@gobolt/genesis 0.0.8 → 0.0.9
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/README.md +10 -0
- package/dist/{AntdIcon-c395a1c4.js → AntdIcon-BoLh1dP8.js} +66 -68
- package/dist/CheckOutlined-CeTKr6II.js +13 -0
- package/dist/{CloseCircleFilled-ddc51e7e.js → CloseCircleFilled-DXCxlIQL.js} +8 -11
- package/dist/{CloseOutlined-14b8bba1.js → CloseOutlined-ClXDNn82.js} +9 -12
- package/dist/{Compact-c39ed20d.js → Compact-CGY560JF.js} +63 -65
- package/dist/ContextIsolator-D5x2Ih51.js +20 -0
- package/dist/{ExclamationCircleFilled-23ef9812.js → ExclamationCircleFilled-C0Kj5KQV.js} +16 -22
- package/dist/KeyCode-DM2sFh3-.js +517 -0
- package/dist/LoadingOutlined-8EnJdZ7I.js +13 -0
- package/dist/{Overflow-a570fa69.js → Overflow-PBZD-PFm.js} +63 -64
- package/dist/{DownOutlined-64a4732a.js → PurePanel-BqPLRtc2.js} +67 -70
- package/dist/{SearchOutlined-a9014e08.js → SearchOutlined-BP3Z2K6j.js} +8 -11
- package/dist/{TextArea-20825221.js → TextArea-DKwCct3i.js} +583 -588
- package/dist/Typography-aGoDUl4R.js +710 -0
- package/dist/bundle.css +1204 -0
- package/dist/{button-fa1c119c.js → button-CDQgO1OK.js} +274 -278
- package/dist/{collapse-345bc884.js → collapse-Dtpt-6W_.js} +2 -2
- package/dist/compact-item-DH13cl8A.js +61 -0
- package/dist/components/Badge/Badge.d.ts +2 -2
- package/dist/components/Badge/Badge.js +63 -62
- package/dist/components/Badge/__tests__/Badge.test.js +11 -65
- package/dist/components/Badge/index.js +2 -21
- package/dist/components/Badge/styles.js +7 -8
- package/dist/components/Breadcrumb/Breadcrumb.js +8 -24
- package/dist/components/Breadcrumb/Breadcrumb.types.d.ts +21 -7
- package/dist/components/Breadcrumb/__tests__/Breadcrumb.test.js +13 -60
- package/dist/components/Breadcrumb/index.js +2 -25
- package/dist/components/Breadcrumb/styles.d.ts +10 -6
- package/dist/components/Breadcrumb/styles.js +787 -808
- package/dist/components/Button/Button.d.ts +6 -4
- package/dist/components/Button/Button.js +20 -40
- package/dist/components/Button/__tests__/Button.test.js +9 -54
- package/dist/components/Button/index.js +2 -20
- package/dist/components/Button/styles.d.ts +9 -5
- package/dist/components/Button/styles.js +19 -30
- package/dist/components/Checkbox/Checkbox.js +8 -38
- package/dist/components/Checkbox/__tests__/Checkbox.test.js +16 -62
- package/dist/components/Checkbox/index.js +2 -47
- package/dist/components/Checkbox/styles.d.ts +8 -1
- package/dist/components/Checkbox/styles.js +181 -188
- package/dist/components/ErrorBoundaryFallback/ErrorBoundaryFallback.d.ts +2 -4
- package/dist/components/ErrorBoundaryFallback/ErrorBoundaryFallback.js +19 -51
- package/dist/components/ErrorBoundaryFallback/index.d.ts +1 -0
- package/dist/components/ErrorBoundaryFallback/index.js +2 -49
- package/dist/components/ErrorBoundaryFallback/styles.d.ts +1 -3
- package/dist/components/ErrorBoundaryFallback/styles.js +34 -37
- package/dist/components/Form/Form.d.ts +18 -5
- package/dist/components/Form/Form.js +4 -45
- package/dist/components/Form/__stories__/FormStory.js +44 -81
- package/dist/components/Form/__tests__/form.test.d.ts +1 -0
- package/dist/components/Form/__tests__/form.test.js +18 -0
- package/dist/components/Form/index.js +2 -46
- package/dist/components/Form/styles.d.ts +3 -0
- package/dist/components/Form/styles.js +5 -0
- package/dist/components/Input/Input.js +6 -29
- package/dist/components/Input/__tests__/Input.test.js +21 -66
- package/dist/components/Input/index.js +2 -29
- package/dist/components/Input/styles.d.ts +5 -2
- package/dist/components/Input/styles.js +319 -332
- package/dist/components/Message/Message.d.ts +4 -4
- package/dist/components/Message/Message.js +53 -80
- package/dist/components/Message/__tests__/Message.test.js +24 -70
- package/dist/components/Message/index.js +2 -48
- package/dist/components/Message/styles.d.ts +4 -1
- package/dist/components/Message/styles.js +24 -18
- package/dist/components/Notification/Notification.d.ts +11 -10
- package/dist/components/Notification/Notification.js +306 -372
- package/dist/components/Notification/NotificationRightChevron.d.ts +2 -0
- package/dist/components/Notification/NotificationRightChevron.js +23 -0
- package/dist/components/Notification/__tests__/Notification.test.js +8 -69
- package/dist/components/Notification/index.js +2 -59
- package/dist/components/Notification/styles.d.ts +13 -3
- package/dist/components/Notification/styles.js +36 -20
- package/dist/components/Radio/Radio.js +20 -106
- package/dist/components/Radio/RadioGroup.js +18 -71
- package/dist/components/Radio/__stories__/RadioGroup.stories.d.ts +1 -1
- package/dist/components/Radio/__tests__/RadioGroup.test.js +15 -70
- package/dist/components/Radio/index.d.ts +1 -1
- package/dist/components/Radio/index.js +2 -56
- package/dist/components/Select/DropdownChevron.d.ts +2 -0
- package/dist/components/Select/DropdownChevron.js +23 -0
- package/dist/components/Select/Select.d.ts +9 -4
- package/dist/components/Select/Select.js +29 -41
- package/dist/components/Select/__tests__/Select.test.js +10752 -93
- package/dist/components/Select/index.js +2 -28
- package/dist/components/Select/styles.d.ts +20 -6
- package/dist/components/Select/styles.js +1381 -1370
- package/dist/components/Toast/Toast.d.ts +4 -4
- package/dist/components/Toast/Toast.js +8 -37
- package/dist/components/Toast/__stories__/Toast.stories.d.ts +1 -0
- package/dist/components/Toast/__tests__/Toast.test.js +10 -55
- package/dist/components/Toast/index.js +2 -46
- package/dist/components/Toast/styles.d.ts +6 -1
- package/dist/components/Toast/styles.js +36 -21
- package/dist/components/Typography/Typography.d.ts +7 -4
- package/dist/components/Typography/Typography.js +2 -42
- package/dist/components/Typography/__stories__/Typography.stories.d.ts +1 -0
- package/dist/components/Typography/__tests__/Typography.test.js +19 -56
- package/dist/components/Typography/index.js +2 -46
- package/dist/components/Typography/styles.d.ts +18 -4
- package/dist/components/Typography/styles.js +36 -43
- package/dist/components/index.d.ts +13 -5
- package/dist/components/index.js +24 -70
- package/dist/{context-3b8a39af.js → context-BMW3aJEf.js} +538 -548
- package/dist/genesis/GenesisThemeBreakdown.js +38 -55
- package/dist/genesis/GenesisThemeDemo.js +3 -53
- package/dist/genesis/styles.d.ts +6 -2
- package/dist/genesis/styles.js +496 -521
- package/dist/{index-e2b72ca8.js → index-1CBpubM3.js} +97 -102
- package/dist/index-BZAhCB_K.js +97 -0
- package/dist/{index-501fc13d.js → index-C0SmxWLS.js} +367 -392
- package/dist/index-C8haFnXI.js +1112 -0
- package/dist/index-CfDY25LP.js +873 -0
- package/dist/index-DPW8XdWj.js +952 -0
- package/dist/{index-8c8d2d0c.js → index-bKlRxQp4.js} +114 -114
- package/dist/index-oK7z6jnz.js +22795 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +31 -77
- package/dist/{isVisible-729780f5.js → isVisible-A-IfeFoT.js} +67 -94
- package/dist/{magic-string.es-b7491176.js → magic-string.es-D2FWSwU3.js} +56 -103
- package/dist/{pickAttrs-00ba4687.js → pickAttrs-B0YTfcV1.js} +1 -1
- package/dist/providers/GenesisProvider.d.ts +0 -5
- package/dist/providers/GenesisProvider.js +9 -59
- package/dist/providers/ThemeProvider.d.ts +1 -2
- package/dist/providers/ThemeProvider.js +11 -13
- package/dist/providers/ToastProvider.d.ts +11 -4
- package/dist/providers/ToastProvider.js +10 -39
- package/dist/providers/index.d.ts +2 -3
- package/dist/providers/index.js +4 -51
- package/dist/providers/useGenesis.d.ts +7 -0
- package/dist/providers/useGenesis.js +6 -0
- package/dist/setup-BvfREoHl.js +33891 -0
- package/dist/{styled-components.browser.esm-02f500bc.js → styled-components.browser.esm-CZ1XM4o4.js} +72 -134
- package/dist/styles/design-tokens/border-tokens/BorderTokenList.js +15 -45
- package/dist/styles/design-tokens/sizing-tokens/SizingTokenList.js +15 -45
- package/dist/styles/design-tokens/{typography → typography-tokens}/TypographyTokens.stories.d.ts +1 -0
- package/dist/styles/design-tokens/variables.d.ts +10 -10
- package/dist/styles/design-tokens/variables.js +1 -1
- package/dist/styles/global-styles.d.ts +1 -0
- package/dist/styles/global-styles.js +14 -31
- package/dist/styles/theme/genesis-theme.js +257 -212
- package/dist/styles/theme/genesis-theme.types.d.ts +46 -0
- package/dist/styles/theme/index.js +4 -5
- package/dist/styles-CT_fyXBd.js +1808 -0
- package/dist/test/setup.js +3 -46
- package/dist/useLocale-DT-z_vQ6.js +16 -0
- package/dist/useVariants-DvhXfgJY.js +30 -0
- package/dist/utils/isAllEnglishString.js +1 -2
- package/dist/{presets-83ccb923.js → warning-C63HNL9U.js} +358 -356
- package/package.json +35 -35
- package/dist/CheckOutlined-52d9ac25.js +0 -29
- package/dist/ContextIsolator-b09b2c52.js +0 -20
- package/dist/EllipsisOutlined-60122660.js +0 -1115
- package/dist/InfoCircleFilled-c5f90c20.js +0 -16
- package/dist/RightOutlined-83515eb4.js +0 -16
- package/dist/compact-item-b8f85aa6.js +0 -75
- package/dist/index-0a886e53.js +0 -100
- package/dist/index-0b9ee239.js +0 -955
- package/dist/index-1a33c134.js +0 -1389
- package/dist/index-4003d75b.js +0 -3748
- package/dist/index-89035ea5.js +0 -3242
- package/dist/providers/ToastWrapper.d.ts +0 -7
- package/dist/providers/ToastWrapper.js +0 -56
- package/dist/setup-aaca7b6f.js +0 -21158
- package/dist/styles/theme/global-styles.d.ts +0 -1
- package/dist/styles/theme/global-styles.js +0 -36
- package/dist/useVariants-a0d64298.js +0 -30
- /package/dist/{presetColors-ccf8cb4c.js → presetColors-Cl8UP3Nw.js} +0 -0
- /package/dist/{reactNode-f4391605.js → reactNode-sKPeiqPL.js} +0 -0
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
import * as K from "react";
|
|
2
|
-
import f, { useRef as le, cloneElement as
|
|
3
|
-
import { c as w, d as _e, h as ie, a as Ce, _ as
|
|
4
|
-
import { m as He,
|
|
5
|
-
import { u as Pe, o as
|
|
6
|
-
import { R as
|
|
7
|
-
import {
|
|
8
|
-
import { u as
|
|
9
|
-
import { u as
|
|
10
|
-
import { b as
|
|
11
|
-
import { C as Ge } from "./ContextIsolator-
|
|
12
|
-
import { g as
|
|
13
|
-
function
|
|
2
|
+
import f, { useRef as le, cloneElement as xn, forwardRef as We, useState as Me, useImperativeHandle as Ze, useEffect as $e, useContext as Sn } from "react";
|
|
3
|
+
import { c as w, d as _e, h as ie, a as Ce, _ as ne, e as Re, f as de } from "./warning-C63HNL9U.js";
|
|
4
|
+
import { m as He, q as T, g as $n, o as Qe, F as Cn, x as Je, v as Te, C as ke, D as en, t as yn, n as Le, w as Ve } from "./index-oK7z6jnz.js";
|
|
5
|
+
import { u as Pe, o as wn } from "./isVisible-A-IfeFoT.js";
|
|
6
|
+
import { R as En } from "./index-bKlRxQp4.js";
|
|
7
|
+
import { R as Rn } from "./CloseCircleFilled-DXCxlIQL.js";
|
|
8
|
+
import { u as nn, a as Fe, g as rn } from "./useVariants-DvhXfgJY.js";
|
|
9
|
+
import { u as tn, F as an } from "./context-BMW3aJEf.js";
|
|
10
|
+
import { b as In, a as on } from "./Compact-CGY560JF.js";
|
|
11
|
+
import { C as Ge } from "./ContextIsolator-D5x2Ih51.js";
|
|
12
|
+
import { g as zn } from "./compact-item-DH13cl8A.js";
|
|
13
|
+
function On(e) {
|
|
14
14
|
return He(e, {
|
|
15
15
|
inputAffixPadding: e.paddingXXS
|
|
16
16
|
});
|
|
17
17
|
}
|
|
18
|
-
const
|
|
18
|
+
const Bn = (e) => {
|
|
19
19
|
const {
|
|
20
|
-
controlHeight:
|
|
21
|
-
fontSize:
|
|
22
|
-
lineHeight:
|
|
23
|
-
lineWidth:
|
|
24
|
-
controlHeightSM:
|
|
20
|
+
controlHeight: n,
|
|
21
|
+
fontSize: r,
|
|
22
|
+
lineHeight: t,
|
|
23
|
+
lineWidth: a,
|
|
24
|
+
controlHeightSM: s,
|
|
25
25
|
controlHeightLG: i,
|
|
26
26
|
fontSizeLG: l,
|
|
27
27
|
lineHeightLG: S,
|
|
@@ -32,31 +32,31 @@ const Br = (e) => {
|
|
|
32
32
|
colorPrimaryHover: G,
|
|
33
33
|
colorPrimary: R,
|
|
34
34
|
controlOutlineWidth: A,
|
|
35
|
-
controlOutline:
|
|
35
|
+
controlOutline: re,
|
|
36
36
|
colorErrorOutline: ee,
|
|
37
37
|
colorWarningOutline: y,
|
|
38
|
-
colorBgContainer:
|
|
38
|
+
colorBgContainer: o
|
|
39
39
|
} = e;
|
|
40
40
|
return {
|
|
41
|
-
paddingBlock: Math.max(Math.round((
|
|
42
|
-
paddingBlockSM: Math.max(Math.round((
|
|
43
|
-
paddingBlockLG: Math.ceil((i - l * S) / 2 * 10) / 10 -
|
|
44
|
-
paddingInline: g -
|
|
45
|
-
paddingInlineSM: p -
|
|
46
|
-
paddingInlineLG: C -
|
|
41
|
+
paddingBlock: Math.max(Math.round((n - r * t) / 2 * 10) / 10 - a, 0),
|
|
42
|
+
paddingBlockSM: Math.max(Math.round((s - r * t) / 2 * 10) / 10 - a, 0),
|
|
43
|
+
paddingBlockLG: Math.ceil((i - l * S) / 2 * 10) / 10 - a,
|
|
44
|
+
paddingInline: g - a,
|
|
45
|
+
paddingInlineSM: p - a,
|
|
46
|
+
paddingInlineLG: C - a,
|
|
47
47
|
addonBg: E,
|
|
48
48
|
activeBorderColor: R,
|
|
49
49
|
hoverBorderColor: G,
|
|
50
|
-
activeShadow: `0 0 0 ${A}px ${
|
|
50
|
+
activeShadow: `0 0 0 ${A}px ${re}`,
|
|
51
51
|
errorActiveShadow: `0 0 0 ${A}px ${ee}`,
|
|
52
52
|
warningActiveShadow: `0 0 0 ${A}px ${y}`,
|
|
53
|
-
hoverBg:
|
|
54
|
-
activeBg:
|
|
55
|
-
inputFontSize:
|
|
53
|
+
hoverBg: o,
|
|
54
|
+
activeBg: o,
|
|
55
|
+
inputFontSize: r,
|
|
56
56
|
inputFontSizeLG: l,
|
|
57
|
-
inputFontSizeSM:
|
|
57
|
+
inputFontSizeSM: r
|
|
58
58
|
};
|
|
59
|
-
},
|
|
59
|
+
}, An = (e) => ({
|
|
60
60
|
borderColor: e.hoverBorderColor,
|
|
61
61
|
backgroundColor: e.hoverBg
|
|
62
62
|
}), De = (e) => ({
|
|
@@ -69,36 +69,36 @@ const Br = (e) => {
|
|
|
69
69
|
"input[disabled], textarea[disabled]": {
|
|
70
70
|
cursor: "not-allowed"
|
|
71
71
|
},
|
|
72
|
-
"&:hover:not([disabled])": Object.assign({},
|
|
72
|
+
"&:hover:not([disabled])": Object.assign({}, An(He(e, {
|
|
73
73
|
hoverBorderColor: e.colorBorder,
|
|
74
74
|
hoverBg: e.colorBgContainerDisabled
|
|
75
75
|
})))
|
|
76
|
-
}),
|
|
76
|
+
}), ln = (e, n) => ({
|
|
77
77
|
background: e.colorBgContainer,
|
|
78
78
|
borderWidth: e.lineWidth,
|
|
79
79
|
borderStyle: e.lineType,
|
|
80
|
-
borderColor:
|
|
80
|
+
borderColor: n.borderColor,
|
|
81
81
|
"&:hover": {
|
|
82
|
-
borderColor:
|
|
82
|
+
borderColor: n.hoverBorderColor,
|
|
83
83
|
backgroundColor: e.hoverBg
|
|
84
84
|
},
|
|
85
85
|
"&:focus, &:focus-within": {
|
|
86
|
-
borderColor:
|
|
87
|
-
boxShadow:
|
|
86
|
+
borderColor: n.activeBorderColor,
|
|
87
|
+
boxShadow: n.activeShadow,
|
|
88
88
|
outline: 0,
|
|
89
89
|
backgroundColor: e.activeBg
|
|
90
90
|
}
|
|
91
|
-
}), Ke = (e,
|
|
92
|
-
[`&${e.componentCls}-status-${
|
|
91
|
+
}), Ke = (e, n) => ({
|
|
92
|
+
[`&${e.componentCls}-status-${n.status}:not(${e.componentCls}-disabled)`]: Object.assign(Object.assign({}, ln(e, n)), {
|
|
93
93
|
[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]: {
|
|
94
|
-
color:
|
|
94
|
+
color: n.affixColor
|
|
95
95
|
}
|
|
96
96
|
}),
|
|
97
|
-
[`&${e.componentCls}-status-${
|
|
98
|
-
borderColor:
|
|
97
|
+
[`&${e.componentCls}-status-${n.status}${e.componentCls}-disabled`]: {
|
|
98
|
+
borderColor: n.borderColor
|
|
99
99
|
}
|
|
100
|
-
}),
|
|
101
|
-
"&-outlined": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},
|
|
100
|
+
}), Nn = (e, n) => ({
|
|
101
|
+
"&-outlined": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, ln(e, {
|
|
102
102
|
borderColor: e.colorBorder,
|
|
103
103
|
hoverBorderColor: e.hoverBorderColor,
|
|
104
104
|
activeBorderColor: e.activeBorderColor,
|
|
@@ -119,15 +119,15 @@ const Br = (e) => {
|
|
|
119
119
|
activeBorderColor: e.colorWarning,
|
|
120
120
|
activeShadow: e.warningActiveShadow,
|
|
121
121
|
affixColor: e.colorWarning
|
|
122
|
-
})),
|
|
123
|
-
}),
|
|
124
|
-
[`&${e.componentCls}-group-wrapper-status-${
|
|
122
|
+
})), n)
|
|
123
|
+
}), Xe = (e, n) => ({
|
|
124
|
+
[`&${e.componentCls}-group-wrapper-status-${n.status}`]: {
|
|
125
125
|
[`${e.componentCls}-group-addon`]: {
|
|
126
|
-
borderColor:
|
|
127
|
-
color:
|
|
126
|
+
borderColor: n.addonBorderColor,
|
|
127
|
+
color: n.addonColor
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
|
-
}),
|
|
130
|
+
}), jn = (e) => ({
|
|
131
131
|
"&-outlined": Object.assign(Object.assign(Object.assign({
|
|
132
132
|
[`${e.componentCls}-group`]: {
|
|
133
133
|
"&-addon": {
|
|
@@ -141,11 +141,11 @@ const Br = (e) => {
|
|
|
141
141
|
borderInlineStart: 0
|
|
142
142
|
}
|
|
143
143
|
}
|
|
144
|
-
},
|
|
144
|
+
}, Xe(e, {
|
|
145
145
|
status: "error",
|
|
146
146
|
addonBorderColor: e.colorError,
|
|
147
147
|
addonColor: e.colorErrorText
|
|
148
|
-
})),
|
|
148
|
+
})), Xe(e, {
|
|
149
149
|
status: "warning",
|
|
150
150
|
addonBorderColor: e.colorWarning,
|
|
151
151
|
addonColor: e.colorWarningText
|
|
@@ -154,9 +154,9 @@ const Br = (e) => {
|
|
|
154
154
|
[`${e.componentCls}-group-addon`]: Object.assign({}, De(e))
|
|
155
155
|
}
|
|
156
156
|
})
|
|
157
|
-
}),
|
|
157
|
+
}), Tn = (e, n) => {
|
|
158
158
|
const {
|
|
159
|
-
componentCls:
|
|
159
|
+
componentCls: r
|
|
160
160
|
} = e;
|
|
161
161
|
return {
|
|
162
162
|
"&-borderless": Object.assign({
|
|
@@ -166,75 +166,75 @@ const Br = (e) => {
|
|
|
166
166
|
outline: "none"
|
|
167
167
|
},
|
|
168
168
|
// >>>>> Disabled
|
|
169
|
-
[`&${
|
|
169
|
+
[`&${r}-disabled, &[disabled]`]: {
|
|
170
170
|
color: e.colorTextDisabled,
|
|
171
171
|
cursor: "not-allowed"
|
|
172
172
|
},
|
|
173
173
|
// >>>>> Status
|
|
174
|
-
[`&${
|
|
174
|
+
[`&${r}-status-error`]: {
|
|
175
175
|
"&, & input, & textarea": {
|
|
176
176
|
color: e.colorError
|
|
177
177
|
}
|
|
178
178
|
},
|
|
179
|
-
[`&${
|
|
179
|
+
[`&${r}-status-warning`]: {
|
|
180
180
|
"&, & input, & textarea": {
|
|
181
181
|
color: e.colorWarning
|
|
182
182
|
}
|
|
183
183
|
}
|
|
184
|
-
},
|
|
184
|
+
}, n)
|
|
185
185
|
};
|
|
186
|
-
},
|
|
187
|
-
background:
|
|
186
|
+
}, dn = (e, n) => ({
|
|
187
|
+
background: n.bg,
|
|
188
188
|
borderWidth: e.lineWidth,
|
|
189
189
|
borderStyle: e.lineType,
|
|
190
190
|
borderColor: "transparent",
|
|
191
191
|
"input&, & input, textarea&, & textarea": {
|
|
192
|
-
color:
|
|
192
|
+
color: n == null ? void 0 : n.inputColor
|
|
193
193
|
},
|
|
194
194
|
"&:hover": {
|
|
195
|
-
background:
|
|
195
|
+
background: n.hoverBg
|
|
196
196
|
},
|
|
197
197
|
"&:focus, &:focus-within": {
|
|
198
198
|
outline: 0,
|
|
199
|
-
borderColor:
|
|
199
|
+
borderColor: n.activeBorderColor,
|
|
200
200
|
backgroundColor: e.activeBg
|
|
201
201
|
}
|
|
202
|
-
}),
|
|
203
|
-
[`&${e.componentCls}-status-${
|
|
202
|
+
}), qe = (e, n) => ({
|
|
203
|
+
[`&${e.componentCls}-status-${n.status}:not(${e.componentCls}-disabled)`]: Object.assign(Object.assign({}, dn(e, n)), {
|
|
204
204
|
[`${e.componentCls}-prefix, ${e.componentCls}-suffix`]: {
|
|
205
|
-
color:
|
|
205
|
+
color: n.affixColor
|
|
206
206
|
}
|
|
207
207
|
})
|
|
208
|
-
}),
|
|
209
|
-
"&-filled": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},
|
|
208
|
+
}), Fn = (e, n) => ({
|
|
209
|
+
"&-filled": Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, dn(e, {
|
|
210
210
|
bg: e.colorFillTertiary,
|
|
211
211
|
hoverBg: e.colorFillSecondary,
|
|
212
212
|
activeBorderColor: e.activeBorderColor
|
|
213
213
|
})), {
|
|
214
214
|
[`&${e.componentCls}-disabled, &[disabled]`]: Object.assign({}, De(e))
|
|
215
|
-
}),
|
|
215
|
+
}), qe(e, {
|
|
216
216
|
status: "error",
|
|
217
217
|
bg: e.colorErrorBg,
|
|
218
218
|
hoverBg: e.colorErrorBgHover,
|
|
219
219
|
activeBorderColor: e.colorError,
|
|
220
220
|
inputColor: e.colorErrorText,
|
|
221
221
|
affixColor: e.colorError
|
|
222
|
-
})),
|
|
222
|
+
})), qe(e, {
|
|
223
223
|
status: "warning",
|
|
224
224
|
bg: e.colorWarningBg,
|
|
225
225
|
hoverBg: e.colorWarningBgHover,
|
|
226
226
|
activeBorderColor: e.colorWarning,
|
|
227
227
|
inputColor: e.colorWarningText,
|
|
228
228
|
affixColor: e.colorWarning
|
|
229
|
-
})),
|
|
230
|
-
}), Ue = (e,
|
|
231
|
-
[`&${e.componentCls}-group-wrapper-status-${
|
|
229
|
+
})), n)
|
|
230
|
+
}), Ue = (e, n) => ({
|
|
231
|
+
[`&${e.componentCls}-group-wrapper-status-${n.status}`]: {
|
|
232
232
|
[`${e.componentCls}-group-addon`]: {
|
|
233
|
-
background:
|
|
234
|
-
color:
|
|
233
|
+
background: n.addonBg,
|
|
234
|
+
color: n.addonColor
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
|
-
}),
|
|
237
|
+
}), Wn = (e) => ({
|
|
238
238
|
"&-filled": Object.assign(Object.assign(Object.assign({
|
|
239
239
|
[`${e.componentCls}-group`]: {
|
|
240
240
|
"&-addon": {
|
|
@@ -277,7 +277,7 @@ const Br = (e) => {
|
|
|
277
277
|
}
|
|
278
278
|
}
|
|
279
279
|
})
|
|
280
|
-
}),
|
|
280
|
+
}), _n = (e) => ({
|
|
281
281
|
// Firefox
|
|
282
282
|
"&::-moz-placeholder": {
|
|
283
283
|
opacity: 1
|
|
@@ -290,24 +290,24 @@ const Br = (e) => {
|
|
|
290
290
|
"&:placeholder-shown": {
|
|
291
291
|
textOverflow: "ellipsis"
|
|
292
292
|
}
|
|
293
|
-
}),
|
|
293
|
+
}), sn = (e) => {
|
|
294
294
|
const {
|
|
295
|
-
paddingBlockLG:
|
|
296
|
-
lineHeightLG:
|
|
297
|
-
borderRadiusLG:
|
|
298
|
-
paddingInlineLG:
|
|
295
|
+
paddingBlockLG: n,
|
|
296
|
+
lineHeightLG: r,
|
|
297
|
+
borderRadiusLG: t,
|
|
298
|
+
paddingInlineLG: a
|
|
299
299
|
} = e;
|
|
300
300
|
return {
|
|
301
|
-
padding: `${T(
|
|
301
|
+
padding: `${T(n)} ${T(a)}`,
|
|
302
302
|
fontSize: e.inputFontSizeLG,
|
|
303
|
-
lineHeight:
|
|
304
|
-
borderRadius:
|
|
303
|
+
lineHeight: r,
|
|
304
|
+
borderRadius: t
|
|
305
305
|
};
|
|
306
|
-
},
|
|
306
|
+
}, un = (e) => ({
|
|
307
307
|
padding: `${T(e.paddingBlockSM)} ${T(e.paddingInlineSM)}`,
|
|
308
308
|
fontSize: e.inputFontSizeSM,
|
|
309
309
|
borderRadius: e.borderRadiusSM
|
|
310
|
-
}),
|
|
310
|
+
}), cn = (e) => Object.assign(Object.assign({
|
|
311
311
|
position: "relative",
|
|
312
312
|
display: "inline-block",
|
|
313
313
|
width: "100%",
|
|
@@ -318,7 +318,7 @@ const Br = (e) => {
|
|
|
318
318
|
lineHeight: e.lineHeight,
|
|
319
319
|
borderRadius: e.borderRadius,
|
|
320
320
|
transition: `all ${e.motionDurationMid}`
|
|
321
|
-
},
|
|
321
|
+
}, _n(e.colorTextPlaceholder)), {
|
|
322
322
|
// Reset height for `textarea`s
|
|
323
323
|
"textarea&": {
|
|
324
324
|
maxWidth: "100%",
|
|
@@ -331,16 +331,16 @@ const Br = (e) => {
|
|
|
331
331
|
resize: "vertical"
|
|
332
332
|
},
|
|
333
333
|
// Size
|
|
334
|
-
"&-lg": Object.assign({},
|
|
335
|
-
"&-sm": Object.assign({},
|
|
334
|
+
"&-lg": Object.assign({}, sn(e)),
|
|
335
|
+
"&-sm": Object.assign({}, un(e)),
|
|
336
336
|
// RTL
|
|
337
337
|
"&-rtl, &-textarea-rtl": {
|
|
338
338
|
direction: "rtl"
|
|
339
339
|
}
|
|
340
|
-
}),
|
|
340
|
+
}), Hn = (e) => {
|
|
341
341
|
const {
|
|
342
|
-
componentCls:
|
|
343
|
-
antCls:
|
|
342
|
+
componentCls: n,
|
|
343
|
+
antCls: r
|
|
344
344
|
} = e;
|
|
345
345
|
return {
|
|
346
346
|
position: "relative",
|
|
@@ -356,22 +356,22 @@ const Br = (e) => {
|
|
|
356
356
|
}
|
|
357
357
|
},
|
|
358
358
|
// Sizing options
|
|
359
|
-
[`&-lg ${
|
|
360
|
-
[`&-sm ${
|
|
359
|
+
[`&-lg ${n}, &-lg > ${n}-group-addon`]: Object.assign({}, sn(e)),
|
|
360
|
+
[`&-sm ${n}, &-sm > ${n}-group-addon`]: Object.assign({}, un(e)),
|
|
361
361
|
// Fix https://github.com/ant-design/ant-design/issues/5754
|
|
362
|
-
[`&-lg ${
|
|
362
|
+
[`&-lg ${r}-select-single ${r}-select-selector`]: {
|
|
363
363
|
height: e.controlHeightLG
|
|
364
364
|
},
|
|
365
|
-
[`&-sm ${
|
|
365
|
+
[`&-sm ${r}-select-single ${r}-select-selector`]: {
|
|
366
366
|
height: e.controlHeightSM
|
|
367
367
|
},
|
|
368
|
-
[`> ${
|
|
368
|
+
[`> ${n}`]: {
|
|
369
369
|
display: "table-cell",
|
|
370
370
|
"&:not(:first-child):not(:last-child)": {
|
|
371
371
|
borderRadius: 0
|
|
372
372
|
}
|
|
373
373
|
},
|
|
374
|
-
[`${
|
|
374
|
+
[`${n}-group`]: {
|
|
375
375
|
"&-addon, &-wrap": {
|
|
376
376
|
display: "table-cell",
|
|
377
377
|
width: 1,
|
|
@@ -395,10 +395,10 @@ const Br = (e) => {
|
|
|
395
395
|
transition: `all ${e.motionDurationSlow}`,
|
|
396
396
|
lineHeight: 1,
|
|
397
397
|
// Reset Select's style in addon
|
|
398
|
-
[`${
|
|
398
|
+
[`${r}-select`]: {
|
|
399
399
|
margin: `${T(e.calc(e.paddingBlock).add(1).mul(-1).equal())} ${T(e.calc(e.paddingInline).mul(-1).equal())}`,
|
|
400
|
-
[`&${
|
|
401
|
-
[`${
|
|
400
|
+
[`&${r}-select-single:not(${r}-select-customize-input):not(${r}-pagination-size-changer)`]: {
|
|
401
|
+
[`${r}-select-selector`]: {
|
|
402
402
|
backgroundColor: "inherit",
|
|
403
403
|
border: `${T(e.lineWidth)} ${e.lineType} transparent`,
|
|
404
404
|
boxShadow: "none"
|
|
@@ -406,10 +406,10 @@ const Br = (e) => {
|
|
|
406
406
|
}
|
|
407
407
|
},
|
|
408
408
|
// https://github.com/ant-design/ant-design/issues/31333
|
|
409
|
-
[`${
|
|
409
|
+
[`${r}-cascader-picker`]: {
|
|
410
410
|
margin: `-9px ${T(e.calc(e.paddingInline).mul(-1).equal())}`,
|
|
411
411
|
backgroundColor: "transparent",
|
|
412
|
-
[`${
|
|
412
|
+
[`${r}-cascader-input`]: {
|
|
413
413
|
textAlign: "start",
|
|
414
414
|
border: 0,
|
|
415
415
|
boxShadow: "none"
|
|
@@ -417,7 +417,7 @@ const Br = (e) => {
|
|
|
417
417
|
}
|
|
418
418
|
}
|
|
419
419
|
},
|
|
420
|
-
[
|
|
420
|
+
[n]: {
|
|
421
421
|
width: "100%",
|
|
422
422
|
marginBottom: 0,
|
|
423
423
|
textAlign: "inherit",
|
|
@@ -429,58 +429,58 @@ const Br = (e) => {
|
|
|
429
429
|
"&:hover": {
|
|
430
430
|
zIndex: 1,
|
|
431
431
|
borderInlineEndWidth: 1,
|
|
432
|
-
[`${
|
|
432
|
+
[`${n}-search-with-button &`]: {
|
|
433
433
|
zIndex: 0
|
|
434
434
|
}
|
|
435
435
|
}
|
|
436
436
|
},
|
|
437
437
|
// Reset rounded corners
|
|
438
|
-
[`> ${
|
|
438
|
+
[`> ${n}:first-child, ${n}-group-addon:first-child`]: {
|
|
439
439
|
borderStartEndRadius: 0,
|
|
440
440
|
borderEndEndRadius: 0,
|
|
441
441
|
// Reset Select's style in addon
|
|
442
|
-
[`${
|
|
442
|
+
[`${r}-select ${r}-select-selector`]: {
|
|
443
443
|
borderStartEndRadius: 0,
|
|
444
444
|
borderEndEndRadius: 0
|
|
445
445
|
}
|
|
446
446
|
},
|
|
447
|
-
[`> ${
|
|
448
|
-
[`&:not(:first-child) ${
|
|
447
|
+
[`> ${n}-affix-wrapper`]: {
|
|
448
|
+
[`&:not(:first-child) ${n}`]: {
|
|
449
449
|
borderStartStartRadius: 0,
|
|
450
450
|
borderEndStartRadius: 0
|
|
451
451
|
},
|
|
452
|
-
[`&:not(:last-child) ${
|
|
452
|
+
[`&:not(:last-child) ${n}`]: {
|
|
453
453
|
borderStartEndRadius: 0,
|
|
454
454
|
borderEndEndRadius: 0
|
|
455
455
|
}
|
|
456
456
|
},
|
|
457
|
-
[`> ${
|
|
457
|
+
[`> ${n}:last-child, ${n}-group-addon:last-child`]: {
|
|
458
458
|
borderStartStartRadius: 0,
|
|
459
459
|
borderEndStartRadius: 0,
|
|
460
460
|
// Reset Select's style in addon
|
|
461
|
-
[`${
|
|
461
|
+
[`${r}-select ${r}-select-selector`]: {
|
|
462
462
|
borderStartStartRadius: 0,
|
|
463
463
|
borderEndStartRadius: 0
|
|
464
464
|
}
|
|
465
465
|
},
|
|
466
|
-
[`${
|
|
466
|
+
[`${n}-affix-wrapper`]: {
|
|
467
467
|
"&:not(:last-child)": {
|
|
468
468
|
borderStartEndRadius: 0,
|
|
469
469
|
borderEndEndRadius: 0,
|
|
470
|
-
[`${
|
|
470
|
+
[`${n}-search &`]: {
|
|
471
471
|
borderStartStartRadius: e.borderRadius,
|
|
472
472
|
borderEndStartRadius: e.borderRadius
|
|
473
473
|
}
|
|
474
474
|
},
|
|
475
|
-
[`&:not(:first-child), ${
|
|
475
|
+
[`&:not(:first-child), ${n}-search &:not(:first-child)`]: {
|
|
476
476
|
borderStartStartRadius: 0,
|
|
477
477
|
borderEndStartRadius: 0
|
|
478
478
|
}
|
|
479
479
|
},
|
|
480
|
-
[`&${
|
|
480
|
+
[`&${n}-group-compact`]: Object.assign(Object.assign({
|
|
481
481
|
display: "block"
|
|
482
|
-
},
|
|
483
|
-
[`${
|
|
482
|
+
}, Cn()), {
|
|
483
|
+
[`${n}-group-addon, ${n}-group-wrap, > ${n}`]: {
|
|
484
484
|
"&:not(:first-child):not(:last-child)": {
|
|
485
485
|
borderInlineEndWidth: e.lineWidth,
|
|
486
486
|
"&:hover, &:focus": {
|
|
@@ -496,9 +496,9 @@ const Br = (e) => {
|
|
|
496
496
|
borderRadius: 0
|
|
497
497
|
},
|
|
498
498
|
[`
|
|
499
|
-
& > ${
|
|
500
|
-
& > ${
|
|
501
|
-
& > ${
|
|
499
|
+
& > ${n}-affix-wrapper,
|
|
500
|
+
& > ${n}-number-affix-wrapper,
|
|
501
|
+
& > ${r}-picker-range
|
|
502
502
|
`]: {
|
|
503
503
|
display: "inline-flex"
|
|
504
504
|
},
|
|
@@ -507,59 +507,59 @@ const Br = (e) => {
|
|
|
507
507
|
borderInlineEndWidth: e.lineWidth
|
|
508
508
|
},
|
|
509
509
|
// Undo float for .ant-input-group .ant-input
|
|
510
|
-
[
|
|
510
|
+
[n]: {
|
|
511
511
|
float: "none"
|
|
512
512
|
},
|
|
513
513
|
// reset border for Select, DatePicker, AutoComplete, Cascader, Mention, TimePicker, Input
|
|
514
|
-
[`& > ${
|
|
515
|
-
& > ${
|
|
516
|
-
& > ${
|
|
517
|
-
& > ${
|
|
514
|
+
[`& > ${r}-select > ${r}-select-selector,
|
|
515
|
+
& > ${r}-select-auto-complete ${n},
|
|
516
|
+
& > ${r}-cascader-picker ${n},
|
|
517
|
+
& > ${n}-group-wrapper ${n}`]: {
|
|
518
518
|
borderInlineEndWidth: e.lineWidth,
|
|
519
519
|
borderRadius: 0,
|
|
520
520
|
"&:hover, &:focus": {
|
|
521
521
|
zIndex: 1
|
|
522
522
|
}
|
|
523
523
|
},
|
|
524
|
-
[`& > ${
|
|
524
|
+
[`& > ${r}-select-focused`]: {
|
|
525
525
|
zIndex: 1
|
|
526
526
|
},
|
|
527
527
|
// update z-index for arrow icon
|
|
528
|
-
[`& > ${
|
|
528
|
+
[`& > ${r}-select > ${r}-select-arrow`]: {
|
|
529
529
|
zIndex: 1
|
|
530
530
|
// https://github.com/ant-design/ant-design/issues/20371
|
|
531
531
|
},
|
|
532
532
|
[`& > *:first-child,
|
|
533
|
-
& > ${
|
|
534
|
-
& > ${
|
|
535
|
-
& > ${
|
|
533
|
+
& > ${r}-select:first-child > ${r}-select-selector,
|
|
534
|
+
& > ${r}-select-auto-complete:first-child ${n},
|
|
535
|
+
& > ${r}-cascader-picker:first-child ${n}`]: {
|
|
536
536
|
borderStartStartRadius: e.borderRadius,
|
|
537
537
|
borderEndStartRadius: e.borderRadius
|
|
538
538
|
},
|
|
539
539
|
[`& > *:last-child,
|
|
540
|
-
& > ${
|
|
541
|
-
& > ${
|
|
542
|
-
& > ${
|
|
540
|
+
& > ${r}-select:last-child > ${r}-select-selector,
|
|
541
|
+
& > ${r}-cascader-picker:last-child ${n},
|
|
542
|
+
& > ${r}-cascader-picker-focused:last-child ${n}`]: {
|
|
543
543
|
borderInlineEndWidth: e.lineWidth,
|
|
544
544
|
borderStartEndRadius: e.borderRadius,
|
|
545
545
|
borderEndEndRadius: e.borderRadius
|
|
546
546
|
},
|
|
547
547
|
// https://github.com/ant-design/ant-design/issues/12493
|
|
548
|
-
[`& > ${
|
|
548
|
+
[`& > ${r}-select-auto-complete ${n}`]: {
|
|
549
549
|
verticalAlign: "top"
|
|
550
550
|
},
|
|
551
|
-
[`${
|
|
551
|
+
[`${n}-group-wrapper + ${n}-group-wrapper`]: {
|
|
552
552
|
marginInlineStart: e.calc(e.lineWidth).mul(-1).equal(),
|
|
553
|
-
[`${
|
|
553
|
+
[`${n}-affix-wrapper`]: {
|
|
554
554
|
borderRadius: 0
|
|
555
555
|
}
|
|
556
556
|
},
|
|
557
|
-
[`${
|
|
558
|
-
[`&${
|
|
559
|
-
[`& > ${
|
|
557
|
+
[`${n}-group-wrapper:not(:last-child)`]: {
|
|
558
|
+
[`&${n}-search > ${n}-group`]: {
|
|
559
|
+
[`& > ${n}-group-addon > ${n}-search-button`]: {
|
|
560
560
|
borderRadius: 0
|
|
561
561
|
},
|
|
562
|
-
[`& > ${
|
|
562
|
+
[`& > ${n}`]: {
|
|
563
563
|
borderStartStartRadius: e.borderRadius,
|
|
564
564
|
borderStartEndRadius: 0,
|
|
565
565
|
borderEndEndRadius: 0,
|
|
@@ -569,22 +569,22 @@ const Br = (e) => {
|
|
|
569
569
|
}
|
|
570
570
|
})
|
|
571
571
|
};
|
|
572
|
-
},
|
|
572
|
+
}, Pn = (e) => {
|
|
573
573
|
const {
|
|
574
|
-
componentCls:
|
|
575
|
-
controlHeightSM:
|
|
576
|
-
lineWidth:
|
|
577
|
-
calc:
|
|
578
|
-
} = e,
|
|
574
|
+
componentCls: n,
|
|
575
|
+
controlHeightSM: r,
|
|
576
|
+
lineWidth: t,
|
|
577
|
+
calc: a
|
|
578
|
+
} = e, i = a(r).sub(a(t).mul(2)).sub(16).div(2).equal();
|
|
579
579
|
return {
|
|
580
|
-
[
|
|
580
|
+
[n]: Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, Qe(e)), cn(e)), Nn(e)), Fn(e)), Tn(e)), {
|
|
581
581
|
'&[type="color"]': {
|
|
582
582
|
height: e.controlHeight,
|
|
583
|
-
[`&${
|
|
583
|
+
[`&${n}-lg`]: {
|
|
584
584
|
height: e.controlHeightLG
|
|
585
585
|
},
|
|
586
|
-
[`&${
|
|
587
|
-
height:
|
|
586
|
+
[`&${n}-sm`]: {
|
|
587
|
+
height: r,
|
|
588
588
|
paddingTop: i,
|
|
589
589
|
paddingBottom: i
|
|
590
590
|
}
|
|
@@ -594,13 +594,13 @@ const Br = (e) => {
|
|
|
594
594
|
}
|
|
595
595
|
})
|
|
596
596
|
};
|
|
597
|
-
},
|
|
597
|
+
}, Dn = (e) => {
|
|
598
598
|
const {
|
|
599
|
-
componentCls:
|
|
599
|
+
componentCls: n
|
|
600
600
|
} = e;
|
|
601
601
|
return {
|
|
602
602
|
// ========================= Input =========================
|
|
603
|
-
[`${
|
|
603
|
+
[`${n}-clear-icon`]: {
|
|
604
604
|
margin: 0,
|
|
605
605
|
padding: 0,
|
|
606
606
|
lineHeight: 0,
|
|
@@ -628,32 +628,32 @@ const Br = (e) => {
|
|
|
628
628
|
}
|
|
629
629
|
}
|
|
630
630
|
};
|
|
631
|
-
},
|
|
631
|
+
}, Mn = (e) => {
|
|
632
632
|
const {
|
|
633
|
-
componentCls:
|
|
634
|
-
inputAffixPadding:
|
|
635
|
-
colorTextDescription:
|
|
636
|
-
motionDurationSlow:
|
|
637
|
-
colorIcon:
|
|
633
|
+
componentCls: n,
|
|
634
|
+
inputAffixPadding: r,
|
|
635
|
+
colorTextDescription: t,
|
|
636
|
+
motionDurationSlow: a,
|
|
637
|
+
colorIcon: s,
|
|
638
638
|
colorIconHover: i,
|
|
639
639
|
iconCls: l
|
|
640
|
-
} = e, S = `${
|
|
640
|
+
} = e, S = `${n}-affix-wrapper`, g = `${n}-affix-wrapper-disabled`;
|
|
641
641
|
return {
|
|
642
|
-
[S]: Object.assign(Object.assign(Object.assign(Object.assign({},
|
|
642
|
+
[S]: Object.assign(Object.assign(Object.assign(Object.assign({}, cn(e)), {
|
|
643
643
|
display: "inline-flex",
|
|
644
|
-
[`&:not(${
|
|
644
|
+
[`&:not(${n}-disabled):hover`]: {
|
|
645
645
|
zIndex: 1,
|
|
646
|
-
[`${
|
|
646
|
+
[`${n}-search-with-button &`]: {
|
|
647
647
|
zIndex: 0
|
|
648
648
|
}
|
|
649
649
|
},
|
|
650
650
|
"&-focused, &:focus": {
|
|
651
651
|
zIndex: 1
|
|
652
652
|
},
|
|
653
|
-
[`> input${
|
|
653
|
+
[`> input${n}`]: {
|
|
654
654
|
padding: 0
|
|
655
655
|
},
|
|
656
|
-
[`> input${
|
|
656
|
+
[`> input${n}, > textarea${n}`]: {
|
|
657
657
|
fontSize: "inherit",
|
|
658
658
|
border: "none",
|
|
659
659
|
borderRadius: 0,
|
|
@@ -673,7 +673,7 @@ const Br = (e) => {
|
|
|
673
673
|
visibility: "hidden",
|
|
674
674
|
content: '"\\a0"'
|
|
675
675
|
},
|
|
676
|
-
[
|
|
676
|
+
[n]: {
|
|
677
677
|
"&-prefix, &-suffix": {
|
|
678
678
|
display: "flex",
|
|
679
679
|
flex: "none",
|
|
@@ -683,24 +683,24 @@ const Br = (e) => {
|
|
|
683
683
|
}
|
|
684
684
|
},
|
|
685
685
|
"&-show-count-suffix": {
|
|
686
|
-
color:
|
|
686
|
+
color: t
|
|
687
687
|
},
|
|
688
688
|
"&-show-count-has-suffix": {
|
|
689
689
|
marginInlineEnd: e.paddingXXS
|
|
690
690
|
},
|
|
691
691
|
"&-prefix": {
|
|
692
|
-
marginInlineEnd:
|
|
692
|
+
marginInlineEnd: r
|
|
693
693
|
},
|
|
694
694
|
"&-suffix": {
|
|
695
|
-
marginInlineStart:
|
|
695
|
+
marginInlineStart: r
|
|
696
696
|
}
|
|
697
697
|
}
|
|
698
|
-
}),
|
|
698
|
+
}), Dn(e)), {
|
|
699
699
|
// password
|
|
700
|
-
[`${l}${
|
|
701
|
-
color:
|
|
700
|
+
[`${l}${n}-password-icon`]: {
|
|
701
|
+
color: s,
|
|
702
702
|
cursor: "pointer",
|
|
703
|
-
transition: `all ${
|
|
703
|
+
transition: `all ${a}`,
|
|
704
704
|
"&:hover": {
|
|
705
705
|
color: i
|
|
706
706
|
}
|
|
@@ -708,23 +708,23 @@ const Br = (e) => {
|
|
|
708
708
|
}),
|
|
709
709
|
[g]: {
|
|
710
710
|
// password disabled
|
|
711
|
-
[`${l}${
|
|
712
|
-
color:
|
|
711
|
+
[`${l}${n}-password-icon`]: {
|
|
712
|
+
color: s,
|
|
713
713
|
cursor: "not-allowed",
|
|
714
714
|
"&:hover": {
|
|
715
|
-
color:
|
|
715
|
+
color: s
|
|
716
716
|
}
|
|
717
717
|
}
|
|
718
718
|
}
|
|
719
719
|
};
|
|
720
|
-
},
|
|
720
|
+
}, Ln = (e) => {
|
|
721
721
|
const {
|
|
722
|
-
componentCls:
|
|
723
|
-
borderRadiusLG:
|
|
724
|
-
borderRadiusSM:
|
|
722
|
+
componentCls: n,
|
|
723
|
+
borderRadiusLG: r,
|
|
724
|
+
borderRadiusSM: t
|
|
725
725
|
} = e;
|
|
726
726
|
return {
|
|
727
|
-
[`${
|
|
727
|
+
[`${n}-group`]: Object.assign(Object.assign(Object.assign({}, Qe(e)), Hn(e)), {
|
|
728
728
|
"&-rtl": {
|
|
729
729
|
direction: "rtl"
|
|
730
730
|
},
|
|
@@ -738,17 +738,17 @@ const Br = (e) => {
|
|
|
738
738
|
},
|
|
739
739
|
// Size
|
|
740
740
|
"&-lg": {
|
|
741
|
-
[`${
|
|
742
|
-
borderRadius:
|
|
741
|
+
[`${n}-group-addon`]: {
|
|
742
|
+
borderRadius: r,
|
|
743
743
|
fontSize: e.inputFontSizeLG
|
|
744
744
|
}
|
|
745
745
|
},
|
|
746
746
|
"&-sm": {
|
|
747
|
-
[`${
|
|
748
|
-
borderRadius:
|
|
747
|
+
[`${n}-group-addon`]: {
|
|
748
|
+
borderRadius: t
|
|
749
749
|
}
|
|
750
750
|
}
|
|
751
|
-
},
|
|
751
|
+
}, jn(e)), Wn(e)), {
|
|
752
752
|
// '&-disabled': {
|
|
753
753
|
// [`${componentCls}-group-addon`]: {
|
|
754
754
|
// ...genDisabledStyle(token),
|
|
@@ -756,35 +756,35 @@ const Br = (e) => {
|
|
|
756
756
|
// },
|
|
757
757
|
// Fix the issue of using icons in Space Compact mode
|
|
758
758
|
// https://github.com/ant-design/ant-design/issues/42122
|
|
759
|
-
[`&:not(${
|
|
760
|
-
[`${
|
|
759
|
+
[`&:not(${n}-compact-first-item):not(${n}-compact-last-item)${n}-compact-item`]: {
|
|
760
|
+
[`${n}, ${n}-group-addon`]: {
|
|
761
761
|
borderRadius: 0
|
|
762
762
|
}
|
|
763
763
|
},
|
|
764
|
-
[`&:not(${
|
|
765
|
-
[`${
|
|
764
|
+
[`&:not(${n}-compact-last-item)${n}-compact-first-item`]: {
|
|
765
|
+
[`${n}, ${n}-group-addon`]: {
|
|
766
766
|
borderStartEndRadius: 0,
|
|
767
767
|
borderEndEndRadius: 0
|
|
768
768
|
}
|
|
769
769
|
},
|
|
770
|
-
[`&:not(${
|
|
771
|
-
[`${
|
|
770
|
+
[`&:not(${n}-compact-first-item)${n}-compact-last-item`]: {
|
|
771
|
+
[`${n}, ${n}-group-addon`]: {
|
|
772
772
|
borderStartStartRadius: 0,
|
|
773
773
|
borderEndStartRadius: 0
|
|
774
774
|
}
|
|
775
775
|
},
|
|
776
776
|
// Fix the issue of input use show-count param in space compact mode
|
|
777
777
|
// https://github.com/ant-design/ant-design/issues/46872
|
|
778
|
-
[`&:not(${
|
|
779
|
-
[`${
|
|
778
|
+
[`&:not(${n}-compact-last-item)${n}-compact-item`]: {
|
|
779
|
+
[`${n}-affix-wrapper`]: {
|
|
780
780
|
borderStartEndRadius: 0,
|
|
781
781
|
borderEndEndRadius: 0
|
|
782
782
|
}
|
|
783
783
|
},
|
|
784
784
|
// Fix the issue of input use `addonAfter` param in space compact mode
|
|
785
785
|
// https://github.com/ant-design/ant-design/issues/52483
|
|
786
|
-
[`&:not(${
|
|
787
|
-
[`${
|
|
786
|
+
[`&:not(${n}-compact-first-item)${n}-compact-item`]: {
|
|
787
|
+
[`${n}-affix-wrapper`]: {
|
|
788
788
|
borderStartStartRadius: 0,
|
|
789
789
|
borderEndStartRadius: 0
|
|
790
790
|
}
|
|
@@ -792,42 +792,42 @@ const Br = (e) => {
|
|
|
792
792
|
})
|
|
793
793
|
})
|
|
794
794
|
};
|
|
795
|
-
},
|
|
795
|
+
}, Vn = (e) => {
|
|
796
796
|
const {
|
|
797
|
-
componentCls:
|
|
798
|
-
antCls:
|
|
799
|
-
} = e,
|
|
797
|
+
componentCls: n,
|
|
798
|
+
antCls: r
|
|
799
|
+
} = e, t = `${n}-search`;
|
|
800
800
|
return {
|
|
801
|
-
[
|
|
802
|
-
[
|
|
801
|
+
[t]: {
|
|
802
|
+
[n]: {
|
|
803
803
|
"&:hover, &:focus": {
|
|
804
|
-
[`+ ${
|
|
804
|
+
[`+ ${n}-group-addon ${t}-button:not(${r}-btn-primary)`]: {
|
|
805
805
|
borderInlineStartColor: e.colorPrimaryHover
|
|
806
806
|
}
|
|
807
807
|
}
|
|
808
808
|
},
|
|
809
|
-
[`${
|
|
809
|
+
[`${n}-affix-wrapper`]: {
|
|
810
810
|
height: e.controlHeight,
|
|
811
811
|
borderRadius: 0
|
|
812
812
|
},
|
|
813
813
|
// fix slight height diff in Firefox:
|
|
814
814
|
// https://ant.design/components/auto-complete-cn/#auto-complete-demo-certain-category
|
|
815
|
-
[`${
|
|
815
|
+
[`${n}-lg`]: {
|
|
816
816
|
lineHeight: e.calc(e.lineHeightLG).sub(2e-4).equal()
|
|
817
817
|
},
|
|
818
|
-
[`> ${
|
|
819
|
-
[`> ${
|
|
818
|
+
[`> ${n}-group`]: {
|
|
819
|
+
[`> ${n}-group-addon:last-child`]: {
|
|
820
820
|
insetInlineStart: -1,
|
|
821
821
|
padding: 0,
|
|
822
822
|
border: 0,
|
|
823
|
-
[`${
|
|
823
|
+
[`${t}-button`]: {
|
|
824
824
|
// Fix https://github.com/ant-design/ant-design/issues/47150
|
|
825
825
|
marginInlineEnd: -1,
|
|
826
826
|
borderStartStartRadius: 0,
|
|
827
827
|
borderEndStartRadius: 0,
|
|
828
828
|
boxShadow: "none"
|
|
829
829
|
},
|
|
830
|
-
[`${
|
|
830
|
+
[`${t}-button:not(${r}-btn-primary)`]: {
|
|
831
831
|
color: e.colorTextDescription,
|
|
832
832
|
"&:hover": {
|
|
833
833
|
color: e.colorPrimaryHover
|
|
@@ -835,7 +835,7 @@ const Br = (e) => {
|
|
|
835
835
|
"&:active": {
|
|
836
836
|
color: e.colorPrimaryActive
|
|
837
837
|
},
|
|
838
|
-
[`&${
|
|
838
|
+
[`&${r}-btn-loading::before`]: {
|
|
839
839
|
insetInlineStart: 0,
|
|
840
840
|
insetInlineEnd: 0,
|
|
841
841
|
insetBlockStart: 0,
|
|
@@ -844,19 +844,19 @@ const Br = (e) => {
|
|
|
844
844
|
}
|
|
845
845
|
}
|
|
846
846
|
},
|
|
847
|
-
[`${
|
|
847
|
+
[`${t}-button`]: {
|
|
848
848
|
height: e.controlHeight,
|
|
849
849
|
"&:hover, &:focus": {
|
|
850
850
|
zIndex: 1
|
|
851
851
|
}
|
|
852
852
|
},
|
|
853
853
|
"&-large": {
|
|
854
|
-
[`${
|
|
854
|
+
[`${n}-affix-wrapper, ${t}-button`]: {
|
|
855
855
|
height: e.controlHeightLG
|
|
856
856
|
}
|
|
857
857
|
},
|
|
858
858
|
"&-small": {
|
|
859
|
-
[`${
|
|
859
|
+
[`${n}-affix-wrapper, ${t}-button`]: {
|
|
860
860
|
height: e.controlHeightSM
|
|
861
861
|
}
|
|
862
862
|
},
|
|
@@ -864,47 +864,47 @@ const Br = (e) => {
|
|
|
864
864
|
direction: "rtl"
|
|
865
865
|
},
|
|
866
866
|
// ===================== Compact Item Customized Styles =====================
|
|
867
|
-
[`&${
|
|
868
|
-
[`&:not(${
|
|
869
|
-
[`${
|
|
870
|
-
[`${
|
|
867
|
+
[`&${n}-compact-item`]: {
|
|
868
|
+
[`&:not(${n}-compact-last-item)`]: {
|
|
869
|
+
[`${n}-group-addon`]: {
|
|
870
|
+
[`${n}-search-button`]: {
|
|
871
871
|
marginInlineEnd: e.calc(e.lineWidth).mul(-1).equal(),
|
|
872
872
|
borderRadius: 0
|
|
873
873
|
}
|
|
874
874
|
}
|
|
875
875
|
},
|
|
876
|
-
[`&:not(${
|
|
877
|
-
[`${
|
|
876
|
+
[`&:not(${n}-compact-first-item)`]: {
|
|
877
|
+
[`${n},${n}-affix-wrapper`]: {
|
|
878
878
|
borderRadius: 0
|
|
879
879
|
}
|
|
880
880
|
},
|
|
881
|
-
[`> ${
|
|
882
|
-
> ${
|
|
883
|
-
${
|
|
881
|
+
[`> ${n}-group-addon ${n}-search-button,
|
|
882
|
+
> ${n},
|
|
883
|
+
${n}-affix-wrapper`]: {
|
|
884
884
|
"&:hover, &:focus, &:active": {
|
|
885
885
|
zIndex: 2
|
|
886
886
|
}
|
|
887
887
|
},
|
|
888
|
-
[`> ${
|
|
888
|
+
[`> ${n}-affix-wrapper-focused`]: {
|
|
889
889
|
zIndex: 2
|
|
890
890
|
}
|
|
891
891
|
}
|
|
892
892
|
}
|
|
893
893
|
};
|
|
894
|
-
},
|
|
894
|
+
}, Gn = (e) => {
|
|
895
895
|
const {
|
|
896
|
-
componentCls:
|
|
897
|
-
paddingLG:
|
|
898
|
-
} = e,
|
|
896
|
+
componentCls: n,
|
|
897
|
+
paddingLG: r
|
|
898
|
+
} = e, t = `${n}-textarea`;
|
|
899
899
|
return {
|
|
900
|
-
[
|
|
900
|
+
[t]: {
|
|
901
901
|
position: "relative",
|
|
902
902
|
"&-show-count": {
|
|
903
903
|
// https://github.com/ant-design/ant-design/issues/33049
|
|
904
|
-
[`> ${
|
|
904
|
+
[`> ${n}`]: {
|
|
905
905
|
height: "100%"
|
|
906
906
|
},
|
|
907
|
-
[`${
|
|
907
|
+
[`${n}-data-count`]: {
|
|
908
908
|
position: "absolute",
|
|
909
909
|
bottom: e.calc(e.fontSize).mul(e.lineHeight).mul(-1).equal(),
|
|
910
910
|
insetInlineEnd: 0,
|
|
@@ -914,14 +914,14 @@ const Br = (e) => {
|
|
|
914
914
|
}
|
|
915
915
|
},
|
|
916
916
|
[`
|
|
917
|
-
&-allow-clear > ${
|
|
918
|
-
&-affix-wrapper${
|
|
917
|
+
&-allow-clear > ${n},
|
|
918
|
+
&-affix-wrapper${t}-has-feedback ${n}
|
|
919
919
|
`]: {
|
|
920
|
-
paddingInlineEnd:
|
|
920
|
+
paddingInlineEnd: r
|
|
921
921
|
},
|
|
922
|
-
[`&-affix-wrapper${
|
|
922
|
+
[`&-affix-wrapper${n}-affix-wrapper`]: {
|
|
923
923
|
padding: 0,
|
|
924
|
-
[`> textarea${
|
|
924
|
+
[`> textarea${n}`]: {
|
|
925
925
|
fontSize: "inherit",
|
|
926
926
|
border: "none",
|
|
927
927
|
outline: "none",
|
|
@@ -930,19 +930,19 @@ const Br = (e) => {
|
|
|
930
930
|
boxShadow: "none !important"
|
|
931
931
|
}
|
|
932
932
|
},
|
|
933
|
-
[`${
|
|
933
|
+
[`${n}-suffix`]: {
|
|
934
934
|
margin: 0,
|
|
935
935
|
"> *:not(:last-child)": {
|
|
936
936
|
marginInline: 0
|
|
937
937
|
},
|
|
938
938
|
// Clear Icon
|
|
939
|
-
[`${
|
|
939
|
+
[`${n}-clear-icon`]: {
|
|
940
940
|
position: "absolute",
|
|
941
941
|
insetInlineEnd: e.paddingInline,
|
|
942
942
|
insetBlockStart: e.paddingXS
|
|
943
943
|
},
|
|
944
944
|
// Feedback Icon
|
|
945
|
-
[`${
|
|
945
|
+
[`${t}-suffix`]: {
|
|
946
946
|
position: "absolute",
|
|
947
947
|
top: 0,
|
|
948
948
|
insetInlineEnd: e.paddingInline,
|
|
@@ -955,112 +955,112 @@ const Br = (e) => {
|
|
|
955
955
|
}
|
|
956
956
|
}
|
|
957
957
|
},
|
|
958
|
-
[`&-affix-wrapper${
|
|
959
|
-
[`${
|
|
960
|
-
[`${
|
|
958
|
+
[`&-affix-wrapper${n}-affix-wrapper-sm`]: {
|
|
959
|
+
[`${n}-suffix`]: {
|
|
960
|
+
[`${n}-clear-icon`]: {
|
|
961
961
|
insetInlineEnd: e.paddingInlineSM
|
|
962
962
|
}
|
|
963
963
|
}
|
|
964
964
|
}
|
|
965
965
|
}
|
|
966
966
|
};
|
|
967
|
-
},
|
|
967
|
+
}, Kn = (e) => {
|
|
968
968
|
const {
|
|
969
|
-
componentCls:
|
|
969
|
+
componentCls: n
|
|
970
970
|
} = e;
|
|
971
971
|
return {
|
|
972
|
-
[`${
|
|
973
|
-
[`&, & input, & textarea, ${
|
|
972
|
+
[`${n}-out-of-range`]: {
|
|
973
|
+
[`&, & input, & textarea, ${n}-show-count-suffix, ${n}-data-count`]: {
|
|
974
974
|
color: e.colorError
|
|
975
975
|
}
|
|
976
976
|
}
|
|
977
977
|
};
|
|
978
|
-
},
|
|
979
|
-
const
|
|
978
|
+
}, fn = $n("Input", (e) => {
|
|
979
|
+
const n = He(e, On(e));
|
|
980
980
|
return [
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
981
|
+
Pn(n),
|
|
982
|
+
Gn(n),
|
|
983
|
+
Mn(n),
|
|
984
|
+
Ln(n),
|
|
985
|
+
Vn(n),
|
|
986
|
+
Kn(n),
|
|
987
987
|
// =====================================================
|
|
988
988
|
// == Space Compact ==
|
|
989
989
|
// =====================================================
|
|
990
|
-
|
|
990
|
+
zn(n)
|
|
991
991
|
];
|
|
992
|
-
},
|
|
992
|
+
}, Bn, {
|
|
993
993
|
resetFont: !1
|
|
994
994
|
});
|
|
995
|
-
function
|
|
995
|
+
function Xn(e) {
|
|
996
996
|
return !!(e.addonBefore || e.addonAfter);
|
|
997
997
|
}
|
|
998
|
-
function
|
|
998
|
+
function qn(e) {
|
|
999
999
|
return !!(e.prefix || e.suffix || e.allowClear);
|
|
1000
1000
|
}
|
|
1001
|
-
function Ye(e,
|
|
1002
|
-
var
|
|
1001
|
+
function Ye(e, n, r) {
|
|
1002
|
+
var t = n.cloneNode(!0), a = Object.create(e, {
|
|
1003
1003
|
target: {
|
|
1004
|
-
value:
|
|
1004
|
+
value: t
|
|
1005
1005
|
},
|
|
1006
1006
|
currentTarget: {
|
|
1007
|
-
value:
|
|
1007
|
+
value: t
|
|
1008
1008
|
}
|
|
1009
1009
|
});
|
|
1010
|
-
return
|
|
1011
|
-
|
|
1012
|
-
},
|
|
1010
|
+
return t.value = r, typeof n.selectionStart == "number" && typeof n.selectionEnd == "number" && (t.selectionStart = n.selectionStart, t.selectionEnd = n.selectionEnd), t.setSelectionRange = function() {
|
|
1011
|
+
n.setSelectionRange.apply(n, arguments);
|
|
1012
|
+
}, a;
|
|
1013
1013
|
}
|
|
1014
|
-
function Ee(e, r, t
|
|
1015
|
-
if (
|
|
1016
|
-
var
|
|
1017
|
-
if (
|
|
1018
|
-
|
|
1014
|
+
function Ee(e, n, r, t) {
|
|
1015
|
+
if (r) {
|
|
1016
|
+
var a = n;
|
|
1017
|
+
if (n.type === "click") {
|
|
1018
|
+
a = Ye(n, e, ""), r(a);
|
|
1019
1019
|
return;
|
|
1020
1020
|
}
|
|
1021
|
-
if (e.type !== "file" &&
|
|
1022
|
-
|
|
1021
|
+
if (e.type !== "file" && t !== void 0) {
|
|
1022
|
+
a = Ye(n, e, t), r(a);
|
|
1023
1023
|
return;
|
|
1024
1024
|
}
|
|
1025
|
-
|
|
1025
|
+
r(a);
|
|
1026
1026
|
}
|
|
1027
1027
|
}
|
|
1028
|
-
function
|
|
1028
|
+
function gn(e, n) {
|
|
1029
1029
|
if (e) {
|
|
1030
|
-
e.focus(
|
|
1031
|
-
var
|
|
1032
|
-
if (
|
|
1033
|
-
var
|
|
1034
|
-
switch (
|
|
1030
|
+
e.focus(n);
|
|
1031
|
+
var r = n || {}, t = r.cursor;
|
|
1032
|
+
if (t) {
|
|
1033
|
+
var a = e.value.length;
|
|
1034
|
+
switch (t) {
|
|
1035
1035
|
case "start":
|
|
1036
1036
|
e.setSelectionRange(0, 0);
|
|
1037
1037
|
break;
|
|
1038
1038
|
case "end":
|
|
1039
|
-
e.setSelectionRange(
|
|
1039
|
+
e.setSelectionRange(a, a);
|
|
1040
1040
|
break;
|
|
1041
1041
|
default:
|
|
1042
|
-
e.setSelectionRange(0,
|
|
1042
|
+
e.setSelectionRange(0, a);
|
|
1043
1043
|
}
|
|
1044
1044
|
}
|
|
1045
1045
|
}
|
|
1046
1046
|
}
|
|
1047
|
-
var
|
|
1048
|
-
var t, a,
|
|
1047
|
+
var pn = /* @__PURE__ */ f.forwardRef(function(e, n) {
|
|
1048
|
+
var r, t, a, s = e.inputElement, i = e.children, l = e.prefixCls, S = e.prefix, g = e.suffix, p = e.addonBefore, C = e.addonAfter, E = e.className, G = e.style, R = e.disabled, A = e.readOnly, re = e.focused, ee = e.triggerFocus, y = e.allowClear, o = e.value, Q = e.handleReset, $ = e.hidden, b = e.classes, d = e.classNames, u = e.dataAttrs, c = e.styles, I = e.components, F = e.onClear, h = i ?? s, D = (I == null ? void 0 : I.affixWrapper) || "span", te = (I == null ? void 0 : I.groupWrapper) || "span", W = (I == null ? void 0 : I.wrapper) || "span", v = (I == null ? void 0 : I.groupAddon) || "span", M = le(null), J = function(Y) {
|
|
1049
1049
|
var Z;
|
|
1050
1050
|
(Z = M.current) !== null && Z !== void 0 && Z.contains(Y.target) && (ee == null || ee());
|
|
1051
|
-
},
|
|
1052
|
-
value:
|
|
1053
|
-
className: w((
|
|
1051
|
+
}, ae = qn(e), z = /* @__PURE__ */ xn(h, {
|
|
1052
|
+
value: o,
|
|
1053
|
+
className: w((r = h.props) === null || r === void 0 ? void 0 : r.className, !ae && (d == null ? void 0 : d.variant)) || null
|
|
1054
1054
|
}), N = le(null);
|
|
1055
|
-
if (f.useImperativeHandle(
|
|
1055
|
+
if (f.useImperativeHandle(n, function() {
|
|
1056
1056
|
return {
|
|
1057
1057
|
nativeElement: N.current || M.current
|
|
1058
1058
|
};
|
|
1059
|
-
}),
|
|
1060
|
-
var
|
|
1059
|
+
}), ae) {
|
|
1060
|
+
var X = null;
|
|
1061
1061
|
if (y) {
|
|
1062
|
-
var _ = !R && !A &&
|
|
1063
|
-
|
|
1062
|
+
var _ = !R && !A && o, H = "".concat(l, "-clear-icon"), B = _e(y) === "object" && y !== null && y !== void 0 && y.clearIcon ? y.clearIcon : "✖";
|
|
1063
|
+
X = /* @__PURE__ */ f.createElement("button", {
|
|
1064
1064
|
type: "button",
|
|
1065
1065
|
onClick: function(Y) {
|
|
1066
1066
|
Q == null || Q(Y), F == null || F();
|
|
@@ -1071,123 +1071,123 @@ var gr = /* @__PURE__ */ f.forwardRef(function(e, r) {
|
|
|
1071
1071
|
className: w(H, ie(ie({}, "".concat(H, "-hidden"), !_), "".concat(H, "-has-suffix"), !!g))
|
|
1072
1072
|
}, B);
|
|
1073
1073
|
}
|
|
1074
|
-
var
|
|
1075
|
-
className: w("".concat(l, "-suffix"),
|
|
1076
|
-
style:
|
|
1077
|
-
},
|
|
1074
|
+
var q = "".concat(l, "-affix-wrapper"), se = w(q, ie(ie(ie(ie(ie({}, "".concat(l, "-disabled"), R), "".concat(q, "-disabled"), R), "".concat(q, "-focused"), re), "".concat(q, "-readonly"), A), "".concat(q, "-input-with-clear-btn"), g && y && o), b == null ? void 0 : b.affixWrapper, d == null ? void 0 : d.affixWrapper, d == null ? void 0 : d.variant), j = (g || y) && /* @__PURE__ */ f.createElement("span", {
|
|
1075
|
+
className: w("".concat(l, "-suffix"), d == null ? void 0 : d.suffix),
|
|
1076
|
+
style: c == null ? void 0 : c.suffix
|
|
1077
|
+
}, X, g);
|
|
1078
1078
|
z = /* @__PURE__ */ f.createElement(D, Ce({
|
|
1079
|
-
className:
|
|
1080
|
-
style:
|
|
1079
|
+
className: se,
|
|
1080
|
+
style: c == null ? void 0 : c.affixWrapper,
|
|
1081
1081
|
onClick: J
|
|
1082
|
-
},
|
|
1082
|
+
}, u == null ? void 0 : u.affixWrapper, {
|
|
1083
1083
|
ref: M
|
|
1084
1084
|
}), S && /* @__PURE__ */ f.createElement("span", {
|
|
1085
|
-
className: w("".concat(l, "-prefix"),
|
|
1086
|
-
style:
|
|
1085
|
+
className: w("".concat(l, "-prefix"), d == null ? void 0 : d.prefix),
|
|
1086
|
+
style: c == null ? void 0 : c.prefix
|
|
1087
1087
|
}, S), z, j);
|
|
1088
1088
|
}
|
|
1089
|
-
if (
|
|
1090
|
-
var k = "".concat(l, "-group"), U = "".concat(k, "-addon"),
|
|
1091
|
-
z = /* @__PURE__ */ f.createElement(
|
|
1089
|
+
if (Xn(e)) {
|
|
1090
|
+
var k = "".concat(l, "-group"), U = "".concat(k, "-addon"), ue = "".concat(k, "-wrapper"), ce = w("".concat(l, "-wrapper"), k, b == null ? void 0 : b.wrapper, d == null ? void 0 : d.wrapper), fe = w(ue, ie({}, "".concat(ue, "-disabled"), R), b == null ? void 0 : b.group, d == null ? void 0 : d.groupWrapper);
|
|
1091
|
+
z = /* @__PURE__ */ f.createElement(te, {
|
|
1092
1092
|
className: fe,
|
|
1093
1093
|
ref: N
|
|
1094
1094
|
}, /* @__PURE__ */ f.createElement(W, {
|
|
1095
|
-
className:
|
|
1096
|
-
}, p && /* @__PURE__ */ f.createElement(
|
|
1095
|
+
className: ce
|
|
1096
|
+
}, p && /* @__PURE__ */ f.createElement(v, {
|
|
1097
1097
|
className: U
|
|
1098
|
-
}, p), z, C && /* @__PURE__ */ f.createElement(
|
|
1098
|
+
}, p), z, C && /* @__PURE__ */ f.createElement(v, {
|
|
1099
1099
|
className: U
|
|
1100
1100
|
}, C)));
|
|
1101
1101
|
}
|
|
1102
1102
|
return /* @__PURE__ */ f.cloneElement(z, {
|
|
1103
|
-
className: w((
|
|
1104
|
-
style:
|
|
1103
|
+
className: w((t = z.props) === null || t === void 0 ? void 0 : t.className, E) || null,
|
|
1104
|
+
style: ne(ne({}, (a = z.props) === null || a === void 0 ? void 0 : a.style), G),
|
|
1105
1105
|
hidden: $
|
|
1106
1106
|
});
|
|
1107
|
-
}),
|
|
1108
|
-
function
|
|
1107
|
+
}), Un = ["show"];
|
|
1108
|
+
function mn(e, n) {
|
|
1109
1109
|
return K.useMemo(function() {
|
|
1110
|
-
var
|
|
1111
|
-
|
|
1112
|
-
var
|
|
1113
|
-
return
|
|
1114
|
-
show: !!
|
|
1115
|
-
showFormatter: typeof
|
|
1116
|
-
strategy:
|
|
1110
|
+
var r = {};
|
|
1111
|
+
n && (r.show = _e(n) === "object" && n.formatter ? n.formatter : !!n), r = ne(ne({}, r), e);
|
|
1112
|
+
var t = r, a = t.show, s = Re(t, Un);
|
|
1113
|
+
return ne(ne({}, s), {}, {
|
|
1114
|
+
show: !!a,
|
|
1115
|
+
showFormatter: typeof a == "function" ? a : void 0,
|
|
1116
|
+
strategy: s.strategy || function(i) {
|
|
1117
1117
|
return i.length;
|
|
1118
1118
|
}
|
|
1119
1119
|
});
|
|
1120
|
-
}, [e,
|
|
1120
|
+
}, [e, n]);
|
|
1121
1121
|
}
|
|
1122
|
-
var
|
|
1123
|
-
var
|
|
1124
|
-
|
|
1125
|
-
},
|
|
1122
|
+
var Yn = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKeyDown", "onKeyUp", "prefixCls", "disabled", "htmlSize", "className", "maxLength", "suffix", "showCount", "count", "type", "classes", "classNames", "styles", "onCompositionStart", "onCompositionEnd"], Zn = /* @__PURE__ */ We(function(e, n) {
|
|
1123
|
+
var r = e.autoComplete, t = e.onChange, a = e.onFocus, s = e.onBlur, i = e.onPressEnter, l = e.onKeyDown, S = e.onKeyUp, g = e.prefixCls, p = g === void 0 ? "rc-input" : g, C = e.disabled, E = e.htmlSize, G = e.className, R = e.maxLength, A = e.suffix, re = e.showCount, ee = e.count, y = e.type, o = y === void 0 ? "text" : y, Q = e.classes, $ = e.classNames, b = e.styles, d = e.onCompositionStart, u = e.onCompositionEnd, c = Re(e, Yn), I = Me(!1), F = de(I, 2), h = F[0], D = F[1], te = le(!1), W = le(!1), v = le(null), M = le(null), J = function(m) {
|
|
1124
|
+
v.current && gn(v.current, m);
|
|
1125
|
+
}, ae = Pe(e.defaultValue, {
|
|
1126
1126
|
value: e.value
|
|
1127
|
-
}), z =
|
|
1128
|
-
Ze(
|
|
1127
|
+
}), z = de(ae, 2), N = z[0], X = z[1], _ = N == null ? "" : String(N), H = Me(null), B = de(H, 2), q = B[0], se = B[1], j = mn(ee, re), k = j.max || R, U = j.strategy(_), ue = !!k && U > k;
|
|
1128
|
+
Ze(n, function() {
|
|
1129
1129
|
var O;
|
|
1130
1130
|
return {
|
|
1131
1131
|
focus: J,
|
|
1132
1132
|
blur: function() {
|
|
1133
1133
|
var L;
|
|
1134
|
-
(L =
|
|
1134
|
+
(L = v.current) === null || L === void 0 || L.blur();
|
|
1135
1135
|
},
|
|
1136
|
-
setSelectionRange: function(L,
|
|
1136
|
+
setSelectionRange: function(L, he, pe) {
|
|
1137
1137
|
var ge;
|
|
1138
|
-
(ge =
|
|
1138
|
+
(ge = v.current) === null || ge === void 0 || ge.setSelectionRange(L, he, pe);
|
|
1139
1139
|
},
|
|
1140
1140
|
select: function() {
|
|
1141
1141
|
var L;
|
|
1142
|
-
(L =
|
|
1142
|
+
(L = v.current) === null || L === void 0 || L.select();
|
|
1143
1143
|
},
|
|
1144
|
-
input:
|
|
1145
|
-
nativeElement: ((O = M.current) === null || O === void 0 ? void 0 : O.nativeElement) ||
|
|
1144
|
+
input: v.current,
|
|
1145
|
+
nativeElement: ((O = M.current) === null || O === void 0 ? void 0 : O.nativeElement) || v.current
|
|
1146
1146
|
};
|
|
1147
1147
|
}), $e(function() {
|
|
1148
1148
|
W.current && (W.current = !1), D(function(O) {
|
|
1149
1149
|
return O && C ? !1 : O;
|
|
1150
1150
|
});
|
|
1151
1151
|
}, [C]);
|
|
1152
|
-
var
|
|
1152
|
+
var ce = function(m, L, he) {
|
|
1153
1153
|
var pe = L;
|
|
1154
|
-
if (!
|
|
1154
|
+
if (!te.current && j.exceedFormatter && j.max && j.strategy(L) > j.max) {
|
|
1155
1155
|
if (pe = j.exceedFormatter(L, {
|
|
1156
1156
|
max: j.max
|
|
1157
1157
|
}), L !== pe) {
|
|
1158
|
-
var ge,
|
|
1159
|
-
|
|
1158
|
+
var ge, ve;
|
|
1159
|
+
se([((ge = v.current) === null || ge === void 0 ? void 0 : ge.selectionStart) || 0, ((ve = v.current) === null || ve === void 0 ? void 0 : ve.selectionEnd) || 0]);
|
|
1160
1160
|
}
|
|
1161
|
-
} else if (
|
|
1161
|
+
} else if (he.source === "compositionEnd")
|
|
1162
1162
|
return;
|
|
1163
|
-
|
|
1163
|
+
X(pe), v.current && Ee(v.current, m, t, pe);
|
|
1164
1164
|
};
|
|
1165
1165
|
$e(function() {
|
|
1166
|
-
if (
|
|
1166
|
+
if (q) {
|
|
1167
1167
|
var O;
|
|
1168
|
-
(O =
|
|
1168
|
+
(O = v.current) === null || O === void 0 || O.setSelectionRange.apply(O, Je(q));
|
|
1169
1169
|
}
|
|
1170
|
-
}, [
|
|
1171
|
-
var fe = function(
|
|
1172
|
-
|
|
1170
|
+
}, [q]);
|
|
1171
|
+
var fe = function(m) {
|
|
1172
|
+
ce(m, m.target.value, {
|
|
1173
1173
|
source: "change"
|
|
1174
1174
|
});
|
|
1175
|
-
}, P = function(
|
|
1176
|
-
|
|
1175
|
+
}, P = function(m) {
|
|
1176
|
+
te.current = !1, ce(m, m.currentTarget.value, {
|
|
1177
1177
|
source: "compositionEnd"
|
|
1178
|
-
}),
|
|
1179
|
-
}, Y = function(
|
|
1180
|
-
i &&
|
|
1181
|
-
}, Z = function(
|
|
1182
|
-
|
|
1183
|
-
},
|
|
1184
|
-
D(!0),
|
|
1185
|
-
}, Ie = function(
|
|
1186
|
-
W.current && (W.current = !1), D(!1),
|
|
1187
|
-
}, xe = function(
|
|
1188
|
-
|
|
1189
|
-
}, ze =
|
|
1190
|
-
var
|
|
1178
|
+
}), u == null || u(m);
|
|
1179
|
+
}, Y = function(m) {
|
|
1180
|
+
i && m.key === "Enter" && !W.current && (W.current = !0, i(m)), l == null || l(m);
|
|
1181
|
+
}, Z = function(m) {
|
|
1182
|
+
m.key === "Enter" && (W.current = !1), S == null || S(m);
|
|
1183
|
+
}, be = function(m) {
|
|
1184
|
+
D(!0), a == null || a(m);
|
|
1185
|
+
}, Ie = function(m) {
|
|
1186
|
+
W.current && (W.current = !1), D(!1), s == null || s(m);
|
|
1187
|
+
}, xe = function(m) {
|
|
1188
|
+
X(""), J(), v.current && Ee(v.current, m, t);
|
|
1189
|
+
}, ze = ue && "".concat(p, "-out-of-range"), ye = function() {
|
|
1190
|
+
var m = wn(e, [
|
|
1191
1191
|
"prefixCls",
|
|
1192
1192
|
"onPressEnter",
|
|
1193
1193
|
"addonBefore",
|
|
@@ -1207,87 +1207,85 @@ var Yr = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKe
|
|
|
1207
1207
|
"onClear"
|
|
1208
1208
|
]);
|
|
1209
1209
|
return /* @__PURE__ */ f.createElement("input", Ce({
|
|
1210
|
-
autoComplete:
|
|
1211
|
-
},
|
|
1210
|
+
autoComplete: r
|
|
1211
|
+
}, m, {
|
|
1212
1212
|
onChange: fe,
|
|
1213
|
-
onFocus:
|
|
1213
|
+
onFocus: be,
|
|
1214
1214
|
onBlur: Ie,
|
|
1215
1215
|
onKeyDown: Y,
|
|
1216
1216
|
onKeyUp: Z,
|
|
1217
1217
|
className: w(p, ie({}, "".concat(p, "-disabled"), C), $ == null ? void 0 : $.input),
|
|
1218
|
-
style:
|
|
1219
|
-
ref:
|
|
1218
|
+
style: b == null ? void 0 : b.input,
|
|
1219
|
+
ref: v,
|
|
1220
1220
|
size: E,
|
|
1221
|
-
type:
|
|
1222
|
-
onCompositionStart: function(
|
|
1223
|
-
|
|
1221
|
+
type: o,
|
|
1222
|
+
onCompositionStart: function(he) {
|
|
1223
|
+
te.current = !0, d == null || d(he);
|
|
1224
1224
|
},
|
|
1225
1225
|
onCompositionEnd: P
|
|
1226
1226
|
}));
|
|
1227
1227
|
}, Oe = function() {
|
|
1228
|
-
var
|
|
1228
|
+
var m = Number(k) > 0;
|
|
1229
1229
|
if (A || j.show) {
|
|
1230
1230
|
var L = j.showFormatter ? j.showFormatter({
|
|
1231
1231
|
value: _,
|
|
1232
1232
|
count: U,
|
|
1233
1233
|
maxLength: k
|
|
1234
|
-
}) : "".concat(U).concat(
|
|
1234
|
+
}) : "".concat(U).concat(m ? " / ".concat(k) : "");
|
|
1235
1235
|
return /* @__PURE__ */ f.createElement(f.Fragment, null, j.show && /* @__PURE__ */ f.createElement("span", {
|
|
1236
1236
|
className: w("".concat(p, "-show-count-suffix"), ie({}, "".concat(p, "-show-count-has-suffix"), !!A), $ == null ? void 0 : $.count),
|
|
1237
|
-
style:
|
|
1237
|
+
style: ne({}, b == null ? void 0 : b.count)
|
|
1238
1238
|
}, L), A);
|
|
1239
1239
|
}
|
|
1240
1240
|
return null;
|
|
1241
1241
|
};
|
|
1242
|
-
return /* @__PURE__ */ f.createElement(
|
|
1242
|
+
return /* @__PURE__ */ f.createElement(pn, Ce({}, c, {
|
|
1243
1243
|
prefixCls: p,
|
|
1244
1244
|
className: w(G, ze),
|
|
1245
1245
|
handleReset: xe,
|
|
1246
1246
|
value: _,
|
|
1247
|
-
focused:
|
|
1247
|
+
focused: h,
|
|
1248
1248
|
triggerFocus: J,
|
|
1249
1249
|
suffix: Oe(),
|
|
1250
1250
|
disabled: C,
|
|
1251
1251
|
classes: Q,
|
|
1252
1252
|
classNames: $,
|
|
1253
|
-
styles:
|
|
1253
|
+
styles: b
|
|
1254
1254
|
}), ye());
|
|
1255
1255
|
});
|
|
1256
|
-
const
|
|
1257
|
-
let
|
|
1258
|
-
return typeof e == "object" && (e != null && e.clearIcon) ?
|
|
1259
|
-
clearIcon: /* @__PURE__ */ f.createElement(
|
|
1260
|
-
}),
|
|
1261
|
-
}
|
|
1262
|
-
function
|
|
1263
|
-
const
|
|
1264
|
-
|
|
1265
|
-
var
|
|
1266
|
-
!((
|
|
1256
|
+
const bn = (e) => {
|
|
1257
|
+
let n;
|
|
1258
|
+
return typeof e == "object" && (e != null && e.clearIcon) ? n = e : e && (n = {
|
|
1259
|
+
clearIcon: /* @__PURE__ */ f.createElement(Rn, null)
|
|
1260
|
+
}), n;
|
|
1261
|
+
};
|
|
1262
|
+
function Qn(e, n) {
|
|
1263
|
+
const r = le([]), t = () => {
|
|
1264
|
+
r.current.push(setTimeout(() => {
|
|
1265
|
+
var a, s, i, l;
|
|
1266
|
+
!((a = e.current) === null || a === void 0) && a.input && ((s = e.current) === null || s === void 0 ? void 0 : s.input.getAttribute("type")) === "password" && (!((i = e.current) === null || i === void 0) && i.input.hasAttribute("value")) && ((l = e.current) === null || l === void 0 || l.input.removeAttribute("value"));
|
|
1267
1267
|
}));
|
|
1268
1268
|
};
|
|
1269
|
-
return $e(() => (
|
|
1270
|
-
|
|
1271
|
-
})), []),
|
|
1269
|
+
return $e(() => (n && t(), () => r.current.forEach((a) => {
|
|
1270
|
+
a && clearTimeout(a);
|
|
1271
|
+
})), []), t;
|
|
1272
1272
|
}
|
|
1273
|
-
function
|
|
1273
|
+
function Jn(e) {
|
|
1274
1274
|
return !!(e.prefix || e.suffix || e.allowClear || e.showCount);
|
|
1275
1275
|
}
|
|
1276
|
-
var
|
|
1277
|
-
var
|
|
1278
|
-
for (var
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
r.indexOf(a[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, a[o]) && (t[a[o]] = e[a[o]]);
|
|
1283
|
-
return t;
|
|
1276
|
+
var kn = function(e, n) {
|
|
1277
|
+
var r = {};
|
|
1278
|
+
for (var t in e) Object.prototype.hasOwnProperty.call(e, t) && n.indexOf(t) < 0 && (r[t] = e[t]);
|
|
1279
|
+
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var a = 0, t = Object.getOwnPropertySymbols(e); a < t.length; a++)
|
|
1280
|
+
n.indexOf(t[a]) < 0 && Object.prototype.propertyIsEnumerable.call(e, t[a]) && (r[t[a]] = e[t[a]]);
|
|
1281
|
+
return r;
|
|
1284
1282
|
};
|
|
1285
|
-
const
|
|
1286
|
-
var
|
|
1283
|
+
const er = /* @__PURE__ */ We((e, n) => {
|
|
1284
|
+
var r;
|
|
1287
1285
|
const {
|
|
1288
|
-
prefixCls:
|
|
1289
|
-
bordered:
|
|
1290
|
-
status:
|
|
1286
|
+
prefixCls: t,
|
|
1287
|
+
bordered: a = !0,
|
|
1288
|
+
status: s,
|
|
1291
1289
|
size: i,
|
|
1292
1290
|
disabled: l,
|
|
1293
1291
|
onBlur: S,
|
|
@@ -1298,12 +1296,12 @@ const mr = /* @__PURE__ */ We((e, r) => {
|
|
|
1298
1296
|
addonBefore: G,
|
|
1299
1297
|
className: R,
|
|
1300
1298
|
style: A,
|
|
1301
|
-
styles:
|
|
1299
|
+
styles: re,
|
|
1302
1300
|
rootClassName: ee,
|
|
1303
1301
|
onChange: y,
|
|
1304
|
-
classNames:
|
|
1302
|
+
classNames: o,
|
|
1305
1303
|
variant: Q
|
|
1306
|
-
} = e, $ =
|
|
1304
|
+
} = e, $ = kn(e, ["prefixCls", "bordered", "status", "size", "disabled", "onBlur", "onFocus", "suffix", "allowClear", "addonAfter", "addonBefore", "className", "style", "styles", "rootClassName", "onChange", "classNames", "variant"]);
|
|
1307
1305
|
if (process.env.NODE_ENV !== "production") {
|
|
1308
1306
|
const {
|
|
1309
1307
|
deprecated: P
|
|
@@ -1311,20 +1309,20 @@ const mr = /* @__PURE__ */ We((e, r) => {
|
|
|
1311
1309
|
P(!("bordered" in e), "bordered", "variant");
|
|
1312
1310
|
}
|
|
1313
1311
|
const {
|
|
1314
|
-
getPrefixCls:
|
|
1315
|
-
direction:
|
|
1316
|
-
input:
|
|
1317
|
-
} = f.useContext(ke),
|
|
1312
|
+
getPrefixCls: b,
|
|
1313
|
+
direction: d,
|
|
1314
|
+
input: u
|
|
1315
|
+
} = f.useContext(ke), c = b("input", t), I = le(null), F = tn(c), [h, D, te] = fn(c, F), {
|
|
1318
1316
|
compactSize: W,
|
|
1319
|
-
compactItemClassnames:
|
|
1320
|
-
} =
|
|
1317
|
+
compactItemClassnames: v
|
|
1318
|
+
} = In(c, d), M = on((P) => {
|
|
1321
1319
|
var Y;
|
|
1322
1320
|
return (Y = i ?? W) !== null && Y !== void 0 ? Y : P;
|
|
1323
|
-
}), J = f.useContext(
|
|
1321
|
+
}), J = f.useContext(en), ae = l ?? J, {
|
|
1324
1322
|
status: z,
|
|
1325
1323
|
hasFeedback: N,
|
|
1326
|
-
feedbackIcon:
|
|
1327
|
-
} =
|
|
1324
|
+
feedbackIcon: X
|
|
1325
|
+
} = Sn(an), _ = rn(z, s), H = Jn(e) || !!N, B = le(H);
|
|
1328
1326
|
if (process.env.NODE_ENV !== "production") {
|
|
1329
1327
|
const P = Te("Input");
|
|
1330
1328
|
$e(() => {
|
|
@@ -1332,26 +1330,26 @@ const mr = /* @__PURE__ */ We((e, r) => {
|
|
|
1332
1330
|
H && !B.current && process.env.NODE_ENV !== "production" && P(document.activeElement === ((Y = I.current) === null || Y === void 0 ? void 0 : Y.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"), B.current = H;
|
|
1333
1331
|
}, [H]);
|
|
1334
1332
|
}
|
|
1335
|
-
const
|
|
1336
|
-
|
|
1333
|
+
const q = Qn(I, !0), se = (P) => {
|
|
1334
|
+
q(), S == null || S(P);
|
|
1337
1335
|
}, j = (P) => {
|
|
1338
|
-
|
|
1336
|
+
q(), g == null || g(P);
|
|
1339
1337
|
}, k = (P) => {
|
|
1340
|
-
|
|
1341
|
-
}, U = (N || p) && /* @__PURE__ */ f.createElement(f.Fragment, null, p, N &&
|
|
1342
|
-
return
|
|
1343
|
-
ref:
|
|
1344
|
-
prefixCls:
|
|
1345
|
-
autoComplete:
|
|
1338
|
+
q(), y == null || y(P);
|
|
1339
|
+
}, U = (N || p) && /* @__PURE__ */ f.createElement(f.Fragment, null, p, N && X), ue = bn(C ?? (u == null ? void 0 : u.allowClear)), [ce, fe] = nn("input", Q, a);
|
|
1340
|
+
return h(/* @__PURE__ */ f.createElement(Zn, Object.assign({
|
|
1341
|
+
ref: yn(n, I),
|
|
1342
|
+
prefixCls: c,
|
|
1343
|
+
autoComplete: u == null ? void 0 : u.autoComplete
|
|
1346
1344
|
}, $, {
|
|
1347
|
-
disabled:
|
|
1348
|
-
onBlur:
|
|
1345
|
+
disabled: ae,
|
|
1346
|
+
onBlur: se,
|
|
1349
1347
|
onFocus: j,
|
|
1350
|
-
style: Object.assign(Object.assign({},
|
|
1351
|
-
styles: Object.assign(Object.assign({},
|
|
1348
|
+
style: Object.assign(Object.assign({}, u == null ? void 0 : u.style), A),
|
|
1349
|
+
styles: Object.assign(Object.assign({}, u == null ? void 0 : u.styles), re),
|
|
1352
1350
|
suffix: U,
|
|
1353
|
-
allowClear:
|
|
1354
|
-
className: w(R, ee,
|
|
1351
|
+
allowClear: ue,
|
|
1352
|
+
className: w(R, ee, te, F, v, u == null ? void 0 : u.className),
|
|
1355
1353
|
onChange: k,
|
|
1356
1354
|
addonBefore: G && /* @__PURE__ */ f.createElement(Ge, {
|
|
1357
1355
|
form: !0,
|
|
@@ -1361,35 +1359,34 @@ const mr = /* @__PURE__ */ We((e, r) => {
|
|
|
1361
1359
|
form: !0,
|
|
1362
1360
|
space: !0
|
|
1363
1361
|
}, E),
|
|
1364
|
-
classNames: Object.assign(Object.assign(Object.assign({},
|
|
1362
|
+
classNames: Object.assign(Object.assign(Object.assign({}, o), u == null ? void 0 : u.classNames), {
|
|
1365
1363
|
input: w({
|
|
1366
|
-
[`${
|
|
1367
|
-
[`${
|
|
1368
|
-
[`${
|
|
1369
|
-
},
|
|
1364
|
+
[`${c}-sm`]: M === "small",
|
|
1365
|
+
[`${c}-lg`]: M === "large",
|
|
1366
|
+
[`${c}-rtl`]: d === "rtl"
|
|
1367
|
+
}, o == null ? void 0 : o.input, (r = u == null ? void 0 : u.classNames) === null || r === void 0 ? void 0 : r.input, D),
|
|
1370
1368
|
variant: w({
|
|
1371
|
-
[`${
|
|
1372
|
-
}, Fe(
|
|
1369
|
+
[`${c}-${ce}`]: fe
|
|
1370
|
+
}, Fe(c, _)),
|
|
1373
1371
|
affixWrapper: w({
|
|
1374
|
-
[`${
|
|
1375
|
-
[`${
|
|
1376
|
-
[`${
|
|
1372
|
+
[`${c}-affix-wrapper-sm`]: M === "small",
|
|
1373
|
+
[`${c}-affix-wrapper-lg`]: M === "large",
|
|
1374
|
+
[`${c}-affix-wrapper-rtl`]: d === "rtl"
|
|
1377
1375
|
}, D),
|
|
1378
1376
|
wrapper: w({
|
|
1379
|
-
[`${
|
|
1377
|
+
[`${c}-group-rtl`]: d === "rtl"
|
|
1380
1378
|
}, D),
|
|
1381
1379
|
groupWrapper: w({
|
|
1382
|
-
[`${
|
|
1383
|
-
[`${
|
|
1384
|
-
[`${
|
|
1385
|
-
[`${
|
|
1386
|
-
}, Fe(`${
|
|
1380
|
+
[`${c}-group-wrapper-sm`]: M === "small",
|
|
1381
|
+
[`${c}-group-wrapper-lg`]: M === "large",
|
|
1382
|
+
[`${c}-group-wrapper-rtl`]: d === "rtl",
|
|
1383
|
+
[`${c}-group-wrapper-${ce}`]: fe
|
|
1384
|
+
}, Fe(`${c}-group-wrapper`, _, N), D)
|
|
1387
1385
|
})
|
|
1388
1386
|
})));
|
|
1389
1387
|
});
|
|
1390
|
-
process.env.NODE_ENV !== "production" && (
|
|
1391
|
-
|
|
1392
|
-
var rt = `
|
|
1388
|
+
process.env.NODE_ENV !== "production" && (er.displayName = "Input");
|
|
1389
|
+
var nr = `
|
|
1393
1390
|
min-height:0 !important;
|
|
1394
1391
|
max-height:none !important;
|
|
1395
1392
|
height:0 !important;
|
|
@@ -1400,31 +1397,31 @@ var rt = `
|
|
|
1400
1397
|
top:0 !important;
|
|
1401
1398
|
right:0 !important;
|
|
1402
1399
|
pointer-events: none !important;
|
|
1403
|
-
`,
|
|
1404
|
-
function
|
|
1405
|
-
var
|
|
1406
|
-
if (
|
|
1407
|
-
return Be[
|
|
1408
|
-
var
|
|
1409
|
-
return "".concat(g, ":").concat(
|
|
1400
|
+
`, rr = ["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"], Be = {}, oe;
|
|
1401
|
+
function tr(e) {
|
|
1402
|
+
var n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, r = e.getAttribute("id") || e.getAttribute("data-reactid") || e.getAttribute("name");
|
|
1403
|
+
if (n && Be[r])
|
|
1404
|
+
return Be[r];
|
|
1405
|
+
var t = window.getComputedStyle(e), a = t.getPropertyValue("box-sizing") || t.getPropertyValue("-moz-box-sizing") || t.getPropertyValue("-webkit-box-sizing"), s = parseFloat(t.getPropertyValue("padding-bottom")) + parseFloat(t.getPropertyValue("padding-top")), i = parseFloat(t.getPropertyValue("border-bottom-width")) + parseFloat(t.getPropertyValue("border-top-width")), l = rr.map(function(g) {
|
|
1406
|
+
return "".concat(g, ":").concat(t.getPropertyValue(g));
|
|
1410
1407
|
}).join(";"), S = {
|
|
1411
1408
|
sizingStyle: l,
|
|
1412
|
-
paddingSize:
|
|
1409
|
+
paddingSize: s,
|
|
1413
1410
|
borderSize: i,
|
|
1414
|
-
boxSizing:
|
|
1411
|
+
boxSizing: a
|
|
1415
1412
|
};
|
|
1416
|
-
return
|
|
1413
|
+
return n && r && (Be[r] = S), S;
|
|
1417
1414
|
}
|
|
1418
|
-
function
|
|
1419
|
-
var
|
|
1420
|
-
|
|
1421
|
-
var
|
|
1422
|
-
|
|
1423
|
-
var g = void 0, p = void 0, C, E =
|
|
1424
|
-
if (l === "border-box" ? E += i : l === "content-box" && (E -=
|
|
1425
|
-
|
|
1426
|
-
var G =
|
|
1427
|
-
|
|
1415
|
+
function ar(e) {
|
|
1416
|
+
var n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : null, t = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : null;
|
|
1417
|
+
oe || (oe = document.createElement("textarea"), oe.setAttribute("tab-index", "-1"), oe.setAttribute("aria-hidden", "true"), oe.setAttribute("name", "hiddenTextarea"), document.body.appendChild(oe)), e.getAttribute("wrap") ? oe.setAttribute("wrap", e.getAttribute("wrap")) : oe.removeAttribute("wrap");
|
|
1418
|
+
var a = tr(e, n), s = a.paddingSize, i = a.borderSize, l = a.boxSizing, S = a.sizingStyle;
|
|
1419
|
+
oe.setAttribute("style", "".concat(S, ";").concat(nr)), oe.value = e.value || e.placeholder || "";
|
|
1420
|
+
var g = void 0, p = void 0, C, E = oe.scrollHeight;
|
|
1421
|
+
if (l === "border-box" ? E += i : l === "content-box" && (E -= s), r !== null || t !== null) {
|
|
1422
|
+
oe.value = " ";
|
|
1423
|
+
var G = oe.scrollHeight - s;
|
|
1424
|
+
r !== null && (g = G * r, l === "border-box" && (g = g + s + i), E = Math.max(g, E)), t !== null && (p = G * t, l === "border-box" && (p = p + s + i), C = E > p ? "" : "hidden", E = Math.min(p, E));
|
|
1428
1425
|
}
|
|
1429
1426
|
var R = {
|
|
1430
1427
|
height: E,
|
|
@@ -1433,144 +1430,144 @@ function ot(e) {
|
|
|
1433
1430
|
};
|
|
1434
1431
|
return g && (R.minHeight = g), p && (R.maxHeight = p), R;
|
|
1435
1432
|
}
|
|
1436
|
-
var
|
|
1437
|
-
var
|
|
1438
|
-
value:
|
|
1433
|
+
var or = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "className", "style", "disabled", "onChange", "onInternalAutoSize"], Ae = 0, Ne = 1, je = 2, ir = /* @__PURE__ */ K.forwardRef(function(e, n) {
|
|
1434
|
+
var r = e, t = r.prefixCls, a = r.defaultValue, s = r.value, i = r.autoSize, l = r.onResize, S = r.className, g = r.style, p = r.disabled, C = r.onChange, E = r.onInternalAutoSize, G = Re(r, or), R = Pe(a, {
|
|
1435
|
+
value: s,
|
|
1439
1436
|
postState: function(B) {
|
|
1440
1437
|
return B ?? "";
|
|
1441
1438
|
}
|
|
1442
|
-
}), A =
|
|
1439
|
+
}), A = de(R, 2), re = A[0], ee = A[1], y = function(B) {
|
|
1443
1440
|
ee(B.target.value), C == null || C(B);
|
|
1444
|
-
},
|
|
1445
|
-
K.useImperativeHandle(
|
|
1441
|
+
}, o = K.useRef();
|
|
1442
|
+
K.useImperativeHandle(n, function() {
|
|
1446
1443
|
return {
|
|
1447
|
-
textArea:
|
|
1444
|
+
textArea: o.current
|
|
1448
1445
|
};
|
|
1449
1446
|
});
|
|
1450
1447
|
var Q = K.useMemo(function() {
|
|
1451
1448
|
return i && _e(i) === "object" ? [i.minRows, i.maxRows] : [];
|
|
1452
|
-
}, [i]), $ =
|
|
1449
|
+
}, [i]), $ = de(Q, 2), b = $[0], d = $[1], u = !!i, c = function() {
|
|
1453
1450
|
try {
|
|
1454
|
-
if (document.activeElement ===
|
|
1455
|
-
var B =
|
|
1456
|
-
|
|
1451
|
+
if (document.activeElement === o.current) {
|
|
1452
|
+
var B = o.current, q = B.selectionStart, se = B.selectionEnd, j = B.scrollTop;
|
|
1453
|
+
o.current.setSelectionRange(q, se), o.current.scrollTop = j;
|
|
1457
1454
|
}
|
|
1458
1455
|
} catch {
|
|
1459
1456
|
}
|
|
1460
|
-
}, I = K.useState(je), F =
|
|
1457
|
+
}, I = K.useState(je), F = de(I, 2), h = F[0], D = F[1], te = K.useState(), W = de(te, 2), v = W[0], M = W[1], J = function() {
|
|
1461
1458
|
D(Ae), process.env.NODE_ENV === "test" && (E == null || E());
|
|
1462
1459
|
};
|
|
1463
1460
|
Le(function() {
|
|
1464
|
-
|
|
1465
|
-
}, [
|
|
1466
|
-
if (
|
|
1461
|
+
u && J();
|
|
1462
|
+
}, [s, b, d, u]), Le(function() {
|
|
1463
|
+
if (h === Ae)
|
|
1467
1464
|
D(Ne);
|
|
1468
|
-
else if (
|
|
1469
|
-
var H =
|
|
1465
|
+
else if (h === Ne) {
|
|
1466
|
+
var H = ar(o.current, !1, b, d);
|
|
1470
1467
|
D(je), M(H);
|
|
1471
1468
|
} else
|
|
1472
|
-
|
|
1473
|
-
}, [
|
|
1474
|
-
var
|
|
1475
|
-
Ve.cancel(
|
|
1469
|
+
c();
|
|
1470
|
+
}, [h]);
|
|
1471
|
+
var ae = K.useRef(), z = function() {
|
|
1472
|
+
Ve.cancel(ae.current);
|
|
1476
1473
|
}, N = function(B) {
|
|
1477
|
-
|
|
1474
|
+
h === je && (l == null || l(B), i && (z(), ae.current = Ve(function() {
|
|
1478
1475
|
J();
|
|
1479
1476
|
})));
|
|
1480
1477
|
};
|
|
1481
1478
|
K.useEffect(function() {
|
|
1482
1479
|
return z;
|
|
1483
1480
|
}, []);
|
|
1484
|
-
var
|
|
1485
|
-
return (
|
|
1481
|
+
var X = u ? v : null, _ = ne(ne({}, g), X);
|
|
1482
|
+
return (h === Ae || h === Ne) && (_.overflowY = "hidden", _.overflowX = "hidden"), /* @__PURE__ */ K.createElement(En, {
|
|
1486
1483
|
onResize: N,
|
|
1487
1484
|
disabled: !(i || l)
|
|
1488
1485
|
}, /* @__PURE__ */ K.createElement("textarea", Ce({}, G, {
|
|
1489
|
-
ref:
|
|
1486
|
+
ref: o,
|
|
1490
1487
|
style: _,
|
|
1491
|
-
className: w(
|
|
1488
|
+
className: w(t, S, ie({}, "".concat(t, "-disabled"), p)),
|
|
1492
1489
|
disabled: p,
|
|
1493
|
-
value:
|
|
1490
|
+
value: re,
|
|
1494
1491
|
onChange: y
|
|
1495
1492
|
})));
|
|
1496
|
-
}),
|
|
1497
|
-
var
|
|
1498
|
-
value:
|
|
1499
|
-
defaultValue:
|
|
1500
|
-
}), W =
|
|
1493
|
+
}), lr = ["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"], dr = /* @__PURE__ */ f.forwardRef(function(e, n) {
|
|
1494
|
+
var r, t = e.defaultValue, a = e.value, s = e.onFocus, i = e.onBlur, l = e.onChange, S = e.allowClear, g = e.maxLength, p = e.onCompositionStart, C = e.onCompositionEnd, E = e.suffix, G = e.prefixCls, R = G === void 0 ? "rc-textarea" : G, A = e.showCount, re = e.count, ee = e.className, y = e.style, o = e.disabled, Q = e.hidden, $ = e.classNames, b = e.styles, d = e.onResize, u = e.onClear, c = e.onPressEnter, I = e.readOnly, F = e.autoSize, h = e.onKeyDown, D = Re(e, lr), te = Pe(t, {
|
|
1495
|
+
value: a,
|
|
1496
|
+
defaultValue: t
|
|
1497
|
+
}), W = de(te, 2), v = W[0], M = W[1], J = v == null ? "" : String(v), ae = f.useState(!1), z = de(ae, 2), N = z[0], X = z[1], _ = f.useRef(!1), H = f.useState(null), B = de(H, 2), q = B[0], se = B[1], j = le(null), k = le(null), U = function() {
|
|
1501
1498
|
var x;
|
|
1502
1499
|
return (x = k.current) === null || x === void 0 ? void 0 : x.textArea;
|
|
1503
|
-
},
|
|
1500
|
+
}, ue = function() {
|
|
1504
1501
|
U().focus();
|
|
1505
1502
|
};
|
|
1506
|
-
Ze(
|
|
1503
|
+
Ze(n, function() {
|
|
1507
1504
|
var V;
|
|
1508
1505
|
return {
|
|
1509
1506
|
resizableTextArea: k.current,
|
|
1510
|
-
focus:
|
|
1507
|
+
focus: ue,
|
|
1511
1508
|
blur: function() {
|
|
1512
1509
|
U().blur();
|
|
1513
1510
|
},
|
|
1514
1511
|
nativeElement: ((V = j.current) === null || V === void 0 ? void 0 : V.nativeElement) || U()
|
|
1515
1512
|
};
|
|
1516
1513
|
}), $e(function() {
|
|
1517
|
-
|
|
1518
|
-
return !
|
|
1514
|
+
X(function(V) {
|
|
1515
|
+
return !o && V;
|
|
1519
1516
|
});
|
|
1520
|
-
}, [
|
|
1521
|
-
var
|
|
1517
|
+
}, [o]);
|
|
1518
|
+
var ce = f.useState(null), fe = de(ce, 2), P = fe[0], Y = fe[1];
|
|
1522
1519
|
f.useEffect(function() {
|
|
1523
1520
|
if (P) {
|
|
1524
1521
|
var V;
|
|
1525
1522
|
(V = U()).setSelectionRange.apply(V, Je(P));
|
|
1526
1523
|
}
|
|
1527
1524
|
}, [P]);
|
|
1528
|
-
var Z =
|
|
1529
|
-
var we =
|
|
1530
|
-
!_.current && Z.exceedFormatter && Z.max && Z.strategy(
|
|
1525
|
+
var Z = mn(re, A), be = (r = Z.max) !== null && r !== void 0 ? r : g, Ie = Number(be) > 0, xe = Z.strategy(J), ze = !!be && xe > be, ye = function(x, me) {
|
|
1526
|
+
var we = me;
|
|
1527
|
+
!_.current && Z.exceedFormatter && Z.max && Z.strategy(me) > Z.max && (we = Z.exceedFormatter(me, {
|
|
1531
1528
|
max: Z.max
|
|
1532
|
-
}),
|
|
1529
|
+
}), me !== we && Y([U().selectionStart || 0, U().selectionEnd || 0])), M(we), Ee(x.currentTarget, x, l, we);
|
|
1533
1530
|
}, Oe = function(x) {
|
|
1534
1531
|
_.current = !0, p == null || p(x);
|
|
1535
1532
|
}, O = function(x) {
|
|
1536
1533
|
_.current = !1, ye(x, x.currentTarget.value), C == null || C(x);
|
|
1537
|
-
},
|
|
1534
|
+
}, m = function(x) {
|
|
1538
1535
|
ye(x, x.target.value);
|
|
1539
1536
|
}, L = function(x) {
|
|
1540
|
-
x.key === "Enter" &&
|
|
1541
|
-
},
|
|
1542
|
-
|
|
1537
|
+
x.key === "Enter" && c && c(x), h == null || h(x);
|
|
1538
|
+
}, he = function(x) {
|
|
1539
|
+
X(!0), s == null || s(x);
|
|
1543
1540
|
}, pe = function(x) {
|
|
1544
|
-
|
|
1541
|
+
X(!1), i == null || i(x);
|
|
1545
1542
|
}, ge = function(x) {
|
|
1546
|
-
M(""),
|
|
1547
|
-
},
|
|
1543
|
+
M(""), ue(), Ee(U(), x, l);
|
|
1544
|
+
}, ve = E, Se;
|
|
1548
1545
|
Z.show && (Z.showFormatter ? Se = Z.showFormatter({
|
|
1549
1546
|
value: J,
|
|
1550
1547
|
count: xe,
|
|
1551
|
-
maxLength:
|
|
1552
|
-
}) : Se = "".concat(xe).concat(Ie ? " / ".concat(
|
|
1548
|
+
maxLength: be
|
|
1549
|
+
}) : Se = "".concat(xe).concat(Ie ? " / ".concat(be) : ""), ve = /* @__PURE__ */ f.createElement(f.Fragment, null, ve, /* @__PURE__ */ f.createElement("span", {
|
|
1553
1550
|
className: w("".concat(R, "-data-count"), $ == null ? void 0 : $.count),
|
|
1554
|
-
style:
|
|
1551
|
+
style: b == null ? void 0 : b.count
|
|
1555
1552
|
}, Se)));
|
|
1556
|
-
var
|
|
1557
|
-
var
|
|
1558
|
-
|
|
1559
|
-
},
|
|
1560
|
-
return /* @__PURE__ */ f.createElement(
|
|
1553
|
+
var hn = function(x) {
|
|
1554
|
+
var me;
|
|
1555
|
+
d == null || d(x), (me = U()) !== null && me !== void 0 && me.style.height && se(!0);
|
|
1556
|
+
}, vn = !F && !A && !S;
|
|
1557
|
+
return /* @__PURE__ */ f.createElement(pn, {
|
|
1561
1558
|
ref: j,
|
|
1562
1559
|
value: J,
|
|
1563
1560
|
allowClear: S,
|
|
1564
1561
|
handleReset: ge,
|
|
1565
|
-
suffix:
|
|
1562
|
+
suffix: ve,
|
|
1566
1563
|
prefixCls: R,
|
|
1567
|
-
classNames:
|
|
1564
|
+
classNames: ne(ne({}, $), {}, {
|
|
1568
1565
|
affixWrapper: w($ == null ? void 0 : $.affixWrapper, ie(ie({}, "".concat(R, "-show-count"), A), "".concat(R, "-textarea-allow-clear"), S))
|
|
1569
1566
|
}),
|
|
1570
|
-
disabled:
|
|
1567
|
+
disabled: o,
|
|
1571
1568
|
focused: N,
|
|
1572
1569
|
className: w(ee, ze && "".concat(R, "-out-of-range")),
|
|
1573
|
-
style:
|
|
1570
|
+
style: ne(ne({}, y), q && !vn ? {
|
|
1574
1571
|
height: "auto"
|
|
1575
1572
|
} : {}),
|
|
1576
1573
|
dataAttrs: {
|
|
@@ -1580,40 +1577,38 @@ var nt = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "classNa
|
|
|
1580
1577
|
},
|
|
1581
1578
|
hidden: Q,
|
|
1582
1579
|
readOnly: I,
|
|
1583
|
-
onClear:
|
|
1584
|
-
}, /* @__PURE__ */ f.createElement(
|
|
1580
|
+
onClear: u
|
|
1581
|
+
}, /* @__PURE__ */ f.createElement(ir, Ce({}, D, {
|
|
1585
1582
|
autoSize: F,
|
|
1586
1583
|
maxLength: g,
|
|
1587
1584
|
onKeyDown: L,
|
|
1588
|
-
onChange:
|
|
1589
|
-
onFocus:
|
|
1585
|
+
onChange: m,
|
|
1586
|
+
onFocus: he,
|
|
1590
1587
|
onBlur: pe,
|
|
1591
1588
|
onCompositionStart: Oe,
|
|
1592
1589
|
onCompositionEnd: O,
|
|
1593
1590
|
className: w($ == null ? void 0 : $.textarea),
|
|
1594
|
-
style:
|
|
1591
|
+
style: ne(ne({}, b == null ? void 0 : b.textarea), {}, {
|
|
1595
1592
|
resize: y == null ? void 0 : y.resize
|
|
1596
1593
|
}),
|
|
1597
|
-
disabled:
|
|
1594
|
+
disabled: o,
|
|
1598
1595
|
prefixCls: R,
|
|
1599
|
-
onResize:
|
|
1596
|
+
onResize: hn,
|
|
1600
1597
|
ref: k,
|
|
1601
1598
|
readOnly: I
|
|
1602
1599
|
})));
|
|
1603
|
-
}),
|
|
1604
|
-
var
|
|
1605
|
-
for (var
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
r.indexOf(a[o]) < 0 && Object.prototype.propertyIsEnumerable.call(e, a[o]) && (t[a[o]] = e[a[o]]);
|
|
1610
|
-
return t;
|
|
1600
|
+
}), sr = function(e, n) {
|
|
1601
|
+
var r = {};
|
|
1602
|
+
for (var t in e) Object.prototype.hasOwnProperty.call(e, t) && n.indexOf(t) < 0 && (r[t] = e[t]);
|
|
1603
|
+
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var a = 0, t = Object.getOwnPropertySymbols(e); a < t.length; a++)
|
|
1604
|
+
n.indexOf(t[a]) < 0 && Object.prototype.propertyIsEnumerable.call(e, t[a]) && (r[t[a]] = e[t[a]]);
|
|
1605
|
+
return r;
|
|
1611
1606
|
};
|
|
1612
|
-
const
|
|
1613
|
-
var
|
|
1607
|
+
const $r = /* @__PURE__ */ We((e, n) => {
|
|
1608
|
+
var r, t;
|
|
1614
1609
|
const {
|
|
1615
|
-
prefixCls:
|
|
1616
|
-
bordered:
|
|
1610
|
+
prefixCls: a,
|
|
1611
|
+
bordered: s = !0,
|
|
1617
1612
|
size: i,
|
|
1618
1613
|
disabled: l,
|
|
1619
1614
|
status: S,
|
|
@@ -1624,7 +1619,7 @@ const ct = /* @__PURE__ */ We((e, r) => {
|
|
|
1624
1619
|
style: G,
|
|
1625
1620
|
styles: R,
|
|
1626
1621
|
variant: A
|
|
1627
|
-
} = e,
|
|
1622
|
+
} = e, re = sr(e, ["prefixCls", "bordered", "size", "disabled", "status", "allowClear", "classNames", "rootClassName", "className", "style", "styles", "variant"]);
|
|
1628
1623
|
if (process.env.NODE_ENV !== "production") {
|
|
1629
1624
|
const {
|
|
1630
1625
|
deprecated: z
|
|
@@ -1634,19 +1629,19 @@ const ct = /* @__PURE__ */ We((e, r) => {
|
|
|
1634
1629
|
const {
|
|
1635
1630
|
getPrefixCls: ee,
|
|
1636
1631
|
direction: y,
|
|
1637
|
-
textArea:
|
|
1638
|
-
} = K.useContext(ke), Q =
|
|
1639
|
-
status:
|
|
1640
|
-
hasFeedback:
|
|
1641
|
-
feedbackIcon:
|
|
1642
|
-
} = K.useContext(
|
|
1643
|
-
K.useImperativeHandle(
|
|
1632
|
+
textArea: o
|
|
1633
|
+
} = K.useContext(ke), Q = on(i), $ = K.useContext(en), b = l ?? $, {
|
|
1634
|
+
status: d,
|
|
1635
|
+
hasFeedback: u,
|
|
1636
|
+
feedbackIcon: c
|
|
1637
|
+
} = K.useContext(an), I = rn(d, S), F = K.useRef(null);
|
|
1638
|
+
K.useImperativeHandle(n, () => {
|
|
1644
1639
|
var z;
|
|
1645
1640
|
return {
|
|
1646
1641
|
resizableTextArea: (z = F.current) === null || z === void 0 ? void 0 : z.resizableTextArea,
|
|
1647
1642
|
focus: (N) => {
|
|
1648
|
-
var
|
|
1649
|
-
|
|
1643
|
+
var X, _;
|
|
1644
|
+
gn((_ = (X = F.current) === null || X === void 0 ? void 0 : X.resizableTextArea) === null || _ === void 0 ? void 0 : _.textArea, N);
|
|
1650
1645
|
},
|
|
1651
1646
|
blur: () => {
|
|
1652
1647
|
var N;
|
|
@@ -1654,42 +1649,42 @@ const ct = /* @__PURE__ */ We((e, r) => {
|
|
|
1654
1649
|
}
|
|
1655
1650
|
};
|
|
1656
1651
|
});
|
|
1657
|
-
const
|
|
1658
|
-
return
|
|
1659
|
-
autoComplete:
|
|
1660
|
-
},
|
|
1661
|
-
style: Object.assign(Object.assign({},
|
|
1662
|
-
styles: Object.assign(Object.assign({},
|
|
1663
|
-
disabled:
|
|
1664
|
-
allowClear:
|
|
1665
|
-
className: w(
|
|
1666
|
-
classNames: Object.assign(Object.assign(Object.assign({}, p),
|
|
1652
|
+
const h = ee("input", a), D = tn(h), [te, W, v] = fn(h, D), [M, J] = nn("textArea", A, s), ae = bn(g ?? (o == null ? void 0 : o.allowClear));
|
|
1653
|
+
return te(/* @__PURE__ */ K.createElement(dr, Object.assign({
|
|
1654
|
+
autoComplete: o == null ? void 0 : o.autoComplete
|
|
1655
|
+
}, re, {
|
|
1656
|
+
style: Object.assign(Object.assign({}, o == null ? void 0 : o.style), G),
|
|
1657
|
+
styles: Object.assign(Object.assign({}, o == null ? void 0 : o.styles), R),
|
|
1658
|
+
disabled: b,
|
|
1659
|
+
allowClear: ae,
|
|
1660
|
+
className: w(v, D, E, C, o == null ? void 0 : o.className),
|
|
1661
|
+
classNames: Object.assign(Object.assign(Object.assign({}, p), o == null ? void 0 : o.classNames), {
|
|
1667
1662
|
textarea: w({
|
|
1668
|
-
[`${
|
|
1669
|
-
[`${
|
|
1670
|
-
}, W, p == null ? void 0 : p.textarea, (
|
|
1663
|
+
[`${h}-sm`]: Q === "small",
|
|
1664
|
+
[`${h}-lg`]: Q === "large"
|
|
1665
|
+
}, W, p == null ? void 0 : p.textarea, (r = o == null ? void 0 : o.classNames) === null || r === void 0 ? void 0 : r.textarea),
|
|
1671
1666
|
variant: w({
|
|
1672
|
-
[`${
|
|
1673
|
-
}, Fe(
|
|
1674
|
-
affixWrapper: w(`${
|
|
1675
|
-
[`${
|
|
1676
|
-
[`${
|
|
1677
|
-
[`${
|
|
1678
|
-
[`${
|
|
1667
|
+
[`${h}-${M}`]: J
|
|
1668
|
+
}, Fe(h, I)),
|
|
1669
|
+
affixWrapper: w(`${h}-textarea-affix-wrapper`, {
|
|
1670
|
+
[`${h}-affix-wrapper-rtl`]: y === "rtl",
|
|
1671
|
+
[`${h}-affix-wrapper-sm`]: Q === "small",
|
|
1672
|
+
[`${h}-affix-wrapper-lg`]: Q === "large",
|
|
1673
|
+
[`${h}-textarea-show-count`]: e.showCount || ((t = e.count) === null || t === void 0 ? void 0 : t.show)
|
|
1679
1674
|
}, W)
|
|
1680
1675
|
}),
|
|
1681
|
-
prefixCls:
|
|
1682
|
-
suffix:
|
|
1683
|
-
className: `${
|
|
1684
|
-
},
|
|
1676
|
+
prefixCls: h,
|
|
1677
|
+
suffix: u && /* @__PURE__ */ K.createElement("span", {
|
|
1678
|
+
className: `${h}-textarea-suffix`
|
|
1679
|
+
}, c),
|
|
1685
1680
|
ref: F
|
|
1686
1681
|
})));
|
|
1687
|
-
})
|
|
1682
|
+
});
|
|
1688
1683
|
export {
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1684
|
+
er as I,
|
|
1685
|
+
$r as T,
|
|
1686
|
+
Bn as a,
|
|
1687
|
+
Qn as b,
|
|
1688
|
+
On as i,
|
|
1689
|
+
fn as u
|
|
1695
1690
|
};
|