Skip to main content
cngx-src documentation

CngxSelectCore

Interface

projects/forms/select/shared/internal/select-core.ts

Import#

import { CngxSelectCore } from '@cngx/forms/select'

Description#

Output of createSelectCore - pure-derivation signals shared by every select-family component.

Index#

Instance Properties#

activeView#Signal
Readonly
ariaBusy#Signal
Readonly
ariaErrorMessage#Signal
Readonly
ariaInvalid#Signal
Readonly
Readonly

Mirrors CNGX_SELECT_CONFIG.ariaLabels. Forwarded onto the panel host.

ariaReadonly#Signal
Readonly
commitController#CngxCommitController
Readonly
commitErrorValue#Signal
Readonly
commitState#CngxAsyncState
Readonly
describedBy#Signal
Readonly
disabled#Signal
Readonly
effectiveOptions#Signal>
Readonly
effectiveTabIndex#Signal
Readonly
externalActivation#Signal
Readonly
fallbackLabels#Required
Readonly

Plain object - config is resolved per-injector and immutable.

flatOptions#Signal
Readonly
isCommitting#Signal
Readonly
panelClassList#Signal
Readonly
Readonly

Bound isGroup/isSelected/isIndeterminate/isCommittingOption for spreading into a variant's CngxSelectPanelHost. Stable identities for the core's lifetime.

panelWidthCss#Signal
Readonly
resolvedAriaLabel#Signal
Readonly
resolvedAriaLabelledBy#Signal
Readonly
resolvedAriaRequired#Signal
Readonly
resolvedId#Signal
Readonly
resolvedListboxLabel#Signal
Readonly
resolvedSelectionIndicatorPosition#Signal<"before" | "after">
Readonly

instance > config > 'before' cascade.

resolvedSelectionIndicatorVariant#Signal<"checkbox" | "checkmark" | "radio">
Readonly

instance > config > 'auto' cascade. 'auto''checkbox' in multi, 'checkmark' in single.

resolvedShowCaret#Signal
Readonly
resolvedShowSelectionIndicator#Signal
Readonly
selection#Signal
Readonly

Shared selection controller. null for single-select. Membership is identity-based - consumers with custom compareWith should prefer isSelected.

showCommitError#Signal
Readonly
showInlineError#Signal
Readonly
showRefreshIndicator#Signal
Readonly
skeletonIndices#Signal
Readonly
togglingOption#WritableSignal
Readonly
triggerAria#Signal
Readonly
unfilteredFlatOptions#Signal
Readonly

Merged-but-unfiltered flat view (server + localItems). Used by chip strips so selected chips stay visible while a search term hides the matching option. Aliases flatOptions when no filter is set.

valueToOptionMap#Signal
Readonly

Methods#

announce#void
announce(option: CngxSelectOptionDef<T> | null, action: "added" | "removed" | "reordered" | "created", count: number, multi: boolean, fromIndex?: number, toIndex?: number)

Announce a selection change via the live-region. Cascade: per-instance > config > default. 'reordered' accepts fromIndex/toIndex; 'created' is fired by action organisms.

@paramaction"added" | "removed" | "reordered" | "created"
@paramcountnumber
@parammultiboolean
@paramfromIndex?number
@paramtoIndex?number
bindCommitRetry#Signal>
bindCommitRetry(retry: function)

Builds a commitErrorContext signal bound to the caller's retry. Cache the result per variant-specific retry signature.

@paramretryfunction
commitErrorMessage#string
commitErrorMessage(err: unknown)
@paramerrunknown
findOption(value: T)
@paramvalueT
isCommittingOption#boolean
isCommittingOption(opt: CngxSelectOptionDef<T>)
isGroup(item: CngxSelectOptionDef | CngxSelectOptionGroupDef)
@paramitemCngxSelectOptionDef | CngxSelectOptionGroupDef
isIndeterminate#boolean
isIndeterminate(value: T)

Always false without childrenFn. Tree-select propagates.

@paramvalueT
isSelected#boolean
isSelected(value: T)

Mode-agnostic membership test. Multi delegates to SelectionController's identity fast path; falls back to compareWith scan for custom comparators.

@paramvalueT
makeErrorContext#Signal
makeErrorContext(retry: function)

Panel-level [state] errors. Cache like bindCommitRetry.

@paramretryfunction