@stacksjs/utils 0.72.102 → 0.72.103
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/observer.d.ts +11 -2
- package/package.json +11 -11
package/dist/observer.d.ts
CHANGED
|
@@ -7,7 +7,16 @@ export declare function isResizeObserverSupported(): boolean;
|
|
|
7
7
|
*
|
|
8
8
|
* Modern browsers all support ResizeObserver, but this provides a fallback
|
|
9
9
|
*/
|
|
10
|
-
|
|
10
|
+
/**
|
|
11
|
+
* The native `ResizeObserver`, or a polyfill constructor with the same shape.
|
|
12
|
+
*
|
|
13
|
+
* Typed as the constructor rather than `any`: the polyfill below already
|
|
14
|
+
* declares `implements ResizeObserver`, so both branches genuinely satisfy it
|
|
15
|
+
* and nothing had to be given up to say so. `any` here spread to the
|
|
16
|
+
* `ResizeObserver` export beneath, so every consumer of the polyfill lost
|
|
17
|
+
* `observe` / `unobserve` / `disconnect` checking.
|
|
18
|
+
*/
|
|
19
|
+
export declare function getResizeObserver(): new (_callback: ResizeObserverCallback) => ResizeObserver;
|
|
11
20
|
/**
|
|
12
21
|
* Create a resize observer with automatic cleanup
|
|
13
22
|
*
|
|
@@ -39,7 +48,7 @@ export declare function createResizeObserver(callback: ResizeObserverCallback, t
|
|
|
39
48
|
*/
|
|
40
49
|
export declare function observeElementSize(element: Element, callback: (entry: ResizeObserverEntry) => void): () => void;
|
|
41
50
|
// Export the native ResizeObserver if available, or the polyfill
|
|
42
|
-
export declare const ResizeObserver:
|
|
51
|
+
export declare const ResizeObserver: new (_callback: ResizeObserverCallback) => ResizeObserver;
|
|
43
52
|
/**
|
|
44
53
|
* ResizeObserver polyfill (resize-observer-polyfill replacement)
|
|
45
54
|
*
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@stacksjs/utils",
|
|
3
3
|
"type": "module",
|
|
4
4
|
"sideEffects": false,
|
|
5
|
-
"version": "0.72.
|
|
5
|
+
"version": "0.72.103",
|
|
6
6
|
"description": "The Stacks helper functions.",
|
|
7
7
|
"author": "Chris Breuer",
|
|
8
8
|
"contributors": [
|
|
@@ -62,20 +62,20 @@
|
|
|
62
62
|
"size": "bun scripts/export-size.ts"
|
|
63
63
|
},
|
|
64
64
|
"dependencies": {
|
|
65
|
-
"@stacksjs/browser": "0.72.
|
|
65
|
+
"@stacksjs/browser": "0.72.103"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
|
-
"@stacksjs/actions": "0.72.
|
|
69
|
-
"@stacksjs/arrays": "0.72.
|
|
70
|
-
"@stacksjs/cli": "0.72.
|
|
71
|
-
"@stacksjs/config": "0.72.
|
|
68
|
+
"@stacksjs/actions": "0.72.103",
|
|
69
|
+
"@stacksjs/arrays": "0.72.103",
|
|
70
|
+
"@stacksjs/cli": "0.72.103",
|
|
71
|
+
"@stacksjs/config": "0.72.103",
|
|
72
72
|
"better-dx": "^0.2.24",
|
|
73
73
|
"filesize": "^11.0.22",
|
|
74
74
|
"markdown-table": "^3.0.4",
|
|
75
|
-
"@stacksjs/lint": "0.72.
|
|
76
|
-
"@stacksjs/path": "0.72.
|
|
77
|
-
"@stacksjs/storage": "0.72.
|
|
78
|
-
"@stacksjs/strings": "0.72.
|
|
79
|
-
"@stacksjs/types": "0.72.
|
|
75
|
+
"@stacksjs/lint": "0.72.103",
|
|
76
|
+
"@stacksjs/path": "0.72.103",
|
|
77
|
+
"@stacksjs/storage": "0.72.103",
|
|
78
|
+
"@stacksjs/strings": "0.72.103",
|
|
79
|
+
"@stacksjs/types": "0.72.103"
|
|
80
80
|
}
|
|
81
81
|
}
|