lido-player 0.0.2-beta-02 → 0.0.2-beta-04
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/{decode-BvT284iq.js → decode-BIc1HvkD.js} +1 -1
- package/dist/cjs/{index-BhikEYm-.js → index-DuRRRFVg.js} +106 -15
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/lido-avatar_22.cjs.entry.js +140 -38
- package/dist/cjs/lido-player.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/canvas/lido-canvas.js +1 -1
- 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 +1 -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 +98 -7
- package/dist/collection/components/keyboard/lido-keyboard.js +2 -2
- package/dist/collection/components/mathMatrix/lido-math-matrix.js +1 -1
- package/dist/collection/components/position/lido-pos.js +1 -1
- package/dist/collection/components/random/lido-random.js +1 -1
- package/dist/collection/components/root/lido-root.js +30 -6
- package/dist/collection/components/row/lido-row.js +1 -1
- package/dist/collection/components/scale/lido-balance.js +1 -1
- package/dist/collection/components/shape/lido-shape.js +2 -2
- package/dist/collection/components/slideFill/lido-slide-fill.js +1 -1
- package/dist/collection/components/text/lido-text.js +1 -1
- package/dist/collection/components/trace/lido-trace.js +1 -1
- package/dist/collection/components/wrap/lido-wrap.js +1 -1
- package/dist/collection/utils/audioPlayer.js +0 -2
- package/dist/collection/utils/constants.js +8 -2
- package/dist/collection/utils/customEvents.js +40 -5
- package/dist/collection/utils/i18n.js +2 -2
- package/dist/collection/utils/utils.js +54 -5
- package/dist/collection/utils/utilsHandlers/highlightHandler.js +2 -2
- package/dist/components/index.js +1 -1
- package/dist/components/lido-avatar.js +1 -1
- package/dist/components/lido-balance.js +1 -1
- package/dist/components/lido-calculator.js +1 -1
- package/dist/components/lido-canvas.js +1 -1
- package/dist/components/lido-cell.js +1 -1
- package/dist/components/lido-col.js +1 -1
- package/dist/components/lido-container.js +1 -1
- package/dist/components/lido-flash-card.js +1 -1
- package/dist/components/lido-float.js +1 -1
- package/dist/components/lido-home.js +1 -1
- package/dist/components/lido-image.js +1 -1
- package/dist/components/lido-keyboard.js +1 -1
- package/dist/components/lido-math-matrix.js +1 -1
- package/dist/components/lido-pos.js +1 -1
- package/dist/components/lido-random.js +1 -1
- package/dist/components/lido-root.js +1 -1
- package/dist/components/lido-row.js +1 -1
- package/dist/components/lido-shape.js +1 -1
- package/dist/components/lido-slide-fill.js +1 -1
- package/dist/components/lido-text.js +1 -1
- package/dist/components/lido-trace.js +1 -1
- package/dist/components/lido-wrap.js +1 -1
- package/dist/components/{p-CusU-d3G.js → p-04xe3uUh.js} +1 -1
- package/dist/components/p-2ox8u4JO.js +1 -0
- package/dist/components/{p-Cvme8ibO.js → p-9181ML6I.js} +1 -1
- package/dist/components/{p-5cqqnSZl.js → p-BD1sZ63-.js} +1 -1
- package/dist/components/{p-WP-EeUIB.js → p-BHrmIag4.js} +1 -1
- package/dist/components/p-BsHyhW7k.js +1 -0
- package/dist/components/{p-Blfvc5ur.js → p-C5Gn0SKo.js} +1 -1
- package/dist/components/p-C7tEzlkQ.js +1 -0
- package/dist/components/p-CADVkDjz.js +1 -0
- package/dist/components/{p-BY1E9s1O.js → p-COBnIJEZ.js} +1 -1
- package/dist/components/{p-q6x112RN.js → p-CwDTdXe5.js} +1 -1
- package/dist/components/{p-CfdL3fZ9.js → p-D-B1groh.js} +1 -1
- package/dist/components/{p-D4JZI_JB.js → p-D0bKCljc.js} +1 -1
- package/dist/components/{p-Czy5pBTg.js → p-D62lkidF.js} +1 -1
- package/dist/components/{p-1qOeKb23.js → p-DOERS2Qe.js} +1 -1
- package/dist/components/{p-1PmJa9_u.js → p-DPAlnts-.js} +1 -1
- package/dist/components/{p-De6WHLEQ.js → p-DU-N8vrM.js} +1 -1
- package/dist/components/{p-yHq43npj.js → p-D_BBs_vA.js} +1 -1
- package/dist/components/p-I53930CY.js +1 -0
- package/dist/components/{p-DqskvXvD.js → p-JN426a_v.js} +1 -1
- package/dist/components/p-iNMFyxvU.js +1 -0
- package/dist/components/p-igIX0BGC.js +12 -0
- package/dist/esm/{decode-B2R73LQH.js → decode-MJThiDx2.js} +1 -1
- package/dist/esm/{index-C1lqv26k.js → index-K2hcd53I.js} +104 -15
- package/dist/esm/index.js +1 -1
- package/dist/esm/lido-avatar_22.entry.js +140 -38
- package/dist/esm/lido-player.js +1 -1
- package/dist/esm/loader.js +1 -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-4385c137.entry.js +12 -0
- package/dist/lido-player/p-BJqlkwHq.js +1 -0
- package/dist/lido-player/{p-C61UwQXx.js → p-OfmKwIbR.js} +1 -1
- package/dist/types/components/home/lido-home.d.ts +9 -0
- package/dist/types/components/root/lido-root.d.ts +4 -0
- package/dist/types/components.d.ts +22 -0
- package/dist/types/utils/constants.d.ts +8 -2
- package/dist/types/utils/customEvents.d.ts +16 -2
- package/dist/types/utils/utils.d.ts +4 -0
- package/package.json +2 -1
- package/dist/components/p-B97yn0-n.js +0 -1
- package/dist/components/p-BLx2hZ8d.js +0 -1
- package/dist/components/p-BOTEFjDY.js +0 -1
- package/dist/components/p-CYA3cHAL.js +0 -1
- package/dist/components/p-DFnbzZUc.js +0 -1
- package/dist/components/p-DWnRy2OX.js +0 -1
- package/dist/components/p-XacgbiAe.js +0 -1
- package/dist/lido-player/p-DLiAHqUu.js +0 -1
- package/dist/lido-player/p-b98f209c.entry.js +0 -1
|
@@ -22,6 +22,10 @@ const LIDO_COMMON_AUDIO_PATH = '__LIDO_COMMON_AUDIO_PATH__';
|
|
|
22
22
|
const LIDO_COMMON_AUDIO_READY_EVENT = 'lidoCommonAudioPathReady';
|
|
23
23
|
const TemplateID = 'template-id';
|
|
24
24
|
const CalculatorOk = 'calculator-ok';
|
|
25
|
+
const MicroProblemEndKey = 'problemEnd';
|
|
26
|
+
const MicroLessonEndKey = 'lessonEnd';
|
|
27
|
+
const MicroGameEndKey = 'gameEnd';
|
|
28
|
+
const MicroGameExitKey = 'gameExit';
|
|
25
29
|
exports.TraceMode = void 0;
|
|
26
30
|
(function (TraceMode) {
|
|
27
31
|
TraceMode["NoFlow"] = "noFlow";
|
|
@@ -32,6 +36,8 @@ exports.TraceMode = void 0;
|
|
|
32
36
|
})(exports.TraceMode || (exports.TraceMode = {}));
|
|
33
37
|
class GameScore {
|
|
34
38
|
constructor() {
|
|
39
|
+
this.totalRightMovesCount = 0;
|
|
40
|
+
this.totalWrongMovesCount = 0;
|
|
35
41
|
this.rightMoves = 0;
|
|
36
42
|
this.wrongMoves = 0;
|
|
37
43
|
this.finalScore = 0;
|
|
@@ -69,7 +75,7 @@ const FAST_WORDS_BY_LANG = {
|
|
|
69
75
|
'तो', 'को',
|
|
70
76
|
'है', 'था', 'थे',
|
|
71
77
|
]),
|
|
72
|
-
'
|
|
78
|
+
'kn': new Set([
|
|
73
79
|
'ಅದು', 'ಇದು',
|
|
74
80
|
'ನಲ್ಲಿ', 'ಮೇಲೆ',
|
|
75
81
|
'ಮತ್ತು', 'ಇದೆ',
|
|
@@ -97,7 +103,7 @@ const LANGUAGE_PROFILES = {
|
|
|
97
103
|
fastWordMultiplier: 0.9, // much weaker compression
|
|
98
104
|
fastClusterMultiplier: 0.9,
|
|
99
105
|
},
|
|
100
|
-
'
|
|
106
|
+
'kn': {
|
|
101
107
|
expectedWPM: 85,
|
|
102
108
|
minWordMs: 35,
|
|
103
109
|
syllableWeight: 1.75,
|
|
@@ -110,15 +116,38 @@ const LANGUAGE_PROFILES = {
|
|
|
110
116
|
};
|
|
111
117
|
|
|
112
118
|
function dispatchCustomEvent(eventName, detail) {
|
|
119
|
+
var _a;
|
|
113
120
|
console.log("👍Event Name : ", eventName, "Detail : ", detail.toString());
|
|
114
121
|
const event = new CustomEvent(eventName, { detail });
|
|
115
122
|
window.dispatchEvent(event);
|
|
123
|
+
if (eventName === ActivityEndKey || eventName === LessonEndKey || eventName === GameCompletedKey || eventName === GameExitKey || eventName === MicroGameEndKey || eventName === MicroGameExitKey || eventName === MicroLessonEndKey || eventName === MicroProblemEndKey) {
|
|
124
|
+
(_a = window.parent) === null || _a === void 0 ? void 0 : _a.postMessage({
|
|
125
|
+
eventName,
|
|
126
|
+
detail: toSerializableDetail(detail),
|
|
127
|
+
}, "*");
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
function toSerializableDetail(detail) {
|
|
131
|
+
if (!detail || typeof detail !== 'object')
|
|
132
|
+
return detail;
|
|
133
|
+
return Object.fromEntries(Object.entries(detail).filter(([, value]) => {
|
|
134
|
+
return (value === null ||
|
|
135
|
+
['string', 'number', 'boolean', 'undefined'].includes(typeof value) ||
|
|
136
|
+
Array.isArray(value) ||
|
|
137
|
+
(typeof value === 'object' && value.constructor === Object));
|
|
138
|
+
}));
|
|
116
139
|
}
|
|
117
|
-
function dispatchActivityEndEvent(totalIndex, currentIndex, score, rightMoves, wrongMoves, timeSpentForActivity) {
|
|
118
|
-
dispatchCustomEvent(ActivityEndKey, { currentIndex, totalIndex, score, rightMoves, wrongMoves, timeSpentForActivity });
|
|
140
|
+
function dispatchActivityEndEvent(totalIndex, currentIndex, score, rightMoves, wrongMoves, timeSpentForActivity, lessonTrackingParams, gameCompleted) {
|
|
141
|
+
dispatchCustomEvent(ActivityEndKey, Object.assign(Object.assign({ currentIndex, totalIndex, score, rightMoves, wrongMoves, timeSpentForActivity }, lessonTrackingParams), { gameCompleted }));
|
|
142
|
+
dispatchCustomEvent(MicroProblemEndKey, Object.assign(Object.assign({ currentIndex, totalIndex, score, rightMoves, wrongMoves, timeSpentForActivity }, lessonTrackingParams), { gameCompleted }));
|
|
119
143
|
}
|
|
120
|
-
function dispatchLessonEndEvent(totalIndex, rightMoves, wrongMoves, finalScore, timeSpendForLesson) {
|
|
121
|
-
dispatchCustomEvent(
|
|
144
|
+
function dispatchLessonEndEvent(totalIndex, rightMoves, wrongMoves, finalScore, timeSpendForLesson, lessonTrackingParams) {
|
|
145
|
+
dispatchCustomEvent(MicroLessonEndKey, Object.assign({ totalIndex, rightMoves, wrongMoves, finalScore, score: finalScore, timeSpendForLesson }, lessonTrackingParams));
|
|
146
|
+
if (getLessonTrackingParams().end === "blank" || getLessonTrackingParams().end === "complete" || getLessonTrackingParams().end === "completed") {
|
|
147
|
+
console.log("Lesson end event skipped. Reason: Lesson end type is set to 'blank' in lesson tracking parameters.");
|
|
148
|
+
return;
|
|
149
|
+
}
|
|
150
|
+
dispatchCustomEvent(LessonEndKey, Object.assign({ totalIndex, rightMoves, wrongMoves, finalScore, score: finalScore, timeSpendForLesson }, lessonTrackingParams));
|
|
122
151
|
}
|
|
123
152
|
function dispatchNextContainerEvent() {
|
|
124
153
|
dispatchCustomEvent(NextContainerKey, {});
|
|
@@ -127,9 +156,19 @@ function dispatchPrevContainerEvent() {
|
|
|
127
156
|
dispatchCustomEvent(PrevContainerKey, {});
|
|
128
157
|
}
|
|
129
158
|
function dispatchGameCompletedEvent() {
|
|
159
|
+
dispatchCustomEvent(MicroGameEndKey, {});
|
|
160
|
+
if (getLessonTrackingParams().end === "blank" || getLessonTrackingParams().end === "complete" || getLessonTrackingParams().end === "completed") {
|
|
161
|
+
console.log("Game end event skipped. Reason: Lesson end type is set to 'blank' in lesson tracking parameters.");
|
|
162
|
+
return;
|
|
163
|
+
}
|
|
130
164
|
dispatchCustomEvent(GameCompletedKey, {});
|
|
131
165
|
}
|
|
132
166
|
function dispatchGameExitEvent() {
|
|
167
|
+
dispatchCustomEvent(MicroGameExitKey, {});
|
|
168
|
+
if (getLessonTrackingParams().end === "blank" || getLessonTrackingParams().end === "complete" || getLessonTrackingParams().end === "completed") {
|
|
169
|
+
console.log("Game exit event skipped. Reason: Lesson end type is set to 'blank' in lesson tracking parameters.");
|
|
170
|
+
return;
|
|
171
|
+
}
|
|
133
172
|
dispatchCustomEvent(GameExitKey, {});
|
|
134
173
|
}
|
|
135
174
|
function dispatchActivityChangeEvent(index) {
|
|
@@ -141,6 +180,7 @@ function dispatchElementDropEvent(dragElement, dropElement, isCorrect) {
|
|
|
141
180
|
function dispatchClickEvent(element, isCorrect) {
|
|
142
181
|
dispatchCustomEvent(ElementClickKey, { element, isCorrect: isCorrect, createdAt: new Date().toISOString() });
|
|
143
182
|
}
|
|
183
|
+
// for nipun - to dispatch custom event
|
|
144
184
|
|
|
145
185
|
// rive-service.ts
|
|
146
186
|
class RiveService {
|
|
@@ -1267,8 +1307,8 @@ function highlightSpeakingElement(element) {
|
|
|
1267
1307
|
// Add a custom class for highlighting
|
|
1268
1308
|
element.classList.add('speaking-highlight');
|
|
1269
1309
|
// Inject keyframe animation and class styles into the document's head if it doesn't already exist
|
|
1270
|
-
const styleId = '
|
|
1271
|
-
if (!document.
|
|
1310
|
+
const styleId = 'speaking-highlight-style';
|
|
1311
|
+
if (!document.getElementById(styleId)) {
|
|
1272
1312
|
const style = document.createElement('style');
|
|
1273
1313
|
style.id = styleId;
|
|
1274
1314
|
style.innerHTML = `
|
|
@@ -1393,8 +1433,6 @@ class AudioPlayer {
|
|
|
1393
1433
|
await this.stop(true);
|
|
1394
1434
|
};
|
|
1395
1435
|
this.audioElement = document.createElement('audio');
|
|
1396
|
-
this.audioElement.id = 'audio';
|
|
1397
|
-
document.body.appendChild(this.audioElement);
|
|
1398
1436
|
this.registerGlobalStopEvents();
|
|
1399
1437
|
this.registerVisibilityEvents();
|
|
1400
1438
|
}
|
|
@@ -4617,6 +4655,8 @@ _extends(config$1, DEFAULT_CONFIG, {
|
|
|
4617
4655
|
NUMBER_OPTIONS
|
|
4618
4656
|
});
|
|
4619
4657
|
|
|
4658
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4659
|
+
|
|
4620
4660
|
function getDefaultExportFromCjs (x) {
|
|
4621
4661
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
4622
4662
|
}
|
|
@@ -72861,6 +72901,8 @@ const calculateScore = () => {
|
|
|
72861
72901
|
}
|
|
72862
72902
|
const rightMoves = gameScore.rightMoves;
|
|
72863
72903
|
const wrongMoves = gameScore.wrongMoves;
|
|
72904
|
+
gameScore.totalRightMovesCount += rightMoves;
|
|
72905
|
+
gameScore.totalWrongMovesCount += wrongMoves;
|
|
72864
72906
|
let finalScore = Math.floor((rightMoves / (rightMoves + wrongMoves)) * 100);
|
|
72865
72907
|
storeActivityScore(finalScore);
|
|
72866
72908
|
gameScore.rightMoves = 0;
|
|
@@ -72928,6 +72970,24 @@ async function onActivityComplete(dragElement, dropElement) {
|
|
|
72928
72970
|
});
|
|
72929
72971
|
handleShowCheck();
|
|
72930
72972
|
}
|
|
72973
|
+
const getLessonTrackingParams = () => {
|
|
72974
|
+
const urlParams = new URLSearchParams(window.location.search);
|
|
72975
|
+
const getParam = (key) => { var _a, _b; return (_b = (_a = urlParams.get(key.toLowerCase())) !== null && _a !== void 0 ? _a : urlParams.get(key)) !== null && _b !== void 0 ? _b : ''; };
|
|
72976
|
+
return {
|
|
72977
|
+
studentId: getParam('studentId'),
|
|
72978
|
+
studentName: getParam('studentName'),
|
|
72979
|
+
classId: getParam('classId'),
|
|
72980
|
+
schoolId: getParam('schoolId'),
|
|
72981
|
+
courseId: getParam('courseId'),
|
|
72982
|
+
courseName: getParam('courseName'),
|
|
72983
|
+
chapterId: getParam('chapterId'),
|
|
72984
|
+
chapterName: getParam('chapterName'),
|
|
72985
|
+
lessonId: getParam('lessonId'),
|
|
72986
|
+
lessonName: getParam('lessonName'),
|
|
72987
|
+
lang: getParam('lang'),
|
|
72988
|
+
end: getParam('end'),
|
|
72989
|
+
};
|
|
72990
|
+
};
|
|
72931
72991
|
const storeActivityScore = (score) => {
|
|
72932
72992
|
var _a, _b, _c;
|
|
72933
72993
|
const appHome = document.querySelector('lido-home');
|
|
@@ -72942,7 +73002,9 @@ const storeActivityScore = (score) => {
|
|
|
72942
73002
|
// window.dispatchEvent(new CustomEvent(ActivityEndKey, { detail: { index: index, totalIndex: totalIndex, score: score } }));
|
|
72943
73003
|
const timeSpendForActivity = Math.floor(Timer.getI().getElapsed() / 1000);
|
|
72944
73004
|
ACTIVYTY_TIME_SPEND_ARRAY.push(timeSpendForActivity);
|
|
72945
|
-
|
|
73005
|
+
const lessonTrackingParams = getLessonTrackingParams();
|
|
73006
|
+
console.log("lessontracking params : ", lessonTrackingParams);
|
|
73007
|
+
dispatchActivityEndEvent(totalIndex, index, score, gameScore.rightMoves, gameScore.wrongMoves, timeSpendForActivity, lessonTrackingParams, true);
|
|
72946
73008
|
localStorage.setItem(ActivityScoreKey, JSON.stringify(activityScore));
|
|
72947
73009
|
if (totalIndex - 1 == index) {
|
|
72948
73010
|
const scoresArray = Object.values(activityScore);
|
|
@@ -72951,7 +73013,10 @@ const storeActivityScore = (score) => {
|
|
|
72951
73013
|
console.log('Total Score : ', gameScore.finalScore);
|
|
72952
73014
|
// window.dispatchEvent(new CustomEvent(LessonEndKey, { detail: { score: finalScore } }));
|
|
72953
73015
|
const timeSpendForLesson = ACTIVYTY_TIME_SPEND_ARRAY.reduce((sum, current) => sum + current, 0);
|
|
72954
|
-
dispatchLessonEndEvent(totalIndex, gameScore.
|
|
73016
|
+
dispatchLessonEndEvent(totalIndex, gameScore.totalRightMovesCount, gameScore.totalWrongMovesCount, finalScore, timeSpendForLesson, lessonTrackingParams);
|
|
73017
|
+
gameScore.totalRightMovesCount = 0;
|
|
73018
|
+
gameScore.totalWrongMovesCount = 0;
|
|
73019
|
+
dispatchGameCompletedEvent();
|
|
72955
73020
|
localStorage.removeItem(ActivityScoreKey);
|
|
72956
73021
|
}
|
|
72957
73022
|
};
|
|
@@ -73141,6 +73206,11 @@ const triggerNextContainer = () => {
|
|
|
73141
73206
|
// const event = new CustomEvent('nextContainer');
|
|
73142
73207
|
console.log('🚀 ~ triggerNextContainer ~ event:', event);
|
|
73143
73208
|
// window.dispatchEvent(event);
|
|
73209
|
+
const lidoHome = document.querySelector('.lido-home');
|
|
73210
|
+
if (lidoHome && (getLessonTrackingParams().end === "blank" || getLessonTrackingParams().end === "complete" || getLessonTrackingParams().end === "completed") && Number(lidoHome.getAttribute('index')) >= Number(lidoHome.getAttribute('totalIndex')) - 1) {
|
|
73211
|
+
console.log('🚀 ~ triggerNextContainer ~ lidoHome:', lidoHome);
|
|
73212
|
+
return;
|
|
73213
|
+
}
|
|
73144
73214
|
dispatchNextContainerEvent();
|
|
73145
73215
|
};
|
|
73146
73216
|
const triggerPrevcontainer = () => {
|
|
@@ -73148,16 +73218,35 @@ const triggerPrevcontainer = () => {
|
|
|
73148
73218
|
console.log('⬅️ ~ triggerPrevContainer triggered');
|
|
73149
73219
|
dispatchPrevContainerEvent();
|
|
73150
73220
|
};
|
|
73221
|
+
let activeZipAssets;
|
|
73222
|
+
function setActiveZipAssets(zipAssets) {
|
|
73223
|
+
activeZipAssets = zipAssets;
|
|
73224
|
+
}
|
|
73225
|
+
function clearActiveZipAssets() {
|
|
73226
|
+
activeZipAssets = undefined;
|
|
73227
|
+
}
|
|
73151
73228
|
function convertUrlToRelative(url) {
|
|
73152
73229
|
const container = document.getElementById(LidoContainer);
|
|
73153
|
-
const baseUrl = container.getAttribute('baseUrl');
|
|
73230
|
+
const baseUrl = container === null || container === void 0 ? void 0 : container.getAttribute('baseUrl');
|
|
73231
|
+
const zipAssets = activeZipAssets;
|
|
73154
73232
|
if ((url === null || url === void 0 ? void 0 : url.startsWith('http')) || (url === null || url === void 0 ? void 0 : url.startsWith('blob')) || (url === null || url === void 0 ? void 0 : url.startsWith('data'))) {
|
|
73155
73233
|
return url;
|
|
73156
73234
|
}
|
|
73157
73235
|
if (url.startsWith('/Lido-CommonAudios/')) {
|
|
73158
73236
|
return url;
|
|
73159
73237
|
}
|
|
73160
|
-
if (
|
|
73238
|
+
if (zipAssets) {
|
|
73239
|
+
const normalizedUrl = url.replace(/^\.\/?/, '');
|
|
73240
|
+
const directMatch = zipAssets[url] || zipAssets[normalizedUrl];
|
|
73241
|
+
if (directMatch) {
|
|
73242
|
+
return directMatch;
|
|
73243
|
+
}
|
|
73244
|
+
const suffixMatch = Object.keys(zipAssets).find(assetKey => assetKey === normalizedUrl || assetKey.endsWith(`/${normalizedUrl}`));
|
|
73245
|
+
if (suffixMatch) {
|
|
73246
|
+
return zipAssets[suffixMatch];
|
|
73247
|
+
}
|
|
73248
|
+
}
|
|
73249
|
+
if (!zipAssets && baseUrl) {
|
|
73161
73250
|
const newUrl = url.startsWith('/') ? url.slice(1) : url;
|
|
73162
73251
|
if (newUrl.startsWith(baseUrl.replace(/^\/+|\/+$/g, '')))
|
|
73163
73252
|
return newUrl;
|
|
@@ -73836,9 +73925,10 @@ exports.Timer = Timer;
|
|
|
73836
73925
|
exports.attachSpeakIcon = attachSpeakIcon;
|
|
73837
73926
|
exports.calculateScale = calculateScale;
|
|
73838
73927
|
exports.calculateScore = calculateScore;
|
|
73928
|
+
exports.clearActiveZipAssets = clearActiveZipAssets;
|
|
73929
|
+
exports.commonjsGlobal = commonjsGlobal;
|
|
73839
73930
|
exports.convertUrlToRelative = convertUrlToRelative;
|
|
73840
73931
|
exports.dispatchActivityChangeEvent = dispatchActivityChangeEvent;
|
|
73841
|
-
exports.dispatchGameCompletedEvent = dispatchGameCompletedEvent;
|
|
73842
73932
|
exports.dispatchGameExitEvent = dispatchGameExitEvent;
|
|
73843
73933
|
exports.equationCheck = equationCheck;
|
|
73844
73934
|
exports.executeActions = executeActions;
|
|
@@ -73859,6 +73949,7 @@ exports.nextUrl = nextUrl;
|
|
|
73859
73949
|
exports.parseProp = parseProp;
|
|
73860
73950
|
exports.prevUrl = prevUrl;
|
|
73861
73951
|
exports.resetFloatState = resetFloatState;
|
|
73952
|
+
exports.setActiveZipAssets = setActiveZipAssets;
|
|
73862
73953
|
exports.setCancelBtnPopup = setCancelBtnPopup;
|
|
73863
73954
|
exports.setVisibilityWithDelay = setVisibilityWithDelay;
|
|
73864
73955
|
exports.speakIcon = speakIcon;
|