jspsych-tangram 0.0.13 → 0.0.15
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/afc/index.browser.js +17751 -0
- package/dist/afc/index.browser.js.map +1 -0
- package/dist/afc/index.browser.min.js +42 -0
- package/dist/afc/index.browser.min.js.map +1 -0
- package/dist/afc/index.cjs +443 -0
- package/dist/afc/index.cjs.map +1 -0
- package/dist/afc/index.d.ts +169 -0
- package/dist/afc/index.js +441 -0
- package/dist/afc/index.js.map +1 -0
- package/dist/construct/index.browser.js +8 -2
- package/dist/construct/index.browser.js.map +1 -1
- package/dist/construct/index.browser.min.js +10 -10
- package/dist/construct/index.browser.min.js.map +1 -1
- package/dist/construct/index.cjs +8 -2
- package/dist/construct/index.cjs.map +1 -1
- package/dist/construct/index.js +8 -2
- package/dist/construct/index.js.map +1 -1
- package/dist/index.cjs +379 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +178 -12
- package/dist/index.js +379 -12
- package/dist/index.js.map +1 -1
- package/dist/nback/index.browser.js +6 -4
- package/dist/nback/index.browser.js.map +1 -1
- package/dist/nback/index.browser.min.js +8 -8
- package/dist/nback/index.browser.min.js.map +1 -1
- package/dist/nback/index.cjs +6 -4
- package/dist/nback/index.cjs.map +1 -1
- package/dist/nback/index.js +6 -4
- package/dist/nback/index.js.map +1 -1
- package/dist/prep/index.browser.js +8 -2
- package/dist/prep/index.browser.js.map +1 -1
- package/dist/prep/index.browser.min.js +10 -10
- package/dist/prep/index.browser.min.js.map +1 -1
- package/dist/prep/index.cjs +8 -2
- package/dist/prep/index.cjs.map +1 -1
- package/dist/prep/index.js +8 -2
- package/dist/prep/index.js.map +1 -1
- package/package.json +1 -1
- package/src/core/components/board/GameBoard.tsx +13 -42
- package/src/core/components/board/useGameBoard.ts +52 -0
- package/src/core/components/index.ts +4 -2
- package/src/core/components/pieces/BlueprintRing.tsx +0 -25
- package/src/core/components/pieces/useBlueprintRing.ts +39 -0
- package/src/index.ts +2 -1
- package/src/plugins/tangram-afc/AFCApp.tsx +341 -0
- package/src/plugins/tangram-afc/index.ts +140 -0
- package/src/plugins/tangram-nback/NBackApp.tsx +3 -3
- package/tangram-construct.min.js +10 -10
- package/tangram-nback.min.js +8 -8
- package/tangram-prep.min.js +10 -10
package/dist/construct/index.cjs
CHANGED
|
@@ -3476,14 +3476,20 @@ function GameBoard(props) {
|
|
|
3476
3476
|
lineHeight: 1.5,
|
|
3477
3477
|
textAlign: "center"
|
|
3478
3478
|
};
|
|
3479
|
+
const scaleX = svgDimensions.width / viewBox.w;
|
|
3480
|
+
const rightEdgeOfSemicircleLogical = viewBox.w / 2 + layout.outerR;
|
|
3481
|
+
const distanceFromRightEdgeLogical = viewBox.w - rightEdgeOfSemicircleLogical;
|
|
3482
|
+
const distanceFromRightEdgePx = distanceFromRightEdgeLogical * scaleX;
|
|
3483
|
+
const charWidth = 24 * 0.6;
|
|
3484
|
+
const offsetLeft = charWidth * 5;
|
|
3479
3485
|
const timerStyle = {
|
|
3480
3486
|
position: "absolute",
|
|
3481
|
-
right:
|
|
3487
|
+
right: `${distanceFromRightEdgePx + offsetLeft}px`,
|
|
3482
3488
|
fontSize: "24px",
|
|
3483
3489
|
fontWeight: "bold",
|
|
3484
3490
|
fontFamily: "monospace",
|
|
3485
3491
|
color: "#333",
|
|
3486
|
-
|
|
3492
|
+
whiteSpace: "nowrap",
|
|
3487
3493
|
textAlign: "right"
|
|
3488
3494
|
};
|
|
3489
3495
|
const gameboardWrapperStyle = {
|