lido-player 0.0.2-alpha-49 → 0.0.2-alpha-43-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-fe562525.js → index-6a69c33a.js} +36 -3
- package/dist/cjs/index.cjs.js +2 -2
- package/dist/cjs/{lido-avatar_19.cjs.entry.js → lido-avatar_21.cjs.entry.js} +431 -180
- package/dist/cjs/lido-player.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{utils-96ce5641.js → utils-079a5e7d.js} +1032 -165
- package/dist/collection/collection-manifest.json +2 -0
- package/dist/collection/components/calculator/lido-calculator.css +87 -0
- package/dist/collection/components/calculator/lido-calculator.js +321 -0
- package/dist/collection/components/cell/lido-cell.js +1 -1
- package/dist/collection/components/column/lido-col.js +1 -1
- package/dist/collection/components/container/lido-container.js +20 -1
- package/dist/collection/components/flashCard/lido-flash-card.js +1 -1
- package/dist/collection/components/float/lido-float.js +1 -1
- package/dist/collection/components/home/lido-home.js +9 -29
- package/dist/collection/components/keyboard/lido-keyboard.js +2 -2
- package/dist/collection/components/mathMatrix/lido-math-matrix.css +10 -2
- package/dist/collection/components/mathMatrix/lido-math-matrix.js +226 -20
- 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.css +114 -0
- package/dist/collection/components/scale/lido-balance.js +549 -0
- package/dist/collection/components/shape/lido-shape.js +1 -1
- 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 +49 -128
- package/dist/collection/components/wrap/lido-wrap.js +1 -1
- package/dist/collection/css/animation.css +21 -0
- package/dist/collection/css/index.css +45 -0
- package/dist/collection/stories/Templates/Fill-Up/fill-up.stories.js +24 -25
- package/dist/collection/stories/Templates/RocketGame/rocketGame.stories.js +0 -3
- package/dist/collection/stories/Templates/balancing/balancing.stories.js +67 -0
- package/dist/collection/stories/Templates/checker-block/checkerBlock.stories.js +156 -0
- package/dist/collection/stories/Templates/checkerBlock/checkerBlock.stories.js +49 -0
- package/dist/collection/stories/Templates/fillAnswer/fill-answer.stories.js +66 -0
- package/dist/collection/stories/Templates/foodJar/food-jar.stories.js +65 -0
- package/dist/collection/stories/Templates/matchBox/matchBox.stories.js +105 -0
- package/dist/collection/stories/Templates/matchBox/matchBox2.stories.js +92 -0
- package/dist/collection/stories/Templates/matchingCard/matching-card.stories.js +47 -0
- package/dist/collection/stories/Templates/multiplyBeeds/multiplyBeeds.stories.js +59 -0
- package/dist/collection/stories/Templates/nimbleTable/nimbleTable.stories.js +93 -0
- package/dist/collection/stories/Templates/numberBoardTwo/numberBoardTwo.stories.js +100 -0
- package/dist/collection/stories/Templates/numberPair/numberPair.stories.js +212 -0
- package/dist/collection/stories/Templates/order-tractor/order-tractor-ascending-order.stories.js +6 -7
- package/dist/collection/stories/Templates/order-tractor/order-tractor.stories.js +6 -7
- package/dist/collection/stories/Templates/questionBoard/questionBoard.stories.js +158 -0
- package/dist/collection/stories/Templates/sequenceBox/sequenceBox1.stories.js +102 -0
- package/dist/collection/stories/Templates/sequenceBox/sequenceBox2.stories.js +94 -0
- package/dist/collection/stories/Templates/shapePair/shape-pair.stories.js +184 -0
- package/dist/collection/stories/Templates/shapeTractor/shape-tractor.stories.js +213 -0
- package/dist/collection/stories/Templates/sumTogether/sumTogether.stories.js +109 -0
- package/dist/collection/stories/Templates/total/total.stories.js +59 -0
- package/dist/collection/stories/Templates/writeNumber/writeNumber.stories.js +96 -0
- package/dist/collection/stories/Templates/writeSet/writeSet.stories.js +55 -0
- package/dist/collection/stories/Templates/writeWord/writeWord.stories.js +5 -6
- package/dist/collection/utils/utils.js +439 -81
- package/dist/collection/utils/utilsHandlers/clickHandler.js +21 -25
- package/dist/collection/utils/utilsHandlers/dragDropHandler.js +95 -42
- package/dist/collection/utils/utilsHandlers/lidoBalanceHandler.js +67 -0
- package/dist/collection/utils/utilsHandlers/lidoCalculatorHandler.js +94 -0
- package/dist/collection/utils/utilsHandlers/matrixHandler.js +298 -0
- package/dist/collection/utils/utilsHandlers/slideHandler.js +4 -2
- package/dist/collection/utils/utilsHandlers/sortHandler.js +21 -12
- package/dist/components/index.js +1 -1
- package/dist/components/lido-avatar.js +1 -1
- package/dist/components/lido-balance.d.ts +11 -0
- package/dist/components/lido-balance.js +6 -0
- package/dist/components/lido-calculator.d.ts +11 -0
- package/dist/components/lido-calculator.js +6 -0
- 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 +32 -20
- 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-08d0deab.js +254 -0
- package/dist/components/{p-b5b6ad27.js → p-15971ede.js} +1 -1
- package/dist/components/{p-0bf92c7f.js → p-1fbdb431.js} +2 -2
- package/dist/components/{p-b43ce4e1.js → p-29bdd953.js} +2 -2
- package/dist/components/{p-b8af26e6.js → p-322acda6.js} +40 -48
- package/dist/components/{p-51943db6.js → p-3f406017.js} +2 -2
- package/dist/components/p-44808985.js +186 -0
- package/dist/components/{p-4cabbf28.js → p-52844fa4.js} +2 -2
- package/dist/components/{p-4882df37.js → p-73e31a86.js} +2 -2
- package/dist/components/{p-af54a485.js → p-74849cdd.js} +4 -4
- package/dist/components/{p-9c56f378.js → p-7f7e5672.js} +2 -2
- package/dist/components/{p-4dbae73b.js → p-835b973d.js} +2 -2
- package/dist/components/{p-b55af747.js → p-90465904.js} +50 -129
- package/dist/components/{p-cae021c6.js → p-904711c8.js} +2 -2
- package/dist/components/{p-e735dce9.js → p-9be56729.js} +5 -3
- package/dist/components/{p-cac6c8bf.js → p-afbc196f.js} +2 -2
- package/dist/components/{p-cfa2aec8.js → p-bed94c37.js} +1047 -164
- package/dist/components/{p-7f11a624.js → p-cbac3cbc.js} +1 -1
- package/dist/components/{p-61d97438.js → p-d37ab4dc.js} +2 -2
- package/dist/components/p-e36ddcc1.js +166 -0
- package/dist/components/{p-03e4cafe.js → p-e4e42677.js} +2 -2
- package/dist/esm/{index-f47852d4.js → index-170e58c7.js} +36 -4
- package/dist/esm/index.js +2 -2
- package/dist/esm/{lido-avatar_19.entry.js → lido-avatar_21.entry.js} +430 -181
- package/dist/esm/lido-player.js +3 -3
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{utils-9ce243d8.js → utils-5df09162.js} +1031 -164
- 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-137c99ce.js +2 -0
- package/dist/lido-player/p-7556e652.js +9 -0
- package/dist/lido-player/p-eb956325.entry.js +1 -0
- package/dist/types/components/calculator/lido-calculator.d.ts +40 -0
- package/dist/types/components/container/lido-container.d.ts +4 -0
- package/dist/types/components/home/lido-home.d.ts +0 -1
- package/dist/types/components/mathMatrix/lido-math-matrix.d.ts +24 -4
- package/dist/types/components/scale/lido-balance.d.ts +160 -0
- package/dist/types/components/trace/lido-trace.d.ts +0 -1
- package/dist/types/components.d.ts +342 -14
- package/dist/types/stories/Templates/balancing/balancing.stories.d.ts +4 -0
- package/dist/types/stories/Templates/checker-block/checkerBlock.stories.d.ts +4 -0
- package/dist/types/stories/Templates/checkerBlock/checkerBlock.stories.d.ts +4 -0
- package/dist/types/stories/Templates/fillAnswer/fill-answer.stories.d.ts +4 -0
- package/dist/types/stories/Templates/foodJar/food-jar.stories.d.ts +4 -0
- package/dist/types/stories/Templates/matchBox/matchBox.stories.d.ts +4 -0
- package/dist/types/stories/Templates/matchBox/matchBox2.stories.d.ts +4 -0
- package/dist/types/stories/Templates/matchingCard/matching-card.stories.d.ts +4 -0
- package/dist/types/stories/Templates/multiplyBeeds/multiplyBeeds.stories.d.ts +9 -0
- package/dist/types/stories/Templates/nimbleTable/nimbleTable.stories.d.ts +4 -0
- package/dist/types/stories/Templates/numberBoardTwo/numberBoardTwo.stories.d.ts +4 -0
- package/dist/types/stories/Templates/numberPair/numberPair.stories.d.ts +4 -0
- package/dist/types/stories/Templates/questionBoard/questionBoard.stories.d.ts +15 -0
- package/dist/types/stories/Templates/sequenceBox/sequenceBox1.stories.d.ts +11 -0
- package/dist/types/stories/Templates/sequenceBox/sequenceBox2.stories.d.ts +11 -0
- package/dist/types/stories/Templates/shapePair/shape-pair.stories.d.ts +4 -0
- package/dist/types/stories/Templates/shapeTractor/shape-tractor.stories.d.ts +12 -0
- package/dist/types/stories/Templates/sumTogether/sumTogether.stories.d.ts +11 -0
- package/dist/types/stories/Templates/total/total.stories.d.ts +4 -0
- package/dist/types/stories/Templates/writeNumber/writeNumber.stories.d.ts +13 -0
- package/dist/types/stories/Templates/writeSet/writeSet.stories.d.ts +4 -0
- package/dist/types/utils/utils.d.ts +8 -2
- package/dist/types/utils/utilsHandlers/dragDropHandler.d.ts +4 -0
- package/dist/types/utils/utilsHandlers/lidoBalanceHandler.d.ts +2 -0
- package/dist/types/utils/utilsHandlers/lidoCalculatorHandler.d.ts +1 -0
- package/dist/types/utils/utilsHandlers/matrixHandler.d.ts +1 -0
- package/package.json +1 -1
- package/dist/components/p-a8ab771b.js +0 -160
- package/dist/lido-player/p-90212aa9.js +0 -9
- package/dist/lido-player/p-d3911ee1.entry.js +0 -1
- package/dist/lido-player/p-ddf627b0.js +0 -2
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/CheckerBlock',
|
|
4
|
+
argTypes: {
|
|
5
|
+
shapeNumber: { control: 'number' },
|
|
6
|
+
},
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
export const Blocks = {
|
|
10
|
+
args: {
|
|
11
|
+
shapeNumber: 1
|
|
12
|
+
},
|
|
13
|
+
render: args => {
|
|
14
|
+
const xml = getContainerXml(args);
|
|
15
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
function getContainerXml(args) {
|
|
19
|
+
const shape = generateSlots(args.shapeNumber);
|
|
20
|
+
let tabIndex = 1;
|
|
21
|
+
let objective = [];
|
|
22
|
+
// Generate <lido-math-matrix> elements for each slot
|
|
23
|
+
const dropMatrices = Object.entries(shape)
|
|
24
|
+
.map(([key, { width, height }], index) => {
|
|
25
|
+
objective.push(`slot${index + 1}`);
|
|
26
|
+
return `
|
|
27
|
+
<lido-math-matrix id="drop-${index + 1}" visible="true" width="1600px" height="900px" rows="${width}" cols="${height}" top-index="false" left-index="false" bottom-index="false" active-only-visible="true" activeBgColor="#967ca6" defualtFill="${width * height}" tab-index="${tabIndex++}" type="drop" value="slot${index + 1}" clickable="false" border="2px solid black" font-color="white"></lido-math-matrix>
|
|
28
|
+
`;
|
|
29
|
+
})
|
|
30
|
+
.join("\n");
|
|
31
|
+
const dragMatrices = Object.entries(shape)
|
|
32
|
+
.map(([key, { width, height }], index) => {
|
|
33
|
+
const colors = ['#a657fa', '#fa7f98', '#dee60e', '#71f24e', '#55d9a4'];
|
|
34
|
+
const randomColor = colors[Math.floor(Math.random() * colors.length)];
|
|
35
|
+
return `
|
|
36
|
+
<lido-math-matrix id="drag-${index + 1}" visible="true" width="1600px" height="900px" rows="${width}" cols="${height}" top-index="false" left-index="false" bottom-index="false" active-only-visible="true" activeBgColor="${randomColor}" defualtFill="${width * height}" tab-index="${tabIndex++}" type="drag" value="slot${index + 1}" clickable="false" border="2px solid black" font-color="white"></lido-math-matrix>`;
|
|
37
|
+
})
|
|
38
|
+
.join("\n");
|
|
39
|
+
return `<main>
|
|
40
|
+
<lido-container visible="true" show-next-button="true" dropAttr="math-matrix" objective="${objective}" onCorrect="this.sleep='200'; all.animation='placeToLeft 1.5s linear'; this.sleep='1500';" is-continue-on-correct="true" is-allow-only-correct="true" bg-color="transparent" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/create%20sentence/Spring.png">
|
|
41
|
+
|
|
42
|
+
<lido-cell visible="true" id="all" layout="row" height="900px" width="1600px" onEntry="this.justifyContent='unset';">
|
|
43
|
+
<lido-cell visible="true" layout="col" width="30%" height="90%" bg-color="transparent" z="2">
|
|
44
|
+
<lido-cell visible="true" layout="random" width="100%" height="100%" bg-color="transparent" x="50px">
|
|
45
|
+
${dragMatrices}
|
|
46
|
+
</lido-cell>
|
|
47
|
+
</lido-cell>
|
|
48
|
+
<lido-cell id="truck" visible="true" layout="pos" x="0" y="0" z="1" onEntry="this.animation='rightToPlace 1.5s linear';">
|
|
49
|
+
<lido-image visible="true" width="1500px" height="900px" x="185px" y='20px' src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/CheckerBlock/checkerBlockTruck.svg"></lido-image>
|
|
50
|
+
<lido-math-matrix id="matrix" visible="true" width="1570px" height="860px" x="800px" y="23px" rows="10" cols="10" top-index="false" left-index="false" bottom-index="false" active-only-visible="false" defualtFill="100" text="1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100" border="2px solid #736e6cff" border-radius="0" active-bg-color="#d7d5d9" clickable="false" type="checkerBlock" font-color="#4f2e35"></lido-math-matrix>
|
|
51
|
+
${dropMatrices}
|
|
52
|
+
|
|
53
|
+
</lido-cell>
|
|
54
|
+
</lido-cell>
|
|
55
|
+
|
|
56
|
+
</lido-container>
|
|
57
|
+
</main>`;
|
|
58
|
+
}
|
|
59
|
+
function generateSlots(level) {
|
|
60
|
+
switch (level) {
|
|
61
|
+
case 1:
|
|
62
|
+
return generateRandomSquare();
|
|
63
|
+
case 2:
|
|
64
|
+
return generateHorizontalStrips();
|
|
65
|
+
case 3:
|
|
66
|
+
return generateVerticalStrips();
|
|
67
|
+
case 8:
|
|
68
|
+
return generateHorizontalHalfStrips();
|
|
69
|
+
case 9:
|
|
70
|
+
return generate2by2Squares();
|
|
71
|
+
case 10:
|
|
72
|
+
return generateDoubleSquares();
|
|
73
|
+
case 11:
|
|
74
|
+
return generateSingleSquares();
|
|
75
|
+
default:
|
|
76
|
+
return generateRandomSquare();
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
function generateRandomSquare() {
|
|
80
|
+
const slots = {};
|
|
81
|
+
let generated = 0;
|
|
82
|
+
while (generated < 8) {
|
|
83
|
+
const type = Math.floor(Math.random() * 3);
|
|
84
|
+
const width = type === 0 ? 2 : 3;
|
|
85
|
+
const height = type === 0 ? 3 : (type === 1 ? 2 : 3);
|
|
86
|
+
generated++;
|
|
87
|
+
slots[`slot-${generated}`] = { width, height };
|
|
88
|
+
}
|
|
89
|
+
return slots;
|
|
90
|
+
}
|
|
91
|
+
function generateHorizontalStrips() {
|
|
92
|
+
const slots = {};
|
|
93
|
+
let generated = 0;
|
|
94
|
+
while (generated < 5) {
|
|
95
|
+
const width = 10;
|
|
96
|
+
const height = 1;
|
|
97
|
+
generated++;
|
|
98
|
+
slots[`slot-${generated}`] = { width, height };
|
|
99
|
+
}
|
|
100
|
+
return slots;
|
|
101
|
+
}
|
|
102
|
+
function generateHorizontalHalfStrips() {
|
|
103
|
+
const slots = {};
|
|
104
|
+
let generated = 0;
|
|
105
|
+
while (generated < 10) {
|
|
106
|
+
const width = 5;
|
|
107
|
+
const height = 1;
|
|
108
|
+
generated++;
|
|
109
|
+
slots[`slot-${generated}`] = { width, height };
|
|
110
|
+
}
|
|
111
|
+
return slots;
|
|
112
|
+
}
|
|
113
|
+
function generateVerticalStrips() {
|
|
114
|
+
const slots = {};
|
|
115
|
+
let generated = 0;
|
|
116
|
+
while (generated < 5) {
|
|
117
|
+
const width = 1;
|
|
118
|
+
const height = 10;
|
|
119
|
+
generated++;
|
|
120
|
+
slots[`slot-${generated}`] = { width, height };
|
|
121
|
+
}
|
|
122
|
+
return slots;
|
|
123
|
+
}
|
|
124
|
+
function generate2by2Squares() {
|
|
125
|
+
const slots = {};
|
|
126
|
+
let generated = 0;
|
|
127
|
+
while (generated < 10) {
|
|
128
|
+
const width = 2;
|
|
129
|
+
const height = 2;
|
|
130
|
+
generated++;
|
|
131
|
+
slots[`slot-${generated}`] = { width, height };
|
|
132
|
+
}
|
|
133
|
+
return slots;
|
|
134
|
+
}
|
|
135
|
+
function generateDoubleSquares() {
|
|
136
|
+
const slots = {};
|
|
137
|
+
let generated = 0;
|
|
138
|
+
while (generated < 10) {
|
|
139
|
+
const width = 2;
|
|
140
|
+
const height = 1;
|
|
141
|
+
generated++;
|
|
142
|
+
slots[`slot-${generated}`] = { width, height };
|
|
143
|
+
}
|
|
144
|
+
return slots;
|
|
145
|
+
}
|
|
146
|
+
function generateSingleSquares() {
|
|
147
|
+
const slots = {};
|
|
148
|
+
let generated = 0;
|
|
149
|
+
while (generated < 10) {
|
|
150
|
+
const width = 1;
|
|
151
|
+
const height = 1;
|
|
152
|
+
generated++;
|
|
153
|
+
slots[`slot-${generated}`] = { width, height };
|
|
154
|
+
}
|
|
155
|
+
return slots;
|
|
156
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/CheckerBlock',
|
|
4
|
+
argTypes: {
|
|
5
|
+
shapeNumber: { control: 'number' },
|
|
6
|
+
},
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
export const CheckerBlock = {
|
|
10
|
+
args: {
|
|
11
|
+
shapeNumber: 1
|
|
12
|
+
},
|
|
13
|
+
render: args => {
|
|
14
|
+
const xml = getContainerXml(args);
|
|
15
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
function getContainerXml(args) {
|
|
19
|
+
const shape = generateSlots();
|
|
20
|
+
console.log("shape : ", shape);
|
|
21
|
+
return `<main>
|
|
22
|
+
<lido-container visible="true" show-next-button="true" dropAttr="math-matrix" objective="nammadha" onCorrect="this.sleep='120000';">
|
|
23
|
+
<lido-math-matrix id="matrix3" visible="true" rows="10" cols="10" top-index="false" left-index="false" bottom-index="false" active-only-visible="false" defualtFill="100" active-bg-color="#deb3f2" clickable="false" type="checkerBlock"></lido-math-matrix>
|
|
24
|
+
|
|
25
|
+
<lido-cell visible="true" layout="pos" x="0" y="0">
|
|
26
|
+
<lido-math-matrix id="matrix1" visible="true" width="1600px" height="900px" rows="1" cols="10" top-index="false" left-index="false" bottom-index="false" active-only-visible="true" text="false" activeBgColor="#9a3dc5ff" defualtFill="10" tab-index="1" type="drop" value="nammadha" clickable="false"></lido-math-matrix>
|
|
27
|
+
</lido-cell>
|
|
28
|
+
|
|
29
|
+
<lido-cell visible="true" layout="pos" x="0" y="0">
|
|
30
|
+
<lido-math-matrix id="matrix4" visible="true" width="1600px" height="900px" rows="2" cols="3" top-index="false" left-index="false" bottom-index="false" active-only-visible="true" text="false" activeBgColor="#9a3dc5ff" defualtFill="9" tab-index="3" type="drag" value="nammadha" clickable="false"></lido-math-matrix>
|
|
31
|
+
</lido-cell>
|
|
32
|
+
|
|
33
|
+
</lido-container>
|
|
34
|
+
</main>`;
|
|
35
|
+
}
|
|
36
|
+
function generateSlots() {
|
|
37
|
+
const gridSize = 10;
|
|
38
|
+
const slots = {};
|
|
39
|
+
let generated = 0;
|
|
40
|
+
const getCell = (row, col) => row * 10 + col + 1;
|
|
41
|
+
while (generated < 8) {
|
|
42
|
+
const type = Math.floor(Math.random() * 3);
|
|
43
|
+
const width = type === 0 ? 2 : 3;
|
|
44
|
+
const height = type === 0 ? 3 : (type === 1 ? 2 : 3);
|
|
45
|
+
generated++;
|
|
46
|
+
slots[`slot-${generated}`] = { width, height };
|
|
47
|
+
return slots;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/fillAnswer',
|
|
4
|
+
argTypes: {
|
|
5
|
+
firstNum: { control: 'text' },
|
|
6
|
+
operator: { control: 'text' },
|
|
7
|
+
secontNum: { control: 'text' },
|
|
8
|
+
equator: { control: 'text' },
|
|
9
|
+
answer: { control: 'text' },
|
|
10
|
+
option1: { control: 'text' },
|
|
11
|
+
option2: { control: 'text' },
|
|
12
|
+
option3: { control: 'text' },
|
|
13
|
+
option4: { control: 'text' },
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
export default meta;
|
|
17
|
+
export const OrderTractor = {
|
|
18
|
+
args: {
|
|
19
|
+
firstNum: '3', operator: '+', secontNum: '4', equator: '=', answer: '7',
|
|
20
|
+
option1: '5', option2: '7', option3: '3', option4: '2',
|
|
21
|
+
},
|
|
22
|
+
render: args => {
|
|
23
|
+
const xml = getContainerXml(args);
|
|
24
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
25
|
+
},
|
|
26
|
+
};
|
|
27
|
+
function getContainerXml(args) {
|
|
28
|
+
return `
|
|
29
|
+
<main>
|
|
30
|
+
<lido-container id="lido-container" is-allow-only-correct="true" value="mainContainer1" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/fill-in-the-blanks/cloud.png" objective="${args.answer}" width="100%" bg-color="transparent" visible="true" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2000'; " onEntry="this.justifyContent='space-around';" onInCorrect="lido-avatar.avatarAnimate='Fail'; this.sleep='2000';" show-check="false" is-continue-on-correct="true" after-drop="false">
|
|
31
|
+
<!-- Chimple Avatar -->
|
|
32
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.448px,portrait.402px" width="landscape.350px,portrait.398px" x="landscape.1267px, portrait.541px" y="landscape.587px, portrait.1304px" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="this.animation='rightToPlace 2.5s linear';">
|
|
33
|
+
<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}">
|
|
34
|
+
</lido-avatar>
|
|
35
|
+
</lido-cell>
|
|
36
|
+
|
|
37
|
+
<!--Parent cell -->
|
|
38
|
+
<lido-cell layout="col" visible="true" width="100%" height="100%" bg-color="transparent">
|
|
39
|
+
<!-- heading -->
|
|
40
|
+
<lido-cell audio="" layout="row" visible="true" width="landscape.45%, portrait.69%" height="landscape.15%, portrait.auto" bg-color="white" onEntry="this.borderRadius='10px'; this.padding='8px';this.animation='topToPlace 2.5s linear';" margin="landscape.110px 0px 0px 0px , portrait.400px 0px 0px 0px">
|
|
41
|
+
<lido-text id="question" visible="false" string="solve the problem and select the correct answer from below" value="solve the problem and select the correct answer from below" onEntry="this.sleep='2000';this.speak='true';"></lido-text>
|
|
42
|
+
|
|
43
|
+
<lido-text tab-index="1" font-family="'Baloo Bhai 2'" visible="true" font-size="88px" y="-10px" string="${args.firstNum}" bg-color="transparent" onEntry="this.position='relative'; this.fontWeight='600';this.display='inline'; this.padding='0px 20px 0px 0px'; "></lido-text>
|
|
44
|
+
<lido-text tab-index="2" font-family="'Baloo Bhai 2'" visible="true" font-size="88px" y="-10px" string="${args.operator}" bg-color="transparent" onEntry="this.position='relative';this.fontWeight='600';this.display='inline';this.boxShadow='0 0 0'; this.padding='0px 21px 0px 0px';"></lido-text>
|
|
45
|
+
<lido-text tab-index="3" font-family="'Baloo Bhai 2'" visible="true" font-size="88px" y="-10px" string="${args.secontNum}" bg-color="transparent" onEntry="this.position='relative';this.fontWeight='600';this.display='inline';this.boxShadow='0 0 0'; this.padding='0px 21px 0px 0px';"></lido-text>
|
|
46
|
+
<lido-text tab-index="4" font-family="'Baloo Bhai 2'" visible="true" font-size="88px" y="-10px" string="${args.equator}" bg-color="transparent" onEntry="this.position='relative';this.fontWeight='600';this.display='inline';this.boxShadow='0 0 0'; this.padding='0px 21px 0px 0px';"></lido-text>
|
|
47
|
+
<lido-text tab-index="5" id="drop1" disable-edit="true" visible="true" width="164px" height="landscape.73px,portrait.77px" value="${args.answer}" type="drop" is-allow-only-one-drop="true" drop-Attr="stretch" onEntry="this.border-radius='10px';this.box-shoadow=''; this.margin-right='35px';" ></lido-text>
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
</lido-cell>
|
|
51
|
+
<lido-cell layout="row" childElementsLength="4" onEntry="this.gap='28px'; this.animation='rightToPlace 2.5s linear'; this.gridTemplateColumns = 'repeat(2, 1fr)'; this.gridTemplateRows = 'repeat(2, 1fr)';" visible="true" margin="landscape.6px 25px 74px 0px, portrait.-170px 128px 0px 117px">
|
|
52
|
+
<lido-text font-family="'Baloo Bhai 2'" audio="" id="option1" value="${args.option1}" tab-index="14" visible="true" bg-color="#fcf3b1" onEntry="this.padding='0px 48px'; this.borderRadius='24px'; this.fontWeight='600';" width="auto" height="landscape.87px, portrait.91px" string="${args.option1}" fontColor="black" font-size="88px" type="drag">
|
|
53
|
+
</lido-text>
|
|
54
|
+
<lido-text font-family="'Baloo Bhai 2'" audio="" id="option2" value="${args.option2}" tab-index="15" visible="true" bg-color="#fcf3b1" onEntry="this.padding='0px 48px'; this.borderRadius='24px'; this.fontWeight='600'; " width="auto" height="landscape.87px, portrait.91px" string="${args.option2}" fontColor="black" font-size="88px" type="drag">
|
|
55
|
+
</lido-text>
|
|
56
|
+
<lido-text font-family="'Baloo Bhai 2'" audio="" id="option3" value="${args.option3}" tab-index="16" visible="true" bg-color="#fcf3b1" onEntry="this.padding='0px 48px'; this.borderRadius='24px'; this.fontWeight='600'; " width="auto" height="landscape.87px, portrait.91px" string="${args.option3}" fontColor="black" font-size="88px" type="drag">
|
|
57
|
+
</lido-text>
|
|
58
|
+
<lido-text font-family="'Baloo Bhai 2'" audio="" id="option4" value="${args.option4}" tab-index="17" visible="true" bg-color="#fcf3b1" onEntry="this.padding='0px 48px'; this.borderRadius='24px'; this.fontWeight='600';" width="auto" height="landscape.87px, portrait.91px" string="${args.option4}" fontColor="black" font-size="88px" type="drag">
|
|
59
|
+
</lido-text>
|
|
60
|
+
</lido-cell>
|
|
61
|
+
|
|
62
|
+
</lido-cell>
|
|
63
|
+
</lido-container>
|
|
64
|
+
</main>
|
|
65
|
+
`;
|
|
66
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/foodJar',
|
|
4
|
+
argTypes: {
|
|
5
|
+
firstNum: { control: 'text' },
|
|
6
|
+
operator: { control: 'text' },
|
|
7
|
+
secondNum: { control: 'text' },
|
|
8
|
+
equator: { control: 'text' },
|
|
9
|
+
answer: { control: 'text' },
|
|
10
|
+
option1: { control: 'text' },
|
|
11
|
+
option2: { control: 'text' },
|
|
12
|
+
option3: { control: 'text' },
|
|
13
|
+
option4: { control: 'text' },
|
|
14
|
+
option5: { control: 'text' },
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
export default meta;
|
|
18
|
+
export const OrderTractor = {
|
|
19
|
+
args: {
|
|
20
|
+
firstNum: '10', operator: '+', secondNum: '5', equator: '=', answer: '15',
|
|
21
|
+
option1: '=', option2: '5', option3: '+', option4: '15', option5: '10',
|
|
22
|
+
},
|
|
23
|
+
render: args => {
|
|
24
|
+
const xml = getContainerXml(args);
|
|
25
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
26
|
+
},
|
|
27
|
+
};
|
|
28
|
+
function getContainerXml(args) {
|
|
29
|
+
return `
|
|
30
|
+
<main>
|
|
31
|
+
<lido-container id="lido-container" is-allow-only-correct="true" value="mainContainer1" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/Sky.png" objective="${[args.firstNum, args.operator, args.secondNum, args.equator, args.answer].join(',')}" width="100%" bg-color="transparent" visible="true" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2000'; " onEntry="this.justifyContent='space-around';" onInCorrect="lido-avatar.avatarAnimate='Fail'; this.sleep='2000';" show-check="false" is-continue-on-correct="true" after-drop="false" custom-style="#drop1, #drop2, #drop3, #drop4, #drop5{border: none !important;boxShadow: none !important;} ">
|
|
32
|
+
<!-- Chimple Avatar -->
|
|
33
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.448px,portrait.402px" width="landscape.350px,portrait.398px" x="landscape.1px, portrait.20px" y="landscape.5px, portrait.100px" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
34
|
+
<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}">
|
|
35
|
+
</lido-avatar>
|
|
36
|
+
</lido-cell>
|
|
37
|
+
|
|
38
|
+
<!-- image math matrix -->
|
|
39
|
+
<lido-cell layout="row" visible="true" width="100%" height="landscape.40%,portrait.80%" bg-color="transparent" margin="landscape.100px 0px 0px 0px,portrait.500px 0px 0px 0px">
|
|
40
|
+
<lido-math-matrix id="mat1" rows="3" cols="4" defualtFill="${args.firstNum}" leftIndex="false" topIndex="false" clickable="true" matrixImage="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/apple.png" activeBgColor="transparent" inactiveBgColor="transparent" border="none" height="100%" width="100%" visible="true"></lido-math-matrix>
|
|
41
|
+
<lido-math-matrix id="mat2" rows="3" cols="4" defualtFill="${args.secondNum}" leftIndex="false" topIndex="false" clickable="true" matrixImage="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/apple.png" activeBgColor="transparent" inactiveBgColor="transparent" border="none" height="100%" width="100%" visible="true"></lido-math-matrix>
|
|
42
|
+
</lido-cell>
|
|
43
|
+
|
|
44
|
+
<!-- drop elements -->
|
|
45
|
+
<lido-cell visible="true" id="answer" layout="row" height="landscape.30%,portrait.40%" width="landscape.80%,portrait.100%" bg-color="transparent" onEntry="this.alignItems='center';" margin="landscape.0,portrait.0px 0px 0px 0px">
|
|
46
|
+
<lido-image id="drop1" width="landscape.300px,portrait.200px" height="landscape.200px,portrait.200px" value="${args.firstNum}" visible="true" tab-index="1" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljargrey_equation.png" bg-Color="transparent" onEntry="" type="drop" onCorrect="lido-avatar.avatarAnimate='Success'"></lido-image>
|
|
47
|
+
<lido-image id="drop2" width="landscape.300px,portrait.200px" height="landscape.200px,portrait.200px" value="${args.operator}" visible="true" tab-index="2" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljargrey_equation.png" bg-Color="transparent" onEntry="" type="drop" onCorrect="lido-avatar.avatarAnimate='Success'" ></lido-image>
|
|
48
|
+
<lido-image id="drop3" width="landscape.300px,portrait.200px" height="landscape.200px,portrait.200px" value="${args.secondNum}" visible="true" tab-index="3" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljargrey_equation.png" bg-Color="transparent" onEntry="" type="drop" onCorrect="lido-avatar.avatarAnimate='Success'" ></lido-image>
|
|
49
|
+
<lido-image id="drop4" width="landscape.300px,portrait.200px" height="landscape.200px,portrait.200px" value="${args.equator}" visible="true" tab-index="4" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljargrey_equation.png" bg-Color="transparent" onEntry="" type="drop" onCorrect="lido-avatar.avatarAnimate='Success'" ></lido-image>
|
|
50
|
+
<lido-image id="drop5" width="landscape.300px,portrait.200px" height="landscape.200px,portrait.200px" value="${args.answer}" visible="true" tab-index="5" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljargrey_equation.png" bg-Color="transparent" onEntry="" type="drop" onCorrect="lido-avatar.avatarAnimate='Success'" ></lido-image>
|
|
51
|
+
</lido-cell>
|
|
52
|
+
|
|
53
|
+
<!-- drag elements -->
|
|
54
|
+
<lido-cell visible="true" id="answer" layout="row" height="landscape.30%,portrait.40%" width="landscape.80%,portrait.100%" bg-color="transparent" onEntry="this.alignItems='center';" >
|
|
55
|
+
<lido-text id="drg1" height="landscape.200px,portrait.200px" width="landscape.160px,portrait.155px" visible="true" font-family="'Baloo Bhai 2'" font-size="90px" string="${args.option1}" value="${args.option1}" tab-index="6" bg-Color="transparent" onEntry=" this.fontWeight='1000';" type="drag" border-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljar_equation.png" ></lido-text>
|
|
56
|
+
<lido-text id="drg2" height="landscape.200px,portrait.200px" width="landscape.160px,portrait.155px" visible="true" font-family="'Baloo Bhai 2'" font-size="90px" string="${args.option2}" value="${args.option2}" tab-index="7" bg-Color="transparent" onEntry=" this.fontWeight='1000';" type="drag" border-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljar_equation.png" ></lido-text>
|
|
57
|
+
<lido-text id="drg3" height="landscape.200px,portrait.200px" width="landscape.160px,portrait.155px" visible="true" font-family="'Baloo Bhai 2'" font-size="90px" string="${args.option3}" value="${args.option3}" tab-index="8" bg-Color="transparent" onEntry=" this.fontWeight='1000';" type="drag" border-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljar_equation.png" ></lido-text>
|
|
58
|
+
<lido-text id="drg4" height="landscape.200px,portrait.200px" width="landscape.160px,portrait.155px" visible="true" font-family="'Baloo Bhai 2'" font-size="90px" string="${args.option4}" value="${args.option4}" tab-index="9" bg-Color="transparent" onEntry=" this.fontWeight='1000';" type="drag" border-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljar_equation.png" ></lido-text>
|
|
59
|
+
<lido-text id="drg5" height="landscape.200px,portrait.200px" width="landscape.160px,portrait.155px" visible="true" font-family="'Baloo Bhai 2'" font-size="90px" string="${args.option5}" value="${args.option5}" tab-index="10" bg-Color="transparent" onEntry=" this.fontWeight='1000';" type="drag" border-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/FoodJar/smalljar_equation.png" ></lido-text>
|
|
60
|
+
</lido-cell>
|
|
61
|
+
|
|
62
|
+
</lido-container>
|
|
63
|
+
</main>
|
|
64
|
+
`;
|
|
65
|
+
}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/matchBox',
|
|
4
|
+
};
|
|
5
|
+
export default meta;
|
|
6
|
+
export const Blanks = {
|
|
7
|
+
args: {
|
|
8
|
+
ans1: '6',
|
|
9
|
+
ans2: '8',
|
|
10
|
+
ans3: '5',
|
|
11
|
+
ans4: '4',
|
|
12
|
+
ans5: '1',
|
|
13
|
+
option1: '6',
|
|
14
|
+
option2: '4',
|
|
15
|
+
option3: '5',
|
|
16
|
+
option4: '1',
|
|
17
|
+
option5: '8',
|
|
18
|
+
row1: '3',
|
|
19
|
+
col1: '2',
|
|
20
|
+
row2: '2',
|
|
21
|
+
col2: '2',
|
|
22
|
+
row3: '5',
|
|
23
|
+
col3: '1',
|
|
24
|
+
row4: '1',
|
|
25
|
+
col4: '1',
|
|
26
|
+
row5: '4',
|
|
27
|
+
col5: '2',
|
|
28
|
+
},
|
|
29
|
+
render: args => {
|
|
30
|
+
const xml = getContainerXml(args);
|
|
31
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
32
|
+
},
|
|
33
|
+
};
|
|
34
|
+
function getContainerXml(args) {
|
|
35
|
+
return `
|
|
36
|
+
<main>
|
|
37
|
+
|
|
38
|
+
<lido-container visible="true" dropAttr="EnableAnimation" is-allow-only-correct="true" objective="${args.ans1},${args.ans2},${args.ans3},${args.ans4},${args.ans5}" id="ldo-container" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2000';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/trace/Sky.png" is-continue-on-correct="true">
|
|
39
|
+
<lido-cell visible="true" onEntry="this.position='relative';" y="landscape.57%,portrait.77%">
|
|
40
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="360px" width="485px" y="landscape.200px,portrait.0px" onEntry="this.position='relative';" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
41
|
+
</lido-avatar>
|
|
42
|
+
</lido-cell>
|
|
43
|
+
<lido-cell layout="row" visible="true" margin="landscape.-336px 0px -49px,portrait.-103px 0px 333px 0px" bg-color="transparent" height="90%" width="landscape.84%,portrait.100%">
|
|
44
|
+
<lido-image layout="col" is-slice="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/matchBox/linematching_building1.png" visible="true" height="100%" width="landscape.30%,portrait.40%" onEntry="this.display='grid'; this.align-items='center';this.justify-content='center';this.gap='26px';">
|
|
45
|
+
<lido-cell layout="col" visible="true" margin="0px 18px 0px -18px" bg-color="transparent" height="89%" width="100%" onEntry="this.display='flex'; align-items='center'; justify-content='space-around';">
|
|
46
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="1" type="drag" id="drag1" value="${args.option1}" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
47
|
+
<lido-math-matrix id="matrix1" clickable="false" rows="${args.row1}" cols="${args.col1}" defualtFill="${args.option1}" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="pink" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
48
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
49
|
+
</lido-image>
|
|
50
|
+
|
|
51
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="2" type="drag" id="drag2" value="${args.option2}" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
52
|
+
<lido-math-matrix id="matrix2" clickable="false" rows="${args.row2}" cols="${args.col2}" defualtFill="${args.option2}" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="pink" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
53
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
54
|
+
</lido-image>
|
|
55
|
+
|
|
56
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="3" type="drag" id="drag3" value="${args.option3}" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
57
|
+
<lido-math-matrix id="matrix3" clickable="false" rows="${args.row3}" cols="${args.col3}" defualtFill="${args.option3}" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="pink" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
58
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
59
|
+
|
|
60
|
+
</lido-image>
|
|
61
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="4" type="drag" id="drag4" value="${args.option4}" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
62
|
+
<lido-math-matrix id="matrix4" clickable="false" rows="${args.row4}" cols="${args.col4}" defualtFill="${args.option4}" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="pink" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
63
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
64
|
+
</lido-image>
|
|
65
|
+
|
|
66
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="5" type="drag" id="drag5" value="${args.option5}" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
67
|
+
<lido-math-matrix id="matrix5" clickable="false" rows="${args.row5}" cols="${args.col5}" defualtFill="${args.option5}" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="pink" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
68
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
69
|
+
</lido-image>
|
|
70
|
+
</lido-cell>
|
|
71
|
+
</lido-image>
|
|
72
|
+
|
|
73
|
+
<lido-image layout="col" is-slice="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/matchBox/linematching_building2.png" visible="true" height="100%" width="landscape.30%,portrait.40%" onEntry="this.display='grid'; this.align-items='center';this.justify-content='center';this.gap='26px';">
|
|
74
|
+
<lido-cell layout="col" visible="true" margin="0px 18px 0px -18px" bg-color="transparent" height="89%" width="100%" onEntry="this.display='flex'; align-items='center'; justify-content='space-around';">
|
|
75
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="11" type="drop" id="drop1" value="6" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
76
|
+
<lido-math-matrix id="matrix11" clickable="false" rows="3" cols="2" defualtFill="6" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="palegreen" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
77
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
78
|
+
</lido-image>
|
|
79
|
+
|
|
80
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="12" type="drop" id="drop2" value="8" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
81
|
+
<lido-math-matrix id="matrix12" clickable="false" rows="4" cols="2" defualtFill="8" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="palegreen" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
82
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
83
|
+
</lido-image>
|
|
84
|
+
|
|
85
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="13" type="drop" id="drop3" value="5" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
86
|
+
<lido-math-matrix id="matrix13" clickable="false" rows="5" cols="1" defualtFill="5" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="palegreen" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
87
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
88
|
+
|
|
89
|
+
</lido-image>
|
|
90
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="14" type="drop" id="drop4" value="4" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
91
|
+
<lido-math-matrix id="matrix14" clickable="false" rows="2" cols="2" defualtFill="4" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="palegreen" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
92
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
93
|
+
</lido-image>
|
|
94
|
+
|
|
95
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="15" type="drop" id="drop5" value="1" height="100px" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
96
|
+
<lido-math-matrix id="matrix15" clickable="false" rows="1" cols="1" defualtFill="1" leftIndex="false" topIndex="false" matrixImage="" activeBgColor="palegreen" inactiveBgColor="transparent" border="2px solid black" height="150px" width="150px"
|
|
97
|
+
visible="true" margin="landscape.0,portrait.-26px 0px 0px 0px"></lido-math-matrix>
|
|
98
|
+
</lido-image>
|
|
99
|
+
</lido-cell>
|
|
100
|
+
</lido-image>
|
|
101
|
+
</lido-cell>
|
|
102
|
+
</lido-container>
|
|
103
|
+
</main>
|
|
104
|
+
`;
|
|
105
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/matchBox2',
|
|
4
|
+
argTypes: {
|
|
5
|
+
dragimg1: { control: 'file' },
|
|
6
|
+
dragimg2: { control: 'file' },
|
|
7
|
+
dragimg3: { control: 'file' },
|
|
8
|
+
dragimg4: { control: 'file' },
|
|
9
|
+
},
|
|
10
|
+
};
|
|
11
|
+
export default meta;
|
|
12
|
+
export const Blanks = {
|
|
13
|
+
args: {
|
|
14
|
+
drag1: 'lion',
|
|
15
|
+
dragimg1: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/lion.jpg",
|
|
16
|
+
drag2: 'zebra',
|
|
17
|
+
dragimg2: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/zebra.jpg",
|
|
18
|
+
drag3: 'tiger',
|
|
19
|
+
dragimg3: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/tiger.jpg",
|
|
20
|
+
drag4: 'hygine',
|
|
21
|
+
dragimg4: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/hygiene%201.png",
|
|
22
|
+
drop1: 'hygine',
|
|
23
|
+
dropimg1: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/hygiene%201.png",
|
|
24
|
+
drop2: 'lion',
|
|
25
|
+
dropimg2: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/lion.jpg",
|
|
26
|
+
drop3: 'tiger',
|
|
27
|
+
dropimg3: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/tiger.jpg",
|
|
28
|
+
drop4: 'zebra',
|
|
29
|
+
dropimg4: "https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/picturemeaning/zebra.jpg",
|
|
30
|
+
},
|
|
31
|
+
render: args => {
|
|
32
|
+
const xml = getContainerXml(args);
|
|
33
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
34
|
+
},
|
|
35
|
+
};
|
|
36
|
+
function getContainerXml(args) {
|
|
37
|
+
return `
|
|
38
|
+
<main>
|
|
39
|
+
|
|
40
|
+
<lido-container visible="true" dropAttr="EnableAnimation" is-allow-only-correct="true" objective="${args.drop1},${args.drop2},${args.drop3},${args.drop4}" id="ldo-container" onCorrect="lido-avatar.avatarAnimate='Success';this.sleep='2000';" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/trace/Sky.png" is-continue-on-correct="true">
|
|
41
|
+
<lido-cell visible="true" onEntry="this.position='relative';" y="landscape.57%,portrait.77%">
|
|
42
|
+
<lido-avatar id="lido-avatar" disable-edit="true" visible="true" height="360px" width="485px" y="landscape.200px,portrait.0px" onEntry="this.position='relative';" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/temp2/chimplecharacter.riv" alt-text="{chimpleCharacterRive}">
|
|
43
|
+
</lido-avatar>
|
|
44
|
+
</lido-cell>
|
|
45
|
+
<lido-cell layout="row" visible="true" margin="landscape.-336px 0px -49px,portrait.-103px 0px 333px 0px" bg-color="transparent" height="90%" width="landscape.84%,portrait.100%">
|
|
46
|
+
<lido-image layout="col" is-slice="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/matchBox/linematching_building1.png" visible="true" height="100%" width="landscape.30%,portrait.40%" onEntry="this.display='grid'; this.align-items='center';this.justify-content='center';this.gap='26px';">
|
|
47
|
+
<lido-cell layout="col" visible="true" margin="0px 18px 0px -18px" bg-color="transparent" height="89%" width="100%" onEntry="this.display='flex'; align-items='center'; justify-content='space-around';">
|
|
48
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="1" type="drag" id="drag1" value="${args.drag1}" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
49
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dragimg1}"></lido-image>
|
|
50
|
+
</lido-image>
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="3" type="drag" id="drag3" value="${args.drag2}" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
55
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dragimg2}"></lido-image>
|
|
56
|
+
|
|
57
|
+
</lido-image>
|
|
58
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="2" type="drag" id="drag2" value="${args.drag3}" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
59
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dragimg3}"></lido-image>
|
|
60
|
+
</lido-image>
|
|
61
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="4" type="drag" id="drag4" value="${args.drag4}" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
62
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dragimg4}"></lido-image>
|
|
63
|
+
</lido-image>
|
|
64
|
+
|
|
65
|
+
</lido-cell>
|
|
66
|
+
</lido-image>
|
|
67
|
+
|
|
68
|
+
<lido-image layout="col" is-slice="true" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/matchBox/linematching_building2.png" visible="true" height="100%" width="landscape.30%,portrait.40%" onEntry="this.display='grid'; this.align-items='center';this.justify-content='center';this.gap='26px';">
|
|
69
|
+
<lido-cell layout="col" visible="true" margin="0px 18px 0px -18px" bg-color="transparent" height="89%" width="100%" onEntry="this.display='flex'; align-items='center'; justify-content='space-around';">
|
|
70
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="11" type="drop" id="drop1" value="hygine" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
71
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dropimg1}"></lido-image>
|
|
72
|
+
</lido-image>
|
|
73
|
+
|
|
74
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="12" type="drop" id="drop2" value="lion" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
75
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dropimg2}"></lido-image>
|
|
76
|
+
</lido-image>
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="14" type="drop" id="drop4" value="tiger" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
80
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dropimg3}"></lido-image>
|
|
81
|
+
</lido-image>
|
|
82
|
+
|
|
83
|
+
<lido-image z="10" visible="true" is-slice="true" src="https://wallpapers.com/images/featured/blank-white-7sn5o1woonmklx1h.jpg" tab-index="15" type="drop" id="drop5" value="zebra" height="auto" width="auto" onEntry="this.display='flex'; this.align-items='center'; this.justify-content='center';" bg-color="white">
|
|
84
|
+
<lido-image visible="true" height="150px" width="150px" src="${args.dropimg4}"></lido-image>
|
|
85
|
+
</lido-image>
|
|
86
|
+
</lido-cell>
|
|
87
|
+
</lido-image>
|
|
88
|
+
</lido-cell>
|
|
89
|
+
</lido-container>
|
|
90
|
+
</main>
|
|
91
|
+
`;
|
|
92
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { html } from "lit";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: 'Templates/matchingCard',
|
|
4
|
+
argTypes: {
|
|
5
|
+
answer: { control: 'text' },
|
|
6
|
+
option1: { control: 'text' },
|
|
7
|
+
option2: { control: 'text' },
|
|
8
|
+
option3: { control: 'text' },
|
|
9
|
+
},
|
|
10
|
+
};
|
|
11
|
+
export default meta;
|
|
12
|
+
export const OrderTractor = {
|
|
13
|
+
args: {
|
|
14
|
+
answer: 'correct',
|
|
15
|
+
option1: 'incorrect', option2: 'correct', option3: 'incorrect',
|
|
16
|
+
},
|
|
17
|
+
render: args => {
|
|
18
|
+
const xml = getContainerXml(args);
|
|
19
|
+
return html `<lido-home .xmlData="${xml}"></lido-home>`;
|
|
20
|
+
},
|
|
21
|
+
};
|
|
22
|
+
function getContainerXml(args) {
|
|
23
|
+
return `
|
|
24
|
+
<main>
|
|
25
|
+
<lido-container id="lido-container" is-allow-only-correct="true" value="mainContainer1" bg-image="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/Spring.png" objective="${args.answer}" width="100%" bg-color="transparent" visible="true" onCorrect="lido-avatar.avatarAnimate='Success'; this.sleep='2000'; truck.animation='placeToLeft 2.5s linear'; imgs.animation='placeToLeft 2.5s linear'; dragEle.animation='placeToLeft 2.5s linear'; this.sleep='2000'; " onEntry="this.justifyContent='space-around';" onInCorrect="lido-avatar.avatarAnimate='Fail'; this.sleep='2000';" show-check="false" is-continue-on-correct="true" after-drop="false" custom-style="#dropEle{border: none !important} #drag1,#drag2,#drag3{box-shadow: none !important}">
|
|
26
|
+
<!-- Chimple Avatar -->
|
|
27
|
+
<lido-cell layout="pos" id="pos1" disable-edit="true" value="pos2" height="landscape.448px,portrait.402px" width="landscape.350px,portrait.398px" x="landscape.1px, portrait.20px" y="landscape.5px, portrait.318px" aria-hidden="true" z="1" bg-color="transparent" visible="true" onEntry="">
|
|
28
|
+
<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}">
|
|
29
|
+
</lido-avatar>
|
|
30
|
+
</lido-cell>
|
|
31
|
+
|
|
32
|
+
<lido-text id="trainAudio" visible="false" audio="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/train1%20(1).m4a" onEntry="this.speak='true';"></lido-text>
|
|
33
|
+
<lido-image id="truck" height="60%" width="landscape.100%,portrait.200%" visible="true" bg-Color="transparent" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/train.svg" margin="landscape.14px 0px 0px 0px,portrait.452px 0px 0px 0px" onEntry="this.animation='rightToPlace 2.5s linear';" onCorrect="this.animation='placeToLeft 2.5s linear';"></lido-image>
|
|
34
|
+
<lido-cell id="imgs" visible="true" x="landscape.-158px,portrait.0" y="landscape.-495px,portrait.-652px" layout="row" height="80%" width="landscape.35%,portrait.70%" bg-color="transparent" margin="landscape.-115px 0px 0px 345px,portrait.0px 0px 0px 95px" onEntry="this.position='relative';this.animation='rightToPlace 2.5s linear';" onCorrect="this.animation='placeToLeft 2.5s linear';">
|
|
35
|
+
<lido-image id="qn" height="landscape.320px,portrait.320px" value="${args.answer}" width="landscape.320px,portrait.320px" tab-index="2" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/Group%2047094.png"></lido-image>
|
|
36
|
+
<lido-image id="dropEle" height="landscape.320px,portrait.320px" value="${args.answer}" width="landscape.320px,portrait.320px" tab-index="1" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/card_shadow.png" type="drop"></lido-image>
|
|
37
|
+
</lido-cell>
|
|
38
|
+
<lido-cell id="dragEle" visible="true" layout="row" width="100%" height="40%" bg-color="transparent" margin="landscape.-580px 0px 50px 0px,portrait.-532px 0px 162px 0px" onEntry="this.animation='rightToPlace 2.5s linear';" onCorrect="this.animation='placeToLeft 2.5s linear';">
|
|
39
|
+
<lido-image id="drag1" height="landscape.320px,portrait.320px" width="landscape.320px,portrait.320px" tab-index="1" value="${args.option1}" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/Group%2047093.png" type="drag"></lido-image>
|
|
40
|
+
<lido-image id="drag2" height="landscape.320px,portrait.320px" width="landscape.320px,portrait.320px" tab-index="2" value="${args.option2}" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/Group%2047094.png" type="drag"></lido-image>
|
|
41
|
+
<lido-image id="drag3" height="landscape.320px,portrait.320px" width="landscape.320px,portrait.320px" tab-index="3" value="${args.option3}" src="https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/MatchingCard/Group%2047095.png" type="drag"></lido-image>
|
|
42
|
+
</lido-cell>
|
|
43
|
+
|
|
44
|
+
</lido-container>
|
|
45
|
+
</main>
|
|
46
|
+
`;
|
|
47
|
+
}
|