@spark-web/text-input 2.0.4 → 3.0.0
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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @spark-web/text-input
|
|
2
2
|
|
|
3
|
+
## 3.0.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#382](https://github.com/brighte-labs/spark-web/pull/382)
|
|
8
|
+
[`955bf5d`](https://github.com/brighte-labs/spark-web/commit/955bf5d7698bfdf45e7f317aa3e726c81d3444c0)
|
|
9
|
+
Thanks [@dilipt-brighte](https://github.com/dilipt-brighte)! - Updates React
|
|
10
|
+
version to latest (18.2.0)
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies
|
|
15
|
+
[[`955bf5d`](https://github.com/brighte-labs/spark-web/commit/955bf5d7698bfdf45e7f317aa3e726c81d3444c0)]:
|
|
16
|
+
- @spark-web/a11y@1.4.0
|
|
17
|
+
- @spark-web/box@1.2.0
|
|
18
|
+
- @spark-web/field@3.1.0
|
|
19
|
+
- @spark-web/text@1.2.0
|
|
20
|
+
- @spark-web/theme@3.2.0
|
|
21
|
+
- @spark-web/utils@1.3.0
|
|
22
|
+
|
|
3
23
|
## 2.0.4
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
|
@@ -57,7 +57,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
57
57
|
readonly height: "medium";
|
|
58
58
|
readonly paddingLeft: "none" | "medium";
|
|
59
59
|
readonly paddingRight: "none" | "medium";
|
|
60
|
-
readonly shadow: "small";
|
|
61
60
|
readonly width: "full";
|
|
62
61
|
}, {
|
|
63
62
|
readonly ':enabled': {
|
|
@@ -83,6 +82,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
83
82
|
readonly alignItems?: import("csstype").Property.AlignItems | import("csstype").Property.AlignItems[] | undefined;
|
|
84
83
|
readonly alignSelf?: import("csstype").Property.AlignSelf | import("csstype").Property.AlignSelf[] | undefined;
|
|
85
84
|
readonly alignTracks?: import("csstype").Property.AlignTracks | import("csstype").Property.AlignTracks[] | undefined;
|
|
85
|
+
readonly animationComposition?: import("csstype").Property.AnimationComposition | import("csstype").Property.AnimationComposition[] | undefined;
|
|
86
86
|
readonly animationDelay?: import("csstype").Property.AnimationDelay<string & {}> | import("csstype").Property.AnimationDelay<string & {}>[] | undefined;
|
|
87
87
|
readonly animationDirection?: import("csstype").Property.AnimationDirection | import("csstype").Property.AnimationDirection[] | undefined;
|
|
88
88
|
readonly animationDuration?: import("csstype").Property.AnimationDuration<string & {}> | import("csstype").Property.AnimationDuration<string & {}>[] | undefined;
|
|
@@ -278,6 +278,8 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
278
278
|
readonly maskRepeat?: import("csstype").Property.MaskRepeat | import("csstype").Property.MaskRepeat[] | undefined;
|
|
279
279
|
readonly maskSize?: string | number | import("csstype").Property.MaskSize<string | number>[] | undefined;
|
|
280
280
|
readonly maskType?: import("csstype").Property.MaskType | import("csstype").Property.MaskType[] | undefined;
|
|
281
|
+
readonly mathDepth?: import("csstype").Property.MathDepth | import("csstype").Property.MathDepth[] | undefined;
|
|
282
|
+
readonly mathShift?: import("csstype").Property.MathShift | import("csstype").Property.MathShift[] | undefined;
|
|
281
283
|
readonly mathStyle?: import("csstype").Property.MathStyle | import("csstype").Property.MathStyle[] | undefined;
|
|
282
284
|
readonly maxBlockSize?: string | number | import("csstype").Property.MaxBlockSize<string | number>[] | undefined;
|
|
283
285
|
readonly maxHeight?: string | number | import("csstype").Property.MaxHeight<string | number>[] | undefined;
|
|
@@ -395,7 +397,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
395
397
|
readonly textDecorationSkipInk?: import("csstype").Property.TextDecorationSkipInk | import("csstype").Property.TextDecorationSkipInk[] | undefined;
|
|
396
398
|
readonly textDecorationStyle?: import("csstype").Property.TextDecorationStyle | import("csstype").Property.TextDecorationStyle[] | undefined;
|
|
397
399
|
readonly textDecorationThickness?: string | number | import("csstype").Property.TextDecorationThickness<string | number>[] | undefined;
|
|
398
|
-
readonly textDecorationWidth?: string | number | import("csstype").Property.TextDecorationThickness<string | number>[] | undefined;
|
|
399
400
|
readonly textEmphasisColor?: import("csstype").Property.TextEmphasisColor | import("csstype").Property.TextEmphasisColor[] | undefined;
|
|
400
401
|
readonly textEmphasisPosition?: import("csstype").Property.TextEmphasisPosition | import("csstype").Property.TextEmphasisPosition[] | undefined;
|
|
401
402
|
readonly textEmphasisStyle?: import("csstype").Property.TextEmphasisStyle | import("csstype").Property.TextEmphasisStyle[] | undefined;
|
|
@@ -503,7 +504,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
503
504
|
readonly MozBoxSizing?: import("csstype").Property.BoxSizing | import("csstype").Property.BoxSizing[] | undefined;
|
|
504
505
|
readonly MozColumnCount?: import("csstype").Property.ColumnCount | import("csstype").Property.ColumnCount[] | undefined;
|
|
505
506
|
readonly MozColumnFill?: import("csstype").Property.ColumnFill | import("csstype").Property.ColumnFill[] | undefined;
|
|
506
|
-
readonly MozColumnGap?: string | number | import("csstype").Property.ColumnGap<string | number>[] | undefined;
|
|
507
507
|
readonly MozColumnRuleColor?: import("csstype").Property.ColumnRuleColor | import("csstype").Property.ColumnRuleColor[] | undefined;
|
|
508
508
|
readonly MozColumnRuleStyle?: import("csstype").Property.ColumnRuleStyle | import("csstype").Property.ColumnRuleStyle[] | undefined;
|
|
509
509
|
readonly MozColumnRuleWidth?: string | number | import("csstype").Property.ColumnRuleWidth<string | number>[] | undefined;
|
|
@@ -537,7 +537,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
537
537
|
readonly MozWindowDragging?: import("csstype").Property.MozWindowDragging | import("csstype").Property.MozWindowDragging[] | undefined;
|
|
538
538
|
readonly MozWindowShadow?: import("csstype").Property.MozWindowShadow | import("csstype").Property.MozWindowShadow[] | undefined;
|
|
539
539
|
readonly msAccelerator?: import("csstype").Property.MsAccelerator | import("csstype").Property.MsAccelerator[] | undefined;
|
|
540
|
-
readonly msAlignSelf?: import("csstype").Property.AlignSelf | import("csstype").Property.AlignSelf[] | undefined;
|
|
541
540
|
readonly msBlockProgression?: import("csstype").Property.MsBlockProgression | import("csstype").Property.MsBlockProgression[] | undefined;
|
|
542
541
|
readonly msContentZoomChaining?: import("csstype").Property.MsContentZoomChaining | import("csstype").Property.MsContentZoomChaining[] | undefined;
|
|
543
542
|
readonly msContentZoomLimitMax?: import("csstype").Property.MsContentZoomLimitMax | import("csstype").Property.MsContentZoomLimitMax[] | undefined;
|
|
@@ -558,7 +557,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
558
557
|
readonly msHyphenateLimitZone?: string | number | import("csstype").Property.MsHyphenateLimitZone<string | number>[] | undefined;
|
|
559
558
|
readonly msHyphens?: import("csstype").Property.Hyphens | import("csstype").Property.Hyphens[] | undefined;
|
|
560
559
|
readonly msImeAlign?: import("csstype").Property.MsImeAlign | import("csstype").Property.MsImeAlign[] | undefined;
|
|
561
|
-
readonly msJustifySelf?: import("csstype").Property.JustifySelf | import("csstype").Property.JustifySelf[] | undefined;
|
|
562
560
|
readonly msLineBreak?: import("csstype").Property.LineBreak | import("csstype").Property.LineBreak[] | undefined;
|
|
563
561
|
readonly msOrder?: import("csstype").Property.Order | import("csstype").Property.Order[] | undefined;
|
|
564
562
|
readonly msOverflowStyle?: import("csstype").Property.MsOverflowStyle | import("csstype").Property.MsOverflowStyle[] | undefined;
|
|
@@ -581,6 +579,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
581
579
|
readonly msScrollbarFaceColor?: import("csstype").Property.MsScrollbarFaceColor | import("csstype").Property.MsScrollbarFaceColor[] | undefined;
|
|
582
580
|
readonly msScrollbarHighlightColor?: import("csstype").Property.MsScrollbarHighlightColor | import("csstype").Property.MsScrollbarHighlightColor[] | undefined;
|
|
583
581
|
readonly msScrollbarShadowColor?: import("csstype").Property.MsScrollbarShadowColor | import("csstype").Property.MsScrollbarShadowColor[] | undefined;
|
|
582
|
+
readonly msScrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
584
583
|
readonly msTextAutospace?: import("csstype").Property.MsTextAutospace | import("csstype").Property.MsTextAutospace[] | undefined;
|
|
585
584
|
readonly msTextCombineHorizontal?: import("csstype").Property.TextCombineUpright | import("csstype").Property.TextCombineUpright[] | undefined;
|
|
586
585
|
readonly msTextOverflow?: import("csstype").Property.TextOverflow | import("csstype").Property.TextOverflow[] | undefined;
|
|
@@ -630,7 +629,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
630
629
|
readonly WebkitClipPath?: import("csstype").Property.ClipPath | import("csstype").Property.ClipPath[] | undefined;
|
|
631
630
|
readonly WebkitColumnCount?: import("csstype").Property.ColumnCount | import("csstype").Property.ColumnCount[] | undefined;
|
|
632
631
|
readonly WebkitColumnFill?: import("csstype").Property.ColumnFill | import("csstype").Property.ColumnFill[] | undefined;
|
|
633
|
-
readonly WebkitColumnGap?: string | number | import("csstype").Property.ColumnGap<string | number>[] | undefined;
|
|
634
632
|
readonly WebkitColumnRuleColor?: import("csstype").Property.ColumnRuleColor | import("csstype").Property.ColumnRuleColor[] | undefined;
|
|
635
633
|
readonly WebkitColumnRuleStyle?: import("csstype").Property.ColumnRuleStyle | import("csstype").Property.ColumnRuleStyle[] | undefined;
|
|
636
634
|
readonly WebkitColumnRuleWidth?: string | number | import("csstype").Property.ColumnRuleWidth<string | number>[] | undefined;
|
|
@@ -759,7 +757,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
759
757
|
readonly scrollSnapPointsY?: import("csstype").Property.ScrollSnapPointsY | import("csstype").Property.ScrollSnapPointsY[] | undefined;
|
|
760
758
|
readonly scrollSnapTypeX?: import("csstype").Property.ScrollSnapTypeX | import("csstype").Property.ScrollSnapTypeX[] | undefined;
|
|
761
759
|
readonly scrollSnapTypeY?: import("csstype").Property.ScrollSnapTypeY | import("csstype").Property.ScrollSnapTypeY[] | undefined;
|
|
762
|
-
readonly scrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
763
760
|
readonly KhtmlBoxAlign?: import("csstype").Property.BoxAlign | import("csstype").Property.BoxAlign[] | undefined;
|
|
764
761
|
readonly KhtmlBoxDirection?: import("csstype").Property.BoxDirection | import("csstype").Property.BoxDirection[] | undefined;
|
|
765
762
|
readonly KhtmlBoxFlex?: import("csstype").Property.BoxFlex | import("csstype").Property.BoxFlex[] | undefined;
|
|
@@ -806,7 +803,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
806
803
|
readonly MozTextDecorationStyle?: import("csstype").Property.TextDecorationStyle | import("csstype").Property.TextDecorationStyle[] | undefined;
|
|
807
804
|
readonly MozUserInput?: import("csstype").Property.MozUserInput | import("csstype").Property.MozUserInput[] | undefined;
|
|
808
805
|
readonly msImeMode?: import("csstype").Property.ImeMode | import("csstype").Property.ImeMode[] | undefined;
|
|
809
|
-
readonly msScrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
810
806
|
readonly OAnimation?: import("csstype").Property.Animation<string & {}> | import("csstype").Property.Animation<string & {}>[] | undefined;
|
|
811
807
|
readonly OAnimationDelay?: import("csstype").Property.AnimationDelay<string & {}> | import("csstype").Property.AnimationDelay<string & {}>[] | undefined;
|
|
812
808
|
readonly OAnimationDirection?: import("csstype").Property.AnimationDirection | import("csstype").Property.AnimationDirection[] | undefined;
|
|
@@ -912,6 +908,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
912
908
|
readonly "::-ms-browse"?: import("@emotion/serialize").CSSObject | undefined;
|
|
913
909
|
readonly "::-ms-check"?: import("@emotion/serialize").CSSObject | undefined;
|
|
914
910
|
readonly "::-ms-clear"?: import("@emotion/serialize").CSSObject | undefined;
|
|
911
|
+
readonly "::-ms-expand"?: import("@emotion/serialize").CSSObject | undefined;
|
|
915
912
|
readonly "::-ms-fill"?: import("@emotion/serialize").CSSObject | undefined;
|
|
916
913
|
readonly "::-ms-fill-lower"?: import("@emotion/serialize").CSSObject | undefined;
|
|
917
914
|
readonly "::-ms-fill-upper"?: import("@emotion/serialize").CSSObject | undefined;
|
|
@@ -980,6 +977,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
980
977
|
readonly ":paused"?: import("@emotion/serialize").CSSObject | undefined;
|
|
981
978
|
readonly ":picture-in-picture"?: import("@emotion/serialize").CSSObject | undefined;
|
|
982
979
|
readonly ":placeholder-shown"?: import("@emotion/serialize").CSSObject | undefined;
|
|
980
|
+
readonly ":playing"?: import("@emotion/serialize").CSSObject | undefined;
|
|
983
981
|
readonly ":read-only"?: import("@emotion/serialize").CSSObject | undefined;
|
|
984
982
|
readonly ":read-write"?: import("@emotion/serialize").CSSObject | undefined;
|
|
985
983
|
readonly ":required"?: import("@emotion/serialize").CSSObject | undefined;
|
|
@@ -1017,6 +1015,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1017
1015
|
readonly alignItems?: import("csstype").Property.AlignItems | import("csstype").Property.AlignItems[] | undefined;
|
|
1018
1016
|
readonly alignSelf?: import("csstype").Property.AlignSelf | import("csstype").Property.AlignSelf[] | undefined;
|
|
1019
1017
|
readonly alignTracks?: import("csstype").Property.AlignTracks | import("csstype").Property.AlignTracks[] | undefined;
|
|
1018
|
+
readonly animationComposition?: import("csstype").Property.AnimationComposition | import("csstype").Property.AnimationComposition[] | undefined;
|
|
1020
1019
|
readonly animationDelay?: import("csstype").Property.AnimationDelay<string & {}> | import("csstype").Property.AnimationDelay<string & {}>[] | undefined;
|
|
1021
1020
|
readonly animationDirection?: import("csstype").Property.AnimationDirection | import("csstype").Property.AnimationDirection[] | undefined;
|
|
1022
1021
|
readonly animationDuration?: import("csstype").Property.AnimationDuration<string & {}> | import("csstype").Property.AnimationDuration<string & {}>[] | undefined;
|
|
@@ -1212,6 +1211,8 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1212
1211
|
readonly maskRepeat?: import("csstype").Property.MaskRepeat | import("csstype").Property.MaskRepeat[] | undefined;
|
|
1213
1212
|
readonly maskSize?: string | number | import("csstype").Property.MaskSize<string | number>[] | undefined;
|
|
1214
1213
|
readonly maskType?: import("csstype").Property.MaskType | import("csstype").Property.MaskType[] | undefined;
|
|
1214
|
+
readonly mathDepth?: import("csstype").Property.MathDepth | import("csstype").Property.MathDepth[] | undefined;
|
|
1215
|
+
readonly mathShift?: import("csstype").Property.MathShift | import("csstype").Property.MathShift[] | undefined;
|
|
1215
1216
|
readonly mathStyle?: import("csstype").Property.MathStyle | import("csstype").Property.MathStyle[] | undefined;
|
|
1216
1217
|
readonly maxBlockSize?: string | number | import("csstype").Property.MaxBlockSize<string | number>[] | undefined;
|
|
1217
1218
|
readonly maxHeight?: string | number | import("csstype").Property.MaxHeight<string | number>[] | undefined;
|
|
@@ -1329,7 +1330,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1329
1330
|
readonly textDecorationSkipInk?: import("csstype").Property.TextDecorationSkipInk | import("csstype").Property.TextDecorationSkipInk[] | undefined;
|
|
1330
1331
|
readonly textDecorationStyle?: import("csstype").Property.TextDecorationStyle | import("csstype").Property.TextDecorationStyle[] | undefined;
|
|
1331
1332
|
readonly textDecorationThickness?: string | number | import("csstype").Property.TextDecorationThickness<string | number>[] | undefined;
|
|
1332
|
-
readonly textDecorationWidth?: string | number | import("csstype").Property.TextDecorationThickness<string | number>[] | undefined;
|
|
1333
1333
|
readonly textEmphasisColor?: import("csstype").Property.TextEmphasisColor | import("csstype").Property.TextEmphasisColor[] | undefined;
|
|
1334
1334
|
readonly textEmphasisPosition?: import("csstype").Property.TextEmphasisPosition | import("csstype").Property.TextEmphasisPosition[] | undefined;
|
|
1335
1335
|
readonly textEmphasisStyle?: import("csstype").Property.TextEmphasisStyle | import("csstype").Property.TextEmphasisStyle[] | undefined;
|
|
@@ -1436,7 +1436,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1436
1436
|
readonly MozBoxSizing?: import("csstype").Property.BoxSizing | import("csstype").Property.BoxSizing[] | undefined;
|
|
1437
1437
|
readonly MozColumnCount?: import("csstype").Property.ColumnCount | import("csstype").Property.ColumnCount[] | undefined;
|
|
1438
1438
|
readonly MozColumnFill?: import("csstype").Property.ColumnFill | import("csstype").Property.ColumnFill[] | undefined;
|
|
1439
|
-
readonly MozColumnGap?: string | number | import("csstype").Property.ColumnGap<string | number>[] | undefined;
|
|
1440
1439
|
readonly MozColumnRuleColor?: import("csstype").Property.ColumnRuleColor | import("csstype").Property.ColumnRuleColor[] | undefined;
|
|
1441
1440
|
readonly MozColumnRuleStyle?: import("csstype").Property.ColumnRuleStyle | import("csstype").Property.ColumnRuleStyle[] | undefined;
|
|
1442
1441
|
readonly MozColumnRuleWidth?: string | number | import("csstype").Property.ColumnRuleWidth<string | number>[] | undefined;
|
|
@@ -1470,7 +1469,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1470
1469
|
readonly MozWindowDragging?: import("csstype").Property.MozWindowDragging | import("csstype").Property.MozWindowDragging[] | undefined;
|
|
1471
1470
|
readonly MozWindowShadow?: import("csstype").Property.MozWindowShadow | import("csstype").Property.MozWindowShadow[] | undefined;
|
|
1472
1471
|
readonly msAccelerator?: import("csstype").Property.MsAccelerator | import("csstype").Property.MsAccelerator[] | undefined;
|
|
1473
|
-
readonly msAlignSelf?: import("csstype").Property.AlignSelf | import("csstype").Property.AlignSelf[] | undefined;
|
|
1474
1472
|
readonly msBlockProgression?: import("csstype").Property.MsBlockProgression | import("csstype").Property.MsBlockProgression[] | undefined;
|
|
1475
1473
|
readonly msContentZoomChaining?: import("csstype").Property.MsContentZoomChaining | import("csstype").Property.MsContentZoomChaining[] | undefined;
|
|
1476
1474
|
readonly msContentZoomLimitMax?: import("csstype").Property.MsContentZoomLimitMax | import("csstype").Property.MsContentZoomLimitMax[] | undefined;
|
|
@@ -1491,7 +1489,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1491
1489
|
readonly msHyphenateLimitZone?: string | number | import("csstype").Property.MsHyphenateLimitZone<string | number>[] | undefined;
|
|
1492
1490
|
readonly msHyphens?: import("csstype").Property.Hyphens | import("csstype").Property.Hyphens[] | undefined;
|
|
1493
1491
|
readonly msImeAlign?: import("csstype").Property.MsImeAlign | import("csstype").Property.MsImeAlign[] | undefined;
|
|
1494
|
-
readonly msJustifySelf?: import("csstype").Property.JustifySelf | import("csstype").Property.JustifySelf[] | undefined;
|
|
1495
1492
|
readonly msLineBreak?: import("csstype").Property.LineBreak | import("csstype").Property.LineBreak[] | undefined;
|
|
1496
1493
|
readonly msOrder?: import("csstype").Property.Order | import("csstype").Property.Order[] | undefined;
|
|
1497
1494
|
readonly msOverflowStyle?: import("csstype").Property.MsOverflowStyle | import("csstype").Property.MsOverflowStyle[] | undefined;
|
|
@@ -1514,6 +1511,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1514
1511
|
readonly msScrollbarFaceColor?: import("csstype").Property.MsScrollbarFaceColor | import("csstype").Property.MsScrollbarFaceColor[] | undefined;
|
|
1515
1512
|
readonly msScrollbarHighlightColor?: import("csstype").Property.MsScrollbarHighlightColor | import("csstype").Property.MsScrollbarHighlightColor[] | undefined;
|
|
1516
1513
|
readonly msScrollbarShadowColor?: import("csstype").Property.MsScrollbarShadowColor | import("csstype").Property.MsScrollbarShadowColor[] | undefined;
|
|
1514
|
+
readonly msScrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
1517
1515
|
readonly msTextAutospace?: import("csstype").Property.MsTextAutospace | import("csstype").Property.MsTextAutospace[] | undefined;
|
|
1518
1516
|
readonly msTextCombineHorizontal?: import("csstype").Property.TextCombineUpright | import("csstype").Property.TextCombineUpright[] | undefined;
|
|
1519
1517
|
readonly msTextOverflow?: import("csstype").Property.TextOverflow | import("csstype").Property.TextOverflow[] | undefined;
|
|
@@ -1563,7 +1561,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1563
1561
|
readonly WebkitClipPath?: import("csstype").Property.ClipPath | import("csstype").Property.ClipPath[] | undefined;
|
|
1564
1562
|
readonly WebkitColumnCount?: import("csstype").Property.ColumnCount | import("csstype").Property.ColumnCount[] | undefined;
|
|
1565
1563
|
readonly WebkitColumnFill?: import("csstype").Property.ColumnFill | import("csstype").Property.ColumnFill[] | undefined;
|
|
1566
|
-
readonly WebkitColumnGap?: string | number | import("csstype").Property.ColumnGap<string | number>[] | undefined;
|
|
1567
1564
|
readonly WebkitColumnRuleColor?: import("csstype").Property.ColumnRuleColor | import("csstype").Property.ColumnRuleColor[] | undefined;
|
|
1568
1565
|
readonly WebkitColumnRuleStyle?: import("csstype").Property.ColumnRuleStyle | import("csstype").Property.ColumnRuleStyle[] | undefined;
|
|
1569
1566
|
readonly WebkitColumnRuleWidth?: string | number | import("csstype").Property.ColumnRuleWidth<string | number>[] | undefined;
|
|
@@ -1692,7 +1689,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1692
1689
|
readonly scrollSnapPointsY?: import("csstype").Property.ScrollSnapPointsY | import("csstype").Property.ScrollSnapPointsY[] | undefined;
|
|
1693
1690
|
readonly scrollSnapTypeX?: import("csstype").Property.ScrollSnapTypeX | import("csstype").Property.ScrollSnapTypeX[] | undefined;
|
|
1694
1691
|
readonly scrollSnapTypeY?: import("csstype").Property.ScrollSnapTypeY | import("csstype").Property.ScrollSnapTypeY[] | undefined;
|
|
1695
|
-
readonly scrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
1696
1692
|
readonly KhtmlBoxAlign?: import("csstype").Property.BoxAlign | import("csstype").Property.BoxAlign[] | undefined;
|
|
1697
1693
|
readonly KhtmlBoxDirection?: import("csstype").Property.BoxDirection | import("csstype").Property.BoxDirection[] | undefined;
|
|
1698
1694
|
readonly KhtmlBoxFlex?: import("csstype").Property.BoxFlex | import("csstype").Property.BoxFlex[] | undefined;
|
|
@@ -1739,7 +1735,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1739
1735
|
readonly MozTextDecorationStyle?: import("csstype").Property.TextDecorationStyle | import("csstype").Property.TextDecorationStyle[] | undefined;
|
|
1740
1736
|
readonly MozUserInput?: import("csstype").Property.MozUserInput | import("csstype").Property.MozUserInput[] | undefined;
|
|
1741
1737
|
readonly msImeMode?: import("csstype").Property.ImeMode | import("csstype").Property.ImeMode[] | undefined;
|
|
1742
|
-
readonly msScrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
1743
1738
|
readonly OAnimation?: import("csstype").Property.Animation<string & {}> | import("csstype").Property.Animation<string & {}>[] | undefined;
|
|
1744
1739
|
readonly OAnimationDelay?: import("csstype").Property.AnimationDelay<string & {}> | import("csstype").Property.AnimationDelay<string & {}>[] | undefined;
|
|
1745
1740
|
readonly OAnimationDirection?: import("csstype").Property.AnimationDirection | import("csstype").Property.AnimationDirection[] | undefined;
|
|
@@ -1845,6 +1840,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1845
1840
|
readonly "::-ms-browse"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1846
1841
|
readonly "::-ms-check"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1847
1842
|
readonly "::-ms-clear"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1843
|
+
readonly "::-ms-expand"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1848
1844
|
readonly "::-ms-fill"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1849
1845
|
readonly "::-ms-fill-lower"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1850
1846
|
readonly "::-ms-fill-upper"?: import("@emotion/serialize").CSSObject | undefined;
|
|
@@ -1913,6 +1909,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1913
1909
|
readonly ":paused"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1914
1910
|
readonly ":picture-in-picture"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1915
1911
|
readonly ":placeholder-shown"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1912
|
+
readonly ":playing"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1916
1913
|
readonly ":read-only"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1917
1914
|
readonly ":read-write"?: import("@emotion/serialize").CSSObject | undefined;
|
|
1918
1915
|
readonly ":required"?: import("@emotion/serialize").CSSObject | undefined;
|
|
@@ -1953,6 +1950,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
1953
1950
|
readonly alignItems?: import("csstype").Property.AlignItems | import("csstype").Property.AlignItems[] | undefined;
|
|
1954
1951
|
readonly alignSelf?: import("csstype").Property.AlignSelf | import("csstype").Property.AlignSelf[] | undefined;
|
|
1955
1952
|
readonly alignTracks?: import("csstype").Property.AlignTracks | import("csstype").Property.AlignTracks[] | undefined;
|
|
1953
|
+
readonly animationComposition?: import("csstype").Property.AnimationComposition | import("csstype").Property.AnimationComposition[] | undefined;
|
|
1956
1954
|
readonly animationDelay?: import("csstype").Property.AnimationDelay<string & {}> | import("csstype").Property.AnimationDelay<string & {}>[] | undefined;
|
|
1957
1955
|
readonly animationDirection?: import("csstype").Property.AnimationDirection | import("csstype").Property.AnimationDirection[] | undefined;
|
|
1958
1956
|
readonly animationDuration?: import("csstype").Property.AnimationDuration<string & {}> | import("csstype").Property.AnimationDuration<string & {}>[] | undefined;
|
|
@@ -2147,6 +2145,8 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2147
2145
|
readonly maskRepeat?: import("csstype").Property.MaskRepeat | import("csstype").Property.MaskRepeat[] | undefined;
|
|
2148
2146
|
readonly maskSize?: string | number | import("csstype").Property.MaskSize<string | number>[] | undefined;
|
|
2149
2147
|
readonly maskType?: import("csstype").Property.MaskType | import("csstype").Property.MaskType[] | undefined;
|
|
2148
|
+
readonly mathDepth?: import("csstype").Property.MathDepth | import("csstype").Property.MathDepth[] | undefined;
|
|
2149
|
+
readonly mathShift?: import("csstype").Property.MathShift | import("csstype").Property.MathShift[] | undefined;
|
|
2150
2150
|
readonly mathStyle?: import("csstype").Property.MathStyle | import("csstype").Property.MathStyle[] | undefined;
|
|
2151
2151
|
readonly maxBlockSize?: string | number | import("csstype").Property.MaxBlockSize<string | number>[] | undefined;
|
|
2152
2152
|
readonly maxHeight?: string | number | import("csstype").Property.MaxHeight<string | number>[] | undefined;
|
|
@@ -2263,7 +2263,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2263
2263
|
readonly textDecorationSkipInk?: import("csstype").Property.TextDecorationSkipInk | import("csstype").Property.TextDecorationSkipInk[] | undefined;
|
|
2264
2264
|
readonly textDecorationStyle?: import("csstype").Property.TextDecorationStyle | import("csstype").Property.TextDecorationStyle[] | undefined;
|
|
2265
2265
|
readonly textDecorationThickness?: string | number | import("csstype").Property.TextDecorationThickness<string | number>[] | undefined;
|
|
2266
|
-
readonly textDecorationWidth?: string | number | import("csstype").Property.TextDecorationThickness<string | number>[] | undefined;
|
|
2267
2266
|
readonly textEmphasisColor?: import("csstype").Property.TextEmphasisColor | import("csstype").Property.TextEmphasisColor[] | undefined;
|
|
2268
2267
|
readonly textEmphasisPosition?: import("csstype").Property.TextEmphasisPosition | import("csstype").Property.TextEmphasisPosition[] | undefined;
|
|
2269
2268
|
readonly textEmphasisStyle?: import("csstype").Property.TextEmphasisStyle | import("csstype").Property.TextEmphasisStyle[] | undefined;
|
|
@@ -2369,7 +2368,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2369
2368
|
readonly MozBoxSizing?: import("csstype").Property.BoxSizing | import("csstype").Property.BoxSizing[] | undefined;
|
|
2370
2369
|
readonly MozColumnCount?: import("csstype").Property.ColumnCount | import("csstype").Property.ColumnCount[] | undefined;
|
|
2371
2370
|
readonly MozColumnFill?: import("csstype").Property.ColumnFill | import("csstype").Property.ColumnFill[] | undefined;
|
|
2372
|
-
readonly MozColumnGap?: string | number | import("csstype").Property.ColumnGap<string | number>[] | undefined;
|
|
2373
2371
|
readonly MozColumnRuleColor?: import("csstype").Property.ColumnRuleColor | import("csstype").Property.ColumnRuleColor[] | undefined;
|
|
2374
2372
|
readonly MozColumnRuleStyle?: import("csstype").Property.ColumnRuleStyle | import("csstype").Property.ColumnRuleStyle[] | undefined;
|
|
2375
2373
|
readonly MozColumnRuleWidth?: string | number | import("csstype").Property.ColumnRuleWidth<string | number>[] | undefined;
|
|
@@ -2403,7 +2401,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2403
2401
|
readonly MozWindowDragging?: import("csstype").Property.MozWindowDragging | import("csstype").Property.MozWindowDragging[] | undefined;
|
|
2404
2402
|
readonly MozWindowShadow?: import("csstype").Property.MozWindowShadow | import("csstype").Property.MozWindowShadow[] | undefined;
|
|
2405
2403
|
readonly msAccelerator?: import("csstype").Property.MsAccelerator | import("csstype").Property.MsAccelerator[] | undefined;
|
|
2406
|
-
readonly msAlignSelf?: import("csstype").Property.AlignSelf | import("csstype").Property.AlignSelf[] | undefined;
|
|
2407
2404
|
readonly msBlockProgression?: import("csstype").Property.MsBlockProgression | import("csstype").Property.MsBlockProgression[] | undefined;
|
|
2408
2405
|
readonly msContentZoomChaining?: import("csstype").Property.MsContentZoomChaining | import("csstype").Property.MsContentZoomChaining[] | undefined;
|
|
2409
2406
|
readonly msContentZoomLimitMax?: import("csstype").Property.MsContentZoomLimitMax | import("csstype").Property.MsContentZoomLimitMax[] | undefined;
|
|
@@ -2424,7 +2421,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2424
2421
|
readonly msHyphenateLimitZone?: string | number | import("csstype").Property.MsHyphenateLimitZone<string | number>[] | undefined;
|
|
2425
2422
|
readonly msHyphens?: import("csstype").Property.Hyphens | import("csstype").Property.Hyphens[] | undefined;
|
|
2426
2423
|
readonly msImeAlign?: import("csstype").Property.MsImeAlign | import("csstype").Property.MsImeAlign[] | undefined;
|
|
2427
|
-
readonly msJustifySelf?: import("csstype").Property.JustifySelf | import("csstype").Property.JustifySelf[] | undefined;
|
|
2428
2424
|
readonly msLineBreak?: import("csstype").Property.LineBreak | import("csstype").Property.LineBreak[] | undefined;
|
|
2429
2425
|
readonly msOrder?: import("csstype").Property.Order | import("csstype").Property.Order[] | undefined;
|
|
2430
2426
|
readonly msOverflowStyle?: import("csstype").Property.MsOverflowStyle | import("csstype").Property.MsOverflowStyle[] | undefined;
|
|
@@ -2447,6 +2443,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2447
2443
|
readonly msScrollbarFaceColor?: import("csstype").Property.MsScrollbarFaceColor | import("csstype").Property.MsScrollbarFaceColor[] | undefined;
|
|
2448
2444
|
readonly msScrollbarHighlightColor?: import("csstype").Property.MsScrollbarHighlightColor | import("csstype").Property.MsScrollbarHighlightColor[] | undefined;
|
|
2449
2445
|
readonly msScrollbarShadowColor?: import("csstype").Property.MsScrollbarShadowColor | import("csstype").Property.MsScrollbarShadowColor[] | undefined;
|
|
2446
|
+
readonly msScrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
2450
2447
|
readonly msTextAutospace?: import("csstype").Property.MsTextAutospace | import("csstype").Property.MsTextAutospace[] | undefined;
|
|
2451
2448
|
readonly msTextCombineHorizontal?: import("csstype").Property.TextCombineUpright | import("csstype").Property.TextCombineUpright[] | undefined;
|
|
2452
2449
|
readonly msTextOverflow?: import("csstype").Property.TextOverflow | import("csstype").Property.TextOverflow[] | undefined;
|
|
@@ -2496,7 +2493,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2496
2493
|
readonly WebkitClipPath?: import("csstype").Property.ClipPath | import("csstype").Property.ClipPath[] | undefined;
|
|
2497
2494
|
readonly WebkitColumnCount?: import("csstype").Property.ColumnCount | import("csstype").Property.ColumnCount[] | undefined;
|
|
2498
2495
|
readonly WebkitColumnFill?: import("csstype").Property.ColumnFill | import("csstype").Property.ColumnFill[] | undefined;
|
|
2499
|
-
readonly WebkitColumnGap?: string | number | import("csstype").Property.ColumnGap<string | number>[] | undefined;
|
|
2500
2496
|
readonly WebkitColumnRuleColor?: import("csstype").Property.ColumnRuleColor | import("csstype").Property.ColumnRuleColor[] | undefined;
|
|
2501
2497
|
readonly WebkitColumnRuleStyle?: import("csstype").Property.ColumnRuleStyle | import("csstype").Property.ColumnRuleStyle[] | undefined;
|
|
2502
2498
|
readonly WebkitColumnRuleWidth?: string | number | import("csstype").Property.ColumnRuleWidth<string | number>[] | undefined;
|
|
@@ -2625,7 +2621,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2625
2621
|
readonly scrollSnapPointsY?: import("csstype").Property.ScrollSnapPointsY | import("csstype").Property.ScrollSnapPointsY[] | undefined;
|
|
2626
2622
|
readonly scrollSnapTypeX?: import("csstype").Property.ScrollSnapTypeX | import("csstype").Property.ScrollSnapTypeX[] | undefined;
|
|
2627
2623
|
readonly scrollSnapTypeY?: import("csstype").Property.ScrollSnapTypeY | import("csstype").Property.ScrollSnapTypeY[] | undefined;
|
|
2628
|
-
readonly scrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
2629
2624
|
readonly KhtmlBoxAlign?: import("csstype").Property.BoxAlign | import("csstype").Property.BoxAlign[] | undefined;
|
|
2630
2625
|
readonly KhtmlBoxDirection?: import("csstype").Property.BoxDirection | import("csstype").Property.BoxDirection[] | undefined;
|
|
2631
2626
|
readonly KhtmlBoxFlex?: import("csstype").Property.BoxFlex | import("csstype").Property.BoxFlex[] | undefined;
|
|
@@ -2672,7 +2667,6 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2672
2667
|
readonly MozTextDecorationStyle?: import("csstype").Property.TextDecorationStyle | import("csstype").Property.TextDecorationStyle[] | undefined;
|
|
2673
2668
|
readonly MozUserInput?: import("csstype").Property.MozUserInput | import("csstype").Property.MozUserInput[] | undefined;
|
|
2674
2669
|
readonly msImeMode?: import("csstype").Property.ImeMode | import("csstype").Property.ImeMode[] | undefined;
|
|
2675
|
-
readonly msScrollbarTrackColor?: import("csstype").Property.MsScrollbarTrackColor | import("csstype").Property.MsScrollbarTrackColor[] | undefined;
|
|
2676
2670
|
readonly OAnimation?: import("csstype").Property.Animation<string & {}> | import("csstype").Property.Animation<string & {}>[] | undefined;
|
|
2677
2671
|
readonly OAnimationDelay?: import("csstype").Property.AnimationDelay<string & {}> | import("csstype").Property.AnimationDelay<string & {}>[] | undefined;
|
|
2678
2672
|
readonly OAnimationDirection?: import("csstype").Property.AnimationDirection | import("csstype").Property.AnimationDirection[] | undefined;
|
|
@@ -2778,6 +2772,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2778
2772
|
readonly "::-ms-browse"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2779
2773
|
readonly "::-ms-check"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2780
2774
|
readonly "::-ms-clear"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2775
|
+
readonly "::-ms-expand"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2781
2776
|
readonly "::-ms-fill"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2782
2777
|
readonly "::-ms-fill-lower"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2783
2778
|
readonly "::-ms-fill-upper"?: import("@emotion/serialize").CSSObject | undefined;
|
|
@@ -2846,6 +2841,7 @@ export declare const useInputStyles: ({ disabled, startAdornment, endAdornment,
|
|
|
2846
2841
|
readonly ":paused"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2847
2842
|
readonly ":picture-in-picture"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2848
2843
|
readonly ":placeholder-shown"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2844
|
+
readonly ":playing"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2849
2845
|
readonly ":read-only"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2850
2846
|
readonly ":read-write"?: import("@emotion/serialize").CSSObject | undefined;
|
|
2851
2847
|
readonly ":required"?: import("@emotion/serialize").CSSObject | undefined;
|
|
@@ -29,7 +29,6 @@ var placementToPadding = {
|
|
|
29
29
|
paddingRight: 'medium'
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
|
-
|
|
33
32
|
/**
|
|
34
33
|
* Places an element at the "start" or "end" of the input, only one adornment
|
|
35
34
|
* may be provided for each placement. By default, the adornment element will be
|
|
@@ -45,9 +44,9 @@ var placementToPadding = {
|
|
|
45
44
|
*/
|
|
46
45
|
var InputAdornment = function InputAdornment(_ref) {
|
|
47
46
|
var children = _ref.children,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
47
|
+
fieldLabel = _ref.fieldLabel,
|
|
48
|
+
placement = _ref.placement,
|
|
49
|
+
raw = _ref.raw;
|
|
51
50
|
var theme$1 = theme.useTheme();
|
|
52
51
|
var adornmentContext = react.useMemo(function () {
|
|
53
52
|
return {
|
|
@@ -55,10 +54,9 @@ var InputAdornment = function InputAdornment(_ref) {
|
|
|
55
54
|
};
|
|
56
55
|
}, [placement]);
|
|
57
56
|
var _placementToPadding$p = placementToPadding[placement],
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
paddingLeft = _placementToPadding$p.paddingLeft,
|
|
58
|
+
paddingRight = _placementToPadding$p.paddingRight;
|
|
60
59
|
var content = children;
|
|
61
|
-
|
|
62
60
|
if (!raw) {
|
|
63
61
|
content = /*#__PURE__*/jsxRuntime.jsx(box.Box, {
|
|
64
62
|
paddingLeft: paddingLeft,
|
|
@@ -74,29 +72,26 @@ var InputAdornment = function InputAdornment(_ref) {
|
|
|
74
72
|
})
|
|
75
73
|
});
|
|
76
74
|
}
|
|
77
|
-
|
|
78
75
|
var wrappedContent = /*#__PURE__*/jsxRuntime.jsx(InputAdornmentContext.Provider, {
|
|
79
76
|
value: adornmentContext,
|
|
80
77
|
children: content
|
|
81
78
|
});
|
|
82
|
-
|
|
83
79
|
if (fieldLabel) {
|
|
84
80
|
return /*#__PURE__*/jsxRuntime.jsx(FieldAdornment, {
|
|
85
81
|
fieldLabel: fieldLabel,
|
|
86
82
|
children: wrappedContent
|
|
87
83
|
});
|
|
88
84
|
}
|
|
89
|
-
|
|
90
85
|
return wrappedContent;
|
|
91
86
|
};
|
|
87
|
+
|
|
92
88
|
/**
|
|
93
89
|
* Wrap the element with a field provider to override the parent field label.
|
|
94
90
|
* Only split-out from `InputAdornment` to avoid the conditional hook rule.
|
|
95
91
|
*/
|
|
96
|
-
|
|
97
92
|
var FieldAdornment = function FieldAdornment(_ref2) {
|
|
98
93
|
var children = _ref2.children,
|
|
99
|
-
|
|
94
|
+
fieldLabel = _ref2.fieldLabel;
|
|
100
95
|
var parentFieldContext = field.useFieldContext();
|
|
101
96
|
var fieldContext = react.useMemo(function () {
|
|
102
97
|
return _objectSpread(_objectSpread({}, parentFieldContext), {}, {
|
|
@@ -112,16 +107,14 @@ var FieldAdornment = function FieldAdornment(_ref2) {
|
|
|
112
107
|
var _excluded$1 = ["children", "startAdornment", "endAdornment"];
|
|
113
108
|
var InputContainer = function InputContainer(_ref) {
|
|
114
109
|
var children = _ref.children,
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
110
|
+
startAdornment = _ref.startAdornment,
|
|
111
|
+
endAdornment = _ref.endAdornment,
|
|
112
|
+
boxProps = _objectWithoutProperties(_ref, _excluded$1);
|
|
119
113
|
var _useFieldContext = field.useFieldContext(),
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
114
|
+
_useFieldContext2 = _slicedToArray(_useFieldContext, 1),
|
|
115
|
+
_useFieldContext2$ = _useFieldContext2[0],
|
|
116
|
+
disabled = _useFieldContext2$.disabled,
|
|
117
|
+
invalid = _useFieldContext2$.invalid;
|
|
125
118
|
return /*#__PURE__*/jsxRuntime.jsxs(box.Box, _objectSpread(_objectSpread({
|
|
126
119
|
borderRadius: "small",
|
|
127
120
|
position: "relative",
|
|
@@ -132,7 +125,6 @@ var InputContainer = function InputContainer(_ref) {
|
|
|
132
125
|
}), endAdornment]
|
|
133
126
|
}));
|
|
134
127
|
};
|
|
135
|
-
|
|
136
128
|
var FocusIndicator = function FocusIndicator(_ref2) {
|
|
137
129
|
var invalid = _ref2.invalid;
|
|
138
130
|
return /*#__PURE__*/jsxRuntime.jsx(box.Box, {
|
|
@@ -140,7 +132,8 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
140
132
|
as: "span",
|
|
141
133
|
data: {
|
|
142
134
|
'focus-indicator': 'true'
|
|
143
|
-
}
|
|
135
|
+
}
|
|
136
|
+
// Styles
|
|
144
137
|
,
|
|
145
138
|
border: invalid ? 'critical' : 'field',
|
|
146
139
|
borderRadius: "small",
|
|
@@ -149,6 +142,7 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
149
142
|
left: 0,
|
|
150
143
|
right: 0,
|
|
151
144
|
top: 0,
|
|
145
|
+
shadow: "small",
|
|
152
146
|
className: css.css({
|
|
153
147
|
pointerEvents: 'none'
|
|
154
148
|
})
|
|
@@ -162,20 +156,17 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
162
156
|
var childrenToAdornments = function childrenToAdornments(children) {
|
|
163
157
|
var startAdornment = null;
|
|
164
158
|
var endAdornment = null;
|
|
165
|
-
|
|
166
159
|
if (!children) {
|
|
167
160
|
return {
|
|
168
161
|
startAdornment: startAdornment,
|
|
169
162
|
endAdornment: endAdornment
|
|
170
163
|
};
|
|
171
164
|
}
|
|
172
|
-
|
|
173
165
|
react.Children.forEach(children, function (child) {
|
|
174
166
|
if ( /*#__PURE__*/react.isValidElement(child)) {
|
|
175
167
|
if (child.props.placement === 'end') {
|
|
176
168
|
endAdornment = child;
|
|
177
169
|
}
|
|
178
|
-
|
|
179
170
|
if (child.props.placement === 'start') {
|
|
180
171
|
startAdornment = child;
|
|
181
172
|
}
|
|
@@ -188,34 +179,29 @@ var childrenToAdornments = function childrenToAdornments(children) {
|
|
|
188
179
|
};
|
|
189
180
|
|
|
190
181
|
var _excluded = ["children", "data"];
|
|
191
|
-
|
|
192
182
|
/** Organize and emphasize information quickly and effectively in a list of text elements. */
|
|
193
183
|
var TextInput = /*#__PURE__*/react.forwardRef(function (_ref, forwardedRef) {
|
|
194
184
|
var children = _ref.children,
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
185
|
+
data = _ref.data,
|
|
186
|
+
consumerProps = _objectWithoutProperties(_ref, _excluded);
|
|
198
187
|
var _useFieldContext = field.useFieldContext(),
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
188
|
+
_useFieldContext2 = _slicedToArray(_useFieldContext, 2),
|
|
189
|
+
_useFieldContext2$ = _useFieldContext2[0],
|
|
190
|
+
disabled = _useFieldContext2$.disabled,
|
|
191
|
+
invalid = _useFieldContext2$.invalid,
|
|
192
|
+
a11yProps = _useFieldContext2[1];
|
|
205
193
|
var _childrenToAdornments = childrenToAdornments(children),
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
194
|
+
startAdornment = _childrenToAdornments.startAdornment,
|
|
195
|
+
endAdornment = _childrenToAdornments.endAdornment;
|
|
209
196
|
var _useInputStyles = useInputStyles({
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
197
|
+
disabled: disabled,
|
|
198
|
+
invalid: invalid,
|
|
199
|
+
startAdornment: Boolean(startAdornment),
|
|
200
|
+
endAdornment: Boolean(endAdornment)
|
|
201
|
+
}),
|
|
202
|
+
_useInputStyles2 = _slicedToArray(_useInputStyles, 2),
|
|
203
|
+
boxProps = _useInputStyles2[0],
|
|
204
|
+
inputStyles = _useInputStyles2[1];
|
|
219
205
|
return /*#__PURE__*/jsxRuntime.jsx(InputContainer, {
|
|
220
206
|
display: "inline-flex",
|
|
221
207
|
alignItems: "center",
|
|
@@ -231,7 +217,6 @@ var TextInput = /*#__PURE__*/react.forwardRef(function (_ref, forwardedRef) {
|
|
|
231
217
|
});
|
|
232
218
|
});
|
|
233
219
|
TextInput.displayName = 'TextInput';
|
|
234
|
-
|
|
235
220
|
/**
|
|
236
221
|
* Returns a tuple where the first item is an object of props to spread onto the
|
|
237
222
|
* underlying Box component that our inputs are created with, and the second
|
|
@@ -239,8 +224,8 @@ TextInput.displayName = 'TextInput';
|
|
|
239
224
|
**/
|
|
240
225
|
var useInputStyles = function useInputStyles(_ref2) {
|
|
241
226
|
var disabled = _ref2.disabled,
|
|
242
|
-
|
|
243
|
-
|
|
227
|
+
startAdornment = _ref2.startAdornment,
|
|
228
|
+
endAdornment = _ref2.endAdornment;
|
|
244
229
|
var theme$1 = theme.useTheme();
|
|
245
230
|
var overflowStyles = text.useOverflowStrategy('truncate');
|
|
246
231
|
var focusRingStyles = a11y.useFocusRing({
|
|
@@ -252,18 +237,15 @@ var useInputStyles = function useInputStyles(_ref2) {
|
|
|
252
237
|
size: 'standard',
|
|
253
238
|
weight: 'regular'
|
|
254
239
|
});
|
|
255
|
-
|
|
256
240
|
var _textStyles = _slicedToArray(textStyles, 2),
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
241
|
+
typographyStyles = _textStyles[0],
|
|
242
|
+
responsiveStyles = _textStyles[1];
|
|
260
243
|
return [{
|
|
261
244
|
flex: 1,
|
|
262
245
|
position: 'relative',
|
|
263
246
|
height: 'medium',
|
|
264
247
|
paddingLeft: startAdornment ? 'none' : 'medium',
|
|
265
248
|
paddingRight: endAdornment ? 'none' : 'medium',
|
|
266
|
-
shadow: 'small',
|
|
267
249
|
width: 'full'
|
|
268
250
|
}, _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typographyStyles), responsiveStyles), overflowStyles), {}, {
|
|
269
251
|
':enabled': {
|
|
@@ -29,7 +29,6 @@ var placementToPadding = {
|
|
|
29
29
|
paddingRight: 'medium'
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
|
-
|
|
33
32
|
/**
|
|
34
33
|
* Places an element at the "start" or "end" of the input, only one adornment
|
|
35
34
|
* may be provided for each placement. By default, the adornment element will be
|
|
@@ -45,9 +44,9 @@ var placementToPadding = {
|
|
|
45
44
|
*/
|
|
46
45
|
var InputAdornment = function InputAdornment(_ref) {
|
|
47
46
|
var children = _ref.children,
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
47
|
+
fieldLabel = _ref.fieldLabel,
|
|
48
|
+
placement = _ref.placement,
|
|
49
|
+
raw = _ref.raw;
|
|
51
50
|
var theme$1 = theme.useTheme();
|
|
52
51
|
var adornmentContext = react.useMemo(function () {
|
|
53
52
|
return {
|
|
@@ -55,10 +54,9 @@ var InputAdornment = function InputAdornment(_ref) {
|
|
|
55
54
|
};
|
|
56
55
|
}, [placement]);
|
|
57
56
|
var _placementToPadding$p = placementToPadding[placement],
|
|
58
|
-
|
|
59
|
-
|
|
57
|
+
paddingLeft = _placementToPadding$p.paddingLeft,
|
|
58
|
+
paddingRight = _placementToPadding$p.paddingRight;
|
|
60
59
|
var content = children;
|
|
61
|
-
|
|
62
60
|
if (!raw) {
|
|
63
61
|
content = /*#__PURE__*/jsxRuntime.jsx(box.Box, {
|
|
64
62
|
paddingLeft: paddingLeft,
|
|
@@ -74,29 +72,26 @@ var InputAdornment = function InputAdornment(_ref) {
|
|
|
74
72
|
})
|
|
75
73
|
});
|
|
76
74
|
}
|
|
77
|
-
|
|
78
75
|
var wrappedContent = /*#__PURE__*/jsxRuntime.jsx(InputAdornmentContext.Provider, {
|
|
79
76
|
value: adornmentContext,
|
|
80
77
|
children: content
|
|
81
78
|
});
|
|
82
|
-
|
|
83
79
|
if (fieldLabel) {
|
|
84
80
|
return /*#__PURE__*/jsxRuntime.jsx(FieldAdornment, {
|
|
85
81
|
fieldLabel: fieldLabel,
|
|
86
82
|
children: wrappedContent
|
|
87
83
|
});
|
|
88
84
|
}
|
|
89
|
-
|
|
90
85
|
return wrappedContent;
|
|
91
86
|
};
|
|
87
|
+
|
|
92
88
|
/**
|
|
93
89
|
* Wrap the element with a field provider to override the parent field label.
|
|
94
90
|
* Only split-out from `InputAdornment` to avoid the conditional hook rule.
|
|
95
91
|
*/
|
|
96
|
-
|
|
97
92
|
var FieldAdornment = function FieldAdornment(_ref2) {
|
|
98
93
|
var children = _ref2.children,
|
|
99
|
-
|
|
94
|
+
fieldLabel = _ref2.fieldLabel;
|
|
100
95
|
var parentFieldContext = field.useFieldContext();
|
|
101
96
|
var fieldContext = react.useMemo(function () {
|
|
102
97
|
return _objectSpread(_objectSpread({}, parentFieldContext), {}, {
|
|
@@ -112,16 +107,14 @@ var FieldAdornment = function FieldAdornment(_ref2) {
|
|
|
112
107
|
var _excluded$1 = ["children", "startAdornment", "endAdornment"];
|
|
113
108
|
var InputContainer = function InputContainer(_ref) {
|
|
114
109
|
var children = _ref.children,
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
110
|
+
startAdornment = _ref.startAdornment,
|
|
111
|
+
endAdornment = _ref.endAdornment,
|
|
112
|
+
boxProps = _objectWithoutProperties(_ref, _excluded$1);
|
|
119
113
|
var _useFieldContext = field.useFieldContext(),
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
114
|
+
_useFieldContext2 = _slicedToArray(_useFieldContext, 1),
|
|
115
|
+
_useFieldContext2$ = _useFieldContext2[0],
|
|
116
|
+
disabled = _useFieldContext2$.disabled,
|
|
117
|
+
invalid = _useFieldContext2$.invalid;
|
|
125
118
|
return /*#__PURE__*/jsxRuntime.jsxs(box.Box, _objectSpread(_objectSpread({
|
|
126
119
|
borderRadius: "small",
|
|
127
120
|
position: "relative",
|
|
@@ -132,7 +125,6 @@ var InputContainer = function InputContainer(_ref) {
|
|
|
132
125
|
}), endAdornment]
|
|
133
126
|
}));
|
|
134
127
|
};
|
|
135
|
-
|
|
136
128
|
var FocusIndicator = function FocusIndicator(_ref2) {
|
|
137
129
|
var invalid = _ref2.invalid;
|
|
138
130
|
return /*#__PURE__*/jsxRuntime.jsx(box.Box, {
|
|
@@ -140,7 +132,8 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
140
132
|
as: "span",
|
|
141
133
|
data: {
|
|
142
134
|
'focus-indicator': 'true'
|
|
143
|
-
}
|
|
135
|
+
}
|
|
136
|
+
// Styles
|
|
144
137
|
,
|
|
145
138
|
border: invalid ? 'critical' : 'field',
|
|
146
139
|
borderRadius: "small",
|
|
@@ -149,6 +142,7 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
149
142
|
left: 0,
|
|
150
143
|
right: 0,
|
|
151
144
|
top: 0,
|
|
145
|
+
shadow: "small",
|
|
152
146
|
className: css.css({
|
|
153
147
|
pointerEvents: 'none'
|
|
154
148
|
})
|
|
@@ -162,20 +156,17 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
162
156
|
var childrenToAdornments = function childrenToAdornments(children) {
|
|
163
157
|
var startAdornment = null;
|
|
164
158
|
var endAdornment = null;
|
|
165
|
-
|
|
166
159
|
if (!children) {
|
|
167
160
|
return {
|
|
168
161
|
startAdornment: startAdornment,
|
|
169
162
|
endAdornment: endAdornment
|
|
170
163
|
};
|
|
171
164
|
}
|
|
172
|
-
|
|
173
165
|
react.Children.forEach(children, function (child) {
|
|
174
166
|
if ( /*#__PURE__*/react.isValidElement(child)) {
|
|
175
167
|
if (child.props.placement === 'end') {
|
|
176
168
|
endAdornment = child;
|
|
177
169
|
}
|
|
178
|
-
|
|
179
170
|
if (child.props.placement === 'start') {
|
|
180
171
|
startAdornment = child;
|
|
181
172
|
}
|
|
@@ -188,34 +179,29 @@ var childrenToAdornments = function childrenToAdornments(children) {
|
|
|
188
179
|
};
|
|
189
180
|
|
|
190
181
|
var _excluded = ["children", "data"];
|
|
191
|
-
|
|
192
182
|
/** Organize and emphasize information quickly and effectively in a list of text elements. */
|
|
193
183
|
var TextInput = /*#__PURE__*/react.forwardRef(function (_ref, forwardedRef) {
|
|
194
184
|
var children = _ref.children,
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
185
|
+
data = _ref.data,
|
|
186
|
+
consumerProps = _objectWithoutProperties(_ref, _excluded);
|
|
198
187
|
var _useFieldContext = field.useFieldContext(),
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
188
|
+
_useFieldContext2 = _slicedToArray(_useFieldContext, 2),
|
|
189
|
+
_useFieldContext2$ = _useFieldContext2[0],
|
|
190
|
+
disabled = _useFieldContext2$.disabled,
|
|
191
|
+
invalid = _useFieldContext2$.invalid,
|
|
192
|
+
a11yProps = _useFieldContext2[1];
|
|
205
193
|
var _childrenToAdornments = childrenToAdornments(children),
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
194
|
+
startAdornment = _childrenToAdornments.startAdornment,
|
|
195
|
+
endAdornment = _childrenToAdornments.endAdornment;
|
|
209
196
|
var _useInputStyles = useInputStyles({
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
197
|
+
disabled: disabled,
|
|
198
|
+
invalid: invalid,
|
|
199
|
+
startAdornment: Boolean(startAdornment),
|
|
200
|
+
endAdornment: Boolean(endAdornment)
|
|
201
|
+
}),
|
|
202
|
+
_useInputStyles2 = _slicedToArray(_useInputStyles, 2),
|
|
203
|
+
boxProps = _useInputStyles2[0],
|
|
204
|
+
inputStyles = _useInputStyles2[1];
|
|
219
205
|
return /*#__PURE__*/jsxRuntime.jsx(InputContainer, {
|
|
220
206
|
display: "inline-flex",
|
|
221
207
|
alignItems: "center",
|
|
@@ -231,7 +217,6 @@ var TextInput = /*#__PURE__*/react.forwardRef(function (_ref, forwardedRef) {
|
|
|
231
217
|
});
|
|
232
218
|
});
|
|
233
219
|
TextInput.displayName = 'TextInput';
|
|
234
|
-
|
|
235
220
|
/**
|
|
236
221
|
* Returns a tuple where the first item is an object of props to spread onto the
|
|
237
222
|
* underlying Box component that our inputs are created with, and the second
|
|
@@ -239,8 +224,8 @@ TextInput.displayName = 'TextInput';
|
|
|
239
224
|
**/
|
|
240
225
|
var useInputStyles = function useInputStyles(_ref2) {
|
|
241
226
|
var disabled = _ref2.disabled,
|
|
242
|
-
|
|
243
|
-
|
|
227
|
+
startAdornment = _ref2.startAdornment,
|
|
228
|
+
endAdornment = _ref2.endAdornment;
|
|
244
229
|
var theme$1 = theme.useTheme();
|
|
245
230
|
var overflowStyles = text.useOverflowStrategy('truncate');
|
|
246
231
|
var focusRingStyles = a11y.useFocusRing({
|
|
@@ -252,18 +237,15 @@ var useInputStyles = function useInputStyles(_ref2) {
|
|
|
252
237
|
size: 'standard',
|
|
253
238
|
weight: 'regular'
|
|
254
239
|
});
|
|
255
|
-
|
|
256
240
|
var _textStyles = _slicedToArray(textStyles, 2),
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
241
|
+
typographyStyles = _textStyles[0],
|
|
242
|
+
responsiveStyles = _textStyles[1];
|
|
260
243
|
return [{
|
|
261
244
|
flex: 1,
|
|
262
245
|
position: 'relative',
|
|
263
246
|
height: 'medium',
|
|
264
247
|
paddingLeft: startAdornment ? 'none' : 'medium',
|
|
265
248
|
paddingRight: endAdornment ? 'none' : 'medium',
|
|
266
|
-
shadow: 'small',
|
|
267
249
|
width: 'full'
|
|
268
250
|
}, _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typographyStyles), responsiveStyles), overflowStyles), {}, {
|
|
269
251
|
':enabled': {
|
|
@@ -25,7 +25,6 @@ var placementToPadding = {
|
|
|
25
25
|
paddingRight: 'medium'
|
|
26
26
|
}
|
|
27
27
|
};
|
|
28
|
-
|
|
29
28
|
/**
|
|
30
29
|
* Places an element at the "start" or "end" of the input, only one adornment
|
|
31
30
|
* may be provided for each placement. By default, the adornment element will be
|
|
@@ -41,9 +40,9 @@ var placementToPadding = {
|
|
|
41
40
|
*/
|
|
42
41
|
var InputAdornment = function InputAdornment(_ref) {
|
|
43
42
|
var children = _ref.children,
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
43
|
+
fieldLabel = _ref.fieldLabel,
|
|
44
|
+
placement = _ref.placement,
|
|
45
|
+
raw = _ref.raw;
|
|
47
46
|
var theme = useTheme();
|
|
48
47
|
var adornmentContext = useMemo(function () {
|
|
49
48
|
return {
|
|
@@ -51,10 +50,9 @@ var InputAdornment = function InputAdornment(_ref) {
|
|
|
51
50
|
};
|
|
52
51
|
}, [placement]);
|
|
53
52
|
var _placementToPadding$p = placementToPadding[placement],
|
|
54
|
-
|
|
55
|
-
|
|
53
|
+
paddingLeft = _placementToPadding$p.paddingLeft,
|
|
54
|
+
paddingRight = _placementToPadding$p.paddingRight;
|
|
56
55
|
var content = children;
|
|
57
|
-
|
|
58
56
|
if (!raw) {
|
|
59
57
|
content = /*#__PURE__*/jsx(Box, {
|
|
60
58
|
paddingLeft: paddingLeft,
|
|
@@ -70,29 +68,26 @@ var InputAdornment = function InputAdornment(_ref) {
|
|
|
70
68
|
})
|
|
71
69
|
});
|
|
72
70
|
}
|
|
73
|
-
|
|
74
71
|
var wrappedContent = /*#__PURE__*/jsx(InputAdornmentContext.Provider, {
|
|
75
72
|
value: adornmentContext,
|
|
76
73
|
children: content
|
|
77
74
|
});
|
|
78
|
-
|
|
79
75
|
if (fieldLabel) {
|
|
80
76
|
return /*#__PURE__*/jsx(FieldAdornment, {
|
|
81
77
|
fieldLabel: fieldLabel,
|
|
82
78
|
children: wrappedContent
|
|
83
79
|
});
|
|
84
80
|
}
|
|
85
|
-
|
|
86
81
|
return wrappedContent;
|
|
87
82
|
};
|
|
83
|
+
|
|
88
84
|
/**
|
|
89
85
|
* Wrap the element with a field provider to override the parent field label.
|
|
90
86
|
* Only split-out from `InputAdornment` to avoid the conditional hook rule.
|
|
91
87
|
*/
|
|
92
|
-
|
|
93
88
|
var FieldAdornment = function FieldAdornment(_ref2) {
|
|
94
89
|
var children = _ref2.children,
|
|
95
|
-
|
|
90
|
+
fieldLabel = _ref2.fieldLabel;
|
|
96
91
|
var parentFieldContext = useFieldContext();
|
|
97
92
|
var fieldContext = useMemo(function () {
|
|
98
93
|
return _objectSpread(_objectSpread({}, parentFieldContext), {}, {
|
|
@@ -108,16 +103,14 @@ var FieldAdornment = function FieldAdornment(_ref2) {
|
|
|
108
103
|
var _excluded$1 = ["children", "startAdornment", "endAdornment"];
|
|
109
104
|
var InputContainer = function InputContainer(_ref) {
|
|
110
105
|
var children = _ref.children,
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
106
|
+
startAdornment = _ref.startAdornment,
|
|
107
|
+
endAdornment = _ref.endAdornment,
|
|
108
|
+
boxProps = _objectWithoutProperties(_ref, _excluded$1);
|
|
115
109
|
var _useFieldContext = useFieldContext(),
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
110
|
+
_useFieldContext2 = _slicedToArray(_useFieldContext, 1),
|
|
111
|
+
_useFieldContext2$ = _useFieldContext2[0],
|
|
112
|
+
disabled = _useFieldContext2$.disabled,
|
|
113
|
+
invalid = _useFieldContext2$.invalid;
|
|
121
114
|
return /*#__PURE__*/jsxs(Box, _objectSpread(_objectSpread({
|
|
122
115
|
borderRadius: "small",
|
|
123
116
|
position: "relative",
|
|
@@ -128,7 +121,6 @@ var InputContainer = function InputContainer(_ref) {
|
|
|
128
121
|
}), endAdornment]
|
|
129
122
|
}));
|
|
130
123
|
};
|
|
131
|
-
|
|
132
124
|
var FocusIndicator = function FocusIndicator(_ref2) {
|
|
133
125
|
var invalid = _ref2.invalid;
|
|
134
126
|
return /*#__PURE__*/jsx(Box, {
|
|
@@ -136,7 +128,8 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
136
128
|
as: "span",
|
|
137
129
|
data: {
|
|
138
130
|
'focus-indicator': 'true'
|
|
139
|
-
}
|
|
131
|
+
}
|
|
132
|
+
// Styles
|
|
140
133
|
,
|
|
141
134
|
border: invalid ? 'critical' : 'field',
|
|
142
135
|
borderRadius: "small",
|
|
@@ -145,6 +138,7 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
145
138
|
left: 0,
|
|
146
139
|
right: 0,
|
|
147
140
|
top: 0,
|
|
141
|
+
shadow: "small",
|
|
148
142
|
className: css({
|
|
149
143
|
pointerEvents: 'none'
|
|
150
144
|
})
|
|
@@ -158,20 +152,17 @@ var FocusIndicator = function FocusIndicator(_ref2) {
|
|
|
158
152
|
var childrenToAdornments = function childrenToAdornments(children) {
|
|
159
153
|
var startAdornment = null;
|
|
160
154
|
var endAdornment = null;
|
|
161
|
-
|
|
162
155
|
if (!children) {
|
|
163
156
|
return {
|
|
164
157
|
startAdornment: startAdornment,
|
|
165
158
|
endAdornment: endAdornment
|
|
166
159
|
};
|
|
167
160
|
}
|
|
168
|
-
|
|
169
161
|
Children.forEach(children, function (child) {
|
|
170
162
|
if ( /*#__PURE__*/isValidElement(child)) {
|
|
171
163
|
if (child.props.placement === 'end') {
|
|
172
164
|
endAdornment = child;
|
|
173
165
|
}
|
|
174
|
-
|
|
175
166
|
if (child.props.placement === 'start') {
|
|
176
167
|
startAdornment = child;
|
|
177
168
|
}
|
|
@@ -184,34 +175,29 @@ var childrenToAdornments = function childrenToAdornments(children) {
|
|
|
184
175
|
};
|
|
185
176
|
|
|
186
177
|
var _excluded = ["children", "data"];
|
|
187
|
-
|
|
188
178
|
/** Organize and emphasize information quickly and effectively in a list of text elements. */
|
|
189
179
|
var TextInput = /*#__PURE__*/forwardRef(function (_ref, forwardedRef) {
|
|
190
180
|
var children = _ref.children,
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
181
|
+
data = _ref.data,
|
|
182
|
+
consumerProps = _objectWithoutProperties(_ref, _excluded);
|
|
194
183
|
var _useFieldContext = useFieldContext(),
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
184
|
+
_useFieldContext2 = _slicedToArray(_useFieldContext, 2),
|
|
185
|
+
_useFieldContext2$ = _useFieldContext2[0],
|
|
186
|
+
disabled = _useFieldContext2$.disabled,
|
|
187
|
+
invalid = _useFieldContext2$.invalid,
|
|
188
|
+
a11yProps = _useFieldContext2[1];
|
|
201
189
|
var _childrenToAdornments = childrenToAdornments(children),
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
190
|
+
startAdornment = _childrenToAdornments.startAdornment,
|
|
191
|
+
endAdornment = _childrenToAdornments.endAdornment;
|
|
205
192
|
var _useInputStyles = useInputStyles({
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
193
|
+
disabled: disabled,
|
|
194
|
+
invalid: invalid,
|
|
195
|
+
startAdornment: Boolean(startAdornment),
|
|
196
|
+
endAdornment: Boolean(endAdornment)
|
|
197
|
+
}),
|
|
198
|
+
_useInputStyles2 = _slicedToArray(_useInputStyles, 2),
|
|
199
|
+
boxProps = _useInputStyles2[0],
|
|
200
|
+
inputStyles = _useInputStyles2[1];
|
|
215
201
|
return /*#__PURE__*/jsx(InputContainer, {
|
|
216
202
|
display: "inline-flex",
|
|
217
203
|
alignItems: "center",
|
|
@@ -227,7 +213,6 @@ var TextInput = /*#__PURE__*/forwardRef(function (_ref, forwardedRef) {
|
|
|
227
213
|
});
|
|
228
214
|
});
|
|
229
215
|
TextInput.displayName = 'TextInput';
|
|
230
|
-
|
|
231
216
|
/**
|
|
232
217
|
* Returns a tuple where the first item is an object of props to spread onto the
|
|
233
218
|
* underlying Box component that our inputs are created with, and the second
|
|
@@ -235,8 +220,8 @@ TextInput.displayName = 'TextInput';
|
|
|
235
220
|
**/
|
|
236
221
|
var useInputStyles = function useInputStyles(_ref2) {
|
|
237
222
|
var disabled = _ref2.disabled,
|
|
238
|
-
|
|
239
|
-
|
|
223
|
+
startAdornment = _ref2.startAdornment,
|
|
224
|
+
endAdornment = _ref2.endAdornment;
|
|
240
225
|
var theme = useTheme();
|
|
241
226
|
var overflowStyles = useOverflowStrategy('truncate');
|
|
242
227
|
var focusRingStyles = useFocusRing({
|
|
@@ -248,18 +233,15 @@ var useInputStyles = function useInputStyles(_ref2) {
|
|
|
248
233
|
size: 'standard',
|
|
249
234
|
weight: 'regular'
|
|
250
235
|
});
|
|
251
|
-
|
|
252
236
|
var _textStyles = _slicedToArray(textStyles, 2),
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
237
|
+
typographyStyles = _textStyles[0],
|
|
238
|
+
responsiveStyles = _textStyles[1];
|
|
256
239
|
return [{
|
|
257
240
|
flex: 1,
|
|
258
241
|
position: 'relative',
|
|
259
242
|
height: 'medium',
|
|
260
243
|
paddingLeft: startAdornment ? 'none' : 'medium',
|
|
261
244
|
paddingRight: endAdornment ? 'none' : 'medium',
|
|
262
|
-
shadow: 'small',
|
|
263
245
|
width: 'full'
|
|
264
246
|
}, _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, typographyStyles), responsiveStyles), overflowStyles), {}, {
|
|
265
247
|
':enabled': {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spark-web/text-input",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"homepage": "https://github.com/brighte-labs/spark-web#readme",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -17,19 +17,19 @@
|
|
|
17
17
|
"dependencies": {
|
|
18
18
|
"@babel/runtime": "^7.19.0",
|
|
19
19
|
"@emotion/css": "^11.9.0",
|
|
20
|
-
"@spark-web/a11y": "^1.
|
|
21
|
-
"@spark-web/box": "^1.
|
|
22
|
-
"@spark-web/text": "^1.
|
|
23
|
-
"@spark-web/theme": "^3.
|
|
24
|
-
"@spark-web/utils": "^1.
|
|
20
|
+
"@spark-web/a11y": "^1.4.0",
|
|
21
|
+
"@spark-web/box": "^1.2.0",
|
|
22
|
+
"@spark-web/text": "^1.2.0",
|
|
23
|
+
"@spark-web/theme": "^3.2.0",
|
|
24
|
+
"@spark-web/utils": "^1.3.0"
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
|
-
"@spark-web/field": "^3.0
|
|
28
|
-
"@types/react": "^
|
|
29
|
-
"react": "^
|
|
27
|
+
"@spark-web/field": "^3.1.0",
|
|
28
|
+
"@types/react": "^18.2.0",
|
|
29
|
+
"react": "^18.2.0"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
|
-
"@spark-web/field": "^3.0
|
|
32
|
+
"@spark-web/field": "^3.1.0",
|
|
33
33
|
"react": ">=17.0.2"
|
|
34
34
|
},
|
|
35
35
|
"engines": {
|