vft 0.0.89 → 0.0.91

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 (240) hide show
  1. package/attributes.json +1 -1
  2. package/es/comp-resolver.js +20 -29
  3. package/es/components/affix/affix.vue2.js +34 -34
  4. package/es/components/alert/alert.vue2.js +44 -44
  5. package/es/components/avatar/avatar.vue2.js +28 -28
  6. package/es/components/backtop/backtop.vue2.js +11 -11
  7. package/es/components/button/button-group.vue2.js +8 -8
  8. package/es/components/button/button.vue2.js +39 -39
  9. package/es/components/card/card.vue2.js +20 -20
  10. package/es/components/check-tag/check-tag.vue2.js +14 -14
  11. package/es/components/checkbox/checkbox-button.vue2.js +61 -61
  12. package/es/components/checkbox/checkbox-group.vue2.js +27 -27
  13. package/es/components/checkbox/checkbox.vue2.js +81 -81
  14. package/es/components/clamp/clamp.vue2.js +59 -59
  15. package/es/components/clamp-toggle/clamp-toggle.vue2.js +25 -25
  16. package/es/components/col/col.vue2.js +33 -33
  17. package/es/components/color-picker/color-picker.vue2.js +126 -126
  18. package/es/components/color-picker/components/alpha-slider.vue2.js +12 -12
  19. package/es/components/config-provider/config-provider.vue2.js +29 -29
  20. package/es/components/container/aside.vue2.js +9 -9
  21. package/es/components/container/container.vue2.js +11 -11
  22. package/es/components/container/footer.vue2.js +8 -8
  23. package/es/components/container/header.vue2.js +9 -9
  24. package/es/components/context-menu/context-menu.vue2.js +29 -29
  25. package/es/components/date-picker/date-picker-com/basic-date-table.vue2.js +53 -53
  26. package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +19 -19
  27. package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +32 -32
  28. package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +168 -168
  29. package/es/components/date-picker/date-picker-com/panel-date-range.vue2.js +89 -89
  30. package/es/components/date-picker/date-picker-com/panel-month-range.vue2.js +38 -38
  31. package/es/components/descriptions/description-item.vue2.js +16 -16
  32. package/es/components/descriptions/description.vue2.js +54 -54
  33. package/es/components/descriptions/descriptions-row.vue2.js +24 -24
  34. package/es/components/dialog/dialog-content.vue2.js +30 -30
  35. package/es/components/dialog/dialog.vue2.js +64 -64
  36. package/es/components/divider/divider.vue2.js +20 -20
  37. package/es/components/dropdown/dropdown.vue.js +2 -127
  38. package/es/components/dropdown/dropdown.vue2.js +234 -181
  39. package/es/components/dropdown/index.js +10 -17
  40. package/es/components/dropdown/style/css.js +5 -0
  41. package/es/components/dropdown/style/index.js +5 -0
  42. package/es/components/dropdown/tokens.js +1 -1
  43. package/es/components/empty/empty.vue2.js +27 -27
  44. package/es/components/exception/exception.vue2.js +19 -19
  45. package/es/components/footer-layout/footer-layout.vue2.js +1 -1
  46. package/es/components/form/form-item.vue2.js +77 -77
  47. package/es/components/form/form.vue2.js +37 -37
  48. package/es/components/full-screen/full-screen.vue2.js +26 -15
  49. package/es/components/header-layout/header-layout.vue2.js +27 -27
  50. package/es/components/horizontal-menu/horizontal-menu.vue2.js +43 -43
  51. package/es/components/icon/icon.vue2.js +24 -24
  52. package/es/components/icon-text/icon-text.vue2.js +27 -27
  53. package/es/components/iframe-layout/iframe-layout.vue2.js +18 -18
  54. package/es/components/iframe-layout/iframe-page.vue2.js +11 -11
  55. package/es/components/image/image.vue2.js +73 -73
  56. package/es/components/image-viewer/image-viewer.vue2.js +109 -109
  57. package/es/components/index.js +145 -150
  58. package/es/components/input/input.vue2.js +175 -175
  59. package/es/components/link/link.vue2.js +27 -27
  60. package/es/components/list-cell/list-cell.vue2.js +8 -8
  61. package/es/components/logo/logo.vue2.js +27 -27
  62. package/es/components/md-container/md-container.vue2.js +1 -1
  63. package/es/components/md-vue-playground/md-vue-playground.vue2.js +16 -16
  64. package/es/components/menu/menu-item-group.vue2.js +15 -15
  65. package/es/components/menu/menu-item.vue2.js +56 -56
  66. package/es/components/menu/menu.vue2.js +20 -20
  67. package/es/components/menu/sub-menu.vue2.js +16 -16
  68. package/es/components/message/message.vue2.js +81 -81
  69. package/es/components/multiple-tabs/multiple-tabs.vue2.js +12 -12
  70. package/es/components/multiple-tabs/tab-content.vue2.js +16 -16
  71. package/es/components/overlay/overlay.vue2.js +14 -14
  72. package/es/components/page-wrapper/page-wrapper.vue2.js +12 -12
  73. package/es/components/pagination/components/jumper.vue2.js +22 -22
  74. package/es/components/pagination/components/next.vue2.js +12 -12
  75. package/es/components/pagination/components/pager.vue2.js +75 -75
  76. package/es/components/pagination/components/prev.vue2.js +13 -13
  77. package/es/components/pagination/components/sizes.vue2.js +11 -11
  78. package/es/components/pagination/components/total.vue2.js +8 -8
  79. package/es/components/pagination/pagination.vue2.js +28 -28
  80. package/es/components/popconfirm/popconfirm.vue2.js +50 -50
  81. package/es/components/popover/popover.vue2.js +44 -44
  82. package/es/components/popper/arrow.vue2.js +2 -2
  83. package/es/components/popper/content.vue2.js +34 -34
  84. package/es/components/popper/popper.vue2.js +5 -5
  85. package/es/components/popper/trigger.vue2.js +48 -48
  86. package/es/components/qrcode/qrcode.vue2.js +35 -35
  87. package/es/components/radio/radio-button.vue2.js +28 -28
  88. package/es/components/radio/radio-group.vue2.js +26 -26
  89. package/es/components/radio/radio.vue2.js +44 -44
  90. package/es/components/result/result.vue2.js +10 -10
  91. package/es/components/router-view-content/router-view-content.vue2.js +20 -20
  92. package/es/components/row/row.vue2.js +19 -19
  93. package/es/components/scrollbar/bar.vue2.js +19 -19
  94. package/es/components/scrollbar/scrollbar.vue2.js +67 -67
  95. package/es/components/scrollbar/thumb.vue2.js +41 -41
  96. package/es/components/search/search.vue2.js +65 -65
  97. package/es/components/side-menu/side-menu.vue2.js +36 -36
  98. package/es/components/skeleton/skeleton-item.vue2.js +13 -13
  99. package/es/components/skeleton/skeleton.vue2.js +19 -19
  100. package/es/components/switch/switch.vue2.js +128 -128
  101. package/es/components/table/index.js +5 -3
  102. package/es/components/table/table.vue2.js +70 -70
  103. package/es/components/tabs/tab-bar.vue2.js +15 -15
  104. package/es/components/tabs/tab-nav.vue2.js +33 -33
  105. package/es/components/tabs/tab-pane.vue2.js +21 -21
  106. package/es/components/tabs/tabs.vue2.js +64 -66
  107. package/es/components/tag/tag.vue2.js +7 -7
  108. package/es/components/time-picker/common/picker.vue2.js +14 -14
  109. package/es/components/time-picker/time-picker-com/basic-time-spinner.vue2.js +60 -60
  110. package/es/components/time-picker/time-picker-com/panel-time-pick.vue2.js +30 -30
  111. package/es/components/time-picker/time-picker-com/panel-time-range.vue2.js +57 -57
  112. package/es/components/time-select/time-select.vue2.js +29 -29
  113. package/es/components/tooltip/constants.js +1 -1
  114. package/es/components/tooltip/content.vue2.js +73 -73
  115. package/es/components/tooltip/tooltip.vue2.js +91 -91
  116. package/es/components/tooltip/trigger.vue2.js +33 -33
  117. package/es/components/verify-code/verify-code.vue2.js +25 -25
  118. package/es/index.js +208 -213
  119. package/es/package.json.js +1 -1
  120. package/lib/comp-resolver.cjs +1 -1
  121. package/lib/components/affix/affix.vue2.cjs +1 -1
  122. package/lib/components/alert/alert.vue2.cjs +1 -1
  123. package/lib/components/avatar/avatar.vue2.cjs +1 -1
  124. package/lib/components/backtop/backtop.vue2.cjs +1 -1
  125. package/lib/components/button/button-group.vue2.cjs +1 -1
  126. package/lib/components/button/button.vue2.cjs +1 -1
  127. package/lib/components/card/card.vue2.cjs +1 -1
  128. package/lib/components/check-tag/check-tag.vue2.cjs +1 -1
  129. package/lib/components/checkbox/checkbox-button.vue2.cjs +1 -1
  130. package/lib/components/checkbox/checkbox-group.vue2.cjs +1 -1
  131. package/lib/components/checkbox/checkbox.vue2.cjs +1 -1
  132. package/lib/components/clamp/clamp.vue2.cjs +1 -1
  133. package/lib/components/clamp-toggle/clamp-toggle.vue2.cjs +1 -1
  134. package/lib/components/col/col.vue2.cjs +1 -1
  135. package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
  136. package/lib/components/color-picker/components/alpha-slider.vue2.cjs +1 -1
  137. package/lib/components/config-provider/config-provider.vue2.cjs +1 -1
  138. package/lib/components/container/aside.vue2.cjs +1 -1
  139. package/lib/components/container/container.vue2.cjs +1 -1
  140. package/lib/components/container/footer.vue2.cjs +1 -1
  141. package/lib/components/container/header.vue2.cjs +1 -1
  142. package/lib/components/context-menu/context-menu.vue2.cjs +1 -1
  143. package/lib/components/date-picker/date-picker-com/basic-date-table.vue2.cjs +1 -1
  144. package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
  145. package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
  146. package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
  147. package/lib/components/date-picker/date-picker-com/panel-date-range.vue2.cjs +1 -1
  148. package/lib/components/date-picker/date-picker-com/panel-month-range.vue2.cjs +1 -1
  149. package/lib/components/descriptions/description-item.vue2.cjs +1 -1
  150. package/lib/components/descriptions/description.vue2.cjs +1 -1
  151. package/lib/components/descriptions/descriptions-row.vue2.cjs +1 -1
  152. package/lib/components/dialog/dialog-content.vue2.cjs +1 -1
  153. package/lib/components/dialog/dialog.vue2.cjs +1 -1
  154. package/lib/components/divider/divider.vue2.cjs +1 -1
  155. package/lib/components/dropdown/dropdown.vue.cjs +1 -1
  156. package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
  157. package/lib/components/dropdown/index.cjs +1 -1
  158. package/lib/components/dropdown/style/css.cjs +1 -1
  159. package/lib/components/dropdown/style/index.cjs +1 -1
  160. package/lib/components/dropdown/tokens.cjs +1 -1
  161. package/lib/components/empty/empty.vue2.cjs +1 -1
  162. package/lib/components/exception/exception.vue2.cjs +1 -1
  163. package/lib/components/footer-layout/footer-layout.vue2.cjs +1 -1
  164. package/lib/components/form/form-item.vue2.cjs +1 -1
  165. package/lib/components/form/form.vue2.cjs +1 -1
  166. package/lib/components/full-screen/full-screen.vue2.cjs +1 -1
  167. package/lib/components/header-layout/header-layout.vue2.cjs +1 -1
  168. package/lib/components/horizontal-menu/horizontal-menu.vue2.cjs +1 -1
  169. package/lib/components/icon/icon.vue2.cjs +1 -1
  170. package/lib/components/icon-text/icon-text.vue2.cjs +1 -1
  171. package/lib/components/iframe-layout/iframe-layout.vue2.cjs +1 -1
  172. package/lib/components/iframe-layout/iframe-page.vue2.cjs +1 -1
  173. package/lib/components/image/image.vue2.cjs +1 -1
  174. package/lib/components/image-viewer/image-viewer.vue2.cjs +1 -1
  175. package/lib/components/index.cjs +1 -1
  176. package/lib/components/input/input.vue2.cjs +1 -1
  177. package/lib/components/link/link.vue2.cjs +1 -1
  178. package/lib/components/list-cell/list-cell.vue2.cjs +1 -1
  179. package/lib/components/logo/logo.vue2.cjs +1 -1
  180. package/lib/components/md-container/md-container.vue2.cjs +1 -1
  181. package/lib/components/md-vue-playground/md-vue-playground.vue2.cjs +1 -1
  182. package/lib/components/menu/menu-item-group.vue2.cjs +1 -1
  183. package/lib/components/menu/menu-item.vue2.cjs +1 -1
  184. package/lib/components/menu/menu.vue2.cjs +1 -1
  185. package/lib/components/menu/sub-menu.vue2.cjs +1 -1
  186. package/lib/components/message/message.vue2.cjs +1 -1
  187. package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
  188. package/lib/components/multiple-tabs/tab-content.vue2.cjs +1 -1
  189. package/lib/components/overlay/overlay.vue2.cjs +1 -1
  190. package/lib/components/page-wrapper/page-wrapper.vue2.cjs +1 -1
  191. package/lib/components/pagination/components/jumper.vue2.cjs +1 -1
  192. package/lib/components/pagination/components/next.vue2.cjs +1 -1
  193. package/lib/components/pagination/components/pager.vue2.cjs +1 -1
  194. package/lib/components/pagination/components/prev.vue2.cjs +1 -1
  195. package/lib/components/pagination/components/sizes.vue2.cjs +1 -1
  196. package/lib/components/pagination/components/total.vue2.cjs +1 -1
  197. package/lib/components/pagination/pagination.vue2.cjs +1 -1
  198. package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -1
  199. package/lib/components/popover/popover.vue2.cjs +1 -1
  200. package/lib/components/popper/arrow.vue2.cjs +1 -1
  201. package/lib/components/popper/content.vue2.cjs +1 -1
  202. package/lib/components/popper/trigger.vue2.cjs +1 -1
  203. package/lib/components/qrcode/qrcode.vue2.cjs +1 -1
  204. package/lib/components/radio/radio-button.vue2.cjs +1 -1
  205. package/lib/components/radio/radio-group.vue2.cjs +1 -1
  206. package/lib/components/radio/radio.vue2.cjs +1 -1
  207. package/lib/components/result/result.vue2.cjs +1 -1
  208. package/lib/components/router-view-content/router-view-content.vue2.cjs +1 -1
  209. package/lib/components/row/row.vue2.cjs +1 -1
  210. package/lib/components/scrollbar/bar.vue2.cjs +1 -1
  211. package/lib/components/scrollbar/scrollbar.vue2.cjs +1 -1
  212. package/lib/components/scrollbar/thumb.vue2.cjs +1 -1
  213. package/lib/components/search/search.vue2.cjs +1 -1
  214. package/lib/components/side-menu/side-menu.vue2.cjs +1 -1
  215. package/lib/components/skeleton/skeleton-item.vue2.cjs +1 -1
  216. package/lib/components/skeleton/skeleton.vue2.cjs +1 -1
  217. package/lib/components/switch/switch.vue2.cjs +1 -1
  218. package/lib/components/table/index.cjs +1 -1
  219. package/lib/components/table/table.vue2.cjs +1 -1
  220. package/lib/components/tabs/tab-bar.vue2.cjs +1 -1
  221. package/lib/components/tabs/tab-nav.vue2.cjs +1 -1
  222. package/lib/components/tabs/tab-pane.vue2.cjs +1 -1
  223. package/lib/components/tabs/tabs.vue2.cjs +1 -1
  224. package/lib/components/tag/tag.vue2.cjs +1 -1
  225. package/lib/components/time-picker/common/picker.vue2.cjs +1 -1
  226. package/lib/components/time-picker/time-picker-com/basic-time-spinner.vue2.cjs +1 -1
  227. package/lib/components/time-picker/time-picker-com/panel-time-pick.vue2.cjs +1 -1
  228. package/lib/components/time-picker/time-picker-com/panel-time-range.vue2.cjs +1 -1
  229. package/lib/components/time-select/time-select.vue2.cjs +1 -1
  230. package/lib/components/tooltip/constants.cjs +1 -1
  231. package/lib/components/tooltip/content.vue2.cjs +1 -1
  232. package/lib/components/tooltip/tooltip.vue2.cjs +1 -1
  233. package/lib/components/tooltip/trigger.vue2.cjs +1 -1
  234. package/lib/components/verify-code/verify-code.vue2.cjs +1 -1
  235. package/lib/index.cjs +1 -1
  236. package/lib/package.json.cjs +1 -1
  237. package/package.json +5 -5
  238. package/tags.json +1 -1
  239. package/web-types.json +1 -1
  240. package/theme-style/vft-back-top.css +0 -1
@@ -1,65 +1,65 @@
1
- import { defineComponent as Qe, useAttrs as Xe, useSlots as Ze, ref as D, inject as me, toRef as je, computed as v, watch as A, openBlock as C, createElementBlock as I, normalizeClass as r, unref as a, createElementVNode as m, renderSlot as xe, Fragment as et, renderList as tt, toDisplayString as j, createCommentVNode as K, createVNode as T, withDirectives as P, vShow as N, withKeys as ve, createBlock as x, withCtx as pe, createTextVNode as fe, nextTick as ee } from "vue";
1
+ import { defineComponent as Qe, useAttrs as Xe, useSlots as Ze, ref as D, inject as ve, toRef as je, computed as m, watch as A, openBlock as C, createElementBlock as I, normalizeClass as r, unref as n, createElementVNode as v, renderSlot as xe, Fragment as ea, renderList as aa, toDisplayString as j, createCommentVNode as K, createVNode as T, withDirectives as P, vShow as N, withKeys as me, createBlock as x, withCtx as pe, createTextVNode as fe, nextTick as ee } from "vue";
2
2
  import p from "dayjs";
3
3
  import { VftButton as he } from "../../button/index.js";
4
- import { ClickOutside as at } from "@vft/directives";
4
+ import { ClickOutside as ta } from "@vft/directives";
5
5
  import { useNamespace as ye } from "../../../hooks/use-namespace/index.js";
6
6
  import "@popperjs/core";
7
7
  import "lodash";
8
8
  import "../../../hooks/use-z-index/index.js";
9
9
  import "@vueuse/core";
10
- import { isFunction as ke, isArray as lt } from "@vft/utils";
10
+ import { isFunction as ke, isArray as la } from "@vft/utils";
11
11
  import { EVENT_CODE as f } from "../../../constants/aria.js";
12
12
  import "../../../utils/ns-cover.js";
13
13
  import { VftInput as be } from "../../input/index.js";
14
14
  import "../../time-picker/index.js";
15
15
  import { VftIcon as U } from "../../icon/index.js";
16
16
  import "../../tooltip/index.js";
17
- import { panelDatePickProps as nt } from "../props/panel-date-pick.js";
18
- import ot from "./basic-date-table.vue2.js";
19
- import rt from "./basic-month-table.vue2.js";
20
- import st from "./basic-year-table.vue2.js";
21
- import { datePickerConfig as ut } from "../constants.js";
22
- import { TOOLTIP_INJECTION_KEY as it } from "../../tooltip/constants.js";
23
- import { extractTimeFormat as ct, extractDateFormat as dt } from "../../time-picker/utils.js";
24
- import mt from "../../time-picker/time-picker-com/panel-time-pick.vue2.js";
25
- const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
17
+ import { panelDatePickProps as na } from "../props/panel-date-pick.js";
18
+ import oa from "./basic-date-table.vue2.js";
19
+ import ra from "./basic-month-table.vue2.js";
20
+ import sa from "./basic-year-table.vue2.js";
21
+ import { datePickerConfig as ua } from "../constants.js";
22
+ import { TOOLTIP_INJECTION_KEY as ia } from "../../tooltip/constants.js";
23
+ import { extractTimeFormat as ca, extractDateFormat as da } from "../../time-picker/utils.js";
24
+ import va from "../../time-picker/time-picker-com/panel-time-pick.vue2.js";
25
+ const ma = ["onClick"], _a = /* @__PURE__ */ Qe({
26
26
  __name: "panel-date-pick",
27
- props: nt,
27
+ props: na,
28
28
  emits: ["pick", "set-picker-option", "panel-change"],
29
29
  setup(we, { emit: w }) {
30
- const u = we, ge = (e, t, n) => !0, d = ye("picker-panel"), g = ye("date-picker"), Ve = Xe(), De = Ze(), h = D("zh-cn"), te = me("EP_PICKER_BASE"), E = me(it), { shortcuts: ae, disabledDate: k, cellClassName: Ce, defaultTime: L, arrowControl: Te } = te.props, M = je(te.props, "defaultValue"), O = D(), l = D(p().locale(h.value)), H = D(!1), le = v(() => p(L).locale(h.value)), Pe = v(() => l.value.month()), ne = v(() => l.value.year()), W = D([]), $ = D(null), F = D(null), J = (e) => W.value.length > 0 ? ge(e, W.value, u.format || "HH:mm:ss") : !0, oe = (e) => L && !ce.value && !H.value ? le.value.year(e.year()).month(e.month()).date(e.date()) : R.value ? e.millisecond(0) : e.startOf("day"), c = (e, ...t) => {
30
+ const u = we, ge = (e, a, l) => !0, d = ye("picker-panel"), g = ye("date-picker"), Ve = Xe(), De = Ze(), h = D("zh-cn"), ae = ve("EP_PICKER_BASE"), E = ve(ia), { shortcuts: te, disabledDate: k, cellClassName: Ce, defaultTime: L, arrowControl: Te } = ae.props, M = je(ae.props, "defaultValue"), O = D(), t = D(p().locale(h.value)), H = D(!1), le = m(() => p(L).locale(h.value)), Pe = m(() => t.value.month()), ne = m(() => t.value.year()), W = D([]), $ = D(null), F = D(null), J = (e) => W.value.length > 0 ? ge(e, W.value, u.format || "HH:mm:ss") : !0, oe = (e) => L && !ce.value && !H.value ? le.value.year(e.year()).month(e.month()).date(e.date()) : R.value ? e.millisecond(0) : e.startOf("day"), c = (e, ...a) => {
31
31
  if (!e)
32
- w("pick", e, ...t);
33
- else if (lt(e)) {
34
- const n = e.map(oe);
35
- w("pick", n, ...t);
32
+ w("pick", e, ...a);
33
+ else if (la(e)) {
34
+ const l = e.map(oe);
35
+ w("pick", l, ...a);
36
36
  } else
37
- w("pick", oe(e), ...t);
37
+ w("pick", oe(e), ...a);
38
38
  $.value = null, F.value = null, H.value = !1;
39
- }, $e = (e, t) => {
39
+ }, $e = (e, a) => {
40
40
  if (i.value === "date") {
41
41
  e = e;
42
- let n = u.parsedValue ? u.parsedValue.year(e.year()).month(e.month()).date(e.date()) : e;
43
- J(n) || (n = W.value[0][0].year(e.year()).month(e.month()).date(e.date())), l.value = n, c(n, R.value || t);
42
+ let l = u.parsedValue ? u.parsedValue.year(e.year()).month(e.month()).date(e.date()) : e;
43
+ J(l) || (l = W.value[0][0].year(e.year()).month(e.month()).date(e.date())), t.value = l, c(l, R.value || a);
44
44
  } else
45
45
  i.value === "week" ? c(e.date) : i.value === "dates" && c(e, !0);
46
46
  }, re = (e) => {
47
- const t = e ? "add" : "subtract";
48
- l.value = l.value[t](1, "month"), z("month");
47
+ const a = e ? "add" : "subtract";
48
+ t.value = t.value[a](1, "month"), z("month");
49
49
  }, se = (e) => {
50
- const t = l.value, n = e ? "add" : "subtract";
51
- l.value = s.value === "year" ? t[n](10, "year") : t[n](1, "year"), z("year");
52
- }, s = D("date"), Fe = v(() => {
50
+ const a = t.value, l = e ? "add" : "subtract";
51
+ t.value = s.value === "year" ? a[l](10, "year") : a[l](1, "year"), z("year");
52
+ }, s = D("date"), Fe = m(() => {
53
53
  const e = "年";
54
54
  if (s.value === "year") {
55
- const t = Math.floor(ne.value / 10) * 10;
56
- return `${t} ${e} - ${t + 9} ${e}`;
55
+ const a = Math.floor(ne.value / 10) * 10;
56
+ return `${a} ${e} - ${a + 9} ${e}`;
57
57
  }
58
58
  return `${ne.value} ${e}`;
59
59
  }), Ie = (e) => {
60
- const t = ke(e.value) ? e.value() : e.value;
61
- if (t) {
62
- c(p(t).locale(h.value));
60
+ const a = ke(e.value) ? e.value() : e.value;
61
+ if (a) {
62
+ c(p(a).locale(h.value));
63
63
  return;
64
64
  }
65
65
  e.onClick && e.onClick({
@@ -67,43 +67,43 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
67
67
  slots: De,
68
68
  emit: w
69
69
  });
70
- }, i = v(() => {
70
+ }, i = m(() => {
71
71
  const { type: e } = u;
72
72
  return ["week", "month", "year", "dates"].includes(e) ? e : "date";
73
- }), Ne = v(() => i.value === "date" ? s.value : i.value), ue = v(() => !!ae.length), Me = async (e) => {
74
- l.value = l.value.startOf("month").month(e), i.value === "month" ? c(l.value, !1) : (s.value = "date", ["month", "year", "date", "week"].includes(i.value) && (c(l.value, !0), await ee(), _())), z("month");
73
+ }), Ne = m(() => i.value === "date" ? s.value : i.value), ue = m(() => !!te.length), Me = async (e) => {
74
+ t.value = t.value.startOf("month").month(e), i.value === "month" ? c(t.value, !1) : (s.value = "date", ["month", "year", "date", "week"].includes(i.value) && (c(t.value, !0), await ee(), _())), z("month");
75
75
  }, Re = async (e) => {
76
- i.value === "year" ? (l.value = l.value.startOf("year").year(e), c(l.value, !1)) : (l.value = l.value.year(e), s.value = "month", ["month", "year", "date", "week"].includes(i.value) && (c(l.value, !0), await ee(), _())), z("year");
76
+ i.value === "year" ? (t.value = t.value.startOf("year").year(e), c(t.value, !1)) : (t.value = t.value.year(e), s.value = "month", ["month", "year", "date", "week"].includes(i.value) && (c(t.value, !0), await ee(), _())), z("year");
77
77
  }, Y = async (e) => {
78
78
  s.value = e, await ee(), _();
79
- }, R = v(
79
+ }, R = m(
80
80
  () => u.type === "datetime" || u.type === "datetimerange"
81
- ), Se = v(() => R.value || i.value === "dates"), Be = () => {
81
+ ), Se = m(() => R.value || i.value === "dates"), Be = () => {
82
82
  if (i.value === "dates")
83
83
  c(u.parsedValue);
84
84
  else {
85
85
  let e = u.parsedValue;
86
86
  if (!e) {
87
- const t = p(L).locale(h.value), n = Q();
88
- e = t.year(n.year()).month(n.month()).date(n.date());
87
+ const a = p(L).locale(h.value), l = Q();
88
+ e = a.year(l.year()).month(l.month()).date(l.date());
89
89
  }
90
- l.value = e, c(e);
90
+ t.value = e, c(e);
91
91
  }
92
92
  }, Ke = () => {
93
- const t = p().locale(h.value).toDate();
94
- H.value = !0, (!k || !k(t)) && J(t) && (l.value = p().locale(h.value), c(l.value));
95
- }, q = v(() => ct(u.format)), ie = v(() => dt(u.format)), ce = v(() => {
93
+ const a = p().locale(h.value).toDate();
94
+ H.value = !0, (!k || !k(a)) && J(a) && (t.value = p().locale(h.value), c(t.value));
95
+ }, q = m(() => ca(u.format)), ie = m(() => da(u.format)), ce = m(() => {
96
96
  if (F.value)
97
97
  return F.value;
98
98
  if (!(!u.parsedValue && !M.value))
99
- return (u.parsedValue || l.value).format(
99
+ return (u.parsedValue || t.value).format(
100
100
  q.value
101
101
  );
102
- }), Oe = v(() => {
102
+ }), Oe = m(() => {
103
103
  if ($.value)
104
104
  return $.value;
105
105
  if (!(!u.parsedValue && !M.value))
106
- return (u.parsedValue || l.value).format(
106
+ return (u.parsedValue || t.value).format(
107
107
  ie.value
108
108
  );
109
109
  }), S = D(!1), Ye = () => {
@@ -117,35 +117,35 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
117
117
  year: e.year(),
118
118
  month: e.month(),
119
119
  date: e.date()
120
- }), ze = (e, t, n) => {
120
+ }), ze = (e, a, l) => {
121
121
  const { hour: y, minute: b, second: X } = G(e), Z = u.parsedValue ? u.parsedValue.hour(y).minute(b).second(X) : e;
122
- l.value = Z, c(l.value, !0), n || (S.value = t);
122
+ t.value = Z, c(t.value, !0), l || (S.value = a);
123
123
  }, Ae = (e) => {
124
- const t = p(e, q.value).locale(h.value);
125
- if (t.isValid() && J(t)) {
126
- const { year: n, month: y, date: b } = G(l.value);
127
- l.value = t.year(n).month(y).date(b), F.value = null, S.value = !1, c(l.value, !0);
124
+ const a = p(e, q.value).locale(h.value);
125
+ if (a.isValid() && J(a)) {
126
+ const { year: l, month: y, date: b } = G(t.value);
127
+ t.value = a.year(l).month(y).date(b), F.value = null, S.value = !1, c(t.value, !0);
128
128
  }
129
129
  }, Ue = (e) => {
130
- const t = p(e, ie.value).locale(h.value);
131
- if (t.isValid()) {
132
- if (k && k(t.toDate()))
130
+ const a = p(e, ie.value).locale(h.value);
131
+ if (a.isValid()) {
132
+ if (k && k(a.toDate()))
133
133
  return;
134
- const { hour: n, minute: y, second: b } = G(l.value);
135
- l.value = t.hour(n).minute(y).second(b), $.value = null, c(l.value, !0);
134
+ const { hour: l, minute: y, second: b } = G(t.value);
135
+ t.value = a.hour(l).minute(y).second(b), $.value = null, c(t.value, !0);
136
136
  }
137
- }, Ee = (e) => p.isDayjs(e) && e.isValid() && (k ? !k(e.toDate()) : !0), Le = (e) => i.value === "dates" ? e.map((t) => t.format(u.format)) : e.format(u.format), He = (e) => p(e, u.format).locale(h.value), Q = () => {
137
+ }, Ee = (e) => p.isDayjs(e) && e.isValid() && (k ? !k(e.toDate()) : !0), Le = (e) => i.value === "dates" ? e.map((a) => a.format(u.format)) : e.format(u.format), He = (e) => p(e, u.format).locale(h.value), Q = () => {
138
138
  const e = p(M.value).locale(h.value);
139
139
  if (!M.value) {
140
- const t = le.value;
141
- return p().hour(t.hour()).minute(t.minute()).second(t.second()).locale(h.value);
140
+ const a = le.value;
141
+ return p().hour(a.hour()).minute(a.minute()).second(a.second()).locale(h.value);
142
142
  }
143
143
  return e;
144
144
  }, _ = async () => {
145
145
  var e;
146
146
  ["week", "month", "year", "date"].includes(i.value) && ((e = O.value) == null || e.focus(), i.value === "week" && de(f.down));
147
147
  }, We = (e) => {
148
- const { code: t } = e;
148
+ const { code: a } = e;
149
149
  [
150
150
  f.up,
151
151
  f.down,
@@ -155,35 +155,35 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
155
155
  f.end,
156
156
  f.pageUp,
157
157
  f.pageDown
158
- ].includes(t) && (de(t), e.stopPropagation(), e.preventDefault()), [f.enter, f.space, f.numpadEnter].includes(
159
- t
160
- ) && $.value === null && F.value === null && (e.preventDefault(), c(l.value, !1));
158
+ ].includes(a) && (de(a), e.stopPropagation(), e.preventDefault()), [f.enter, f.space, f.numpadEnter].includes(
159
+ a
160
+ ) && $.value === null && F.value === null && (e.preventDefault(), c(t.value, !1));
161
161
  }, de = (e) => {
162
- const { up: t, down: n, left: y, right: b, home: X, end: Z, pageUp: Je, pageDown: qe } = f, Ge = {
162
+ const { up: a, down: l, left: y, right: b, home: X, end: Z, pageUp: Je, pageDown: qe } = f, Ge = {
163
163
  year: {
164
- [t]: -4,
165
- [n]: 4,
164
+ [a]: -4,
165
+ [l]: 4,
166
166
  [y]: -1,
167
167
  [b]: 1,
168
168
  offset: (o, V) => o.setFullYear(o.getFullYear() + V)
169
169
  },
170
170
  month: {
171
- [t]: -4,
172
- [n]: 4,
171
+ [a]: -4,
172
+ [l]: 4,
173
173
  [y]: -1,
174
174
  [b]: 1,
175
175
  offset: (o, V) => o.setMonth(o.getMonth() + V)
176
176
  },
177
177
  week: {
178
- [t]: -1,
179
- [n]: 1,
178
+ [a]: -1,
179
+ [l]: 1,
180
180
  [y]: -1,
181
181
  [b]: 1,
182
182
  offset: (o, V) => o.setDate(o.getDate() + V * 7)
183
183
  },
184
184
  date: {
185
- [t]: -7,
186
- [n]: 7,
185
+ [a]: -7,
186
+ [l]: 7,
187
187
  [y]: -1,
188
188
  [b]: 1,
189
189
  [X]: (o) => -o.getDay(),
@@ -192,8 +192,8 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
192
192
  [qe]: (o) => new Date(o.getFullYear(), o.getMonth() + 1, 0).getDate(),
193
193
  offset: (o, V) => o.setDate(o.getDate() + V)
194
194
  }
195
- }, B = l.value.toDate();
196
- for (; Math.abs(l.value.diff(B, "year", !0)) < 1; ) {
195
+ }, B = t.value.toDate();
196
+ for (; Math.abs(t.value.diff(B, "year", !0)) < 1; ) {
197
197
  const o = Ge[Ne.value];
198
198
  if (!o)
199
199
  return;
@@ -203,11 +203,11 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
203
203
  ), k && k(B))
204
204
  break;
205
205
  const V = p(B).locale(h.value);
206
- l.value = V, w("pick", V, !0);
206
+ t.value = V, w("pick", V, !0);
207
207
  break;
208
208
  }
209
209
  }, z = (e) => {
210
- w("panel-change", l.value.toDate(), e, s.value);
210
+ w("panel-change", t.value.toDate(), e, s.value);
211
211
  };
212
212
  return A(
213
213
  () => i.value,
@@ -227,7 +227,7 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
227
227
  ), A(
228
228
  () => M.value,
229
229
  (e) => {
230
- e && (l.value = Q());
230
+ e && (t.value = Q());
231
231
  },
232
232
  { immediate: !0 }
233
233
  ), A(
@@ -236,193 +236,193 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
236
236
  if (e) {
237
237
  if (i.value === "dates" || Array.isArray(e))
238
238
  return;
239
- l.value = e;
239
+ t.value = e;
240
240
  } else
241
- l.value = Q();
241
+ t.value = Q();
242
242
  },
243
243
  { immediate: !0 }
244
- ), w("set-picker-option", ["isValidValue", Ee]), w("set-picker-option", ["formatToString", Le]), w("set-picker-option", ["parseUserInput", He]), w("set-picker-option", ["handleFocusPicker", _]), (e, t) => (C(), I("div", {
244
+ ), w("set-picker-option", ["isValidValue", Ee]), w("set-picker-option", ["formatToString", Le]), w("set-picker-option", ["parseUserInput", He]), w("set-picker-option", ["handleFocusPicker", _]), (e, a) => (C(), I("div", {
245
245
  class: r([
246
- a(d).b(),
247
- a(g).b(),
246
+ n(d).b(),
247
+ n(g).b(),
248
248
  {
249
- "has-sidebar": e.$slots.sidebar || a(ue),
250
- "has-time": a(R)
249
+ "has-sidebar": e.$slots.sidebar || ue.value,
250
+ "has-time": R.value
251
251
  }
252
252
  ])
253
253
  }, [
254
- m("div", {
255
- class: r(a(d).e("body-wrapper"))
254
+ v("div", {
255
+ class: r(n(d).e("body-wrapper"))
256
256
  }, [
257
257
  xe(e.$slots, "sidebar", {
258
- class: r(a(d).e("sidebar"))
258
+ class: r(n(d).e("sidebar"))
259
259
  }),
260
- a(ue) ? (C(), I("div", {
260
+ ue.value ? (C(), I("div", {
261
261
  key: 0,
262
- class: r(a(d).e("sidebar"))
262
+ class: r(n(d).e("sidebar"))
263
263
  }, [
264
- (C(!0), I(et, null, tt(a(ae), (n, y) => (C(), I("button", {
264
+ (C(!0), I(ea, null, aa(n(te), (l, y) => (C(), I("button", {
265
265
  key: y,
266
266
  type: "button",
267
- class: r(a(d).e("shortcut")),
268
- onClick: (b) => Ie(n)
269
- }, j(n.text), 11, vt))), 128))
267
+ class: r(n(d).e("shortcut")),
268
+ onClick: (b) => Ie(l)
269
+ }, j(l.text), 11, ma))), 128))
270
270
  ], 2)) : K("", !0),
271
- m("div", {
272
- class: r(a(d).e("body"))
271
+ v("div", {
272
+ class: r(n(d).e("body"))
273
273
  }, [
274
- a(R) ? (C(), I("div", {
274
+ R.value ? (C(), I("div", {
275
275
  key: 0,
276
- class: r(a(g).e("time-header"))
276
+ class: r(n(g).e("time-header"))
277
277
  }, [
278
- m("span", {
279
- class: r(a(g).e("editor-wrap"))
278
+ v("span", {
279
+ class: r(n(g).e("editor-wrap"))
280
280
  }, [
281
- T(a(be), {
281
+ T(n(be), {
282
282
  placeholder: "選擇日期",
283
- "model-value": a(Oe),
283
+ "model-value": Oe.value,
284
284
  size: "small",
285
285
  "validate-event": !1,
286
- onInput: t[0] || (t[0] = (n) => $.value = n),
286
+ onInput: a[0] || (a[0] = (l) => $.value = l),
287
287
  onChange: Ue
288
288
  }, null, 8, ["model-value"])
289
289
  ], 2),
290
290
  P((C(), I("span", {
291
- class: r(a(g).e("editor-wrap"))
291
+ class: r(n(g).e("editor-wrap"))
292
292
  }, [
293
- T(a(be), {
293
+ T(n(be), {
294
294
  placeholder: "選擇時間",
295
- "model-value": a(ce),
295
+ "model-value": ce.value,
296
296
  size: "small",
297
297
  "validate-event": !1,
298
298
  onFocus: Ye,
299
- onInput: t[1] || (t[1] = (n) => F.value = n),
299
+ onInput: a[1] || (a[1] = (l) => F.value = l),
300
300
  onChange: Ae
301
301
  }, null, 8, ["model-value"]),
302
- T(a(mt), {
302
+ T(n(va), {
303
303
  visible: S.value,
304
- format: a(q),
305
- "time-arrow-control": a(Te),
306
- "parsed-value": l.value,
304
+ format: q.value,
305
+ "time-arrow-control": n(Te),
306
+ "parsed-value": t.value,
307
307
  onPick: ze
308
308
  }, null, 8, ["visible", "format", "time-arrow-control", "parsed-value"])
309
309
  ], 2)), [
310
- [a(at), _e]
310
+ [n(ta), _e]
311
311
  ])
312
312
  ], 2)) : K("", !0),
313
- P(m("div", {
313
+ P(v("div", {
314
314
  class: r([
315
- a(g).e("header"),
316
- (s.value === "year" || s.value === "month") && a(g).e("header--bordered")
315
+ n(g).e("header"),
316
+ (s.value === "year" || s.value === "month") && n(g).e("header--bordered")
317
317
  ])
318
318
  }, [
319
- m("span", {
320
- class: r(a(g).e("prev-btn"))
319
+ v("span", {
320
+ class: r(n(g).e("prev-btn"))
321
321
  }, [
322
- m("button", {
322
+ v("button", {
323
323
  type: "button",
324
- class: r(["d-arrow-left", a(d).e("icon-btn")]),
325
- onClick: t[2] || (t[2] = (n) => se(!1))
324
+ class: r(["d-arrow-left", n(d).e("icon-btn")]),
325
+ onClick: a[2] || (a[2] = (l) => se(!1))
326
326
  }, [
327
- T(a(U), { icon: "ico-ep:d-arrow-left" })
327
+ T(n(U), { icon: "ico-ep:d-arrow-left" })
328
328
  ], 2),
329
- P(m("button", {
329
+ P(v("button", {
330
330
  type: "button",
331
- class: r([a(d).e("icon-btn"), "arrow-left"]),
332
- onClick: t[3] || (t[3] = (n) => re(!1))
331
+ class: r([n(d).e("icon-btn"), "arrow-left"]),
332
+ onClick: a[3] || (a[3] = (l) => re(!1))
333
333
  }, [
334
- T(a(U), { icon: "ico-ep:arrow-left" })
334
+ T(n(U), { icon: "ico-ep:arrow-left" })
335
335
  ], 2), [
336
336
  [N, s.value === "date"]
337
337
  ])
338
338
  ], 2),
339
- m("span", {
339
+ v("span", {
340
340
  role: "button",
341
- class: r(a(g).e("header-label")),
341
+ class: r(n(g).e("header-label")),
342
342
  "aria-live": "polite",
343
343
  tabindex: "0",
344
- onKeydown: t[4] || (t[4] = ve((n) => Y("year"), ["enter"])),
345
- onClick: t[5] || (t[5] = (n) => Y("year"))
346
- }, j(a(Fe)), 35),
347
- P(m("span", {
344
+ onKeydown: a[4] || (a[4] = me((l) => Y("year"), ["enter"])),
345
+ onClick: a[5] || (a[5] = (l) => Y("year"))
346
+ }, j(Fe.value), 35),
347
+ P(v("span", {
348
348
  role: "button",
349
349
  "aria-live": "polite",
350
350
  tabindex: "0",
351
351
  class: r([
352
- a(g).e("header-label"),
352
+ n(g).e("header-label"),
353
353
  { active: s.value === "month" }
354
354
  ]),
355
- onKeydown: t[6] || (t[6] = ve((n) => Y("month"), ["enter"])),
356
- onClick: t[7] || (t[7] = (n) => Y("month"))
357
- }, j(a(ut)["month" + (a(Pe) + 1)]), 35), [
355
+ onKeydown: a[6] || (a[6] = me((l) => Y("month"), ["enter"])),
356
+ onClick: a[7] || (a[7] = (l) => Y("month"))
357
+ }, j(n(ua)["month" + (Pe.value + 1)]), 35), [
358
358
  [N, s.value === "date"]
359
359
  ]),
360
- m("span", {
361
- class: r(a(g).e("next-btn"))
360
+ v("span", {
361
+ class: r(n(g).e("next-btn"))
362
362
  }, [
363
- P(m("button", {
363
+ P(v("button", {
364
364
  type: "button",
365
- class: r([a(d).e("icon-btn"), "arrow-right"]),
366
- onClick: t[8] || (t[8] = (n) => re(!0))
365
+ class: r([n(d).e("icon-btn"), "arrow-right"]),
366
+ onClick: a[8] || (a[8] = (l) => re(!0))
367
367
  }, [
368
- T(a(U), { icon: "ico-ep:arrow-right" })
368
+ T(n(U), { icon: "ico-ep:arrow-right" })
369
369
  ], 2), [
370
370
  [N, s.value === "date"]
371
371
  ]),
372
- m("button", {
372
+ v("button", {
373
373
  type: "button",
374
- class: r([a(d).e("icon-btn"), "d-arrow-right"]),
375
- onClick: t[9] || (t[9] = (n) => se(!0))
374
+ class: r([n(d).e("icon-btn"), "d-arrow-right"]),
375
+ onClick: a[9] || (a[9] = (l) => se(!0))
376
376
  }, [
377
- T(a(U), { icon: "ico-ep:d-arrow-right" })
377
+ T(n(U), { icon: "ico-ep:d-arrow-right" })
378
378
  ], 2)
379
379
  ], 2)
380
380
  ], 2), [
381
381
  [N, s.value !== "time"]
382
382
  ]),
383
- m("div", {
384
- class: r(a(d).e("content")),
383
+ v("div", {
384
+ class: r(n(d).e("content")),
385
385
  onKeydown: We
386
386
  }, [
387
- s.value === "date" ? (C(), x(ot, {
387
+ s.value === "date" ? (C(), x(oa, {
388
388
  key: 0,
389
389
  ref_key: "currentViewRef",
390
390
  ref: O,
391
- "selection-mode": a(i),
392
- date: l.value,
391
+ "selection-mode": i.value,
392
+ date: t.value,
393
393
  "parsed-value": e.parsedValue,
394
- "disabled-date": a(k),
395
- "cell-class-name": a(Ce),
394
+ "disabled-date": n(k),
395
+ "cell-class-name": n(Ce),
396
396
  onPick: $e
397
397
  }, null, 8, ["selection-mode", "date", "parsed-value", "disabled-date", "cell-class-name"])) : K("", !0),
398
- s.value === "year" ? (C(), x(st, {
398
+ s.value === "year" ? (C(), x(sa, {
399
399
  key: 1,
400
400
  ref_key: "currentViewRef",
401
401
  ref: O,
402
- date: l.value,
403
- "disabled-date": a(k),
402
+ date: t.value,
403
+ "disabled-date": n(k),
404
404
  "parsed-value": e.parsedValue,
405
405
  onPick: Re
406
406
  }, null, 8, ["date", "disabled-date", "parsed-value"])) : K("", !0),
407
- s.value === "month" ? (C(), x(rt, {
407
+ s.value === "month" ? (C(), x(ra, {
408
408
  key: 2,
409
409
  ref_key: "currentViewRef",
410
410
  ref: O,
411
- date: l.value,
411
+ date: t.value,
412
412
  "parsed-value": e.parsedValue,
413
- "disabled-date": a(k),
413
+ "disabled-date": n(k),
414
414
  onPick: Me
415
415
  }, null, 8, ["date", "parsed-value", "disabled-date"])) : K("", !0)
416
416
  ], 34)
417
417
  ], 2)
418
418
  ], 2),
419
- P(m("div", {
420
- class: r(a(d).e("footer"))
419
+ P(v("div", {
420
+ class: r(n(d).e("footer"))
421
421
  }, [
422
- P(T(a(he), {
422
+ P(T(n(he), {
423
423
  text: "",
424
424
  size: "small",
425
- class: r(a(d).e("link-btn")),
425
+ class: r(n(d).e("link-btn")),
426
426
  onClick: Ke
427
427
  }, {
428
428
  default: pe(() => [
@@ -430,12 +430,12 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
430
430
  ]),
431
431
  _: 1
432
432
  }, 8, ["class"]), [
433
- [N, a(i) !== "dates"]
433
+ [N, i.value !== "dates"]
434
434
  ]),
435
- T(a(he), {
435
+ T(n(he), {
436
436
  plain: "",
437
437
  size: "small",
438
- class: r(a(d).e("link-btn")),
438
+ class: r(n(d).e("link-btn")),
439
439
  onClick: Be
440
440
  }, {
441
441
  default: pe(() => [
@@ -444,11 +444,11 @@ const vt = ["onClick"], _t = /* @__PURE__ */ Qe({
444
444
  _: 1
445
445
  }, 8, ["class"])
446
446
  ], 2), [
447
- [N, a(Se) && s.value === "date"]
447
+ [N, Se.value && s.value === "date"]
448
448
  ])
449
449
  ], 2));
450
450
  }
451
451
  });
452
452
  export {
453
- _t as default
453
+ _a as default
454
454
  };