frosty 0.0.36 → 0.0.37
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/_native.d.ts +3 -3
- package/dist/_native.js +5 -4
- package/dist/_native.js.map +1 -1
- package/dist/_native.mjs +4 -4
- package/dist/dom.d.ts +3 -3
- package/dist/dom.js +4 -6
- package/dist/dom.js.map +1 -1
- package/dist/dom.mjs +4 -6
- package/dist/dom.mjs.map +1 -1
- package/dist/index.d.ts +5 -50
- package/dist/index.js +109 -77
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +99 -62
- package/dist/index.mjs.map +1 -1
- package/dist/internals/{common-BOZ7LFsB.mjs → common-BoxPKJqo.mjs} +4 -5
- package/dist/internals/{common-BOZ7LFsB.mjs.map → common-BoxPKJqo.mjs.map} +1 -1
- package/dist/internals/{common-CjVBgVnj.js → common-CRYEvU6P.js} +5 -6
- package/dist/internals/{common-CjVBgVnj.js.map → common-CRYEvU6P.js.map} +1 -1
- package/dist/internals/{common-oNHXt-X6.d.ts → common-CUIKizze.d.ts} +6 -6
- package/dist/internals/common-CUIKizze.d.ts.map +1 -0
- package/dist/internals/{common-BLDQwvsd.d.ts → common-D44KuOmi.d.ts} +3 -3
- package/dist/internals/common-D44KuOmi.d.ts.map +1 -0
- package/dist/internals/{runtime-PKOt40BM.js → component-BiP3XIPe.js} +1 -33
- package/dist/internals/component-BiP3XIPe.js.map +1 -0
- package/dist/internals/{runtime-DrGYUphO.mjs → component-BzurKp_J.mjs} +2 -32
- package/dist/internals/component-BzurKp_J.mjs.map +1 -0
- package/dist/internals/{fragment-BkyAEmoa.d.ts → fragment-50WCFjrW.d.ts} +2 -2
- package/dist/internals/fragment-50WCFjrW.d.ts.map +1 -0
- package/dist/internals/{renderer-BIGBfQIc.mjs → renderer-ClDlweEF.mjs} +3 -3
- package/dist/internals/{renderer-BIGBfQIc.mjs.map → renderer-ClDlweEF.mjs.map} +1 -1
- package/dist/internals/{renderer-Bmw8wKAf.d.ts → renderer-DPoACdip.d.ts} +2 -2
- package/dist/internals/renderer-DPoACdip.d.ts.map +1 -0
- package/dist/internals/{renderer-Ds5Glygc.js → renderer-a9zN1_RB.js} +12 -12
- package/dist/internals/{renderer-Ds5Glygc.js.map → renderer-a9zN1_RB.js.map} +1 -1
- package/dist/internals/runtime-DCKT7fd6.js +37 -0
- package/dist/internals/runtime-DCKT7fd6.js.map +1 -0
- package/dist/internals/runtime-DK28Kyy2.mjs +34 -0
- package/dist/internals/runtime-DK28Kyy2.mjs.map +1 -0
- package/dist/internals/{state-CK2bzUOk.mjs → state-5PNx91ec.mjs} +3 -3
- package/dist/internals/{state-CK2bzUOk.mjs.map → state-5PNx91ec.mjs.map} +1 -1
- package/dist/internals/{state-CKAt_mTM.js → state-Lf_tbWNd.js} +4 -4
- package/dist/internals/{state-CKAt_mTM.js.map → state-Lf_tbWNd.js.map} +1 -1
- package/dist/internals/{sync-CyAho2g-.mjs → sync-C4RmxDzS.mjs} +99 -4
- package/dist/internals/sync-C4RmxDzS.mjs.map +1 -0
- package/dist/internals/{sync-w9XkAX8E.js → sync-e3464vDv.js} +105 -7
- package/dist/internals/sync-e3464vDv.js.map +1 -0
- package/dist/internals/{utils--X3fYqdu.d.ts → utils-DWp2-G3N.d.ts} +2 -2
- package/dist/internals/utils-DWp2-G3N.d.ts.map +1 -0
- package/dist/jsx-runtime.d.ts +2 -2
- package/dist/jsx-runtime.js +3 -2
- package/dist/jsx-runtime.js.map +1 -1
- package/dist/jsx-runtime.mjs +2 -1
- package/dist/jsx-runtime.mjs.map +1 -1
- package/dist/server-dom.d.ts +3 -3
- package/dist/server-dom.js +4 -6
- package/dist/server-dom.js.map +1 -1
- package/dist/server-dom.mjs +4 -6
- package/dist/server-dom.mjs.map +1 -1
- package/dist/web.d.ts +3 -3
- package/dist/web.js +6 -8
- package/dist/web.js.map +1 -1
- package/dist/web.mjs +6 -8
- package/dist/web.mjs.map +1 -1
- package/package.json +1 -1
- package/dist/internals/common-BLDQwvsd.d.ts.map +0 -1
- package/dist/internals/common-oNHXt-X6.d.ts.map +0 -1
- package/dist/internals/error-BT7hiUUR.mjs +0 -193
- package/dist/internals/error-BT7hiUUR.mjs.map +0 -1
- package/dist/internals/error-Cbb2rheX.js +0 -201
- package/dist/internals/error-Cbb2rheX.js.map +0 -1
- package/dist/internals/fragment-BkyAEmoa.d.ts.map +0 -1
- package/dist/internals/renderer-Bmw8wKAf.d.ts.map +0 -1
- package/dist/internals/runtime-DrGYUphO.mjs.map +0 -1
- package/dist/internals/runtime-PKOt40BM.js.map +0 -1
- package/dist/internals/sync-CyAho2g-.mjs.map +0 -1
- package/dist/internals/sync-w9XkAX8E.js.map +0 -1
- package/dist/internals/utils--X3fYqdu.d.ts.map +0 -1
|
@@ -1,8 +1,68 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var _ = require('lodash');
|
|
4
|
-
var
|
|
5
|
-
|
|
4
|
+
var state = require('./state-Lf_tbWNd.js');
|
|
5
|
+
|
|
6
|
+
//
|
|
7
|
+
// index.ts
|
|
8
|
+
//
|
|
9
|
+
// The MIT License
|
|
10
|
+
// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.
|
|
11
|
+
//
|
|
12
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
13
|
+
// of this software and associated documentation files (the "Software"), to deal
|
|
14
|
+
// in the Software without restriction, including without limitation the rights
|
|
15
|
+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
16
|
+
// copies of the Software, and to permit persons to whom the Software is
|
|
17
|
+
// furnished to do so, subject to the following conditions:
|
|
18
|
+
//
|
|
19
|
+
// The above copyright notice and this permission notice shall be included in
|
|
20
|
+
// all copies or substantial portions of the Software.
|
|
21
|
+
//
|
|
22
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
23
|
+
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
24
|
+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
25
|
+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
26
|
+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
27
|
+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
28
|
+
// THE SOFTWARE.
|
|
29
|
+
//
|
|
30
|
+
const _useHookState = (hook) => {
|
|
31
|
+
const state$1 = state.reconciler.currentHookState;
|
|
32
|
+
if (!state$1)
|
|
33
|
+
throw Error(`${hook} must be used within a render function.`);
|
|
34
|
+
const { prevState, state: newState } = state$1;
|
|
35
|
+
if (prevState && prevState[newState.length]?.hook !== hook) {
|
|
36
|
+
console.warn([
|
|
37
|
+
`Hook "${hook}" is called conditionally.`,
|
|
38
|
+
'Hooks must be called in the exact same order in every component render.',
|
|
39
|
+
'Did you accidentally call a hook after an early return?'
|
|
40
|
+
].join(' '));
|
|
41
|
+
}
|
|
42
|
+
return state$1;
|
|
43
|
+
};
|
|
44
|
+
const _useEffect = (hook, effect, deps) => {
|
|
45
|
+
const state = _useHookState(hook);
|
|
46
|
+
const { state: newState } = state;
|
|
47
|
+
newState.push({
|
|
48
|
+
mount: () => effect(state),
|
|
49
|
+
deps,
|
|
50
|
+
hook,
|
|
51
|
+
});
|
|
52
|
+
};
|
|
53
|
+
const _useMemo = (hook, factory, deps) => {
|
|
54
|
+
const state$1 = _useHookState(hook);
|
|
55
|
+
const { prevState, state: newState } = state$1;
|
|
56
|
+
const idx = newState.length;
|
|
57
|
+
const changed = prevState?.[idx]?.hook !== hook || !state.equalDeps(prevState[idx].deps, deps);
|
|
58
|
+
const data = changed ? factory(state$1) : prevState[idx].data;
|
|
59
|
+
newState.push({
|
|
60
|
+
deps,
|
|
61
|
+
hook,
|
|
62
|
+
data
|
|
63
|
+
});
|
|
64
|
+
return data;
|
|
65
|
+
};
|
|
6
66
|
|
|
7
67
|
//
|
|
8
68
|
// memo.ts
|
|
@@ -48,8 +108,8 @@ var state = require('./state-CKAt_mTM.js');
|
|
|
48
108
|
*/
|
|
49
109
|
const useCallback = (callback, deps) => {
|
|
50
110
|
if (!_.isUndefined(deps))
|
|
51
|
-
return
|
|
52
|
-
const store =
|
|
111
|
+
return _useMemo('useCallback', callback, deps);
|
|
112
|
+
const store = _useMemo('useCallback', () => {
|
|
53
113
|
const store = {
|
|
54
114
|
current: callback,
|
|
55
115
|
stable: (...args) => store.current(...args),
|
|
@@ -113,7 +173,7 @@ const useCallback = (callback, deps) => {
|
|
|
113
173
|
* };
|
|
114
174
|
* }, []);
|
|
115
175
|
*/
|
|
116
|
-
const useEffect = (effect, deps) =>
|
|
176
|
+
const useEffect = (effect, deps) => _useEffect('useEffect', () => {
|
|
117
177
|
const abort = new AbortController();
|
|
118
178
|
try {
|
|
119
179
|
const destructor = effect(abort.signal);
|
|
@@ -137,6 +197,41 @@ const useEffect = (effect, deps) => error._useEffect('useEffect', () => {
|
|
|
137
197
|
}
|
|
138
198
|
}, deps);
|
|
139
199
|
|
|
200
|
+
//
|
|
201
|
+
// memo.ts
|
|
202
|
+
//
|
|
203
|
+
// The MIT License
|
|
204
|
+
// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.
|
|
205
|
+
//
|
|
206
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
207
|
+
// of this software and associated documentation files (the "Software"), to deal
|
|
208
|
+
// in the Software without restriction, including without limitation the rights
|
|
209
|
+
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
210
|
+
// copies of the Software, and to permit persons to whom the Software is
|
|
211
|
+
// furnished to do so, subject to the following conditions:
|
|
212
|
+
//
|
|
213
|
+
// The above copyright notice and this permission notice shall be included in
|
|
214
|
+
// all copies or substantial portions of the Software.
|
|
215
|
+
//
|
|
216
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
217
|
+
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
218
|
+
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
219
|
+
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
220
|
+
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
221
|
+
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
222
|
+
// THE SOFTWARE.
|
|
223
|
+
//
|
|
224
|
+
/**
|
|
225
|
+
* A utility function that memoizes the result of a factory function.
|
|
226
|
+
*
|
|
227
|
+
* @template T The type of the value returned by the factory function.
|
|
228
|
+
* @param factory A function that produces a value to be memoized.
|
|
229
|
+
* @param deps An optional dependency array. The memoized value is recalculated
|
|
230
|
+
* only when the dependencies change.
|
|
231
|
+
* @returns The memoized value produced by the factory function.
|
|
232
|
+
*/
|
|
233
|
+
const useMemo = (factory, deps) => _useMemo('useMemo', factory, deps);
|
|
234
|
+
|
|
140
235
|
//
|
|
141
236
|
// sync.ts
|
|
142
237
|
//
|
|
@@ -180,7 +275,7 @@ const useSyncExternalStore = (subscribe, getSnapshot, getServerSnapshot) => {
|
|
|
180
275
|
const state$1 = state.reconciler.currentHookState;
|
|
181
276
|
if (!state$1)
|
|
182
277
|
throw Error('useSyncExternalStore must be used within a render function.');
|
|
183
|
-
|
|
278
|
+
_useEffect('useSyncExternalStore', ({ node }) => {
|
|
184
279
|
const abort = new AbortController();
|
|
185
280
|
try {
|
|
186
281
|
const destructor = subscribe(() => { node?._setDirty(); }, abort.signal);
|
|
@@ -209,7 +304,10 @@ const useSyncExternalStore = (subscribe, getSnapshot, getServerSnapshot) => {
|
|
|
209
304
|
return getSnapshot();
|
|
210
305
|
};
|
|
211
306
|
|
|
307
|
+
exports._useEffect = _useEffect;
|
|
308
|
+
exports._useMemo = _useMemo;
|
|
212
309
|
exports.useCallback = useCallback;
|
|
213
310
|
exports.useEffect = useEffect;
|
|
311
|
+
exports.useMemo = useMemo;
|
|
214
312
|
exports.useSyncExternalStore = useSyncExternalStore;
|
|
215
|
-
//# sourceMappingURL=sync-
|
|
313
|
+
//# sourceMappingURL=sync-e3464vDv.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sync-e3464vDv.js","sources":["../../../src/core/reconciler/hooks.ts","../../../src/core/hooks/callback.ts","../../../src/core/hooks/effect.ts","../../../src/core/hooks/memo.ts","../../../src/core/hooks/sync.ts"],"sourcesContent":["//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { reconciler } from './state';\nimport { equalDeps } from './utils';\n\nconst _useHookState = (hook: string) => {\n const state = reconciler.currentHookState;\n if (!state) throw Error(`${hook} must be used within a render function.`);\n const { prevState, state: newState } = state;\n if (prevState && prevState[newState.length]?.hook !== hook) {\n console.warn([\n `Hook \"${hook}\" is called conditionally.`,\n 'Hooks must be called in the exact same order in every component render.',\n 'Did you accidentally call a hook after an early return?'\n ].join(' '));\n }\n return state;\n};\n\nexport const _useEffect = (\n hook: string,\n effect: (state: ReturnType<typeof _useHookState>) => () => void,\n deps?: any\n) => {\n const state = _useHookState(hook);\n const { state: newState } = state;\n newState.push({\n mount: () => effect(state),\n deps,\n hook,\n });\n};\n\nexport const _useMemo = <T>(\n hook: string,\n factory: (state: ReturnType<typeof _useHookState>) => T,\n deps?: any\n): T => {\n const state = _useHookState(hook);\n const { prevState, state: newState } = state;\n const idx = newState.length;\n const changed = prevState?.[idx]?.hook !== hook || !equalDeps(prevState[idx].deps, deps);\n const data = changed ? factory(state) : prevState[idx].data;\n newState.push({\n deps,\n hook,\n data\n });\n return data;\n};\n","//\n// memo.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { _useMemo } from '../reconciler/hooks';\n\n/**\n * A hook that memoizes a callback function, ensuring that it only changes\n * if its dependencies change. This is useful for optimizing performance by preventing\n * unnecessary re-creations of functions.\n *\n * @template T - The type of the callback function.\n * @param callback - The callback function to be memoized.\n * @param deps - An optional dependencies. If provided, the callback\n * will only be updated when one of these dependencies changes.\n * If not provided, the callback will remain stable.\n * @returns - A stable version of the callback function that will not change unless\n * its dependencies change.\n *\n * @example\n * const memoizedCallback = useCallback(() => {\n * console.log('This function is memoized!');\n * }, [dependency]);\n */\nexport const useCallback = <T extends (...args: any) => any>(\n callback: T,\n deps?: any\n): T => {\n if (!_.isUndefined(deps)) return _useMemo('useCallback', callback, deps);\n const store = _useMemo('useCallback', () => {\n const store = {\n current: callback,\n stable: (...args: Parameters<T>): ReturnType<T> => store.current(...args),\n };\n return store;\n }, null);\n store.current = callback;\n return store.stable as T;\n}\n","//\n// effect.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { Awaitable } from '@o2ter/utils-js';\nimport { _useEffect } from '../reconciler/hooks';\n\n/**\n * A hook that manages side effects with support for an `AbortSignal`.\n * It ensures proper cleanup logic and handles asynchronous operations effectively.\n *\n * @param effect - \n * A function that receives an `AbortSignal` and performs side effects. \n * It can optionally return a cleanup function or a promise that resolves to a cleanup function.\n *\n * @param deps - \n * An optional dependencies that determines when the effect should be re-executed.\n *\n * @example\n * useEffect((signal) => {\n * fetch('/api/data', { signal })\n * .then(response => response.json())\n * .then(data => console.log(data))\n * .catch(err => {\n * if (err.name === 'AbortError') {\n * console.log('Fetch aborted');\n * } else {\n * console.error(err);\n * }\n * });\n * \n * return () => {\n * console.log('Cleanup logic here');\n * };\n * }, []);\n */\nexport const useEffect = (\n effect: (\n signal: AbortSignal,\n ) => Awaitable<void | (() => Awaitable<void>)>,\n deps?: any,\n) => _useEffect('useEffect', () => {\n const abort = new AbortController();\n try {\n const destructor = effect(abort.signal);\n return () => {\n abort.abort();\n (async () => {\n try {\n const _destructor = await destructor;\n if (_.isFunction(_destructor)) _destructor();\n } catch (e) {\n console.error(e);\n }\n })();\n };\n } catch (e) {\n console.error(e);\n return () => abort.abort();\n }\n}, deps);","//\n// memo.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { _useMemo } from '../reconciler/hooks';\n\n/**\n * A utility function that memoizes the result of a factory function.\n * \n * @template T The type of the value returned by the factory function.\n * @param factory A function that produces a value to be memoized.\n * @param deps An optional dependency array. The memoized value is recalculated \n * only when the dependencies change.\n * @returns The memoized value produced by the factory function.\n */\nexport const useMemo = <T>(\n factory: () => T,\n deps?: any,\n) => _useMemo('useMemo', factory, deps);\n","//\n// sync.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { Awaitable } from '@o2ter/utils-js';\nimport { _useEffect } from '../reconciler/hooks';\nimport { reconciler } from '../reconciler/state';\n\n/**\n * A hook utility for synchronizing with an external store.\n *\n * @template Snapshot - The type of the snapshot returned by the store.\n * @param subscribe - A function that sets up a subscription to the external store.\n * - `onStoreChange`: A callback to invoke when the store changes.\n * - `signal`: An `AbortSignal` to handle cleanup when the subscription is no longer needed.\n * - Returns an optional cleanup function or a promise resolving to one.\n * @param getSnapshot - A function that retrieves the current snapshot of the store.\n * @param getServerSnapshot - (Optional) A function that retrieves the snapshot of the store\n * in a server environment.\n * @returns The current snapshot of the store.\n *\n * @throws Will throw an error if used outside of a valid render context.\n */\nexport const useSyncExternalStore = <Snapshot>(\n subscribe: (\n onStoreChange: () => void,\n signal: AbortSignal,\n ) => Awaitable<void | (() => Awaitable<void>)>,\n getSnapshot: () => Snapshot,\n getServerSnapshot?: () => Snapshot,\n) => {\n const state = reconciler.currentHookState;\n if (!state) throw Error('useSyncExternalStore must be used within a render function.');\n _useEffect('useSyncExternalStore', ({ node }) => {\n const abort = new AbortController();\n try {\n const destructor = subscribe(() => { node?._setDirty(); }, abort.signal);\n return () => {\n abort.abort();\n (async () => {\n try {\n const _destructor = await destructor;\n if (_.isFunction(_destructor)) _destructor();\n } catch (e) {\n console.error(e);\n }\n })();\n };\n } catch (e) {\n console.error(e);\n return () => abort.abort();\n }\n }, null);\n if (getServerSnapshot && state.renderer._server) {\n return getServerSnapshot();\n }\n return getSnapshot();\n};"],"names":["state","reconciler","equalDeps"],"mappings":";;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;A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;AACF,YAAA,MAAM,UAAU,GAAG,SAAS,CAAC,QAAQ,IAAI,EAAE,SAAS,EAAE,CAAC,EAAE,EAAE,KAAK,CAAC,MAAM,CAAC;AACxE,YAAA,OAAO,MAAK;gBACV,KAAK,CAAC,KAAK,EAAE;gBACb,CAAC,YAAW;AACV,oBAAA,IAAI;AACF,wBAAA,MAAM,WAAW,GAAG,MAAM,UAAU;AACpC,wBAAA,IAAI,CAAC,CAAC,UAAU,CAAC,WAAW,CAAC;AAAE,4BAAA,WAAW,EAAE;;oBAC5C,OAAO,CAAC,EAAE;AACV,wBAAA,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC;;iBAEnB,GAAG;AACN,aAAC;;QACD,OAAO,CAAC,EAAE;AACV,YAAA,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC;AAChB,YAAA,OAAO,MAAM,KAAK,CAAC,KAAK,EAAE;;KAE7B,EAAE,IAAI,CAAC;IACR,IAAI,iBAAiB,IAAIA,OAAK,CAAC,QAAQ,CAAC,OAAO,EAAE;QAC/C,OAAO,iBAAiB,EAAE;;IAE5B,OAAO,WAAW,EAAE;AACtB;;;;;;;;;"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { a as Ref } from './common-
|
|
1
|
+
import { a as Ref } from './common-CUIKizze.js';
|
|
2
2
|
|
|
3
3
|
declare const mergeRefs: <T>(...refs: Ref<T>[]) => (x: T) => void;
|
|
4
4
|
declare const uniqueId: () => string;
|
|
5
5
|
|
|
6
6
|
export { mergeRefs as m, uniqueId as u };
|
|
7
|
-
//# sourceMappingURL=utils
|
|
7
|
+
//# sourceMappingURL=utils-DWp2-G3N.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils-DWp2-G3N.d.ts","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
package/dist/jsx-runtime.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { F as Fragment } from './internals/fragment-
|
|
1
|
+
import { n as _IntrinsicElements, o as _IntrinsicAttributes, _ as _ElementType, b as ComponentNode, c as PropsType } from './internals/common-CUIKizze.js';
|
|
2
|
+
export { F as Fragment } from './internals/fragment-50WCFjrW.js';
|
|
3
3
|
import '@o2ter/utils-js';
|
|
4
4
|
import 'lodash';
|
|
5
5
|
import 'csstype';
|
package/dist/jsx-runtime.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var component = require('./internals/component-BiP3XIPe.js');
|
|
4
|
+
var runtime = require('./internals/runtime-DCKT7fd6.js');
|
|
4
5
|
|
|
5
6
|
//
|
|
6
7
|
// index.ts
|
|
@@ -55,7 +56,7 @@ const Fragment = ({ children }) => {
|
|
|
55
56
|
// THE SOFTWARE.
|
|
56
57
|
//
|
|
57
58
|
const JSX = Object.freeze({
|
|
58
|
-
Element:
|
|
59
|
+
Element: component.ComponentNode,
|
|
59
60
|
});
|
|
60
61
|
function jsx(type, props, key) {
|
|
61
62
|
return runtime._createElement(type, { ...props, key });
|
package/dist/jsx-runtime.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jsx-runtime.js","sources":["../../src/core/types/fragment.ts","../../src/jsx-runtime.ts"],"sourcesContent":["//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentType, PropsWithChildren } from './common';\n\nexport const Fragment: ComponentType<PropsWithChildren<{}>> = ({ children }) => {\n return children;\n}\n","//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentNode } from './core/types/component';\nimport { _createElement, _ElementType, _IntrinsicAttributes, _IntrinsicElements, PropsType } from './core/types/runtime';\n\nexport { Fragment } from './core/types/fragment';\n\nexport declare namespace JSX {\n type IntrinsicElements = _IntrinsicElements;\n type IntrinsicAttributes = _IntrinsicAttributes;\n type ElementType = _ElementType;\n type Element = ComponentNode;\n type ElementChildrenAttribute = { children: {}; };\n};\n\nexport const JSX = Object.freeze({\n Element: ComponentNode,\n});\n\nexport function jsx(\n type: _ElementType,\n props: PropsType,\n key?: string | number\n): ComponentNode {\n return _createElement(type, { ...props, key });\n}\n\nexport const jsxs = jsx;\n"],"names":["ComponentNode","_createElement"],"mappings":"
|
|
1
|
+
{"version":3,"file":"jsx-runtime.js","sources":["../../src/core/types/fragment.ts","../../src/jsx-runtime.ts"],"sourcesContent":["//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentType, PropsWithChildren } from './common';\n\nexport const Fragment: ComponentType<PropsWithChildren<{}>> = ({ children }) => {\n return children;\n}\n","//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentNode } from './core/types/component';\nimport { _createElement, _ElementType, _IntrinsicAttributes, _IntrinsicElements, PropsType } from './core/types/runtime';\n\nexport { Fragment } from './core/types/fragment';\n\nexport declare namespace JSX {\n type IntrinsicElements = _IntrinsicElements;\n type IntrinsicAttributes = _IntrinsicAttributes;\n type ElementType = _ElementType;\n type Element = ComponentNode;\n type ElementChildrenAttribute = { children: {}; };\n};\n\nexport const JSX = Object.freeze({\n Element: ComponentNode,\n});\n\nexport function jsx(\n type: _ElementType,\n props: PropsType,\n key?: string | number\n): ComponentNode {\n return _createElement(type, { ...props, key });\n}\n\nexport const jsxs = jsx;\n"],"names":["ComponentNode","_createElement"],"mappings":";;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;MAIa,QAAQ,GAAyC,CAAC,EAAE,QAAQ,EAAE,KAAI;AAC7E,IAAA,OAAO,QAAQ;AACjB;;AC7BA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAea,MAAA,GAAG,GAAG,MAAM,CAAC,MAAM,CAAC;AAC/B,IAAA,OAAO,EAAEA,uBAAa;AACvB,CAAA;SAEe,GAAG,CACjB,IAAkB,EAClB,KAAgB,EAChB,GAAqB,EAAA;IAErB,OAAOC,sBAAc,CAAC,IAAI,EAAE,EAAE,GAAG,KAAK,EAAE,GAAG,EAAE,CAAC;AAChD;AAEO,MAAM,IAAI,GAAG;;;;;;;"}
|
package/dist/jsx-runtime.mjs
CHANGED
package/dist/jsx-runtime.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"jsx-runtime.mjs","sources":["../../src/core/types/fragment.ts","../../src/jsx-runtime.ts"],"sourcesContent":["//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentType, PropsWithChildren } from './common';\n\nexport const Fragment: ComponentType<PropsWithChildren<{}>> = ({ children }) => {\n return children;\n}\n","//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentNode } from './core/types/component';\nimport { _createElement, _ElementType, _IntrinsicAttributes, _IntrinsicElements, PropsType } from './core/types/runtime';\n\nexport { Fragment } from './core/types/fragment';\n\nexport declare namespace JSX {\n type IntrinsicElements = _IntrinsicElements;\n type IntrinsicAttributes = _IntrinsicAttributes;\n type ElementType = _ElementType;\n type Element = ComponentNode;\n type ElementChildrenAttribute = { children: {}; };\n};\n\nexport const JSX = Object.freeze({\n Element: ComponentNode,\n});\n\nexport function jsx(\n type: _ElementType,\n props: PropsType,\n key?: string | number\n): ComponentNode {\n return _createElement(type, { ...props, key });\n}\n\nexport const jsxs = jsx;\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"jsx-runtime.mjs","sources":["../../src/core/types/fragment.ts","../../src/jsx-runtime.ts"],"sourcesContent":["//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentType, PropsWithChildren } from './common';\n\nexport const Fragment: ComponentType<PropsWithChildren<{}>> = ({ children }) => {\n return children;\n}\n","//\n// index.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport { ComponentNode } from './core/types/component';\nimport { _createElement, _ElementType, _IntrinsicAttributes, _IntrinsicElements, PropsType } from './core/types/runtime';\n\nexport { Fragment } from './core/types/fragment';\n\nexport declare namespace JSX {\n type IntrinsicElements = _IntrinsicElements;\n type IntrinsicAttributes = _IntrinsicAttributes;\n type ElementType = _ElementType;\n type Element = ComponentNode;\n type ElementChildrenAttribute = { children: {}; };\n};\n\nexport const JSX = Object.freeze({\n Element: ComponentNode,\n});\n\nexport function jsx(\n type: _ElementType,\n props: PropsType,\n key?: string | number\n): ComponentNode {\n return _createElement(type, { ...props, key });\n}\n\nexport const jsxs = jsx;\n"],"names":[],"mappings":";;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;MAIa,QAAQ,GAAyC,CAAC,EAAE,QAAQ,EAAE,KAAI;AAC7E,IAAA,OAAO,QAAQ;AACjB;;AC7BA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAea,MAAA,GAAG,GAAG,MAAM,CAAC,MAAM,CAAC;AAC/B,IAAA,OAAO,EAAE,aAAa;AACvB,CAAA;SAEe,GAAG,CACjB,IAAkB,EAClB,KAAgB,EAChB,GAAqB,EAAA;IAErB,OAAO,cAAc,CAAC,IAAI,EAAE,EAAE,GAAG,KAAK,EAAE,GAAG,EAAE,CAAC;AAChD;AAEO,MAAM,IAAI,GAAG;;;;"}
|
package/dist/server-dom.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { JSDOM } from 'jsdom';
|
|
2
2
|
export * from 'jsdom';
|
|
3
|
-
import { _ as _DOMRenderer } from './internals/common-
|
|
4
|
-
import './internals/common-
|
|
3
|
+
import { _ as _DOMRenderer } from './internals/common-D44KuOmi.js';
|
|
4
|
+
import './internals/common-CUIKizze.js';
|
|
5
5
|
import '@o2ter/utils-js';
|
|
6
6
|
import 'lodash';
|
|
7
7
|
import 'csstype';
|
|
8
|
-
import './internals/renderer-
|
|
8
|
+
import './internals/renderer-DPoACdip.js';
|
|
9
9
|
|
|
10
10
|
declare class ServerDOMRenderer extends _DOMRenderer {
|
|
11
11
|
constructor(dom?: JSDOM);
|
package/dist/server-dom.js
CHANGED
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var jsdom = require('jsdom');
|
|
4
|
-
var common = require('./internals/common-
|
|
4
|
+
var common = require('./internals/common-CRYEvU6P.js');
|
|
5
5
|
require('lodash');
|
|
6
6
|
require('myers.js');
|
|
7
|
-
require('./internals/
|
|
8
|
-
require('./internals/renderer-
|
|
9
|
-
require('./internals/state-
|
|
7
|
+
require('./internals/component-BiP3XIPe.js');
|
|
8
|
+
require('./internals/renderer-a9zN1_RB.js');
|
|
9
|
+
require('./internals/state-Lf_tbWNd.js');
|
|
10
10
|
require('nextick');
|
|
11
11
|
require('postcss');
|
|
12
12
|
require('postcss-js');
|
|
13
13
|
require('postcss-nested');
|
|
14
14
|
require('autoprefixer');
|
|
15
|
-
require('./internals/error-Cbb2rheX.js');
|
|
16
|
-
require('./jsx-runtime.js');
|
|
17
15
|
|
|
18
16
|
//
|
|
19
17
|
// dom.ts
|
package/dist/server-dom.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server-dom.js","sources":["../../src/renderer/server-dom.ts"],"sourcesContent":["//\n// dom.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { JSDOM } from 'jsdom';\nimport { _DOMRenderer } from './common';\n\nexport * from 'jsdom';\n\nexport class ServerDOMRenderer extends _DOMRenderer {\n\n constructor(dom = new JSDOM()) {\n super(dom.window.document);\n }\n\n /** @internal */\n get _server(): boolean {\n return true;\n }\n}\n"],"names":["_DOMRenderer","JSDOM"],"mappings":"
|
|
1
|
+
{"version":3,"file":"server-dom.js","sources":["../../src/renderer/server-dom.ts"],"sourcesContent":["//\n// dom.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { JSDOM } from 'jsdom';\nimport { _DOMRenderer } from './common';\n\nexport * from 'jsdom';\n\nexport class ServerDOMRenderer extends _DOMRenderer {\n\n constructor(dom = new JSDOM()) {\n super(dom.window.document);\n }\n\n /** @internal */\n get _server(): boolean {\n return true;\n }\n}\n"],"names":["_DOMRenderer","JSDOM"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAQM,MAAO,iBAAkB,SAAQA,mBAAY,CAAA;AAEjD,IAAA,WAAA,CAAY,GAAG,GAAG,IAAIC,WAAK,EAAE,EAAA;AAC3B,QAAA,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC;;;AAI5B,IAAA,IAAI,OAAO,GAAA;AACT,QAAA,OAAO,IAAI;;AAEd;;;;;;;;;;"}
|
package/dist/server-dom.mjs
CHANGED
|
@@ -1,18 +1,16 @@
|
|
|
1
1
|
import { JSDOM } from 'jsdom';
|
|
2
2
|
export * from 'jsdom';
|
|
3
|
-
import { _ as _DOMRenderer } from './internals/common-
|
|
3
|
+
import { _ as _DOMRenderer } from './internals/common-BoxPKJqo.mjs';
|
|
4
4
|
import 'lodash';
|
|
5
5
|
import 'myers.js';
|
|
6
|
-
import './internals/
|
|
7
|
-
import './internals/renderer-
|
|
8
|
-
import './internals/state-
|
|
6
|
+
import './internals/component-BzurKp_J.mjs';
|
|
7
|
+
import './internals/renderer-ClDlweEF.mjs';
|
|
8
|
+
import './internals/state-5PNx91ec.mjs';
|
|
9
9
|
import 'nextick';
|
|
10
10
|
import 'postcss';
|
|
11
11
|
import 'postcss-js';
|
|
12
12
|
import 'postcss-nested';
|
|
13
13
|
import 'autoprefixer';
|
|
14
|
-
import './internals/error-BT7hiUUR.mjs';
|
|
15
|
-
import './jsx-runtime.mjs';
|
|
16
14
|
|
|
17
15
|
//
|
|
18
16
|
// dom.ts
|
package/dist/server-dom.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server-dom.mjs","sources":["../../src/renderer/server-dom.ts"],"sourcesContent":["//\n// dom.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { JSDOM } from 'jsdom';\nimport { _DOMRenderer } from './common';\n\nexport * from 'jsdom';\n\nexport class ServerDOMRenderer extends _DOMRenderer {\n\n constructor(dom = new JSDOM()) {\n super(dom.window.document);\n }\n\n /** @internal */\n get _server(): boolean {\n return true;\n }\n}\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"server-dom.mjs","sources":["../../src/renderer/server-dom.ts"],"sourcesContent":["//\n// dom.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { JSDOM } from 'jsdom';\nimport { _DOMRenderer } from './common';\n\nexport * from 'jsdom';\n\nexport class ServerDOMRenderer extends _DOMRenderer {\n\n constructor(dom = new JSDOM()) {\n super(dom.window.document);\n }\n\n /** @internal */\n get _server(): boolean {\n return true;\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAQM,MAAO,iBAAkB,SAAQ,YAAY,CAAA;AAEjD,IAAA,WAAA,CAAY,GAAG,GAAG,IAAI,KAAK,EAAE,EAAA;AAC3B,QAAA,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC;;;AAI5B,IAAA,IAAI,OAAO,GAAA;AACT,QAAA,OAAO,IAAI;;AAEd;;;;"}
|
package/dist/web.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { S as SetStateAction } from './internals/common-
|
|
2
|
-
export { D as DOMNativeNode, _ as _DOMRenderer } from './internals/common-
|
|
1
|
+
import { S as SetStateAction } from './internals/common-CUIKizze.js';
|
|
2
|
+
export { D as DOMNativeNode, _ as _DOMRenderer } from './internals/common-D44KuOmi.js';
|
|
3
3
|
import '@o2ter/utils-js';
|
|
4
4
|
import 'lodash';
|
|
5
5
|
import 'csstype';
|
|
6
|
-
import './internals/renderer-
|
|
6
|
+
import './internals/renderer-DPoACdip.js';
|
|
7
7
|
|
|
8
8
|
declare const useDocument: () => Document;
|
|
9
9
|
|
package/dist/web.js
CHANGED
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var state = require('./internals/state-
|
|
4
|
-
var common = require('./internals/common-
|
|
3
|
+
var state = require('./internals/state-Lf_tbWNd.js');
|
|
4
|
+
var common = require('./internals/common-CRYEvU6P.js');
|
|
5
5
|
var _ = require('lodash');
|
|
6
|
-
var
|
|
7
|
-
|
|
8
|
-
require('./internals/runtime-PKOt40BM.js');
|
|
6
|
+
var sync = require('./internals/sync-e3464vDv.js');
|
|
7
|
+
require('./internals/component-BiP3XIPe.js');
|
|
9
8
|
require('myers.js');
|
|
10
|
-
require('./internals/renderer-
|
|
9
|
+
require('./internals/renderer-a9zN1_RB.js');
|
|
11
10
|
require('nextick');
|
|
12
11
|
require('postcss');
|
|
13
12
|
require('postcss-js');
|
|
14
13
|
require('postcss-nested');
|
|
15
14
|
require('autoprefixer');
|
|
16
|
-
require('./jsx-runtime.js');
|
|
17
15
|
|
|
18
16
|
//
|
|
19
17
|
// document.ts
|
|
@@ -155,7 +153,7 @@ const useLocation = () => {
|
|
|
155
153
|
*/
|
|
156
154
|
const useSearchParams = () => {
|
|
157
155
|
const location = useLocation();
|
|
158
|
-
const searchParams =
|
|
156
|
+
const searchParams = sync.useMemo(() => new URLSearchParams(location.search), [location.search]);
|
|
159
157
|
const setSearchParams = sync.useCallback((params) => {
|
|
160
158
|
const newParams = new URLSearchParams(params);
|
|
161
159
|
location.pushState(location.state, `?${newParams.toString()}`);
|
package/dist/web.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"web.js","sources":["../../src/web/document.ts","../../src/web/location.ts","../../src/web/observer.ts","../../src/web/online.ts","../../src/web/storage.ts","../../src/web/window.ts"],"sourcesContent":["//\n// document.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { reconciler } from '../core/reconciler/state';\nimport { _DOMRenderer } from '../renderer/common';\n\nexport const useDocument = () => {\n const state = reconciler.currentHookState;\n if (!state) throw Error('useDocument must be used within a render function.');\n if (state.renderer instanceof _DOMRenderer) {\n return state.renderer.doc;\n } else {\n throw Error('Unsupported renderer.');\n }\n}","//\n// location.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useMemo } from '../core/hooks/memo';\nimport { useCallback } from '../core/hooks/callback';\nimport { useSyncExternalStore } from '../core/hooks/sync';\nimport { EventEmitter } from '../core/reconciler/events';\nimport { useDocument } from './document';\n\nconst emitters = new WeakMap<Document, EventEmitter>();\nconst emitterFor = (document: Document) => {\n if (!emitters.has(document)) emitters.set(document, new EventEmitter());\n return emitters.get(document)!;\n}\n\n/**\n * A hook that provides the current browser location and methods to manipulate the browser history.\n *\n * @returns An object with the following properties and methods:\n * - `hash`: The fragment identifier of the URL.\n * - `host`: The hostname and port number.\n * - `hostname`: The domain name.\n * - `href`: The full URL.\n * - `origin`: The protocol, hostname, and port.\n * - `pathname`: The path of the URL.\n * - `port`: The port number.\n * - `protocol`: The protocol scheme.\n * - `search`: The query string.\n * - `state`: The current state object associated with the history entry.\n * - `back()`: Navigates to the previous entry in the history stack.\n * - `forward()`: Navigates to the next entry in the history stack.\n * - `pushState(data, url)`: Pushes a new entry onto the history stack.\n * - `replaceState(data, url)`: Replaces the current history entry.\n *\n * The hook subscribes to changes in the browser's history and location, causing components to re-render when navigation occurs.\n *\n * @example\n * const location = useLocation();\n * console.log(location.pathname); // e.g., \"/about\"\n * location.pushState({ some: 'state' }, '/new-path');\n */\nexport const useLocation = () => {\n const document = useDocument();\n const emitter = emitterFor(document);\n const result = (history?: History) => ({\n ..._.pick(document.location, 'hash', 'host', 'hostname', 'href', 'origin', 'pathname', 'port', 'protocol', 'search'),\n state: history?.state ?? null,\n back: () => {\n history?.back();\n },\n forward: () => {\n history?.forward();\n emitter.emit('change');\n },\n pushState: (data: any, url?: string | URL | null) => {\n history?.pushState(data, '', url);\n emitter.emit('change');\n },\n replaceState: (data: any, url?: string | URL | null) => {\n history?.replaceState(data, '', url);\n emitter.emit('change');\n },\n });\n return useSyncExternalStore((onStoreChange) => {\n window.addEventListener('popstate', onStoreChange);\n const event = emitter.register('change', onStoreChange);\n return () => {\n window.removeEventListener('popstate', onStoreChange);\n event.remove();\n }\n }, () => result(window.history), () => result());\n}\n\ntype URLSearchParamsInit = ConstructorParameters<typeof URLSearchParams>[0];\n\n/**\n * A hook for reading and updating the URL's query string (search parameters).\n *\n * @returns A tuple:\n * - The first element is a `URLSearchParams` instance representing the current query string.\n * - The second element is a function to update the search parameters, which accepts any valid\n * `URLSearchParams` initializer (string, array, or object).\n *\n * Updating the search parameters will push a new history entry and update the URL in the address bar.\n *\n * @example\n * const [searchParams, setSearchParams] = useSearchParams();\n * const page = searchParams.get('page');\n * setSearchParams({ page: '2', filter: 'active' });\n */\nexport const useSearchParams = () => {\n const location = useLocation();\n const searchParams = useMemo(() => new URLSearchParams(location.search), [location.search]);\n const setSearchParams = useCallback((params: URLSearchParamsInit) => {\n const newParams = new URLSearchParams(params);\n location.pushState(location.state, `?${newParams.toString()}`);\n });\n return [searchParams, setSearchParams];\n}\n","//\n// observer.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useEffect } from '../core/hooks/effect';\nimport { useCallback } from '../core/hooks/callback';\n\ninterface _Observer<T> {\n observe(target: Element, options?: T): void;\n unobserve(target: Element): void;\n}\n\nconst createObserver = <E extends { target: Element; }, T>(\n constructor: new (callback: (entries: E[]) => void) => _Observer<T>\n) => {\n const listeners = new WeakMap<Element, ((entry: E) => void)[]>();\n const observer = new constructor((entries) => {\n for (const entry of entries) {\n for (const listener of listeners.get(entry.target) ?? []) {\n (async () => {\n try {\n await listener(entry);\n } catch (e) {\n console.error(e);\n }\n })();\n }\n }\n });\n return {\n observe: (target: Element, callback: (entry: E) => void, options?: T) => {\n observer.observe(target, options);\n listeners.set(target, [...listeners.get(target) ?? [], callback]);\n },\n unobserve: (target: Element, callback: (entry: E) => void) => {\n const list = _.filter(listeners.get(target), x => x !== callback);\n listeners.set(target, list);\n if (_.isEmpty(list)) observer.unobserve?.(target);\n },\n };\n};\n\nconst observer = typeof window === 'undefined' ? undefined : {\n resize: createObserver(ResizeObserver),\n intersection: createObserver(IntersectionObserver),\n};\n\nexport const useResizeObserver = (\n target: Element | null | undefined,\n callback: (entry: ResizeObserverEntry) => void,\n options?: ResizeObserverOptions,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (!observer || !target) return;\n observer.resize.observe(target, _callback, options);\n return () => observer.resize.unobserve(target, _callback);\n }, [target]);\n}\n\nexport const useIntersectionObserver = (\n target: Element | null | undefined,\n callback: (entry: IntersectionObserverEntry) => void,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (!observer || !target) return;\n observer.intersection.observe(target, _callback);\n return () => observer.intersection.unobserve(target, _callback);\n }, [target]);\n}\n\nexport const useMutationObserver = (\n target: Node | null | undefined,\n callback: MutationCallback,\n options?: MutationObserverInit,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (typeof window === 'undefined' || !target) return;\n const observer = new MutationObserver(_callback);\n observer.observe(target, options);\n return () => observer.disconnect();\n }, [target]);\n}\n\nexport const usePerformanceObserver = (\n callback: PerformanceObserverCallback,\n options?: PerformanceObserverInit,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (typeof window === 'undefined') return;\n const observer = new PerformanceObserver(_callback);\n observer.observe(options);\n return () => observer.disconnect();\n }, []);\n}\n","//\n// online.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useSyncExternalStore } from '../core/hooks/sync';\n\nexport const useOnline = () => useSyncExternalStore((onStoreChange) => {\n window.addEventListener('offline', onStoreChange);\n window.addEventListener('online', onStoreChange);\n return () => {\n window.removeEventListener('offline', onStoreChange);\n window.removeEventListener('online', onStoreChange);\n };\n}, () => navigator.onLine, () => false);","//\n// storage.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useSyncExternalStore } from '../core/hooks/sync';\nimport { useCallback } from '../core/hooks/callback';\nimport { SetStateAction } from '../core/types/common';\nimport { EventEmitter } from '../core/reconciler/events';\n\nconst emitters = new WeakMap<Storage, EventEmitter>();\nconst emitterFor = (storage: Storage) => {\n if (!emitters.has(storage)) emitters.set(storage, new EventEmitter());\n return emitters.get(storage)!;\n}\n\nconst _useStorage = (\n storage: () => Storage,\n key: string,\n initialValue?: string | null\n) => {\n const state = useSyncExternalStore((onStoreChange) => {\n const _storage = storage();\n const emitter = emitterFor(_storage);\n const callback = (ev: StorageEvent) => { \n if (!ev.storageArea || ev.storageArea === _storage) onStoreChange();\n };\n window.addEventListener('storage', callback);\n const event = emitter.register('change', onStoreChange);\n return () => {\n window.removeEventListener('storage', callback);\n event.remove();\n }\n }, () => storage().getItem(key), () => undefined);\n const setState = useCallback((v: SetStateAction<string | null | undefined>) => {\n try {\n const _storage = storage();\n const newValue = _.isFunction(v) ? v(state) : v;\n if (_.isNil(newValue)) {\n _storage.removeItem(key);\n } else {\n _storage.setItem(key, newValue);\n }\n const emitter = emitterFor(_storage);\n emitter.emit('change');\n } catch (e) {\n console.error(e);\n }\n }, [key]);\n return [state ?? initialValue ?? null, setState] as const;\n}\n\nexport const useLocalStorage = (\n key: string,\n initialValue?: string | null\n) => _useStorage(() => window.localStorage, key, initialValue);\n\nexport const useSessionStorage = (\n key: string,\n initialValue?: string | null\n) => _useStorage(() => window.sessionStorage, key, initialValue);\n","//\n// window.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useSyncExternalStore } from '../core/hooks/sync';\nimport { uniqueId } from '../core/utils';\n\nconst colorSchemeDark = typeof window !== 'undefined' ? window.matchMedia?.('(prefers-color-scheme: dark)') : undefined;\n\nconst emptyInsets = { top: 0, left: 0, right: 0, bottom: 0 };\nconst safeAreaInsets = () => {\n let support;\n if (!('CSS' in window) || typeof CSS.supports != 'function') {\n return emptyInsets;\n }\n if (CSS.supports('top: env(safe-area-inset-top)')) {\n support = 'env'\n } else if (CSS.supports('top: constant(safe-area-inset-top)')) {\n support = 'constant'\n } else {\n return emptyInsets;\n }\n const id = uniqueId();\n const style = document.createElement('style');\n style.textContent = `:root {\n --${id}-top: ${support}(safe-area-inset-top);\n --${id}-left: ${support}(safe-area-inset-left);\n --${id}-right: ${support}(safe-area-inset-right);\n --${id}-bottom: ${support}(safe-area-inset-bottom);\n }`;\n document.head.appendChild(style);\n const computedStyle = getComputedStyle(document.documentElement);\n const insets = {\n top: computedStyle.getPropertyValue(`--${id}-top`),\n left: computedStyle.getPropertyValue(`--${id}-left`),\n right: computedStyle.getPropertyValue(`--${id}-right`),\n bottom: computedStyle.getPropertyValue(`--${id}-bottom`),\n };\n style.remove();\n return _.mapValues(insets, v => parseFloat(v));\n}\n\nexport const useWindowMetrics = () => useSyncExternalStore((onStoreChange) => {\n window.addEventListener('resize', onStoreChange);\n return () => {\n window.removeEventListener('resize', onStoreChange);\n };\n}, () => ({\n safeAreaInsets: safeAreaInsets(),\n devicePixelRatio: window.devicePixelRatio,\n outerWidth: window.outerWidth,\n outerHeight: window.outerHeight,\n innerWidth: window.innerWidth,\n innerHeight: window.innerHeight,\n}), () => ({\n safeAreaInsets: emptyInsets,\n devicePixelRatio: 1,\n outerWidth: 0,\n outerHeight: 0,\n innerWidth: 0,\n innerHeight: 0,\n}));\n\nexport const useWindowScroll = () => useSyncExternalStore((onStoreChange) => {\n window.addEventListener('scroll', onStoreChange);\n return () => {\n window.removeEventListener('scroll', onStoreChange);\n };\n}, () => ({\n scrollX: window.scrollX,\n scrollY: window.scrollY,\n}), () => ({\n scrollX: 0,\n scrollY: 0,\n}));\n\nexport const useColorScheme = () => useSyncExternalStore((onStoreChange) => {\n colorSchemeDark?.addEventListener('change', onStoreChange);\n return () => {\n colorSchemeDark?.removeEventListener('change', onStoreChange);\n };\n}, () => colorSchemeDark?.matches ? 'dark' : 'light', () => 'light');\n"],"names":["state","reconciler","_DOMRenderer","emitters","emitterFor","EventEmitter","useSyncExternalStore","useMemo","useCallback","useEffect","uniqueId"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAMO,MAAM,WAAW,GAAG,MAAK;AAC9B,IAAA,MAAMA,OAAK,GAAGC,gBAAU,CAAC,gBAAgB;AACzC,IAAA,IAAI,CAACD,OAAK;AAAE,QAAA,MAAM,KAAK,CAAC,oDAAoD,CAAC;AAC7E,IAAA,IAAIA,OAAK,CAAC,QAAQ,YAAYE,mBAAY,EAAE;AAC1C,QAAA,OAAOF,OAAK,CAAC,QAAQ,CAAC,GAAG;;SACpB;AACL,QAAA,MAAM,KAAK,CAAC,uBAAuB,CAAC;;AAExC;;ACrCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AASA,MAAMG,UAAQ,GAAG,IAAI,OAAO,EAA0B;AACtD,MAAMC,YAAU,GAAG,CAAC,QAAkB,KAAI;AACxC,IAAA,IAAI,CAACD,UAAQ,CAAC,GAAG,CAAC,QAAQ,CAAC;QAAEA,UAAQ,CAAC,GAAG,CAAC,QAAQ,EAAE,IAAIE,kBAAY,EAAE,CAAC;AACvE,IAAA,OAAOF,UAAQ,CAAC,GAAG,CAAC,QAAQ,CAAE;AAChC,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;AAyBG;AACI,MAAM,WAAW,GAAG,MAAK;AAC9B,IAAA,MAAM,QAAQ,GAAG,WAAW,EAAE;AAC9B,IAAA,MAAM,OAAO,GAAGC,YAAU,CAAC,QAAQ,CAAC;AACpC,IAAA,MAAM,MAAM,GAAG,CAAC,OAAiB,MAAM;QACrC,GAAG,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;AAC1E,IAAA,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,aAAa,CAAC;AAChD,IAAA,OAAO,MAAK;AACV,QAAA,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,aAAa,CAAC;AACrD,KAAC;AACH,CAAC,EAAE,OAAO;IACR,OAAO,EAAE,MAAM,CAAC,OAAO;IACvB,OAAO,EAAE,MAAM,CAAC,OAAO;AACxB,CAAA,CAAC,EAAE,OAAO;AACT,IAAA,OAAO,EAAE,CAAC;AACV,IAAA,OAAO,EAAE,CAAC;AACX,CAAA,CAAC;AAEK,MAAM,cAAc,GAAG,MAAMA,yBAAoB,CAAC,CAAC,aAAa,KAAI;AACzE,IAAA,eAAe,EAAE,gBAAgB,CAAC,QAAQ,EAAE,aAAa,CAAC;AAC1D,IAAA,OAAO,MAAK;AACV,QAAA,eAAe,EAAE,mBAAmB,CAAC,QAAQ,EAAE,aAAa,CAAC;AAC/D,KAAC;AACH,CAAC,EAAE,MAAM,eAAe,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,EAAE,MAAM,OAAO;;;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"web.js","sources":["../../src/web/document.ts","../../src/web/location.ts","../../src/web/observer.ts","../../src/web/online.ts","../../src/web/storage.ts","../../src/web/window.ts"],"sourcesContent":["//\n// document.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { reconciler } from '../core/reconciler/state';\nimport { _DOMRenderer } from '../renderer/common';\n\nexport const useDocument = () => {\n const state = reconciler.currentHookState;\n if (!state) throw Error('useDocument must be used within a render function.');\n if (state.renderer instanceof _DOMRenderer) {\n return state.renderer.doc;\n } else {\n throw Error('Unsupported renderer.');\n }\n}","//\n// location.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useMemo } from '../core/hooks/memo';\nimport { useCallback } from '../core/hooks/callback';\nimport { useSyncExternalStore } from '../core/hooks/sync';\nimport { EventEmitter } from '../core/reconciler/events';\nimport { useDocument } from './document';\n\nconst emitters = new WeakMap<Document, EventEmitter>();\nconst emitterFor = (document: Document) => {\n if (!emitters.has(document)) emitters.set(document, new EventEmitter());\n return emitters.get(document)!;\n}\n\n/**\n * A hook that provides the current browser location and methods to manipulate the browser history.\n *\n * @returns An object with the following properties and methods:\n * - `hash`: The fragment identifier of the URL.\n * - `host`: The hostname and port number.\n * - `hostname`: The domain name.\n * - `href`: The full URL.\n * - `origin`: The protocol, hostname, and port.\n * - `pathname`: The path of the URL.\n * - `port`: The port number.\n * - `protocol`: The protocol scheme.\n * - `search`: The query string.\n * - `state`: The current state object associated with the history entry.\n * - `back()`: Navigates to the previous entry in the history stack.\n * - `forward()`: Navigates to the next entry in the history stack.\n * - `pushState(data, url)`: Pushes a new entry onto the history stack.\n * - `replaceState(data, url)`: Replaces the current history entry.\n *\n * The hook subscribes to changes in the browser's history and location, causing components to re-render when navigation occurs.\n *\n * @example\n * const location = useLocation();\n * console.log(location.pathname); // e.g., \"/about\"\n * location.pushState({ some: 'state' }, '/new-path');\n */\nexport const useLocation = () => {\n const document = useDocument();\n const emitter = emitterFor(document);\n const result = (history?: History) => ({\n ..._.pick(document.location, 'hash', 'host', 'hostname', 'href', 'origin', 'pathname', 'port', 'protocol', 'search'),\n state: history?.state ?? null,\n back: () => {\n history?.back();\n },\n forward: () => {\n history?.forward();\n emitter.emit('change');\n },\n pushState: (data: any, url?: string | URL | null) => {\n history?.pushState(data, '', url);\n emitter.emit('change');\n },\n replaceState: (data: any, url?: string | URL | null) => {\n history?.replaceState(data, '', url);\n emitter.emit('change');\n },\n });\n return useSyncExternalStore((onStoreChange) => {\n window.addEventListener('popstate', onStoreChange);\n const event = emitter.register('change', onStoreChange);\n return () => {\n window.removeEventListener('popstate', onStoreChange);\n event.remove();\n }\n }, () => result(window.history), () => result());\n}\n\ntype URLSearchParamsInit = ConstructorParameters<typeof URLSearchParams>[0];\n\n/**\n * A hook for reading and updating the URL's query string (search parameters).\n *\n * @returns A tuple:\n * - The first element is a `URLSearchParams` instance representing the current query string.\n * - The second element is a function to update the search parameters, which accepts any valid\n * `URLSearchParams` initializer (string, array, or object).\n *\n * Updating the search parameters will push a new history entry and update the URL in the address bar.\n *\n * @example\n * const [searchParams, setSearchParams] = useSearchParams();\n * const page = searchParams.get('page');\n * setSearchParams({ page: '2', filter: 'active' });\n */\nexport const useSearchParams = () => {\n const location = useLocation();\n const searchParams = useMemo(() => new URLSearchParams(location.search), [location.search]);\n const setSearchParams = useCallback((params: URLSearchParamsInit) => {\n const newParams = new URLSearchParams(params);\n location.pushState(location.state, `?${newParams.toString()}`);\n });\n return [searchParams, setSearchParams];\n}\n","//\n// observer.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useEffect } from '../core/hooks/effect';\nimport { useCallback } from '../core/hooks/callback';\n\ninterface _Observer<T> {\n observe(target: Element, options?: T): void;\n unobserve(target: Element): void;\n}\n\nconst createObserver = <E extends { target: Element; }, T>(\n constructor: new (callback: (entries: E[]) => void) => _Observer<T>\n) => {\n const listeners = new WeakMap<Element, ((entry: E) => void)[]>();\n const observer = new constructor((entries) => {\n for (const entry of entries) {\n for (const listener of listeners.get(entry.target) ?? []) {\n (async () => {\n try {\n await listener(entry);\n } catch (e) {\n console.error(e);\n }\n })();\n }\n }\n });\n return {\n observe: (target: Element, callback: (entry: E) => void, options?: T) => {\n observer.observe(target, options);\n listeners.set(target, [...listeners.get(target) ?? [], callback]);\n },\n unobserve: (target: Element, callback: (entry: E) => void) => {\n const list = _.filter(listeners.get(target), x => x !== callback);\n listeners.set(target, list);\n if (_.isEmpty(list)) observer.unobserve?.(target);\n },\n };\n};\n\nconst observer = typeof window === 'undefined' ? undefined : {\n resize: createObserver(ResizeObserver),\n intersection: createObserver(IntersectionObserver),\n};\n\nexport const useResizeObserver = (\n target: Element | null | undefined,\n callback: (entry: ResizeObserverEntry) => void,\n options?: ResizeObserverOptions,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (!observer || !target) return;\n observer.resize.observe(target, _callback, options);\n return () => observer.resize.unobserve(target, _callback);\n }, [target]);\n}\n\nexport const useIntersectionObserver = (\n target: Element | null | undefined,\n callback: (entry: IntersectionObserverEntry) => void,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (!observer || !target) return;\n observer.intersection.observe(target, _callback);\n return () => observer.intersection.unobserve(target, _callback);\n }, [target]);\n}\n\nexport const useMutationObserver = (\n target: Node | null | undefined,\n callback: MutationCallback,\n options?: MutationObserverInit,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (typeof window === 'undefined' || !target) return;\n const observer = new MutationObserver(_callback);\n observer.observe(target, options);\n return () => observer.disconnect();\n }, [target]);\n}\n\nexport const usePerformanceObserver = (\n callback: PerformanceObserverCallback,\n options?: PerformanceObserverInit,\n) => {\n const _callback = useCallback(callback);\n useEffect(() => {\n if (typeof window === 'undefined') return;\n const observer = new PerformanceObserver(_callback);\n observer.observe(options);\n return () => observer.disconnect();\n }, []);\n}\n","//\n// online.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useSyncExternalStore } from '../core/hooks/sync';\n\nexport const useOnline = () => useSyncExternalStore((onStoreChange) => {\n window.addEventListener('offline', onStoreChange);\n window.addEventListener('online', onStoreChange);\n return () => {\n window.removeEventListener('offline', onStoreChange);\n window.removeEventListener('online', onStoreChange);\n };\n}, () => navigator.onLine, () => false);","//\n// storage.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useSyncExternalStore } from '../core/hooks/sync';\nimport { useCallback } from '../core/hooks/callback';\nimport { SetStateAction } from '../core/types/common';\nimport { EventEmitter } from '../core/reconciler/events';\n\nconst emitters = new WeakMap<Storage, EventEmitter>();\nconst emitterFor = (storage: Storage) => {\n if (!emitters.has(storage)) emitters.set(storage, new EventEmitter());\n return emitters.get(storage)!;\n}\n\nconst _useStorage = (\n storage: () => Storage,\n key: string,\n initialValue?: string | null\n) => {\n const state = useSyncExternalStore((onStoreChange) => {\n const _storage = storage();\n const emitter = emitterFor(_storage);\n const callback = (ev: StorageEvent) => { \n if (!ev.storageArea || ev.storageArea === _storage) onStoreChange();\n };\n window.addEventListener('storage', callback);\n const event = emitter.register('change', onStoreChange);\n return () => {\n window.removeEventListener('storage', callback);\n event.remove();\n }\n }, () => storage().getItem(key), () => undefined);\n const setState = useCallback((v: SetStateAction<string | null | undefined>) => {\n try {\n const _storage = storage();\n const newValue = _.isFunction(v) ? v(state) : v;\n if (_.isNil(newValue)) {\n _storage.removeItem(key);\n } else {\n _storage.setItem(key, newValue);\n }\n const emitter = emitterFor(_storage);\n emitter.emit('change');\n } catch (e) {\n console.error(e);\n }\n }, [key]);\n return [state ?? initialValue ?? null, setState] as const;\n}\n\nexport const useLocalStorage = (\n key: string,\n initialValue?: string | null\n) => _useStorage(() => window.localStorage, key, initialValue);\n\nexport const useSessionStorage = (\n key: string,\n initialValue?: string | null\n) => _useStorage(() => window.sessionStorage, key, initialValue);\n","//\n// window.ts\n//\n// The MIT License\n// Copyright (c) 2021 - 2025 O2ter Limited. All rights reserved.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a copy\n// of this software and associated documentation files (the \"Software\"), to deal\n// in the Software without restriction, including without limitation the rights\n// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n// copies of the Software, and to permit persons to whom the Software is\n// furnished to do so, subject to the following conditions:\n//\n// The above copyright notice and this permission notice shall be included in\n// all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n// THE SOFTWARE.\n//\n\nimport _ from 'lodash';\nimport { useSyncExternalStore } from '../core/hooks/sync';\nimport { uniqueId } from '../core/utils';\n\nconst colorSchemeDark = typeof window !== 'undefined' ? window.matchMedia?.('(prefers-color-scheme: dark)') : undefined;\n\nconst emptyInsets = { top: 0, left: 0, right: 0, bottom: 0 };\nconst safeAreaInsets = () => {\n let support;\n if (!('CSS' in window) || typeof CSS.supports != 'function') {\n return emptyInsets;\n }\n if (CSS.supports('top: env(safe-area-inset-top)')) {\n support = 'env'\n } else if (CSS.supports('top: constant(safe-area-inset-top)')) {\n support = 'constant'\n } else {\n return emptyInsets;\n }\n const id = uniqueId();\n const style = document.createElement('style');\n style.textContent = `:root {\n --${id}-top: ${support}(safe-area-inset-top);\n --${id}-left: ${support}(safe-area-inset-left);\n --${id}-right: ${support}(safe-area-inset-right);\n --${id}-bottom: ${support}(safe-area-inset-bottom);\n }`;\n document.head.appendChild(style);\n const computedStyle = getComputedStyle(document.documentElement);\n const insets = {\n top: computedStyle.getPropertyValue(`--${id}-top`),\n left: computedStyle.getPropertyValue(`--${id}-left`),\n right: computedStyle.getPropertyValue(`--${id}-right`),\n bottom: computedStyle.getPropertyValue(`--${id}-bottom`),\n };\n style.remove();\n return _.mapValues(insets, v => parseFloat(v));\n}\n\nexport const useWindowMetrics = () => useSyncExternalStore((onStoreChange) => {\n window.addEventListener('resize', onStoreChange);\n return () => {\n window.removeEventListener('resize', onStoreChange);\n };\n}, () => ({\n safeAreaInsets: safeAreaInsets(),\n devicePixelRatio: window.devicePixelRatio,\n outerWidth: window.outerWidth,\n outerHeight: window.outerHeight,\n innerWidth: window.innerWidth,\n innerHeight: window.innerHeight,\n}), () => ({\n safeAreaInsets: emptyInsets,\n devicePixelRatio: 1,\n outerWidth: 0,\n outerHeight: 0,\n innerWidth: 0,\n innerHeight: 0,\n}));\n\nexport const useWindowScroll = () => useSyncExternalStore((onStoreChange) => {\n window.addEventListener('scroll', onStoreChange);\n return () => {\n window.removeEventListener('scroll', onStoreChange);\n };\n}, () => ({\n scrollX: window.scrollX,\n scrollY: window.scrollY,\n}), () => ({\n scrollX: 0,\n scrollY: 0,\n}));\n\nexport const useColorScheme = () => useSyncExternalStore((onStoreChange) => {\n colorSchemeDark?.addEventListener('change', onStoreChange);\n return () => {\n colorSchemeDark?.removeEventListener('change', onStoreChange);\n };\n}, () => colorSchemeDark?.matches ? 'dark' : 'light', () => 'light');\n"],"names":["state","reconciler","_DOMRenderer","emitters","emitterFor","EventEmitter","useSyncExternalStore","useMemo","useCallback","useEffect","uniqueId"],"mappings":";;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAMO,MAAM,WAAW,GAAG,MAAK;AAC9B,IAAA,MAAMA,OAAK,GAAGC,gBAAU,CAAC,gBAAgB;AACzC,IAAA,IAAI,CAACD,OAAK;AAAE,QAAA,MAAM,KAAK,CAAC,oDAAoD,CAAC;AAC7E,IAAA,IAAIA,OAAK,CAAC,QAAQ,YAAYE,mBAAY,EAAE;AAC1C,QAAA,OAAOF,OAAK,CAAC,QAAQ,CAAC,GAAG;;SACpB;AACL,QAAA,MAAM,KAAK,CAAC,uBAAuB,CAAC;;AAExC;;ACrCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AASA,MAAMG,UAAQ,GAAG,IAAI,OAAO,EAA0B;AACtD,MAAMC,YAAU,GAAG,CAAC,QAAkB,KAAI;AACxC,IAAA,IAAI,CAACD,UAAQ,CAAC,GAAG,CAAC,QAAQ,CAAC;QAAEA,UAAQ,CAAC,GAAG,CAAC,QAAQ,EAAE,IAAIE,kBAAY,EAAE,CAAC;AACvE,IAAA,OAAOF,UAAQ,CAAC,GAAG,CAAC,QAAQ,CAAE;AAChC,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;AAyBG;AACI,MAAM,WAAW,GAAG,MAAK;AAC9B,IAAA,MAAM,QAAQ,GAAG,WAAW,EAAE;AAC9B,IAAA,MAAM,OAAO,GAAGC,YAAU,CAAC,QAAQ,CAAC;AACpC,IAAA,MAAM,MAAM,GAAG,CAAC,OAAiB,MAAM;QACrC,GAAG,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,QAAQ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