@kjun-ui/native 0.14.0 → 0.15.0
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/index.cjs +334 -284
- package/dist/index.js +204 -152
- package/dist/index.web.cjs +345 -295
- package/dist/index.web.js +208 -156
- package/dist/styles.css +1 -1
- package/dist/types/packages/native/src/collapse.d.cts +3 -1
- package/dist/types/packages/native/src/collapse.d.ts +3 -1
- package/dist/types/packages/native/src/drawer.d.cts +3 -1
- package/dist/types/packages/native/src/drawer.d.ts +3 -1
- package/dist/types/packages/native/src/layout-primitives.d.cts +5 -3
- package/dist/types/packages/native/src/layout-primitives.d.ts +5 -3
- package/dist/types/packages/native/src/list.d.cts +5 -1
- package/dist/types/packages/native/src/list.d.ts +5 -1
- package/dist/types/packages/native/src/modal.d.cts +3 -1
- package/dist/types/packages/native/src/modal.d.ts +3 -1
- package/dist/types/packages/native/src/navigation.d.cts +7 -1
- package/dist/types/packages/native/src/navigation.d.ts +7 -1
- package/dist/types/shared/package-runtime/use-after-close.d.cts +6 -0
- package/dist/types/shared/package-runtime/use-after-close.d.ts +6 -0
- package/package.json +3 -3
package/dist/styles.css
CHANGED
|
@@ -4800,7 +4800,7 @@
|
|
|
4800
4800
|
|
|
4801
4801
|
.kjun-list-section,.kjun-top-navigation,.kjun-bottom-navigation,.kjun-bottom-action-bar{min-width:0;max-width:100%;color:var(--_kjun-color-text);background:var(--_kjun-color-surface)}
|
|
4802
4802
|
.kjun-list-heading{display:flex;align-items:center;justify-content:space-between;gap:var(--_kjun-extension-list-gap);padding:var(--_kjun-extension-list-padding)}.kjun-list-heading h3{font-size:var(--_kjun-type-card-title-size);margin:0;line-height:var(--_kjun-type-card-title-line);font-weight:var(--_kjun-type-card-title-weight);letter-spacing:var(--_kjun-type-card-title-tracking)}.kjun-list-heading p{margin:var(--_kjun-geometry-dimension-value4) 0 0;font-size:var(--_kjun-type-caption-size);color:var(--_kjun-color-text-secondary);overflow-wrap:anywhere;line-height:var(--_kjun-type-caption-line);font-weight:var(--_kjun-type-caption-weight);letter-spacing:var(--_kjun-type-caption-tracking)}
|
|
4803
|
-
.kjun-list{list-style:none;padding:0;margin:0}.kjun-list-row{display:flex;align-items:center;gap:var(--_kjun-extension-list-gap);border-bottom:var(--_kjun-border-default-width) solid var(--_kjun-color-divider);min-width:0}.kjun-list-row:last-child{border-bottom:0}.kjun-list[data-divider=false]>.kjun-list-row{border-bottom:0}.kjun-list[data-density=compact] .kjun-list-main{min-height:var(--_kjun-extension-list-compact-minimum-height);padding-block:var(--_kjun-extension-list-compact-padding-y)}.kjun-list-main{display:flex;align-items:center;gap:var(--_kjun-extension-list-gap);flex:1;min-width:0;min-height:var(--_kjun-extension-list-minimum-height);padding:var(--_kjun-extension-list-padding);text-align:start;color:inherit;text-decoration:none;background:transparent;border:0;font:inherit}.kjun-list-main:is(button,a):hover{background:var(--_kjun-color-hover)}.kjun-list-body{flex:1;min-width:0}.kjun-list-title,.kjun-list-description{display:block;overflow-wrap:anywhere;line-height:1.5}.kjun-list-title{font-size:var(--_kjun-type-label-size);line-height:var(--_kjun-type-label-line);font-weight:var(--_kjun-type-label-weight);letter-spacing:var(--_kjun-type-label-tracking)}.kjun-list-description{font-size:var(--_kjun-type-caption-size);color:var(--_kjun-color-text-secondary);line-height:var(--_kjun-type-caption-line);font-weight:var(--_kjun-type-caption-weight);letter-spacing:var(--_kjun-type-caption-tracking)}.kjun-list-leading{flex-shrink:0}.kjun-list-trailing{overflow-wrap:anywhere;max-width:35%}.kjun-list-actions{display:flex;flex-wrap:wrap;gap:var(--_kjun-extension-list-actions-gap);padding-inline-end:var(--_kjun-extension-list-actions-padding);max-width:45%}
|
|
4803
|
+
.kjun-list{list-style:none;padding:0;margin:0}.kjun-list-row{display:flex;align-items:center;gap:var(--_kjun-extension-list-gap);border-bottom:var(--_kjun-border-default-width) solid var(--_kjun-color-divider);min-width:0}.kjun-list-row:last-child{border-bottom:0}.kjun-list[data-divider=false]>.kjun-list-row{border-bottom:0}.kjun-list[data-density=compact] .kjun-list-main{min-height:var(--_kjun-extension-list-compact-minimum-height);padding-block:var(--_kjun-extension-list-compact-padding-y)}.kjun-list-main{display:flex;align-items:center;gap:var(--_kjun-extension-list-gap);flex:1;min-width:0;min-height:var(--_kjun-extension-list-minimum-height);padding:var(--_kjun-extension-list-padding);text-align:start;color:inherit;text-decoration:none;background:transparent;border:0;font:inherit}.kjun-list-main:is(button,a):hover{background:var(--_kjun-color-hover)}.kjun-list-body{flex:1;min-width:0}.kjun-list-content{display:block;margin-top:var(--_kjun-extension-list-description-gap)}.kjun-list-title,.kjun-list-description{display:block;overflow-wrap:anywhere;line-height:1.5}.kjun-list-title{font-size:var(--_kjun-type-label-size);line-height:var(--_kjun-type-label-line);font-weight:var(--_kjun-type-label-weight);letter-spacing:var(--_kjun-type-label-tracking)}.kjun-list-description{font-size:var(--_kjun-type-caption-size);color:var(--_kjun-color-text-secondary);line-height:var(--_kjun-type-caption-line);font-weight:var(--_kjun-type-caption-weight);letter-spacing:var(--_kjun-type-caption-tracking)}.kjun-list-leading{flex-shrink:0}.kjun-list-trailing{overflow-wrap:anywhere;max-width:35%}.kjun-list-actions{display:flex;flex-wrap:wrap;gap:var(--_kjun-extension-list-actions-gap);padding-inline-end:var(--_kjun-extension-list-actions-padding);max-width:45%}
|
|
4804
4804
|
/* A disabled row disables its actions too, so the row never reads as partly available. */
|
|
4805
4805
|
.kjun-list-actions[data-disabled]{opacity:var(--_kjun-state-opacity-disabled)}
|
|
4806
4806
|
.kjun-navigation-actions{display:flex;align-items:center;justify-content:flex-end;flex-wrap:wrap;gap:var(--_kjun-extension-navigation-actions-gap);min-width:0}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
|
-
|
|
2
|
+
/** keepMounted: once opened, the body stays mounted (height 0, hidden from assistive technology) while closed. */
|
|
3
|
+
export declare function Collapse({ open, keepMounted, children }: {
|
|
3
4
|
open: boolean;
|
|
5
|
+
keepMounted?: boolean;
|
|
4
6
|
children: ReactNode;
|
|
5
7
|
}): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
|
-
|
|
2
|
+
/** keepMounted: once opened, the body stays mounted (height 0, hidden from assistive technology) while closed. */
|
|
3
|
+
export declare function Collapse({ open, keepMounted, children }: {
|
|
3
4
|
open: boolean;
|
|
5
|
+
keepMounted?: boolean;
|
|
4
6
|
children: ReactNode;
|
|
5
7
|
}): import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -13,6 +13,8 @@ export interface KjunDrawerProps {
|
|
|
13
13
|
footer?: ReactNode;
|
|
14
14
|
children: ReactNode;
|
|
15
15
|
onClose?: () => void;
|
|
16
|
+
/** Called once after the close finishes and the layer has left the screen (not when it mounts closed or reopens during the exit). */
|
|
17
|
+
onAfterClose?: () => void;
|
|
16
18
|
ariaLabel?: string;
|
|
17
19
|
/** Top safe area, padded inside top and side drawers and kept clear above a bottom sheet. */
|
|
18
20
|
safeAreaTop?: number;
|
|
@@ -23,4 +25,4 @@ export interface KjunDrawerProps {
|
|
|
23
25
|
/** Keeps the panel above the on-screen keyboard (devices only). */
|
|
24
26
|
avoidKeyboard?: boolean;
|
|
25
27
|
}
|
|
26
|
-
export declare function KjunDrawer({ open, onOpenChange, title, position, width, closable, closeOnOverlay, closeOnEsc, noPadding, header, footer, children, onClose, ariaLabel, safeAreaTop, safeAreaBottom, maxHeight, avoidKeyboard, }: KjunDrawerProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export declare function KjunDrawer({ open, onOpenChange, title, position, width, closable, closeOnOverlay, closeOnEsc, noPadding, header, footer, children, onClose, onAfterClose, ariaLabel, safeAreaTop, safeAreaBottom, maxHeight, avoidKeyboard, }: KjunDrawerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -13,6 +13,8 @@ export interface KjunDrawerProps {
|
|
|
13
13
|
footer?: ReactNode;
|
|
14
14
|
children: ReactNode;
|
|
15
15
|
onClose?: () => void;
|
|
16
|
+
/** Called once after the close finishes and the layer has left the screen (not when it mounts closed or reopens during the exit). */
|
|
17
|
+
onAfterClose?: () => void;
|
|
16
18
|
ariaLabel?: string;
|
|
17
19
|
/** Top safe area, padded inside top and side drawers and kept clear above a bottom sheet. */
|
|
18
20
|
safeAreaTop?: number;
|
|
@@ -23,4 +25,4 @@ export interface KjunDrawerProps {
|
|
|
23
25
|
/** Keeps the panel above the on-screen keyboard (devices only). */
|
|
24
26
|
avoidKeyboard?: boolean;
|
|
25
27
|
}
|
|
26
|
-
export declare function KjunDrawer({ open, onOpenChange, title, position, width, closable, closeOnOverlay, closeOnEsc, noPadding, header, footer, children, onClose, ariaLabel, safeAreaTop, safeAreaBottom, maxHeight, avoidKeyboard, }: KjunDrawerProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export declare function KjunDrawer({ open, onOpenChange, title, position, width, closable, closeOnOverlay, closeOnEsc, noPadding, header, footer, children, onClose, onAfterClose, ariaLabel, safeAreaTop, safeAreaBottom, maxHeight, avoidKeyboard, }: KjunDrawerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
|
-
import { type StyleProp, type TextStyle, type ViewStyle } from "react-native";
|
|
2
|
+
import { type StyleProp, type TextProps, type TextStyle, type ViewStyle } from "react-native";
|
|
3
3
|
import { type InlineAlign, type InlineGap, type InlineJustify, type StackAlign, type StackGap, type TextAlign, type TextTone, type TextVariant } from "../../../shared/package-runtime/layout-primitives.cjs";
|
|
4
4
|
export type { InlineAlign, InlineGap, InlineJustify, StackAlign, StackGap, TextAlign, TextTone, TextVariant };
|
|
5
|
-
|
|
5
|
+
/** Other React Native Text props (accessibilityLabel, testID, selectable, allowFontScaling, adjustsFontSizeToFit…) pass through.
|
|
6
|
+
* adjustsFontSizeToFit only shrinks: the variant size stays the largest. */
|
|
7
|
+
export interface KjunTextProps extends Omit<TextProps, "style" | "children" | "numberOfLines"> {
|
|
6
8
|
/** Typography role; every size, line height and weight comes from tokens.typography. */
|
|
7
9
|
variant?: TextVariant;
|
|
8
10
|
/** Text color role. */
|
|
@@ -13,7 +15,7 @@ export interface KjunTextProps {
|
|
|
13
15
|
style?: StyleProp<TextStyle>;
|
|
14
16
|
children?: ReactNode;
|
|
15
17
|
}
|
|
16
|
-
export declare function KjunText({ variant, tone, align, maxLines, style, children }: KjunTextProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare function KjunText({ variant, tone, align, maxLines, style, children, ...rest }: KjunTextProps): import("react/jsx-runtime").JSX.Element;
|
|
17
19
|
export interface KjunStackProps {
|
|
18
20
|
/** Space between children: space.stack (sm·md·lg) or space.section (section-sm·md·lg). */
|
|
19
21
|
gap?: StackGap;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { type ReactNode } from "react";
|
|
2
|
-
import { type StyleProp, type TextStyle, type ViewStyle } from "react-native";
|
|
2
|
+
import { type StyleProp, type TextProps, type TextStyle, type ViewStyle } from "react-native";
|
|
3
3
|
import { type InlineAlign, type InlineGap, type InlineJustify, type StackAlign, type StackGap, type TextAlign, type TextTone, type TextVariant } from "../../../shared/package-runtime/layout-primitives.js";
|
|
4
4
|
export type { InlineAlign, InlineGap, InlineJustify, StackAlign, StackGap, TextAlign, TextTone, TextVariant };
|
|
5
|
-
|
|
5
|
+
/** Other React Native Text props (accessibilityLabel, testID, selectable, allowFontScaling, adjustsFontSizeToFit…) pass through.
|
|
6
|
+
* adjustsFontSizeToFit only shrinks: the variant size stays the largest. */
|
|
7
|
+
export interface KjunTextProps extends Omit<TextProps, "style" | "children" | "numberOfLines"> {
|
|
6
8
|
/** Typography role; every size, line height and weight comes from tokens.typography. */
|
|
7
9
|
variant?: TextVariant;
|
|
8
10
|
/** Text color role. */
|
|
@@ -13,7 +15,7 @@ export interface KjunTextProps {
|
|
|
13
15
|
style?: StyleProp<TextStyle>;
|
|
14
16
|
children?: ReactNode;
|
|
15
17
|
}
|
|
16
|
-
export declare function KjunText({ variant, tone, align, maxLines, style, children }: KjunTextProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare function KjunText({ variant, tone, align, maxLines, style, children, ...rest }: KjunTextProps): import("react/jsx-runtime").JSX.Element;
|
|
17
19
|
export interface KjunStackProps {
|
|
18
20
|
/** Space between children: space.stack (sm·md·lg) or space.section (section-sm·md·lg). */
|
|
19
21
|
gap?: StackGap;
|
|
@@ -13,8 +13,12 @@ export interface KjunListRowProps {
|
|
|
13
13
|
/** Ends the row with a decorative chevron that marks it as navigation. */
|
|
14
14
|
chevron?: boolean;
|
|
15
15
|
onPress?: (event: GestureResponderEvent) => void;
|
|
16
|
+
/** Name of a pressable or link row, e.g. with the amount a screen reader should hear. */
|
|
17
|
+
ariaLabel?: string;
|
|
18
|
+
/** Display-only content under the description (a budget bar); no buttons or links inside a pressable row. */
|
|
19
|
+
children?: ReactNode;
|
|
16
20
|
}
|
|
17
|
-
export declare function KjunListRow({ title, description, leading, trailing, actions, href, disabled, destructive, chevron, onPress }: KjunListRowProps): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export declare function KjunListRow({ title, description, leading, trailing, actions, href, disabled, destructive, chevron, onPress, ariaLabel, children }: KjunListRowProps): import("react/jsx-runtime").JSX.Element;
|
|
18
22
|
export interface KjunListSectionProps {
|
|
19
23
|
title?: string;
|
|
20
24
|
description?: string;
|
|
@@ -13,8 +13,12 @@ export interface KjunListRowProps {
|
|
|
13
13
|
/** Ends the row with a decorative chevron that marks it as navigation. */
|
|
14
14
|
chevron?: boolean;
|
|
15
15
|
onPress?: (event: GestureResponderEvent) => void;
|
|
16
|
+
/** Name of a pressable or link row, e.g. with the amount a screen reader should hear. */
|
|
17
|
+
ariaLabel?: string;
|
|
18
|
+
/** Display-only content under the description (a budget bar); no buttons or links inside a pressable row. */
|
|
19
|
+
children?: ReactNode;
|
|
16
20
|
}
|
|
17
|
-
export declare function KjunListRow({ title, description, leading, trailing, actions, href, disabled, destructive, chevron, onPress }: KjunListRowProps): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export declare function KjunListRow({ title, description, leading, trailing, actions, href, disabled, destructive, chevron, onPress, ariaLabel, children }: KjunListRowProps): import("react/jsx-runtime").JSX.Element;
|
|
18
22
|
export interface KjunListSectionProps {
|
|
19
23
|
title?: string;
|
|
20
24
|
description?: string;
|
|
@@ -19,6 +19,8 @@ export interface KjunModalProps {
|
|
|
19
19
|
open: boolean;
|
|
20
20
|
onOpenChange: (value: boolean) => void;
|
|
21
21
|
onClose?: () => void;
|
|
22
|
+
/** Called once after the close finishes and the layer has left the screen (not when it mounts closed or reopens during the exit). */
|
|
23
|
+
onAfterClose?: () => void;
|
|
22
24
|
onCancel?: () => void;
|
|
23
25
|
onConfirm?: () => void;
|
|
24
26
|
title?: string;
|
|
@@ -43,4 +45,4 @@ export interface KjunModalProps {
|
|
|
43
45
|
children: ReactNode;
|
|
44
46
|
ariaLabel?: string;
|
|
45
47
|
}
|
|
46
|
-
export declare function KjunModal({ open, onOpenChange, onClose, onCancel, onConfirm, title, size, closable, closeOnOverlay, closeOnEsc, showHeader, showFooter, showConfirmButton, showCancelButton, confirmText, cancelText, confirmDisabled, loading, noPadding, height, confirmVariant, footerSize, header, footer, children, ariaLabel, }: KjunModalProps): import("react/jsx-runtime").JSX.Element;
|
|
48
|
+
export declare function KjunModal({ open, onOpenChange, onClose, onAfterClose, onCancel, onConfirm, title, size, closable, closeOnOverlay, closeOnEsc, showHeader, showFooter, showConfirmButton, showCancelButton, confirmText, cancelText, confirmDisabled, loading, noPadding, height, confirmVariant, footerSize, header, footer, children, ariaLabel, }: KjunModalProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -19,6 +19,8 @@ export interface KjunModalProps {
|
|
|
19
19
|
open: boolean;
|
|
20
20
|
onOpenChange: (value: boolean) => void;
|
|
21
21
|
onClose?: () => void;
|
|
22
|
+
/** Called once after the close finishes and the layer has left the screen (not when it mounts closed or reopens during the exit). */
|
|
23
|
+
onAfterClose?: () => void;
|
|
22
24
|
onCancel?: () => void;
|
|
23
25
|
onConfirm?: () => void;
|
|
24
26
|
title?: string;
|
|
@@ -43,4 +45,4 @@ export interface KjunModalProps {
|
|
|
43
45
|
children: ReactNode;
|
|
44
46
|
ariaLabel?: string;
|
|
45
47
|
}
|
|
46
|
-
export declare function KjunModal({ open, onOpenChange, onClose, onCancel, onConfirm, title, size, closable, closeOnOverlay, closeOnEsc, showHeader, showFooter, showConfirmButton, showCancelButton, confirmText, cancelText, confirmDisabled, loading, noPadding, height, confirmVariant, footerSize, header, footer, children, ariaLabel, }: KjunModalProps): import("react/jsx-runtime").JSX.Element;
|
|
48
|
+
export declare function KjunModal({ open, onOpenChange, onClose, onAfterClose, onCancel, onConfirm, title, size, closable, closeOnOverlay, closeOnEsc, showHeader, showFooter, showConfirmButton, showCancelButton, confirmText, cancelText, confirmDisabled, loading, noPadding, height, confirmVariant, footerSize, header, footer, children, ariaLabel, }: KjunModalProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -9,11 +9,17 @@ export declare function KjunAccordion({ multiple, tone, children, }: KjunAccordi
|
|
|
9
9
|
export interface KjunAccordionItemProps {
|
|
10
10
|
title?: string;
|
|
11
11
|
defaultOpen?: boolean;
|
|
12
|
+
/** Controlled open state. A controlled item follows this value only and stays out of the Accordion's single-open rule. */
|
|
13
|
+
open?: boolean;
|
|
14
|
+
/** Requests a change on a controlled item; reports every change on an uncontrolled one (also when a sibling closes it). */
|
|
15
|
+
onOpenChange?: (open: boolean) => void;
|
|
16
|
+
/** Keeps the body mounted after it first opens, so inputs keep their state while closed. */
|
|
17
|
+
keepMounted?: boolean;
|
|
12
18
|
disabled?: boolean;
|
|
13
19
|
header?: ReactNode;
|
|
14
20
|
children: ReactNode;
|
|
15
21
|
}
|
|
16
|
-
export declare function KjunAccordionItem({ title, defaultOpen, disabled, header, children, }: KjunAccordionItemProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare function KjunAccordionItem({ title, defaultOpen, disabled, header, open: openProp, onOpenChange, keepMounted, children, }: KjunAccordionItemProps): import("react/jsx-runtime").JSX.Element;
|
|
17
23
|
export interface BreadcrumbItem {
|
|
18
24
|
label: string;
|
|
19
25
|
to?: string;
|
|
@@ -9,11 +9,17 @@ export declare function KjunAccordion({ multiple, tone, children, }: KjunAccordi
|
|
|
9
9
|
export interface KjunAccordionItemProps {
|
|
10
10
|
title?: string;
|
|
11
11
|
defaultOpen?: boolean;
|
|
12
|
+
/** Controlled open state. A controlled item follows this value only and stays out of the Accordion's single-open rule. */
|
|
13
|
+
open?: boolean;
|
|
14
|
+
/** Requests a change on a controlled item; reports every change on an uncontrolled one (also when a sibling closes it). */
|
|
15
|
+
onOpenChange?: (open: boolean) => void;
|
|
16
|
+
/** Keeps the body mounted after it first opens, so inputs keep their state while closed. */
|
|
17
|
+
keepMounted?: boolean;
|
|
12
18
|
disabled?: boolean;
|
|
13
19
|
header?: ReactNode;
|
|
14
20
|
children: ReactNode;
|
|
15
21
|
}
|
|
16
|
-
export declare function KjunAccordionItem({ title, defaultOpen, disabled, header, children, }: KjunAccordionItemProps): import("react/jsx-runtime").JSX.Element;
|
|
22
|
+
export declare function KjunAccordionItem({ title, defaultOpen, disabled, header, open: openProp, onOpenChange, keepMounted, children, }: KjunAccordionItemProps): import("react/jsx-runtime").JSX.Element;
|
|
17
23
|
export interface BreadcrumbItem {
|
|
18
24
|
label: string;
|
|
19
25
|
to?: string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/** Calls onAfterClose once when a layer leaves the screen (present true → false). A reopen during the exit keeps
|
|
2
|
+
* present true, so it reports nothing; a layer mounted closed reports nothing either. */
|
|
3
|
+
export declare function useAfterClose(present: boolean, onAfterClose?: () => void, enabled?: boolean): void;
|
|
4
|
+
/** Web overlays can outlive present by a render (react-aria finishes its exit first), so this reports when the
|
|
5
|
+
* overlay element itself leaves the DOM while closed. Attach the returned ref to the overlay. */
|
|
6
|
+
export declare function useAfterCloseRef(open: boolean, onAfterClose?: () => void): (node: Element | null) => void;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/** Calls onAfterClose once when a layer leaves the screen (present true → false). A reopen during the exit keeps
|
|
2
|
+
* present true, so it reports nothing; a layer mounted closed reports nothing either. */
|
|
3
|
+
export declare function useAfterClose(present: boolean, onAfterClose?: () => void, enabled?: boolean): void;
|
|
4
|
+
/** Web overlays can outlive present by a render (react-aria finishes its exit first), so this reports when the
|
|
5
|
+
* overlay element itself leaves the DOM while closed. Attach the returned ref to the overlay. */
|
|
6
|
+
export declare function useAfterCloseRef(open: boolean, onAfterClose?: () => void): (node: Element | null) => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kjun-ui/native",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"homepage": "https://ui.kjun.dev",
|
|
6
6
|
"repository": {
|
|
@@ -47,8 +47,8 @@
|
|
|
47
47
|
"./package.json": "./package.json"
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@kjun-ui/tokens": "0.
|
|
51
|
-
"@kjun-ui/icons": "0.
|
|
50
|
+
"@kjun-ui/tokens": "0.15.0",
|
|
51
|
+
"@kjun-ui/icons": "0.15.0"
|
|
52
52
|
},
|
|
53
53
|
"peerDependencies": {
|
|
54
54
|
"react": "^19.2.3",
|