lido-player 0.0.2-alpha-33 → 0.0.2-alpha-35
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_18.cjs.entry.js +26 -24
- package/dist/cjs/{utils-07b2249f.js → utils-3bd777d9.js} +2 -1
- package/dist/collection/components/float/lido-float.css +4 -0
- package/dist/collection/components/home/lido-home.js +22 -20
- package/dist/collection/components/trace/lido-trace.js +3 -3
- package/dist/collection/utils/utilsHandlers/floatHandler.js +2 -1
- package/dist/components/index.js +1 -1
- package/dist/components/lido-avatar.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-pos.js +1 -1
- package/dist/components/lido-random.js +1 -1
- package/dist/components/lido-root.js +18 -18
- 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-72d16bea.js → p-0da64fcd.js} +1 -1
- package/dist/components/{p-dd8aa1c2.js → p-2b7f6448.js} +38 -36
- package/dist/components/{p-d00f3288.js → p-43d05f49.js} +1 -1
- package/dist/components/{p-4f726fb5.js → p-65eae7f7.js} +1 -1
- package/dist/components/{p-ac57a4e2.js → p-688c02a0.js} +4 -4
- package/dist/components/{p-963af660.js → p-6f439433.js} +1 -1
- package/dist/components/{p-9cb1af1a.js → p-74d63405.js} +1 -1
- package/dist/components/{p-7a22083e.js → p-7ca9b2ff.js} +1 -1
- package/dist/components/{p-6cb00626.js → p-806687ef.js} +1 -1
- package/dist/components/{p-affc10b9.js → p-89ce7a02.js} +1 -1
- package/dist/components/{p-891ef62d.js → p-912a3fd1.js} +2 -1
- package/dist/components/{p-fb18186b.js → p-95965640.js} +2 -2
- package/dist/components/{p-a9e29b2f.js → p-9a0d4b4d.js} +1 -1
- package/dist/components/{p-66a06c78.js → p-a0e12946.js} +1 -1
- package/dist/components/{p-6a7d604b.js → p-c204e882.js} +1 -1
- package/dist/components/{p-cbba1f37.js → p-d0160fac.js} +2 -2
- package/dist/components/{p-b8a8822b.js → p-d3e62673.js} +1 -1
- package/dist/components/{p-effc1618.js → p-f3888e54.js} +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/lido-avatar_18.entry.js +26 -24
- package/dist/esm/{utils-f0e0b5c8.js → utils-29a54046.js} +2 -1
- package/dist/lido-player/index.esm.js +1 -1
- package/dist/lido-player/lido-player.esm.js +1 -1
- package/dist/lido-player/{p-918b6138.js → p-671f562c.js} +1 -1
- package/dist/lido-player/{p-169fbe16.entry.js → p-fe6ae561.entry.js} +1 -1
- package/package.json +1 -1
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-fe562525.js');
|
|
6
|
-
const utils = require('./utils-
|
|
6
|
+
const utils = require('./utils-3bd777d9.js');
|
|
7
7
|
|
|
8
8
|
var rive = {exports: {}};
|
|
9
9
|
|
|
@@ -7026,7 +7026,7 @@ const LidoFlash = class {
|
|
|
7026
7026
|
};
|
|
7027
7027
|
LidoFlash.style = LidoFlashCardStyle0;
|
|
7028
7028
|
|
|
7029
|
-
const lidoFloatCss = ".lido-float{position:relative}.lido-float>*{position:absolute;cursor:pointer}@keyframes float-up{from{top:var(--el-top)}to{top:-500px}}@keyframes float-lr{from{right:var(--el-left)}to{right:-500px}}";
|
|
7029
|
+
const lidoFloatCss = ".lido-float{position:relative}.lido-float>*{position:absolute;cursor:pointer}@keyframes float-up{from{top:var(--el-top)}to{top:-500px}}#removeShadow{box-shadow:unset !important}@keyframes float-lr{from{right:var(--el-left)}to{right:-500px}}";
|
|
7030
7030
|
const LidoFloatStyle0 = lidoFloatCss;
|
|
7031
7031
|
|
|
7032
7032
|
const LidoFloat = class {
|
|
@@ -7116,7 +7116,7 @@ const LidoHome = class {
|
|
|
7116
7116
|
if (index != undefined && index < this.containers.length) {
|
|
7117
7117
|
// Move to the next container
|
|
7118
7118
|
this.currentContainerIndex = index;
|
|
7119
|
-
console.log(
|
|
7119
|
+
console.log('container index ; ', this.currentContainerIndex);
|
|
7120
7120
|
// window.dispatchEvent(new CustomEvent('activityChange', { detail: { index: this.currentContainerIndex } }));
|
|
7121
7121
|
utils.dispatchActivityChangeEvent(this.currentContainerIndex);
|
|
7122
7122
|
}
|
|
@@ -7257,30 +7257,32 @@ const LidoHome = class {
|
|
|
7257
7257
|
});
|
|
7258
7258
|
}
|
|
7259
7259
|
async handleIcons() {
|
|
7260
|
+
var _a;
|
|
7260
7261
|
const checkUrl = async (url, containerUrl, fallback) => {
|
|
7261
|
-
if (!url && !containerUrl)
|
|
7262
|
-
|
|
7263
|
-
|
|
7264
|
-
|
|
7265
|
-
|
|
7266
|
-
|
|
7267
|
-
|
|
7268
|
-
|
|
7269
|
-
|
|
7270
|
-
|
|
7271
|
-
|
|
7272
|
-
|
|
7273
|
-
|
|
7274
|
-
|
|
7275
|
-
|
|
7276
|
-
|
|
7277
|
-
|
|
7262
|
+
// if (!url && !containerUrl) return fallback ?? false;
|
|
7263
|
+
if (url)
|
|
7264
|
+
return utils.convertUrlToRelative(url);
|
|
7265
|
+
if (containerUrl)
|
|
7266
|
+
return utils.convertUrlToRelative(containerUrl);
|
|
7267
|
+
return fallback !== null && fallback !== void 0 ? fallback : false;
|
|
7268
|
+
// try {
|
|
7269
|
+
// let res = await fetch(url);
|
|
7270
|
+
// if (res.ok && url) {
|
|
7271
|
+
// return url;
|
|
7272
|
+
// } else {
|
|
7273
|
+
// if (!containerUrl) return fallback ?? false;
|
|
7274
|
+
// res = await fetch(containerUrl);
|
|
7275
|
+
// return res.ok ? containerUrl : fallback ?? false;
|
|
7276
|
+
// }
|
|
7277
|
+
// } catch {
|
|
7278
|
+
// return fallback ?? false;
|
|
7279
|
+
// }
|
|
7278
7280
|
};
|
|
7279
7281
|
const container = document.getElementById(utils.LidoContainer);
|
|
7280
7282
|
const containerExit = container.getAttribute('exit-button-url');
|
|
7281
7283
|
const containerPrev = container.getAttribute('prev-button-url');
|
|
7282
7284
|
const containerNext = container.getAttribute('next-button-url');
|
|
7283
|
-
const containerSpeak = container.getAttribute('speak-button-url');
|
|
7285
|
+
const containerSpeak = (_a = container.getAttribute('speak-button-url')) !== null && _a !== void 0 ? _a : container.getAttribute('speaker-button-url');
|
|
7284
7286
|
this.navBarIcons = {
|
|
7285
7287
|
exit: `${await checkUrl(this.exitButtonUrl, containerExit, utils.exitUrl)}`,
|
|
7286
7288
|
prev: `${await checkUrl(this.prevButtonUrl, containerPrev, utils.prevUrl)}`,
|
|
@@ -11189,7 +11191,7 @@ const LidoTrace = class {
|
|
|
11189
11191
|
console.error('No SVG URL provided or index out of bounds.');
|
|
11190
11192
|
return;
|
|
11191
11193
|
}
|
|
11192
|
-
await this.fetchSVG(url);
|
|
11194
|
+
await this.fetchSVG(utils.convertUrlToRelative(url));
|
|
11193
11195
|
console.log('SVG fetched successfully\n');
|
|
11194
11196
|
await this.loadAnotherSVG(state, true); // Load the first SVG
|
|
11195
11197
|
}
|
|
@@ -11243,7 +11245,7 @@ const LidoTrace = class {
|
|
|
11243
11245
|
testImage.onerror = () => {
|
|
11244
11246
|
img.setAttributeNS('http://www.w3.org/1999/xlink', 'href', utils.convertUrlToRelative(utils.fingerUrl));
|
|
11245
11247
|
};
|
|
11246
|
-
testImage.src = this.fingerHintUrl || utils.fingerUrl;
|
|
11248
|
+
testImage.src = utils.convertUrlToRelative(this.fingerHintUrl || utils.fingerUrl);
|
|
11247
11249
|
img.setAttribute('width', `${IMG_SIZE}`);
|
|
11248
11250
|
img.setAttribute('height', `${IMG_SIZE}`);
|
|
11249
11251
|
img.setAttribute('id', 'lido-finger-hint');
|
|
@@ -11814,7 +11816,7 @@ const LidoTrace = class {
|
|
|
11814
11816
|
};
|
|
11815
11817
|
}
|
|
11816
11818
|
render() {
|
|
11817
|
-
return (index.h(index.Host, { key: '
|
|
11819
|
+
return (index.h(index.Host, { key: '16fb46d69a04aac108b4c21629210f3f31289ee4', class: "lido-trace", id: this.id, onCorrect: this.onCorrect, onInCorrect: this.onInCorrect, style: this.style, "aria-label": this.ariaLabel, "aria-hidden": this.ariaHidden, tabindex: this.tabIndex }, index.h("div", { key: '966e4f549b34e8c1f1886359527a36d81226ac9e', style: this.style, id: "lido-svgContainer" })));
|
|
11818
11820
|
}
|
|
11819
11821
|
static get assetsDirs() { return ["svg", "images"]; }
|
|
11820
11822
|
get el() { return index.getElement(this); }
|
|
@@ -67825,7 +67825,7 @@ async function handleElementClick(element) {
|
|
|
67825
67825
|
if (res) {
|
|
67826
67826
|
const onCorrect = container['onCorrect'];
|
|
67827
67827
|
await executeActions(onCorrect, container);
|
|
67828
|
-
|
|
67828
|
+
const fillValue = JSON.parse(fillElement['fill']);
|
|
67829
67829
|
if (fillValue === 100 && !fillCompleted) {
|
|
67830
67830
|
fillCompleted = true;
|
|
67831
67831
|
container.style.pointerEvents = 'none';
|
|
@@ -67876,6 +67876,7 @@ function handleFloatElementPosition(element) {
|
|
|
67876
67876
|
const duration = 5 + Math.random() * 5;
|
|
67877
67877
|
element.style.setProperty('--el-top', `${startTop}px`);
|
|
67878
67878
|
element.style.animation = `float-up ${duration}s linear ${delay}s`;
|
|
67879
|
+
element.id = 'removeShadow';
|
|
67879
67880
|
}
|
|
67880
67881
|
element.addEventListener('animationend', () => {
|
|
67881
67882
|
element.style.animation = 'none';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { h, Host } from "@stencil/core";
|
|
2
2
|
import { NextContainerKey, PrevContainerKey, LidoContainer, exitUrl, prevUrl, nextUrl, speakUrl, ActivityScoreKey, } from "../../utils/constants";
|
|
3
3
|
import { dispatchActivityChangeEvent, dispatchGameCompletedEvent, dispatchGameExitEvent } from "../../utils/customEvents";
|
|
4
|
-
import { clearLocalStorage, calculateScale, getCancelBtnPopup, setCancelBtnPopup, executeActions, triggerPrevcontainer } from "../../utils/utils";
|
|
4
|
+
import { clearLocalStorage, calculateScale, getCancelBtnPopup, setCancelBtnPopup, executeActions, triggerPrevcontainer, convertUrlToRelative } from "../../utils/utils";
|
|
5
5
|
import { AudioPlayer } from "../../utils/audioPlayer";
|
|
6
6
|
/**
|
|
7
7
|
* @component LidoHome
|
|
@@ -25,7 +25,7 @@ export class LidoHome {
|
|
|
25
25
|
if (index != undefined && index < this.containers.length) {
|
|
26
26
|
// Move to the next container
|
|
27
27
|
this.currentContainerIndex = index;
|
|
28
|
-
console.log(
|
|
28
|
+
console.log('container index ; ', this.currentContainerIndex);
|
|
29
29
|
// window.dispatchEvent(new CustomEvent('activityChange', { detail: { index: this.currentContainerIndex } }));
|
|
30
30
|
dispatchActivityChangeEvent(this.currentContainerIndex);
|
|
31
31
|
}
|
|
@@ -166,30 +166,32 @@ export class LidoHome {
|
|
|
166
166
|
});
|
|
167
167
|
}
|
|
168
168
|
async handleIcons() {
|
|
169
|
+
var _a;
|
|
169
170
|
const checkUrl = async (url, containerUrl, fallback) => {
|
|
170
|
-
if (!url && !containerUrl)
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
171
|
+
// if (!url && !containerUrl) return fallback ?? false;
|
|
172
|
+
if (url)
|
|
173
|
+
return convertUrlToRelative(url);
|
|
174
|
+
if (containerUrl)
|
|
175
|
+
return convertUrlToRelative(containerUrl);
|
|
176
|
+
return fallback !== null && fallback !== void 0 ? fallback : false;
|
|
177
|
+
// try {
|
|
178
|
+
// let res = await fetch(url);
|
|
179
|
+
// if (res.ok && url) {
|
|
180
|
+
// return url;
|
|
181
|
+
// } else {
|
|
182
|
+
// if (!containerUrl) return fallback ?? false;
|
|
183
|
+
// res = await fetch(containerUrl);
|
|
184
|
+
// return res.ok ? containerUrl : fallback ?? false;
|
|
185
|
+
// }
|
|
186
|
+
// } catch {
|
|
187
|
+
// return fallback ?? false;
|
|
188
|
+
// }
|
|
187
189
|
};
|
|
188
190
|
const container = document.getElementById(LidoContainer);
|
|
189
191
|
const containerExit = container.getAttribute('exit-button-url');
|
|
190
192
|
const containerPrev = container.getAttribute('prev-button-url');
|
|
191
193
|
const containerNext = container.getAttribute('next-button-url');
|
|
192
|
-
const containerSpeak = container.getAttribute('speak-button-url');
|
|
194
|
+
const containerSpeak = (_a = container.getAttribute('speak-button-url')) !== null && _a !== void 0 ? _a : container.getAttribute('speaker-button-url');
|
|
193
195
|
this.navBarIcons = {
|
|
194
196
|
exit: `${await checkUrl(this.exitButtonUrl, containerExit, exitUrl)}`,
|
|
195
197
|
prev: `${await checkUrl(this.prevButtonUrl, containerPrev, prevUrl)}`,
|
|
@@ -63,7 +63,7 @@ export class LidoTrace {
|
|
|
63
63
|
console.error('No SVG URL provided or index out of bounds.');
|
|
64
64
|
return;
|
|
65
65
|
}
|
|
66
|
-
const svgText = await this.fetchSVG(url);
|
|
66
|
+
const svgText = await this.fetchSVG(convertUrlToRelative(url));
|
|
67
67
|
console.log('SVG fetched successfully\n');
|
|
68
68
|
await this.loadAnotherSVG(state, true); // Load the first SVG
|
|
69
69
|
}
|
|
@@ -117,7 +117,7 @@ export class LidoTrace {
|
|
|
117
117
|
testImage.onerror = () => {
|
|
118
118
|
img.setAttributeNS('http://www.w3.org/1999/xlink', 'href', convertUrlToRelative(fingerUrl));
|
|
119
119
|
};
|
|
120
|
-
testImage.src = this.fingerHintUrl || fingerUrl;
|
|
120
|
+
testImage.src = convertUrlToRelative(this.fingerHintUrl || fingerUrl);
|
|
121
121
|
img.setAttribute('width', `${IMG_SIZE}`);
|
|
122
122
|
img.setAttribute('height', `${IMG_SIZE}`);
|
|
123
123
|
img.setAttribute('id', 'lido-finger-hint');
|
|
@@ -688,7 +688,7 @@ export class LidoTrace {
|
|
|
688
688
|
};
|
|
689
689
|
}
|
|
690
690
|
render() {
|
|
691
|
-
return (h(Host, { key: '
|
|
691
|
+
return (h(Host, { key: '16fb46d69a04aac108b4c21629210f3f31289ee4', class: "lido-trace", id: this.id, onCorrect: this.onCorrect, onInCorrect: this.onInCorrect, style: this.style, "aria-label": this.ariaLabel, "aria-hidden": this.ariaHidden, tabindex: this.tabIndex }, h("div", { key: '966e4f549b34e8c1f1886359527a36d81226ac9e', style: this.style, id: "lido-svgContainer" })));
|
|
692
692
|
}
|
|
693
693
|
static get is() { return "lido-trace"; }
|
|
694
694
|
static get originalStyleUrls() {
|
|
@@ -23,7 +23,7 @@ export async function handleElementClick(element) {
|
|
|
23
23
|
if (res) {
|
|
24
24
|
const onCorrect = container['onCorrect'];
|
|
25
25
|
await executeActions(onCorrect, container);
|
|
26
|
-
|
|
26
|
+
const fillValue = JSON.parse(fillElement['fill']);
|
|
27
27
|
if (fillValue === 100 && !fillCompleted) {
|
|
28
28
|
fillCompleted = true;
|
|
29
29
|
container.style.pointerEvents = 'none';
|
|
@@ -74,6 +74,7 @@ export function handleFloatElementPosition(element) {
|
|
|
74
74
|
const duration = 5 + Math.random() * 5;
|
|
75
75
|
element.style.setProperty('--el-top', `${startTop}px`);
|
|
76
76
|
element.style.animation = `float-up ${duration}s linear ${delay}s`;
|
|
77
|
+
element.id = 'removeShadow';
|
|
77
78
|
}
|
|
78
79
|
element.addEventListener('animationend', () => {
|
|
79
80
|
element.style.animation = 'none';
|
package/dist/components/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { f as format, g as getAssetPath, s as setAssetPath, a as setNonce, b as setPlatformOptions } from './p-
|
|
1
|
+
export { f as format, g as getAssetPath, s as setAssetPath, a as setNonce, b as setPlatformOptions } from './p-912a3fd1.js';
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, g as getAssetPath, h } from './p-
|
|
2
|
-
import { d as defineCustomElement$i } from './p-
|
|
3
|
-
import { d as defineCustomElement$h } from './p-
|
|
4
|
-
import { d as defineCustomElement$g } from './p-
|
|
5
|
-
import { d as defineCustomElement$f } from './p-
|
|
6
|
-
import { d as defineCustomElement$e } from './p-
|
|
7
|
-
import { d as defineCustomElement$d } from './p-
|
|
8
|
-
import { d as defineCustomElement$c } from './p-
|
|
9
|
-
import { d as defineCustomElement$b } from './p-
|
|
10
|
-
import { d as defineCustomElement$a } from './p-
|
|
11
|
-
import { d as defineCustomElement$9 } from './p-
|
|
12
|
-
import { d as defineCustomElement$8 } from './p-
|
|
13
|
-
import { d as defineCustomElement$7 } from './p-
|
|
14
|
-
import { d as defineCustomElement$6 } from './p-
|
|
15
|
-
import { d as defineCustomElement$5 } from './p-
|
|
16
|
-
import { d as defineCustomElement$4 } from './p-
|
|
17
|
-
import { d as defineCustomElement$3 } from './p-
|
|
18
|
-
import { d as defineCustomElement$2 } from './p-
|
|
1
|
+
import { p as proxyCustomElement, H, g as getAssetPath, h } from './p-912a3fd1.js';
|
|
2
|
+
import { d as defineCustomElement$i } from './p-f3888e54.js';
|
|
3
|
+
import { d as defineCustomElement$h } from './p-6f439433.js';
|
|
4
|
+
import { d as defineCustomElement$g } from './p-9a0d4b4d.js';
|
|
5
|
+
import { d as defineCustomElement$f } from './p-89ce7a02.js';
|
|
6
|
+
import { d as defineCustomElement$e } from './p-0da64fcd.js';
|
|
7
|
+
import { d as defineCustomElement$d } from './p-95965640.js';
|
|
8
|
+
import { d as defineCustomElement$c } from './p-2b7f6448.js';
|
|
9
|
+
import { d as defineCustomElement$b } from './p-43d05f49.js';
|
|
10
|
+
import { d as defineCustomElement$a } from './p-d0160fac.js';
|
|
11
|
+
import { d as defineCustomElement$9 } from './p-d3e62673.js';
|
|
12
|
+
import { d as defineCustomElement$8 } from './p-74d63405.js';
|
|
13
|
+
import { d as defineCustomElement$7 } from './p-7ca9b2ff.js';
|
|
14
|
+
import { d as defineCustomElement$6 } from './p-c204e882.js';
|
|
15
|
+
import { d as defineCustomElement$5 } from './p-806687ef.js';
|
|
16
|
+
import { d as defineCustomElement$4 } from './p-65eae7f7.js';
|
|
17
|
+
import { d as defineCustomElement$3 } from './p-688c02a0.js';
|
|
18
|
+
import { d as defineCustomElement$2 } from './p-a0e12946.js';
|
|
19
19
|
|
|
20
20
|
const LidoRoot$1 = /*@__PURE__*/ proxyCustomElement(class LidoRoot extends H {
|
|
21
21
|
constructor() {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, m as parseProp, d as setVisibilityWithDelay, i as initEventsForElement, h, j as Host } from './p-
|
|
1
|
+
import { p as proxyCustomElement, H, m as parseProp, d as setVisibilityWithDelay, i as initEventsForElement, h, j as Host } from './p-912a3fd1.js';
|
|
2
2
|
|
|
3
3
|
const lidoFlashCardCss = ".card{position:relative;width:100%;height:100%;transform-style:preserve-3d;transition:transform 0.6s ease;cursor:pointer}.card.flipped{transform:rotateY(180deg)}.card-face{position:absolute;width:100%;height:100%;backface-visibility:hidden;display:flex;align-items:center;justify-content:center}.card-back{transform:rotateY(180deg)}";
|
|
4
4
|
const LidoFlashCardStyle0 = lidoFlashCardCss;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, r as clearLocalStorage, t as dispatchActivityChangeEvent, A as ActivityScoreKey, u as dispatchGameCompletedEvent, v as dispatchGameExitEvent, w as AudioPlayer, x as exitUrl, y as prevUrl, z as nextUrl, B as speakUrl, N as NextContainerKey, P as PrevContainerKey, L as LidoContainer, h, C as getCancelBtnPopup, n as calculateScale, D as triggerPrevcontainer, E as executeActions, j as Host, F as setCancelBtnPopup } from './p-
|
|
2
|
-
import { d as defineCustomElement$g } from './p-
|
|
3
|
-
import { d as defineCustomElement$f } from './p-
|
|
4
|
-
import { d as defineCustomElement$e } from './p-
|
|
5
|
-
import { d as defineCustomElement$d } from './p-
|
|
6
|
-
import { d as defineCustomElement$c } from './p-
|
|
7
|
-
import { d as defineCustomElement$b } from './p-
|
|
8
|
-
import { d as defineCustomElement$a } from './p-
|
|
9
|
-
import { d as defineCustomElement$9 } from './p-
|
|
10
|
-
import { d as defineCustomElement$8 } from './p-
|
|
11
|
-
import { d as defineCustomElement$7 } from './p-
|
|
12
|
-
import { d as defineCustomElement$6 } from './p-
|
|
13
|
-
import { d as defineCustomElement$5 } from './p-
|
|
14
|
-
import { d as defineCustomElement$4 } from './p-
|
|
15
|
-
import { d as defineCustomElement$3 } from './p-
|
|
16
|
-
import { d as defineCustomElement$2 } from './p-
|
|
17
|
-
import { d as defineCustomElement$1 } from './p-
|
|
1
|
+
import { p as proxyCustomElement, H, r as clearLocalStorage, t as dispatchActivityChangeEvent, A as ActivityScoreKey, u as dispatchGameCompletedEvent, v as dispatchGameExitEvent, w as AudioPlayer, x as exitUrl, y as prevUrl, z as nextUrl, B as speakUrl, N as NextContainerKey, P as PrevContainerKey, L as LidoContainer, h, C as getCancelBtnPopup, n as calculateScale, D as triggerPrevcontainer, E as executeActions, j as Host, e as convertUrlToRelative, F as setCancelBtnPopup } from './p-912a3fd1.js';
|
|
2
|
+
import { d as defineCustomElement$g } from './p-f3888e54.js';
|
|
3
|
+
import { d as defineCustomElement$f } from './p-6f439433.js';
|
|
4
|
+
import { d as defineCustomElement$e } from './p-9a0d4b4d.js';
|
|
5
|
+
import { d as defineCustomElement$d } from './p-89ce7a02.js';
|
|
6
|
+
import { d as defineCustomElement$c } from './p-0da64fcd.js';
|
|
7
|
+
import { d as defineCustomElement$b } from './p-95965640.js';
|
|
8
|
+
import { d as defineCustomElement$a } from './p-43d05f49.js';
|
|
9
|
+
import { d as defineCustomElement$9 } from './p-d0160fac.js';
|
|
10
|
+
import { d as defineCustomElement$8 } from './p-d3e62673.js';
|
|
11
|
+
import { d as defineCustomElement$7 } from './p-74d63405.js';
|
|
12
|
+
import { d as defineCustomElement$6 } from './p-7ca9b2ff.js';
|
|
13
|
+
import { d as defineCustomElement$5 } from './p-c204e882.js';
|
|
14
|
+
import { d as defineCustomElement$4 } from './p-806687ef.js';
|
|
15
|
+
import { d as defineCustomElement$3 } from './p-65eae7f7.js';
|
|
16
|
+
import { d as defineCustomElement$2 } from './p-688c02a0.js';
|
|
17
|
+
import { d as defineCustomElement$1 } from './p-a0e12946.js';
|
|
18
18
|
|
|
19
19
|
const indexCss = "@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap'); @import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@400..800&display=swap'); @import url('https://fonts.googleapis.com/css2?family=Baloo+Bhai+2:wght@400..800&display=swap'); body{overflow:hidden;background-position:center;background-size:cover;background-repeat:no-repeat;height:100vh}*{user-select:none}.lido-disable-check-button{pointer-events:none;background-color:#9393935c !important;color:white}.lido-element-selected{border:2px solid;background-color:#ffdf7d !important}.diagonal-target,.diagonal-drop *{transform:scale(0.8) !important;opacity:1 !important}.cloned-element{display:flex !important;position:absolute !important;filter:grayscale(100%);pointer-events:none}.removeShadow{box-shadow:0px 0px 0px 0px #ff8900 !important}.highlight-element{border:2px solid white;box-shadow:0 2px 4px rgba(151, 150, 150, 0.1) !important}.drop-element.empty{border:4px dashed #f34d08 !important}.drop-element.filled{border:'none' !important}.drag-element{box-shadow:0px 15px 11px rgba(43, 0, 0, 0.3) !important}.drag-element.dropped{box-shadow:none !important}.click-element{background-color:var(--btn-bg-color, rgba(255, 172, 76, 1)) !important;box-shadow:var(--btn-shadow-px) var(--btn-shadow-color, rgba(225, 121, 76, 1)) !important;cursor:pointer;transition:box-shadow 0.1s ease-out, transform 0.2s ease-out;}.click-element:active{box-shadow:0px 0px 0px var(--btn-shadow-color, rgba(225, 121, 76, 1)) !important;transform:translateY(var(--btn-active));}.click-element:focus{outline:2px solid dodgerblue;outline-offset:3px}.after-drop-popup-container{width:200%;height:200%;background-color:rgba(0, 0, 0, 0.8);position:absolute;display:flex;flex-direction:row-reverse;align-items:center;justify-content:center !important;gap:80px}.after-drop-popup-drag-element{scale:1.5;border-radius:8px;transform:none !important;position:unset !important}.after-drop-popup-drop-element{scale:1.5;border:unset;border-radius:8px;transform:none !important;position:unset !important}@keyframes zoomFadeIn{0%{transform:scale(0.6);opacity:0}100%{transform:scale(1);opacity:1}}.zoom-fade-in{animation:zoomFadeIn 0.8s ease-out forwards}@keyframes zoomFadeOut{0%{transform:scale(1);opacity:1}100%{transform:scale(0.6);opacity:0}}.zoom-fade-out{animation:zoomFadeOut 0.8s ease-in forwards}.slide-numbers{width:70px;height:70px;border:1px solid #f57139;background-color:white;font-weight:500;color:#f57139;font-size:44px;border-radius:40px;display:flex;align-items:center;justify-content:center;font-family:'Baloo Bhai 2', serif}.slide-numbers-bottom{position:absolute;display:flex;justify-content:space-around;align-items:center;bottom:-25px;width:100%;height:50px}.slide-numbers-left{position:absolute;display:flex;flex-direction:column;justify-content:space-around;height:100%;width:50px;left:-25px;bottom:0px}.lido-speak-icon{width:56px;height:56px;position:absolute;top:-25px;right:-25px;z-index:10;background-image:url(\"https://aeakbcdznktpsbrfsgys.supabase.co/storage/v1/object/public/template-assets/template/audioIcon.png\");background-color:white;border:4px solid #F34D08;border-radius:16px;box-shadow:0px 4px 0px 0px #F34D08;background-size:contain;background-repeat:no-repeat;cursor:pointer}.lido-speak-icon:active{transform:translateY(8px);box-shadow:0px 0px 0px 0px !important}.lido-strong-shake{animation:strongShake 0.3s ease}.lido-scaled-shake{animation:scaledShake 0.6s ease-in-out}.lido-horizontal-shake{animation:horizontalShake 0.6s ease-in-out;border-radius:20px}.lido-vertical-shake{animation:verticalShake 0.6s ease-in-out;border-radius:20px}.lido-diagonal-shake{animation:diagonalShake 0.5s ease-in-out;border-radius:20px;will-change:transform}";
|
|
20
20
|
const LidoHomeStyle0 = indexCss;
|
|
@@ -42,7 +42,7 @@ const LidoHome = /*@__PURE__*/ proxyCustomElement(class LidoHome extends H {
|
|
|
42
42
|
if (index != undefined && index < this.containers.length) {
|
|
43
43
|
// Move to the next container
|
|
44
44
|
this.currentContainerIndex = index;
|
|
45
|
-
console.log(
|
|
45
|
+
console.log('container index ; ', this.currentContainerIndex);
|
|
46
46
|
// window.dispatchEvent(new CustomEvent('activityChange', { detail: { index: this.currentContainerIndex } }));
|
|
47
47
|
dispatchActivityChangeEvent(this.currentContainerIndex);
|
|
48
48
|
}
|
|
@@ -183,30 +183,32 @@ const LidoHome = /*@__PURE__*/ proxyCustomElement(class LidoHome extends H {
|
|
|
183
183
|
});
|
|
184
184
|
}
|
|
185
185
|
async handleIcons() {
|
|
186
|
+
var _a;
|
|
186
187
|
const checkUrl = async (url, containerUrl, fallback) => {
|
|
187
|
-
if (!url && !containerUrl)
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
188
|
+
// if (!url && !containerUrl) return fallback ?? false;
|
|
189
|
+
if (url)
|
|
190
|
+
return convertUrlToRelative(url);
|
|
191
|
+
if (containerUrl)
|
|
192
|
+
return convertUrlToRelative(containerUrl);
|
|
193
|
+
return fallback !== null && fallback !== void 0 ? fallback : false;
|
|
194
|
+
// try {
|
|
195
|
+
// let res = await fetch(url);
|
|
196
|
+
// if (res.ok && url) {
|
|
197
|
+
// return url;
|
|
198
|
+
// } else {
|
|
199
|
+
// if (!containerUrl) return fallback ?? false;
|
|
200
|
+
// res = await fetch(containerUrl);
|
|
201
|
+
// return res.ok ? containerUrl : fallback ?? false;
|
|
202
|
+
// }
|
|
203
|
+
// } catch {
|
|
204
|
+
// return fallback ?? false;
|
|
205
|
+
// }
|
|
204
206
|
};
|
|
205
207
|
const container = document.getElementById(LidoContainer);
|
|
206
208
|
const containerExit = container.getAttribute('exit-button-url');
|
|
207
209
|
const containerPrev = container.getAttribute('prev-button-url');
|
|
208
210
|
const containerNext = container.getAttribute('next-button-url');
|
|
209
|
-
const containerSpeak = container.getAttribute('speak-button-url');
|
|
211
|
+
const containerSpeak = (_a = container.getAttribute('speak-button-url')) !== null && _a !== void 0 ? _a : container.getAttribute('speaker-button-url');
|
|
210
212
|
this.navBarIcons = {
|
|
211
213
|
exit: `${await checkUrl(this.exitButtonUrl, containerExit, exitUrl)}`,
|
|
212
214
|
prev: `${await checkUrl(this.prevButtonUrl, containerPrev, prevUrl)}`,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as commonjsGlobal, G as getDefaultExportFromCjs, p as proxyCustomElement, H, d as setVisibilityWithDelay, i as initEventsForElement, I as tinyColor, l as attachSpeakIcon, m as parseProp, e as convertUrlToRelative, h, j as Host } from './p-
|
|
1
|
+
import { c as commonjsGlobal, G as getDefaultExportFromCjs, p as proxyCustomElement, H, d as setVisibilityWithDelay, i as initEventsForElement, I as tinyColor, l as attachSpeakIcon, m as parseProp, e as convertUrlToRelative, h, j as Host } from './p-912a3fd1.js';
|
|
2
2
|
|
|
3
3
|
var lib = {exports: {}};
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, d as setVisibilityWithDelay, i as initEventsForElement, l as attachSpeakIcon, e as convertUrlToRelative, m as parseProp, h, j as Host } from './p-
|
|
1
|
+
import { p as proxyCustomElement, H, d as setVisibilityWithDelay, i as initEventsForElement, l as attachSpeakIcon, e as convertUrlToRelative, m as parseProp, h, j as Host } from './p-912a3fd1.js';
|
|
2
2
|
|
|
3
3
|
const lidoTextCss = ".lido-text{transition:background-color 0.3s ease;user-select:none;align-items:center;justify-content:center;text-align:center;border-radius:24px;color:#333;cursor:pointer;font-family:'Baloo Bhai 2', serif}.text-letters{transition:color 0.3s, text-shadow 0.3s;display:inline-block;padding:0 2px}.text-letters.letter-highlight{color:#8e24aa;background:none;border-radius:0;text-shadow:0 2px 8px #8e24aa88;animation:text-letter-bounce 0.4s}.text-words{transition:color 0.3s, text-shadow 0.3s;display:inline-block;padding:0 2px}.text-words.word-highlight{color:#8e24aa;background:none;border-radius:0;text-shadow:0 2px 8px #8e24aa88;animation:text-word-bounce 0.4s}@keyframes text-letter-bounce{0%{transform:scale(1)}60%{transform:scale(1.4)}100%{transform:scale(1)}}@keyframes text-word-bounce{0%{transform:scale(1)}60%{transform:scale(1.3)}100%{transform:scale(1)}}";
|
|
4
4
|
const LidoTextStyle0 = lidoTextCss;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, T as TraceMode,
|
|
1
|
+
import { p as proxyCustomElement, H, T as TraceMode, e as convertUrlToRelative, d as setVisibilityWithDelay, Q as speakIcon, L as LidoContainer, E as executeActions, J as triggerNextContainer, m as parseProp, h, j as Host, U as fingerUrl } from './p-912a3fd1.js';
|
|
2
2
|
|
|
3
3
|
const lidoTraceCss = ":host{display:block;position:relative}#lido-svgContainer{display:flex;justify-content:center;align-items:center;overflow:hidden}svg{width:100%;height:100%;max-height:calc(100vh - 50px);touch-action:none}#lido-draggableCircle{cursor:pointer;fill:#CF1565;transition:fill 0.2s, r 0.2s}.lido-blindTracing{stroke:none !important}.lido-blindFreeTrace{stroke:none !important}.lido-hovered{cursor:grab;fill:darkred}#lido-controls{position:fixed;bottom:0;left:0;right:0;display:flex;justify-content:space-between;padding:10px;background-color:#f0f0f0;border-top:1px solid #ccc}button{padding:10px;font-size:16px}@media (max-width: 600px){button{padding:8px;font-size:14px}}.lido-trace-path-green{}.lido-flow-indicator{stroke:blue;stroke-width:2;stroke-dasharray:6, 6;fill:none}.lido-trace{height:700px;width:700px;z-index:1;justify-items:center;align-content:center}.trace-animate{animation:trace-bounce 0.5s}@keyframes trace-bounce{0%{transform:scale(1)}30%{transform:scale(1.05)}60%{transform:scale(0.95)}100%{transform:scale(1)}}";
|
|
4
4
|
const LidoTraceStyle0 = lidoTraceCss;
|
|
@@ -66,7 +66,7 @@ const LidoTrace = /*@__PURE__*/ proxyCustomElement(class LidoTrace extends H {
|
|
|
66
66
|
console.error('No SVG URL provided or index out of bounds.');
|
|
67
67
|
return;
|
|
68
68
|
}
|
|
69
|
-
await this.fetchSVG(url);
|
|
69
|
+
await this.fetchSVG(convertUrlToRelative(url));
|
|
70
70
|
console.log('SVG fetched successfully\n');
|
|
71
71
|
await this.loadAnotherSVG(state, true); // Load the first SVG
|
|
72
72
|
}
|
|
@@ -120,7 +120,7 @@ const LidoTrace = /*@__PURE__*/ proxyCustomElement(class LidoTrace extends H {
|
|
|
120
120
|
testImage.onerror = () => {
|
|
121
121
|
img.setAttributeNS('http://www.w3.org/1999/xlink', 'href', convertUrlToRelative(fingerUrl));
|
|
122
122
|
};
|
|
123
|
-
testImage.src = this.fingerHintUrl || fingerUrl;
|
|
123
|
+
testImage.src = convertUrlToRelative(this.fingerHintUrl || fingerUrl);
|
|
124
124
|
img.setAttribute('width', `${IMG_SIZE}`);
|
|
125
125
|
img.setAttribute('height', `${IMG_SIZE}`);
|
|
126
126
|
img.setAttribute('id', 'lido-finger-hint');
|
|
@@ -691,7 +691,7 @@ const LidoTrace = /*@__PURE__*/ proxyCustomElement(class LidoTrace extends H {
|
|
|
691
691
|
};
|
|
692
692
|
}
|
|
693
693
|
render() {
|
|
694
|
-
return (h(Host, { key: '
|
|
694
|
+
return (h(Host, { key: '16fb46d69a04aac108b4c21629210f3f31289ee4', class: "lido-trace", id: this.id, onCorrect: this.onCorrect, onInCorrect: this.onInCorrect, style: this.style, "aria-label": this.ariaLabel, "aria-hidden": this.ariaHidden, tabindex: this.tabIndex }, h("div", { key: '966e4f549b34e8c1f1886359527a36d81226ac9e', style: this.style, id: "lido-svgContainer" })));
|
|
695
695
|
}
|
|
696
696
|
static get assetsDirs() { return ["svg", "images"]; }
|
|
697
697
|
get el() { return this; }
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { p as proxyCustomElement, H, d as setVisibilityWithDelay, i as initEventsForElement, k as handlingChildElements, l as attachSpeakIcon, m as parseProp, h, j as Host } from './p-
|
|
1
|
+
import { p as proxyCustomElement, H, d as setVisibilityWithDelay, i as initEventsForElement, k as handlingChildElements, l as attachSpeakIcon, m as parseProp, h, j as Host } from './p-912a3fd1.js';
|
|
2
2
|
|
|
3
3
|
const lidoCellCss = ".lido-col{top:var(--y, 0);left:var(--x, 0);height:var(--height, 100%);width:var(--width, 100%);background-color:var(--bgColor, #eeeeee);padding:15px;border-radius:10px;display:flex;justify-content:space-around;flex-direction:column;align-items:center}.lido-col>*{}.lido-row{display:flex;justify-content:space-around;align-items:center;}.lido-row>*{}.lido-wrap{display:grid;grid-gap:10px;grid-template-columns:repeat(auto-fill, minmax(186px, auto))}.lido-wrap>*{padding:10px;box-sizing:border-box}.lido-flex{display:flex;flex-wrap:wrap;align-content:flex-start;gap:10px}.lido-pos{top:var(--y, 0);left:var(--x, 0);height:var(--height, 100%);width:var(--width, 100%);background-color:var(--bgColor, #eeeeee);display:flex;justify-content:space-around;flex-direction:column;position:fixed}.lido-pos>*{position:absolute}.lido-random{position:relative;width:100%;height:100%}.lido-random>*{position:absolute}.lido-col::-webkit-scrollbar,.lido-wrap::-webkit-scrollbar,.lido-flex::-webkit-scrollbar{width:var(--scrollbar-width);height:var(--scrollbar-width)}.lido-col::-webkit-scrollbar-thumb,.lido-wrap::-webkit-scrollbar-thumb,.lido-flex::-webkit-scrollbar-thumb{background-color:#888;border-radius:10px;border:3px solid transparent;background-clip:content-box}.lido-col::-webkit-scrollbar-track,.lido-wrap::-webkit-scrollbar-track,.lido-flex::-webkit-scrollbar-track{background:#f1f1f1}";
|
|
4
4
|
const LidoCellStyle0 = lidoCellCss;
|