vft 0.0.73 → 0.0.76

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 (369) hide show
  1. package/attributes.json +1 -1
  2. package/dist/index.css +1 -1
  3. package/es/component.js +67 -48
  4. package/es/components/affix/affix.js +45 -0
  5. package/es/components/affix/affix.vue.js +4 -0
  6. package/es/components/affix/affix.vue2.js +83 -0
  7. package/es/components/affix/index.js +12 -0
  8. package/es/components/affix/style/css.js +2 -0
  9. package/es/components/affix/style/index.js +2 -0
  10. package/es/components/back-top/back-top.vue2.js +10 -2
  11. package/es/components/button/button.vue2.js +58 -59
  12. package/es/components/button/use-button.js +26 -20
  13. package/es/components/card/card.vue.js +4 -0
  14. package/es/components/card/card.vue2.js +44 -0
  15. package/es/components/card/index.js +12 -0
  16. package/es/components/card/instance.js +1 -0
  17. package/es/components/card/style/css.js +2 -0
  18. package/es/components/card/style/index.js +2 -0
  19. package/es/components/check-tag/check-tag.vue.js +4 -0
  20. package/es/components/check-tag/check-tag.vue2.js +35 -0
  21. package/es/components/check-tag/index.js +12 -0
  22. package/es/components/check-tag/style/css.js +2 -0
  23. package/es/components/check-tag/style/index.js +2 -0
  24. package/es/components/color-picker/color-picker.vue2.js +1 -1
  25. package/es/components/context-menu/context-menu.vue2.js +10 -2
  26. package/es/components/date-picker/composables/use-month-range-header.js +1 -1
  27. package/es/components/date-picker/constants.js +16 -2
  28. package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +37 -34
  29. package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +0 -1
  30. package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +177 -178
  31. package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +328 -336
  32. package/es/components/date-picker/date-picker.js +18 -18
  33. package/es/components/date-picker/index.js +5 -4
  34. package/es/components/date-picker/props/shared.js +1 -1
  35. package/es/components/date-time-select/date-time-select.vue2.js +59 -59
  36. package/es/components/dialog/dialog.vue2.js +12 -12
  37. package/es/components/dialog/hooks/use-dialog.js +4 -4
  38. package/es/components/dropdown/dropdown-menu.vue2.js +4 -4
  39. package/es/components/footer-layout/footer-layout.vue2.js +10 -2
  40. package/es/components/header-layout/header-layout.vue2.js +10 -2
  41. package/es/components/horizontal-menu/constants.js +4 -0
  42. package/es/components/horizontal-menu/horizontal-menu.vue2.js +153 -86
  43. package/es/components/horizontal-menu/index.js +7 -5
  44. package/es/components/index.js +228 -194
  45. package/es/components/md-container/md-container.vue2.js +10 -2
  46. package/es/components/menu/menu-item.vue2.js +58 -58
  47. package/es/components/menu/menu.vue2.js +72 -68
  48. package/es/components/menu/sub-menu.vue2.js +139 -117
  49. package/es/components/multiple-tabs/multiple-tabs.vue2.js +35 -26
  50. package/es/components/option/style/css.js +2 -0
  51. package/es/components/option/style/index.js +2 -0
  52. package/es/components/option-group/style/css.js +2 -0
  53. package/es/components/option-group/style/index.js +2 -0
  54. package/es/components/popconfirm/index.js +12 -0
  55. package/es/components/popconfirm/popconfirm.vue.js +4 -0
  56. package/es/components/popconfirm/popconfirm.vue2.js +112 -0
  57. package/es/components/popconfirm/style/css.js +6 -0
  58. package/es/components/popconfirm/style/index.js +6 -0
  59. package/es/components/popover/style/index.js +1 -1
  60. package/es/components/result/result.vue2.js +10 -2
  61. package/es/components/roving-focus-group/roving-focus-item.vue2.js +1 -1
  62. package/es/components/search/style/css.js +2 -0
  63. package/es/components/search/style/index.js +2 -0
  64. package/es/components/select/index.js +22 -0
  65. package/es/components/select/option-group.vue.js +25 -0
  66. package/es/components/select/option-group.vue2.js +53 -0
  67. package/es/components/select/option.vue.js +27 -0
  68. package/es/components/select/option.vue2.js +58 -0
  69. package/es/components/select/options.js +34 -0
  70. package/es/components/select/select-dropdown.vue.js +15 -0
  71. package/es/components/select/select-dropdown.vue2.js +32 -0
  72. package/es/components/select/select.vue.js +327 -0
  73. package/es/components/select/select.vue2.js +348 -0
  74. package/es/components/select/style/css.js +8 -0
  75. package/es/components/select/style/index.js +8 -0
  76. package/es/components/select/token.js +5 -0
  77. package/es/components/select/useOption.js +71 -0
  78. package/es/components/select/useSelect.js +414 -0
  79. package/es/components/select-v2/select-dropdown.js +1 -1
  80. package/es/components/select-v2/useSelect.js +269 -269
  81. package/es/components/side-menu/side-menu.vue2.js +153 -142
  82. package/es/components/skeleton/index.js +16 -0
  83. package/es/components/skeleton/skeleton-item.vue.js +4 -0
  84. package/es/components/skeleton/skeleton-item.vue2.js +31 -0
  85. package/es/components/skeleton/skeleton.vue.js +4 -0
  86. package/es/components/skeleton/skeleton.vue2.js +55 -0
  87. package/es/components/skeleton/style/css.js +3 -0
  88. package/es/components/skeleton/style/index.js +3 -0
  89. package/es/components/skeleton-item/style/css.js +2 -0
  90. package/es/components/skeleton-item/style/index.js +2 -0
  91. package/es/components/space/index.js +17 -0
  92. package/es/components/space/item.js +24 -0
  93. package/es/components/space/space.js +182 -0
  94. package/es/components/space/style/css.js +2 -0
  95. package/es/components/space/style/index.js +2 -0
  96. package/es/components/space/use-space.js +44 -0
  97. package/es/components/switch/switch.vue2.js +1 -1
  98. package/es/components/tabs/tab-nav.vue2.js +30 -22
  99. package/es/components/tabs/tabs.vue2.js +37 -37
  100. package/es/components/time-picker/common/picker.vue2.js +241 -257
  101. package/es/components/time-picker/common/props.js +10 -6
  102. package/es/components/time-picker/time-picker-com/panel-time-range.vue2.js +1 -1
  103. package/es/components/time-picker/time-picker.js +10 -10
  104. package/es/components/time-select/time-select.vue2.js +38 -42
  105. package/es/components/tooltip/content.vue2.js +1 -1
  106. package/es/components/tree/index.js +14 -0
  107. package/es/components/tree/model/node.js +248 -0
  108. package/es/components/tree/model/tree-store.js +197 -0
  109. package/es/components/tree/model/useDragNode.js +71 -0
  110. package/es/components/tree/model/useKeydown.js +81 -0
  111. package/es/components/tree/model/useNodeExpandEventBroadcast.js +19 -0
  112. package/es/components/tree/model/util.js +21 -0
  113. package/es/components/tree/style/css.js +3 -0
  114. package/es/components/tree/style/index.js +3 -0
  115. package/es/components/tree/tree-node-content.vue.js +4 -0
  116. package/es/components/tree/tree-node-content.vue2.js +28 -0
  117. package/es/components/tree/tree-node.vue.js +98 -0
  118. package/es/components/tree/tree-node.vue2.js +152 -0
  119. package/es/components/tree/tree.type.js +1 -0
  120. package/es/components/tree/tree.vue.js +48 -0
  121. package/es/components/tree/tree.vue2.js +268 -0
  122. package/es/components/tree-select/cache-options.js +32 -0
  123. package/es/components/tree-select/index.js +9 -0
  124. package/es/components/tree-select/select.js +38 -0
  125. package/es/components/tree-select/style/css.js +11 -0
  126. package/es/components/tree-select/style/index.js +11 -0
  127. package/es/components/tree-select/tree-select-option.js +21 -0
  128. package/es/components/tree-select/tree-select.vue.js +4 -0
  129. package/es/components/tree-select/tree-select.vue2.js +81 -0
  130. package/es/components/tree-select/tree.js +137 -0
  131. package/es/components/tree-select/utils.js +45 -0
  132. package/es/hooks/index.js +25 -21
  133. package/es/hooks/use-focus/index.js +9 -0
  134. package/es/hooks/use-throttle-render/index.js +21 -0
  135. package/es/index.js +408 -368
  136. package/es/package.json.js +1 -1
  137. package/es/utils/helper.js +5 -2
  138. package/es/utils/index.js +48 -46
  139. package/lib/component.cjs +1 -1
  140. package/lib/components/affix/affix.cjs +1 -0
  141. package/lib/components/affix/affix.vue.cjs +1 -0
  142. package/lib/components/affix/affix.vue2.cjs +1 -0
  143. package/lib/components/affix/index.cjs +1 -0
  144. package/lib/components/affix/style/css.cjs +1 -0
  145. package/lib/components/affix/style/index.cjs +1 -0
  146. package/lib/components/back-top/back-top.vue2.cjs +1 -1
  147. package/lib/components/button/button.vue2.cjs +1 -1
  148. package/lib/components/button/use-button.cjs +1 -1
  149. package/lib/components/card/card.vue.cjs +1 -0
  150. package/lib/components/card/card.vue2.cjs +1 -0
  151. package/lib/components/card/index.cjs +1 -0
  152. package/lib/components/card/instance.cjs +1 -0
  153. package/lib/components/card/style/css.cjs +1 -0
  154. package/lib/components/card/style/index.cjs +1 -0
  155. package/lib/components/check-tag/check-tag.vue.cjs +1 -0
  156. package/lib/components/check-tag/check-tag.vue2.cjs +1 -0
  157. package/lib/components/check-tag/index.cjs +1 -0
  158. package/lib/components/check-tag/style/css.cjs +1 -0
  159. package/lib/components/check-tag/style/index.cjs +1 -0
  160. package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
  161. package/lib/components/context-menu/context-menu.vue2.cjs +1 -1
  162. package/lib/components/date-picker/composables/use-month-range-header.cjs +1 -1
  163. package/lib/components/date-picker/constants.cjs +1 -1
  164. package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
  165. package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
  166. package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
  167. package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
  168. package/lib/components/date-picker/date-picker.cjs +1 -1
  169. package/lib/components/date-picker/index.cjs +1 -1
  170. package/lib/components/date-picker/props/shared.cjs +1 -1
  171. package/lib/components/date-time-select/date-time-select.vue2.cjs +1 -1
  172. package/lib/components/dialog/dialog.vue2.cjs +1 -1
  173. package/lib/components/dialog/hooks/use-dialog.cjs +1 -1
  174. package/lib/components/dropdown/dropdown-menu.vue2.cjs +1 -1
  175. package/lib/components/footer-layout/footer-layout.vue2.cjs +1 -1
  176. package/lib/components/header-layout/header-layout.vue2.cjs +1 -1
  177. package/lib/components/horizontal-menu/constants.cjs +1 -0
  178. package/lib/components/horizontal-menu/horizontal-menu.vue2.cjs +1 -1
  179. package/lib/components/horizontal-menu/index.cjs +1 -1
  180. package/lib/components/index.cjs +1 -1
  181. package/lib/components/md-container/md-container.vue2.cjs +1 -1
  182. package/lib/components/menu/menu-item.vue2.cjs +1 -1
  183. package/lib/components/menu/menu.vue2.cjs +1 -1
  184. package/lib/components/menu/sub-menu.vue2.cjs +1 -1
  185. package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
  186. package/lib/components/option/style/css.cjs +1 -0
  187. package/lib/components/option/style/index.cjs +1 -0
  188. package/lib/components/option-group/style/css.cjs +1 -0
  189. package/lib/components/option-group/style/index.cjs +1 -0
  190. package/lib/components/popconfirm/index.cjs +1 -0
  191. package/lib/components/popconfirm/popconfirm.vue.cjs +1 -0
  192. package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -0
  193. package/lib/components/popconfirm/style/css.cjs +1 -0
  194. package/lib/components/popconfirm/style/index.cjs +1 -0
  195. package/lib/components/popover/style/index.cjs +1 -1
  196. package/lib/components/result/result.vue2.cjs +1 -1
  197. package/lib/components/roving-focus-group/roving-focus-item.vue2.cjs +1 -1
  198. package/lib/components/search/style/css.cjs +1 -1
  199. package/lib/components/search/style/index.cjs +1 -1
  200. package/lib/components/select/index.cjs +1 -0
  201. package/lib/components/select/option-group.vue.cjs +1 -0
  202. package/lib/components/select/option-group.vue2.cjs +1 -0
  203. package/lib/components/select/option.vue.cjs +1 -0
  204. package/lib/components/select/option.vue2.cjs +1 -0
  205. package/lib/components/select/options.cjs +1 -0
  206. package/lib/components/select/select-dropdown.vue.cjs +1 -0
  207. package/lib/components/select/select-dropdown.vue2.cjs +1 -0
  208. package/lib/components/select/select.vue.cjs +1 -0
  209. package/lib/components/select/select.vue2.cjs +1 -0
  210. package/lib/components/select/style/css.cjs +1 -0
  211. package/lib/components/select/style/index.cjs +1 -0
  212. package/lib/components/select/token.cjs +1 -0
  213. package/lib/components/select/useOption.cjs +1 -0
  214. package/lib/components/select/useSelect.cjs +1 -0
  215. package/lib/components/select-v2/select-dropdown.cjs +1 -1
  216. package/lib/components/select-v2/useSelect.cjs +1 -1
  217. package/lib/components/side-menu/side-menu.vue2.cjs +1 -1
  218. package/lib/components/skeleton/index.cjs +1 -0
  219. package/lib/components/skeleton/skeleton-item.vue.cjs +1 -0
  220. package/lib/components/skeleton/skeleton-item.vue2.cjs +1 -0
  221. package/lib/components/skeleton/skeleton.vue.cjs +1 -0
  222. package/lib/components/skeleton/skeleton.vue2.cjs +1 -0
  223. package/lib/components/skeleton/style/css.cjs +1 -0
  224. package/lib/components/skeleton/style/index.cjs +1 -0
  225. package/lib/components/skeleton-item/style/css.cjs +1 -0
  226. package/lib/components/skeleton-item/style/index.cjs +1 -0
  227. package/lib/components/space/index.cjs +1 -0
  228. package/lib/components/space/item.cjs +1 -0
  229. package/lib/components/space/space.cjs +1 -0
  230. package/lib/components/space/style/css.cjs +1 -0
  231. package/lib/components/space/style/index.cjs +1 -0
  232. package/lib/components/space/use-space.cjs +1 -0
  233. package/lib/components/switch/switch.vue2.cjs +1 -1
  234. package/lib/components/tabs/tab-nav.vue2.cjs +1 -1
  235. package/lib/components/tabs/tabs.vue2.cjs +1 -1
  236. package/lib/components/time-picker/common/picker.vue2.cjs +1 -1
  237. package/lib/components/time-picker/common/props.cjs +1 -1
  238. package/lib/components/time-picker/time-picker-com/panel-time-range.vue2.cjs +1 -1
  239. package/lib/components/time-picker/time-picker.cjs +1 -1
  240. package/lib/components/time-select/time-select.vue2.cjs +1 -1
  241. package/lib/components/tooltip/content.vue2.cjs +1 -1
  242. package/lib/components/tree/index.cjs +1 -0
  243. package/lib/components/tree/model/node.cjs +1 -0
  244. package/lib/components/tree/model/tree-store.cjs +1 -0
  245. package/lib/components/tree/model/useDragNode.cjs +1 -0
  246. package/lib/components/tree/model/useKeydown.cjs +1 -0
  247. package/lib/components/tree/model/useNodeExpandEventBroadcast.cjs +1 -0
  248. package/lib/components/tree/model/util.cjs +1 -0
  249. package/lib/components/tree/style/css.cjs +1 -0
  250. package/lib/components/tree/style/index.cjs +1 -0
  251. package/lib/components/tree/tree-node-content.vue.cjs +1 -0
  252. package/lib/components/tree/tree-node-content.vue2.cjs +1 -0
  253. package/lib/components/tree/tree-node.vue.cjs +1 -0
  254. package/lib/components/tree/tree-node.vue2.cjs +1 -0
  255. package/lib/components/tree/tree.type.cjs +1 -0
  256. package/lib/components/tree/tree.vue.cjs +1 -0
  257. package/lib/components/tree/tree.vue2.cjs +1 -0
  258. package/lib/components/tree-select/cache-options.cjs +1 -0
  259. package/lib/components/tree-select/index.cjs +1 -0
  260. package/lib/components/tree-select/select.cjs +1 -0
  261. package/lib/components/tree-select/style/css.cjs +1 -0
  262. package/lib/components/tree-select/style/index.cjs +1 -0
  263. package/lib/components/tree-select/tree-select-option.cjs +1 -0
  264. package/lib/components/tree-select/tree-select.vue.cjs +1 -0
  265. package/lib/components/tree-select/tree-select.vue2.cjs +1 -0
  266. package/lib/components/tree-select/tree.cjs +1 -0
  267. package/lib/components/tree-select/utils.cjs +1 -0
  268. package/lib/hooks/index.cjs +1 -1
  269. package/lib/hooks/use-focus/index.cjs +1 -0
  270. package/lib/hooks/use-throttle-render/index.cjs +1 -0
  271. package/lib/index.cjs +1 -1
  272. package/lib/package.json.cjs +1 -1
  273. package/lib/utils/helper.cjs +1 -1
  274. package/lib/utils/index.cjs +1 -1
  275. package/package.json +1 -1
  276. package/tags.json +1 -1
  277. package/theme-style/base.css +1 -1
  278. package/theme-style/index.css +1 -1
  279. package/theme-style/src/alert.scss +1 -1
  280. package/theme-style/src/autocomplete.scss +2 -2
  281. package/theme-style/src/breadcrumb.scss +4 -4
  282. package/theme-style/src/calendar.scss +2 -2
  283. package/theme-style/src/card.scss +1 -1
  284. package/theme-style/src/carousel.scss +1 -1
  285. package/theme-style/src/cascader.scss +3 -3
  286. package/theme-style/src/check-tag.scss +3 -3
  287. package/theme-style/src/checkbox.scss +1 -1
  288. package/theme-style/src/color-picker.scss +2 -2
  289. package/theme-style/src/common/var.scss +527 -521
  290. package/theme-style/src/date-picker/date-picker.scss +1 -1
  291. package/theme-style/src/date-picker/date-range-picker.scss +2 -2
  292. package/theme-style/src/date-picker/date-table.scss +1 -1
  293. package/theme-style/src/date-picker/month-table.scss +2 -2
  294. package/theme-style/src/date-picker/picker-panel.scss +4 -5
  295. package/theme-style/src/date-picker/picker.scss +7 -9
  296. package/theme-style/src/date-picker/time-picker.scss +2 -2
  297. package/theme-style/src/date-picker/time-spinner.scss +6 -8
  298. package/theme-style/src/date-picker/year-table.scss +3 -3
  299. package/theme-style/src/date-time-select.scss +3 -4
  300. package/theme-style/src/descriptions-item.scss +4 -4
  301. package/theme-style/src/descriptions.scss +2 -2
  302. package/theme-style/src/header-layout.scss +1 -1
  303. package/theme-style/src/horizontal-menu.scss +27 -39
  304. package/theme-style/src/image-viewer.scss +1 -1
  305. package/theme-style/src/index.scss +3 -0
  306. package/theme-style/src/input-number.scss +1 -1
  307. package/theme-style/src/menu.scss +76 -66
  308. package/theme-style/src/mixins/_var.scss +2 -2
  309. package/theme-style/src/mixins/mixins.scss +2 -2
  310. package/theme-style/src/popconfirm.scss +16 -0
  311. package/theme-style/src/popper.scss +4 -2
  312. package/theme-style/src/progress.scss +1 -1
  313. package/theme-style/src/reset.scss +3 -3
  314. package/theme-style/src/result.scss +2 -2
  315. package/theme-style/src/select-dropdown-v2.scss +1 -1
  316. package/theme-style/src/select-dropdown.scss +1 -1
  317. package/theme-style/src/select-v2.scss +2 -2
  318. package/theme-style/src/select.scss +4 -5
  319. package/theme-style/src/side-menu.scss +0 -1
  320. package/theme-style/src/skeleton-item.scss +83 -0
  321. package/theme-style/src/skeleton.scss +44 -0
  322. package/theme-style/src/step.scss +10 -10
  323. package/theme-style/src/tabs.scss +15 -155
  324. package/theme-style/src/timeline-item.scss +2 -2
  325. package/theme-style/src/transfer.scss +5 -5
  326. package/theme-style/src/tree.scss +2 -5
  327. package/theme-style/src/upload.scss +11 -11
  328. package/theme-style/src/var.scss +1 -1
  329. package/theme-style/vft-alert.css +1 -1
  330. package/theme-style/vft-autocomplete.css +1 -1
  331. package/theme-style/vft-breadcrumb.css +1 -1
  332. package/theme-style/vft-calendar.css +1 -1
  333. package/theme-style/vft-card.css +1 -1
  334. package/theme-style/vft-carousel.css +1 -1
  335. package/theme-style/vft-cascader.css +1 -1
  336. package/theme-style/vft-check-tag.css +1 -1
  337. package/theme-style/vft-checkbox.css +1 -1
  338. package/theme-style/vft-color-picker.css +1 -1
  339. package/theme-style/vft-date-picker.css +1 -1
  340. package/theme-style/vft-date-time-select.css +1 -1
  341. package/theme-style/vft-descriptions-item.css +1 -1
  342. package/theme-style/vft-descriptions.css +1 -1
  343. package/theme-style/vft-header-layout.css +1 -1
  344. package/theme-style/vft-horizontal-menu.css +1 -1
  345. package/theme-style/vft-image-viewer.css +1 -1
  346. package/theme-style/vft-input-number.css +1 -1
  347. package/theme-style/vft-menu.css +1 -1
  348. package/theme-style/vft-popconfirm.css +1 -0
  349. package/theme-style/vft-popper.css +1 -1
  350. package/theme-style/vft-progress.css +1 -1
  351. package/theme-style/vft-reset.css +1 -1
  352. package/theme-style/vft-result.css +1 -1
  353. package/theme-style/vft-select-dropdown-v2.css +1 -1
  354. package/theme-style/vft-select-dropdown.css +1 -1
  355. package/theme-style/vft-select-v2.css +1 -1
  356. package/theme-style/vft-select.css +1 -1
  357. package/theme-style/vft-side-menu.css +1 -1
  358. package/theme-style/vft-skeleton-item.css +1 -0
  359. package/theme-style/vft-skeleton.css +1 -0
  360. package/theme-style/vft-step.css +1 -1
  361. package/theme-style/vft-tabs.css +1 -1
  362. package/theme-style/vft-time-picker.css +1 -1
  363. package/theme-style/vft-time-select.css +1 -1
  364. package/theme-style/vft-timeline-item.css +1 -1
  365. package/theme-style/vft-transfer.css +1 -1
  366. package/theme-style/vft-tree.css +1 -1
  367. package/theme-style/vft-upload.css +1 -1
  368. package/theme-style/vft-var.css +1 -1
  369. package/web-types.json +1 -1
@@ -0,0 +1,182 @@
1
+ import { defineComponent as P, renderSlot as T, createVNode as c, isVNode as b, createTextVNode as A } from "vue";
2
+ import { isArray as p, isNumber as m, isString as L } from "@vft/utils";
3
+ import { PatchFlags as r, isFragment as h, isValidElementNode as C } from "../../utils/vue/vnode.js";
4
+ import { buildProps as O, definePropType as d } from "../../utils/vue/props/runtime.js";
5
+ import "@vueuse/core";
6
+ import { componentSizes as V } from "../../constants/size.js";
7
+ import "../../utils/ns-cover.js";
8
+ import "lodash";
9
+ import g from "./item.js";
10
+ import { useSpace as x } from "./use-space.js";
11
+ const z = O({
12
+ /**
13
+ * @description Placement direction
14
+ */
15
+ direction: {
16
+ type: String,
17
+ values: ["horizontal", "vertical"],
18
+ default: "horizontal"
19
+ },
20
+ /**
21
+ * @description Classname
22
+ */
23
+ class: {
24
+ type: d([
25
+ String,
26
+ Object,
27
+ Array
28
+ ]),
29
+ default: ""
30
+ },
31
+ /**
32
+ * @description Extra style rules
33
+ */
34
+ style: {
35
+ type: d([String, Array, Object]),
36
+ default: ""
37
+ },
38
+ /**
39
+ * @description Controls the alignment of items
40
+ */
41
+ alignment: {
42
+ type: String,
43
+ default: "center"
44
+ },
45
+ /**
46
+ * @description Prefix for space-items
47
+ */
48
+ prefixCls: {
49
+ type: String
50
+ },
51
+ /**
52
+ * @description Spacer
53
+ */
54
+ spacer: {
55
+ type: d([Object, String, Number, Array]),
56
+ default: null,
57
+ validator: (e) => b(e) || m(e) || L(e)
58
+ },
59
+ /**
60
+ * @description Auto wrapping
61
+ */
62
+ wrap: Boolean,
63
+ /**
64
+ * @description Whether to fill the container
65
+ */
66
+ fill: Boolean,
67
+ /**
68
+ * @description Ratio of fill
69
+ */
70
+ fillRatio: {
71
+ type: Number,
72
+ default: 100
73
+ },
74
+ /**
75
+ * @description Spacing size
76
+ */
77
+ size: {
78
+ type: [String, Array, Number],
79
+ values: V,
80
+ validator: (e) => m(e) || p(e) && e.length === 2 && e.every(m)
81
+ }
82
+ }), q = P({
83
+ name: "VftSpace",
84
+ props: z,
85
+ setup(e, { slots: v }) {
86
+ const { classes: E, containerStyle: N, itemStyle: u } = x(e);
87
+ function y(n, a = "", t = []) {
88
+ const { prefixCls: i } = e;
89
+ return n.forEach((l, f) => {
90
+ h(l) ? p(l.children) && l.children.forEach((o, s) => {
91
+ h(o) && p(o.children) ? y(
92
+ o.children,
93
+ `${a + s}-`,
94
+ t
95
+ ) : t.push(
96
+ c(
97
+ g,
98
+ {
99
+ style: u.value,
100
+ prefixCls: i,
101
+ key: `nested-${a + s}`
102
+ },
103
+ {
104
+ default: () => [o]
105
+ },
106
+ r.PROPS | r.STYLE,
107
+ ["style", "prefixCls"]
108
+ )
109
+ );
110
+ }) : C(l) && t.push(
111
+ c(
112
+ g,
113
+ {
114
+ style: u.value,
115
+ prefixCls: i,
116
+ key: `LoopKey${a + f}`
117
+ },
118
+ {
119
+ default: () => [l]
120
+ },
121
+ r.PROPS | r.STYLE,
122
+ ["style", "prefixCls"]
123
+ )
124
+ );
125
+ }), t;
126
+ }
127
+ return () => {
128
+ const { spacer: n, direction: a } = e, t = T(v, "default", { key: 0 }, () => []);
129
+ if ((t.children ?? []).length === 0)
130
+ return null;
131
+ if (p(t.children)) {
132
+ let i = y(t.children);
133
+ if (n) {
134
+ const l = i.length - 1;
135
+ i = i.reduce(
136
+ (f, o, s) => {
137
+ const S = [...f, o];
138
+ return s !== l && S.push(
139
+ c(
140
+ "span",
141
+ // adding width 100% for vertical alignment,
142
+ // when the spacer inherit the width from the
143
+ // parent, this span's width was not set, so space
144
+ // might disappear
145
+ {
146
+ style: [
147
+ u.value,
148
+ a === "vertical" ? "width: 100%" : null
149
+ ],
150
+ key: s
151
+ },
152
+ [
153
+ // if spacer is already a valid vnode, then append it to the current
154
+ // span element.
155
+ // otherwise, treat it as string.
156
+ b(n) ? n : A(n, r.TEXT)
157
+ ],
158
+ r.STYLE
159
+ )
160
+ ), S;
161
+ },
162
+ []
163
+ );
164
+ }
165
+ return c(
166
+ "div",
167
+ {
168
+ class: E.value,
169
+ style: N.value
170
+ },
171
+ i,
172
+ r.STYLE | r.CLASS
173
+ );
174
+ }
175
+ return t.children;
176
+ };
177
+ }
178
+ });
179
+ export {
180
+ q as default,
181
+ z as spaceProps
182
+ };
@@ -0,0 +1,2 @@
1
+ import "vft/theme-style/base.css";
2
+ import "vft/theme-style/vft-space.css";
@@ -0,0 +1,2 @@
1
+ import "vft/theme-style/src/base.scss";
2
+ import "vft/theme-style/src/space.scss";
@@ -0,0 +1,44 @@
1
+ import { computed as o, ref as m, watchEffect as S } from "vue";
2
+ import { isArray as h, isNumber as p } from "@vft/utils";
3
+ import { useNamespace as w } from "../../hooks/use-namespace/index.js";
4
+ import "@popperjs/core";
5
+ import "lodash";
6
+ import "../../hooks/use-z-index/index.js";
7
+ import "@vueuse/core";
8
+ import "../../utils/ns-cover.js";
9
+ const c = {
10
+ small: 8,
11
+ default: 12,
12
+ large: 16
13
+ };
14
+ function I(e) {
15
+ const r = w("space"), u = o(() => [r.b(), r.m(e.direction), e.class]), a = m(0), i = m(0), f = o(() => {
16
+ const t = e.wrap || e.fill ? { flexWrap: "wrap", marginBottom: `-${i.value}px` } : {}, n = {
17
+ alignItems: e.alignment
18
+ };
19
+ return [t, n, e.style];
20
+ }), v = o(() => {
21
+ const t = {
22
+ paddingBottom: `${i.value}px`,
23
+ marginRight: `${a.value}px`
24
+ }, n = e.fill ? { flexGrow: 1, minWidth: `${e.fillRatio}%` } : {};
25
+ return [t, n];
26
+ });
27
+ return S(() => {
28
+ const { size: t = "small", wrap: n, direction: s, fill: d } = e;
29
+ if (h(t)) {
30
+ const [l = 0, g = 0] = t;
31
+ a.value = l, i.value = g;
32
+ } else {
33
+ let l;
34
+ p(t) ? l = t : l = c[t || "small"] || c.small, (n || d) && s === "horizontal" ? a.value = i.value = l : s === "horizontal" ? (a.value = l, i.value = 0) : (i.value = l, a.value = 0);
35
+ }
36
+ }), {
37
+ classes: u,
38
+ containerStyle: f,
39
+ itemStyle: v
40
+ };
41
+ }
42
+ export {
43
+ I as useSpace
44
+ };
@@ -3,10 +3,10 @@ import { singleAttrToObj as G, addUnit as ie, isPromise as H, isBoolean as ne }
3
3
  import { debugWarn as L, throwError as le } from "../../utils/error.js";
4
4
  import "lodash";
5
5
  import "@vueuse/core";
6
+ import { UPDATE_MODEL_EVENT as P, CHANGE_EVENT as S, INPUT_EVENT as z } from "../../constants/event.js";
6
7
  import "../../utils/ns-cover.js";
7
8
  import { VftIcon as g } from "../icon/index.js";
8
9
  import "../form/index.js";
9
- import { UPDATE_MODEL_EVENT as P, CHANGE_EVENT as S, INPUT_EVENT as z } from "../../constants/event.js";
10
10
  import { useNamespace as oe } from "../../hooks/use-namespace/index.js";
11
11
  import "@popperjs/core";
12
12
  import "../../hooks/use-z-index/index.js";
@@ -2,7 +2,7 @@ import { defineComponent as E, getCurrentInstance as Z, inject as _, ref as g, c
2
2
  import { capitalize as $ } from "@vft/utils";
3
3
  import { throwError as it } from "../../utils/error.js";
4
4
  import "lodash";
5
- import { useDocumentVisibility as nt, useWindowFocus as lt, useResizeObserver as at } from "@vueuse/core";
5
+ import { useDocumentVisibility as nt, useWindowFocus as rt, useResizeObserver as lt } from "@vueuse/core";
6
6
  import "../../utils/ns-cover.js";
7
7
  import "../divider/index.js";
8
8
  import { VftIcon as B } from "../icon/index.js";
@@ -55,6 +55,8 @@ import "../virtual-list/components/fixed-size-grid.js";
55
55
  import "../virtual-list/components/dynamic-size-grid.js";
56
56
  import "../virtual-list/props.js";
57
57
  import "../select-v2/index.js";
58
+ import "../select/index.js";
59
+ import "../tree-select/index.js";
58
60
  import "../verify-code/index.js";
59
61
  import "../table/index.js";
60
62
  import "../image-viewer/index.js";
@@ -66,6 +68,12 @@ import "../row/index.js";
66
68
  import "../horizontal-menu/index.js";
67
69
  import "../time-picker/index.js";
68
70
  import "../date-picker/index.js";
71
+ import "../check-tag/index.js";
72
+ import "../tree/index.js";
73
+ import "../skeleton/index.js";
74
+ import "../space/index.js";
75
+ import "../card/index.js";
76
+ import "../popconfirm/index.js";
69
77
  import "../md-container/index.js";
70
78
  import "../md-comment/index.js";
71
79
  import "../md-tabs/index.js";
@@ -77,14 +85,14 @@ import { useNamespace as K } from "../../hooks/use-namespace/index.js";
77
85
  import "@popperjs/core";
78
86
  import "../../hooks/use-z-index/index.js";
79
87
  import { EVENT_CODE as T } from "@vft/constants";
80
- import { TabsRootContextKey as rt } from "./types.js";
88
+ import { TabsRootContextKey as at } from "./types.js";
81
89
  import st from "./tab-bar.vue2.js";
82
90
  const V = (
83
91
  /* hoist-static*/
84
92
  K("tab-nav")
85
93
  ), ct = E({
86
94
  name: V.b()
87
- }), Ko = /* @__PURE__ */ E({
95
+ }), Uo = /* @__PURE__ */ E({
88
96
  ...ct,
89
97
  props: {
90
98
  panes: null,
@@ -112,9 +120,9 @@ const V = (
112
120
  emit: h
113
121
  }) {
114
122
  var A;
115
- const M = Z(), d = _(rt);
123
+ const M = Z(), d = _(at);
116
124
  d || it(V.b(), "<vft-tabs><tab-nav /></vft-tabs>");
117
- const e = K("tabs"), q = nt(), H = lt(), y = g(), v = g(), C = g(), m = g(!1), f = g(0), k = g(!1), x = g(!0), w = I(() => ["top", "bottom"].includes(d.props.tabPosition) ? "width" : "height"), W = I(() => ({
125
+ const e = K("tabs"), q = nt(), H = rt(), y = g(), v = g(), C = g(), m = g(!1), f = g(0), k = g(!1), x = g(!0), w = I(() => ["top", "bottom"].includes(d.props.tabPosition) ? "width" : "height"), W = I(() => ({
118
126
  transform: `translate${w.value === "width" ? "X" : "Y"}(-${f.value}px)`
119
127
  })), j = () => {
120
128
  if (!v.value)
@@ -134,9 +142,9 @@ const V = (
134
142
  const t = y.value.querySelector(".is-active");
135
143
  if (!t)
136
144
  return;
137
- const i = v.value, b = ["top", "bottom"].includes(d.props.tabPosition), r = t.getBoundingClientRect(), l = i.getBoundingClientRect(), u = b ? o.offsetWidth - l.width : o.offsetHeight - l.height, c = f.value;
138
- let a = c;
139
- b ? (r.left < l.left && (a = c - (l.left - r.left)), r.right > l.right && (a = c + r.right - l.right)) : (r.top < l.top && (a = c - (l.top - r.top)), r.bottom > l.bottom && (a = c + (r.bottom - l.bottom))), a = Math.max(a, 0), f.value = Math.min(a, u);
145
+ const i = v.value, b = ["top", "bottom"].includes(d.props.tabPosition), a = t.getBoundingClientRect(), r = i.getBoundingClientRect(), u = b ? o.offsetWidth - r.width : o.offsetHeight - r.height, c = f.value;
146
+ let l = c;
147
+ b ? (a.left < r.left && (l = c - (r.left - a.left)), a.right > r.right && (l = c + a.right - r.right)) : (a.top < r.top && (l = c - (r.top - a.top)), a.bottom > r.bottom && (l = c + (a.bottom - r.bottom))), l = Math.max(l, 0), f.value = Math.min(l, u);
140
148
  }, z = () => {
141
149
  if (!C.value || !v.value)
142
150
  return;
@@ -146,14 +154,14 @@ const V = (
146
154
  const t = o.code, {
147
155
  up: i,
148
156
  down: b,
149
- left: r,
150
- right: l
157
+ left: a,
158
+ right: r
151
159
  } = T;
152
- if (![i, b, r, l].includes(t))
160
+ if (![i, b, a, r].includes(t))
153
161
  return;
154
162
  const u = Array.from(o.currentTarget.querySelectorAll("[role=tab]:not(.is-disabled)")), c = u.indexOf(o.target);
155
- let a;
156
- t === r || t === i ? c === 0 ? a = u.length - 1 : a = c - 1 : c < u.length - 1 ? a = c + 1 : a = 0, u[a].focus(), u[a].click(), P();
163
+ let l;
164
+ t === a || t === i ? c === 0 ? l = u.length - 1 : l = c - 1 : c < u.length - 1 ? l = c + 1 : l = 0, u[l].focus(), u[l].click(), P();
157
165
  }, P = () => {
158
166
  x.value && (k.value = !0);
159
167
  }, S = () => k.value = !1;
@@ -161,7 +169,7 @@ const V = (
161
169
  o === "hidden" ? x.value = !1 : o === "visible" && setTimeout(() => x.value = !0, 50);
162
170
  }), O(H, (o) => {
163
171
  o ? setTimeout(() => x.value = !0, 50) : x.value = !1;
164
- }), at(y, z), tt(() => setTimeout(() => R(), 0)), ot(() => z()), D({
172
+ }), lt(y, z), tt(() => setTimeout(() => R(), 0)), ot(() => z()), D({
165
173
  scrollToActiveTab: R,
166
174
  removeFocus: S
167
175
  }), O(() => n.panes, () => M.update(), {
@@ -180,25 +188,25 @@ const V = (
180
188
  var o;
181
189
  return (o = n.panes) == null ? void 0 : o.map((t, i) => {
182
190
  var N, F, L;
183
- const b = t.uid, r = t.props.disabled, l = t.props.name ?? t.index ?? `${i}`, u = !r && (t.isClosable || n.editable);
191
+ const b = t.uid, a = t.props.disabled, r = t.props.name ?? t.index ?? `${i}`, u = !a && (t.isClosable || n.editable);
184
192
  t.index = `${i}`;
185
193
  const c = u ? s("span", {
186
194
  class: "is-icon-close",
187
195
  onClick: (p) => h("tabRemove", t, p)
188
- }, [(N = n.closeIconCfg) != null && N.icon ? s(B, n.closeIconCfg, null) : null]) : null, a = ((L = (F = t.slots).label) == null ? void 0 : L.call(F)) || t.props.label, Q = !r && t.active ? 0 : -1;
196
+ }, [(N = n.closeIconCfg) != null && N.icon ? s(B, n.closeIconCfg, null) : null]) : null, l = ((L = (F = t.slots).label) == null ? void 0 : L.call(F)) || t.props.label, Q = !a && t.active ? 0 : -1;
189
197
  return s("div", {
190
198
  ref: `tab-${b}`,
191
- class: [e.e("item"), e.is(d.props.tabPosition), e.is("active", t.active), e.is("disabled", r), e.is("closable", u), e.is("focus", k.value)],
192
- id: `tab-${l}`,
199
+ class: [e.e("item"), e.is(d.props.tabPosition), e.is("active", t.active), e.is("disabled", a), e.is("closable", u), e.is("focus", k.value)],
200
+ id: `tab-${r}`,
193
201
  key: `tab-${b}`,
194
- "aria-controls": `pane-${l}`,
202
+ "aria-controls": `pane-${r}`,
195
203
  role: "tab",
196
204
  "aria-selected": t.active,
197
205
  tabindex: Q,
198
206
  onFocus: () => P(),
199
207
  onBlur: () => S(),
200
208
  onClick: (p) => {
201
- S(), h("tabClick", t, l, p);
209
+ S(), h("tabClick", t, r, p);
202
210
  },
203
211
  onContextmenu: (p) => {
204
212
  p.preventDefault(), h("tabContextmenu", {
@@ -210,7 +218,7 @@ const V = (
210
218
  onKeydown: (p) => {
211
219
  u && (p.code === T.delete || p.code === T.backspace) && h("tabRemove", t, p);
212
220
  }
213
- }, [a, c]);
221
+ }, [l, c]);
214
222
  });
215
223
  }), J = n.editable || n.addable ? s("span", {
216
224
  class: e.e("new-tab"),
@@ -238,5 +246,5 @@ const V = (
238
246
  }
239
247
  });
240
248
  export {
241
- Ko as default
249
+ Uo as default
242
250
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as w, getCurrentInstance as g, useSlots as M, ref as h, watch as p, nextTick as D, computed as i, createVNode as s, provide as F } from "vue";
1
+ import { defineComponent as w, getCurrentInstance as g, useSlots as M, ref as h, watch as p, nextTick as D, computed as l, createVNode as s, provide as F } from "vue";
2
2
  import { useNamespace as O } from "../../hooks/use-namespace/index.js";
3
3
  import "@popperjs/core";
4
4
  import "lodash";
@@ -40,7 +40,7 @@ const d = (
40
40
  },
41
41
  showBar: {
42
42
  type: Boolean,
43
- default: !1
43
+ default: !0
44
44
  },
45
45
  closeIconCfg: null,
46
46
  addIconCfg: null,
@@ -48,49 +48,49 @@ const d = (
48
48
  arrowRightIconCfg: null
49
49
  },
50
50
  emits: {
51
- [$]: (a) => f(a),
51
+ [$]: (t) => f(t),
52
52
  /** 点击 */
53
- tabClick: (a, c) => c instanceof Event,
53
+ tabClick: (t, c) => c instanceof Event,
54
54
  /** 右键点击 */
55
- tabContextMenu: (a, c, t) => t instanceof Event,
56
- tabChange: (a) => f(a),
57
- edit: (a, c) => ["remove", "add"].includes(c),
55
+ tabContextMenu: (t, c, a) => a instanceof Event,
56
+ tabChange: (t) => f(t),
57
+ edit: (t, c) => ["remove", "add"].includes(c),
58
58
  /** 移除 */
59
- tabRemove: (a) => f(a),
59
+ tabRemove: (t) => f(t),
60
60
  /** 增加 */
61
61
  tabAdd: () => !0
62
62
  },
63
- setup(a, {
63
+ setup(t, {
64
64
  expose: c,
65
- emit: t
65
+ emit: a
66
66
  }) {
67
- const T = g(), l = M(), u = h(), r = h(a.modelValue ?? "0"), y = (e) => {
68
- r.value = e, t("update:modelValue", e), t("tabChange", e);
67
+ const T = g(), i = M(), u = h(), r = h(t.modelValue ?? "0"), y = (e) => {
68
+ r.value = e, a("update:modelValue", e), a("tabChange", e);
69
69
  }, m = async (e) => {
70
70
  var n, o, v;
71
71
  if (!(r.value === e || I(e)))
72
72
  try {
73
- await ((n = a.beforeLeave) == null ? void 0 : n.call(a, e, r.value)) !== !1 && (y(e), (v = (o = u.value) == null ? void 0 : o.removeFocus) == null || v.call(o));
73
+ await ((n = t.beforeLeave) == null ? void 0 : n.call(t, e, r.value)) !== !1 && (y(e), (v = (o = u.value) == null ? void 0 : o.removeFocus) == null || v.call(o));
74
74
  } catch {
75
75
  }
76
76
  }, R = (e, n, o) => {
77
- e.props.disabled || (m(n), t("tabClick", e, o));
77
+ e.props.disabled || (m(n), a("tabClick", e, o));
78
78
  }, L = (e, n) => {
79
- e.props.disabled || I(e.props.name) || (n.stopPropagation(), t("edit", e.props.name, "remove"), t("tabRemove", e.props.name));
79
+ e.props.disabled || I(e.props.name) || (n.stopPropagation(), a("edit", e.props.name, "remove"), a("tabRemove", e.props.name));
80
80
  };
81
- p(() => a.modelValue, (e) => m(e)), p(r, async () => {
81
+ p(() => t.modelValue, (e) => m(e)), p(r, async () => {
82
82
  var e;
83
83
  await D(), (e = u.value) == null || e.scrollToActiveTab();
84
84
  });
85
85
  const N = () => {
86
- t("edit", void 0, "add"), t("tabAdd");
86
+ a("edit", void 0, "add"), a("tabAdd");
87
87
  }, x = (e, n, o) => {
88
- t("tabContextMenu", e, n, o);
89
- }, b = i(() => {
88
+ a("tabContextMenu", e, n, o);
89
+ }, b = l(() => {
90
90
  var e;
91
91
  return s("div", {
92
92
  class: d.e("content")
93
- }, [(e = l.default) == null ? void 0 : e.call(l)]);
93
+ }, [(e = i.default) == null ? void 0 : e.call(i)]);
94
94
  }), {
95
95
  children: B,
96
96
  addChild: P,
@@ -104,47 +104,47 @@ const d = (
104
104
  }), c({
105
105
  currentName: r
106
106
  });
107
- const E = i(() => ({
107
+ const E = l(() => ({
108
108
  icon: "ico-ep:plus",
109
109
  size: 12,
110
- ...a.addIconCfg
111
- })), V = i(() => ({
110
+ ...t.addIconCfg
111
+ })), V = l(() => ({
112
112
  icon: "ico-ep:close",
113
113
  size: 14,
114
- ...a.closeIconCfg
115
- })), k = i(() => ({
114
+ ...t.closeIconCfg
115
+ })), k = l(() => ({
116
116
  icon: "ico-ep:arrow-left",
117
117
  size: 18,
118
- ...a.arrowLeftIconCfg
119
- })), z = i(() => ({
118
+ ...t.arrowLeftIconCfg
119
+ })), z = l(() => ({
120
120
  icon: "ico-ep:arrow-right",
121
121
  size: 18,
122
- ...a.arrowRightIconCfg
123
- })), C = i(() => {
122
+ ...t.arrowRightIconCfg
123
+ })), C = l(() => {
124
124
  var e;
125
125
  return s("div", {
126
- class: [d.e("header"), d.is(a.tabPosition)]
126
+ class: [d.e("header"), d.is(t.tabPosition)]
127
127
  }, [s(K, {
128
128
  ref: u,
129
129
  currentName: r.value,
130
130
  panes: B.value,
131
- stretch: a.stretch,
132
- showBar: a.showBar,
131
+ stretch: t.stretch,
132
+ showBar: t.showBar,
133
133
  closeIconCfg: V.value,
134
134
  addIconCfg: E.value,
135
135
  arrowRightIconCfg: z.value,
136
136
  arrowLeftIconCfg: k.value,
137
- editable: a.editable,
138
- addable: a.addable,
137
+ editable: t.editable,
138
+ addable: t.addable,
139
139
  onTabClick: R,
140
140
  onTabRemove: L,
141
141
  onTabAdd: N,
142
142
  onTabContextmenu: x
143
- }, null), (e = l.headerRight) == null ? void 0 : e.call(l)]);
143
+ }, null), (e = i.headerRight) == null ? void 0 : e.call(i)]);
144
144
  });
145
145
  return () => s("div", {
146
- class: [d.b(), d.m(a.tabPosition)]
147
- }, [...a.tabPosition !== "bottom" ? [C.value, b.value] : [b.value, C.value]]);
146
+ class: [d.b(), d.m(t.tabPosition)]
147
+ }, [...t.tabPosition !== "bottom" ? [C.value, b.value] : [b.value, C.value]]);
148
148
  }
149
149
  });
150
150
  export {