@manyducks.co/dolla 2.0.0-alpha.65 → 2.0.0-alpha.67

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.
@@ -7,6 +7,7 @@ export { m, Markup, MarkupNode, portal, render, repeat, unless, when } from "./m
7
7
  export { ref, type Ref } from "./ref.js";
8
8
  export { For, type ForProps } from "./views/for.js";
9
9
  export { Show, type ShowProps } from "./views/show.js";
10
+ export { Portal, type PortalProps } from "./views/portal.js";
10
11
  export { deepEqual, shallowEqual, strictEqual } from "../utils.js";
11
12
  export { getEnv, setEnv } from "./env.js";
12
13
  export { createLogger, onLoggerCrash, setLogFilter, setLogLevels } from "./logger.js";
@@ -2,7 +2,7 @@ import type { IntrinsicElements, Renderable, View } from "../types.js";
2
2
  import { Context } from "./context.js";
3
3
  import { MarkupNode } from "./nodes/_markup.js";
4
4
  import { KeyFn, RenderFn } from "./nodes/repeat.js";
5
- import { type Signal, type MaybeSignal } from "./signals.js";
5
+ import { type MaybeSignal, type Signal } from "./signals.js";
6
6
  export { MarkupNode };
7
7
  type PropsOf<V extends string | View<any>> = V extends View<infer U> ? U : any;
8
8
  /**
@@ -74,19 +74,27 @@ export declare function m<P extends {}>(type: View<P>, props?: P): Markup;
74
74
  export declare function m<P>(type: View<P>, props: P): Markup;
75
75
  /**
76
76
  * If `condition` is truthy, displays `thenContent`, otherwise `elseContent`.
77
+ *
78
+ * @deprecated use `Show` view with `when` prop.
77
79
  */
78
80
  export declare function when(condition: MaybeSignal<any>, thenContent?: Renderable, elseContent?: Renderable): Markup;
79
81
  /**
80
82
  * Inverted `when`. If `condition` is falsy, displays `thenContent`, otherwise `elseContent`.
83
+ *
84
+ * @deprecated use `Show` view with `unless` prop.
81
85
  */
82
86
  export declare function unless(condition: MaybeSignal<any>, thenContent?: Renderable, elseContent?: Renderable): Markup;
83
87
  /**
84
88
  * Calls `render` for each item in `items`. Dynamically adds and removes views as items change.
85
89
  * The result of `key` is used to compare items and decide if item was added, removed or updated.
90
+ *
91
+ * @deprecated use `For` view
86
92
  */
87
93
  export declare function repeat<T>(items: MaybeSignal<T[]>, key: KeyFn<T>, render: RenderFn<T>): Markup;
88
94
  /**
89
95
  * Renders `content` into a `parent` node anywhere in the page, rather than its usual position in the view.
96
+ *
97
+ * @deprecated use `Portal` view
90
98
  */
91
99
  export declare function portal(parent: Element, content: Renderable): Markup;
92
100
  /**
@@ -32,14 +32,35 @@ export interface SignalOptions<T> {
32
32
  */
33
33
  equals?: EqualityFn<T>;
34
34
  }
35
+ /**
36
+ * @deprecated use `signal()` and `memo()` directly
37
+ */
35
38
  export declare function $<T>(compute: (previousValue?: T) => MaybeSignal<T>, options?: MemoOptions<T>): Signal<T>;
39
+ /**
40
+ * @deprecated use `signal()` and `memo()` directly
41
+ */
36
42
  export declare function $<T>(): Writable<T | undefined>;
43
+ /**
44
+ * @deprecated use `signal()` and `memo()` directly
45
+ */
37
46
  export declare function $<T>(initialValue: undefined, options: SignalOptions<T | undefined>): Writable<T | undefined>;
47
+ /**
48
+ * @deprecated use `signal()` and `memo()` directly
49
+ */
38
50
  export declare function $<T>(initialValue: T, options?: SignalOptions<T>): Writable<T>;
39
51
  export declare function writable<T>(): Writable<T | undefined>;
40
52
  export declare function writable<T>(initialValue: undefined, options: SignalOptions<T | undefined>): Writable<T | undefined>;
41
53
  export declare function writable<T>(initialValue: T, options?: SignalOptions<T>): Writable<T>;
42
54
  export declare function readable<T>(signal: MaybeSignal<T>): Signal<T>;
55
+ /**
56
+ * Creates a new signal, returning a bound getter and setter pair.
57
+ *
58
+ * @example
59
+ * const [$count, setCount] = signal(0);
60
+ */
61
+ export declare function signal<T>(initialValue: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>];
62
+ export declare function signal<T>(initialValue: undefined, options: SignalOptions<T>): [Signal<T | undefined>, Setter<T | undefined>];
63
+ export declare function signal<T>(): [Signal<T | undefined>, Setter<T | undefined>];
43
64
  export interface MemoOptions<T> extends SignalOptions<T> {
44
65
  /**
45
66
  * An array of signals this `memo` depends on. If this is passed, calls to signals within `fn` will NOT be tracked.
@@ -0,0 +1,17 @@
1
+ import type { Renderable } from "../../types";
2
+ import type { Context } from "../context";
3
+ import { Markup, MarkupType } from "../markup";
4
+ export interface PortalProps {
5
+ /**
6
+ * The parent element or a selector that will match it.
7
+ */
8
+ into: Element | string;
9
+ /**
10
+ * Content to render inside the `into` element.
11
+ */
12
+ children: Renderable;
13
+ }
14
+ /**
15
+ * Render content into any element on the page.
16
+ */
17
+ export declare function Portal(props: PortalProps, ctx: Context): Markup<MarkupType.Portal>;
@@ -11,31 +11,47 @@ export declare function useContext(): Context;
11
11
  export declare function useLogger(name?: MaybeSignal<string>): Logger;
12
12
  /**
13
13
  * Creates a new read-only Getter and a bound Setter function.
14
+ * @deprecated prefer useSignal
14
15
  */
15
16
  export declare function useState<T>(value: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>];
16
17
  /**
17
18
  * Creates a new read-only Signal and a bound Setter function.
19
+ * @deprecated prefer useSignal
18
20
  */
19
21
  export declare function useState<T>(value: undefined, options: SignalOptions<T>): [Signal<T | undefined>, Setter<T | undefined>];
20
22
  /**
21
23
  * Creates a new read-only Signal and a bound Setter function.
24
+ * @deprecated prefer useSignal
22
25
  */
23
26
  export declare function useState<T>(): [Signal<T | undefined>, Setter<T | undefined>];
27
+ /**
28
+ * Creates a new read-only Signal. Returns bound Getter and Setter functions.
29
+ *
30
+ * @example
31
+ * const [$count, setCount] = useSignal(5);
32
+ * $count(); // 5
33
+ * setCount(6);
34
+ * setCount((current) => current + 1);
35
+ * $count(); // 7
36
+ */
37
+ export declare function useSignal<T>(value: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>];
38
+ export declare function useSignal<T>(value: undefined, options: SignalOptions<T>): [Signal<T | undefined>, Setter<T | undefined>];
39
+ export declare function useSignal<T>(): [Signal<T | undefined>, Setter<T | undefined>];
24
40
  export declare function useMemo<T>(compute: (current?: T) => MaybeSignal<T>, deps?: Signal<any>[], options?: SignalOptions<T>): Signal<T>;
25
41
  export declare function useEffect(fn: EffectFn, deps?: Signal<any>[]): void;
26
42
  /**
27
43
  * Takes the current state and a dispatched action. Returns a new state based on the action.
28
44
  * Typically the body of this function will be a large switch statement.
29
45
  */
30
- export type ReducerFn<State, Action> = (state: State, action: Action) => State;
46
+ export type Reducer<State, Action> = (state: State, action: Action) => State;
31
47
  /**
32
48
  * Dispatches an action to this reducer, causing the state to update.
33
49
  */
34
- export type DispatchFn<Action> = (action: Action) => void;
50
+ export type Dispatcher<Action> = (action: Action) => void;
35
51
  /**
36
52
  *
37
53
  */
38
- export declare function useReducer<State, Action>(reducer: ReducerFn<State, Action>, initialState: State): [Signal<State>, DispatchFn<Action>];
54
+ export declare function useReducer<State, Action>(reducer: Reducer<State, Action>, initialState: State): [Signal<State>, Dispatcher<Action>];
39
55
  /**
40
56
  * Uses a previously added Store. Takes the Store function itself and returns the nearest instance.
41
57
  */
package/dist/hooks.js CHANGED
@@ -1,64 +1,68 @@
1
- import { w as s, m as f, g as i, u as a, h as x } from "./signals-BDlRtifZ.js";
2
- import { r as m } from "./ref-BD79iqlg.js";
1
+ import { w as s, h as f, m as i, g as a, u as x, i as m } from "./signals-HNnDUJRQ.js";
2
+ import { r as g } from "./ref-BD79iqlg.js";
3
3
  function o() {
4
- const t = x();
4
+ const t = m();
5
5
  if (!t)
6
6
  throw new Error("No context found; hooks can only be called in the body of a View, Store or Mixin.");
7
7
  return t;
8
8
  }
9
- function p(t) {
9
+ function S(t) {
10
10
  const e = o();
11
11
  return t && e.setName(t), e;
12
12
  }
13
- function d(t, e) {
13
+ function w(t, e) {
14
14
  o();
15
15
  const n = s(t, e);
16
16
  return [() => n(), n.set];
17
17
  }
18
- function w(t, e, n) {
19
- return o(), f(t, { ...n, deps: e });
18
+ function l(t, e) {
19
+ return o(), f(t, e);
20
20
  }
21
- function S(t, e) {
21
+ function b(t, e, n) {
22
+ return o(), i(t, { ...n, deps: e });
23
+ }
24
+ function M(t, e) {
22
25
  const n = o();
23
26
  e ? n.effect(() => {
24
- for (const c of e) i(c);
25
- a(t);
27
+ for (const r of e) a(r);
28
+ return x(t);
26
29
  }) : n.effect(t);
27
30
  }
28
- function b(t, e) {
29
- const [n, c] = d(e);
30
- return [n, (r) => {
31
- c((u) => t(u, r));
31
+ function y(t, e) {
32
+ const [n, r] = l(e);
33
+ return [n, (u) => {
34
+ r((c) => t(c, u));
32
35
  }];
33
36
  }
34
- function M(t) {
37
+ function C(t) {
35
38
  return o().getStore(t);
36
39
  }
37
- function y(...t) {
40
+ function R(...t) {
38
41
  o();
39
- const e = m(...t);
42
+ const e = g(...t);
40
43
  return Object.defineProperty(e, "current", { get: e, set: e }), e;
41
44
  }
42
- function C(t) {
45
+ function U(t) {
43
46
  const e = o();
44
47
  e.onMount(() => {
45
48
  const n = t();
46
49
  n && e.onUnmount(n);
47
50
  });
48
51
  }
49
- function R(t) {
52
+ function k(t) {
50
53
  o().onUnmount(t);
51
54
  }
52
55
  export {
53
56
  o as useContext,
54
- S as useEffect,
55
- p as useLogger,
56
- w as useMemo,
57
- C as useMount,
58
- b as useReducer,
59
- y as useRef,
60
- d as useState,
61
- M as useStore,
62
- R as useUnmount
57
+ M as useEffect,
58
+ S as useLogger,
59
+ b as useMemo,
60
+ U as useMount,
61
+ y as useReducer,
62
+ R as useRef,
63
+ l as useSignal,
64
+ w as useState,
65
+ C as useStore,
66
+ k as useUnmount
63
67
  };
64
68
  //# sourceMappingURL=hooks.js.map
package/dist/hooks.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"hooks.js","sources":["../src/hooks/index.ts"],"sourcesContent":["import { type Context, type Logger, ref, type Ref, type Store } from \"../core\";\nimport {\n type EffectFn,\n get,\n getCurrentContext,\n type MaybeSignal,\n memo,\n type Setter,\n type Signal,\n type SignalOptions,\n untracked,\n writable,\n} from \"../core/signals\";\n\n/**\n * Returns the Context object of the View, Store or Mixin this hook is called in.\n */\nexport function useContext(): Context {\n const context = getCurrentContext();\n if (!context) {\n throw new Error(`No context found; hooks can only be called in the body of a View, Store or Mixin.`);\n }\n return context;\n}\n\n/**\n * Returns a logger. If a name is passed it will be used as a prefix for all console messages.\n * Otherwise the default name of the context will be used.\n */\nexport function useLogger(name?: MaybeSignal<string>): Logger {\n const context = useContext();\n if (name) context.setName(name);\n return context;\n}\n\n/**\n * Creates a new read-only Getter and a bound Setter function.\n */\nexport function useState<T>(value: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>];\n\n/**\n * Creates a new read-only Signal and a bound Setter function.\n */\nexport function useState<T>(\n value: undefined,\n options: SignalOptions<T>,\n): [Signal<T | undefined>, Setter<T | undefined>];\n\n/**\n * Creates a new read-only Signal and a bound Setter function.\n */\nexport function useState<T>(): [Signal<T | undefined>, Setter<T | undefined>];\n\nexport function useState<T>(value?: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>] {\n useContext(); // assert that we're in a valid context\n const state = writable(value as T, options);\n return [() => state(), state.set];\n}\n\nexport function useMemo<T>(\n compute: (current?: T) => MaybeSignal<T>,\n deps?: Signal<any>[],\n options?: SignalOptions<T>,\n): Signal<T> {\n useContext(); // assert that we're in a valid context\n return memo(compute, { ...options, deps });\n}\n\nexport function useEffect(fn: EffectFn, deps?: Signal<any>[]): void {\n const context = useContext();\n if (deps) {\n context.effect(() => {\n for (const dep of deps) get(dep);\n untracked(fn);\n });\n } else {\n context.effect(fn);\n }\n}\n\n/**\n * Takes the current state and a dispatched action. Returns a new state based on the action.\n * Typically the body of this function will be a large switch statement.\n */\nexport type ReducerFn<State, Action> = (state: State, action: Action) => State;\n\n/**\n * Dispatches an action to this reducer, causing the state to update.\n */\nexport type DispatchFn<Action> = (action: Action) => void;\n\n/**\n *\n */\nexport function useReducer<State, Action>(\n reducer: ReducerFn<State, Action>,\n initialState: State,\n): [Signal<State>, DispatchFn<Action>] {\n const [state, setState] = useState(initialState);\n const dispatch = (action: Action) => {\n setState((current) => reducer(current, action));\n };\n return [state, dispatch];\n}\n\n/**\n * Uses a previously added Store. Takes the Store function itself and returns the nearest instance.\n */\nexport function useStore<T>(store: Store<any, T>): T {\n const context = useContext();\n return context.getStore(store);\n}\n\n/**\n * A hybrid Ref which is both a function ref and a React-style object ref with a `current` property.\n * Both the `current` property and the function syntax access the same value.\n */\nexport interface HybridRef<T> extends Ref<T> {\n current: T;\n}\n\n/**\n * Creates a Ref. Useful for getting references to DOM nodes.\n */\nexport function useRef<T>(initialValue?: T): HybridRef<T>;\n\nexport function useRef<T>(...value: [T]): HybridRef<T> {\n useContext(); // assert that we're in a valid context\n const valueRef = ref(...value);\n Object.defineProperty(valueRef, \"current\", { get: valueRef, set: valueRef });\n return valueRef as HybridRef<T>;\n}\n\n/**\n * Calls `callback` when the context is mounted. If `callback` returns a function, that function is called when the context is unmounted.\n */\nexport function useMount(callback: () => void | (() => void)): void {\n const context = useContext();\n context.onMount(() => {\n const result = callback();\n if (result) context.onUnmount(result);\n });\n}\n\n/**\n * Calls `callback` when the context is unmounted.\n */\nexport function useUnmount(callback: () => void): void {\n const context = useContext();\n context.onUnmount(callback);\n}\n"],"names":["useContext","context","getCurrentContext","useLogger","name","useState","value","options","state","writable","useMemo","compute","deps","memo","useEffect","fn","dep","get","untracked","useReducer","reducer","initialState","setState","action","current","useStore","store","useRef","valueRef","ref","useMount","callback","result","useUnmount"],"mappings":";;AAiBO,SAASA,IAAsB;AACpC,QAAMC,IAAUC,EAAkB;AAClC,MAAI,CAACD;AACG,UAAA,IAAI,MAAM,mFAAmF;AAE9F,SAAAA;AACT;AAMO,SAASE,EAAUC,GAAoC;AAC5D,QAAMH,IAAUD,EAAW;AACvB,SAAAI,KAAcH,EAAA,QAAQG,CAAI,GACvBH;AACT;AAoBgB,SAAAI,EAAYC,GAAWC,GAAoD;AAC9E,EAAAP,EAAA;AACL,QAAAQ,IAAQC,EAASH,GAAYC,CAAO;AAC1C,SAAO,CAAC,MAAMC,KAASA,EAAM,GAAG;AAClC;AAEgB,SAAAE,EACdC,GACAC,GACAL,GACW;AACA,SAAAP,EAAA,GACJa,EAAKF,GAAS,EAAE,GAAGJ,GAAS,MAAAK,GAAM;AAC3C;AAEgB,SAAAE,EAAUC,GAAcH,GAA4B;AAClE,QAAMX,IAAUD,EAAW;AAC3B,EAAIY,IACFX,EAAQ,OAAO,MAAM;AACR,eAAAe,KAAOJ,EAAM,CAAAK,EAAID,CAAG;AAC/B,IAAAE,EAAUH,CAAE;AAAA,EAAA,CACb,IAEDd,EAAQ,OAAOc,CAAE;AAErB;AAgBgB,SAAAI,EACdC,GACAC,GACqC;AACrC,QAAM,CAACb,GAAOc,CAAQ,IAAIjB,EAASgB,CAAY;AAIxC,SAAA,CAACb,GAHS,CAACe,MAAmB;AACnC,IAAAD,EAAS,CAACE,MAAYJ,EAAQI,GAASD,CAAM,CAAC;AAAA,EAChD,CACuB;AACzB;AAKO,SAASE,EAAYC,GAAyB;AAE5C,SADS1B,EAAW,EACZ,SAAS0B,CAAK;AAC/B;AAeO,SAASC,KAAarB,GAA0B;AAC1C,EAAAN,EAAA;AACL,QAAA4B,IAAWC,EAAI,GAAGvB,CAAK;AACtB,gBAAA,eAAesB,GAAU,WAAW,EAAE,KAAKA,GAAU,KAAKA,GAAU,GACpEA;AACT;AAKO,SAASE,EAASC,GAA2C;AAClE,QAAM9B,IAAUD,EAAW;AAC3B,EAAAC,EAAQ,QAAQ,MAAM;AACpB,UAAM+B,IAASD,EAAS;AACpB,IAAAC,KAAgB/B,EAAA,UAAU+B,CAAM;AAAA,EAAA,CACrC;AACH;AAKO,SAASC,EAAWF,GAA4B;AAErD,EADgB/B,EAAW,EACnB,UAAU+B,CAAQ;AAC5B;"}
1
+ {"version":3,"file":"hooks.js","sources":["../src/hooks/index.ts"],"sourcesContent":["import { type Context, type Logger, ref, type Ref, type Store } from \"../core\";\nimport {\n type EffectFn,\n get,\n getCurrentContext,\n type MaybeSignal,\n memo,\n type Setter,\n signal,\n type Signal,\n type SignalOptions,\n untracked,\n writable,\n} from \"../core/signals\";\n\n/**\n * Returns the Context object of the View, Store or Mixin this hook is called in.\n */\nexport function useContext(): Context {\n const context = getCurrentContext();\n if (!context) {\n throw new Error(`No context found; hooks can only be called in the body of a View, Store or Mixin.`);\n }\n return context;\n}\n\n/**\n * Returns a logger. If a name is passed it will be used as a prefix for all console messages.\n * Otherwise the default name of the context will be used.\n */\nexport function useLogger(name?: MaybeSignal<string>): Logger {\n const context = useContext();\n if (name) context.setName(name);\n return context;\n}\n\n/**\n * Creates a new read-only Getter and a bound Setter function.\n * @deprecated prefer useSignal\n */\nexport function useState<T>(value: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>];\n\n/**\n * Creates a new read-only Signal and a bound Setter function.\n * @deprecated prefer useSignal\n */\nexport function useState<T>(\n value: undefined,\n options: SignalOptions<T>,\n): [Signal<T | undefined>, Setter<T | undefined>];\n\n/**\n * Creates a new read-only Signal and a bound Setter function.\n * @deprecated prefer useSignal\n */\nexport function useState<T>(): [Signal<T | undefined>, Setter<T | undefined>];\n\nexport function useState<T>(value?: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>] {\n useContext(); // assert that we're in a valid context\n const state = writable(value as T, options);\n return [() => state(), state.set];\n}\n\n/**\n * Creates a new read-only Signal. Returns bound Getter and Setter functions.\n *\n * @example\n * const [$count, setCount] = useSignal(5);\n * $count(); // 5\n * setCount(6);\n * setCount((current) => current + 1);\n * $count(); // 7\n */\nexport function useSignal<T>(value: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>];\n\nexport function useSignal<T>(\n value: undefined,\n options: SignalOptions<T>,\n): [Signal<T | undefined>, Setter<T | undefined>];\n\nexport function useSignal<T>(): [Signal<T | undefined>, Setter<T | undefined>];\n\nexport function useSignal<T>(value?: T, options?: SignalOptions<T>): [Signal<T>, Setter<T>] {\n useContext(); // assert that we're in a valid context\n return signal(value as T, options);\n}\n\nexport function useMemo<T>(\n compute: (current?: T) => MaybeSignal<T>,\n deps?: Signal<any>[],\n options?: SignalOptions<T>,\n): Signal<T> {\n useContext(); // assert that we're in a valid context\n return memo(compute, { ...options, deps });\n}\n\nexport function useEffect(fn: EffectFn, deps?: Signal<any>[]): void {\n const context = useContext();\n if (deps) {\n context.effect(() => {\n for (const dep of deps) get(dep);\n return untracked(fn);\n });\n } else {\n context.effect(fn);\n }\n}\n\n/**\n * Takes the current state and a dispatched action. Returns a new state based on the action.\n * Typically the body of this function will be a large switch statement.\n */\nexport type Reducer<State, Action> = (state: State, action: Action) => State;\n\n/**\n * Dispatches an action to this reducer, causing the state to update.\n */\nexport type Dispatcher<Action> = (action: Action) => void;\n\n/**\n *\n */\nexport function useReducer<State, Action>(\n reducer: Reducer<State, Action>,\n initialState: State,\n): [Signal<State>, Dispatcher<Action>] {\n const [$state, setState] = useSignal(initialState);\n const dispatch = (action: Action) => {\n setState((current) => reducer(current, action));\n };\n return [$state, dispatch];\n}\n\n/**\n * Uses a previously added Store. Takes the Store function itself and returns the nearest instance.\n */\nexport function useStore<T>(store: Store<any, T>): T {\n const context = useContext();\n return context.getStore(store);\n}\n\n/**\n * A hybrid Ref which is both a function ref and a React-style object ref with a `current` property.\n * Both the `current` property and the function syntax access the same value.\n */\nexport interface HybridRef<T> extends Ref<T> {\n current: T;\n}\n\n/**\n * Creates a Ref. Useful for getting references to DOM nodes.\n */\nexport function useRef<T>(initialValue?: T): HybridRef<T>;\n\nexport function useRef<T>(...value: [T]): HybridRef<T> {\n useContext(); // assert that we're in a valid context\n const valueRef = ref(...value);\n Object.defineProperty(valueRef, \"current\", { get: valueRef, set: valueRef });\n return valueRef as HybridRef<T>;\n}\n\n/**\n * Calls `callback` when the context is mounted. If `callback` returns a function, that function is called when the context is unmounted.\n */\nexport function useMount(callback: () => void | (() => void)): void {\n const context = useContext();\n context.onMount(() => {\n const result = callback();\n if (result) context.onUnmount(result);\n });\n}\n\n/**\n * Calls `callback` when the context is unmounted.\n */\nexport function useUnmount(callback: () => void): void {\n const context = useContext();\n context.onUnmount(callback);\n}\n"],"names":["useContext","context","getCurrentContext","useLogger","name","useState","value","options","state","writable","useSignal","signal","useMemo","compute","deps","memo","useEffect","fn","dep","get","untracked","useReducer","reducer","initialState","$state","setState","action","current","useStore","store","useRef","valueRef","ref","useMount","callback","result","useUnmount"],"mappings":";;AAkBO,SAASA,IAAsB;AACpC,QAAMC,IAAUC,EAAkB;AAClC,MAAI,CAACD;AACG,UAAA,IAAI,MAAM,mFAAmF;AAE9F,SAAAA;AACT;AAMO,SAASE,EAAUC,GAAoC;AAC5D,QAAMH,IAAUD,EAAW;AACvB,SAAAI,KAAcH,EAAA,QAAQG,CAAI,GACvBH;AACT;AAuBgB,SAAAI,EAAYC,GAAWC,GAAoD;AAC9E,EAAAP,EAAA;AACL,QAAAQ,IAAQC,EAASH,GAAYC,CAAO;AAC1C,SAAO,CAAC,MAAMC,KAASA,EAAM,GAAG;AAClC;AAqBgB,SAAAE,EAAaJ,GAAWC,GAAoD;AAC/E,SAAAP,EAAA,GACJW,EAAOL,GAAYC,CAAO;AACnC;AAEgB,SAAAK,EACdC,GACAC,GACAP,GACW;AACA,SAAAP,EAAA,GACJe,EAAKF,GAAS,EAAE,GAAGN,GAAS,MAAAO,GAAM;AAC3C;AAEgB,SAAAE,EAAUC,GAAcH,GAA4B;AAClE,QAAMb,IAAUD,EAAW;AAC3B,EAAIc,IACFb,EAAQ,OAAO,MAAM;AACR,eAAAiB,KAAOJ,EAAM,CAAAK,EAAID,CAAG;AAC/B,WAAOE,EAAUH,CAAE;AAAA,EAAA,CACpB,IAEDhB,EAAQ,OAAOgB,CAAE;AAErB;AAgBgB,SAAAI,EACdC,GACAC,GACqC;AACrC,QAAM,CAACC,GAAQC,CAAQ,IAAIf,EAAUa,CAAY;AAI1C,SAAA,CAACC,GAHS,CAACE,MAAmB;AACnC,IAAAD,EAAS,CAACE,MAAYL,EAAQK,GAASD,CAAM,CAAC;AAAA,EAChD,CACwB;AAC1B;AAKO,SAASE,EAAYC,GAAyB;AAE5C,SADS7B,EAAW,EACZ,SAAS6B,CAAK;AAC/B;AAeO,SAASC,KAAaxB,GAA0B;AAC1C,EAAAN,EAAA;AACL,QAAA+B,IAAWC,EAAI,GAAG1B,CAAK;AACtB,gBAAA,eAAeyB,GAAU,WAAW,EAAE,KAAKA,GAAU,KAAKA,GAAU,GACpEA;AACT;AAKO,SAASE,EAASC,GAA2C;AAClE,QAAMjC,IAAUD,EAAW;AAC3B,EAAAC,EAAQ,QAAQ,MAAM;AACpB,UAAMkC,IAASD,EAAS;AACpB,IAAAC,KAAgBlC,EAAA,UAAUkC,CAAM;AAAA,EAAA,CACrC;AACH;AAKO,SAASC,EAAWF,GAA4B;AAErD,EADgBlC,EAAW,EACnB,UAAUkC,CAAQ;AAC5B;"}
package/dist/http.js CHANGED
@@ -6,7 +6,7 @@ var g = (r, e, t) => e in r ? b(r, e, { enumerable: !0, configurable: !0, writab
6
6
  var a = (r, e, t) => g(r, typeof e != "symbol" ? e + "" : e, t), m = (r, e, t) => e.has(r) || f("Cannot " + t);
7
7
  var d = (r, e, t) => (m(r, e, "read from private field"), t ? t.call(r) : e.get(r)), c = (r, e, t) => e.has(r) ? f("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(r) : e.set(r, t);
8
8
  var o = (r, e, t) => (m(r, e, "access private method"), t);
9
- import { i as w } from "./typeChecking-D0-H8_Xm.js";
9
+ import { a as w } from "./typeChecking-Cw-4pIto.js";
10
10
  var l, p, i, h;
11
11
  class O {
12
12
  constructor() {
package/dist/i18n.js CHANGED
@@ -5,9 +5,9 @@ var D = (o) => {
5
5
  var J = (o, t, e) => t in o ? B(o, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : o[t] = e;
6
6
  var O = (o, t, e) => J(o, typeof t != "symbol" ? t + "" : t, e), _ = (o, t, e) => t.has(o) || D("Cannot " + e);
7
7
  var r = (o, t, e) => (_(o, t, "read from private field"), e ? e.call(o) : t.get(o)), m = (o, t, e) => t.has(o) ? D("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(o) : t.set(o, e), N = (o, t, e, n) => (_(o, t, "write to private field"), n ? n.call(o, e) : t.set(o, e), e), g = (o, t, e) => (_(o, t, "access private method"), e);
8
- import { c as K } from "./logger-BuZRMjzE.js";
9
- import { w as Q, m as k, d as U, g as x } from "./signals-BDlRtifZ.js";
10
- import { a as C, i as j, b as W, t as P } from "./typeChecking-D0-H8_Xm.js";
8
+ import { c as K } from "./logger-BcgYqLUO.js";
9
+ import { w as Q, m as k, d as U, g as x } from "./signals-HNnDUJRQ.js";
10
+ import { i as C, a as j, b as W, t as P } from "./typeChecking-Cw-4pIto.js";
11
11
  var I, F, p, S, G;
12
12
  class X {
13
13
  constructor(t) {
@@ -13,10 +13,10 @@ var D = (r, t, e, n) => ({
13
13
  return l(r, t, n);
14
14
  }
15
15
  });
16
- import { c as st } from "./logger-BuZRMjzE.js";
17
- import { D as at, V as it, m as ot, d as ct } from "./markup-DsJHUuod.js";
18
- import { w as F, m as U, d as lt, s as B, u as J, b as ht, h as ut } from "./signals-BDlRtifZ.js";
19
- import { c as ft, d as Y, b as Q, e as pt, f as X, i as dt, a as A, g as mt } from "./typeChecking-D0-H8_Xm.js";
16
+ import { c as st } from "./logger-BcgYqLUO.js";
17
+ import { D as at, V as it, m as ot, a as ct } from "./markup-BgNq6mZF.js";
18
+ import { w as F, m as U, d as lt, s as B, u as J, b as ht, i as ut } from "./signals-HNnDUJRQ.js";
19
+ import { c as ft, d as Y, b as Q, e as pt, f as X, a as dt, i as A, g as mt } from "./typeChecking-Cw-4pIto.js";
20
20
  function W(r) {
21
21
  return Y(r, "Expected `path` to be a string. Got type: %t, value: %v"), r.split("/").map((t) => t.trim()).filter((t) => t !== "");
22
22
  }
@@ -553,4 +553,4 @@ export {
553
553
  Wt as c,
554
554
  Ot as u
555
555
  };
556
- //# sourceMappingURL=index-Bh8JrCt1.js.map
556
+ //# sourceMappingURL=index-DKMlSUEt.js.map