{"version":3,"file":"forty-cdk-listbox.mjs","sources":["../../../projects/forty-cdk/listbox/src/listbox-context.ts","../../../projects/forty-cdk/listbox/src/listbox-defaults.ts","../../../projects/forty-cdk/listbox/src/listbox-virtualized-navigator.ts","../../../projects/forty-cdk/listbox/src/listbox.ts","../../../projects/forty-cdk/listbox/src/listbox-option.ts","../../../projects/forty-cdk/listbox/src/listbox-option-indicator.ts","../../../projects/forty-cdk/listbox/src/listbox-group.ts","../../../projects/forty-cdk/listbox/src/listbox-group-label.ts","../../../projects/forty-cdk/listbox/src/listbox-reorder.ts","../../../projects/forty-cdk/listbox/src/listbox-host-directive.ts","../../../projects/forty-cdk/listbox/src/forty-cdk-listbox.ts"],"sourcesContent":["import { inject, InjectionToken, type Signal } from '@angular/core';\n\nimport {\n  assertRootContext,\n  type ListNavigationAction,\n  orphanContextError,\n  type WritingDirection,\n} from 'forty-cdk/core';\n\nexport interface ForListboxOptionHandle<T = unknown> {\n  readonly host: HTMLElement;\n  readonly value: Signal<T>;\n  readonly disabled: Signal<boolean>;\n  readonly id: Signal<string>;\n  readonly posInSet: Signal<number | null>;\n}\n\n/**\n * Coordination contract owned by `ForListbox`. Each `ForListboxOption`\n * registers a handle on init so the group can react to disabled changes,\n * compute the first-enabled tab entry, and run typeahead matching.\n *\n * Generic over the option value type `T` (default `string` at the public\n * root). When a consumer binds object items the directive infers `T` from\n * `[(value)]` and `[forListboxOption][value]`; object identity is resolved\n * by the consumer-supplied `compareWith` and the form's hidden inputs\n * serialize via `itemToFormValue`. Option text labels are still read from the\n * rendered `textContent`.\n */\nexport interface ForListboxContext<T = unknown> {\n  readonly value: Signal<readonly T[]>;\n  readonly multiple: Signal<boolean>;\n  /**\n   * The listbox's effective disabled — its own `disabled` input OR'd with a\n   * surrounding disabled `[forFieldset]`. Each `ForListboxOption` ORs this into\n   * its own `effectiveDisabled`, so a disabled listbox (or fieldset) disables\n   * every option.\n   */\n  readonly effectiveDisabled: Signal<boolean>;\n  readonly readonly: Signal<boolean>;\n  readonly orientation: Signal<'horizontal' | 'vertical'>;\n  readonly dir: Signal<WritingDirection>;\n  readonly selectionFollowsFocus: Signal<boolean>;\n\n  /** Compare two items for equality. Defaults to `===`; overridden for object values. */\n  readonly compareWith: Signal<(a: T, b: T) => boolean>;\n  /** Serialize an item for the hidden input's `value` attribute. Defaults to `String(item)`. */\n  readonly itemToFormValue: Signal<(item: T) => string>;\n\n  /**\n   * Full source length when virtualizing, `undefined` in the roving-tabindex\n   * path. Drives the option's `aria-setsize` / `aria-posinset` and the\n   * option's focus-model branch.\n   */\n  readonly totalCount: Signal<number | undefined>;\n  /**\n   * The active option's `id` when using the activedescendant focus model,\n   * `null` in the roving-tabindex path. Moved by keyboard navigation and by\n   * hover alike. Options read this to compute `data-highlighted`.\n   */\n  readonly activeDescendantId: Signal<string | null>;\n\n  isSelected(value: T): boolean;\n  /** Toggle in multi-mode, replace in single-mode. No-op on disabled / readonly. */\n  activate(value: T): void;\n  /** Move focus from `currentOption` according to `action`. May also select if `selectionFollowsFocus` is on. */\n  navigate(currentOption: HTMLElement, action: ListNavigationAction): void;\n  /**\n   * Multi-mode only. Move focus to the next/prev enabled option AND toggle its\n   * selected state — APG \"Shift+ArrowDown / Shift+ArrowUp toggles selection\n   * while moving focus\". No-op in single mode, on disabled, or when no enabled\n   * neighbor exists. On `readonly` the focus still moves (matching\n   * {@link navigate}); only the selection mutation is blocked.\n   */\n  extendByArrow(currentOption: HTMLElement, action: 'next' | 'prev'): void;\n  /**\n   * Multi-mode only. APG \"Shift+Space\": select every enabled option from the\n   * anchor (set on the most recent unmodified activation) up to and including\n   * `currentOption`. Existing selection outside the range is preserved. No-op\n   * in single mode or when the listbox is disabled / readonly.\n   */\n  selectRangeToFocused(currentOption: HTMLElement): void;\n  /**\n   * Multi-mode only. APG \"Ctrl/Cmd+A\": select every enabled option. If every\n   * enabled option is already selected, clears the selection (toggle).\n   */\n  selectAll(): void;\n  /**\n   * Multi-mode only. APG \"Ctrl+Shift+Home / Ctrl+Shift+End\": select every\n   * enabled option from `currentOption` (inclusive) to the first / last\n   * enabled option, and move focus to that edge.\n   */\n  selectFromCurrentToEdge(currentOption: HTMLElement, edge: 'first' | 'last'): void;\n  /**\n   * Forward a keydown to the typeahead helper. If the key is a printable\n   * character, finds the first matching option and focuses it; returns true\n   * to indicate the event was consumed.\n   */\n  handleTypeahead(event: KeyboardEvent): boolean;\n  /**\n   * Pre-focus tab-stop policy: with at least one selection, the first selected\n   * enabled option is the sole entry point; otherwise the first enabled option\n   * in DOM order. Guarantees a single `tabindex=\"0\"` before roving takes over.\n   */\n  isFirstFocusableOption(el: HTMLElement): boolean;\n  /**\n   * `true` when `el` is the highlighted option in the roving-tabindex path\n   * (reflected as `data-highlighted`): the one the pointer is over, else the\n   * roving active option.\n   */\n  isOptionHighlighted(el: HTMLElement): boolean;\n  /**\n   * Roving-tabindex value for `el`: `0` for the active option once roving has\n   * taken over, `-1` otherwise. Returns `null` before any option is active so\n   * the caller can fall back to {@link isFirstFocusableOption}.\n   */\n  optionTabindex(el: HTMLElement): -1 | 0 | null;\n  /**\n   * Mark `el` as the roving-tabindex active option (called on option focus).\n   * Also drops any pointer highlight, so the keyboard channel owns the highlight\n   * again from the move that focused `el`.\n   */\n  setActiveOption(el: HTMLElement): void;\n\n  /**\n   * All registered options, in DOM (rendered) order. Exposed for container-level\n   * coordinators that compose onto the listbox — e.g. `ForListboxReorder` reads the\n   * ordered hosts to resolve drop targets and emit reorder indices — without each\n   * option needing a `[forDraggable]` that would fight the listbox's own roving tabindex.\n   */\n  readonly options: Signal<readonly ForListboxOptionHandle<T>[]>;\n\n  /**\n   * Called by an option on click. In the virtualized path, moves\n   * `aria-activedescendant` to that option and returns DOM focus to the\n   * container. A no-op in the roving-tabindex path.\n   */\n  notifyOptionClick(optionId: string): void;\n\n  registerOption(handle: ForListboxOptionHandle<T>): void;\n  unregisterOption(handle: ForListboxOptionHandle<T>): void;\n}\n\n/**\n * The listbox's pointer channel: the one call `[forListboxOption]` makes so the\n * option under the cursor takes the highlight.\n *\n * **Not** part of {@link ForListboxContext} and never exported from\n * `public-api.ts` — a consumer styles the pointed-at option off\n * `data-highlighted`, never by reporting a hover into the root.\n */\nexport interface ListboxPieceContext {\n  /**\n   * Reported by `[forListboxOption]` on `pointermove` so the highlight follows\n   * the pointer. Never moves DOM focus, never commits a selection (not even\n   * under `selectionFollowsFocus`), and never touches the range anchor; a move\n   * arriving inside the pointer-suppression window a programmatic scroll opened\n   * is ignored, so a synthetic `pointermove` from the scroll cannot hijack the\n   * keyboard's highlight.\n   *\n   * @param host The hovered option's host element — the roving path's highlight target.\n   * @param id The hovered option's id — the activedescendant path's highlight target.\n   */\n  highlightFromPointer(host: HTMLElement, id: string): void;\n}\n\n/**\n * The listbox's internal coordination surface: everything\n * {@link ForListboxContext} publishes plus the {@link ListboxPieceContext} call.\n *\n * Never exported from `public-api.ts`. It is the type the pieces read\n * {@link FOR_LISTBOX_CONTEXT} at, so a consumer who injects that token gets the\n * read surface while `[forListboxOption]` gets the pointer channel. `ForListbox`\n * declares `highlightFromPointer` TS-`private`, which keeps it out of the\n * emitted `.d.ts` while `useExisting` still satisfies this contract at runtime.\n */\nexport interface ListboxContext<T = unknown> extends ForListboxContext<T>, ListboxPieceContext {}\n\n/**\n * DI token for the listbox's coordination surface, provided by `[forListbox]`.\n *\n * Publicly typed as the read surface {@link ForListboxContext}, which is the whole\n * of what the token promises a consumer. The options read the same token at an\n * internal type that adds the pointer-highlight channel, so a wrapper re-providing\n * it must alias it to the root: `{ provide: FOR_LISTBOX_CONTEXT, useExisting: MyListbox }`,\n * where `MyListbox` extends `ForListbox`. A value that merely satisfies the declared\n * type resolves too, and is rejected in dev mode by the first piece to reach the channel.\n */\nexport const FOR_LISTBOX_CONTEXT = new InjectionToken<ForListboxContext>('FOR_LISTBOX_CONTEXT');\n\nexport function injectListboxContext<T = unknown>(piece: string): ListboxContext<T> {\n  const ctx = inject(FOR_LISTBOX_CONTEXT, { optional: true });\n  if (!ctx) {\n    throw orphanContextError({\n      code: 'FORCDK-LISTBOX-001',\n      piece,\n      root: '[forListbox]',\n      token: 'FOR_LISTBOX_CONTEXT',\n    });\n  }\n  const widened = ctx as unknown as ListboxContext<T>;\n  assertRootContext({\n    entryPoint: 'listbox',\n    token: 'FOR_LISTBOX_CONTEXT',\n    root: '[forListbox]',\n    piece,\n    probe: () => widened.highlightFromPointer,\n  });\n  return widened;\n}\n","import { type Provider } from '@angular/core';\n\nimport { createDefaults } from 'forty-cdk/core';\n\n/**\n * Defaults inherited by descendant listboxes in the surrounding injector\n * scope. Configure with `provideForListboxDefaults` either at the\n * application root or in any component's `providers` array; partial\n * overrides merge with the parent scope.\n */\nexport interface ForListboxDefaults {\n  /**\n   * Single-mode only: when `true`, arrow navigation also selects the\n   * focused option. APG calls this optional and recommends caution —\n   * leave `false` unless the UX truly benefits from selection following\n   * focus.\n   */\n  selectionFollowsFocus: boolean;\n  /**\n   * `[forListboxReorder]` announcement when an option is lifted for reorder.\n   * `index` and `total` are 1-based. Override to localize.\n   */\n  reorderAnnounceLift: (label: string, index: number, total: number) => string;\n  /**\n   * `[forListboxReorder]` announcement when the reorder drop position changes.\n   * `index` and `total` are 1-based. Override to localize.\n   */\n  reorderAnnounceMove: (label: string, index: number, total: number) => string;\n  /**\n   * `[forListboxReorder]` announcement on a committed reorder drop. `index` and\n   * `total` are 1-based. Override to localize.\n   */\n  reorderAnnounceDrop: (label: string, index: number, total: number) => string;\n  /**\n   * `[forListboxReorder]` announcement when a reorder is cancelled. Override to\n   * localize.\n   */\n  reorderAnnounceCancel: (label: string) => string;\n}\n\n/**\n * Library fallback for listbox defaults, read at the root injector when no\n * consumer has called `provideForListboxDefaults`. Exported for the shared defaults\n * contract spec; not re-exported from the primitive's public entry.\n *\n * The reorder formatters mirror the lift / move / drop / cancel cadence the\n * drag-drop and tree coordinators use, so a consumer hears consistent reorder\n * announcements across primitives. Defining them inside the listbox's own\n * defaults (rather than importing `FOR_DRAG_DROP_DEFAULTS`) keeps\n * `[forListboxReorder]` from pulling in the drag-drop primitive.\n */\nexport const FOR_LISTBOX_FALLBACK_DEFAULTS: ForListboxDefaults = {\n  selectionFollowsFocus: false,\n  reorderAnnounceLift: (label, index, total) => `${label}, lifted. ${index} of ${total}.`,\n  reorderAnnounceMove: (label, index, total) => `${label}, moved to position ${index} of ${total}.`,\n  reorderAnnounceDrop: (label, index, total) =>\n    `${label}, dropped at position ${index} of ${total}.`,\n  reorderAnnounceCancel: (label) => `${label}, movement cancelled.`,\n};\n\nconst { token, provideDefaults } = createDefaults<ForListboxDefaults>(\n  'FOR_LISTBOX_DEFAULTS',\n  FOR_LISTBOX_FALLBACK_DEFAULTS,\n);\n\n/** Token holding the resolved listbox defaults for the current scope. */\nexport const FOR_LISTBOX_DEFAULTS = token;\n\n/**\n * Configures forty-cdk listbox defaults for this injector scope. Partial\n * overrides inherit unspecified keys from the parent scope (or library\n * defaults at the root).\n */\nexport function provideForListboxDefaults(defaults: Partial<ForListboxDefaults> = {}): Provider[] {\n  return provideDefaults(defaults);\n}\n","import { VirtualizedNavigator, type VirtualizedNavigatorDeps } from 'forty-cdk/core';\nimport type { ForListboxOptionHandle } from './listbox-context';\n\n/**\n * Position-snapshot entry for `ForListbox`. The listbox never reads option\n * values off the snapshot, so the engine's minimal shape is the whole entry.\n */\nexport interface ListboxPositionEntry {\n  /** Stable option host id — the activedescendant target. */\n  readonly id: string;\n  /** Whether the option is disabled, so navigation skips over it. */\n  readonly disabled: boolean;\n}\n\n/** The shared navigation engine as `ForListbox` parameterises it. */\nexport type ListboxVirtualizedNavigator<T> = VirtualizedNavigator<\n  ForListboxOptionHandle<T>,\n  ListboxPositionEntry\n>;\n\n/**\n * Wire the shared `forty-cdk/core` navigation engine to the listbox option\n * handle. The snapshot needs only the id + disabled flag, so no unwritten-binding\n * guard is required on `readEntry`. Scroll-into-view is routed through\n * `scrollActiveIntoView` so the root's pointer-suppression window opens first — a\n * synthetic `pointermove` from the scroll must not hijack the highlight.\n *\n * Internal — not re-exported from `listbox/index.ts` or `public-api.ts`.\n */\nexport function createListboxVirtualizedNavigator<T>(\n  deps: VirtualizedNavigatorDeps<ForListboxOptionHandle<T>>,\n  scrollActiveIntoView: (host: HTMLElement) => void,\n): ListboxVirtualizedNavigator<T> {\n  return new VirtualizedNavigator(deps, {\n    posOf: (o) => o.posInSet(),\n    idOf: (o) => o.id(),\n    hostOf: (o) => o.host,\n    isDisabled: (o) => o.disabled(),\n    readEntry: (o) => ({ id: o.id(), disabled: o.disabled() }),\n    scrollIntoView: (host) => scrollActiveIntoView(host),\n  });\n}\n","import {\n  booleanAttribute,\n  computed,\n  Directive,\n  effect,\n  ElementRef,\n  inject,\n  input,\n  model,\n  numberAttribute,\n  output,\n  signal,\n} from '@angular/core';\nimport type { FormValueControl } from '@angular/forms/signals';\n\nimport {\n  accessibleTextContent,\n  Collection,\n  createPointerSuppression,\n  firstEnabledHost,\n  FormUiControlBase,\n  injectHiddenInput,\n  isRangeSelectShortcut,\n  type ListNavigationAction,\n  resolveListNavigation,\n  resolveListTypeahead,\n  runVirtualizedNavigatorBridge,\n  throwUnsupportedVirtualizedRangeSelect,\n  throwUnsupportedVirtualizedSelectionFollowsFocus,\n  type WritingDirection,\n  nextEnabledHandle,\n  RangeSelectionEngine,\n  RovingTabindex,\n  defaultItemToFormValue,\n  isInArray,\n  singleSelected,\n  toggleInArray,\n  injectTextDirection,\n  injectTypeahead,\n  isUnset,\n  hostAriaLabel,\n} from 'forty-cdk/core';\nimport {\n  FOR_LISTBOX_CONTEXT,\n  type ForListboxContext,\n  type ForListboxOptionHandle,\n} from './listbox-context';\nimport { FOR_LISTBOX_DEFAULTS } from './listbox-defaults';\nimport {\n  createListboxVirtualizedNavigator,\n  type ListboxVirtualizedNavigator,\n} from './listbox-virtualized-navigator';\n\n/**\n * Headless implementation of the [WAI-ARIA Listbox pattern](https://www.w3.org/WAI/ARIA/apg/patterns/listbox/).\n * Implements `FormValueControl<readonly T[]>` from\n * `@angular/forms/signals` for `[formField]` auto-wiring.\n *\n * Generic over the option value type `T` (default `string`). When the\n * consumer binds object items the directive infers `T` from `[(value)]` and\n * `[forListboxOption][value]`; object identity is resolved by the\n * consumer-supplied `[compareWith]` and the hidden inputs serialize\n * via `[itemToFormValue]`. Option display text is read from the rendered\n * `textContent`, so no separate label function is needed.\n *\n * Selection is always modeled as `readonly T[]`:\n * - In single mode (`multiple=false`, default), the array has 0 or 1 element.\n * - In multi mode, any number of items can be selected.\n *\n * Single-select consumers can read the sole value through the\n * {@link ForListbox.selected} convenience accessor instead of unwrapping the\n * array.\n *\n * Keyboard supports the full APG-recommended model: arrows + Home/End for\n * focus movement, Space/Enter (via native `<button>` activation) to select\n * or toggle, typeahead, plus multi-select range modifiers (Shift+Arrow,\n * Shift+Space, Ctrl/Cmd+A, Ctrl+Shift+Home/End).\n */\n@Directive({\n  selector: '[forListbox]',\n  exportAs: 'forListbox',\n  host: {\n    role: 'listbox',\n    '[attr.aria-label]': 'resolvedAriaLabel()',\n    '[attr.aria-orientation]': 'orientation()',\n    '[attr.aria-multiselectable]': 'multiple() ? \"true\" : null',\n    '[attr.aria-disabled]': 'effectiveDisabled() ? \"true\" : null',\n    '[attr.aria-readonly]': 'readonly() ? \"true\" : null',\n    '[attr.aria-required]': 'required() ? \"true\" : null',\n    '[attr.aria-invalid]': 'invalid() ? \"true\" : null',\n    '[attr.aria-busy]': 'pending() ? \"true\" : null',\n    '[attr.aria-activedescendant]': 'activeDescendantId()',\n    '[attr.tabindex]': 'hostTabindex()',\n    '[attr.data-orientation]': 'orientation()',\n    '[attr.data-disabled]': 'effectiveDisabled() ? \"\" : null',\n    '[attr.data-readonly]': 'readonly() ? \"\" : null',\n    '[attr.dir]': 'dir()',\n    '(keydown)': 'onHostKeyDown($event)',\n    '(focusin)': 'onHostFocusIn()',\n    '(focusout)': 'onFocusOut($event)',\n    '(pointerleave)': 'onPointerLeave()',\n  },\n  providers: [{ provide: FOR_LISTBOX_CONTEXT, useExisting: ForListbox }],\n})\nexport class ForListbox<T = string>\n  extends FormUiControlBase\n  implements FormValueControl<readonly T[]>, ForListboxContext<T>\n{\n  readonly #host = inject<ElementRef<HTMLElement>>(ElementRef);\n  readonly #defaults = inject(FOR_LISTBOX_DEFAULTS);\n\n  /**\n   * Two-way bindable. Selected option values. Single-mode keeps 0 or 1\n   * element. The `model()` change emitter (`(valueChange)`) fires only on\n   * internal selection changes (option activation or `selectionFollowsFocus`\n   * nav), never on consumer writes via `[(value)]` — observe transitions\n   * without binding back.\n   */\n  readonly value = model<readonly T[]>([]);\n\n  /**\n   * Compare two items for equality. Defaults to `===`, which is the\n   * correct identity for primitive `T` (e.g. strings, numbers). Override\n   * when binding object items so the directive can locate selected entries\n   * by id (or any other stable key) instead of by reference:\n   * `[compareWith]=\"(a, b) => a.id === b.id\"`.\n   */\n  readonly compareWith = input<(a: T, b: T) => boolean>((a, b) => a === b);\n\n  /**\n   * Serialize an item for the hidden input that participates in native\n   * form submission. Defaults to identity for strings and to\n   * `JSON.stringify` for non-string items so the primitive works out of\n   * the box round-tripping objects. Override to emit a specific wire\n   * format — typically a per-item id — when the backend expects that:\n   * `[itemToFormValue]=\"(it) => it.id\"`.\n   */\n  readonly itemToFormValue = input<(item: T) => string>(defaultItemToFormValue);\n\n  /**\n   * Read-only single-select convenience view of {@link value}. Returns the\n   * sole value when exactly one is selected (regardless of `multiple`),\n   * otherwise `null` (zero, or 2+ selected). Lets single-select consumers\n   * read `selected()` instead of unwrapping `value()[0]`. The array-backed\n   * `value` model remains the source of truth and the `FormValueControl`\n   * contract; this is a derived accessor.\n   */\n  readonly selected = singleSelected(this.value);\n\n  /**\n   * When true, multiple options can be selected. Single mode (default) keeps\n   * the value array at 0 or 1 element.\n   *\n   * Multi-select range keyboard (Shift+Arrow, Shift+Space, Ctrl/Cmd+A,\n   * Ctrl+Shift+Home/End) is not supported together with virtualization\n   * (`totalCount` set): range selection needs the full set of enabled options\n   * across the range, which is unavailable while the list is partially\n   * unmounted. Pressing one of those combinations on a virtualized multi-select\n   * listbox throws in dev mode. Toggle options individually with Enter, Space,\n   * or click, or drop `totalCount` to use the non-virtualized roving-tabindex\n   * listbox.\n   */\n  readonly multiple = input(false, { transform: booleanAttribute });\n\n  /**\n   * Manual `aria-label` for the listbox. Use this when no visible label\n   * element exists; otherwise prefer pointing `aria-labelledby` at one. A\n   * `null` (default) or empty value emits no attribute.\n   */\n  readonly ariaLabel = input<string | null>(null);\n\n  protected readonly resolvedAriaLabel = hostAriaLabel(() => this.ariaLabel() || null);\n\n  /**\n   * Axis the arrow keys navigate. Reflected as `data-orientation`.\n   */\n  readonly orientation = input<'vertical' | 'horizontal'>('vertical');\n\n  /**\n   * When true (default), arrow navigation wraps at the ends — moving past the\n   * last option focuses the first and vice versa. Set `false` to stop at the\n   * boundaries. Mirrors the `loop` input on `ForSelect`, `ForToggleGroup` and\n   * `ForCombobox`. Range extension (Shift+Arrow) never wraps regardless of\n   * this input, per the APG.\n   */\n  readonly loop = input(true, { transform: booleanAttribute });\n\n  /**\n   * Total number of items in the source data. When set, enables the\n   * virtualized activedescendant focus model and populates `aria-setsize`\n   * on each rendered option. Leave unset (default `undefined`) for the\n   * standard roving-tabindex model.\n   */\n  readonly totalCount = input(undefined, {\n    transform: (v: unknown): number | undefined => (v == null ? undefined : numberAttribute(v)),\n  });\n\n  /**\n   * Inclusive-exclusive `[start, end)` index range of the currently rendered\n   * options. The virtualizer provides this; the listbox uses it to decide\n   * whether a navigation target is in the visible window.\n   */\n  readonly visibleRange = input<readonly [number, number] | undefined>(undefined);\n\n  /**\n   * Optional virtualized-only seam that tells the directive the source dataset\n   * changed **without** a `totalCount` transition — a same-length re-sort or\n   * refresh (e.g. sorting a 1000-row list). Bind any value that changes on such\n   * a refresh (a version counter, the array reference, a sort-key string); when\n   * it changes the position snapshot rebuilds from empty so navigation never\n   * resolves against a stale off-window entry. Leave unset (default) when the\n   * dataset only ever changes length. Equivalent to calling\n   * {@link ForListbox.invalidateSnapshot} imperatively.\n   */\n  readonly dataVersion = input<unknown>();\n\n  /**\n   * Emitted when keyboard navigation reaches an option outside the rendered\n   * window. The consumer passes this index to `injectVirtualizer`'s\n   * `scrollToIndex` so the correct option mounts.\n   */\n  readonly scrollToIndex = output<number>();\n\n  /**\n   * Writing direction. When unset (default `null`), the inherited ambient\n   * direction is resolved from the nearest ancestor carrying a `dir` attribute\n   * (or `<html dir>`), defaulting to `'ltr'`. An explicit `[dir]` always wins.\n   * The resolved value is reflected to the host `dir` attribute and swaps\n   * ArrowLeft / ArrowRight semantics in RTL for horizontal listboxes.\n   */\n  readonly _dirInput = input<WritingDirection | null>(null, { alias: 'dir' });\n  readonly dir = injectTextDirection(this._dirInput);\n\n  /**\n   * Single-mode only: when true, arrow nav also selects the focused option.\n   * APG calls this optional and recommends caution — leave off unless your\n   * UX truly benefits from selection following focus. Default `false`.\n   * The default is read from `provideForListboxDefaults` for the surrounding\n   * scope.\n   *\n   * Not supported together with virtualization (`totalCount` set): the\n   * virtualized `aria-activedescendant` path resolves off-window navigation\n   * targets asynchronously, so selection cannot follow focus there without\n   * deriving the committed value from a render side effect. Keyboard-navigating\n   * a virtualized listbox with it set throws in dev mode, from the move the\n   * combination degrades.\n   */\n  readonly selectionFollowsFocus = input(this.#defaults.selectionFollowsFocus, {\n    transform: booleanAttribute,\n  });\n\n  readonly roving = new RovingTabindex(() => this.#options.items());\n  readonly #typeahead = injectTypeahead();\n\n  readonly #options = new Collection<ForListboxOptionHandle<T>>();\n\n  /**\n   * All registered options in DOM (rendered) order. Part of the public\n   * {@link ForListboxContext} surface so container-level coordinators (e.g.\n   * `ForListboxReorder`) can read the ordered hosts without each option owning a\n   * `[forDraggable]` that would fight the listbox's roving tabindex.\n   */\n  readonly options = this.#options.items;\n\n  readonly #firstEnabledHost = computed(() => firstEnabledHost(this.#options.items()));\n\n  readonly #firstSelectedHost = computed<HTMLElement | null>(() => {\n    const selected = this.value();\n    if (selected.length === 0) {\n      return null;\n    }\n    const equals = this.compareWith();\n    for (const option of this.#options.items()) {\n      if (option.disabled()) {\n        continue;\n      }\n      const value = option.value();\n      if (isUnset(value)) {\n        continue;\n      }\n      if (selected.some((v) => equals(v, value))) {\n        return option.host;\n      }\n    }\n    return null;\n  });\n\n  readonly #virtualized = computed(() => this.totalCount() !== undefined);\n\n  readonly #activeId = signal<string | null>(null);\n\n  readonly #pointerSuppression = createPointerSuppression();\n\n  readonly #pointerHost = signal<HTMLElement | null>(null);\n\n  /**\n   * The pointed-at option's host in the roving path, self-healed on read: a host\n   * that has left the registered set or become disabled is discounted, so the\n   * roving active option reclaims the highlight. The registered set is read only\n   * while a host is stored, keeping the mount's highlight channel independent of\n   * the option list.\n   */\n  readonly #pointerHighlighted = computed<HTMLElement | null>(() => {\n    const host = this.#pointerHost();\n    if (host === null) {\n      return null;\n    }\n    const handle = this.#options.items().find((option) => option.host === host);\n    return handle && !handle.disabled() ? host : null;\n  });\n\n  /**\n   * The active option's `id` when using the activedescendant focus model,\n   * `null` in the roving-tabindex path. Moved by keyboard navigation and by\n   * hover alike, so the highlight and the option `Enter` activates never\n   * disagree. The host reflects this as `aria-activedescendant`; options read it\n   * to compute `data-highlighted`.\n   */\n  readonly activeDescendantId = computed<string | null>(() =>\n    this.#virtualized() ? this.#activeId() : null,\n  );\n\n  /**\n   * Tabindex for the listbox host. In the virtualized path the host is always\n   * the single tab stop. In the roving path the host carries `tabindex=\"0\"`\n   * only when no option qualifies — an empty listbox or one whose options are\n   * all disabled — so the control is still reachable. A disabled listbox is\n   * never tabbable.\n   */\n  protected readonly hostTabindex = computed<'0' | null>(() => {\n    if (this.effectiveDisabled()) {\n      return null;\n    }\n    if (this.#virtualized()) {\n      return '0';\n    }\n    const hasRovingEntry = this.#firstSelectedHost() !== null || this.#firstEnabledHost() !== null;\n    return hasRovingEntry ? null : '0';\n  });\n\n  /**\n   * Shared APG range-selection state machine: owns the range anchor and the\n   * Shift+Arrow / Shift+Space / Ctrl+A / Ctrl+Shift+Home/End actions plus the\n   * single-mode idempotent select guard. The value-specific `activate` and the\n   * virtualized activedescendant path stay in this root; the range methods\n   * one-line delegate here.\n   */\n  readonly #rangeEngine = new RangeSelectionEngine<T, ForListboxOptionHandle<T>>({\n    options: this.#options.items,\n    value: this.value,\n    setValue: (v) => this.value.set(v),\n    compareWith: this.compareWith,\n    multiple: this.multiple,\n    effectiveDisabled: this.effectiveDisabled,\n    readonly: this.readonly,\n  });\n\n  #navigator: ListboxVirtualizedNavigator<T> | null = null;\n\n  #requireNavigator(): ListboxVirtualizedNavigator<T> {\n    return (this.#navigator ??= createListboxVirtualizedNavigator<T>(\n      {\n        items: this.#options.items,\n        totalCount: this.totalCount,\n        visibleRange: this.visibleRange,\n        loop: this.loop,\n        getActiveId: () => this.#activeId(),\n        setActiveId: (id) => this.#activeId.set(id),\n        emitScrollToIndex: (idx) => this.scrollToIndex.emit(idx),\n        dataVersion: this.dataVersion,\n      },\n      (host) => this.#scrollActiveIntoView(host),\n    ));\n  }\n\n  /**\n   * Scroll an option into view with the pointer-suppression window open, so the\n   * synthetic `pointermove` the scroll fires when a different option slides under\n   * a stationary cursor cannot hand the highlight to it.\n   */\n  #scrollActiveIntoView(host: HTMLElement): void {\n    this.#pointerSuppression.suppress();\n    host.scrollIntoView?.({ block: 'nearest' });\n  }\n\n  /**\n   * Force the virtualized position snapshot to rebuild from empty on the next\n   * fold, discarding stale off-window entries. Call after a same-length dataset\n   * refresh (a re-sort / reload that keeps `totalCount` unchanged) when you\n   * cannot express the change through the reactive `[dataVersion]` input. No-op\n   * when the listbox is not virtualized (`totalCount` unset).\n   */\n  invalidateSnapshot(): void {\n    if (!this.#virtualized()) {\n      return;\n    }\n    this.#requireNavigator().invalidateSnapshot();\n  }\n\n  constructor() {\n    super();\n    injectHiddenInput<T>({\n      name: this.name,\n      values: this.value,\n      serialize: (item) => this.itemToFormValue()(item),\n      disabled: this.effectiveDisabled,\n    });\n    // @sanctioned-pull(navigator-position-map): the rendered window is transient,\n    // so a window nothing reads during is lost to the lazy fold.\n    effect(() => {\n      runVirtualizedNavigatorBridge({\n        items: this.#options.items,\n        virtualized: this.#virtualized,\n        requireNavigator: () => this.#requireNavigator(),\n      });\n    });\n  }\n\n  /**\n   * Move focus into the listbox, implementing `FormValueControl.focus` from\n   * `@angular/forms/signals`. Targets the host when it is the tab stop (the\n   * virtualized activedescendant model, or an empty / all-disabled roving\n   * listbox); otherwise the first selected option, else the first enabled one —\n   * mirroring the roving entry point. Without this override Signal Forms'\n   * focus-on-error would focus the bound host even in the roving model, where\n   * the options carry the tab stops. No-op when disabled.\n   */\n  override focus(options?: FocusOptions): void {\n    if (this.effectiveDisabled()) {\n      return;\n    }\n    if (this.hostTabindex() === '0') {\n      this.#host.nativeElement.focus(options);\n      return;\n    }\n    const target = this.#firstSelectedHost() ?? this.#firstEnabledHost();\n    target?.focus(options);\n  }\n\n  isSelected(v: T): boolean {\n    return isInArray(this.value(), v, this.compareWith());\n  }\n\n  activate(v: T): void {\n    if (this.effectiveDisabled() || this.readonly() || isUnset(v)) {\n      return;\n    }\n    if (this.multiple()) {\n      this.value.set(toggleInArray(this.value(), v, this.compareWith()));\n    } else {\n      this.#rangeEngine.selectSingle(v);\n    }\n    this.#rangeEngine.setAnchor(v);\n  }\n\n  extendByArrow(currentOption: HTMLElement, action: 'next' | 'prev'): void {\n    this.#rangeEngine.extendByArrow(currentOption, action);\n  }\n\n  selectRangeToFocused(currentOption: HTMLElement): void {\n    this.#rangeEngine.selectRangeToFocused(currentOption);\n  }\n\n  selectAll(): void {\n    this.#rangeEngine.selectAll();\n  }\n\n  selectFromCurrentToEdge(currentOption: HTMLElement, edge: 'first' | 'last'): void {\n    this.#rangeEngine.selectFromCurrentToEdge(currentOption, edge);\n  }\n\n  navigate(currentOption: HTMLElement, action: ListNavigationAction): void {\n    if (this.effectiveDisabled()) {\n      return;\n    }\n    const target = nextEnabledHandle(this.#options.items(), currentOption, action, {\n      loop: this.loop(),\n    });\n    if (target === null) {\n      return;\n    }\n    this.#pointerSuppression.suppress();\n    target.host.focus();\n    target.host.scrollIntoView?.({ block: 'nearest' });\n    if (!this.multiple() && this.selectionFollowsFocus() && !this.readonly()) {\n      this.#rangeEngine.selectSingle(target.value());\n    }\n  }\n\n  handleTypeahead(event: KeyboardEvent): boolean {\n    const options = this.#options.items();\n    const { handled, match } = resolveListTypeahead(this.#typeahead, event, {\n      items: options,\n      anchorIndex: options.findIndex((o) => o.host === event.target),\n      getText: (o) => accessibleTextContent(o.host),\n      isDisabled: (o) => o.disabled(),\n    });\n    if (!handled) {\n      return false;\n    }\n    if (match) {\n      this.#pointerSuppression.suppress();\n      match.host.focus();\n    }\n    return true;\n  }\n\n  isFirstFocusableOption(el: HTMLElement): boolean {\n    const firstSelected = this.#firstSelectedHost();\n    if (firstSelected) {\n      return firstSelected === el;\n    }\n    return this.#firstEnabledHost() === el;\n  }\n\n  isOptionHighlighted(el: HTMLElement): boolean {\n    const pointed = this.#pointerHighlighted();\n    if (pointed !== null) {\n      return pointed === el;\n    }\n    return this.roving.active() === el;\n  }\n\n  private highlightFromPointer(host: HTMLElement, id: string): void {\n    if (this.#pointerSuppression.isSuppressed()) {\n      return;\n    }\n    if (this.#virtualized()) {\n      this.#activeId.set(id);\n      return;\n    }\n    this.#pointerHost.set(host);\n  }\n\n  optionTabindex(el: HTMLElement): -1 | 0 | null {\n    if (this.#virtualized()) {\n      return -1;\n    }\n    return this.roving.hasActive() ? this.roving.tabindexFor(el) : null;\n  }\n\n  setActiveOption(el: HTMLElement): void {\n    this.#pointerHost.set(null);\n    this.roving.setActive(el);\n  }\n\n  registerOption(handle: ForListboxOptionHandle<T>): void {\n    this.#options.register(handle);\n  }\n\n  notifyOptionClick(optionId: string): void {\n    if (!this.#virtualized()) {\n      return;\n    }\n    this.#activeId.set(optionId);\n    this.#host.nativeElement.focus();\n  }\n\n  unregisterOption(handle: ForListboxOptionHandle<T>): void {\n    this.#options.unregister(handle);\n    this.roving.unregister(handle.host);\n    if (this.#virtualized() && this.#activeId() === handle.id()) {\n      this.#activeId.set(null);\n    }\n  }\n\n  protected onHostKeyDown(event: KeyboardEvent): void {\n    if (!this.#virtualized() || this.effectiveDisabled()) {\n      return;\n    }\n    if (\n      this.multiple() &&\n      isRangeSelectShortcut(event, { orientation: this.orientation(), dir: this.dir() })\n    ) {\n      event.preventDefault();\n      throwUnsupportedVirtualizedRangeSelect({\n        primitive: 'listbox',\n        focusModel: 'roving-tabindex',\n        collection: 'listbox',\n        shortcuts: 'Shift+Arrow, Shift+Space, Ctrl/Cmd+A, Ctrl+Shift+Home/End',\n        alternative: 'Toggle options individually with Enter, Space, or click',\n      });\n      return;\n    }\n    if (event.key === 'Enter' || event.key === ' ') {\n      event.preventDefault();\n      this.#activateActiveDescendant();\n      return;\n    }\n    const action = resolveListNavigation(event, {\n      orientation: this.orientation(),\n      dir: this.dir(),\n      pageKeys: true,\n    });\n    if (action) {\n      event.preventDefault();\n      this.#assertSelectionFollowsFocusSupported();\n      this.#requireNavigator().navigate(action);\n      return;\n    }\n    this.#typeaheadVirtualized(event);\n  }\n\n  /**\n   * Guards the `selectionFollowsFocus` + virtualization invariant at every\n   * keyboard move of the virtualized activedescendant — arrow / Home / End /\n   * Page navigation and a typeahead match alike, since both move focus without\n   * carrying selection. Seeding on `focusin` and a click are not\n   * covered: neither is a navigation the combination degrades.\n   */\n  #assertSelectionFollowsFocusSupported(): void {\n    if (this.#virtualized() && this.selectionFollowsFocus()) {\n      throwUnsupportedVirtualizedSelectionFollowsFocus({\n        primitive: 'listbox',\n        focusModel: 'roving-tabindex',\n        collection: 'listbox',\n      });\n    }\n  }\n\n  #activateActiveDescendant(): void {\n    const id = this.#activeId();\n    if (id === null) {\n      return;\n    }\n    const handle = this.#options.items().find((o) => o.id() === id);\n    if (!handle || handle.disabled()) {\n      return;\n    }\n    this.activate(handle.value());\n  }\n\n  #typeaheadVirtualized(event: KeyboardEvent): void {\n    const options = this.#options.items();\n    const activeId = this.#activeId();\n    const { match } = resolveListTypeahead(this.#typeahead, event, {\n      items: options,\n      anchorIndex: activeId === null ? -1 : options.findIndex((o) => o.id() === activeId),\n      getText: (o) => accessibleTextContent(o.host),\n      isDisabled: (o) => o.disabled(),\n    });\n    if (match) {\n      this.#assertSelectionFollowsFocusSupported();\n      this.#activeId.set(match.id());\n      this.#scrollActiveIntoView(match.host);\n    }\n  }\n\n  protected onHostFocusIn(): void {\n    if (!this.#virtualized() || this.effectiveDisabled()) {\n      return;\n    }\n    if (this.#activeId() !== null) {\n      return;\n    }\n    const items = this.#options.items();\n    if (items.length === 0) {\n      return;\n    }\n    const ordered = [...items].sort((a, b) => (a.posInSet() ?? 0) - (b.posInSet() ?? 0));\n    const equals = this.compareWith();\n    const value = this.value();\n    const selectedFirst = ordered.find(\n      (o) => !o.disabled() && value.some((v) => equals(v, o.value())),\n    );\n    const target = selectedFirst ?? ordered.find((o) => !o.disabled());\n    if (target) {\n      this.#activeId.set(target.id());\n    }\n  }\n\n  protected onFocusOut(event: FocusEvent): void {\n    const next = event.relatedTarget as HTMLElement | null;\n    if (next && this.#host.nativeElement.contains(next)) {\n      return;\n    }\n    this.markTouched();\n  }\n\n  protected onPointerLeave(): void {\n    this.#pointerHost.set(null);\n  }\n}\n","import {\n  booleanAttribute,\n  computed,\n  Directive,\n  ElementRef,\n  inject,\n  InjectionToken,\n  input,\n} from '@angular/core';\n\nimport {\n  assertInputBound,\n  hostButtonType,\n  isUnset,\n  registerHandle,\n  hostId,\n  resolveListNavigation,\n  unsetInput,\n} from 'forty-cdk/core';\nimport { injectListboxContext } from './listbox-context';\n\n/**\n * Injection key the `[forListboxOptionIndicator]` uses to resolve its parent\n * option, decoupled from the concrete `ForListboxOption` class.\n * `ForListboxOption` provides itself under this token, so a design system\n * wrapping the option by subclassing re-points it at the subclass with a\n * single provider (`{ provide: FOR_LISTBOX_OPTION, useExisting: MtxListboxOption }`)\n * and the indicator keeps resolving — see `docs/wrapping-form-primitives.md`.\n */\nexport const FOR_LISTBOX_OPTION = new InjectionToken<ForListboxOption>('FOR_LISTBOX_OPTION');\n\n/**\n * One option inside a `ForListbox`. Apply on a `<button type=\"button\">` so\n * Space / Enter activation come from native button behavior — printable keys\n * fall through to the parent listbox for typeahead matching.\n *\n * Generic over the option value type `T` (default `string`). Inferred from\n * the `[value]` binding so consumers can pass either primitive ids or full\n * objects (`[value]=\"lang\"` infers `T = Language`); the parent `[forListbox]`\n * must be parameterized over the same `T`. The parent's\n * `[compareWith]` decides how options are matched against the\n * committed selection.\n *\n * Hovering an enabled option hands it `data-highlighted`, so pointer and\n * keyboard feed one highlight and exactly one option is ever decorated. Hover\n * never moves DOM focus and never selects — the pointer's own click activates —\n * and moving the pointer off the listbox hands the highlight back to the\n * keyboard's option.\n */\n@Directive({\n  selector: '[forListboxOption]',\n  exportAs: 'forListboxOption',\n  providers: [{ provide: FOR_LISTBOX_OPTION, useExisting: ForListboxOption }],\n  host: {\n    role: 'option',\n    '[attr.type]': 'buttonType()',\n    '[id]': 'id()',\n    '[attr.aria-selected]': 'selected() ? \"true\" : \"false\"',\n    '[attr.aria-disabled]': 'effectiveDisabled() ? \"true\" : null',\n    '[attr.aria-setsize]': 'ariaSetSize()',\n    '[attr.aria-posinset]': 'ariaPosInSet()',\n    '[attr.tabindex]': 'tabindex()',\n    '[attr.data-state]': 'selected() ? \"checked\" : \"unchecked\"',\n    '[attr.data-highlighted]': 'highlighted() ? \"\" : null',\n    '[attr.data-disabled]': 'effectiveDisabled() ? \"\" : null',\n    '(click)': 'onClick()',\n    '(focus)': 'onFocus()',\n    '(keydown)': 'onKeyDown($event)',\n    '(pointerdown)': 'onPointerDown($event)',\n    '(pointermove)': 'onPointerMove()',\n  },\n})\nexport class ForListboxOption<T = string> {\n  protected readonly buttonType = hostButtonType();\n\n  readonly #group = injectListboxContext<T>('ForListboxOption');\n  readonly #host = inject<ElementRef<HTMLElement>>(ElementRef);\n\n  /**\n   * Stable identifier serialized into `[(value)]` and the hidden input.\n   * Defaults to `string` for back-compat; bind an object to specialize the\n   * parent `[forListbox]` over a richer `T`. The parent's\n   * `[compareWith]` decides how options are matched against the\n   * committed selection.\n   *\n   * Mandatory — an unbound option throws in dev mode.\n   */\n  readonly value = input(unsetInput<T>());\n  /**\n   * Whether the option can be activated. A disabled option stays rendered and announced, and is\n   * skipped by arrow navigation and typeahead.\n   */\n  readonly disabled = input(false, { transform: booleanAttribute });\n\n  /**\n   * Zero-based absolute position of this option in the full source data.\n   * Required in the virtualized path — the listbox uses it to build the\n   * position snapshot and to emit `aria-posinset` (which is `posInSet + 1`).\n   * Leave unset (default `null`) outside the virtualized path.\n   */\n  readonly posInSet = input<number | null>(null);\n\n  readonly id = hostId('for-listbox-option');\n\n  readonly selected = computed(() => {\n    const value = this.value();\n    return isUnset(value) ? false : this.#group.isSelected(value);\n  });\n\n  /**\n   * True when this option is the active candidate — the one the pointer is over,\n   * else the keyboard's. In the roving-tabindex path the keyboard channel is the\n   * DOM-focused option; in the virtualized activedescendant path it is\n   * `aria-activedescendant`, which hover moves too, so the highlight and the\n   * option `Enter` activates never disagree there. Reflected as\n   * `data-highlighted` so consumers can style it uniformly with the other\n   * primitives.\n   */\n  readonly highlighted = computed(() => {\n    const activeId = this.#group.activeDescendantId();\n    if (activeId !== null) {\n      return activeId === this.id();\n    }\n    return this.#group.isOptionHighlighted(this.#host.nativeElement);\n  });\n\n  protected readonly ariaSetSize = computed<string | null>(() => {\n    const total = this.#group.totalCount();\n    return total === undefined ? null : String(total);\n  });\n\n  protected readonly ariaPosInSet = computed<string | null>(() => {\n    if (this.#group.totalCount() === undefined) {\n      return null;\n    }\n    const pos = this.posInSet();\n    return pos === null ? null : String(pos + 1);\n  });\n\n  readonly effectiveDisabled = computed(() => this.disabled() || this.#group.effectiveDisabled());\n\n  protected readonly tabindex = computed<-1 | 0>(() => {\n    if (this.effectiveDisabled()) {\n      return -1;\n    }\n    const rovingTabindex = this.#group.optionTabindex(this.#host.nativeElement);\n    if (rovingTabindex !== null) {\n      return rovingTabindex;\n    }\n    return this.#group.isFirstFocusableOption(this.#host.nativeElement) ? 0 : -1;\n  });\n\n  constructor() {\n    assertInputBound(this.value, 'listbox', '[forListboxOption]', 'value');\n    const handle = {\n      host: this.#host.nativeElement,\n      value: this.value,\n      disabled: this.effectiveDisabled,\n      id: this.id,\n      posInSet: this.posInSet,\n    };\n    registerHandle(\n      handle,\n      (h) => this.#group.registerOption(h),\n      (h) => this.#group.unregisterOption(h),\n    );\n  }\n\n  protected onClick(): void {\n    if (this.effectiveDisabled() || this.#group.readonly()) {\n      return;\n    }\n    this.#group.activate(this.value());\n    this.#group.notifyOptionClick(this.id());\n  }\n\n  protected onPointerDown(event: PointerEvent): void {\n    if (this.#group.totalCount() === undefined) {\n      return;\n    }\n    event.preventDefault();\n  }\n\n  protected onFocus(): void {\n    if (this.effectiveDisabled()) {\n      return;\n    }\n    this.#group.setActiveOption(this.#host.nativeElement);\n  }\n\n  protected onPointerMove(): void {\n    if (this.effectiveDisabled()) {\n      return;\n    }\n    this.#group.highlightFromPointer(this.#host.nativeElement, this.id());\n  }\n\n  protected onKeyDown(event: KeyboardEvent): void {\n    if (this.effectiveDisabled()) {\n      return;\n    }\n\n    // APG-recommended multi-select range modifiers. Single-mode falls through\n    // to plain navigation so Shift+Arrow / Ctrl+A behave like their unmodified\n    // counterparts (or no-op).\n    if (this.#group.multiple()) {\n      // Ctrl/Cmd+A — select all enabled (toggle if all already selected).\n      if ((event.ctrlKey || event.metaKey) && !event.shiftKey && !event.altKey) {\n        if (event.key === 'a' || event.key === 'A') {\n          event.preventDefault();\n          this.#group.selectAll();\n          return;\n        }\n      }\n\n      // Ctrl+Shift+Home / Ctrl+Shift+End — extend selection to first/last.\n      if ((event.ctrlKey || event.metaKey) && event.shiftKey && !event.altKey) {\n        if (event.key === 'Home') {\n          event.preventDefault();\n          this.#group.selectFromCurrentToEdge(this.#host.nativeElement, 'first');\n          return;\n        }\n        if (event.key === 'End') {\n          event.preventDefault();\n          this.#group.selectFromCurrentToEdge(this.#host.nativeElement, 'last');\n          return;\n        }\n      }\n\n      // Shift+Space — contiguous range from anchor to current.\n      if (event.shiftKey && event.key === ' ') {\n        event.preventDefault();\n        this.#group.selectRangeToFocused(this.#host.nativeElement);\n        return;\n      }\n\n      // Shift+Arrow — move focus AND toggle the destination option.\n      if (event.shiftKey && !event.ctrlKey && !event.metaKey && !event.altKey) {\n        const action = resolveListNavigation(event, {\n          orientation: this.#group.orientation(),\n          dir: this.#group.dir(),\n        });\n        if (action === 'next' || action === 'prev') {\n          event.preventDefault();\n          this.#group.extendByArrow(this.#host.nativeElement, action);\n          return;\n        }\n      }\n    }\n\n    const action = resolveListNavigation(event, {\n      orientation: this.#group.orientation(),\n      dir: this.#group.dir(),\n      pageKeys: true,\n    });\n    if (action) {\n      event.preventDefault();\n      this.#group.navigate(this.#host.nativeElement, action);\n      return;\n    }\n    this.#group.handleTypeahead(event);\n  }\n}\n","import { Directive, inject } from '@angular/core';\n\nimport { orphanContextError } from 'forty-cdk/core';\n\nimport { FOR_LISTBOX_OPTION, type ForListboxOption } from './listbox-option';\n\n/**\n * Optional indicator slot inside a `ForListboxOption`. Apply on the\n * element the consumer wants to show only while this option is selected\n * (typically a check icon to the left of the label). Mirrors `data-state`\n * and hides itself while unselected. Visibility is enforced with an inline\n * `display: none` (which beats any author `display` rule a consumer applies\n * via a class) in addition to the `hidden` attribute that removes it from\n * the a11y tree.\n */\n@Directive({\n  selector: '[forListboxOptionIndicator]',\n  exportAs: 'forListboxOptionIndicator',\n  host: {\n    'aria-hidden': 'true',\n    '[attr.data-state]': 'parent.selected() ? \"checked\" : \"unchecked\"',\n    '[attr.hidden]': 'parent.selected() ? null : \"\"',\n    '[style.display]': 'parent.selected() ? null : \"none\"',\n  },\n})\nexport class ForListboxOptionIndicator {\n  protected readonly parent: ForListboxOption;\n\n  constructor() {\n    const parent = inject(FOR_LISTBOX_OPTION, { optional: true });\n    if (!parent) {\n      throw orphanContextError({\n        code: 'FORCDK-LISTBOX-003',\n        piece: 'ForListboxOptionIndicator',\n        root: '[forListboxOption]',\n        token: 'FOR_LISTBOX_OPTION',\n      });\n    }\n    this.parent = parent;\n  }\n}\n","import { Directive, signal } from '@angular/core';\n\nimport { hostLabelledBy } from 'forty-cdk/core';\n\n/**\n * Optional grouping wrapper inside a `ForListbox`. Renders `role=\"group\"`\n * and references the descendant `[forListboxGroupLabel]` (if any) via\n * `aria-labelledby`. Options inside a group still register with the\n * listbox normally, so keyboard navigation traverses across groups in DOM\n * order without special handling.\n */\n@Directive({\n  selector: '[forListboxGroup]',\n  exportAs: 'forListboxGroup',\n  host: {\n    role: 'group',\n    '[attr.aria-labelledby]': 'labelledBy()',\n  },\n})\nexport class ForListboxGroup {\n  readonly #labelId = signal<string | null>(null);\n\n  /** The id of the registered group label (or `null` if none). */\n  readonly labelId = this.#labelId.asReadonly();\n\n  protected readonly labelledBy = hostLabelledBy(() => this.labelId());\n\n  /** Called by `ForListboxGroupLabel` on mount. */\n  registerLabel(id: string): void {\n    this.#labelId.set(id);\n  }\n\n  /** Called by `ForListboxGroupLabel` on destroy. Idempotent. */\n  unregisterLabel(id: string): void {\n    if (this.#labelId() === id) {\n      this.#labelId.set(null);\n    }\n  }\n}\n","import { Directive, inject } from '@angular/core';\n\nimport { orphanContextError, registerA11yName } from 'forty-cdk/core';\nimport { ForListboxGroup } from './listbox-group';\n\n/**\n * Visible label for a `ForListboxGroup`. Generates a stable id and\n * registers with its parent group so the group's `aria-labelledby` points\n * at this element. Apply on whatever heading element fits the design\n * (often `<div>` styled as a small caption — `<h3>`/`<h4>` if the\n * surrounding document has a sensible heading hierarchy).\n */\n@Directive({\n  selector: '[forListboxGroupLabel]',\n  exportAs: 'forListboxGroupLabel',\n  host: {\n    '[id]': 'id',\n  },\n})\nexport class ForListboxGroupLabel {\n  /** Stable host id used by the parent group's `aria-labelledby`. */\n  readonly id: string;\n\n  constructor() {\n    const group = inject(ForListboxGroup, { optional: true });\n    if (!group) {\n      throw orphanContextError({\n        code: 'FORCDK-LISTBOX-002',\n        piece: 'ForListboxGroupLabel',\n        root: '[forListboxGroup]',\n        token: 'ForListboxGroup',\n      });\n    }\n    this.id = registerA11yName(group, 'for-listbox-group-label');\n  }\n}\n","import { isPlatformBrowser } from '@angular/common';\nimport {\n  booleanAttribute,\n  DestroyRef,\n  Directive,\n  DOCUMENT,\n  ElementRef,\n  inject,\n  input,\n  output,\n  PLATFORM_ID,\n  signal,\n} from '@angular/core';\n\nimport {\n  accessibleTextContent,\n  resolveDropTarget,\n  isDragLiftKey,\n  resolveLiftedDragControl,\n  createKeyboardDragMediator,\n  createPointerDragSession,\n  type PointerDragSession,\n  PreviewController,\n  LiveAnnouncer,\n  type WritingDirection,\n} from 'forty-cdk/core';\nimport { injectListboxContext, type ForListboxContext } from './listbox-context';\nimport { FOR_LISTBOX_DEFAULTS } from './listbox-defaults';\n\nconst POINTER_ARM_THRESHOLD_PX = 5;\n\ntype ReorderMode = 'idle' | 'keyboard' | 'pointer';\n\ntype ReorderAction = 'cancel' | 'commit' | 'next' | 'prev' | 'first' | 'last';\n\n/** Payload of `optionReorder`: the lifted option's previous and new index, both 0-based. */\nexport interface ForListboxReorderEvent {\n  /** The lifted option's index before the move, in DOM (rendered) order. */\n  readonly from: number;\n  /** The option's index after the move — pass to `moveItemInArray(items, from, to)`. */\n  readonly to: number;\n}\n\n/**\n * Resolves a lifted-drag keydown to a reorder action. `Escape` / `Tab` cancel and\n * `Space` / `Enter` commit (shared with the tree coordinator); arrow keys step the target\n * linearly in DOM order (both axes, so a wrapping chip grid reorders by either pair), and\n * `Home` / `End` jump to the ends. Honors writing direction for the horizontal arrows.\n */\nfunction resolveReorderAction(event: KeyboardEvent, dir: WritingDirection): ReorderAction | null {\n  const control = resolveLiftedDragControl(event);\n  if (control) {\n    return control;\n  }\n  const isRtl = dir === 'rtl';\n  switch (event.key) {\n    case 'ArrowDown':\n      return 'next';\n    case 'ArrowUp':\n      return 'prev';\n    case 'ArrowRight':\n      return isRtl ? 'prev' : 'next';\n    case 'ArrowLeft':\n      return isRtl ? 'next' : 'prev';\n    case 'Home':\n      return 'first';\n    case 'End':\n      return 'last';\n    default:\n      return null;\n  }\n}\n\n/**\n * Opt-in **pointer + keyboard reordering** for `ForListbox`, composed onto the same element as\n * `[forListbox]`.\n *\n * `[forDraggable]` cannot stack on a `[forListboxOption]` — both would manage the option's\n * roving tabindex and keyboard, colliding on `tabindex`, on Space / Enter activation, and on the\n * container `orientation` input. This coordinator is the listbox-side analogue of\n * `ForTreeNodeDrag` / `ForTableRowReorder`: it lives on the container, **never touches the\n * option's roving tabindex**, intercepts keys in the capture phase, and owns its own 2D drop\n * geometry — so the listbox keeps full selection + typeahead behavior while becoming sortable.\n *\n * Keyboard: focus an option, press `Ctrl+Space` (or `Cmd+Space`) to lift. While lifted, the\n * arrow keys step the target position (linearly in DOM order, so a wrapping chip grid works with\n * either axis), `Home` / `End` jump to the ends, `Space` / `Enter` drop, `Escape` / `Tab` cancel.\n *\n * Pointer: drag an option past a small threshold to reorder; a short press without movement still\n * selects (the post-drag click is suppressed). A floating preview follows the pointer; drop\n * geometry is resolved in 2D, so vertical lists, horizontal lists, and wrapping grids all work\n * without configuring `orientation`.\n *\n * It **never reorders the options itself** (BYO-data): `(optionReorder)` emits the previous / new\n * index on every committed drop; apply `moveItemInArray(items, from, to)` to your own array.\n * Intended for the standard roving-tabindex listbox; a virtualized listbox (`[totalCount]` set)\n * is left untouched, since reordering a windowed subset is ill-defined.\n *\n * @example\n * ```html\n * <ul forListbox forListboxReorder multiple [(value)]=\"selected\" (optionReorder)=\"reorder($event)\">\n *   @for (tag of tags(); track tag) {\n *     <li><button type=\"button\" forListboxOption [value]=\"tag\">{{ tag }}</button></li>\n *   }\n * </ul>\n * ```\n */\n@Directive({\n  selector: '[forListboxReorder]',\n  exportAs: 'forListboxReorder',\n  host: {\n    '[attr.data-dragging]': '_dragging() ? \"\" : null',\n  },\n})\nexport class ForListboxReorder {\n  readonly #ctx: ForListboxContext = injectListboxContext('ForListboxReorder');\n  readonly #host = inject<ElementRef<HTMLElement>>(ElementRef).nativeElement;\n  readonly #document = inject(DOCUMENT);\n  readonly #isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n  readonly #announcer = inject(LiveAnnouncer);\n  readonly #destroyRef = inject(DestroyRef);\n  readonly #defaults = inject(FOR_LISTBOX_DEFAULTS);\n\n  /**\n   * Disables reorder interactions while leaving selection / typeahead intact. Named distinctly\n   * from the listbox's own `disabled` so the two never share a single `[disabled]` binding on the\n   * shared host. The listbox being disabled (its own `disabled` or a surrounding `[forFieldset]`)\n   * also disables reorder.\n   */\n  readonly reorderDisabled = input(false, { transform: booleanAttribute });\n\n  /** Emitted once per committed reorder gesture with the previous / new option index. */\n  readonly optionReorder = output<ForListboxReorderEvent>();\n\n  protected readonly _dragging = signal(false);\n\n  #mode: ReorderMode = 'idle';\n  #liftedHost: HTMLElement | null = null;\n  #fromIndex = 0;\n  #targetIndex = 0;\n  #label = '';\n  #previewController: PreviewController | null = null;\n  #pointerSession: PointerDragSession | null = null;\n\n  constructor() {\n    createKeyboardDragMediator({\n      host: this.#host,\n      document: this.#document,\n      isBrowser: this.#isBrowser,\n      destroyRef: this.#destroyRef,\n      isLifted: () => this.#mode === 'keyboard',\n      onIdleKeydown: (event) => this.#onIdleKeydown(event),\n      onLiftedKeydown: (event) => this.#onLiftedKeydown(event),\n      onFocusLeave: () => this.#cancel(),\n    });\n\n    if (this.#isBrowser) {\n      this.#pointerSession = createPointerDragSession({\n        host: this.#host,\n        document: this.#document,\n        armThreshold: POINTER_ARM_THRESHOLD_PX,\n        cancelOnEscape: true,\n        capturePointer: true,\n        canStart: (event) => this.#canStartPointer(event),\n        onLift: (event) => this.#onPointerLift(event),\n        onMove: (event) => this.#onPointerMove(event),\n        onCommit: (event) => this.#onPointerCommit(event),\n        onCancel: () => this.#onPointerCancel(),\n      });\n      this.#destroyRef.onDestroy(() => {\n        this.#pointerSession?.destroy();\n        if (this.#mode !== 'idle') {\n          this.#clearSession();\n        }\n      });\n    }\n  }\n\n  #reorderable(): boolean {\n    return (\n      !this.reorderDisabled() &&\n      !this.#ctx.effectiveDisabled() &&\n      this.#ctx.totalCount() === undefined\n    );\n  }\n\n  #resolveOption(target: EventTarget | null): { host: HTMLElement; index: number } | null {\n    if (!(target instanceof Node)) {\n      return null;\n    }\n    const options = this.#ctx.options();\n    for (let i = 0; i < options.length; i++) {\n      const option = options[i]!;\n      if (option.host === target || option.host.contains(target)) {\n        return option.disabled() ? null : { host: option.host, index: i };\n      }\n    }\n    return null;\n  }\n\n  #canStartPointer(event: PointerEvent): boolean {\n    if (!this.#reorderable() || (event.pointerType === 'mouse' && event.button !== 0)) {\n      return false;\n    }\n    const resolved = this.#resolveOption(event.target);\n    if (!resolved) {\n      return false;\n    }\n    this.#liftedHost = resolved.host;\n    this.#fromIndex = resolved.index;\n    return true;\n  }\n\n  #onPointerLift(event: PointerEvent): boolean {\n    if (this.#liftedHost === null) {\n      return false;\n    }\n    this.#lift(this.#liftedHost, this.#fromIndex, 'pointer', {\n      x: event.clientX,\n      y: event.clientY,\n    });\n    return true;\n  }\n\n  #onPointerMove(event: PointerEvent): void {\n    if (this.#mode !== 'pointer') {\n      return;\n    }\n    const point = { x: event.clientX, y: event.clientY };\n    this.#previewController?.moveTo(point);\n    this.#setTarget(this.#resolvePointerTarget(point), 'polite');\n  }\n\n  #onPointerCommit(event: PointerEvent): void {\n    if (this.#mode !== 'pointer') {\n      return;\n    }\n    this.#targetIndex = this.#resolvePointerTarget({ x: event.clientX, y: event.clientY });\n    this.#commit();\n  }\n\n  #onPointerCancel(): void {\n    if (this.#mode !== 'pointer') {\n      return;\n    }\n    this.#cancel();\n  }\n\n  #resolvePointerTarget(point: { x: number; y: number }): number {\n    const lifted = this.#liftedHost;\n    const itemRects = this.#ctx\n      .options()\n      .filter((option) => option.host !== lifted)\n      .map((option) => option.host.getBoundingClientRect());\n    const target = resolveDropTarget(point, [\n      {\n        rect: this.#host.getBoundingClientRect(),\n        itemRects,\n        orientation: 'mixed',\n        dir: this.#ctx.dir(),\n      },\n    ]);\n    return target ? target.index : this.#targetIndex;\n  }\n\n  #onIdleKeydown(event: KeyboardEvent): void {\n    if (this.#mode !== 'idle' || !isDragLiftKey(event) || !this.#reorderable()) {\n      return;\n    }\n    const resolved = this.#resolveOption(event.target);\n    if (!resolved) {\n      return;\n    }\n    event.preventDefault();\n    event.stopPropagation();\n    this.#lift(resolved.host, resolved.index, 'keyboard');\n  }\n\n  #onLiftedKeydown(event: KeyboardEvent): void {\n    const action = resolveReorderAction(event, this.#ctx.dir());\n    if (action === null) {\n      return;\n    }\n    event.preventDefault();\n    event.stopPropagation();\n    switch (action) {\n      case 'cancel':\n        this.#cancel();\n        return;\n      case 'commit':\n        this.#commit();\n        return;\n      case 'next':\n        this.#setTarget(this.#targetIndex + 1, 'polite');\n        return;\n      case 'prev':\n        this.#setTarget(this.#targetIndex - 1, 'polite');\n        return;\n      case 'first':\n        this.#setTarget(0, 'polite');\n        return;\n      case 'last':\n        this.#setTarget(this.#ctx.options().length - 1, 'polite');\n        return;\n    }\n  }\n\n  #lift(\n    host: HTMLElement,\n    index: number,\n    mode: 'keyboard' | 'pointer',\n    point?: { x: number; y: number },\n  ): void {\n    this.#mode = mode;\n    this.#liftedHost = host;\n    this.#fromIndex = index;\n    this.#targetIndex = index;\n    this.#label = accessibleTextContent(host).trim();\n    host.setAttribute('data-dragging', '');\n    this._dragging.set(true);\n\n    if (mode === 'pointer' && point) {\n      this.#previewController = new PreviewController({\n        source: host,\n        point,\n        preview: null,\n        doc: this.#document,\n        boundary: null,\n        lockAxis: () => null,\n      });\n    }\n\n    this.#announcer.announce(\n      this.#defaults.reorderAnnounceLift(this.#label, index + 1, this.#ctx.options().length),\n      'assertive',\n    );\n  }\n\n  #setTarget(to: number, politeness: 'polite' | 'assertive'): void {\n    const total = this.#ctx.options().length;\n    const clamped = Math.max(0, Math.min(total - 1, to));\n    if (clamped === this.#targetIndex) {\n      return;\n    }\n    this.#targetIndex = clamped;\n    this.#announcer.announce(\n      this.#defaults.reorderAnnounceMove(this.#label, clamped + 1, total),\n      politeness,\n    );\n  }\n\n  #commit(): void {\n    if (this.#mode === 'idle' || this.#liftedHost === null) {\n      return;\n    }\n    const total = this.#ctx.options().length;\n    const to = Math.max(0, Math.min(total - 1, this.#targetIndex));\n    const from = this.#fromIndex;\n    const label = this.#label;\n    this.#clearSession();\n    this.optionReorder.emit({ from, to });\n    this.#announcer.announce(this.#defaults.reorderAnnounceDrop(label, to + 1, total), 'assertive');\n  }\n\n  #cancel(): void {\n    if (this.#mode === 'idle') {\n      return;\n    }\n    const label = this.#label;\n    this.#clearSession();\n    this.#announcer.announce(this.#defaults.reorderAnnounceCancel(label), 'assertive');\n  }\n\n  #clearSession(): void {\n    this.#liftedHost?.removeAttribute('data-dragging');\n    this.#mode = 'idle';\n    this.#liftedHost = null;\n    this.#fromIndex = 0;\n    this.#targetIndex = 0;\n    this.#label = '';\n    this.#previewController?.destroy();\n    this.#previewController = null;\n    this._dragging.set(false);\n  }\n}\n","/**\n * Exact public names of every `ForListbox` input, its models included. Spread it into the\n * `inputs` array of a `hostDirectives` entry so a wrapper component re-exposes the\n * primitive's full surface — the Signal Forms members `[formField]` binds among them —\n * without hand-maintaining the list. Always spread into an inline object literal as shown\n * below: the literal is what keeps the entry statically analyzable for consumers compiling\n * against the published package. An anti-drift spec fails when this list no longer matches\n * the directive's actual API. See `docs/wrapping-form-primitives.md` for both supported\n * wrapping patterns.\n *\n * @example\n * ```ts\n * @Component({\n *   selector: 'div[myListbox]',\n *   template: '',\n *   hostDirectives: [\n *     {\n *       directive: ForListbox,\n *       inputs: [...FOR_LISTBOX_HOST_DIRECTIVE_INPUTS],\n *       outputs: [...FOR_LISTBOX_HOST_DIRECTIVE_OUTPUTS],\n *     },\n *   ],\n * })\n * export class MyListbox {}\n * ```\n */\nexport const FOR_LISTBOX_HOST_DIRECTIVE_INPUTS = [\n  'value',\n  'ariaLabel',\n  'compareWith',\n  'dataVersion',\n  'dir',\n  'dirty',\n  'disabled',\n  'errors',\n  'invalid',\n  'itemToFormValue',\n  'loop',\n  'multiple',\n  'name',\n  'orientation',\n  'pending',\n  'readonly',\n  'required',\n  'selectionFollowsFocus',\n  'totalCount',\n  'touched',\n  'visibleRange',\n] as const;\n\n/**\n * Exact public names of every `ForListbox` output, the Signal Forms `touch` output\n * included. Spread it into the `outputs` array of the same `hostDirectives` entry as\n * {@link FOR_LISTBOX_HOST_DIRECTIVE_INPUTS}.\n */\nexport const FOR_LISTBOX_HOST_DIRECTIVE_OUTPUTS = [\n  'scrollToIndex',\n  'touch',\n  'touchedChange',\n  'valueChange',\n] as const;\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAkLA;;;;;;;;;AASG;MACU,mBAAmB,GAAG,IAAI,cAAc,CAAoB,qBAAqB;AAExF,SAAU,oBAAoB,CAAc,KAAa,EAAA;AAC7D,IAAA,MAAM,GAAG,GAAG,MAAM,CAAC,mBAAmB,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC3D,IAAI,CAAC,GAAG,EAAE;AACR,QAAA,MAAM,kBAAkB,CAAC;AACvB,YAAA,IAAI,EAAE,oBAAoB;YAC1B,KAAK;AACL,YAAA,IAAI,EAAE,cAAc;AACpB,YAAA,KAAK,EAAE,qBAAqB;AAC7B,SAAA,CAAC;IACJ;IACA,MAAM,OAAO,GAAG,GAAmC;AACnD,IAAA,iBAAiB,CAAC;AAChB,QAAA,UAAU,EAAE,SAAS;AACrB,QAAA,KAAK,EAAE,qBAAqB;AAC5B,QAAA,IAAI,EAAE,cAAc;QACpB,KAAK;AACL,QAAA,KAAK,EAAE,MAAM,OAAO,CAAC,oBAAoB;AAC1C,KAAA,CAAC;AACF,IAAA,OAAO,OAAO;AAChB;;ACzKA;;;;;;;;;;AAUG;AACI,MAAM,6BAA6B,GAAuB;AAC/D,IAAA,qBAAqB,EAAE,KAAK;AAC5B,IAAA,mBAAmB,EAAE,CAAC,KAAK,EAAE,KAAK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