@proyecto-viviana/solidaria-components 0.7.0-rc.3 → 0.7.0-rc.5

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.
@@ -1 +1 @@
1
- {"version":3,"file":"Collection.d.ts","sourceRoot":"","sources":["../src/Collection.tsx"],"names":[],"mappings":"AAgBA;;;;;;;;GAQG;AAEH,OAAO,EAQL,KAAK,QAAQ,EACd,MAAM,UAAU,CAAC;AAClB,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,iCAAiC,CAAC;AAC3D,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC5F,OAAO,EAGL,mBAAmB,EACnB,qBAAqB,EACrB,KAAK,eAAe,IAAI,mBAAmB,EAC3C,KAAK,sBAAsB,IAAI,0BAA0B,EAC1D,MAAM,6BAA6B,CAAC;AAErC,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,YAAY,EACjB,KAAK,eAAe,EACpB,KAAK,SAAS,EAIf,MAAM,SAAS,CAAC;AAEjB,MAAM,WAAW,8BAA8B;IAC7C,0DAA0D;IAC1D,WAAW,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,eAAe;IAC9B,0DAA0D;IAC1D,SAAS,EAAE,OAAO,CAAC;IACnB,wDAAwD;IACxD,SAAS,EAAE,OAAO,CAAC;IACnB,8CAA8C;IAC9C,UAAU,EAAE,OAAO,CAAC;IACpB,6CAA6C;IAC7C,SAAS,EAAE,OAAO,CAAC;IACnB,sDAAsD;IACtD,cAAc,EAAE,OAAO,CAAC;IACxB,2CAA2C;IAC3C,UAAU,EAAE,OAAO,CAAC;IACpB,+DAA+D;IAC/D,aAAa,EAAE,MAAM,GAAG,QAAQ,GAAG,UAAU,CAAC;IAC9C,iDAAiD;IACjD,iBAAiB,EAAE,QAAQ,GAAG,SA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,EAAE,CAAC,KAAK,GAAG,CAAC,OAAO,CAAC;CACpE;AAED,wBAAgB,iBAAiB,CAAC,CAAC,EACjC,KAAK,EAAE,0BAA0B,CAAC,CAAC,CAAC,GAAG,4BAA4B,GAClE,OAAO,CAWT;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,mBAAmB,CAAC,CAAC,CAAC,GAAG,OAAO,CAEpE;AAED,OAAO,EAAE,mBAAmB,EAAE,qBAAqB,EAAE,CAAC;AAEtD;;;;;GAKG;AACH,wBAAgB,yBAAyB,CAAC,OAAO,EAAE;IACjD,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;IAClB,mBAAmB,CAAC,EAAE,CACpB,KAAK,EAAE,MAAM,EACb,QAAQ,EAAE,QAAQ,GAAG,OAAO,GAAG,IAAI,KAChC,GAAG,CAAC,OAAO,GAAG,SAAS,CAAC;IAC7B,QAAQ,EAAE,GAAG,CAAC,OAAO,CAAC;CACvB,GAAG,GAAG,CAAC,OAAO,CAUd;AAED;;GAEG;AACH,wBAAgB,OAAO,CAAC,KAAK,EAAE,YAAY,GAAG,GAAG,CAAC,OAAO,CA6CxD;AAED;;GAEG;AACH,wBAAgB,MAAM,CAAC,KAAK,EAAE,WAAW,GAAG,GAAG,CAAC,OAAO,CAkDtD;AAED;;GAEG;AACH,wBAAgB,KAAK,CAAC,KAAK,EAAE,UAAU,GAAG,GAAG,CAAC,OAAO,CAqCpD"}
@@ -14,7 +14,7 @@
14
14
  // Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Header.tsx
15
15
  import { filterDOMProps, useContextProps, useRenderProps } from "./utils.js";
16
16
  import { createComponent, getNextElement, insert, memo, ref, runHydrationEvents, scope, spread, template } from "@solidjs/web";
17
- import { For, createContext, createEffect, createMemo, createSignal, onCleanup, useContext } from "solid-js";
17
+ import { For, createContext, createEffect, createMemo, createSignal, onCleanup, runWithOwner, useContext } from "solid-js";
18
18
  import { Collection as Collection$1, CollectionBuilder as CollectionBuilder$1, createBranchComponent, createLeafComponent } from "@proyecto-viviana/solidaria";
19
19
  import { isDevEnv, splitProps } from "@proyecto-viviana/solidaria/utils";
20
20
  //#region src/Collection.tsx
@@ -138,7 +138,7 @@ function createStaticCollectionState() {
138
138
  const [items, setItems] = createSignal([]);
139
139
  const itemMap = /* @__PURE__ */ new Map();
140
140
  const syncItems = () => {
141
- setItems(Array.from(itemMap.values()));
141
+ runWithOwner(null, () => setItems(Array.from(itemMap.values())));
142
142
  };
143
143
  return {
144
144
  items,
@@ -1 +1 @@
1
- {"version":3,"file":"Collection.js","names":["<For each={items}>\n {(item, index) => {\n const node = item as { type?: unknown; key?: Key };\n if (node.type === \"content\") {\n // Content rows are rendered by their owning item/section branch.\n return <></>;\n }\n const key = node.key ?? index();\n const isLastInLevel = index() === lastRenderableIndex;\n return (\n <>\n {renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}\n {item as unknown as JSX.Element}\n {isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}\n </>\n );\n }}\n </For>","each={items}","{renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}","{isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}","<StaticCollectionContext value={context}>\n <StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>\n {(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)}\n </StaticCollectionContext>","value={context}","<StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>","value={true}","(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)","{options.renderDropIndicator?.(options.index, \"before\")}","{options.children}","{options.index === options.lastIndex\n ? options.renderDropIndicator?.(options.index, \"after\")\n : null}","ref={(el) => assignRef(local.ref, el)}","{renderProps.renderChildren()}","<div\n ref={(el) => assignRef(local.ref, el)}\n {...filteredDomProps()}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-section\n >\n {renderProps.renderChildren()}\n </div>","ref={ref}","<div\n ref={ref}\n {...filteredDomProps()}\n role={local.role ?? \"heading\"}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-header\n >\n {renderProps.renderChildren()}\n </div>","role=\"group\"","<div\n {...filteredDomProps()}\n role=\"group\"\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-group\n >\n {renderProps.renderChildren()}\n </div>","assignRef","_$createComponent","_$memo","AriaCollectionBuilder","AriaCollection","_$getNextElement","_$scope","ref"],"sources":["../src/Collection.tsx"],"sourcesContent":["/*\n * Copyright 2022 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Collection.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Group.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Header.tsx\n\n/**\n * Collection composition primitives for solidaria-components.\n *\n * Foundational parity layer for React Spectrum-style composition:\n * Section / Header / Group. Based on:\n * - packages/react-aria-components/src/Collection.tsx\n * - packages/react-aria-components/src/Group.tsx\n * - packages/react-aria-components/src/Header.tsx\n */\n\nimport {\n createContext,\n createEffect,\n createMemo,\n createSignal,\n onCleanup,\n useContext,\n For,\n type Accessor,\n} from \"solid-js\";\nimport type { JSX } from \"@solidjs/web\";\nimport type { Key } from \"@proyecto-viviana/solid-stately\";\nimport type { DragTypes, DropOperation, DropTarget } from \"@proyecto-viviana/solid-stately\";\nimport {\n Collection as AriaCollection,\n CollectionBuilder as AriaCollectionBuilder,\n createLeafComponent,\n createBranchComponent,\n type CollectionProps as AriaCollectionProps,\n type CollectionBuilderProps as AriaCollectionBuilderProps,\n} from \"@proyecto-viviana/solidaria\";\nimport { splitProps, isDevEnv } from \"@proyecto-viviana/solidaria/utils\";\nimport {\n type ClassNameOrFunction,\n type ContextValue,\n type StyleOrFunction,\n type SlotProps,\n useContextProps,\n useRenderProps,\n filterDOMProps,\n} from \"./utils\";\n\nexport interface CollectionPrimitiveRenderProps {\n /** Whether the primitive has visible children content. */\n hasChildren: boolean;\n}\n\nexport interface ItemRenderProps {\n /** Whether the item is currently hovered with a mouse. */\n isHovered: boolean;\n /** Whether the item is currently in a pressed state. */\n isPressed: boolean;\n /** Whether the item is currently selected. */\n isSelected: boolean;\n /** Whether the item is currently focused. */\n isFocused: boolean;\n /** Whether the item is currently keyboard focused. */\n isFocusVisible: boolean;\n /** Whether the item is non-interactive. */\n isDisabled: boolean;\n /** The type of selection that is allowed in the collection. */\n selectionMode: \"none\" | \"single\" | \"multiple\";\n /** The selection behavior for the collection. */\n selectionBehavior: \"toggle\" | \"replace\";\n /**\n * Whether the item allows dragging.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-allows-dragging]\n */\n allowsDragging?: boolean;\n /**\n * Whether the item is currently being dragged.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-dragging]\n */\n isDragging?: boolean;\n /**\n * Whether the item is currently an active drop target.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-drop-target]\n */\n isDropTarget?: boolean;\n}\n\ntype RefLike<T> = ((el: T) => void) | { current?: T | null } | undefined;\n\nfunction assignRef<T>(ref: RefLike<T>, el: T): void {\n if (!ref) return;\n if (typeof ref === \"function\") ref(el);\n else ref.current = el;\n}\n\nexport interface CollectionDropTargetDelegate {\n getDropTargetFromPoint(\n x: number,\n y: number,\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getDropOperation(\n target: DropTarget,\n types: DragTypes,\n allowedOperations: DropOperation[],\n ): DropOperation;\n getKeyboardNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getKeyboardPageNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n}\n\nexport interface CollectionRendererContextValue<T> {\n /** Render function used by collection parents to render each item node. */\n renderItem: (item: T) => JSX.Element;\n /** Whether collection rendering is currently virtualized. */\n isVirtualized?: boolean;\n /** Optional layout delegate used by virtualized renderers. */\n layoutDelegate?: unknown;\n /** Optional drop target delegate used by DnD-aware collection paths. */\n dropTargetDelegate?: CollectionDropTargetDelegate;\n /** Optional drop indicator renderer for DnD-aware collection paths. */\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n /**\n * Root renderer for collection items. RAC `CollectionRenderer.CollectionRoot`\n * (`Collection.tsx:196`). Virtualizer replaces this with a scroll-attached\n * content wrapper (`react-aria-components/src/Virtualizer.tsx:99-151`).\n */\n CollectionRoot?: (props: CollectionRootProps<T>) => JSX.Element;\n /** Branch renderer for nested collection items. RAC `CollectionBranch`. */\n CollectionBranch?: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport type CollectionEntry<T> = T | CollectionSection<T>;\n\nexport interface CollectionSection<T> {\n /** Optional unique key for the section wrapper. */\n key?: Key;\n /** Optional section header title. */\n title?: JSX.Element;\n /** Optional aria-label for section grouping. */\n \"aria-label\"?: string;\n /** Items contained in the section. */\n items: T[];\n}\n\nexport interface SectionProps extends SlotProps {\n /** Section contents, usually Header + Group/items. */\n children?: JSX.Element;\n /** Ref for the section element. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id forwarded to the section element. */\n id?: string;\n /** ARIA role forwarded to the section element. */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Accessible name when the section has no naming header. */\n \"aria-label\"?: string;\n /** Id of the element that names the section. */\n \"aria-labelledby\"?: string;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface HeaderProps extends SlotProps {\n /** Header contents, usually section title text. */\n children?: JSX.Element;\n /** Ref for the header element. Context refs merge with this. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id. A menu section assigns this so the group can name itself. */\n id?: string;\n /**\n * ARIA role. Defaults to `heading`. A menu section passes `presentation`\n * so the title names the group instead of exposing a heading.\n */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Optional heading level when rendered as a heading role. */\n \"aria-level\"?: number;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface GroupProps extends SlotProps {\n /** Group contents, usually section items. */\n children?: JSX.Element;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\ninterface SectionContextValue {\n name: string;\n render: (props: SectionProps, className?: string) => JSX.Element;\n}\n\nexport interface CollectionBranchProps<T> {\n collection: Iterable<T>;\n parent?: unknown;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n}\n\nexport interface CollectionRootProps<T> {\n collection: Iterable<T>;\n persistedKeys?: Set<Key> | null;\n /**\n * The collection element that scrolls. RAC `CollectionRootProps.scrollRef`\n * (`Collection.tsx:183`).\n */\n scrollRef?: () => HTMLElement | null | undefined;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n /**\n * Rendered collection items. RAC CollectionRoot renders `node.render()` from\n * the collection; Solid collections pass the already-composed item tree.\n */\n children?: JSX.Element;\n}\n\nexport interface CollectionRenderer<T = unknown> {\n isVirtualized?: boolean;\n layoutDelegate?: unknown;\n dropTargetDelegate?: CollectionDropTargetDelegate;\n CollectionRoot: (props: CollectionRootProps<T>) => JSX.Element;\n CollectionBranch: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport const CollectionRendererContext =\n createContext<CollectionRendererContextValue<unknown> | null>(null);\nexport const SelectableCollectionContext = CollectionRendererContext;\nexport const SectionContext = createContext<SectionContextValue | null>(null);\nexport const GroupContext = createContext<Partial<GroupProps> | null>(null);\nexport const HeaderContext = createContext<ContextValue<HeaderProps, HTMLDivElement>>(null);\nexport const HeadingContext = createContext<Partial<HeaderProps> | null>(null);\n\nexport function useCollectionRenderer<T>(): CollectionRendererContextValue<T> | null {\n return useContext(CollectionRendererContext) as CollectionRendererContextValue<T> | null;\n}\n\n/** RAC collections always render `CollectionRoot` from the renderer context. */\nexport function useCollectionRoot<T>(): (props: CollectionRootProps<T>) => JSX.Element {\n const renderer = useCollectionRenderer<T>();\n return renderer?.CollectionRoot ?? DefaultCollectionRenderer.CollectionRoot;\n}\n\nexport function isCollectionSection<T>(entry: CollectionEntry<T>): entry is CollectionSection<T> {\n return (\n typeof entry === \"object\" &&\n entry !== null &&\n Array.isArray((entry as CollectionSection<T>).items)\n );\n}\n\nexport function flattenCollectionEntries<T>(entries?: CollectionEntry<T>[]): T[] {\n if (!entries || !Array.isArray(entries)) return [];\n const flattened: T[] = [];\n for (const entry of entries) {\n if (isCollectionSection(entry)) flattened.push(...entry.items);\n else flattened.push(entry);\n }\n return flattened;\n}\n\nfunction renderCollectionItems<T>(\n collection: Iterable<T>,\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined,\n): JSX.Element {\n const items = Array.from(collection);\n let lastRenderableIndex = -1;\n for (let i = 0; i < items.length; i++) {\n if ((items[i] as { type?: unknown }).type !== \"content\") {\n lastRenderableIndex = i;\n }\n }\n return (\n <For each={items}>\n {(item, index) => {\n const node = item as { type?: unknown; key?: Key };\n if (node.type === \"content\") {\n // Content rows are rendered by their owning item/section branch.\n return <></>;\n }\n const key = node.key ?? index();\n const isLastInLevel = index() === lastRenderableIndex;\n return (\n <>\n {renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}\n {item as unknown as JSX.Element}\n {isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}\n </>\n );\n }}\n </For>\n );\n}\n\nexport const DefaultCollectionRenderer: CollectionRenderer<unknown> = {\n CollectionRoot(props) {\n if (props.children != null) return props.children;\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n CollectionBranch(props) {\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n};\n\nexport interface StaticCollectionItem {\n id: Key;\n textValue?: string;\n isDisabled?: boolean;\n}\n\nexport interface StaticCollectionContextValue {\n registerItem(item: StaticCollectionItem): void;\n unregisterItem(id: Key): void;\n}\n\nexport const StaticCollectionContext = createContext<StaticCollectionContextValue | null>(null);\n\n/** True only for the registration/probe copy of static collection children. */\nexport const StaticCollectionProbeContext = createContext(false);\n\n/**\n * Set around the displayed copy of static children by a host that filters them\n * (ComboBox): whether the item with this key is in the displayed collection.\n */\nexport const StaticCollectionFilterContext = createContext<((key: Key) => boolean) | null>(null);\n\n/**\n * Display text for a static collection option. An explicit `textValue` wins,\n * including an empty string. Otherwise a string aria-label, then string or number\n * children.\n */\nexport function staticItemText(props: {\n textValue?: string;\n \"aria-label\"?: string;\n children?: unknown;\n}): string | undefined {\n if (props.textValue != null) return props.textValue;\n const label = props[\"aria-label\"];\n if (typeof label === \"string\") return label;\n return textFromNode(props.children);\n}\n\nfunction textFromNode(node: unknown): string | undefined {\n if (typeof node === \"string\" || typeof node === \"number\") return String(node);\n if (typeof node === \"function\" && node.length === 0) {\n return textFromNode((node as () => unknown)());\n }\n if (Array.isArray(node)) {\n let text = \"\";\n let any = false;\n for (const child of node) {\n const part = textFromNode(child);\n if (part != null) {\n text += part;\n any = true;\n }\n }\n return any ? text : undefined;\n }\n return undefined;\n}\n\n/**\n * Manages item descriptor registration for collections with static JSX children (Menu, Select).\n */\nexport function createStaticCollectionState(): {\n items: Accessor<StaticCollectionItem[]>;\n context: StaticCollectionContextValue;\n} {\n const [items, setItems] = createSignal<StaticCollectionItem[]>([]);\n const itemMap = new Map<Key, StaticCollectionItem>();\n\n const syncItems = () => {\n setItems(Array.from(itemMap.values()));\n };\n\n const context: StaticCollectionContextValue = {\n registerItem(item) {\n const previous = itemMap.get(item.id);\n if (\n previous &&\n previous.textValue === item.textValue &&\n previous.isDisabled === item.isDisabled\n ) {\n return;\n }\n\n itemMap.set(item.id, item);\n syncItems();\n },\n unregisterItem(id) {\n if (itemMap.delete(id)) {\n syncItems();\n }\n },\n };\n\n return { items, context };\n}\n\n/**\n * Registers an item with the nearest StaticCollectionContext.\n */\nexport function useStaticItemRegistration(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): void {\n const collection = useContext(StaticCollectionContext);\n let registeredKey: Key | null = null;\n\n createEffect(\n () => {\n if (!collection) return null;\n const disabled = props.isDisabled;\n return {\n id: props.id,\n textValue: staticItemText(props),\n isDisabled: typeof disabled === \"function\" ? Boolean(disabled()) : Boolean(disabled),\n };\n },\n (item) => {\n if (!collection || !item) return;\n if (registeredKey != null && registeredKey !== item.id) {\n collection.unregisterItem(registeredKey);\n }\n registeredKey = item.id;\n collection.registerItem(item);\n },\n );\n\n onCleanup(() => {\n if (registeredKey != null) {\n collection?.unregisterItem(registeredKey);\n }\n });\n}\n\n/**\n * Mounted while a collection is probed or closed so the collection exists before\n * display. Renders nothing.\n */\nexport function StaticCollectionProbeItem(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): JSX.Element {\n useStaticItemRegistration(props);\n return <></>;\n}\n\nexport interface StaticCollectionBuilderProps {\n content?: JSX.Element;\n children: (items: Accessor<StaticCollectionItem[]>) => JSX.Element;\n}\n\nexport function CollectionBuilder<T>(\n props: AriaCollectionBuilderProps<T> | StaticCollectionBuilderProps,\n): unknown {\n if (\"content\" in props && typeof props.children === \"function\") {\n const { items, context } = createStaticCollectionState();\n return (\n <StaticCollectionContext value={context}>\n <StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>\n {(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)}\n </StaticCollectionContext>\n );\n }\n return AriaCollectionBuilder(props as AriaCollectionBuilderProps<T>);\n}\n\nexport function Collection<T>(props: AriaCollectionProps<T>): unknown {\n return AriaCollection(props);\n}\n\nexport { createLeafComponent, createBranchComponent };\n\n/**\n * RAC Collection renders `before` + item for every item, and `after` only when\n * the next item in the same level is null (`renderAfterDropIndicators`). The\n * `\"on\"` position is not a collection-level slot. Index-based hosts (ListBox,\n * GridList, Menu, Table) use this helper so they do not fork the geometry.\n */\nexport function renderCollectionDropSlots(options: {\n index: number;\n lastIndex: number;\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n children: JSX.Element;\n}): JSX.Element {\n return (\n <>\n {options.renderDropIndicator?.(options.index, \"before\")}\n {options.children}\n {options.index === options.lastIndex\n ? options.renderDropIndicator?.(options.index, \"after\")\n : null}\n </>\n );\n}\n\n/**\n * A semantic section wrapper for grouped collection content.\n */\nexport function Section(props: SectionProps): JSX.Element {\n const sectionContext = useContext(SectionContext);\n if (sectionContext) {\n if (isDevEnv()) {\n console.warn(`<Section> is deprecated. Please use <${sectionContext.name}> instead.`);\n }\n return sectionContext.render(props, \"solidaria-Section\");\n }\n\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\", \"ref\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Section\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n ref={(el) => assignRef(local.ref, el)}\n {...filteredDomProps()}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-section\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A header/title primitive for collection sections.\n */\nexport function Header(props: HeaderProps): JSX.Element {\n const probe = useContext(StaticCollectionProbeContext);\n const [merged, ref] = useContextProps(props, props.ref, HeaderContext);\n const [local, domProps] = splitProps(merged, [\n \"children\",\n \"class\",\n \"style\",\n \"slot\",\n \"ref\",\n \"role\",\n ]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Header\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n // The registration copy of a static select must not paint a heading.\n if (probe) return <></>;\n\n return (\n <div\n ref={ref}\n {...filteredDomProps()}\n role={local.role ?? \"heading\"}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-header\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A grouping primitive for section item containers.\n */\nexport function Group(props: GroupProps): JSX.Element {\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Group\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n {...filteredDomProps()}\n role=\"group\"\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-group\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyGA,SAASmB,YAAa,KAAiB,IAAa;CAClD,IAAI,CAAC,KAAK;CACV,IAAI,OAAO,QAAQ,YAAY,IAAI,EAAE;MAChC,IAAI,UAAU;AACrB;AAyJA,MAAa,4BACX,cAA8D,IAAI;AACpE,MAAa,8BAA8B;AAC3C,MAAa,iBAAiB,cAA0C,IAAI;AAC5E,MAAa,eAAe,cAA0C,IAAI;AAC1E,MAAa,gBAAgB,cAAyD,IAAI;AAC1F,MAAa,iBAAiB,cAA2C,IAAI;AAE7E,SAAgB,wBAAqE;CACnF,OAAO,WAAW,yBAAyB;AAC7C;;AAGA,SAAgB,oBAAuE;CAErF,OADiB,sBACV,CAAA,EAAU,kBAAkB,0BAA0B;AAC/D;AAEA,SAAgB,oBAAuB,OAA0D;CAC/F,OACE,OAAO,UAAU,YACjB,UAAU,QACV,MAAM,QAAS,MAA+B,KAAK;AAEvD;AAEA,SAAgB,yBAA4B,SAAqC;CAC/E,IAAI,CAAC,WAAW,CAAC,MAAM,QAAQ,OAAO,GAAG,OAAO,CAAC;CACjD,MAAM,YAAiB,CAAC;CACxB,KAAK,MAAM,SAAS,SAClB,IAAI,oBAAoB,KAAK,GAAG,UAAU,KAAK,GAAG,MAAM,KAAK;MACxD,UAAU,KAAK,KAAK;CAE3B,OAAO;AACT;AAEA,SAAS,sBACP,YACA,qBAKa;CACb,MAAM,QAAQ,MAAM,KAAK,UAAU;CACnC,IAAI,sBAAsB;CAC1B,KAAK,IAAI,IAAI,GAAG,IAAI,MAAM,QAAQ,KAChC,IAAK,MAAM,EAAA,CAA0B,SAAS,WAC5C,sBAAsB;CAG1B,OACEnB,gBAA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A,YAAY,MAAM;EAAC;EAC1B,IAAA,OAAA;GAAM,OAAA,MAAM;EAAI;EAChB,eAAA;;CAPF,OAAA,OASEF,YAAAA;EAAC,OAAA,YAAY,eAAe;CAAC,CAAA,CAC1B;CAVL,mBAUK;CAXP,OACEG;AAYJ;;;;AAKA,SAAgB,MAAM,OAAgC;CACpD,MAAM,CAAC,OAAO,YAAY,WAAW,OAAO;EAAC;EAAY;EAAS;EAAS;CAAM,CAAC;CAElF,MAAM,eAAe,kBAAkD,EACrE,aAAa,MAAM,YAAY,KACjC,EAAE;CAEF,MAAM,cAAc,eAClB;EACE,IAAI,WAAW;GACb,OAAO,MAAM;EACf;EACA,IAAI,QAAQ;GACV,OAAO,MAAM;EACf;EACA,IAAI,QAAQ;GACV,OAAO,MAAM;EACf;EACA,kBAAkB;CACpB,GACA,YACF;CAEA,MAAM,mBAAmB,iBAAiB,eAAe,UAAU,EAAE,QAAQ,KAAK,CAAC,CAAC;CAGlF,IAAA,QAAAQ,eAAA,MASK;CARC,OAAA,OAAA,CAAA,kBAAA;EACJP,MAAAA;EACA,IAAA,UAAA;GAAO,OAAA,YAAY,MAAM;EAAC;EAC1B,IAAA,QAAA;GAAO,OAAA,YAAY,MAAM;EAAC;EAC1B,IAAA,OAAA;GAAM,OAAA,MAAM;EAAI;EAChB,cAAA;;CANF,OAAA,OAQEJ,YAAAA;EAAC,OAAA,YAAY,eAAe;CAAC,CAAA,CAC1B;CATL,mBASK;CAVP,OACEK;AAWJ"}
1
+ {"version":3,"file":"Collection.js","names":["<For each={items}>\n {(item, index) => {\n const node = item as { type?: unknown; key?: Key };\n if (node.type === \"content\") {\n // Content rows are rendered by their owning item/section branch.\n return <></>;\n }\n const key = node.key ?? index();\n const isLastInLevel = index() === lastRenderableIndex;\n return (\n <>\n {renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}\n {item as unknown as JSX.Element}\n {isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}\n </>\n );\n }}\n </For>","each={items}","{renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}","{isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}","<StaticCollectionContext value={context}>\n <StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>\n {(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)}\n </StaticCollectionContext>","value={context}","<StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>","value={true}","(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)","{options.renderDropIndicator?.(options.index, \"before\")}","{options.children}","{options.index === options.lastIndex\n ? options.renderDropIndicator?.(options.index, \"after\")\n : null}","ref={(el) => assignRef(local.ref, el)}","{renderProps.renderChildren()}","<div\n ref={(el) => assignRef(local.ref, el)}\n {...filteredDomProps()}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-section\n >\n {renderProps.renderChildren()}\n </div>","ref={ref}","<div\n ref={ref}\n {...filteredDomProps()}\n role={local.role ?? \"heading\"}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-header\n >\n {renderProps.renderChildren()}\n </div>","role=\"group\"","<div\n {...filteredDomProps()}\n role=\"group\"\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-group\n >\n {renderProps.renderChildren()}\n </div>","assignRef","_$createComponent","_$memo","AriaCollectionBuilder","AriaCollection","_$getNextElement","_$scope","ref"],"sources":["../src/Collection.tsx"],"sourcesContent":["/*\n * Copyright 2022 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Collection.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Group.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Header.tsx\n\n/**\n * Collection composition primitives for solidaria-components.\n *\n * Foundational parity layer for React Spectrum-style composition:\n * Section / Header / Group. Based on:\n * - packages/react-aria-components/src/Collection.tsx\n * - packages/react-aria-components/src/Group.tsx\n * - packages/react-aria-components/src/Header.tsx\n */\n\nimport {\n createContext,\n createEffect,\n createMemo,\n createSignal,\n onCleanup,\n runWithOwner,\n useContext,\n For,\n type Accessor,\n} from \"solid-js\";\nimport type { JSX } from \"@solidjs/web\";\nimport type { Key } from \"@proyecto-viviana/solid-stately\";\nimport type { DragTypes, DropOperation, DropTarget } from \"@proyecto-viviana/solid-stately\";\nimport {\n Collection as AriaCollection,\n CollectionBuilder as AriaCollectionBuilder,\n createLeafComponent,\n createBranchComponent,\n type CollectionProps as AriaCollectionProps,\n type CollectionBuilderProps as AriaCollectionBuilderProps,\n} from \"@proyecto-viviana/solidaria\";\nimport { splitProps, isDevEnv } from \"@proyecto-viviana/solidaria/utils\";\nimport {\n type ClassNameOrFunction,\n type ContextValue,\n type StyleOrFunction,\n type SlotProps,\n useContextProps,\n useRenderProps,\n filterDOMProps,\n} from \"./utils\";\n\nexport interface CollectionPrimitiveRenderProps {\n /** Whether the primitive has visible children content. */\n hasChildren: boolean;\n}\n\nexport interface ItemRenderProps {\n /** Whether the item is currently hovered with a mouse. */\n isHovered: boolean;\n /** Whether the item is currently in a pressed state. */\n isPressed: boolean;\n /** Whether the item is currently selected. */\n isSelected: boolean;\n /** Whether the item is currently focused. */\n isFocused: boolean;\n /** Whether the item is currently keyboard focused. */\n isFocusVisible: boolean;\n /** Whether the item is non-interactive. */\n isDisabled: boolean;\n /** The type of selection that is allowed in the collection. */\n selectionMode: \"none\" | \"single\" | \"multiple\";\n /** The selection behavior for the collection. */\n selectionBehavior: \"toggle\" | \"replace\";\n /**\n * Whether the item allows dragging.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-allows-dragging]\n */\n allowsDragging?: boolean;\n /**\n * Whether the item is currently being dragged.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-dragging]\n */\n isDragging?: boolean;\n /**\n * Whether the item is currently an active drop target.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-drop-target]\n */\n isDropTarget?: boolean;\n}\n\ntype RefLike<T> = ((el: T) => void) | { current?: T | null } | undefined;\n\nfunction assignRef<T>(ref: RefLike<T>, el: T): void {\n if (!ref) return;\n if (typeof ref === \"function\") ref(el);\n else ref.current = el;\n}\n\nexport interface CollectionDropTargetDelegate {\n getDropTargetFromPoint(\n x: number,\n y: number,\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getDropOperation(\n target: DropTarget,\n types: DragTypes,\n allowedOperations: DropOperation[],\n ): DropOperation;\n getKeyboardNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getKeyboardPageNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n}\n\nexport interface CollectionRendererContextValue<T> {\n /** Render function used by collection parents to render each item node. */\n renderItem: (item: T) => JSX.Element;\n /** Whether collection rendering is currently virtualized. */\n isVirtualized?: boolean;\n /** Optional layout delegate used by virtualized renderers. */\n layoutDelegate?: unknown;\n /** Optional drop target delegate used by DnD-aware collection paths. */\n dropTargetDelegate?: CollectionDropTargetDelegate;\n /** Optional drop indicator renderer for DnD-aware collection paths. */\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n /**\n * Root renderer for collection items. RAC `CollectionRenderer.CollectionRoot`\n * (`Collection.tsx:196`). Virtualizer replaces this with a scroll-attached\n * content wrapper (`react-aria-components/src/Virtualizer.tsx:99-151`).\n */\n CollectionRoot?: (props: CollectionRootProps<T>) => JSX.Element;\n /** Branch renderer for nested collection items. RAC `CollectionBranch`. */\n CollectionBranch?: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport type CollectionEntry<T> = T | CollectionSection<T>;\n\nexport interface CollectionSection<T> {\n /** Optional unique key for the section wrapper. */\n key?: Key;\n /** Optional section header title. */\n title?: JSX.Element;\n /** Optional aria-label for section grouping. */\n \"aria-label\"?: string;\n /** Items contained in the section. */\n items: T[];\n}\n\nexport interface SectionProps extends SlotProps {\n /** Section contents, usually Header + Group/items. */\n children?: JSX.Element;\n /** Ref for the section element. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id forwarded to the section element. */\n id?: string;\n /** ARIA role forwarded to the section element. */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Accessible name when the section has no naming header. */\n \"aria-label\"?: string;\n /** Id of the element that names the section. */\n \"aria-labelledby\"?: string;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface HeaderProps extends SlotProps {\n /** Header contents, usually section title text. */\n children?: JSX.Element;\n /** Ref for the header element. Context refs merge with this. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id. A menu section assigns this so the group can name itself. */\n id?: string;\n /**\n * ARIA role. Defaults to `heading`. A menu section passes `presentation`\n * so the title names the group instead of exposing a heading.\n */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Optional heading level when rendered as a heading role. */\n \"aria-level\"?: number;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface GroupProps extends SlotProps {\n /** Group contents, usually section items. */\n children?: JSX.Element;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\ninterface SectionContextValue {\n name: string;\n render: (props: SectionProps, className?: string) => JSX.Element;\n}\n\nexport interface CollectionBranchProps<T> {\n collection: Iterable<T>;\n parent?: unknown;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n}\n\nexport interface CollectionRootProps<T> {\n collection: Iterable<T>;\n persistedKeys?: Set<Key> | null;\n /**\n * The collection element that scrolls. RAC `CollectionRootProps.scrollRef`\n * (`Collection.tsx:183`).\n */\n scrollRef?: () => HTMLElement | null | undefined;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n /**\n * Rendered collection items. RAC CollectionRoot renders `node.render()` from\n * the collection; Solid collections pass the already-composed item tree.\n */\n children?: JSX.Element;\n}\n\nexport interface CollectionRenderer<T = unknown> {\n isVirtualized?: boolean;\n layoutDelegate?: unknown;\n dropTargetDelegate?: CollectionDropTargetDelegate;\n CollectionRoot: (props: CollectionRootProps<T>) => JSX.Element;\n CollectionBranch: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport const CollectionRendererContext =\n createContext<CollectionRendererContextValue<unknown> | null>(null);\nexport const SelectableCollectionContext = CollectionRendererContext;\nexport const SectionContext = createContext<SectionContextValue | null>(null);\nexport const GroupContext = createContext<Partial<GroupProps> | null>(null);\nexport const HeaderContext = createContext<ContextValue<HeaderProps, HTMLDivElement>>(null);\nexport const HeadingContext = createContext<Partial<HeaderProps> | null>(null);\n\nexport function useCollectionRenderer<T>(): CollectionRendererContextValue<T> | null {\n return useContext(CollectionRendererContext) as CollectionRendererContextValue<T> | null;\n}\n\n/** RAC collections always render `CollectionRoot` from the renderer context. */\nexport function useCollectionRoot<T>(): (props: CollectionRootProps<T>) => JSX.Element {\n const renderer = useCollectionRenderer<T>();\n return renderer?.CollectionRoot ?? DefaultCollectionRenderer.CollectionRoot;\n}\n\nexport function isCollectionSection<T>(entry: CollectionEntry<T>): entry is CollectionSection<T> {\n return (\n typeof entry === \"object\" &&\n entry !== null &&\n Array.isArray((entry as CollectionSection<T>).items)\n );\n}\n\nexport function flattenCollectionEntries<T>(entries?: CollectionEntry<T>[]): T[] {\n if (!entries || !Array.isArray(entries)) return [];\n const flattened: T[] = [];\n for (const entry of entries) {\n if (isCollectionSection(entry)) flattened.push(...entry.items);\n else flattened.push(entry);\n }\n return flattened;\n}\n\nfunction renderCollectionItems<T>(\n collection: Iterable<T>,\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined,\n): JSX.Element {\n const items = Array.from(collection);\n let lastRenderableIndex = -1;\n for (let i = 0; i < items.length; i++) {\n if ((items[i] as { type?: unknown }).type !== \"content\") {\n lastRenderableIndex = i;\n }\n }\n return (\n <For each={items}>\n {(item, index) => {\n const node = item as { type?: unknown; key?: Key };\n if (node.type === \"content\") {\n // Content rows are rendered by their owning item/section branch.\n return <></>;\n }\n const key = node.key ?? index();\n const isLastInLevel = index() === lastRenderableIndex;\n return (\n <>\n {renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}\n {item as unknown as JSX.Element}\n {isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}\n </>\n );\n }}\n </For>\n );\n}\n\nexport const DefaultCollectionRenderer: CollectionRenderer<unknown> = {\n CollectionRoot(props) {\n if (props.children != null) return props.children;\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n CollectionBranch(props) {\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n};\n\nexport interface StaticCollectionItem {\n id: Key;\n textValue?: string;\n isDisabled?: boolean;\n}\n\nexport interface StaticCollectionContextValue {\n registerItem(item: StaticCollectionItem): void;\n unregisterItem(id: Key): void;\n}\n\nexport const StaticCollectionContext = createContext<StaticCollectionContextValue | null>(null);\n\n/** True only for the registration/probe copy of static collection children. */\nexport const StaticCollectionProbeContext = createContext(false);\n\n/**\n * Set around the displayed copy of static children by a host that filters them\n * (ComboBox): whether the item with this key is in the displayed collection.\n */\nexport const StaticCollectionFilterContext = createContext<((key: Key) => boolean) | null>(null);\n\n/**\n * Display text for a static collection option. An explicit `textValue` wins,\n * including an empty string. Otherwise a string aria-label, then string or number\n * children.\n */\nexport function staticItemText(props: {\n textValue?: string;\n \"aria-label\"?: string;\n children?: unknown;\n}): string | undefined {\n if (props.textValue != null) return props.textValue;\n const label = props[\"aria-label\"];\n if (typeof label === \"string\") return label;\n return textFromNode(props.children);\n}\n\nfunction textFromNode(node: unknown): string | undefined {\n if (typeof node === \"string\" || typeof node === \"number\") return String(node);\n if (typeof node === \"function\" && node.length === 0) {\n return textFromNode((node as () => unknown)());\n }\n if (Array.isArray(node)) {\n let text = \"\";\n let any = false;\n for (const child of node) {\n const part = textFromNode(child);\n if (part != null) {\n text += part;\n any = true;\n }\n }\n return any ? text : undefined;\n }\n return undefined;\n}\n\n/**\n * Manages item descriptor registration for collections with static JSX children (Menu, Select).\n */\nexport function createStaticCollectionState(): {\n items: Accessor<StaticCollectionItem[]>;\n context: StaticCollectionContextValue;\n} {\n const [items, setItems] = createSignal<StaticCollectionItem[]>([]);\n const itemMap = new Map<Key, StaticCollectionItem>();\n\n const syncItems = () => {\n // Item cleanup may run inside a keyed collection computation.\n runWithOwner(null, () => setItems(Array.from(itemMap.values())));\n };\n\n const context: StaticCollectionContextValue = {\n registerItem(item) {\n const previous = itemMap.get(item.id);\n if (\n previous &&\n previous.textValue === item.textValue &&\n previous.isDisabled === item.isDisabled\n ) {\n return;\n }\n\n itemMap.set(item.id, item);\n syncItems();\n },\n unregisterItem(id) {\n if (itemMap.delete(id)) {\n syncItems();\n }\n },\n };\n\n return { items, context };\n}\n\n/**\n * Registers an item with the nearest StaticCollectionContext.\n */\nexport function useStaticItemRegistration(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): void {\n const collection = useContext(StaticCollectionContext);\n let registeredKey: Key | null = null;\n\n createEffect(\n () => {\n if (!collection) return null;\n const disabled = props.isDisabled;\n return {\n id: props.id,\n textValue: staticItemText(props),\n isDisabled: typeof disabled === \"function\" ? Boolean(disabled()) : Boolean(disabled),\n };\n },\n (item) => {\n if (!collection || !item) return;\n if (registeredKey != null && registeredKey !== item.id) {\n collection.unregisterItem(registeredKey);\n }\n registeredKey = item.id;\n collection.registerItem(item);\n },\n );\n\n onCleanup(() => {\n if (registeredKey != null) {\n collection?.unregisterItem(registeredKey);\n }\n });\n}\n\n/**\n * Mounted while a collection is probed or closed so the collection exists before\n * display. Renders nothing.\n */\nexport function StaticCollectionProbeItem(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): JSX.Element {\n useStaticItemRegistration(props);\n return <></>;\n}\n\nexport interface StaticCollectionBuilderProps {\n content?: JSX.Element;\n children: (items: Accessor<StaticCollectionItem[]>) => JSX.Element;\n}\n\nexport function CollectionBuilder<T>(\n props: AriaCollectionBuilderProps<T> | StaticCollectionBuilderProps,\n): unknown {\n if (\"content\" in props && typeof props.children === \"function\") {\n const { items, context } = createStaticCollectionState();\n return (\n <StaticCollectionContext value={context}>\n <StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>\n {(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)}\n </StaticCollectionContext>\n );\n }\n return AriaCollectionBuilder(props as AriaCollectionBuilderProps<T>);\n}\n\nexport function Collection<T>(props: AriaCollectionProps<T>): unknown {\n return AriaCollection(props);\n}\n\nexport { createLeafComponent, createBranchComponent };\n\n/**\n * RAC Collection renders `before` + item for every item, and `after` only when\n * the next item in the same level is null (`renderAfterDropIndicators`). The\n * `\"on\"` position is not a collection-level slot. Index-based hosts (ListBox,\n * GridList, Menu, Table) use this helper so they do not fork the geometry.\n */\nexport function renderCollectionDropSlots(options: {\n index: number;\n lastIndex: number;\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n children: JSX.Element;\n}): JSX.Element {\n return (\n <>\n {options.renderDropIndicator?.(options.index, \"before\")}\n {options.children}\n {options.index === options.lastIndex\n ? options.renderDropIndicator?.(options.index, \"after\")\n : null}\n </>\n );\n}\n\n/**\n * A semantic section wrapper for grouped collection content.\n */\nexport function Section(props: SectionProps): JSX.Element {\n const sectionContext = useContext(SectionContext);\n if (sectionContext) {\n if (isDevEnv()) {\n console.warn(`<Section> is deprecated. Please use <${sectionContext.name}> instead.`);\n }\n return sectionContext.render(props, \"solidaria-Section\");\n }\n\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\", \"ref\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Section\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n ref={(el) => assignRef(local.ref, el)}\n {...filteredDomProps()}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-section\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A header/title primitive for collection sections.\n */\nexport function Header(props: HeaderProps): JSX.Element {\n const probe = useContext(StaticCollectionProbeContext);\n const [merged, ref] = useContextProps(props, props.ref, HeaderContext);\n const [local, domProps] = splitProps(merged, [\n \"children\",\n \"class\",\n \"style\",\n \"slot\",\n \"ref\",\n \"role\",\n ]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Header\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n // The registration copy of a static select must not paint a heading.\n if (probe) return <></>;\n\n return (\n <div\n ref={ref}\n {...filteredDomProps()}\n role={local.role ?? \"heading\"}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-header\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A grouping primitive for section item containers.\n */\nexport function Group(props: GroupProps): JSX.Element {\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Group\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n {...filteredDomProps()}\n role=\"group\"\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-group\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0GA,SAASmB,YAAa,KAAiB,IAAa;CAClD,IAAI,CAAC,KAAK;CACV,IAAI,OAAO,QAAQ,YAAY,IAAI,EAAE;MAChC,IAAI,UAAU;AACrB;AAyJA,MAAa,4BACX,cAA8D,IAAI;AACpE,MAAa,8BAA8B;AAC3C,MAAa,iBAAiB,cAA0C,IAAI;AAC5E,MAAa,eAAe,cAA0C,IAAI;AAC1E,MAAa,gBAAgB,cAAyD,IAAI;AAC1F,MAAa,iBAAiB,cAA2C,IAAI;AAE7E,SAAgB,wBAAqE;CACnF,OAAO,WAAW,yBAAyB;AAC7C;;AAGA,SAAgB,oBAAuE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GlF,IAAA,QAAAQ,eAAA,MASK;CARC,OAAA,OAAA,CAAA,kBAAA;EACJP,MAAAA;EACA,IAAA,UAAA;GAAO,OAAA,YAAY,MAAM;EAAC;EAC1B,IAAA,QAAA;GAAO,OAAA,YAAY,MAAM;EAAC;EAC1B,IAAA,OAAA;GAAM,OAAA,MAAM;EAAI;EAChB,cAAA;;CANF,OAAA,OAQEJ,YAAAA;EAAC,OAAA,YAAY,eAAe;CAAC,CAAA,CAC1B;CATL,mBASK;CAVP,OACEK;AAWJ"}
@@ -13,7 +13,7 @@
13
13
  // Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Group.tsx
14
14
  // Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Header.tsx
15
15
  import { filterDOMProps, useContextProps, useRenderProps } from "./utils.jsx";
16
- import { For, createContext, createEffect, createMemo, createSignal, onCleanup, useContext } from "solid-js";
16
+ import { For, createContext, createEffect, createMemo, createSignal, onCleanup, runWithOwner, useContext } from "solid-js";
17
17
  import { Collection as Collection$1, CollectionBuilder as CollectionBuilder$1, createBranchComponent, createLeafComponent } from "@proyecto-viviana/solidaria";
18
18
  import { isDevEnv, splitProps } from "@proyecto-viviana/solidaria/utils";
19
19
  //#region src/Collection.tsx
@@ -131,7 +131,7 @@ function createStaticCollectionState() {
131
131
  const [items, setItems] = createSignal([]);
132
132
  const itemMap = /* @__PURE__ */ new Map();
133
133
  const syncItems = () => {
134
- setItems(Array.from(itemMap.values()));
134
+ runWithOwner(null, () => setItems(Array.from(itemMap.values())));
135
135
  };
136
136
  return {
137
137
  items,
@@ -1 +1 @@
1
- {"version":3,"file":"Collection.jsx","names":["assignRef","AriaCollectionBuilder","AriaCollection"],"sources":["../src/Collection.tsx"],"sourcesContent":["/*\n * Copyright 2022 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Collection.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Group.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Header.tsx\n\n/**\n * Collection composition primitives for solidaria-components.\n *\n * Foundational parity layer for React Spectrum-style composition:\n * Section / Header / Group. Based on:\n * - packages/react-aria-components/src/Collection.tsx\n * - packages/react-aria-components/src/Group.tsx\n * - packages/react-aria-components/src/Header.tsx\n */\n\nimport {\n createContext,\n createEffect,\n createMemo,\n createSignal,\n onCleanup,\n useContext,\n For,\n type Accessor,\n} from \"solid-js\";\nimport type { JSX } from \"@solidjs/web\";\nimport type { Key } from \"@proyecto-viviana/solid-stately\";\nimport type { DragTypes, DropOperation, DropTarget } from \"@proyecto-viviana/solid-stately\";\nimport {\n Collection as AriaCollection,\n CollectionBuilder as AriaCollectionBuilder,\n createLeafComponent,\n createBranchComponent,\n type CollectionProps as AriaCollectionProps,\n type CollectionBuilderProps as AriaCollectionBuilderProps,\n} from \"@proyecto-viviana/solidaria\";\nimport { splitProps, isDevEnv } from \"@proyecto-viviana/solidaria/utils\";\nimport {\n type ClassNameOrFunction,\n type ContextValue,\n type StyleOrFunction,\n type SlotProps,\n useContextProps,\n useRenderProps,\n filterDOMProps,\n} from \"./utils\";\n\nexport interface CollectionPrimitiveRenderProps {\n /** Whether the primitive has visible children content. */\n hasChildren: boolean;\n}\n\nexport interface ItemRenderProps {\n /** Whether the item is currently hovered with a mouse. */\n isHovered: boolean;\n /** Whether the item is currently in a pressed state. */\n isPressed: boolean;\n /** Whether the item is currently selected. */\n isSelected: boolean;\n /** Whether the item is currently focused. */\n isFocused: boolean;\n /** Whether the item is currently keyboard focused. */\n isFocusVisible: boolean;\n /** Whether the item is non-interactive. */\n isDisabled: boolean;\n /** The type of selection that is allowed in the collection. */\n selectionMode: \"none\" | \"single\" | \"multiple\";\n /** The selection behavior for the collection. */\n selectionBehavior: \"toggle\" | \"replace\";\n /**\n * Whether the item allows dragging.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-allows-dragging]\n */\n allowsDragging?: boolean;\n /**\n * Whether the item is currently being dragged.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-dragging]\n */\n isDragging?: boolean;\n /**\n * Whether the item is currently an active drop target.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-drop-target]\n */\n isDropTarget?: boolean;\n}\n\ntype RefLike<T> = ((el: T) => void) | { current?: T | null } | undefined;\n\nfunction assignRef<T>(ref: RefLike<T>, el: T): void {\n if (!ref) return;\n if (typeof ref === \"function\") ref(el);\n else ref.current = el;\n}\n\nexport interface CollectionDropTargetDelegate {\n getDropTargetFromPoint(\n x: number,\n y: number,\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getDropOperation(\n target: DropTarget,\n types: DragTypes,\n allowedOperations: DropOperation[],\n ): DropOperation;\n getKeyboardNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getKeyboardPageNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n}\n\nexport interface CollectionRendererContextValue<T> {\n /** Render function used by collection parents to render each item node. */\n renderItem: (item: T) => JSX.Element;\n /** Whether collection rendering is currently virtualized. */\n isVirtualized?: boolean;\n /** Optional layout delegate used by virtualized renderers. */\n layoutDelegate?: unknown;\n /** Optional drop target delegate used by DnD-aware collection paths. */\n dropTargetDelegate?: CollectionDropTargetDelegate;\n /** Optional drop indicator renderer for DnD-aware collection paths. */\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n /**\n * Root renderer for collection items. RAC `CollectionRenderer.CollectionRoot`\n * (`Collection.tsx:196`). Virtualizer replaces this with a scroll-attached\n * content wrapper (`react-aria-components/src/Virtualizer.tsx:99-151`).\n */\n CollectionRoot?: (props: CollectionRootProps<T>) => JSX.Element;\n /** Branch renderer for nested collection items. RAC `CollectionBranch`. */\n CollectionBranch?: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport type CollectionEntry<T> = T | CollectionSection<T>;\n\nexport interface CollectionSection<T> {\n /** Optional unique key for the section wrapper. */\n key?: Key;\n /** Optional section header title. */\n title?: JSX.Element;\n /** Optional aria-label for section grouping. */\n \"aria-label\"?: string;\n /** Items contained in the section. */\n items: T[];\n}\n\nexport interface SectionProps extends SlotProps {\n /** Section contents, usually Header + Group/items. */\n children?: JSX.Element;\n /** Ref for the section element. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id forwarded to the section element. */\n id?: string;\n /** ARIA role forwarded to the section element. */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Accessible name when the section has no naming header. */\n \"aria-label\"?: string;\n /** Id of the element that names the section. */\n \"aria-labelledby\"?: string;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface HeaderProps extends SlotProps {\n /** Header contents, usually section title text. */\n children?: JSX.Element;\n /** Ref for the header element. Context refs merge with this. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id. A menu section assigns this so the group can name itself. */\n id?: string;\n /**\n * ARIA role. Defaults to `heading`. A menu section passes `presentation`\n * so the title names the group instead of exposing a heading.\n */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Optional heading level when rendered as a heading role. */\n \"aria-level\"?: number;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface GroupProps extends SlotProps {\n /** Group contents, usually section items. */\n children?: JSX.Element;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\ninterface SectionContextValue {\n name: string;\n render: (props: SectionProps, className?: string) => JSX.Element;\n}\n\nexport interface CollectionBranchProps<T> {\n collection: Iterable<T>;\n parent?: unknown;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n}\n\nexport interface CollectionRootProps<T> {\n collection: Iterable<T>;\n persistedKeys?: Set<Key> | null;\n /**\n * The collection element that scrolls. RAC `CollectionRootProps.scrollRef`\n * (`Collection.tsx:183`).\n */\n scrollRef?: () => HTMLElement | null | undefined;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n /**\n * Rendered collection items. RAC CollectionRoot renders `node.render()` from\n * the collection; Solid collections pass the already-composed item tree.\n */\n children?: JSX.Element;\n}\n\nexport interface CollectionRenderer<T = unknown> {\n isVirtualized?: boolean;\n layoutDelegate?: unknown;\n dropTargetDelegate?: CollectionDropTargetDelegate;\n CollectionRoot: (props: CollectionRootProps<T>) => JSX.Element;\n CollectionBranch: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport const CollectionRendererContext =\n createContext<CollectionRendererContextValue<unknown> | null>(null);\nexport const SelectableCollectionContext = CollectionRendererContext;\nexport const SectionContext = createContext<SectionContextValue | null>(null);\nexport const GroupContext = createContext<Partial<GroupProps> | null>(null);\nexport const HeaderContext = createContext<ContextValue<HeaderProps, HTMLDivElement>>(null);\nexport const HeadingContext = createContext<Partial<HeaderProps> | null>(null);\n\nexport function useCollectionRenderer<T>(): CollectionRendererContextValue<T> | null {\n return useContext(CollectionRendererContext) as CollectionRendererContextValue<T> | null;\n}\n\n/** RAC collections always render `CollectionRoot` from the renderer context. */\nexport function useCollectionRoot<T>(): (props: CollectionRootProps<T>) => JSX.Element {\n const renderer = useCollectionRenderer<T>();\n return renderer?.CollectionRoot ?? DefaultCollectionRenderer.CollectionRoot;\n}\n\nexport function isCollectionSection<T>(entry: CollectionEntry<T>): entry is CollectionSection<T> {\n return (\n typeof entry === \"object\" &&\n entry !== null &&\n Array.isArray((entry as CollectionSection<T>).items)\n );\n}\n\nexport function flattenCollectionEntries<T>(entries?: CollectionEntry<T>[]): T[] {\n if (!entries || !Array.isArray(entries)) return [];\n const flattened: T[] = [];\n for (const entry of entries) {\n if (isCollectionSection(entry)) flattened.push(...entry.items);\n else flattened.push(entry);\n }\n return flattened;\n}\n\nfunction renderCollectionItems<T>(\n collection: Iterable<T>,\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined,\n): JSX.Element {\n const items = Array.from(collection);\n let lastRenderableIndex = -1;\n for (let i = 0; i < items.length; i++) {\n if ((items[i] as { type?: unknown }).type !== \"content\") {\n lastRenderableIndex = i;\n }\n }\n return (\n <For each={items}>\n {(item, index) => {\n const node = item as { type?: unknown; key?: Key };\n if (node.type === \"content\") {\n // Content rows are rendered by their owning item/section branch.\n return <></>;\n }\n const key = node.key ?? index();\n const isLastInLevel = index() === lastRenderableIndex;\n return (\n <>\n {renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}\n {item as unknown as JSX.Element}\n {isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}\n </>\n );\n }}\n </For>\n );\n}\n\nexport const DefaultCollectionRenderer: CollectionRenderer<unknown> = {\n CollectionRoot(props) {\n if (props.children != null) return props.children;\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n CollectionBranch(props) {\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n};\n\nexport interface StaticCollectionItem {\n id: Key;\n textValue?: string;\n isDisabled?: boolean;\n}\n\nexport interface StaticCollectionContextValue {\n registerItem(item: StaticCollectionItem): void;\n unregisterItem(id: Key): void;\n}\n\nexport const StaticCollectionContext = createContext<StaticCollectionContextValue | null>(null);\n\n/** True only for the registration/probe copy of static collection children. */\nexport const StaticCollectionProbeContext = createContext(false);\n\n/**\n * Set around the displayed copy of static children by a host that filters them\n * (ComboBox): whether the item with this key is in the displayed collection.\n */\nexport const StaticCollectionFilterContext = createContext<((key: Key) => boolean) | null>(null);\n\n/**\n * Display text for a static collection option. An explicit `textValue` wins,\n * including an empty string. Otherwise a string aria-label, then string or number\n * children.\n */\nexport function staticItemText(props: {\n textValue?: string;\n \"aria-label\"?: string;\n children?: unknown;\n}): string | undefined {\n if (props.textValue != null) return props.textValue;\n const label = props[\"aria-label\"];\n if (typeof label === \"string\") return label;\n return textFromNode(props.children);\n}\n\nfunction textFromNode(node: unknown): string | undefined {\n if (typeof node === \"string\" || typeof node === \"number\") return String(node);\n if (typeof node === \"function\" && node.length === 0) {\n return textFromNode((node as () => unknown)());\n }\n if (Array.isArray(node)) {\n let text = \"\";\n let any = false;\n for (const child of node) {\n const part = textFromNode(child);\n if (part != null) {\n text += part;\n any = true;\n }\n }\n return any ? text : undefined;\n }\n return undefined;\n}\n\n/**\n * Manages item descriptor registration for collections with static JSX children (Menu, Select).\n */\nexport function createStaticCollectionState(): {\n items: Accessor<StaticCollectionItem[]>;\n context: StaticCollectionContextValue;\n} {\n const [items, setItems] = createSignal<StaticCollectionItem[]>([]);\n const itemMap = new Map<Key, StaticCollectionItem>();\n\n const syncItems = () => {\n setItems(Array.from(itemMap.values()));\n };\n\n const context: StaticCollectionContextValue = {\n registerItem(item) {\n const previous = itemMap.get(item.id);\n if (\n previous &&\n previous.textValue === item.textValue &&\n previous.isDisabled === item.isDisabled\n ) {\n return;\n }\n\n itemMap.set(item.id, item);\n syncItems();\n },\n unregisterItem(id) {\n if (itemMap.delete(id)) {\n syncItems();\n }\n },\n };\n\n return { items, context };\n}\n\n/**\n * Registers an item with the nearest StaticCollectionContext.\n */\nexport function useStaticItemRegistration(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): void {\n const collection = useContext(StaticCollectionContext);\n let registeredKey: Key | null = null;\n\n createEffect(\n () => {\n if (!collection) return null;\n const disabled = props.isDisabled;\n return {\n id: props.id,\n textValue: staticItemText(props),\n isDisabled: typeof disabled === \"function\" ? Boolean(disabled()) : Boolean(disabled),\n };\n },\n (item) => {\n if (!collection || !item) return;\n if (registeredKey != null && registeredKey !== item.id) {\n collection.unregisterItem(registeredKey);\n }\n registeredKey = item.id;\n collection.registerItem(item);\n },\n );\n\n onCleanup(() => {\n if (registeredKey != null) {\n collection?.unregisterItem(registeredKey);\n }\n });\n}\n\n/**\n * Mounted while a collection is probed or closed so the collection exists before\n * display. Renders nothing.\n */\nexport function StaticCollectionProbeItem(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): JSX.Element {\n useStaticItemRegistration(props);\n return <></>;\n}\n\nexport interface StaticCollectionBuilderProps {\n content?: JSX.Element;\n children: (items: Accessor<StaticCollectionItem[]>) => JSX.Element;\n}\n\nexport function CollectionBuilder<T>(\n props: AriaCollectionBuilderProps<T> | StaticCollectionBuilderProps,\n): unknown {\n if (\"content\" in props && typeof props.children === \"function\") {\n const { items, context } = createStaticCollectionState();\n return (\n <StaticCollectionContext value={context}>\n <StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>\n {(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)}\n </StaticCollectionContext>\n );\n }\n return AriaCollectionBuilder(props as AriaCollectionBuilderProps<T>);\n}\n\nexport function Collection<T>(props: AriaCollectionProps<T>): unknown {\n return AriaCollection(props);\n}\n\nexport { createLeafComponent, createBranchComponent };\n\n/**\n * RAC Collection renders `before` + item for every item, and `after` only when\n * the next item in the same level is null (`renderAfterDropIndicators`). The\n * `\"on\"` position is not a collection-level slot. Index-based hosts (ListBox,\n * GridList, Menu, Table) use this helper so they do not fork the geometry.\n */\nexport function renderCollectionDropSlots(options: {\n index: number;\n lastIndex: number;\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n children: JSX.Element;\n}): JSX.Element {\n return (\n <>\n {options.renderDropIndicator?.(options.index, \"before\")}\n {options.children}\n {options.index === options.lastIndex\n ? options.renderDropIndicator?.(options.index, \"after\")\n : null}\n </>\n );\n}\n\n/**\n * A semantic section wrapper for grouped collection content.\n */\nexport function Section(props: SectionProps): JSX.Element {\n const sectionContext = useContext(SectionContext);\n if (sectionContext) {\n if (isDevEnv()) {\n console.warn(`<Section> is deprecated. Please use <${sectionContext.name}> instead.`);\n }\n return sectionContext.render(props, \"solidaria-Section\");\n }\n\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\", \"ref\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Section\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n ref={(el) => assignRef(local.ref, el)}\n {...filteredDomProps()}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-section\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A header/title primitive for collection sections.\n */\nexport function Header(props: HeaderProps): JSX.Element {\n const probe = useContext(StaticCollectionProbeContext);\n const [merged, ref] = useContextProps(props, props.ref, HeaderContext);\n const [local, domProps] = splitProps(merged, [\n \"children\",\n \"class\",\n \"style\",\n \"slot\",\n \"ref\",\n \"role\",\n ]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Header\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n // The registration copy of a static select must not paint a heading.\n if (probe) return <></>;\n\n return (\n <div\n ref={ref}\n {...filteredDomProps()}\n role={local.role ?? \"heading\"}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-header\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A grouping primitive for section item containers.\n */\nexport function Group(props: GroupProps): JSX.Element {\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Group\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n {...filteredDomProps()}\n role=\"group\"\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-group\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyGA,SAASA,YAAa,KAAiB,IAAa;CAClD,IAAI,CAAC,KAAK;CACV,IAAI,OAAO,QAAQ,YAAY,IAAI,EAAE;MAChC,IAAI,UAAU;AACrB;AAyJA,MAAa,4BACX,cAA8D,IAAI;AACpE,MAAa,8BAA8B;AAC3C,MAAa,iBAAiB,cAA0C,IAAI;AAC5E,MAAa,eAAe,cAA0C,IAAI;AAC1E,MAAa,gBAAgB,cAAyD,IAAI;AAC1F,MAAa,iBAAiB,cAA2C,IAAI;AAE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AI,OAAO,OAAO,EAAE;CAEpB,OACE,CAAC,IACC,KAAK,KACL,IAAI,iBAAiB,CAAC,EACtB,MAAM,MAAM,QAAQ,WACpB,OAAO,YAAY,MAAM,GACzB,OAAO,YAAY,MAAM,GACzB,MAAM,MAAM,MACZ,YACD;OACE,YAAY,eAAe,EAAE;IAChC,EAAE;AAEN;;;;AAKA,SAAgB,MAAM,OAAgC;CACpD,MAAM,CAAC,OAAO,YAAY,WAAW,OAAO;EAAC;EAAY;EAAS;EAAS;CAAM,CAAC;CAElF,MAAM,eAAe,kBAAkD,EACrE,aAAa,MAAM,YAAY,KACjC,EAAE;CAEF,MAAM,cAAc,eAClB;EACE,IAAI,WAAW;GACb,OAAO,MAAM;EACf;EACA,IAAI,QAAQ;GACV,OAAO,MAAM;EACf;EACA,IAAI,QAAQ;GACV,OAAO,MAAM;EACf;EACA,kBAAkB;CACpB,GACA,YACF;CAEA,MAAM,mBAAmB,iBAAiB,eAAe,UAAU,EAAE,QAAQ,KAAK,CAAC,CAAC;CAEpF,OACE,CAAC,IACC,IAAI,iBAAiB,CAAC,EACtB,aACA,OAAO,YAAY,MAAM,GACzB,OAAO,YAAY,MAAM,GACzB,MAAM,MAAM,MACZ,WACD;OACE,YAAY,eAAe,EAAE;IAChC,EAAE;AAEN"}
1
+ {"version":3,"file":"Collection.jsx","names":["assignRef","AriaCollectionBuilder","AriaCollection"],"sources":["../src/Collection.tsx"],"sourcesContent":["/*\n * Copyright 2022 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Collection.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Group.tsx\n// Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/Header.tsx\n\n/**\n * Collection composition primitives for solidaria-components.\n *\n * Foundational parity layer for React Spectrum-style composition:\n * Section / Header / Group. Based on:\n * - packages/react-aria-components/src/Collection.tsx\n * - packages/react-aria-components/src/Group.tsx\n * - packages/react-aria-components/src/Header.tsx\n */\n\nimport {\n createContext,\n createEffect,\n createMemo,\n createSignal,\n onCleanup,\n runWithOwner,\n useContext,\n For,\n type Accessor,\n} from \"solid-js\";\nimport type { JSX } from \"@solidjs/web\";\nimport type { Key } from \"@proyecto-viviana/solid-stately\";\nimport type { DragTypes, DropOperation, DropTarget } from \"@proyecto-viviana/solid-stately\";\nimport {\n Collection as AriaCollection,\n CollectionBuilder as AriaCollectionBuilder,\n createLeafComponent,\n createBranchComponent,\n type CollectionProps as AriaCollectionProps,\n type CollectionBuilderProps as AriaCollectionBuilderProps,\n} from \"@proyecto-viviana/solidaria\";\nimport { splitProps, isDevEnv } from \"@proyecto-viviana/solidaria/utils\";\nimport {\n type ClassNameOrFunction,\n type ContextValue,\n type StyleOrFunction,\n type SlotProps,\n useContextProps,\n useRenderProps,\n filterDOMProps,\n} from \"./utils\";\n\nexport interface CollectionPrimitiveRenderProps {\n /** Whether the primitive has visible children content. */\n hasChildren: boolean;\n}\n\nexport interface ItemRenderProps {\n /** Whether the item is currently hovered with a mouse. */\n isHovered: boolean;\n /** Whether the item is currently in a pressed state. */\n isPressed: boolean;\n /** Whether the item is currently selected. */\n isSelected: boolean;\n /** Whether the item is currently focused. */\n isFocused: boolean;\n /** Whether the item is currently keyboard focused. */\n isFocusVisible: boolean;\n /** Whether the item is non-interactive. */\n isDisabled: boolean;\n /** The type of selection that is allowed in the collection. */\n selectionMode: \"none\" | \"single\" | \"multiple\";\n /** The selection behavior for the collection. */\n selectionBehavior: \"toggle\" | \"replace\";\n /**\n * Whether the item allows dragging.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-allows-dragging]\n */\n allowsDragging?: boolean;\n /**\n * Whether the item is currently being dragged.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-dragging]\n */\n isDragging?: boolean;\n /**\n * Whether the item is currently an active drop target.\n *\n * @note This property is only available in collection components that support drag and drop.\n * @selector [data-drop-target]\n */\n isDropTarget?: boolean;\n}\n\ntype RefLike<T> = ((el: T) => void) | { current?: T | null } | undefined;\n\nfunction assignRef<T>(ref: RefLike<T>, el: T): void {\n if (!ref) return;\n if (typeof ref === \"function\") ref(el);\n else ref.current = el;\n}\n\nexport interface CollectionDropTargetDelegate {\n getDropTargetFromPoint(\n x: number,\n y: number,\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getDropOperation(\n target: DropTarget,\n types: DragTypes,\n allowedOperations: DropOperation[],\n ): DropOperation;\n getKeyboardNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n getKeyboardPageNavigationTarget?(\n target: DropTarget | null,\n direction: \"next\" | \"previous\",\n isValidDropTarget: (target: DropTarget) => boolean,\n ): DropTarget | null;\n}\n\nexport interface CollectionRendererContextValue<T> {\n /** Render function used by collection parents to render each item node. */\n renderItem: (item: T) => JSX.Element;\n /** Whether collection rendering is currently virtualized. */\n isVirtualized?: boolean;\n /** Optional layout delegate used by virtualized renderers. */\n layoutDelegate?: unknown;\n /** Optional drop target delegate used by DnD-aware collection paths. */\n dropTargetDelegate?: CollectionDropTargetDelegate;\n /** Optional drop indicator renderer for DnD-aware collection paths. */\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n /**\n * Root renderer for collection items. RAC `CollectionRenderer.CollectionRoot`\n * (`Collection.tsx:196`). Virtualizer replaces this with a scroll-attached\n * content wrapper (`react-aria-components/src/Virtualizer.tsx:99-151`).\n */\n CollectionRoot?: (props: CollectionRootProps<T>) => JSX.Element;\n /** Branch renderer for nested collection items. RAC `CollectionBranch`. */\n CollectionBranch?: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport type CollectionEntry<T> = T | CollectionSection<T>;\n\nexport interface CollectionSection<T> {\n /** Optional unique key for the section wrapper. */\n key?: Key;\n /** Optional section header title. */\n title?: JSX.Element;\n /** Optional aria-label for section grouping. */\n \"aria-label\"?: string;\n /** Items contained in the section. */\n items: T[];\n}\n\nexport interface SectionProps extends SlotProps {\n /** Section contents, usually Header + Group/items. */\n children?: JSX.Element;\n /** Ref for the section element. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id forwarded to the section element. */\n id?: string;\n /** ARIA role forwarded to the section element. */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Accessible name when the section has no naming header. */\n \"aria-label\"?: string;\n /** Id of the element that names the section. */\n \"aria-labelledby\"?: string;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface HeaderProps extends SlotProps {\n /** Header contents, usually section title text. */\n children?: JSX.Element;\n /** Ref for the header element. Context refs merge with this. */\n ref?: RefLike<HTMLDivElement>;\n /** DOM id. A menu section assigns this so the group can name itself. */\n id?: string;\n /**\n * ARIA role. Defaults to `heading`. A menu section passes `presentation`\n * so the title names the group instead of exposing a heading.\n */\n role?: JSX.HTMLAttributes<HTMLElement>[\"role\"];\n /** Optional heading level when rendered as a heading role. */\n \"aria-level\"?: number;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\nexport interface GroupProps extends SlotProps {\n /** Group contents, usually section items. */\n children?: JSX.Element;\n /** The CSS className for the element. */\n class?: ClassNameOrFunction<CollectionPrimitiveRenderProps>;\n /** The inline style for the element. */\n style?: StyleOrFunction<CollectionPrimitiveRenderProps>;\n}\n\ninterface SectionContextValue {\n name: string;\n render: (props: SectionProps, className?: string) => JSX.Element;\n}\n\nexport interface CollectionBranchProps<T> {\n collection: Iterable<T>;\n parent?: unknown;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n}\n\nexport interface CollectionRootProps<T> {\n collection: Iterable<T>;\n persistedKeys?: Set<Key> | null;\n /**\n * The collection element that scrolls. RAC `CollectionRootProps.scrollRef`\n * (`Collection.tsx:183`).\n */\n scrollRef?: () => HTMLElement | null | undefined;\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined;\n /**\n * Rendered collection items. RAC CollectionRoot renders `node.render()` from\n * the collection; Solid collections pass the already-composed item tree.\n */\n children?: JSX.Element;\n}\n\nexport interface CollectionRenderer<T = unknown> {\n isVirtualized?: boolean;\n layoutDelegate?: unknown;\n dropTargetDelegate?: CollectionDropTargetDelegate;\n CollectionRoot: (props: CollectionRootProps<T>) => JSX.Element;\n CollectionBranch: (props: CollectionBranchProps<T>) => JSX.Element;\n}\n\nexport const CollectionRendererContext =\n createContext<CollectionRendererContextValue<unknown> | null>(null);\nexport const SelectableCollectionContext = CollectionRendererContext;\nexport const SectionContext = createContext<SectionContextValue | null>(null);\nexport const GroupContext = createContext<Partial<GroupProps> | null>(null);\nexport const HeaderContext = createContext<ContextValue<HeaderProps, HTMLDivElement>>(null);\nexport const HeadingContext = createContext<Partial<HeaderProps> | null>(null);\n\nexport function useCollectionRenderer<T>(): CollectionRendererContextValue<T> | null {\n return useContext(CollectionRendererContext) as CollectionRendererContextValue<T> | null;\n}\n\n/** RAC collections always render `CollectionRoot` from the renderer context. */\nexport function useCollectionRoot<T>(): (props: CollectionRootProps<T>) => JSX.Element {\n const renderer = useCollectionRenderer<T>();\n return renderer?.CollectionRoot ?? DefaultCollectionRenderer.CollectionRoot;\n}\n\nexport function isCollectionSection<T>(entry: CollectionEntry<T>): entry is CollectionSection<T> {\n return (\n typeof entry === \"object\" &&\n entry !== null &&\n Array.isArray((entry as CollectionSection<T>).items)\n );\n}\n\nexport function flattenCollectionEntries<T>(entries?: CollectionEntry<T>[]): T[] {\n if (!entries || !Array.isArray(entries)) return [];\n const flattened: T[] = [];\n for (const entry of entries) {\n if (isCollectionSection(entry)) flattened.push(...entry.items);\n else flattened.push(entry);\n }\n return flattened;\n}\n\nfunction renderCollectionItems<T>(\n collection: Iterable<T>,\n renderDropIndicator?: (target: {\n type: \"item\";\n key: Key;\n dropPosition: \"before\" | \"after\" | \"on\";\n }) => JSX.Element | undefined,\n): JSX.Element {\n const items = Array.from(collection);\n let lastRenderableIndex = -1;\n for (let i = 0; i < items.length; i++) {\n if ((items[i] as { type?: unknown }).type !== \"content\") {\n lastRenderableIndex = i;\n }\n }\n return (\n <For each={items}>\n {(item, index) => {\n const node = item as { type?: unknown; key?: Key };\n if (node.type === \"content\") {\n // Content rows are rendered by their owning item/section branch.\n return <></>;\n }\n const key = node.key ?? index();\n const isLastInLevel = index() === lastRenderableIndex;\n return (\n <>\n {renderDropIndicator?.({ type: \"item\", key, dropPosition: \"before\" })}\n {item as unknown as JSX.Element}\n {isLastInLevel\n ? renderDropIndicator?.({ type: \"item\", key, dropPosition: \"after\" })\n : null}\n </>\n );\n }}\n </For>\n );\n}\n\nexport const DefaultCollectionRenderer: CollectionRenderer<unknown> = {\n CollectionRoot(props) {\n if (props.children != null) return props.children;\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n CollectionBranch(props) {\n return renderCollectionItems(props.collection, props.renderDropIndicator);\n },\n};\n\nexport interface StaticCollectionItem {\n id: Key;\n textValue?: string;\n isDisabled?: boolean;\n}\n\nexport interface StaticCollectionContextValue {\n registerItem(item: StaticCollectionItem): void;\n unregisterItem(id: Key): void;\n}\n\nexport const StaticCollectionContext = createContext<StaticCollectionContextValue | null>(null);\n\n/** True only for the registration/probe copy of static collection children. */\nexport const StaticCollectionProbeContext = createContext(false);\n\n/**\n * Set around the displayed copy of static children by a host that filters them\n * (ComboBox): whether the item with this key is in the displayed collection.\n */\nexport const StaticCollectionFilterContext = createContext<((key: Key) => boolean) | null>(null);\n\n/**\n * Display text for a static collection option. An explicit `textValue` wins,\n * including an empty string. Otherwise a string aria-label, then string or number\n * children.\n */\nexport function staticItemText(props: {\n textValue?: string;\n \"aria-label\"?: string;\n children?: unknown;\n}): string | undefined {\n if (props.textValue != null) return props.textValue;\n const label = props[\"aria-label\"];\n if (typeof label === \"string\") return label;\n return textFromNode(props.children);\n}\n\nfunction textFromNode(node: unknown): string | undefined {\n if (typeof node === \"string\" || typeof node === \"number\") return String(node);\n if (typeof node === \"function\" && node.length === 0) {\n return textFromNode((node as () => unknown)());\n }\n if (Array.isArray(node)) {\n let text = \"\";\n let any = false;\n for (const child of node) {\n const part = textFromNode(child);\n if (part != null) {\n text += part;\n any = true;\n }\n }\n return any ? text : undefined;\n }\n return undefined;\n}\n\n/**\n * Manages item descriptor registration for collections with static JSX children (Menu, Select).\n */\nexport function createStaticCollectionState(): {\n items: Accessor<StaticCollectionItem[]>;\n context: StaticCollectionContextValue;\n} {\n const [items, setItems] = createSignal<StaticCollectionItem[]>([]);\n const itemMap = new Map<Key, StaticCollectionItem>();\n\n const syncItems = () => {\n // Item cleanup may run inside a keyed collection computation.\n runWithOwner(null, () => setItems(Array.from(itemMap.values())));\n };\n\n const context: StaticCollectionContextValue = {\n registerItem(item) {\n const previous = itemMap.get(item.id);\n if (\n previous &&\n previous.textValue === item.textValue &&\n previous.isDisabled === item.isDisabled\n ) {\n return;\n }\n\n itemMap.set(item.id, item);\n syncItems();\n },\n unregisterItem(id) {\n if (itemMap.delete(id)) {\n syncItems();\n }\n },\n };\n\n return { items, context };\n}\n\n/**\n * Registers an item with the nearest StaticCollectionContext.\n */\nexport function useStaticItemRegistration(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): void {\n const collection = useContext(StaticCollectionContext);\n let registeredKey: Key | null = null;\n\n createEffect(\n () => {\n if (!collection) return null;\n const disabled = props.isDisabled;\n return {\n id: props.id,\n textValue: staticItemText(props),\n isDisabled: typeof disabled === \"function\" ? Boolean(disabled()) : Boolean(disabled),\n };\n },\n (item) => {\n if (!collection || !item) return;\n if (registeredKey != null && registeredKey !== item.id) {\n collection.unregisterItem(registeredKey);\n }\n registeredKey = item.id;\n collection.registerItem(item);\n },\n );\n\n onCleanup(() => {\n if (registeredKey != null) {\n collection?.unregisterItem(registeredKey);\n }\n });\n}\n\n/**\n * Mounted while a collection is probed or closed so the collection exists before\n * display. Renders nothing.\n */\nexport function StaticCollectionProbeItem(props: {\n id: Key;\n textValue?: string;\n isDisabled?: boolean | (() => boolean);\n \"aria-label\"?: string;\n children?: unknown;\n}): JSX.Element {\n useStaticItemRegistration(props);\n return <></>;\n}\n\nexport interface StaticCollectionBuilderProps {\n content?: JSX.Element;\n children: (items: Accessor<StaticCollectionItem[]>) => JSX.Element;\n}\n\nexport function CollectionBuilder<T>(\n props: AriaCollectionBuilderProps<T> | StaticCollectionBuilderProps,\n): unknown {\n if (\"content\" in props && typeof props.children === \"function\") {\n const { items, context } = createStaticCollectionState();\n return (\n <StaticCollectionContext value={context}>\n <StaticCollectionProbeContext value={true}>{props.content}</StaticCollectionProbeContext>\n {(props.children as (items: Accessor<StaticCollectionItem[]>) => JSX.Element)(items)}\n </StaticCollectionContext>\n );\n }\n return AriaCollectionBuilder(props as AriaCollectionBuilderProps<T>);\n}\n\nexport function Collection<T>(props: AriaCollectionProps<T>): unknown {\n return AriaCollection(props);\n}\n\nexport { createLeafComponent, createBranchComponent };\n\n/**\n * RAC Collection renders `before` + item for every item, and `after` only when\n * the next item in the same level is null (`renderAfterDropIndicators`). The\n * `\"on\"` position is not a collection-level slot. Index-based hosts (ListBox,\n * GridList, Menu, Table) use this helper so they do not fork the geometry.\n */\nexport function renderCollectionDropSlots(options: {\n index: number;\n lastIndex: number;\n renderDropIndicator?: (\n index: number,\n position: \"before\" | \"after\" | \"on\",\n ) => JSX.Element | undefined;\n children: JSX.Element;\n}): JSX.Element {\n return (\n <>\n {options.renderDropIndicator?.(options.index, \"before\")}\n {options.children}\n {options.index === options.lastIndex\n ? options.renderDropIndicator?.(options.index, \"after\")\n : null}\n </>\n );\n}\n\n/**\n * A semantic section wrapper for grouped collection content.\n */\nexport function Section(props: SectionProps): JSX.Element {\n const sectionContext = useContext(SectionContext);\n if (sectionContext) {\n if (isDevEnv()) {\n console.warn(`<Section> is deprecated. Please use <${sectionContext.name}> instead.`);\n }\n return sectionContext.render(props, \"solidaria-Section\");\n }\n\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\", \"ref\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Section\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n ref={(el) => assignRef(local.ref, el)}\n {...filteredDomProps()}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-section\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A header/title primitive for collection sections.\n */\nexport function Header(props: HeaderProps): JSX.Element {\n const probe = useContext(StaticCollectionProbeContext);\n const [merged, ref] = useContextProps(props, props.ref, HeaderContext);\n const [local, domProps] = splitProps(merged, [\n \"children\",\n \"class\",\n \"style\",\n \"slot\",\n \"ref\",\n \"role\",\n ]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Header\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n // The registration copy of a static select must not paint a heading.\n if (probe) return <></>;\n\n return (\n <div\n ref={ref}\n {...filteredDomProps()}\n role={local.role ?? \"heading\"}\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-header\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n\n/**\n * A grouping primitive for section item containers.\n */\nexport function Group(props: GroupProps): JSX.Element {\n const [local, domProps] = splitProps(props, [\"children\", \"class\", \"style\", \"slot\"]);\n\n const renderValues = createMemo<CollectionPrimitiveRenderProps>(() => ({\n hasChildren: local.children != null,\n }));\n\n const renderProps = useRenderProps(\n {\n get children() {\n return local.children;\n },\n get class() {\n return local.class;\n },\n get style() {\n return local.style;\n },\n defaultClassName: \"solidaria-Group\",\n },\n renderValues,\n );\n\n const filteredDomProps = createMemo(() => filterDOMProps(domProps, { global: true }));\n\n return (\n <div\n {...filteredDomProps()}\n role=\"group\"\n class={renderProps.class()}\n style={renderProps.style()}\n slot={local.slot}\n data-group\n >\n {renderProps.renderChildren()}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0GA,SAASA,YAAa,KAAiB,IAAa;CAClD,IAAI,CAAC,KAAK;CACV,IAAI,OAAO,QAAQ,YAAY,IAAI,EAAE;MAChC,IAAI,UAAU;AACrB;AAyJA,MAAa,4BACX,cAA8D,IAAI;AACpE,MAAa,8BAA8B;AAC3C,MAAa,iBAAiB,cAA0C,IAAI;AAC5E,MAAa,eAAe,cAA0C,IAAI;AAC1E,MAAa,gBAAgB,cAAyD,IAAI;AAC1F,MAAa,iBAAiB,cAA2C,IAAI;AAE7E,SAAgB,wBAAqE;CACnF,OAAO,WAAW,yBAAyB;AAC7C;;AAGA,SAAgB,oBAAuE;CAErF,OADiB,sBACH,CAAC,EAAE,kBAAkB,0BAA0B;AAC/D;AAEA,SAAgB,o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GACzB,OAAO,YAAY,MAAM,GACzB,MAAM,MAAM,MACZ,YACD;OACE,YAAY,eAAe,EAAE;IAChC,EAAE;AAEN;;;;AAKA,SAAgB,MAAM,OAAgC;CACpD,MAAM,CAAC,OAAO,YAAY,WAAW,OAAO;EAAC;EAAY;EAAS;EAAS;CAAM,CAAC;CAElF,MAAM,eAAe,kBAAkD,EACrE,aAAa,MAAM,YAAY,KACjC,EAAE;CAEF,MAAM,cAAc,eAClB;EACE,IAAI,WAAW;GACb,OAAO,MAAM;EACf;EACA,IAAI,QAAQ;GACV,OAAO,MAAM;EACf;EACA,IAAI,QAAQ;GACV,OAAO,MAAM;EACf;EACA,kBAAkB;CACpB,GACA,YACF;CAEA,MAAM,mBAAmB,iBAAiB,eAAe,UAAU,EAAE,QAAQ,KAAK,CAAC,CAAC;CAEpF,OACE,CAAC,IACC,IAAI,iBAAiB,CAAC,EACtB,aACA,OAAO,YAAY,MAAM,GACzB,OAAO,YAAY,MAAM,GACzB,MAAM,MAAM,MACZ,WACD;OACE,YAAY,eAAe,EAAE;IAChC,EAAE;AAEN"}
@@ -1,14 +1 @@
1
- /*
2
- * Copyright 2024 Adobe. All rights reserved.
3
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- * you may not use this file except in compliance with the License. You may obtain a copy
5
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
6
- *
7
- * Unless required by applicable law or agreed to in writing, software distributed under
8
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- * OF ANY KIND, either express or implied. See the License for the specific language
10
- * governing permissions and limitations under the License.
11
- */
12
- // Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/ColorThumb.tsx
13
- import { ColorSliderThumb } from "./ColorSlider.js";
14
- export { ColorSliderThumb as ColorThumb };
1
+ export { ColorSliderThumb as ColorThumb } from "./ColorSlider.js";
@@ -1,14 +1 @@
1
- /*
2
- * Copyright 2024 Adobe. All rights reserved.
3
- * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4
- * you may not use this file except in compliance with the License. You may obtain a copy
5
- * of the License at http://www.apache.org/licenses/LICENSE-2.0
6
- *
7
- * Unless required by applicable law or agreed to in writing, software distributed under
8
- * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9
- * OF ANY KIND, either express or implied. See the License for the specific language
10
- * governing permissions and limitations under the License.
11
- */
12
- // Ported to SolidJS for Proyecto Viviana; based on packages/react-aria-components/src/ColorThumb.tsx
13
- import { ColorSliderThumb } from "./ColorSlider.jsx";
14
- export { ColorSliderThumb as ColorThumb };
1
+ export { ColorSliderThumb as ColorThumb } from "./ColorSlider.jsx";
package/dist/DateField.js CHANGED
@@ -1,2 +1 @@
1
- import { a as DateFieldLabel, c as DateSegment, i as DateFieldErrorMessage, l as useDateFieldContext, n as DateFieldContext, o as DateFieldStateContext, r as DateFieldDescription, s as DateInput, t as DateField } from "./DateField2.js";
2
- export { DateField, DateFieldContext, DateFieldDescription, DateFieldErrorMessage, DateFieldLabel, DateFieldStateContext, DateInput, DateSegment, useDateFieldContext };
1
+ export { t as DateField, n as DateFieldContext, r as DateFieldDescription, i as DateFieldErrorMessage, a as DateFieldLabel, o as DateFieldStateContext, s as DateInput, c as DateSegment, l as useDateFieldContext } from "./DateField2.js";
@@ -1,2 +1 @@
1
- import { a as DateFieldLabel, c as DateSegment, i as DateFieldErrorMessage, l as useDateFieldContext, n as DateFieldContext, o as DateFieldStateContext, r as DateFieldDescription, s as DateInput, t as DateField } from "./DateField2.jsx";
2
- export { DateField, DateFieldContext, DateFieldDescription, DateFieldErrorMessage, DateFieldLabel, DateFieldStateContext, DateInput, DateSegment, useDateFieldContext };
1
+ export { t as DateField, n as DateFieldContext, r as DateFieldDescription, i as DateFieldErrorMessage, a as DateFieldLabel, o as DateFieldStateContext, s as DateInput, c as DateSegment, l as useDateFieldContext } from "./DateField2.jsx";