iobroker.vis-2-widgets-collection 2.0.2 → 2.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -0
- package/io-package.json +27 -27
- package/package.json +1 -1
- package/widgets/vis-2-widgets-collection/assets/Button-BK3gDuCC.js +677 -0
- package/widgets/vis-2-widgets-collection/assets/ButtonGroupCollectionWidget-Bjl7COzs.js +687 -0
- package/widgets/vis-2-widgets-collection/assets/CheckboxCollectionWidget-8WjweMs2.js +440 -0
- package/widgets/vis-2-widgets-collection/assets/Close-APpa6HX8.js +18 -0
- package/widgets/vis-2-widgets-collection/assets/DialogCollectionWidget-o_rzKqrW.js +485 -0
- package/widgets/vis-2-widgets-collection/assets/FormControlLabel-CHae4jKA.js +207 -0
- package/widgets/vis-2-widgets-collection/assets/GaugeCollectionWidget-C7OFMKbW.js +2860 -0
- package/widgets/vis-2-widgets-collection/assets/Light2CollectionWidget-C_bjOKZG.js +2733 -0
- package/widgets/vis-2-widgets-collection/assets/RadioGroupCollectionWidget-dntcZhrq.js +538 -0
- package/widgets/vis-2-widgets-collection/assets/SafeImg-DHsE-xU3.js +29 -0
- package/widgets/vis-2-widgets-collection/assets/SelectCollectionWidget-Dh93X-tG.js +2545 -0
- package/widgets/vis-2-widgets-collection/assets/Stack-Dzb7Q6ZE.js +132 -0
- package/widgets/vis-2-widgets-collection/assets/StateCollectionWidget-Cp6J4wqx.js +1610 -0
- package/widgets/vis-2-widgets-collection/assets/SwitchBase-C4gssu33.js +204 -0
- package/widgets/vis-2-widgets-collection/assets/SwitchCollectionWidget-2KPRtnA9.js +572 -0
- package/widgets/vis-2-widgets-collection/assets/_commonjsHelpers-Cpj98o6Y.js +8 -0
- package/widgets/vis-2-widgets-collection/assets/commonFields-Dc3dYGx-.js +20628 -0
- package/widgets/vis-2-widgets-collection/assets/formControlState-Dq1zat_P.js +6 -0
- package/widgets/vis-2-widgets-collection/assets/hostInit-D6momM_S.js +9 -0
- package/widgets/vis-2-widgets-collection/assets/index-B5Qt9EMX.js +18 -0
- package/widgets/vis-2-widgets-collection/assets/index-BEpFHtMA.js +249 -0
- package/widgets/vis-2-widgets-collection/assets/index-DMBzzD-N.js +6098 -0
- package/widgets/vis-2-widgets-collection/assets/listItemTextClasses-DQeLHf2R.js +120 -0
- package/widgets/vis-2-widgets-collection/assets/preload-helper-PPVm8Dsz.js +36 -0
- package/widgets/vis-2-widgets-collection/assets/translations-DXoq3Ras.js +9 -0
- package/widgets/vis-2-widgets-collection/assets/useFormControl--TM4wVzV.js +20 -0
- package/widgets/vis-2-widgets-collection/assets/useHtmlValue-Dcwl_hqT.js +27 -0
- package/widgets/vis-2-widgets-collection/assets/useOidValue-DGq_wsMY.js +35 -0
- package/widgets/vis-2-widgets-collection/assets/virtualExposes-B50cAOvG.js +118 -0
- package/widgets/vis-2-widgets-collection/assets/vis2CollectionWidget__loadShare__react__loadShare__-L1bZe9z4.js +45 -0
- package/widgets/vis-2-widgets-collection/assets/vis2CollectionWidget__mf_v__runtimeInit__mf_v__-Cugi9Gwb.js +12 -0
- package/widgets/vis-2-widgets-collection/img/prev-collection-checkbox.png +0 -0
- package/widgets/vis-2-widgets-collection/img/prev-collection-dialog.png +0 -0
- package/widgets/vis-2-widgets-collection/img/prev-collection-gauge.png +0 -0
- package/widgets/vis-2-widgets-collection/img/prev-collection-light.png +0 -0
- package/widgets/vis-2-widgets-collection/img/prev-collection-radio-group.png +0 -0
- package/widgets/vis-2-widgets-collection/img/prev-collection-select.png +0 -0
|
@@ -0,0 +1,677 @@
|
|
|
1
|
+
import { v as x, __tla as __tla_0 } from "./vis2CollectionWidget__loadShare__react__loadShare__-L1bZe9z4.js";
|
|
2
|
+
import { a as G, g as D, N as H, u as A, h as q, j as e, s as y, d as m, i, e as J, n as K, r as Q, m as X, o as v, O as Y, am as Z, __tla as __tla_1 } from "./commonFields-Dc3dYGx-.js";
|
|
3
|
+
let co;
|
|
4
|
+
let __tla = Promise.all([
|
|
5
|
+
(() => {
|
|
6
|
+
try {
|
|
7
|
+
return __tla_0;
|
|
8
|
+
} catch {
|
|
9
|
+
}
|
|
10
|
+
})(),
|
|
11
|
+
(() => {
|
|
12
|
+
try {
|
|
13
|
+
return __tla_1;
|
|
14
|
+
} catch {
|
|
15
|
+
}
|
|
16
|
+
})()
|
|
17
|
+
]).then(async () => {
|
|
18
|
+
function oo(o) {
|
|
19
|
+
return D("MuiButton", o);
|
|
20
|
+
}
|
|
21
|
+
let d, ao, to, no, L, io, ro, eo, so, E;
|
|
22
|
+
d = G("MuiButton", [
|
|
23
|
+
"root",
|
|
24
|
+
"text",
|
|
25
|
+
"textInherit",
|
|
26
|
+
"textPrimary",
|
|
27
|
+
"textSecondary",
|
|
28
|
+
"textSuccess",
|
|
29
|
+
"textError",
|
|
30
|
+
"textInfo",
|
|
31
|
+
"textWarning",
|
|
32
|
+
"outlined",
|
|
33
|
+
"outlinedInherit",
|
|
34
|
+
"outlinedPrimary",
|
|
35
|
+
"outlinedSecondary",
|
|
36
|
+
"outlinedSuccess",
|
|
37
|
+
"outlinedError",
|
|
38
|
+
"outlinedInfo",
|
|
39
|
+
"outlinedWarning",
|
|
40
|
+
"contained",
|
|
41
|
+
"containedInherit",
|
|
42
|
+
"containedPrimary",
|
|
43
|
+
"containedSecondary",
|
|
44
|
+
"containedSuccess",
|
|
45
|
+
"containedError",
|
|
46
|
+
"containedInfo",
|
|
47
|
+
"containedWarning",
|
|
48
|
+
"disableElevation",
|
|
49
|
+
"focusVisible",
|
|
50
|
+
"disabled",
|
|
51
|
+
"colorInherit",
|
|
52
|
+
"colorPrimary",
|
|
53
|
+
"colorSecondary",
|
|
54
|
+
"colorSuccess",
|
|
55
|
+
"colorError",
|
|
56
|
+
"colorInfo",
|
|
57
|
+
"colorWarning",
|
|
58
|
+
"textSizeSmall",
|
|
59
|
+
"textSizeMedium",
|
|
60
|
+
"textSizeLarge",
|
|
61
|
+
"outlinedSizeSmall",
|
|
62
|
+
"outlinedSizeMedium",
|
|
63
|
+
"outlinedSizeLarge",
|
|
64
|
+
"containedSizeSmall",
|
|
65
|
+
"containedSizeMedium",
|
|
66
|
+
"containedSizeLarge",
|
|
67
|
+
"sizeMedium",
|
|
68
|
+
"sizeSmall",
|
|
69
|
+
"sizeLarge",
|
|
70
|
+
"fullWidth",
|
|
71
|
+
"startIcon",
|
|
72
|
+
"endIcon",
|
|
73
|
+
"icon",
|
|
74
|
+
"iconSizeSmall",
|
|
75
|
+
"iconSizeMedium",
|
|
76
|
+
"iconSizeLarge",
|
|
77
|
+
"loading",
|
|
78
|
+
"loadingWrapper",
|
|
79
|
+
"loadingIconPlaceholder",
|
|
80
|
+
"loadingIndicator",
|
|
81
|
+
"loadingPositionCenter",
|
|
82
|
+
"loadingPositionStart",
|
|
83
|
+
"loadingPositionEnd"
|
|
84
|
+
]);
|
|
85
|
+
ao = x.createContext({});
|
|
86
|
+
to = x.createContext(void 0);
|
|
87
|
+
no = (o) => {
|
|
88
|
+
const { color: a, disableElevation: t, fullWidth: n, size: p, variant: c, loading: u, loadingPosition: f, classes: b } = o, S = {
|
|
89
|
+
root: [
|
|
90
|
+
"root",
|
|
91
|
+
u && "loading",
|
|
92
|
+
c,
|
|
93
|
+
`${c}${i(a)}`,
|
|
94
|
+
`size${i(p)}`,
|
|
95
|
+
`${c}Size${i(p)}`,
|
|
96
|
+
`color${i(a)}`,
|
|
97
|
+
t && "disableElevation",
|
|
98
|
+
n && "fullWidth",
|
|
99
|
+
u && `loadingPosition${i(f)}`
|
|
100
|
+
],
|
|
101
|
+
startIcon: [
|
|
102
|
+
"icon",
|
|
103
|
+
"startIcon",
|
|
104
|
+
`iconSize${i(p)}`
|
|
105
|
+
],
|
|
106
|
+
endIcon: [
|
|
107
|
+
"icon",
|
|
108
|
+
"endIcon",
|
|
109
|
+
`iconSize${i(p)}`
|
|
110
|
+
],
|
|
111
|
+
loadingIndicator: [
|
|
112
|
+
"loadingIndicator"
|
|
113
|
+
],
|
|
114
|
+
loadingWrapper: [
|
|
115
|
+
"loadingWrapper"
|
|
116
|
+
]
|
|
117
|
+
}, z = J(S, oo, b);
|
|
118
|
+
return {
|
|
119
|
+
...b,
|
|
120
|
+
...z
|
|
121
|
+
};
|
|
122
|
+
};
|
|
123
|
+
L = [
|
|
124
|
+
{
|
|
125
|
+
props: {
|
|
126
|
+
size: "small"
|
|
127
|
+
},
|
|
128
|
+
style: {
|
|
129
|
+
"& > *:nth-of-type(1)": {
|
|
130
|
+
fontSize: 18
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
props: {
|
|
136
|
+
size: "medium"
|
|
137
|
+
},
|
|
138
|
+
style: {
|
|
139
|
+
"& > *:nth-of-type(1)": {
|
|
140
|
+
fontSize: 20
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
props: {
|
|
146
|
+
size: "large"
|
|
147
|
+
},
|
|
148
|
+
style: {
|
|
149
|
+
"& > *:nth-of-type(1)": {
|
|
150
|
+
fontSize: 22
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
];
|
|
155
|
+
io = y(K, {
|
|
156
|
+
shouldForwardProp: (o) => Q(o) || o === "classes",
|
|
157
|
+
name: "MuiButton",
|
|
158
|
+
slot: "Root",
|
|
159
|
+
overridesResolver: (o, a) => {
|
|
160
|
+
const { ownerState: t } = o;
|
|
161
|
+
return [
|
|
162
|
+
a.root,
|
|
163
|
+
a[t.variant],
|
|
164
|
+
a[`${t.variant}${i(t.color)}`],
|
|
165
|
+
a[`size${i(t.size)}`],
|
|
166
|
+
a[`${t.variant}Size${i(t.size)}`],
|
|
167
|
+
t.color === "inherit" && a.colorInherit,
|
|
168
|
+
t.disableElevation && a.disableElevation,
|
|
169
|
+
t.fullWidth && a.fullWidth,
|
|
170
|
+
t.loading && a.loading
|
|
171
|
+
];
|
|
172
|
+
}
|
|
173
|
+
})(X(({ theme: o }) => {
|
|
174
|
+
const a = o.palette.mode === "light" ? o.palette.grey[300] : o.palette.grey[800], t = o.palette.mode === "light" ? o.palette.grey.A100 : o.palette.grey[700];
|
|
175
|
+
return {
|
|
176
|
+
...o.typography.button,
|
|
177
|
+
minWidth: 64,
|
|
178
|
+
padding: "6px 16px",
|
|
179
|
+
border: 0,
|
|
180
|
+
borderRadius: (o.vars || o).shape.borderRadius,
|
|
181
|
+
transition: o.transitions.create([
|
|
182
|
+
"background-color",
|
|
183
|
+
"box-shadow",
|
|
184
|
+
"border-color",
|
|
185
|
+
"color"
|
|
186
|
+
], {
|
|
187
|
+
duration: o.transitions.duration.short
|
|
188
|
+
}),
|
|
189
|
+
"&:hover": {
|
|
190
|
+
textDecoration: "none"
|
|
191
|
+
},
|
|
192
|
+
[`&.${d.disabled}`]: {
|
|
193
|
+
color: (o.vars || o).palette.action.disabled
|
|
194
|
+
},
|
|
195
|
+
variants: [
|
|
196
|
+
{
|
|
197
|
+
props: {
|
|
198
|
+
variant: "contained"
|
|
199
|
+
},
|
|
200
|
+
style: {
|
|
201
|
+
color: "var(--variant-containedColor)",
|
|
202
|
+
backgroundColor: "var(--variant-containedBg)",
|
|
203
|
+
boxShadow: (o.vars || o).shadows[2],
|
|
204
|
+
"&:hover": {
|
|
205
|
+
boxShadow: (o.vars || o).shadows[4],
|
|
206
|
+
"@media (hover: none)": {
|
|
207
|
+
boxShadow: (o.vars || o).shadows[2]
|
|
208
|
+
}
|
|
209
|
+
},
|
|
210
|
+
"&:active": {
|
|
211
|
+
boxShadow: (o.vars || o).shadows[8]
|
|
212
|
+
},
|
|
213
|
+
[`&.${d.focusVisible}`]: {
|
|
214
|
+
boxShadow: (o.vars || o).shadows[6]
|
|
215
|
+
},
|
|
216
|
+
[`&.${d.disabled}`]: {
|
|
217
|
+
color: (o.vars || o).palette.action.disabled,
|
|
218
|
+
boxShadow: (o.vars || o).shadows[0],
|
|
219
|
+
backgroundColor: (o.vars || o).palette.action.disabledBackground
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
props: {
|
|
225
|
+
variant: "outlined"
|
|
226
|
+
},
|
|
227
|
+
style: {
|
|
228
|
+
padding: "5px 15px",
|
|
229
|
+
border: "1px solid currentColor",
|
|
230
|
+
borderColor: "var(--variant-outlinedBorder, currentColor)",
|
|
231
|
+
backgroundColor: "var(--variant-outlinedBg)",
|
|
232
|
+
color: "var(--variant-outlinedColor)",
|
|
233
|
+
[`&.${d.disabled}`]: {
|
|
234
|
+
border: `1px solid ${(o.vars || o).palette.action.disabledBackground}`
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
props: {
|
|
240
|
+
variant: "text"
|
|
241
|
+
},
|
|
242
|
+
style: {
|
|
243
|
+
padding: "6px 8px",
|
|
244
|
+
color: "var(--variant-textColor)",
|
|
245
|
+
backgroundColor: "var(--variant-textBg)"
|
|
246
|
+
}
|
|
247
|
+
},
|
|
248
|
+
...Object.entries(o.palette).filter(Y()).map(([n]) => ({
|
|
249
|
+
props: {
|
|
250
|
+
color: n
|
|
251
|
+
},
|
|
252
|
+
style: {
|
|
253
|
+
"--variant-textColor": (o.vars || o).palette[n].main,
|
|
254
|
+
"--variant-outlinedColor": (o.vars || o).palette[n].main,
|
|
255
|
+
"--variant-outlinedBorder": o.vars ? `rgba(${o.vars.palette[n].mainChannel} / 0.5)` : v(o.palette[n].main, 0.5),
|
|
256
|
+
"--variant-containedColor": (o.vars || o).palette[n].contrastText,
|
|
257
|
+
"--variant-containedBg": (o.vars || o).palette[n].main,
|
|
258
|
+
"@media (hover: hover)": {
|
|
259
|
+
"&:hover": {
|
|
260
|
+
"--variant-containedBg": (o.vars || o).palette[n].dark,
|
|
261
|
+
"--variant-textBg": o.vars ? `rgba(${o.vars.palette[n].mainChannel} / ${o.vars.palette.action.hoverOpacity})` : v(o.palette[n].main, o.palette.action.hoverOpacity),
|
|
262
|
+
"--variant-outlinedBorder": (o.vars || o).palette[n].main,
|
|
263
|
+
"--variant-outlinedBg": o.vars ? `rgba(${o.vars.palette[n].mainChannel} / ${o.vars.palette.action.hoverOpacity})` : v(o.palette[n].main, o.palette.action.hoverOpacity)
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
})),
|
|
268
|
+
{
|
|
269
|
+
props: {
|
|
270
|
+
color: "inherit"
|
|
271
|
+
},
|
|
272
|
+
style: {
|
|
273
|
+
color: "inherit",
|
|
274
|
+
borderColor: "currentColor",
|
|
275
|
+
"--variant-containedBg": o.vars ? o.vars.palette.Button.inheritContainedBg : a,
|
|
276
|
+
"@media (hover: hover)": {
|
|
277
|
+
"&:hover": {
|
|
278
|
+
"--variant-containedBg": o.vars ? o.vars.palette.Button.inheritContainedHoverBg : t,
|
|
279
|
+
"--variant-textBg": o.vars ? `rgba(${o.vars.palette.text.primaryChannel} / ${o.vars.palette.action.hoverOpacity})` : v(o.palette.text.primary, o.palette.action.hoverOpacity),
|
|
280
|
+
"--variant-outlinedBg": o.vars ? `rgba(${o.vars.palette.text.primaryChannel} / ${o.vars.palette.action.hoverOpacity})` : v(o.palette.text.primary, o.palette.action.hoverOpacity)
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
props: {
|
|
287
|
+
size: "small",
|
|
288
|
+
variant: "text"
|
|
289
|
+
},
|
|
290
|
+
style: {
|
|
291
|
+
padding: "4px 5px",
|
|
292
|
+
fontSize: o.typography.pxToRem(13)
|
|
293
|
+
}
|
|
294
|
+
},
|
|
295
|
+
{
|
|
296
|
+
props: {
|
|
297
|
+
size: "large",
|
|
298
|
+
variant: "text"
|
|
299
|
+
},
|
|
300
|
+
style: {
|
|
301
|
+
padding: "8px 11px",
|
|
302
|
+
fontSize: o.typography.pxToRem(15)
|
|
303
|
+
}
|
|
304
|
+
},
|
|
305
|
+
{
|
|
306
|
+
props: {
|
|
307
|
+
size: "small",
|
|
308
|
+
variant: "outlined"
|
|
309
|
+
},
|
|
310
|
+
style: {
|
|
311
|
+
padding: "3px 9px",
|
|
312
|
+
fontSize: o.typography.pxToRem(13)
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
{
|
|
316
|
+
props: {
|
|
317
|
+
size: "large",
|
|
318
|
+
variant: "outlined"
|
|
319
|
+
},
|
|
320
|
+
style: {
|
|
321
|
+
padding: "7px 21px",
|
|
322
|
+
fontSize: o.typography.pxToRem(15)
|
|
323
|
+
}
|
|
324
|
+
},
|
|
325
|
+
{
|
|
326
|
+
props: {
|
|
327
|
+
size: "small",
|
|
328
|
+
variant: "contained"
|
|
329
|
+
},
|
|
330
|
+
style: {
|
|
331
|
+
padding: "4px 10px",
|
|
332
|
+
fontSize: o.typography.pxToRem(13)
|
|
333
|
+
}
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
props: {
|
|
337
|
+
size: "large",
|
|
338
|
+
variant: "contained"
|
|
339
|
+
},
|
|
340
|
+
style: {
|
|
341
|
+
padding: "8px 22px",
|
|
342
|
+
fontSize: o.typography.pxToRem(15)
|
|
343
|
+
}
|
|
344
|
+
},
|
|
345
|
+
{
|
|
346
|
+
props: {
|
|
347
|
+
disableElevation: true
|
|
348
|
+
},
|
|
349
|
+
style: {
|
|
350
|
+
boxShadow: "none",
|
|
351
|
+
"&:hover": {
|
|
352
|
+
boxShadow: "none"
|
|
353
|
+
},
|
|
354
|
+
[`&.${d.focusVisible}`]: {
|
|
355
|
+
boxShadow: "none"
|
|
356
|
+
},
|
|
357
|
+
"&:active": {
|
|
358
|
+
boxShadow: "none"
|
|
359
|
+
},
|
|
360
|
+
[`&.${d.disabled}`]: {
|
|
361
|
+
boxShadow: "none"
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
},
|
|
365
|
+
{
|
|
366
|
+
props: {
|
|
367
|
+
fullWidth: true
|
|
368
|
+
},
|
|
369
|
+
style: {
|
|
370
|
+
width: "100%"
|
|
371
|
+
}
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
props: {
|
|
375
|
+
loadingPosition: "center"
|
|
376
|
+
},
|
|
377
|
+
style: {
|
|
378
|
+
transition: o.transitions.create([
|
|
379
|
+
"background-color",
|
|
380
|
+
"box-shadow",
|
|
381
|
+
"border-color"
|
|
382
|
+
], {
|
|
383
|
+
duration: o.transitions.duration.short
|
|
384
|
+
}),
|
|
385
|
+
[`&.${d.loading}`]: {
|
|
386
|
+
color: "transparent"
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
]
|
|
391
|
+
};
|
|
392
|
+
}));
|
|
393
|
+
ro = y("span", {
|
|
394
|
+
name: "MuiButton",
|
|
395
|
+
slot: "StartIcon",
|
|
396
|
+
overridesResolver: (o, a) => {
|
|
397
|
+
const { ownerState: t } = o;
|
|
398
|
+
return [
|
|
399
|
+
a.startIcon,
|
|
400
|
+
t.loading && a.startIconLoadingStart,
|
|
401
|
+
a[`iconSize${i(t.size)}`]
|
|
402
|
+
];
|
|
403
|
+
}
|
|
404
|
+
})(({ theme: o }) => ({
|
|
405
|
+
display: "inherit",
|
|
406
|
+
marginRight: 8,
|
|
407
|
+
marginLeft: -4,
|
|
408
|
+
variants: [
|
|
409
|
+
{
|
|
410
|
+
props: {
|
|
411
|
+
size: "small"
|
|
412
|
+
},
|
|
413
|
+
style: {
|
|
414
|
+
marginLeft: -2
|
|
415
|
+
}
|
|
416
|
+
},
|
|
417
|
+
{
|
|
418
|
+
props: {
|
|
419
|
+
loadingPosition: "start",
|
|
420
|
+
loading: true
|
|
421
|
+
},
|
|
422
|
+
style: {
|
|
423
|
+
transition: o.transitions.create([
|
|
424
|
+
"opacity"
|
|
425
|
+
], {
|
|
426
|
+
duration: o.transitions.duration.short
|
|
427
|
+
}),
|
|
428
|
+
opacity: 0
|
|
429
|
+
}
|
|
430
|
+
},
|
|
431
|
+
{
|
|
432
|
+
props: {
|
|
433
|
+
loadingPosition: "start",
|
|
434
|
+
loading: true,
|
|
435
|
+
fullWidth: true
|
|
436
|
+
},
|
|
437
|
+
style: {
|
|
438
|
+
marginRight: -8
|
|
439
|
+
}
|
|
440
|
+
},
|
|
441
|
+
...L
|
|
442
|
+
]
|
|
443
|
+
}));
|
|
444
|
+
eo = y("span", {
|
|
445
|
+
name: "MuiButton",
|
|
446
|
+
slot: "EndIcon",
|
|
447
|
+
overridesResolver: (o, a) => {
|
|
448
|
+
const { ownerState: t } = o;
|
|
449
|
+
return [
|
|
450
|
+
a.endIcon,
|
|
451
|
+
t.loading && a.endIconLoadingEnd,
|
|
452
|
+
a[`iconSize${i(t.size)}`]
|
|
453
|
+
];
|
|
454
|
+
}
|
|
455
|
+
})(({ theme: o }) => ({
|
|
456
|
+
display: "inherit",
|
|
457
|
+
marginRight: -4,
|
|
458
|
+
marginLeft: 8,
|
|
459
|
+
variants: [
|
|
460
|
+
{
|
|
461
|
+
props: {
|
|
462
|
+
size: "small"
|
|
463
|
+
},
|
|
464
|
+
style: {
|
|
465
|
+
marginRight: -2
|
|
466
|
+
}
|
|
467
|
+
},
|
|
468
|
+
{
|
|
469
|
+
props: {
|
|
470
|
+
loadingPosition: "end",
|
|
471
|
+
loading: true
|
|
472
|
+
},
|
|
473
|
+
style: {
|
|
474
|
+
transition: o.transitions.create([
|
|
475
|
+
"opacity"
|
|
476
|
+
], {
|
|
477
|
+
duration: o.transitions.duration.short
|
|
478
|
+
}),
|
|
479
|
+
opacity: 0
|
|
480
|
+
}
|
|
481
|
+
},
|
|
482
|
+
{
|
|
483
|
+
props: {
|
|
484
|
+
loadingPosition: "end",
|
|
485
|
+
loading: true,
|
|
486
|
+
fullWidth: true
|
|
487
|
+
},
|
|
488
|
+
style: {
|
|
489
|
+
marginLeft: -8
|
|
490
|
+
}
|
|
491
|
+
},
|
|
492
|
+
...L
|
|
493
|
+
]
|
|
494
|
+
}));
|
|
495
|
+
so = y("span", {
|
|
496
|
+
name: "MuiButton",
|
|
497
|
+
slot: "LoadingIndicator",
|
|
498
|
+
overridesResolver: (o, a) => a.loadingIndicator
|
|
499
|
+
})(({ theme: o }) => ({
|
|
500
|
+
display: "none",
|
|
501
|
+
position: "absolute",
|
|
502
|
+
visibility: "visible",
|
|
503
|
+
variants: [
|
|
504
|
+
{
|
|
505
|
+
props: {
|
|
506
|
+
loading: true
|
|
507
|
+
},
|
|
508
|
+
style: {
|
|
509
|
+
display: "flex"
|
|
510
|
+
}
|
|
511
|
+
},
|
|
512
|
+
{
|
|
513
|
+
props: {
|
|
514
|
+
loadingPosition: "start"
|
|
515
|
+
},
|
|
516
|
+
style: {
|
|
517
|
+
left: 14
|
|
518
|
+
}
|
|
519
|
+
},
|
|
520
|
+
{
|
|
521
|
+
props: {
|
|
522
|
+
loadingPosition: "start",
|
|
523
|
+
size: "small"
|
|
524
|
+
},
|
|
525
|
+
style: {
|
|
526
|
+
left: 10
|
|
527
|
+
}
|
|
528
|
+
},
|
|
529
|
+
{
|
|
530
|
+
props: {
|
|
531
|
+
variant: "text",
|
|
532
|
+
loadingPosition: "start"
|
|
533
|
+
},
|
|
534
|
+
style: {
|
|
535
|
+
left: 6
|
|
536
|
+
}
|
|
537
|
+
},
|
|
538
|
+
{
|
|
539
|
+
props: {
|
|
540
|
+
loadingPosition: "center"
|
|
541
|
+
},
|
|
542
|
+
style: {
|
|
543
|
+
left: "50%",
|
|
544
|
+
transform: "translate(-50%)",
|
|
545
|
+
color: (o.vars || o).palette.action.disabled
|
|
546
|
+
}
|
|
547
|
+
},
|
|
548
|
+
{
|
|
549
|
+
props: {
|
|
550
|
+
loadingPosition: "end"
|
|
551
|
+
},
|
|
552
|
+
style: {
|
|
553
|
+
right: 14
|
|
554
|
+
}
|
|
555
|
+
},
|
|
556
|
+
{
|
|
557
|
+
props: {
|
|
558
|
+
loadingPosition: "end",
|
|
559
|
+
size: "small"
|
|
560
|
+
},
|
|
561
|
+
style: {
|
|
562
|
+
right: 10
|
|
563
|
+
}
|
|
564
|
+
},
|
|
565
|
+
{
|
|
566
|
+
props: {
|
|
567
|
+
variant: "text",
|
|
568
|
+
loadingPosition: "end"
|
|
569
|
+
},
|
|
570
|
+
style: {
|
|
571
|
+
right: 6
|
|
572
|
+
}
|
|
573
|
+
},
|
|
574
|
+
{
|
|
575
|
+
props: {
|
|
576
|
+
loadingPosition: "start",
|
|
577
|
+
fullWidth: true
|
|
578
|
+
},
|
|
579
|
+
style: {
|
|
580
|
+
position: "relative",
|
|
581
|
+
left: -10
|
|
582
|
+
}
|
|
583
|
+
},
|
|
584
|
+
{
|
|
585
|
+
props: {
|
|
586
|
+
loadingPosition: "end",
|
|
587
|
+
fullWidth: true
|
|
588
|
+
},
|
|
589
|
+
style: {
|
|
590
|
+
position: "relative",
|
|
591
|
+
right: -10
|
|
592
|
+
}
|
|
593
|
+
}
|
|
594
|
+
]
|
|
595
|
+
}));
|
|
596
|
+
E = y("span", {
|
|
597
|
+
name: "MuiButton",
|
|
598
|
+
slot: "LoadingIconPlaceholder",
|
|
599
|
+
overridesResolver: (o, a) => a.loadingIconPlaceholder
|
|
600
|
+
})({
|
|
601
|
+
display: "inline-block",
|
|
602
|
+
width: "1em",
|
|
603
|
+
height: "1em"
|
|
604
|
+
});
|
|
605
|
+
co = x.forwardRef(function(a, t) {
|
|
606
|
+
const n = x.useContext(ao), p = x.useContext(to), c = H(n, a), u = A({
|
|
607
|
+
props: c,
|
|
608
|
+
name: "MuiButton"
|
|
609
|
+
}), { children: f, color: b = "primary", component: S = "button", className: z, disabled: I = false, disableElevation: N = false, disableFocusRipple: C = false, endIcon: B, focusVisibleClassName: M, fullWidth: k = false, id: P, loading: s = null, loadingIndicator: j, loadingPosition: g = "center", size: O = "medium", startIcon: h, type: $, variant: T = "text", ..._ } = u, w = q(P), R = j ?? e.jsx(Z, {
|
|
610
|
+
"aria-labelledby": w,
|
|
611
|
+
color: "inherit",
|
|
612
|
+
size: 16
|
|
613
|
+
}), l = {
|
|
614
|
+
...u,
|
|
615
|
+
color: b,
|
|
616
|
+
component: S,
|
|
617
|
+
disabled: I,
|
|
618
|
+
disableElevation: N,
|
|
619
|
+
disableFocusRipple: C,
|
|
620
|
+
fullWidth: k,
|
|
621
|
+
loading: s,
|
|
622
|
+
loadingIndicator: R,
|
|
623
|
+
loadingPosition: g,
|
|
624
|
+
size: O,
|
|
625
|
+
type: $,
|
|
626
|
+
variant: T
|
|
627
|
+
}, r = no(l), V = (h || s && g === "start") && e.jsx(ro, {
|
|
628
|
+
className: r.startIcon,
|
|
629
|
+
ownerState: l,
|
|
630
|
+
children: h || e.jsx(E, {
|
|
631
|
+
className: r.loadingIconPlaceholder,
|
|
632
|
+
ownerState: l
|
|
633
|
+
})
|
|
634
|
+
}), F = (B || s && g === "end") && e.jsx(eo, {
|
|
635
|
+
className: r.endIcon,
|
|
636
|
+
ownerState: l,
|
|
637
|
+
children: B || e.jsx(E, {
|
|
638
|
+
className: r.loadingIconPlaceholder,
|
|
639
|
+
ownerState: l
|
|
640
|
+
})
|
|
641
|
+
}), U = p || "", W = typeof s == "boolean" ? e.jsx("span", {
|
|
642
|
+
className: r.loadingWrapper,
|
|
643
|
+
style: {
|
|
644
|
+
display: "contents"
|
|
645
|
+
},
|
|
646
|
+
children: s && e.jsx(so, {
|
|
647
|
+
className: r.loadingIndicator,
|
|
648
|
+
ownerState: l,
|
|
649
|
+
children: R
|
|
650
|
+
})
|
|
651
|
+
}) : null;
|
|
652
|
+
return e.jsxs(io, {
|
|
653
|
+
ownerState: l,
|
|
654
|
+
className: m(n.className, r.root, z, U),
|
|
655
|
+
component: S,
|
|
656
|
+
disabled: I || s,
|
|
657
|
+
focusRipple: !C,
|
|
658
|
+
focusVisibleClassName: m(r.focusVisible, M),
|
|
659
|
+
ref: t,
|
|
660
|
+
type: $,
|
|
661
|
+
id: s ? w : P,
|
|
662
|
+
..._,
|
|
663
|
+
classes: r,
|
|
664
|
+
children: [
|
|
665
|
+
V,
|
|
666
|
+
g !== "end" && W,
|
|
667
|
+
f,
|
|
668
|
+
g === "end" && W,
|
|
669
|
+
F
|
|
670
|
+
]
|
|
671
|
+
});
|
|
672
|
+
});
|
|
673
|
+
});
|
|
674
|
+
export {
|
|
675
|
+
co as B,
|
|
676
|
+
__tla
|
|
677
|
+
};
|