@keyblade/pro-components 1.13.8-alpha.8 → 1.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (156) hide show
  1. package/es/components.d.ts +7 -0
  2. package/es/global-props.d.ts +21 -2
  3. package/es/global-props.js +6 -2
  4. package/es/index.d.ts +7 -0
  5. package/es/index.js +47 -28
  6. package/es/inerface.d.ts +5 -1
  7. package/es/pro-calendar/calendar.vue.d.ts +75 -0
  8. package/es/pro-calendar/calendar.vue.js +159 -0
  9. package/es/pro-calendar/calendar.vue3.js +5 -0
  10. package/es/pro-calendar/enum.d.ts +6 -0
  11. package/es/pro-calendar/enum.js +4 -0
  12. package/es/pro-calendar/header.vue.d.ts +35 -0
  13. package/es/pro-calendar/header.vue.js +146 -0
  14. package/es/pro-calendar/header.vue2.js +4 -0
  15. package/es/pro-calendar/hooks/useCellClassName.d.ts +12 -0
  16. package/es/pro-calendar/hooks/useCellClassName.js +40 -0
  17. package/es/pro-calendar/index.d.ts +117 -0
  18. package/es/pro-calendar/index.js +12 -0
  19. package/es/pro-calendar/interface.d.ts +89 -0
  20. package/es/pro-calendar/month.d.ts +5 -0
  21. package/es/pro-calendar/month.js +53 -0
  22. package/es/pro-calendar/month.vue.d.ts +22 -0
  23. package/es/pro-calendar/month.vue.js +126 -0
  24. package/es/pro-calendar/month.vue2.js +4 -0
  25. package/es/pro-calendar/week.vue.d.ts +3 -0
  26. package/es/pro-calendar/week.vue.js +34 -0
  27. package/es/pro-calendar/week.vue2.js +4 -0
  28. package/es/pro-calendar/year.vue.d.ts +3 -0
  29. package/es/pro-calendar/year.vue.js +123 -0
  30. package/es/pro-calendar/year.vue2.js +4 -0
  31. package/es/pro-date-range-picker/index.d.ts +183 -13
  32. package/es/pro-date-range-picker/index.js +6 -7
  33. package/es/pro-date-range-picker/interface.d.ts +38 -0
  34. package/es/pro-date-range-picker/pro-date-range-picker.vue.d.ts +173 -6
  35. package/es/pro-date-range-picker/pro-date-range-picker.vue.js +1 -1
  36. package/es/pro-date-range-picker/pro-date-range-picker.vue2.js +127 -97
  37. package/es/pro-dates-picker/index.d.ts +49 -0
  38. package/es/pro-dates-picker/index.js +11 -0
  39. package/es/pro-dates-picker/index.vue.d.ts +29 -0
  40. package/es/pro-dates-picker/index.vue.js +135 -0
  41. package/es/pro-dates-picker/index.vue3.js +5 -0
  42. package/es/pro-dates-picker/interface.d.ts +38 -0
  43. package/es/pro-dates-picker/util.d.ts +12 -0
  44. package/es/pro-dates-picker/util.js +9 -0
  45. package/es/pro-find-password/enum.d.ts +8 -0
  46. package/es/pro-find-password/enum.js +4 -0
  47. package/es/pro-find-password/index.d.ts +11 -0
  48. package/es/pro-find-password/index.js +11 -0
  49. package/es/pro-find-password/index.vue.d.ts +4459 -0
  50. package/es/pro-find-password/index.vue.js +176 -0
  51. package/es/pro-find-password/index.vue3.js +5 -0
  52. package/es/pro-find-password/interface.d.ts +45 -0
  53. package/es/pro-find-password/reset-password.vue.d.ts +591 -0
  54. package/es/pro-find-password/reset-password.vue.js +179 -0
  55. package/es/pro-find-password/reset-password.vue2.js +4 -0
  56. package/es/pro-find-password/verify-user-name.vue.d.ts +795 -0
  57. package/es/pro-find-password/verify-user-name.vue.js +112 -0
  58. package/es/pro-find-password/verify-user-name.vue3.js +5 -0
  59. package/es/pro-footer-bar/index.d.ts +6 -3
  60. package/es/pro-footer-bar/index.js +6 -7
  61. package/es/pro-footer-bar/index.vue.d.ts +1 -1
  62. package/es/pro-footer-bar/index.vue.js +2 -2
  63. package/es/pro-footer-bar/index.vue2.js +24 -26
  64. package/es/pro-footer-bar/{inerface.d.ts → interface.d.ts} +1 -0
  65. package/es/pro-form-group/index.d.ts +7 -6
  66. package/es/pro-form-group/index.js +6 -8
  67. package/es/pro-form-group/index.vue.d.ts +2 -2
  68. package/es/pro-form-group/index.vue.js +1 -1
  69. package/es/pro-form-group/index.vue2.js +31 -32
  70. package/es/pro-image-upload/cropper.vue.js +2 -2
  71. package/es/pro-image-upload/cropper.vue2.js +200 -190
  72. package/es/pro-image-upload/image-upload.vue.d.ts +1124 -371
  73. package/es/pro-image-upload/image-upload.vue.js +178 -144
  74. package/es/pro-image-upload/index.d.ts +1727 -1001
  75. package/es/pro-image-upload/index.js +6 -8
  76. package/es/pro-keep-alive-router-view/index.d.ts +1 -0
  77. package/es/pro-keep-alive-router-view/pro-keep-alive-router-view.vue.js +17 -18
  78. package/es/pro-layout/hooks.d.ts +80 -1
  79. package/es/pro-layout/hooks.js +133 -84
  80. package/es/pro-layout/index.d.ts +9 -6
  81. package/es/pro-layout/index.js +6 -11
  82. package/es/pro-layout/pro-layout.vue.d.ts +4 -2
  83. package/es/pro-layout/pro-layout.vue.js +220 -208
  84. package/es/pro-loader/index.d.ts +43 -0
  85. package/es/pro-loader/index.js +11 -0
  86. package/es/pro-loader/index.vue.d.ts +28 -0
  87. package/es/pro-loader/index.vue.js +112 -0
  88. package/es/pro-loader/index.vue3.js +5 -0
  89. package/es/pro-loader/interface.d.ts +16 -0
  90. package/es/pro-login/enum.d.ts +6 -0
  91. package/es/pro-login/enum.js +4 -0
  92. package/es/pro-login/form-mobile.vue.d.ts +797 -0
  93. package/es/pro-login/form-mobile.vue.js +146 -0
  94. package/es/pro-login/form-mobile.vue2.js +4 -0
  95. package/es/pro-login/form-password.vue.d.ts +584 -0
  96. package/es/pro-login/form-password.vue.js +99 -0
  97. package/es/pro-login/form-password.vue2.js +4 -0
  98. package/es/pro-login/index.d.ts +11 -0
  99. package/es/pro-login/index.js +11 -0
  100. package/es/pro-login/index.vue.d.ts +4429 -0
  101. package/es/pro-login/index.vue.js +105 -0
  102. package/es/pro-login/index.vue3.js +5 -0
  103. package/es/pro-login/interface.d.ts +72 -0
  104. package/es/pro-login/regexp.d.ts +17 -0
  105. package/es/pro-login/regexp.js +28 -0
  106. package/es/pro-menu/index.d.ts +18 -80
  107. package/es/pro-menu/index.js +6 -7
  108. package/es/pro-menu/interface.d.ts +31 -0
  109. package/es/pro-menu/menu-item.vue.d.ts +27 -0
  110. package/es/pro-menu/menu-item.vue.js +35 -0
  111. package/es/pro-menu/menu-item.vue2.js +4 -0
  112. package/es/pro-menu/pro-menu-item.vue.d.ts +9 -0
  113. package/es/pro-menu/pro-menu-item.vue.js +63 -0
  114. package/es/pro-menu/pro-menu-item.vue2.js +4 -0
  115. package/es/pro-menu/pro-menu.vue.d.ts +9 -55
  116. package/es/pro-menu/pro-menu.vue.js +36 -119
  117. package/es/pro-menu/sub-menu.vue.d.ts +22 -0
  118. package/es/pro-menu/sub-menu.vue.js +55 -0
  119. package/es/pro-menu/sub-menu.vue2.js +4 -0
  120. package/es/pro-menu/util.d.ts +9 -0
  121. package/es/pro-menu/util.js +7 -0
  122. package/es/pro-page-container/constant.d.ts +2 -0
  123. package/es/pro-page-container/constant.js +9 -0
  124. package/es/pro-page-container/index.d.ts +7 -21
  125. package/es/pro-page-container/index.js +6 -8
  126. package/es/pro-page-container/interface.d.ts +12 -0
  127. package/es/pro-page-container/pro-page-container.vue.d.ts +4 -15
  128. package/es/pro-page-container/pro-page-container.vue.js +58 -38
  129. package/es/pro-page-header/constant.d.ts +2 -0
  130. package/es/pro-page-header/constant.js +13 -0
  131. package/es/pro-page-header/index.d.ts +12 -146
  132. package/es/pro-page-header/index.js +6 -8
  133. package/es/pro-page-header/interface.d.ts +21 -0
  134. package/es/pro-page-header/pro-page-header.vue.d.ts +18 -103
  135. package/es/pro-page-header/pro-page-header.vue.js +141 -124
  136. package/es/pro-reuse-tabs/index.d.ts +8 -6
  137. package/es/pro-reuse-tabs/index.js +6 -7
  138. package/es/pro-reuse-tabs/pro-reuse-tabs.vue.d.ts +2 -2
  139. package/es/pro-reuse-tabs/pro-reuse-tabs.vue.js +33 -35
  140. package/es/pro-table/index.d.ts +18 -18
  141. package/es/pro-table/index.js +6 -7
  142. package/es/pro-table/index.vue.d.ts +6 -6
  143. package/es/pro-table/index.vue.js +94 -39
  144. package/es/pro-table/interface.d.ts +73 -65
  145. package/es/pro-textarea/index.d.ts +7 -5
  146. package/es/pro-textarea/index.js +5 -6
  147. package/es/pro-textarea/index.vue.d.ts +1 -1
  148. package/es/pro-textarea/index.vue.js +1 -1
  149. package/es/pro-textarea/index.vue2.js +14 -16
  150. package/es/pro-textarea/{inerface.d.ts → interface.d.ts} +19 -18
  151. package/es/style.css +1 -1
  152. package/es/utils.d.ts +6 -0
  153. package/es/utils.js +7 -0
  154. package/package.json +5 -4
  155. package/es/pro-date-range-picker/type.d.ts +0 -22
  156. package/es/pro-page-container/inerface.d.ts +0 -12
@@ -1,7 +1,22 @@
1
- import { defineComponent as R, ref as p, computed as y, resolveComponent as b, createElementBlock as w, openBlock as I, normalizeClass as N, createVNode as i, mergeProps as s, withCtx as c, createTextVNode as q, toDisplayString as A, nextTick as D } from "vue";
2
- import o from "dayjs";
3
- import { range as f } from "./pro-date-range-picker.js";
4
- const H = "keyblade-pro-date-range-picker", $ = /* @__PURE__ */ R({
1
+ var j = Object.defineProperty, z = Object.defineProperties;
2
+ var G = Object.getOwnPropertyDescriptors;
3
+ var B = Object.getOwnPropertySymbols;
4
+ var J = Object.prototype.hasOwnProperty, K = Object.prototype.propertyIsEnumerable;
5
+ var I = (r, d, e) => d in r ? j(r, d, { enumerable: !0, configurable: !0, writable: !0, value: e }) : r[d] = e, c = (r, d) => {
6
+ for (var e in d || (d = {}))
7
+ J.call(d, e) && I(r, e, d[e]);
8
+ if (B)
9
+ for (var e of B(d))
10
+ K.call(d, e) && I(r, e, d[e]);
11
+ return r;
12
+ }, f = (r, d) => z(r, G(d));
13
+ import { defineComponent as O, ref as s, computed as h, createElementBlock as Q, openBlock as W, normalizeClass as X, createVNode as u, unref as m, mergeProps as P, withCtx as y, createTextVNode as Y, toDisplayString as Z, nextTick as w } from "vue";
14
+ import { FormItem as F, DatePicker as N } from "@arco-design/web-vue";
15
+ import i from "dayjs";
16
+ import { conclude as q } from "vue-global-config";
17
+ import { globalProps as x } from "../global-props.js";
18
+ import { range as g } from "./pro-date-range-picker.js";
19
+ const ee = "keyblade-pro-date-range-picker", se = /* @__PURE__ */ O({
5
20
  __name: "pro-date-range-picker",
6
21
  props: {
7
22
  modelValue: {},
@@ -13,125 +28,140 @@ const H = "keyblade-pro-date-range-picker", $ = /* @__PURE__ */ R({
13
28
  intraday: { type: Boolean },
14
29
  hideLabel: { type: Boolean, default: !0 },
15
30
  formItemProps: {},
16
- datePickerProps: {}
31
+ datePickerProps: {},
32
+ timePickerProps: {},
33
+ disabledStartDate: {},
34
+ disabledEndDate: {}
17
35
  },
18
36
  emits: ["update:modelValue"],
19
- setup(F, { emit: g }) {
20
- const e = F, V = g, h = p(), P = p(), n = p(), u = y({
37
+ setup(r, { emit: d }) {
38
+ const e = r, S = d, b = s(), k = s(), v = s(), E = s(), C = s(), p = s(), V = h({
21
39
  get: () => e.modelValue[e.startField],
22
40
  set: (t) => {
23
- V("update:modelValue", {
24
- ...e.modelValue,
41
+ t ? b.value = "success" : b.value = void 0, S("update:modelValue", f(c({}, e.modelValue), {
25
42
  [e.startField]: t
26
- });
43
+ }));
27
44
  }
28
- }), k = y({
45
+ }), R = h({
29
46
  get: () => e.modelValue[e.endField],
30
47
  set: (t) => {
31
- V("update:modelValue", {
32
- ...e.modelValue,
48
+ t ? k.value = "success" : k.value = void 0, S("update:modelValue", f(c({}, e.modelValue), {
33
49
  [e.endField]: t
34
- });
50
+ }));
35
51
  }
36
- }), v = (t) => {
37
- var l;
38
- if (!e.modelValue[e.endField]) return !1;
39
- let a = o(e.modelValue[e.endField]);
40
- return e.intraday && !((l = e.datePickerProps) != null && l.showTime) && (a = a.add(1, "day")), o(t).isAfter(a);
41
- }, S = (t) => {
42
- var d;
43
- return e.modelValue[e.startField] ? (e.intraday && ((d = e.datePickerProps) != null && d.showTime) && t.setDate(t.getDate() + 1), o(t).isBefore(o(e.modelValue[e.startField]))) : !1;
44
- }, C = (t) => {
52
+ }), A = (t) => {
53
+ const a = () => {
54
+ var n;
55
+ if (!e.modelValue[e.endField]) return !1;
56
+ let l = i(e.modelValue[e.endField]);
57
+ return e.intraday && !((n = e.datePickerProps) != null && n.showTime) && (l = l.add(1, "day")), i(t).isAfter(l);
58
+ };
59
+ return e.disabledStartDate ? e.disabledStartDate({ current: t, enabled: a() }) : a();
60
+ }, H = (t) => {
61
+ const a = () => {
62
+ var o;
63
+ return e.modelValue[e.startField] ? (e.intraday && ((o = e.datePickerProps) != null && o.showTime) && t.setDate(t.getDate() + 1), i(t).isBefore(i(e.modelValue[e.startField]))) : !1;
64
+ };
65
+ return e.disabledEndDate ? e.disabledEndDate({ current: t, enabled: a() }) : a();
66
+ }, L = (t) => {
45
67
  if (!e.modelValue[e.startField] || !t || !e.intraday) {
46
- n.value = {};
68
+ p.value = {};
47
69
  return;
48
70
  }
49
- const a = o(e.modelValue[e.startField]), d = o(t);
50
- if (!a.isSame(d, "day")) {
51
- n.value = {};
71
+ const a = i(e.modelValue[e.startField]), l = i(t);
72
+ if (!a.isSame(l, "day")) {
73
+ p.value = {};
52
74
  return;
53
75
  }
54
- const l = a.hour(), r = a.minute(), B = a.second();
55
- n.value = {
56
- disabledHours: () => f(0, l),
57
- disabledMinutes: (m) => m === l ? f(0, r) : [],
58
- disabledSeconds: (m, _) => m === l && _ === r ? f(0, B) : []
76
+ const o = a.hour(), n = a.minute(), _ = a.second();
77
+ p.value = {
78
+ disabledHours: () => g(0, o),
79
+ disabledMinutes: (D) => D === o ? g(0, n) : [],
80
+ disabledSeconds: (D, $) => D === o && $ === n ? g(0, _) : []
59
81
  };
60
- }, T = () => {
82
+ }, M = () => {
61
83
  setTimeout(() => {
62
84
  const t = e.modelValue[e.endField], a = e.modelValue[e.startField];
63
- o(a).isAfter(o(t)) && (u.value = t), t && !a && D(() => {
64
- var l;
65
- const d = (l = P.value) == null ? void 0 : l.$el.parentElement.querySelector("input");
66
- d && d.click();
85
+ a && t && i(a).isAfter(i(t)) && (V.value = t), !t && a && w(() => {
86
+ var o;
87
+ const l = (o = C.value) == null ? void 0 : o.$el.parentElement.querySelector("input");
88
+ l && l.click();
67
89
  });
68
90
  });
69
- }, E = () => {
91
+ }, U = () => {
70
92
  setTimeout(() => {
71
- e.modelValue[e.endField] && !e.modelValue[e.startField] && D(() => {
93
+ e.modelValue[e.endField] && !e.modelValue[e.startField] && w(() => {
72
94
  var a;
73
- const t = (a = h.value) == null ? void 0 : a.$el.parentElement.querySelector("input");
95
+ const t = (a = E.value) == null ? void 0 : a.$el.parentElement.querySelector("input");
74
96
  t && t.click();
75
97
  });
76
98
  });
77
- };
78
- return (t, a) => {
79
- const d = b("a-date-picker"), l = b("a-form-item");
80
- return I(), w("div", {
81
- class: N(H)
82
- }, [
83
- i(l, s(t.formItemProps, {
84
- field: t.startField,
85
- "hide-label": t.hideLabel
86
- }), {
87
- default: c(() => [
88
- i(d, s({
89
- ref_key: "startDatePickerRef",
90
- ref: h,
91
- modelValue: u.value,
92
- "onUpdate:modelValue": a[0] || (a[0] = (r) => u.value = r)
93
- }, t.datePickerProps, {
94
- placeholder: t.startPlaceholder,
95
- "disabled-date": (r) => v(r),
96
- onChange: T
97
- }), null, 16, ["modelValue", "placeholder", "disabled-date"])
98
- ]),
99
- _: 1
100
- }, 16, ["field", "hide-label"]),
101
- i(l, {
102
- "hide-label": "",
103
- style: { "max-height": "32px", top: "0px" }
104
- }, {
105
- default: c(() => [
106
- q(A(t.separator), 1)
107
- ]),
108
- _: 1
109
- }),
110
- i(l, s(t.formItemProps, {
111
- field: t.endField,
112
- "hide-label": "",
113
- style: { "margin-right": "0px" }
114
- }), {
115
- default: c(() => [
116
- i(d, s({
117
- ref_key: "endDatePickerRef",
118
- ref: P,
119
- modelValue: k.value,
120
- "onUpdate:modelValue": a[1] || (a[1] = (r) => k.value = r)
121
- }, t.datePickerProps, {
122
- placeholder: t.endPlaceholder,
123
- "disabled-date": (r) => S(r),
124
- "disabled-time": () => n.value,
125
- onSelect: C,
126
- onChange: E
127
- }), null, 16, ["modelValue", "placeholder", "disabled-date", "disabled-time"])
128
- ]),
129
- _: 1
130
- }, 16, ["field"])
131
- ]);
132
- };
99
+ }, T = h(() => {
100
+ var t, a;
101
+ return f(c({}, q([e.datePickerProps, (t = x.dateRangePicker) == null ? void 0 : t.datePickerProps, {}])), {
102
+ timePickerProps: q([e.timePickerProps, (a = x.dateRangePicker) == null ? void 0 : a.timePickerProps], {})
103
+ });
104
+ });
105
+ return (t, a) => (W(), Q("div", {
106
+ class: X(ee),
107
+ ref_key: "dateRef",
108
+ ref: v
109
+ }, [
110
+ u(m(F), P(t.formItemProps, {
111
+ "validate-status": b.value,
112
+ field: t.startField,
113
+ "hide-label": t.hideLabel
114
+ }), {
115
+ default: y(() => [
116
+ u(m(N), P({
117
+ ref_key: "startDatePickerRef",
118
+ ref: E,
119
+ modelValue: V.value,
120
+ "onUpdate:modelValue": a[0] || (a[0] = (l) => V.value = l)
121
+ }, T.value, {
122
+ "popup-container": v.value,
123
+ placeholder: t.startPlaceholder,
124
+ "disabled-date": (l) => A(l),
125
+ onChange: M
126
+ }), null, 16, ["modelValue", "popup-container", "placeholder", "disabled-date"])
127
+ ]),
128
+ _: 1
129
+ }, 16, ["validate-status", "field", "hide-label"]),
130
+ u(m(F), {
131
+ "hide-label": "",
132
+ style: { "max-height": "32px", top: "0px" }
133
+ }, {
134
+ default: y(() => [
135
+ Y(Z(t.separator), 1)
136
+ ]),
137
+ _: 1
138
+ }),
139
+ u(m(F), P(t.formItemProps, {
140
+ "validate-status": k.value,
141
+ field: t.endField,
142
+ "hide-label": "",
143
+ style: { "margin-right": "0px" }
144
+ }), {
145
+ default: y(() => [
146
+ u(m(N), P({
147
+ ref_key: "endDatePickerRef",
148
+ ref: C,
149
+ modelValue: R.value,
150
+ "onUpdate:modelValue": a[1] || (a[1] = (l) => R.value = l)
151
+ }, T.value, {
152
+ "popup-container": v.value,
153
+ placeholder: t.endPlaceholder,
154
+ "disabled-date": (l) => H(l),
155
+ "disabled-time": () => p.value,
156
+ onSelect: L,
157
+ onChange: U
158
+ }), null, 16, ["modelValue", "popup-container", "placeholder", "disabled-date", "disabled-time"])
159
+ ]),
160
+ _: 1
161
+ }, 16, ["validate-status", "field"])
162
+ ], 512));
133
163
  }
134
164
  });
135
165
  export {
136
- $ as default
166
+ se as default
137
167
  };
@@ -0,0 +1,49 @@
1
+ import { App } from 'vue';
2
+ declare const ProDatesPicker: {
3
+ new (...args: any[]): import('vue').CreateComponentPublicInstanceWithMixins<Readonly<import('./interface').IProDatesPickerProps> & Readonly<{
4
+ "onUpdate:modelValue"?: ((value: string | string[]) => any) | undefined;
5
+ onClear?: ((ev: FocusEvent) => any) | undefined;
6
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
7
+ "update:modelValue": (value: string | string[]) => any;
8
+ clear: (ev: FocusEvent) => any;
9
+ }, import('vue').PublicProps, {
10
+ allowClear: boolean;
11
+ maxLength: number;
12
+ }, false, {}, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, {
13
+ datePickerRef: HTMLDivElement;
14
+ }, HTMLDivElement, import('vue').ComponentProvideOptions, {
15
+ P: {};
16
+ B: {};
17
+ D: {};
18
+ C: {};
19
+ M: {};
20
+ Defaults: {};
21
+ }, Readonly<import('./interface').IProDatesPickerProps> & Readonly<{
22
+ "onUpdate:modelValue"?: ((value: string | string[]) => any) | undefined;
23
+ onClear?: ((ev: FocusEvent) => any) | undefined;
24
+ }>, {}, {}, {}, {}, {
25
+ allowClear: boolean;
26
+ maxLength: number;
27
+ }>;
28
+ __isFragment?: never;
29
+ __isTeleport?: never;
30
+ __isSuspense?: never;
31
+ } & import('vue').ComponentOptionsBase<Readonly<import('./interface').IProDatesPickerProps> & Readonly<{
32
+ "onUpdate:modelValue"?: ((value: string | string[]) => any) | undefined;
33
+ onClear?: ((ev: FocusEvent) => any) | undefined;
34
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
35
+ "update:modelValue": (value: string | string[]) => any;
36
+ clear: (ev: FocusEvent) => any;
37
+ }, string, {
38
+ allowClear: boolean;
39
+ maxLength: number;
40
+ }, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps & (new () => {
41
+ $slots: Partial<Record<NonNullable<string | number>, (_: any) => any>>;
42
+ }) & {
43
+ install: (app: App) => void;
44
+ };
45
+ /** 导出类型 */
46
+ export * from './interface';
47
+ /** 导出组件 */
48
+ export { ProDatesPicker };
49
+ export default ProDatesPicker;
@@ -0,0 +1,11 @@
1
+ import t from "./index.vue.js";
2
+ /* empty css */
3
+ const s = Object.assign(t, {
4
+ install: (o) => {
5
+ o.component("KbProDatesPicker", t);
6
+ }
7
+ });
8
+ export {
9
+ s as ProDatesPicker,
10
+ s as default
11
+ };
@@ -0,0 +1,29 @@
1
+ import { IProDatesPickerProps } from './interface.ts';
2
+ declare function __VLS_template(): {
3
+ attrs: Partial<{}>;
4
+ slots: Partial<Record<NonNullable<string | number>, (_: any) => any>>;
5
+ refs: {
6
+ datePickerRef: HTMLDivElement;
7
+ };
8
+ rootEl: HTMLDivElement;
9
+ };
10
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
11
+ declare const __VLS_component: import('vue').DefineComponent<IProDatesPickerProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
12
+ "update:modelValue": (value: string | string[]) => any;
13
+ clear: (ev: FocusEvent) => any;
14
+ }, string, import('vue').PublicProps, Readonly<IProDatesPickerProps> & Readonly<{
15
+ "onUpdate:modelValue"?: ((value: string | string[]) => any) | undefined;
16
+ onClear?: ((ev: FocusEvent) => any) | undefined;
17
+ }>, {
18
+ allowClear: boolean;
19
+ maxLength: number;
20
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
21
+ datePickerRef: HTMLDivElement;
22
+ }, HTMLDivElement>;
23
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
24
+ export default _default;
25
+ type __VLS_WithTemplateSlots<T, S> = T & {
26
+ new (): {
27
+ $slots: S;
28
+ };
29
+ };
@@ -0,0 +1,135 @@
1
+ var C = Object.getOwnPropertySymbols;
2
+ var N = Object.prototype.hasOwnProperty, A = Object.prototype.propertyIsEnumerable;
3
+ var y = (s, k) => {
4
+ var m = {};
5
+ for (var r in s)
6
+ N.call(s, r) && k.indexOf(r) < 0 && (m[r] = s[r]);
7
+ if (s != null && C)
8
+ for (var r of C(s))
9
+ k.indexOf(r) < 0 && A.call(s, r) && (m[r] = s[r]);
10
+ return m;
11
+ };
12
+ import { defineComponent as j, ref as Y, useSlots as O, useAttrs as T, computed as x, onMounted as U, createElementBlock as W, openBlock as q, normalizeClass as F, createVNode as P, unref as u, withCtx as g, mergeProps as M, withModifiers as G, createSlots as H, createElementVNode as S, normalizeStyle as J, toDisplayString as K, renderList as Q, renderSlot as X, normalizeProps as Z, guardReactiveProps as ee } from "vue";
13
+ import { conclude as V } from "vue-global-config";
14
+ import { Popover as te, Input as re, DatePicker as oe } from "@arco-design/web-vue";
15
+ import { IconCalendar as le } from "@arco-design/web-vue/es/icon";
16
+ import { globalProps as $ } from "../global-props.js";
17
+ import d from "dayjs";
18
+ import { initSelected as ae, transDatesString as b } from "./util.js";
19
+ const ne = ["onClick"], se = "keyblade-pro-dates-picker", ge = /* @__PURE__ */ j({
20
+ __name: "index",
21
+ props: {
22
+ modelValue: {},
23
+ defaultValue: {},
24
+ size: {},
25
+ allowClear: { type: Boolean, default: !0 },
26
+ disabled: { type: Boolean },
27
+ readonly: { type: Boolean },
28
+ error: { type: Boolean },
29
+ placeholder: {},
30
+ maxLength: { default: 100 },
31
+ showWordLimit: { type: Boolean },
32
+ wordLength: {},
33
+ wordSlice: {},
34
+ inputAttrs: {},
35
+ type: {},
36
+ prepend: {},
37
+ append: {},
38
+ datePickerProps: {}
39
+ },
40
+ emits: ["update:modelValue", "clear"],
41
+ setup(s, { emit: k }) {
42
+ const m = {
43
+ placeholder: "请选择日期",
44
+ datePickerProps: {
45
+ hideTrigger: !0
46
+ }
47
+ }, r = k, c = s, h = Y(), _ = Y(null), f = Y(ae(c.modelValue)), w = O(), B = T(), D = Y(), I = x(() => {
48
+ const v = c, { datePickerProps: e } = v, a = y(v, ["datePickerProps"]), n = m, { datePickerProps: o } = n, i = y(n, ["datePickerProps"]);
49
+ return V([a, $.datesPicker || {}, i]);
50
+ }), L = x(() => {
51
+ var e;
52
+ return V([c.datePickerProps, ((e = $.datesPicker) == null ? void 0 : e.datePickerProps) || {}, m.datePickerProps]);
53
+ }), t = x({
54
+ get: () => c.modelValue,
55
+ set: (e) => {
56
+ typeof e == "string" ? r("update:modelValue", e || "") : r("update:modelValue", e || []);
57
+ }
58
+ });
59
+ U(() => {
60
+ (c.modelValue === null || c.modelValue === void 0) && (t.value = []);
61
+ });
62
+ const R = (e) => {
63
+ var i, p, v;
64
+ const a = d(e).format("YYYY-MM-DD"), o = f.value.findIndex((n) => d(n).format("YYYY-MM-DD") === d(e).format("YYYY-MM-DD"));
65
+ if (o !== -1) {
66
+ if (f.value.splice(o, 1), typeof t.value == "string") {
67
+ const n = a.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
68
+ let l = (i = b(t.value)) == null ? void 0 : i.replace(new RegExp(`${n}, `, "g"), "");
69
+ l = l == null ? void 0 : l.replace(new RegExp(`${n}`, "g"), ""), l = l == null ? void 0 : l.replace(/^, |, $/g, "").replace(/,{2,}/g, ",").trim(), t.value = l || "";
70
+ } else if (t.value) {
71
+ const n = (p = t.value) == null ? void 0 : p.findIndex((l) => d(l).format("YYYY-MM-DD") === d(e).format("YYYY-MM-DD"));
72
+ n !== -1 && t.value.splice(n, 1);
73
+ }
74
+ D.value = e.getDate();
75
+ } else
76
+ f.value.length < c.maxLength && (f.value.push(e), typeof t.value == "string" ? t.value += t.value ? `, ${a}` : a : (v = t.value) == null || v.push(a)), D.value = void 0;
77
+ }, z = (e) => D.value === e.getDate() ? { backgroundColor: "transparent", color: "var(--color-text-1)" } : f.value.some((o) => d(o).format("YYYY-MM-DD") === d(e).format("YYYY-MM-DD")) ? { backgroundColor: "rgb(var(--primary-6))", color: "var(--color-white)" } : {}, E = (e) => {
78
+ f.value = [], t.value = typeof t.value == "string" ? "" : [], r("clear", e);
79
+ };
80
+ return (e, a) => (q(), W("div", {
81
+ class: F(se),
82
+ ref_key: "datePickerRef",
83
+ ref: h
84
+ }, [
85
+ P(u(te), {
86
+ position: "bl",
87
+ "popup-container": h.value,
88
+ trigger: "click"
89
+ }, {
90
+ content: g(() => [
91
+ P(u(oe), M(L.value, {
92
+ pickerValue: _.value,
93
+ "onUpdate:pickerValue": a[0] || (a[0] = (o) => _.value = o),
94
+ style: { width: "268px" }
95
+ }), H({
96
+ cell: g(({ date: o }) => [
97
+ S("div", {
98
+ class: "arco-picker-date",
99
+ onClick: (i) => R(o)
100
+ }, [
101
+ S("div", {
102
+ style: J(z(o)),
103
+ class: "arco-picker-date-value"
104
+ }, K(o.getDate()), 5)
105
+ ], 8, ne)
106
+ ]),
107
+ _: 2
108
+ }, [
109
+ Q(u(w), (o, i) => ({
110
+ name: i,
111
+ fn: g((p) => [
112
+ X(e.$slots, i, Z(ee(p != null ? p : {})))
113
+ ])
114
+ }))
115
+ ]), 1040, ["pickerValue"])
116
+ ]),
117
+ default: g(() => [
118
+ P(u(re), M(M(I.value, u(B)), {
119
+ "model-value": u(b)(t.value),
120
+ onClear: G(E, ["stop"])
121
+ }), {
122
+ suffix: g(() => [
123
+ P(u(le))
124
+ ]),
125
+ _: 1
126
+ }, 16, ["model-value"])
127
+ ]),
128
+ _: 3
129
+ }, 8, ["popup-container"])
130
+ ], 512));
131
+ }
132
+ });
133
+ export {
134
+ ge as default
135
+ };
@@ -0,0 +1,5 @@
1
+ import o from "./index.vue.js";
2
+ /* empty css */
3
+ export {
4
+ o as default
5
+ };
@@ -0,0 +1,38 @@
1
+ import { RangePickerProps } from '@arco-design/web-vue/es/date-picker/interface';
2
+ export interface IProDatesPickerProps {
3
+ /** 绑定值 */
4
+ modelValue?: string | Array<string>;
5
+ /** 默认值 */
6
+ defaultValue?: string;
7
+ /** 输入框大小 */
8
+ size?: string;
9
+ /** 是否允许清空输入框 */
10
+ allowClear?: boolean;
11
+ /** 是否禁用 */
12
+ disabled?: boolean;
13
+ /** 是否为只读状态 */
14
+ readonly?: boolean;
15
+ /** 是否为错误状态 */
16
+ error?: boolean;
17
+ /** 提示文字 */
18
+ placeholder?: string;
19
+ /** 最大日期个数 */
20
+ maxLength?: number;
21
+ /** 是否显示字数统计 */
22
+ showWordLimit?: boolean;
23
+ /** 自定义字数计算方法 */
24
+ wordLength?: (value: string) => number;
25
+ /** 超出最大长度时的截取方法 */
26
+ wordSlice?: (value: string, maxLength: number) => string;
27
+ /** 原生 input 元素的额外属性 */
28
+ inputAttrs?: Record<string, any>;
29
+ /** 输入框类型 */
30
+ type?: string;
31
+ /** 前置标签 */
32
+ prepend?: string;
33
+ /** 后置标签 */
34
+ append?: string;
35
+ /** 日期选择器配置 */
36
+ datePickerProps?: Partial<RangePickerProps>;
37
+ }
38
+ export type ProDatesPickerProps = Partial<IProDatesPickerProps>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * 转换成显示字符串
3
+ * @param value
4
+ * @returns
5
+ */
6
+ export declare const transDatesString: (value?: string | Array<string>) => string;
7
+ /**
8
+ * 初始化
9
+ * @param value
10
+ * @returns
11
+ */
12
+ export declare const initSelected: (value?: string | Array<string>) => Date[];
@@ -0,0 +1,9 @@
1
+ import n from "dayjs";
2
+ const i = (t) => {
3
+ const r = n(t);
4
+ return r.isValid() ? r.format("YYYY-MM-DD") : "";
5
+ }, o = (t) => t ? typeof t == "string" ? t.replace(/,(?=\S)/g, ", ") : t.map((e) => i(e)).filter(Boolean).join(", ") : "", a = (t) => t ? typeof t == "string" ? t.split(",").map((r) => new Date(r)) : t.map((r) => new Date(r)) : [];
6
+ export {
7
+ a as initSelected,
8
+ o as transDatesString
9
+ };
@@ -0,0 +1,8 @@
1
+ export declare enum EFindPasswordSteps {
2
+ /** 验证用户名 */
3
+ verify = 1,
4
+ /** 修改密码 */
5
+ reset = 2,
6
+ /** 成功 */
7
+ succeed = 3
8
+ }
@@ -0,0 +1,4 @@
1
+ var c = /* @__PURE__ */ ((e) => (e[e.verify = 1] = "verify", e[e.reset = 2] = "reset", e[e.succeed = 3] = "succeed", e))(c || {});
2
+ export {
3
+ c as EFindPasswordSteps
4
+ };
@@ -0,0 +1,11 @@
1
+ import { App } from 'vue';
2
+ import { default as _ProFindPassword } from './index.vue';
3
+ type ProFindPasswordType = typeof _ProFindPassword & {
4
+ install: (app: App) => void;
5
+ };
6
+ declare const ProFindPassword: ProFindPasswordType;
7
+ /** 导出类型 */
8
+ export * from './interface';
9
+ /** 导出组件 */
10
+ export { ProFindPassword };
11
+ export default ProFindPassword;
@@ -0,0 +1,11 @@
1
+ import o from "./index.vue.js";
2
+ /* empty css */
3
+ const t = Object.assign(o, {
4
+ install: (s) => {
5
+ s.component("KbProFindPassword", o);
6
+ }
7
+ });
8
+ export {
9
+ t as ProFindPassword,
10
+ t as default
11
+ };