mnfst 0.5.216 → 0.5.217
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/lib/manifest.data.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"manifest.appwrite.auth.js": "sha384-X30RFvbwT9qEIaMsMUumnW54ZzcnY5aY9QQeXPG8/0sI6VAbAw3+FZ6iuZb6b4cu",
|
|
3
|
-
"manifest.appwrite.data.js": "sha384-
|
|
3
|
+
"manifest.appwrite.data.js": "sha384-yZr9vTGb3KKbkLp20t/jHdmCbVZM5eHXS7595SiOeeK1oBIDn/uWnJZQxmB5qTCz",
|
|
4
4
|
"manifest.appwrite.presences.js": "sha384-JyVDWFT69b7Svq8J8p9tNWe2v9PZNQBY5UyhtOl1vnuHFAX0CRQ3MA9SiKq5wzNh",
|
|
5
5
|
"manifest.bindings.js": "sha384-lPtMf8Ykaic9gNVZKq8Scia1881ZeMAyxer3WCIkUNwwrgzGBWto1OXADUwjvORF",
|
|
6
6
|
"manifest.charts.js": "sha384-gEAv/98+29RbhvNkiNWTNyBPbLTFr2Ld15wLu29FLCL57j1cwGChRrL9Pfk7dBtT",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"manifest.combobox.js": "sha384-MILTkrgsTzsYUjGo4ZuADqV85Xs4GmfB4xexfe9vbJMIoQTZ42W4zs+DTaVSPEsx",
|
|
12
12
|
"manifest.components.js": "sha384-4bc3HgPvF9DHMiOG08w+nWXI7Hho01RuAPAUL9xyLxOiS2igeZpulCVcvr5aT9v6",
|
|
13
13
|
"manifest.computed.js": "sha384-GYML/e81gQfN+iDbqhPUgny8bINCyL+SrbTofoGk4hlCnLLjv51mCv42JMqq+ku5",
|
|
14
|
-
"manifest.data.js": "sha384-
|
|
14
|
+
"manifest.data.js": "sha384-9SGjL5hRZj0Hthg0LaJFKuV/ijKRjN55rs2ZqAczXg4iEPBnneRByU3I+CeBQlxb",
|
|
15
15
|
"manifest.datepicker.js": "sha384-XnbeURni2X91ozVzatQcSjYYIS4MoW12dBRJnYAGBr0nCQ624heH5s+xtQSpLZX6",
|
|
16
16
|
"manifest.defer.js": "sha384-wXa60M2OHigi5rBurXQ7Oa8eyr5WTKs7EUn2GOru62KMdfs/LDyNegxCc9MNJFSe",
|
|
17
17
|
"manifest.device.js": "sha384-g+txmrEszYtuOvRelTp/c1wSNR2AtllVI9rx5NPPD7DzhVUnMNughonZykv2xlBW",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"manifest.slides.js": "sha384-3uRTkyK9XPLmnxI2+igZlpi4EyPlU/7IHj5j3BZJJ2KN455vXyk99fiXV3feO/XY",
|
|
29
29
|
"manifest.status.js": "sha384-MBO345ab7H6Uq1X2dZLt4Ge1Gcra+Z2qYApvlAeIV8CJhDDJrz2FPXpp+Kcp8zcM",
|
|
30
30
|
"manifest.svg.js": "sha384-qr/8H9+2cIhSXNbRWRtIdrDlTOxKlNJqwEefHvCYoiBNW/kKhPTFa109Orv/EBnb",
|
|
31
|
-
"manifest.sw.js": "sha384-
|
|
31
|
+
"manifest.sw.js": "sha384-umdIE2mmw7q0g6sS8FFKJNZloFTYwJnSLjH69oqKPuwkFxiox+/0rtC3L//80ac6",
|
|
32
32
|
"manifest.tabs.js": "sha384-OIIcyaQnGS0eNYk4zgAFEDboNYect7THvUd9D0V6nqCeDOxQcoiqLrBEmmWVTTet",
|
|
33
33
|
"manifest.tailwind.js": "sha384-r/Jvqb+Piz21jUts10BbVAJoKkShOdJRVFpywyi4HPIi/OfOJq5CtPyWAPbdkMgt",
|
|
34
34
|
"manifest.text.edit.js": "sha384-pfhc4IPKNJokj6ldlgD+KwGLN4UoM21CNeVf2sVq/34X1Un2PUhEuyTg5itmtsXS",
|
|
@@ -36,6 +36,6 @@
|
|
|
36
36
|
"manifest.tooltips.js": "sha384-uXVVQADl6pY2Pj9i/UaSclZN7dzbKhLkmevv7Ad0+wXR8LgqodALNFrc5jZJjlwm",
|
|
37
37
|
"manifest.url.parameters.js": "sha384-J2aSVBOPsoqsbafHndrWLHEDpKb4AKJAoQnVmKA4gZh5P/8HHjFWHO/lkusmG84l",
|
|
38
38
|
"manifest.utilities.js": "sha384-pIKcTvk9lrlXZK0OXld6SA6wrmlaFTCmTpLn67nOCE+XhNw4fuGSDX4Z3C2eR6CJ",
|
|
39
|
-
"manifest.virtual.js": "sha384-
|
|
39
|
+
"manifest.virtual.js": "sha384-ZDNoF9QVhVcVpkjIK6NH15S6I5c6OBshiJpXSOYjNsIB+298I0a7g3aFO+jyq4Vb",
|
|
40
40
|
"manifest.js": "sha384-OMEyd7TUB5EfAhabW58OgEn6AkZgOuH5IQ85dHZf7ciI0jmXXrsCp2Eh74iVnJ62"
|
|
41
41
|
}
|
package/lib/manifest.sw.js
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
// Build stamps the published version here; unstamped (dev) falls back to the
|
|
18
18
|
// registration URL's `v`, then 'dev'.
|
|
19
|
-
const BUILD_VERSION = '0.5.
|
|
19
|
+
const BUILD_VERSION = '0.5.217';
|
|
20
20
|
const CACHE_PREFIX = 'mnfst-sw:';
|
|
21
21
|
const META_CACHE = CACHE_PREFIX + 'meta';
|
|
22
22
|
// Sized to hold a full precache.json warm-up (PRECACHE_MAX_ENTRIES server-side)
|
package/lib/manifest.virtual.js
CHANGED
|
@@ -52,10 +52,9 @@ function initializeVirtualPlugin() {
|
|
|
52
52
|
const cs = getComputedStyle(scrollEl);
|
|
53
53
|
if (cs.overflow === 'visible' && cs.overflowY === 'visible') scrollEl.style.overflow = 'auto';
|
|
54
54
|
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
const isMasonry = mode === 'masonry';
|
|
55
|
+
const isMasonry = options.mode === 'masonry';
|
|
56
|
+
let kind = detectKind(host); // table | grid | flex | block; null while hidden
|
|
57
|
+
let isGallery = false;
|
|
59
58
|
|
|
60
59
|
// Masonry: fixed `columns` or target `columnWidth`; optional per-item `span`/
|
|
61
60
|
// `height` fns from data for ~zero settling; `gap` px (falls back to CSS gap).
|
|
@@ -83,6 +82,22 @@ function initializeVirtualPlugin() {
|
|
|
83
82
|
botSpacer = makeSpacer(kind, colCount);
|
|
84
83
|
host.insertBefore(topSpacer, template);
|
|
85
84
|
host.insertBefore(botSpacer, template);
|
|
85
|
+
if (kind) applyKind();
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
// A display:none host can't be classified; resolve once it has a box.
|
|
89
|
+
function applyKind() {
|
|
90
|
+
styleSpacer(topSpacer, kind);
|
|
91
|
+
styleSpacer(botSpacer, kind);
|
|
92
|
+
isGallery = (options.mode || detectMode(kind, host)) === 'gallery';
|
|
93
|
+
}
|
|
94
|
+
function resolveKind() {
|
|
95
|
+
if (kind || isMasonry) return true;
|
|
96
|
+
if (!(kind = detectKind(host))) return false;
|
|
97
|
+
if (ro && host !== scrollEl) ro.unobserve(host);
|
|
98
|
+
applyKind();
|
|
99
|
+
rebuild();
|
|
100
|
+
return true;
|
|
86
101
|
}
|
|
87
102
|
const anchor = isMasonry ? sizer : botSpacer; // rows insert before this
|
|
88
103
|
|
|
@@ -99,6 +114,7 @@ function initializeVirtualPlugin() {
|
|
|
99
114
|
let totalHeight = 0; // masonry: packed content height
|
|
100
115
|
let maxItemH = 0; // masonry: back-scan bound
|
|
101
116
|
let ready = false; // becomes true once container is sized
|
|
117
|
+
let ro = null;
|
|
102
118
|
|
|
103
119
|
const keyFn = buildKeyFn(itemName, keyExpr);
|
|
104
120
|
const avgH = () => (measuredCount > 0 ? measuredSum / measuredCount : estimateH);
|
|
@@ -204,11 +220,11 @@ function initializeVirtualPlugin() {
|
|
|
204
220
|
|
|
205
221
|
function render() {
|
|
206
222
|
if (isMasonry) return renderMasonry();
|
|
207
|
-
|
|
208
|
-
if (!total) { clearRows(); setHeight(topSpacer, 0); setHeight(botSpacer, 0); return; }
|
|
223
|
+
if (!data.length) { clearRows(); setHeight(topSpacer, 0); setHeight(botSpacer, 0); return; }
|
|
209
224
|
const vh = scrollEl.clientHeight;
|
|
210
|
-
if (!vh) return;
|
|
225
|
+
if (!vh || !resolveKind()) return; // defer until sized
|
|
211
226
|
ready = true;
|
|
227
|
+
const total = isGallery ? lines.length : data.length; // after resolveKind (may enable gallery)
|
|
212
228
|
|
|
213
229
|
const eff = Math.max(0, scrollEl.scrollTop - regionTop());
|
|
214
230
|
let startUnit = findStart(eff, total) - overscan;
|
|
@@ -358,18 +374,13 @@ function initializeVirtualPlugin() {
|
|
|
358
374
|
}
|
|
359
375
|
|
|
360
376
|
// display:contents rows (grid-table) have no box — measure the union of
|
|
361
|
-
// their cells. Everything else uses offsetHeight.
|
|
377
|
+
// their cells. Everything else uses offsetHeight. Vertically sticky (top)
|
|
378
|
+
// cells report their stuck rect and aren't supported; horizontal sticky is fine.
|
|
362
379
|
function measureHeight(node) {
|
|
363
|
-
if (getComputedStyle(node).display
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
if (r.top < top) top = r.top;
|
|
368
|
-
if (r.bottom > bottom) bottom = r.bottom;
|
|
369
|
-
}
|
|
370
|
-
return bottom > top ? bottom - top : 0;
|
|
371
|
-
}
|
|
372
|
-
return node.offsetHeight;
|
|
380
|
+
if (getComputedStyle(node).display !== 'contents') return node.offsetHeight;
|
|
381
|
+
const b = { top: Infinity, bottom: -Infinity };
|
|
382
|
+
unionCellRects(node, b);
|
|
383
|
+
return b.bottom > b.top ? b.bottom - b.top : 0;
|
|
373
384
|
}
|
|
374
385
|
|
|
375
386
|
// ---- Geometry helpers ----
|
|
@@ -420,12 +431,13 @@ function initializeVirtualPlugin() {
|
|
|
420
431
|
scrollEl.addEventListener('scroll', onScroll, { passive: true });
|
|
421
432
|
|
|
422
433
|
let resizeTimer = null;
|
|
423
|
-
|
|
424
|
-
if (!ready) { requestAnimationFrame(render); return; } // first paint once sized, off the observer tick
|
|
434
|
+
ro = new ResizeObserver(() => {
|
|
435
|
+
if (!ready) { requestAnimationFrame(() => { rebuild(); render(); }); return; } // first paint once sized, off the observer tick
|
|
425
436
|
clearTimeout(resizeTimer);
|
|
426
437
|
resizeTimer = setTimeout(() => { rebuild(); render(); }, 100); // debounced re-pack
|
|
427
438
|
});
|
|
428
439
|
ro.observe(scrollEl);
|
|
440
|
+
if (!kind && !isMasonry && host !== scrollEl) ro.observe(host); // only until a hidden host is classified
|
|
429
441
|
|
|
430
442
|
cleanup(() => {
|
|
431
443
|
scrollEl.removeEventListener('scroll', onScroll);
|
|
@@ -446,6 +458,7 @@ function detectKind(host) {
|
|
|
446
458
|
const tag = host.tagName;
|
|
447
459
|
if (tag === 'TBODY' || tag === 'THEAD' || tag === 'TFOOT' || tag === 'TABLE') return 'table';
|
|
448
460
|
const disp = getComputedStyle(host).display;
|
|
461
|
+
if (disp === 'none') return null;
|
|
449
462
|
if (disp.includes('grid')) return 'grid';
|
|
450
463
|
if (disp.includes('flex')) return 'flex';
|
|
451
464
|
return 'block';
|
|
@@ -467,8 +480,6 @@ function makeSpacer(kind, colCount) {
|
|
|
467
480
|
s.appendChild(td);
|
|
468
481
|
} else {
|
|
469
482
|
s = document.createElement('div');
|
|
470
|
-
if (kind === 'grid') s.style.gridColumn = '1 / -1';
|
|
471
|
-
else if (kind === 'flex') s.style.flex = '0 0 100%';
|
|
472
483
|
s.style.width = '100%';
|
|
473
484
|
}
|
|
474
485
|
s.dataset.virtualSpacer = '';
|
|
@@ -482,6 +493,26 @@ function makeSpacer(kind, colCount) {
|
|
|
482
493
|
return s;
|
|
483
494
|
}
|
|
484
495
|
|
|
496
|
+
// Box-less children (template, display:none) report a 0,0 rect that would drag
|
|
497
|
+
// the union to the viewport top; skip them, descend into nested display:contents.
|
|
498
|
+
function unionCellRects(node, b) {
|
|
499
|
+
for (const c of node.children) {
|
|
500
|
+
if (c.tagName === 'TEMPLATE') continue;
|
|
501
|
+
const r = c.getBoundingClientRect();
|
|
502
|
+
if (!r.width && !r.height) {
|
|
503
|
+
if (getComputedStyle(c).display === 'contents') unionCellRects(c, b);
|
|
504
|
+
continue;
|
|
505
|
+
}
|
|
506
|
+
if (r.top < b.top) b.top = r.top;
|
|
507
|
+
if (r.bottom > b.bottom) b.bottom = r.bottom;
|
|
508
|
+
}
|
|
509
|
+
}
|
|
510
|
+
|
|
511
|
+
function styleSpacer(s, kind) {
|
|
512
|
+
s.style.gridColumn = kind === 'grid' ? '1 / -1' : '';
|
|
513
|
+
s.style.flex = kind === 'flex' ? '0 0 100%' : '';
|
|
514
|
+
}
|
|
515
|
+
|
|
485
516
|
function setHeight(spacer, px) {
|
|
486
517
|
const h = Math.max(0, px) + 'px';
|
|
487
518
|
spacer.style.height = h;
|