@easyv/biz-components 2.1.3 → 2.1.4

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 (147) hide show
  1. package/dist/lib/components/ai-components/ai-message-render/ai-message-render.es.js +1 -0
  2. package/dist/lib/components/ai-components/ai-message-render/ai-message-render.es.js.map +1 -1
  3. package/dist/lib/components/ai-components/mobile-voice-input/icon-button.es.js +3 -2
  4. package/dist/lib/components/ai-components/mobile-voice-input/icon-button.es.js.map +1 -1
  5. package/dist/lib/components/ai-components/mobile-voice-input/mobile-voice-input.es.js +11 -8
  6. package/dist/lib/components/ai-components/mobile-voice-input/mobile-voice-input.es.js.map +1 -1
  7. package/dist/lib/easyv-biz-components/src/components/easyv-reactgrid/test/easyv-react-grid.cy.d.ts +1 -0
  8. package/dist/lib/easyv-biz-components/src/components/voice-animation/test/voice-animation.cy.d.ts +1 -0
  9. package/dist/lib/easyv-biz-components/src/index.d.ts +4 -0
  10. package/dist/lib/easyv-biz-components/src/utils/show-modal/test/show-modal.cy.d.ts +1 -0
  11. package/dist/lib/hooks/use-tencent-sentence-recognition/use-tencent-sentence-recognition.es.js +3 -2
  12. package/dist/lib/hooks/use-tencent-sentence-recognition/use-tencent-sentence-recognition.es.js.map +1 -1
  13. package/dist/lib/index.d.ts +1 -4
  14. package/dist/lib/packages/easyv-arco/dist/lib/chunks/button-Dip6wfc7.es.es.js +29 -0
  15. package/dist/lib/packages/easyv-arco/dist/lib/chunks/button-Dip6wfc7.es.es.js.map +1 -0
  16. package/dist/lib/packages/easyv-arco/dist/lib/chunks/index-EAFzPBke.es.es.js +720 -0
  17. package/dist/lib/packages/easyv-arco/dist/lib/chunks/index-EAFzPBke.es.es.js.map +1 -0
  18. package/dist/lib/packages/easyv-arco/dist/lib/chunks/index-zvVd1BJp.es.es.js +3508 -0
  19. package/dist/lib/packages/easyv-arco/dist/lib/chunks/index-zvVd1BJp.es.es.js.map +1 -0
  20. package/dist/lib/packages/easyv-arco/dist/lib/chunks/input-Dhdn9e9Z.es.es.js +1276 -0
  21. package/dist/lib/packages/easyv-arco/dist/lib/chunks/input-Dhdn9e9Z.es.es.js.map +1 -0
  22. package/dist/lib/packages/easyv-arco/dist/lib/chunks/keycode-DOHuQiUY.es.es.js +77 -0
  23. package/dist/lib/packages/easyv-arco/dist/lib/chunks/keycode-DOHuQiUY.es.es.js.map +1 -0
  24. package/dist/lib/packages/easyv-arco/dist/lib/index.es.es.js +2 -0
  25. package/dist/lib/packages/easyv-arco/dist/lib/index.es.es.js.map +1 -0
  26. package/dist/lib/stats.html +1 -1
  27. package/dist/lib/utils/show-modal/show-modal.es.js +5 -5
  28. package/dist/lib/utils/show-modal/show-modal.es.js.map +1 -1
  29. package/dist/tailwindcss.pkg.css +0 -4
  30. package/package.json +3 -2
  31. package/dist/lib/components/ai-components/ai-message-render/test/ai-message-render.cy.d.ts +0 -1
  32. package/dist/lib/components/ai-components/ai-message-render/test/ai-message-table.cy.d.ts +0 -1
  33. package/dist/lib/utils/show-modal/test/show-modal.cy.d.ts +0 -1
  34. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/ai-message-render.d.ts +0 -0
  35. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/constants.d.ts +0 -0
  36. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/image-preview.d.ts +0 -0
  37. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/index.d.ts +0 -0
  38. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/render-utils.d.ts +0 -0
  39. /package/dist/lib/{components/easyv-monaco-editor/test/easyv-monaco-editor.cy.d.ts → easyv-biz-components/src/components/ai-components/ai-message-render/test/ai-message-render.cy.d.ts} +0 -0
  40. /package/dist/lib/{components/easyv-reactgrid/test/easyv-react-grid.cy.d.ts → easyv-biz-components/src/components/ai-components/ai-message-render/test/ai-message-table.cy.d.ts} +0 -0
  41. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/types.d.ts +0 -0
  42. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/ai-message-render/utils.d.ts +0 -0
  43. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/mobile-voice-input/icon-button.d.ts +0 -0
  44. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/mobile-voice-input/index.d.ts +0 -0
  45. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-components/mobile-voice-input/mobile-voice-input.d.ts +0 -0
  46. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-model-select/ai-model-select-panel.d.ts +0 -0
  47. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-model-select/iconBtn.d.ts +0 -0
  48. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-model-select/index.d.ts +0 -0
  49. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-model-select/test/ai-model-select-panel.cy.d.ts +0 -0
  50. /package/dist/lib/{components → easyv-biz-components/src/components}/ai-model-select/types.d.ts +0 -0
  51. /package/dist/lib/{components → easyv-biz-components/src/components}/circle-loading/circle-loading.d.ts +0 -0
  52. /package/dist/lib/{components → easyv-biz-components/src/components}/circle-loading/index.d.ts +0 -0
  53. /package/dist/lib/{components → easyv-biz-components/src/components}/circle-loading/test/circle-loading.cy.d.ts +0 -0
  54. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/code-mirror-editor.d.ts +0 -0
  55. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/constants.d.ts +0 -0
  56. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/format-utils.d.ts +0 -0
  57. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/index.d.ts +0 -0
  58. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/test/CodeEditor.cy.d.ts +0 -0
  59. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/theme.d.ts +0 -0
  60. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/types.d.ts +0 -0
  61. /package/dist/lib/{components → easyv-biz-components/src/components}/code-mirror-editor/utils.d.ts +0 -0
  62. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-monaco-editor/easyv-monaco-editor.d.ts +0 -0
  63. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-monaco-editor/index.d.ts +0 -0
  64. /package/dist/lib/{components/voice-animation/test/voice-animation.cy.d.ts → easyv-biz-components/src/components/easyv-monaco-editor/test/easyv-monaco-editor.cy.d.ts} +0 -0
  65. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-monaco-editor/types.d.ts +0 -0
  66. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-reactgrid/constants.d.ts +0 -0
  67. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-reactgrid/easyv-react-grid.d.ts +0 -0
  68. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-reactgrid/index.d.ts +0 -0
  69. /package/dist/lib/{components → easyv-biz-components/src/components}/easyv-reactgrid/utils.d.ts +0 -0
  70. /package/dist/lib/{components → easyv-biz-components/src/components}/echarts-render/constants.d.ts +0 -0
  71. /package/dist/lib/{components → easyv-biz-components/src/components}/echarts-render/echarts-render.d.ts +0 -0
  72. /package/dist/lib/{components → easyv-biz-components/src/components}/echarts-render/index.d.ts +0 -0
  73. /package/dist/lib/{components → easyv-biz-components/src/components}/echarts-render/test/echarts.cy.d.ts +0 -0
  74. /package/dist/lib/{components → easyv-biz-components/src/components}/echarts-render/types.d.ts +0 -0
  75. /package/dist/lib/{components → easyv-biz-components/src/components}/error-boundary/error-boundary.d.ts +0 -0
  76. /package/dist/lib/{components → easyv-biz-components/src/components}/error-boundary/index.d.ts +0 -0
  77. /package/dist/lib/{components → easyv-biz-components/src/components}/index.d.ts +0 -0
  78. /package/dist/lib/{components → easyv-biz-components/src/components}/scroll-controller/index.d.ts +0 -0
  79. /package/dist/lib/{components → easyv-biz-components/src/components}/scroll-controller/scroll-controller.d.ts +0 -0
  80. /package/dist/lib/{components → easyv-biz-components/src/components}/shadow-dom/index.d.ts +0 -0
  81. /package/dist/lib/{components → easyv-biz-components/src/components}/shadow-dom/shadow-dom.d.ts +0 -0
  82. /package/dist/lib/{components → easyv-biz-components/src/components}/voice-animation/index.d.ts +0 -0
  83. /package/dist/lib/{components → easyv-biz-components/src/components}/voice-animation/voice-animation.d.ts +0 -0
  84. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/index.d.ts +0 -0
  85. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-ai-agent-message/constants.d.ts +0 -0
  86. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-ai-agent-message/index.d.ts +0 -0
  87. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-ai-agent-message/types.d.ts +0 -0
  88. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-ai-agent-message/use-ai-agent-message.d.ts +0 -0
  89. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-ai-agent-message/utils.d.ts +0 -0
  90. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-div-auto-scroll.d.ts +0 -0
  91. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-document-unmount/index.d.ts +0 -0
  92. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-document-unmount/use-document-unmount.d.ts +0 -0
  93. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-initialized.d.ts +0 -0
  94. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-socket-events/constant.d.ts +0 -0
  95. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-socket-events/index.d.ts +0 -0
  96. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-socket-events/types.d.ts +0 -0
  97. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-socket-events/use-socket-events.d.ts +0 -0
  98. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-tencent-sentence-recognition/index.d.ts +0 -0
  99. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-tencent-sentence-recognition/use-tencent-sentence-recognition.d.ts +0 -0
  100. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-watch-value/playground.cy.d.ts +0 -0
  101. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-watch-value/use-watch-value.cy.d.ts +0 -0
  102. /package/dist/lib/{hooks → easyv-biz-components/src/hooks}/use-watch-value/use-watch-value.d.ts +0 -0
  103. /package/dist/lib/{types → easyv-biz-components/src/types}/ai-agent.d.ts +0 -0
  104. /package/dist/lib/{types → easyv-biz-components/src/types}/common.d.ts +0 -0
  105. /package/dist/lib/{types → easyv-biz-components/src/types}/index.d.ts +0 -0
  106. /package/dist/lib/{utils → easyv-biz-components/src/utils}/ai-agent-message-manager/ai-agent-message-manager.d.ts +0 -0
  107. /package/dist/lib/{utils → easyv-biz-components/src/utils}/ai-agent-message-manager/constants.d.ts +0 -0
  108. /package/dist/lib/{utils → easyv-biz-components/src/utils}/ai-agent-message-manager/index.d.ts +0 -0
  109. /package/dist/lib/{utils → easyv-biz-components/src/utils}/ai-agent-message-manager/types.d.ts +0 -0
  110. /package/dist/lib/{utils → easyv-biz-components/src/utils}/ai-agent-message-manager/utils.d.ts +0 -0
  111. /package/dist/lib/{utils → easyv-biz-components/src/utils}/common/common.d.ts +0 -0
  112. /package/dist/lib/{utils → easyv-biz-components/src/utils}/common/index.d.ts +0 -0
  113. /package/dist/lib/{utils → easyv-biz-components/src/utils}/common/url.d.ts +0 -0
  114. /package/dist/lib/{utils → easyv-biz-components/src/utils}/common/voice-helper-utils.d.ts +0 -0
  115. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/common.d.ts +0 -0
  116. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/component-dimension.d.ts +0 -0
  117. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/constants.d.ts +0 -0
  118. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/easyv-gui-helper.d.ts +0 -0
  119. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/index.d.ts +0 -0
  120. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/test/get-config-value.cy.d.ts +0 -0
  121. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/test/get-new-config-from-value.cy.d.ts +0 -0
  122. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/test/test-data.d.ts +0 -0
  123. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/test/update-gui-config-list.cy.d.ts +0 -0
  124. /package/dist/lib/{utils → easyv-biz-components/src/utils}/easyv-gui-helper/types.d.ts +0 -0
  125. /package/dist/lib/{utils → easyv-biz-components/src/utils}/fetch-knowledge/fetch-knowledge.d.ts +0 -0
  126. /package/dist/lib/{utils → easyv-biz-components/src/utils}/fetch-knowledge/index.d.ts +0 -0
  127. /package/dist/lib/{utils → easyv-biz-components/src/utils}/fun-ASR/fun-ASR-manager.d.ts +0 -0
  128. /package/dist/lib/{utils → easyv-biz-components/src/utils}/fun-ASR/index.d.ts +0 -0
  129. /package/dist/lib/{utils → easyv-biz-components/src/utils}/index.d.ts +0 -0
  130. /package/dist/lib/{utils → easyv-biz-components/src/utils}/show-modal/index.d.ts +0 -0
  131. /package/dist/lib/{utils → easyv-biz-components/src/utils}/show-modal/show-modal.d.ts +0 -0
  132. /package/dist/lib/{utils → easyv-biz-components/src/utils}/voice-record-manager/index.d.ts +0 -0
  133. /package/dist/lib/{utils → easyv-biz-components/src/utils}/voice-record-manager/voice-record-manager.d.ts +0 -0
  134. /package/dist/lib/{utils → easyv-biz-components/src/utils}/vosk-browser-manager/audio-manager/audio-manager.d.ts +0 -0
  135. /package/dist/lib/{utils → easyv-biz-components/src/utils}/vosk-browser-manager/audio-manager/test/audio-manager.cy.d.ts +0 -0
  136. /package/dist/lib/{utils → easyv-biz-components/src/utils}/vosk-browser-manager/audio-manager/types.d.ts +0 -0
  137. /package/dist/lib/{utils → easyv-biz-components/src/utils}/vosk-browser-manager/index.d.ts +0 -0
  138. /package/dist/lib/{utils → easyv-biz-components/src/utils}/vosk-browser-manager/test/voskBrowserManager.cy.d.ts +0 -0
  139. /package/dist/lib/{utils → easyv-biz-components/src/utils}/vosk-browser-manager/vosk-browser-manager.d.ts +0 -0
  140. /package/dist/lib/{utils → easyv-biz-components/src/utils}/wait-something/index.d.ts +0 -0
  141. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/XF-stream-voice-manager.d.ts +0 -0
  142. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/index.d.ts +0 -0
  143. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/recorder-manager/RecorderManager-draft.d.ts +0 -0
  144. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/recorder-manager/index.d.ts +0 -0
  145. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/test/RecorderManager.cy.d.ts +0 -0
  146. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/test/XunFeiVoiceManager.cy.d.ts +0 -0
  147. /package/dist/lib/{utils → easyv-biz-components/src/utils}/xun-fei-voice/types.d.ts +0 -0
@@ -0,0 +1,1276 @@
1
+ import { j as kr$1, B as _e$1 } from "./index-EAFzPBke.es.es.js";
2
+ import React__default, { useContext, useState, useRef, useImperativeHandle, useMemo, useEffect, useCallback, cloneElement, isValidElement, useLayoutEffect } from "react";
3
+ import { C as _e, u as Lr$1, h as wt$1, c as De$1, i as be$1, n as xr$1, o as Ar$1, k as cr$1, l as We$1, f as Un, g as Xr$1, s as vn$1, b as Vn$1, m as Sr$1, a as Or$1, I as Nt$1, d as ie$1, _ as fe, e as Ee, j as Se } from "./index-zvVd1BJp.es.es.js";
4
+ import { u as A, d as _, E, A as b, a as g, b as x, c as S, i as V } from "./keycode-DOHuQiUY.es.es.js";
5
+ var Pt = Object.defineProperty, Rt = Object.defineProperties;
6
+ var Nt = Object.getOwnPropertyDescriptors;
7
+ var me = Object.getOwnPropertySymbols;
8
+ var Fe = Object.prototype.hasOwnProperty, Be = Object.prototype.propertyIsEnumerable;
9
+ var ke = (e, n, t) => n in e ? Pt(e, n, { enumerable: true, configurable: true, writable: true, value: t }) : e[n] = t, Ke = (e, n) => {
10
+ for (var t in n || (n = {}))
11
+ Fe.call(n, t) && ke(e, t, n[t]);
12
+ if (me)
13
+ for (var t of me(n))
14
+ Be.call(n, t) && ke(e, t, n[t]);
15
+ return e;
16
+ }, He = (e, n) => Rt(e, Nt(n));
17
+ var Ge = (e, n) => {
18
+ var t = {};
19
+ for (var r in e)
20
+ Fe.call(e, r) && n.indexOf(r) < 0 && (t[r] = e[r]);
21
+ if (e != null && me)
22
+ for (var r of me(e))
23
+ n.indexOf(r) < 0 && Be.call(e, r) && (t[r] = e[r]);
24
+ return t;
25
+ };
26
+ function Jt(e) {
27
+ var n = typeof e;
28
+ return e != null && (n == "object" || n == "function");
29
+ }
30
+ var Ae = Jt, Qt = typeof Or$1 == "object" && Or$1 && Or$1.Object === Object && Or$1, Yt = Qt, er = Yt, tr = typeof self == "object" && self && self.Object === Object && self, rr = er || tr || Function("return this")(), vt = rr, nr = vt, ir = function() {
31
+ return nr.Date.now();
32
+ }, ar = ir, or = /\s/;
33
+ function lr(e) {
34
+ for (var n = e.length; n-- && or.test(e.charAt(n)); )
35
+ ;
36
+ return n;
37
+ }
38
+ var ur = lr, sr = ur, cr = /^\s+/;
39
+ function fr(e) {
40
+ return e && e.slice(0, sr(e) + 1).replace(cr, "");
41
+ }
42
+ var dr = fr, vr = vt, hr = vr.Symbol, ht = hr, Ze = ht, mt = Object.prototype, mr = mt.hasOwnProperty, gr = mt.toString, ue = Ze ? Ze.toStringTag : void 0;
43
+ function pr(e) {
44
+ var n = mr.call(e, ue), t = e[ue];
45
+ try {
46
+ e[ue] = void 0;
47
+ var r = true;
48
+ } catch (a) {
49
+ }
50
+ var i = gr.call(e);
51
+ return r && (n ? e[ue] = t : delete e[ue]), i;
52
+ }
53
+ var yr = pr, br = Object.prototype, wr = br.toString;
54
+ function Or(e) {
55
+ return wr.call(e);
56
+ }
57
+ var _r = Or, Xe = ht, xr = yr, Cr = _r, Er = "[object Null]", Sr = "[object Undefined]", Je = Xe ? Xe.toStringTag : void 0;
58
+ function jr(e) {
59
+ return e == null ? e === void 0 ? Sr : Er : Je && Je in Object(e) ? xr(e) : Cr(e);
60
+ }
61
+ var Pr = jr;
62
+ function Rr(e) {
63
+ return e != null && typeof e == "object";
64
+ }
65
+ var Nr = Rr, Tr = Pr, Dr = Nr, Ir = "[object Symbol]";
66
+ function zr(e) {
67
+ return typeof e == "symbol" || Dr(e) && Tr(e) == Ir;
68
+ }
69
+ var Mr = zr, Lr = dr, Qe = Ae, Vr = Mr, Ye = NaN, Ar = /^[-+]0x[0-9a-f]+$/i, Wr = /^0b[01]+$/i, $r = /^0o[0-7]+$/i, kr = parseInt;
70
+ function Fr(e) {
71
+ if (typeof e == "number")
72
+ return e;
73
+ if (Vr(e))
74
+ return Ye;
75
+ if (Qe(e)) {
76
+ var n = typeof e.valueOf == "function" ? e.valueOf() : e;
77
+ e = Qe(n) ? n + "" : n;
78
+ }
79
+ if (typeof e != "string")
80
+ return e === 0 ? e : +e;
81
+ e = Lr(e);
82
+ var t = Wr.test(e);
83
+ return t || $r.test(e) ? kr(e.slice(2), t ? 2 : 8) : Ar.test(e) ? Ye : +e;
84
+ }
85
+ var Br = Fr, Kr = Ae, Pe = ar, et = Br, Hr = "Expected a function", Gr = Math.max, Ur = Math.min;
86
+ function qr(e, n, t) {
87
+ var r, i, a, o, l, c, f = 0, u = false, v = false, y = true;
88
+ if (typeof e != "function")
89
+ throw new TypeError(Hr);
90
+ n = et(n) || 0, Kr(t) && (u = !!t.leading, v = "maxWait" in t, a = v ? Gr(et(t.maxWait) || 0, n) : a, y = "trailing" in t ? !!t.trailing : y);
91
+ function s(m) {
92
+ var g2 = r, M = i;
93
+ return r = i = void 0, f = m, o = e.apply(M, g2), o;
94
+ }
95
+ function _2(m) {
96
+ return f = m, l = setTimeout(P, n), u ? s(m) : o;
97
+ }
98
+ function C(m) {
99
+ var g2 = m - c, M = m - f, D = n - g2;
100
+ return v ? Ur(D, a - M) : D;
101
+ }
102
+ function x2(m) {
103
+ var g2 = m - c, M = m - f;
104
+ return c === void 0 || g2 >= n || g2 < 0 || v && M >= a;
105
+ }
106
+ function P() {
107
+ var m = Pe();
108
+ if (x2(m))
109
+ return I(m);
110
+ l = setTimeout(P, C(m));
111
+ }
112
+ function I(m) {
113
+ return l = void 0, y && r ? s(m) : (r = i = void 0, o);
114
+ }
115
+ function R() {
116
+ l !== void 0 && clearTimeout(l), f = 0, r = c = i = l = void 0;
117
+ }
118
+ function N() {
119
+ return l === void 0 ? o : I(Pe());
120
+ }
121
+ function b2() {
122
+ var m = Pe(), g2 = x2(m);
123
+ if (r = arguments, i = this, c = m, g2) {
124
+ if (l === void 0)
125
+ return _2(c);
126
+ if (v)
127
+ return clearTimeout(l), l = setTimeout(P, n), s(c);
128
+ }
129
+ return l === void 0 && (l = setTimeout(P, n)), o;
130
+ }
131
+ return b2.cancel = R, b2.flush = N, b2;
132
+ }
133
+ var Zr = qr, Xr = Zr, Jr = Ae, Qr = "Expected a function";
134
+ function Yr(e, n, t) {
135
+ var r = true, i = true;
136
+ if (typeof e != "function")
137
+ throw new TypeError(Qr);
138
+ return Jr(t) && (r = "leading" in t ? !!t.leading : r, i = "trailing" in t ? !!t.trailing : i), Xr(e, n, {
139
+ leading: r,
140
+ maxWait: n,
141
+ trailing: i
142
+ });
143
+ }
144
+ var en = Yr;
145
+ const tn = /* @__PURE__ */ Xr$1(en);
146
+ var gt = function() {
147
+ if (typeof Map != "undefined")
148
+ return Map;
149
+ function e(n, t) {
150
+ var r = -1;
151
+ return n.some(function(i, a) {
152
+ return i[0] === t ? (r = a, true) : false;
153
+ }), r;
154
+ }
155
+ return (
156
+ /** @class */
157
+ function() {
158
+ function n() {
159
+ this.__entries__ = [];
160
+ }
161
+ return Object.defineProperty(n.prototype, "size", {
162
+ /**
163
+ * @returns {boolean}
164
+ */
165
+ get: function() {
166
+ return this.__entries__.length;
167
+ },
168
+ enumerable: true,
169
+ configurable: true
170
+ }), n.prototype.get = function(t) {
171
+ var r = e(this.__entries__, t), i = this.__entries__[r];
172
+ return i && i[1];
173
+ }, n.prototype.set = function(t, r) {
174
+ var i = e(this.__entries__, t);
175
+ ~i ? this.__entries__[i][1] = r : this.__entries__.push([t, r]);
176
+ }, n.prototype.delete = function(t) {
177
+ var r = this.__entries__, i = e(r, t);
178
+ ~i && r.splice(i, 1);
179
+ }, n.prototype.has = function(t) {
180
+ return !!~e(this.__entries__, t);
181
+ }, n.prototype.clear = function() {
182
+ this.__entries__.splice(0);
183
+ }, n.prototype.forEach = function(t, r) {
184
+ r === void 0 && (r = null);
185
+ for (var i = 0, a = this.__entries__; i < a.length; i++) {
186
+ var o = a[i];
187
+ t.call(r, o[1], o[0]);
188
+ }
189
+ }, n;
190
+ }()
191
+ );
192
+ }(), Te = typeof window != "undefined" && typeof document != "undefined" && window.document === document, ye = function() {
193
+ return typeof global != "undefined" && global.Math === Math ? global : typeof self != "undefined" && self.Math === Math ? self : typeof window != "undefined" && window.Math === Math ? window : Function("return this")();
194
+ }(), rn = function() {
195
+ return typeof requestAnimationFrame == "function" ? requestAnimationFrame.bind(ye) : function(e) {
196
+ return setTimeout(function() {
197
+ return e(Date.now());
198
+ }, 1e3 / 60);
199
+ };
200
+ }(), nn = 2;
201
+ function an(e, n) {
202
+ var t = false, r = false, i = 0;
203
+ function a() {
204
+ t && (t = false, e()), r && l();
205
+ }
206
+ function o() {
207
+ rn(a);
208
+ }
209
+ function l() {
210
+ var c = Date.now();
211
+ if (t) {
212
+ if (c - i < nn)
213
+ return;
214
+ r = true;
215
+ } else
216
+ t = true, r = false, setTimeout(o, n);
217
+ i = c;
218
+ }
219
+ return l;
220
+ }
221
+ var on = 20, ln = ["top", "right", "bottom", "left", "width", "height", "size", "weight"], un = typeof MutationObserver != "undefined", sn = (
222
+ /** @class */
223
+ function() {
224
+ function e() {
225
+ this.connected_ = false, this.mutationEventsAdded_ = false, this.mutationsObserver_ = null, this.observers_ = [], this.onTransitionEnd_ = this.onTransitionEnd_.bind(this), this.refresh = an(this.refresh.bind(this), on);
226
+ }
227
+ return e.prototype.addObserver = function(n) {
228
+ ~this.observers_.indexOf(n) || this.observers_.push(n), this.connected_ || this.connect_();
229
+ }, e.prototype.removeObserver = function(n) {
230
+ var t = this.observers_, r = t.indexOf(n);
231
+ ~r && t.splice(r, 1), !t.length && this.connected_ && this.disconnect_();
232
+ }, e.prototype.refresh = function() {
233
+ var n = this.updateObservers_();
234
+ n && this.refresh();
235
+ }, e.prototype.updateObservers_ = function() {
236
+ var n = this.observers_.filter(function(t) {
237
+ return t.gatherActive(), t.hasActive();
238
+ });
239
+ return n.forEach(function(t) {
240
+ return t.broadcastActive();
241
+ }), n.length > 0;
242
+ }, e.prototype.connect_ = function() {
243
+ !Te || this.connected_ || (document.addEventListener("transitionend", this.onTransitionEnd_), window.addEventListener("resize", this.refresh), un ? (this.mutationsObserver_ = new MutationObserver(this.refresh), this.mutationsObserver_.observe(document, {
244
+ attributes: true,
245
+ childList: true,
246
+ characterData: true,
247
+ subtree: true
248
+ })) : (document.addEventListener("DOMSubtreeModified", this.refresh), this.mutationEventsAdded_ = true), this.connected_ = true);
249
+ }, e.prototype.disconnect_ = function() {
250
+ !Te || !this.connected_ || (document.removeEventListener("transitionend", this.onTransitionEnd_), window.removeEventListener("resize", this.refresh), this.mutationsObserver_ && this.mutationsObserver_.disconnect(), this.mutationEventsAdded_ && document.removeEventListener("DOMSubtreeModified", this.refresh), this.mutationsObserver_ = null, this.mutationEventsAdded_ = false, this.connected_ = false);
251
+ }, e.prototype.onTransitionEnd_ = function(n) {
252
+ var t = n.propertyName, r = t === void 0 ? "" : t, i = ln.some(function(a) {
253
+ return !!~r.indexOf(a);
254
+ });
255
+ i && this.refresh();
256
+ }, e.getInstance = function() {
257
+ return this.instance_ || (this.instance_ = new e()), this.instance_;
258
+ }, e.instance_ = null, e;
259
+ }()
260
+ ), pt = function(e, n) {
261
+ for (var t = 0, r = Object.keys(n); t < r.length; t++) {
262
+ var i = r[t];
263
+ Object.defineProperty(e, i, {
264
+ value: n[i],
265
+ enumerable: false,
266
+ writable: false,
267
+ configurable: true
268
+ });
269
+ }
270
+ return e;
271
+ }, ae = function(e) {
272
+ var n = e && e.ownerDocument && e.ownerDocument.defaultView;
273
+ return n || ye;
274
+ }, yt = Ce(0, 0, 0, 0);
275
+ function be(e) {
276
+ return parseFloat(e) || 0;
277
+ }
278
+ function tt(e) {
279
+ for (var n = [], t = 1; t < arguments.length; t++)
280
+ n[t - 1] = arguments[t];
281
+ return n.reduce(function(r, i) {
282
+ var a = e["border-" + i + "-width"];
283
+ return r + be(a);
284
+ }, 0);
285
+ }
286
+ function cn(e) {
287
+ for (var n = ["top", "right", "bottom", "left"], t = {}, r = 0, i = n; r < i.length; r++) {
288
+ var a = i[r], o = e["padding-" + a];
289
+ t[a] = be(o);
290
+ }
291
+ return t;
292
+ }
293
+ function fn(e) {
294
+ var n = e.getBBox();
295
+ return Ce(0, 0, n.width, n.height);
296
+ }
297
+ function dn(e) {
298
+ var n = e.clientWidth, t = e.clientHeight;
299
+ if (!n && !t)
300
+ return yt;
301
+ var r = ae(e).getComputedStyle(e), i = cn(r), a = i.left + i.right, o = i.top + i.bottom, l = be(r.width), c = be(r.height);
302
+ if (r.boxSizing === "border-box" && (Math.round(l + a) !== n && (l -= tt(r, "left", "right") + a), Math.round(c + o) !== t && (c -= tt(r, "top", "bottom") + o)), !hn(e)) {
303
+ var f = Math.round(l + a) - n, u = Math.round(c + o) - t;
304
+ Math.abs(f) !== 1 && (l -= f), Math.abs(u) !== 1 && (c -= u);
305
+ }
306
+ return Ce(i.left, i.top, l, c);
307
+ }
308
+ var vn = /* @__PURE__ */ function() {
309
+ return typeof SVGGraphicsElement != "undefined" ? function(e) {
310
+ return e instanceof ae(e).SVGGraphicsElement;
311
+ } : function(e) {
312
+ return e instanceof ae(e).SVGElement && typeof e.getBBox == "function";
313
+ };
314
+ }();
315
+ function hn(e) {
316
+ return e === ae(e).document.documentElement;
317
+ }
318
+ function mn(e) {
319
+ return Te ? vn(e) ? fn(e) : dn(e) : yt;
320
+ }
321
+ function gn(e) {
322
+ var n = e.x, t = e.y, r = e.width, i = e.height, a = typeof DOMRectReadOnly != "undefined" ? DOMRectReadOnly : Object, o = Object.create(a.prototype);
323
+ return pt(o, {
324
+ x: n,
325
+ y: t,
326
+ width: r,
327
+ height: i,
328
+ top: t,
329
+ right: n + r,
330
+ bottom: i + t,
331
+ left: n
332
+ }), o;
333
+ }
334
+ function Ce(e, n, t, r) {
335
+ return { x: e, y: n, width: t, height: r };
336
+ }
337
+ var pn = (
338
+ /** @class */
339
+ function() {
340
+ function e(n) {
341
+ this.broadcastWidth = 0, this.broadcastHeight = 0, this.contentRect_ = Ce(0, 0, 0, 0), this.target = n;
342
+ }
343
+ return e.prototype.isActive = function() {
344
+ var n = mn(this.target);
345
+ return this.contentRect_ = n, n.width !== this.broadcastWidth || n.height !== this.broadcastHeight;
346
+ }, e.prototype.broadcastRect = function() {
347
+ var n = this.contentRect_;
348
+ return this.broadcastWidth = n.width, this.broadcastHeight = n.height, n;
349
+ }, e;
350
+ }()
351
+ ), yn = (
352
+ /** @class */
353
+ /* @__PURE__ */ function() {
354
+ function e(n, t) {
355
+ var r = gn(t);
356
+ pt(this, { target: n, contentRect: r });
357
+ }
358
+ return e;
359
+ }()
360
+ ), bn = (
361
+ /** @class */
362
+ function() {
363
+ function e(n, t, r) {
364
+ if (this.activeObservations_ = [], this.observations_ = new gt(), typeof n != "function")
365
+ throw new TypeError("The callback provided as parameter 1 is not a function.");
366
+ this.callback_ = n, this.controller_ = t, this.callbackCtx_ = r;
367
+ }
368
+ return e.prototype.observe = function(n) {
369
+ if (!arguments.length)
370
+ throw new TypeError("1 argument required, but only 0 present.");
371
+ if (!(typeof Element == "undefined" || !(Element instanceof Object))) {
372
+ if (!(n instanceof ae(n).Element))
373
+ throw new TypeError('parameter 1 is not of type "Element".');
374
+ var t = this.observations_;
375
+ t.has(n) || (t.set(n, new pn(n)), this.controller_.addObserver(this), this.controller_.refresh());
376
+ }
377
+ }, e.prototype.unobserve = function(n) {
378
+ if (!arguments.length)
379
+ throw new TypeError("1 argument required, but only 0 present.");
380
+ if (!(typeof Element == "undefined" || !(Element instanceof Object))) {
381
+ if (!(n instanceof ae(n).Element))
382
+ throw new TypeError('parameter 1 is not of type "Element".');
383
+ var t = this.observations_;
384
+ t.has(n) && (t.delete(n), t.size || this.controller_.removeObserver(this));
385
+ }
386
+ }, e.prototype.disconnect = function() {
387
+ this.clearActive(), this.observations_.clear(), this.controller_.removeObserver(this);
388
+ }, e.prototype.gatherActive = function() {
389
+ var n = this;
390
+ this.clearActive(), this.observations_.forEach(function(t) {
391
+ t.isActive() && n.activeObservations_.push(t);
392
+ });
393
+ }, e.prototype.broadcastActive = function() {
394
+ if (this.hasActive()) {
395
+ var n = this.callbackCtx_, t = this.activeObservations_.map(function(r) {
396
+ return new yn(r.target, r.broadcastRect());
397
+ });
398
+ this.callback_.call(n, t, n), this.clearActive();
399
+ }
400
+ }, e.prototype.clearActive = function() {
401
+ this.activeObservations_.splice(0);
402
+ }, e.prototype.hasActive = function() {
403
+ return this.activeObservations_.length > 0;
404
+ }, e;
405
+ }()
406
+ ), bt = typeof WeakMap != "undefined" ? /* @__PURE__ */ new WeakMap() : new gt(), wt = (
407
+ /** @class */
408
+ /* @__PURE__ */ function() {
409
+ function e(n) {
410
+ if (!(this instanceof e))
411
+ throw new TypeError("Cannot call a class as a function.");
412
+ if (!arguments.length)
413
+ throw new TypeError("1 argument required, but only 0 present.");
414
+ var t = sn.getInstance(), r = new bn(n, t, this);
415
+ bt.set(this, r);
416
+ }
417
+ return e;
418
+ }()
419
+ );
420
+ [
421
+ "observe",
422
+ "unobserve",
423
+ "disconnect"
424
+ ].forEach(function(e) {
425
+ wt.prototype[e] = function() {
426
+ var n;
427
+ return (n = bt.get(this))[e].apply(n, arguments);
428
+ };
429
+ });
430
+ var wn = function() {
431
+ return typeof ye.ResizeObserver != "undefined" ? ye.ResizeObserver : wt;
432
+ }(), On = /* @__PURE__ */ function() {
433
+ var e = function(n, t) {
434
+ return e = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(r, i) {
435
+ r.__proto__ = i;
436
+ } || function(r, i) {
437
+ for (var a in i) Object.prototype.hasOwnProperty.call(i, a) && (r[a] = i[a]);
438
+ }, e(n, t);
439
+ };
440
+ return function(n, t) {
441
+ if (typeof t != "function" && t !== null)
442
+ throw new TypeError("Class extends value " + String(t) + " is not a constructor or null");
443
+ e(n, t);
444
+ function r() {
445
+ this.constructor = n;
446
+ }
447
+ n.prototype = t === null ? Object.create(t) : (r.prototype = t.prototype, new r());
448
+ };
449
+ }(), _n = (
450
+ /** @class */
451
+ function(e) {
452
+ On(n, e);
453
+ function n() {
454
+ var t = e !== null && e.apply(this, arguments) || this;
455
+ return t.getRootElement = function() {
456
+ var r = t.props.getTargetDOMNode;
457
+ return Un((r == null ? void 0 : r()) || t.rootDOMRef, t);
458
+ }, t.getRootDOMNode = function() {
459
+ return t.getRootElement();
460
+ }, t.componentWillUnmount = function() {
461
+ t.resizeObserver && t.destroyResizeObserver();
462
+ }, t.createResizeObserver = function() {
463
+ var r = t.props.throttle, i = r === void 0 ? true : r, a = function(f) {
464
+ var u, v;
465
+ (v = (u = t.props).onResize) === null || v === void 0 || v.call(u, f);
466
+ }, o = i ? tn(a) : a, l = true;
467
+ t.resizeObserver = new wn(function(f) {
468
+ l && (l = false, a(f)), o(f);
469
+ });
470
+ var c = t.getRootElement();
471
+ c && t.resizeObserver.observe(c);
472
+ }, t.destroyResizeObserver = function() {
473
+ t.resizeObserver && t.resizeObserver.disconnect(), t.resizeObserver = null;
474
+ }, t;
475
+ }
476
+ return n.prototype.componentDidMount = function() {
477
+ React__default.isValidElement(this.props.children) ? this.createResizeObserver() : console.warn("The children of ResizeObserver is invalid.");
478
+ }, n.prototype.componentDidUpdate = function() {
479
+ !this.resizeObserver && this.getRootElement() && this.createResizeObserver();
480
+ }, n.prototype.render = function() {
481
+ var t = this, r = this.props.children;
482
+ return vn$1(r) && isValidElement(r) && !this.props.getTargetDOMNode ? cloneElement(r, {
483
+ ref: function(i) {
484
+ t.rootDOMRef = i, Vn$1(r, i);
485
+ }
486
+ }) : (this.rootDOMRef = null, this.props.children);
487
+ }, n;
488
+ }(React__default.Component)
489
+ ), xn = V ? useEffect : useLayoutEffect;
490
+ function rt(e, n) {
491
+ var t = Object.keys(e);
492
+ if (Object.getOwnPropertySymbols) {
493
+ var r = Object.getOwnPropertySymbols(e);
494
+ n && (r = r.filter(function(i) {
495
+ return Object.getOwnPropertyDescriptor(e, i).enumerable;
496
+ })), t.push.apply(t, r);
497
+ }
498
+ return t;
499
+ }
500
+ function nt(e) {
501
+ for (var n = 1; n < arguments.length; n++) {
502
+ var t = arguments[n] != null ? arguments[n] : {};
503
+ n % 2 ? rt(Object(t), true).forEach(function(r) {
504
+ Ee(e, r, t[r]);
505
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : rt(Object(t)).forEach(function(r) {
506
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
507
+ });
508
+ }
509
+ return e;
510
+ }
511
+ function Cn(e, n) {
512
+ var t = useContext(ie$1), r = t.prefixCls, i = r === void 0 ? "arco" : r, a = e.spin, o = e.className, l = nt(nt({
513
+ "aria-hidden": true,
514
+ focusable: false,
515
+ ref: n
516
+ }, e), {}, {
517
+ className: "".concat(o ? o + " " : "").concat(i, "-icon ").concat(i, "-icon-search")
518
+ });
519
+ return a && (l.className = "".concat(l.className, " ").concat(i, "-icon-loading")), delete l.spin, delete l.isIcon, /* @__PURE__ */ React__default.createElement("svg", fe({
520
+ fill: "none",
521
+ stroke: "currentColor",
522
+ strokeWidth: "4",
523
+ viewBox: "0 0 48 48"
524
+ }, l), /* @__PURE__ */ React__default.createElement("path", {
525
+ d: "M33.072 33.071c6.248-6.248 6.248-16.379 0-22.627-6.249-6.249-16.38-6.249-22.628 0-6.248 6.248-6.248 16.379 0 22.627 6.248 6.248 16.38 6.248 22.628 0Zm0 0 8.485 8.485"
526
+ }));
527
+ }
528
+ var we = /* @__PURE__ */ React__default.forwardRef(Cn);
529
+ we.defaultProps = {
530
+ isIcon: true
531
+ };
532
+ we.displayName = "IconSearch";
533
+ var De = function() {
534
+ return De = Object.assign || function(e) {
535
+ for (var n, t = 1, r = arguments.length; t < r; t++) {
536
+ n = arguments[t];
537
+ for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
538
+ }
539
+ return e;
540
+ }, De.apply(this, arguments);
541
+ }, En = function(e, n) {
542
+ var t = {};
543
+ for (var r in e) Object.prototype.hasOwnProperty.call(e, r) && n.indexOf(r) < 0 && (t[r] = e[r]);
544
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
545
+ for (var i = 0, r = Object.getOwnPropertySymbols(e); i < r.length; i++)
546
+ n.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[i]) && (t[r[i]] = e[r[i]]);
547
+ return t;
548
+ }, Sn = function(e, n) {
549
+ var t = typeof Symbol == "function" && e[Symbol.iterator];
550
+ if (!t) return e;
551
+ var r = t.call(e), i, a = [], o;
552
+ try {
553
+ for (; (n === void 0 || n-- > 0) && !(i = r.next()).done; ) a.push(i.value);
554
+ } catch (l) {
555
+ o = { error: l };
556
+ } finally {
557
+ try {
558
+ i && !i.done && (t = r.return) && t.call(r);
559
+ } finally {
560
+ if (o) throw o.error;
561
+ }
562
+ }
563
+ return a;
564
+ }, Ot = React__default.forwardRef(function(e, n) {
565
+ var t, r = useContext(_e).getPrefixCls, i = e.className, a = e.style, o = e.placeholder, l = e.disabled, c = e.searchButton, f = e.loading, u = e.defaultValue, v = e.addAfter, y = e.suffix, s = En(e, ["className", "style", "placeholder", "disabled", "searchButton", "loading", "defaultValue", "addAfter", "suffix"]), _2 = wt$1(e.maxLength) ? e.maxLength.length : e.maxLength, C = wt$1(e.maxLength) && e.maxLength.errorOnly ? void 0 : _2, x2 = Sn(A("", {
566
+ defaultValue: "defaultValue" in e ? oe(e.defaultValue, C) : void 0,
567
+ value: "value" in e ? oe(e.value, C) : void 0
568
+ }), 2), P = x2[0], I = x2[1], R = r("input-search"), N = De$1(R, (t = {}, t[R + "-button"] = c, t), i), b2 = function() {
569
+ !l && e.onSearch && e.onSearch(P);
570
+ };
571
+ return React__default.createElement(J, De({}, Ar$1(s, ["onSearch"]), { disabled: l, className: N, style: a, ref: n, placeholder: o, addAfter: v !== void 0 ? v : c ? React__default.createElement(_e$1, { disabled: l, size: s.size, className: R + "-btn", type: "primary", onClick: b2, loading: f, loadingFixedWidth: true, icon: c === true && !f && React__default.createElement(we, null) }, c !== true && c) : null, suffix: y !== void 0 ? y : !c && (f ? React__default.createElement(Nt$1, null) : React__default.createElement(we, { onClick: b2 })), onChange: function(m, g2) {
572
+ I(m), e.onChange && e.onChange(m, g2);
573
+ }, defaultValue: u, onPressEnter: function(m) {
574
+ b2(), e.onPressEnter && e.onPressEnter(m);
575
+ } }));
576
+ });
577
+ Ot.displayName = "Search";
578
+ var jn = `
579
+ position: absolute;
580
+ min-height: 0 !important;
581
+ max-height: none;
582
+ height:0;
583
+ visibility: hidden;
584
+ z-index: -100;
585
+ top: 0;
586
+ right: 0;
587
+ `, Pn = [
588
+ "border-width",
589
+ "box-sizing",
590
+ "font-family",
591
+ "font-weight",
592
+ "font-size",
593
+ "font-variant",
594
+ "letter-spacing",
595
+ "line-height",
596
+ "padding-top",
597
+ "padding-bottom",
598
+ "padding-left",
599
+ "padding-right",
600
+ "text-indent",
601
+ "text-rendering",
602
+ "text-transform",
603
+ "width"
604
+ ], q;
605
+ function Rn(e) {
606
+ q || (q = document.createElement("textarea"), document.body.appendChild(q));
607
+ var n = window.getComputedStyle(e), t = `
608
+ ` + Pn.map(function(o) {
609
+ return o + ":" + n.getPropertyValue(o);
610
+ }).join(";") + `
611
+ `;
612
+ q.setAttribute("style", "" + jn + t);
613
+ var r = parseFloat(n.getPropertyValue("padding-top")) + parseFloat(n.getPropertyValue("padding-bottom")), i = n.getPropertyValue("box-sizing"), a = parseFloat(n.getPropertyValue("border-top-width")) + parseFloat(n.getPropertyValue("border-bottom-width"));
614
+ return {
615
+ paddingSize: r,
616
+ boxSizing: i,
617
+ borderSize: a
618
+ };
619
+ }
620
+ function Nn(e, n) {
621
+ var t = function() {
622
+ var P, I;
623
+ return wt$1(e) && (P = e.minRows, I = e.maxRows), {
624
+ minRows: P,
625
+ maxRows: I
626
+ };
627
+ };
628
+ if (e) {
629
+ var r = t(), i = r.minRows, a = r.maxRows, o = n, l = Rn(o), c = l.paddingSize, f = l.boxSizing, u = l.borderSize;
630
+ q.value = o.value || o.placeholder || "";
631
+ var v = q.scrollHeight + u, y = void 0, s = void 0, _2 = void 0;
632
+ if (i || a) {
633
+ q.value = "";
634
+ var C = q.scrollHeight - c;
635
+ Se(i) && (y = C * i, f === "border-box" && (y += c, y += u), v = Math.max(v, y)), Se(a) && (s = C * a, f === "border-box" && (s += c, s += u), _2 = v > s ? "auto" : "", s = Math.min(v, s));
636
+ }
637
+ var x2 = {};
638
+ return x2.height = v, y && (x2.minHeight = y), s && (x2.maxHeight = s), _2 && (x2.overflowY = _2), x2;
639
+ }
640
+ }
641
+ var Tn = function(e, n) {
642
+ var t = typeof Symbol == "function" && e[Symbol.iterator];
643
+ if (!t) return e;
644
+ var r = t.call(e), i, a = [], o;
645
+ try {
646
+ for (; (n === void 0 || n-- > 0) && !(i = r.next()).done; ) a.push(i.value);
647
+ } catch (l) {
648
+ o = { error: l };
649
+ } finally {
650
+ try {
651
+ i && !i.done && (t = r.return) && t.call(r);
652
+ } finally {
653
+ if (o) throw o.error;
654
+ }
655
+ }
656
+ return a;
657
+ };
658
+ function _t(e) {
659
+ var n = e.value, t = e.maxLength, r = e.onChange, i = e.onKeyDown, a = e.onPressEnter, o = e.beforeTriggerValueChangeCallback, l = e.normalizeHandler, c = useRef(false), f = Tn(useState(""), 2), u = f[0], v = f[1], y = function(s, _2) {
660
+ o && o(s), r && // https://github.com/arco-design/arco-design/issues/520
661
+ // Avoid triggering onChange repeatedly for the same value
662
+ // Compositionend is earlier than onchange in Firefox, different with chrome
663
+ s !== n && (t === void 0 || s.length <= t) && r(s, _2);
664
+ };
665
+ return {
666
+ compositionValue: u,
667
+ triggerValueChangeCallback: y,
668
+ compositionHandler: function(s) {
669
+ c.current = s.type !== "compositionend", c.current || (v(void 0), y(s.target.value, s));
670
+ },
671
+ valueChangeHandler: function(s) {
672
+ var _2 = s.target.value;
673
+ c.current ? (c.current = false, v(_2)) : (u && v(void 0), y(_2, s));
674
+ },
675
+ keyDownHandler: function(s) {
676
+ var _2 = s.keyCode || s.which;
677
+ if (!c.current && (i && i(s), _2 === E.code)) {
678
+ a && a(s);
679
+ var C = l == null ? void 0 : l("onPressEnter");
680
+ C && y(C(s.target.value), s);
681
+ }
682
+ }
683
+ };
684
+ }
685
+ var se = function() {
686
+ return se = Object.assign || function(e) {
687
+ for (var n, t = 1, r = arguments.length; t < r; t++) {
688
+ n = arguments[t];
689
+ for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
690
+ }
691
+ return e;
692
+ }, se.apply(this, arguments);
693
+ }, Dn = function(e, n) {
694
+ var t = {};
695
+ for (var r in e) Object.prototype.hasOwnProperty.call(e, r) && n.indexOf(r) < 0 && (t[r] = e[r]);
696
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
697
+ for (var i = 0, r = Object.getOwnPropertySymbols(e); i < r.length; i++)
698
+ n.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[i]) && (t[r[i]] = e[r[i]]);
699
+ return t;
700
+ }, Re = function(e, n) {
701
+ var t = typeof Symbol == "function" && e[Symbol.iterator];
702
+ if (!t) return e;
703
+ var r = t.call(e), i, a = [], o;
704
+ try {
705
+ for (; (n === void 0 || n-- > 0) && !(i = r.next()).done; ) a.push(i.value);
706
+ } catch (l) {
707
+ o = { error: l };
708
+ } finally {
709
+ try {
710
+ i && !i.done && (t = r.return) && t.call(r);
711
+ } finally {
712
+ if (o) throw o.error;
713
+ }
714
+ }
715
+ return a;
716
+ }, In = function(e, n) {
717
+ var t, r, i, a = e.className, o = e.style, l = e.wrapperStyle, c = e.placeholder, f = e.disabled, u = e.error, v = e.maxLength, y = e.showWordLimit, s = e.allowClear, _2 = e.onChange, C = e.onClear, x2 = e.onKeyDown, P = e.onPressEnter, I = e.status, R = e.clearIcon, N = Dn(e, ["className", "style", "wrapperStyle", "placeholder", "disabled", "error", "maxLength", "showWordLimit", "allowClear", "onChange", "onClear", "onKeyDown", "onPressEnter", "status", "clearIcon"]), b2 = wt$1(v) ? v.length : v, m = wt$1(v) ? v.errorOnly ? void 0 : v.length : v, g2 = useRef(), M = Re(useState({}), 2), D = M[0], K = M[1], w = Re(A("", {
718
+ defaultValue: "defaultValue" in e ? oe(e.defaultValue, m) : void 0,
719
+ value: "value" in e ? oe(e.value, m) : void 0
720
+ }), 2), z = w[0], Q = w[1], $ = _t({
721
+ value: z,
722
+ maxLength: m,
723
+ onChange: _2,
724
+ onKeyDown: x2,
725
+ onPressEnter: P,
726
+ beforeTriggerValueChangeCallback: function(S2) {
727
+ !("value" in e) && (m === void 0 || S2.length <= m) && Q(S2);
728
+ }
729
+ }), Y = $.compositionValue, j = $.compositionHandler, ee = $.valueChangeHandler, F = $.keyDownHandler, H = $.triggerValueChangeCallback, G = Y || z || "", te = useContext(_e), le = te.getPrefixCls, p = te.rtl, E2 = le("textarea");
730
+ f && (D.resize = "none");
731
+ var U = function() {
732
+ if (g2.current && g2.current.focus) {
733
+ if (g2.current.setSelectionRange) {
734
+ var S2 = g2.current.textContent.length;
735
+ g2.current.setSelectionRange(S2, S2);
736
+ }
737
+ g2.current.focus();
738
+ }
739
+ }, W = function() {
740
+ var S2 = Nn(e.autoSize, g2.current);
741
+ S2 && K(S2);
742
+ }, h = function(S2) {
743
+ S2.stopPropagation(), U(), H("", S2), C == null || C();
744
+ };
745
+ xn(function() {
746
+ W();
747
+ }, [G]), useImperativeHandle(n, function() {
748
+ return {
749
+ dom: g2.current,
750
+ focus: function() {
751
+ U();
752
+ },
753
+ blur: function() {
754
+ g2.current && g2.current.blur && g2.current.blur();
755
+ },
756
+ getRootDOMNode: function() {
757
+ return g2.current;
758
+ }
759
+ };
760
+ }, []);
761
+ var O = z ? z.length : 0, k = b2 && y || s, fe2 = useMemo(function() {
762
+ return !m && b2 ? O > b2 : false;
763
+ }, [O, b2, m]), de = I || (u || fe2 ? "error" : void 0), Ee2 = De$1(E2, (t = {}, t[E2 + "-" + de] = de, // [`${prefixCls}-error`]: error || lengthError || status === 'error',
764
+ t[E2 + "-disabled"] = f, t[E2 + "-rtl"] = p, t), a), re = React__default.createElement("textarea", se({}, Ar$1(N, ["autoSize", "defaultValue"]), { maxLength: m, ref: g2, style: se(se({}, o), D), className: Ee2, placeholder: c, disabled: f, value: G, onChange: ee, onKeyDown: F, onCompositionStart: j, onCompositionUpdate: j, onCompositionEnd: j }));
765
+ if (k) {
766
+ var ve = !f && s && z, ne = Re(p ? [b2, O] : [O, b2], 2), he = ne[0], T = ne[1];
767
+ return React__default.createElement(
768
+ "div",
769
+ { className: De$1(E2 + "-wrapper", (r = {}, r[E2 + "-clear-wrapper"] = s, r[E2 + "-wrapper-rtl"] = p, r)), style: l },
770
+ re,
771
+ ve ? R !== void 0 ? React__default.createElement("span", { className: E2 + "-clear-icon", onClick: h, onMouseDown: function(S2) {
772
+ S2.preventDefault();
773
+ } }, R) : React__default.createElement(
774
+ cr$1,
775
+ { className: E2 + "-clear-icon" },
776
+ React__default.createElement(We$1, {
777
+ onClick: h,
778
+ // keep focus status
779
+ onMouseDown: function(S2) {
780
+ S2.preventDefault();
781
+ }
782
+ })
783
+ ) : null,
784
+ b2 && y && React__default.createElement(
785
+ "span",
786
+ { className: De$1(E2 + "-word-limit", (i = {}, i[E2 + "-word-limit-error"] = fe2, i)) },
787
+ he,
788
+ "/",
789
+ T
790
+ )
791
+ );
792
+ }
793
+ return re;
794
+ }, xt = React__default.forwardRef(In);
795
+ xt.displayName = "TextArea";
796
+ function it(e, n) {
797
+ var t = Object.keys(e);
798
+ if (Object.getOwnPropertySymbols) {
799
+ var r = Object.getOwnPropertySymbols(e);
800
+ n && (r = r.filter(function(i) {
801
+ return Object.getOwnPropertyDescriptor(e, i).enumerable;
802
+ })), t.push.apply(t, r);
803
+ }
804
+ return t;
805
+ }
806
+ function at(e) {
807
+ for (var n = 1; n < arguments.length; n++) {
808
+ var t = arguments[n] != null ? arguments[n] : {};
809
+ n % 2 ? it(Object(t), true).forEach(function(r) {
810
+ Ee(e, r, t[r]);
811
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : it(Object(t)).forEach(function(r) {
812
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
813
+ });
814
+ }
815
+ return e;
816
+ }
817
+ function zn(e, n) {
818
+ var t = useContext(ie$1), r = t.prefixCls, i = r === void 0 ? "arco" : r, a = e.spin, o = e.className, l = at(at({
819
+ "aria-hidden": true,
820
+ focusable: false,
821
+ ref: n
822
+ }, e), {}, {
823
+ className: "".concat(o ? o + " " : "").concat(i, "-icon ").concat(i, "-icon-eye")
824
+ });
825
+ return a && (l.className = "".concat(l.className, " ").concat(i, "-icon-loading")), delete l.spin, delete l.isIcon, /* @__PURE__ */ React__default.createElement("svg", fe({
826
+ fill: "none",
827
+ stroke: "currentColor",
828
+ strokeWidth: "4",
829
+ viewBox: "0 0 48 48"
830
+ }, l), /* @__PURE__ */ React__default.createElement("path", {
831
+ d: "M24 37c6.627 0 12.627-4.333 18-13-5.373-8.667-11.373-13-18-13-6.627 0-12.627 4.333-18 13 5.373 8.667 11.373 13 18 13Z",
832
+ clipRule: "evenodd"
833
+ }), /* @__PURE__ */ React__default.createElement("path", {
834
+ d: "M29 24a5 5 0 1 1-10 0 5 5 0 0 1 10 0Z"
835
+ }));
836
+ }
837
+ var We = /* @__PURE__ */ React__default.forwardRef(zn);
838
+ We.defaultProps = {
839
+ isIcon: true
840
+ };
841
+ We.displayName = "IconEye";
842
+ function ot(e, n) {
843
+ var t = Object.keys(e);
844
+ if (Object.getOwnPropertySymbols) {
845
+ var r = Object.getOwnPropertySymbols(e);
846
+ n && (r = r.filter(function(i) {
847
+ return Object.getOwnPropertyDescriptor(e, i).enumerable;
848
+ })), t.push.apply(t, r);
849
+ }
850
+ return t;
851
+ }
852
+ function lt(e) {
853
+ for (var n = 1; n < arguments.length; n++) {
854
+ var t = arguments[n] != null ? arguments[n] : {};
855
+ n % 2 ? ot(Object(t), true).forEach(function(r) {
856
+ Ee(e, r, t[r]);
857
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ot(Object(t)).forEach(function(r) {
858
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
859
+ });
860
+ }
861
+ return e;
862
+ }
863
+ function Mn(e, n) {
864
+ var t = useContext(ie$1), r = t.prefixCls, i = r === void 0 ? "arco" : r, a = e.spin, o = e.className, l = lt(lt({
865
+ "aria-hidden": true,
866
+ focusable: false,
867
+ ref: n
868
+ }, e), {}, {
869
+ className: "".concat(o ? o + " " : "").concat(i, "-icon ").concat(i, "-icon-eye-invisible")
870
+ });
871
+ return a && (l.className = "".concat(l.className, " ").concat(i, "-icon-loading")), delete l.spin, delete l.isIcon, /* @__PURE__ */ React__default.createElement("svg", fe({
872
+ fill: "none",
873
+ stroke: "currentColor",
874
+ strokeWidth: "4",
875
+ viewBox: "0 0 48 48"
876
+ }, l), /* @__PURE__ */ React__default.createElement("path", {
877
+ d: "M14 14.5c-2.69 2-5.415 5.33-8 9.5 5.373 8.667 11.373 13 18 13 3.325 0 6.491-1.09 9.5-3.271M17.463 12.5C19 11 21.75 11 24 11c6.627 0 12.627 4.333 18 13-1.766 2.848-3.599 5.228-5.5 7.14"
878
+ }), /* @__PURE__ */ React__default.createElement("path", {
879
+ d: "M29 24a5 5 0 1 1-10 0 5 5 0 0 1 10 0ZM6.852 7.103l34.294 34.294"
880
+ }));
881
+ }
882
+ var $e = /* @__PURE__ */ React__default.forwardRef(Mn);
883
+ $e.defaultProps = {
884
+ isIcon: true
885
+ };
886
+ $e.displayName = "IconEyeInvisible";
887
+ function Ct(e) {
888
+ var n = useCallback(function(t) {
889
+ return {
890
+ onKeyDown: function(r) {
891
+ var i, a, o, l, c, f, u = r.keyCode || r.which;
892
+ u === E.code && ((i = t.onPressEnter) === null || i === void 0 || i.call(t, r)), u === b.code && ((a = t.onArrowDown) === null || a === void 0 || a.call(t, r)), u === g.code && ((o = t.onArrowLeft) === null || o === void 0 || o.call(t, r)), u === x.code && ((l = t.onArrowRight) === null || l === void 0 || l.call(t, r)), u === S.code && ((c = t.onArrowUp) === null || c === void 0 || c.call(t, r)), (f = void 0) === null || f === void 0 || f.call(e, r);
893
+ }
894
+ };
895
+ }, []);
896
+ return n;
897
+ }
898
+ var ie = function() {
899
+ return ie = Object.assign || function(e) {
900
+ for (var n, t = 1, r = arguments.length; t < r; t++) {
901
+ n = arguments[t];
902
+ for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
903
+ }
904
+ return e;
905
+ }, ie.apply(this, arguments);
906
+ }, Ln = function(e, n) {
907
+ var t = {};
908
+ for (var r in e) Object.prototype.hasOwnProperty.call(e, r) && n.indexOf(r) < 0 && (t[r] = e[r]);
909
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
910
+ for (var i = 0, r = Object.getOwnPropertySymbols(e); i < r.length; i++)
911
+ n.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[i]) && (t[r[i]] = e[r[i]]);
912
+ return t;
913
+ }, Vn = function(e, n) {
914
+ var t = typeof Symbol == "function" && e[Symbol.iterator];
915
+ if (!t) return e;
916
+ var r = t.call(e), i, a = [], o;
917
+ try {
918
+ for (; (n === void 0 || n-- > 0) && !(i = r.next()).done; ) a.push(i.value);
919
+ } catch (l) {
920
+ o = { error: l };
921
+ } finally {
922
+ try {
923
+ i && !i.done && (t = r.return) && t.call(r);
924
+ } finally {
925
+ if (o) throw o.error;
926
+ }
927
+ }
928
+ return a;
929
+ }, Et = React__default.forwardRef(function(e, n) {
930
+ var t, r = Vn(A(false, {
931
+ defaultValue: e.defaultVisibility,
932
+ value: e.visibility
933
+ }), 2), i = r[0], a = r[1], o = useContext(_e).getPrefixCls, l = Ct(), c = e.className, f = e.visibilityToggle, u = f === void 0 ? true : f, v = e.onVisibilityChange, y = Ln(e, ["className", "visibilityToggle", "onVisibilityChange"]), s = o("input-password"), _2 = De$1(s, (t = {}, t[s + "-visibility"] = u, t), c), C = function(N) {
934
+ "visibility" in e || a(N), v && v(N);
935
+ }, x2 = e.suffix, P = function() {
936
+ C(!i);
937
+ };
938
+ if (u) {
939
+ var I = ie({
940
+ onClick: P,
941
+ // 预防focus丢失
942
+ onMouseDown: function(N) {
943
+ return N.preventDefault();
944
+ },
945
+ onMouseUp: function(N) {
946
+ return N.preventDefault();
947
+ }
948
+ }, l({
949
+ onPressEnter: P
950
+ }));
951
+ if (e.suffix)
952
+ x2 = React__default.createElement("span", ie({}, I), e.suffix);
953
+ else {
954
+ var R = i ? We : $e;
955
+ x2 = React__default.createElement(R, ie({}, I, {
956
+ focusable: void 0,
957
+ "aria-hidden": void 0,
958
+ tabIndex: 0,
959
+ className: s + "-visibility-icon"
960
+ }));
961
+ }
962
+ }
963
+ return React__default.createElement(J, ie({}, Ar$1(y, ["visibility", "defaultVisibility"]), { type: i ? "text" : "password", className: _2, ref: n, suffix: x2 }));
964
+ });
965
+ Et.displayName = "Password";
966
+ function An(e) {
967
+ return typeof e == "string" ? e.replace(/(\s{2,})|(\s{1,}$)/g, function(n) {
968
+ return " ".repeat(n.length);
969
+ }) : e;
970
+ }
971
+ var L = function() {
972
+ return L = Object.assign || function(e) {
973
+ for (var n, t = 1, r = arguments.length; t < r; t++) {
974
+ n = arguments[t];
975
+ for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
976
+ }
977
+ return e;
978
+ }, L.apply(this, arguments);
979
+ }, Wn = function(e, n) {
980
+ var t = {};
981
+ for (var r in e) Object.prototype.hasOwnProperty.call(e, r) && n.indexOf(r) < 0 && (t[r] = e[r]);
982
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
983
+ for (var i = 0, r = Object.getOwnPropertySymbols(e); i < r.length; i++)
984
+ n.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[i]) && (t[r[i]] = e[r[i]]);
985
+ return t;
986
+ }, $n = function(e, n) {
987
+ var t = typeof Symbol == "function" && e[Symbol.iterator];
988
+ if (!t) return e;
989
+ var r = t.call(e), i, a = [], o;
990
+ try {
991
+ for (; (n === void 0 || n-- > 0) && !(i = r.next()).done; ) a.push(i.value);
992
+ } catch (l) {
993
+ o = { error: l };
994
+ } finally {
995
+ try {
996
+ i && !i.done && (t = r.return) && t.call(r);
997
+ } finally {
998
+ if (o) throw o.error;
999
+ }
1000
+ }
1001
+ return a;
1002
+ }, kn = 2, Fn = function(e) {
1003
+ if (!e)
1004
+ return {};
1005
+ var n = window.getComputedStyle(e), t = [
1006
+ "font",
1007
+ "letterSpacing",
1008
+ "overflow",
1009
+ "tabSize",
1010
+ "textIndent",
1011
+ "textTransform",
1012
+ "whiteSpace",
1013
+ "wordBreak",
1014
+ "wordSpacing",
1015
+ "paddingLeft",
1016
+ "paddingRight",
1017
+ "borderLeft",
1018
+ "borderRight",
1019
+ "boxSizing"
1020
+ ];
1021
+ return t.reduce(function(r, i) {
1022
+ return r[i] = n[i], r;
1023
+ }, {});
1024
+ }, St = React__default.forwardRef(function(e, n) {
1025
+ var t, r = e.allowClear, i = e.disabled, a = e.placeholder, o = e.className, l = e.style, c = e.height, f = e.prefixCls, u = e.hasParent, v = e.size, y = e.value, s = e.autoFitWidth, _2 = e.onClear, C = e.readOnly, x2 = e.onChange, P = e.onKeyDown, I = e.onPressEnter, R = e.maxLength, N = e.clearIcon, b2 = Wn(e, ["allowClear", "disabled", "placeholder", "className", "style", "height", "prefixCls", "hasParent", "size", "value", "autoFitWidth", "onClear", "readOnly", "onChange", "onKeyDown", "onPressEnter", "maxLength", "clearIcon"]), m = Ar$1(b2, [
1026
+ "error",
1027
+ "status",
1028
+ "showWordLimit",
1029
+ "className",
1030
+ "defaultValue",
1031
+ "addBefore",
1032
+ "addAfter",
1033
+ "afterStyle",
1034
+ "beforeStyle",
1035
+ "prefix",
1036
+ "suffix",
1037
+ "normalize",
1038
+ "normalizeTrigger",
1039
+ "autoWidth"
1040
+ ]), g2 = $n(useState(), 2), M = g2[0], D = g2[1], K = Ct(), w = useRef(), z = useRef(), Q = useRef(null), $ = wt$1(R) ? R.errorOnly ? void 0 : R.length : R, Y = function(h) {
1041
+ var O, k = e.normalizeTrigger || ["onBlur"];
1042
+ return Array.isArray(k) && k.indexOf(h) > -1 && Sr$1(e.normalize) && (O = e.normalize), O;
1043
+ }, j = _t({
1044
+ value: y,
1045
+ maxLength: $,
1046
+ onChange: x2,
1047
+ onKeyDown: P,
1048
+ onPressEnter: I,
1049
+ normalizeHandler: Y
1050
+ }), ee = j.compositionValue, F = j.valueChangeHandler, H = j.compositionHandler, G = j.keyDownHandler, te = j.triggerValueChangeCallback, le = De$1(f, f && (t = {}, t[f + "-size-" + v] = v, t[f + "-" + e.status] = e.status, t[f + "-disabled"] = i, t[f + "-autowidth"] = s, t), u ? void 0 : o), p = L(L({ "aria-invalid": e.status === "error" || void 0 }, m), { readOnly: C, maxLength: $, disabled: i, placeholder: a, value: ee || y || "", className: le, onKeyDown: G, onChange: F, onCompositionStart: function(h) {
1051
+ var O;
1052
+ (O = b2.onCompositionStart) === null || O === void 0 || O.call(b2, h), H(h);
1053
+ }, onCompositionUpdate: function(h) {
1054
+ var O;
1055
+ (O = b2.onCompositionUpdate) === null || O === void 0 || O.call(b2, h), H(h);
1056
+ }, onCompositionEnd: function(h) {
1057
+ var O;
1058
+ (O = b2.onCompositionEnd) === null || O === void 0 || O.call(b2, h), H(h);
1059
+ }, onBlur: function(h) {
1060
+ var O;
1061
+ (O = e.onBlur) === null || O === void 0 || O.call(e, h);
1062
+ var k = Y("onBlur");
1063
+ k && te(k(h.target.value), h);
1064
+ } });
1065
+ useImperativeHandle(n, function() {
1066
+ return {
1067
+ dom: w.current,
1068
+ getRootDOMNode: function() {
1069
+ return w.current;
1070
+ },
1071
+ focus: function() {
1072
+ w.current && w.current.focus && w.current.focus();
1073
+ },
1074
+ blur: function() {
1075
+ w.current && w.current.blur && w.current.blur();
1076
+ }
1077
+ };
1078
+ }, []);
1079
+ var E2 = function() {
1080
+ if (z.current && w.current) {
1081
+ var h = z.current.offsetWidth;
1082
+ w.current.style.width = h + kn + "px";
1083
+ }
1084
+ };
1085
+ useEffect(function() {
1086
+ s && ((!wt$1(s) || !s.pure) && D(Fn(w == null ? void 0 : w.current)), E2());
1087
+ }, [s]);
1088
+ var U = p.value || a, W = function(h) {
1089
+ w.current && w.current.focus && w.current.focus(), te("", h), _2 == null || _2();
1090
+ };
1091
+ return React__default.createElement(
1092
+ React__default.Fragment,
1093
+ null,
1094
+ r ? React__default.createElement(
1095
+ React__default.Fragment,
1096
+ null,
1097
+ React__default.createElement("input", L({ ref: w }, p)),
1098
+ !C && !i && r && y ? N !== void 0 ? React__default.createElement("span", L({ tabIndex: 0, className: f + "-clear-icon" }, K({ onPressEnter: W }), { onClick: function(h) {
1099
+ h.stopPropagation(), W(h);
1100
+ }, onMouseDown: function(h) {
1101
+ h.preventDefault();
1102
+ } }), N) : React__default.createElement(
1103
+ cr$1,
1104
+ L({ tabIndex: 0, className: f + "-clear-icon" }, K({ onPressEnter: W }), { onClick: function(h) {
1105
+ h.stopPropagation(), W(h);
1106
+ } }),
1107
+ React__default.createElement(
1108
+ We$1,
1109
+ {
1110
+ // keep focus status
1111
+ onMouseDown: function(h) {
1112
+ h.preventDefault();
1113
+ }
1114
+ }
1115
+ )
1116
+ ) : null
1117
+ ) : React__default.createElement("input", L({ ref: w }, p, { style: u ? {} : L(L({ minWidth: wt$1(s) ? s.minWidth : void 0, maxWidth: wt$1(s) ? s.maxWidth : void 0 }, l), "height" in e ? { height: c } : {}) })),
1118
+ s && React__default.createElement(
1119
+ _n,
1120
+ { getTargetDOMNode: function() {
1121
+ return z.current;
1122
+ }, onResize: function() {
1123
+ var h = z.current.offsetWidth;
1124
+ if (typeof s == "object") {
1125
+ var O = typeof s.delay == "function" ? s.delay(h, Q.current) : s.delay;
1126
+ O ? setTimeout(E2, O) : E2();
1127
+ } else
1128
+ E2();
1129
+ Q.current = h;
1130
+ } },
1131
+ React__default.createElement("span", { className: De$1(f + "-mirror"), style: u ? M : L(L(L({}, M), l), "height" in e ? { height: c } : {}), ref: z }, An(U))
1132
+ )
1133
+ );
1134
+ });
1135
+ St.displayName = "InputComponent";
1136
+ var Ie = function() {
1137
+ return Ie = Object.assign || function(e) {
1138
+ for (var n, t = 1, r = arguments.length; t < r; t++) {
1139
+ n = arguments[t];
1140
+ for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
1141
+ }
1142
+ return e;
1143
+ }, Ie.apply(this, arguments);
1144
+ }, Bn = function(e, n) {
1145
+ var t = {};
1146
+ for (var r in e) Object.prototype.hasOwnProperty.call(e, r) && n.indexOf(r) < 0 && (t[r] = e[r]);
1147
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
1148
+ for (var i = 0, r = Object.getOwnPropertySymbols(e); i < r.length; i++)
1149
+ n.indexOf(r[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, r[i]) && (t[r[i]] = e[r[i]]);
1150
+ return t;
1151
+ }, jt = React__default.forwardRef(function(e, n) {
1152
+ var t, r = useContext(_e).getPrefixCls, i = e.className, a = e.style, o = e.children, l = e.compact, c = Bn(e, ["className", "style", "children", "compact"]), f = r("input-group"), u = De$1(f, (t = {}, t[f + "-compact"] = l, t), i);
1153
+ return React__default.createElement("div", Ie({ ref: n, className: u, style: a }, c), o);
1154
+ });
1155
+ jt.displayName = "InputGroup";
1156
+ var B = function() {
1157
+ return B = Object.assign || function(e) {
1158
+ for (var n, t = 1, r = arguments.length; t < r; t++) {
1159
+ n = arguments[t];
1160
+ for (var i in n) Object.prototype.hasOwnProperty.call(n, i) && (e[i] = n[i]);
1161
+ }
1162
+ return e;
1163
+ }, B.apply(this, arguments);
1164
+ }, Ne = function(e, n) {
1165
+ var t = typeof Symbol == "function" && e[Symbol.iterator];
1166
+ if (!t) return e;
1167
+ var r = t.call(e), i, a = [], o;
1168
+ try {
1169
+ for (; (n === void 0 || n-- > 0) && !(i = r.next()).done; ) a.push(i.value);
1170
+ } catch (l) {
1171
+ o = { error: l };
1172
+ } finally {
1173
+ try {
1174
+ i && !i.done && (t = r.return) && t.call(r);
1175
+ } finally {
1176
+ if (o) throw o.error;
1177
+ }
1178
+ }
1179
+ return a;
1180
+ }, Kn = function(e) {
1181
+ e.target.tagName !== "INPUT" && e.preventDefault();
1182
+ }, pe = function(e, n, t, r) {
1183
+ return t === void 0 && (t = {}), n ? React__default.createElement("span", { style: t, className: e, onClick: r }, n) : null;
1184
+ };
1185
+ function oe(e, n) {
1186
+ var t = e !== null && !be$1(e) && !xr$1(e) ? String(e) : e || "";
1187
+ return n ? t.slice(0, n) : t;
1188
+ }
1189
+ function Hn(e, n) {
1190
+ var t, r, i, a = useContext(_e), o = a.getPrefixCls, l = a.size, c = a.componentConfig, f = a.rtl, u = Lr$1(e, {}, c == null ? void 0 : c.Input), v = u.className, y = u.style, s = u.addBefore, _$1 = u.addAfter, C = u.suffix, x2 = u.prefix, P = u.beforeStyle, I = u.afterStyle, R = u.height, N = u.disabled, b2 = u.maxLength, m = u.showWordLimit, g2 = u.allowClear, M = u.autoWidth, D = M ? B({ minWidth: 0, maxWidth: "100%" }, wt$1(M) ? M : {}) : null, K = B({ minWidth: D == null ? void 0 : D.minWidth, maxWidth: D == null ? void 0 : D.maxWidth, width: D && "auto" }, y), w = wt$1(b2) ? b2.length : b2, z = wt$1(b2) && b2.errorOnly ? void 0 : w, Q = Ne(useState(false), 2), $ = Q[0], Y = Q[1], j = useRef(), ee = useRef(), F = useRef(), H = Ne(A("", {
1191
+ defaultValue: "defaultValue" in u ? oe(u.defaultValue, z) : void 0,
1192
+ value: "value" in u ? oe(u.value, z) : void 0
1193
+ }), 2), G = H[0], te = H[1];
1194
+ useImperativeHandle(n, function() {
1195
+ var T, S2, Se2;
1196
+ return {
1197
+ focus: (T = j.current) === null || T === void 0 ? void 0 : T.focus,
1198
+ blur: (S2 = j.current) === null || S2 === void 0 ? void 0 : S2.blur,
1199
+ dom: (Se2 = j.current) === null || Se2 === void 0 ? void 0 : Se2.dom,
1200
+ getRootDOMNode: function() {
1201
+ var je;
1202
+ return ee.current || ((je = j.current) === null || je === void 0 ? void 0 : je.dom);
1203
+ }
1204
+ };
1205
+ }, []);
1206
+ var le = function(T, S2) {
1207
+ "value" in u || te(T), u.onChange && u.onChange(T, S2);
1208
+ }, p = o("input"), E2 = u.size || l, U = "height" in u, W = C, h = G ? G.length : 0, O = useMemo(function() {
1209
+ return !z && w ? h > w : false;
1210
+ }, [h, w, z]);
1211
+ if (w && m) {
1212
+ var k = Ne(f ? [w, h] : [h, w], 2), fe2 = k[0], de = k[1];
1213
+ W = React__default.createElement(
1214
+ "span",
1215
+ { className: De$1(p + "-word-limit", (t = {}, t[p + "-word-limit-error"] = O, t)) },
1216
+ fe2,
1217
+ "/",
1218
+ de
1219
+ );
1220
+ }
1221
+ var Ee2 = De$1(p + "-group-wrapper", p + "-group-wrapper-" + E2, (r = {}, r[p + "-custom-height"] = U, r[p + "-has-suffix"] = W, r[p + "-group-wrapper-disabled"] = N, r[p + "-group-wrapper-rtl"] = f, r[p + "-group-wrapper-autowidth"] = D, r), v), re = u.status || (u.error || O ? "error" : void 0), ve = s || _$1 || W || x2, ne = React__default.createElement(St, B({ ref: j }, u, { autoFitWidth: !!D, style: K, status: re, onFocus: function(T) {
1222
+ Y(true), u.onFocus && u.onFocus(T);
1223
+ }, onBlur: function(T) {
1224
+ Y(false), u.onBlur && u.onBlur(T);
1225
+ }, onChange: le, prefixCls: p, value: G, hasParent: !!ve || g2, size: E2 })), he = De$1(p + "-inner-wrapper", (i = {}, i[p + "-inner-wrapper-" + re] = re, i[p + "-inner-wrapper-disabled"] = N, i[p + "-inner-wrapper-focus"] = $, i[p + "-inner-wrapper-has-prefix"] = x2, i[p + "-inner-wrapper-" + E2] = E2, i[p + "-clear-wrapper"] = g2, i[p + "-inner-wrapper-rtl"] = f, i));
1226
+ return ve ? React__default.createElement(
1227
+ "div",
1228
+ { ref: ee, className: Ee2, style: B(B({}, K), U ? { height: R } : {}) },
1229
+ React__default.createElement(
1230
+ "span",
1231
+ { className: p + "-group" },
1232
+ pe(p + "-group-addbefore", s, P),
1233
+ React__default.createElement(
1234
+ "span",
1235
+ { className: he, ref: F, onMouseDown: function(T) {
1236
+ T.target.tagName !== "INPUT" && F.current && _(F.current, T.target) && T.preventDefault();
1237
+ }, onClick: function(T) {
1238
+ F.current && _(F.current, T.target) && j.current && j.current.focus();
1239
+ } },
1240
+ pe(p + "-group-prefix", x2),
1241
+ ne,
1242
+ pe(p + "-group-suffix", W)
1243
+ ),
1244
+ pe(p + "-group-addafter", _$1, I)
1245
+ )
1246
+ ) : g2 ? React__default.createElement("span", { ref: ee, className: De$1(v, he), style: B(B({}, K), U ? { height: R } : {}), onMouseDown: Kn, onClick: function() {
1247
+ j.current && j.current.focus();
1248
+ } }, ne) : ne;
1249
+ }
1250
+ var J = React__default.forwardRef(Hn);
1251
+ J.displayName = "Input";
1252
+ J.Search = Ot;
1253
+ J.TextArea = xt;
1254
+ J.Password = Et;
1255
+ J.Group = jt;
1256
+ const Jn = (r) => {
1257
+ var i = r, { className: e = "", ref: n } = i, t = Ge(i, ["className", "ref"]);
1258
+ return /* @__PURE__ */ kr$1.jsx(
1259
+ J,
1260
+ He(Ke({
1261
+ className: e
1262
+ }, t), {
1263
+ ref: (a) => {
1264
+ n && a && (n.current = {
1265
+ blur: a.blur,
1266
+ focus: a.focus,
1267
+ dom: a.dom
1268
+ });
1269
+ }
1270
+ })
1271
+ );
1272
+ };
1273
+ export {
1274
+ Jn as A
1275
+ };
1276
+ //# sourceMappingURL=input-Dhdn9e9Z.es.es.js.map