jspsych 8.0.2 → 8.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.browser.js +9 -10
- package/dist/index.browser.js.map +1 -1
- package/dist/index.browser.min.js +3 -3
- package/dist/index.browser.min.js.map +1 -1
- package/dist/index.cjs +8 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +20 -7
- package/dist/index.js +8 -9
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/modules/randomization.ts +29 -10
- package/src/timeline/Timeline.spec.ts +105 -5
- package/src/timeline/Timeline.ts +12 -9
package/dist/index.browser.js
CHANGED
|
@@ -53,7 +53,7 @@ var jsPsychModule = (function (exports) {
|
|
|
53
53
|
|
|
54
54
|
var _package = {
|
|
55
55
|
name: "jspsych",
|
|
56
|
-
version: "8.0
|
|
56
|
+
version: "8.1.0",
|
|
57
57
|
description: "Behavioral experiments in a browser",
|
|
58
58
|
type: "module",
|
|
59
59
|
main: "dist/index.cjs",
|
|
@@ -101,7 +101,7 @@ var jsPsychModule = (function (exports) {
|
|
|
101
101
|
},
|
|
102
102
|
devDependencies: {
|
|
103
103
|
"@fontsource/open-sans": "4.5.3",
|
|
104
|
-
"@jspsych/config": "^3.0.
|
|
104
|
+
"@jspsych/config": "^3.0.1",
|
|
105
105
|
"@types/dom-mediacapture-record": "^1.0.11",
|
|
106
106
|
"base64-inline-loader": "^2.0.1",
|
|
107
107
|
"css-loader": "^6.6.0",
|
|
@@ -2574,7 +2574,8 @@ var jsPsychModule = (function (exports) {
|
|
|
2574
2574
|
}
|
|
2575
2575
|
for (const timelineVariableIndex of timelineVariableOrder) {
|
|
2576
2576
|
this.setCurrentTimelineVariablesByIndex(timelineVariableIndex);
|
|
2577
|
-
for (const
|
|
2577
|
+
for (const childNodeDescription of this.description.timeline) {
|
|
2578
|
+
const childNode = this.instantiateChildNode(childNodeDescription);
|
|
2578
2579
|
const previousChild = this.currentChild;
|
|
2579
2580
|
this.currentChild = childNode;
|
|
2580
2581
|
childNode.index = previousChild ? previousChild.getLatestNode().index + 1 : this.index;
|
|
@@ -2632,12 +2633,10 @@ var jsPsychModule = (function (exports) {
|
|
|
2632
2633
|
}
|
|
2633
2634
|
}
|
|
2634
2635
|
}
|
|
2635
|
-
|
|
2636
|
-
const
|
|
2637
|
-
|
|
2638
|
-
|
|
2639
|
-
this.children.push(...newChildNodes);
|
|
2640
|
-
return newChildNodes;
|
|
2636
|
+
instantiateChildNode(childDescription) {
|
|
2637
|
+
const newChildNode = isTimelineDescription(childDescription) ? new Timeline(this.dependencies, childDescription, this) : new Trial(this.dependencies, childDescription, this);
|
|
2638
|
+
this.children.push(newChildNode);
|
|
2639
|
+
return newChildNode;
|
|
2641
2640
|
}
|
|
2642
2641
|
currentTimelineVariables;
|
|
2643
2642
|
setCurrentTimelineVariablesByIndex(index) {
|
|
@@ -3100,4 +3099,4 @@ var jsPsychModule = (function (exports) {
|
|
|
3100
3099
|
|
|
3101
3100
|
})({});
|
|
3102
3101
|
var initJsPsych = jsPsychModule.initJsPsych;
|
|
3103
|
-
//# sourceMappingURL=https://unpkg.com/jspsych@8.0
|
|
3102
|
+
//# sourceMappingURL=https://unpkg.com/jspsych@8.1.0/dist/index.browser.js.map
|