@fictjs/runtime 0.14.0 → 0.15.0

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.
Files changed (53) hide show
  1. package/dist/advanced.cjs +9 -9
  2. package/dist/advanced.d.cts +3 -3
  3. package/dist/advanced.d.ts +3 -3
  4. package/dist/advanced.js +4 -4
  5. package/dist/{binding-FRyTeLDn.d.cts → binding-BlABuUiG.d.cts} +2 -2
  6. package/dist/{binding-DcnhUSQK.d.ts → binding-CQUGLLBI.d.ts} +2 -2
  7. package/dist/{chunk-4GEXXASF.js → chunk-4P4DYWLQ.js} +3 -3
  8. package/dist/{chunk-IEYESQRE.cjs → chunk-AR2T7JEX.cjs} +269 -211
  9. package/dist/chunk-AR2T7JEX.cjs.map +1 -0
  10. package/dist/{chunk-HAFRB2OT.cjs → chunk-BADX4WTQ.cjs} +17 -17
  11. package/dist/{chunk-HAFRB2OT.cjs.map → chunk-BADX4WTQ.cjs.map} +1 -1
  12. package/dist/{chunk-BW4GNOOZ.cjs → chunk-CBRGOLTR.cjs} +40 -40
  13. package/dist/{chunk-BW4GNOOZ.cjs.map → chunk-CBRGOLTR.cjs.map} +1 -1
  14. package/dist/{chunk-FXDZVFEP.cjs → chunk-ECNK25S4.cjs} +8 -8
  15. package/dist/{chunk-FXDZVFEP.cjs.map → chunk-ECNK25S4.cjs.map} +1 -1
  16. package/dist/{chunk-A5K2MPZW.js → chunk-MAHWGB55.js} +11 -4
  17. package/dist/{chunk-A5K2MPZW.js.map → chunk-MAHWGB55.js.map} +1 -1
  18. package/dist/{chunk-VEBU7SMW.js → chunk-RK2WSQYL.js} +3 -3
  19. package/dist/{chunk-R2WMNQGO.cjs → chunk-WJMZ7X46.cjs} +11 -4
  20. package/dist/chunk-WJMZ7X46.cjs.map +1 -0
  21. package/dist/{chunk-E6A6PCTW.js → chunk-ZJZ6LMDN.js} +78 -20
  22. package/dist/chunk-ZJZ6LMDN.js.map +1 -0
  23. package/dist/{chunk-NPSPJGD4.js → chunk-ZWQLXWSV.js} +3 -3
  24. package/dist/{devtools-D2z4llpA.d.ts → devtools-DNnnDGu1.d.ts} +1 -1
  25. package/dist/{devtools-BtIkN77t.d.cts → devtools-DWIZRe7L.d.cts} +1 -1
  26. package/dist/index.cjs +42 -42
  27. package/dist/index.d.cts +4 -4
  28. package/dist/index.d.ts +4 -4
  29. package/dist/index.dev.js +1 -0
  30. package/dist/index.dev.js.map +1 -1
  31. package/dist/index.js +3 -3
  32. package/dist/internal-list.cjs +4 -4
  33. package/dist/internal-list.js +3 -3
  34. package/dist/internal.cjs +5 -5
  35. package/dist/internal.d.cts +3 -3
  36. package/dist/internal.d.ts +3 -3
  37. package/dist/internal.js +4 -4
  38. package/dist/loader.cjs +18 -18
  39. package/dist/loader.js +1 -1
  40. package/dist/{props-D1nj2p_3.d.ts → props-DabFQwLR.d.ts} +1 -1
  41. package/dist/{props-9chMyBGb.d.cts → props-tImUZAty.d.cts} +1 -1
  42. package/dist/{scope-Bn3sxem5.d.cts → scope-GwC4DJ50.d.cts} +1 -1
  43. package/dist/{scope-BSkhJr0a.d.ts → scope-gpOMWTlf.d.ts} +1 -1
  44. package/package.json +1 -1
  45. package/src/binding.ts +92 -19
  46. package/src/resume.ts +7 -3
  47. package/src/store.ts +4 -1
  48. package/dist/chunk-E6A6PCTW.js.map +0 -1
  49. package/dist/chunk-IEYESQRE.cjs.map +0 -1
  50. package/dist/chunk-R2WMNQGO.cjs.map +0 -1
  51. /package/dist/{chunk-4GEXXASF.js.map → chunk-4P4DYWLQ.js.map} +0 -0
  52. /package/dist/{chunk-VEBU7SMW.js.map → chunk-RK2WSQYL.js.map} +0 -0
  53. /package/dist/{chunk-NPSPJGD4.js.map → chunk-ZWQLXWSV.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"sources":["/home/runner/work/fict/fict/packages/runtime/dist/chunk-HAFRB2OT.cjs","../src/context.ts"],"names":[],"mappings":"AAAA;AACE;AACA;AACA;AACA;AACF,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AM,QAAQ,CAAA;AAAA,IAC/B,CAAC,CAAA;AAED,IAAA,OAAO,QAAA;AAAA,EACT,CAAA;AAEA,EAAA,OAAO,OAAA;AACT;AAsBO,SAAS,UAAA,CAAc,OAAA,EAAwB;AACpD,EAAA,IAAI,KAAA,EAAO,8CAAA,CAAe;AAG1B,EAAA,MAAA,CAAO,IAAA,EAAM;AACX,IAAA,MAAM,WAAA,EAAa,cAAA,CAAe,GAAA,CAAI,IAAI,CAAA;AAC1C,IAAA,GAAA,CAAI,WAAA,GAAc,UAAA,CAAW,GAAA,CAAI,OAAA,CAAQ,EAAE,CAAA,EAAG;AAC5C,MAAA,OAAO,UAAA,CAAW,GAAA,CAAI,OAAA,CAAQ,EAAE,CAAA;AAAA,IAClC;AACA,IAAA,KAAA,EAAO,IAAA,CAAK,MAAA;AAAA,EACd;AAGA,EAAA,OAAO,OAAA,CAAQ,YAAA;AACjB;AAqBO,SAAS,UAAA,CAAc,OAAA,EAA8B;AAC1D,EAAA,IAAI,KAAA,EAAO,8CAAA,CAAe;AAE1B,EAAA,MAAA,CAAO,IAAA,EAAM;AACX,IAAA,MAAM,WAAA,EAAa,cAAA,CAAe,GAAA,CAAI,IAAI,CAAA;AAC1C,IAAA,GAAA,CAAI,WAAA,GAAc,UAAA,CAAW,GAAA,CAAI,OAAA,CAAQ,EAAE,CAAA,EAAG;AAC5C,MAAA,OAAO,IAAA;AAAA,IACT;AACA,IAAA,KAAA,EAAO,IAAA,CAAK,MAAA;AAAA,EACd;AAEA,EAAA,OAAO,KAAA;AACT;ADnMA;AACA;AACE;AACA;AACA;AACF,wGAAC","file":"/home/runner/work/fict/fict/packages/runtime/dist/chunk-HAFRB2OT.cjs","sourcesContent":[null,"/**\n * @fileoverview Context API for Fict\n *\n * Provides a way to pass data through the component tree without having to pass\n * props down manually at every level. Context is designed for:\n *\n * - SSR isolation (different request = different context values)\n * - Multi-instance support (multiple app roots with different values)\n * - Subtree scoping (override values in specific parts of the tree)\n *\n * ## Design Principles\n *\n * 1. **Reuses existing RootContext hierarchy** - Uses parent chain for value lookup,\n * consistent with handleError/handleSuspend mechanisms.\n *\n * 2. **Zero extra root creation overhead** - Provider doesn't create new root,\n * only mounts value on current root.\n *\n * 3. **Auto-aligned with insert/suspense boundaries** - Because they create child\n * roots that inherit parent, context values propagate correctly.\n *\n * ## Usage\n *\n * ```tsx\n * // Create context with default value\n * const ThemeContext = createContext<'light' | 'dark'>('light')\n *\n * // Provide value to subtree\n * function App() {\n * return (\n * <ThemeContext.Provider value=\"dark\">\n * <ThemedComponent />\n * </ThemeContext.Provider>\n * )\n * }\n *\n * // Consume value\n * function ThemedComponent() {\n * const theme = useContext(ThemeContext)\n * return <div class={theme}>...</div>\n * }\n * ```\n *\n * @module\n */\n\nimport { createElement } from './dom'\nimport { createRenderEffect } from './effect'\nimport {\n createRootContext,\n destroyRoot,\n flushOnMount,\n getCurrentRoot,\n popRoot,\n pushRoot,\n type RootContext,\n} from './lifecycle'\nimport { insertNodesBefore, removeNodes, toNodeArray } from './node-ops'\nimport type { BaseProps, FictNode } from './types'\n\n// ============================================================================\n// Types\n// ============================================================================\n\n/**\n * Context object created by createContext.\n * Contains the Provider component and serves as a key for context lookup.\n */\nexport interface Context<T> {\n /** Unique identifier for this context */\n readonly id: symbol\n /** Default value when no provider is found */\n readonly defaultValue: T\n /** Provider component for supplying context values */\n Provider: ContextProvider<T>\n /** Display name for debugging */\n displayName?: string\n}\n\n/**\n * Props for the Context Provider component\n */\nexport interface ProviderProps<T> extends BaseProps {\n /** The value to provide to the subtree */\n value: T\n}\n\n/**\n * Provider component type\n */\nexport type ContextProvider<T> = (props: ProviderProps<T>) => FictNode\n\n// ============================================================================\n// Internal Context Storage\n// ============================================================================\n\n/**\n * WeakMap to store context values per RootContext.\n * Using WeakMap ensures proper garbage collection when roots are destroyed.\n */\nconst contextStorage = new WeakMap<RootContext, Map<symbol, unknown>>()\n\n/**\n * Get the context map for a root, creating it if needed\n */\nfunction getContextMap(root: RootContext): Map<symbol, unknown> {\n let map = contextStorage.get(root)\n if (!map) {\n map = new Map()\n contextStorage.set(root, map)\n }\n return map\n}\n\n// ============================================================================\n// Context API\n// ============================================================================\n\n/**\n * Creates a new context with the given default value.\n *\n * Context provides a way to pass values through the component tree without\n * explicit props drilling. It's especially useful for:\n *\n * - Theme data\n * - Locale/i18n settings\n * - Authentication state\n * - Feature flags\n * - Any data that many components at different nesting levels need\n *\n * @param defaultValue - The value to use when no Provider is found above in the tree\n * @returns A context object with a Provider component\n *\n * @example\n * ```tsx\n * // Create a theme context\n * const ThemeContext = createContext<'light' | 'dark'>('light')\n *\n * // Use the provider\n * function App() {\n * return (\n * <ThemeContext.Provider value=\"dark\">\n * <Content />\n * </ThemeContext.Provider>\n * )\n * }\n *\n * // Consume the context\n * function Content() {\n * const theme = useContext(ThemeContext)\n * return <div class={`theme-${theme}`}>Hello</div>\n * }\n * ```\n */\nexport function createContext<T>(defaultValue: T): Context<T> {\n const id = Symbol('fict.context')\n\n const context: Context<T> = {\n id,\n defaultValue,\n Provider: null as unknown as ContextProvider<T>,\n }\n\n // Create the Provider component\n context.Provider = function Provider(props: ProviderProps<T>): FictNode {\n const hostRoot = getCurrentRoot()\n\n // Create a child root for the provider's subtree\n // This establishes the provider boundary - children will look up from here\n const providerRoot = createRootContext(hostRoot)\n\n // Store the context value on this root\n const contextMap = getContextMap(providerRoot)\n contextMap.set(id, props.value)\n\n // Create DOM structure\n const markerOwnerDocument = providerRoot.ownerDocument ?? hostRoot?.ownerDocument ?? document\n const fragment = markerOwnerDocument.createDocumentFragment()\n const marker = markerOwnerDocument.createComment('fict:ctx')\n fragment.appendChild(marker)\n\n let cleanup: (() => void) | undefined\n let activeNodes: Node[] = []\n\n const renderChildren = (children: FictNode) => {\n // Cleanup previous render\n if (cleanup) {\n cleanup()\n cleanup = undefined\n }\n if (activeNodes.length) {\n removeNodes(activeNodes)\n activeNodes = []\n }\n\n if (children == null || children === false) {\n return\n }\n\n const prev = pushRoot(providerRoot)\n let nodes: Node[] = []\n try {\n const output = createElement(children)\n nodes = toNodeArray(output, markerOwnerDocument)\n const parentNode = marker.parentNode as (ParentNode & Node) | null\n if (parentNode) {\n insertNodesBefore(parentNode, nodes, marker)\n }\n } finally {\n popRoot(prev)\n flushOnMount(providerRoot)\n }\n\n cleanup = () => {\n destroyRoot(providerRoot)\n removeNodes(nodes)\n }\n activeNodes = nodes\n }\n\n // Initial render\n createRenderEffect(() => {\n // Update context value on re-render (if value prop changes reactively)\n contextMap.set(id, props.value)\n renderChildren(props.children)\n })\n\n return fragment\n }\n\n return context\n}\n\n/**\n * Reads the current value of a context.\n *\n * useContext looks up through the RootContext parent chain to find the\n * nearest Provider for this context. If no Provider is found, returns\n * the context's default value.\n *\n * @param context - The context object created by createContext\n * @returns The current context value\n *\n * @example\n * ```tsx\n * const ThemeContext = createContext('light')\n *\n * function ThemedButton() {\n * const theme = useContext(ThemeContext)\n * return <button class={theme === 'dark' ? 'btn-dark' : 'btn-light'}>Click</button>\n * }\n * ```\n */\nexport function useContext<T>(context: Context<T>): T {\n let root = getCurrentRoot()\n\n // Walk up the parent chain looking for the context value\n while (root) {\n const contextMap = contextStorage.get(root)\n if (contextMap && contextMap.has(context.id)) {\n return contextMap.get(context.id) as T\n }\n root = root.parent\n }\n\n // No provider found, return default value\n return context.defaultValue\n}\n\n/**\n * Checks if a context value is currently provided in the tree.\n *\n * Useful for conditional behavior when a provider may or may not exist.\n *\n * @param context - The context object to check\n * @returns true if a Provider exists above in the tree\n *\n * @example\n * ```tsx\n * function OptionalTheme() {\n * if (hasContext(ThemeContext)) {\n * const theme = useContext(ThemeContext)\n * return <div class={theme}>Themed content</div>\n * }\n * return <div>Default content</div>\n * }\n * ```\n */\nexport function hasContext<T>(context: Context<T>): boolean {\n let root = getCurrentRoot()\n\n while (root) {\n const contextMap = contextStorage.get(root)\n if (contextMap && contextMap.has(context.id)) {\n return true\n }\n root = root.parent\n }\n\n return false\n}\n"]}
1
+ {"version":3,"sources":["/home/runner/work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,UAAA,CAAW,GAAA,CAAI,EAAA,EAAI,KAAA,CAAM,KAAK,CAAA;AAC9B,MAAA,cAAA,CAAe,KAAA,CAAM,QAAQ,CAAA;AAAA,IAC/B,CAAC,CAAA;AAED,IAAA,OAAO,QAAA;AAAA,EACT,CAAA;AAEA,EAAA,OAAO,OAAA;AACT;AAsBO,SAAS,UAAA,CAAc,OAAA,EAAwB;AACpD,EAAA,IAAI,KAAA,EAAO,8CAAA,CAAe;AAG1B,EAAA,MAAA,CAAO,IAAA,EAAM;AACX,IAAA,MAAM,WAAA,EAAa,cAAA,CAAe,GAAA,CAAI,IAAI,CAAA;AAC1C,IAAA,GAAA,CAAI,WAAA,GAAc,UAAA,CAAW,GAAA,CAAI,OAAA,CAAQ,EAAE,CAAA,EAAG;AAC5C,MAAA,OAAO,UAAA,CAAW,GAAA,CAAI,OAAA,CAAQ,EAAE,CAAA;AAAA,IAClC;AACA,IAAA,KAAA,EAAO,IAAA,CAAK,MAAA;AAAA,EACd;AAGA,EAAA,OAAO,OAAA,CAAQ,YAAA;AACjB;AAqBO,SAAS,UAAA,CAAc,OAAA,EAA8B;AAC1D,EAAA,IAAI,KAAA,EAAO,8CAAA,CAAe;AAE1B,EAAA,MAAA,CAAO,IAAA,EAAM;AACX,IAAA,MAAM,WAAA,EAAa,cAAA,CAAe,GAAA,CAAI,IAAI,CAAA;AAC1C,IAAA,GAAA,CAAI,WAAA,GAAc,UAAA,CAAW,GAAA,CAAI,OAAA,CAAQ,EAAE,CAAA,EAAG;AAC5C,MAAA,OAAO,IAAA;AAAA,IACT;AACA,IAAA,KAAA,EAAO,IAAA,CAAK,MAAA;AAAA,EACd;AAEA,EAAA,OAAO,KAAA;AACT;ADnMA;AACA;AACE;AACA;AACA;AACF,wGAAC","file":"/home/runner/work/fict/fict/packages/runtime/dist/chunk-BADX4WTQ.cjs","sourcesContent":[null,"/**\n * @fileoverview Context API for Fict\n *\n * Provides a way to pass data through the component tree without having to pass\n * props down manually at every level. Context is designed for:\n *\n * - SSR isolation (different request = different context values)\n * - Multi-instance support (multiple app roots with different values)\n * - Subtree scoping (override values in specific parts of the tree)\n *\n * ## Design Principles\n *\n * 1. **Reuses existing RootContext hierarchy** - Uses parent chain for value lookup,\n * consistent with handleError/handleSuspend mechanisms.\n *\n * 2. **Zero extra root creation overhead** - Provider doesn't create new root,\n * only mounts value on current root.\n *\n * 3. **Auto-aligned with insert/suspense boundaries** - Because they create child\n * roots that inherit parent, context values propagate correctly.\n *\n * ## Usage\n *\n * ```tsx\n * // Create context with default value\n * const ThemeContext = createContext<'light' | 'dark'>('light')\n *\n * // Provide value to subtree\n * function App() {\n * return (\n * <ThemeContext.Provider value=\"dark\">\n * <ThemedComponent />\n * </ThemeContext.Provider>\n * )\n * }\n *\n * // Consume value\n * function ThemedComponent() {\n * const theme = useContext(ThemeContext)\n * return <div class={theme}>...</div>\n * }\n * ```\n *\n * @module\n */\n\nimport { createElement } from './dom'\nimport { createRenderEffect } from './effect'\nimport {\n createRootContext,\n destroyRoot,\n flushOnMount,\n getCurrentRoot,\n popRoot,\n pushRoot,\n type RootContext,\n} from './lifecycle'\nimport { insertNodesBefore, removeNodes, toNodeArray } from './node-ops'\nimport type { BaseProps, FictNode } from './types'\n\n// ============================================================================\n// Types\n// ============================================================================\n\n/**\n * Context object created by createContext.\n * Contains the Provider component and serves as a key for context lookup.\n */\nexport interface Context<T> {\n /** Unique identifier for this context */\n readonly id: symbol\n /** Default value when no provider is found */\n readonly defaultValue: T\n /** Provider component for supplying context values */\n Provider: ContextProvider<T>\n /** Display name for debugging */\n displayName?: string\n}\n\n/**\n * Props for the Context Provider component\n */\nexport interface ProviderProps<T> extends BaseProps {\n /** The value to provide to the subtree */\n value: T\n}\n\n/**\n * Provider component type\n */\nexport type ContextProvider<T> = (props: ProviderProps<T>) => FictNode\n\n// ============================================================================\n// Internal Context Storage\n// ============================================================================\n\n/**\n * WeakMap to store context values per RootContext.\n * Using WeakMap ensures proper garbage collection when roots are destroyed.\n */\nconst contextStorage = new WeakMap<RootContext, Map<symbol, unknown>>()\n\n/**\n * Get the context map for a root, creating it if needed\n */\nfunction getContextMap(root: RootContext): Map<symbol, unknown> {\n let map = contextStorage.get(root)\n if (!map) {\n map = new Map()\n contextStorage.set(root, map)\n }\n return map\n}\n\n// ============================================================================\n// Context API\n// ============================================================================\n\n/**\n * Creates a new context with the given default value.\n *\n * Context provides a way to pass values through the component tree without\n * explicit props drilling. It's especially useful for:\n *\n * - Theme data\n * - Locale/i18n settings\n * - Authentication state\n * - Feature flags\n * - Any data that many components at different nesting levels need\n *\n * @param defaultValue - The value to use when no Provider is found above in the tree\n * @returns A context object with a Provider component\n *\n * @example\n * ```tsx\n * // Create a theme context\n * const ThemeContext = createContext<'light' | 'dark'>('light')\n *\n * // Use the provider\n * function App() {\n * return (\n * <ThemeContext.Provider value=\"dark\">\n * <Content />\n * </ThemeContext.Provider>\n * )\n * }\n *\n * // Consume the context\n * function Content() {\n * const theme = useContext(ThemeContext)\n * return <div class={`theme-${theme}`}>Hello</div>\n * }\n * ```\n */\nexport function createContext<T>(defaultValue: T): Context<T> {\n const id = Symbol('fict.context')\n\n const context: Context<T> = {\n id,\n defaultValue,\n Provider: null as unknown as ContextProvider<T>,\n }\n\n // Create the Provider component\n context.Provider = function Provider(props: ProviderProps<T>): FictNode {\n const hostRoot = getCurrentRoot()\n\n // Create a child root for the provider's subtree\n // This establishes the provider boundary - children will look up from here\n const providerRoot = createRootContext(hostRoot)\n\n // Store the context value on this root\n const contextMap = getContextMap(providerRoot)\n contextMap.set(id, props.value)\n\n // Create DOM structure\n const markerOwnerDocument = providerRoot.ownerDocument ?? hostRoot?.ownerDocument ?? document\n const fragment = markerOwnerDocument.createDocumentFragment()\n const marker = markerOwnerDocument.createComment('fict:ctx')\n fragment.appendChild(marker)\n\n let cleanup: (() => void) | undefined\n let activeNodes: Node[] = []\n\n const renderChildren = (children: FictNode) => {\n // Cleanup previous render\n if (cleanup) {\n cleanup()\n cleanup = undefined\n }\n if (activeNodes.length) {\n removeNodes(activeNodes)\n activeNodes = []\n }\n\n if (children == null || children === false) {\n return\n }\n\n const prev = pushRoot(providerRoot)\n let nodes: Node[] = []\n try {\n const output = createElement(children)\n nodes = toNodeArray(output, markerOwnerDocument)\n const parentNode = marker.parentNode as (ParentNode & Node) | null\n if (parentNode) {\n insertNodesBefore(parentNode, nodes, marker)\n }\n } finally {\n popRoot(prev)\n flushOnMount(providerRoot)\n }\n\n cleanup = () => {\n destroyRoot(providerRoot)\n removeNodes(nodes)\n }\n activeNodes = nodes\n }\n\n // Initial render\n createRenderEffect(() => {\n // Update context value on re-render (if value prop changes reactively)\n contextMap.set(id, props.value)\n renderChildren(props.children)\n })\n\n return fragment\n }\n\n return context\n}\n\n/**\n * Reads the current value of a context.\n *\n * useContext looks up through the RootContext parent chain to find the\n * nearest Provider for this context. If no Provider is found, returns\n * the context's default value.\n *\n * @param context - The context object created by createContext\n * @returns The current context value\n *\n * @example\n * ```tsx\n * const ThemeContext = createContext('light')\n *\n * function ThemedButton() {\n * const theme = useContext(ThemeContext)\n * return <button class={theme === 'dark' ? 'btn-dark' : 'btn-light'}>Click</button>\n * }\n * ```\n */\nexport function useContext<T>(context: Context<T>): T {\n let root = getCurrentRoot()\n\n // Walk up the parent chain looking for the context value\n while (root) {\n const contextMap = contextStorage.get(root)\n if (contextMap && contextMap.has(context.id)) {\n return contextMap.get(context.id) as T\n }\n root = root.parent\n }\n\n // No provider found, return default value\n return context.defaultValue\n}\n\n/**\n * Checks if a context value is currently provided in the tree.\n *\n * Useful for conditional behavior when a provider may or may not exist.\n *\n * @param context - The context object to check\n * @returns true if a Provider exists above in the tree\n *\n * @example\n * ```tsx\n * function OptionalTheme() {\n * if (hasContext(ThemeContext)) {\n * const theme = useContext(ThemeContext)\n * return <div class={theme}>Themed content</div>\n * }\n * return <div>Default content</div>\n * }\n * ```\n */\nexport function hasContext<T>(context: Context<T>): boolean {\n let root = getCurrentRoot()\n\n while (root) {\n const contextMap = contextStorage.get(root)\n if (contextMap && contextMap.has(context.id)) {\n return true\n }\n root = root.parent\n }\n\n return false\n}\n"]}
@@ -6,7 +6,7 @@
6
6
 
7
7
 
8
8
 
9
- var _chunkIEYESQREcjs = require('./chunk-IEYESQRE.cjs');
9
+ var _chunkAR2T7JEXcjs = require('./chunk-AR2T7JEX.cjs');
10
10
 
11
11
 
12
12
 
@@ -21,7 +21,7 @@ var _chunkIEYESQREcjs = require('./chunk-IEYESQRE.cjs');
21
21
 
22
22
 
23
23
 
24
- var _chunkR2WMNQGOcjs = require('./chunk-R2WMNQGO.cjs');
24
+ var _chunkWJMZ7X46cjs = require('./chunk-WJMZ7X46.cjs');
25
25
 
26
26
  // src/reconcile.ts
27
27
  function reconcileArrays(parentNode, a, b) {
@@ -151,7 +151,7 @@ var MAX_SAFE_VERSION = 9007199254740991;
151
151
  function createVersionedSignalAccessor(initialValue) {
152
152
  let current = initialValue;
153
153
  let version = 0;
154
- const track = _chunkR2WMNQGOcjs.signal.call(void 0, version);
154
+ const track = _chunkWJMZ7X46cjs.signal.call(void 0, version);
155
155
  function accessor(value) {
156
156
  if (arguments.length === 0) {
157
157
  track();
@@ -169,7 +169,7 @@ function createKeyedListContainer(startOverride, endOverride, defaultOwnerDocume
169
169
  const endMarker = _nullishCoalesce(endOverride, () => ( markerOwnerDocument.createComment("fict:list:end")));
170
170
  const dispose = () => {
171
171
  for (const block of container.blocks.values()) {
172
- _chunkR2WMNQGOcjs.destroyRoot.call(void 0, block.root);
172
+ _chunkWJMZ7X46cjs.destroyRoot.call(void 0, block.root);
173
173
  }
174
174
  container.blocks.clear();
175
175
  container.nextBlocks.clear();
@@ -209,33 +209,33 @@ function createKeyedListContainer(startOverride, endOverride, defaultOwnerDocume
209
209
  }
210
210
  function createKeyedBlock(key, item, index, render, needsIndex = true, hostRoot) {
211
211
  const itemSig = createVersionedSignalAccessor(item);
212
- const indexSig = needsIndex ? _chunkR2WMNQGOcjs.signal.call(void 0, index) : (function indexSignal(next) {
212
+ const indexSig = needsIndex ? _chunkWJMZ7X46cjs.signal.call(void 0, index) : (function indexSignal(next) {
213
213
  if (arguments.length === 0) return index;
214
214
  index = next;
215
215
  return index;
216
216
  });
217
- const root = _chunkR2WMNQGOcjs.createRootContext.call(void 0, hostRoot);
217
+ const root = _chunkWJMZ7X46cjs.createRootContext.call(void 0, hostRoot);
218
218
  const nodeOwnerDocument = _nullishCoalesce(_nullishCoalesce(root.ownerDocument, () => ( _optionalChain([hostRoot, 'optionalAccess', _11 => _11.ownerDocument]))), () => ( document));
219
- const prevRoot = _chunkR2WMNQGOcjs.pushRoot.call(void 0, root);
219
+ const prevRoot = _chunkWJMZ7X46cjs.pushRoot.call(void 0, root);
220
220
  let nodes = [];
221
221
  let scopeDispose;
222
- const prevSub = _chunkR2WMNQGOcjs.setActiveSub.call(void 0, void 0);
222
+ const prevSub = _chunkWJMZ7X46cjs.setActiveSub.call(void 0, void 0);
223
223
  try {
224
- scopeDispose = _chunkR2WMNQGOcjs.effectScope.call(void 0, () => {
224
+ scopeDispose = _chunkWJMZ7X46cjs.effectScope.call(void 0, () => {
225
225
  const rendered = render(itemSig, indexSig, key);
226
226
  if (rendered instanceof Node || Array.isArray(rendered) && rendered.every((n) => n instanceof Node)) {
227
- nodes = _chunkIEYESQREcjs.toNodeArray.call(void 0, rendered, nodeOwnerDocument);
227
+ nodes = _chunkAR2T7JEXcjs.toNodeArray.call(void 0, rendered, nodeOwnerDocument);
228
228
  } else {
229
- const element = _chunkIEYESQREcjs.createElement.call(void 0, rendered);
230
- nodes = _chunkIEYESQREcjs.toNodeArray.call(void 0, element, nodeOwnerDocument);
229
+ const element = _chunkAR2T7JEXcjs.createElement.call(void 0, rendered);
230
+ nodes = _chunkAR2T7JEXcjs.toNodeArray.call(void 0, element, nodeOwnerDocument);
231
231
  }
232
232
  });
233
233
  if (scopeDispose) {
234
234
  root.cleanups.push(scopeDispose);
235
235
  }
236
236
  } finally {
237
- _chunkR2WMNQGOcjs.setActiveSub.call(void 0, prevSub);
238
- _chunkR2WMNQGOcjs.popRoot.call(void 0, prevRoot);
237
+ _chunkWJMZ7X46cjs.setActiveSub.call(void 0, prevSub);
238
+ _chunkWJMZ7X46cjs.popRoot.call(void 0, prevRoot);
239
239
  }
240
240
  return {
241
241
  key,
@@ -347,7 +347,7 @@ function createKeyedList(getItems, keyFn, renderItem, needsIndex, startMarker, e
347
347
  );
348
348
  }
349
349
  function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, startOverride, endOverride) {
350
- const hostRoot = _chunkR2WMNQGOcjs.getCurrentRoot.call(void 0, );
350
+ const hostRoot = _chunkWJMZ7X46cjs.getCurrentRoot.call(void 0, );
351
351
  const container = createKeyedListContainer(
352
352
  startOverride,
353
353
  endOverride,
@@ -365,7 +365,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
365
365
  let connectObserver = null;
366
366
  let effectStarted = false;
367
367
  let startScheduled = false;
368
- let initialHydrating = _chunkR2WMNQGOcjs.__fictIsHydrating.call(void 0, );
368
+ let initialHydrating = _chunkWJMZ7X46cjs.__fictIsHydrating.call(void 0, );
369
369
  const collectBetween = () => {
370
370
  const nodes = [];
371
371
  let cursor = container.startMarker.nextSibling;
@@ -393,17 +393,17 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
393
393
  };
394
394
  const performDiff = () => {
395
395
  if (disposed) return;
396
- const isSSR = _chunkR2WMNQGOcjs.__fictIsSSR.call(void 0, );
396
+ const isSSR = _chunkWJMZ7X46cjs.__fictIsSSR.call(void 0, );
397
397
  const parent = isSSR ? container.startMarker.parentNode : getConnectedParent();
398
398
  if (!parent) return;
399
- _chunkIEYESQREcjs.batch.call(void 0, () => {
399
+ _chunkAR2T7JEXcjs.batch.call(void 0, () => {
400
400
  const oldBlocks = container.blocks;
401
401
  const newBlocks = container.nextBlocks;
402
402
  const prevOrderedBlocks = container.orderedBlocks;
403
403
  const nextOrderedBlocks = container.nextOrderedBlocks;
404
404
  const orderedIndexByKey = container.orderedIndexByKey;
405
405
  const newItems = getItems();
406
- if (initialHydrating && _chunkIEYESQREcjs.isHydratingActive.call(void 0, )) {
406
+ if (initialHydrating && _chunkAR2T7JEXcjs.isHydratingActive.call(void 0, )) {
407
407
  initialHydrating = false;
408
408
  newBlocks.clear();
409
409
  nextOrderedBlocks.length = 0;
@@ -416,7 +416,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
416
416
  return;
417
417
  }
418
418
  const createdBlocks2 = [];
419
- _chunkIEYESQREcjs.withHydrationRange.call(void 0,
419
+ _chunkAR2T7JEXcjs.withHydrationRange.call(void 0,
420
420
  container.startMarker.nextSibling,
421
421
  container.endMarker,
422
422
  _nullishCoalesce(parent.ownerDocument, () => ( markerOwnerDocument)),
@@ -432,8 +432,8 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
432
432
  }
433
433
  const existing = newBlocks.get(key);
434
434
  if (existing) {
435
- _chunkR2WMNQGOcjs.destroyRoot.call(void 0, existing.root);
436
- _chunkIEYESQREcjs.removeNodes.call(void 0, existing.nodes);
435
+ _chunkWJMZ7X46cjs.destroyRoot.call(void 0, existing.root);
436
+ _chunkAR2T7JEXcjs.removeNodes.call(void 0, existing.nodes);
437
437
  }
438
438
  }
439
439
  const block = createKeyedBlock(key, item, index, renderItem, needsIndex, hostRoot);
@@ -454,7 +454,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
454
454
  container.nextNodes.length = 0;
455
455
  for (const block of createdBlocks2) {
456
456
  if (newBlocks.get(block.key) === block) {
457
- _chunkR2WMNQGOcjs.flushOnMount.call(void 0, block.root);
457
+ _chunkWJMZ7X46cjs.flushOnMount.call(void 0, block.root);
458
458
  }
459
459
  }
460
460
  return;
@@ -462,7 +462,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
462
462
  if (newItems.length === 0) {
463
463
  if (oldBlocks.size > 0) {
464
464
  for (const block of oldBlocks.values()) {
465
- _chunkR2WMNQGOcjs.destroyRoot.call(void 0, block.root);
465
+ _chunkWJMZ7X46cjs.destroyRoot.call(void 0, block.root);
466
466
  }
467
467
  const range = (_nullishCoalesce(parent.ownerDocument, () => ( markerOwnerDocument))).createRange();
468
468
  range.setStartAfter(container.startMarker);
@@ -543,8 +543,8 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
543
543
  `[fict] Duplicate key "${String(key)}" detected in list rendering. Each item should have a unique key. The previous item with this key will be replaced.`
544
544
  );
545
545
  }
546
- _chunkR2WMNQGOcjs.destroyRoot.call(void 0, existingBlock.root);
547
- _chunkIEYESQREcjs.removeNodes.call(void 0, existingBlock.nodes);
546
+ _chunkWJMZ7X46cjs.destroyRoot.call(void 0, existingBlock.root);
547
+ _chunkAR2T7JEXcjs.removeNodes.call(void 0, existingBlock.nodes);
548
548
  }
549
549
  block = createKeyedBlock(key, item, index, renderItem, needsIndex, hostRoot);
550
550
  createdBlocks.push(block);
@@ -557,8 +557,8 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
557
557
  hasDuplicateKey = true;
558
558
  const prior = nextOrderedBlocks[position];
559
559
  if (prior && prior !== resolvedBlock) {
560
- _chunkR2WMNQGOcjs.destroyRoot.call(void 0, prior.root);
561
- _chunkIEYESQREcjs.removeNodes.call(void 0, prior.nodes);
560
+ _chunkWJMZ7X46cjs.destroyRoot.call(void 0, prior.root);
561
+ _chunkAR2T7JEXcjs.removeNodes.call(void 0, prior.nodes);
562
562
  }
563
563
  nextOrderedBlocks[position] = resolvedBlock;
564
564
  } else {
@@ -596,7 +596,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
596
596
  }
597
597
  }
598
598
  if (appendedNodes.length > 0) {
599
- _chunkIEYESQREcjs.insertNodesBefore.call(void 0, parent, appendedNodes, container.endMarker);
599
+ _chunkAR2T7JEXcjs.insertNodesBefore.call(void 0, parent, appendedNodes, container.endMarker);
600
600
  const currentNodes = container.currentNodes;
601
601
  currentNodes.pop();
602
602
  for (let i = 0; i < appendedNodes.length; i++) {
@@ -610,15 +610,15 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
610
610
  container.nextOrderedBlocks = prevOrderedBlocks;
611
611
  for (const block of createdBlocks) {
612
612
  if (newBlocks.get(block.key) === block) {
613
- _chunkR2WMNQGOcjs.flushOnMount.call(void 0, block.root);
613
+ _chunkWJMZ7X46cjs.flushOnMount.call(void 0, block.root);
614
614
  }
615
615
  }
616
616
  return;
617
617
  }
618
618
  if (oldBlocks.size > 0) {
619
619
  for (const block of oldBlocks.values()) {
620
- _chunkR2WMNQGOcjs.destroyRoot.call(void 0, block.root);
621
- _chunkIEYESQREcjs.removeNodes.call(void 0, block.nodes);
620
+ _chunkWJMZ7X46cjs.destroyRoot.call(void 0, block.root);
621
+ _chunkAR2T7JEXcjs.removeNodes.call(void 0, block.nodes);
622
622
  }
623
623
  oldBlocks.clear();
624
624
  }
@@ -677,7 +677,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
677
677
  container.nextOrderedBlocks = prevOrderedBlocks;
678
678
  for (const block of createdBlocks) {
679
679
  if (newBlocks.get(block.key) === block) {
680
- _chunkR2WMNQGOcjs.flushOnMount.call(void 0, block.root);
680
+ _chunkWJMZ7X46cjs.flushOnMount.call(void 0, block.root);
681
681
  }
682
682
  }
683
683
  });
@@ -688,19 +688,19 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
688
688
  };
689
689
  const ensureEffectStarted = () => {
690
690
  if (disposed || effectStarted) return effectStarted;
691
- const isSSR = _chunkR2WMNQGOcjs.__fictIsSSR.call(void 0, );
691
+ const isSSR = _chunkWJMZ7X46cjs.__fictIsSSR.call(void 0, );
692
692
  const parent = isSSR ? container.startMarker.parentNode : getConnectedParent();
693
693
  if (!parent) return false;
694
694
  const start = () => {
695
- effectDispose = _chunkR2WMNQGOcjs.createRenderEffect.call(void 0, performDiff);
695
+ effectDispose = _chunkWJMZ7X46cjs.createRenderEffect.call(void 0, performDiff);
696
696
  effectStarted = true;
697
697
  };
698
698
  if (hostRoot) {
699
- const prev = _chunkR2WMNQGOcjs.pushRoot.call(void 0, hostRoot);
699
+ const prev = _chunkWJMZ7X46cjs.pushRoot.call(void 0, hostRoot);
700
700
  try {
701
701
  start();
702
702
  } finally {
703
- _chunkR2WMNQGOcjs.popRoot.call(void 0, prev);
703
+ _chunkWJMZ7X46cjs.popRoot.call(void 0, prev);
704
704
  }
705
705
  } else {
706
706
  start();
@@ -716,7 +716,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
716
716
  if (getConnectedParent()) {
717
717
  disconnectObserver();
718
718
  if (ensureEffectStarted()) {
719
- _chunkR2WMNQGOcjs.flush.call(void 0, );
719
+ _chunkWJMZ7X46cjs.flush.call(void 0, );
720
720
  }
721
721
  }
722
722
  });
@@ -756,7 +756,7 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
756
756
  if (disposed) return;
757
757
  scheduleStart();
758
758
  if (ensureEffectStarted()) {
759
- _chunkR2WMNQGOcjs.flush.call(void 0, );
759
+ _chunkWJMZ7X46cjs.flush.call(void 0, );
760
760
  } else {
761
761
  waitForConnection();
762
762
  }
@@ -776,4 +776,4 @@ function createFineGrainedKeyedList(getItems, keyFn, renderItem, needsIndex, sta
776
776
 
777
777
 
778
778
  exports.reconcileArrays = reconcileArrays; exports.moveNodesBefore = moveNodesBefore; exports.isNodeBetweenMarkers = isNodeBetweenMarkers; exports.createKeyedList = createKeyedList;
779
- //# sourceMappingURL=chunk-BW4GNOOZ.cjs.map
779
+ //# sourceMappingURL=chunk-CBRGOLTR.cjs.map