@onpe/ui 1.3.30 → 1.3.32
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/dist/a11y/robustFocus.d.ts +12 -0
- package/dist/components/Modal/Modal.d.ts +14 -1
- package/dist/components.d.ts +14 -1
- package/dist/components.esm.js +1 -1
- package/dist/components.js +1 -1
- package/dist/index.d.ts +14 -1
- package/dist/index.esm.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type RobustFocusByIdOptions = {
|
|
2
|
+
ids: string[];
|
|
3
|
+
scrollToTop?: boolean;
|
|
4
|
+
intervalMs?: number;
|
|
5
|
+
timeoutMs?: number;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Enfoca de forma robusta (con reintentos) el primer elemento visible entre los IDs.
|
|
9
|
+
* Retorna una función de cleanup para limpiar interval/timeout.
|
|
10
|
+
*/
|
|
11
|
+
export declare const setupRobustFocusById: ({ ids, scrollToTop, intervalMs, timeoutMs, }: RobustFocusByIdOptions) => (() => void);
|
|
12
|
+
//# sourceMappingURL=robustFocus.d.ts.map
|
|
@@ -13,8 +13,21 @@ export interface ModalProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
13
13
|
existTabIndex?: boolean;
|
|
14
14
|
zIndexLevel?: number;
|
|
15
15
|
onCloseComplete?: () => void;
|
|
16
|
+
/**
|
|
17
|
+
* IDs (en orden de preferencia) a los que se intentará enfocar al abrir.
|
|
18
|
+
* Útil cuando el contenido se renderiza/hidrata con delay.
|
|
19
|
+
*/
|
|
20
|
+
initialFocusIds?: string | string[];
|
|
21
|
+
/**
|
|
22
|
+
* Intervalo de reintentos (ms) para `initialFocusIds`.
|
|
23
|
+
*/
|
|
24
|
+
initialFocusIntervalMs?: number;
|
|
25
|
+
/**
|
|
26
|
+
* Tiempo máximo (ms) para reintentar `initialFocusIds`.
|
|
27
|
+
*/
|
|
28
|
+
initialFocusTimeoutMs?: number;
|
|
16
29
|
overlayColor?: 'blue' | 'skyblue' | 'skyblue-light' | 'yellow' | 'light-skyblue' | 'gray' | 'gray-light' | 'gray-extra-light' | 'red' | 'dark-gray' | 'green' | 'yellow-light' | 'primary';
|
|
17
30
|
}
|
|
18
|
-
export declare const Modal: ({ isOpen, onClose, children, whitoutBackground, closeButton, closeDisabled, escapeToClose, disableFocus, disableFocusRestore, existTabIndex, zIndexLevel, onCloseComplete, overlayColor, ...props }: ModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
export declare const Modal: ({ isOpen, onClose, children, whitoutBackground, closeButton, closeDisabled, escapeToClose, disableFocus, disableFocusRestore, existTabIndex, zIndexLevel, onCloseComplete, initialFocusIds, initialFocusIntervalMs, initialFocusTimeoutMs, overlayColor, ...props }: ModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
32
|
export default Modal;
|
|
20
33
|
//# sourceMappingURL=Modal.d.ts.map
|
package/dist/components.d.ts
CHANGED
|
@@ -42,9 +42,22 @@ interface ModalProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
42
42
|
existTabIndex?: boolean;
|
|
43
43
|
zIndexLevel?: number;
|
|
44
44
|
onCloseComplete?: () => void;
|
|
45
|
+
/**
|
|
46
|
+
* IDs (en orden de preferencia) a los que se intentará enfocar al abrir.
|
|
47
|
+
* Útil cuando el contenido se renderiza/hidrata con delay.
|
|
48
|
+
*/
|
|
49
|
+
initialFocusIds?: string | string[];
|
|
50
|
+
/**
|
|
51
|
+
* Intervalo de reintentos (ms) para `initialFocusIds`.
|
|
52
|
+
*/
|
|
53
|
+
initialFocusIntervalMs?: number;
|
|
54
|
+
/**
|
|
55
|
+
* Tiempo máximo (ms) para reintentar `initialFocusIds`.
|
|
56
|
+
*/
|
|
57
|
+
initialFocusTimeoutMs?: number;
|
|
45
58
|
overlayColor?: 'blue' | 'skyblue' | 'skyblue-light' | 'yellow' | 'light-skyblue' | 'gray' | 'gray-light' | 'gray-extra-light' | 'red' | 'dark-gray' | 'green' | 'yellow-light' | 'primary';
|
|
46
59
|
}
|
|
47
|
-
declare const Modal: ({ isOpen, onClose, children, whitoutBackground, closeButton, closeDisabled, escapeToClose, disableFocus, disableFocusRestore, existTabIndex, zIndexLevel, onCloseComplete, overlayColor, ...props }: ModalProps) => react_jsx_runtime.JSX.Element;
|
|
60
|
+
declare const Modal: ({ isOpen, onClose, children, whitoutBackground, closeButton, closeDisabled, escapeToClose, disableFocus, disableFocusRestore, existTabIndex, zIndexLevel, onCloseComplete, initialFocusIds, initialFocusIntervalMs, initialFocusTimeoutMs, overlayColor, ...props }: ModalProps) => react_jsx_runtime.JSX.Element;
|
|
48
61
|
|
|
49
62
|
interface ModalBrowserIncompatibleProps {
|
|
50
63
|
isOpen: boolean;
|