@sylwellsoftware/fray 0.1.0-alpha.1
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/EXPERIMENTAL.md +75 -0
- package/LICENSE +55 -0
- package/NOTICE +2 -0
- package/README.md +521 -0
- package/dist/Components/Placeholder.d.ts +14 -0
- package/dist/Components/Placeholder.d.ts.map +1 -0
- package/dist/Components/component.d.ts +187 -0
- package/dist/Components/component.d.ts.map +1 -0
- package/dist/Components/controlUtils.d.ts +20 -0
- package/dist/Components/controlUtils.d.ts.map +1 -0
- package/dist/Components/data/descriptionList.d.ts +21 -0
- package/dist/Components/data/descriptionList.d.ts.map +1 -0
- package/dist/Components/data/listview/listview.d.ts +39 -0
- package/dist/Components/data/listview/listview.d.ts.map +1 -0
- package/dist/Components/data/selectionhandler.d.ts +68 -0
- package/dist/Components/data/selectionhandler.d.ts.map +1 -0
- package/dist/Components/data/table/DataTable.d.ts +72 -0
- package/dist/Components/data/table/DataTable.d.ts.map +1 -0
- package/dist/Components/data/table/FilterPanel.d.ts +35 -0
- package/dist/Components/data/table/FilterPanel.d.ts.map +1 -0
- package/dist/Components/data/table/TableHeader.d.ts +21 -0
- package/dist/Components/data/table/TableHeader.d.ts.map +1 -0
- package/dist/Components/data/table/TableHeaderCell.d.ts +39 -0
- package/dist/Components/data/table/TableHeaderCell.d.ts.map +1 -0
- package/dist/Components/data/table/tableQuery.d.ts +25 -0
- package/dist/Components/data/table/tableQuery.d.ts.map +1 -0
- package/dist/Components/data/treeview/treeitem.d.ts +20 -0
- package/dist/Components/data/treeview/treeitem.d.ts.map +1 -0
- package/dist/Components/data/treeview/treeview.d.ts +42 -0
- package/dist/Components/data/treeview/treeview.d.ts.map +1 -0
- package/dist/Components/dialog/dialog.d.ts +37 -0
- package/dist/Components/dialog/dialog.d.ts.map +1 -0
- package/dist/Components/layout/panel.d.ts +20 -0
- package/dist/Components/layout/panel.d.ts.map +1 -0
- package/dist/Components/layout/sidebar.d.ts +18 -0
- package/dist/Components/layout/sidebar.d.ts.map +1 -0
- package/dist/Components/layout/splitView.d.ts +18 -0
- package/dist/Components/layout/splitView.d.ts.map +1 -0
- package/dist/Components/layout/tabpanel/tab.d.ts +12 -0
- package/dist/Components/layout/tabpanel/tab.d.ts.map +1 -0
- package/dist/Components/layout/tabpanel/tabline.d.ts +32 -0
- package/dist/Components/layout/tabpanel/tabline.d.ts.map +1 -0
- package/dist/Components/layout/tabpanel/tabpanel.d.ts +34 -0
- package/dist/Components/layout/tabpanel/tabpanel.d.ts.map +1 -0
- package/dist/Components/lineinputs/checkbox/Checkbox.d.ts +35 -0
- package/dist/Components/lineinputs/checkbox/Checkbox.d.ts.map +1 -0
- package/dist/Components/lineinputs/checkbox/QuadCheckbox.d.ts +12 -0
- package/dist/Components/lineinputs/checkbox/QuadCheckbox.d.ts.map +1 -0
- package/dist/Components/lineinputs/checkbox/TriCheckbox.d.ts +12 -0
- package/dist/Components/lineinputs/checkbox/TriCheckbox.d.ts.map +1 -0
- package/dist/Components/lineinputs/dropdown.d.ts +37 -0
- package/dist/Components/lineinputs/dropdown.d.ts.map +1 -0
- package/dist/Components/lineinputs/textbox.d.ts +36 -0
- package/dist/Components/lineinputs/textbox.d.ts.map +1 -0
- package/dist/Components/lineinputs/toggle.d.ts +30 -0
- package/dist/Components/lineinputs/toggle.d.ts.map +1 -0
- package/dist/Components/menu/button.d.ts +24 -0
- package/dist/Components/menu/button.d.ts.map +1 -0
- package/dist/Components/menu/toolbar.d.ts +15 -0
- package/dist/Components/menu/toolbar.d.ts.map +1 -0
- package/dist/Components/status/progressBar.d.ts +21 -0
- package/dist/Components/status/progressBar.d.ts.map +1 -0
- package/dist/button-BRDkmR1C.js +203 -0
- package/dist/button-BRDkmR1C.js.map +1 -0
- package/dist/experimental.d.ts +16 -0
- package/dist/experimental.d.ts.map +1 -0
- package/dist/experimental.js +1361 -0
- package/dist/experimental.js.map +1 -0
- package/dist/index.d.ts +23 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +1014 -0
- package/dist/index.js.map +1 -0
- package/dist/jsx-dev-runtime-CarwHDyL.js +1155 -0
- package/dist/jsx-dev-runtime-CarwHDyL.js.map +1 -0
- package/dist/jsx-dev-runtime.d.ts +2 -0
- package/dist/jsx-dev-runtime.d.ts.map +1 -0
- package/dist/jsx-dev-runtime.js +6 -0
- package/dist/jsx-dev-runtime.js.map +1 -0
- package/dist/jsx-runtime.d.ts +26 -0
- package/dist/jsx-runtime.d.ts.map +1 -0
- package/dist/jsx-runtime.js +9 -0
- package/dist/jsx-runtime.js.map +1 -0
- package/dist/runtime.d.ts +29 -0
- package/dist/runtime.d.ts.map +1 -0
- package/dist/styling/baseStyleDefinitions.d.ts +154 -0
- package/dist/styling/baseStyleDefinitions.d.ts.map +1 -0
- package/dist/styling/styleRegistry.d.ts +19 -0
- package/dist/styling/styleRegistry.d.ts.map +1 -0
- package/dist/util/filterMode.d.ts +13 -0
- package/dist/util/filterMode.d.ts.map +1 -0
- package/package.json +83 -0
- package/themes/README.md +30 -0
- package/themes/dark.css +39 -0
- package/themes/light.css +39 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-dev-runtime-CarwHDyL.js","sources":["../src/styling/baseStyleDefinitions.ts","../src/styling/styleRegistry.ts","../src/runtime.ts","../src/Components/component.ts","../src/jsx-runtime.ts"],"sourcesContent":["export type CSSDeclarations = Record<string, string>\nexport type CSSVariantMap = Record<string, CSSDeclarations>\nexport type BaseStyleDefinition = Record<string, string | CSSVariantMap>\n\nexport const baseStyleDefinitions = {\n after: {\n content: '\"\"',\n display: 'block',\n position: 'absolute',\n top: '0',\n left: '0',\n width: '100%',\n height: '100%',\n 'pointer-events': 'none',\n },\n\n inputline: {\n display: 'flex',\n 'flex-flow': 'row nowrap',\n position: 'relative',\n 'line-height': '1.25',\n 'font-size': 'var(--ui-font-size)',\n 'min-height': 'calc(var(--ui-font-size) + var(--ui-padding) + var(--ui-padding))',\n color: 'var(--ui-text-color)',\n 'border-radius': 'var(--ui-border-radius)',\n 'box-sizing': 'border-box',\n },\n\n input: {\n background: 'var(--ui-input-bg)',\n padding: 'var(--ui-padding-v) var(--ui-padding-h)',\n 'pointer-events': 'all',\n border: 'var(--ui-input-border)',\n width: 'var(--input-width)',\n 'box-shadow': 'var(--input-shadow)',\n 'box-sizing': 'border-box',\n 'white-space': 'nowrap',\n variants: {\n ':focus-visible': {\n outline: '2px solid transparent',\n 'outline-offset': '1px',\n 'border-color': 'var(--ui-accent-color)',\n 'box-shadow': '0 0 0 1px var(--ui-accent-color-highlight)',\n },\n ':disabled': {\n background: 'var(--ui-input-bg-disabled)',\n 'border-color': 'var(--ui-input-border-disabled)',\n color: 'var(--ui-input-text-color-disabled)',\n cursor: 'not-allowed',\n },\n },\n },\n\n inputlike: {\n background: 'var(--ui-input-bg)',\n padding: 'var(--ui-padding-v) var(--ui-padding-h)',\n 'pointer-events': 'all',\n border: 'var(--ui-input-border)',\n 'box-shadow': 'var(--input-shadow)',\n 'box-sizing': 'border-box',\n 'white-space': 'nowrap',\n 'border-radius': 'var(--ui-border-radius)',\n },\n\n labeledinput: {\n display: 'flex',\n 'flex-flow': 'row nowrap',\n 'align-items': 'center',\n gap: '.5em',\n },\n\n label: {\n color: 'var(--ui-text-color)',\n 'font-size': 'var(--ui-font-size)',\n },\n\n disabled: {\n 'border-color': 'var(--ui-input-border-disabled)',\n color: 'var(--ui-input-text-color-disabled)',\n },\n\n error: {\n color: 'var(--error-color)',\n },\n\n working: {\n display: 'inline',\n position: 'absolute',\n 'z-index': '1',\n margin: 'auto',\n animation: 'fray-placeholder-progress 0.8s linear infinite',\n 'background-repeat': 'repeat',\n 'background-size': '2rem 2rem',\n 'background-image': 'linear-gradient(-45deg, #0001 25%, #fff1 25%, #fff1 50%, #0001 50%, #0001 75%, #fff1 75%, #fff1)',\n border: '0 solid transparent',\n 'border-radius': 'inherit',\n 'box-sizing': 'border-box',\n },\n\n panel: {\n background: 'var(--panel-bg)',\n border: 'var(--panel-border)',\n 'border-radius': 'var(--panel-radius)',\n 'box-shadow': 'var(--panel-shadow)',\n color: 'var(--panel-color)',\n },\n\n sectionheader: {\n 'box-shadow': 'var(--sectionheader-shadow)',\n background: 'var(--sectionheader-bg)',\n color: 'var(--sectionheader-color)',\n },\n\n uiline: {\n 'box-sizing': 'border-box',\n 'line-height': '1.25',\n 'font-size': 'var(--ui-font-size)',\n 'min-height': 'calc(var(--ui-font-size) + var(--ui-padding) + var(--ui-padding))',\n color: 'var(--ui-text-color)',\n padding: 'var(--ui-padding-v) var(--ui-padding-h)',\n 'border-radius': 'var(--ui-border-radius)',\n cursor: 'pointer',\n 'user-select': 'none',\n },\n\n noselect: {\n 'user-select': 'var(--noselect-user-select)',\n 'cursor': 'var(--noselect-cursor)',\n },\n\n button: {\n 'box-sizing': 'border-box',\n background: 'var(--button-background)',\n border: 'var(--button-border)',\n 'box-shadow': 'var(--button-shadow)',\n color: 'var(--button-color)',\n cursor: 'default',\n 'user-select': 'none',\n variants: {\n ':hover': {\n background: 'var(--button-background-hover)',\n 'box-shadow': 'var(--button-shadow)',\n },\n ':focus-visible': {\n outline: '2px solid transparent',\n 'outline-offset': '1px',\n border: '1px solid var(--ui-accent-color)',\n 'box-shadow': '0 0 0 1px var(--ui-accent-color-highlight)',\n },\n ':disabled': {\n background: 'var(--button-background-disabled)',\n border: 'var(--button-border-disabled)',\n color: 'var(--ui-input-text-color-disabled)',\n cursor: 'not-allowed',\n 'pointer-events': 'none',\n },\n },\n },\n\n toolbar: {\n background: 'var(--toolbar-bg)',\n border: 'var(--toolbar-border)',\n 'border-radius': 'var(--toolbar-radius)',\n 'box-shadow': 'var(--toolbar-shadow)',\n color: 'var(--toolbar-color)',\n },\n\n} satisfies Record<string, BaseStyleDefinition>\n\nexport type BaseStyleName = keyof typeof baseStyleDefinitions\n","import {\n baseStyleDefinitions,\n} from './baseStyleDefinitions.js'\nimport type {\n BaseStyleDefinition,\n BaseStyleName,\n CSSDeclarations,\n CSSVariantMap,\n} from './baseStyleDefinitions.js'\n\nconst STYLE_ATTRIBUTE = 'data-fray-structural-styles'\nlet nextRegistryId = 1\n\n/** Application-scoped structural-style collection and injection. */\nexport class StyleRegistry {\n readonly id: string\n private readonly cssFragments = new Set<string>()\n private readonly baseStyleMap = new Map<BaseStyleName, Set<string>>()\n\n constructor(id: string = `runtime-${nextRegistryId++}`) {\n if (typeof id !== 'string') throw new TypeError('StyleRegistry id must be a string')\n this.id = id\n }\n\n registerCSS(css: string): this {\n if (typeof css !== 'string') throw new TypeError('Component CSS must be a string')\n if (css.trim().length > 0) this.cssFragments.add(css.trim())\n return this\n }\n\n registerBaseStyle(selector: string, styleNames: string | readonly string[]): this {\n if (typeof selector !== 'string' || selector.trim().length === 0) {\n throw new TypeError('Base style selector must be a non-empty string')\n }\n const names = typeof styleNames === 'string' ? [styleNames] : styleNames\n if (!Array.isArray(names)) {\n throw new TypeError('Base style names must be a string or array')\n }\n\n for (const name of names) {\n if (!Object.hasOwn(baseStyleDefinitions, name)) {\n throw new Error(`Unknown Fray base style: ${String(name)}`)\n }\n const styleName = name as BaseStyleName\n const selectors = this.baseStyleMap.get(styleName) ?? new Set<string>()\n selectors.add(selector.trim())\n this.baseStyleMap.set(styleName, selectors)\n }\n return this\n }\n\n generateRootCSS(): string {\n return `:root {\n --base-font-size: 14px;\n --ui-font-size: var(--base-font-size);\n --ui-padding: 0.375rem;\n --ui-padding-h: 0.375rem;\n --ui-padding-v: 0;\n --ui-border-radius: 0.25rem;\n --input-width: 15rem;\n --spacing-small: 0.5rem;\n --spacing-medium: 1rem;\n --panel-padding: 0.75rem;\n --noselect-user-select: none;\n --noselect-cursor: default;\n}\n\n*, *::before, *::after {\n box-sizing: border-box;\n}\n\n@media (prefers-reduced-motion: reduce) {\n *, *::before, *::after {\n scroll-behavior: auto !important;\n animation-duration: 0.01ms !important;\n animation-iteration-count: 1 !important;\n transition-duration: 0.01ms !important;\n }\n}\n\n@media (forced-colors: active) {\n :focus-visible {\n outline: 2px solid Highlight !important;\n outline-offset: 2px !important;\n }\n}`\n }\n\n generateBaseStyleCSS(): string {\n let generated = ''\n for (const [name, selectors] of this.baseStyleMap) {\n const {properties, variants} = splitDefinition(baseStyleDefinitions[name])\n const selectorList = [...selectors]\n generated += renderRule(name, selectorList, properties)\n for (const [variant, variantProperties] of Object.entries(variants)) {\n generated += renderRule(\n `${name}${variant}`,\n selectorList.map((selector) => appendVariant(selector, variant)),\n variantProperties,\n )\n }\n }\n return generated.trim()\n }\n\n generateCSS(): string {\n return [\n this.generateRootCSS(),\n this.generateBaseStyleCSS(),\n [...this.cssFragments].join('\\n\\n'),\n ].filter(Boolean).join('\\n\\n')\n }\n\n injectAll(targetDocument: Document = globalThis.document): HTMLStyleElement {\n if (targetDocument?.head == null) {\n throw new TypeError('StyleRegistry.injectAll requires a document with a head')\n }\n const selector = `style[${STYLE_ATTRIBUTE}=\"${escapeAttributeValue(this.id)}\"]`\n let style = targetDocument.head.querySelector<HTMLStyleElement>(selector)\n if (style == null) {\n style = targetDocument.createElement('style')\n style.setAttribute(STYLE_ATTRIBUTE, this.id)\n targetDocument.head.prepend(style)\n }\n const css = this.generateCSS()\n if (style.textContent !== css) style.textContent = css\n return style\n }\n\n reset(): void {\n this.cssFragments.clear()\n this.baseStyleMap.clear()\n }\n}\n\n/** Create an isolated registry for a configured Fray application runtime. */\nexport function createStyleRegistry(): StyleRegistry {\n return new StyleRegistry()\n}\n\n/** Backward-compatible structural styles for the default Fray runtime. */\nexport const styleRegistry = new StyleRegistry('')\n\nfunction splitDefinition(definition: BaseStyleDefinition): {\n properties: CSSDeclarations\n variants: CSSVariantMap\n} {\n const properties: CSSDeclarations = {}\n let variants: CSSVariantMap = {}\n for (const [property, value] of Object.entries(definition)) {\n if (property === 'variants') {\n if (typeof value !== 'object') {\n throw new TypeError('Base style variants must be declaration maps')\n }\n variants = value\n } else if (typeof value === 'string') {\n properties[property] = value\n } else {\n throw new TypeError(`Base style property ${property} must be a string`)\n }\n }\n return {properties, variants}\n}\n\nfunction renderRule(\n label: string,\n selectors: string[],\n properties: CSSDeclarations,\n): string {\n if (selectors.length === 0 || Object.keys(properties).length === 0) return ''\n const declarations = Object.entries(properties)\n .map(([property, value]) => ` ${property}: ${value};`)\n .join('\\n')\n return `/* ${label} */\\n${selectors.join(',\\n')} {\\n${declarations}\\n}\\n\\n`\n}\n\nfunction appendVariant(selector: string, variant: string): string {\n const pseudoElement = selector.indexOf('::')\n if (pseudoElement < 0) return `${selector}${variant}`\n return `${selector.slice(0, pseudoElement)}${variant}${selector.slice(pseudoElement)}`\n}\n\nfunction escapeAttributeValue(value: string): string {\n return value.replaceAll('\\\\', '\\\\\\\\').replaceAll('\"', '\\\\\"')\n}\n","import type {\n Component,\n ComponentDependency,\n} from './Components/component.js'\nimport {\n createStyleRegistry,\n styleRegistry,\n} from './styling/styleRegistry.js'\nimport type {StyleRegistry} from './styling/styleRegistry.js'\n\nconst RESERVED_CUSTOM_ELEMENT_NAMES = new Set([\n 'annotation-xml',\n 'color-profile',\n 'font-face',\n 'font-face-src',\n 'font-face-uri',\n 'font-face-format',\n 'font-face-name',\n 'missing-glyph',\n])\n\nexport interface FrayElementNameOptions {\n /** Namespace prepended to component host names. Defaults to `fray`. */\n prefix?: string | null\n /** Complete standards-valid tag names keyed by stable component host name. */\n overrides?: Readonly<Record<string, string>>\n}\n\nexport interface FrayRuntimeOptions {\n elementNames?: FrayElementNameOptions\n}\n\n/** Immutable application scope for element naming and structural styles. */\nexport class FrayRuntime {\n readonly elementPrefix: string | null\n readonly elementNameOverrides: Readonly<Record<string, string>>\n readonly styleRegistry: StyleRegistry\n\n constructor(\n options: FrayRuntimeOptions = {},\n registry: StyleRegistry = createStyleRegistry(),\n ) {\n if (options == null || typeof options !== 'object' || Array.isArray(options)) {\n throw new TypeError('FrayRuntime options must be an object')\n }\n const elementNames = options.elementNames ?? {}\n if (elementNames == null\n || typeof elementNames !== 'object'\n || Array.isArray(elementNames)) {\n throw new TypeError('Fray elementNames must be an object')\n }\n const prefix = elementNames.prefix === undefined ? 'fray' : elementNames.prefix\n if (prefix !== null) assertNamePart(prefix, 'Fray element prefix')\n\n const overrides = elementNames.overrides ?? {}\n if (overrides == null || typeof overrides !== 'object' || Array.isArray(overrides)) {\n throw new TypeError('Fray element-name overrides must be an object')\n }\n for (const [componentName, tagName] of Object.entries(overrides)) {\n assertNamePart(componentName, 'Fray component host name')\n assertCustomElementName(tagName)\n }\n\n this.elementPrefix = prefix\n this.elementNameOverrides = Object.freeze({...overrides})\n this.styleRegistry = registry\n }\n\n resolveElementName(hostName: string, standaloneHostName: string | null = null): string {\n assertNamePart(hostName, 'Fray component host name')\n const override = this.elementNameOverrides[hostName]\n const resolved = override\n ?? (this.elementPrefix == null\n ? standaloneHostName ?? hostName\n : `${this.elementPrefix}-${hostName}`)\n assertCustomElementName(resolved)\n return resolved\n }\n\n resolveHostSelector(\n selector: string,\n hostName: string,\n standaloneHostName: string | null = null,\n ): string {\n if (typeof selector !== 'string') throw new TypeError('Host selector must be a string')\n return selector.replaceAll('&', this.resolveElementName(hostName, standaloneHostName))\n }\n\n resolveHostCSS(\n cssText: string,\n hostName: string,\n standaloneHostName: string | null = null,\n ): string {\n if (typeof cssText !== 'string') throw new TypeError('Host CSS must be a string')\n return cssText.replaceAll('&', this.resolveElementName(hostName, standaloneHostName))\n }\n\n create<TArgs extends unknown[], TComponent extends Component>(\n componentType: new(...args: TArgs) => TComponent,\n ...args: TArgs\n ): TComponent {\n const component = new componentType(...args)\n component._setRuntime(this)\n return component\n }\n\n mount<TComponent extends Component>(\n component: TComponent,\n parent: ParentNode,\n before: Node | null = null,\n ): TComponent {\n component._setRuntime(this)\n component.mount(parent, before)\n return component\n }\n\n registerStyles(dependency: ComponentDependency): this {\n if (dependency == null || typeof dependency.registerStyles !== 'function') {\n throw new TypeError('registerStyles requires a Fray component dependency')\n }\n dependency.registerStyles(this)\n return this\n }\n\n injectStyles(targetDocument: Document = globalThis.document): HTMLStyleElement {\n return this.styleRegistry.injectAll(targetDocument)\n }\n}\n\nexport function createFrayRuntime(options: FrayRuntimeOptions = {}): FrayRuntime {\n return new FrayRuntime(options)\n}\n\n/** Runtime used by Component.new(), direct mount(), and the legacy styleRegistry export. */\nexport const defaultFrayRuntime = new FrayRuntime({}, styleRegistry)\n\nfunction assertNamePart(value: unknown, label: string): asserts value is string {\n if (typeof value !== 'string' || !/^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$/.test(value)) {\n throw new TypeError(`${label} must be a lowercase kebab-case name`)\n }\n}\n\nfunction assertCustomElementName(value: unknown): asserts value is string {\n assertNamePart(value, 'Fray element name')\n if (!value.includes('-') || RESERVED_CUSTOM_ELEMENT_NAMES.has(value)) {\n throw new TypeError(`Fray element name must be a non-reserved name containing a hyphen: ${value}`)\n }\n}\n","import type {\n EventBubble,\n FetchStateValue,\n ReadableEmitter,\n} from '@sylwellsoftware/glue'\n\nimport {FrayRuntime, defaultFrayRuntime} from '../runtime.js'\n\nexport const Fragment = Symbol.for('@sylwellsoftware/fray.Fragment')\n\nexport type Key = string | number\n\nexport interface ComponentProps {\n key?: Key | null\n children?: FrayChild | readonly FrayChild[]\n class?: string | null\n className?: string | null\n [name: string]: unknown\n}\n\nexport type Ref<TNode extends Node = Node> =\n | ((value: TNode | null) => void)\n | {current: TNode | null}\n\nexport type FunctionComponent<TProps extends ComponentProps = ComponentProps> = (\n props: TProps,\n) => FrayChild\n\nexport type ComponentConstructor<\n TProps extends ComponentProps = ComponentProps,\n TInstance extends Component<TProps> = Component<TProps>,\n> = new(props: TProps) => TInstance\n\ntype AnyComponentConstructor = new(props?: never) => Component\ntype ConcreteComponentConstructor = new(...args: never[]) => Component\n\nexport type VNodeType<TProps extends ComponentProps = ComponentProps> =\n | string\n | typeof Fragment\n | ComponentConstructor<TProps>\n | FunctionComponent<TProps>\n\nexport interface VNode<TProps extends ComponentProps = ComponentProps> {\n readonly type: string | typeof Fragment | Function\n readonly key: Key | null\n readonly props: TProps & {children: NormalizedChild[]}\n}\n\nexport type FrayChild =\n | string\n | number\n | boolean\n | null\n | undefined\n | VNode\n | Component\n | ReadableEmitter<FrayChild, unknown>\n | readonly FrayChild[]\n\ntype NormalizedChild = string | number | VNode | Component | ReadableEmitter<FrayChild, unknown>\n\ndeclare const liveBindingBrand: unique symbol\n\n/** Explicitly subscribe a DOM or component property to an emitter's current value. */\nexport interface LiveBinding<TValue> {\n readonly emitter: ReadableEmitter<TValue, unknown>\n readonly [liveBindingBrand]: true\n}\n\n/** Minimal writable Glue contract used by native `bind:value` and `bind:checked`. */\nexport interface WritableEmitter<TValue, TError = unknown>\nextends ReadableEmitter<TValue, TError> {\n set(value: TValue, eventOrCause?: unknown): unknown\n}\n\nexport interface EmitterSnapshot<TValue, TError = unknown> {\n readonly value: TValue\n readonly fetchState: FetchStateValue\n readonly error: TError | null\n}\n\nexport type TemplateProps<TProps extends ComponentProps> = {\n [TName in keyof TProps]: TName extends 'key' | 'children'\n ? TProps[TName]\n : TProps[TName] | LiveBinding<Exclude<TProps[TName], undefined>>\n}\n\nexport type BaseStyleNames = string | readonly string[]\nexport type BaseStyles =\n | Readonly<Record<string, BaseStyleNames>>\n | ReadonlyArray<readonly [string, BaseStyleNames]>\n\nexport interface ComponentDependency {\n registerStyles(runtime?: FrayRuntime, seen?: Set<ComponentDependency>): void\n}\n\ninterface Watchable {\n subscribe(\n listener: (notification: {event: EventBubble<unknown> | null}) => void,\n options?: {emitCurrent?: boolean},\n ): () => void\n}\n\nconst liveBindingValues = new WeakSet<object>()\n\nconst BOOLEAN_ATTRIBUTES = new Set([\n 'allowFullScreen',\n 'async',\n 'autoFocus',\n 'autoPlay',\n 'checked',\n 'controls',\n 'default',\n 'defer',\n 'disabled',\n 'formNoValidate',\n 'hidden',\n 'inert',\n 'loop',\n 'multiple',\n 'muted',\n 'noModule',\n 'noValidate',\n 'open',\n 'playsInline',\n 'readOnly',\n 'required',\n 'reversed',\n 'selected',\n])\n\nconst PROPERTY_PROPS = new Set([\n 'checked',\n 'defaultChecked',\n 'defaultValue',\n 'disabled',\n 'indeterminate',\n 'multiple',\n 'muted',\n 'readOnly',\n 'required',\n 'selected',\n 'selectedIndex',\n 'tabIndex',\n 'value',\n])\n\n/** Mark an emitter as a one-way live value for a DOM or component property. */\nexport function live<TValue>(emitter: ReadableEmitter<TValue, unknown>): LiveBinding<TValue> {\n assertReadableEmitter(emitter, 'live')\n const binding = Object.freeze({emitter}) as LiveBinding<TValue>\n liveBindingValues.add(binding)\n return binding\n}\n\n/** Build a Fray virtual node. */\nexport function h<TProps extends ComponentProps = ComponentProps>(\n type: VNodeType<TProps>,\n props: TemplateProps<TProps> | null = null,\n ...children: FrayChild[]\n): VNode<TProps> {\n const suppliedProps = props ?? {} as TemplateProps<TProps>\n if (typeof suppliedProps !== 'object' || Array.isArray(suppliedProps)) {\n throw new TypeError('VNode props must be an object or null')\n }\n const {\n children: propChildren,\n key = null,\n ...restProps\n } = suppliedProps\n return {\n type,\n key,\n props: {\n ...restProps,\n children: normalizeChildren([propChildren, children]),\n } as TProps & {children: NormalizedChild[]},\n }\n}\n\ntype LiveValue<TValue> = TValue | LiveBinding<Exclude<TValue, undefined>>\n\ntype AriaAttributes = {\n [TName in `aria-${string}`]?: LiveValue<string | number | boolean | null | undefined>\n}\n\ntype DataAttributes = {\n [TName in `data-${string}`]?: LiveValue<string | number | boolean | null | undefined>\n}\n\ninterface DOMEvents<TElement extends HTMLElement> {\n onClick?: ((event: MouseEvent & {currentTarget: TElement}) => void) | undefined\n onInput?: ((event: InputEvent & {currentTarget: TElement}) => void) | undefined\n onChange?: ((event: Event & {currentTarget: TElement}) => void) | undefined\n onKeyDown?: ((event: KeyboardEvent & {currentTarget: TElement}) => void) | undefined\n onKeyUp?: ((event: KeyboardEvent & {currentTarget: TElement}) => void) | undefined\n onFocus?: ((event: FocusEvent & {currentTarget: TElement}) => void) | undefined\n onBlur?: ((event: FocusEvent & {currentTarget: TElement}) => void) | undefined\n}\n\ntype FrayDOMProps<TElement extends HTMLElement> =\nOmit<ComponentProps, 'class' | 'className'>\n& DOMEvents<TElement>\n& AriaAttributes\n& DataAttributes\n& {\n class?: LiveValue<string | undefined>\n className?: LiveValue<string | undefined>\n for?: string | undefined\n htmlFor?: string | undefined\n ref?: Ref<TElement> | undefined\n style?: LiveValue<string | Record<string, string | number | null | undefined> | undefined>\n}\n\ntype LiveDOMProperties<TElement extends HTMLElement> = {\n [TName in keyof Omit<TElement, keyof ComponentProps | 'style' | 'children'>]?:\n LiveValue<TElement[TName] | undefined>\n}\n\ntype NativeValueBinding<TElement extends HTMLElement> =\n TElement extends HTMLInputElement | HTMLTextAreaElement | HTMLSelectElement\n ? {'bind:value'?: WritableEmitter<string> | undefined}\n : {}\n\ntype NativeCheckedBinding<TElement extends HTMLElement> =\n TElement extends HTMLInputElement\n ? {'bind:checked'?: WritableEmitter<boolean> | undefined}\n : {}\n\nexport type FrayIntrinsicElements = {\n [TTag in keyof HTMLElementTagNameMap]: FrayDOMProps<HTMLElementTagNameMap[TTag]>\n & LiveDOMProperties<HTMLElementTagNameMap[TTag]>\n & NativeValueBinding<HTMLElementTagNameMap[TTag]>\n & NativeCheckedBinding<HTMLElementTagNameMap[TTag]>\n}\n\n/** Classic JSX type namespace for consumers configured with `jsxFactory: \"h\"`. */\nexport namespace h {\n export namespace JSX {\n export type Element = VNode | Component\n export interface ElementClass extends Component {}\n export interface ElementAttributesProperty {\n props: {}\n }\n export interface ElementChildrenAttribute {\n children: {}\n }\n export interface IntrinsicAttributes {\n key?: Key\n }\n export type LibraryManagedAttributes<_TComponent, TProps extends ComponentProps> =\n TemplateProps<TProps>\n export type IntrinsicElements = FrayIntrinsicElements\n }\n}\n\nexport function css(strings: TemplateStringsArray, ...values: unknown[]): string {\n return strings.reduce((result, string, index) =>\n result + string + String(values[index] ?? ''), '')\n}\n\nexport class Component<TProps extends ComponentProps = ComponentProps> {\n static dependencies: ComponentDependency[] = []\n static css = ''\n static hostName: string | null = null\n static standaloneHostName: string | null = null\n\n static new<TConstructor extends ConcreteComponentConstructor>(\n this: TConstructor,\n ...args: ConstructorParameters<TConstructor>\n ): InstanceType<TConstructor> {\n const instance = new this(...args)\n if (!(instance instanceof Component)) {\n throw new TypeError('Component.new() requires a Component constructor')\n }\n return instance.mount() as InstanceType<TConstructor>\n }\n\n static get baseStyles(): unknown {\n return {}\n }\n\n static registerStyles(\n this: ComponentDependency & {\n css?: string\n baseStyles?: unknown\n dependencies?: ComponentDependency[]\n hostName?: string | null\n standaloneHostName?: string | null\n },\n runtime: FrayRuntime = defaultFrayRuntime,\n seen: Set<ComponentDependency> = new Set(),\n ): void {\n if (seen.has(this)) return\n seen.add(this)\n\n const hostName = this.hostName ?? null\n const standaloneHostName = this.standaloneHostName ?? null\n if (this.css) {\n runtime.styleRegistry.registerCSS(hostName == null\n ? this.css\n : runtime.resolveHostCSS(this.css, hostName, standaloneHostName))\n }\n const baseStyles = normalizeBaseStyles(this.baseStyles)\n for (const [selector, styleNames] of baseStyles) {\n runtime.styleRegistry.registerBaseStyle(hostName == null\n ? selector\n : runtime.resolveHostSelector(selector, hostName, standaloneHostName), styleNames)\n }\n for (const dependency of this.dependencies ?? []) {\n dependency.registerStyles(runtime, seen)\n }\n }\n\n props: TProps\n dom: ChildNode | null = null\n /** @internal */\n _rendered: RenderRecord | null = null\n /** @internal */\n readonly _childComponents = new Set<Component>()\n private initialized = false\n private mounted = false\n private destroyed = false\n private updating = false\n private updateRequested = false\n private readonly cleanupFunctions = new Set<() => void>()\n private readonly watched = new Map<Watchable, () => void>()\n private readonly renderReadSubscriptions = new Map<Watchable, () => void>()\n private collectingRenderReads: Set<Watchable> | null = null\n /** @internal */\n _runtime: FrayRuntime = defaultFrayRuntime\n\n constructor(props: TProps = {} as TProps) {\n if (props == null || typeof props !== 'object' || Array.isArray(props)) {\n throw new TypeError(`${this.constructor.name} props must be an object`)\n }\n this.props = props\n }\n\n /** One-time setup hook. Constructors must not subscribe or render. */\n initialize(): void {}\n\n render(): FrayChild {\n throw new Error(`${this.constructor.name} must implement render()`)\n }\n\n /** Render this component's configured custom host element. */\n protected host(props: ComponentProps | null = null, ...children: FrayChild[]): VNode {\n const componentType = this.constructor as typeof Component\n const hostName = componentType.hostName\n if (hostName == null) {\n throw new Error(`${this.constructor.name} does not declare a custom host name`)\n }\n return h(this._runtime.resolveElementName(\n hostName,\n componentType.standaloneHostName,\n ), {\n ...props,\n 'data-fray-component': hostName,\n }, ...children)\n }\n\n /** JSX component for this instance's runtime-configured custom host. */\n protected readonly Host: (props: ComponentProps) => VNode = ({\n children = [],\n ...props\n }) => this.host(props, children)\n\n /** @internal Assign an immutable application runtime before initialization or mounting. */\n _setRuntime(runtime: FrayRuntime): this {\n if (!(runtime instanceof FrayRuntime)) {\n throw new TypeError('Component runtime must be a FrayRuntime')\n }\n if (runtime === this._runtime) return this\n if (this.initialized || this.mounted || this._rendered != null) {\n throw new Error('Cannot change a component runtime after initialization')\n }\n this._runtime = runtime\n return this\n }\n\n mount(parent: ParentNode | null = null, before: Node | null = null): this {\n if (this.destroyed) throw new Error('Cannot mount a destroyed component')\n let mountedNow = false\n if (!this.initialized) {\n this.initialized = true\n this.initialize()\n }\n if (!this.mounted) {\n this.mounted = true\n this.update()\n mountedNow = true\n }\n if (parent != null) {\n assertParentNode(parent)\n insertRecord(parent, this._rendered, before)\n }\n if (mountedNow) this.afterMount(this.dom)\n return this\n }\n\n attachTo(parent: ParentNode): this {\n this.mount(parent)\n return this\n }\n\n update(_event?: unknown): this {\n if (this.destroyed) return this\n if (!this.mounted) return this.mount()\n if (this.updating) {\n this.updateRequested = true\n return this\n }\n\n this.updating = true\n try {\n do {\n this.updateRequested = false\n const nextReads = new Set<Watchable>()\n this.collectingRenderReads = nextReads\n let nextVNode: NormalizedChild\n try {\n nextVNode = normalizeRoot(this.render())\n } finally {\n this.collectingRenderReads = null\n }\n this._rendered = patchRoot(this._rendered, nextVNode, this)\n this.dom = firstNode(this._rendered)\n this.reconcileRenderReads(nextReads)\n this.afterUpdate(this.dom)\n } while (this.updateRequested && !this.destroyed)\n } finally {\n this.updating = false\n }\n return this\n }\n\n setProps(nextProps: TProps): this {\n if (nextProps == null || typeof nextProps !== 'object' || Array.isArray(nextProps)) {\n throw new TypeError(`${this.constructor.name} props must be an object`)\n }\n this.props = nextProps\n if (this.mounted) this.update()\n return this\n }\n\n afterMount(_dom: ChildNode | null): void {}\n afterUpdate(_dom: ChildNode | null): void {}\n\n watch(...observables: Watchable[]): this {\n for (const observable of observables) {\n if (observable == null || typeof observable.subscribe !== 'function') {\n throw new TypeError('watch requires emitter-like values')\n }\n if (this.watched.has(observable)) continue\n const unsubscribe = observable.subscribe(({event}) => {\n if (this.mounted && !this.destroyed) this.update(event)\n }, {emitCurrent: false})\n this.watched.set(observable, unsubscribe)\n this.onCleanup(() => {\n unsubscribe()\n this.watched.delete(observable)\n })\n }\n return this\n }\n\n watchFutureValues(...observables: Watchable[]): this {\n return this.watch(...observables)\n }\n\n /** Read an emitter during render and rerender when that dependency changes. */\n read<TValue, TError>(emitter: ReadableEmitter<TValue, TError>): TValue {\n this.trackRenderRead(emitter)\n return emitter.get()\n }\n\n /** Read a Glue value, fetch state, and error as one tracked render dependency. */\n snapshot<TValue, TError>(\n emitter: ReadableEmitter<TValue, TError>,\n ): EmitterSnapshot<TValue, TError> {\n this.trackRenderRead(emitter)\n return Object.freeze({\n value: emitter.get(),\n fetchState: emitter.getFetchState(),\n error: emitter.getError(),\n })\n }\n\n onCleanup(cleanup: () => void): () => void {\n if (typeof cleanup !== 'function') throw new TypeError('cleanup must be a function')\n if (this.destroyed) {\n cleanup()\n return () => {}\n }\n this.cleanupFunctions.add(cleanup)\n let active = true\n return () => {\n if (!active) return\n active = false\n this.cleanupFunctions.delete(cleanup)\n cleanup()\n }\n }\n\n listen<TEvent extends Event = Event>(\n target: EventTarget,\n type: string,\n listener: (event: TEvent) => void,\n options?: boolean | AddEventListenerOptions,\n ): this {\n if (target == null || typeof target.addEventListener !== 'function') {\n throw new TypeError('listen target must be an EventTarget')\n }\n const eventListener = listener as EventListener\n target.addEventListener(type, eventListener, options)\n this.onCleanup(() => target.removeEventListener(type, eventListener, options))\n return this\n }\n\n registerChild<TComponent extends Component>(component: TComponent): TComponent {\n if (!(component instanceof Component)) {\n throw new TypeError('registerChild requires a Component')\n }\n this._childComponents.add(component)\n return component\n }\n\n destroy(): void {\n if (this.destroyed) return\n this.destroyed = true\n this.mounted = false\n\n for (const cleanup of [...this.cleanupFunctions]) cleanup()\n this.cleanupFunctions.clear()\n this.watched.clear()\n for (const unsubscribe of this.renderReadSubscriptions.values()) unsubscribe()\n this.renderReadSubscriptions.clear()\n this.collectingRenderReads = null\n\n if (this._rendered) disposeRecord(this._rendered, true)\n this._rendered = null\n this.dom = null\n this._childComponents.clear()\n this.onDestroy()\n }\n\n onDestroy(): void {}\n\n private trackRenderRead(emitter: ReadableEmitter<unknown, unknown>): void {\n assertReadableEmitter(emitter, 'Component.read')\n if (this.collectingRenderReads == null) {\n throw new Error('Component.read() and snapshot() may only be called during render()')\n }\n this.collectingRenderReads.add(emitter)\n }\n\n private reconcileRenderReads(nextReads: Set<Watchable>): void {\n for (const [emitter, unsubscribe] of this.renderReadSubscriptions) {\n if (nextReads.has(emitter)) continue\n unsubscribe()\n this.renderReadSubscriptions.delete(emitter)\n }\n for (const emitter of nextReads) {\n if (this.watched.has(emitter) || this.renderReadSubscriptions.has(emitter)) continue\n const unsubscribe = emitter.subscribe(({event}) => {\n if (this.mounted && !this.destroyed) this.update(event)\n }, {emitCurrent: false})\n this.renderReadSubscriptions.set(emitter, unsubscribe)\n }\n }\n}\n\ninterface RecordBase {\n readonly kind: string\n key: Key | null\n owner: Component\n}\n\ninterface TextRecord extends RecordBase {\n readonly kind: 'text'\n value: string | number\n node: Text\n}\n\ninterface EmitterRecord extends RecordBase {\n readonly kind: 'emitter'\n source: ReadableEmitter<FrayChild, unknown>\n start: Comment\n end: Comment\n child: RenderRecord\n unsubscribe: () => void\n}\n\ninterface LivePropRecord {\n source: ReadableEmitter<unknown, unknown>\n value: unknown\n unsubscribe: () => void\n}\n\ninterface NativeBindingRecord extends LivePropRecord {\n eventName: 'input' | 'change'\n listener: EventListener\n}\n\ninterface ElementRecord extends RecordBase {\n readonly kind: 'element'\n type: string\n node: HTMLElement\n props: ComponentProps\n listeners: Map<string, EventListener>\n liveProps: Map<string, LivePropRecord>\n nativeBindings: Map<string, NativeBindingRecord>\n ref: Ref<HTMLElement> | null\n children: RenderRecord[]\n}\n\ninterface FragmentRecord extends RecordBase {\n readonly kind: 'fragment'\n type: typeof Fragment\n start: Comment\n end: Comment\n children: RenderRecord[]\n}\n\ninterface ComponentRecord extends RecordBase {\n readonly kind: 'component'\n type: Function\n instance: Component\n prebuilt: boolean\n props: ComponentProps\n liveProps: Map<string, LivePropRecord>\n}\n\ninterface FunctionRecord extends RecordBase {\n readonly kind: 'function'\n type: FunctionComponent\n props: ComponentProps\n sourceProps: ComponentProps\n liveProps: Map<string, LivePropRecord>\n child: RenderRecord\n}\n\ntype RenderRecord =\n | TextRecord\n | EmitterRecord\n | ElementRecord\n | FragmentRecord\n | ComponentRecord\n | FunctionRecord\n\nfunction normalizeRoot(value: FrayChild): NormalizedChild {\n if (Array.isArray(value)) return h(Fragment, null, value)\n if (value == null || typeof value === 'boolean') return h(Fragment)\n return value as NormalizedChild\n}\n\nfunction normalizeChildren(values: FrayChild | readonly FrayChild[]): NormalizedChild[] {\n const normalized: NormalizedChild[] = []\n const visit = (value: FrayChild): void => {\n if (Array.isArray(value)) {\n for (const child of value) visit(child)\n } else if (value != null && typeof value !== 'boolean') {\n normalized.push(value as NormalizedChild)\n }\n }\n visit(values)\n return normalized\n}\n\nfunction createRecord(value: NormalizedChild, owner: Component): RenderRecord {\n if (typeof value === 'string' || typeof value === 'number') {\n return {\n kind: 'text',\n key: null,\n value,\n node: document.createTextNode(String(value)),\n owner,\n }\n }\n\n if (isReadableEmitter(value)) {\n const start = document.createComment('fray-emitter-start')\n const end = document.createComment('fray-emitter-end')\n const current = value.get()\n if (Object.is(current, value)) {\n throw new TypeError('A Fray emitter child cannot render itself')\n }\n const fragment = document.createDocumentFragment()\n fragment.append(start, end)\n const child = createRecord(normalizeRoot(current), owner)\n insertRecord(fragment, child, end)\n const record: EmitterRecord = {\n kind: 'emitter',\n key: null,\n source: value,\n start,\n end,\n child,\n unsubscribe: () => {},\n owner,\n }\n record.unsubscribe = value.subscribe(({value: nextValue}) => {\n if (Object.is(nextValue, value)) {\n throw new TypeError('A Fray emitter child cannot render itself')\n }\n record.child = patchRoot(record.child, normalizeRoot(nextValue), owner)\n }, {emitCurrent: false})\n return record\n }\n\n if (value instanceof Component) {\n value._setRuntime(owner._runtime)\n value.mount()\n owner.registerChild(value)\n return {\n kind: 'component',\n key: readKey(value.props),\n type: value.constructor,\n instance: value,\n prebuilt: true,\n props: value.props,\n liveProps: new Map(),\n owner,\n }\n }\n\n if (!isVNode(value)) {\n throw new TypeError(`Invalid Fray child: ${describeValue(value)}`)\n }\n\n const {type, key = null, props} = value\n if (type === Fragment) {\n const start = document.createComment('fray-fragment-start')\n const end = document.createComment('fray-fragment-end')\n const record: FragmentRecord = {\n kind: 'fragment',\n key,\n type,\n start,\n end,\n children: [],\n owner,\n }\n const fragment = document.createDocumentFragment()\n fragment.append(start, end)\n record.children = patchChildren(\n fragment,\n [],\n props.children,\n owner,\n end,\n start,\n )\n return record\n }\n\n if (typeof type === 'string') {\n const node = document.createElement(type)\n const record: ElementRecord = {\n kind: 'element',\n key,\n type,\n node,\n props: {},\n listeners: new Map(),\n liveProps: new Map(),\n nativeBindings: new Map(),\n ref: null,\n children: [],\n owner,\n }\n patchElementProps(record, props)\n record.children = patchChildren(node, [], props.children, owner)\n return record\n }\n\n if (isComponentClass(type)) {\n const sourceProps = props as ComponentProps\n const resolvedProps = resolveLivePropValues(sourceProps)\n const instance = new type(resolvedProps as never)\n instance._setRuntime(owner._runtime)\n const record: ComponentRecord = {\n kind: 'component',\n key,\n type,\n instance,\n prebuilt: false,\n props: resolvedProps,\n liveProps: new Map(),\n owner,\n }\n subscribeComponentLiveProps(record, sourceProps)\n instance.mount()\n owner.registerChild(instance)\n return record\n }\n\n if (typeof type === 'function') {\n const functionType = type as FunctionComponent\n const sourceProps = props as ComponentProps\n const functionProps = resolveLivePropValues(sourceProps)\n const rendered = normalizeRoot(functionType(functionProps))\n const record: FunctionRecord = {\n kind: 'function',\n key,\n type: functionType,\n props: functionProps,\n sourceProps,\n liveProps: new Map(),\n child: createRecord(rendered, owner),\n owner,\n }\n subscribeFunctionLiveProps(record)\n return record\n }\n\n throw new TypeError(`Unsupported vnode type: ${describeValue(type)}`)\n}\n\nfunction patchRoot(\n previous: RenderRecord | null,\n value: NormalizedChild,\n owner: Component,\n): RenderRecord {\n if (previous == null) return createRecord(value, owner)\n if (isCompatible(previous, value)) return patchCompatible(previous, value, owner)\n\n const next = createRecord(value, owner)\n const anchor = firstNode(previous)\n const parent = anchor?.parentNode ?? null\n if (parent) insertRecord(parent, next, anchor)\n disposeRecord(previous, true)\n return next\n}\n\nfunction patchCompatible(\n record: RenderRecord,\n value: NormalizedChild,\n owner: Component,\n): RenderRecord {\n if (record.kind === 'text') {\n if (typeof value !== 'string' && typeof value !== 'number') return record\n if (!Object.is(record.value, value)) {\n record.value = value\n record.node.data = String(value)\n }\n return record\n }\n\n if (record.kind === 'emitter') {\n if (!isReadableEmitter(value) || record.source !== value) return record\n return record\n }\n\n if (record.kind === 'component') {\n if (value instanceof Component) return record\n if (isVNode(value)) patchComponentLiveProps(record, value.props)\n return record\n }\n\n if (!isVNode(value)) return record\n\n if (record.kind === 'function') {\n patchFunctionLiveProps(record, value.props)\n return record\n }\n\n if (record.kind === 'fragment') {\n record.children = patchChildren(\n record.start.parentNode,\n record.children,\n value.props.children,\n owner,\n record.end,\n record.start,\n )\n return record\n }\n\n patchElementProps(record, value.props)\n record.children = patchChildren(\n record.node,\n record.children,\n value.props.children,\n owner,\n )\n return record\n}\n\nfunction resolveLivePropValues(sourceProps: ComponentProps): ComponentProps {\n return Object.fromEntries(Object.entries(sourceProps).map(([key, value]) => [\n key,\n isLiveBinding(value) ? value.emitter.get() : value,\n ]))\n}\n\nfunction subscribeComponentLiveProps(\n record: ComponentRecord,\n sourceProps: ComponentProps,\n): void {\n reconcileLiveProps(record.liveProps, sourceProps, (key, value) => {\n record.props = {...record.props, [key]: value}\n record.instance.setProps(record.props)\n })\n record.props = resolvedLiveProps(record.liveProps, sourceProps)\n record.instance.setProps(record.props)\n}\n\nfunction patchComponentLiveProps(record: ComponentRecord, sourceProps: ComponentProps): void {\n subscribeComponentLiveProps(record, sourceProps)\n}\n\nfunction subscribeFunctionLiveProps(record: FunctionRecord): void {\n reconcileLiveProps(record.liveProps, record.sourceProps, (key, value) => {\n record.props = {...record.props, [key]: value}\n rerenderFunctionRecord(record)\n })\n record.props = resolvedLiveProps(record.liveProps, record.sourceProps)\n}\n\nfunction patchFunctionLiveProps(record: FunctionRecord, sourceProps: ComponentProps): void {\n record.sourceProps = sourceProps\n reconcileLiveProps(record.liveProps, sourceProps, (key, value) => {\n record.props = {...record.props, [key]: value}\n rerenderFunctionRecord(record)\n })\n record.props = resolvedLiveProps(record.liveProps, sourceProps)\n rerenderFunctionRecord(record)\n}\n\nfunction rerenderFunctionRecord(record: FunctionRecord): void {\n const rendered = normalizeRoot(record.type(record.props))\n record.child = patchRoot(record.child, rendered, record.owner)\n}\n\nfunction reconcileLiveProps(\n subscriptions: Map<string, LivePropRecord>,\n sourceProps: ComponentProps,\n onValue: (key: string, value: unknown) => void,\n): void {\n for (const [key, existing] of subscriptions) {\n const next = sourceProps[key]\n if (isLiveBinding(next) && next.emitter === existing.source) continue\n existing.unsubscribe()\n subscriptions.delete(key)\n }\n\n for (const [key, value] of Object.entries(sourceProps)) {\n if (!isLiveBinding(value) || subscriptions.has(key)) continue\n const liveProp: LivePropRecord = {\n source: value.emitter,\n value: value.emitter.get(),\n unsubscribe: () => {},\n }\n liveProp.unsubscribe = value.emitter.subscribe(({value: nextValue}) => {\n if (subscriptions.get(key) !== liveProp) return\n liveProp.value = nextValue\n onValue(key, nextValue)\n }, {emitCurrent: false})\n subscriptions.set(key, liveProp)\n }\n}\n\nfunction resolvedLiveProps(\n subscriptions: Map<string, LivePropRecord>,\n sourceProps: ComponentProps,\n): ComponentProps {\n return Object.fromEntries(Object.entries(sourceProps).map(([key, value]) => [\n key,\n isLiveBinding(value) ? subscriptions.get(key)?.value ?? value.emitter.get() : value,\n ]))\n}\n\nfunction patchChildren(\n parent: ParentNode | null,\n previous: RenderRecord[],\n values: FrayChild | readonly FrayChild[],\n owner: Component,\n end: Node | null = null,\n start: Node | null = null,\n): RenderRecord[] {\n if (parent == null) throw new Error('Cannot patch a detached fragment range')\n const nextValues = normalizeChildren(values)\n const keyed = new Map<Key, RenderRecord>()\n const unkeyed: RenderRecord[] = []\n for (const record of previous) {\n if (record.key == null) unkeyed.push(record)\n else if (!keyed.has(record.key)) keyed.set(record.key, record)\n }\n\n const seenKeys = new Set<Key>()\n const retained = new Set<RenderRecord>()\n const nextRecords: RenderRecord[] = []\n let unkeyedIndex = 0\n\n for (const value of nextValues) {\n const key = valueKey(value)\n if (key != null) {\n if (seenKeys.has(key)) throw new Error(`Duplicate sibling key: ${String(key)}`)\n seenKeys.add(key)\n }\n const candidate = key == null\n ? unkeyed[unkeyedIndex++]\n : keyed.get(key)\n if (candidate && isCompatible(candidate, value)) {\n retained.add(candidate)\n nextRecords.push(patchCompatible(candidate, value, owner))\n } else {\n nextRecords.push(createRecord(value, owner))\n }\n }\n\n for (const record of previous) {\n if (!retained.has(record)) disposeRecord(record, true)\n }\n\n let cursor = start ? start.nextSibling : parent.firstChild\n for (const record of nextRecords) {\n for (const node of recordNodes(record)) {\n if (node === cursor) {\n cursor = cursor.nextSibling\n } else {\n parent.insertBefore(node, cursor ?? end)\n cursor = node.nextSibling\n }\n }\n }\n\n return nextRecords\n}\n\nfunction patchElementProps(record: ElementRecord, nextProps: ComponentProps): void {\n const {children: _nextChildren, ...next} = nextProps\n const previous = record.props\n const keys = new Set([...Object.keys(previous), ...Object.keys(next)])\n\n for (const property of ['value', 'checked'] as const) {\n if (Object.hasOwn(next, property) && Object.hasOwn(next, `bind:${property}`)) {\n throw new Error(`${property} and bind:${property} cannot be used together`)\n }\n }\n\n for (const key of keys) {\n const previousValue = previous[key]\n const nextValue = next[key]\n if (isNativeBindingProp(key)) {\n patchNativeBinding(record, key, nextValue)\n } else if (key === 'ref') {\n if (previousValue !== nextValue) patchRef(record, nextValue)\n } else if (isEventProp(key)) {\n patchEvent(record, key, nextValue)\n } else if (isLiveBinding(nextValue)) {\n patchLiveElementProp(record, key, nextValue)\n } else {\n const previousLive = record.liveProps.get(key)\n if (previousLive) {\n previousLive.unsubscribe()\n record.liveProps.delete(key)\n }\n const previousResolved = previousLive?.value ?? previousValue\n if (!Object.is(previousResolved, nextValue)) {\n patchDOMProp(record.node, key, previousResolved, nextValue)\n }\n }\n }\n record.props = {...next}\n}\n\nfunction patchLiveElementProp(\n record: ElementRecord,\n key: string,\n binding: LiveBinding<unknown>,\n): void {\n const existing = record.liveProps.get(key)\n if (existing?.source === binding.emitter) return\n\n existing?.unsubscribe()\n const value = binding.emitter.get()\n patchDOMProp(record.node, key, existing?.value ?? record.props[key], value)\n const liveProp: LivePropRecord = {\n source: binding.emitter,\n value,\n unsubscribe: () => {},\n }\n liveProp.unsubscribe = binding.emitter.subscribe(({value: nextValue}) => {\n const previousValue = liveProp.value\n liveProp.value = nextValue\n if (!Object.is(previousValue, nextValue)) {\n patchDOMProp(record.node, key, previousValue, nextValue)\n }\n }, {emitCurrent: false})\n record.liveProps.set(key, liveProp)\n}\n\nfunction patchNativeBinding(\n record: ElementRecord,\n key: 'bind:value' | 'bind:checked',\n next: unknown,\n): void {\n const property = key.slice(5) as 'value' | 'checked'\n const existing = record.nativeBindings.get(key)\n if (next == null) {\n if (existing) {\n existing.unsubscribe()\n record.node.removeEventListener(existing.eventName, existing.listener)\n record.nativeBindings.delete(key)\n patchDOMProp(record.node, property, existing.value, undefined)\n }\n return\n }\n assertWritableEmitter(next, key)\n if (existing?.source === next) return\n\n if (existing) {\n existing.unsubscribe()\n record.node.removeEventListener(existing.eventName, existing.listener)\n }\n assertNativeBindingTarget(record.node, property)\n const eventName = nativeBindingEvent(record.node, property)\n const value = next.get()\n patchDOMProp(record.node, property, existing?.value, value)\n const listener: EventListener = () => {\n next.set(Reflect.get(record.node, property), `${key} changed`)\n }\n const binding: NativeBindingRecord = {\n source: next,\n value,\n eventName,\n listener,\n unsubscribe: () => {},\n }\n binding.unsubscribe = next.subscribe(({value: nextValue}) => {\n const previousValue = binding.value\n binding.value = nextValue\n if (!Object.is(previousValue, nextValue)) {\n patchDOMProp(record.node, property, previousValue, nextValue)\n }\n }, {emitCurrent: false})\n record.node.addEventListener(eventName, listener)\n record.nativeBindings.set(key, binding)\n}\n\nfunction patchEvent(record: ElementRecord, key: string, next: unknown): void {\n const eventName = key.slice(2).toLowerCase()\n const registered = record.listeners.get(key)\n if (registered && registered !== next) {\n record.node.removeEventListener(eventName, registered)\n record.listeners.delete(key)\n }\n if (next != null && typeof next !== 'function') {\n throw new TypeError(`${key} must be a function or null`)\n }\n if (typeof next === 'function' && registered !== next) {\n const listener = next as EventListener\n record.node.addEventListener(eventName, listener)\n record.listeners.set(key, listener)\n }\n}\n\nfunction patchRef(record: ElementRecord, next: unknown): void {\n applyRef(record.ref, null)\n if (next != null && typeof next !== 'function' && typeof next !== 'object') {\n throw new TypeError('ref must be a function, object, or null')\n }\n record.ref = next as Ref<HTMLElement> | null\n applyRef(record.ref, record.node)\n}\n\nfunction patchDOMProp(\n node: HTMLElement,\n key: string,\n previous: unknown,\n next: unknown,\n): void {\n if (key === 'class' || key === 'className') {\n setAttribute(node, 'class', next)\n return\n }\n if (key === 'for' || key === 'htmlFor') {\n setAttribute(node, 'for', next)\n return\n }\n if (key === 'dataset') {\n patchDataset(node, previous, next)\n return\n }\n if (key === 'style') {\n patchStyle(node, previous, next)\n return\n }\n if (key === 'dangerouslySetInnerHTML') {\n throw new Error('dangerouslySetInnerHTML is not supported')\n }\n\n const property = normalizePropertyName(key)\n if (BOOLEAN_ATTRIBUTES.has(property)) {\n const enabled = Boolean(next)\n if (property in node) Reflect.set(node, property, enabled)\n node.toggleAttribute(normalizeAttributeName(key), enabled)\n return\n }\n if (PROPERTY_PROPS.has(property) && property in node) {\n const value = next ?? (property === 'value' ? '' : false)\n if (!Object.is(Reflect.get(node, property), value)) Reflect.set(node, property, value)\n if (next == null) node.removeAttribute(normalizeAttributeName(key))\n return\n }\n\n setAttribute(node, normalizeAttributeName(key), next)\n}\n\nfunction patchDataset(node: HTMLElement, previous: unknown, next: unknown): void {\n const oldValues = toPropertyRecord(previous, 'dataset')\n const newValues = toPropertyRecord(next, 'dataset')\n for (const key of new Set([...Object.keys(oldValues), ...Object.keys(newValues)])) {\n const value = newValues[key]\n if (value == null) delete node.dataset[key]\n else node.dataset[key] = String(value)\n }\n}\n\nfunction patchStyle(node: HTMLElement, previous: unknown, next: unknown): void {\n if (typeof next === 'string') {\n node.style.cssText = next\n return\n }\n const oldValues = typeof previous === 'string'\n ? {}\n : toPropertyRecord(previous, 'style')\n const newValues = toPropertyRecord(next, 'style')\n if (typeof previous === 'string') node.style.cssText = ''\n for (const key of new Set([...Object.keys(oldValues), ...Object.keys(newValues)])) {\n const value = newValues[key]\n if (key.startsWith('--')) {\n if (value == null) node.style.removeProperty(key)\n else node.style.setProperty(key, String(value))\n } else {\n Reflect.set(node.style, key, value == null ? '' : String(value))\n }\n }\n}\n\nfunction toPropertyRecord(value: unknown, label: string): Record<string, unknown> {\n if (value == null) return {}\n if (typeof value !== 'object' || Array.isArray(value)) {\n throw new TypeError(`${label} must be an object or null`)\n }\n return value as Record<string, unknown>\n}\n\nfunction setAttribute(node: HTMLElement, name: string, value: unknown): void {\n if (value == null || value === false) node.removeAttribute(name)\n else if (value === true) node.setAttribute(name, '')\n else node.setAttribute(name, String(value))\n}\n\nfunction normalizePropertyName(key: string): string {\n if (key === 'readonly') return 'readOnly'\n if (key === 'autofocus') return 'autoFocus'\n return key\n}\n\nfunction normalizeAttributeName(key: string): string {\n if (key === 'className') return 'class'\n if (key === 'htmlFor') return 'for'\n if (/^aria[A-Z]/.test(key)) return camelToKebab(key)\n if (/^data[A-Z]/.test(key)) return camelToKebab(key)\n return key.replace(/[A-Z]/g, (letter) => `-${letter.toLowerCase()}`)\n}\n\nfunction camelToKebab(value: string): string {\n return value.replace(/[A-Z]/g, (letter) => `-${letter.toLowerCase()}`)\n}\n\nfunction applyRef<TNode extends Node>(ref: Ref<TNode> | null, value: TNode | null): void {\n if (ref == null) return\n if (typeof ref === 'function') ref(value)\n else ref.current = value\n}\n\nfunction disposeRecord(record: RenderRecord, removeNodes: boolean): void {\n if (record.kind === 'emitter') {\n record.unsubscribe()\n disposeRecord(record.child, false)\n if (removeNodes) {\n for (const node of recordNodes(record)) node.remove()\n }\n return\n }\n if (record.kind === 'component') {\n for (const binding of record.liveProps.values()) binding.unsubscribe()\n record.liveProps.clear()\n record.owner._childComponents.delete(record.instance)\n record.instance.destroy()\n return\n }\n if (record.kind === 'function') {\n for (const binding of record.liveProps.values()) binding.unsubscribe()\n record.liveProps.clear()\n disposeRecord(record.child, removeNodes)\n return\n }\n if (record.kind === 'element') {\n applyRef(record.ref, null)\n for (const [key, listener] of record.listeners) {\n record.node.removeEventListener(key.slice(2).toLowerCase(), listener)\n }\n record.listeners.clear()\n for (const binding of record.liveProps.values()) binding.unsubscribe()\n record.liveProps.clear()\n for (const binding of record.nativeBindings.values()) {\n binding.unsubscribe()\n record.node.removeEventListener(binding.eventName, binding.listener)\n }\n record.nativeBindings.clear()\n for (const child of record.children) disposeRecord(child, false)\n if (removeNodes) record.node.remove()\n return\n }\n if (record.kind === 'fragment') {\n for (const child of record.children) disposeRecord(child, false)\n if (removeNodes) {\n for (const node of recordNodes(record)) node.remove()\n }\n return\n }\n if (removeNodes) record.node.remove()\n}\n\nfunction insertRecord(parent: ParentNode, record: RenderRecord | null, before: Node | null = null): void {\n if (record == null) return\n for (const node of recordNodes(record)) parent.insertBefore(node, before)\n}\n\nfunction recordNodes(record: RenderRecord | null): ChildNode[] {\n if (record == null) return []\n if (record.kind === 'text' || record.kind === 'element') return [record.node]\n if (record.kind === 'component') return recordNodes(record.instance._rendered)\n if (record.kind === 'function') return recordNodes(record.child)\n\n const nodes: ChildNode[] = []\n let node: ChildNode | null = record.start\n while (node) {\n nodes.push(node)\n if (node === record.end) break\n node = node.nextSibling\n }\n return nodes\n}\n\nfunction firstNode(record: RenderRecord | null): ChildNode | null {\n return recordNodes(record)[0] ?? null\n}\n\nfunction valueKey(value: NormalizedChild): Key | null {\n if (value instanceof Component) return readKey(value.props)\n return isVNode(value) ? value.key : null\n}\n\nfunction readKey(props: ComponentProps): Key | null {\n const key = props.key\n return typeof key === 'string' || typeof key === 'number' ? key : null\n}\n\nfunction isCompatible(record: RenderRecord, value: NormalizedChild): boolean {\n if (record.kind === 'text') {\n return typeof value === 'string' || typeof value === 'number'\n }\n if (record.kind === 'emitter') {\n return isReadableEmitter(value) && record.source === value\n }\n if (record.kind === 'component') {\n if (value instanceof Component) return record.instance === value\n return isVNode(value)\n && isComponentClass(value.type)\n && record.type === value.type\n && record.key === valueKey(value)\n }\n if (record.kind === 'function') {\n return isVNode(value)\n && record.type === value.type\n && record.key === valueKey(value)\n }\n if (record.kind === 'fragment') {\n return isVNode(value)\n && value.type === Fragment\n && record.key === valueKey(value)\n }\n return isVNode(value)\n && typeof value.type === 'string'\n && record.type === value.type\n && record.key === valueKey(value)\n}\n\nexport function isVNode(value: unknown): value is VNode {\n return value != null\n && typeof value === 'object'\n && Object.hasOwn(value, 'type')\n}\n\nfunction isComponentClass(value: unknown): value is AnyComponentConstructor {\n return typeof value === 'function'\n && (value === Component || value.prototype instanceof Component)\n}\n\nfunction isEventProp(key: string): boolean {\n return /^on[A-Z]/.test(key)\n}\n\nfunction isNativeBindingProp(key: string): key is 'bind:value' | 'bind:checked' {\n return key === 'bind:value' || key === 'bind:checked'\n}\n\nfunction isLiveBinding(value: unknown): value is LiveBinding<unknown> {\n return value != null\n && typeof value === 'object'\n && liveBindingValues.has(value)\n}\n\nfunction isReadableEmitter(value: unknown): value is ReadableEmitter<FrayChild, unknown> {\n if ((typeof value !== 'object' || value == null) && typeof value !== 'function') return false\n return typeof Reflect.get(value, 'get') === 'function'\n && typeof Reflect.get(value, 'getFetchState') === 'function'\n && typeof Reflect.get(value, 'getError') === 'function'\n && typeof Reflect.get(value, 'subscribe') === 'function'\n}\n\nfunction assertReadableEmitter(\n value: unknown,\n label: string,\n): asserts value is ReadableEmitter<unknown, unknown> {\n if (!isReadableEmitter(value)) throw new TypeError(`${label} requires a readable emitter`)\n}\n\nfunction assertWritableEmitter(\n value: unknown,\n label: string,\n): asserts value is WritableEmitter<unknown, unknown> {\n assertReadableEmitter(value, label)\n if (typeof Reflect.get(value, 'set') !== 'function') {\n throw new TypeError(`${label} requires a writable emitter`)\n }\n}\n\nfunction assertNativeBindingTarget(\n node: HTMLElement,\n property: 'value' | 'checked',\n): void {\n const tagName = node.localName\n const valid = property === 'checked'\n ? tagName === 'input'\n : tagName === 'input' || tagName === 'textarea' || tagName === 'select'\n if (!valid) throw new TypeError(`bind:${property} is not supported on ${tagName}`)\n}\n\nfunction nativeBindingEvent(\n node: HTMLElement,\n property: 'value' | 'checked',\n): 'input' | 'change' {\n return property === 'value' && node.localName !== 'select' ? 'input' : 'change'\n}\n\nfunction assertParentNode(value: unknown): asserts value is ParentNode {\n if (value == null\n || (typeof value !== 'object' && typeof value !== 'function')\n || typeof Reflect.get(value, 'insertBefore') !== 'function') {\n throw new TypeError('Component parent must be a DOM ParentNode')\n }\n}\n\nfunction describeValue(value: unknown): string {\n try {\n return String(value)\n } catch {\n return Object.prototype.toString.call(value)\n }\n}\n\nfunction normalizeBaseStyles(value: unknown): Array<[string, BaseStyleNames]> {\n if (value == null) return []\n if (Array.isArray(value)) {\n return value.map((entry) => {\n if (!Array.isArray(entry) || entry.length < 2 || typeof entry[0] !== 'string') {\n throw new TypeError('Component baseStyles entries must be selector/style tuples')\n }\n const names = entry[1]\n if (typeof names !== 'string'\n && (!Array.isArray(names) || names.some((name) => typeof name !== 'string'))) {\n throw new TypeError('Component base style names must be strings')\n }\n return [entry[0], names as BaseStyleNames]\n })\n }\n if (typeof value !== 'object') {\n throw new TypeError('Component baseStyles must be an object or tuple array')\n }\n return Object.entries(value).map(([selector, names]) => [\n selector,\n names as BaseStyleNames,\n ])\n}\n","import {\n Component,\n Fragment,\n h,\n} from './Components/component.js'\nimport type {\n ComponentProps,\n FrayIntrinsicElements,\n FrayChild,\n Key,\n TemplateProps,\n VNode,\n VNodeType,\n} from './Components/component.js'\n\nexport {Fragment}\n\nexport function jsx<TProps extends ComponentProps>(\n type: VNodeType<TProps>,\n props: TemplateProps<TProps> | null,\n key?: Key,\n): VNode<TProps> {\n const nextProps: TemplateProps<TProps> = props == null\n ? {} as TemplateProps<TProps>\n : {...props}\n if (key !== undefined) nextProps.key = key\n return h(type, nextProps)\n}\n\nexport const jsxs = jsx\nexport const jsxDEV = jsx\n\n/** Preserve an explicitly constructed component instance in a vnode tree. */\nexport function createPrebuiltElement<TComponent extends Component>(\n component: TComponent,\n): TComponent {\n if (!(component instanceof Component)) {\n throw new TypeError('createPrebuiltElement requires a Component instance')\n }\n return component\n}\n\nexport namespace JSX {\n export type Element = VNode | Component\n export interface ElementClass extends Component {}\n export interface ElementAttributesProperty {\n props: {}\n }\n export interface ElementChildrenAttribute {\n children: {}\n }\n export interface IntrinsicAttributes {\n key?: Key\n }\n export type LibraryManagedAttributes<_TComponent, TProps extends ComponentProps> =\n TemplateProps<TProps>\n export type IntrinsicElements = FrayIntrinsicElements\n}\n\n// Used by declaration consumers that construct children without JSX.\nexport type JSXChild = FrayChild\n"],"names":["baseStyleDefinitions","STYLE_ATTRIBUTE","nextRegistryId","StyleRegistry","id","__publicField","css","selector","styleNames","names","name","styleName","selectors","generated","properties","variants","splitDefinition","selectorList","renderRule","variant","variantProperties","appendVariant","targetDocument","escapeAttributeValue","style","createStyleRegistry","styleRegistry","definition","property","value","label","declarations","pseudoElement","RESERVED_CUSTOM_ELEMENT_NAMES","FrayRuntime","options","registry","elementNames","prefix","assertNamePart","overrides","componentName","tagName","assertCustomElementName","hostName","standaloneHostName","resolved","cssText","componentType","args","component","parent","before","dependency","createFrayRuntime","defaultFrayRuntime","Fragment","liveBindingValues","BOOLEAN_ATTRIBUTES","PROPERTY_PROPS","live","emitter","assertReadableEmitter","binding","h","type","props","children","suppliedProps","propChildren","key","restProps","normalizeChildren","strings","values","result","string","index","_Component","instance","runtime","seen","baseStyles","normalizeBaseStyles","mountedNow","assertParentNode","insertRecord","_event","nextReads","nextVNode","normalizeRoot","patchRoot","firstNode","nextProps","_dom","observables","observable","unsubscribe","event","cleanup","active","target","listener","eventListener","disposeRecord","Component","normalized","visit","child","createRecord","owner","isReadableEmitter","start","end","current","fragment","record","nextValue","readKey","isVNode","describeValue","patchChildren","node","patchElementProps","isComponentClass","sourceProps","resolvedProps","resolveLivePropValues","subscribeComponentLiveProps","functionType","functionProps","rendered","subscribeFunctionLiveProps","previous","isCompatible","patchCompatible","next","anchor","patchComponentLiveProps","patchFunctionLiveProps","isLiveBinding","reconcileLiveProps","resolvedLiveProps","rerenderFunctionRecord","subscriptions","onValue","existing","liveProp","_a","nextValues","keyed","unkeyed","seenKeys","retained","nextRecords","unkeyedIndex","valueKey","candidate","cursor","recordNodes","_nextChildren","keys","previousValue","isNativeBindingProp","patchNativeBinding","patchRef","isEventProp","patchEvent","patchLiveElementProp","previousLive","previousResolved","patchDOMProp","assertWritableEmitter","assertNativeBindingTarget","eventName","nativeBindingEvent","registered","applyRef","setAttribute","patchDataset","patchStyle","normalizePropertyName","enabled","normalizeAttributeName","oldValues","toPropertyRecord","newValues","camelToKebab","letter","ref","removeNodes","nodes","entry","jsx","jsxs","jsxDEV","createPrebuiltElement"],"mappings":";;;AAIO,MAAMA,IAAuB;AAA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AC,GAAGA,EAAA;AACV,SAAII,MAAQ,WAAWuB,EAAU,MAAMvB,IAChCN,EAAEC,GAAM4B,CAAS;AAC5B;AAEO,MAAMqG,KAAOD,IACPE,KAASF;AAGf,SAASG,GACZlJ,GACU;AACV,MAAI,EAAEA,aAAqBuD;AACvB,UAAM,IAAI,UAAU,qDAAqD;AAE7E,SAAOvD;AACX;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-dev-runtime.d.ts","sourceRoot":"","sources":["../src/jsx-dev-runtime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,QAAQ,EAAE,MAAM,EAAC,MAAM,kBAAkB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-dev-runtime.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Component, Fragment } from './Components/component.js';
|
|
2
|
+
import type { ComponentProps, FrayIntrinsicElements, FrayChild, Key, TemplateProps, VNode, VNodeType } from './Components/component.js';
|
|
3
|
+
export { Fragment };
|
|
4
|
+
export declare function jsx<TProps extends ComponentProps>(type: VNodeType<TProps>, props: TemplateProps<TProps> | null, key?: Key): VNode<TProps>;
|
|
5
|
+
export declare const jsxs: typeof jsx;
|
|
6
|
+
export declare const jsxDEV: typeof jsx;
|
|
7
|
+
/** Preserve an explicitly constructed component instance in a vnode tree. */
|
|
8
|
+
export declare function createPrebuiltElement<TComponent extends Component>(component: TComponent): TComponent;
|
|
9
|
+
export declare namespace JSX {
|
|
10
|
+
type Element = VNode | Component;
|
|
11
|
+
interface ElementClass extends Component {
|
|
12
|
+
}
|
|
13
|
+
interface ElementAttributesProperty {
|
|
14
|
+
props: {};
|
|
15
|
+
}
|
|
16
|
+
interface ElementChildrenAttribute {
|
|
17
|
+
children: {};
|
|
18
|
+
}
|
|
19
|
+
interface IntrinsicAttributes {
|
|
20
|
+
key?: Key;
|
|
21
|
+
}
|
|
22
|
+
type LibraryManagedAttributes<_TComponent, TProps extends ComponentProps> = TemplateProps<TProps>;
|
|
23
|
+
type IntrinsicElements = FrayIntrinsicElements;
|
|
24
|
+
}
|
|
25
|
+
export type JSXChild = FrayChild;
|
|
26
|
+
//# sourceMappingURL=jsx-runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-runtime.d.ts","sourceRoot":"","sources":["../src/jsx-runtime.ts"],"names":[],"mappings":"AAAA,OAAO,EACH,SAAS,EACT,QAAQ,EAEX,MAAM,2BAA2B,CAAA;AAClC,OAAO,KAAK,EACR,cAAc,EACd,qBAAqB,EACrB,SAAS,EACT,GAAG,EACH,aAAa,EACb,KAAK,EACL,SAAS,EACZ,MAAM,2BAA2B,CAAA;AAElC,OAAO,EAAC,QAAQ,EAAC,CAAA;AAEjB,wBAAgB,GAAG,CAAC,MAAM,SAAS,cAAc,EAC7C,IAAI,EAAE,SAAS,CAAC,MAAM,CAAC,EACvB,KAAK,EAAE,aAAa,CAAC,MAAM,CAAC,GAAG,IAAI,EACnC,GAAG,CAAC,EAAE,GAAG,GACV,KAAK,CAAC,MAAM,CAAC,CAMf;AAED,eAAO,MAAM,IAAI,YAAM,CAAA;AACvB,eAAO,MAAM,MAAM,YAAM,CAAA;AAEzB,6EAA6E;AAC7E,wBAAgB,qBAAqB,CAAC,UAAU,SAAS,SAAS,EAC9D,SAAS,EAAE,UAAU,GACtB,UAAU,CAKZ;AAED,yBAAiB,GAAG,CAAC;IACjB,KAAY,OAAO,GAAG,KAAK,GAAG,SAAS,CAAA;IACvC,UAAiB,YAAa,SAAQ,SAAS;KAAG;IAClD,UAAiB,yBAAyB;QACtC,KAAK,EAAE,EAAE,CAAA;KACZ;IACD,UAAiB,wBAAwB;QACrC,QAAQ,EAAE,EAAE,CAAA;KACf;IACD,UAAiB,mBAAmB;QAChC,GAAG,CAAC,EAAE,GAAG,CAAA;KACZ;IACD,KAAY,wBAAwB,CAAC,WAAW,EAAE,MAAM,SAAS,cAAc,IAC3E,aAAa,CAAC,MAAM,CAAC,CAAA;IACzB,KAAY,iBAAiB,GAAG,qBAAqB,CAAA;CACxD;AAGD,MAAM,MAAM,QAAQ,GAAG,SAAS,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-runtime.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { Component, ComponentDependency } from './Components/component.js';
|
|
2
|
+
import type { StyleRegistry } from './styling/styleRegistry.js';
|
|
3
|
+
export interface FrayElementNameOptions {
|
|
4
|
+
/** Namespace prepended to component host names. Defaults to `fray`. */
|
|
5
|
+
prefix?: string | null;
|
|
6
|
+
/** Complete standards-valid tag names keyed by stable component host name. */
|
|
7
|
+
overrides?: Readonly<Record<string, string>>;
|
|
8
|
+
}
|
|
9
|
+
export interface FrayRuntimeOptions {
|
|
10
|
+
elementNames?: FrayElementNameOptions;
|
|
11
|
+
}
|
|
12
|
+
/** Immutable application scope for element naming and structural styles. */
|
|
13
|
+
export declare class FrayRuntime {
|
|
14
|
+
readonly elementPrefix: string | null;
|
|
15
|
+
readonly elementNameOverrides: Readonly<Record<string, string>>;
|
|
16
|
+
readonly styleRegistry: StyleRegistry;
|
|
17
|
+
constructor(options?: FrayRuntimeOptions, registry?: StyleRegistry);
|
|
18
|
+
resolveElementName(hostName: string, standaloneHostName?: string | null): string;
|
|
19
|
+
resolveHostSelector(selector: string, hostName: string, standaloneHostName?: string | null): string;
|
|
20
|
+
resolveHostCSS(cssText: string, hostName: string, standaloneHostName?: string | null): string;
|
|
21
|
+
create<TArgs extends unknown[], TComponent extends Component>(componentType: new (...args: TArgs) => TComponent, ...args: TArgs): TComponent;
|
|
22
|
+
mount<TComponent extends Component>(component: TComponent, parent: ParentNode, before?: Node | null): TComponent;
|
|
23
|
+
registerStyles(dependency: ComponentDependency): this;
|
|
24
|
+
injectStyles(targetDocument?: Document): HTMLStyleElement;
|
|
25
|
+
}
|
|
26
|
+
export declare function createFrayRuntime(options?: FrayRuntimeOptions): FrayRuntime;
|
|
27
|
+
/** Runtime used by Component.new(), direct mount(), and the legacy styleRegistry export. */
|
|
28
|
+
export declare const defaultFrayRuntime: FrayRuntime;
|
|
29
|
+
//# sourceMappingURL=runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../src/runtime.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACR,SAAS,EACT,mBAAmB,EACtB,MAAM,2BAA2B,CAAA;AAKlC,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,4BAA4B,CAAA;AAa7D,MAAM,WAAW,sBAAsB;IACnC,uEAAuE;IACvE,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;IACtB,8EAA8E;IAC9E,SAAS,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAA;CAC/C;AAED,MAAM,WAAW,kBAAkB;IAC/B,YAAY,CAAC,EAAE,sBAAsB,CAAA;CACxC;AAED,4EAA4E;AAC5E,qBAAa,WAAW;IACpB,QAAQ,CAAC,aAAa,EAAE,MAAM,GAAG,IAAI,CAAA;IACrC,QAAQ,CAAC,oBAAoB,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAA;IAC/D,QAAQ,CAAC,aAAa,EAAE,aAAa,CAAA;gBAGjC,OAAO,GAAE,kBAAuB,EAChC,QAAQ,GAAE,aAAqC;IA4BnD,kBAAkB,CAAC,QAAQ,EAAE,MAAM,EAAE,kBAAkB,GAAE,MAAM,GAAG,IAAW,GAAG,MAAM;IAWtF,mBAAmB,CACf,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,MAAM,EAChB,kBAAkB,GAAE,MAAM,GAAG,IAAW,GACzC,MAAM;IAKT,cAAc,CACV,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,kBAAkB,GAAE,MAAM,GAAG,IAAW,GACzC,MAAM;IAKT,MAAM,CAAC,KAAK,SAAS,OAAO,EAAE,EAAE,UAAU,SAAS,SAAS,EACxD,aAAa,EAAE,KAAI,GAAG,IAAI,EAAE,KAAK,KAAK,UAAU,EAChD,GAAG,IAAI,EAAE,KAAK,GACf,UAAU;IAMb,KAAK,CAAC,UAAU,SAAS,SAAS,EAC9B,SAAS,EAAE,UAAU,EACrB,MAAM,EAAE,UAAU,EAClB,MAAM,GAAE,IAAI,GAAG,IAAW,GAC3B,UAAU;IAMb,cAAc,CAAC,UAAU,EAAE,mBAAmB,GAAG,IAAI;IAQrD,YAAY,CAAC,cAAc,GAAE,QAA8B,GAAG,gBAAgB;CAGjF;AAED,wBAAgB,iBAAiB,CAAC,OAAO,GAAE,kBAAuB,GAAG,WAAW,CAE/E;AAED,4FAA4F;AAC5F,eAAO,MAAM,kBAAkB,aAAqC,CAAA"}
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
export type CSSDeclarations = Record<string, string>;
|
|
2
|
+
export type CSSVariantMap = Record<string, CSSDeclarations>;
|
|
3
|
+
export type BaseStyleDefinition = Record<string, string | CSSVariantMap>;
|
|
4
|
+
export declare const baseStyleDefinitions: {
|
|
5
|
+
after: {
|
|
6
|
+
content: string;
|
|
7
|
+
display: string;
|
|
8
|
+
position: string;
|
|
9
|
+
top: string;
|
|
10
|
+
left: string;
|
|
11
|
+
width: string;
|
|
12
|
+
height: string;
|
|
13
|
+
'pointer-events': string;
|
|
14
|
+
};
|
|
15
|
+
inputline: {
|
|
16
|
+
display: string;
|
|
17
|
+
'flex-flow': string;
|
|
18
|
+
position: string;
|
|
19
|
+
'line-height': string;
|
|
20
|
+
'font-size': string;
|
|
21
|
+
'min-height': string;
|
|
22
|
+
color: string;
|
|
23
|
+
'border-radius': string;
|
|
24
|
+
'box-sizing': string;
|
|
25
|
+
};
|
|
26
|
+
input: {
|
|
27
|
+
background: string;
|
|
28
|
+
padding: string;
|
|
29
|
+
'pointer-events': string;
|
|
30
|
+
border: string;
|
|
31
|
+
width: string;
|
|
32
|
+
'box-shadow': string;
|
|
33
|
+
'box-sizing': string;
|
|
34
|
+
'white-space': string;
|
|
35
|
+
variants: {
|
|
36
|
+
':focus-visible': {
|
|
37
|
+
outline: string;
|
|
38
|
+
'outline-offset': string;
|
|
39
|
+
'border-color': string;
|
|
40
|
+
'box-shadow': string;
|
|
41
|
+
};
|
|
42
|
+
':disabled': {
|
|
43
|
+
background: string;
|
|
44
|
+
'border-color': string;
|
|
45
|
+
color: string;
|
|
46
|
+
cursor: string;
|
|
47
|
+
};
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
inputlike: {
|
|
51
|
+
background: string;
|
|
52
|
+
padding: string;
|
|
53
|
+
'pointer-events': string;
|
|
54
|
+
border: string;
|
|
55
|
+
'box-shadow': string;
|
|
56
|
+
'box-sizing': string;
|
|
57
|
+
'white-space': string;
|
|
58
|
+
'border-radius': string;
|
|
59
|
+
};
|
|
60
|
+
labeledinput: {
|
|
61
|
+
display: string;
|
|
62
|
+
'flex-flow': string;
|
|
63
|
+
'align-items': string;
|
|
64
|
+
gap: string;
|
|
65
|
+
};
|
|
66
|
+
label: {
|
|
67
|
+
color: string;
|
|
68
|
+
'font-size': string;
|
|
69
|
+
};
|
|
70
|
+
disabled: {
|
|
71
|
+
'border-color': string;
|
|
72
|
+
color: string;
|
|
73
|
+
};
|
|
74
|
+
error: {
|
|
75
|
+
color: string;
|
|
76
|
+
};
|
|
77
|
+
working: {
|
|
78
|
+
display: string;
|
|
79
|
+
position: string;
|
|
80
|
+
'z-index': string;
|
|
81
|
+
margin: string;
|
|
82
|
+
animation: string;
|
|
83
|
+
'background-repeat': string;
|
|
84
|
+
'background-size': string;
|
|
85
|
+
'background-image': string;
|
|
86
|
+
border: string;
|
|
87
|
+
'border-radius': string;
|
|
88
|
+
'box-sizing': string;
|
|
89
|
+
};
|
|
90
|
+
panel: {
|
|
91
|
+
background: string;
|
|
92
|
+
border: string;
|
|
93
|
+
'border-radius': string;
|
|
94
|
+
'box-shadow': string;
|
|
95
|
+
color: string;
|
|
96
|
+
};
|
|
97
|
+
sectionheader: {
|
|
98
|
+
'box-shadow': string;
|
|
99
|
+
background: string;
|
|
100
|
+
color: string;
|
|
101
|
+
};
|
|
102
|
+
uiline: {
|
|
103
|
+
'box-sizing': string;
|
|
104
|
+
'line-height': string;
|
|
105
|
+
'font-size': string;
|
|
106
|
+
'min-height': string;
|
|
107
|
+
color: string;
|
|
108
|
+
padding: string;
|
|
109
|
+
'border-radius': string;
|
|
110
|
+
cursor: string;
|
|
111
|
+
'user-select': string;
|
|
112
|
+
};
|
|
113
|
+
noselect: {
|
|
114
|
+
'user-select': string;
|
|
115
|
+
cursor: string;
|
|
116
|
+
};
|
|
117
|
+
button: {
|
|
118
|
+
'box-sizing': string;
|
|
119
|
+
background: string;
|
|
120
|
+
border: string;
|
|
121
|
+
'box-shadow': string;
|
|
122
|
+
color: string;
|
|
123
|
+
cursor: string;
|
|
124
|
+
'user-select': string;
|
|
125
|
+
variants: {
|
|
126
|
+
':hover': {
|
|
127
|
+
background: string;
|
|
128
|
+
'box-shadow': string;
|
|
129
|
+
};
|
|
130
|
+
':focus-visible': {
|
|
131
|
+
outline: string;
|
|
132
|
+
'outline-offset': string;
|
|
133
|
+
border: string;
|
|
134
|
+
'box-shadow': string;
|
|
135
|
+
};
|
|
136
|
+
':disabled': {
|
|
137
|
+
background: string;
|
|
138
|
+
border: string;
|
|
139
|
+
color: string;
|
|
140
|
+
cursor: string;
|
|
141
|
+
'pointer-events': string;
|
|
142
|
+
};
|
|
143
|
+
};
|
|
144
|
+
};
|
|
145
|
+
toolbar: {
|
|
146
|
+
background: string;
|
|
147
|
+
border: string;
|
|
148
|
+
'border-radius': string;
|
|
149
|
+
'box-shadow': string;
|
|
150
|
+
color: string;
|
|
151
|
+
};
|
|
152
|
+
};
|
|
153
|
+
export type BaseStyleName = keyof typeof baseStyleDefinitions;
|
|
154
|
+
//# sourceMappingURL=baseStyleDefinitions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"baseStyleDefinitions.d.ts","sourceRoot":"","sources":["../../src/styling/baseStyleDefinitions.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;AACpD,MAAM,MAAM,aAAa,GAAG,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,CAAA;AAC3D,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,aAAa,CAAC,CAAA;AAExE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmKc,CAAA;AAE/C,MAAM,MAAM,aAAa,GAAG,MAAM,OAAO,oBAAoB,CAAA"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/** Application-scoped structural-style collection and injection. */
|
|
2
|
+
export declare class StyleRegistry {
|
|
3
|
+
readonly id: string;
|
|
4
|
+
private readonly cssFragments;
|
|
5
|
+
private readonly baseStyleMap;
|
|
6
|
+
constructor(id?: string);
|
|
7
|
+
registerCSS(css: string): this;
|
|
8
|
+
registerBaseStyle(selector: string, styleNames: string | readonly string[]): this;
|
|
9
|
+
generateRootCSS(): string;
|
|
10
|
+
generateBaseStyleCSS(): string;
|
|
11
|
+
generateCSS(): string;
|
|
12
|
+
injectAll(targetDocument?: Document): HTMLStyleElement;
|
|
13
|
+
reset(): void;
|
|
14
|
+
}
|
|
15
|
+
/** Create an isolated registry for a configured Fray application runtime. */
|
|
16
|
+
export declare function createStyleRegistry(): StyleRegistry;
|
|
17
|
+
/** Backward-compatible structural styles for the default Fray runtime. */
|
|
18
|
+
export declare const styleRegistry: StyleRegistry;
|
|
19
|
+
//# sourceMappingURL=styleRegistry.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"styleRegistry.d.ts","sourceRoot":"","sources":["../../src/styling/styleRegistry.ts"],"names":[],"mappings":"AAaA,oEAAoE;AACpE,qBAAa,aAAa;IACtB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAA;IACnB,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAoB;IACjD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAwC;gBAEzD,EAAE,GAAE,MAAsC;IAKtD,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAM9B,iBAAiB,CAAC,QAAQ,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,SAAS,MAAM,EAAE,GAAG,IAAI;IAqBjF,eAAe,IAAI,MAAM;IAqCzB,oBAAoB,IAAI,MAAM;IAiB9B,WAAW,IAAI,MAAM;IAQrB,SAAS,CAAC,cAAc,GAAE,QAA8B,GAAG,gBAAgB;IAgB3E,KAAK,IAAI,IAAI;CAIhB;AAED,6EAA6E;AAC7E,wBAAgB,mBAAmB,IAAI,aAAa,CAEnD;AAED,0EAA0E;AAC1E,eAAO,MAAM,aAAa,eAAwB,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** Represents the filter mode for a query. */
|
|
2
|
+
export declare const FilterMode: {
|
|
3
|
+
/** Deny mode: Excludes items that match the filter. */
|
|
4
|
+
readonly Deny: "!";
|
|
5
|
+
/** Require mode: Includes only items that match the filter. */
|
|
6
|
+
readonly Require: "_";
|
|
7
|
+
/** Prefer mode: If there are any filter options that are set to Prefer, at least one of the preferred filter options must match. Otherwise, it is treated as Neutral. */
|
|
8
|
+
readonly Prefer: "";
|
|
9
|
+
/** Neutral mode: Does not affect the inclusion or exclusion of items. */
|
|
10
|
+
readonly Neutral: "☐";
|
|
11
|
+
};
|
|
12
|
+
export type FilterModeValue = typeof FilterMode[keyof typeof FilterMode];
|
|
13
|
+
//# sourceMappingURL=filterMode.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filterMode.d.ts","sourceRoot":"","sources":["../../src/util/filterMode.ts"],"names":[],"mappings":"AAAA,8CAA8C;AAC9C,eAAO,MAAM,UAAU;IACnB,uDAAuD;;IAEvD,+DAA+D;;IAE/D,yKAAyK;;IAEzK,yEAAyE;;CAEnE,CAAA;AAEV,MAAM,MAAM,eAAe,GAAG,OAAO,UAAU,CAAC,MAAM,OAAO,UAAU,CAAC,CAAA"}
|