diff --git a/docs/overview/building-surveys.md b/docs/overview/building-surveys.md index 257a695410..5a5dccfb38 100644 --- a/docs/overview/building-surveys.md +++ b/docs/overview/building-surveys.md @@ -387,7 +387,7 @@ Rather than repeating a question format within the same trial, perhaps you want elements: [ { type: "text", - title: `Enter a word related to ${jsPsych.timelineVariable('word').toUpperCase()}:`, + title: `Enter a word related to ${jsPsych.evaluteTimelineVariable('word').toUpperCase()}:`, autocomplete: "off" } ], @@ -416,7 +416,7 @@ Rather than repeating a question format within the same trial, perhaps you want // Create question using timeline variables const page = survey.addNewPage('page1'); const question = page.addNewQuestion('text'); - question.title = `Enter a word related to ${jsPsych.timelineVariable('word').toUpperCase()}`; + question.title = `Enter a word related to ${jsPsych.evaluateTimelineVariable('word').toUpperCase()}`; question.autocomplete = "off"; // Set survey-level parameters survey.showQuestionNumbers = false; diff --git a/examples/extension-record-video.html b/examples/extension-record-video.html index 10108a75c5..29cf9ee570 100644 --- a/examples/extension-record-video.html +++ b/examples/extension-record-video.html @@ -32,7 +32,7 @@ type: jsPsychHtmlKeyboardResponse, stimulus: ()=>{ let html = `
-
+
`; return html; }, diff --git a/examples/webgazer.html b/examples/webgazer.html index c7d19455d5..a1a04cfffa 100644 --- a/examples/webgazer.html +++ b/examples/webgazer.html @@ -109,8 +109,8 @@ stimulus: function () { return( `
-
- ${jsPsych.timelineVariable('direction', true) == 'left' ? '⬅' : '➡'} +
+ ${jsPsych.evaluateTimelineVariable('direction', true) == 'left' ? '⬅' : '➡'}
` ) diff --git a/packages/plugin-survey/examples/dynamically_generating_content.html b/packages/plugin-survey/examples/dynamically_generating_content.html index 15c3df1b4e..be3f4ea396 100644 --- a/packages/plugin-survey/examples/dynamically_generating_content.html +++ b/packages/plugin-survey/examples/dynamically_generating_content.html @@ -100,7 +100,7 @@ type: jsPsychHtmlKeyboardResponse, stimulus: function () { var html = ` -
${jsPsych.timelineVariable('word1')}${jsPsych.timelineVariable('word2')}
`; +
${jsPsych.evaluateTimelineVariable('word1')}${jsPsych.evaluateTimelineVariable('word2')}
`; return html; }, choices: ['f', 'j'], @@ -112,7 +112,7 @@ survey_json: function () { const last_response = jsPsych.data.getLastTrialData().values()[0].response; const response_type = (last_response === 'j') ? "RELATED" : "NOT RELATED"; - const question_text = `You said that the words "${jsPsych.timelineVariable('word1')}" and "${jsPsych.timelineVariable('word2')}" are ${response_type}. Please explain your answer.`; + const question_text = `You said that the words "${jsPsych.evaluateTimelineVariable('word1')}" and "${jsPsych.evaluateTimelineVariable('word2')}" are ${response_type}. Please explain your answer.`; const survey_json = { showQuestionNumbers: false, completeText: "Next",