antdv-next 1.0.0-alpha.4 → 1.0.0-beta.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.
Files changed (266) hide show
  1. package/dist/_util/PurePanel.js +106 -0
  2. package/dist/_util/hooks/useMergeSemantic.js +3 -3
  3. package/dist/_util/styleUtils.js +10 -0
  4. package/dist/_util/tools.js +2 -1
  5. package/dist/_util/wave/WaveEffect.js +6 -1
  6. package/dist/_util/wave/style.js +4 -3
  7. package/dist/affix/index.d.ts +3 -3
  8. package/dist/alert/Alert.d.ts +4 -3
  9. package/dist/alert/Alert.js +1 -1
  10. package/dist/anchor/Anchor.d.ts +5 -5
  11. package/dist/anchor/AnchorLink.js +2 -2
  12. package/dist/anchor/index.d.ts +1 -1
  13. package/dist/antd.js +123 -115
  14. package/dist/app/App.d.ts +2 -2
  15. package/dist/auto-complete/index.d.ts +78 -0
  16. package/dist/auto-complete/index.js +634 -0
  17. package/dist/avatar/Avatar.d.ts +3 -3
  18. package/dist/avatar/AvatarGroup.d.ts +2 -2
  19. package/dist/badge/Ribbon.d.ts +3 -3
  20. package/dist/badge/ScrollNumber.js +1 -1
  21. package/dist/badge/SingleNumber.js +1 -1
  22. package/dist/badge/index.d.ts +3 -3
  23. package/dist/badge/index.js +5 -3
  24. package/dist/badge/style/index.js +1 -1
  25. package/dist/breadcrumb/Breadcrumb.d.ts +5 -5
  26. package/dist/breadcrumb/Breadcrumb.js +0 -8
  27. package/dist/breadcrumb/BreadcrumbItem.d.ts +1 -1
  28. package/dist/breadcrumb/BreadcrumbItem.js +1 -17
  29. package/dist/breadcrumb/index.d.ts +1 -1
  30. package/dist/button/Button.d.ts +3 -3
  31. package/dist/button/style/variant.js +116 -104
  32. package/dist/calendar/Header.js +1 -1
  33. package/dist/calendar/generateCalendar.d.ts +3 -3
  34. package/dist/calendar/index.d.ts +3 -3
  35. package/dist/calendar/style/index.d.ts +1 -1
  36. package/dist/calendar/style/index.js +1 -1
  37. package/dist/card/Card.d.ts +3 -3
  38. package/dist/card/CardGrid.d.ts +2 -2
  39. package/dist/card/CardMeta.d.ts +3 -3
  40. package/dist/card/style/index.js +11 -2
  41. package/dist/carousel/index.d.ts +3 -3
  42. package/dist/cascader/Panel.d.ts +3 -3
  43. package/dist/cascader/index.d.ts +4 -3
  44. package/dist/cascader/index.js +3 -1
  45. package/dist/checkbox/Checkbox.d.ts +3 -3
  46. package/dist/checkbox/Group.d.ts +3 -3
  47. package/dist/checkbox/style/index.d.ts +1 -1
  48. package/dist/collapse/Collapse.d.ts +3 -3
  49. package/dist/color-picker/ColorPicker.d.ts +3 -3
  50. package/dist/color-picker/ColorPicker.js +13 -2
  51. package/dist/components.d.ts +11 -8
  52. package/dist/components.js +7 -4
  53. package/dist/config-provider/context.d.ts +2 -1
  54. package/dist/config-provider/context.js +3 -3
  55. package/dist/config-provider/define.d.ts +14 -0
  56. package/dist/config-provider/index.d.ts +3 -3
  57. package/dist/config-provider/index.js +21 -2
  58. package/dist/date-picker/generatePicker/generateRangePicker.js +2 -2
  59. package/dist/date-picker/generatePicker/generateSinglePicker.js +3 -2
  60. package/dist/date-picker/generatePicker/index.d.ts +17 -17
  61. package/dist/date-picker/index.d.ts +29 -27
  62. package/dist/date-picker/index.js +3 -0
  63. package/dist/date-picker/style/panel.js +4 -4
  64. package/dist/descriptions/index.d.ts +3 -3
  65. package/dist/divider/index.d.ts +2 -2
  66. package/dist/drawer/index.d.ts +6 -4
  67. package/dist/drawer/index.js +17 -5
  68. package/dist/drawer/useFocusable.d.ts +10 -0
  69. package/dist/drawer/useFocusable.js +18 -0
  70. package/dist/dropdown/dropdown.d.ts +4 -4
  71. package/dist/dropdown/dropdown.js +12 -3
  72. package/dist/empty/index.d.ts +3 -3
  73. package/dist/flex/index.d.ts +3 -3
  74. package/dist/flex/index.js +1 -1
  75. package/dist/float-button/BackTop.d.ts +3 -3
  76. package/dist/float-button/BackTop.js +4 -1
  77. package/dist/float-button/FloatButton.d.ts +3 -3
  78. package/dist/float-button/FloatButtonGroup.d.ts +3 -3
  79. package/dist/float-button/PurePanel.js +5 -5
  80. package/dist/float-button/style/button.js +4 -4
  81. package/dist/float-button/style/group.js +12 -12
  82. package/dist/form/ErrorList.js +4 -7
  83. package/dist/form/Form.d.ts +7 -3
  84. package/dist/form/Form.js +39 -22
  85. package/dist/form/FormItem/ItemHolder.js +0 -1
  86. package/dist/form/FormItem/index.d.ts +5 -5
  87. package/dist/form/FormItem/index.js +48 -29
  88. package/dist/form/FormItemInput.js +17 -19
  89. package/dist/form/style/index.js +3 -2
  90. package/dist/form/utils/valueUtil.js +4 -1
  91. package/dist/grid/col.js +7 -2
  92. package/dist/grid/index.d.ts +2 -2
  93. package/dist/grid/row.d.ts +2 -2
  94. package/dist/grid/style/index.js +7 -5
  95. package/dist/image/PreviewGroup.d.ts +2 -2
  96. package/dist/image/index.d.ts +7 -4
  97. package/dist/image/index.js +2 -0
  98. package/dist/image/style/index.d.ts +1 -1
  99. package/dist/index.d.ts +16 -12
  100. package/dist/index.js +7 -4
  101. package/dist/input/Input.js +1 -1
  102. package/dist/input/OTP/index.js +1 -1
  103. package/dist/input/TextArea.d.ts +3 -3
  104. package/dist/input/TextArea.js +1 -1
  105. package/dist/input/index.d.ts +11 -11
  106. package/dist/input/style/index.d.ts +2 -2
  107. package/dist/input-number/index.d.ts +4 -4
  108. package/dist/input-number/index.js +2 -6
  109. package/dist/input-number/style/index.js +18 -17
  110. package/dist/layout/index.d.ts +6 -6
  111. package/dist/layout/layout.d.ts +2 -2
  112. package/dist/layout/style/sider.js +1 -1
  113. package/dist/masonry/Masonry.d.ts +3 -3
  114. package/dist/masonry/Masonry.js +8 -6
  115. package/dist/mentions/index.d.ts +4 -3
  116. package/dist/mentions/index.js +4 -2
  117. package/dist/mentions/style/index.js +18 -17
  118. package/dist/menu/MenuDivider.d.ts +2 -2
  119. package/dist/menu/MenuItem.d.ts +3 -3
  120. package/dist/menu/index.d.ts +5 -5
  121. package/dist/menu/style/horizontal.js +1 -1
  122. package/dist/menu/style/index.js +5 -5
  123. package/dist/message/PurePanel.d.ts +2 -2
  124. package/dist/message/useMessage.d.ts +1 -0
  125. package/dist/modal/ConfirmDialog.js +1 -1
  126. package/dist/modal/Modal.d.ts +3 -3
  127. package/dist/modal/Modal.js +17 -6
  128. package/dist/modal/PurePanel.js +305 -0
  129. package/dist/modal/index.js +2 -0
  130. package/dist/modal/interface.d.ts +3 -1
  131. package/dist/notification/PurePanel.d.ts +2 -2
  132. package/dist/notification/PurePanel.js +4 -3
  133. package/dist/notification/style/index.d.ts +1 -1
  134. package/dist/notification/useNotification.d.ts +2 -1
  135. package/dist/notification/useNotification.js +7 -7
  136. package/dist/package.d.ts +143 -3
  137. package/dist/package.js +1 -1
  138. package/dist/pagination/Pagination.d.ts +3 -3
  139. package/dist/pagination/Pagination.js +1 -1
  140. package/dist/pagination/style/index.js +61 -50
  141. package/dist/popconfirm/PurePanel.d.ts +2 -2
  142. package/dist/popconfirm/PurePanel.js +2 -1
  143. package/dist/popconfirm/index.d.ts +3 -3
  144. package/dist/popover/PurePanel.js +4 -2
  145. package/dist/popover/index.d.ts +9 -6
  146. package/dist/popover/index.js +2 -1
  147. package/dist/popover/style/index.js +11 -8
  148. package/dist/progress/progress.d.ts +3 -3
  149. package/dist/qrcode/index.d.ts +3 -3
  150. package/dist/radio/index.d.ts +5 -5
  151. package/dist/radio/radio.d.ts +3 -3
  152. package/dist/radio/style/index.js +1 -1
  153. package/dist/rate/index.d.ts +3 -3
  154. package/dist/rate/style/index.d.ts +1 -1
  155. package/dist/result/index.d.ts +3 -3
  156. package/dist/result/noFound.d.ts +2 -2
  157. package/dist/result/serverError.d.ts +2 -2
  158. package/dist/segmented/index.d.ts +3 -3
  159. package/dist/select/index.d.ts +6 -6
  160. package/dist/select/index.js +5 -3
  161. package/dist/select/style/dropdown.js +1 -1
  162. package/dist/select/style/select-input-multiple.js +31 -29
  163. package/dist/select/style/select-input.js +50 -44
  164. package/dist/skeleton/Avatar.d.ts +2 -2
  165. package/dist/skeleton/Button.d.ts +2 -2
  166. package/dist/skeleton/Image.d.ts +2 -2
  167. package/dist/skeleton/Input.d.ts +2 -2
  168. package/dist/skeleton/Node.d.ts +3 -3
  169. package/dist/skeleton/Skeleton.d.ts +3 -3
  170. package/dist/skeleton/Skeleton.js +1 -1
  171. package/dist/skeleton/Title.d.ts +1 -2
  172. package/dist/skeleton/Title.js +0 -5
  173. package/dist/slider/index.d.ts +3 -3
  174. package/dist/space/Compact.d.ts +2 -0
  175. package/dist/space/Compact.js +17 -4
  176. package/dist/space/index.d.ts +5 -5
  177. package/dist/space/style/addon.js +20 -19
  178. package/dist/spin/index.d.ts +3 -3
  179. package/dist/spin/index.js +7 -6
  180. package/dist/splitter/SplitBar.js +9 -2
  181. package/dist/splitter/Splitter.d.ts +3 -3
  182. package/dist/splitter/Splitter.js +2 -1
  183. package/dist/splitter/index.d.ts +2 -2
  184. package/dist/splitter/style/index.js +6 -6
  185. package/dist/statistic/Statistic.d.ts +3 -3
  186. package/dist/statistic/Timer.d.ts +5 -5
  187. package/dist/statistic/index.d.ts +5 -5
  188. package/dist/steps/ProgressIcon.js +9 -2
  189. package/dist/steps/index.d.ts +3 -3
  190. package/dist/steps/index.js +7 -4
  191. package/dist/steps/style/horizontal.js +13 -10
  192. package/dist/steps/style/icon.js +12 -9
  193. package/dist/steps/style/index.js +19 -18
  194. package/dist/steps/style/inline.js +20 -17
  195. package/dist/steps/style/label-placement.js +22 -20
  196. package/dist/steps/style/nav.js +7 -5
  197. package/dist/steps/style/panel.js +34 -32
  198. package/dist/steps/style/progress-dot.js +10 -8
  199. package/dist/steps/style/progress.js +29 -58
  200. package/dist/steps/style/rtl.js +6 -4
  201. package/dist/steps/style/small.js +10 -8
  202. package/dist/steps/style/status.js +124 -121
  203. package/dist/steps/style/util.js +7 -4
  204. package/dist/steps/style/vertical.js +17 -14
  205. package/dist/style/placementArrow.js +7 -5
  206. package/dist/switch/index.d.ts +3 -3
  207. package/dist/table/Column.d.ts +3 -3
  208. package/dist/table/ColumnGroup.d.ts +3 -3
  209. package/dist/table/InternalTable.js +20 -6
  210. package/dist/table/Table.d.ts +3 -3
  211. package/dist/table/hooks/useFilter/FilterDropdown.js +1 -1
  212. package/dist/table/style/index.js +3 -3
  213. package/dist/table/style/radius.js +6 -0
  214. package/dist/table/style/virtual.js +1 -1
  215. package/dist/tabs/TabPane.d.ts +3 -3
  216. package/dist/tabs/index.d.ts +3 -3
  217. package/dist/tag/CheckableTag.d.ts +3 -3
  218. package/dist/tag/CheckableTagGroup.d.ts +3 -3
  219. package/dist/tag/CheckableTagGroup.js +3 -3
  220. package/dist/tag/index.d.ts +3 -3
  221. package/dist/theme/context.d.ts +2 -2
  222. package/dist/theme/index.d.ts +1 -1
  223. package/dist/theme/useToken.d.ts +2 -2
  224. package/dist/theme/useToken.js +1 -1
  225. package/dist/theme/util/genStyleUtils.d.ts +2 -2
  226. package/dist/theme/util/genStyleUtils.js +8 -5
  227. package/dist/theme/util/useResetIconStyle.js +1 -1
  228. package/dist/time-picker/index.d.ts +8 -7
  229. package/dist/time-picker/index.js +17 -13
  230. package/dist/timeline/Timeline.d.ts +3 -3
  231. package/dist/tooltip/PurePanel.d.ts +2 -2
  232. package/dist/tooltip/PurePanel.js +12 -8
  233. package/dist/tooltip/UniqueProvider/index.d.ts +2 -2
  234. package/dist/tooltip/index.d.ts +3 -3
  235. package/dist/tooltip/index.js +2 -3
  236. package/dist/tooltip/style/index.js +10 -8
  237. package/dist/tooltip/util.js +5 -3
  238. package/dist/tour/PurePanel.js +243 -0
  239. package/dist/tour/index.d.ts +3 -3
  240. package/dist/tour/index.js +2 -0
  241. package/dist/tour/style/index.js +5 -4
  242. package/dist/transfer/Actions.d.ts +2 -2
  243. package/dist/transfer/Section.d.ts +2 -2
  244. package/dist/transfer/Transfer.d.ts +3 -3
  245. package/dist/transfer/Transfer.js +2 -2
  246. package/dist/transfer/search.d.ts +3 -3
  247. package/dist/tree/DirectoryTree.d.ts +3 -3
  248. package/dist/tree/Tree.d.ts +3 -3
  249. package/dist/tree/style/index.d.ts +1 -1
  250. package/dist/tree-select/index.d.ts +5 -4
  251. package/dist/tree-select/index.js +3 -1
  252. package/dist/typography/Link.d.ts +3 -3
  253. package/dist/typography/Paragraph.d.ts +3 -3
  254. package/dist/typography/Text.d.ts +3 -3
  255. package/dist/typography/Title.d.ts +3 -3
  256. package/dist/typography/Typography.d.ts +3 -3
  257. package/dist/typography/index.d.ts +9 -9
  258. package/dist/upload/Dragger.d.ts +6 -3
  259. package/dist/upload/Upload.d.ts +3 -3
  260. package/dist/upload/Upload.js +15 -1
  261. package/dist/upload/index.d.ts +6 -3
  262. package/dist/upload/interface.d.ts +4 -4
  263. package/global.d.ts +3 -0
  264. package/package.json +69 -17
  265. package/web-tags.json +5069 -0
  266. package/web-types.json +14335 -0
@@ -6,9 +6,10 @@ import { getSlotPropsFnRun, toPropsRefs } from "../_util/tools.js";
6
6
  import useCSSVarCls_default from "../config-provider/hooks/useCSSVarCls.js";
7
7
  import { useSize } from "../config-provider/hooks/useSize.js";
8
8
  import { useDisabledContext } from "../config-provider/DisabledContext.js";
9
- import { useFormItemInputContext } from "../form/context.js";
9
+ import PurePanel_default from "../_util/PurePanel.js";
10
10
  import { getMergedStatus, getStatusClassNames } from "../_util/statusUtils.js";
11
11
  import { DefaultRenderEmpty } from "../config-provider/defaultRenderEmpty.js";
12
+ import { useFormItemInputContext } from "../form/context.js";
12
13
  import useVariant from "../form/hooks/useVariant.js";
13
14
  import getAllowClear_default from "../_util/getAllowClear.js";
14
15
  import toList_default from "../_util/toList.js";
@@ -97,7 +98,7 @@ const Mentions = /* @__PURE__ */ defineComponent((props, { slots, emit, expose,
97
98
  };
98
99
  const notFoundContent = computed(() => {
99
100
  if (props.notFoundContent !== void 0) return props.notFoundContent;
100
- return renderEmpty?.("Select") || createVNode(DefaultRenderEmpty, { "componentName": "Select" }, null);
101
+ return renderEmpty?.value?.("Select") || createVNode(DefaultRenderEmpty, { "componentName": "Select" }, null);
101
102
  });
102
103
  const mergedFilterOption = computed(() => props.loading ? loadingFilterOption : props.filterOption);
103
104
  const resolveRenderNode = (key, ctx) => {
@@ -367,6 +368,7 @@ Mentions.getMentions = (value = "", config = {}) => {
367
368
  return null;
368
369
  }).filter((entity) => !!entity && !!entity.value);
369
370
  };
371
+ Mentions._InternalPanelDoNotUseOrYouWillBeFired = PurePanel_default(Mentions, void 0, void 0, "mentions");
370
372
  var mentions_default = Mentions;
371
373
 
372
374
  //#endregion
@@ -1,5 +1,5 @@
1
1
  import { resetComponent, textEllipsis } from "../../style/index.js";
2
- import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
2
+ import { genCssVar, genStyleHooks } from "../../theme/util/genStyleUtils.js";
3
3
  import { mergeToken } from "../../theme/internal.js";
4
4
  import { initComponentToken, initInputToken } from "../../input/style/token.js";
5
5
  import { genBorderlessStyle, genDisabledStyle, genFilledStyle, genOutlinedStyle, genUnderlinedStyle } from "../../input/style/variants.js";
@@ -65,20 +65,21 @@ const genDropdownStyle = (token) => {
65
65
  };
66
66
  const genMentionsStyle = (token) => {
67
67
  const { componentCls, calc, colorText, antCls, colorTextDisabled } = token;
68
+ const [varName, varRef] = genCssVar(antCls, "cmp-mentions");
68
69
  return { [componentCls]: [
69
70
  resetComponent(token),
70
71
  genBasicInputStyle(token, {
71
- largeStyle: { padding: void 0 },
72
- smallStyle: { padding: void 0 }
72
+ largeStyle: { padding: 0 },
73
+ smallStyle: { padding: 0 }
73
74
  }),
74
75
  genOutlinedStyle(token),
75
76
  genFilledStyle(token),
76
77
  genBorderlessStyle(token),
77
78
  genUnderlinedStyle(token),
78
79
  {
79
- "--mentions-padding-inline": token.paddingInline,
80
- "--mentions-padding-block": token.paddingBlock,
81
- "--mentions-control-height": token.controlHeight,
80
+ [varName("padding-inline")]: token.paddingInline,
81
+ [varName("padding-block")]: token.paddingBlock,
82
+ [varName("control-height")]: token.controlHeight,
82
83
  "display": "flex",
83
84
  "padding": 0,
84
85
  "whiteSpace": "pre-wrap",
@@ -100,9 +101,9 @@ const genMentionsStyle = (token) => {
100
101
  color: colorText,
101
102
  boxSizing: "border-box",
102
103
  margin: 0,
103
- minHeight: calc("var(--mentions-control-height)").sub(calc(token.lineWidth).mul(2).equal()).equal(),
104
- paddingInline: "var(--mentions-padding-inline)",
105
- paddingBlock: "var(--mentions-padding-block)",
104
+ minHeight: calc(varRef("control-height")).sub(calc(token.lineWidth).mul(2).equal()).equal(),
105
+ paddingInline: varRef("padding-inline"),
106
+ paddingBlock: varRef("padding-block"),
106
107
  overflow: "inherit",
107
108
  overflowX: "hidden",
108
109
  overflowY: "auto",
@@ -144,7 +145,7 @@ const genMentionsStyle = (token) => {
144
145
  position: "absolute",
145
146
  top: "50%",
146
147
  transform: "translateY(-50%)",
147
- insetInlineEnd: "var(--mentions-padding-inline)",
148
+ insetInlineEnd: varRef("padding-inline"),
148
149
  columnGap: token.marginXS,
149
150
  [`${componentCls}-clear-icon`]: {
150
151
  "cursor": "pointer",
@@ -161,18 +162,18 @@ const genMentionsStyle = (token) => {
161
162
  }
162
163
  }
163
164
  },
164
- { "&-has-suffix": { "> textarea": { paddingInlineEnd: calc(token.paddingXXS).mul(1.5).add(token.fontSizeIcon).add("var(--mentions-padding-inline)").equal() } } },
165
+ { "&-has-suffix": { "> textarea": { paddingInlineEnd: calc(token.paddingXXS).mul(1.5).add(token.fontSizeIcon).add(varRef("padding-inline")).equal() } } },
165
166
  { "&-disabled": { "> textarea": { ...genDisabledStyle(token) } } },
166
167
  {
167
168
  "&-lg": {
168
- "--mentions-padding-inline": token.paddingInlineLG,
169
- "--mentions-padding-block": token.paddingBlockLG,
170
- "--mentions-control-height": token.controlHeightLG
169
+ [varName("padding-inline")]: token.paddingInlineLG,
170
+ [varName("padding-block")]: token.paddingBlockLG,
171
+ [varName("control-height")]: token.controlHeightLG
171
172
  },
172
173
  "&-sm": {
173
- "--mentions-padding-inline": token.paddingInlineSM,
174
- "--mentions-padding-block": token.paddingBlockSM,
175
- "--mentions-control-height": token.controlHeightSM
174
+ [varName("padding-inline")]: token.paddingInlineSM,
175
+ [varName("padding-block")]: token.paddingBlockSM,
176
+ [varName("control-height")]: token.controlHeightSM
176
177
  }
177
178
  }
178
179
  ] };
@@ -1,10 +1,10 @@
1
- import * as vue402 from "vue";
1
+ import * as vue404 from "vue";
2
2
 
3
3
  //#region src/menu/MenuDivider.d.ts
4
4
  interface MenuDividerProps {
5
5
  prefixCls?: string;
6
6
  dashed?: boolean;
7
7
  }
8
- declare const MenuDivider: vue402.DefineSetupFnComponent<MenuDividerProps, {}, {}, MenuDividerProps & {}, vue402.PublicProps>;
8
+ declare const MenuDivider: vue404.DefineSetupFnComponent<MenuDividerProps, {}, {}, MenuDividerProps & {}, vue404.PublicProps>;
9
9
  //#endregion
10
10
  export { MenuDivider };
@@ -1,5 +1,5 @@
1
1
  import { EmptyEmit, VueNode } from "../_util/type.js";
2
- import * as vue404 from "vue";
2
+ import * as vue398 from "vue";
3
3
  import { SlotsType } from "vue";
4
4
  import { MenuItemType } from "@v-c/menu";
5
5
 
@@ -24,8 +24,8 @@ interface MenuItemSlots {
24
24
  title: () => any;
25
25
  extra: () => any;
26
26
  }
27
- declare const MenuItem: vue404.DefineSetupFnComponent<MenuItemProps$1, EmptyEmit, SlotsType<MenuItemSlots>, MenuItemProps$1 & {
27
+ declare const MenuItem: vue398.DefineSetupFnComponent<MenuItemProps$1, EmptyEmit, SlotsType<MenuItemSlots>, MenuItemProps$1 & {
28
28
  [x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
29
- }, vue404.PublicProps>;
29
+ }, vue398.PublicProps>;
30
30
  //#endregion
31
31
  export { MenuItem, MenuItemProps$1 as MenuItemProps, MenuItemSlots };
@@ -4,7 +4,7 @@ import { ItemType } from "./interface.js";
4
4
  import { MenuEmits, MenuProps as MenuProps$1, MenuSlots } from "./menu.js";
5
5
  import { SubMenu as SubMenu$1, SubMenuProps } from "./SubMenu.js";
6
6
  import { MenuDivider } from "./MenuDivider.js";
7
- import * as vue147 from "vue";
7
+ import * as vue124 from "vue";
8
8
  import { SlotsType } from "vue";
9
9
  import { MenuItemGroupProps, MenuRef } from "@v-c/menu";
10
10
 
@@ -14,12 +14,12 @@ interface MenuRef$1 {
14
14
  menu: MenuRef | null;
15
15
  focus: (options?: FocusOptions) => void;
16
16
  }
17
- declare const Menu: vue147.DefineSetupFnComponent<MenuProps$1, MenuEmits, SlotsType<MenuSlots>, MenuProps$1 & {
17
+ declare const Menu: vue124.DefineSetupFnComponent<MenuProps$1, MenuEmits, SlotsType<MenuSlots>, MenuProps$1 & {
18
18
  [x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
19
- }, vue147.PublicProps>;
20
- declare const MenuItem$1: vue147.DefineSetupFnComponent<MenuItemProps$1, EmptyEmit, SlotsType<MenuItemSlots>, MenuItemProps$1 & {
19
+ }, vue124.PublicProps>;
20
+ declare const MenuItem$1: vue124.DefineSetupFnComponent<MenuItemProps$1, EmptyEmit, SlotsType<MenuItemSlots>, MenuItemProps$1 & {
21
21
  [x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
22
- }, vue147.PublicProps>;
22
+ }, vue124.PublicProps>;
23
23
  declare const _default: typeof Menu & {
24
24
  Item: typeof MenuItem;
25
25
  SubMenu: typeof SubMenu$1;
@@ -23,7 +23,7 @@ const getHorizontalStyle = (token) => {
23
23
  [`> ${componentCls}-item:hover,
24
24
  > ${componentCls}-item-active,
25
25
  > ${componentCls}-submenu ${componentCls}-submenu-title:hover`]: { backgroundColor: "transparent" },
26
- [`${componentCls}-item, ${componentCls}-submenu-title`]: { transition: [`border-color ${motionDurationSlow}`, `background ${motionDurationSlow}`].join(",") },
26
+ [`${componentCls}-item, ${componentCls}-submenu-title`]: { transition: [`border-color ${motionDurationSlow}`, `background-color ${motionDurationSlow}`].join(",") },
27
27
  [`${componentCls}-submenu-arrow`]: { display: "none" }
28
28
  } };
29
29
  };
@@ -24,7 +24,7 @@ function genMenuItemStyle(token) {
24
24
  cursor: "pointer",
25
25
  transition: [
26
26
  `border-color ${motionDurationSlow}`,
27
- `background ${motionDurationSlow}`,
27
+ `background-color ${motionDurationSlow}`,
28
28
  `padding calc(${motionDurationSlow} + 0.1s) ${motionEaseInOut}`
29
29
  ].join(","),
30
30
  [`${componentCls}-item-icon, ${iconCls}`]: {
@@ -84,7 +84,7 @@ function genSubMenuArrowStyle(token) {
84
84
  backgroundColor: "currentcolor",
85
85
  borderRadius,
86
86
  transition: [
87
- `background ${motionDurationSlow} ${motionEaseInOut}`,
87
+ `background-color ${motionDurationSlow} ${motionEaseInOut}`,
88
88
  `transform ${motionDurationSlow} ${motionEaseInOut}`,
89
89
  `top ${motionDurationSlow} ${motionEaseInOut}`,
90
90
  `color ${motionDurationSlow} ${motionEaseInOut}`
@@ -132,15 +132,15 @@ const getBaseStyle = (token) => {
132
132
  lineHeight: groupTitleLineHeight,
133
133
  transition: `all ${motionDurationSlow}`
134
134
  },
135
- [`&-horizontal ${componentCls}-submenu`]: { transition: [`border-color ${motionDurationSlow} ${motionEaseInOut}`, `background ${motionDurationSlow} ${motionEaseInOut}`].join(",") },
135
+ [`&-horizontal ${componentCls}-submenu`]: { transition: [`border-color ${motionDurationSlow} ${motionEaseInOut}`, `background-color ${motionDurationSlow} ${motionEaseInOut}`].join(",") },
136
136
  [`${componentCls}-submenu, ${componentCls}-submenu-inline`]: { transition: [
137
137
  `border-color ${motionDurationSlow} ${motionEaseInOut}`,
138
- `background ${motionDurationSlow} ${motionEaseInOut}`,
138
+ `background-color ${motionDurationSlow} ${motionEaseInOut}`,
139
139
  `padding ${motionDurationMid} ${motionEaseInOut}`
140
140
  ].join(",") },
141
141
  [`${componentCls}-submenu ${componentCls}-sub`]: {
142
142
  cursor: "initial",
143
- transition: [`background ${motionDurationSlow} ${motionEaseInOut}`, `padding ${motionDurationSlow} ${motionEaseInOut}`].join(",")
143
+ transition: [`background-color ${motionDurationSlow} ${motionEaseInOut}`, `padding ${motionDurationSlow} ${motionEaseInOut}`].join(",")
144
144
  },
145
145
  [`${componentCls}-title-content`]: {
146
146
  "transition": `color ${motionDurationSlow}`,
@@ -2,7 +2,7 @@ import { VueNode } from "../_util/type.js";
2
2
  import { SemanticClassNames, SemanticStyles } from "../_util/hooks/useMergeSemantic.js";
3
3
  import "../_util/hooks/index.js";
4
4
  import { ArgsClassNamesType, ArgsStylesType, NoticeType, SemanticName } from "./interface.js";
5
- import * as vue394 from "vue";
5
+ import * as vue406 from "vue";
6
6
 
7
7
  //#region src/message/PurePanel.d.ts
8
8
  interface PureContentProps {
@@ -31,6 +31,6 @@ interface PurePanelProps extends Omit<PureContentProps, 'prefixCls' | 'children'
31
31
  styles?: ArgsStylesType;
32
32
  }
33
33
  /** @private Internal Component. Do not use in your production. */
34
- declare const PurePanel: vue394.DefineSetupFnComponent<PurePanelProps, {}, {}, PurePanelProps & {}, vue394.PublicProps>;
34
+ declare const PurePanel: vue406.DefineSetupFnComponent<PurePanelProps, {}, {}, PurePanelProps & {}, vue406.PublicProps>;
35
35
  //#endregion
36
36
  export { PurePanel };
@@ -1,4 +1,5 @@
1
1
  import { ConfigOptions, MessageInstance } from "./interface.js";
2
+ import { MaybeRef } from "@v-c/util/dist/type";
2
3
  import * as vue_jsx_runtime15 from "vue/jsx-runtime";
3
4
 
4
5
  //#region src/message/useMessage.d.ts
@@ -1252,4 +1252,4 @@ const ConfirmDialogWrapper = /* @__PURE__ */ defineComponent((props) => {
1252
1252
  var ConfirmDialog_default = ConfirmDialogWrapper;
1253
1253
 
1254
1254
  //#endregion
1255
- export { ConfirmDialog_default as default };
1255
+ export { ConfirmContent, ConfirmDialog_default as default };
@@ -1,10 +1,10 @@
1
1
  import { ModalEmits, ModalProps, ModalSlots } from "./interface.js";
2
- import * as vue339 from "vue";
2
+ import * as vue267 from "vue";
3
3
  import { SlotsType } from "vue";
4
4
 
5
5
  //#region src/modal/Modal.d.ts
6
- declare const Modal: vue339.DefineSetupFnComponent<ModalProps, ModalEmits, SlotsType<ModalSlots>, ModalProps & {
6
+ declare const Modal: vue267.DefineSetupFnComponent<ModalProps, ModalEmits, SlotsType<ModalSlots>, ModalProps & {
7
7
  [x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
8
- }, vue339.PublicProps>;
8
+ }, vue267.PublicProps>;
9
9
  //#endregion
10
10
  export { Modal };
@@ -10,6 +10,7 @@ import useCSSVarCls_default from "../config-provider/hooks/useCSSVarCls.js";
10
10
  import { ContextIsolator } from "../_util/ContextIsolator.js";
11
11
  import useClosable, { pickClosable } from "../_util/hooks/useClosable.js";
12
12
  import { canUseDocElement } from "../_util/styleChecker.js";
13
+ import useFocusable from "../drawer/useFocusable.js";
13
14
  import skeleton_default from "../skeleton/index.js";
14
15
  import { usePanelRef } from "../watermark/context.js";
15
16
  import { Footer, renderCloseIcon } from "./shared.js";
@@ -40,7 +41,7 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
40
41
  "okButtonProps",
41
42
  "mask"
42
43
  ]);
43
- const { mask: modalMask, classes, styles, zIndex: customZIndex, width: widthRef, rootClass: rootClassRef, rootStyle: rootStyleRef, panelRef: panelRefRef } = toPropsRefs(props, "mask", "classes", "styles", "zIndex", "width", "rootClass", "rootStyle", "panelRef");
44
+ const { mask: modalMask, classes, styles, zIndex: customZIndex, width: widthRef, rootClass: rootClassRef, rootStyle: rootStyleRef, panelRef: panelRefRef, focusable, focusTriggerAfterClose } = toPropsRefs(props, "mask", "classes", "styles", "zIndex", "width", "rootClass", "rootStyle", "panelRef", "focusable", "focusTriggerAfterClose");
44
45
  const { modal: modalContext } = useBaseConfig();
45
46
  const modalRenderRef = computed(() => slots.modalRender || props.modalRender);
46
47
  const rootPrefixCls = computed(() => getPrefixCls());
@@ -50,6 +51,7 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
50
51
  return [closable?.afterClose, closable?.onClose];
51
52
  });
52
53
  const [mergedMask, maskBlurClassName] = useMergedMask(modalMask, contextMask, prefixCls);
54
+ const mergedFocusable = useFocusable(focusable, mergedMask, focusTriggerAfterClose);
53
55
  const onClose = () => {
54
56
  closableContext.value?.[1]?.();
55
57
  };
@@ -89,7 +91,9 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
89
91
  const mergedProps = computed(() => ({
90
92
  ...props,
91
93
  mask: mergedMask.value,
92
- zIndex: zIndex.value
94
+ zIndex: zIndex.value,
95
+ focusTriggerAfterClose: mergedFocusable.value?.focusTriggerAfterClose,
96
+ focusable: mergedFocusable.value
93
97
  }));
94
98
  const [mergedClassNames, mergedStyles] = useMergeSemantic(useToArr(contextClassNames, classes, maskBlurClassName), useToArr(contextStyles, styles), useToProps(mergedProps));
95
99
  const numWidth = computed(() => {
@@ -122,12 +126,12 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
122
126
  [`${prefixCls.value}-wrap-rtl`]: direction.value === "rtl"
123
127
  });
124
128
  const [rawClosable, mergedCloseIcon, closeBtnIsDisabled, ariaProps] = closableIconContext.value;
125
- const [closableAfterclose] = closableContext.value;
129
+ const [closableAfterClose] = closableContext.value;
126
130
  const mergedClosable = rawClosable ? {
127
131
  disabled: closeBtnIsDisabled,
128
132
  closeIcon: mergedCloseIcon,
129
133
  afterClose: () => {
130
- closableAfterclose?.();
134
+ closableAfterClose?.();
131
135
  },
132
136
  ...ariaProps
133
137
  } : false;
@@ -179,7 +183,8 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
179
183
  "destroyOnClose",
180
184
  "mousePosition",
181
185
  "focusTriggerAfterClose",
182
- "panelRef"
186
+ "panelRef",
187
+ "focusable"
183
188
  ]);
184
189
  const titleNode = getSlotPropsFnRun(slots, props, "title");
185
190
  const mergedClassName = clsx(hashId.value, contextClassName.value, className);
@@ -205,7 +210,8 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
205
210
  "onClose": handleCancel,
206
211
  "closable": mergedClosable,
207
212
  "closeIcon": mergedCloseIcon,
208
- "focusTriggerAfterClose": props.focusTriggerAfterClose ?? true,
213
+ "focusTriggerAfterClose": mergedFocusable.value?.focusTriggerAfterClose,
214
+ "focusTrap": mergedFocusable.value?.trap,
209
215
  "transitionName": getTransitionName(rootPrefixCls.value, "zoom", props.transitionName),
210
216
  "maskTransitionName": getTransitionName(rootPrefixCls.value, "fade", props.maskTransitionName),
211
217
  "mask": mergedMask.value,
@@ -443,6 +449,11 @@ const Modal = /* @__PURE__ */ defineComponent((props, { slots, attrs, emit }) =>
443
449
  required: false,
444
450
  default: void 0
445
451
  },
452
+ focusable: {
453
+ type: Object,
454
+ required: false,
455
+ default: void 0
456
+ },
446
457
  footer: {
447
458
  type: [
448
459
  Function,
@@ -0,0 +1,305 @@
1
+ import { useComponentBaseConfig } from "../config-provider/context.js";
2
+ import { getAttrStyleAndClass } from "../_util/hooks/useMergeSemantic.js";
3
+ import "../_util/hooks/index.js";
4
+ import { getSlotPropsFnRun } from "../_util/tools.js";
5
+ import useCSSVarCls_default from "../config-provider/hooks/useCSSVarCls.js";
6
+ import { Footer, renderCloseIcon } from "./shared.js";
7
+ import style_default from "./style/index.js";
8
+ import { ConfirmContent } from "./ConfirmDialog.js";
9
+ import { withPureRenderTheme } from "../_util/PurePanel.js";
10
+ import { computed, createVNode, defineComponent, mergeProps } from "vue";
11
+ import { clsx } from "@v-c/util";
12
+ import { Panel } from "@v-c/dialog";
13
+
14
+ //#region src/modal/PurePanel.tsx
15
+ const PurePanel = /* @__PURE__ */ defineComponent((props, { slots, attrs }) => {
16
+ const { getPrefixCls } = useComponentBaseConfig("modal", props, []);
17
+ const prefixCls = computed(() => props.prefixCls || getPrefixCls());
18
+ const rootPrefixCls = computed(() => getPrefixCls(void 0, ""));
19
+ const rootCls = useCSSVarCls_default(rootPrefixCls);
20
+ const [hashId, cssVarCls] = style_default(prefixCls, rootCls);
21
+ const confirmPrefixCls = computed(() => `${prefixCls.value}-confirm`);
22
+ return () => {
23
+ const { className: attrClassName, restAttrs } = getAttrStyleAndClass(attrs);
24
+ const { type, closable, closeIcon, style: attrStyle } = props;
25
+ const footer = getSlotPropsFnRun(slots, props, "footer", false);
26
+ const title = getSlotPropsFnRun(slots, props, "title", false);
27
+ let additionalProps = {};
28
+ if (type) additionalProps = {
29
+ closable: closable ?? false,
30
+ title: "",
31
+ footer: "",
32
+ children: createVNode(ConfirmContent, mergeProps(props, {
33
+ "prefixCls": prefixCls.value,
34
+ "confirmPrefixCls": confirmPrefixCls.value,
35
+ "rootPrefixCls": rootPrefixCls.value,
36
+ "content": slots.default?.()
37
+ }), null)
38
+ };
39
+ else additionalProps = {
40
+ closable: closable ?? true,
41
+ title,
42
+ footer: footer !== null && createVNode(Footer, mergeProps(props, { "footer": footer }), null),
43
+ children: slots.default?.()
44
+ };
45
+ return createVNode(Panel, mergeProps({
46
+ "prefixCls": prefixCls.value,
47
+ "className": clsx(hashId.value, `${prefixCls.value}-pure-panel`, type && confirmPrefixCls.value, type && `${confirmPrefixCls.value}-${type}`, attrClassName, cssVarCls.value, rootCls.value, props.rootClass),
48
+ "animationVisible": true,
49
+ "style": attrStyle
50
+ }, restAttrs, {
51
+ "closeIcon": renderCloseIcon(prefixCls.value, slots.closeIcon || closeIcon),
52
+ "closable": closable,
53
+ "visible": true
54
+ }, additionalProps), { default: () => additionalProps.children });
55
+ };
56
+ }, {
57
+ props: {
58
+ prefixCls: {
59
+ type: String,
60
+ required: false,
61
+ default: void 0
62
+ },
63
+ rootClass: {
64
+ type: String,
65
+ required: false,
66
+ default: void 0
67
+ },
68
+ className: {
69
+ type: String,
70
+ required: false,
71
+ default: void 0
72
+ },
73
+ keyboard: {
74
+ type: Boolean,
75
+ required: false,
76
+ default: void 0
77
+ },
78
+ style: {
79
+ type: Object,
80
+ required: false,
81
+ default: void 0
82
+ },
83
+ rootStyle: {
84
+ type: Object,
85
+ required: false,
86
+ default: void 0
87
+ },
88
+ mask: {
89
+ type: Boolean,
90
+ required: false,
91
+ default: void 0
92
+ },
93
+ children: {
94
+ type: [
95
+ Object,
96
+ Function,
97
+ String,
98
+ Number,
99
+ null,
100
+ Boolean,
101
+ Array
102
+ ],
103
+ required: false,
104
+ default: void 0
105
+ },
106
+ afterClose: {
107
+ type: Function,
108
+ required: false,
109
+ default: void 0
110
+ },
111
+ afterOpenChange: {
112
+ type: Function,
113
+ required: false,
114
+ default: void 0
115
+ },
116
+ onClose: {
117
+ type: Function,
118
+ required: false,
119
+ default: void 0
120
+ },
121
+ closable: {
122
+ type: [Boolean, Object],
123
+ required: false,
124
+ default: void 0
125
+ },
126
+ maskClosable: {
127
+ type: Boolean,
128
+ required: false,
129
+ default: void 0
130
+ },
131
+ destroyOnHidden: {
132
+ type: Boolean,
133
+ required: false,
134
+ default: void 0
135
+ },
136
+ mousePosition: {
137
+ type: [Object, null],
138
+ required: false,
139
+ default: void 0
140
+ },
141
+ title: {
142
+ type: [
143
+ Object,
144
+ Function,
145
+ String,
146
+ Number,
147
+ null,
148
+ Boolean,
149
+ Array
150
+ ],
151
+ required: false,
152
+ default: void 0
153
+ },
154
+ transitionName: {
155
+ type: String,
156
+ required: false,
157
+ default: void 0
158
+ },
159
+ maskTransitionName: {
160
+ type: String,
161
+ required: false,
162
+ default: void 0
163
+ },
164
+ animation: {
165
+ required: false,
166
+ default: void 0
167
+ },
168
+ maskAnimation: {
169
+ required: false,
170
+ default: void 0
171
+ },
172
+ wrapStyle: {
173
+ type: Object,
174
+ required: false,
175
+ default: void 0
176
+ },
177
+ bodyStyle: {
178
+ type: Object,
179
+ required: false,
180
+ default: void 0
181
+ },
182
+ maskStyle: {
183
+ type: Object,
184
+ required: false,
185
+ default: void 0
186
+ },
187
+ wrapClassName: {
188
+ type: String,
189
+ required: false,
190
+ default: void 0
191
+ },
192
+ width: {
193
+ type: [String, Number],
194
+ required: false,
195
+ default: void 0
196
+ },
197
+ height: {
198
+ type: [String, Number],
199
+ required: false,
200
+ default: void 0
201
+ },
202
+ zIndex: {
203
+ type: Number,
204
+ required: false,
205
+ default: void 0
206
+ },
207
+ bodyProps: {
208
+ required: false,
209
+ default: void 0
210
+ },
211
+ maskProps: {
212
+ required: false,
213
+ default: void 0
214
+ },
215
+ rootClassName: {
216
+ type: String,
217
+ required: false,
218
+ default: void 0
219
+ },
220
+ classNames: {
221
+ type: Object,
222
+ required: false,
223
+ default: void 0
224
+ },
225
+ styles: {
226
+ type: Object,
227
+ required: false,
228
+ default: void 0
229
+ },
230
+ wrapProps: {
231
+ required: false,
232
+ default: void 0
233
+ },
234
+ getContainer: {
235
+ type: [
236
+ String,
237
+ Function,
238
+ Boolean
239
+ ],
240
+ required: false,
241
+ skipCheck: true,
242
+ default: void 0
243
+ },
244
+ closeIcon: {
245
+ type: [
246
+ Object,
247
+ Function,
248
+ String,
249
+ Number,
250
+ null,
251
+ Boolean,
252
+ Array
253
+ ],
254
+ required: false,
255
+ default: void 0
256
+ },
257
+ modalRender: {
258
+ type: Function,
259
+ required: false,
260
+ default: void 0
261
+ },
262
+ forceRender: {
263
+ type: Boolean,
264
+ required: false,
265
+ default: void 0
266
+ },
267
+ focusTriggerAfterClose: {
268
+ type: Boolean,
269
+ required: false,
270
+ default: void 0
271
+ },
272
+ focusTrap: {
273
+ type: Boolean,
274
+ required: false,
275
+ default: void 0
276
+ },
277
+ panelRef: {
278
+ required: false,
279
+ default: void 0
280
+ },
281
+ type: {
282
+ type: String,
283
+ required: false,
284
+ default: void 0
285
+ },
286
+ footer: {
287
+ type: [
288
+ Function,
289
+ Boolean,
290
+ String,
291
+ Number,
292
+ null,
293
+ Object
294
+ ],
295
+ required: false,
296
+ default: void 0
297
+ }
298
+ },
299
+ name: "AModalPurePanel",
300
+ inheritAttrs: false
301
+ });
302
+ var PurePanel_default = withPureRenderTheme(PurePanel);
303
+
304
+ //#endregion
305
+ export { PurePanel_default as default };
@@ -1,6 +1,7 @@
1
1
  import Modal_default from "./Modal.js";
2
2
  import destroyFns_default from "./destroyFns.js";
3
3
  import confirm, { modalGlobalConfig, withError, withInfo, withSuccess, withWarn } from "./confirm.js";
4
+ import PurePanel_default from "./PurePanel.js";
4
5
  import useModal from "./useModal/index.js";
5
6
 
6
7
  //#region src/modal/index.tsx
@@ -20,6 +21,7 @@ Modal.install = (app) => {
20
21
  app.component(Modal.name, Modal);
21
22
  };
22
23
  var modal_default = Modal;
24
+ Modal._InternalPanelDoNotUseOrYouWillBeFired = PurePanel_default;
23
25
 
24
26
  //#endregion
25
27
  export { modal_default as default };