diff --git a/docs/demos/eye-tracking-with-webgazer.html b/docs/demos/eye-tracking-with-webgazer.html index 78d2437f..76743bc0 100644 --- a/docs/demos/eye-tracking-with-webgazer.html +++ b/docs/demos/eye-tracking-with-webgazer.html @@ -26,17 +26,17 @@ var jsPsych = initJsPsych({ extensions: [ - {type: 'webgazer'} + {type: jsPsychExtensionWebgazer} ] }); var preload = { - type: 'preload', + type: jsPsychPreload, images: ['img/blue.png'] } var camera_instructions = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: `
In order to participate you must allow the experiment to use your camera.
You will be prompted to do this on the next screen.
@@ -47,11 +47,11 @@ } var init_camera = { - type: 'webgazer-init-camera' + type: jsPsychWebgazerInitCamera } var calibration_instructions = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: `Now you'll calibrate the eye tracking, so that the software can use the image of your eyes to predict where you are looking.
You'll see a series of dots appear on the screen. Look at each dot and click on it.
@@ -60,7 +60,7 @@ } var calibration = { - type: 'webgazer-calibrate', + type: jsPsychWebgazerCalibrate, calibration_points: [ [25,25],[75,25],[50,50],[25,75],[75,75] ], @@ -69,7 +69,7 @@ } var validation_instructions = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: `Now we'll measure the accuracy of the calibration.
Look at each dot as it appears on the screen.
@@ -80,7 +80,7 @@ } var validation = { - type: 'webgazer-validate', + type: jsPsychWebgazerValidate, validation_points: [ [25,25],[75,25],[50,50],[25,75],[75,75] ], @@ -93,7 +93,7 @@ } var recalibrate_instructions = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: `The accuracy of the calibration is a little lower than we'd like.
Let's try calibrating one more time.
@@ -117,7 +117,7 @@ } var calibration_done = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: `Great, we're done with calibration!
`, @@ -125,7 +125,7 @@ } var begin = { - type: 'html-keyboard-response', + type: jsPsychHtmKeyboardResponse, stimulus: `The next screen will show an image to demonstrate adding the webgazer extension to a trial.
Just look at the image while eye tracking data is collected. The trial will end automatically.
Press any key to start.
@@ -133,20 +133,20 @@ } var trial = { - type: 'image-keyboard-response', + type: jsPsychImageKeyboardResponse, stimulus: 'img/blue.png', choices: jsPsych.NO_KEYS, trial_duration: 2000, extensions: [ { - type: 'webgazer', + type: jsPsychExtensionWebgazer, params: {targets: ['#jspsych-image-keyboard-response-stimulus']} } ] } var show_data = { - type: 'html-keyboard-response', + type: jsPsychHtmKeyboardResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-animation-demo.html b/docs/demos/jspsych-animation-demo.html index b9e90cac..896941cf 100644 --- a/docs/demos/jspsych-animation-demo.html +++ b/docs/demos/jspsych-animation-demo.html @@ -17,18 +17,18 @@ var jsPsych = initJsPsych(); var preload_trial = { - type: 'preload', + type: jsPsychPreload, auto_preload: true } var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var animation_trial = { - type: 'animation', + type: jsPsychAnimation, stimuli: [ 'https://cdn.jsdelivr.net/gh/jspsych/jsPsych@6.3.1/examples/img/happy_face_1.jpg', 'https://cdn.jsdelivr.net/gh/jspsych/jsPsych@6.3.1/examples/img/happy_face_2.jpg', @@ -41,7 +41,7 @@ }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-audio-button-response-demo-1.html b/docs/demos/jspsych-audio-button-response-demo-1.html index e3eddf95..a6d75cb3 100644 --- a/docs/demos/jspsych-audio-button-response-demo-1.html +++ b/docs/demos/jspsych-audio-button-response-demo-1.html @@ -15,12 +15,12 @@ var timeline = []; timeline.push({ - type: 'preload', + type: jsPsychPreload, auto_preload: true }); timeline.push({ - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: 'Some browsers now require the user to interact with a page before it can play audio. '+ 'Clicking the button below counts as an interaction.
Be aware of this when planning audio experiments if '+ 'you want the first trial to include audio.
Is the pitch high or low?
" }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-audio-button-response-demo-2.html b/docs/demos/jspsych-audio-button-response-demo-2.html index 41e3c79a..08e1c7cc 100644 --- a/docs/demos/jspsych-audio-button-response-demo-2.html +++ b/docs/demos/jspsych-audio-button-response-demo-2.html @@ -19,13 +19,13 @@ var images = ['img/lion.png', 'img/elephant.png', 'img/monkey.png'] timeline.push({ - type: 'preload', + type: jsPsychPreload, auto_preload: true, images: images }); timeline.push({ - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: 'Some browsers now require the user to interact with a page before it can play audio. '+ 'Clicking the button below counts as an interaction.
Be aware of this when planning audio experiments if '+ 'you want the first trial to include audio.
Which animal made the sound?
", @@ -41,7 +41,7 @@ }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-audio-keyboard-response-demo-1.html b/docs/demos/jspsych-audio-keyboard-response-demo-1.html index fdb639c9..0eb202fc 100644 --- a/docs/demos/jspsych-audio-keyboard-response-demo-1.html +++ b/docs/demos/jspsych-audio-keyboard-response-demo-1.html @@ -13,12 +13,12 @@ var jsPsych = initJsPsych(); var preload = { - type: 'preload', + type: jsPsychPreload, auto_preload: true } var pre_audio = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: 'Some browsers now require the user to interact with a page before it can play audio. '+ 'Clicking the button below counts as an interaction.
Be aware of this when planning audio experiments if '+ 'you want the first trial to include audio.
Is the pitch high or low? Press 'e' for low and 'i' for high.
", @@ -34,7 +34,7 @@ }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-audio-keyboard-response-demo-2.html b/docs/demos/jspsych-audio-keyboard-response-demo-2.html index 52124d6e..06013a66 100644 --- a/docs/demos/jspsych-audio-keyboard-response-demo-2.html +++ b/docs/demos/jspsych-audio-keyboard-response-demo-2.html @@ -13,12 +13,12 @@ var jsPsych = initJsPsych(); var preload = { - type: 'preload', + type: jsPsychPreload, auto_preload: true } var pre_audio = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: 'Some browsers now require the user to interact with a page before it can play audio. '+ 'Clicking the button below counts as an interaction.
Be aware of this when planning audio experiments if '+ 'you want the first trial to include audio.
Some browsers now require the user to interact with a page before it can play audio. '+ 'Clicking the button below counts as an interaction.
Be aware of this when planning audio experiments if '+ 'you want the first trial to include audio.
How funny is the joke?
' }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-audio-slider-response-demo-2.html b/docs/demos/jspsych-audio-slider-response-demo-2.html index 543c446f..1ba88dfb 100644 --- a/docs/demos/jspsych-audio-slider-response-demo-2.html +++ b/docs/demos/jspsych-audio-slider-response-demo-2.html @@ -13,12 +13,12 @@ var jsPsych = initJsPsych(); var preload = { - type: 'preload', + type: jsPsychPreload, auto_preload: true }; var pre_audio = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: 'Some browsers now require the user to interact with a page before it can play audio. '+ 'Clicking the button below counts as an interaction.
Be aware of this when planning audio experiments if '+ 'you want the first trial to include audio.
How funny is the joke?
', @@ -35,7 +35,7 @@ }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); diff --git a/docs/demos/jspsych-call-function-demo1.html b/docs/demos/jspsych-call-function-demo1.html index 40a1bc24..01a892cf 100644 --- a/docs/demos/jspsych-call-function-demo1.html +++ b/docs/demos/jspsych-call-function-demo1.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -36,7 +36,7 @@ } var trial = { - type: 'call-function', + type: jsPsychCallFunction, func: myfunc } diff --git a/docs/demos/jspsych-call-function-demo2.html b/docs/demos/jspsych-call-function-demo2.html index 0e7a1e97..08e5a4b0 100644 --- a/docs/demos/jspsych-call-function-demo2.html +++ b/docs/demos/jspsych-call-function-demo2.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -41,7 +41,7 @@ } var trial = { - type: 'call-function', + type: jsPsychCallFunction, func: function(){ myfunc(jsPsych.data.get()) } } diff --git a/docs/demos/jspsych-call-function-demo3.html b/docs/demos/jspsych-call-function-demo3.html index 8921b8dd..e1145257 100644 --- a/docs/demos/jspsych-call-function-demo3.html +++ b/docs/demos/jspsych-call-function-demo3.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -32,7 +32,7 @@ }; var trial = { - type: 'call-function', + type: jsPsychCallFunction, async: true, func: function(done){ // generate a delay between 1500 and 3000 milliseconds to simulate diff --git a/docs/demos/jspsych-canvas-button-response-demo1.html b/docs/demos/jspsych-canvas-button-response-demo1.html index a41ea398..6b1cc609 100644 --- a/docs/demos/jspsych-canvas-button-response-demo1.html +++ b/docs/demos/jspsych-canvas-button-response-demo1.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var all_trial_data = jsPsych.data.get().filter({trial_type: 'canvas-button-response'}); var last_two_data = all_trial_data.last(2).values(); // One block consists of two canvas-button-response trials @@ -44,7 +44,7 @@ } var circle_1 = { - type: 'canvas-button-response', + type: jsPsychCanvasButtonResponse, stimulus: function(c) { filledCirc(c, 100, 'blue'); }, @@ -55,7 +55,7 @@ }; var circle_2 = { - type: 'canvas-button-response', + type: jsPsychCanvasButtonResponse, stimulus: function(c) { filledCirc(c, 150, 'green'); }, diff --git a/docs/demos/jspsych-canvas-button-response-demo2.html b/docs/demos/jspsych-canvas-button-response-demo2.html index 8d5042fb..5d54facf 100644 --- a/docs/demos/jspsych-canvas-button-response-demo2.html +++ b/docs/demos/jspsych-canvas-button-response-demo2.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -34,7 +34,7 @@ // write the canvas stimulus drawing function without using a named function // the anonymous function must take the canvas as an argument var lines = { - type: 'canvas-button-response', + type: jsPsychCanvasButtonResponse, stimulus: function(c) { var ctx = c.getContext("2d"); // first line diff --git a/docs/demos/jspsych-canvas-button-response-demo3.html b/docs/demos/jspsych-canvas-button-response-demo3.html index 47dbc6f1..f7ef3032 100644 --- a/docs/demos/jspsych-canvas-button-response-demo3.html +++ b/docs/demos/jspsych-canvas-button-response-demo3.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var all_trial_data = jsPsych.data.get().filter({trial_type: 'canvas-button-response'}); var last_three_data = all_trial_data.last(3).values(); // One block consists of three canvas-button-response trials @@ -45,7 +45,7 @@ // In addition, this code demonstrates how to check whether participants' answers were correct or not. var circle_procedure = { timeline: [{ - type: 'canvas-button-response', + type: jsPsychCanvasButtonResponse, stimulus: function(c) { filledCirc(c, jsPsych.timelineVariable('radius'), jsPsych.timelineVariable('color')); }, diff --git a/docs/demos/jspsych-canvas-keyboard-response-demo1.html b/docs/demos/jspsych-canvas-keyboard-response-demo1.html index 06b87866..c194f92f 100644 --- a/docs/demos/jspsych-canvas-keyboard-response-demo1.html +++ b/docs/demos/jspsych-canvas-keyboard-response-demo1.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -40,7 +40,7 @@ } var trial = { - type: 'canvas-keyboard-response', + type: jsPsychCanvasKeyboardResponse, canvas_size: [300, 300], stimulus: drawRect, choices: ['e','i'], diff --git a/docs/demos/jspsych-canvas-keyboard-response-demo2.html b/docs/demos/jspsych-canvas-keyboard-response-demo2.html index e6049e5f..9ca292d3 100644 --- a/docs/demos/jspsych-canvas-keyboard-response-demo2.html +++ b/docs/demos/jspsych-canvas-keyboard-response-demo2.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -40,7 +40,7 @@ } var trial = { - type: 'canvas-keyboard-response', + type: jsPsychCanvasKeyboardResponse, canvas_size: [300, 300], stimulus: drawCirc, prompt: 'No key response is allowed.
The stimulus disappears after 3 seconds.
', diff --git a/docs/demos/jspsych-canvas-slider-response-demo1.html b/docs/demos/jspsych-canvas-slider-response-demo1.html index b5691b46..0698f616 100644 --- a/docs/demos/jspsych-canvas-slider-response-demo1.html +++ b/docs/demos/jspsych-canvas-slider-response-demo1.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -44,7 +44,7 @@ } var trial = { - type: 'canvas-slider-response', + type: jsPsychCanvasSliderResponse, stimulus: twoSquares, labels: ['0','10'], canvas_size: [150, 500], diff --git a/docs/demos/jspsych-canvas-slider-response-demo2.html b/docs/demos/jspsych-canvas-slider-response-demo2.html index 71b788fb..cde5ad2d 100644 --- a/docs/demos/jspsych-canvas-slider-response-demo2.html +++ b/docs/demos/jspsych-canvas-slider-response-demo2.html @@ -15,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -44,7 +44,7 @@ } var trial = { - type: 'canvas-slider-response', + type: jsPsychCanvasSliderResponse, stimulus: function(c) { colors = ['darkred', 'cyan']; twoSquares(c, colors); diff --git a/docs/demos/jspsych-categorize-animation-demo1.html b/docs/demos/jspsych-categorize-animation-demo1.html index fdcb6870..81d062ba 100644 --- a/docs/demos/jspsych-categorize-animation-demo1.html +++ b/docs/demos/jspsych-categorize-animation-demo1.html @@ -17,13 +17,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -34,12 +34,12 @@ }; var preload_trial = { - type: 'preload', + type: jsPsychPreload, auto_preload: true } var animation_trial = { - type: 'categorize-animation', + type: jsPsychCategorizeAnimation, stimuli: [ 'https://cdn.jsdelivr.net/gh/jspsych/jsPsych@6.3.1/examples/img/happy_face_1.jpg', 'https://cdn.jsdelivr.net/gh/jspsych/jsPsych@6.3.1/examples/img/happy_face_2.jpg', diff --git a/docs/demos/jspsych-categorize-animation-demo2.html b/docs/demos/jspsych-categorize-animation-demo2.html index 0a93de24..d440d1cb 100644 --- a/docs/demos/jspsych-categorize-animation-demo2.html +++ b/docs/demos/jspsych-categorize-animation-demo2.html @@ -17,13 +17,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -34,7 +34,7 @@ }; var preload_trial = { - type: 'preload', + type: jsPsychPreload, auto_preload: true } @@ -46,7 +46,7 @@ ]; var animation_trial = { - type: 'categorize-animation', + type: jsPsychCategorizeAnimation, stimuli: images, choices: ['p', 'q'], prompt: `Press the P or Q key.`, diff --git a/docs/demos/jspsych-categorize-html-demo1.html b/docs/demos/jspsych-categorize-html-demo1.html index 67325970..7e42f52d 100644 --- a/docs/demos/jspsych-categorize-html-demo1.html +++ b/docs/demos/jspsych-categorize-html-demo1.html @@ -2,7 +2,6 @@ - @@ -16,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -33,7 +32,7 @@ }; var categorization_trial = { - type: 'categorize-html', + type: jsPsychCategorizeHtml, stimulus: 'B
', key_answer: 'p', text_answer: 'letter', diff --git a/docs/demos/jspsych-categorize-image-demo1.html b/docs/demos/jspsych-categorize-image-demo1.html index 1fe2afd7..7a608b49 100644 --- a/docs/demos/jspsych-categorize-image-demo1.html +++ b/docs/demos/jspsych-categorize-image-demo1.html @@ -16,13 +16,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -33,12 +33,12 @@ }; var preload_trial = { - type: 'preload', + type: jsPsychPreload, auto_preload: true } var categorization_trial = { - type: 'categorize-image', + type: jsPsychCategorizeImage, stimulus: 'https://cdn.jsdelivr.net/gh/jspsych/jsPsych@6.3.1/examples/img/blue.png', key_answer: 'b', text_answer: 'Blue', diff --git a/docs/demos/jspsych-cloze-demo1.html b/docs/demos/jspsych-cloze-demo1.html index 5cc950f7..b3fafeee 100644 --- a/docs/demos/jspsych-cloze-demo1.html +++ b/docs/demos/jspsych-cloze-demo1.html @@ -2,7 +2,6 @@ - @@ -16,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -33,7 +32,7 @@ }; var cloze_trial = { - type: 'cloze', + type: jsPsychCloze, text: 'The %% is the largest terrestrial mammal. It lives in both %% and %%.' }; diff --git a/docs/demos/jspsych-cloze-demo2.html b/docs/demos/jspsych-cloze-demo2.html index 77b9117e..3b28f8f0 100644 --- a/docs/demos/jspsych-cloze-demo2.html +++ b/docs/demos/jspsych-cloze-demo2.html @@ -2,7 +2,6 @@ - @@ -16,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -33,7 +32,7 @@ }; var cloze_trial = { - type: 'cloze', + type: jsPsychCloze, text: 'A rectangle has % 4 % corners and a triangle has % 3 %.', check_answers: true, button_text: 'Next', diff --git a/docs/demos/jspsych-external-html-demo1.html b/docs/demos/jspsych-external-html-demo1.html index ed35f20c..15cd6fa3 100644 --- a/docs/demos/jspsych-external-html-demo1.html +++ b/docs/demos/jspsych-external-html-demo1.html @@ -2,7 +2,6 @@ - @@ -16,13 +15,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -47,7 +46,7 @@ // declare the block. var trial = { - type:'external-html', + type: jsPsychExternalHtml, url: "external_page.html", cont_btn: "start", check_fn: check_consent diff --git a/docs/demos/jspsych-free-sort-demo1.html b/docs/demos/jspsych-free-sort-demo1.html index cc6fec0f..2828d71f 100644 --- a/docs/demos/jspsych-free-sort-demo1.html +++ b/docs/demos/jspsych-free-sort-demo1.html @@ -16,13 +16,13 @@ var jsPsych = initJsPsych(); var start = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: '', choices: ['Run demo'] }; var show_data = { - type: 'html-button-response', + type: jsPsychHtmlButtonResponse, stimulus: function() { var trial_data = jsPsych.data.getLastTrialData().values(); var trial_json = JSON.stringify(trial_data, null, 2); @@ -40,12 +40,12 @@ ] var preload_trial = { - type: 'preload', + type: jsPsychPreload, images: sorting_stimuli } var sort_trial = { - type: 'free-sort', + type: jsPsychFreeSort, stimuli: sorting_stimuli, stim_width: 80, stim_height: 60, diff --git a/docs/demos/jspsych-fullscreen-demo1.html b/docs/demos/jspsych-fullscreen-demo1.html index 719634e7..65be4562 100644 --- a/docs/demos/jspsych-fullscreen-demo1.html +++ b/docs/demos/jspsych-fullscreen-demo1.html @@ -2,7 +2,6 @@ - -