@michaelyagi/shoji 0.1.0-beta.3 → 0.1.0-beta.5
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/core/shoji-core.js +7 -0
- package/dist/core/shoji-core.js.map +1 -1
- package/dist/core/shoji-core.min.js +1 -1
- package/dist/core/shoji-core.min.js.map +1 -1
- package/dist/esm/core/Gallery.d.ts +2 -0
- package/dist/esm/core/index.js +94 -1
- package/dist/esm/core/index.js.map +1 -1
- package/dist/esm/index.css +86 -820
- package/dist/esm/index.js +1 -1
- package/dist/esm/index2.css +819 -44
- package/dist/esm/index3.css +47 -159
- package/dist/esm/index4.css +169 -26
- package/dist/esm/index5.css +27 -0
- package/dist/esm/plugins/activeThumbnail/index.d.ts +7 -1
- package/dist/esm/plugins/activeThumbnail/index.js +55 -16
- package/dist/esm/plugins/activeThumbnail/index.js.map +1 -1
- package/dist/plugins/activeThumbnail.css +99 -0
- package/dist/plugins/activeThumbnail.js +55 -17
- package/dist/plugins/activeThumbnail.js.map +1 -1
- package/dist/plugins/activeThumbnail.min.css +1 -0
- package/dist/plugins/activeThumbnail.min.js +1 -1
- package/dist/plugins/activeThumbnail.min.js.map +1 -1
- package/dist/shoji.css +99 -0
- package/dist/shoji.js +60 -16
- package/dist/shoji.js.map +1 -1
- package/dist/shoji.min.css +1 -1
- package/dist/shoji.min.js +1 -1
- package/dist/shoji.min.js.map +1 -1
- package/package.json +1 -1
- package/dist/esm/bodyScrollLock-CC5PJxJp.js +0 -96
- package/dist/esm/bodyScrollLock-CC5PJxJp.js.map +0 -1
package/dist/core/shoji-core.js
CHANGED
|
@@ -14,6 +14,9 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
14
14
|
let styleObserver = null;
|
|
15
15
|
let intentionalScrollOccurred = false;
|
|
16
16
|
const LIGHTBOX_SELECTOR = ".shoji-outer";
|
|
17
|
+
function markIntentionalScroll() {
|
|
18
|
+
intentionalScrollOccurred = true;
|
|
19
|
+
}
|
|
17
20
|
function isRtl() {
|
|
18
21
|
return getComputedStyle(document.documentElement).direction === "rtl";
|
|
19
22
|
}
|
|
@@ -2579,6 +2582,10 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2579
2582
|
}
|
|
2580
2583
|
return this.scannedElements[index] ?? null;
|
|
2581
2584
|
}
|
|
2585
|
+
/** Lets a plugin's background-page `scrollIntoView()` survive `close()`'s scroll restore, routed through this shared instance rather than importing `bodyScrollLock` directly — required for the standalone core+plugins distribution, where a direct import would get its own disconnected module copy (DESIGN.md §4.2/§10). Same reasoning `getOriginElement`/`getActiveMedia` were made public for. */
|
|
2586
|
+
markIntentionalScroll() {
|
|
2587
|
+
markIntentionalScroll();
|
|
2588
|
+
}
|
|
2582
2589
|
scheduleAutoHide() {
|
|
2583
2590
|
if (this.autoHideTimer !== null) {
|
|
2584
2591
|
clearTimeout(this.autoHideTimer);
|