Class TJSFocusIndicator
Hierarchy
- SvelteComponent<
TJSFocusIndicator.Props,
TJSFocusIndicator.Events,
TJSFocusIndicator.Slots,
>- TJSFocusIndicator (View Summary)
Indexable
- [prop: string]: any
Index
Constructors
Methods
Constructors
constructor
- new TJSFocusIndicator(
options: ComponentConstructorOptions<TJSFocusIndicator.Props>,
): TJSFocusIndicator Parameters
Returns TJSFocusIndicator
Methods
$destroy
$on
- $on<K extends string>(type: K, callback: (e: CustomEvent) => void): () => void
Type Parameters
Parameters
- type: K
- callback: (e: CustomEvent) => void
Returns () => void
$set
- $set(props: Partial<TJSFocusIndicator.Props>): void
Parameters
- props: Partial<TJSFocusIndicator.Props>
Returns void
Provides a reusable absolute and block / flexbox positioned focus indicator for accessibility / keyboard navigation across components.
TJSFocusIndicator
is used in menus like TJSMenu / TJSContextMenu and for folders like TJSIconFolder and TJSSvgFolder in the standard library. This focus indicator is also available for 3rd party implementation for external consumers. By default, thespan
element is configured for block / flexbox usage. Set the propabsolute
totrue
and absolute positioning is enabled. In this case make sure the parent element containingTJSFocusIndicator
hasrelative
positioning. There are several CSS variables that are available to alter the appearance.Example