@godxjp/ui 19.6.0 → 20.0.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.
Files changed (137) hide show
  1. package/dist/components/data-display/card.d.ts +2 -2
  2. package/dist/components/data-display/collapsible.d.ts +23 -4
  3. package/dist/components/data-display/collapsible.js +119 -4
  4. package/dist/components/data-display/index.d.ts +3 -1
  5. package/dist/components/data-display/index.js +2 -0
  6. package/dist/components/data-display/legend.d.ts +15 -0
  7. package/dist/components/data-display/legend.js +11 -0
  8. package/dist/components/data-display/list-row.js +1 -1
  9. package/dist/components/data-display/popover.d.ts +58 -5
  10. package/dist/components/data-display/popover.js +206 -27
  11. package/dist/components/data-display/progress.d.ts +50 -2
  12. package/dist/components/data-display/progress.js +57 -9
  13. package/dist/components/data-entry/calendar.d.ts +1 -1
  14. package/dist/components/data-entry/calendar.js +67 -32
  15. package/dist/components/data-entry/checkbox.d.ts +19 -6
  16. package/dist/components/data-entry/checkbox.js +55 -16
  17. package/dist/components/data-entry/choice-option.d.ts +1 -1
  18. package/dist/components/data-entry/date-range-picker.d.ts +1 -1
  19. package/dist/components/data-entry/field.js +0 -1
  20. package/dist/components/data-entry/form.js +1 -1
  21. package/dist/components/data-entry/label.d.ts +3 -2
  22. package/dist/components/data-entry/label.js +23 -10
  23. package/dist/components/data-entry/month-picker.d.ts +1 -1
  24. package/dist/components/data-entry/month-range-picker.d.ts +1 -1
  25. package/dist/components/data-entry/transfer.js +16 -6
  26. package/dist/components/data-entry/tree-select-strategy.d.ts +1 -1
  27. package/dist/components/data-entry/tree-select.js +29 -12
  28. package/dist/components/data-entry/tree-utils.d.ts +1 -1
  29. package/dist/components/data-entry/upload.js +7 -2
  30. package/dist/components/feedback/dialog.d.ts +105 -38
  31. package/dist/components/feedback/dialog.js +272 -194
  32. package/dist/components/feedback/overlay-close-focus.d.ts +31 -0
  33. package/dist/components/feedback/overlay-close-focus.js +31 -0
  34. package/dist/components/feedback/overlay-header-tone.d.ts +1 -1
  35. package/dist/components/feedback/sheet.d.ts +53 -11
  36. package/dist/components/feedback/sheet.js +150 -81
  37. package/dist/components/feedback/tooltip.d.ts +51 -7
  38. package/dist/components/feedback/tooltip.js +107 -25
  39. package/dist/components/general/button.js +2 -2
  40. package/dist/components/general/logo.d.ts +17 -0
  41. package/dist/components/general/logo.js +22 -16
  42. package/dist/components/layout/app-shell.d.ts +1 -1
  43. package/dist/components/layout/app-shell.js +52 -8
  44. package/dist/components/layout/aspect-ratio.js +0 -1
  45. package/dist/components/layout/auth-divider.js +0 -1
  46. package/dist/components/layout/flex.d.ts +1 -1
  47. package/dist/components/layout/flex.js +19 -2
  48. package/dist/components/layout/nav-surface.d.ts +26 -0
  49. package/dist/components/layout/nav-surface.js +17 -0
  50. package/dist/components/layout/org-switcher.d.ts +5 -1
  51. package/dist/components/layout/org-switcher.js +5 -3
  52. package/dist/components/layout/separator.js +0 -1
  53. package/dist/components/layout/sidebar.js +4 -1
  54. package/dist/components/layout/split-pane.d.ts +14 -1
  55. package/dist/components/layout/split-pane.js +26 -13
  56. package/dist/components/layout/topbar-item.js +1 -2
  57. package/dist/components/navigation/app-setting-picker.js +21 -2
  58. package/dist/components/navigation/app-setting-toggle.d.ts +16 -0
  59. package/dist/components/navigation/app-setting-toggle.js +96 -0
  60. package/dist/components/navigation/dropdown-menu.d.ts +199 -18
  61. package/dist/components/navigation/dropdown-menu.js +344 -117
  62. package/dist/components/navigation/index.d.ts +2 -0
  63. package/dist/components/navigation/index.js +2 -0
  64. package/dist/components/navigation/pagination-utils.d.ts +2 -1
  65. package/dist/components/navigation/tabs.d.ts +47 -6
  66. package/dist/components/navigation/tabs.js +152 -90
  67. package/dist/components/ui/accordion.d.ts +50 -5
  68. package/dist/components/ui/accordion.js +239 -33
  69. package/dist/components/ui/aspect-ratio.d.ts +23 -2
  70. package/dist/components/ui/aspect-ratio.js +15 -13
  71. package/dist/components/ui/avatar.d.ts +29 -4
  72. package/dist/components/ui/avatar.js +111 -25
  73. package/dist/components/ui/hover-card.d.ts +42 -4
  74. package/dist/components/ui/hover-card.js +183 -27
  75. package/dist/components/ui/label.js +0 -1
  76. package/dist/components/ui/segmented.d.ts +3 -3
  77. package/dist/components/ui/separator.d.ts +8 -2
  78. package/dist/components/ui/separator.js +17 -9
  79. package/dist/components/ui/toggle-group.d.ts +50 -5
  80. package/dist/components/ui/toggle-group.js +79 -20
  81. package/dist/components/ui/toggle.d.ts +31 -5
  82. package/dist/components/ui/toggle.js +42 -3
  83. package/dist/i18n/messages/en.json +8 -0
  84. package/dist/i18n/messages/ja.json +8 -0
  85. package/dist/i18n/messages/vi.json +8 -0
  86. package/dist/lib/control-styles.d.ts +1 -1
  87. package/dist/lib/control-styles.js +1 -1
  88. package/dist/lib/slot.d.ts +32 -0
  89. package/dist/lib/slot.js +22 -0
  90. package/dist/lib/variants.d.ts +22 -3
  91. package/dist/lib/variants.js +56 -1
  92. package/dist/props/components/app.prop.d.ts +25 -1
  93. package/dist/props/components/data-display.prop.d.ts +17 -0
  94. package/dist/props/components/data-entry.prop.d.ts +32 -4
  95. package/dist/props/components/index.d.ts +1 -1
  96. package/dist/props/components/layout.prop.d.ts +118 -5
  97. package/dist/props/components/navigation.prop.d.ts +1 -1
  98. package/dist/props/registry.d.ts +22 -2
  99. package/dist/props/registry.js +33 -2
  100. package/dist/props/vocabulary/content.prop.d.ts +1 -1
  101. package/dist/props/vocabulary/index.d.ts +2 -2
  102. package/dist/props/vocabulary/interaction.prop.d.ts +17 -1
  103. package/dist/props/vocabulary/layout.prop.d.ts +57 -1
  104. package/dist/styles/control.css +142 -1
  105. package/dist/styles/core.css +5 -2
  106. package/dist/styles/data-display-layout.css +72 -0
  107. package/dist/styles/focus-ring.css +4 -0
  108. package/dist/styles/index.css +5 -2
  109. package/dist/styles/layout.css +106 -0
  110. package/dist/styles/shell-layout.css +140 -8
  111. package/dist/styles/text-layout.css +5 -4
  112. package/dist/tokens/base.css +1 -1
  113. package/dist/tokens/components/data-display.css +11 -0
  114. package/dist/tokens/components/shell.css +3 -1
  115. package/dist/tokens/foundation.css +2 -0
  116. package/docs/COMPONENTS.md +9 -3
  117. package/docs/DESIGN-AUTHORITY.md +96 -71
  118. package/docs/FRAME-COVERAGE-REPORT.md +5 -3
  119. package/docs/README.md +14 -14
  120. package/docs/WHAT-BELONGS-HERE.md +179 -0
  121. package/docs/data-display/legend.tsx +145 -0
  122. package/docs/data-display/progress.tsx +32 -0
  123. package/docs/data-entry/segmented.tsx +1 -1
  124. package/docs/data-entry/select.tsx +2 -2
  125. package/docs/feedback/sheet.tsx +1 -1
  126. package/docs/layout/app-shell-arrangements.tsx +225 -0
  127. package/docs/layout/aspect-ratio.tsx +1 -1
  128. package/docs/navigation/app-setting-picker.tsx +26 -1
  129. package/docs/navigation/app-setting-toggle.tsx +111 -0
  130. package/package.json +11 -8
  131. package/scripts/_agent-setup.mjs +165 -3
  132. package/scripts/consumer-rule.md +98 -0
  133. package/scripts/guinea-pig-skill.md +322 -0
  134. package/scripts/init-guinea-pig.mjs +62 -0
  135. package/scripts/postinstall.mjs +13 -2
  136. package/scripts/ui-audit.mjs +115 -14
  137. /package/dist/tokens/{antd.generated.css → derived.css} +0 -0
@@ -1,24 +1,205 @@
1
1
  import * as React from "react";
2
- import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
3
- export declare function DropdownMenu(props: React.ComponentProps<typeof DropdownMenuPrimitive.Root>): React.JSX.Element;
4
- export declare function DropdownMenuTrigger(props: React.ComponentProps<typeof DropdownMenuPrimitive.Trigger>): React.JSX.Element;
5
- export declare function DropdownMenuPortal(props: React.ComponentProps<typeof DropdownMenuPrimitive.Portal>): React.JSX.Element;
6
- export declare function DropdownMenuGroup(props: React.ComponentProps<typeof DropdownMenuPrimitive.Group>): React.JSX.Element;
7
- export declare function DropdownMenuRadioGroup(props: React.ComponentProps<typeof DropdownMenuPrimitive.RadioGroup>): React.JSX.Element;
8
- export declare function DropdownMenuSub(props: React.ComponentProps<typeof DropdownMenuPrimitive.Sub>): React.JSX.Element;
9
- export declare const DropdownMenuContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
10
- export declare const DropdownMenuItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
2
+ import { type MenuItemRenderProps, type PopoverProps, type PopoverRenderProps } from "react-aria-components";
3
+ /**
4
+ * Dịch trạng thái item của RAC sang bộ `data-*` mà Radix phát ra và CSS của kho đang bám.
5
+ *
6
+ * `data-highlighted` móc tô sáng bàn phím (`.ui-dropdown-menu-item[data-highlighted]`);
7
+ * `data-state` mang cả hai nghĩa của Radix — "open" cho sub-trigger, "checked" cho hàng có chọn.
8
+ */
9
+ export declare function radixItemState(state: MenuItemRenderProps): Record<string, string | undefined>;
10
+ /**
11
+ * Dịch trạng thái popover của RAC sang `data-state` / `data-side` của Radix.
12
+ *
13
+ * ĐI KÈM: hai chỗ gọi nó đều bỏ `role` khỏi DOM (`role={undefined}`). RAC tự gắn `role="dialog"`
14
+ * cho MỌI popover modal — "Automatically render Popover with role=dialog except when isNonModal is
15
+ * true" — kể cả khi ruột của nó là một `role="menu"`. Radix không làm thế, và hợp đồng của tệp này
16
+ * là giữ hình dạng Radix ở CẢ cây a11y chứ không chỉ ở tên prop.
17
+ *
18
+ * Cái giá, đo được ở consumer chuột bạch (godx-chat, 08/09/2026): mở một hộp thoại TỪ một mục menu
19
+ * để lại HAI phần tử `role="dialog"` trong DOM suốt ~300ms — popover của menu đang chạy animation
20
+ * thoát (`data-exiting`), cộng chính hộp thoại vừa mở. 12 phép kiểm Playwright đỏ bằng "strict mode
21
+ * violation" trên `getByRole('dialog')`, thứ Playwright KHÔNG thử lại. Và với trình đọc màn hình,
22
+ * một menu vẫn tự xưng là "dialog".
23
+ *
24
+ * Bỏ đúng THUỘC TÍNH, không đụng hành vi: state `isDialog` bên trong RAC không đổi, nên việc đưa
25
+ * tiêu điểm vào popover lúc mở vẫn chạy nguyên như cũ.
26
+ */
27
+ export declare function radixSurfaceState(state: PopoverRenderProps): Record<string, string | undefined>;
28
+ /** Radix `side` + `align` → `placement` của RAC. `align="center"` là placement trần. */
29
+ export declare function toPlacement(side?: "top" | "right" | "bottom" | "left", align?: "start" | "center" | "end"): PopoverProps["placement"];
30
+ /**
31
+ * Radix trao cho `onSelect` một `Event` huỷ được. RAC's `onAction` không có sự kiện nào, nên ta
32
+ * dựng một cái tương đương để consumer gọi `preventDefault()` không nổ — nhưng nó KHÔNG còn giữ
33
+ * menu mở được nữa (xem báo cáo di trú).
34
+ */
35
+ export declare function selectEvent(name: string): Event;
36
+ interface DropdownMenuPropsOwn {
37
+ /** Trạng thái mở có kiểm soát (Radix). Bên trong là `isOpen` của RAC. */
38
+ open?: boolean;
39
+ defaultOpen?: boolean;
40
+ onOpenChange?: (open: boolean) => void;
41
+ /** `modal={false}` → `isNonModal` của RAC: nền không bị khoá cuộn, không bị `inert`. */
42
+ modal?: boolean;
43
+ /**
44
+ * Radix đọc `dir` để đảo mũi tên trái/phải. RAC lấy hướng từ locale (`I18nProvider` /
45
+ * `useLocale`), nên prop này còn trong API vì hợp đồng, nhưng không tự đảo hướng.
46
+ */
47
+ dir?: "ltr" | "rtl";
48
+ }
49
+ type DropdownMenuProps = React.PropsWithChildren<DropdownMenuPropsOwn>;
50
+ export declare function DropdownMenu({ children, open, defaultOpen, onOpenChange, modal, dir, }: DropdownMenuProps): React.JSX.Element;
51
+ interface DropdownMenuTriggerProps extends React.ComponentPropsWithoutRef<"button"> {
52
+ /** Giao hành vi mở cho phần tử con thay vì `<button>` mặc định — như Radix. */
53
+ asChild?: boolean;
54
+ }
55
+ /**
56
+ * RAC không nhận một `<button>` trần làm trigger: hành vi nhấn đi qua `PressResponder`, và chỉ
57
+ * `Pressable` (hoặc một component gọi `usePress`) mới nhận được nó. `asChild` vì vậy trở thành
58
+ * "bọc con trong `Pressable`" thay vì "hợp nhất props vào con" — kết quả với consumer là như nhau:
59
+ * chính phần tử của họ mang `aria-haspopup` / `aria-expanded` và nhận cú nhấn.
60
+ */
61
+ export declare function DropdownMenuTrigger({ asChild, children, ...props }: DropdownMenuTriggerProps): React.JSX.Element;
62
+ interface DropdownMenuPortalPropsOwn {
63
+ /** Giữ tên vì hợp đồng: RAC `Popover` tự cổng ra `document.body`, không có bản dựng cưỡng bức. */
64
+ forceMount?: true;
65
+ }
66
+ type DropdownMenuPortalProps = React.PropsWithChildren<DropdownMenuPortalPropsOwn>;
67
+ /** RAC `Popover` đã tự cổng, nên Portal chỉ còn là chỗ giữ hình dạng cây của Radix. */
68
+ export declare function DropdownMenuPortal({ children }: DropdownMenuPortalProps): React.JSX.Element;
69
+ interface DropdownMenuGroupPropsOwn {
70
+ className?: string;
71
+ }
72
+ type DropdownMenuGroupProps = React.PropsWithChildren<DropdownMenuGroupPropsOwn>;
73
+ /** Radix dựng `<div role="group">`; RAC `MenuSection` dựng `<section role="group">`. */
74
+ export declare function DropdownMenuGroup({ children, className }: DropdownMenuGroupProps): React.JSX.Element;
75
+ interface DropdownMenuRadioGroupPropsOwn {
76
+ className?: string;
77
+ value?: string;
78
+ onValueChange?: (value: string) => void;
79
+ }
80
+ type DropdownMenuRadioGroupProps = React.PropsWithChildren<DropdownMenuRadioGroupPropsOwn>;
81
+ /**
82
+ * Radix giữ trạng thái chọn ở chính RadioGroup; RAC giữ ở collection, khoá theo `id` của item.
83
+ * Nên `value` của consumer trở thành `selectedKeys` và `value` của RadioItem trở thành khoá.
84
+ */
85
+ export declare function DropdownMenuRadioGroup({ children, className, value, onValueChange, }: DropdownMenuRadioGroupProps): React.JSX.Element;
86
+ interface DropdownMenuSubPropsOwn {
87
+ /**
88
+ * RAC `SubmenuTrigger` tự giữ trạng thái mở của submenu và không phơi ra chỗ nào để điều khiển
89
+ * nó. Ba prop này còn trong API vì hợp đồng, nhưng không còn tác dụng.
90
+ */
91
+ open?: boolean;
92
+ defaultOpen?: boolean;
93
+ onOpenChange?: (open: boolean) => void;
94
+ }
95
+ type DropdownMenuSubProps = React.PropsWithChildren<DropdownMenuSubPropsOwn>;
96
+ /**
97
+ * `SubmenuTrigger` đọc children THEO VỊ TRÍ — `children[0]` là item mở submenu, `children[1]` là
98
+ * popover — nên thứ tự `<SubTrigger/>` rồi `<SubContent/>` của Radix ánh xạ thẳng.
99
+ */
100
+ export declare function DropdownMenuSub({ children }: DropdownMenuSubProps): React.JSX.Element;
101
+ interface DropdownMenuContentPropsOwn {
102
+ className?: string;
103
+ side?: "top" | "right" | "bottom" | "left";
104
+ align?: "start" | "center" | "end";
105
+ sideOffset?: number;
106
+ alignOffset?: number;
107
+ avoidCollisions?: boolean;
108
+ collisionPadding?: number;
109
+ /** Radix `loop` cho điều hướng bàn phím → `shouldFocusWrap` của RAC. */
110
+ loop?: boolean;
111
+ /** Giữ tên vì hợp đồng; RAC không có bản dựng cưỡng bức và không tự tháo khi trigger rời màn. */
112
+ forceMount?: true;
113
+ hideWhenDetached?: boolean;
114
+ sticky?: "partial" | "always";
115
+ }
116
+ type DropdownMenuContentProps = React.PropsWithChildren<DropdownMenuContentPropsOwn>;
117
+ /**
118
+ * Một phần tử của Radix (`Content`) tách thành HAI ở RAC: `Popover` là hộp được định vị, `Menu` là
119
+ * phần tử mang `role="menu"`. `data-slot` và lớp `ui-dropdown-menu-content` ở lại trên HỘP, cùng
120
+ * chỗ với `data-state` / `data-side` mà các utility animate đang đọc.
121
+ *
122
+ * `useInertHiddenBackground` đã được gỡ ở đây: RAC gọi `ariaHideOutside(..., {shouldUseInert:
123
+ * true})` — nền thành `inert` thật chứ không chỉ `aria-hidden`, nên axe `aria-hidden-focus` không
124
+ * còn cửa để nổ. Và hiệu ứng đó khoá theo `state.isOpen`, không theo unmount, nên `inert` được nhả
125
+ * NGAY ở ý định đóng: đúng lớp lỗi gh#385, đã sửa ở thượng nguồn. Phép đo là
126
+ * `src/components/__tests__/overlay-inert-release-385.test.tsx`.
127
+ */
128
+ export declare function DropdownMenuContent({ children, className, side, align, sideOffset, alignOffset, avoidCollisions, collisionPadding, loop, hideWhenDetached, sticky, forceMount, }: DropdownMenuContentProps): React.JSX.Element;
129
+ interface DropdownMenuItemPropsOwn {
130
+ className?: string;
11
131
  inset?: boolean;
12
132
  variant?: "default" | "destructive";
13
- } & React.RefAttributes<HTMLDivElement>>;
14
- export declare const DropdownMenuLabel: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
133
+ disabled?: boolean;
134
+ onSelect?: (event: Event) => void;
135
+ textValue?: string;
136
+ /** Mượn thẻ của con thay vì dựng `<div>` riêng — chỗ để nhét một `<Link>` vào một mục menu. */
137
+ asChild?: boolean;
138
+ }
139
+ type DropdownMenuItemProps = React.PropsWithChildren<DropdownMenuItemPropsOwn>;
140
+ export declare function DropdownMenuItem({ children, className, inset, variant, disabled, onSelect, textValue, asChild, }: DropdownMenuItemProps): React.JSX.Element;
141
+ interface DropdownMenuLabelPropsOwn {
142
+ className?: string;
15
143
  inset?: boolean;
16
- } & React.RefAttributes<HTMLDivElement>>;
17
- export declare const DropdownMenuSeparator: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
18
- export declare const DropdownMenuCheckboxItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuCheckboxItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
19
- export declare const DropdownMenuRadioItem: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuRadioItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
20
- export declare const DropdownMenuSubTrigger: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubTriggerProps & React.RefAttributes<HTMLDivElement>, "ref"> & {
144
+ /** Mượn thẻ của con thay vì dựng `<header>` riêng. */
145
+ asChild?: boolean;
146
+ }
147
+ type DropdownMenuLabelProps = React.PropsWithChildren<DropdownMenuLabelPropsOwn>;
148
+ /**
149
+ * Radix dựng `<div>`; nút nhãn của một collection RAC là `Header`, tức `<header>`.
150
+ *
151
+ * `Header` không đi qua `useRenderProps`, nên `props.children` trong `render` CHÍNH là children của
152
+ * consumer — không có `Provider` chen vào như ở `MenuItem`. `Slot` vì thế nhận thẳng gói props.
153
+ */
154
+ export declare function DropdownMenuLabel({ children, className, inset, asChild }: DropdownMenuLabelProps): React.JSX.Element;
155
+ interface DropdownMenuSeparatorProps {
156
+ className?: string;
157
+ }
158
+ export declare function DropdownMenuSeparator({ className }: DropdownMenuSeparatorProps): React.JSX.Element;
159
+ interface DropdownMenuCheckboxItemPropsOwn {
160
+ className?: string;
161
+ checked?: boolean;
162
+ onCheckedChange?: (checked: boolean) => void;
163
+ disabled?: boolean;
164
+ textValue?: string;
165
+ /** Mượn thẻ của con thay vì dựng `<div>` riêng; ô đánh dấu vẫn nằm bên trong thẻ mượn. */
166
+ asChild?: boolean;
167
+ }
168
+ type DropdownMenuCheckboxItemProps = React.PropsWithChildren<DropdownMenuCheckboxItemPropsOwn>;
169
+ export declare function DropdownMenuCheckboxItem({ children, className, checked, onCheckedChange, disabled, textValue, asChild, }: DropdownMenuCheckboxItemProps): React.JSX.Element;
170
+ interface DropdownMenuRadioItemPropsOwn {
171
+ className?: string;
172
+ value: string;
173
+ disabled?: boolean;
174
+ textValue?: string;
175
+ /** Mượn thẻ của con thay vì dựng `<div>` riêng. */
176
+ asChild?: boolean;
177
+ }
178
+ type DropdownMenuRadioItemProps = React.PropsWithChildren<DropdownMenuRadioItemPropsOwn>;
179
+ export declare function DropdownMenuRadioItem({ children, className, value, disabled, textValue, asChild, }: DropdownMenuRadioItemProps): React.JSX.Element;
180
+ interface DropdownMenuSubTriggerPropsOwn {
181
+ className?: string;
21
182
  inset?: boolean;
22
- } & React.RefAttributes<HTMLDivElement>>;
23
- export declare const DropdownMenuSubContent: React.ForwardRefExoticComponent<Omit<DropdownMenuPrimitive.DropdownMenuSubContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
183
+ disabled?: boolean;
184
+ textValue?: string;
185
+ /** Mượn thẻ của con thay vì dựng `<div>` riêng; mũi tên submenu vẫn nằm bên trong thẻ mượn. */
186
+ asChild?: boolean;
187
+ }
188
+ type DropdownMenuSubTriggerProps = React.PropsWithChildren<DropdownMenuSubTriggerPropsOwn>;
189
+ export declare function DropdownMenuSubTrigger({ children, className, inset, disabled, textValue, asChild, }: DropdownMenuSubTriggerProps): React.JSX.Element;
190
+ interface DropdownMenuSubContentPropsOwn {
191
+ className?: string;
192
+ align?: "start" | "center" | "end";
193
+ alignOffset?: number;
194
+ sideOffset?: number;
195
+ avoidCollisions?: boolean;
196
+ collisionPadding?: number;
197
+ loop?: boolean;
198
+ forceMount?: true;
199
+ hideWhenDetached?: boolean;
200
+ sticky?: "partial" | "always";
201
+ }
202
+ type DropdownMenuSubContentProps = React.PropsWithChildren<DropdownMenuSubContentPropsOwn>;
203
+ export declare function DropdownMenuSubContent({ children, className, align, alignOffset, sideOffset, avoidCollisions, collisionPadding, loop, forceMount, hideWhenDetached, sticky, }: DropdownMenuSubContentProps): React.JSX.Element;
24
204
  export declare const DropdownMenuShortcut: ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => React.JSX.Element;
205
+ export {};