lido-player 0.0.2-beta-24 → 0.0.2-beta-26-dev
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/LICENSE +21 -21
- package/dist/cjs/{decode-BCvdWRyT.js → decode-CE64w_Pc.js} +1 -1
- package/dist/cjs/{index-DjM03fsg.js → index-Cf9LHdIw.js} +238 -87
- package/dist/cjs/{index-DBCFoh1I.js → index-DnaH8sO-.js} +1 -1
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/lido-avatar_22.cjs.entry.js +214 -53
- package/dist/cjs/lido-player.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/components/avatar/lido-avatar.css +4 -4
- package/dist/collection/components/avatar/lido-avatar.js +1 -1
- package/dist/collection/components/avatar/lido-avatar.tsx +214 -214
- package/dist/collection/components/avatar/readme.md +49 -49
- package/dist/collection/components/calculator/lido-calculator.css +89 -89
- package/dist/collection/components/calculator/lido-calculator.js +2 -2
- package/dist/collection/components/canvas/lido-canvas.css +33 -33
- package/dist/collection/components/canvas/lido-canvas.js +1 -1
- package/dist/collection/components/cell/lido-cell.css +100 -100
- package/dist/collection/components/cell/lido-cell.js +12 -12
- package/dist/collection/components/column/lido-col.css +19 -19
- package/dist/collection/components/column/lido-col.js +6 -6
- package/dist/collection/components/container/lido-container.css +34 -10
- package/dist/collection/components/container/lido-container.js +55 -9
- package/dist/collection/components/flashCard/lido-flash-card.css +72 -72
- package/dist/collection/components/flashCard/lido-flash-card.js +84 -15
- package/dist/collection/components/float/lido-float.css +30 -30
- package/dist/collection/components/float/lido-float.js +2 -2
- package/dist/collection/components/home/lido-home.css +309 -309
- package/dist/collection/components/home/lido-home.js +38 -14
- package/dist/collection/components/image/lido-image.css +17 -17
- package/dist/collection/components/image/lido-image.js +6 -6
- package/dist/collection/components/keyboard/lido-keyboard.css +38 -38
- package/dist/collection/components/keyboard/lido-keyboard.js +3 -3
- package/dist/collection/components/mathMatrix/lido-math-matrix.css +56 -56
- package/dist/collection/components/mathMatrix/lido-math-matrix.js +1 -1
- package/dist/collection/components/position/lido-pos.css +16 -16
- package/dist/collection/components/position/lido-pos.js +2 -2
- package/dist/collection/components/random/lido-random.css +8 -8
- package/dist/collection/components/random/lido-random.js +2 -2
- package/dist/collection/components/root/lido-root.js +6 -6
- package/dist/collection/components/row/lido-row.css +10 -10
- package/dist/collection/components/row/lido-row.js +6 -6
- package/dist/collection/components/scale/assets/Shadow.svg +9 -9
- package/dist/collection/components/scale/lido-balance.css +174 -174
- package/dist/collection/components/scale/lido-balance.js +13 -13
- package/dist/collection/components/shape/lido-shape.css +216 -216
- package/dist/collection/components/shape/lido-shape.js +6 -6
- package/dist/collection/components/slideFill/lido-slide-fill.css +3 -3
- package/dist/collection/components/slideFill/lido-slide-fill.js +13 -13
- package/dist/collection/components/text/lido-text.css +53 -53
- package/dist/collection/components/text/lido-text.js +6 -6
- package/dist/collection/components/trace/assets/Tracing-hand.svg +8 -8
- package/dist/collection/components/trace/lido-trace.css +97 -97
- package/dist/collection/components/trace/lido-trace.js +2 -2
- package/dist/collection/components/wrap/lido-wrap.css +18 -18
- package/dist/collection/components/wrap/lido-wrap.js +6 -6
- package/dist/collection/css/animation.css +211 -211
- package/dist/collection/css/index.css +323 -323
- package/dist/collection/stories/Templates/Fill-Up/fill-up.stories.js +61 -61
- package/dist/collection/stories/Templates/LetterPairing/LetterPairing.stories.js +123 -123
- package/dist/collection/stories/Templates/RocketGame/rocketGame.stories.js +48 -48
- package/dist/collection/stories/Templates/Tag/tagGame.stories.js +39 -39
- package/dist/collection/stories/Templates/arrangeLetters/arrangeLetters.stories.js +44 -44
- package/dist/collection/stories/Templates/balancing/balancing.stories.js +35 -35
- package/dist/collection/stories/Templates/balloonPop/balloonPop.stories.js +38 -38
- package/dist/collection/stories/Templates/blender/blender.stories.js +59 -59
- package/dist/collection/stories/Templates/bubbleType/bubbleType.stories.js +42 -42
- package/dist/collection/stories/Templates/calculator/calculator.stories.js +28 -28
- package/dist/collection/stories/Templates/categorize/categorize.stories.js +37 -37
- package/dist/collection/stories/Templates/categorize2/categorize2.stories.js +67 -67
- package/dist/collection/stories/Templates/checker-block/checkerBlock.stories.js +29 -29
- package/dist/collection/stories/Templates/checkerBlock/checkerBlock.stories.js +13 -13
- package/dist/collection/stories/Templates/create-sentence/createSentence.stories.js +74 -74
- package/dist/collection/stories/Templates/dragAndDrop/drag-drop.stories.js +69 -69
- package/dist/collection/stories/Templates/fillAnswer/fill-answer.stories.js +43 -43
- package/dist/collection/stories/Templates/fillBlank/fill-blank.stories.js +282 -282
- package/dist/collection/stories/Templates/foodJar/food-jar.stories.js +35 -35
- package/dist/collection/stories/Templates/grid/grid.stories.js +118 -118
- package/dist/collection/stories/Templates/gridGame/grid-game.stories.js +57 -57
- package/dist/collection/stories/Templates/imageMatch/imageMatch.stories.js +44 -44
- package/dist/collection/stories/Templates/jumpSentence/jumpSentence.stories.js +41 -41
- package/dist/collection/stories/Templates/letterboard/letterboard.stories.js +183 -183
- package/dist/collection/stories/Templates/makeSentence/make-sentence.stories.js +36 -36
- package/dist/collection/stories/Templates/matchBox/matchBox.stories.js +69 -69
- package/dist/collection/stories/Templates/matchBox/matchBox2.stories.js +84 -84
- package/dist/collection/stories/Templates/matchingCard/matching-card.stories.js +31 -31
- package/dist/collection/stories/Templates/multipleOption/mcqWithQuestionImage.stories.js +112 -112
- package/dist/collection/stories/Templates/multipleOption/multiple-option.stories.js +47 -47
- package/dist/collection/stories/Templates/multiplyBeeds/multiplyBeeds.stories.js +57 -57
- package/dist/collection/stories/Templates/nimbleTable/nimbleTable.stories.js +53 -53
- package/dist/collection/stories/Templates/numberBoard/numberBoard.stories.js +46 -46
- package/dist/collection/stories/Templates/numberBoardTwo/numberBoardTwo.stories.js +45 -45
- package/dist/collection/stories/Templates/numberIdentification/numberIdentificationimageTotext.stories.js +56 -56
- package/dist/collection/stories/Templates/numberIdentification/numberIdentificationtextTotext.stories.js +53 -53
- package/dist/collection/stories/Templates/numberPair/numberPair.stories.js +127 -127
- package/dist/collection/stories/Templates/openwindow/openwindow.stories.js +47 -47
- package/dist/collection/stories/Templates/openwindow/openwindow2.stories.js +38 -38
- package/dist/collection/stories/Templates/order-tractor/order-tractor-ascending-order.stories.js +97 -97
- package/dist/collection/stories/Templates/order-tractor/order-tractor.stories.js +90 -90
- package/dist/collection/stories/Templates/palEgmaCalculateSum/palEgmaMultiOption.stories.js +63 -63
- package/dist/collection/stories/Templates/palEgmaCalculateSum/palEgmaSumTogether.stories.js +45 -45
- package/dist/collection/stories/Templates/palEgmaPatternMatching/palEgmaPatternMatching.stories.js +63 -63
- package/dist/collection/stories/Templates/palEgmaWordProblem/palEgmaWordProblem.stories.js +79 -79
- package/dist/collection/stories/Templates/palEgraInventedSpelling/pal_egra_invented_spelling_schema.stories.js +32 -32
- package/dist/collection/stories/Templates/palEgraMCQWithImage/palEgraMCQWithImage.stories.js +42 -42
- package/dist/collection/stories/Templates/palEgraOptionWithAudio/palEgraOptionWithAudio.stories.js +63 -63
- package/dist/collection/stories/Templates/palEgraStoryMaking/pal_egra_story_making.stories.js +44 -44
- package/dist/collection/stories/Templates/palEgraTemplate1/palEgraLetterIdentification.stories.js +34 -34
- package/dist/collection/stories/Templates/palEgraWordMatch/palEgraWordMatch.stories.js +52 -52
- package/dist/collection/stories/Templates/palEgra_OddOneOut/palEgra_oddOneOut.stories.js +33 -33
- package/dist/collection/stories/Templates/palEgra_arrange_pictures/palEgra_arrange_pictures.stories.js +40 -40
- package/dist/collection/stories/Templates/palEgra_build_word/palEgra_build_word.stories.js +48 -48
- package/dist/collection/stories/Templates/palEgra_word_formation/palEgra_WordFormation.stories.js +48 -48
- package/dist/collection/stories/Templates/palStorytale/palStorytale.stories.js +18 -18
- package/dist/collection/stories/Templates/phonic-tractor/phonic-tractor.stories.js +44 -44
- package/dist/collection/stories/Templates/pictureClues/pictureClues.stories.js +34 -34
- package/dist/collection/stories/Templates/pictureWordMatch/pictureWordMatch1.stories.js +36 -36
- package/dist/collection/stories/Templates/pictureWordMatch/pictureWordMatch2.stories.js +30 -30
- package/dist/collection/stories/Templates/picturemeaning/pictureMeaningCocos.stories.js +20 -20
- package/dist/collection/stories/Templates/puzzleGame/puzzleGame.stories.js +17 -17
- package/dist/collection/stories/Templates/questionBoard/questionBoard.stories.js +58 -58
- package/dist/collection/stories/Templates/quizLiteracy/quizLiteracy.stories.js +50 -50
- package/dist/collection/stories/Templates/quizLiteracy/quizLiteracyImageWithText.stories.js +36 -36
- package/dist/collection/stories/Templates/quizLiteracy/quizLiteracyImageWord.stories.js +43 -43
- package/dist/collection/stories/Templates/quizMaths/quizMaths.stories.js +633 -633
- package/dist/collection/stories/Templates/reorder/reorder.stories.js +63 -63
- package/dist/collection/stories/Templates/rowBlocks/rowBlocks.stories.js +47 -47
- package/dist/collection/stories/Templates/sentenceMatch/sentenceMatch.stories.js +29 -29
- package/dist/collection/stories/Templates/sequenceBox/sequenceBox1.stories.js +64 -64
- package/dist/collection/stories/Templates/sequenceBox/sequenceBox2.stories.js +62 -62
- package/dist/collection/stories/Templates/shapePair/shape-pair.stories.js +106 -106
- package/dist/collection/stories/Templates/shapeTractor/shape-tractor.stories.js +50 -50
- package/dist/collection/stories/Templates/spellDoor/spellDoor.stories.js +41 -41
- package/dist/collection/stories/Templates/storyTale/storyTale.stories.js +39 -39
- package/dist/collection/stories/Templates/substraction/substractionWithimg.stories.js +62 -62
- package/dist/collection/stories/Templates/substraction/substractionWithoutImg.stories.js +42 -42
- package/dist/collection/stories/Templates/sumTogether/sumTogether.stories.js +50 -50
- package/dist/collection/stories/Templates/tenBox/tenBox.stories.js +88 -88
- package/dist/collection/stories/Templates/total/total.stories.js +28 -28
- package/dist/collection/stories/Templates/wordBuilding/wordBuildingwithimg.stories.js +35 -35
- package/dist/collection/stories/Templates/wordBuilding/wordBuildingwithoutimg.stories.js +34 -34
- package/dist/collection/stories/Templates/writeCard/writeCard.stories.js +31 -31
- package/dist/collection/stories/Templates/writeLetter/writeLetter.stories.js +58 -58
- package/dist/collection/stories/Templates/writeNumber/writeNumber.stories.js +44 -44
- package/dist/collection/stories/Templates/writeSet/writeSet.stories.js +31 -31
- package/dist/collection/stories/Templates/writeWord/writeWord.stories.js +34 -34
- package/dist/collection/stories/components/flash-card.stories.js +48 -48
- package/dist/collection/stories/components/keyboard.stories.js +10 -10
- package/dist/collection/stories/components/slider.stories.js +4 -4
- package/dist/collection/stories/components/trace.stories.js +5 -5
- package/dist/collection/utils/audioPlayer.js +10 -3
- package/dist/collection/utils/constants.js +6 -0
- package/dist/collection/utils/utils.js +109 -14
- package/dist/collection/utils/utilsHandlers/dragDropHandler.js +8 -8
- package/dist/collection/utils/utilsHandlers/highlightHandler.js +54 -54
- package/dist/collection/utils/utilsHandlers/slideHandler.js +58 -19
- package/dist/collection/utils/utilsHandlers/sortHandler.js +10 -10
- package/dist/components/index.js +1 -1
- package/dist/components/lido-avatar.js +1 -1
- package/dist/components/lido-balance.js +1 -1
- package/dist/components/lido-calculator.js +1 -1
- package/dist/components/lido-canvas.js +1 -1
- package/dist/components/lido-cell.js +1 -1
- package/dist/components/lido-col.js +1 -1
- package/dist/components/lido-container.js +1 -1
- package/dist/components/lido-flash-card.js +1 -1
- package/dist/components/lido-float.js +1 -1
- package/dist/components/lido-home.js +1 -1
- package/dist/components/lido-image.js +1 -1
- package/dist/components/lido-keyboard.js +1 -1
- package/dist/components/lido-math-matrix.js +1 -1
- package/dist/components/lido-pos.js +1 -1
- package/dist/components/lido-random.js +1 -1
- package/dist/components/lido-root.js +1 -1
- package/dist/components/lido-row.js +1 -1
- package/dist/components/lido-shape.js +1 -1
- package/dist/components/lido-slide-fill.js +1 -1
- package/dist/components/lido-text.js +1 -1
- package/dist/components/lido-trace.js +1 -1
- package/dist/components/lido-wrap.js +1 -1
- package/dist/components/p-B4iWvszS.js +1 -0
- package/dist/components/{p-C5jvgiPE.js → p-BA-XmR9g.js} +1 -1
- package/dist/components/p-BJt-z8VW.js +1 -0
- package/dist/components/{p-CTlcpv4a.js → p-BfwUqpXc.js} +1 -1
- package/dist/components/{p-DNo3iX_r.js → p-BiBt9LGP.js} +1 -1
- package/dist/components/{p-DG0KR2iN.js → p-BlN0IsR4.js} +1 -1
- package/dist/components/{p-CFPSty2U.js → p-BpVpANK9.js} +1 -1
- package/dist/components/{p-CgsPIpg0.js → p-Bw-OC9iR.js} +1 -1
- package/dist/components/p-C2J7-bcH.js +1 -0
- package/dist/components/{p-CFWohOId.js → p-CEmofYPx.js} +1 -1
- package/dist/components/{p-C5WmmkI6.js → p-CPYnt0P-.js} +1 -1
- package/dist/components/{p-CsDu4kiC.js → p-ChfVUoX4.js} +1 -1
- package/dist/components/p-CnQ-4EIw.js +1 -0
- package/dist/components/{p-CXHPZN3m.js → p-CyGxEcn7.js} +1 -1
- package/dist/components/{p-C-pHQRbp.js → p-D1cBkIab.js} +1 -1
- package/dist/components/p-DP6jQ5ML.js +1 -0
- package/dist/components/{p-Bv1hunWk.js → p-DV-k1ulI.js} +1 -1
- package/dist/components/p-Qhj9-H6e.js +12 -0
- package/dist/components/{p-Bh_vemY3.js → p-hUfX1As2.js} +1 -1
- package/dist/components/p-leIEepjl.js +1 -0
- package/dist/components/{p-B8nzzM8c.js → p-s4oGlKg6.js} +1 -1
- package/dist/components/{p-C70ykycD.js → p-useuhkjH.js} +1 -1
- package/dist/esm/{decode-BxzUG5XP.js → decode-DhjaTUf2.js} +1 -1
- package/dist/esm/{index-C_uxZLF-.js → index-Bc6Y7rds.js} +235 -88
- package/dist/esm/{index-mMpK8062.js → index-Dvjbti-h.js} +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/lido-avatar_22.entry.js +214 -53
- package/dist/esm/lido-player.js +3 -3
- package/dist/esm/loader.js +3 -3
- package/dist/lido-player/assets/Shadow.svg +9 -9
- package/dist/lido-player/assets/Tracing-hand.svg +8 -8
- package/dist/lido-player/index.esm.js +1 -1
- package/dist/lido-player/lido-avatar.css +4 -4
- package/dist/lido-player/lido-avatar.tsx +214 -214
- package/dist/lido-player/lido-player.css +7 -7
- package/dist/lido-player/lido-player.esm.js +1 -1
- package/dist/lido-player/{p-CsCr7DlS.js → p-CORilAH-.js} +1 -1
- package/dist/lido-player/p-D66K5DXn.js +1 -0
- package/dist/lido-player/p-Dvjbti-h.js +2 -0
- package/dist/lido-player/p-ca195982.entry.js +12 -0
- package/dist/lido-player/readme.md +49 -49
- package/dist/types/components/container/lido-container.d.ts +7 -0
- package/dist/types/components/flashCard/lido-flash-card.d.ts +2 -0
- package/dist/types/components.d.ts +1 -0
- package/dist/types/types/json.d.ts +3 -3
- package/dist/types/utils/audioPlayer.d.ts +1 -1
- package/dist/types/utils/constants.d.ts +2 -0
- package/dist/types/utils/utils.d.ts +11 -0
- package/dist/types/utils/utilsHandlers/slideHandler.d.ts +1 -1
- package/package.json +73 -73
- package/readme.md +113 -113
- package/dist/components/p-CgBwmr9A.js +0 -12
- package/dist/components/p-Ckb8QhUV.js +0 -1
- package/dist/components/p-DDwqmTYM.js +0 -1
- package/dist/components/p-DLyacZap.js +0 -1
- package/dist/components/p-DONbWJGn.js +0 -1
- package/dist/components/p-DXy70SGv.js +0 -1
- package/dist/components/p-Gwko4CTL.js +0 -1
- package/dist/lido-player/p-00993d1a.entry.js +0 -12
- package/dist/lido-player/p-mMpK8062.js +0 -2
- package/dist/lido-player/p-v3GBrpv9.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as getAssetPath } from './index-
|
|
1
|
+
import { c as getAssetPath } from './index-Dvjbti-h.js';
|
|
2
2
|
|
|
3
3
|
const DragMapKey = 'lidoDragMap';
|
|
4
4
|
const SelectedValuesKey = 'lidoSelectedValues';
|
|
@@ -19,6 +19,12 @@ const DropTimeAttr = 'drop-time';
|
|
|
19
19
|
const LidoContainer = 'lido-container';
|
|
20
20
|
const LIDO_COMMON_AUDIO_PATH = '__LIDO_COMMON_AUDIO_PATH__';
|
|
21
21
|
const LIDO_COMMON_AUDIO_READY_EVENT = 'lidoCommonAudioPathReady';
|
|
22
|
+
const GOOD_JOB_AUDIO_FILE = 'goodJob.mp3';
|
|
23
|
+
const resolveCommonAudioPath = (basePath, fileName) => {
|
|
24
|
+
if (!basePath || !fileName)
|
|
25
|
+
return undefined;
|
|
26
|
+
return `${basePath}/${fileName}`;
|
|
27
|
+
};
|
|
22
28
|
const LIDO_INTERACTION_CLEANUP_EVENT = 'lido:interaction-cleanup';
|
|
23
29
|
const TemplateID = 'template-id';
|
|
24
30
|
const CalculatorOk = 'calculator-ok';
|
|
@@ -1349,14 +1355,14 @@ async function onClickDropOrDragElement(element, type) {
|
|
|
1349
1355
|
if (!document.querySelector('#dynamic-highlight-style')) {
|
|
1350
1356
|
const style = document.createElement('style');
|
|
1351
1357
|
style.id = 'dynamic-highlight-style';
|
|
1352
|
-
style.innerHTML = `
|
|
1353
|
-
.highlight {
|
|
1354
|
-
// border: 4px solid #e74c3c; /* Thicker red border for more visibility */
|
|
1355
|
-
// border-radius: 12px; /* Larger rounded corners */
|
|
1356
|
-
// background-color: rgba(231, 76, 60, 0.3); /* Stronger, more noticeable background */
|
|
1357
|
-
// box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 12px 40px rgba(0, 0, 0, 0.2); /* Stronger shadow */
|
|
1358
|
-
// outline: 4px solid rgba(231, 76, 60, 0.6); /* Glow effect */
|
|
1359
|
-
}
|
|
1358
|
+
style.innerHTML = `
|
|
1359
|
+
.highlight {
|
|
1360
|
+
// border: 4px solid #e74c3c; /* Thicker red border for more visibility */
|
|
1361
|
+
// border-radius: 12px; /* Larger rounded corners */
|
|
1362
|
+
// background-color: rgba(231, 76, 60, 0.3); /* Stronger, more noticeable background */
|
|
1363
|
+
// box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2), 0 12px 40px rgba(0, 0, 0, 0.2); /* Stronger shadow */
|
|
1364
|
+
// outline: 4px solid rgba(231, 76, 60, 0.6); /* Glow effect */
|
|
1365
|
+
}
|
|
1360
1366
|
`;
|
|
1361
1367
|
document.head.appendChild(style);
|
|
1362
1368
|
}
|
|
@@ -1544,34 +1550,34 @@ function highlightSpeakingElement(element) {
|
|
|
1544
1550
|
if (!document.getElementById(styleId)) {
|
|
1545
1551
|
const style = document.createElement('style');
|
|
1546
1552
|
style.id = styleId;
|
|
1547
|
-
style.innerHTML = `
|
|
1548
|
-
.speaking-highlight {
|
|
1549
|
-
--base-transform: ${element.style.transform};
|
|
1550
|
-
box-shadow: 0 0 20px 10px rgba(255, 165, 0, 0.9) !important; /* Stronger orange glow effect */
|
|
1551
|
-
// border: 3px solid green !important;
|
|
1552
|
-
// transition: box-shadow 0.5s ease-in-out, transform 0.5s ease-in-out;
|
|
1553
|
-
// transform: scale(1.05); /* Subtle scale effect to pop the element */
|
|
1554
|
-
// animation: pulseEffect 1.5s infinite; /* Pulsing animation */
|
|
1555
|
-
|
|
1556
|
-
}
|
|
1557
|
-
|
|
1558
|
-
@keyframes pulseEffect {
|
|
1559
|
-
0% {
|
|
1560
|
-
box-shadow: 0 0 20px 10px rgba(255, 165, 0, 0.9);
|
|
1561
|
-
// transform: var(--base-transform) scale(1.05);
|
|
1562
|
-
// background-color: #FFFF0B;
|
|
1563
|
-
}
|
|
1564
|
-
50% {
|
|
1565
|
-
box-shadow: 0 0 30px 15px rgba(255, 165, 0, 1);
|
|
1566
|
-
// transform: var(--base-transform) scale(1.1);
|
|
1567
|
-
// background-color: #FFFF0B;
|
|
1568
|
-
}
|
|
1569
|
-
100% {
|
|
1570
|
-
box-shadow: 0 0 20px 10px rgba(255, 165, 0, 0.9);
|
|
1571
|
-
// transform: var(--base-transform) scale(1.05);
|
|
1572
|
-
// background-color: #FFFF0B;
|
|
1573
|
-
}
|
|
1574
|
-
}
|
|
1553
|
+
style.innerHTML = `
|
|
1554
|
+
.speaking-highlight {
|
|
1555
|
+
--base-transform: ${element.style.transform};
|
|
1556
|
+
box-shadow: 0 0 20px 10px rgba(255, 165, 0, 0.9) !important; /* Stronger orange glow effect */
|
|
1557
|
+
// border: 3px solid green !important;
|
|
1558
|
+
// transition: box-shadow 0.5s ease-in-out, transform 0.5s ease-in-out;
|
|
1559
|
+
// transform: scale(1.05); /* Subtle scale effect to pop the element */
|
|
1560
|
+
// animation: pulseEffect 1.5s infinite; /* Pulsing animation */
|
|
1561
|
+
|
|
1562
|
+
}
|
|
1563
|
+
|
|
1564
|
+
@keyframes pulseEffect {
|
|
1565
|
+
0% {
|
|
1566
|
+
box-shadow: 0 0 20px 10px rgba(255, 165, 0, 0.9);
|
|
1567
|
+
// transform: var(--base-transform) scale(1.05);
|
|
1568
|
+
// background-color: #FFFF0B;
|
|
1569
|
+
}
|
|
1570
|
+
50% {
|
|
1571
|
+
box-shadow: 0 0 30px 15px rgba(255, 165, 0, 1);
|
|
1572
|
+
// transform: var(--base-transform) scale(1.1);
|
|
1573
|
+
// background-color: #FFFF0B;
|
|
1574
|
+
}
|
|
1575
|
+
100% {
|
|
1576
|
+
box-shadow: 0 0 20px 10px rgba(255, 165, 0, 0.9);
|
|
1577
|
+
// transform: var(--base-transform) scale(1.05);
|
|
1578
|
+
// background-color: #FFFF0B;
|
|
1579
|
+
}
|
|
1580
|
+
}
|
|
1575
1581
|
`;
|
|
1576
1582
|
document.head.appendChild(style);
|
|
1577
1583
|
}
|
|
@@ -1747,7 +1753,7 @@ class AudioPlayer {
|
|
|
1747
1753
|
return el;
|
|
1748
1754
|
return el.closest('lido-text');
|
|
1749
1755
|
}
|
|
1750
|
-
async play(targetElement, suppressHighlight = false, playbackContext) {
|
|
1756
|
+
async play(targetElement, suppressHighlight = false, playbackContext, fallbackAudio) {
|
|
1751
1757
|
this.registerVisibilityEvents();
|
|
1752
1758
|
this.playbackHasStarted = false;
|
|
1753
1759
|
if (!this.isWindowVisible()) {
|
|
@@ -1850,7 +1856,12 @@ class AudioPlayer {
|
|
|
1850
1856
|
};
|
|
1851
1857
|
});
|
|
1852
1858
|
}
|
|
1853
|
-
catch (error) {
|
|
1859
|
+
catch (error) {
|
|
1860
|
+
if (fallbackAudio && fallbackAudio !== audioUrl) {
|
|
1861
|
+
targetElement.setAttribute('audio', fallbackAudio);
|
|
1862
|
+
await this.play(targetElement, suppressHighlight, playbackContext);
|
|
1863
|
+
}
|
|
1864
|
+
}
|
|
1854
1865
|
finally {
|
|
1855
1866
|
this.audioElement.onended = null;
|
|
1856
1867
|
this.audioElement.onloadedmetadata = null;
|
|
@@ -2064,7 +2075,9 @@ class AudioPlayer {
|
|
|
2064
2075
|
const duration = timeline[timeline.length - 1].endMs - timeline[0].startMs;
|
|
2065
2076
|
const averageWordMs = duration / timeline.length;
|
|
2066
2077
|
const speedLead = averageWordMs < 190 ? 120 : averageWordMs < 260 ? 90 : 60;
|
|
2067
|
-
|
|
2078
|
+
// Advance the estimated highlight slightly to compensate for perceived lag.
|
|
2079
|
+
const playbackLeadAdjustmentMs = 40;
|
|
2080
|
+
return Math.max(profile.preemptiveOffsetMs, speedLead) + playbackLeadAdjustmentMs;
|
|
2068
2081
|
}
|
|
2069
2082
|
getTimelineIndex(timeline, currentMs) {
|
|
2070
2083
|
if (!timeline.length)
|
|
@@ -2280,11 +2293,11 @@ function enableReorderDrag(element) {
|
|
|
2280
2293
|
onDropToCategory(element, category);
|
|
2281
2294
|
}
|
|
2282
2295
|
if (divEl) {
|
|
2283
|
-
const keyframes = `
|
|
2284
|
-
@keyframes widthDecrease {
|
|
2285
|
-
0% { width: ${divEl.offsetWidth}px; height: ${divEl.offsetHeight}px; }
|
|
2286
|
-
100% { width: 0px; height: 0px;}
|
|
2287
|
-
}
|
|
2296
|
+
const keyframes = `
|
|
2297
|
+
@keyframes widthDecrease {
|
|
2298
|
+
0% { width: ${divEl.offsetWidth}px; height: ${divEl.offsetHeight}px; }
|
|
2299
|
+
100% { width: 0px; height: 0px;}
|
|
2300
|
+
}
|
|
2288
2301
|
`;
|
|
2289
2302
|
const styleSheet = document.styleSheets[0];
|
|
2290
2303
|
styleSheet.insertRule(keyframes, styleSheet.cssRules.length);
|
|
@@ -2507,11 +2520,11 @@ function moveWithAnimation(target, overlapped) {
|
|
|
2507
2520
|
const dummy = createDummyElement(target);
|
|
2508
2521
|
dummy.style.visibility = 'hidden';
|
|
2509
2522
|
dummy.setAttribute('type', 'dummy');
|
|
2510
|
-
const keyframes = `
|
|
2511
|
-
@keyframes widthIncrease {
|
|
2512
|
-
0% { width: 0px; height: 0px; }
|
|
2513
|
-
100% { width: ${target.offsetWidth}px; height: ${target.offsetHeight}px;}
|
|
2514
|
-
}
|
|
2523
|
+
const keyframes = `
|
|
2524
|
+
@keyframes widthIncrease {
|
|
2525
|
+
0% { width: 0px; height: 0px; }
|
|
2526
|
+
100% { width: ${target.offsetWidth}px; height: ${target.offsetHeight}px;}
|
|
2527
|
+
}
|
|
2515
2528
|
`;
|
|
2516
2529
|
if (!overlapped) {
|
|
2517
2530
|
const overlapCategory = findMostoverlappedElement(target, 'category');
|
|
@@ -2737,6 +2750,7 @@ function slidingWithScaling(element) {
|
|
|
2737
2750
|
};
|
|
2738
2751
|
// Start observing the element
|
|
2739
2752
|
observer.observe(parentElement, observerConfig);
|
|
2753
|
+
let mostOverlappedElement;
|
|
2740
2754
|
const onMove = (event) => {
|
|
2741
2755
|
if (!isDragging)
|
|
2742
2756
|
return;
|
|
@@ -2757,12 +2771,14 @@ function slidingWithScaling(element) {
|
|
|
2757
2771
|
// Get the dimensions and scale-corrected position of the container and element
|
|
2758
2772
|
const containerRect = parentElement.getBoundingClientRect();
|
|
2759
2773
|
const elementRect = element.getBoundingClientRect();
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
const
|
|
2763
|
-
const
|
|
2764
|
-
const
|
|
2765
|
-
const
|
|
2774
|
+
// Firefox serializes translate(x, 0) as translate(x), so parsing the
|
|
2775
|
+
// inline string can lose Y and produce NaN. Read the computed matrix instead.
|
|
2776
|
+
const transform = window.getComputedStyle(element).transform;
|
|
2777
|
+
const translation = new DOMMatrixReadOnly(transform === 'none' ? undefined : transform);
|
|
2778
|
+
const initialElementLeftPx = elementRect.left / parentElementScale - translation.m41;
|
|
2779
|
+
const initialElementTopPx = elementRect.top - translation.m42;
|
|
2780
|
+
const initialElementRightPx = elementRect.right / parentElementScale - translation.m41;
|
|
2781
|
+
const initialElementBottomPx = elementRect.bottom - translation.m42;
|
|
2766
2782
|
const maxRight = containerRect.right - initialElementRightPx;
|
|
2767
2783
|
const maxLeft = containerRect.left - initialElementLeftPx;
|
|
2768
2784
|
const maxTop = containerRect.top - initialElementTopPx;
|
|
@@ -2772,7 +2788,7 @@ function slidingWithScaling(element) {
|
|
|
2772
2788
|
// Apply transform with translation within boundaries
|
|
2773
2789
|
element.style.transform = `translate(${newLeftClamp}px, ${newTopClamp}px)`;
|
|
2774
2790
|
// Check for overlaps and highlight only the most overlapping element
|
|
2775
|
-
|
|
2791
|
+
mostOverlappedElement = findMostoverlappedElement$1(element, 'slide');
|
|
2776
2792
|
// Apply styles only to the most overlapped element
|
|
2777
2793
|
if (mostOverlappedElement) {
|
|
2778
2794
|
if (mostOverlappedElement != element) {
|
|
@@ -2833,6 +2849,7 @@ function slidingWithScaling(element) {
|
|
|
2833
2849
|
setTimeout(() => {
|
|
2834
2850
|
if (overlapElement) {
|
|
2835
2851
|
void slideCompleted(element);
|
|
2852
|
+
updateReorderCorrectness(container, element, mostOverlappedElement);
|
|
2836
2853
|
overlapElement = false;
|
|
2837
2854
|
}
|
|
2838
2855
|
}, 300);
|
|
@@ -2875,18 +2892,50 @@ const isArrangeLettersComplete = (slideValues, objectiveString) => {
|
|
|
2875
2892
|
return slideValues.length === objectiveValues.length
|
|
2876
2893
|
&& slideValues.every((value, index) => value === objectiveValues[index]);
|
|
2877
2894
|
};
|
|
2878
|
-
const updateReorderCorrectness = (container,
|
|
2879
|
-
const
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
|
|
2886
|
-
|
|
2887
|
-
|
|
2888
|
-
|
|
2895
|
+
const updateReorderCorrectness = (container, slideElement, overlappedElement) => {
|
|
2896
|
+
const allSlideElements = Array.from(container.querySelectorAll('[type="slide"]'));
|
|
2897
|
+
const elementIndex = allSlideElements.indexOf(slideElement);
|
|
2898
|
+
const overlappedElementIndex = allSlideElements.indexOf(overlappedElement);
|
|
2899
|
+
const objectiveString = document.getElementById(LidoContainer)['objective'];
|
|
2900
|
+
const objectiveArray = objectiveString.split(',');
|
|
2901
|
+
const slideValues = getSlideValuesForValidation(container, allSlideElements);
|
|
2902
|
+
const isCorrect = elementIndex >= 0 && elementIndex < objectiveArray.length
|
|
2903
|
+
? matchStringPattern(slideValues[elementIndex], [objectiveArray[elementIndex].trim()])
|
|
2904
|
+
: false;
|
|
2905
|
+
const isCorrectOverlap = overlappedElementIndex >= 0 && overlappedElementIndex < objectiveArray.length
|
|
2906
|
+
? matchStringPattern(slideValues[overlappedElementIndex], [objectiveArray[overlappedElementIndex].trim()])
|
|
2907
|
+
: false;
|
|
2908
|
+
if (isCorrect && isCorrectOverlap) {
|
|
2909
|
+
updateElementCategoryClass(slideElement, true);
|
|
2910
|
+
updateElementCategoryClass(overlappedElement, true);
|
|
2911
|
+
}
|
|
2912
|
+
else if (isCorrect) {
|
|
2913
|
+
updateElementCategoryClass(slideElement, true);
|
|
2914
|
+
updateElementCategoryClass(overlappedElement, false);
|
|
2915
|
+
}
|
|
2916
|
+
else if (isCorrectOverlap) {
|
|
2917
|
+
updateElementCategoryClass(slideElement, false);
|
|
2918
|
+
updateElementCategoryClass(overlappedElement, true);
|
|
2919
|
+
}
|
|
2920
|
+
else {
|
|
2921
|
+
updateElementCategoryClass(slideElement, false);
|
|
2922
|
+
updateElementCategoryClass(overlappedElement, false);
|
|
2923
|
+
}
|
|
2889
2924
|
};
|
|
2925
|
+
function updateElementCategoryClass(element, isCorrect) {
|
|
2926
|
+
if (!element)
|
|
2927
|
+
return;
|
|
2928
|
+
const correctClass = 'category-dropped-onCorrect';
|
|
2929
|
+
const incorrectClass = 'category-dropped-onInCorrect';
|
|
2930
|
+
if (isCorrect) {
|
|
2931
|
+
element.classList.add(correctClass);
|
|
2932
|
+
element.classList.remove(incorrectClass);
|
|
2933
|
+
}
|
|
2934
|
+
else {
|
|
2935
|
+
element.classList.add(incorrectClass);
|
|
2936
|
+
element.classList.remove(correctClass);
|
|
2937
|
+
}
|
|
2938
|
+
}
|
|
2890
2939
|
const isReorderComplete = (slideValues, objectiveString) => {
|
|
2891
2940
|
if (!objectiveString)
|
|
2892
2941
|
return false;
|
|
@@ -2914,7 +2963,10 @@ const slideCompleted = async (slideElement) => {
|
|
|
2914
2963
|
updateArrangeLettersCorrectness(container, slideValues, objectiveArray);
|
|
2915
2964
|
}
|
|
2916
2965
|
else if (isReorderContainer(container)) {
|
|
2917
|
-
|
|
2966
|
+
if (isReorderComplete(slideValues, objectiveString)) {
|
|
2967
|
+
allSlideElements.forEach(item => updateElementCategoryClass(item, true));
|
|
2968
|
+
}
|
|
2969
|
+
// updateReorderCorrectness(container, slideValues, objectiveArray);
|
|
2918
2970
|
}
|
|
2919
2971
|
if (container.getAttribute('is-continue-on-correct') === 'true') {
|
|
2920
2972
|
storingEachActivityScore(true);
|
|
@@ -32020,15 +32072,15 @@ function _typeof(o) {
|
|
|
32020
32072
|
}, _typeof(o);
|
|
32021
32073
|
}
|
|
32022
32074
|
|
|
32023
|
-
function toPrimitive(t,
|
|
32075
|
+
function toPrimitive(t, r) {
|
|
32024
32076
|
if ("object" != _typeof(t) || !t) return t;
|
|
32025
|
-
var
|
|
32026
|
-
if (
|
|
32027
|
-
var i =
|
|
32077
|
+
var e = t[Symbol.toPrimitive];
|
|
32078
|
+
if (void 0 !== e) {
|
|
32079
|
+
var i = e.call(t, r);
|
|
32028
32080
|
if ("object" != _typeof(i)) return i;
|
|
32029
32081
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
32030
32082
|
}
|
|
32031
|
-
return ("string" ===
|
|
32083
|
+
return ("string" === r ? String : Number)(t);
|
|
32032
32084
|
}
|
|
32033
32085
|
|
|
32034
32086
|
function toPropertyKey(t) {
|
|
@@ -72839,6 +72891,44 @@ class Timer {
|
|
|
72839
72891
|
let ACTIVYTY_TIME_SPEND_ARRAY = [];
|
|
72840
72892
|
|
|
72841
72893
|
const gameScore = new GameScore();
|
|
72894
|
+
const GOOD_JOB_TEMPLATES = new Set(['flashcardtemplate', 'writeCard', 'drawShape', 'storyTale']);
|
|
72895
|
+
const isGoodJobAudioTarget = (element) => {
|
|
72896
|
+
var _a;
|
|
72897
|
+
const templateId = (_a = element === null || element === void 0 ? void 0 : element.closest('lido-container')) === null || _a === void 0 ? void 0 : _a.getAttribute('template-id');
|
|
72898
|
+
if (!GOOD_JOB_TEMPLATES.has(templateId || ''))
|
|
72899
|
+
return false;
|
|
72900
|
+
if ((element === null || element === void 0 ? void 0 : element.id) === 'arrow')
|
|
72901
|
+
return true;
|
|
72902
|
+
return templateId === 'storyTale' && (element === null || element === void 0 ? void 0 : element.id) === 'arrow1' && !!element.closest('#arrow');
|
|
72903
|
+
};
|
|
72904
|
+
const resetGoodJobAudioTracking = (home) => {
|
|
72905
|
+
home.__lidoGoodJobTemplates = new Set();
|
|
72906
|
+
};
|
|
72907
|
+
const shouldPlayGoodJobAudio = (element) => {
|
|
72908
|
+
var _a;
|
|
72909
|
+
if (!isGoodJobAudioTarget(element))
|
|
72910
|
+
return false;
|
|
72911
|
+
// Standalone templates and editor previews have no lesson host. Preserve
|
|
72912
|
+
// their existing behavior rather than making them depend on lido-home.
|
|
72913
|
+
const home = element.closest('lido-home');
|
|
72914
|
+
if (!home)
|
|
72915
|
+
return true;
|
|
72916
|
+
const templateId = (_a = element.closest('lido-container')) === null || _a === void 0 ? void 0 : _a.getAttribute('template-id');
|
|
72917
|
+
if (!templateId)
|
|
72918
|
+
return true;
|
|
72919
|
+
const played = home.__lidoGoodJobTemplates || (home.__lidoGoodJobTemplates = new Set());
|
|
72920
|
+
if (played.has(templateId))
|
|
72921
|
+
return false;
|
|
72922
|
+
played.add(templateId);
|
|
72923
|
+
return true;
|
|
72924
|
+
};
|
|
72925
|
+
const getGoodJobAudio = (element) => {
|
|
72926
|
+
if (!element)
|
|
72927
|
+
return undefined;
|
|
72928
|
+
if (!isGoodJobAudioTarget(element))
|
|
72929
|
+
return undefined;
|
|
72930
|
+
return resolveCommonAudioPath(window[LIDO_COMMON_AUDIO_PATH], GOOD_JOB_AUDIO_FILE);
|
|
72931
|
+
};
|
|
72842
72932
|
function buildDragSelectedMapFromDOM() {
|
|
72843
72933
|
const map = {};
|
|
72844
72934
|
const draggedEls = document.querySelectorAll(`[${DropToAttr}]`);
|
|
@@ -72971,6 +73061,22 @@ const initEventsForElement = async (element, type) => {
|
|
|
72971
73061
|
}
|
|
72972
73062
|
onTouchListenerForOnTouch(element);
|
|
72973
73063
|
};
|
|
73064
|
+
/**
|
|
73065
|
+
* Re-enable the gameplay handlers for interactive children that were created
|
|
73066
|
+
* while the player was in edit mode. This is intentionally limited to the
|
|
73067
|
+
* drag/drop elements used by Food Jar; other templates retain their existing
|
|
73068
|
+
* component-load initialization path.
|
|
73069
|
+
*/
|
|
73070
|
+
const initializePlayModeDragDropElements = async (root) => {
|
|
73071
|
+
const elements = root.querySelectorAll('[type="drag"], [type="drop"]');
|
|
73072
|
+
for (const element of Array.from(elements)) {
|
|
73073
|
+
const type = element.getAttribute('type') || undefined;
|
|
73074
|
+
const initializedElement = element;
|
|
73075
|
+
if (initializedElement.__lidoInitializationKey === `${type || ''}:true`)
|
|
73076
|
+
continue;
|
|
73077
|
+
await initEventsForElement(element, type);
|
|
73078
|
+
}
|
|
73079
|
+
};
|
|
72974
73080
|
// Function to execute actions parsed from the onMatch string
|
|
72975
73081
|
const executeActions = async (actionsString, thisElement, element, options = {}) => {
|
|
72976
73082
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
@@ -73044,7 +73150,21 @@ const executeActions = async (actionsString, thisElement, element, options = {})
|
|
|
73044
73150
|
const val = (action.value || '').toString().trim().toLowerCase();
|
|
73045
73151
|
if (val === 'true' || val === '1' || val === 'yes') {
|
|
73046
73152
|
try {
|
|
73047
|
-
|
|
73153
|
+
if (isGoodJobAudioTarget(targetElement) && !shouldPlayGoodJobAudio(targetElement))
|
|
73154
|
+
break;
|
|
73155
|
+
const isGoodJobTarget = isGoodJobAudioTarget(targetElement);
|
|
73156
|
+
const currentAudio = targetElement.getAttribute('audio') || undefined;
|
|
73157
|
+
const originalAudio = isGoodJobTarget
|
|
73158
|
+
? (targetElement.getAttribute('data-lido-original-audio') || currentAudio)
|
|
73159
|
+
: currentAudio;
|
|
73160
|
+
const localizedAudio = getGoodJobAudio(targetElement);
|
|
73161
|
+
if (localizedAudio) {
|
|
73162
|
+
if (currentAudio && !targetElement.hasAttribute('data-lido-original-audio')) {
|
|
73163
|
+
targetElement.setAttribute('data-lido-original-audio', currentAudio);
|
|
73164
|
+
}
|
|
73165
|
+
targetElement.setAttribute('audio', localizedAudio);
|
|
73166
|
+
}
|
|
73167
|
+
await AudioPlayer.getI().play(targetElement, false, undefined, originalAudio);
|
|
73048
73168
|
}
|
|
73049
73169
|
catch (err) {
|
|
73050
73170
|
console.error('Error playing audio for speak action:', err);
|
|
@@ -73254,12 +73374,25 @@ const afterDropDragHandling = (dragElement, dropElement) => {
|
|
|
73254
73374
|
const element = dragElement;
|
|
73255
73375
|
const isAppend = container.getAttribute('drop-action') === DropAction.Move;
|
|
73256
73376
|
const isInfinite = container.getAttribute('drop-action') === DropAction.InfiniteDrop;
|
|
73377
|
+
const isCreateSentence = container.getAttribute('template-id') === 'createSentence';
|
|
73378
|
+
// Reserve the source slot synchronously so an overlapping drag sees the
|
|
73379
|
+
// updated source layout before the dropped element is reparented.
|
|
73380
|
+
let sourcePlaceholder = null;
|
|
73381
|
+
if (isAppend && isCreateSentence) {
|
|
73382
|
+
const computedStyle = window.getComputedStyle(dragElement);
|
|
73383
|
+
sourcePlaceholder = document.createElement('div');
|
|
73384
|
+
sourcePlaceholder.style.width = `${dragElement.offsetWidth}px`;
|
|
73385
|
+
sourcePlaceholder.style.height = `${dragElement.offsetHeight}px`;
|
|
73386
|
+
sourcePlaceholder.style.margin = computedStyle.margin;
|
|
73387
|
+
sourcePlaceholder.style.visibility = 'hidden';
|
|
73388
|
+
dragElement.replaceWith(sourcePlaceholder);
|
|
73389
|
+
}
|
|
73257
73390
|
if (isAppend || isInfinite) {
|
|
73258
|
-
|
|
73391
|
+
const finishDrop = () => {
|
|
73259
73392
|
var _a, _b;
|
|
73260
73393
|
dragElement.style.transform = 'translate(0,0)';
|
|
73261
73394
|
dragElement.style.transition = '';
|
|
73262
|
-
let dummyElement = document.createElement('div');
|
|
73395
|
+
let dummyElement = sourcePlaceholder || document.createElement('div');
|
|
73263
73396
|
if (isInfinite) {
|
|
73264
73397
|
dummyElement = cloneElementWithComputedStyles(dragElement);
|
|
73265
73398
|
dummyElement.classList.remove('dropped');
|
|
@@ -73274,17 +73407,25 @@ const afterDropDragHandling = (dragElement, dropElement) => {
|
|
|
73274
73407
|
}, 100);
|
|
73275
73408
|
}
|
|
73276
73409
|
dummyElement.setAttribute('id', dragElement.getAttribute('id'));
|
|
73277
|
-
|
|
73278
|
-
|
|
73279
|
-
|
|
73280
|
-
|
|
73281
|
-
|
|
73282
|
-
|
|
73410
|
+
if (!sourcePlaceholder) {
|
|
73411
|
+
dragElement.replaceWith(dummyElement);
|
|
73412
|
+
}
|
|
73413
|
+
const keyframes = `
|
|
73414
|
+
@keyframes widthDecrease {
|
|
73415
|
+
0% { width: ${dragElement.style.width}; height: ${dragElement.style.height}; margin: ${dragElement.style.margin}; }
|
|
73416
|
+
100% { width: 0px; height: 0px; margin: 0px;}
|
|
73417
|
+
}
|
|
73283
73418
|
`;
|
|
73284
73419
|
if (!isInfinite) {
|
|
73285
|
-
dummyElement.style.width =
|
|
73286
|
-
|
|
73287
|
-
|
|
73420
|
+
dummyElement.style.width = sourcePlaceholder
|
|
73421
|
+
? sourcePlaceholder.style.width
|
|
73422
|
+
: element.style.width;
|
|
73423
|
+
dummyElement.style.height = sourcePlaceholder
|
|
73424
|
+
? sourcePlaceholder.style.height
|
|
73425
|
+
: element.style.height;
|
|
73426
|
+
dummyElement.style.margin = sourcePlaceholder
|
|
73427
|
+
? sourcePlaceholder.style.margin
|
|
73428
|
+
: element.style.margin;
|
|
73288
73429
|
const styleSheet = document.styleSheets[0];
|
|
73289
73430
|
styleSheet.insertRule(keyframes, styleSheet.cssRules.length);
|
|
73290
73431
|
dummyElement.style.animation = `widthDecrease 0.5s`;
|
|
@@ -73314,7 +73455,13 @@ const afterDropDragHandling = (dragElement, dropElement) => {
|
|
|
73314
73455
|
const scaledLeft = (dropCenterX - dragCenterX) / containerScale;
|
|
73315
73456
|
const scaledTop = (dropCenterY - dragCenterY) / containerScale;
|
|
73316
73457
|
dragElement.style.transform = `translate(${scaledLeft}px, ${scaledTop}px)`;
|
|
73317
|
-
}
|
|
73458
|
+
};
|
|
73459
|
+
if (isAppend && isCreateSentence) {
|
|
73460
|
+
finishDrop();
|
|
73461
|
+
}
|
|
73462
|
+
else {
|
|
73463
|
+
setTimeout(finishDrop, 700);
|
|
73464
|
+
}
|
|
73318
73465
|
}
|
|
73319
73466
|
};
|
|
73320
73467
|
// function cloneElementWithComputedStyles(originalEl: HTMLElement): HTMLElement {
|
|
@@ -74546,4 +74693,4 @@ const updateCalculatorAnswer = (el) => {
|
|
|
74546
74693
|
el.setAttribute('string', value);
|
|
74547
74694
|
};
|
|
74548
74695
|
|
|
74549
|
-
export {
|
|
74696
|
+
export { LIDO_COMMON_AUDIO_READY_EVENT as $, AudioPlayer as A, resetGoodJobAudioTracking as B, CalculatorOk as C, speakUrl as D, nextUrl as E, prevUrl as F, GameScore as G, exitUrl as H, LIDO_COMMON_AUDIO_PATH as I, LidoContainer as J, getCancelBtnPopup as K, LIDO_INTERACTION_CLEANUP_EVENT as L, matchStringPattern as M, NextContainerKey as N, triggerPrevcontainer as O, PrevContainerKey as P, setActiveZipAssets as Q, RiveService as R, SelectedValuesKey as S, TemplateID as T, clearActiveZipAssets as U, setCancelBtnPopup as V, tinycolor as W, stopHighlightForSpeakingElement as X, DropAction as Y, validateObjectiveStatus as Z, fraction as _, storingEachActivityScore as a, TraceMode as a0, speakIcon as a1, fingerUrl as a2, format as a3, executeActions as b, convertUrlToRelative as c, calculateScore as d, equationCheck as e, attachSpeakIcon as f, getDefaultExportFromCjs as g, handlingChildElements as h, initEventsForElement as i, initializePlayModeDragDropElements as j, calculateScale as k, highlightElement as l, Timer as m, getGoodJobAudio as n, shouldPlayGoodJobAudio as o, parseProp as p, handleFloatElementPosition as q, resetFloatState as r, setVisibilityWithDelay as s, triggerNextContainer as t, handleElementClick as u, commonjsGlobal as v, generateUUIDFallback as w, ActivityScoreKey as x, dispatchActivityChangeEvent as y, dispatchGameExitEvent as z };
|
|
@@ -2,7 +2,7 @@ const NAMESPACE = 'lido-player';
|
|
|
2
2
|
const BUILD = /* lido-player */ { hotModuleReplacement: false, hydratedSelectorName: "hydrated", lazyLoad: true, propChangeCallback: true, slotRelocation: true, state: true, updatable: true};
|
|
3
3
|
|
|
4
4
|
const globalScripts = () => {};
|
|
5
|
-
const globalStyles = "@font-face{font-family:'Baloo Bhai 2';font-style:normal;font-weight:400 800;font-display:swap;src:url('../assets/offline-assets/fonts/Baloo-Bhai-2/Baloo-Bhai-2-Variable.woff2') format('woff2')}body{overflow:hidden;background-position:center;background-size:cover;background-repeat:no-repeat;height:100vh}*{user-select:none}.lido-disable-check-button{pointer-events:none;background-color:#9393935c !important;color:white}.lido-element-selected{border:2px solid;background-color:#ffdf7d !important}.diagonal-target,.diagonal-drop *{transform:scale(0.8) !important;opacity:1 !important}.cloned-element{display:flex !important;position:absolute !important;filter:grayscale(100%);pointer-events:none}.removeShadow{box-shadow:0px 0px 0px 0px #ff8900 !important}.highlight-element{border:2px solid white;box-shadow:rgb(243, 77, 8) 0px 0px 40px !important}.drop-element.empty{border:4px dashed #f34d08 !important}.drop-element.filled{border:'none' !important}.drag-element{box-shadow:0px 15px 11px rgba(43, 0, 0, 0.3) !important}.drag-element.dropped{box-shadow:none !important}.click-element{background-color:var(--btn-bg-color, rgba(255, 172, 76, 1)) !important;box-shadow:var(--btn-shadow-px) var(--btn-shadow-color, rgba(225, 121, 76, 1)) !important;cursor:pointer;transition:box-shadow 0.1s ease-out, transform 0.2s ease-out;}.click-element:active{box-shadow:0px 0px 0px var(--btn-shadow-color, rgba(225, 121, 76, 1)) !important;transform:translateY(var(--btn-active));}.click-element:focus{outline:2px solid dodgerblue;outline-offset:3px}.after-drop-popup-container{width:200%;height:200%;background-color:rgba(0, 0, 0, 0.8);position:absolute;display:flex;flex-direction:row-reverse;align-items:center;justify-content:center !important;gap:80px}.after-drop-popup-drag-element{scale:1.5;border-radius:8px;transform:none !important;position:unset !important}.after-drop-popup-drop-element{scale:1.5;border:unset;border-radius:8px;transform:none !important;position:unset !important}@keyframes zoomFadeIn{0%{transform:scale(0.6);opacity:0}100%{transform:scale(1);opacity:1}}.zoom-fade-in{animation:zoomFadeIn 0.8s ease-out forwards}@keyframes zoomFadeOut{0%{transform:scale(1);opacity:1}100%{transform:scale(0.6);opacity:0}}.zoom-fade-out{animation:zoomFadeOut 0.8s ease-in forwards}.slide-numbers{width:70px;height:70px;border:1px solid #f57139;background-color:white;font-weight:500;color:#f57139;font-size:44px;border-radius:40px;display:flex;align-items:center;justify-content:center;font-family:'Baloo Bhai 2', serif}.slide-numbers-bottom{position:absolute;display:flex;justify-content:space-around;align-items:center;bottom:-25px;width:100%;height:50px}.slide-numbers-left{position:absolute;display:flex;flex-direction:column;justify-content:space-around;height:100%;width:50px;left:-25px;bottom:0px}.lido-speak-icon{width:56px;height:56px;position:absolute;top:-25px;right:-25px;z-index:10;background-color:white;border:4px solid #F34D08;border-radius:16px;box-shadow:0px 4px 0px 0px #F34D08;background-size:contain;background-repeat:no-repeat;cursor:pointer}.lido-speak-icon:active{transform:translateY(8px);box-shadow:0px 0px 0px 0px !important}.lido-strong-shake{animation:strongShake 0.3s ease}.lido-scaled-shake{animation:scaledShake 0.6s ease-in-out}.lido-horizontal-shake{animation:horizontalShake 0.6s ease-in-out;border-radius:20px}.lido-vertical-shake{animation:verticalShake 0.6s ease-in-out;border-radius:20px}.lido-diagonal-shake{animation:diagonalShake 0.5s ease-in-out;border-radius:20px;will-change:transform}.lido-glow{animation:glowPulse 1s infinite alternate;transition:opacity 0.5s ease-in-out}.lido-box-highlight{animation:topToPlace 0.3s linear}.lido-display-hiddenvalue{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:80px;font-weight:1000;color:brown;-webkit-text-stroke:2px white;font-family:'Baloo Bhai 2', sans-serif;pointer-events:none}.lido-image-colorize{position:relative;display:inline-block}.lido-image-colorize::after{content:'';position:absolute;inset:0;background:var(--tint-color);mix-blend-mode:multiply;opacity:0.8;pointer-events:none;mask-image:var(--mask-url);mask-size:cover;mask-repeat:no-repeat;mask-position:center}.lido-tts-highlight-overlay{position:fixed;left:0;top:0;pointer-events:none;z-index:9999;background:linear-gradient(\n 180deg,\n rgba(255, 235, 59, 0.95),\n rgba(255, 214, 0, 0.95)\n );border-radius:6px;box-shadow:0 2px 6px rgba(0, 0, 0, 0.18),\n inset 0 -1px 0 rgba(255, 255, 255, 0.25);transition:width 25ms ease-out,\n height 25ms ease-out,\n opacity 80ms ease-out;opacity:0.95;will-change:transform, width, height;contain:layout paint style}.category-dropped-onCorrect{box-shadow:rgba(129, 193, 39, 1) 0px 8px 8px 0px !important}.category-dropped-onInCorrect{box-shadow:rgba(255, 4, 16, 1) 0px 8px 8px 0px !important}";
|
|
5
|
+
const globalStyles = "@font-face{font-family:'Baloo Bhai 2';font-style:normal;font-weight:400 800;font-display:swap;src:url('../assets/offline-assets/fonts/Baloo-Bhai-2/Baloo-Bhai-2-Variable.woff2') format('woff2')}body{overflow:hidden;background-position:center;background-size:cover;background-repeat:no-repeat;height:100vh}*{user-select:none}.lido-disable-check-button{pointer-events:none;background-color:#9393935c !important;color:white}.lido-element-selected{border:2px solid;background-color:#ffdf7d !important}.diagonal-target,.diagonal-drop *{transform:scale(0.8) !important;opacity:1 !important}.cloned-element{display:flex !important;position:absolute !important;filter:grayscale(100%);pointer-events:none}.removeShadow{box-shadow:0px 0px 0px 0px #ff8900 !important}.highlight-element{border:2px solid white;box-shadow:rgb(243, 77, 8) 0px 0px 40px !important}.drop-element.empty{border:4px dashed #f34d08 !important}.drop-element.filled{border:'none' !important}.drag-element{box-shadow:0px 15px 11px rgba(43, 0, 0, 0.3) !important}.drag-element.dropped{box-shadow:none !important}.click-element{background-color:var(--btn-bg-color, rgba(255, 172, 76, 1)) !important;box-shadow:var(--btn-shadow-px) var(--btn-shadow-color, rgba(225, 121, 76, 1)) !important;cursor:pointer;transition:box-shadow 0.1s ease-out, transform 0.2s ease-out;}.click-element:active{box-shadow:0px 0px 0px var(--btn-shadow-color, rgba(225, 121, 76, 1)) !important;transform:translateY(var(--btn-active));}.click-element:focus{outline:2px solid dodgerblue;outline-offset:3px}.after-drop-popup-container{width:200%;height:200%;background-color:rgba(0, 0, 0, 0.8);position:absolute;display:flex;flex-direction:row-reverse;align-items:center;justify-content:center !important;gap:80px}.after-drop-popup-drag-element{scale:1.5;border-radius:8px;transform:none !important;position:unset !important}.after-drop-popup-drop-element{scale:1.5;border:unset;border-radius:8px;transform:none !important;position:unset !important}@keyframes zoomFadeIn{0%{transform:scale(0.6);opacity:0}100%{transform:scale(1);opacity:1}}.zoom-fade-in{animation:zoomFadeIn 0.8s ease-out forwards}@keyframes zoomFadeOut{0%{transform:scale(1);opacity:1}100%{transform:scale(0.6);opacity:0}}.zoom-fade-out{animation:zoomFadeOut 0.8s ease-in forwards}.slide-numbers{width:70px;height:70px;border:1px solid #f57139;background-color:white;font-weight:500;color:#f57139;font-size:44px;border-radius:40px;display:flex;align-items:center;justify-content:center;font-family:'Baloo Bhai 2', serif}.slide-numbers-bottom{position:absolute;display:flex;justify-content:space-around;align-items:center;bottom:-25px;width:100%;height:50px}.slide-numbers-left{position:absolute;display:flex;flex-direction:column;justify-content:space-around;height:100%;width:50px;left:-25px;bottom:0px}.lido-speak-icon{width:56px;height:56px;position:absolute;top:-25px;right:-25px;z-index:10;background-color:white;border:4px solid #F34D08;border-radius:16px;box-shadow:0px 4px 0px 0px #F34D08;background-size:contain;background-repeat:no-repeat;cursor:pointer}.lido-speak-icon:active{transform:translateY(8px);box-shadow:0px 0px 0px 0px !important}.lido-strong-shake{animation:strongShake 0.3s ease}.lido-scaled-shake{animation:scaledShake 0.6s ease-in-out}.lido-horizontal-shake{animation:horizontalShake 0.6s ease-in-out;border-radius:20px}.lido-vertical-shake{animation:verticalShake 0.6s ease-in-out;border-radius:20px}.lido-diagonal-shake{animation:diagonalShake 0.5s ease-in-out;border-radius:20px;will-change:transform}.lido-glow{animation:glowPulse 1s infinite alternate;transition:opacity 0.5s ease-in-out}.lido-box-highlight{animation:topToPlace 0.3s linear}.lido-display-hiddenvalue{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:80px;font-weight:1000;color:brown;-webkit-text-stroke:2px white;font-family:'Baloo Bhai 2', sans-serif;pointer-events:none}.lido-image-colorize{position:relative;display:inline-block}.lido-image-colorize::after{content:'';position:absolute;inset:0;background:var(--tint-color);mix-blend-mode:multiply;opacity:0.8;pointer-events:none;mask-image:var(--mask-url);mask-size:cover;mask-repeat:no-repeat;mask-position:center}.lido-tts-highlight-overlay{position:fixed;left:0;top:0;pointer-events:none;z-index:9999;background:linear-gradient(\r\n 180deg,\r\n rgba(255, 235, 59, 0.95),\r\n rgba(255, 214, 0, 0.95)\r\n );border-radius:6px;box-shadow:0 2px 6px rgba(0, 0, 0, 0.18),\r\n inset 0 -1px 0 rgba(255, 255, 255, 0.25);transition:width 25ms ease-out,\r\n height 25ms ease-out,\r\n opacity 80ms ease-out;opacity:0.95;will-change:transform, width, height;contain:layout paint style}.category-dropped-onCorrect{box-shadow:rgba(129, 193, 39, 1) 0px 8px 8px 0px !important}.category-dropped-onInCorrect{box-shadow:rgba(255, 4, 16, 1) 0px 8px 8px 0px !important}";
|
|
6
6
|
|
|
7
7
|
/*
|
|
8
8
|
Stencil Client Platform v4.43.5 | MIT Licensed | https://stenciljs.com
|
package/dist/esm/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export {
|
|
2
|
-
import './index-
|
|
1
|
+
export { a3 as format } from './index-Bc6Y7rds.js';
|
|
2
|
+
import './index-Dvjbti-h.js';
|