musae 1.3.1-beta.4 → 1.3.1-beta.6
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/components/input/__test__/input.test.d.ts +1 -0
- package/dist/components/input/context.cjs +2 -0
- package/dist/components/input/context.d.ts +2 -0
- package/dist/components/input/context.mjs +2 -0
- package/dist/components/input/input.cjs +24 -11
- package/dist/components/input/input.mjs +25 -12
- package/dist/components/input/styles.stylex.cjs +60 -9
- package/dist/components/input/styles.stylex.d.ts +61 -10
- package/dist/components/input/styles.stylex.mjs +60 -9
- package/dist/styles.css +36 -8
- package/dist/types/input.d.ts +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "@testing-library/jest-dom";
|
|
@@ -18,7 +18,7 @@ var context = require('./context.cjs');
|
|
|
18
18
|
var theme = require('../theme/theme.cjs');
|
|
19
19
|
var useThemeColorVars = require('../../hooks/use-theme-color-vars.cjs');
|
|
20
20
|
|
|
21
|
-
var _excluded = ["className", "style", "type", "invalid", "disabled", "maxLength", "value", "onBlur", "onChange", "onClick", "onFocus", "leading", "trailing", "onInputorClick"];
|
|
21
|
+
var _excluded = ["className", "style", "type", "invalid", "disabled", "maxLength", "value", "onBlur", "onChange", "onClick", "onFocus", "leading", "trailing", "onInputorClick", "label"];
|
|
22
22
|
/**
|
|
23
23
|
* @author murukal
|
|
24
24
|
* @zh 输入组件
|
|
@@ -40,11 +40,15 @@ var Input = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
40
40
|
leading = _ref.leading,
|
|
41
41
|
trailing = _ref.trailing,
|
|
42
42
|
onInputorClick = _ref.onInputorClick,
|
|
43
|
+
label = _ref.label,
|
|
43
44
|
inputProps = _objectWithoutProperties(_ref, _excluded);
|
|
44
45
|
var inputorRef = React.useRef(null);
|
|
45
46
|
var inputRef = React.useRef(null);
|
|
46
47
|
var classNames = useClassNames.useClassNames(context.CLASS_NAMES);
|
|
47
48
|
var hasPlaceholder = !!inputProps.placeholder;
|
|
49
|
+
var _useIdentity = relax.useIdentity(),
|
|
50
|
+
_useIdentity2 = _slicedToArray(_useIdentity, 1),
|
|
51
|
+
id = _useIdentity2[0];
|
|
48
52
|
var _themeColorVars = useThemeColorVars.useThemeColorVars(["primary", "outline", "error", "on-surface-variant", ["on-surface", tokens_stylex.OPACITY.thickest], ["on-surface", tokens_stylex.OPACITY.medium], ["on-surface", tokens_stylex.OPACITY.thin]]);
|
|
49
53
|
// controlled value
|
|
50
54
|
var _useControlledState = relax.useControlledState(valueInProps, {
|
|
@@ -100,13 +104,15 @@ var Input = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
100
104
|
isFocused = _useFocus2[0],
|
|
101
105
|
focusProps = _useFocus2[1];
|
|
102
106
|
var styled = {
|
|
103
|
-
root: stylex.props(theme.$body.medium, styles_stylex.default.root.base,
|
|
104
|
-
input: stylex.props(styles_stylex.default.input.base, disabled && styles_stylex.default.input.disabled),
|
|
107
|
+
root: stylex.props(theme.$body.medium, styles_stylex.default.root.base, disabled && styles_stylex.default.root.disabled, !disabled && styles_stylex.textFieldMarker),
|
|
108
|
+
input: stylex.props(styles_stylex.default.input.base, !!leading && styles_stylex.default.input.hasLeading, !!trailing && styles_stylex.default.input.hasTrailing, disabled && styles_stylex.default.input.disabled),
|
|
109
|
+
leading: stylex.props(styles_stylex.default.leading.base),
|
|
110
|
+
trailing: stylex.props(styles_stylex.default.trailing.base),
|
|
105
111
|
outline: stylex.props(styles_stylex.default.outline.base),
|
|
106
|
-
outlineLeading: stylex.props(styles_stylex.default.outlineLeading.base, disabled && styles_stylex.default.outlineLeading.disabled),
|
|
107
|
-
outlineNotch: stylex.props(styles_stylex.default.outlineNotch.base,
|
|
108
|
-
outlineTrailing: stylex.props(styles_stylex.default.outlineTrailing.base, disabled && styles_stylex.default.outlineTrailing.disabled),
|
|
109
|
-
floatingLabel: stylex.props(styles_stylex.default.floatingLabel.base, hasPlaceholder && styles_stylex.default.floatingLabel.placeholder, disabled && styles_stylex.default.floatingLabel.disabled)
|
|
112
|
+
outlineLeading: stylex.props(styles_stylex.default.outlineLeading.base, disabled && styles_stylex.default.outlineLeading.disabled, invalid && styles_stylex.default.outlineLeading.invalid),
|
|
113
|
+
outlineNotch: stylex.props(styles_stylex.default.outlineNotch.base, theme.$body.small, !!label && styles_stylex.default.outlineNotch.withLabel, hasPlaceholder && !!label && styles_stylex.default.outlineNotch.withLabelAndPlaceholder, disabled && styles_stylex.default.outlineNotch.disabled, invalid && styles_stylex.default.outlineNotch.invalid),
|
|
114
|
+
outlineTrailing: stylex.props(styles_stylex.default.outlineTrailing.base, disabled && styles_stylex.default.outlineTrailing.disabled, invalid && styles_stylex.default.outlineTrailing.invalid),
|
|
115
|
+
floatingLabel: stylex.props(styles_stylex.default.floatingLabel.base, hasPlaceholder && styles_stylex.default.floatingLabel.placeholder, disabled && styles_stylex.default.floatingLabel.disabled, invalid && styles_stylex.default.floatingLabel.invalid)
|
|
110
116
|
};
|
|
111
117
|
return /*#__PURE__*/React.createElement("div", _objectSpread({
|
|
112
118
|
ref: inputorRef,
|
|
@@ -115,7 +121,11 @@ var Input = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
115
121
|
onClick: inputorEvents.click
|
|
116
122
|
}, !disabled && {
|
|
117
123
|
tabIndex: -1
|
|
118
|
-
}), leading
|
|
124
|
+
}), !!leading && (/*#__PURE__*/React.createElement("div", {
|
|
125
|
+
className: className.stringify(classNames.leading, styled.leading.className),
|
|
126
|
+
style: styled.leading.style
|
|
127
|
+
}, leading)), /*#__PURE__*/React.createElement("input", _objectSpread(_objectSpread({
|
|
128
|
+
id: id,
|
|
119
129
|
value: _value,
|
|
120
130
|
className: className.stringify(classNames.input, styled.input.className),
|
|
121
131
|
style: styled.input.style,
|
|
@@ -136,12 +146,15 @@ var Input = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
|
136
146
|
className: className.stringify(classNames.outlineNotch, styled.outlineNotch.className),
|
|
137
147
|
style: styled.outlineNotch.style
|
|
138
148
|
}, /*#__PURE__*/React.createElement("label", {
|
|
139
|
-
htmlFor:
|
|
149
|
+
htmlFor: id,
|
|
140
150
|
className: className.stringify(styled.floatingLabel.className)
|
|
141
|
-
},
|
|
151
|
+
}, label)), /*#__PURE__*/React.createElement("div", {
|
|
142
152
|
className: className.stringify(classNames.outlineTrailing, styled.outlineTrailing.className),
|
|
143
153
|
style: styled.outlineTrailing.style
|
|
144
|
-
})), trailing
|
|
154
|
+
})), !!trailing && (/*#__PURE__*/React.createElement("div", {
|
|
155
|
+
className: className.stringify(classNames.trailing, styled.trailing.className),
|
|
156
|
+
style: styled.trailing.style
|
|
157
|
+
}, trailing)));
|
|
145
158
|
});
|
|
146
159
|
|
|
147
160
|
exports.default = Input;
|
|
@@ -5,7 +5,7 @@ import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProper
|
|
|
5
5
|
import styles, { textFieldMarker } from './styles.stylex.mjs';
|
|
6
6
|
import React, { forwardRef, useRef, useImperativeHandle } from 'react';
|
|
7
7
|
import { useInputEvents, useInputorEvents } from './hooks.mjs';
|
|
8
|
-
import { useControlledState, useFocus } from '@aiszlab/relax';
|
|
8
|
+
import { useIdentity, useControlledState, useFocus } from '@aiszlab/relax';
|
|
9
9
|
import { props } from '../../node_modules/.pnpm/@stylexjs_stylex@0.19.0/node_modules/@stylexjs/stylex/lib/es/stylex.mjs';
|
|
10
10
|
import { OPACITY } from '../theme/tokens.stylex.mjs';
|
|
11
11
|
import { useClassNames } from '../../hooks/use-class-names.mjs';
|
|
@@ -14,7 +14,7 @@ import { CLASS_NAMES } from './context.mjs';
|
|
|
14
14
|
import { $body } from '../theme/theme.mjs';
|
|
15
15
|
import { useThemeColorVars } from '../../hooks/use-theme-color-vars.mjs';
|
|
16
16
|
|
|
17
|
-
var _excluded = ["className", "style", "type", "invalid", "disabled", "maxLength", "value", "onBlur", "onChange", "onClick", "onFocus", "leading", "trailing", "onInputorClick"];
|
|
17
|
+
var _excluded = ["className", "style", "type", "invalid", "disabled", "maxLength", "value", "onBlur", "onChange", "onClick", "onFocus", "leading", "trailing", "onInputorClick", "label"];
|
|
18
18
|
/**
|
|
19
19
|
* @author murukal
|
|
20
20
|
* @zh 输入组件
|
|
@@ -36,11 +36,15 @@ var Input = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
36
36
|
leading = _ref.leading,
|
|
37
37
|
trailing = _ref.trailing,
|
|
38
38
|
onInputorClick = _ref.onInputorClick,
|
|
39
|
+
label = _ref.label,
|
|
39
40
|
inputProps = _objectWithoutProperties(_ref, _excluded);
|
|
40
41
|
var inputorRef = useRef(null);
|
|
41
42
|
var inputRef = useRef(null);
|
|
42
43
|
var classNames = useClassNames(CLASS_NAMES);
|
|
43
44
|
var hasPlaceholder = !!inputProps.placeholder;
|
|
45
|
+
var _useIdentity = useIdentity(),
|
|
46
|
+
_useIdentity2 = _slicedToArray(_useIdentity, 1),
|
|
47
|
+
id = _useIdentity2[0];
|
|
44
48
|
var _themeColorVars = useThemeColorVars(["primary", "outline", "error", "on-surface-variant", ["on-surface", OPACITY.thickest], ["on-surface", OPACITY.medium], ["on-surface", OPACITY.thin]]);
|
|
45
49
|
// controlled value
|
|
46
50
|
var _useControlledState = useControlledState(valueInProps, {
|
|
@@ -96,13 +100,15 @@ var Input = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
96
100
|
isFocused = _useFocus2[0],
|
|
97
101
|
focusProps = _useFocus2[1];
|
|
98
102
|
var styled = {
|
|
99
|
-
root: props($body.medium, styles.root.base,
|
|
100
|
-
input: props(styles.input.base, disabled && styles.input.disabled),
|
|
103
|
+
root: props($body.medium, styles.root.base, disabled && styles.root.disabled, !disabled && textFieldMarker),
|
|
104
|
+
input: props(styles.input.base, !!leading && styles.input.hasLeading, !!trailing && styles.input.hasTrailing, disabled && styles.input.disabled),
|
|
105
|
+
leading: props(styles.leading.base),
|
|
106
|
+
trailing: props(styles.trailing.base),
|
|
101
107
|
outline: props(styles.outline.base),
|
|
102
|
-
outlineLeading: props(styles.outlineLeading.base, disabled && styles.outlineLeading.disabled),
|
|
103
|
-
outlineNotch: props(styles.outlineNotch.base,
|
|
104
|
-
outlineTrailing: props(styles.outlineTrailing.base, disabled && styles.outlineTrailing.disabled),
|
|
105
|
-
floatingLabel: props(styles.floatingLabel.base, hasPlaceholder && styles.floatingLabel.placeholder, disabled && styles.floatingLabel.disabled)
|
|
108
|
+
outlineLeading: props(styles.outlineLeading.base, disabled && styles.outlineLeading.disabled, invalid && styles.outlineLeading.invalid),
|
|
109
|
+
outlineNotch: props(styles.outlineNotch.base, $body.small, !!label && styles.outlineNotch.withLabel, hasPlaceholder && !!label && styles.outlineNotch.withLabelAndPlaceholder, disabled && styles.outlineNotch.disabled, invalid && styles.outlineNotch.invalid),
|
|
110
|
+
outlineTrailing: props(styles.outlineTrailing.base, disabled && styles.outlineTrailing.disabled, invalid && styles.outlineTrailing.invalid),
|
|
111
|
+
floatingLabel: props(styles.floatingLabel.base, hasPlaceholder && styles.floatingLabel.placeholder, disabled && styles.floatingLabel.disabled, invalid && styles.floatingLabel.invalid)
|
|
106
112
|
};
|
|
107
113
|
return /*#__PURE__*/React.createElement("div", _objectSpread({
|
|
108
114
|
ref: inputorRef,
|
|
@@ -111,7 +117,11 @@ var Input = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
111
117
|
onClick: inputorEvents.click
|
|
112
118
|
}, !disabled && {
|
|
113
119
|
tabIndex: -1
|
|
114
|
-
}), leading
|
|
120
|
+
}), !!leading && (/*#__PURE__*/React.createElement("div", {
|
|
121
|
+
className: stringify(classNames.leading, styled.leading.className),
|
|
122
|
+
style: styled.leading.style
|
|
123
|
+
}, leading)), /*#__PURE__*/React.createElement("input", _objectSpread(_objectSpread({
|
|
124
|
+
id: id,
|
|
115
125
|
value: _value,
|
|
116
126
|
className: stringify(classNames.input, styled.input.className),
|
|
117
127
|
style: styled.input.style,
|
|
@@ -132,12 +142,15 @@ var Input = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
132
142
|
className: stringify(classNames.outlineNotch, styled.outlineNotch.className),
|
|
133
143
|
style: styled.outlineNotch.style
|
|
134
144
|
}, /*#__PURE__*/React.createElement("label", {
|
|
135
|
-
htmlFor:
|
|
145
|
+
htmlFor: id,
|
|
136
146
|
className: stringify(styled.floatingLabel.className)
|
|
137
|
-
},
|
|
147
|
+
}, label)), /*#__PURE__*/React.createElement("div", {
|
|
138
148
|
className: stringify(classNames.outlineTrailing, styled.outlineTrailing.className),
|
|
139
149
|
style: styled.outlineTrailing.style
|
|
140
|
-
})), trailing
|
|
150
|
+
})), !!trailing && (/*#__PURE__*/React.createElement("div", {
|
|
151
|
+
className: stringify(classNames.trailing, styled.trailing.className),
|
|
152
|
+
style: styled.trailing.style
|
|
153
|
+
}, trailing)));
|
|
141
154
|
});
|
|
142
155
|
|
|
143
156
|
export { Input as default };
|
|
@@ -21,12 +21,7 @@ var root = {
|
|
|
21
21
|
kB7OPa: "musaex-9f619",
|
|
22
22
|
kogj98: "musaex-q3gua8",
|
|
23
23
|
k8WAf4: "musaex-11owsmz",
|
|
24
|
-
kg3NbH: "musaex-
|
|
25
|
-
$$css: true
|
|
26
|
-
},
|
|
27
|
-
invalid: {
|
|
28
|
-
kGVxlE: "musaex-4ms1xy",
|
|
29
|
-
knuKkz: null,
|
|
24
|
+
kg3NbH: "musaex-2961ne",
|
|
30
25
|
$$css: true
|
|
31
26
|
},
|
|
32
27
|
disabled: {
|
|
@@ -38,13 +33,23 @@ var input = {
|
|
|
38
33
|
base: {
|
|
39
34
|
kLWn49: "musaex-15bjb6t",
|
|
40
35
|
kGuDYH: "musaex-1qlqyl8",
|
|
41
|
-
|
|
36
|
+
k8WAf4: "musaex-6yerk0",
|
|
37
|
+
kg3NbH: "musaex-1v4gb6w",
|
|
42
38
|
kMzoRj: "musaex-k59kd",
|
|
43
39
|
kWkggS: "musaex-jbqb8w",
|
|
44
40
|
kI3sdo: "musaex-4fx59i",
|
|
45
41
|
k7Eaqz: "musaex-1rdiejn",
|
|
46
42
|
kZKoxP: "musaex-kyvkcq",
|
|
47
43
|
kUk6DE: "musaex-98rzlu",
|
|
44
|
+
k8Qsv1: "musaex-19r3k9r",
|
|
45
|
+
$$css: true
|
|
46
|
+
},
|
|
47
|
+
hasLeading: {
|
|
48
|
+
kZCmMZ: "musaex-t0f09o",
|
|
49
|
+
$$css: true
|
|
50
|
+
},
|
|
51
|
+
hasTrailing: {
|
|
52
|
+
kwRFfy: "musaex-1kav6dm",
|
|
48
53
|
$$css: true
|
|
49
54
|
},
|
|
50
55
|
disabled: {
|
|
@@ -52,6 +57,26 @@ var input = {
|
|
|
52
57
|
$$css: true
|
|
53
58
|
}
|
|
54
59
|
};
|
|
60
|
+
var leading = {
|
|
61
|
+
base: {
|
|
62
|
+
kVAEAm: "musaex-10l6tqk",
|
|
63
|
+
kYYq5F: "musaex-vg9ial",
|
|
64
|
+
kLqNvP: "musaex-82zlsq",
|
|
65
|
+
k1xSpc: "musaex-3nfvp2",
|
|
66
|
+
kGNEyG: "musaex-6s0dn4",
|
|
67
|
+
$$css: true
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
var trailing = {
|
|
71
|
+
base: {
|
|
72
|
+
kVAEAm: "musaex-10l6tqk",
|
|
73
|
+
kYYq5F: "musaex-vg9ial",
|
|
74
|
+
kt4wiu: "musaex-1swhz51",
|
|
75
|
+
k1xSpc: "musaex-3nfvp2",
|
|
76
|
+
kGNEyG: "musaex-6s0dn4",
|
|
77
|
+
$$css: true
|
|
78
|
+
}
|
|
79
|
+
};
|
|
55
80
|
var outline = {
|
|
56
81
|
base: {
|
|
57
82
|
kVAEAm: "musaex-10l6tqk",
|
|
@@ -83,6 +108,11 @@ var outlineLeading = {
|
|
|
83
108
|
disabled: {
|
|
84
109
|
kVAM5u: "musaex-utl9qk",
|
|
85
110
|
$$css: true
|
|
111
|
+
},
|
|
112
|
+
invalid: {
|
|
113
|
+
kVAM5u: "musaex-1ofxpqo",
|
|
114
|
+
k6qhrQ: "musaex-7rzjjb",
|
|
115
|
+
$$css: true
|
|
86
116
|
}
|
|
87
117
|
};
|
|
88
118
|
var outlineTrailing = {
|
|
@@ -107,6 +137,11 @@ var outlineTrailing = {
|
|
|
107
137
|
disabled: {
|
|
108
138
|
kVAM5u: "musaex-utl9qk",
|
|
109
139
|
$$css: true
|
|
140
|
+
},
|
|
141
|
+
invalid: {
|
|
142
|
+
kVAM5u: "musaex-1ofxpqo",
|
|
143
|
+
k6qhrQ: "musaex-7rzjjb",
|
|
144
|
+
$$css: true
|
|
110
145
|
}
|
|
111
146
|
};
|
|
112
147
|
var outlineNotch = {
|
|
@@ -123,18 +158,27 @@ var outlineNotch = {
|
|
|
123
158
|
kVAM5u: "musaex-1t7i6ks",
|
|
124
159
|
kjGldf: "musaex-aafj1c",
|
|
125
160
|
kLoX6v: "musaex-kap2c3",
|
|
126
|
-
|
|
161
|
+
kVixrW: "musaex-hkrz9u",
|
|
127
162
|
k6qhrQ: "musaex-48fzr0",
|
|
163
|
+
$$css: true
|
|
164
|
+
},
|
|
165
|
+
withLabel: {
|
|
166
|
+
k3lJl8: "musaex-14zl4sw",
|
|
128
167
|
kRj6wj: "musaex-1bq66p9",
|
|
129
168
|
$$css: true
|
|
130
169
|
},
|
|
131
|
-
|
|
170
|
+
withLabelAndPlaceholder: {
|
|
132
171
|
kLZC3w: "musaex-1v8p93f",
|
|
133
172
|
$$css: true
|
|
134
173
|
},
|
|
135
174
|
disabled: {
|
|
136
175
|
kVAM5u: "musaex-utl9qk",
|
|
137
176
|
$$css: true
|
|
177
|
+
},
|
|
178
|
+
invalid: {
|
|
179
|
+
kVAM5u: "musaex-1ofxpqo",
|
|
180
|
+
k6qhrQ: "musaex-7rzjjb",
|
|
181
|
+
$$css: true
|
|
138
182
|
}
|
|
139
183
|
};
|
|
140
184
|
var floatingLabel = {
|
|
@@ -156,6 +200,11 @@ var floatingLabel = {
|
|
|
156
200
|
k3aq6I: "musaex-3oybdh",
|
|
157
201
|
$$css: true
|
|
158
202
|
},
|
|
203
|
+
invalid: {
|
|
204
|
+
kMwMTN: "musaex-jt36v0",
|
|
205
|
+
kan248: "musaex-19uxsja",
|
|
206
|
+
$$css: true
|
|
207
|
+
},
|
|
159
208
|
disabled: {
|
|
160
209
|
kMwMTN: "musaex-1ldep6k",
|
|
161
210
|
$$css: true
|
|
@@ -164,6 +213,8 @@ var floatingLabel = {
|
|
|
164
213
|
var styles = {
|
|
165
214
|
root: root,
|
|
166
215
|
input: input,
|
|
216
|
+
leading: leading,
|
|
217
|
+
trailing: trailing,
|
|
167
218
|
outline: outline,
|
|
168
219
|
outlineLeading: outlineLeading,
|
|
169
220
|
outlineNotch: outlineNotch,
|
|
@@ -19,12 +19,6 @@ declare const styles: {
|
|
|
19
19
|
readonly paddingBlock: import("@stylexjs/stylex").StyleXClassNameFor<"paddingBlock", string>;
|
|
20
20
|
readonly paddingInline: import("@stylexjs/stylex").StyleXClassNameFor<"paddingInline", string>;
|
|
21
21
|
}>;
|
|
22
|
-
readonly invalid: Readonly<{
|
|
23
|
-
readonly boxShadow: import("@stylexjs/stylex").StyleXClassNameFor<"boxShadow", `0px 0px 0px ${import("@stylexjs/stylex").StyleXVar<string>} var(--color-error) inset`>;
|
|
24
|
-
readonly ":focus-within": import("@stylexjs/stylex").StyleXClassNameFor<":focus-within", {
|
|
25
|
-
readonly boxShadow: null;
|
|
26
|
-
}>;
|
|
27
|
-
}>;
|
|
28
22
|
readonly disabled: Readonly<{
|
|
29
23
|
readonly color: import("@stylexjs/stylex").StyleXClassNameFor<"color", "var(--color-on-surface-opacity-38)">;
|
|
30
24
|
}>;
|
|
@@ -33,13 +27,23 @@ declare const styles: {
|
|
|
33
27
|
readonly base: Readonly<{
|
|
34
28
|
readonly lineHeight: import("@stylexjs/stylex").StyleXClassNameFor<"lineHeight", "inherit">;
|
|
35
29
|
readonly fontSize: import("@stylexjs/stylex").StyleXClassNameFor<"fontSize", "inherit">;
|
|
36
|
-
readonly
|
|
30
|
+
readonly paddingBlock: import("@stylexjs/stylex").StyleXClassNameFor<"paddingBlock", string>;
|
|
31
|
+
readonly paddingInline: import("@stylexjs/stylex").StyleXClassNameFor<"paddingInline", string>;
|
|
37
32
|
readonly borderWidth: import("@stylexjs/stylex").StyleXClassNameFor<"borderWidth", string>;
|
|
38
33
|
readonly backgroundColor: import("@stylexjs/stylex").StyleXClassNameFor<"backgroundColor", "transparent">;
|
|
39
34
|
readonly outline: import("@stylexjs/stylex").StyleXClassNameFor<"outline", string>;
|
|
40
35
|
readonly minWidth: import("@stylexjs/stylex").StyleXClassNameFor<"minWidth", string>;
|
|
41
36
|
readonly height: import("@stylexjs/stylex").StyleXClassNameFor<"height", string>;
|
|
42
37
|
readonly flex: import("@stylexjs/stylex").StyleXClassNameFor<"flex", 1>;
|
|
38
|
+
readonly "::placeholder": import("@stylexjs/stylex").StyleXClassNameFor<"::placeholder", {
|
|
39
|
+
readonly color: "var(--color-on-surface-variant)";
|
|
40
|
+
}>;
|
|
41
|
+
}>;
|
|
42
|
+
readonly hasLeading: Readonly<{
|
|
43
|
+
readonly paddingInlineStart: import("@stylexjs/stylex").StyleXClassNameFor<"paddingInlineStart", string>;
|
|
44
|
+
}>;
|
|
45
|
+
readonly hasTrailing: Readonly<{
|
|
46
|
+
readonly paddingInlineEnd: import("@stylexjs/stylex").StyleXClassNameFor<"paddingInlineEnd", string>;
|
|
43
47
|
}>;
|
|
44
48
|
readonly disabled: Readonly<{
|
|
45
49
|
readonly "::placeholder": import("@stylexjs/stylex").StyleXClassNameFor<"::placeholder", {
|
|
@@ -47,6 +51,24 @@ declare const styles: {
|
|
|
47
51
|
}>;
|
|
48
52
|
}>;
|
|
49
53
|
}>;
|
|
54
|
+
leading: Readonly<{
|
|
55
|
+
readonly base: Readonly<{
|
|
56
|
+
readonly position: import("@stylexjs/stylex").StyleXClassNameFor<"position", "absolute">;
|
|
57
|
+
readonly insetBlock: import("@stylexjs/stylex").StyleXClassNameFor<"insetBlock", string>;
|
|
58
|
+
readonly insetInlineStart: import("@stylexjs/stylex").StyleXClassNameFor<"insetInlineStart", string>;
|
|
59
|
+
readonly display: import("@stylexjs/stylex").StyleXClassNameFor<"display", "inline-flex">;
|
|
60
|
+
readonly alignItems: import("@stylexjs/stylex").StyleXClassNameFor<"alignItems", "center">;
|
|
61
|
+
}>;
|
|
62
|
+
}>;
|
|
63
|
+
trailing: Readonly<{
|
|
64
|
+
readonly base: Readonly<{
|
|
65
|
+
readonly position: import("@stylexjs/stylex").StyleXClassNameFor<"position", "absolute">;
|
|
66
|
+
readonly insetBlock: import("@stylexjs/stylex").StyleXClassNameFor<"insetBlock", string>;
|
|
67
|
+
readonly insetInlineEnd: import("@stylexjs/stylex").StyleXClassNameFor<"insetInlineEnd", string>;
|
|
68
|
+
readonly display: import("@stylexjs/stylex").StyleXClassNameFor<"display", "inline-flex">;
|
|
69
|
+
readonly alignItems: import("@stylexjs/stylex").StyleXClassNameFor<"alignItems", "center">;
|
|
70
|
+
}>;
|
|
71
|
+
}>;
|
|
50
72
|
outline: Readonly<{
|
|
51
73
|
readonly base: Readonly<{
|
|
52
74
|
readonly position: import("@stylexjs/stylex").StyleXClassNameFor<"position", "absolute">;
|
|
@@ -78,13 +100,18 @@ declare const styles: {
|
|
|
78
100
|
readonly disabled: Readonly<{
|
|
79
101
|
readonly borderColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderColor", "var(--color-on-surface-opacity-12)">;
|
|
80
102
|
}>;
|
|
103
|
+
readonly invalid: Readonly<{
|
|
104
|
+
readonly [x: string]: import("@stylexjs/stylex").StyleXClassNameFor<string, "var(--color-error)" | {
|
|
105
|
+
readonly borderColor: "var(--color-error)";
|
|
106
|
+
}>;
|
|
107
|
+
readonly borderColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderColor", "var(--color-error)">;
|
|
108
|
+
}>;
|
|
81
109
|
}>;
|
|
82
110
|
outlineNotch: Readonly<{
|
|
83
111
|
readonly base: Readonly<{
|
|
84
112
|
readonly [x: string]: import("@stylexjs/stylex").StyleXClassNameFor<string, string | {
|
|
85
|
-
readonly
|
|
113
|
+
readonly borderBlockWidth: import("@stylexjs/stylex").StyleXVar<string>;
|
|
86
114
|
readonly borderColor: "var(--color-primary)";
|
|
87
|
-
readonly borderBlockStartColor: "transparent";
|
|
88
115
|
}>;
|
|
89
116
|
readonly boxSizing: import("@stylexjs/stylex").StyleXClassNameFor<"boxSizing", "border-box">;
|
|
90
117
|
readonly display: import("@stylexjs/stylex").StyleXClassNameFor<"display", "flex">;
|
|
@@ -99,12 +126,24 @@ declare const styles: {
|
|
|
99
126
|
readonly borderInlineWidth: import("@stylexjs/stylex").StyleXClassNameFor<"borderInlineWidth", string>;
|
|
100
127
|
readonly borderBlockWidth: import("@stylexjs/stylex").StyleXClassNameFor<"borderBlockWidth", string>;
|
|
101
128
|
}>;
|
|
102
|
-
readonly
|
|
129
|
+
readonly withLabel: Readonly<{
|
|
130
|
+
readonly [x: string]: import("@stylexjs/stylex").StyleXClassNameFor<string, {
|
|
131
|
+
readonly borderBlockStartWidth: import("@stylexjs/stylex").StyleXVar<string>;
|
|
132
|
+
readonly borderBlockStartColor: "transparent";
|
|
133
|
+
}>;
|
|
134
|
+
}>;
|
|
135
|
+
readonly withLabelAndPlaceholder: Readonly<{
|
|
103
136
|
readonly borderBlockStartColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderBlockStartColor", "transparent">;
|
|
104
137
|
}>;
|
|
105
138
|
readonly disabled: Readonly<{
|
|
106
139
|
readonly borderColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderColor", "var(--color-on-surface-opacity-12)">;
|
|
107
140
|
}>;
|
|
141
|
+
readonly invalid: Readonly<{
|
|
142
|
+
readonly [x: string]: import("@stylexjs/stylex").StyleXClassNameFor<string, "var(--color-error)" | {
|
|
143
|
+
readonly borderColor: "var(--color-error)";
|
|
144
|
+
}>;
|
|
145
|
+
readonly borderColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderColor", "var(--color-error)">;
|
|
146
|
+
}>;
|
|
108
147
|
}>;
|
|
109
148
|
outlineTrailing: Readonly<{
|
|
110
149
|
readonly base: Readonly<{
|
|
@@ -129,6 +168,12 @@ declare const styles: {
|
|
|
129
168
|
readonly disabled: Readonly<{
|
|
130
169
|
readonly borderColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderColor", "var(--color-on-surface-opacity-12)">;
|
|
131
170
|
}>;
|
|
171
|
+
readonly invalid: Readonly<{
|
|
172
|
+
readonly [x: string]: import("@stylexjs/stylex").StyleXClassNameFor<string, "var(--color-error)" | {
|
|
173
|
+
readonly borderColor: "var(--color-error)";
|
|
174
|
+
}>;
|
|
175
|
+
readonly borderColor: import("@stylexjs/stylex").StyleXClassNameFor<"borderColor", "var(--color-error)">;
|
|
176
|
+
}>;
|
|
132
177
|
}>;
|
|
133
178
|
floatingLabel: Readonly<{
|
|
134
179
|
readonly base: Readonly<{
|
|
@@ -149,6 +194,12 @@ declare const styles: {
|
|
|
149
194
|
readonly top: import("@stylexjs/stylex").StyleXClassNameFor<"top", "-50%">;
|
|
150
195
|
readonly transform: import("@stylexjs/stylex").StyleXClassNameFor<"transform", "scale(1)">;
|
|
151
196
|
}>;
|
|
197
|
+
readonly invalid: Readonly<{
|
|
198
|
+
readonly [x: string]: import("@stylexjs/stylex").StyleXClassNameFor<string, "var(--color-error)" | {
|
|
199
|
+
readonly color: "var(--color-error)";
|
|
200
|
+
}>;
|
|
201
|
+
readonly color: import("@stylexjs/stylex").StyleXClassNameFor<"color", "var(--color-error)">;
|
|
202
|
+
}>;
|
|
152
203
|
readonly disabled: Readonly<{
|
|
153
204
|
readonly color: import("@stylexjs/stylex").StyleXClassNameFor<"color", "var(--color-on-surface-opacity-38)">;
|
|
154
205
|
}>;
|
|
@@ -17,12 +17,7 @@ var root = {
|
|
|
17
17
|
kB7OPa: "musaex-9f619",
|
|
18
18
|
kogj98: "musaex-q3gua8",
|
|
19
19
|
k8WAf4: "musaex-11owsmz",
|
|
20
|
-
kg3NbH: "musaex-
|
|
21
|
-
$$css: true
|
|
22
|
-
},
|
|
23
|
-
invalid: {
|
|
24
|
-
kGVxlE: "musaex-4ms1xy",
|
|
25
|
-
knuKkz: null,
|
|
20
|
+
kg3NbH: "musaex-2961ne",
|
|
26
21
|
$$css: true
|
|
27
22
|
},
|
|
28
23
|
disabled: {
|
|
@@ -34,13 +29,23 @@ var input = {
|
|
|
34
29
|
base: {
|
|
35
30
|
kLWn49: "musaex-15bjb6t",
|
|
36
31
|
kGuDYH: "musaex-1qlqyl8",
|
|
37
|
-
|
|
32
|
+
k8WAf4: "musaex-6yerk0",
|
|
33
|
+
kg3NbH: "musaex-1v4gb6w",
|
|
38
34
|
kMzoRj: "musaex-k59kd",
|
|
39
35
|
kWkggS: "musaex-jbqb8w",
|
|
40
36
|
kI3sdo: "musaex-4fx59i",
|
|
41
37
|
k7Eaqz: "musaex-1rdiejn",
|
|
42
38
|
kZKoxP: "musaex-kyvkcq",
|
|
43
39
|
kUk6DE: "musaex-98rzlu",
|
|
40
|
+
k8Qsv1: "musaex-19r3k9r",
|
|
41
|
+
$$css: true
|
|
42
|
+
},
|
|
43
|
+
hasLeading: {
|
|
44
|
+
kZCmMZ: "musaex-t0f09o",
|
|
45
|
+
$$css: true
|
|
46
|
+
},
|
|
47
|
+
hasTrailing: {
|
|
48
|
+
kwRFfy: "musaex-1kav6dm",
|
|
44
49
|
$$css: true
|
|
45
50
|
},
|
|
46
51
|
disabled: {
|
|
@@ -48,6 +53,26 @@ var input = {
|
|
|
48
53
|
$$css: true
|
|
49
54
|
}
|
|
50
55
|
};
|
|
56
|
+
var leading = {
|
|
57
|
+
base: {
|
|
58
|
+
kVAEAm: "musaex-10l6tqk",
|
|
59
|
+
kYYq5F: "musaex-vg9ial",
|
|
60
|
+
kLqNvP: "musaex-82zlsq",
|
|
61
|
+
k1xSpc: "musaex-3nfvp2",
|
|
62
|
+
kGNEyG: "musaex-6s0dn4",
|
|
63
|
+
$$css: true
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
var trailing = {
|
|
67
|
+
base: {
|
|
68
|
+
kVAEAm: "musaex-10l6tqk",
|
|
69
|
+
kYYq5F: "musaex-vg9ial",
|
|
70
|
+
kt4wiu: "musaex-1swhz51",
|
|
71
|
+
k1xSpc: "musaex-3nfvp2",
|
|
72
|
+
kGNEyG: "musaex-6s0dn4",
|
|
73
|
+
$$css: true
|
|
74
|
+
}
|
|
75
|
+
};
|
|
51
76
|
var outline = {
|
|
52
77
|
base: {
|
|
53
78
|
kVAEAm: "musaex-10l6tqk",
|
|
@@ -79,6 +104,11 @@ var outlineLeading = {
|
|
|
79
104
|
disabled: {
|
|
80
105
|
kVAM5u: "musaex-utl9qk",
|
|
81
106
|
$$css: true
|
|
107
|
+
},
|
|
108
|
+
invalid: {
|
|
109
|
+
kVAM5u: "musaex-1ofxpqo",
|
|
110
|
+
k6qhrQ: "musaex-7rzjjb",
|
|
111
|
+
$$css: true
|
|
82
112
|
}
|
|
83
113
|
};
|
|
84
114
|
var outlineTrailing = {
|
|
@@ -103,6 +133,11 @@ var outlineTrailing = {
|
|
|
103
133
|
disabled: {
|
|
104
134
|
kVAM5u: "musaex-utl9qk",
|
|
105
135
|
$$css: true
|
|
136
|
+
},
|
|
137
|
+
invalid: {
|
|
138
|
+
kVAM5u: "musaex-1ofxpqo",
|
|
139
|
+
k6qhrQ: "musaex-7rzjjb",
|
|
140
|
+
$$css: true
|
|
106
141
|
}
|
|
107
142
|
};
|
|
108
143
|
var outlineNotch = {
|
|
@@ -119,18 +154,27 @@ var outlineNotch = {
|
|
|
119
154
|
kVAM5u: "musaex-1t7i6ks",
|
|
120
155
|
kjGldf: "musaex-aafj1c",
|
|
121
156
|
kLoX6v: "musaex-kap2c3",
|
|
122
|
-
|
|
157
|
+
kVixrW: "musaex-hkrz9u",
|
|
123
158
|
k6qhrQ: "musaex-48fzr0",
|
|
159
|
+
$$css: true
|
|
160
|
+
},
|
|
161
|
+
withLabel: {
|
|
162
|
+
k3lJl8: "musaex-14zl4sw",
|
|
124
163
|
kRj6wj: "musaex-1bq66p9",
|
|
125
164
|
$$css: true
|
|
126
165
|
},
|
|
127
|
-
|
|
166
|
+
withLabelAndPlaceholder: {
|
|
128
167
|
kLZC3w: "musaex-1v8p93f",
|
|
129
168
|
$$css: true
|
|
130
169
|
},
|
|
131
170
|
disabled: {
|
|
132
171
|
kVAM5u: "musaex-utl9qk",
|
|
133
172
|
$$css: true
|
|
173
|
+
},
|
|
174
|
+
invalid: {
|
|
175
|
+
kVAM5u: "musaex-1ofxpqo",
|
|
176
|
+
k6qhrQ: "musaex-7rzjjb",
|
|
177
|
+
$$css: true
|
|
134
178
|
}
|
|
135
179
|
};
|
|
136
180
|
var floatingLabel = {
|
|
@@ -152,6 +196,11 @@ var floatingLabel = {
|
|
|
152
196
|
k3aq6I: "musaex-3oybdh",
|
|
153
197
|
$$css: true
|
|
154
198
|
},
|
|
199
|
+
invalid: {
|
|
200
|
+
kMwMTN: "musaex-jt36v0",
|
|
201
|
+
kan248: "musaex-19uxsja",
|
|
202
|
+
$$css: true
|
|
203
|
+
},
|
|
155
204
|
disabled: {
|
|
156
205
|
kMwMTN: "musaex-1ldep6k",
|
|
157
206
|
$$css: true
|
|
@@ -160,6 +209,8 @@ var floatingLabel = {
|
|
|
160
209
|
var styles = {
|
|
161
210
|
root: root,
|
|
162
211
|
input: input,
|
|
212
|
+
leading: leading,
|
|
213
|
+
trailing: trailing,
|
|
163
214
|
outline: outline,
|
|
164
215
|
outlineLeading: outlineLeading,
|
|
165
216
|
outlineNotch: outlineNotch,
|
package/dist/styles.css
CHANGED
|
@@ -352,6 +352,10 @@
|
|
|
352
352
|
grid-template-areas: var(--layout);
|
|
353
353
|
}
|
|
354
354
|
|
|
355
|
+
.musaex-vg9ial {
|
|
356
|
+
inset-block: var(--musaex-1fxazvh);
|
|
357
|
+
}
|
|
358
|
+
|
|
355
359
|
.musaex-17y0mx6 {
|
|
356
360
|
inset-inline: 0;
|
|
357
361
|
}
|
|
@@ -512,6 +516,10 @@
|
|
|
512
516
|
transition: transform .3s;
|
|
513
517
|
}
|
|
514
518
|
|
|
519
|
+
.musaex-7rzjjb.musaex-7rzjjb:where(.musaex-19ap9w9:focus-within *) {
|
|
520
|
+
border-color: var(--color-error);
|
|
521
|
+
}
|
|
522
|
+
|
|
515
523
|
.musaex-48fzr0.musaex-48fzr0:where(.musaex-19ap9w9:focus-within *) {
|
|
516
524
|
border-color: var(--color-primary);
|
|
517
525
|
}
|
|
@@ -796,10 +804,6 @@
|
|
|
796
804
|
border-start-start-radius: var(--musaex-17d148i);
|
|
797
805
|
}
|
|
798
806
|
|
|
799
|
-
.musaex-4ms1xy {
|
|
800
|
-
box-shadow: 0 0 0 var(--musaex-1035pbm) var(--color-error) inset;
|
|
801
|
-
}
|
|
802
|
-
|
|
803
807
|
.musaex-bxw2on {
|
|
804
808
|
box-shadow: 0 0 0 var(--musaex-1xf102v) var(--color-on-primary);
|
|
805
809
|
}
|
|
@@ -1172,6 +1176,10 @@
|
|
|
1172
1176
|
inset-inline-end: 0;
|
|
1173
1177
|
}
|
|
1174
1178
|
|
|
1179
|
+
.musaex-1swhz51 {
|
|
1180
|
+
inset-inline-end: var(--musaex-14eq97i);
|
|
1181
|
+
}
|
|
1182
|
+
|
|
1175
1183
|
.musaex-1aovfyv {
|
|
1176
1184
|
inset-inline-end: var(--musaex-1bvtfky);
|
|
1177
1185
|
}
|
|
@@ -1192,6 +1200,10 @@
|
|
|
1192
1200
|
inset-inline-start: var(--musaex-12cvltn);
|
|
1193
1201
|
}
|
|
1194
1202
|
|
|
1203
|
+
.musaex-82zlsq {
|
|
1204
|
+
inset-inline-start: var(--musaex-14eq97i);
|
|
1205
|
+
}
|
|
1206
|
+
|
|
1195
1207
|
.musaex-lrh9k8 {
|
|
1196
1208
|
inset-inline-start: var(--musaex-1ninzqv);
|
|
1197
1209
|
}
|
|
@@ -1432,6 +1444,10 @@
|
|
|
1432
1444
|
padding-inline-end: var(--musaex-1vpnstl);
|
|
1433
1445
|
}
|
|
1434
1446
|
|
|
1447
|
+
.musaex-1kav6dm {
|
|
1448
|
+
padding-inline-end: var(--musaex-mk8wyj);
|
|
1449
|
+
}
|
|
1450
|
+
|
|
1435
1451
|
.musaex-1sznsej {
|
|
1436
1452
|
padding-inline-start: calc(var(--depth) * var(--musaex-14eq97i));
|
|
1437
1453
|
}
|
|
@@ -1460,6 +1476,10 @@
|
|
|
1460
1476
|
padding-inline-start: var(--musaex-1vpnstl);
|
|
1461
1477
|
}
|
|
1462
1478
|
|
|
1479
|
+
.musaex-t0f09o {
|
|
1480
|
+
padding-inline-start: var(--musaex-mk8wyj);
|
|
1481
|
+
}
|
|
1482
|
+
|
|
1463
1483
|
.musaex-67bb7w {
|
|
1464
1484
|
pointer-events: auto;
|
|
1465
1485
|
}
|
|
@@ -1821,6 +1841,10 @@
|
|
|
1821
1841
|
border-inline-start-width: var(--musaex-1035pbm);
|
|
1822
1842
|
}
|
|
1823
1843
|
|
|
1844
|
+
.musaex-19uxsja.musaex-19uxsja:where(.musaex-19ap9w9:focus-within *) {
|
|
1845
|
+
color: var(--color-error);
|
|
1846
|
+
}
|
|
1847
|
+
|
|
1824
1848
|
.musaex-1lxvvmp.musaex-1lxvvmp:where(.musaex-19ap9w9:focus-within *) {
|
|
1825
1849
|
color: var(--color-primary);
|
|
1826
1850
|
}
|
|
@@ -2661,14 +2685,14 @@
|
|
|
2661
2685
|
width: var(--width);
|
|
2662
2686
|
}
|
|
2663
2687
|
|
|
2664
|
-
.musaex-1wg96mr.musaex-1wg96mr:where(.musaex-19ap9w9:focus-within *) {
|
|
2665
|
-
border-bottom-width: var(--musaex-1035pbm);
|
|
2666
|
-
}
|
|
2667
|
-
|
|
2668
2688
|
.musaex-1bq66p9.musaex-1bq66p9:where(.musaex-19ap9w9:focus-within *) {
|
|
2669
2689
|
border-top-color: #0000;
|
|
2670
2690
|
}
|
|
2671
2691
|
|
|
2692
|
+
.musaex-14zl4sw.musaex-14zl4sw:where(.musaex-19ap9w9:focus-within *) {
|
|
2693
|
+
border-top-width: var(--musaex-1xf102v);
|
|
2694
|
+
}
|
|
2695
|
+
|
|
2672
2696
|
.musaex-1skm1u1.musaex-1skm1u1:where(.musaex-19ap9w9:focus-within *) {
|
|
2673
2697
|
top: -50%;
|
|
2674
2698
|
}
|
|
@@ -2863,6 +2887,10 @@
|
|
|
2863
2887
|
color: var(--color-on-surface-opacity-38);
|
|
2864
2888
|
}
|
|
2865
2889
|
|
|
2890
|
+
.musaex-19r3k9r::placeholder {
|
|
2891
|
+
color: var(--color-on-surface-variant);
|
|
2892
|
+
}
|
|
2893
|
+
|
|
2866
2894
|
.musaex-100rkj9:after, .musaex-10tli2e:before, .musaex-1cpjm7i:before, .musaex-1s928wv:after {
|
|
2867
2895
|
content: "";
|
|
2868
2896
|
}
|
package/dist/types/input.d.ts
CHANGED