@yuku123/z-cognition-component 2.0.0 → 2.0.2
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.
- package/dist-lib/ApartmentOutlined-M6qSurnE.js +12 -0
- package/dist-lib/ArrowLeftOutlined-DowsrSUj.js +12 -0
- package/dist-lib/{ConceptsPage-DOf_CJlz.js → ConceptsPage-BOeKdDKI.js} +16 -13
- package/dist-lib/{DocsPage-CiC7TU96.js → DocsPage-BZOBFp3c.js} +4 -4
- package/dist-lib/EvidenceFormList-DXqqSpPV.js +91 -0
- package/dist-lib/{EyeOutlined-CH-5UdnC.js → EyeOutlined-DGSrX-0M.js} +1 -1
- package/dist-lib/ImpactPage-DyhUR6fT.js +71 -0
- package/dist-lib/{LeftOutlined-DQTflZ6D.js → LeftOutlined-Cgo6Izj-.js} +1 -1
- package/dist-lib/{OntologyDetailPage-mgK_NQxP.js → OntologyDetailPage-B8DyU8WW.js} +93 -99
- package/dist-lib/{OntologyInferPage-NUaoaQpN.js → OntologyInferPage-CvcjxpBB.js} +40 -38
- package/dist-lib/{OntologyListPage-C9wH01y0.js → OntologyListPage-Cb0XfpWE.js} +49 -47
- package/dist-lib/OntologyMaterializePage-B0f9TnJa.js +136 -0
- package/dist-lib/OntologyNodesPage-D4MWlm6q.js +1268 -0
- package/dist-lib/{OntologyValidatePage-DtkYK_l4.js → OntologyValidatePage-abQVJwzV.js} +52 -49
- package/dist-lib/{Pagination-Ds8VKQIT.js → Pagination-Dxslodkq.js} +258 -260
- package/dist-lib/PlusOutlined-B_dXo_97.js +12 -0
- package/dist-lib/{ReloadOutlined-B26pDoyV.js → ReloadOutlined-CS-e-TmN.js} +10 -19
- package/dist-lib/{ResolvePage-Cz9HORZ3.js → ResolvePage-rbQ-8nNZ.js} +33 -31
- package/dist-lib/{RotateRightOutlined-B575hEBK.js → RotateRightOutlined-q7zp2e47.js} +1 -1
- package/dist-lib/SearchOutlined-puH6bCY6.js +979 -0
- package/dist-lib/Skeleton-DXcERb5r.js +557 -0
- package/dist-lib/{Table-D8pPXolZ.js → Table-CDagah-g.js} +452 -450
- package/dist-lib/TagsOutlined-B4_qkn6-.js +20 -0
- package/dist-lib/TermDetailPage-CP0D6OvA.js +242 -0
- package/dist-lib/{TermsPage-BuzCMYov.js → TermsPage-CuufAyuL.js} +31 -28
- package/dist-lib/TextArea-DTpTS5HL.js +1897 -0
- package/dist-lib/ThunderboltOutlined-Bf54AaFE.js +20 -0
- package/dist-lib/{agents-DS0rPJGV.js → agents-CvgRLQw2.js} +46 -46
- package/dist-lib/{ai-CQ67aRC4.js → ai-DYDhijtn.js} +30 -30
- package/dist-lib/{ai-chat-share-AOB7rEOb.js → ai-chat-share-DJnybJtS.js} +14 -13
- package/dist-lib/{approval-LLVR3fMa.js → approval-3IbhY8Lp.js} +26 -25
- package/dist-lib/{approvals-D1DSA-Mw.js → approvals-Cd6CVzz4.js} +43 -42
- package/dist-lib/{assistant-DpabpWKV.js → assistant-cIXgilaE.js} +50 -49
- package/dist-lib/{assistant-history-ChvhtZwX.js → assistant-history-BQzH4ChB.js} +5 -5
- package/dist-lib/{assistant-summary-B0ksF8CX.js → assistant-summary-LKTj_HKM.js} +1 -1
- package/dist-lib/{audit-DeU1XEgQ.js → audit-CxuJ5unU.js} +1 -1
- package/dist-lib/{bios-Bk36bVhw.js → bios-BplnCOF4.js} +130 -125
- package/dist-lib/callSuper-DZEfdkXG.js +7 -0
- package/dist-lib/{changelog-xEt2qnho.js → changelog-BoGqt_81.js} +2 -2
- package/dist-lib/{changelog-CCMDMI4R.js → changelog-Cn81Dvgk.js} +1 -1
- package/dist-lib/chunk-YDNE64FV-DGyyfCo0.js +2004 -0
- package/dist-lib/colors-sdAcAcU3.js +24 -0
- package/dist-lib/context-Buz0ggsK.js +710 -0
- package/dist-lib/context-DpmyNOn3.js +21 -0
- package/dist-lib/createForOfIteratorHelper-DEx_aTey.js +51 -0
- package/dist-lib/d3-force-CZK-Rgd6.js +598 -0
- package/dist-lib/{dayjs.min-DoEf5yCX.js → dayjs.min-BauDENhn.js} +1 -1
- package/dist-lib/{detail-Xtof0GoK.js → detail-BaX7WiWV.js} +51 -50
- package/dist-lib/{detail-BW6dD_YP.js → detail-Cx5c4KJH.js} +89 -88
- package/dist-lib/{docx-preview-D4v2g8Yg.js → docx-preview-B5nQuTwk.js} +1 -1
- package/dist-lib/{downloads-Dj4DgBSS.js → downloads-C3Oz04OW.js} +4 -3
- package/dist-lib/{edit-nZ7siGuW.js → edit-Cbn2eJaJ.js} +265 -259
- package/dist-lib/{editor-BuhZwEsv.js → editor-mtaJBQXz.js} +21 -20
- package/dist-lib/embed-CR8XVkMy.js +31148 -0
- package/dist-lib/{evaluation-B-igEqQ9.js → evaluation-BoHiY8yT.js} +15 -14
- package/dist-lib/{focus-set-DfRWcq91.js → focus-set-h0YtOUB2.js} +34 -33
- package/dist-lib/{format-CWI99NCN.js → format-UGmYKemG.js} +1 -1
- package/dist-lib/index-9aQ4BzIK.js +500 -0
- package/dist-lib/{index-BJ2Gpcbi.js → index-B22_2Dzh.js} +2 -2
- package/dist-lib/index-B57Fj7Y0.js +1169 -0
- package/dist-lib/{index-D_-8dmug.js → index-BEjXaDfk.js} +23 -22
- package/dist-lib/{index-rtSfQuYs.js → index-BSlCGnzo.js} +12 -12
- package/dist-lib/index-Bc-Vin3j.js +256 -0
- package/dist-lib/{index-SAPKyv8e.js → index-Bm1sK-VN.js} +10 -10
- package/dist-lib/{index-g9uC_rON.js → index-BwVZgt5s.js} +129 -146
- package/dist-lib/{index-CZipVp1G.js → index-C3AMwzIi.js} +1 -1
- package/dist-lib/{index-B5jr3A7f.js → index-CHBNrCMy.js} +19 -19
- package/dist-lib/{index-BFRg0cn3.js → index-CLTfICbf.js} +6 -6
- package/dist-lib/{index-CnLkqTRm.js → index-CaXylbQR.js} +175 -173
- package/dist-lib/index-Cfu1W1H6.js +535 -0
- package/dist-lib/{index-DzrH4RQ7.js → index-Cj4DDWyj.js} +11 -10
- package/dist-lib/index-CrMcNEAZ.js +9656 -0
- package/dist-lib/index-Cy9i4Kx7.js +699 -0
- package/dist-lib/index-CyKWCYMK.js +218 -0
- package/dist-lib/{index-CjwzwBTy.js → index-D3GHtSlM.js} +94 -93
- package/dist-lib/{index-B8l4PAGJ.js → index-DBlG9uXV.js} +112 -108
- package/dist-lib/index-DBtGE89a.js +168 -0
- package/dist-lib/{index-CS5YTpdI.js → index-DMTPsTna.js} +4 -3
- package/dist-lib/index-DjFPRXl5.js +1484 -0
- package/dist-lib/{index-Bu6udiyN.js → index-DsuUGhTA.js} +123 -121
- package/dist-lib/index-DvWHYX81.js +450 -0
- package/dist-lib/{index-D5V4bZ4e.js → index-PBT9GksC.js} +8 -8
- package/dist-lib/index-Vu6sPBci.js +1884 -0
- package/dist-lib/index-bOY1cBol.js +4890 -0
- package/dist-lib/index-nQSVLWfW.js +356 -0
- package/dist-lib/{index-pcUZcUIA.js → index-o65vKUwa.js} +48 -47
- package/dist-lib/{index-K7z38Ybg.js → index-ounfql2z.js} +33 -31
- package/dist-lib/{index-B1rpIXU7.js → index-y7jVGGI0.js} +23 -21
- package/dist-lib/index.js +3 -1
- package/dist-lib/{jszip.min-dcaDnWUw.js → jszip.min-DcEHhn-b.js} +1 -1
- package/dist-lib/{kb-form-modal-9L0AUHVG.js → kb-form-modal-B0rM1ZvV.js} +71 -71
- package/dist-lib/{kbTeam-BECePvJe.js → kbTeam-Bh_FQH28.js} +3 -3
- package/dist-lib/{knowledge-base-C8gHP0dj.js → knowledge-base-Cl1Ka1e6.js} +104 -103
- package/dist-lib/{knowledge-hub-C9KkDv1A.js → knowledge-hub-CPuzdRiq.js} +52 -51
- package/dist-lib/{markdown-lite-BABX4bcl.js → markdown-lite-Cu62Fl7J.js} +181 -177
- package/dist-lib/{material-preview-docx-lp_xPipj.js → material-preview-docx-CH-09KeC.js} +1 -1
- package/dist-lib/{material-preview-pdf-CKAovvpc.js → material-preview-pdf-CTSo215V.js} +7 -7
- package/dist-lib/{material-preview-pptx-6Byitp0J.js → material-preview-pptx-D8XGDF-u.js} +1 -1
- package/dist-lib/{member-B5WF3FCj.js → member-DKDx77PD.js} +1 -1
- package/dist-lib/{message-kHyjuooj.js → message-BrooQ3Q7.js} +25 -24
- package/dist-lib/{message-D2MSaOMq.js → message-Dievi8Jw.js} +1 -1
- package/dist-lib/{messages-D_VDuKK7.js → messages-xTNmTS9g.js} +16 -15
- package/dist-lib/{meta-CEf_DYcU.js → meta-BD_qYTZu.js} +1 -1
- package/dist-lib/{metrics-hONGW0KG.js → metrics-DiHYqBKB.js} +2 -2
- package/dist-lib/{monitor-DF3WVsVV.js → monitor-BBCu3zRe.js} +8 -8
- package/dist-lib/{monitor-DFmEu6rH.js → monitor-BXsdMJSV.js} +4 -4
- package/dist-lib/{my-access-j53lA6T6.js → my-access-CEGErUgv.js} +4 -4
- package/dist-lib/{my-permissions-C5L8ZN2d.js → my-permissions-wSr5zv7g.js} +23 -22
- package/dist-lib/{new-DfZ61nMQ.js → new-BevAuTe5.js} +14 -12
- package/dist-lib/{ontology-CUH5qslO.js → ontology-DXGSJC-y.js} +145 -142
- package/dist-lib/{ontology-domains-CRC1ZRit.js → ontology-domains-jTG7CZm8.js} +88 -84
- package/dist-lib/ontology-modeling-CjRsa-DR.js +1039 -0
- package/dist-lib/{ontology-modeling-DaSk5fsh.js → ontology-modeling-DOj68TuI.js} +2125 -2117
- package/dist-lib/ontology-scenarios-CcAagMiP.js +660 -0
- package/dist-lib/{ontology-scenarios-DAbyoKV6.js → ontology-scenarios-J5kw6xgi.js} +703 -712
- package/dist-lib/pages-CsexFuEz.js +73 -0
- package/dist-lib/pages.js +3 -3
- package/dist-lib/{permission-CklDU2kO.js → permission-BUXo69Ne.js} +31 -31
- package/dist-lib/{pptx-preview.es-D4ODiBv2.js → pptx-preview.es-AUrdYKu3.js} +2 -2
- package/dist-lib/{preset-Bp_mvsJm.js → preset-gh5SGoYT.js} +9810 -10199
- package/dist-lib/{quota-DLe9so2b.js → quota-D31cXjul.js} +4 -4
- package/dist-lib/{row-CE051ClO.js → row-B5MnGm9M.js} +63 -61
- package/dist-lib/{save-blob-qKrc8-z6.js → save-blob-CiWNK-cX.js} +2 -2
- package/dist-lib/{scenario-mapping-preview-CSDqIN3R.js → scenario-mapping-preview-DQ_OBV4Z.js} +48 -46
- package/dist-lib/{scenario-simple-form-CAkhVgeV.js → scenario-simple-form-DESMvU7A.js} +425 -423
- package/dist-lib/{schedule-B_ujtL3h.js → schedule-BktxwX3S.js} +8 -8
- package/dist-lib/{settings-BIkKTQjc.js → settings-dsB3H65I.js} +147 -146
- package/dist-lib/{shared-Dfz1X4Mq.js → shared-CTCzvhyE.js} +1 -1
- package/dist-lib/{shared-utils-BeRiAkbe.js → shared-utils-BstybhBG.js} +2 -2
- package/dist-lib/{skills-BzpcX5fN.js → skills-CHPlMsgO.js} +40 -39
- package/dist-lib/{source-selection-DOL5LBrV.js → source-selection-tXqc855k.js} +16 -16
- package/dist-lib/{task-config-D0a7TOYt.js → task-config-BiTOiZj0.js} +4 -4
- package/dist-lib/{tech-CH01ekZ5.js → tech-BKlGPkV0.js} +4 -3
- package/dist-lib/{tools-YnTN61uE.js → tools-CouQ4FWk.js} +14 -14
- package/dist-lib/{use-domain-access-CXx1YzE5.js → use-domain-access-BPlNfoiP.js} +13 -13
- package/dist-lib/use-g6-graph-WLX0PweO.js +1119 -0
- package/dist-lib/{use-graph-layers-CowyyYcb.js → use-graph-layers-ja-ZIC_R.js} +50 -48
- package/dist-lib/useClosable-BY7FgWKy.js +59 -0
- package/dist-lib/useForm-Byp1LopG.js +145 -0
- package/dist-lib/{version-control-panel-CLy2ZXI_.js → version-control-panel-CkBm36Yk.js} +27 -26
- package/dist-lib/{version-management-C_v8w1E4.js → version-management-B4kIbdVc.js} +7 -6
- package/dist-lib/{welcome-ChEcA4Ej.js → welcome-F5iZoFB1.js} +4 -3
- package/package.json +2 -3
- package/dist-lib/EvidenceFormList-CrE2FzHk.js +0 -90
- package/dist-lib/ImpactPage-CYiuqy0S.js +0 -68
- package/dist-lib/OntologyMaterializePage-D_fDqYHY.js +0 -134
- package/dist-lib/OntologyNodesPage-5kH7RHwE.js +0 -2844
- package/dist-lib/PlusOutlined-BSTPGLOH.js +0 -21
- package/dist-lib/Skeleton-CxFsInYI.js +0 -671
- package/dist-lib/Table-Civ838nE.js +0 -20514
- package/dist-lib/TermDetailPage-BtkOpbPT.js +0 -263
- package/dist-lib/_commonjsHelpers-DaMA6jEr.js +0 -8
- package/dist-lib/callSuper-CwIeyYoc.js +0 -7
- package/dist-lib/chunk-6KYCQHYJ-DcgZQlO5.js +0 -1627
- package/dist-lib/context-T27uno74.js +0 -54
- package/dist-lib/d3-force-Cr_oBTiR.js +0 -647
- package/dist-lib/embed-Bs3Hmsyy.js +0 -51377
- package/dist-lib/index-0TvzCTD7.js +0 -2336
- package/dist-lib/index-4tbtbcAt.js +0 -550
- package/dist-lib/index-B1wh6i1C.js +0 -1308
- package/dist-lib/index-BVgdmf6r.js +0 -2487
- package/dist-lib/index-CSnvcFg-.js +0 -543
- package/dist-lib/index-D35Ry0PG.js +0 -1162
- package/dist-lib/index-DC57_dnh.js +0 -604
- package/dist-lib/index-DQ16Zb7x.js +0 -546
- package/dist-lib/index-DRcTwC17.js +0 -418
- package/dist-lib/index-Dd9pPAT3.js +0 -2192
- package/dist-lib/index-DxzorPvG.js +0 -13960
- package/dist-lib/index-If4xc1-H.js +0 -559
- package/dist-lib/index-R71k3nB_.js +0 -710
- package/dist-lib/index-mUlorJxp.js +0 -3279
- package/dist-lib/ontology-modeling-CvJIImxt.js +0 -3612
- package/dist-lib/ontology-scenarios-BRDkk3uA.js +0 -675
- package/dist-lib/pages-CticGC6S.js +0 -512
- package/dist-lib/use-g6-graph-SwJtPLce.js +0 -57552
|
@@ -1,2336 +0,0 @@
|
|
|
1
|
-
import * as c from "react";
|
|
2
|
-
import R, { useRef as pe, cloneElement as Dt, forwardRef as Ye, useState as Ke, useImperativeHandle as gt, useEffect as Ie, useContext as Ue, useMemo as Wt } from "react";
|
|
3
|
-
import { by as Ht, b1 as Xe, aA as Ee, aj as J, ah as Te, bz as Lt, ai as mt, bA as Vt, am as W, bB as Ze, bC as fe, b3 as ye, bD as se, bE as Me, bF as ve, bG as Je, aL as ke, aD as vt, as as Gt, ak as ze, al as bt, aJ as ht, bH as et, aO as Fe, aN as tt, aY as we, bI as xt, ap as rt, bJ as qe, bK as at, bL as nt, aB as Be, aZ as Qe, an as Kt, bM as it, b2 as Ut, be as st, B as Xt, bN as qt, bO as Qt } from "./embed-Bs3Hmsyy.js";
|
|
4
|
-
import { r as Yt, a as Zt } from "./mediaQueryUtil-8vWuS10Z.js";
|
|
5
|
-
import { R as Jt } from "./EyeOutlined-CH-5UdnC.js";
|
|
6
|
-
const kt = () => R.useReducer((e) => e + 1, 0), Ct = ["xxl", "xl", "lg", "md", "sm", "xs"], er = (e) => ({
|
|
7
|
-
xs: `(max-width: ${e.screenXSMax}px)`,
|
|
8
|
-
sm: `(min-width: ${e.screenSM}px)`,
|
|
9
|
-
md: `(min-width: ${e.screenMD}px)`,
|
|
10
|
-
lg: `(min-width: ${e.screenLG}px)`,
|
|
11
|
-
xl: `(min-width: ${e.screenXL}px)`,
|
|
12
|
-
xxl: `(min-width: ${e.screenXXL}px)`
|
|
13
|
-
}), tr = (e) => {
|
|
14
|
-
const t = e, r = [].concat(Ct).reverse();
|
|
15
|
-
return r.forEach((n, o) => {
|
|
16
|
-
const i = n.toUpperCase(), a = `screen${i}Min`, s = `screen${i}`;
|
|
17
|
-
if (!(t[a] <= t[s]))
|
|
18
|
-
throw new Error(`${a}<=${s} fails : !(${t[a]}<=${t[s]})`);
|
|
19
|
-
if (o < r.length - 1) {
|
|
20
|
-
const u = `screen${i}Max`;
|
|
21
|
-
if (!(t[s] <= t[u]))
|
|
22
|
-
throw new Error(`${s}<=${u} fails : !(${t[s]}<=${t[u]})`);
|
|
23
|
-
const d = `screen${r[o + 1].toUpperCase()}Min`;
|
|
24
|
-
if (!(t[u] <= t[d]))
|
|
25
|
-
throw new Error(`${u}<=${d} fails : !(${t[u]}<=${t[d]})`);
|
|
26
|
-
}
|
|
27
|
-
}), e;
|
|
28
|
-
}, tn = (e, t) => {
|
|
29
|
-
if (t) {
|
|
30
|
-
for (const r of Ct)
|
|
31
|
-
if (e[r] && (t == null ? void 0 : t[r]) !== void 0)
|
|
32
|
-
return t[r];
|
|
33
|
-
}
|
|
34
|
-
}, rr = () => {
|
|
35
|
-
const [, e] = Ht(), t = er(tr(e));
|
|
36
|
-
return R.useMemo(() => {
|
|
37
|
-
const r = /* @__PURE__ */ new Map();
|
|
38
|
-
let n = -1, o = {};
|
|
39
|
-
return {
|
|
40
|
-
responsiveMap: t,
|
|
41
|
-
matchHandlers: {},
|
|
42
|
-
dispatch(i) {
|
|
43
|
-
return o = i, r.forEach((a) => a(o)), r.size >= 1;
|
|
44
|
-
},
|
|
45
|
-
subscribe(i) {
|
|
46
|
-
return r.size || this.register(), n += 1, r.set(n, i), i(o), n;
|
|
47
|
-
},
|
|
48
|
-
unsubscribe(i) {
|
|
49
|
-
r.delete(i), r.size || this.unregister();
|
|
50
|
-
},
|
|
51
|
-
register() {
|
|
52
|
-
Object.entries(t).forEach(([i, a]) => {
|
|
53
|
-
const s = ({
|
|
54
|
-
matches: g
|
|
55
|
-
}) => {
|
|
56
|
-
this.dispatch(Object.assign(Object.assign({}, o), {
|
|
57
|
-
[i]: g
|
|
58
|
-
}));
|
|
59
|
-
}, u = window.matchMedia(a);
|
|
60
|
-
Zt(u, s), this.matchHandlers[a] = {
|
|
61
|
-
mql: u,
|
|
62
|
-
listener: s
|
|
63
|
-
}, s(u);
|
|
64
|
-
});
|
|
65
|
-
},
|
|
66
|
-
unregister() {
|
|
67
|
-
Object.values(t).forEach((i) => {
|
|
68
|
-
const a = this.matchHandlers[i];
|
|
69
|
-
Yt(a == null ? void 0 : a.mql, a == null ? void 0 : a.listener);
|
|
70
|
-
}), r.clear();
|
|
71
|
-
}
|
|
72
|
-
};
|
|
73
|
-
}, [t]);
|
|
74
|
-
};
|
|
75
|
-
function rn(e = !0, t = {}) {
|
|
76
|
-
const r = pe(t), [, n] = kt(), o = rr();
|
|
77
|
-
return Xe(() => {
|
|
78
|
-
const i = o.subscribe((a) => {
|
|
79
|
-
r.current = a, e && n();
|
|
80
|
-
});
|
|
81
|
-
return () => o.unsubscribe(i);
|
|
82
|
-
}, []), r.current;
|
|
83
|
-
}
|
|
84
|
-
function De(e) {
|
|
85
|
-
return Ee(e, {
|
|
86
|
-
inputAffixPadding: e.paddingXXS
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
|
-
const We = (e) => {
|
|
90
|
-
const {
|
|
91
|
-
controlHeight: t,
|
|
92
|
-
fontSize: r,
|
|
93
|
-
lineHeight: n,
|
|
94
|
-
lineWidth: o,
|
|
95
|
-
controlHeightSM: i,
|
|
96
|
-
controlHeightLG: a,
|
|
97
|
-
fontSizeLG: s,
|
|
98
|
-
lineHeightLG: u,
|
|
99
|
-
paddingSM: g,
|
|
100
|
-
controlPaddingHorizontalSM: d,
|
|
101
|
-
controlPaddingHorizontal: x,
|
|
102
|
-
colorFillAlter: C,
|
|
103
|
-
colorPrimaryHover: L,
|
|
104
|
-
colorPrimary: S,
|
|
105
|
-
controlOutlineWidth: N,
|
|
106
|
-
controlOutline: B,
|
|
107
|
-
colorErrorOutline: j,
|
|
108
|
-
colorWarningOutline: O,
|
|
109
|
-
colorBgContainer: A,
|
|
110
|
-
inputFontSize: K,
|
|
111
|
-
inputFontSizeLG: m,
|
|
112
|
-
inputFontSizeSM: y
|
|
113
|
-
} = e, f = K || r, H = y || f, _ = m || s, I = Math.round((t - f * n) / 2 * 10) / 10 - o, z = Math.round((i - H * n) / 2 * 10) / 10 - o, T = Math.ceil((a - _ * u) / 2 * 10) / 10 - o;
|
|
114
|
-
return {
|
|
115
|
-
paddingBlock: Math.max(I, 0),
|
|
116
|
-
paddingBlockSM: Math.max(z, 0),
|
|
117
|
-
paddingBlockLG: Math.max(T, 0),
|
|
118
|
-
paddingInline: g - o,
|
|
119
|
-
paddingInlineSM: d - o,
|
|
120
|
-
paddingInlineLG: x - o,
|
|
121
|
-
addonBg: C,
|
|
122
|
-
activeBorderColor: S,
|
|
123
|
-
hoverBorderColor: L,
|
|
124
|
-
activeShadow: `0 0 0 ${N}px ${B}`,
|
|
125
|
-
errorActiveShadow: `0 0 0 ${N}px ${j}`,
|
|
126
|
-
warningActiveShadow: `0 0 0 ${N}px ${O}`,
|
|
127
|
-
hoverBg: A,
|
|
128
|
-
activeBg: A,
|
|
129
|
-
inputFontSize: f,
|
|
130
|
-
inputFontSizeLG: _,
|
|
131
|
-
inputFontSizeSM: H
|
|
132
|
-
};
|
|
133
|
-
}, nr = (e) => ({
|
|
134
|
-
borderColor: e.hoverBorderColor,
|
|
135
|
-
backgroundColor: e.hoverBg
|
|
136
|
-
}), ot = (e) => ({
|
|
137
|
-
color: e.colorTextDisabled,
|
|
138
|
-
backgroundColor: e.colorBgContainerDisabled,
|
|
139
|
-
borderColor: e.colorBorder,
|
|
140
|
-
boxShadow: "none",
|
|
141
|
-
cursor: "not-allowed",
|
|
142
|
-
opacity: 1,
|
|
143
|
-
"input[disabled], textarea[disabled]": {
|
|
144
|
-
cursor: "not-allowed"
|
|
145
|
-
},
|
|
146
|
-
"&:hover:not([disabled])": Object.assign({}, nr(Ee(e, {
|
|
147
|
-
hoverBorderColor: e.colorBorder,
|
|
148
|
-
hoverBg: e.colorBgContainerDisabled
|
|
149
|
-
})))
|
|
150
|
-
}), St = (e, t) => ({
|
|
151
|
-
background: e.colorBgContainer,
|
|
152
|
-
borderWidth: e.lineWidth,
|
|
153
|
-
borderStyle: e.lineType,
|
|
154
|
-
borderColor: t.borderColor,
|
|
155
|
-
"&:hover": {
|
|
156
|
-
borderColor: t.hoverBorderColor,
|
|
157
|
-
backgroundColor: e.hoverBg
|
|
158
|
-
},
|
|
159
|
-
"&:focus, &:focus-within": {
|
|
160
|
-
borderColor: t.activeBorderColor,
|
|
161
|
-
boxShadow: t.activeShadow,
|
|
162
|
-
outline: 0,
|
|
163
|
-
backgroundColor: e.activeBg
|
|
164
|
-
}
|
|
165
|
-
}), lt = (e, t) => ({
|
|
166
|
-
[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]: Object.assign(Object.assign({}, St(e, t)), {
|
|
167
|
-
[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]: {
|
|
168
|
-
color: t.affixColor
|
|
169
|
-
}
|
|
170
|
-
}),
|
|
171
|
-
[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]: {
|
|
172
|
-
borderColor: t.borderColor
|
|
173
|
-
}
|
|
174
|
-
}), or = (e, t) => ({
|
|
175
|
-
"&-outlined": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, St(e, {
|
|
176
|
-
borderColor: e.colorBorder,
|
|
177
|
-
hoverBorderColor: e.hoverBorderColor,
|
|
178
|
-
activeBorderColor: e.activeBorderColor,
|
|
179
|
-
activeShadow: e.activeShadow
|
|
180
|
-
})), {
|
|
181
|
-
[`&${e.componentCls}-disabled, &[disabled]`]: Object.assign({}, ot(e))
|
|
182
|
-
}), lt(e, {
|
|
183
|
-
status: "error",
|
|
184
|
-
borderColor: e.colorError,
|
|
185
|
-
hoverBorderColor: e.colorErrorBorderHover,
|
|
186
|
-
activeBorderColor: e.colorError,
|
|
187
|
-
activeShadow: e.errorActiveShadow,
|
|
188
|
-
affixColor: e.colorError
|
|
189
|
-
})), lt(e, {
|
|
190
|
-
status: "warning",
|
|
191
|
-
borderColor: e.colorWarning,
|
|
192
|
-
hoverBorderColor: e.colorWarningBorderHover,
|
|
193
|
-
activeBorderColor: e.colorWarning,
|
|
194
|
-
activeShadow: e.warningActiveShadow,
|
|
195
|
-
affixColor: e.colorWarning
|
|
196
|
-
})), t)
|
|
197
|
-
}), ct = (e, t) => ({
|
|
198
|
-
[`&${e.componentCls}-group-wrapper-status-${t.status}`]: {
|
|
199
|
-
[`${e.componentCls}-group-addon`]: {
|
|
200
|
-
borderColor: t.addonBorderColor,
|
|
201
|
-
color: t.addonColor
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
}), ar = (e) => ({
|
|
205
|
-
"&-outlined": Object.assign(Object.assign(Object.assign({
|
|
206
|
-
[`${e.componentCls}-group`]: {
|
|
207
|
-
"&-addon": {
|
|
208
|
-
background: e.addonBg,
|
|
209
|
-
border: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`
|
|
210
|
-
},
|
|
211
|
-
"&-addon:first-child": {
|
|
212
|
-
borderInlineEnd: 0
|
|
213
|
-
},
|
|
214
|
-
"&-addon:last-child": {
|
|
215
|
-
borderInlineStart: 0
|
|
216
|
-
}
|
|
217
|
-
}
|
|
218
|
-
}, ct(e, {
|
|
219
|
-
status: "error",
|
|
220
|
-
addonBorderColor: e.colorError,
|
|
221
|
-
addonColor: e.colorErrorText
|
|
222
|
-
})), ct(e, {
|
|
223
|
-
status: "warning",
|
|
224
|
-
addonBorderColor: e.colorWarning,
|
|
225
|
-
addonColor: e.colorWarningText
|
|
226
|
-
})), {
|
|
227
|
-
[`&${e.componentCls}-group-wrapper-disabled`]: {
|
|
228
|
-
[`${e.componentCls}-group-addon`]: Object.assign({}, ot(e))
|
|
229
|
-
}
|
|
230
|
-
})
|
|
231
|
-
}), ir = (e, t) => {
|
|
232
|
-
const {
|
|
233
|
-
componentCls: r
|
|
234
|
-
} = e;
|
|
235
|
-
return {
|
|
236
|
-
"&-borderless": Object.assign({
|
|
237
|
-
background: "transparent",
|
|
238
|
-
border: "none",
|
|
239
|
-
"&:focus, &:focus-within": {
|
|
240
|
-
outline: "none"
|
|
241
|
-
},
|
|
242
|
-
// >>>>> Disabled
|
|
243
|
-
[`&${r}-disabled, &[disabled]`]: {
|
|
244
|
-
color: e.colorTextDisabled,
|
|
245
|
-
cursor: "not-allowed"
|
|
246
|
-
},
|
|
247
|
-
// >>>>> Status
|
|
248
|
-
[`&${r}-status-error`]: {
|
|
249
|
-
"&, & input, & textarea": {
|
|
250
|
-
color: e.colorError
|
|
251
|
-
}
|
|
252
|
-
},
|
|
253
|
-
[`&${r}-status-warning`]: {
|
|
254
|
-
"&, & input, & textarea": {
|
|
255
|
-
color: e.colorWarning
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
}, t)
|
|
259
|
-
};
|
|
260
|
-
}, $t = (e, t) => {
|
|
261
|
-
var r;
|
|
262
|
-
return {
|
|
263
|
-
background: t.bg,
|
|
264
|
-
borderWidth: e.lineWidth,
|
|
265
|
-
borderStyle: e.lineType,
|
|
266
|
-
borderColor: "transparent",
|
|
267
|
-
"input&, & input, textarea&, & textarea": {
|
|
268
|
-
color: (r = t == null ? void 0 : t.inputColor) !== null && r !== void 0 ? r : "unset"
|
|
269
|
-
},
|
|
270
|
-
"&:hover": {
|
|
271
|
-
background: t.hoverBg
|
|
272
|
-
},
|
|
273
|
-
"&:focus, &:focus-within": {
|
|
274
|
-
outline: 0,
|
|
275
|
-
borderColor: t.activeBorderColor,
|
|
276
|
-
backgroundColor: e.activeBg
|
|
277
|
-
}
|
|
278
|
-
};
|
|
279
|
-
}, dt = (e, t) => ({
|
|
280
|
-
[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]: Object.assign(Object.assign({}, $t(e, t)), {
|
|
281
|
-
[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]: {
|
|
282
|
-
color: t.affixColor
|
|
283
|
-
}
|
|
284
|
-
})
|
|
285
|
-
}), sr = (e, t) => ({
|
|
286
|
-
"&-filled": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, $t(e, {
|
|
287
|
-
bg: e.colorFillTertiary,
|
|
288
|
-
hoverBg: e.colorFillSecondary,
|
|
289
|
-
activeBorderColor: e.activeBorderColor
|
|
290
|
-
})), {
|
|
291
|
-
[`&${e.componentCls}-disabled, &[disabled]`]: Object.assign({}, ot(e))
|
|
292
|
-
}), dt(e, {
|
|
293
|
-
status: "error",
|
|
294
|
-
bg: e.colorErrorBg,
|
|
295
|
-
hoverBg: e.colorErrorBgHover,
|
|
296
|
-
activeBorderColor: e.colorError,
|
|
297
|
-
inputColor: e.colorErrorText,
|
|
298
|
-
affixColor: e.colorError
|
|
299
|
-
})), dt(e, {
|
|
300
|
-
status: "warning",
|
|
301
|
-
bg: e.colorWarningBg,
|
|
302
|
-
hoverBg: e.colorWarningBgHover,
|
|
303
|
-
activeBorderColor: e.colorWarning,
|
|
304
|
-
inputColor: e.colorWarningText,
|
|
305
|
-
affixColor: e.colorWarning
|
|
306
|
-
})), t)
|
|
307
|
-
}), ut = (e, t) => ({
|
|
308
|
-
[`&${e.componentCls}-group-wrapper-status-${t.status}`]: {
|
|
309
|
-
[`${e.componentCls}-group-addon`]: {
|
|
310
|
-
background: t.addonBg,
|
|
311
|
-
color: t.addonColor
|
|
312
|
-
}
|
|
313
|
-
}
|
|
314
|
-
}), lr = (e) => ({
|
|
315
|
-
"&-filled": Object.assign(Object.assign(Object.assign({
|
|
316
|
-
[`${e.componentCls}-group-addon`]: {
|
|
317
|
-
background: e.colorFillTertiary,
|
|
318
|
-
"&:last-child": {
|
|
319
|
-
position: "static"
|
|
320
|
-
}
|
|
321
|
-
}
|
|
322
|
-
}, ut(e, {
|
|
323
|
-
status: "error",
|
|
324
|
-
addonBg: e.colorErrorBg,
|
|
325
|
-
addonColor: e.colorErrorText
|
|
326
|
-
})), ut(e, {
|
|
327
|
-
status: "warning",
|
|
328
|
-
addonBg: e.colorWarningBg,
|
|
329
|
-
addonColor: e.colorWarningText
|
|
330
|
-
})), {
|
|
331
|
-
[`&${e.componentCls}-group-wrapper-disabled`]: {
|
|
332
|
-
[`${e.componentCls}-group`]: {
|
|
333
|
-
"&-addon": {
|
|
334
|
-
background: e.colorFillTertiary,
|
|
335
|
-
color: e.colorTextDisabled
|
|
336
|
-
},
|
|
337
|
-
"&-addon:first-child": {
|
|
338
|
-
borderInlineStart: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,
|
|
339
|
-
borderTop: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,
|
|
340
|
-
borderBottom: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`
|
|
341
|
-
},
|
|
342
|
-
"&-addon:last-child": {
|
|
343
|
-
borderInlineEnd: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,
|
|
344
|
-
borderTop: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`,
|
|
345
|
-
borderBottom: `${J(e.lineWidth)} ${e.lineType} ${e.colorBorder}`
|
|
346
|
-
}
|
|
347
|
-
}
|
|
348
|
-
}
|
|
349
|
-
})
|
|
350
|
-
}), yt = (e, t) => ({
|
|
351
|
-
background: e.colorBgContainer,
|
|
352
|
-
borderWidth: `${J(e.lineWidth)} 0`,
|
|
353
|
-
borderStyle: `${e.lineType} none`,
|
|
354
|
-
borderColor: `transparent transparent ${t.borderColor} transparent`,
|
|
355
|
-
borderRadius: 0,
|
|
356
|
-
"&:hover": {
|
|
357
|
-
borderColor: `transparent transparent ${t.hoverBorderColor} transparent`,
|
|
358
|
-
backgroundColor: e.hoverBg
|
|
359
|
-
},
|
|
360
|
-
"&:focus, &:focus-within": {
|
|
361
|
-
borderColor: `transparent transparent ${t.activeBorderColor} transparent`,
|
|
362
|
-
outline: 0,
|
|
363
|
-
backgroundColor: e.activeBg
|
|
364
|
-
}
|
|
365
|
-
}), ft = (e, t) => ({
|
|
366
|
-
[`&${e.componentCls}-status-${t.status}:not(${e.componentCls}-disabled)`]: Object.assign(Object.assign({}, yt(e, t)), {
|
|
367
|
-
[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]: {
|
|
368
|
-
color: t.affixColor
|
|
369
|
-
}
|
|
370
|
-
}),
|
|
371
|
-
[`&${e.componentCls}-status-${t.status}${e.componentCls}-disabled`]: {
|
|
372
|
-
borderColor: `transparent transparent ${t.borderColor} transparent`
|
|
373
|
-
}
|
|
374
|
-
}), cr = (e, t) => ({
|
|
375
|
-
"&-underlined": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, yt(e, {
|
|
376
|
-
borderColor: e.colorBorder,
|
|
377
|
-
hoverBorderColor: e.hoverBorderColor,
|
|
378
|
-
activeBorderColor: e.activeBorderColor,
|
|
379
|
-
activeShadow: e.activeShadow
|
|
380
|
-
})), {
|
|
381
|
-
// >>>>> Disabled
|
|
382
|
-
[`&${e.componentCls}-disabled, &[disabled]`]: {
|
|
383
|
-
color: e.colorTextDisabled,
|
|
384
|
-
boxShadow: "none",
|
|
385
|
-
cursor: "not-allowed",
|
|
386
|
-
"&:hover": {
|
|
387
|
-
borderColor: `transparent transparent ${e.colorBorder} transparent`
|
|
388
|
-
}
|
|
389
|
-
},
|
|
390
|
-
"input[disabled], textarea[disabled]": {
|
|
391
|
-
cursor: "not-allowed"
|
|
392
|
-
}
|
|
393
|
-
}), ft(e, {
|
|
394
|
-
status: "error",
|
|
395
|
-
borderColor: e.colorError,
|
|
396
|
-
hoverBorderColor: e.colorErrorBorderHover,
|
|
397
|
-
activeBorderColor: e.colorError,
|
|
398
|
-
activeShadow: e.errorActiveShadow,
|
|
399
|
-
affixColor: e.colorError
|
|
400
|
-
})), ft(e, {
|
|
401
|
-
status: "warning",
|
|
402
|
-
borderColor: e.colorWarning,
|
|
403
|
-
hoverBorderColor: e.colorWarningBorderHover,
|
|
404
|
-
activeBorderColor: e.colorWarning,
|
|
405
|
-
activeShadow: e.warningActiveShadow,
|
|
406
|
-
affixColor: e.colorWarning
|
|
407
|
-
})), t)
|
|
408
|
-
}), dr = (e) => ({
|
|
409
|
-
// Firefox
|
|
410
|
-
"&::-moz-placeholder": {
|
|
411
|
-
opacity: 1
|
|
412
|
-
},
|
|
413
|
-
"&::placeholder": {
|
|
414
|
-
color: e,
|
|
415
|
-
userSelect: "none"
|
|
416
|
-
// https://github.com/ant-design/ant-design/pull/32639
|
|
417
|
-
},
|
|
418
|
-
"&:placeholder-shown": {
|
|
419
|
-
textOverflow: "ellipsis"
|
|
420
|
-
}
|
|
421
|
-
}), wt = (e) => {
|
|
422
|
-
const {
|
|
423
|
-
paddingBlockLG: t,
|
|
424
|
-
lineHeightLG: r,
|
|
425
|
-
borderRadiusLG: n,
|
|
426
|
-
paddingInlineLG: o
|
|
427
|
-
} = e;
|
|
428
|
-
return {
|
|
429
|
-
padding: `${J(t)} ${J(o)}`,
|
|
430
|
-
fontSize: e.inputFontSizeLG,
|
|
431
|
-
lineHeight: r,
|
|
432
|
-
borderRadius: n
|
|
433
|
-
};
|
|
434
|
-
}, Et = (e) => ({
|
|
435
|
-
padding: `${J(e.paddingBlockSM)} ${J(e.paddingInlineSM)}`,
|
|
436
|
-
fontSize: e.inputFontSizeSM,
|
|
437
|
-
borderRadius: e.borderRadiusSM
|
|
438
|
-
}), Ot = (e) => Object.assign(Object.assign({
|
|
439
|
-
position: "relative",
|
|
440
|
-
display: "inline-block",
|
|
441
|
-
width: "100%",
|
|
442
|
-
minWidth: 0,
|
|
443
|
-
padding: `${J(e.paddingBlock)} ${J(e.paddingInline)}`,
|
|
444
|
-
color: e.colorText,
|
|
445
|
-
fontSize: e.inputFontSize,
|
|
446
|
-
lineHeight: e.lineHeight,
|
|
447
|
-
borderRadius: e.borderRadius,
|
|
448
|
-
transition: `all ${e.motionDurationMid}`
|
|
449
|
-
}, dr(e.colorTextPlaceholder)), {
|
|
450
|
-
// Size
|
|
451
|
-
"&-lg": Object.assign({}, wt(e)),
|
|
452
|
-
"&-sm": Object.assign({}, Et(e)),
|
|
453
|
-
// RTL
|
|
454
|
-
"&-rtl, &-textarea-rtl": {
|
|
455
|
-
direction: "rtl"
|
|
456
|
-
}
|
|
457
|
-
}), ur = (e) => {
|
|
458
|
-
const {
|
|
459
|
-
componentCls: t,
|
|
460
|
-
antCls: r
|
|
461
|
-
} = e;
|
|
462
|
-
return {
|
|
463
|
-
position: "relative",
|
|
464
|
-
display: "table",
|
|
465
|
-
width: "100%",
|
|
466
|
-
borderCollapse: "separate",
|
|
467
|
-
borderSpacing: 0,
|
|
468
|
-
// Undo padding and float of grid classes
|
|
469
|
-
"&[class*='col-']": {
|
|
470
|
-
paddingInlineEnd: e.paddingXS,
|
|
471
|
-
"&:last-child": {
|
|
472
|
-
paddingInlineEnd: 0
|
|
473
|
-
}
|
|
474
|
-
},
|
|
475
|
-
// Sizing options
|
|
476
|
-
[`&-lg ${t}, &-lg > ${t}-group-addon`]: Object.assign({}, wt(e)),
|
|
477
|
-
[`&-sm ${t}, &-sm > ${t}-group-addon`]: Object.assign({}, Et(e)),
|
|
478
|
-
// Fix https://github.com/ant-design/ant-design/issues/5754
|
|
479
|
-
[`&-lg ${r}-select-single ${r}-select-selector`]: {
|
|
480
|
-
height: e.controlHeightLG
|
|
481
|
-
},
|
|
482
|
-
[`&-sm ${r}-select-single ${r}-select-selector`]: {
|
|
483
|
-
height: e.controlHeightSM
|
|
484
|
-
},
|
|
485
|
-
[`> ${t}`]: {
|
|
486
|
-
display: "table-cell",
|
|
487
|
-
"&:not(:first-child):not(:last-child)": {
|
|
488
|
-
borderRadius: 0
|
|
489
|
-
}
|
|
490
|
-
},
|
|
491
|
-
[`${t}-group`]: {
|
|
492
|
-
"&-addon, &-wrap": {
|
|
493
|
-
display: "table-cell",
|
|
494
|
-
width: 1,
|
|
495
|
-
whiteSpace: "nowrap",
|
|
496
|
-
verticalAlign: "middle",
|
|
497
|
-
"&:not(:first-child):not(:last-child)": {
|
|
498
|
-
borderRadius: 0
|
|
499
|
-
}
|
|
500
|
-
},
|
|
501
|
-
"&-wrap > *": {
|
|
502
|
-
display: "block !important"
|
|
503
|
-
},
|
|
504
|
-
"&-addon": {
|
|
505
|
-
position: "relative",
|
|
506
|
-
padding: `0 ${J(e.paddingInline)}`,
|
|
507
|
-
color: e.colorText,
|
|
508
|
-
fontWeight: "normal",
|
|
509
|
-
fontSize: e.inputFontSize,
|
|
510
|
-
textAlign: "center",
|
|
511
|
-
borderRadius: e.borderRadius,
|
|
512
|
-
transition: `all ${e.motionDurationSlow}`,
|
|
513
|
-
lineHeight: 1,
|
|
514
|
-
// Reset Select's style in addon
|
|
515
|
-
[`${r}-select`]: {
|
|
516
|
-
margin: `${J(e.calc(e.paddingBlock).add(1).mul(-1).equal())} ${J(e.calc(e.paddingInline).mul(-1).equal())}`,
|
|
517
|
-
[`&${r}-select-single:not(${r}-select-customize-input):not(${r}-pagination-size-changer)`]: {
|
|
518
|
-
[`${r}-select-selector`]: {
|
|
519
|
-
backgroundColor: "inherit",
|
|
520
|
-
border: `${J(e.lineWidth)} ${e.lineType} transparent`,
|
|
521
|
-
boxShadow: "none"
|
|
522
|
-
}
|
|
523
|
-
}
|
|
524
|
-
},
|
|
525
|
-
// https://github.com/ant-design/ant-design/issues/31333
|
|
526
|
-
[`${r}-cascader-picker`]: {
|
|
527
|
-
margin: `-9px ${J(e.calc(e.paddingInline).mul(-1).equal())}`,
|
|
528
|
-
backgroundColor: "transparent",
|
|
529
|
-
[`${r}-cascader-input`]: {
|
|
530
|
-
textAlign: "start",
|
|
531
|
-
border: 0,
|
|
532
|
-
boxShadow: "none"
|
|
533
|
-
}
|
|
534
|
-
}
|
|
535
|
-
}
|
|
536
|
-
},
|
|
537
|
-
[t]: {
|
|
538
|
-
width: "100%",
|
|
539
|
-
marginBottom: 0,
|
|
540
|
-
textAlign: "inherit",
|
|
541
|
-
"&:focus": {
|
|
542
|
-
zIndex: 1,
|
|
543
|
-
// Fix https://gw.alipayobjects.com/zos/rmsportal/DHNpoqfMXSfrSnlZvhsJ.png
|
|
544
|
-
borderInlineEndWidth: 1
|
|
545
|
-
},
|
|
546
|
-
"&:hover": {
|
|
547
|
-
zIndex: 1,
|
|
548
|
-
borderInlineEndWidth: 1,
|
|
549
|
-
[`${t}-search-with-button &`]: {
|
|
550
|
-
zIndex: 0
|
|
551
|
-
}
|
|
552
|
-
}
|
|
553
|
-
},
|
|
554
|
-
// Reset rounded corners
|
|
555
|
-
[`> ${t}:first-child, ${t}-group-addon:first-child`]: {
|
|
556
|
-
borderStartEndRadius: 0,
|
|
557
|
-
borderEndEndRadius: 0,
|
|
558
|
-
// Reset Select's style in addon
|
|
559
|
-
[`${r}-select ${r}-select-selector`]: {
|
|
560
|
-
borderStartEndRadius: 0,
|
|
561
|
-
borderEndEndRadius: 0
|
|
562
|
-
}
|
|
563
|
-
},
|
|
564
|
-
[`> ${t}-affix-wrapper`]: {
|
|
565
|
-
[`&:not(:first-child) ${t}`]: {
|
|
566
|
-
borderStartStartRadius: 0,
|
|
567
|
-
borderEndStartRadius: 0
|
|
568
|
-
},
|
|
569
|
-
[`&:not(:last-child) ${t}`]: {
|
|
570
|
-
borderStartEndRadius: 0,
|
|
571
|
-
borderEndEndRadius: 0
|
|
572
|
-
}
|
|
573
|
-
},
|
|
574
|
-
[`> ${t}:last-child, ${t}-group-addon:last-child`]: {
|
|
575
|
-
borderStartStartRadius: 0,
|
|
576
|
-
borderEndStartRadius: 0,
|
|
577
|
-
// Reset Select's style in addon
|
|
578
|
-
[`${r}-select ${r}-select-selector`]: {
|
|
579
|
-
borderStartStartRadius: 0,
|
|
580
|
-
borderEndStartRadius: 0
|
|
581
|
-
}
|
|
582
|
-
},
|
|
583
|
-
[`${t}-affix-wrapper`]: {
|
|
584
|
-
"&:not(:last-child)": {
|
|
585
|
-
borderStartEndRadius: 0,
|
|
586
|
-
borderEndEndRadius: 0,
|
|
587
|
-
[`${t}-search &`]: {
|
|
588
|
-
borderStartStartRadius: e.borderRadius,
|
|
589
|
-
borderEndStartRadius: e.borderRadius
|
|
590
|
-
}
|
|
591
|
-
},
|
|
592
|
-
[`&:not(:first-child), ${t}-search &:not(:first-child)`]: {
|
|
593
|
-
borderStartStartRadius: 0,
|
|
594
|
-
borderEndStartRadius: 0
|
|
595
|
-
}
|
|
596
|
-
},
|
|
597
|
-
[`&${t}-group-compact`]: Object.assign(Object.assign({
|
|
598
|
-
display: "block"
|
|
599
|
-
}, Vt()), {
|
|
600
|
-
[`${t}-group-addon, ${t}-group-wrap, > ${t}`]: {
|
|
601
|
-
"&:not(:first-child):not(:last-child)": {
|
|
602
|
-
borderInlineEndWidth: e.lineWidth,
|
|
603
|
-
"&:hover, &:focus": {
|
|
604
|
-
zIndex: 1
|
|
605
|
-
}
|
|
606
|
-
}
|
|
607
|
-
},
|
|
608
|
-
"& > *": {
|
|
609
|
-
display: "inline-flex",
|
|
610
|
-
float: "none",
|
|
611
|
-
verticalAlign: "top",
|
|
612
|
-
// https://github.com/ant-design/ant-design-pro/issues/139
|
|
613
|
-
borderRadius: 0
|
|
614
|
-
},
|
|
615
|
-
[`
|
|
616
|
-
& > ${t}-affix-wrapper,
|
|
617
|
-
& > ${t}-number-affix-wrapper,
|
|
618
|
-
& > ${r}-picker-range
|
|
619
|
-
`]: {
|
|
620
|
-
display: "inline-flex"
|
|
621
|
-
},
|
|
622
|
-
"& > *:not(:last-child)": {
|
|
623
|
-
marginInlineEnd: e.calc(e.lineWidth).mul(-1).equal(),
|
|
624
|
-
borderInlineEndWidth: e.lineWidth
|
|
625
|
-
},
|
|
626
|
-
// Undo float for .ant-input-group .ant-input
|
|
627
|
-
[t]: {
|
|
628
|
-
float: "none"
|
|
629
|
-
},
|
|
630
|
-
// reset border for Select, DatePicker, AutoComplete, Cascader, Mention, TimePicker, Input
|
|
631
|
-
[`& > ${r}-select > ${r}-select-selector,
|
|
632
|
-
& > ${r}-select-auto-complete ${t},
|
|
633
|
-
& > ${r}-cascader-picker ${t},
|
|
634
|
-
& > ${t}-group-wrapper ${t}`]: {
|
|
635
|
-
borderInlineEndWidth: e.lineWidth,
|
|
636
|
-
borderRadius: 0,
|
|
637
|
-
"&:hover, &:focus": {
|
|
638
|
-
zIndex: 1
|
|
639
|
-
}
|
|
640
|
-
},
|
|
641
|
-
[`& > ${r}-select-focused`]: {
|
|
642
|
-
zIndex: 1
|
|
643
|
-
},
|
|
644
|
-
// update z-index for arrow icon
|
|
645
|
-
[`& > ${r}-select > ${r}-select-arrow`]: {
|
|
646
|
-
zIndex: 1
|
|
647
|
-
// https://github.com/ant-design/ant-design/issues/20371
|
|
648
|
-
},
|
|
649
|
-
[`& > *:first-child,
|
|
650
|
-
& > ${r}-select:first-child > ${r}-select-selector,
|
|
651
|
-
& > ${r}-select-auto-complete:first-child ${t},
|
|
652
|
-
& > ${r}-cascader-picker:first-child ${t}`]: {
|
|
653
|
-
borderStartStartRadius: e.borderRadius,
|
|
654
|
-
borderEndStartRadius: e.borderRadius
|
|
655
|
-
},
|
|
656
|
-
[`& > *:last-child,
|
|
657
|
-
& > ${r}-select:last-child > ${r}-select-selector,
|
|
658
|
-
& > ${r}-cascader-picker:last-child ${t},
|
|
659
|
-
& > ${r}-cascader-picker-focused:last-child ${t}`]: {
|
|
660
|
-
borderInlineEndWidth: e.lineWidth,
|
|
661
|
-
borderStartEndRadius: e.borderRadius,
|
|
662
|
-
borderEndEndRadius: e.borderRadius
|
|
663
|
-
},
|
|
664
|
-
// https://github.com/ant-design/ant-design/issues/12493
|
|
665
|
-
[`& > ${r}-select-auto-complete ${t}`]: {
|
|
666
|
-
verticalAlign: "top"
|
|
667
|
-
},
|
|
668
|
-
[`${t}-group-wrapper + ${t}-group-wrapper`]: {
|
|
669
|
-
marginInlineStart: e.calc(e.lineWidth).mul(-1).equal(),
|
|
670
|
-
[`${t}-affix-wrapper`]: {
|
|
671
|
-
borderRadius: 0
|
|
672
|
-
}
|
|
673
|
-
},
|
|
674
|
-
[`${t}-group-wrapper:not(:last-child)`]: {
|
|
675
|
-
[`&${t}-search > ${t}-group`]: {
|
|
676
|
-
[`& > ${t}-group-addon > ${t}-search-button`]: {
|
|
677
|
-
borderRadius: 0
|
|
678
|
-
},
|
|
679
|
-
[`& > ${t}`]: {
|
|
680
|
-
borderStartStartRadius: e.borderRadius,
|
|
681
|
-
borderStartEndRadius: 0,
|
|
682
|
-
borderEndEndRadius: 0,
|
|
683
|
-
borderEndStartRadius: e.borderRadius
|
|
684
|
-
}
|
|
685
|
-
}
|
|
686
|
-
}
|
|
687
|
-
})
|
|
688
|
-
};
|
|
689
|
-
}, fr = (e) => {
|
|
690
|
-
const {
|
|
691
|
-
componentCls: t,
|
|
692
|
-
controlHeightSM: r,
|
|
693
|
-
lineWidth: n,
|
|
694
|
-
calc: o
|
|
695
|
-
} = e, a = o(r).sub(o(n).mul(2)).sub(16).div(2).equal();
|
|
696
|
-
return {
|
|
697
|
-
[t]: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, mt(e)), Ot(e)), or(e)), sr(e)), ir(e)), cr(e)), {
|
|
698
|
-
'&[type="color"]': {
|
|
699
|
-
height: e.controlHeight,
|
|
700
|
-
[`&${t}-lg`]: {
|
|
701
|
-
height: e.controlHeightLG
|
|
702
|
-
},
|
|
703
|
-
[`&${t}-sm`]: {
|
|
704
|
-
height: r,
|
|
705
|
-
paddingTop: a,
|
|
706
|
-
paddingBottom: a
|
|
707
|
-
}
|
|
708
|
-
},
|
|
709
|
-
'&[type="search"]::-webkit-search-cancel-button, &[type="search"]::-webkit-search-decoration': {
|
|
710
|
-
appearance: "none"
|
|
711
|
-
}
|
|
712
|
-
})
|
|
713
|
-
};
|
|
714
|
-
}, pr = (e) => {
|
|
715
|
-
const {
|
|
716
|
-
componentCls: t
|
|
717
|
-
} = e;
|
|
718
|
-
return {
|
|
719
|
-
// ========================= Input =========================
|
|
720
|
-
[`${t}-clear-icon`]: {
|
|
721
|
-
margin: 0,
|
|
722
|
-
padding: 0,
|
|
723
|
-
lineHeight: 0,
|
|
724
|
-
color: e.colorTextQuaternary,
|
|
725
|
-
fontSize: e.fontSizeIcon,
|
|
726
|
-
verticalAlign: -1,
|
|
727
|
-
// https://github.com/ant-design/ant-design/pull/18151
|
|
728
|
-
// https://codesandbox.io/s/wizardly-sun-u10br
|
|
729
|
-
cursor: "pointer",
|
|
730
|
-
transition: `color ${e.motionDurationSlow}`,
|
|
731
|
-
border: "none",
|
|
732
|
-
outline: "none",
|
|
733
|
-
backgroundColor: "transparent",
|
|
734
|
-
"&:hover": {
|
|
735
|
-
color: e.colorIcon
|
|
736
|
-
},
|
|
737
|
-
"&:active": {
|
|
738
|
-
color: e.colorText
|
|
739
|
-
},
|
|
740
|
-
"&-hidden": {
|
|
741
|
-
visibility: "hidden"
|
|
742
|
-
},
|
|
743
|
-
"&-has-suffix": {
|
|
744
|
-
margin: `0 ${J(e.inputAffixPadding)}`
|
|
745
|
-
}
|
|
746
|
-
}
|
|
747
|
-
};
|
|
748
|
-
}, gr = (e) => {
|
|
749
|
-
const {
|
|
750
|
-
componentCls: t,
|
|
751
|
-
inputAffixPadding: r,
|
|
752
|
-
colorTextDescription: n,
|
|
753
|
-
motionDurationSlow: o,
|
|
754
|
-
colorIcon: i,
|
|
755
|
-
colorIconHover: a,
|
|
756
|
-
iconCls: s
|
|
757
|
-
} = e, u = `${t}-affix-wrapper`, g = `${t}-affix-wrapper-disabled`;
|
|
758
|
-
return {
|
|
759
|
-
[u]: Object.assign(Object.assign(Object.assign(Object.assign({}, Ot(e)), {
|
|
760
|
-
display: "inline-flex",
|
|
761
|
-
[`&:not(${t}-disabled):hover`]: {
|
|
762
|
-
zIndex: 1,
|
|
763
|
-
[`${t}-search-with-button &`]: {
|
|
764
|
-
zIndex: 0
|
|
765
|
-
}
|
|
766
|
-
},
|
|
767
|
-
"&-focused, &:focus": {
|
|
768
|
-
zIndex: 1
|
|
769
|
-
},
|
|
770
|
-
[`> input${t}`]: {
|
|
771
|
-
padding: 0
|
|
772
|
-
},
|
|
773
|
-
[`> input${t}, > textarea${t}`]: {
|
|
774
|
-
fontSize: "inherit",
|
|
775
|
-
border: "none",
|
|
776
|
-
borderRadius: 0,
|
|
777
|
-
outline: "none",
|
|
778
|
-
background: "transparent",
|
|
779
|
-
color: "inherit",
|
|
780
|
-
"&::-ms-reveal": {
|
|
781
|
-
display: "none"
|
|
782
|
-
},
|
|
783
|
-
"&:focus": {
|
|
784
|
-
boxShadow: "none !important"
|
|
785
|
-
}
|
|
786
|
-
},
|
|
787
|
-
"&::before": {
|
|
788
|
-
display: "inline-block",
|
|
789
|
-
width: 0,
|
|
790
|
-
visibility: "hidden",
|
|
791
|
-
content: '"\\a0"'
|
|
792
|
-
},
|
|
793
|
-
[t]: {
|
|
794
|
-
"&-prefix, &-suffix": {
|
|
795
|
-
display: "flex",
|
|
796
|
-
flex: "none",
|
|
797
|
-
alignItems: "center",
|
|
798
|
-
"> *:not(:last-child)": {
|
|
799
|
-
marginInlineEnd: e.paddingXS
|
|
800
|
-
}
|
|
801
|
-
},
|
|
802
|
-
"&-show-count-suffix": {
|
|
803
|
-
color: n,
|
|
804
|
-
direction: "ltr"
|
|
805
|
-
},
|
|
806
|
-
"&-show-count-has-suffix": {
|
|
807
|
-
marginInlineEnd: e.paddingXXS
|
|
808
|
-
},
|
|
809
|
-
"&-prefix": {
|
|
810
|
-
marginInlineEnd: r
|
|
811
|
-
},
|
|
812
|
-
"&-suffix": {
|
|
813
|
-
marginInlineStart: r
|
|
814
|
-
}
|
|
815
|
-
}
|
|
816
|
-
}), pr(e)), {
|
|
817
|
-
// password
|
|
818
|
-
[`${s}${t}-password-icon`]: {
|
|
819
|
-
color: i,
|
|
820
|
-
cursor: "pointer",
|
|
821
|
-
transition: `all ${o}`,
|
|
822
|
-
"&:hover": {
|
|
823
|
-
color: a
|
|
824
|
-
}
|
|
825
|
-
}
|
|
826
|
-
}),
|
|
827
|
-
// 覆盖 affix-wrapper borderRadius!
|
|
828
|
-
[`${t}-underlined`]: {
|
|
829
|
-
borderRadius: 0
|
|
830
|
-
},
|
|
831
|
-
[g]: {
|
|
832
|
-
// password disabled
|
|
833
|
-
[`${s}${t}-password-icon`]: {
|
|
834
|
-
color: i,
|
|
835
|
-
cursor: "not-allowed",
|
|
836
|
-
"&:hover": {
|
|
837
|
-
color: i
|
|
838
|
-
}
|
|
839
|
-
}
|
|
840
|
-
}
|
|
841
|
-
};
|
|
842
|
-
}, mr = (e) => {
|
|
843
|
-
const {
|
|
844
|
-
componentCls: t,
|
|
845
|
-
borderRadiusLG: r,
|
|
846
|
-
borderRadiusSM: n
|
|
847
|
-
} = e;
|
|
848
|
-
return {
|
|
849
|
-
[`${t}-group`]: Object.assign(Object.assign(Object.assign({}, mt(e)), ur(e)), {
|
|
850
|
-
"&-rtl": {
|
|
851
|
-
direction: "rtl"
|
|
852
|
-
},
|
|
853
|
-
"&-wrapper": Object.assign(Object.assign(Object.assign({
|
|
854
|
-
display: "inline-block",
|
|
855
|
-
width: "100%",
|
|
856
|
-
textAlign: "start",
|
|
857
|
-
verticalAlign: "top",
|
|
858
|
-
"&-rtl": {
|
|
859
|
-
direction: "rtl"
|
|
860
|
-
},
|
|
861
|
-
// Size
|
|
862
|
-
"&-lg": {
|
|
863
|
-
[`${t}-group-addon`]: {
|
|
864
|
-
borderRadius: r,
|
|
865
|
-
fontSize: e.inputFontSizeLG
|
|
866
|
-
}
|
|
867
|
-
},
|
|
868
|
-
"&-sm": {
|
|
869
|
-
[`${t}-group-addon`]: {
|
|
870
|
-
borderRadius: n
|
|
871
|
-
}
|
|
872
|
-
}
|
|
873
|
-
}, ar(e)), lr(e)), {
|
|
874
|
-
// '&-disabled': {
|
|
875
|
-
// [`${componentCls}-group-addon`]: {
|
|
876
|
-
// ...genDisabledStyle(token),
|
|
877
|
-
// },
|
|
878
|
-
// },
|
|
879
|
-
// Fix the issue of using icons in Space Compact mode
|
|
880
|
-
// https://github.com/ant-design/ant-design/issues/42122
|
|
881
|
-
[`&:not(${t}-compact-first-item):not(${t}-compact-last-item)${t}-compact-item`]: {
|
|
882
|
-
[`${t}, ${t}-group-addon`]: {
|
|
883
|
-
borderRadius: 0
|
|
884
|
-
}
|
|
885
|
-
},
|
|
886
|
-
[`&:not(${t}-compact-last-item)${t}-compact-first-item`]: {
|
|
887
|
-
[`${t}, ${t}-group-addon`]: {
|
|
888
|
-
borderStartEndRadius: 0,
|
|
889
|
-
borderEndEndRadius: 0
|
|
890
|
-
}
|
|
891
|
-
},
|
|
892
|
-
[`&:not(${t}-compact-first-item)${t}-compact-last-item`]: {
|
|
893
|
-
[`${t}, ${t}-group-addon`]: {
|
|
894
|
-
borderStartStartRadius: 0,
|
|
895
|
-
borderEndStartRadius: 0
|
|
896
|
-
}
|
|
897
|
-
},
|
|
898
|
-
// Fix the issue of input use show-count param in space compact mode
|
|
899
|
-
// https://github.com/ant-design/ant-design/issues/46872
|
|
900
|
-
[`&:not(${t}-compact-last-item)${t}-compact-item`]: {
|
|
901
|
-
[`${t}-affix-wrapper`]: {
|
|
902
|
-
borderStartEndRadius: 0,
|
|
903
|
-
borderEndEndRadius: 0
|
|
904
|
-
}
|
|
905
|
-
},
|
|
906
|
-
// Fix the issue of input use `addonAfter` param in space compact mode
|
|
907
|
-
// https://github.com/ant-design/ant-design/issues/52483
|
|
908
|
-
[`&:not(${t}-compact-first-item)${t}-compact-item`]: {
|
|
909
|
-
[`${t}-affix-wrapper`]: {
|
|
910
|
-
borderStartStartRadius: 0,
|
|
911
|
-
borderEndStartRadius: 0
|
|
912
|
-
}
|
|
913
|
-
}
|
|
914
|
-
})
|
|
915
|
-
})
|
|
916
|
-
};
|
|
917
|
-
}, vr = (e) => {
|
|
918
|
-
const {
|
|
919
|
-
componentCls: t,
|
|
920
|
-
antCls: r
|
|
921
|
-
} = e, n = `${t}-search`;
|
|
922
|
-
return {
|
|
923
|
-
[n]: {
|
|
924
|
-
[t]: {
|
|
925
|
-
"&:not([disabled]):hover, &:not([disabled]):focus": {
|
|
926
|
-
[`+ ${t}-group-addon ${n}-button:not(${r}-btn-color-primary):not(${r}-btn-variant-text)`]: {
|
|
927
|
-
borderInlineStartColor: e.colorPrimaryHover
|
|
928
|
-
}
|
|
929
|
-
}
|
|
930
|
-
},
|
|
931
|
-
[`${t}-affix-wrapper`]: {
|
|
932
|
-
height: e.controlHeight,
|
|
933
|
-
borderRadius: 0
|
|
934
|
-
},
|
|
935
|
-
// fix slight height diff in Firefox:
|
|
936
|
-
// https://ant.design/components/auto-complete-cn/#auto-complete-demo-certain-category
|
|
937
|
-
[`${t}-lg`]: {
|
|
938
|
-
lineHeight: e.calc(e.lineHeightLG).sub(2e-4).equal()
|
|
939
|
-
},
|
|
940
|
-
[`> ${t}-group`]: {
|
|
941
|
-
[`> ${t}-group-addon:last-child`]: {
|
|
942
|
-
insetInlineStart: -1,
|
|
943
|
-
padding: 0,
|
|
944
|
-
border: 0,
|
|
945
|
-
[`${n}-button`]: {
|
|
946
|
-
// Fix https://github.com/ant-design/ant-design/issues/47150
|
|
947
|
-
marginInlineEnd: -1,
|
|
948
|
-
borderStartStartRadius: 0,
|
|
949
|
-
borderEndStartRadius: 0,
|
|
950
|
-
boxShadow: "none"
|
|
951
|
-
},
|
|
952
|
-
[`${n}-button:not(${r}-btn-color-primary)`]: {
|
|
953
|
-
color: e.colorTextDescription,
|
|
954
|
-
"&:not([disabled]):hover": {
|
|
955
|
-
color: e.colorPrimaryHover
|
|
956
|
-
},
|
|
957
|
-
"&:active": {
|
|
958
|
-
color: e.colorPrimaryActive
|
|
959
|
-
},
|
|
960
|
-
[`&${r}-btn-loading::before`]: {
|
|
961
|
-
inset: 0
|
|
962
|
-
}
|
|
963
|
-
}
|
|
964
|
-
}
|
|
965
|
-
},
|
|
966
|
-
[`${n}-button`]: {
|
|
967
|
-
height: e.controlHeight,
|
|
968
|
-
"&:hover, &:focus": {
|
|
969
|
-
zIndex: 1
|
|
970
|
-
}
|
|
971
|
-
},
|
|
972
|
-
"&-large": {
|
|
973
|
-
[`${t}-affix-wrapper, ${n}-button`]: {
|
|
974
|
-
height: e.controlHeightLG
|
|
975
|
-
}
|
|
976
|
-
},
|
|
977
|
-
"&-small": {
|
|
978
|
-
[`${t}-affix-wrapper, ${n}-button`]: {
|
|
979
|
-
height: e.controlHeightSM
|
|
980
|
-
}
|
|
981
|
-
},
|
|
982
|
-
"&-rtl": {
|
|
983
|
-
direction: "rtl"
|
|
984
|
-
},
|
|
985
|
-
// ===================== Compact Item Customized Styles =====================
|
|
986
|
-
[`&${t}-compact-item`]: {
|
|
987
|
-
[`&:not(${t}-compact-last-item)`]: {
|
|
988
|
-
[`${t}-group-addon`]: {
|
|
989
|
-
[`${t}-search-button`]: {
|
|
990
|
-
marginInlineEnd: e.calc(e.lineWidth).mul(-1).equal(),
|
|
991
|
-
borderRadius: 0
|
|
992
|
-
}
|
|
993
|
-
}
|
|
994
|
-
},
|
|
995
|
-
[`&:not(${t}-compact-first-item)`]: {
|
|
996
|
-
[`${t},${t}-affix-wrapper`]: {
|
|
997
|
-
borderRadius: 0
|
|
998
|
-
}
|
|
999
|
-
},
|
|
1000
|
-
[`> ${t}-group-addon ${t}-search-button,
|
|
1001
|
-
> ${t},
|
|
1002
|
-
${t}-affix-wrapper`]: {
|
|
1003
|
-
"&:hover, &:focus, &:active": {
|
|
1004
|
-
zIndex: 2
|
|
1005
|
-
}
|
|
1006
|
-
},
|
|
1007
|
-
[`> ${t}-affix-wrapper-focused`]: {
|
|
1008
|
-
zIndex: 2
|
|
1009
|
-
}
|
|
1010
|
-
}
|
|
1011
|
-
}
|
|
1012
|
-
};
|
|
1013
|
-
}, br = (e) => {
|
|
1014
|
-
const {
|
|
1015
|
-
componentCls: t
|
|
1016
|
-
} = e;
|
|
1017
|
-
return {
|
|
1018
|
-
[`${t}-out-of-range`]: {
|
|
1019
|
-
[`&, & input, & textarea, ${t}-show-count-suffix, ${t}-data-count`]: {
|
|
1020
|
-
color: e.colorError
|
|
1021
|
-
}
|
|
1022
|
-
}
|
|
1023
|
-
};
|
|
1024
|
-
}, Rt = Te(["Input", "Shared"], (e) => {
|
|
1025
|
-
const t = Ee(e, De(e));
|
|
1026
|
-
return [fr(t), gr(t)];
|
|
1027
|
-
}, We, {
|
|
1028
|
-
resetFont: !1
|
|
1029
|
-
}), It = Te(["Input", "Component"], (e) => {
|
|
1030
|
-
const t = Ee(e, De(e));
|
|
1031
|
-
return [
|
|
1032
|
-
mr(t),
|
|
1033
|
-
vr(t),
|
|
1034
|
-
br(t),
|
|
1035
|
-
// =====================================================
|
|
1036
|
-
// == Space Compact ==
|
|
1037
|
-
// =====================================================
|
|
1038
|
-
Lt(t)
|
|
1039
|
-
];
|
|
1040
|
-
}, We, {
|
|
1041
|
-
resetFont: !1
|
|
1042
|
-
});
|
|
1043
|
-
function hr(e) {
|
|
1044
|
-
return !!(e.addonBefore || e.addonAfter);
|
|
1045
|
-
}
|
|
1046
|
-
function xr(e) {
|
|
1047
|
-
return !!(e.prefix || e.suffix || e.allowClear);
|
|
1048
|
-
}
|
|
1049
|
-
function pt(e, t, r) {
|
|
1050
|
-
var n = t.cloneNode(!0), o = Object.create(e, {
|
|
1051
|
-
target: {
|
|
1052
|
-
value: n
|
|
1053
|
-
},
|
|
1054
|
-
currentTarget: {
|
|
1055
|
-
value: n
|
|
1056
|
-
}
|
|
1057
|
-
});
|
|
1058
|
-
return n.value = r, typeof t.selectionStart == "number" && typeof t.selectionEnd == "number" && (n.selectionStart = t.selectionStart, n.selectionEnd = t.selectionEnd), n.setSelectionRange = function() {
|
|
1059
|
-
t.setSelectionRange.apply(t, arguments);
|
|
1060
|
-
}, o;
|
|
1061
|
-
}
|
|
1062
|
-
function _e(e, t, r, n) {
|
|
1063
|
-
if (r) {
|
|
1064
|
-
var o = t;
|
|
1065
|
-
if (t.type === "click") {
|
|
1066
|
-
o = pt(t, e, ""), r(o);
|
|
1067
|
-
return;
|
|
1068
|
-
}
|
|
1069
|
-
if (e.type !== "file" && n !== void 0) {
|
|
1070
|
-
o = pt(t, e, n), r(o);
|
|
1071
|
-
return;
|
|
1072
|
-
}
|
|
1073
|
-
r(o);
|
|
1074
|
-
}
|
|
1075
|
-
}
|
|
1076
|
-
function zt(e, t) {
|
|
1077
|
-
if (e) {
|
|
1078
|
-
e.focus(t);
|
|
1079
|
-
var r = t || {}, n = r.cursor;
|
|
1080
|
-
if (n) {
|
|
1081
|
-
var o = e.value.length;
|
|
1082
|
-
switch (n) {
|
|
1083
|
-
case "start":
|
|
1084
|
-
e.setSelectionRange(0, 0);
|
|
1085
|
-
break;
|
|
1086
|
-
case "end":
|
|
1087
|
-
e.setSelectionRange(o, o);
|
|
1088
|
-
break;
|
|
1089
|
-
default:
|
|
1090
|
-
e.setSelectionRange(0, o);
|
|
1091
|
-
}
|
|
1092
|
-
}
|
|
1093
|
-
}
|
|
1094
|
-
}
|
|
1095
|
-
var Bt = /* @__PURE__ */ R.forwardRef(function(e, t) {
|
|
1096
|
-
var r, n, o, i = e.inputElement, a = e.children, s = e.prefixCls, u = e.prefix, g = e.suffix, d = e.addonBefore, x = e.addonAfter, C = e.className, L = e.style, S = e.disabled, N = e.readOnly, B = e.focused, j = e.triggerFocus, O = e.allowClear, A = e.value, K = e.handleReset, m = e.hidden, y = e.classes, f = e.classNames, H = e.dataAttrs, _ = e.styles, I = e.components, z = e.onClear, T = a ?? i, Q = (I == null ? void 0 : I.affixWrapper) || "span", w = (I == null ? void 0 : I.groupWrapper) || "span", P = (I == null ? void 0 : I.wrapper) || "span", E = (I == null ? void 0 : I.groupAddon) || "span", M = pe(null), h = function(de) {
|
|
1097
|
-
var D;
|
|
1098
|
-
(D = M.current) !== null && D !== void 0 && D.contains(de.target) && (j == null || j());
|
|
1099
|
-
}, ne = xr(e), X = /* @__PURE__ */ Dt(T, {
|
|
1100
|
-
value: A,
|
|
1101
|
-
className: W((r = T.props) === null || r === void 0 ? void 0 : r.className, !ne && (f == null ? void 0 : f.variant)) || null
|
|
1102
|
-
}), k = pe(null);
|
|
1103
|
-
if (R.useImperativeHandle(t, function() {
|
|
1104
|
-
return {
|
|
1105
|
-
nativeElement: k.current || M.current
|
|
1106
|
-
};
|
|
1107
|
-
}), ne) {
|
|
1108
|
-
var Y = null;
|
|
1109
|
-
if (O) {
|
|
1110
|
-
var p = !S && !N && A, l = "".concat(s, "-clear-icon"), v = Ze(O) === "object" && O !== null && O !== void 0 && O.clearIcon ? O.clearIcon : "✖";
|
|
1111
|
-
Y = /* @__PURE__ */ R.createElement("button", {
|
|
1112
|
-
type: "button",
|
|
1113
|
-
tabIndex: -1,
|
|
1114
|
-
onClick: function(de) {
|
|
1115
|
-
K == null || K(de), z == null || z();
|
|
1116
|
-
},
|
|
1117
|
-
onMouseDown: function(de) {
|
|
1118
|
-
return de.preventDefault();
|
|
1119
|
-
},
|
|
1120
|
-
className: W(l, fe(fe({}, "".concat(l, "-hidden"), !p), "".concat(l, "-has-suffix"), !!g))
|
|
1121
|
-
}, v);
|
|
1122
|
-
}
|
|
1123
|
-
var b = "".concat(s, "-affix-wrapper"), ee = W(b, fe(fe(fe(fe(fe({}, "".concat(s, "-disabled"), S), "".concat(b, "-disabled"), S), "".concat(b, "-focused"), B), "".concat(b, "-readonly"), N), "".concat(b, "-input-with-clear-btn"), g && O && A), y == null ? void 0 : y.affixWrapper, f == null ? void 0 : f.affixWrapper, f == null ? void 0 : f.variant), $ = (g || O) && /* @__PURE__ */ R.createElement("span", {
|
|
1124
|
-
className: W("".concat(s, "-suffix"), f == null ? void 0 : f.suffix),
|
|
1125
|
-
style: _ == null ? void 0 : _.suffix
|
|
1126
|
-
}, Y, g);
|
|
1127
|
-
X = /* @__PURE__ */ R.createElement(Q, ye({
|
|
1128
|
-
className: ee,
|
|
1129
|
-
style: _ == null ? void 0 : _.affixWrapper,
|
|
1130
|
-
onClick: h
|
|
1131
|
-
}, H == null ? void 0 : H.affixWrapper, {
|
|
1132
|
-
ref: M
|
|
1133
|
-
}), u && /* @__PURE__ */ R.createElement("span", {
|
|
1134
|
-
className: W("".concat(s, "-prefix"), f == null ? void 0 : f.prefix),
|
|
1135
|
-
style: _ == null ? void 0 : _.prefix
|
|
1136
|
-
}, u), X, $);
|
|
1137
|
-
}
|
|
1138
|
-
if (hr(e)) {
|
|
1139
|
-
var Z = "".concat(s, "-group"), q = "".concat(Z, "-addon"), ce = "".concat(Z, "-wrapper"), ge = W("".concat(s, "-wrapper"), Z, y == null ? void 0 : y.wrapper, f == null ? void 0 : f.wrapper), be = W(ce, fe({}, "".concat(ce, "-disabled"), S), y == null ? void 0 : y.group, f == null ? void 0 : f.groupWrapper);
|
|
1140
|
-
X = /* @__PURE__ */ R.createElement(w, {
|
|
1141
|
-
className: be,
|
|
1142
|
-
ref: k
|
|
1143
|
-
}, /* @__PURE__ */ R.createElement(P, {
|
|
1144
|
-
className: ge
|
|
1145
|
-
}, d && /* @__PURE__ */ R.createElement(E, {
|
|
1146
|
-
className: q
|
|
1147
|
-
}, d), X, x && /* @__PURE__ */ R.createElement(E, {
|
|
1148
|
-
className: q
|
|
1149
|
-
}, x)));
|
|
1150
|
-
}
|
|
1151
|
-
return /* @__PURE__ */ R.cloneElement(X, {
|
|
1152
|
-
className: W((n = X.props) === null || n === void 0 ? void 0 : n.className, C) || null,
|
|
1153
|
-
style: se(se({}, (o = X.props) === null || o === void 0 ? void 0 : o.style), L),
|
|
1154
|
-
hidden: m
|
|
1155
|
-
});
|
|
1156
|
-
}), Cr = ["show"];
|
|
1157
|
-
function jt(e, t) {
|
|
1158
|
-
return c.useMemo(function() {
|
|
1159
|
-
var r = {};
|
|
1160
|
-
t && (r.show = Ze(t) === "object" && t.formatter ? t.formatter : !!t), r = se(se({}, r), e);
|
|
1161
|
-
var n = r, o = n.show, i = Me(n, Cr);
|
|
1162
|
-
return se(se({}, i), {}, {
|
|
1163
|
-
show: !!o,
|
|
1164
|
-
showFormatter: typeof o == "function" ? o : void 0,
|
|
1165
|
-
strategy: i.strategy || function(a) {
|
|
1166
|
-
return a.length;
|
|
1167
|
-
}
|
|
1168
|
-
});
|
|
1169
|
-
}, [e, t]);
|
|
1170
|
-
}
|
|
1171
|
-
var Sr = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKeyDown", "onKeyUp", "prefixCls", "disabled", "htmlSize", "className", "maxLength", "suffix", "showCount", "count", "type", "classes", "classNames", "styles", "onCompositionStart", "onCompositionEnd"], $r = /* @__PURE__ */ Ye(function(e, t) {
|
|
1172
|
-
var r = e.autoComplete, n = e.onChange, o = e.onFocus, i = e.onBlur, a = e.onPressEnter, s = e.onKeyDown, u = e.onKeyUp, g = e.prefixCls, d = g === void 0 ? "rc-input" : g, x = e.disabled, C = e.htmlSize, L = e.className, S = e.maxLength, N = e.suffix, B = e.showCount, j = e.count, O = e.type, A = O === void 0 ? "text" : O, K = e.classes, m = e.classNames, y = e.styles, f = e.onCompositionStart, H = e.onCompositionEnd, _ = Me(e, Sr), I = Ke(!1), z = ve(I, 2), T = z[0], Q = z[1], w = pe(!1), P = pe(!1), E = pe(null), M = pe(null), h = function(F) {
|
|
1173
|
-
E.current && zt(E.current, F);
|
|
1174
|
-
}, ne = Je(e.defaultValue, {
|
|
1175
|
-
value: e.value
|
|
1176
|
-
}), X = ve(ne, 2), k = X[0], Y = X[1], p = k == null ? "" : String(k), l = Ke(null), v = ve(l, 2), b = v[0], ee = v[1], $ = jt(j, B), Z = $.max || S, q = $.strategy(p), ce = !!Z && q > Z;
|
|
1177
|
-
gt(t, function() {
|
|
1178
|
-
var U;
|
|
1179
|
-
return {
|
|
1180
|
-
focus: h,
|
|
1181
|
-
blur: function() {
|
|
1182
|
-
var te;
|
|
1183
|
-
(te = E.current) === null || te === void 0 || te.blur();
|
|
1184
|
-
},
|
|
1185
|
-
setSelectionRange: function(te, Se, xe) {
|
|
1186
|
-
var he;
|
|
1187
|
-
(he = E.current) === null || he === void 0 || he.setSelectionRange(te, Se, xe);
|
|
1188
|
-
},
|
|
1189
|
-
select: function() {
|
|
1190
|
-
var te;
|
|
1191
|
-
(te = E.current) === null || te === void 0 || te.select();
|
|
1192
|
-
},
|
|
1193
|
-
input: E.current,
|
|
1194
|
-
nativeElement: ((U = M.current) === null || U === void 0 ? void 0 : U.nativeElement) || E.current
|
|
1195
|
-
};
|
|
1196
|
-
}), Ie(function() {
|
|
1197
|
-
P.current && (P.current = !1), Q(function(U) {
|
|
1198
|
-
return U && x ? !1 : U;
|
|
1199
|
-
});
|
|
1200
|
-
}, [x]);
|
|
1201
|
-
var ge = function(F, te, Se) {
|
|
1202
|
-
var xe = te;
|
|
1203
|
-
if (!w.current && $.exceedFormatter && $.max && $.strategy(te) > $.max) {
|
|
1204
|
-
if (xe = $.exceedFormatter(te, {
|
|
1205
|
-
max: $.max
|
|
1206
|
-
}), te !== xe) {
|
|
1207
|
-
var he, $e;
|
|
1208
|
-
ee([((he = E.current) === null || he === void 0 ? void 0 : he.selectionStart) || 0, (($e = E.current) === null || $e === void 0 ? void 0 : $e.selectionEnd) || 0]);
|
|
1209
|
-
}
|
|
1210
|
-
} else if (Se.source === "compositionEnd")
|
|
1211
|
-
return;
|
|
1212
|
-
Y(xe), E.current && _e(E.current, F, n, xe);
|
|
1213
|
-
};
|
|
1214
|
-
Ie(function() {
|
|
1215
|
-
if (b) {
|
|
1216
|
-
var U;
|
|
1217
|
-
(U = E.current) === null || U === void 0 || U.setSelectionRange.apply(U, ke(b));
|
|
1218
|
-
}
|
|
1219
|
-
}, [b]);
|
|
1220
|
-
var be = function(F) {
|
|
1221
|
-
ge(F, F.target.value, {
|
|
1222
|
-
source: "change"
|
|
1223
|
-
});
|
|
1224
|
-
}, me = function(F) {
|
|
1225
|
-
w.current = !1, ge(F, F.currentTarget.value, {
|
|
1226
|
-
source: "compositionEnd"
|
|
1227
|
-
}), H == null || H(F);
|
|
1228
|
-
}, de = function(F) {
|
|
1229
|
-
a && F.key === "Enter" && !P.current && (P.current = !0, a(F)), s == null || s(F);
|
|
1230
|
-
}, D = function(F) {
|
|
1231
|
-
F.key === "Enter" && (P.current = !1), u == null || u(F);
|
|
1232
|
-
}, G = function(F) {
|
|
1233
|
-
Q(!0), o == null || o(F);
|
|
1234
|
-
}, le = function(F) {
|
|
1235
|
-
P.current && (P.current = !1), Q(!1), i == null || i(F);
|
|
1236
|
-
}, ae = function(F) {
|
|
1237
|
-
Y(""), h(), E.current && _e(E.current, F, n);
|
|
1238
|
-
}, oe = ce && "".concat(d, "-out-of-range"), ie = function() {
|
|
1239
|
-
var F = vt(e, [
|
|
1240
|
-
"prefixCls",
|
|
1241
|
-
"onPressEnter",
|
|
1242
|
-
"addonBefore",
|
|
1243
|
-
"addonAfter",
|
|
1244
|
-
"prefix",
|
|
1245
|
-
"suffix",
|
|
1246
|
-
"allowClear",
|
|
1247
|
-
// Input elements must be either controlled or uncontrolled,
|
|
1248
|
-
// specify either the value prop, or the defaultValue prop, but not both.
|
|
1249
|
-
"defaultValue",
|
|
1250
|
-
"showCount",
|
|
1251
|
-
"count",
|
|
1252
|
-
"classes",
|
|
1253
|
-
"htmlSize",
|
|
1254
|
-
"styles",
|
|
1255
|
-
"classNames",
|
|
1256
|
-
"onClear"
|
|
1257
|
-
]);
|
|
1258
|
-
return /* @__PURE__ */ R.createElement("input", ye({
|
|
1259
|
-
autoComplete: r
|
|
1260
|
-
}, F, {
|
|
1261
|
-
onChange: be,
|
|
1262
|
-
onFocus: G,
|
|
1263
|
-
onBlur: le,
|
|
1264
|
-
onKeyDown: de,
|
|
1265
|
-
onKeyUp: D,
|
|
1266
|
-
className: W(d, fe({}, "".concat(d, "-disabled"), x), m == null ? void 0 : m.input),
|
|
1267
|
-
style: y == null ? void 0 : y.input,
|
|
1268
|
-
ref: E,
|
|
1269
|
-
size: C,
|
|
1270
|
-
type: A,
|
|
1271
|
-
onCompositionStart: function(Se) {
|
|
1272
|
-
w.current = !0, f == null || f(Se);
|
|
1273
|
-
},
|
|
1274
|
-
onCompositionEnd: me
|
|
1275
|
-
}));
|
|
1276
|
-
}, Oe = function() {
|
|
1277
|
-
var F = Number(Z) > 0;
|
|
1278
|
-
if (N || $.show) {
|
|
1279
|
-
var te = $.showFormatter ? $.showFormatter({
|
|
1280
|
-
value: p,
|
|
1281
|
-
count: q,
|
|
1282
|
-
maxLength: Z
|
|
1283
|
-
}) : "".concat(q).concat(F ? " / ".concat(Z) : "");
|
|
1284
|
-
return /* @__PURE__ */ R.createElement(R.Fragment, null, $.show && /* @__PURE__ */ R.createElement("span", {
|
|
1285
|
-
className: W("".concat(d, "-show-count-suffix"), fe({}, "".concat(d, "-show-count-has-suffix"), !!N), m == null ? void 0 : m.count),
|
|
1286
|
-
style: se({}, y == null ? void 0 : y.count)
|
|
1287
|
-
}, te), N);
|
|
1288
|
-
}
|
|
1289
|
-
return null;
|
|
1290
|
-
};
|
|
1291
|
-
return /* @__PURE__ */ R.createElement(Bt, ye({}, _, {
|
|
1292
|
-
prefixCls: d,
|
|
1293
|
-
className: W(L, oe),
|
|
1294
|
-
handleReset: ae,
|
|
1295
|
-
value: p,
|
|
1296
|
-
focused: T,
|
|
1297
|
-
triggerFocus: h,
|
|
1298
|
-
suffix: Oe(),
|
|
1299
|
-
disabled: x,
|
|
1300
|
-
classes: K,
|
|
1301
|
-
classNames: m,
|
|
1302
|
-
styles: y,
|
|
1303
|
-
ref: M
|
|
1304
|
-
}), ie());
|
|
1305
|
-
});
|
|
1306
|
-
const Nt = (e) => {
|
|
1307
|
-
let t;
|
|
1308
|
-
return typeof e == "object" && (e != null && e.clearIcon) ? t = e : e && (t = {
|
|
1309
|
-
clearIcon: /* @__PURE__ */ R.createElement(Gt, null)
|
|
1310
|
-
}), t;
|
|
1311
|
-
};
|
|
1312
|
-
function At(e, t) {
|
|
1313
|
-
const r = pe([]), n = () => {
|
|
1314
|
-
r.current.push(setTimeout(() => {
|
|
1315
|
-
var o, i, a, s;
|
|
1316
|
-
!((o = e.current) === null || o === void 0) && o.input && ((i = e.current) === null || i === void 0 ? void 0 : i.input.getAttribute("type")) === "password" && (!((a = e.current) === null || a === void 0) && a.input.hasAttribute("value")) && ((s = e.current) === null || s === void 0 || s.input.removeAttribute("value"));
|
|
1317
|
-
}));
|
|
1318
|
-
};
|
|
1319
|
-
return Ie(() => (t && n(), () => r.current.forEach((o) => {
|
|
1320
|
-
o && clearTimeout(o);
|
|
1321
|
-
})), []), n;
|
|
1322
|
-
}
|
|
1323
|
-
function yr(e) {
|
|
1324
|
-
return !!(e.prefix || e.suffix || e.allowClear || e.showCount);
|
|
1325
|
-
}
|
|
1326
|
-
var wr = function(e, t) {
|
|
1327
|
-
var r = {};
|
|
1328
|
-
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
1329
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var o = 0, n = Object.getOwnPropertySymbols(e); o < n.length; o++)
|
|
1330
|
-
t.indexOf(n[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[o]) && (r[n[o]] = e[n[o]]);
|
|
1331
|
-
return r;
|
|
1332
|
-
};
|
|
1333
|
-
const je = /* @__PURE__ */ Ye((e, t) => {
|
|
1334
|
-
const {
|
|
1335
|
-
prefixCls: r,
|
|
1336
|
-
bordered: n = !0,
|
|
1337
|
-
status: o,
|
|
1338
|
-
size: i,
|
|
1339
|
-
disabled: a,
|
|
1340
|
-
onBlur: s,
|
|
1341
|
-
onFocus: u,
|
|
1342
|
-
suffix: g,
|
|
1343
|
-
allowClear: d,
|
|
1344
|
-
addonAfter: x,
|
|
1345
|
-
addonBefore: C,
|
|
1346
|
-
className: L,
|
|
1347
|
-
style: S,
|
|
1348
|
-
styles: N,
|
|
1349
|
-
rootClassName: B,
|
|
1350
|
-
onChange: j,
|
|
1351
|
-
classNames: O,
|
|
1352
|
-
variant: A,
|
|
1353
|
-
_skipAddonWarning: K
|
|
1354
|
-
} = e, m = wr(e, ["prefixCls", "bordered", "status", "size", "disabled", "onBlur", "onFocus", "suffix", "allowClear", "addonAfter", "addonBefore", "className", "style", "styles", "rootClassName", "onChange", "classNames", "variant", "_skipAddonWarning"]);
|
|
1355
|
-
if (process.env.NODE_ENV !== "production") {
|
|
1356
|
-
const {
|
|
1357
|
-
deprecated: oe
|
|
1358
|
-
} = ze("Input");
|
|
1359
|
-
oe(!("bordered" in e), "bordered", "variant"), K || [["addonAfter", "Space.Compact"], ["addonBefore", "Space.Compact"]].forEach(([ie, Oe]) => {
|
|
1360
|
-
oe(!(ie in e), ie, Oe);
|
|
1361
|
-
});
|
|
1362
|
-
}
|
|
1363
|
-
const {
|
|
1364
|
-
getPrefixCls: y,
|
|
1365
|
-
direction: f,
|
|
1366
|
-
allowClear: H,
|
|
1367
|
-
autoComplete: _,
|
|
1368
|
-
className: I,
|
|
1369
|
-
style: z,
|
|
1370
|
-
classNames: T,
|
|
1371
|
-
styles: Q
|
|
1372
|
-
} = bt("input"), w = y("input", r), P = pe(null), E = ht(w), [M, h, ne] = Rt(w, B), [X] = It(w, E), {
|
|
1373
|
-
compactSize: k,
|
|
1374
|
-
compactItemClassnames: Y
|
|
1375
|
-
} = et(w, f), p = Fe((oe) => {
|
|
1376
|
-
var ie;
|
|
1377
|
-
return (ie = i ?? k) !== null && ie !== void 0 ? ie : oe;
|
|
1378
|
-
}), l = R.useContext(tt), v = a ?? l, {
|
|
1379
|
-
status: b,
|
|
1380
|
-
hasFeedback: ee,
|
|
1381
|
-
feedbackIcon: $
|
|
1382
|
-
} = Ue(we), Z = nt(b, o), q = yr(e) || !!ee, ce = pe(q);
|
|
1383
|
-
if (process.env.NODE_ENV !== "production") {
|
|
1384
|
-
const oe = ze("Input");
|
|
1385
|
-
Ie(() => {
|
|
1386
|
-
var ie;
|
|
1387
|
-
q && !ce.current && process.env.NODE_ENV !== "production" && oe(document.activeElement === ((ie = P.current) === null || ie === void 0 ? void 0 : ie.input), "usage", "When Input is focused, dynamic add or remove prefix / suffix will make it lose focus caused by dom structure change. Read more: https://ant.design/components/input/#FAQ"), ce.current = q;
|
|
1388
|
-
}, [q]);
|
|
1389
|
-
}
|
|
1390
|
-
const ge = At(P, !0), be = (oe) => {
|
|
1391
|
-
ge(), s == null || s(oe);
|
|
1392
|
-
}, me = (oe) => {
|
|
1393
|
-
ge(), u == null || u(oe);
|
|
1394
|
-
}, de = (oe) => {
|
|
1395
|
-
ge(), j == null || j(oe);
|
|
1396
|
-
}, D = (ee || g) && /* @__PURE__ */ R.createElement(R.Fragment, null, g, ee && $), G = Nt(d ?? H), [le, ae] = xt("input", A, n);
|
|
1397
|
-
return M(X(/* @__PURE__ */ R.createElement($r, Object.assign({
|
|
1398
|
-
ref: rt(t, P),
|
|
1399
|
-
prefixCls: w,
|
|
1400
|
-
autoComplete: _
|
|
1401
|
-
}, m, {
|
|
1402
|
-
disabled: v,
|
|
1403
|
-
onBlur: be,
|
|
1404
|
-
onFocus: me,
|
|
1405
|
-
style: Object.assign(Object.assign({}, z), S),
|
|
1406
|
-
styles: Object.assign(Object.assign({}, Q), N),
|
|
1407
|
-
suffix: D,
|
|
1408
|
-
allowClear: G,
|
|
1409
|
-
className: W(L, B, ne, E, Y, I),
|
|
1410
|
-
onChange: de,
|
|
1411
|
-
addonBefore: C && /* @__PURE__ */ R.createElement(at, {
|
|
1412
|
-
form: !0,
|
|
1413
|
-
space: !0
|
|
1414
|
-
}, C),
|
|
1415
|
-
addonAfter: x && /* @__PURE__ */ R.createElement(at, {
|
|
1416
|
-
form: !0,
|
|
1417
|
-
space: !0
|
|
1418
|
-
}, x),
|
|
1419
|
-
classNames: Object.assign(Object.assign(Object.assign({}, O), T), {
|
|
1420
|
-
input: W({
|
|
1421
|
-
[`${w}-sm`]: p === "small",
|
|
1422
|
-
[`${w}-lg`]: p === "large",
|
|
1423
|
-
[`${w}-rtl`]: f === "rtl"
|
|
1424
|
-
}, O == null ? void 0 : O.input, T.input, h),
|
|
1425
|
-
variant: W({
|
|
1426
|
-
[`${w}-${le}`]: ae
|
|
1427
|
-
}, qe(w, Z)),
|
|
1428
|
-
affixWrapper: W({
|
|
1429
|
-
[`${w}-affix-wrapper-sm`]: p === "small",
|
|
1430
|
-
[`${w}-affix-wrapper-lg`]: p === "large",
|
|
1431
|
-
[`${w}-affix-wrapper-rtl`]: f === "rtl"
|
|
1432
|
-
}, h),
|
|
1433
|
-
wrapper: W({
|
|
1434
|
-
[`${w}-group-rtl`]: f === "rtl"
|
|
1435
|
-
}, h),
|
|
1436
|
-
groupWrapper: W({
|
|
1437
|
-
[`${w}-group-wrapper-sm`]: p === "small",
|
|
1438
|
-
[`${w}-group-wrapper-lg`]: p === "large",
|
|
1439
|
-
[`${w}-group-wrapper-rtl`]: f === "rtl",
|
|
1440
|
-
[`${w}-group-wrapper-${le}`]: ae
|
|
1441
|
-
}, qe(`${w}-group-wrapper`, Z, ee), h)
|
|
1442
|
-
})
|
|
1443
|
-
}))));
|
|
1444
|
-
});
|
|
1445
|
-
process.env.NODE_ENV !== "production" && (je.displayName = "Input");
|
|
1446
|
-
const Er = (e) => {
|
|
1447
|
-
const {
|
|
1448
|
-
getPrefixCls: t,
|
|
1449
|
-
direction: r
|
|
1450
|
-
} = Ue(Be), {
|
|
1451
|
-
prefixCls: n,
|
|
1452
|
-
className: o
|
|
1453
|
-
} = e, i = t("input-group", n), a = t("input"), [s, u, g] = It(a), d = W(i, g, {
|
|
1454
|
-
[`${i}-lg`]: e.size === "large",
|
|
1455
|
-
[`${i}-sm`]: e.size === "small",
|
|
1456
|
-
[`${i}-compact`]: e.compact,
|
|
1457
|
-
[`${i}-rtl`]: r === "rtl"
|
|
1458
|
-
}, u, o), x = Ue(we), C = Wt(() => Object.assign(Object.assign({}, x), {
|
|
1459
|
-
isFormItemInput: !1
|
|
1460
|
-
}), [x]);
|
|
1461
|
-
return process.env.NODE_ENV !== "production" && ze("Input.Group").deprecated(!1, "Input.Group", "Space.Compact"), s(/* @__PURE__ */ c.createElement("span", {
|
|
1462
|
-
className: d,
|
|
1463
|
-
style: e.style,
|
|
1464
|
-
onMouseEnter: e.onMouseEnter,
|
|
1465
|
-
onMouseLeave: e.onMouseLeave,
|
|
1466
|
-
onFocus: e.onFocus,
|
|
1467
|
-
onBlur: e.onBlur
|
|
1468
|
-
}, /* @__PURE__ */ c.createElement(we.Provider, {
|
|
1469
|
-
value: C
|
|
1470
|
-
}, e.children)));
|
|
1471
|
-
}, Or = (e) => {
|
|
1472
|
-
const {
|
|
1473
|
-
componentCls: t,
|
|
1474
|
-
paddingXS: r
|
|
1475
|
-
} = e;
|
|
1476
|
-
return {
|
|
1477
|
-
[t]: {
|
|
1478
|
-
display: "inline-flex",
|
|
1479
|
-
alignItems: "center",
|
|
1480
|
-
flexWrap: "nowrap",
|
|
1481
|
-
columnGap: r,
|
|
1482
|
-
[`${t}-input-wrapper`]: {
|
|
1483
|
-
position: "relative",
|
|
1484
|
-
[`${t}-mask-icon`]: {
|
|
1485
|
-
position: "absolute",
|
|
1486
|
-
zIndex: "1",
|
|
1487
|
-
top: "50%",
|
|
1488
|
-
right: "50%",
|
|
1489
|
-
transform: "translate(50%, -50%)",
|
|
1490
|
-
pointerEvents: "none"
|
|
1491
|
-
},
|
|
1492
|
-
[`${t}-mask-input`]: {
|
|
1493
|
-
color: "transparent",
|
|
1494
|
-
caretColor: e.colorText
|
|
1495
|
-
},
|
|
1496
|
-
[`${t}-mask-input[type=number]::-webkit-inner-spin-button`]: {
|
|
1497
|
-
"-webkit-appearance": "none",
|
|
1498
|
-
margin: 0
|
|
1499
|
-
},
|
|
1500
|
-
[`${t}-mask-input[type=number]`]: {
|
|
1501
|
-
"-moz-appearance": "textfield"
|
|
1502
|
-
}
|
|
1503
|
-
},
|
|
1504
|
-
"&-rtl": {
|
|
1505
|
-
direction: "rtl"
|
|
1506
|
-
},
|
|
1507
|
-
[`${t}-input`]: {
|
|
1508
|
-
textAlign: "center",
|
|
1509
|
-
paddingInline: e.paddingXXS
|
|
1510
|
-
},
|
|
1511
|
-
// ================= Size =================
|
|
1512
|
-
[`&${t}-sm ${t}-input`]: {
|
|
1513
|
-
paddingInline: e.calc(e.paddingXXS).div(2).equal()
|
|
1514
|
-
},
|
|
1515
|
-
[`&${t}-lg ${t}-input`]: {
|
|
1516
|
-
paddingInline: e.paddingXS
|
|
1517
|
-
}
|
|
1518
|
-
}
|
|
1519
|
-
};
|
|
1520
|
-
}, Rr = Te(["Input", "OTP"], (e) => {
|
|
1521
|
-
const t = Ee(e, De(e));
|
|
1522
|
-
return Or(t);
|
|
1523
|
-
}, We);
|
|
1524
|
-
var Ir = function(e, t) {
|
|
1525
|
-
var r = {};
|
|
1526
|
-
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
1527
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var o = 0, n = Object.getOwnPropertySymbols(e); o < n.length; o++)
|
|
1528
|
-
t.indexOf(n[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[o]) && (r[n[o]] = e[n[o]]);
|
|
1529
|
-
return r;
|
|
1530
|
-
};
|
|
1531
|
-
const zr = /* @__PURE__ */ c.forwardRef((e, t) => {
|
|
1532
|
-
const {
|
|
1533
|
-
className: r,
|
|
1534
|
-
value: n,
|
|
1535
|
-
onChange: o,
|
|
1536
|
-
onActiveChange: i,
|
|
1537
|
-
index: a,
|
|
1538
|
-
mask: s
|
|
1539
|
-
} = e, u = Ir(e, ["className", "value", "onChange", "onActiveChange", "index", "mask"]), {
|
|
1540
|
-
getPrefixCls: g
|
|
1541
|
-
} = c.useContext(Be), d = g("otp"), x = typeof s == "string" ? s : n, C = c.useRef(null);
|
|
1542
|
-
c.useImperativeHandle(t, () => C.current);
|
|
1543
|
-
const L = (B) => {
|
|
1544
|
-
o(a, B.target.value);
|
|
1545
|
-
}, S = () => {
|
|
1546
|
-
Qe(() => {
|
|
1547
|
-
var B;
|
|
1548
|
-
const j = (B = C.current) === null || B === void 0 ? void 0 : B.input;
|
|
1549
|
-
document.activeElement === j && j && j.select();
|
|
1550
|
-
});
|
|
1551
|
-
}, N = (B) => {
|
|
1552
|
-
const {
|
|
1553
|
-
key: j,
|
|
1554
|
-
ctrlKey: O,
|
|
1555
|
-
metaKey: A
|
|
1556
|
-
} = B;
|
|
1557
|
-
j === "ArrowLeft" ? i(a - 1) : j === "ArrowRight" ? i(a + 1) : j === "z" && (O || A) ? B.preventDefault() : j === "Backspace" && !n && i(a - 1), S();
|
|
1558
|
-
};
|
|
1559
|
-
return /* @__PURE__ */ c.createElement("span", {
|
|
1560
|
-
className: `${d}-input-wrapper`,
|
|
1561
|
-
role: "presentation"
|
|
1562
|
-
}, s && n !== "" && n !== void 0 && /* @__PURE__ */ c.createElement("span", {
|
|
1563
|
-
className: `${d}-mask-icon`,
|
|
1564
|
-
"aria-hidden": "true"
|
|
1565
|
-
}, x), /* @__PURE__ */ c.createElement(je, Object.assign({
|
|
1566
|
-
"aria-label": `OTP Input ${a + 1}`,
|
|
1567
|
-
type: s === !0 ? "password" : "text"
|
|
1568
|
-
}, u, {
|
|
1569
|
-
ref: C,
|
|
1570
|
-
value: n,
|
|
1571
|
-
onInput: L,
|
|
1572
|
-
onFocus: S,
|
|
1573
|
-
onKeyDown: N,
|
|
1574
|
-
onMouseDown: S,
|
|
1575
|
-
onMouseUp: S,
|
|
1576
|
-
className: W(r, {
|
|
1577
|
-
[`${d}-mask-input`]: s
|
|
1578
|
-
})
|
|
1579
|
-
})));
|
|
1580
|
-
});
|
|
1581
|
-
var Br = function(e, t) {
|
|
1582
|
-
var r = {};
|
|
1583
|
-
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
1584
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var o = 0, n = Object.getOwnPropertySymbols(e); o < n.length; o++)
|
|
1585
|
-
t.indexOf(n[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[o]) && (r[n[o]] = e[n[o]]);
|
|
1586
|
-
return r;
|
|
1587
|
-
};
|
|
1588
|
-
function Pe(e) {
|
|
1589
|
-
return (e || "").split("");
|
|
1590
|
-
}
|
|
1591
|
-
const jr = (e) => {
|
|
1592
|
-
const {
|
|
1593
|
-
index: t,
|
|
1594
|
-
prefixCls: r,
|
|
1595
|
-
separator: n
|
|
1596
|
-
} = e, o = typeof n == "function" ? n(t) : n;
|
|
1597
|
-
return o ? /* @__PURE__ */ c.createElement("span", {
|
|
1598
|
-
className: `${r}-separator`
|
|
1599
|
-
}, o) : null;
|
|
1600
|
-
}, Nr = /* @__PURE__ */ c.forwardRef((e, t) => {
|
|
1601
|
-
const {
|
|
1602
|
-
prefixCls: r,
|
|
1603
|
-
length: n = 6,
|
|
1604
|
-
size: o,
|
|
1605
|
-
defaultValue: i,
|
|
1606
|
-
value: a,
|
|
1607
|
-
onChange: s,
|
|
1608
|
-
formatter: u,
|
|
1609
|
-
separator: g,
|
|
1610
|
-
variant: d,
|
|
1611
|
-
disabled: x,
|
|
1612
|
-
status: C,
|
|
1613
|
-
autoFocus: L,
|
|
1614
|
-
mask: S,
|
|
1615
|
-
type: N,
|
|
1616
|
-
onInput: B,
|
|
1617
|
-
inputMode: j
|
|
1618
|
-
} = e, O = Br(e, ["prefixCls", "length", "size", "defaultValue", "value", "onChange", "formatter", "separator", "variant", "disabled", "status", "autoFocus", "mask", "type", "onInput", "inputMode"]);
|
|
1619
|
-
if (process.env.NODE_ENV !== "production") {
|
|
1620
|
-
const l = ze("Input.OTP");
|
|
1621
|
-
process.env.NODE_ENV !== "production" && l(!(typeof S == "string" && S.length > 1), "usage", "`mask` prop should be a single character.");
|
|
1622
|
-
}
|
|
1623
|
-
const {
|
|
1624
|
-
getPrefixCls: A,
|
|
1625
|
-
direction: K
|
|
1626
|
-
} = c.useContext(Be), m = A("otp", r), y = Kt(O, {
|
|
1627
|
-
aria: !0,
|
|
1628
|
-
data: !0,
|
|
1629
|
-
attr: !0
|
|
1630
|
-
}), [f, H, _] = Rr(m), I = Fe((l) => o ?? l), z = c.useContext(we), T = nt(z.status, C), Q = c.useMemo(() => Object.assign(Object.assign({}, z), {
|
|
1631
|
-
status: T,
|
|
1632
|
-
hasFeedback: !1,
|
|
1633
|
-
feedbackIcon: null
|
|
1634
|
-
}), [z, T]), w = c.useRef(null), P = c.useRef({});
|
|
1635
|
-
c.useImperativeHandle(t, () => ({
|
|
1636
|
-
focus: () => {
|
|
1637
|
-
var l;
|
|
1638
|
-
(l = P.current[0]) === null || l === void 0 || l.focus();
|
|
1639
|
-
},
|
|
1640
|
-
blur: () => {
|
|
1641
|
-
var l;
|
|
1642
|
-
for (let v = 0; v < n; v += 1)
|
|
1643
|
-
(l = P.current[v]) === null || l === void 0 || l.blur();
|
|
1644
|
-
},
|
|
1645
|
-
nativeElement: w.current
|
|
1646
|
-
}));
|
|
1647
|
-
const E = (l) => u ? u(l) : l, [M, h] = c.useState(() => Pe(E(i || "")));
|
|
1648
|
-
c.useEffect(() => {
|
|
1649
|
-
a !== void 0 && h(Pe(a));
|
|
1650
|
-
}, [a]);
|
|
1651
|
-
const ne = it((l) => {
|
|
1652
|
-
h(l), B && B(l), s && l.length === n && l.every((v) => v) && l.some((v, b) => M[b] !== v) && s(l.join(""));
|
|
1653
|
-
}), X = it((l, v) => {
|
|
1654
|
-
let b = ke(M);
|
|
1655
|
-
for (let $ = 0; $ < l; $ += 1)
|
|
1656
|
-
b[$] || (b[$] = "");
|
|
1657
|
-
v.length <= 1 ? b[l] = v : b = b.slice(0, l).concat(Pe(v)), b = b.slice(0, n);
|
|
1658
|
-
for (let $ = b.length - 1; $ >= 0 && !b[$]; $ -= 1)
|
|
1659
|
-
b.pop();
|
|
1660
|
-
const ee = E(b.map(($) => $ || " ").join(""));
|
|
1661
|
-
return b = Pe(ee).map(($, Z) => $ === " " && !b[Z] ? b[Z] : $), b;
|
|
1662
|
-
}), k = (l, v) => {
|
|
1663
|
-
var b;
|
|
1664
|
-
const ee = X(l, v), $ = Math.min(l + v.length, n - 1);
|
|
1665
|
-
$ !== l && ee[l] !== void 0 && ((b = P.current[$]) === null || b === void 0 || b.focus()), ne(ee);
|
|
1666
|
-
}, Y = (l) => {
|
|
1667
|
-
var v;
|
|
1668
|
-
(v = P.current[l]) === null || v === void 0 || v.focus();
|
|
1669
|
-
}, p = {
|
|
1670
|
-
variant: d,
|
|
1671
|
-
disabled: x,
|
|
1672
|
-
status: T,
|
|
1673
|
-
mask: S,
|
|
1674
|
-
type: N,
|
|
1675
|
-
inputMode: j
|
|
1676
|
-
};
|
|
1677
|
-
return f(/* @__PURE__ */ c.createElement("div", Object.assign({}, y, {
|
|
1678
|
-
ref: w,
|
|
1679
|
-
className: W(m, {
|
|
1680
|
-
[`${m}-sm`]: I === "small",
|
|
1681
|
-
[`${m}-lg`]: I === "large",
|
|
1682
|
-
[`${m}-rtl`]: K === "rtl"
|
|
1683
|
-
}, _, H),
|
|
1684
|
-
role: "group"
|
|
1685
|
-
}), /* @__PURE__ */ c.createElement(we.Provider, {
|
|
1686
|
-
value: Q
|
|
1687
|
-
}, Array.from({
|
|
1688
|
-
length: n
|
|
1689
|
-
}).map((l, v) => {
|
|
1690
|
-
const b = `otp-${v}`, ee = M[v] || "";
|
|
1691
|
-
return /* @__PURE__ */ c.createElement(c.Fragment, {
|
|
1692
|
-
key: b
|
|
1693
|
-
}, /* @__PURE__ */ c.createElement(zr, Object.assign({
|
|
1694
|
-
ref: ($) => {
|
|
1695
|
-
P.current[v] = $;
|
|
1696
|
-
},
|
|
1697
|
-
index: v,
|
|
1698
|
-
size: I,
|
|
1699
|
-
htmlSize: 1,
|
|
1700
|
-
className: `${m}-input`,
|
|
1701
|
-
onChange: k,
|
|
1702
|
-
value: ee,
|
|
1703
|
-
onActiveChange: Y,
|
|
1704
|
-
autoFocus: v === 0 && L
|
|
1705
|
-
}, p)), v < n - 1 && /* @__PURE__ */ c.createElement(jr, {
|
|
1706
|
-
separator: g,
|
|
1707
|
-
index: v,
|
|
1708
|
-
prefixCls: m
|
|
1709
|
-
}));
|
|
1710
|
-
}))));
|
|
1711
|
-
});
|
|
1712
|
-
var Ar = { icon: { tag: "svg", attrs: { viewBox: "64 64 896 896", focusable: "false" }, children: [{ tag: "path", attrs: { d: "M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z" } }, { tag: "path", attrs: { d: "M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z" } }] }, name: "eye-invisible", theme: "outlined" }, Pr = function(t, r) {
|
|
1713
|
-
return /* @__PURE__ */ c.createElement(Ut, ye({}, t, {
|
|
1714
|
-
ref: r,
|
|
1715
|
-
icon: Ar
|
|
1716
|
-
}));
|
|
1717
|
-
}, Pt = /* @__PURE__ */ c.forwardRef(Pr);
|
|
1718
|
-
process.env.NODE_ENV !== "production" && (Pt.displayName = "EyeInvisibleOutlined");
|
|
1719
|
-
var _r = function(e, t) {
|
|
1720
|
-
var r = {};
|
|
1721
|
-
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
1722
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var o = 0, n = Object.getOwnPropertySymbols(e); o < n.length; o++)
|
|
1723
|
-
t.indexOf(n[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[o]) && (r[n[o]] = e[n[o]]);
|
|
1724
|
-
return r;
|
|
1725
|
-
};
|
|
1726
|
-
const Tr = (e) => e ? /* @__PURE__ */ c.createElement(Jt, null) : /* @__PURE__ */ c.createElement(Pt, null), Mr = {
|
|
1727
|
-
click: "onClick",
|
|
1728
|
-
hover: "onMouseOver"
|
|
1729
|
-
}, _t = /* @__PURE__ */ c.forwardRef((e, t) => {
|
|
1730
|
-
const {
|
|
1731
|
-
disabled: r,
|
|
1732
|
-
action: n = "click",
|
|
1733
|
-
visibilityToggle: o = !0,
|
|
1734
|
-
iconRender: i = Tr,
|
|
1735
|
-
suffix: a
|
|
1736
|
-
} = e, s = c.useContext(tt), u = r ?? s, g = typeof o == "object" && o.visible !== void 0, [d, x] = Ke(() => g ? o.visible : !1), C = pe(null);
|
|
1737
|
-
c.useEffect(() => {
|
|
1738
|
-
g && x(o.visible);
|
|
1739
|
-
}, [g, o]);
|
|
1740
|
-
const L = At(C), S = () => {
|
|
1741
|
-
var z;
|
|
1742
|
-
if (u)
|
|
1743
|
-
return;
|
|
1744
|
-
d && L();
|
|
1745
|
-
const T = !d;
|
|
1746
|
-
x(T), typeof o == "object" && ((z = o.onVisibleChange) === null || z === void 0 || z.call(o, T));
|
|
1747
|
-
}, N = (z) => {
|
|
1748
|
-
const T = Mr[n] || "", Q = i(d), w = {
|
|
1749
|
-
[T]: S,
|
|
1750
|
-
className: `${z}-icon`,
|
|
1751
|
-
key: "passwordIcon",
|
|
1752
|
-
onMouseDown: (P) => {
|
|
1753
|
-
P.preventDefault();
|
|
1754
|
-
},
|
|
1755
|
-
onMouseUp: (P) => {
|
|
1756
|
-
P.preventDefault();
|
|
1757
|
-
}
|
|
1758
|
-
};
|
|
1759
|
-
return /* @__PURE__ */ c.cloneElement(/* @__PURE__ */ c.isValidElement(Q) ? Q : /* @__PURE__ */ c.createElement("span", null, Q), w);
|
|
1760
|
-
}, {
|
|
1761
|
-
className: B,
|
|
1762
|
-
prefixCls: j,
|
|
1763
|
-
inputPrefixCls: O,
|
|
1764
|
-
size: A
|
|
1765
|
-
} = e, K = _r(e, ["className", "prefixCls", "inputPrefixCls", "size"]), {
|
|
1766
|
-
getPrefixCls: m
|
|
1767
|
-
} = c.useContext(Be), y = m("input", O), f = m("input-password", j), H = o && N(f), _ = W(f, B, {
|
|
1768
|
-
[`${f}-${A}`]: !!A
|
|
1769
|
-
}), I = Object.assign(Object.assign({}, vt(K, ["suffix", "iconRender", "visibilityToggle"])), {
|
|
1770
|
-
type: d ? "text" : "password",
|
|
1771
|
-
className: _,
|
|
1772
|
-
prefixCls: y,
|
|
1773
|
-
suffix: /* @__PURE__ */ c.createElement(c.Fragment, null, H, a)
|
|
1774
|
-
});
|
|
1775
|
-
return A && (I.size = A), /* @__PURE__ */ c.createElement(je, Object.assign({
|
|
1776
|
-
ref: rt(t, C)
|
|
1777
|
-
}, I));
|
|
1778
|
-
});
|
|
1779
|
-
process.env.NODE_ENV !== "production" && (_t.displayName = "Input.Password");
|
|
1780
|
-
var Fr = function(e, t) {
|
|
1781
|
-
var r = {};
|
|
1782
|
-
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
1783
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var o = 0, n = Object.getOwnPropertySymbols(e); o < n.length; o++)
|
|
1784
|
-
t.indexOf(n[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[o]) && (r[n[o]] = e[n[o]]);
|
|
1785
|
-
return r;
|
|
1786
|
-
};
|
|
1787
|
-
const Tt = /* @__PURE__ */ c.forwardRef((e, t) => {
|
|
1788
|
-
const {
|
|
1789
|
-
prefixCls: r,
|
|
1790
|
-
inputPrefixCls: n,
|
|
1791
|
-
className: o,
|
|
1792
|
-
size: i,
|
|
1793
|
-
suffix: a,
|
|
1794
|
-
enterButton: s = !1,
|
|
1795
|
-
addonAfter: u,
|
|
1796
|
-
loading: g,
|
|
1797
|
-
disabled: d,
|
|
1798
|
-
onSearch: x,
|
|
1799
|
-
onChange: C,
|
|
1800
|
-
onCompositionStart: L,
|
|
1801
|
-
onCompositionEnd: S,
|
|
1802
|
-
variant: N,
|
|
1803
|
-
onPressEnter: B
|
|
1804
|
-
} = e, j = Fr(e, ["prefixCls", "inputPrefixCls", "className", "size", "suffix", "enterButton", "addonAfter", "loading", "disabled", "onSearch", "onChange", "onCompositionStart", "onCompositionEnd", "variant", "onPressEnter"]), {
|
|
1805
|
-
getPrefixCls: O,
|
|
1806
|
-
direction: A
|
|
1807
|
-
} = c.useContext(Be), K = c.useRef(!1), m = O("input-search", r), y = O("input", n), {
|
|
1808
|
-
compactSize: f
|
|
1809
|
-
} = et(m, A), H = Fe((p) => {
|
|
1810
|
-
var l;
|
|
1811
|
-
return (l = i ?? f) !== null && l !== void 0 ? l : p;
|
|
1812
|
-
}), _ = c.useRef(null), I = (p) => {
|
|
1813
|
-
p != null && p.target && p.type === "click" && x && x(p.target.value, p, {
|
|
1814
|
-
source: "clear"
|
|
1815
|
-
}), C == null || C(p);
|
|
1816
|
-
}, z = (p) => {
|
|
1817
|
-
var l;
|
|
1818
|
-
document.activeElement === ((l = _.current) === null || l === void 0 ? void 0 : l.input) && p.preventDefault();
|
|
1819
|
-
}, T = (p) => {
|
|
1820
|
-
var l, v;
|
|
1821
|
-
x && x((v = (l = _.current) === null || l === void 0 ? void 0 : l.input) === null || v === void 0 ? void 0 : v.value, p, {
|
|
1822
|
-
source: "input"
|
|
1823
|
-
});
|
|
1824
|
-
}, Q = (p) => {
|
|
1825
|
-
K.current || g || (B == null || B(p), T(p));
|
|
1826
|
-
}, w = typeof s == "boolean" ? /* @__PURE__ */ c.createElement(qt, null) : null, P = `${m}-button`;
|
|
1827
|
-
let E;
|
|
1828
|
-
const M = s || {}, h = M.type && M.type.__ANT_BUTTON === !0;
|
|
1829
|
-
h || M.type === "button" ? E = st(M, Object.assign({
|
|
1830
|
-
onMouseDown: z,
|
|
1831
|
-
onClick: (p) => {
|
|
1832
|
-
var l, v;
|
|
1833
|
-
(v = (l = M == null ? void 0 : M.props) === null || l === void 0 ? void 0 : l.onClick) === null || v === void 0 || v.call(l, p), T(p);
|
|
1834
|
-
},
|
|
1835
|
-
key: "enterButton"
|
|
1836
|
-
}, h ? {
|
|
1837
|
-
className: P,
|
|
1838
|
-
size: H
|
|
1839
|
-
} : {})) : E = /* @__PURE__ */ c.createElement(Xt, {
|
|
1840
|
-
className: P,
|
|
1841
|
-
color: s ? "primary" : "default",
|
|
1842
|
-
size: H,
|
|
1843
|
-
disabled: d,
|
|
1844
|
-
key: "enterButton",
|
|
1845
|
-
onMouseDown: z,
|
|
1846
|
-
onClick: T,
|
|
1847
|
-
loading: g,
|
|
1848
|
-
icon: w,
|
|
1849
|
-
variant: N === "borderless" || N === "filled" || N === "underlined" ? "text" : s ? "solid" : void 0
|
|
1850
|
-
}, s), u && (E = [E, st(u, {
|
|
1851
|
-
key: "addonAfter"
|
|
1852
|
-
})]);
|
|
1853
|
-
const ne = W(m, {
|
|
1854
|
-
[`${m}-rtl`]: A === "rtl",
|
|
1855
|
-
[`${m}-${H}`]: !!H,
|
|
1856
|
-
[`${m}-with-button`]: !!s
|
|
1857
|
-
}, o), X = (p) => {
|
|
1858
|
-
K.current = !0, L == null || L(p);
|
|
1859
|
-
}, k = (p) => {
|
|
1860
|
-
K.current = !1, S == null || S(p);
|
|
1861
|
-
}, Y = Object.assign(Object.assign({}, j), {
|
|
1862
|
-
className: ne,
|
|
1863
|
-
prefixCls: y,
|
|
1864
|
-
type: "search",
|
|
1865
|
-
size: H,
|
|
1866
|
-
variant: N,
|
|
1867
|
-
onPressEnter: Q,
|
|
1868
|
-
onCompositionStart: X,
|
|
1869
|
-
onCompositionEnd: k,
|
|
1870
|
-
addonAfter: E,
|
|
1871
|
-
suffix: a,
|
|
1872
|
-
onChange: I,
|
|
1873
|
-
disabled: d,
|
|
1874
|
-
_skipAddonWarning: !0
|
|
1875
|
-
});
|
|
1876
|
-
return /* @__PURE__ */ c.createElement(je, Object.assign({
|
|
1877
|
-
ref: rt(_, t)
|
|
1878
|
-
}, Y));
|
|
1879
|
-
});
|
|
1880
|
-
process.env.NODE_ENV !== "production" && (Tt.displayName = "Search");
|
|
1881
|
-
var Dr = `
|
|
1882
|
-
min-height:0 !important;
|
|
1883
|
-
max-height:none !important;
|
|
1884
|
-
height:0 !important;
|
|
1885
|
-
visibility:hidden !important;
|
|
1886
|
-
overflow:hidden !important;
|
|
1887
|
-
position:absolute !important;
|
|
1888
|
-
z-index:-1000 !important;
|
|
1889
|
-
top:0 !important;
|
|
1890
|
-
right:0 !important;
|
|
1891
|
-
pointer-events: none !important;
|
|
1892
|
-
`, Wr = ["letter-spacing", "line-height", "padding-top", "padding-bottom", "font-family", "font-weight", "font-size", "font-variant", "text-rendering", "text-transform", "width", "text-indent", "padding-left", "padding-right", "border-width", "box-sizing", "word-break", "white-space"], He = {}, ue;
|
|
1893
|
-
function Hr(e) {
|
|
1894
|
-
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, r = e.getAttribute("id") || e.getAttribute("data-reactid") || e.getAttribute("name");
|
|
1895
|
-
if (t && He[r])
|
|
1896
|
-
return He[r];
|
|
1897
|
-
var n = window.getComputedStyle(e), o = n.getPropertyValue("box-sizing") || n.getPropertyValue("-moz-box-sizing") || n.getPropertyValue("-webkit-box-sizing"), i = parseFloat(n.getPropertyValue("padding-bottom")) + parseFloat(n.getPropertyValue("padding-top")), a = parseFloat(n.getPropertyValue("border-bottom-width")) + parseFloat(n.getPropertyValue("border-top-width")), s = Wr.map(function(g) {
|
|
1898
|
-
return "".concat(g, ":").concat(n.getPropertyValue(g));
|
|
1899
|
-
}).join(";"), u = {
|
|
1900
|
-
sizingStyle: s,
|
|
1901
|
-
paddingSize: i,
|
|
1902
|
-
borderSize: a,
|
|
1903
|
-
boxSizing: o
|
|
1904
|
-
};
|
|
1905
|
-
return t && r && (He[r] = u), u;
|
|
1906
|
-
}
|
|
1907
|
-
function Lr(e) {
|
|
1908
|
-
var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : null, n = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : null;
|
|
1909
|
-
ue || (ue = document.createElement("textarea"), ue.setAttribute("tab-index", "-1"), ue.setAttribute("aria-hidden", "true"), ue.setAttribute("name", "hiddenTextarea"), document.body.appendChild(ue)), e.getAttribute("wrap") ? ue.setAttribute("wrap", e.getAttribute("wrap")) : ue.removeAttribute("wrap");
|
|
1910
|
-
var o = Hr(e, t), i = o.paddingSize, a = o.borderSize, s = o.boxSizing, u = o.sizingStyle;
|
|
1911
|
-
ue.setAttribute("style", "".concat(u, ";").concat(Dr)), ue.value = e.value || e.placeholder || "";
|
|
1912
|
-
var g = void 0, d = void 0, x, C = ue.scrollHeight;
|
|
1913
|
-
if (s === "border-box" ? C += a : s === "content-box" && (C -= i), r !== null || n !== null) {
|
|
1914
|
-
ue.value = " ";
|
|
1915
|
-
var L = ue.scrollHeight - i;
|
|
1916
|
-
r !== null && (g = L * r, s === "border-box" && (g = g + i + a), C = Math.max(g, C)), n !== null && (d = L * n, s === "border-box" && (d = d + i + a), x = C > d ? "" : "hidden", C = Math.min(d, C));
|
|
1917
|
-
}
|
|
1918
|
-
var S = {
|
|
1919
|
-
height: C,
|
|
1920
|
-
overflowY: x,
|
|
1921
|
-
resize: "none"
|
|
1922
|
-
};
|
|
1923
|
-
return g && (S.minHeight = g), d && (S.maxHeight = d), S;
|
|
1924
|
-
}
|
|
1925
|
-
var Vr = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "className", "style", "disabled", "onChange", "onInternalAutoSize"], Le = 0, Ve = 1, Ge = 2, Gr = /* @__PURE__ */ c.forwardRef(function(e, t) {
|
|
1926
|
-
var r = e, n = r.prefixCls, o = r.defaultValue, i = r.value, a = r.autoSize, s = r.onResize, u = r.className, g = r.style, d = r.disabled, x = r.onChange, C = r.onInternalAutoSize, L = Me(r, Vr), S = Je(o, {
|
|
1927
|
-
value: i,
|
|
1928
|
-
postState: function(l) {
|
|
1929
|
-
return l ?? "";
|
|
1930
|
-
}
|
|
1931
|
-
}), N = ve(S, 2), B = N[0], j = N[1], O = function(l) {
|
|
1932
|
-
j(l.target.value), x == null || x(l);
|
|
1933
|
-
}, A = c.useRef();
|
|
1934
|
-
c.useImperativeHandle(t, function() {
|
|
1935
|
-
return {
|
|
1936
|
-
textArea: A.current
|
|
1937
|
-
};
|
|
1938
|
-
});
|
|
1939
|
-
var K = c.useMemo(function() {
|
|
1940
|
-
return a && Ze(a) === "object" ? [a.minRows, a.maxRows] : [];
|
|
1941
|
-
}, [a]), m = ve(K, 2), y = m[0], f = m[1], H = !!a, _ = c.useState(Ge), I = ve(_, 2), z = I[0], T = I[1], Q = c.useState(), w = ve(Q, 2), P = w[0], E = w[1], M = function() {
|
|
1942
|
-
T(Le), process.env.NODE_ENV === "test" && (C == null || C());
|
|
1943
|
-
};
|
|
1944
|
-
Xe(function() {
|
|
1945
|
-
H && M();
|
|
1946
|
-
}, [i, y, f, H]), Xe(function() {
|
|
1947
|
-
if (z === Le)
|
|
1948
|
-
T(Ve);
|
|
1949
|
-
else if (z === Ve) {
|
|
1950
|
-
var p = Lr(A.current, !1, y, f);
|
|
1951
|
-
T(Ge), E(p);
|
|
1952
|
-
}
|
|
1953
|
-
}, [z]);
|
|
1954
|
-
var h = c.useRef(), ne = function() {
|
|
1955
|
-
Qe.cancel(h.current);
|
|
1956
|
-
}, X = function(l) {
|
|
1957
|
-
z === Ge && (s == null || s(l), a && (ne(), h.current = Qe(function() {
|
|
1958
|
-
M();
|
|
1959
|
-
})));
|
|
1960
|
-
};
|
|
1961
|
-
c.useEffect(function() {
|
|
1962
|
-
return ne;
|
|
1963
|
-
}, []);
|
|
1964
|
-
var k = H ? P : null, Y = se(se({}, g), k);
|
|
1965
|
-
return (z === Le || z === Ve) && (Y.overflowY = "hidden", Y.overflowX = "hidden"), /* @__PURE__ */ c.createElement(Qt, {
|
|
1966
|
-
onResize: X,
|
|
1967
|
-
disabled: !(a || s)
|
|
1968
|
-
}, /* @__PURE__ */ c.createElement("textarea", ye({}, L, {
|
|
1969
|
-
ref: A,
|
|
1970
|
-
style: Y,
|
|
1971
|
-
className: W(n, u, fe({}, "".concat(n, "-disabled"), d)),
|
|
1972
|
-
disabled: d,
|
|
1973
|
-
value: B,
|
|
1974
|
-
onChange: O
|
|
1975
|
-
})));
|
|
1976
|
-
}), Kr = ["defaultValue", "value", "onFocus", "onBlur", "onChange", "allowClear", "maxLength", "onCompositionStart", "onCompositionEnd", "suffix", "prefixCls", "showCount", "count", "className", "style", "disabled", "hidden", "classNames", "styles", "onResize", "onClear", "onPressEnter", "readOnly", "autoSize", "onKeyDown"], Ur = /* @__PURE__ */ R.forwardRef(function(e, t) {
|
|
1977
|
-
var r, n = e.defaultValue, o = e.value, i = e.onFocus, a = e.onBlur, s = e.onChange, u = e.allowClear, g = e.maxLength, d = e.onCompositionStart, x = e.onCompositionEnd, C = e.suffix, L = e.prefixCls, S = L === void 0 ? "rc-textarea" : L, N = e.showCount, B = e.count, j = e.className, O = e.style, A = e.disabled, K = e.hidden, m = e.classNames, y = e.styles, f = e.onResize, H = e.onClear, _ = e.onPressEnter, I = e.readOnly, z = e.autoSize, T = e.onKeyDown, Q = Me(e, Kr), w = Je(n, {
|
|
1978
|
-
value: o,
|
|
1979
|
-
defaultValue: n
|
|
1980
|
-
}), P = ve(w, 2), E = P[0], M = P[1], h = E == null ? "" : String(E), ne = R.useState(!1), X = ve(ne, 2), k = X[0], Y = X[1], p = R.useRef(!1), l = R.useState(null), v = ve(l, 2), b = v[0], ee = v[1], $ = pe(null), Z = pe(null), q = function() {
|
|
1981
|
-
var V;
|
|
1982
|
-
return (V = Z.current) === null || V === void 0 ? void 0 : V.textArea;
|
|
1983
|
-
}, ce = function() {
|
|
1984
|
-
q().focus();
|
|
1985
|
-
};
|
|
1986
|
-
gt(t, function() {
|
|
1987
|
-
var re;
|
|
1988
|
-
return {
|
|
1989
|
-
resizableTextArea: Z.current,
|
|
1990
|
-
focus: ce,
|
|
1991
|
-
blur: function() {
|
|
1992
|
-
q().blur();
|
|
1993
|
-
},
|
|
1994
|
-
nativeElement: ((re = $.current) === null || re === void 0 ? void 0 : re.nativeElement) || q()
|
|
1995
|
-
};
|
|
1996
|
-
}), Ie(function() {
|
|
1997
|
-
Y(function(re) {
|
|
1998
|
-
return !A && re;
|
|
1999
|
-
});
|
|
2000
|
-
}, [A]);
|
|
2001
|
-
var ge = R.useState(null), be = ve(ge, 2), me = be[0], de = be[1];
|
|
2002
|
-
R.useEffect(function() {
|
|
2003
|
-
if (me) {
|
|
2004
|
-
var re;
|
|
2005
|
-
(re = q()).setSelectionRange.apply(re, ke(me));
|
|
2006
|
-
}
|
|
2007
|
-
}, [me]);
|
|
2008
|
-
var D = jt(B, N), G = (r = D.max) !== null && r !== void 0 ? r : g, le = Number(G) > 0, ae = D.strategy(h), oe = !!G && ae > G, ie = function(V, Ce) {
|
|
2009
|
-
var Ae = Ce;
|
|
2010
|
-
!p.current && D.exceedFormatter && D.max && D.strategy(Ce) > D.max && (Ae = D.exceedFormatter(Ce, {
|
|
2011
|
-
max: D.max
|
|
2012
|
-
}), Ce !== Ae && de([q().selectionStart || 0, q().selectionEnd || 0])), M(Ae), _e(V.currentTarget, V, s, Ae);
|
|
2013
|
-
}, Oe = function(V) {
|
|
2014
|
-
p.current = !0, d == null || d(V);
|
|
2015
|
-
}, U = function(V) {
|
|
2016
|
-
p.current = !1, ie(V, V.currentTarget.value), x == null || x(V);
|
|
2017
|
-
}, F = function(V) {
|
|
2018
|
-
ie(V, V.target.value);
|
|
2019
|
-
}, te = function(V) {
|
|
2020
|
-
V.key === "Enter" && _ && _(V), T == null || T(V);
|
|
2021
|
-
}, Se = function(V) {
|
|
2022
|
-
Y(!0), i == null || i(V);
|
|
2023
|
-
}, xe = function(V) {
|
|
2024
|
-
Y(!1), a == null || a(V);
|
|
2025
|
-
}, he = function(V) {
|
|
2026
|
-
M(""), ce(), _e(q(), V, s);
|
|
2027
|
-
}, $e = C, Re;
|
|
2028
|
-
D.show && (D.showFormatter ? Re = D.showFormatter({
|
|
2029
|
-
value: h,
|
|
2030
|
-
count: ae,
|
|
2031
|
-
maxLength: G
|
|
2032
|
-
}) : Re = "".concat(ae).concat(le ? " / ".concat(G) : ""), $e = /* @__PURE__ */ R.createElement(R.Fragment, null, $e, /* @__PURE__ */ R.createElement("span", {
|
|
2033
|
-
className: W("".concat(S, "-data-count"), m == null ? void 0 : m.count),
|
|
2034
|
-
style: y == null ? void 0 : y.count
|
|
2035
|
-
}, Re)));
|
|
2036
|
-
var Mt = function(V) {
|
|
2037
|
-
var Ce;
|
|
2038
|
-
f == null || f(V), (Ce = q()) !== null && Ce !== void 0 && Ce.style.height && ee(!0);
|
|
2039
|
-
}, Ft = !z && !N && !u;
|
|
2040
|
-
return /* @__PURE__ */ R.createElement(Bt, {
|
|
2041
|
-
ref: $,
|
|
2042
|
-
value: h,
|
|
2043
|
-
allowClear: u,
|
|
2044
|
-
handleReset: he,
|
|
2045
|
-
suffix: $e,
|
|
2046
|
-
prefixCls: S,
|
|
2047
|
-
classNames: se(se({}, m), {}, {
|
|
2048
|
-
affixWrapper: W(m == null ? void 0 : m.affixWrapper, fe(fe({}, "".concat(S, "-show-count"), N), "".concat(S, "-textarea-allow-clear"), u))
|
|
2049
|
-
}),
|
|
2050
|
-
disabled: A,
|
|
2051
|
-
focused: k,
|
|
2052
|
-
className: W(j, oe && "".concat(S, "-out-of-range")),
|
|
2053
|
-
style: se(se({}, O), b && !Ft ? {
|
|
2054
|
-
height: "auto"
|
|
2055
|
-
} : {}),
|
|
2056
|
-
dataAttrs: {
|
|
2057
|
-
affixWrapper: {
|
|
2058
|
-
"data-count": typeof Re == "string" ? Re : void 0
|
|
2059
|
-
}
|
|
2060
|
-
},
|
|
2061
|
-
hidden: K,
|
|
2062
|
-
readOnly: I,
|
|
2063
|
-
onClear: H
|
|
2064
|
-
}, /* @__PURE__ */ R.createElement(Gr, ye({}, Q, {
|
|
2065
|
-
autoSize: z,
|
|
2066
|
-
maxLength: g,
|
|
2067
|
-
onKeyDown: te,
|
|
2068
|
-
onChange: F,
|
|
2069
|
-
onFocus: Se,
|
|
2070
|
-
onBlur: xe,
|
|
2071
|
-
onCompositionStart: Oe,
|
|
2072
|
-
onCompositionEnd: U,
|
|
2073
|
-
className: W(m == null ? void 0 : m.textarea),
|
|
2074
|
-
style: se(se({}, y == null ? void 0 : y.textarea), {}, {
|
|
2075
|
-
resize: O == null ? void 0 : O.resize
|
|
2076
|
-
}),
|
|
2077
|
-
disabled: A,
|
|
2078
|
-
prefixCls: S,
|
|
2079
|
-
onResize: Mt,
|
|
2080
|
-
ref: Z,
|
|
2081
|
-
readOnly: I
|
|
2082
|
-
})));
|
|
2083
|
-
});
|
|
2084
|
-
const Xr = (e) => {
|
|
2085
|
-
const {
|
|
2086
|
-
componentCls: t,
|
|
2087
|
-
paddingLG: r
|
|
2088
|
-
} = e, n = `${t}-textarea`;
|
|
2089
|
-
return {
|
|
2090
|
-
// Raw Textarea
|
|
2091
|
-
[`textarea${t}`]: {
|
|
2092
|
-
maxWidth: "100%",
|
|
2093
|
-
// prevent textarea resize from coming out of its container
|
|
2094
|
-
height: "auto",
|
|
2095
|
-
minHeight: e.controlHeight,
|
|
2096
|
-
lineHeight: e.lineHeight,
|
|
2097
|
-
verticalAlign: "bottom",
|
|
2098
|
-
transition: `all ${e.motionDurationSlow}`,
|
|
2099
|
-
resize: "vertical",
|
|
2100
|
-
[`&${t}-mouse-active`]: {
|
|
2101
|
-
transition: `all ${e.motionDurationSlow}, height 0s, width 0s`
|
|
2102
|
-
}
|
|
2103
|
-
},
|
|
2104
|
-
// Wrapper for resize
|
|
2105
|
-
[`${t}-textarea-affix-wrapper-resize-dirty`]: {
|
|
2106
|
-
width: "auto"
|
|
2107
|
-
},
|
|
2108
|
-
[n]: {
|
|
2109
|
-
position: "relative",
|
|
2110
|
-
"&-show-count": {
|
|
2111
|
-
[`${t}-data-count`]: {
|
|
2112
|
-
position: "absolute",
|
|
2113
|
-
bottom: e.calc(e.fontSize).mul(e.lineHeight).mul(-1).equal(),
|
|
2114
|
-
insetInlineEnd: 0,
|
|
2115
|
-
color: e.colorTextDescription,
|
|
2116
|
-
whiteSpace: "nowrap",
|
|
2117
|
-
pointerEvents: "none"
|
|
2118
|
-
}
|
|
2119
|
-
},
|
|
2120
|
-
[`
|
|
2121
|
-
&-allow-clear > ${t},
|
|
2122
|
-
&-affix-wrapper${n}-has-feedback ${t}
|
|
2123
|
-
`]: {
|
|
2124
|
-
paddingInlineEnd: r
|
|
2125
|
-
},
|
|
2126
|
-
[`&-affix-wrapper${t}-affix-wrapper`]: {
|
|
2127
|
-
padding: 0,
|
|
2128
|
-
[`> textarea${t}`]: {
|
|
2129
|
-
fontSize: "inherit",
|
|
2130
|
-
border: "none",
|
|
2131
|
-
outline: "none",
|
|
2132
|
-
background: "transparent",
|
|
2133
|
-
minHeight: e.calc(e.controlHeight).sub(e.calc(e.lineWidth).mul(2)).equal(),
|
|
2134
|
-
"&:focus": {
|
|
2135
|
-
boxShadow: "none !important"
|
|
2136
|
-
}
|
|
2137
|
-
},
|
|
2138
|
-
[`${t}-suffix`]: {
|
|
2139
|
-
margin: 0,
|
|
2140
|
-
"> *:not(:last-child)": {
|
|
2141
|
-
marginInline: 0
|
|
2142
|
-
},
|
|
2143
|
-
// Clear Icon
|
|
2144
|
-
[`${t}-clear-icon`]: {
|
|
2145
|
-
position: "absolute",
|
|
2146
|
-
insetInlineEnd: e.paddingInline,
|
|
2147
|
-
insetBlockStart: e.paddingXS
|
|
2148
|
-
},
|
|
2149
|
-
// Feedback Icon
|
|
2150
|
-
[`${n}-suffix`]: {
|
|
2151
|
-
position: "absolute",
|
|
2152
|
-
top: 0,
|
|
2153
|
-
insetInlineEnd: e.paddingInline,
|
|
2154
|
-
bottom: 0,
|
|
2155
|
-
zIndex: 1,
|
|
2156
|
-
display: "inline-flex",
|
|
2157
|
-
alignItems: "center",
|
|
2158
|
-
margin: "auto",
|
|
2159
|
-
pointerEvents: "none"
|
|
2160
|
-
}
|
|
2161
|
-
}
|
|
2162
|
-
},
|
|
2163
|
-
[`&-affix-wrapper${t}-affix-wrapper-rtl`]: {
|
|
2164
|
-
[`${t}-suffix`]: {
|
|
2165
|
-
[`${t}-data-count`]: {
|
|
2166
|
-
direction: "ltr",
|
|
2167
|
-
insetInlineStart: 0
|
|
2168
|
-
}
|
|
2169
|
-
}
|
|
2170
|
-
},
|
|
2171
|
-
[`&-affix-wrapper${t}-affix-wrapper-sm`]: {
|
|
2172
|
-
[`${t}-suffix`]: {
|
|
2173
|
-
[`${t}-clear-icon`]: {
|
|
2174
|
-
insetInlineEnd: e.paddingInlineSM
|
|
2175
|
-
}
|
|
2176
|
-
}
|
|
2177
|
-
}
|
|
2178
|
-
}
|
|
2179
|
-
};
|
|
2180
|
-
}, qr = Te(["Input", "TextArea"], (e) => {
|
|
2181
|
-
const t = Ee(e, De(e));
|
|
2182
|
-
return Xr(t);
|
|
2183
|
-
}, We, {
|
|
2184
|
-
resetFont: !1
|
|
2185
|
-
});
|
|
2186
|
-
var Qr = function(e, t) {
|
|
2187
|
-
var r = {};
|
|
2188
|
-
for (var n in e) Object.prototype.hasOwnProperty.call(e, n) && t.indexOf(n) < 0 && (r[n] = e[n]);
|
|
2189
|
-
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var o = 0, n = Object.getOwnPropertySymbols(e); o < n.length; o++)
|
|
2190
|
-
t.indexOf(n[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, n[o]) && (r[n[o]] = e[n[o]]);
|
|
2191
|
-
return r;
|
|
2192
|
-
};
|
|
2193
|
-
const Yr = /* @__PURE__ */ Ye((e, t) => {
|
|
2194
|
-
var r;
|
|
2195
|
-
const {
|
|
2196
|
-
prefixCls: n,
|
|
2197
|
-
bordered: o = !0,
|
|
2198
|
-
size: i,
|
|
2199
|
-
disabled: a,
|
|
2200
|
-
status: s,
|
|
2201
|
-
allowClear: u,
|
|
2202
|
-
classNames: g,
|
|
2203
|
-
rootClassName: d,
|
|
2204
|
-
className: x,
|
|
2205
|
-
style: C,
|
|
2206
|
-
styles: L,
|
|
2207
|
-
variant: S,
|
|
2208
|
-
showCount: N,
|
|
2209
|
-
onMouseDown: B,
|
|
2210
|
-
onResize: j
|
|
2211
|
-
} = e, O = Qr(e, ["prefixCls", "bordered", "size", "disabled", "status", "allowClear", "classNames", "rootClassName", "className", "style", "styles", "variant", "showCount", "onMouseDown", "onResize"]);
|
|
2212
|
-
if (process.env.NODE_ENV !== "production") {
|
|
2213
|
-
const {
|
|
2214
|
-
deprecated: D
|
|
2215
|
-
} = ze("TextArea");
|
|
2216
|
-
D(!("bordered" in e), "bordered", "variant");
|
|
2217
|
-
}
|
|
2218
|
-
const {
|
|
2219
|
-
getPrefixCls: A,
|
|
2220
|
-
direction: K,
|
|
2221
|
-
allowClear: m,
|
|
2222
|
-
autoComplete: y,
|
|
2223
|
-
className: f,
|
|
2224
|
-
style: H,
|
|
2225
|
-
classNames: _,
|
|
2226
|
-
styles: I
|
|
2227
|
-
} = bt("textArea"), z = c.useContext(tt), T = a ?? z, {
|
|
2228
|
-
status: Q,
|
|
2229
|
-
hasFeedback: w,
|
|
2230
|
-
feedbackIcon: P
|
|
2231
|
-
} = c.useContext(we), E = nt(Q, s), M = c.useRef(null);
|
|
2232
|
-
c.useImperativeHandle(t, () => {
|
|
2233
|
-
var D;
|
|
2234
|
-
return {
|
|
2235
|
-
resizableTextArea: (D = M.current) === null || D === void 0 ? void 0 : D.resizableTextArea,
|
|
2236
|
-
focus: (G) => {
|
|
2237
|
-
var le, ae;
|
|
2238
|
-
zt((ae = (le = M.current) === null || le === void 0 ? void 0 : le.resizableTextArea) === null || ae === void 0 ? void 0 : ae.textArea, G);
|
|
2239
|
-
},
|
|
2240
|
-
blur: () => {
|
|
2241
|
-
var G;
|
|
2242
|
-
return (G = M.current) === null || G === void 0 ? void 0 : G.blur();
|
|
2243
|
-
}
|
|
2244
|
-
};
|
|
2245
|
-
});
|
|
2246
|
-
const h = A("input", n), ne = ht(h), [X, k, Y] = Rt(h, d), [p] = qr(h, ne), {
|
|
2247
|
-
compactSize: l,
|
|
2248
|
-
compactItemClassnames: v
|
|
2249
|
-
} = et(h, K), b = Fe((D) => {
|
|
2250
|
-
var G;
|
|
2251
|
-
return (G = i ?? l) !== null && G !== void 0 ? G : D;
|
|
2252
|
-
}), [ee, $] = xt("textArea", S, o), Z = Nt(u ?? m), [q, ce] = c.useState(!1), [ge, be] = c.useState(!1), me = (D) => {
|
|
2253
|
-
ce(!0), B == null || B(D);
|
|
2254
|
-
const G = () => {
|
|
2255
|
-
ce(!1), document.removeEventListener("mouseup", G);
|
|
2256
|
-
};
|
|
2257
|
-
document.addEventListener("mouseup", G);
|
|
2258
|
-
}, de = (D) => {
|
|
2259
|
-
var G, le;
|
|
2260
|
-
if (j == null || j(D), q && typeof getComputedStyle == "function") {
|
|
2261
|
-
const ae = (le = (G = M.current) === null || G === void 0 ? void 0 : G.nativeElement) === null || le === void 0 ? void 0 : le.querySelector("textarea");
|
|
2262
|
-
ae && getComputedStyle(ae).resize === "both" && be(!0);
|
|
2263
|
-
}
|
|
2264
|
-
};
|
|
2265
|
-
return X(p(/* @__PURE__ */ c.createElement(Ur, Object.assign({
|
|
2266
|
-
autoComplete: y
|
|
2267
|
-
}, O, {
|
|
2268
|
-
style: Object.assign(Object.assign({}, H), C),
|
|
2269
|
-
styles: Object.assign(Object.assign({}, I), L),
|
|
2270
|
-
disabled: T,
|
|
2271
|
-
allowClear: Z,
|
|
2272
|
-
className: W(
|
|
2273
|
-
Y,
|
|
2274
|
-
ne,
|
|
2275
|
-
x,
|
|
2276
|
-
d,
|
|
2277
|
-
v,
|
|
2278
|
-
f,
|
|
2279
|
-
// Only for wrapper
|
|
2280
|
-
ge && `${h}-textarea-affix-wrapper-resize-dirty`
|
|
2281
|
-
),
|
|
2282
|
-
classNames: Object.assign(Object.assign(Object.assign({}, g), _), {
|
|
2283
|
-
textarea: W({
|
|
2284
|
-
[`${h}-sm`]: b === "small",
|
|
2285
|
-
[`${h}-lg`]: b === "large"
|
|
2286
|
-
}, k, g == null ? void 0 : g.textarea, _.textarea, q && `${h}-mouse-active`),
|
|
2287
|
-
variant: W({
|
|
2288
|
-
[`${h}-${ee}`]: $
|
|
2289
|
-
}, qe(h, E)),
|
|
2290
|
-
affixWrapper: W(`${h}-textarea-affix-wrapper`, {
|
|
2291
|
-
[`${h}-affix-wrapper-rtl`]: K === "rtl",
|
|
2292
|
-
[`${h}-affix-wrapper-sm`]: b === "small",
|
|
2293
|
-
[`${h}-affix-wrapper-lg`]: b === "large",
|
|
2294
|
-
[`${h}-textarea-show-count`]: N || ((r = e.count) === null || r === void 0 ? void 0 : r.show)
|
|
2295
|
-
}, k)
|
|
2296
|
-
}),
|
|
2297
|
-
prefixCls: h,
|
|
2298
|
-
suffix: w && /* @__PURE__ */ c.createElement("span", {
|
|
2299
|
-
className: `${h}-textarea-suffix`
|
|
2300
|
-
}, P),
|
|
2301
|
-
showCount: N,
|
|
2302
|
-
ref: M,
|
|
2303
|
-
onResize: de,
|
|
2304
|
-
onMouseDown: me
|
|
2305
|
-
}))));
|
|
2306
|
-
}), Ne = je;
|
|
2307
|
-
Ne.Group = Er;
|
|
2308
|
-
Ne.Search = Tt;
|
|
2309
|
-
Ne.TextArea = Yr;
|
|
2310
|
-
Ne.Password = _t;
|
|
2311
|
-
Ne.OTP = Nr;
|
|
2312
|
-
export {
|
|
2313
|
-
Bt as B,
|
|
2314
|
-
Ne as I,
|
|
2315
|
-
Yr as T,
|
|
2316
|
-
je as a,
|
|
2317
|
-
rn as b,
|
|
2318
|
-
De as c,
|
|
2319
|
-
or as d,
|
|
2320
|
-
sr as e,
|
|
2321
|
-
cr as f,
|
|
2322
|
-
Ot as g,
|
|
2323
|
-
ir as h,
|
|
2324
|
-
We as i,
|
|
2325
|
-
dr as j,
|
|
2326
|
-
ur as k,
|
|
2327
|
-
ar as l,
|
|
2328
|
-
tn as m,
|
|
2329
|
-
lr as n,
|
|
2330
|
-
St as o,
|
|
2331
|
-
ot as p,
|
|
2332
|
-
Et as q,
|
|
2333
|
-
Ct as r,
|
|
2334
|
-
zt as t,
|
|
2335
|
-
kt as u
|
|
2336
|
-
};
|