@fluentui/react-tabster 9.0.0-rc.8 → 9.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.json +271 -1
- package/CHANGELOG.md +99 -2
- package/dist/index.d.ts +16 -3
- package/{lib → dist}/tsdoc-metadata.json +0 -0
- package/lib/focus/constants.js.map +1 -1
- package/lib/focus/createCustomFocusIndicatorStyle.js +1 -1
- package/lib/focus/createCustomFocusIndicatorStyle.js.map +1 -1
- package/lib/focus/createFocusOutlineStyle.js +1 -1
- package/lib/focus/createFocusOutlineStyle.js.map +1 -1
- package/lib/hooks/useArrowNavigationGroup.js.map +1 -1
- package/lib/hooks/useFocusFinders.js.map +1 -1
- package/lib/hooks/useFocusableGroup.js +1 -1
- package/lib/hooks/useFocusableGroup.js.map +1 -1
- package/lib/hooks/useKeyboardNavAttribute.js +4 -2
- package/lib/hooks/useKeyboardNavAttribute.js.map +1 -1
- package/lib/hooks/useModalAttributes.js +4 -2
- package/lib/hooks/useModalAttributes.js.map +1 -1
- package/lib/hooks/useTabster.js +1 -1
- package/lib/hooks/useTabster.js.map +1 -1
- package/lib/hooks/useTabsterAttributes.js +1 -0
- package/lib/hooks/useTabsterAttributes.js.map +1 -1
- package/lib-commonjs/focus/constants.js.map +1 -1
- package/lib-commonjs/focus/createCustomFocusIndicatorStyle.js +1 -1
- package/lib-commonjs/focus/createCustomFocusIndicatorStyle.js.map +1 -1
- package/lib-commonjs/focus/createFocusOutlineStyle.js +1 -1
- package/lib-commonjs/focus/createFocusOutlineStyle.js.map +1 -1
- package/lib-commonjs/hooks/useArrowNavigationGroup.js.map +1 -1
- package/lib-commonjs/hooks/useFocusFinders.js.map +1 -1
- package/lib-commonjs/hooks/useFocusableGroup.js +1 -1
- package/lib-commonjs/hooks/useFocusableGroup.js.map +1 -1
- package/lib-commonjs/hooks/useKeyboardNavAttribute.js +4 -2
- package/lib-commonjs/hooks/useKeyboardNavAttribute.js.map +1 -1
- package/lib-commonjs/hooks/useModalAttributes.js +4 -2
- package/lib-commonjs/hooks/useModalAttributes.js.map +1 -1
- package/lib-commonjs/hooks/useTabster.js +1 -1
- package/lib-commonjs/hooks/useTabster.js.map +1 -1
- package/lib-commonjs/hooks/useTabsterAttributes.js +1 -0
- package/lib-commonjs/hooks/useTabsterAttributes.js.map +1 -1
- package/lib-commonjs/index.js.map +1 -1
- package/package.json +10 -11
- package/lib/focus/constants.d.ts +0 -6
- package/lib/focus/createCustomFocusIndicatorStyle.d.ts +0 -12
- package/lib/focus/createFocusOutlineStyle.d.ts +0 -24
- package/lib/focus/index.d.ts +0 -2
- package/lib/hooks/index.d.ts +0 -6
- package/lib/hooks/useArrowNavigationGroup.d.ts +0 -26
- package/lib/hooks/useFocusFinders.d.ts +0 -11
- package/lib/hooks/useFocusableGroup.d.ts +0 -12
- package/lib/hooks/useKeyboardNavAttribute.d.ts +0 -5
- package/lib/hooks/useModalAttributes.d.ts +0 -22
- package/lib/hooks/useTabster.d.ts +0 -9
- package/lib/hooks/useTabsterAttributes.d.ts +0 -5
- package/lib/index.d.ts +0 -4
- package/lib-commonjs/focus/constants.d.ts +0 -6
- package/lib-commonjs/focus/createCustomFocusIndicatorStyle.d.ts +0 -12
- package/lib-commonjs/focus/createFocusOutlineStyle.d.ts +0 -24
- package/lib-commonjs/focus/index.d.ts +0 -2
- package/lib-commonjs/hooks/index.d.ts +0 -6
- package/lib-commonjs/hooks/useArrowNavigationGroup.d.ts +0 -26
- package/lib-commonjs/hooks/useFocusFinders.d.ts +0 -11
- package/lib-commonjs/hooks/useFocusableGroup.d.ts +0 -12
- package/lib-commonjs/hooks/useKeyboardNavAttribute.d.ts +0 -5
- package/lib-commonjs/hooks/useModalAttributes.d.ts +0 -22
- package/lib-commonjs/hooks/useTabster.d.ts +0 -9
- package/lib-commonjs/hooks/useTabsterAttributes.d.ts +0 -5
- package/lib-commonjs/index.d.ts +0 -4
@@ -1,26 +0,0 @@
|
|
1
|
-
import { Types } from 'tabster';
|
2
|
-
export interface UseArrowNavigationGroupOptions {
|
3
|
-
/**
|
4
|
-
* Focus will navigate vertically, horizontally or in both directions (grid), defaults to horizontally
|
5
|
-
* @defaultValue vertical
|
6
|
-
*/
|
7
|
-
axis?: 'vertical' | 'horizontal' | 'grid';
|
8
|
-
/**
|
9
|
-
* Focus will cycle to the first/last elements of the group without stopping
|
10
|
-
*/
|
11
|
-
circular?: boolean;
|
12
|
-
/**
|
13
|
-
* Last focused element in the group will be remembered and focused (if still
|
14
|
-
* available) when tabbing from outside of the group
|
15
|
-
*/
|
16
|
-
memorizeCurrent?: boolean;
|
17
|
-
/**
|
18
|
-
* Allow tabbing within the arrow navigation group items.
|
19
|
-
*/
|
20
|
-
tabbable?: boolean;
|
21
|
-
}
|
22
|
-
/**
|
23
|
-
* A hook that returns the necessary tabster attributes to support arrow key navigation
|
24
|
-
* @param options - Options to configure keyboard navigation
|
25
|
-
*/
|
26
|
-
export declare const useArrowNavigationGroup: (options?: UseArrowNavigationGroupOptions | undefined) => Types.TabsterDOMAttribute;
|
@@ -1,11 +0,0 @@
|
|
1
|
-
import { Types as TabsterTypes } from 'tabster';
|
2
|
-
/**
|
3
|
-
* Returns a set of helper functions that will traverse focusable elements in the context of a root DOM element
|
4
|
-
*/
|
5
|
-
export declare const useFocusFinders: () => {
|
6
|
-
findAllFocusable: (container: HTMLElement, acceptCondition: (el: HTMLElement) => boolean) => HTMLElement[];
|
7
|
-
findFirstFocusable: (container: HTMLElement) => HTMLElement | null | undefined;
|
8
|
-
findLastFocusable: (container: HTMLElement) => HTMLElement | null | undefined;
|
9
|
-
findNextFocusable: (currentElement: HTMLElement, options?: Pick<TabsterTypes.FindNextProps, 'container'>) => HTMLElement | null | undefined;
|
10
|
-
findPrevFocusable: (currentElement: HTMLElement, options?: Pick<TabsterTypes.FindNextProps, 'container'>) => HTMLElement | null | undefined;
|
11
|
-
};
|
@@ -1,12 +0,0 @@
|
|
1
|
-
import { Types } from 'tabster';
|
2
|
-
export interface UseFocusableGroupOptions {
|
3
|
-
/**
|
4
|
-
* Behavior for the Tab key.
|
5
|
-
*/
|
6
|
-
tabBehavior?: 'unlimited' | 'limited' | 'limitedTrapFocus';
|
7
|
-
}
|
8
|
-
/**
|
9
|
-
* A hook that returns the necessary tabster attributes to support groupping.
|
10
|
-
* @param options - Options to configure keyboard navigation
|
11
|
-
*/
|
12
|
-
export declare const useFocusableGroup: (options?: UseFocusableGroupOptions | undefined) => Types.TabsterDOMAttribute;
|
@@ -1,22 +0,0 @@
|
|
1
|
-
import { Types as TabsterTypes } from 'tabster';
|
2
|
-
export interface UseModalAttributesOptions {
|
3
|
-
/**
|
4
|
-
* Traps focus inside the elements the attributes are applied
|
5
|
-
*/
|
6
|
-
trapFocus?: boolean;
|
7
|
-
/**
|
8
|
-
* Always reachabled in Tab order
|
9
|
-
*/
|
10
|
-
alwaysFocusable?: boolean;
|
11
|
-
}
|
12
|
-
/**
|
13
|
-
* Applies modal dialog behaviour through DOM attributes
|
14
|
-
* Modal element will focus trap and hide other content on the page
|
15
|
-
* The trigger element will be focused if focus is lost after the modal element is removed
|
16
|
-
*
|
17
|
-
* @returns DOM attributes to apply to the modal element and its trigger
|
18
|
-
*/
|
19
|
-
export declare const useModalAttributes: (options?: UseModalAttributesOptions) => {
|
20
|
-
modalAttributes: TabsterTypes.TabsterDOMAttribute;
|
21
|
-
triggerAttributes: TabsterTypes.TabsterDOMAttribute;
|
22
|
-
};
|
@@ -1,9 +0,0 @@
|
|
1
|
-
import { Types as TabsterTypes } from 'tabster';
|
2
|
-
/**
|
3
|
-
* Tries to get a tabster instance on the current window or creates a new one
|
4
|
-
* Since Tabster is single instance only, feel free to call this hook to ensure Tabster exists if necessary
|
5
|
-
*
|
6
|
-
* @internal
|
7
|
-
* @returns Tabster core instance
|
8
|
-
*/
|
9
|
-
export declare const useTabster: () => TabsterTypes.TabsterCore | null;
|
package/lib-commonjs/index.d.ts
DELETED
@@ -1,4 +0,0 @@
|
|
1
|
-
export { useArrowNavigationGroup, useFocusableGroup, useFocusFinders, useKeyboardNavAttribute, useModalAttributes, useTabsterAttributes, } from './hooks/index';
|
2
|
-
export type { UseArrowNavigationGroupOptions, UseFocusableGroupOptions, UseModalAttributesOptions, } from './hooks/index';
|
3
|
-
export { createCustomFocusIndicatorStyle, createFocusOutlineStyle } from './focus/index';
|
4
|
-
export type { CreateCustomFocusIndicatorStyleOptions, CreateFocusOutlineStyleOptions, FocusOutlineOffset, FocusOutlineStyleOptions, } from './focus/index';
|