@shower/core 3.4.0 → 3.4.1
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/index.js +9 -7
- package/lib/modules/view.js +8 -6
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Core for Shower HTML presentation engine
|
|
3
|
-
* @shower/core v3.
|
|
3
|
+
* @shower/core v3.4.0, https://github.com/shower/shower/tree/main/packages/core
|
|
4
4
|
* @copyright 2010–2026 Vadim Makeev, https://pepelsbey.dev
|
|
5
5
|
* @license MIT
|
|
6
6
|
*/
|
|
@@ -564,14 +564,16 @@
|
|
|
564
564
|
container.classList.add(listModeClass);
|
|
565
565
|
}
|
|
566
566
|
|
|
567
|
-
|
|
567
|
+
requestAnimationFrame(() => {
|
|
568
|
+
updateScale();
|
|
568
569
|
|
|
569
|
-
|
|
570
|
+
if (shower.isFullMode) return;
|
|
570
571
|
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
572
|
+
const slide = shower.activeSlide;
|
|
573
|
+
if (slide) {
|
|
574
|
+
slide.element.scrollIntoView({ block: 'center' });
|
|
575
|
+
}
|
|
576
|
+
});
|
|
575
577
|
};
|
|
576
578
|
|
|
577
579
|
shower.addEventListener('start', updateModeView);
|
package/lib/modules/view.js
CHANGED
|
@@ -31,14 +31,16 @@ export default (shower) => {
|
|
|
31
31
|
container.classList.add(listModeClass);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
requestAnimationFrame(() => {
|
|
35
|
+
updateScale();
|
|
35
36
|
|
|
36
|
-
|
|
37
|
+
if (shower.isFullMode) return;
|
|
37
38
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
39
|
+
const slide = shower.activeSlide;
|
|
40
|
+
if (slide) {
|
|
41
|
+
slide.element.scrollIntoView({ block: 'center' });
|
|
42
|
+
}
|
|
43
|
+
});
|
|
42
44
|
};
|
|
43
45
|
|
|
44
46
|
shower.addEventListener('start', updateModeView);
|