@surdeddd/bottom-sheet 0.21.1 → 0.21.2
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.cjs +16 -6
- package/dist/core.js +16 -6
- package/dist/element.cjs +22 -11
- package/dist/element.iife.global.js +2 -2
- package/dist/element.js +22 -11
- package/dist/index.cjs +16 -6
- package/dist/index.js +16 -6
- package/dist/qwik-lib/index.qwik.cjs +17 -4
- package/dist/qwik-lib/index.qwik.mjs +17 -4
- package/dist/qwik.cjs +16 -6
- package/dist/qwik.js +16 -6
- package/dist/react.cjs +16 -6
- package/dist/react.js +16 -6
- package/dist/solid.cjs +16 -6
- package/dist/solid.js +16 -6
- package/dist/solid.source.jsx +16 -6
- package/dist/svelte-core.cjs +16 -6
- package/dist/svelte-core.js +16 -6
- package/dist/svelte.cjs +16 -6
- package/dist/svelte.js +16 -6
- package/dist/vue.cjs +16 -6
- package/dist/vue.js +16 -6
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -375,14 +375,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
375
375
|
}
|
|
376
376
|
}
|
|
377
377
|
|
|
378
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
379
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
380
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
381
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
382
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
383
|
+
|
|
378
384
|
// src/core/features/resize-observer.ts
|
|
379
385
|
function installResizeObserver(deps) {
|
|
380
386
|
if (typeof window === "undefined") {
|
|
381
387
|
return () => {
|
|
382
388
|
};
|
|
383
389
|
}
|
|
390
|
+
const seatFor = () => {
|
|
391
|
+
const snap = deps.resolveActiveSnap();
|
|
392
|
+
const max = deps.getMaxAxisSize();
|
|
393
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
394
|
+
};
|
|
384
395
|
const onResize = () => {
|
|
385
396
|
if (deps.isDestroyed()) return;
|
|
397
|
+
const before = seatFor();
|
|
386
398
|
deps.recomputeSnaps();
|
|
387
399
|
const mode = deps.getMode();
|
|
388
400
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -391,6 +403,10 @@ function installResizeObserver(deps) {
|
|
|
391
403
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
392
404
|
deps.setMaxAxisSize(viewportSize2);
|
|
393
405
|
}
|
|
406
|
+
const after = seatFor();
|
|
407
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
408
|
+
return;
|
|
409
|
+
}
|
|
394
410
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
395
411
|
deps.cancelInFlight();
|
|
396
412
|
deps.newCycle();
|
|
@@ -659,12 +675,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
659
675
|
}
|
|
660
676
|
});
|
|
661
677
|
|
|
662
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
663
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
664
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
665
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
666
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
667
|
-
|
|
668
678
|
// src/core/primitives/opacity-dedup.ts
|
|
669
679
|
var WriteSentinel = class {
|
|
670
680
|
constructor() {
|
package/dist/index.js
CHANGED
|
@@ -373,14 +373,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
373
373
|
}
|
|
374
374
|
}
|
|
375
375
|
|
|
376
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
377
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
378
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
379
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
380
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
381
|
+
|
|
376
382
|
// src/core/features/resize-observer.ts
|
|
377
383
|
function installResizeObserver(deps) {
|
|
378
384
|
if (typeof window === "undefined") {
|
|
379
385
|
return () => {
|
|
380
386
|
};
|
|
381
387
|
}
|
|
388
|
+
const seatFor = () => {
|
|
389
|
+
const snap = deps.resolveActiveSnap();
|
|
390
|
+
const max = deps.getMaxAxisSize();
|
|
391
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
392
|
+
};
|
|
382
393
|
const onResize = () => {
|
|
383
394
|
if (deps.isDestroyed()) return;
|
|
395
|
+
const before = seatFor();
|
|
384
396
|
deps.recomputeSnaps();
|
|
385
397
|
const mode = deps.getMode();
|
|
386
398
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -389,6 +401,10 @@ function installResizeObserver(deps) {
|
|
|
389
401
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
390
402
|
deps.setMaxAxisSize(viewportSize2);
|
|
391
403
|
}
|
|
404
|
+
const after = seatFor();
|
|
405
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
406
|
+
return;
|
|
407
|
+
}
|
|
392
408
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
393
409
|
deps.cancelInFlight();
|
|
394
410
|
deps.newCycle();
|
|
@@ -657,12 +673,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
657
673
|
}
|
|
658
674
|
});
|
|
659
675
|
|
|
660
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
661
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
662
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
663
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
664
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
665
|
-
|
|
666
676
|
// src/core/primitives/opacity-dedup.ts
|
|
667
677
|
var WriteSentinel = class {
|
|
668
678
|
constructor() {
|
|
@@ -359,13 +359,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
359
359
|
}
|
|
360
360
|
}
|
|
361
361
|
}
|
|
362
|
+
const SIZE_WRITE_EPSILON = 0.5;
|
|
363
|
+
const OPACITY_WRITE_EPSILON = 5e-3;
|
|
364
|
+
const POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
365
|
+
const RANGE_DIVISION_EPSILON = 1e-4;
|
|
362
366
|
function installResizeObserver(deps) {
|
|
363
367
|
if (typeof window === "undefined") {
|
|
364
368
|
return () => {
|
|
365
369
|
};
|
|
366
370
|
}
|
|
371
|
+
const seatFor = () => {
|
|
372
|
+
const snap = deps.resolveActiveSnap();
|
|
373
|
+
const max = deps.getMaxAxisSize();
|
|
374
|
+
return {
|
|
375
|
+
target: snap ? Math.min(snap.size, max) : null,
|
|
376
|
+
max
|
|
377
|
+
};
|
|
378
|
+
};
|
|
367
379
|
const onResize = () => {
|
|
368
380
|
if (deps.isDestroyed()) return;
|
|
381
|
+
const before = seatFor();
|
|
369
382
|
deps.recomputeSnaps();
|
|
370
383
|
const mode = deps.getMode();
|
|
371
384
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -374,6 +387,10 @@ function installResizeObserver(deps) {
|
|
|
374
387
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
375
388
|
deps.setMaxAxisSize(viewportSize2);
|
|
376
389
|
}
|
|
390
|
+
const after = seatFor();
|
|
391
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
392
|
+
return;
|
|
393
|
+
}
|
|
377
394
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
378
395
|
deps.cancelInFlight();
|
|
379
396
|
deps.newCycle();
|
|
@@ -635,10 +652,6 @@ const SCRIM_PRESETS = Object.freeze({
|
|
|
635
652
|
interactive: false
|
|
636
653
|
}
|
|
637
654
|
});
|
|
638
|
-
const SIZE_WRITE_EPSILON = 0.5;
|
|
639
|
-
const OPACITY_WRITE_EPSILON = 5e-3;
|
|
640
|
-
const POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
641
|
-
const RANGE_DIVISION_EPSILON = 1e-4;
|
|
642
655
|
class WriteSentinel {
|
|
643
656
|
constructor() {
|
|
644
657
|
__publicField(this, "last", -1);
|
|
@@ -357,13 +357,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
357
357
|
}
|
|
358
358
|
}
|
|
359
359
|
}
|
|
360
|
+
const SIZE_WRITE_EPSILON = 0.5;
|
|
361
|
+
const OPACITY_WRITE_EPSILON = 5e-3;
|
|
362
|
+
const POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
363
|
+
const RANGE_DIVISION_EPSILON = 1e-4;
|
|
360
364
|
function installResizeObserver(deps) {
|
|
361
365
|
if (typeof window === "undefined") {
|
|
362
366
|
return () => {
|
|
363
367
|
};
|
|
364
368
|
}
|
|
369
|
+
const seatFor = () => {
|
|
370
|
+
const snap = deps.resolveActiveSnap();
|
|
371
|
+
const max = deps.getMaxAxisSize();
|
|
372
|
+
return {
|
|
373
|
+
target: snap ? Math.min(snap.size, max) : null,
|
|
374
|
+
max
|
|
375
|
+
};
|
|
376
|
+
};
|
|
365
377
|
const onResize = () => {
|
|
366
378
|
if (deps.isDestroyed()) return;
|
|
379
|
+
const before = seatFor();
|
|
367
380
|
deps.recomputeSnaps();
|
|
368
381
|
const mode = deps.getMode();
|
|
369
382
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -372,6 +385,10 @@ function installResizeObserver(deps) {
|
|
|
372
385
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
373
386
|
deps.setMaxAxisSize(viewportSize2);
|
|
374
387
|
}
|
|
388
|
+
const after = seatFor();
|
|
389
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
390
|
+
return;
|
|
391
|
+
}
|
|
375
392
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
376
393
|
deps.cancelInFlight();
|
|
377
394
|
deps.newCycle();
|
|
@@ -633,10 +650,6 @@ const SCRIM_PRESETS = Object.freeze({
|
|
|
633
650
|
interactive: false
|
|
634
651
|
}
|
|
635
652
|
});
|
|
636
|
-
const SIZE_WRITE_EPSILON = 0.5;
|
|
637
|
-
const OPACITY_WRITE_EPSILON = 5e-3;
|
|
638
|
-
const POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
639
|
-
const RANGE_DIVISION_EPSILON = 1e-4;
|
|
640
653
|
class WriteSentinel {
|
|
641
654
|
constructor() {
|
|
642
655
|
__publicField(this, "last", -1);
|
package/dist/qwik.cjs
CHANGED
|
@@ -378,14 +378,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
378
378
|
}
|
|
379
379
|
}
|
|
380
380
|
|
|
381
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
382
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
383
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
384
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
385
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
386
|
+
|
|
381
387
|
// src/core/features/resize-observer.ts
|
|
382
388
|
function installResizeObserver(deps) {
|
|
383
389
|
if (typeof window === "undefined") {
|
|
384
390
|
return () => {
|
|
385
391
|
};
|
|
386
392
|
}
|
|
393
|
+
const seatFor = () => {
|
|
394
|
+
const snap = deps.resolveActiveSnap();
|
|
395
|
+
const max = deps.getMaxAxisSize();
|
|
396
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
397
|
+
};
|
|
387
398
|
const onResize = () => {
|
|
388
399
|
if (deps.isDestroyed()) return;
|
|
400
|
+
const before = seatFor();
|
|
389
401
|
deps.recomputeSnaps();
|
|
390
402
|
const mode = deps.getMode();
|
|
391
403
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -394,6 +406,10 @@ function installResizeObserver(deps) {
|
|
|
394
406
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
395
407
|
deps.setMaxAxisSize(viewportSize2);
|
|
396
408
|
}
|
|
409
|
+
const after = seatFor();
|
|
410
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
411
|
+
return;
|
|
412
|
+
}
|
|
397
413
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
398
414
|
deps.cancelInFlight();
|
|
399
415
|
deps.newCycle();
|
|
@@ -662,12 +678,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
662
678
|
}
|
|
663
679
|
});
|
|
664
680
|
|
|
665
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
666
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
667
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
668
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
669
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
670
|
-
|
|
671
681
|
// src/core/primitives/opacity-dedup.ts
|
|
672
682
|
var WriteSentinel = class {
|
|
673
683
|
constructor() {
|
package/dist/qwik.js
CHANGED
|
@@ -376,14 +376,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
376
376
|
}
|
|
377
377
|
}
|
|
378
378
|
|
|
379
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
380
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
381
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
382
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
383
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
384
|
+
|
|
379
385
|
// src/core/features/resize-observer.ts
|
|
380
386
|
function installResizeObserver(deps) {
|
|
381
387
|
if (typeof window === "undefined") {
|
|
382
388
|
return () => {
|
|
383
389
|
};
|
|
384
390
|
}
|
|
391
|
+
const seatFor = () => {
|
|
392
|
+
const snap = deps.resolveActiveSnap();
|
|
393
|
+
const max = deps.getMaxAxisSize();
|
|
394
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
395
|
+
};
|
|
385
396
|
const onResize = () => {
|
|
386
397
|
if (deps.isDestroyed()) return;
|
|
398
|
+
const before = seatFor();
|
|
387
399
|
deps.recomputeSnaps();
|
|
388
400
|
const mode = deps.getMode();
|
|
389
401
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -392,6 +404,10 @@ function installResizeObserver(deps) {
|
|
|
392
404
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
393
405
|
deps.setMaxAxisSize(viewportSize2);
|
|
394
406
|
}
|
|
407
|
+
const after = seatFor();
|
|
408
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
409
|
+
return;
|
|
410
|
+
}
|
|
395
411
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
396
412
|
deps.cancelInFlight();
|
|
397
413
|
deps.newCycle();
|
|
@@ -660,12 +676,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
660
676
|
}
|
|
661
677
|
});
|
|
662
678
|
|
|
663
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
664
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
665
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
666
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
667
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
668
|
-
|
|
669
679
|
// src/core/primitives/opacity-dedup.ts
|
|
670
680
|
var WriteSentinel = class {
|
|
671
681
|
constructor() {
|
package/dist/react.cjs
CHANGED
|
@@ -385,14 +385,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
385
385
|
}
|
|
386
386
|
}
|
|
387
387
|
|
|
388
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
389
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
390
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
391
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
392
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
393
|
+
|
|
388
394
|
// src/core/features/resize-observer.ts
|
|
389
395
|
function installResizeObserver(deps) {
|
|
390
396
|
if (typeof window === "undefined") {
|
|
391
397
|
return () => {
|
|
392
398
|
};
|
|
393
399
|
}
|
|
400
|
+
const seatFor = () => {
|
|
401
|
+
const snap = deps.resolveActiveSnap();
|
|
402
|
+
const max = deps.getMaxAxisSize();
|
|
403
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
404
|
+
};
|
|
394
405
|
const onResize = () => {
|
|
395
406
|
if (deps.isDestroyed()) return;
|
|
407
|
+
const before = seatFor();
|
|
396
408
|
deps.recomputeSnaps();
|
|
397
409
|
const mode = deps.getMode();
|
|
398
410
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -401,6 +413,10 @@ function installResizeObserver(deps) {
|
|
|
401
413
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
402
414
|
deps.setMaxAxisSize(viewportSize2);
|
|
403
415
|
}
|
|
416
|
+
const after = seatFor();
|
|
417
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
418
|
+
return;
|
|
419
|
+
}
|
|
404
420
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
405
421
|
deps.cancelInFlight();
|
|
406
422
|
deps.newCycle();
|
|
@@ -669,12 +685,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
669
685
|
}
|
|
670
686
|
});
|
|
671
687
|
|
|
672
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
673
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
674
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
675
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
676
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
677
|
-
|
|
678
688
|
// src/core/primitives/opacity-dedup.ts
|
|
679
689
|
var WriteSentinel = class {
|
|
680
690
|
constructor() {
|
package/dist/react.js
CHANGED
|
@@ -383,14 +383,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
383
383
|
}
|
|
384
384
|
}
|
|
385
385
|
|
|
386
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
387
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
388
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
389
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
390
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
391
|
+
|
|
386
392
|
// src/core/features/resize-observer.ts
|
|
387
393
|
function installResizeObserver(deps) {
|
|
388
394
|
if (typeof window === "undefined") {
|
|
389
395
|
return () => {
|
|
390
396
|
};
|
|
391
397
|
}
|
|
398
|
+
const seatFor = () => {
|
|
399
|
+
const snap = deps.resolveActiveSnap();
|
|
400
|
+
const max = deps.getMaxAxisSize();
|
|
401
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
402
|
+
};
|
|
392
403
|
const onResize = () => {
|
|
393
404
|
if (deps.isDestroyed()) return;
|
|
405
|
+
const before = seatFor();
|
|
394
406
|
deps.recomputeSnaps();
|
|
395
407
|
const mode = deps.getMode();
|
|
396
408
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -399,6 +411,10 @@ function installResizeObserver(deps) {
|
|
|
399
411
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
400
412
|
deps.setMaxAxisSize(viewportSize2);
|
|
401
413
|
}
|
|
414
|
+
const after = seatFor();
|
|
415
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
416
|
+
return;
|
|
417
|
+
}
|
|
402
418
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
403
419
|
deps.cancelInFlight();
|
|
404
420
|
deps.newCycle();
|
|
@@ -667,12 +683,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
667
683
|
}
|
|
668
684
|
});
|
|
669
685
|
|
|
670
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
671
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
672
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
673
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
674
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
675
|
-
|
|
676
686
|
// src/core/primitives/opacity-dedup.ts
|
|
677
687
|
var WriteSentinel = class {
|
|
678
688
|
constructor() {
|
package/dist/solid.cjs
CHANGED
|
@@ -378,14 +378,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
378
378
|
}
|
|
379
379
|
}
|
|
380
380
|
|
|
381
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
382
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
383
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
384
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
385
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
386
|
+
|
|
381
387
|
// src/core/features/resize-observer.ts
|
|
382
388
|
function installResizeObserver(deps) {
|
|
383
389
|
if (typeof window === "undefined") {
|
|
384
390
|
return () => {
|
|
385
391
|
};
|
|
386
392
|
}
|
|
393
|
+
const seatFor = () => {
|
|
394
|
+
const snap = deps.resolveActiveSnap();
|
|
395
|
+
const max = deps.getMaxAxisSize();
|
|
396
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
397
|
+
};
|
|
387
398
|
const onResize = () => {
|
|
388
399
|
if (deps.isDestroyed()) return;
|
|
400
|
+
const before = seatFor();
|
|
389
401
|
deps.recomputeSnaps();
|
|
390
402
|
const mode = deps.getMode();
|
|
391
403
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -394,6 +406,10 @@ function installResizeObserver(deps) {
|
|
|
394
406
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
395
407
|
deps.setMaxAxisSize(viewportSize2);
|
|
396
408
|
}
|
|
409
|
+
const after = seatFor();
|
|
410
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
411
|
+
return;
|
|
412
|
+
}
|
|
397
413
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
398
414
|
deps.cancelInFlight();
|
|
399
415
|
deps.newCycle();
|
|
@@ -662,12 +678,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
662
678
|
}
|
|
663
679
|
});
|
|
664
680
|
|
|
665
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
666
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
667
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
668
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
669
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
670
|
-
|
|
671
681
|
// src/core/primitives/opacity-dedup.ts
|
|
672
682
|
var WriteSentinel = class {
|
|
673
683
|
constructor() {
|
package/dist/solid.js
CHANGED
|
@@ -376,14 +376,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
376
376
|
}
|
|
377
377
|
}
|
|
378
378
|
|
|
379
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
380
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
381
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
382
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
383
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
384
|
+
|
|
379
385
|
// src/core/features/resize-observer.ts
|
|
380
386
|
function installResizeObserver(deps) {
|
|
381
387
|
if (typeof window === "undefined") {
|
|
382
388
|
return () => {
|
|
383
389
|
};
|
|
384
390
|
}
|
|
391
|
+
const seatFor = () => {
|
|
392
|
+
const snap = deps.resolveActiveSnap();
|
|
393
|
+
const max = deps.getMaxAxisSize();
|
|
394
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
395
|
+
};
|
|
385
396
|
const onResize = () => {
|
|
386
397
|
if (deps.isDestroyed()) return;
|
|
398
|
+
const before = seatFor();
|
|
387
399
|
deps.recomputeSnaps();
|
|
388
400
|
const mode = deps.getMode();
|
|
389
401
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -392,6 +404,10 @@ function installResizeObserver(deps) {
|
|
|
392
404
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
393
405
|
deps.setMaxAxisSize(viewportSize2);
|
|
394
406
|
}
|
|
407
|
+
const after = seatFor();
|
|
408
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
409
|
+
return;
|
|
410
|
+
}
|
|
395
411
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
396
412
|
deps.cancelInFlight();
|
|
397
413
|
deps.newCycle();
|
|
@@ -660,12 +676,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
660
676
|
}
|
|
661
677
|
});
|
|
662
678
|
|
|
663
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
664
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
665
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
666
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
667
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
668
|
-
|
|
669
679
|
// src/core/primitives/opacity-dedup.ts
|
|
670
680
|
var WriteSentinel = class {
|
|
671
681
|
constructor() {
|
package/dist/solid.source.jsx
CHANGED
|
@@ -381,14 +381,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
381
381
|
}
|
|
382
382
|
}
|
|
383
383
|
|
|
384
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
385
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
386
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
387
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
388
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
389
|
+
|
|
384
390
|
// src/core/features/resize-observer.ts
|
|
385
391
|
function installResizeObserver(deps) {
|
|
386
392
|
if (typeof window === "undefined") {
|
|
387
393
|
return () => {
|
|
388
394
|
};
|
|
389
395
|
}
|
|
396
|
+
const seatFor = () => {
|
|
397
|
+
const snap = deps.resolveActiveSnap();
|
|
398
|
+
const max = deps.getMaxAxisSize();
|
|
399
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
400
|
+
};
|
|
390
401
|
const onResize = () => {
|
|
391
402
|
if (deps.isDestroyed()) return;
|
|
403
|
+
const before = seatFor();
|
|
392
404
|
deps.recomputeSnaps();
|
|
393
405
|
const mode = deps.getMode();
|
|
394
406
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -397,6 +409,10 @@ function installResizeObserver(deps) {
|
|
|
397
409
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
398
410
|
deps.setMaxAxisSize(viewportSize2);
|
|
399
411
|
}
|
|
412
|
+
const after = seatFor();
|
|
413
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
414
|
+
return;
|
|
415
|
+
}
|
|
400
416
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
401
417
|
deps.cancelInFlight();
|
|
402
418
|
deps.newCycle();
|
|
@@ -665,12 +681,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
665
681
|
}
|
|
666
682
|
});
|
|
667
683
|
|
|
668
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
669
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
670
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
671
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
672
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
673
|
-
|
|
674
684
|
// src/core/primitives/opacity-dedup.ts
|
|
675
685
|
var WriteSentinel = class {
|
|
676
686
|
last = -1;
|
package/dist/svelte-core.cjs
CHANGED
|
@@ -377,14 +377,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
377
377
|
}
|
|
378
378
|
}
|
|
379
379
|
|
|
380
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
381
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
382
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
383
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
384
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
385
|
+
|
|
380
386
|
// src/core/features/resize-observer.ts
|
|
381
387
|
function installResizeObserver(deps) {
|
|
382
388
|
if (typeof window === "undefined") {
|
|
383
389
|
return () => {
|
|
384
390
|
};
|
|
385
391
|
}
|
|
392
|
+
const seatFor = () => {
|
|
393
|
+
const snap = deps.resolveActiveSnap();
|
|
394
|
+
const max = deps.getMaxAxisSize();
|
|
395
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
396
|
+
};
|
|
386
397
|
const onResize = () => {
|
|
387
398
|
if (deps.isDestroyed()) return;
|
|
399
|
+
const before = seatFor();
|
|
388
400
|
deps.recomputeSnaps();
|
|
389
401
|
const mode = deps.getMode();
|
|
390
402
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -393,6 +405,10 @@ function installResizeObserver(deps) {
|
|
|
393
405
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
394
406
|
deps.setMaxAxisSize(viewportSize2);
|
|
395
407
|
}
|
|
408
|
+
const after = seatFor();
|
|
409
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
410
|
+
return;
|
|
411
|
+
}
|
|
396
412
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
397
413
|
deps.cancelInFlight();
|
|
398
414
|
deps.newCycle();
|
|
@@ -661,12 +677,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
661
677
|
}
|
|
662
678
|
});
|
|
663
679
|
|
|
664
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
665
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
666
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
667
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
668
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
669
|
-
|
|
670
680
|
// src/core/primitives/opacity-dedup.ts
|
|
671
681
|
var WriteSentinel = class {
|
|
672
682
|
constructor() {
|
package/dist/svelte-core.js
CHANGED
|
@@ -375,14 +375,26 @@ function notifyLinkedSheets(sheets, self) {
|
|
|
375
375
|
}
|
|
376
376
|
}
|
|
377
377
|
|
|
378
|
+
// src/core/primitives/hot-path-thresholds.ts
|
|
379
|
+
var SIZE_WRITE_EPSILON = 0.5;
|
|
380
|
+
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
381
|
+
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
382
|
+
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
383
|
+
|
|
378
384
|
// src/core/features/resize-observer.ts
|
|
379
385
|
function installResizeObserver(deps) {
|
|
380
386
|
if (typeof window === "undefined") {
|
|
381
387
|
return () => {
|
|
382
388
|
};
|
|
383
389
|
}
|
|
390
|
+
const seatFor = () => {
|
|
391
|
+
const snap = deps.resolveActiveSnap();
|
|
392
|
+
const max = deps.getMaxAxisSize();
|
|
393
|
+
return { target: snap ? Math.min(snap.size, max) : null, max };
|
|
394
|
+
};
|
|
384
395
|
const onResize = () => {
|
|
385
396
|
if (deps.isDestroyed()) return;
|
|
397
|
+
const before = seatFor();
|
|
386
398
|
deps.recomputeSnaps();
|
|
387
399
|
const mode = deps.getMode();
|
|
388
400
|
const isVerticalAxis = mode === "bottom" || mode === "top";
|
|
@@ -391,6 +403,10 @@ function installResizeObserver(deps) {
|
|
|
391
403
|
if (viewportSize2 > 0 && viewportSize2 < max) {
|
|
392
404
|
deps.setMaxAxisSize(viewportSize2);
|
|
393
405
|
}
|
|
406
|
+
const after = seatFor();
|
|
407
|
+
if (before.target !== null && after.target !== null && Math.abs(after.target - before.target) < SIZE_WRITE_EPSILON && Math.abs(after.max - before.max) < SIZE_WRITE_EPSILON) {
|
|
408
|
+
return;
|
|
409
|
+
}
|
|
394
410
|
const wasAnimating = deps.isAnimating?.() ?? false;
|
|
395
411
|
deps.cancelInFlight();
|
|
396
412
|
deps.newCycle();
|
|
@@ -659,12 +675,6 @@ var SCRIM_PRESETS = Object.freeze({
|
|
|
659
675
|
}
|
|
660
676
|
});
|
|
661
677
|
|
|
662
|
-
// src/core/primitives/hot-path-thresholds.ts
|
|
663
|
-
var SIZE_WRITE_EPSILON = 0.5;
|
|
664
|
-
var OPACITY_WRITE_EPSILON = 5e-3;
|
|
665
|
-
var POINTER_EVENTS_OPACITY_THRESHOLD = 0.05;
|
|
666
|
-
var RANGE_DIVISION_EPSILON = 1e-4;
|
|
667
|
-
|
|
668
678
|
// src/core/primitives/opacity-dedup.ts
|
|
669
679
|
var WriteSentinel = class {
|
|
670
680
|
constructor() {
|