bloom-player 2.11.2 → 2.11.4
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/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "A library for displaying Bloom books in iframes or WebViews",
|
|
4
4
|
"author": "SIL Global",
|
|
5
5
|
"license": "MIT",
|
|
6
|
-
"version": "2.11.
|
|
6
|
+
"version": "2.11.4",
|
|
7
7
|
"private": false,
|
|
8
8
|
"// sideeffects might need to be ['*.css'] to avoid 'shaking' our CSS, if we ever get tree shaking working": "",
|
|
9
9
|
"sideEffects": false,
|
|
@@ -253,11 +253,7 @@ const prepareOrderSentenceActivity = (page: HTMLElement) => {
|
|
|
253
253
|
makeWordItems(page, shuffledWords, container, contentElt, true);
|
|
254
254
|
container.style.left = elt.style.left;
|
|
255
255
|
container.style.top = elt.style.top;
|
|
256
|
-
container.style.width =
|
|
257
|
-
elt.parentElement!.offsetWidth - elt.offsetLeft - 10 + "px";
|
|
258
|
-
// Enhance: limit width somehow so it does not collide with other elements?
|
|
259
|
-
// Maybe now we tweaked word padding to make the original sentence take up more
|
|
260
|
-
// space, we could use its own width?
|
|
256
|
+
container.style.width = elt.style.width;
|
|
261
257
|
elt.parentElement?.insertBefore(container, elt);
|
|
262
258
|
},
|
|
263
259
|
);
|
|
@@ -565,6 +561,7 @@ const showCorrect = (e: MouseEvent) => {
|
|
|
565
561
|
if (!currentPage) {
|
|
566
562
|
return; // huh?? but makes TS happy
|
|
567
563
|
}
|
|
564
|
+
restorePositions(); // any distractors return to start positions.
|
|
568
565
|
currentPage
|
|
569
566
|
.querySelectorAll("[data-draggable-id]")
|
|
570
567
|
.forEach((elt: HTMLElement) => {
|