lido-player 0.0.2-alpha-58-dev → 0.0.2-alpha-60-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/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/lido-avatar_22.cjs.entry.js +96 -34
- package/dist/cjs/lido-player.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{utils-470fe410.js → utils-28faa755.js} +142 -108
- package/dist/collection/components/container/lido-container.js +62 -3
- package/dist/collection/components/flashCard/lido-flash-card.js +10 -1
- package/dist/collection/components/float/lido-float.js +1 -1
- package/dist/collection/components/home/lido-home.js +22 -12
- package/dist/collection/components/keyboard/lido-keyboard.js +2 -2
- package/dist/collection/components/mathMatrix/lido-math-matrix.js +1 -1
- package/dist/collection/components/position/lido-pos.js +1 -1
- package/dist/collection/components/random/lido-random.js +1 -1
- package/dist/collection/components/row/lido-row.js +1 -1
- package/dist/collection/components/scale/lido-balance.js +1 -1
- package/dist/collection/components/shape/lido-shape.js +2 -2
- package/dist/collection/components/slideFill/lido-slide-fill.js +1 -1
- package/dist/collection/components/text/lido-text.js +1 -1
- package/dist/collection/components/trace/lido-trace.js +18 -7
- package/dist/collection/components/wrap/lido-wrap.js +1 -1
- package/dist/collection/css/animation.css +17 -0
- package/dist/collection/css/index.css +1 -1
- package/dist/collection/stories/Templates/LetterPairing/LetterPairing.stories.js +3 -3
- package/dist/collection/stories/Templates/balancing/balancing.stories.js +1 -1
- package/dist/collection/stories/Templates/imageMatch/imageMatch.stories.js +79 -0
- package/dist/collection/stories/Templates/matchBox/matchBox2.stories.js +74 -44
- package/dist/collection/stories/Templates/matchingCard/matching-card.stories.js +4 -4
- package/dist/collection/stories/Templates/numberIdentification/numberIdentificationimageTotext.stories.js +91 -0
- package/dist/collection/stories/Templates/numberIdentification/numberIdentificationtextTotext.stories.js +84 -0
- package/dist/collection/stories/Templates/openwindow/openwindow.stories.js +0 -2
- package/dist/collection/stories/Templates/openwindow/openwindow2.stories.js +0 -2
- package/dist/collection/stories/Templates/palEgmaCalculateSum/palEgmaMultiOption.stories.js +106 -0
- package/dist/collection/stories/Templates/palEgmaCalculateSum/palEgmaSumTogether.stories.js +89 -0
- package/dist/collection/stories/Templates/palEgmaPatternMatching/palEgmaPatternMatching.stories.js +86 -0
- package/dist/collection/stories/Templates/palEgmaWordProblem/palEgmaWordProblem.stories.js +131 -0
- package/dist/collection/stories/Templates/palEgraInventedSpelling/pal_egra_invented_spelling_schema.stories.js +61 -0
- package/dist/collection/stories/Templates/palEgraMCQWithImage/palEgraMCQWithImage.stories.js +87 -0
- package/dist/collection/stories/Templates/palEgraOptionWithAudio/palEgraOptionWithAudio.stories.js +98 -0
- package/dist/collection/stories/Templates/palEgraStoryMaking/pal_egra_story_making.stories.js +72 -0
- package/dist/collection/stories/Templates/palEgraTemplate1/palEgraLetterIdentification.stories.js +61 -0
- package/dist/collection/stories/Templates/palEgra_OddOneOut/palEgra_oddOneOut.stories.js +60 -0
- package/dist/collection/stories/Templates/palEgra_arrange_pictures/palEgra_arrange_pictures.stories.js +78 -0
- package/dist/collection/stories/Templates/palEgra_build_word/palEgra_build_word.stories.js +78 -0
- package/dist/collection/stories/Templates/palEgra_word_formation/palEgra_WordFormation.stories.js +73 -0
- package/dist/collection/stories/Templates/palStorytale/palStorytale.stories.js +35 -0
- package/dist/collection/stories/Templates/pictureClues/pictureClues.stories.js +88 -0
- package/dist/collection/stories/Templates/pictureWordMatch/pictureWordMatch1.stories.js +88 -0
- package/dist/collection/stories/Templates/pictureWordMatch/pictureWordMatch2.stories.js +66 -0
- package/dist/collection/stories/Templates/picturemeaning/pictureMeaningCocos.stories.js +1 -1
- package/dist/collection/stories/Templates/quizMaths/quizMaths.stories.js +7 -7
- package/dist/collection/stories/Templates/rowBlocks/rowBlocks.stories.js +1 -1
- package/dist/collection/stories/Templates/sequenceBox/sequenceBox1.stories.js +2 -2
- package/dist/collection/stories/Templates/sequenceBox/sequenceBox2.stories.js +2 -2
- package/dist/collection/stories/Templates/substraction/substractionWithimg.stories.js +111 -0
- package/dist/collection/stories/Templates/substraction/substractionWithoutImg.stories.js +70 -0
- package/dist/collection/stories/Templates/total/total.stories.js +2 -0
- package/dist/collection/stories/Templates/wordBuilding/wordBuildingwithimg.stories.js +76 -0
- package/dist/collection/stories/Templates/wordBuilding/wordBuildingwithoutimg.stories.js +74 -0
- package/dist/collection/stories/Templates/writeSet/writeSet.stories.js +1 -1
- package/dist/collection/utils/constants.js +2 -1
- package/dist/collection/utils/utils.js +10 -4
- package/dist/collection/utils/utilsHandlers/clickHandler.js +2 -0
- package/dist/collection/utils/utilsHandlers/dragDropHandler.js +25 -21
- package/dist/collection/utils/utilsHandlers/highlightHandler.js +50 -2
- package/dist/collection/utils/utilsHandlers/lidoBalanceHandler.js +5 -4
- 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 +22 -23
- 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-ee4759de.js → p-06cecca5.js} +2 -2
- package/dist/components/{p-17cdbc3d.js → p-16604098.js} +1 -1
- package/dist/components/{p-6953efe0.js → p-235091a1.js} +141 -109
- package/dist/components/{p-bc7835fc.js → p-32c89979.js} +18 -7
- package/dist/components/{p-822b692a.js → p-354f7b19.js} +2 -2
- package/dist/components/{p-73e3f0f4.js → p-37c86a94.js} +203 -1
- package/dist/components/{p-53a7d4cb.js → p-3acada8c.js} +1 -1
- package/dist/components/{p-984ef5d1.js → p-3acd9a2e.js} +2 -2
- package/dist/components/{p-6f451328.js → p-4d01394c.js} +1 -1
- package/dist/components/{p-c62da3ed.js → p-57400ebc.js} +1 -1
- package/dist/components/{p-cfde157c.js → p-5e7c6afa.js} +2 -2
- package/dist/components/{p-f36d02e9.js → p-74c270d2.js} +4 -4
- package/dist/components/{p-9eb8593c.js → p-8a32f7cb.js} +3 -3
- package/dist/components/{p-0fa0ada9.js → p-8c0667eb.js} +2 -2
- package/dist/components/{p-9c7f08c4.js → p-8f082c62.js} +11 -2
- package/dist/components/{p-8c526c86.js → p-93acfbb2.js} +2 -2
- package/dist/components/{p-97ddbda4.js → p-a182c9a2.js} +2 -2
- package/dist/components/{p-348f95ba.js → p-b151457d.js} +47 -6
- package/dist/components/{p-d0c4d5a7.js → p-b867548e.js} +2 -2
- package/dist/components/{p-6f91a337.js → p-c90d92db.js} +2 -2
- package/dist/components/{p-67d97edc.js → p-db2a05f5.js} +3 -3
- package/dist/components/{p-f729ff82.js → p-de45dcab.js} +41 -33
- package/dist/esm/index.js +1 -1
- package/dist/esm/lido-avatar_22.entry.js +96 -34
- package/dist/esm/lido-player.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{utils-d0f004f8.js → utils-2edeb213.js} +141 -109
- package/dist/lido-player/index.esm.js +1 -1
- package/dist/lido-player/lido-player.css +1 -1
- package/dist/lido-player/lido-player.esm.js +1 -1
- package/dist/lido-player/p-280e3d34.entry.js +1 -0
- package/dist/lido-player/{p-bde62361.js → p-add7f36e.js} +2 -2
- package/dist/types/components/container/lido-container.d.ts +15 -2
- package/dist/types/components/trace/lido-trace.d.ts +3 -3
- package/dist/types/components.d.ts +10 -2
- package/dist/types/stories/Templates/imageMatch/imageMatch.stories.d.ts +4 -0
- package/dist/types/stories/Templates/numberIdentification/numberIdentificationimageTotext.stories.d.ts +4 -0
- package/dist/types/stories/Templates/numberIdentification/numberIdentificationtextTotext.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgmaCalculateSum/palEgmaMultiOption.stories.d.ts +11 -0
- package/dist/types/stories/Templates/palEgmaCalculateSum/palEgmaSumTogether.stories.d.ts +12 -0
- package/dist/types/stories/Templates/palEgmaPatternMatching/palEgmaPatternMatching.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgmaWordProblem/palEgmaWordProblem.stories.d.ts +5 -0
- package/dist/types/stories/Templates/palEgraInventedSpelling/pal_egra_invented_spelling_schema.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgraMCQWithImage/palEgraMCQWithImage.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgraOptionWithAudio/palEgraOptionWithAudio.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgraStoryMaking/pal_egra_story_making.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgraTemplate1/palEgraLetterIdentification.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgra_OddOneOut/palEgra_oddOneOut.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgra_arrange_pictures/palEgra_arrange_pictures.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgra_build_word/palEgra_build_word.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palEgra_word_formation/palEgra_WordFormation.stories.d.ts +4 -0
- package/dist/types/stories/Templates/palStorytale/palStorytale.stories.d.ts +4 -0
- package/dist/types/stories/Templates/pictureClues/pictureClues.stories.d.ts +4 -0
- package/dist/types/stories/Templates/pictureWordMatch/pictureWordMatch1.stories.d.ts +4 -0
- package/dist/types/stories/Templates/pictureWordMatch/pictureWordMatch2.stories.d.ts +4 -0
- package/dist/types/stories/Templates/substraction/substractionWithimg.stories.d.ts +4 -0
- package/dist/types/stories/Templates/substraction/substractionWithoutImg.stories.d.ts +4 -0
- package/dist/types/stories/Templates/wordBuilding/wordBuildingwithimg.stories.d.ts +4 -0
- package/dist/types/stories/Templates/wordBuilding/wordBuildingwithoutimg.stories.d.ts +4 -0
- package/dist/types/utils/constants.d.ts +9 -1
- package/dist/types/utils/utils.d.ts +1 -0
- package/dist/types/utils/utilsHandlers/highlightHandler.d.ts +1 -0
- package/package.json +1 -1
- package/dist/components/p-0e645e5b.js +0 -204
- package/dist/lido-player/p-06248bc2.entry.js +0 -1
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { html } from "lit-html";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/StoryMaking',
|
|
4
|
+
argTypes: {
|
|
5
|
+
PracticeMode: { control: 'boolean' },
|
|
6
|
+
value1: { control: 'text' },
|
|
7
|
+
value2: { control: 'text' },
|
|
8
|
+
value3: { control: 'text' },
|
|
9
|
+
value4: { control: 'text' },
|
|
10
|
+
},
|
|
11
|
+
};
|
|
12
|
+
export default meta;
|
|
13
|
+
export const Default = {
|
|
14
|
+
args: {
|
|
15
|
+
PracticeMode: false,
|
|
16
|
+
value1: 'A',
|
|
17
|
+
value2: 'D',
|
|
18
|
+
value3: 'E',
|
|
19
|
+
value4: 'B',
|
|
20
|
+
},
|
|
21
|
+
render: args => {
|
|
22
|
+
const xml = getContainerXml(args);
|
|
23
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
24
|
+
},
|
|
25
|
+
};
|
|
26
|
+
function getContainerXml(args) {
|
|
27
|
+
return `<main>
|
|
28
|
+
<lido-container is-continue-on-correct="true" template-id="dragAndDrop" is-allow-only-correct="true" objective="${args.value1},${args.value2},${args.value3},${args.value4}" onCorrect="lido-avatar.avatarAnimate='Success'; this.sleep='2000';" onInCorrect="lido-avatar.avatarAnimate='Fail'; this.sleep='2000';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/palStory/bgImage.png">
|
|
29
|
+
|
|
30
|
+
<!-- Chimple Avatar -->
|
|
31
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.300px,portrait.402px" width="landscape.250px,portrait.398px" x="landscape.68%, portrait.28%" y="landscape.600px, portrait.77%" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
32
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv">
|
|
33
|
+
</lido-avatar>
|
|
34
|
+
<lido-image id="image" disableEdit="true" value="image" visible="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/Shadow.png" bgColor="transparent" width="150px" height="27px" x="45px" y="235px">
|
|
35
|
+
</lido-image>
|
|
36
|
+
</lido-cell>
|
|
37
|
+
|
|
38
|
+
<lido-cell visible="true" layout="row" width="97%" height="87%" bg-color="transparent" margin="70px 0 0 0">
|
|
39
|
+
<!-- Drop Elements -->
|
|
40
|
+
<lido-cell visible="true" layout="col" width="53%" height="100%" padding="0" bg-color="transparent">
|
|
41
|
+
<lido-cell visible="true" layout="row" width="100%" height="22%" bg-color="transparent">
|
|
42
|
+
<lido-image visible="true" width="160px" height="160px" bg-color="white" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picture_Clues/f1.png"></lido-image>
|
|
43
|
+
<lido-text visible="true" value="${args.value1}" id="drop1" tab-index="1" type="drop" width="630px" height="100px" bg-color="white" border-radius="16px" onCorrect="lido-avatar.avatarAnimate='Success';"></lido-text>
|
|
44
|
+
</lido-cell>
|
|
45
|
+
<lido-cell visible="true" layout="row" width="100%" height="22%" bg-color="transparent">
|
|
46
|
+
<lido-image visible="true" width="160px" height="160px" bg-color="white" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picture_Clues/f1.png"></lido-image>
|
|
47
|
+
<lido-text visible="true" value="${args.value2}" id="drop2" tab-index="2" type="drop" width="630px" height="100px" bg-color="white" border-radius="16px" onCorrect="lido-avatar.avatarAnimate='Success';"></lido-text>
|
|
48
|
+
</lido-cell>
|
|
49
|
+
<lido-cell visible="true" layout="row" width="100%" height="22%" bg-color="transparent">
|
|
50
|
+
<lido-image visible="true" width="160px" height="160px" bg-color="white" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picture_Clues/f1.png"></lido-image>
|
|
51
|
+
<lido-text visible="true" value="${args.value3}" id="drop3" tab-index="3" type="drop" width="630px" height="100px" bg-color="white" border-radius="16px" onCorrect="lido-avatar.avatarAnimate='Success';"></lido-text>
|
|
52
|
+
</lido-cell>
|
|
53
|
+
<lido-cell visible="true" layout="row" width="100%" height="22%" bg-color="transparent">
|
|
54
|
+
<lido-image visible="true" width="160px" height="160px" bg-color="white" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picture_Clues/f1.png"></lido-image>
|
|
55
|
+
<lido-text visible="true" value="${args.value4}" id="drop4" tab-index="4" type="drop" width="630px" height="100px" bg-color="white" border-radius="16px" onCorrect="lido-avatar.avatarAnimate='Success';"></lido-text>
|
|
56
|
+
</lido-cell>
|
|
57
|
+
</lido-cell>
|
|
58
|
+
|
|
59
|
+
<!-- Drag Elements -->
|
|
60
|
+
<lido-cell visible="true" layout="col" width="42%" height="100%" bg-color="transparent">
|
|
61
|
+
<lido-cell visible="true" layout="col" width="100%" height="70%" bg-color="transparent">
|
|
62
|
+
<lido-text visible="true" value="${args.value3}" type="drag" width="630px" height="100px" bg-color="#FFAC4C" font-size="50px" font-color="black" string="${args.value3}" border-radius="16px" onEntry="this.fontWeight='600';"></lido-text>
|
|
63
|
+
<lido-text visible="true" value="${args.value1}" type="drag" width="630px" height="100px" bg-color="#FFAC4C" font-size="50px" font-color="black" string="${args.value1}" border-radius="16px" onEntry="this.fontWeight='600';"></lido-text>
|
|
64
|
+
<lido-text visible="true" value="${args.value4}" type="drag" width="630px" height="100px" bg-color="#FFAC4C" font-size="50px" font-color="black" string="${args.value4}" border-radius="16px" onEntry="this.fontWeight='600';"></lido-text>
|
|
65
|
+
<lido-text visible="true" value="${args.value2}" type="drag" width="630px" height="100px" bg-color="#FFAC4C" font-size="50px" font-color="black" string="${args.value2}" border-radius="16px" onEntry="this.fontWeight='600';"></lido-text>
|
|
66
|
+
</lido-cell>
|
|
67
|
+
<lido-cell visible="true" height="30%"></lido-cell>
|
|
68
|
+
</lido-cell>
|
|
69
|
+
</lido-cell>
|
|
70
|
+
</lido-container>
|
|
71
|
+
</main>`;
|
|
72
|
+
}
|
package/dist/collection/stories/Templates/palEgraTemplate1/palEgraLetterIdentification.stories.js
ADDED
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { html } from "lit-html";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/LetterIdentification',
|
|
4
|
+
argTypes: {
|
|
5
|
+
PracticeMode: { control: 'boolean' },
|
|
6
|
+
template: { control: 'select', options: ['Template1', 'Template2'] },
|
|
7
|
+
option1: { control: 'text' },
|
|
8
|
+
option2: { control: 'text' },
|
|
9
|
+
option3: { control: 'text' },
|
|
10
|
+
option4: { control: 'text' },
|
|
11
|
+
option5: { control: 'text' },
|
|
12
|
+
correctAns: { control: 'text' },
|
|
13
|
+
},
|
|
14
|
+
};
|
|
15
|
+
export default meta;
|
|
16
|
+
export const Default = {
|
|
17
|
+
args: {
|
|
18
|
+
PracticeMode: false,
|
|
19
|
+
template: ['Template1'],
|
|
20
|
+
option1: 'A',
|
|
21
|
+
option2: 'D',
|
|
22
|
+
option3: 'E',
|
|
23
|
+
option4: 'B',
|
|
24
|
+
option5: 'C',
|
|
25
|
+
correctAns: 'A',
|
|
26
|
+
},
|
|
27
|
+
render: args => {
|
|
28
|
+
const xml = getContainerXml(args);
|
|
29
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
function getContainerXml(args) {
|
|
33
|
+
return `<main>
|
|
34
|
+
<lido-container objective="${(args.correctAns)}" template-id="mcq" is-continue-on-correct="${args.PracticeMode}" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/background-images/Write%20Set.png" onCorrect="lido-avatar.avatarAnimate='Success'; this.sleep='2000';" onInCorrect="lido-avatar.avatarAnimate='Fail';" onEntry="questionText.speak='true';">
|
|
35
|
+
<lido-col visible="true" width="100%" height="80%" bg-color="transparent">
|
|
36
|
+
|
|
37
|
+
<!-- Chimple Avatar -->
|
|
38
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.400px,portrait.402px" width="landscape.350px,portrait.398px" x="landscape.60%, portrait.28%" y="landscape.50px, portrait.77%" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
39
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv">
|
|
40
|
+
</lido-avatar>
|
|
41
|
+
<lido-image id="image" disableEdit="true" value="image" visible="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/Shadow.png" bgColor="transparent" width="inherit" height="27px" x="0" y="330px">
|
|
42
|
+
</lido-image>
|
|
43
|
+
</lido-cell>
|
|
44
|
+
|
|
45
|
+
<lido-text visible="${args.template === 'Template1'}" id="questionText" width="300px" height="300px" tab-index="1" bg-color="#fff5bb" string="${(args.correctAns).toLowerCase()}" font-size="150px" border-radius="20px" font-color="black" onEntry="this.fontWeight='700'; this.border='#ffac4c 2px solid'; "></lido-text>
|
|
46
|
+
|
|
47
|
+
<lido-cell visible="${args.template !== 'Template1'}" onTouch="questionText.speak='true';" layout="row" width="300px" height="300px" bg-color="white" border-radius="130px" onEntry="this.border='#ffac4c 2px solid';">
|
|
48
|
+
<lido-image visible="true" bg-color="transparent" width="200px" height="200px" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/Icons/palAudioIcon.png"></lido-image>
|
|
49
|
+
</lido-cell>
|
|
50
|
+
|
|
51
|
+
<lido-row visible="true" width="80%" height="50%" bg-color="transparent">
|
|
52
|
+
<lido-text visible="true" width="220px" height="220px" type="click" value="${args.option1}" string="${args.option1}" font-size="120px" border-radius="20px" font-color="black" onEntry="this.fontWeight='700';"></lido-text>
|
|
53
|
+
<lido-text visible="true" width="220px" height="220px" type="click" value="${args.option2}" string="${args.option2}" font-size="120px" border-radius="20px" font-color="black" onEntry="this.fontWeight='700';"></lido-text>
|
|
54
|
+
<lido-text visible="true" width="220px" height="220px" type="click" value="${args.option3}" string="${args.option3}" font-size="120px" border-radius="20px" font-color="black" onEntry="this.fontWeight='700';"></lido-text>
|
|
55
|
+
<lido-text visible="true" width="220px" height="220px" type="click" value="${args.option4}" string="${args.option4}" font-size="120px" border-radius="20px" font-color="black" onEntry="this.fontWeight='700';"></lido-text>
|
|
56
|
+
<lido-text visible="true" width="220px" height="220px" type="click" value="${args.option5}" string="${args.option5}" font-size="120px" border-radius="20px" font-color="black" onEntry="this.fontWeight='700';"></lido-text>
|
|
57
|
+
</lido-row>
|
|
58
|
+
</lido-col>
|
|
59
|
+
</lido-container>
|
|
60
|
+
</main>`;
|
|
61
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/palEgra_OddOneOut',
|
|
4
|
+
argTypes: {
|
|
5
|
+
options: { control: 'object' },
|
|
6
|
+
PracticeMode: { control: 'boolean' },
|
|
7
|
+
},
|
|
8
|
+
};
|
|
9
|
+
export default meta;
|
|
10
|
+
export const palEgra_OddOneOut = {
|
|
11
|
+
args: {
|
|
12
|
+
question_text: 'विषम का चयन कीजिये',
|
|
13
|
+
options: ['तन', '@नर', 'मन', 'जन'],
|
|
14
|
+
PracticeMode: true,
|
|
15
|
+
},
|
|
16
|
+
render: args => {
|
|
17
|
+
const xml = getContainerXml(args);
|
|
18
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
19
|
+
},
|
|
20
|
+
};
|
|
21
|
+
function getContainerXml(args) {
|
|
22
|
+
const option_cells = args.options.map((q, index) => {
|
|
23
|
+
return `
|
|
24
|
+
<lido-cell layout="row" id="text${1 + index}" tab-index="${12 + index}" template-id="mcq" visible="true" margin="" onEntry="this.border-radius='14px'; this.justify-content='center'; this.alignItems='center';" height="landscape.280px,portrait.244px" width="landscape.328px,portrait.244px" bg-color="orange" type="click" value="${q.startsWith('@') ? q.slice(1) : q}">
|
|
25
|
+
<lido-text visible="true" value="${q.startsWith('@') ? q.slice(1) : q}" string="${q.startsWith('@') ? q.slice(1) : q}" font-family="'Baloo Bhai 2'" font-color="black" font-size="landscape.130px, portrait.100px" bg-color="orange" onEntry="this.fontWeight='700';">
|
|
26
|
+
</lido-text>
|
|
27
|
+
</lido-cell>
|
|
28
|
+
`;
|
|
29
|
+
}).join('');
|
|
30
|
+
// ---------------------- FINAL XML ----------------------
|
|
31
|
+
return `
|
|
32
|
+
<main>
|
|
33
|
+
<lido-container visible="true" id="lido-container" template-id="mcq" onInCorrect="lido-avatar.avatarAnimate='Fail';this.sleep='2000';" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2300';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/fb207af37ae5d938778718e0095fc36abef7c694.png" objective="${(args.options.find(q => q.startsWith('@')) || '').slice(1)}" is-continue-on-correct="${args.PracticeMode}" is-allow-only-correct="${args.PracticeMode}" custom-style= "#text {
|
|
34
|
+
box-shadow: none !important;
|
|
35
|
+
}" onEntry="questionText.speak='true';">
|
|
36
|
+
<!-- Chimple Avatar -->
|
|
37
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.362px,portrait.378px" width="landscape.315px,portrait.382px"
|
|
38
|
+
x="landscape.39%, portrait.30%" y="landscape.27%, portrait.78%" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
39
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
40
|
+
</lido-avatar>
|
|
41
|
+
</lido-cell>
|
|
42
|
+
|
|
43
|
+
<lido-cell layout="landscape.col, portrait.row" aria-hidden="true" visible="true" height="landscape.100%,portrait.150px" width="landscape.100%, portrait.80%" bg-Color="transparent" margin="landscape.46px 0px 0px 0px,portrait.20px 0px 0px 0px" onEntry="this.z-index='1'; this.justify-content='center'; this.alignItems='center'; this.gap='278px';">
|
|
44
|
+
<!-- question cells -->
|
|
45
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px 0px 0px 0px,portrait.-168px 0px 0px 0px" onEntry="this.border-radius='26px'; this.border='2px solid #FFB612'; this.justify-content='center'; this.align-items='center';" height="landscape.184px,portrait.42%" width="landscape.1050px,portrait.100%" bg-color="#FFF5BB">
|
|
46
|
+
<lido-text visible="true" id="questionText" tab-index="11" value="" string="${args.question_text}" font-family="'Baloo Bhai 2'" font-color="#07004E" font-size="landscape.90px, portrait.100px" bg-color="" onEntry="this.fontWeight='700';">
|
|
47
|
+
</lido-text>
|
|
48
|
+
</lido-cell>
|
|
49
|
+
|
|
50
|
+
<!-- options cells -->
|
|
51
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px 38px 0px 0px,portrait.0" onEntry="this.border-radius='26px';" height="landscape.290px,portrait.35%" width="landscape.100%,portrait.100%" bg-color="transparent">
|
|
52
|
+
${option_cells}
|
|
53
|
+
</lido-cell>
|
|
54
|
+
</lido-cell>
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
</lido-container>
|
|
58
|
+
</main>
|
|
59
|
+
`;
|
|
60
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/palEgraArrangePictures',
|
|
4
|
+
argTypes: {
|
|
5
|
+
options: { control: 'object' },
|
|
6
|
+
PracticeMode: { control: 'boolean' },
|
|
7
|
+
},
|
|
8
|
+
};
|
|
9
|
+
export default meta;
|
|
10
|
+
export const palEgraArrangePictures = {
|
|
11
|
+
args: {
|
|
12
|
+
question_text: 'एक बिल्ली मेज के ऊपर बैठी थी। मेज के ऊपर एक गिलास में शरबत था। बिल्ली मेज के ऊपर शरबत पीने चढ़ी। उसने शरबत मेज पर गिरा दिया।',
|
|
13
|
+
images: [{ id: '1', src: 'https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/cat_playing_outside.webp' },
|
|
14
|
+
{ id: '2', src: 'https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/glass_on_table.webp' },
|
|
15
|
+
{ id: '3', src: 'https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/cat_on_table.jpg' },
|
|
16
|
+
{ id: '4', src: 'https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/juice_on_table_spilled.webp' }],
|
|
17
|
+
PracticeMode: true,
|
|
18
|
+
},
|
|
19
|
+
render: args => {
|
|
20
|
+
const xml = getContainerXml(args);
|
|
21
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
function getContainerXml(args) {
|
|
25
|
+
const drop_cells = args.images.map((img, index) => {
|
|
26
|
+
return `
|
|
27
|
+
<lido-cell layout="landscape.col, portrait.col" visible="true" margin="landscape.0px,portrait.0" onEntry="this.border-radius='16px';" height="landscape.auto,portrait.35%" width="landscape.auto,portrait.100%" bg-color="transparent" padding="0px 13px 0px 17px" gap="12px">
|
|
28
|
+
<lido-text visible="true" id="label${index + 1}" tab-index="" value="" string="${img.id}" font-family="'Baloo Bhai 2'" width="72px" height="72px" font-color="#030028" font-size="landscape.60px, portrait.100px" bg-color="#FFF5BB" onEntry="this.fontWeight='600'; this.border-radius='100%';">
|
|
29
|
+
</lido-text>
|
|
30
|
+
<lido-text visible="true" id="drop${index + 1}" tab-index="${11 + index}" value="${img.id}" string="" font-family="'Baloo Bhai 2'" width="215px" height="215px" font-color="#030028" font-size="landscape.140px, portrait.100px" bg-color="#FFFFFF" type="drop" onEntry="this.fontWeight='700'; this.border-radius='16px';">
|
|
31
|
+
</lido-text>
|
|
32
|
+
</lido-cell>
|
|
33
|
+
`;
|
|
34
|
+
}).join('');
|
|
35
|
+
const shuffledOptions = [...args.images].sort(() => Math.random() - 0.5);
|
|
36
|
+
const drag_cells = shuffledOptions.map((img, index) => {
|
|
37
|
+
return `
|
|
38
|
+
<lido-image visible="true" id="drag${index + 1}" value="${img.id}" bg-color="transparent" width="215px" height="215px" src="${img.src}" type="drag"></lido-image>
|
|
39
|
+
`;
|
|
40
|
+
}).join('');
|
|
41
|
+
// ---------------------- FINAL XML ----------------------
|
|
42
|
+
return `
|
|
43
|
+
<main>
|
|
44
|
+
<lido-container visible="true" id="lido-container" onEntry="lido-question.speak='true';" onInCorrect="lido-avatar.avatarAnimate='Fail';this.sleep='2000';" template-id="dragAndDrop" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2300';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/palEgraTemp6_bg.png" objective="${args.images.map(img => img.id).join(',')}" is-continue-on-correct="${args.PracticeMode}" is-allow-only-correct="${args.PracticeMode}" custom-style= "#drop1, #drop2, #drop3, #drop4, #drop5 {
|
|
45
|
+
border: none !important;
|
|
46
|
+
box-shadow:
|
|
47
|
+
inset -10px 10px 10px 0 rgba(0, 0, 0, 0.25);
|
|
48
|
+
}">
|
|
49
|
+
<!-- Chimple Avatar -->
|
|
50
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.330px,portrait.378px" width="landscape.300px,portrait.382px"
|
|
51
|
+
x="landscape.86%, portrait.30%" y="landscape.34%, portrait.78%" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
52
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
53
|
+
</lido-avatar>
|
|
54
|
+
<lido-image id="image" disableEdit="true" value="image" visible="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/Shadow.png" bgColor="transparent" width="inherit" height="20px" x="landscape.-1px, portrait.-7px" y="landscape.280px, portrait.535px" altText="{shadowImage}"></lido-image>
|
|
55
|
+
</lido-cell>
|
|
56
|
+
|
|
57
|
+
<lido-cell layout="landscape.col, portrait.row" aria-hidden="true" visible="true" height="landscape.95%,portrait.150px" width="landscape.98%, portrait.80%" bg-Color="transparent" margin="landscape.102px 0px 0px 0px,portrait.20px 0px 0px 0px" onEntry="this.z-index='1'; this.justify-content='center'; this.alignItems='center'; this.gap='12px';">
|
|
58
|
+
<!-- question cell -->
|
|
59
|
+
<lido-text tab-index="111" visible="true" id="lido-question" width="landscape.103%, portrait.80%" height="auto" bg-color="#FFF5BB" string="${args.question_text}" border-radius="16px" onEntry="this.border='2px solid #FFB612'; this.fontWeight='700';" font-size="48px" font-color="#07004E" font-family="'Baloo Bhai 2'" padding="7px 0px 0px 0px">
|
|
60
|
+
</lido-text>
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
<!--drop cells -->
|
|
64
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px 84px 0px 0px,portrait.0" onEntry="this.border-radius='26px';" height="landscape.auto,portrait.35%" width="landscape.auto,portrait.100%" bg-color="transparent">
|
|
65
|
+
${drop_cells}
|
|
66
|
+
</lido-cell>
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px 50px 0px 0px,portrait.0" onEntry="this.border-radius='16px'; this.justify-content='space-evenly';" height="landscape.auto,portrait.35%" width="landscape.100%,portrait.100%" bg-color="transparent">
|
|
70
|
+
${drag_cells}
|
|
71
|
+
</lido-cell>
|
|
72
|
+
|
|
73
|
+
</lido-cell>
|
|
74
|
+
|
|
75
|
+
</lido-container>
|
|
76
|
+
</main>
|
|
77
|
+
`;
|
|
78
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/palEgraBuildWord',
|
|
4
|
+
argTypes: {
|
|
5
|
+
options: { control: 'object' },
|
|
6
|
+
PracticeMode: { control: 'boolean' },
|
|
7
|
+
},
|
|
8
|
+
};
|
|
9
|
+
export default meta;
|
|
10
|
+
export const palEgraBuildWord = {
|
|
11
|
+
args: {
|
|
12
|
+
question_text: 'Listen to the word and build it with the letters below',
|
|
13
|
+
question_word: ['dance'],
|
|
14
|
+
PracticeMode: true,
|
|
15
|
+
},
|
|
16
|
+
render: args => {
|
|
17
|
+
const xml = getContainerXml(args);
|
|
18
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
19
|
+
},
|
|
20
|
+
};
|
|
21
|
+
function getContainerXml(args) {
|
|
22
|
+
const word = args.question_word[0]; // "dance"
|
|
23
|
+
const letters = [...word]; // ["d", "a", "n", "c", "e"]
|
|
24
|
+
const drop_cells = letters.map((q, index) => {
|
|
25
|
+
return `
|
|
26
|
+
<lido-text visible="true" id="drop${index + 1}" tab-index="${12 + index}" value="${q}" string="?" font-family="'Baloo Bhai 2'" width="172px" height="189px" font-color="#030028" font-size="landscape.140px, portrait.100px" bg-color="#FFFFFF" type="drop" onEntry="this.fontWeight='700'; this.border-radius='16px';">
|
|
27
|
+
</lido-text>
|
|
28
|
+
`;
|
|
29
|
+
}).join('');
|
|
30
|
+
const shuffledOptions = [...letters].sort(() => Math.random() - 0.5);
|
|
31
|
+
const drag_cells = shuffledOptions.map((q, index) => {
|
|
32
|
+
return `
|
|
33
|
+
<lido-text visible="true" id="drag${index + 1}" tab-index="${16 + index}" value="${q}" string="${q}" font-family="'Baloo Bhai 2'" width="173px" height="189px" font-color="#FFFFFF" font-size="landscape.140px, portrait.100px" bg-color="#A05730" type="drag" onEntry="this.fontWeight='700'; this.border-radius='16px'; this.justifyContent='center'; this.alignItems='center';">
|
|
34
|
+
</lido-text>
|
|
35
|
+
`;
|
|
36
|
+
}).join('');
|
|
37
|
+
// ---------------------- FINAL XML ----------------------
|
|
38
|
+
return `
|
|
39
|
+
<main>
|
|
40
|
+
<lido-container visible="true" id="lido-container" onEntry="lido-question.speak='true';" onInCorrect="lido-avatar.avatarAnimate='Fail';this.sleep='2000';" template-id="dragAndDrop" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2300';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/palEgraTemp6_bg.png" objective="${args.question_word.join(',')}" is-continue-on-correct="${args.PracticeMode}" is-allow-only-correct="${args.PracticeMode}" custom-style= "#drop1, #drop2, #drop3, #drop4, #drop5 {
|
|
41
|
+
border: 2px solid #FFB612 !important;
|
|
42
|
+
}">
|
|
43
|
+
<!-- Chimple Avatar -->
|
|
44
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.330px,portrait.378px" width="landscape.300px,portrait.382px"
|
|
45
|
+
x="landscape.82%, portrait.30%" y="landscape.32%, portrait.78%" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
46
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
47
|
+
</lido-avatar>
|
|
48
|
+
<lido-image id="image" disableEdit="true" value="image" visible="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/Shadow.png" bgColor="transparent" width="inherit" height="20px" x="landscape.-1px, portrait.-7px" y="landscape.280px, portrait.535px" altText="{shadowImage}"></lido-image>
|
|
49
|
+
</lido-cell>
|
|
50
|
+
|
|
51
|
+
<lido-cell layout="landscape.col, portrait.row" aria-hidden="true" visible="true" height="landscape.82%,portrait.150px" width="landscape.98%, portrait.80%" bg-Color="transparent" margin="landscape.94px 0px 0px 0px,portrait.20px 0px 0px 0px" onEntry="this.z-index='1'; this.justify-content='center'; this.alignItems='center'; this.gap='73px';">
|
|
52
|
+
<!-- question cell -->
|
|
53
|
+
<lido-text tab-index="111" visible="true" id="lido-question" width="landscape.93%, portrait.80%" height="60px" bg-color="#FFF5BB" string="${args.question_text}" border-radius="16px" onEntry="this.border='2px solid #FFB612'; this.fontWeight='700'; this.padding='50px';" font-size="60px" font-color="#07004E" font-family="'Baloo Bhai 2'">
|
|
54
|
+
</lido-text>
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
<!-- options cells -->
|
|
58
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.-18px 91px 31px -100px,portrait.0" onEntry="this.border-radius='26px';" height="landscape.auto,portrait.35%" width="landscape.auto,portrait.100%" bg-color="transparent" gap="60px">
|
|
59
|
+
<lido-text layout="landscape.row, portrait.col" visible="true" margin="landscape.0px,portrait.0" onEntry="this.border-radius='100%'; this.border='2px solid #FFB612';" height="landscape.190px,portrait.35%" width="landscape.184px,portrait.100%" bg-color="white" font-size="1px" onTouch="this.speak='true';" string="${word}">
|
|
60
|
+
<lido-image visible="true" bg-color="transparent" width="100px" height="100px" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/Icons/palAudioIcon.png"></lido-image>
|
|
61
|
+
</lido-text>
|
|
62
|
+
|
|
63
|
+
<!-- drop cells -->
|
|
64
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px,portrait.0" onEntry="this.border-radius='16px';" height="landscape.239px,portrait.35%" width="landscape.auto,portrait.100%" bg-color="#FFFFFF99" padding="0px 13px 0px 17px" gap="12px">
|
|
65
|
+
${drop_cells}
|
|
66
|
+
</lido-cell>
|
|
67
|
+
</lido-cell>
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.-46px 0px 0px 0px,portrait.0" onEntry="this.border-radius='16px';" height="landscape.239px,portrait.35%" width="landscape.auto,portrait.100%" bg-color="transparent" gap="23px">
|
|
71
|
+
${drag_cells}
|
|
72
|
+
</lido-cell>
|
|
73
|
+
|
|
74
|
+
</lido-cell>
|
|
75
|
+
</lido-container>
|
|
76
|
+
</main>
|
|
77
|
+
`;
|
|
78
|
+
}
|
package/dist/collection/stories/Templates/palEgra_word_formation/palEgra_WordFormation.stories.js
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/palEgraWordFormation',
|
|
4
|
+
argTypes: {
|
|
5
|
+
options: { control: 'object' },
|
|
6
|
+
PracticeMode: { control: 'boolean' },
|
|
7
|
+
},
|
|
8
|
+
};
|
|
9
|
+
export default meta;
|
|
10
|
+
export const palEgraWordFormation = {
|
|
11
|
+
args: {
|
|
12
|
+
image: ['https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/madari.jpg'],
|
|
13
|
+
options: ['म', 'दा', 'री'],
|
|
14
|
+
PracticeMode: true,
|
|
15
|
+
},
|
|
16
|
+
render: args => {
|
|
17
|
+
const xml = getContainerXml(args);
|
|
18
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
19
|
+
},
|
|
20
|
+
};
|
|
21
|
+
function getContainerXml(args) {
|
|
22
|
+
const drop_cells = args.options.map((q, index) => {
|
|
23
|
+
return `
|
|
24
|
+
<lido-text visible="true" id="drop${index + 1}" tab-index="${12 + index}" value="${q}" string="?" font-family="'Baloo Bhai 2'" width="173px" height="189px" font-color="#030028" font-size="landscape.140px, portrait.100px" bg-color="#FFFFFF" type="drop" onEntry="this.fontWeight='700'; this.border-radius='16px';">
|
|
25
|
+
</lido-text>
|
|
26
|
+
`;
|
|
27
|
+
}).join('');
|
|
28
|
+
const shuffledOptions = [...args.options].sort(() => Math.random() - 0.5);
|
|
29
|
+
const drag_cells = shuffledOptions.map((q, index) => {
|
|
30
|
+
return `
|
|
31
|
+
<lido-text visible="true" id="drag${index + 1}" tab-index="${16 + index}" value="${q}" string="${q}" font-family="'Baloo Bhai 2'" width="173px" height="189px" font-color="#030028" font-size="landscape.140px, portrait.100px" bg-color="#A05730" type="drag" onEntry="this.fontWeight='700'; this.border-radius='16px'; this.justifyContent='center'; this.alignItems='baseline';">
|
|
32
|
+
</lido-text>
|
|
33
|
+
`;
|
|
34
|
+
}).join('');
|
|
35
|
+
// ---------------------- FINAL XML ----------------------
|
|
36
|
+
return `
|
|
37
|
+
<main>
|
|
38
|
+
<lido-container visible="true" id="lido-container" template-id="dragAndDrop" onInCorrect="lido-avatar.avatarAnimate='Fail';this.sleep='2000';" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2300';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/PAL-EGRA/palEgraTemp6_bg.png" objective="${args.options.join(',')}" is-continue-on-correct="${args.PracticeMode}" is-allow-only-correct="${args.PracticeMode}" custom-style= "#drop1, #drop2, #drop3, #drop4 {
|
|
39
|
+
border: 2px solid #FFB612 !important;
|
|
40
|
+
}">
|
|
41
|
+
<!-- Chimple Avatar -->
|
|
42
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.330px,portrait.378px" width="landscape.300px,portrait.382px"
|
|
43
|
+
x="landscape.62%, portrait.30%" y="landscape.35%, portrait.78%" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
44
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
45
|
+
</lido-avatar>
|
|
46
|
+
</lido-cell>
|
|
47
|
+
|
|
48
|
+
<lido-cell layout="landscape.row, portrait.row" aria-hidden="true" visible="true" height="landscape.100%,portrait.150px" width="landscape.98%, portrait.80%" bg-Color="transparent" margin="landscape.46px 0px 0px 0px,portrait.20px 0px 0px 0px" onEntry="this.z-index='1'; this.justify-content='center'; this.alignItems='center'; this.gap='73px';">
|
|
49
|
+
<!-- image cell -->
|
|
50
|
+
<lido-cell layout="landscape.row, portrait.col" tab-index="11" visible="true" margin="landscape.0px 0px 0px 0px,portrait.-168px 0px 0px 0px" onEntry="this.border='11px solid #FFFFFF'; this.justify-content='center'; this.align-items='center';" height="landscape.600px,portrait.42%" width="landscape.600px,portrait.100%" bg-color="#FFF5BB">
|
|
51
|
+
<lido-image type="text" margin="landscape.0px,portrait.0px 0px 0px 0px" id="" visible="true" src="${args.image}" width="100%" height="100%" onTouch="this.speak='true'">
|
|
52
|
+
</lido-image>
|
|
53
|
+
</lido-cell>
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
<lido-cell layout="landscape.col, portrait.col" visible="true" margin="landscape.0px,portrait.0" onEntry="this.border-radius='26px';" height="landscape.84%,portrait.35%" width="landscape.51%,portrait.100%" bg-color="transparent" gap="240px">
|
|
57
|
+
<!-- drop cells -->
|
|
58
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px,portrait.0" onEntry="this.border-radius='16px';" height="landscape.239px,portrait.35%" width="landscape.auto,portrait.100%" bg-color="#FFFFFF99" padding="0px 13px 0px 17px" gap="23px">
|
|
59
|
+
${drop_cells}
|
|
60
|
+
</lido-cell>
|
|
61
|
+
|
|
62
|
+
<!-- drag cells -->
|
|
63
|
+
<lido-cell layout="landscape.row, portrait.col" visible="true" margin="landscape.0px,portrait.0" onEntry="this.border-radius='16px';" height="landscape.239px,portrait.35%" width="landscape.auto,portrait.100%" bg-color="transparent" padding="0px 13px 0px 17px" gap="23px">
|
|
64
|
+
${drag_cells}
|
|
65
|
+
</lido-cell>
|
|
66
|
+
</lido-cell>
|
|
67
|
+
</lido-cell>
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
</lido-container>
|
|
71
|
+
</main>
|
|
72
|
+
`;
|
|
73
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/palStorytale',
|
|
4
|
+
};
|
|
5
|
+
export default meta;
|
|
6
|
+
export const AmazingStories = {
|
|
7
|
+
args: {
|
|
8
|
+
content: 'One hot day, a crow was very thirsty.It flew here and there looking for water. At last, it found a pitcher with a little water at the bottom. The crow tried to drink but could not reach the water. Then the crow had an idea. It dropped small stones into the pitcher. Slowly, the water rose up. The crow drank the water and flew away happily.',
|
|
9
|
+
},
|
|
10
|
+
render: args => {
|
|
11
|
+
const xml = getContainerXml(args);
|
|
12
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
13
|
+
},
|
|
14
|
+
};
|
|
15
|
+
function getContainerXml(args) {
|
|
16
|
+
return `<main>
|
|
17
|
+
<lido-container show-prev-button="false" show-next-button="true" id="lido-container" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/palStory/bgImage.png" height="1600px" width="900px" value="mainContainer4" objective="" aria-label="" x="0" y="0" z="0" visible="true" audio="" onTouch="" onCorrect="" onEntry="" onInCorrect="lido-avatar.avatarAnimate='Fail'; this.sleep='2000';" show-check="false" is-continue-on-correct="true">
|
|
18
|
+
<lido-cell layout="row" id="cell1" visible="true" margin="82px 203px 0px 0px" value="cell1" width="landscape.100%,portrait.86%" height="landscape.82%,portrait.80%" x="50px" y="50px" bg-color="transparent" onEntry="" >
|
|
19
|
+
|
|
20
|
+
<lido-text id="text1" tab-index="1" value="text1" visible="true" width="landscape.100%,portrait.90%" height="100%" bg-color="#FFF5BB" font-family="Baloo Bhai 2" font-size="60px" font-color="#000" string='${args.content}' onEntry="this.border='2px solid #FFB612'; this.fontWeight='600';this.padding='0px 40px 0px 40px'; this.boxShadow='unset'; this.border-radius='16px'; this.textAlign='start'; this.speak='true';">
|
|
21
|
+
</lido-text>
|
|
22
|
+
</lido-cell>
|
|
23
|
+
|
|
24
|
+
<!-- below is the code for avatar -->
|
|
25
|
+
|
|
26
|
+
<lido-pos id="pos1" disable-edit="true" value="pos1" height="350px" width="350px" x="landscape.91%, portrait.580px" y="landscape.56%, portrait.1350px" aria-hidden="true" z="1" bg-color="transparent" type="" visible="true" audio="col1.mp3" onTouch="" onCorrect="">
|
|
27
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="350px" width="350px" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
28
|
+
</lido-avatar>
|
|
29
|
+
<lido-image id="image1" disable-edit="true" value="image1" visible="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/Shadow.png" bg-color="transparent" width="186px" height="20px" x="77px" y="305px" alt-text="{shadowImage}">
|
|
30
|
+
</lido-image>
|
|
31
|
+
</lido-pos>
|
|
32
|
+
</lido-container>
|
|
33
|
+
|
|
34
|
+
</main>`;
|
|
35
|
+
}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/pictureClues',
|
|
4
|
+
argTypes: {
|
|
5
|
+
option1: { control: 'text' },
|
|
6
|
+
option2: { control: 'text' },
|
|
7
|
+
option3: { control: 'text' },
|
|
8
|
+
option4: { control: 'text' },
|
|
9
|
+
option5: { control: 'text' },
|
|
10
|
+
img1: { control: 'file' },
|
|
11
|
+
sentenceParts: { control: 'object' },
|
|
12
|
+
answer: { control: 'text' },
|
|
13
|
+
isAllowOnlyCorrect: { control: 'boolean' },
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
export default meta;
|
|
17
|
+
export const pictureClues = {
|
|
18
|
+
args: {
|
|
19
|
+
option1: "विद्यालय",
|
|
20
|
+
option2: "पानी",
|
|
21
|
+
option3: "पाठ",
|
|
22
|
+
option4: "बस",
|
|
23
|
+
option5: "बाजा",
|
|
24
|
+
sentenceParts: [
|
|
25
|
+
'ज़ोर ज़ोर से',
|
|
26
|
+
'#बाजा',
|
|
27
|
+
'बजा।।'
|
|
28
|
+
],
|
|
29
|
+
isAllowOnlyCorrect: true,
|
|
30
|
+
img1: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picture_Clues/f1.png",
|
|
31
|
+
answer: "बाजा",
|
|
32
|
+
},
|
|
33
|
+
render: args => {
|
|
34
|
+
const xml = getContainerXml(args);
|
|
35
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
36
|
+
},
|
|
37
|
+
};
|
|
38
|
+
function renderSentencePart(text, id) {
|
|
39
|
+
// DROP case
|
|
40
|
+
if (text.startsWith('#')) {
|
|
41
|
+
const value = text.replace('#', '').trim();
|
|
42
|
+
return `
|
|
43
|
+
<lido-text type="drop" drop-attr="stretch" value="${value}" id="${id}" visible="true" height="136px" width="200px" y="19px" onEntry="this.position='relative';this.margin-right='40px';this.border='4px solid #A8B53A';this.border-radius='16px';"></lido-text>
|
|
44
|
+
`;
|
|
45
|
+
}
|
|
46
|
+
// NORMAL TEXT case
|
|
47
|
+
return `
|
|
48
|
+
<lido-text visible="true" height="100px" width="auto" id="${id}" string="${text}" font-family="'Baloo Bhai 2'" font-color="black" font-size="80px" bg-color="transparent" onEntry=" this.font-weight='700'; this.border-radius='16px'; this.margin-right='40px'; " ></lido-text>
|
|
49
|
+
`;
|
|
50
|
+
}
|
|
51
|
+
function getContainerXml(args) {
|
|
52
|
+
let tabCounter = 1;
|
|
53
|
+
const { isAllowOnlyCorrect = true } = args;
|
|
54
|
+
const { sentenceParts = [] } = args;
|
|
55
|
+
return `<main>
|
|
56
|
+
<lido-container show-drop-border="false" visible="true" template-id="dragAndDrop" id="lido-container" objective="बाजा" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/palEgra-pictureWordMatch/bgImg.png" onInCorrect="lido-avatar.avatarAnimate='Fail';this.sleep='2000';" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2300';" is-continue-on-correct="true" is-allow-only-correct="${isAllowOnlyCorrect}" onEntry="inst.speak='true';">
|
|
57
|
+
|
|
58
|
+
<!-- Chimple Avatar -->
|
|
59
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.344px,portrait.402px" width="landscape.296px,portrait.398px" x="landscape.85%, portrait.28%" y="landscape.21%, portrait.77%" aria-hidden="true" z="1" bg-color="transparent" visible="true">
|
|
60
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="100%" width="100%" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="">
|
|
61
|
+
</lido-avatar>
|
|
62
|
+
</lido-cell>
|
|
63
|
+
|
|
64
|
+
<lido-text visible="false" id="inst" tab-index="1" string="drag and drop the correct option to form a sentence"></lido-text>
|
|
65
|
+
|
|
66
|
+
<lido-cell visible="true" layout="col" height="85%" width="98%" bg-color="transparent" margin="61px 0px -58px 0px">
|
|
67
|
+
<lido-cell layout="row" visible="true" height="330px" width="330px" bg-color="transparent">
|
|
68
|
+
<lido-image tab-index="8" visible="true" height="auto" width="auto" src="${args.img1}"></lido-image>
|
|
69
|
+
|
|
70
|
+
</lido-cell>
|
|
71
|
+
<lido-cell layout="flex" visible="true" height="270px" width="auto" onEntry="this.display='ruby';" bg-color="transparent">
|
|
72
|
+
${sentenceParts
|
|
73
|
+
.map((part, index) => renderSentencePart(part, `sentence-${index}`))
|
|
74
|
+
.join('')}
|
|
75
|
+
</lido-cell>
|
|
76
|
+
<lido-cell layout="row" visible="true" height="270px" width="90%" bg-color="transparent" onEntry="this.align-items='center';this.justify-content='space-around';">
|
|
77
|
+
<lido-text visible="true" height="136px" width="auto" type="drag" id="drag1" tab-index="2" string="${args.option1}" value="${args.option1}" font-family="'Baloo Bhai 2'" font-color="black" font-size="80px" bg-color="#FFAC4C" onEntry="this.font-weight='700';this.padding='10px 45px 10px 45px'; this.border-radius='16px';" ></lido-text>
|
|
78
|
+
<lido-text visible="true" height="136px" width="auto" type="drag" id="drag2" tab-index="3" string="${args.option2}" value="${args.option2}" font-family="'Baloo Bhai 2'" font-color="black" font-size="80px" bg-color="#FFAC4C" onEntry="this.font-weight='700';this.padding='10px 45px 10px 45px';this.border-radius='16px';" ></lido-text>
|
|
79
|
+
<lido-text visible="true" height="136px" width="auto" type="drag" id="drag3" tab-index="4" string="${args.option3}" value="${args.option3}" font-family="'Baloo Bhai 2'" font-color="black" font-size="80px" bg-color="#FFAC4C" onEntry="this.font-weight='700';this.padding='10px 45px 10px 45px';this.border-radius='16px';" ></lido-text>
|
|
80
|
+
<lido-text visible="true" height="136px" width="auto" type="drag" id="drag4" tab-index="5" string="${args.option4}" value="${args.option4}" font-family="'Baloo Bhai 2'" font-color="black" font-size="80px" bg-color="#FFAC4C" onEntry="this.font-weight='700';this.padding='10px 45px 10px 45px';this.border-radius='16px';" ></lido-text>
|
|
81
|
+
<lido-text visible="true" height="136px" width="auto" type="drag" id="drag5" tab-index="6" string="${args.option5}" value="${args.option5}" font-family="'Baloo Bhai 2'" font-color="black" font-size="80px" bg-color="#FFAC4C" onEntry="this.font-weight='700';this.padding='10px 45px 10px 45px';this.border-radius='16px';" ></lido-text>
|
|
82
|
+
|
|
83
|
+
</lido-cell>
|
|
84
|
+
</lido-cell>
|
|
85
|
+
|
|
86
|
+
</lido-container>
|
|
87
|
+
</main>`;
|
|
88
|
+
}
|