@mw-kit/mw-ui 1.7.37 → 1.7.39
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/components/Range/interfaces.d.ts +1 -0
- package/dist/components/Input/components/Range/styles.d.ts +5 -0
- package/dist/index.js +157 -58
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +157 -58
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.modern.js
CHANGED
|
@@ -15542,7 +15542,7 @@ var Switch = function Switch(props) {
|
|
|
15542
15542
|
})), React__default.createElement("span", null), label.after && React__default.createElement(LabelContainer$3, null, label.after));
|
|
15543
15543
|
};
|
|
15544
15544
|
|
|
15545
|
-
var _templateObject$q, _templateObject2$m, _templateObject3$i, _templateObject4$d, _templateObject5$b, _templateObject6$a, _templateObject7$a, _templateObject8$8, _templateObject9$8, _templateObject10$6, _templateObject11$4, _templateObject12$3, _templateObject13$2, _templateObject14$2, _templateObject15$2, _templateObject16$2;
|
|
15545
|
+
var _templateObject$q, _templateObject2$m, _templateObject3$i, _templateObject4$d, _templateObject5$b, _templateObject6$a, _templateObject7$a, _templateObject8$8, _templateObject9$8, _templateObject10$6, _templateObject11$4, _templateObject12$3, _templateObject13$2, _templateObject14$2, _templateObject15$2, _templateObject16$2, _templateObject17$2, _templateObject18$2, _templateObject19$1, _templateObject20$1;
|
|
15546
15546
|
var bullet = css(_templateObject$q || (_templateObject$q = _taggedTemplateLiteralLoose(["\n appearance: none;\n width: ", ";\n height: ", ";\n border-radius: 100%;\n border-width: 1px;\n border-style: solid;\n background-color: ", ";\n box-shadow: 0px 1px 3px ", ";\n"])), function (_ref) {
|
|
15547
15547
|
var theme = _ref.theme;
|
|
15548
15548
|
return theme.spacings.s4;
|
|
@@ -15556,61 +15556,88 @@ var bullet = css(_templateObject$q || (_templateObject$q = _taggedTemplateLitera
|
|
|
15556
15556
|
var theme = _ref4.theme;
|
|
15557
15557
|
return theme.getColor('black', 10);
|
|
15558
15558
|
});
|
|
15559
|
-
var
|
|
15560
|
-
var Label$5 = styled.label(_templateObject3$i || (_templateObject3$i = _taggedTemplateLiteralLoose(["\n ", ";\n line-height: 19px;\n\n width: ", ";\n box-sizing: border-box;\n display: block;\n position: relative;\n\n ", "\n\n > div:first-child {\n display: inline-block;\n margin-bottom: ", ";\n\n ", "\n }\n"])), function (_ref5) {
|
|
15559
|
+
var NavBar = styled.div(_templateObject2$m || (_templateObject2$m = _taggedTemplateLiteralLoose(["\n position: absolute;\n z-index: 2;\n\n left: 0;\n width: 100%;\n height: calc(33px + ", ");\n transition: height 0.25s ease-in-out;\n overflow: hidden;\n\n ", "\n\n > div {\n position: absolute;\n z-index: 2;\n\n width: 100px;\n left: ", ";\n background-color: ", ";\n color: ", ";\n padding: ", ";\n border-radius: 4px;\n\n display: flex;\n align-items: center;\n justify-content: space-between;\n }\n"])), function (_ref5) {
|
|
15561
15560
|
var theme = _ref5.theme;
|
|
15562
|
-
return theme.useTypography('p');
|
|
15563
|
-
}, function (_ref6) {
|
|
15564
|
-
var width = _ref6.width;
|
|
15565
|
-
return width || '100%';
|
|
15566
|
-
}, function (_ref7) {
|
|
15567
|
-
var disabled = _ref7.disabled;
|
|
15568
|
-
if (!disabled) return;
|
|
15569
|
-
return css(_templateObject4$d || (_templateObject4$d = _taggedTemplateLiteralLoose(["\n opacity: 0.5;\n "])));
|
|
15570
|
-
}, function (_ref8) {
|
|
15571
|
-
var theme = _ref8.theme;
|
|
15572
15561
|
return theme.spacings.s1;
|
|
15562
|
+
}, function (_ref6) {
|
|
15563
|
+
var position = _ref6.position;
|
|
15564
|
+
return position === 'bottom' ? css(_templateObject3$i || (_templateObject3$i = _taggedTemplateLiteralLoose(["\n bottom: 100%;\n > div {\n bottom: ", ";\n }\n "])), function (_ref7) {
|
|
15565
|
+
var theme = _ref7.theme;
|
|
15566
|
+
return theme.spacings.s1;
|
|
15567
|
+
}) : css(_templateObject4$d || (_templateObject4$d = _taggedTemplateLiteralLoose(["\n top: 100%;\n > div {\n top: ", ";\n }\n "])), function (_ref8) {
|
|
15568
|
+
var theme = _ref8.theme;
|
|
15569
|
+
return theme.spacings.s1;
|
|
15570
|
+
});
|
|
15573
15571
|
}, function (_ref9) {
|
|
15574
|
-
var
|
|
15575
|
-
if (
|
|
15576
|
-
|
|
15572
|
+
var percent = _ref9.percent;
|
|
15573
|
+
if (percent < 10) return '0%';
|
|
15574
|
+
if (percent > 90) return 'calc(100% - 100px)';
|
|
15575
|
+
return "calc(" + percent + "% - 50px + 22px * " + (50 - percent) / 100 + ")";
|
|
15576
|
+
}, function (_ref10) {
|
|
15577
|
+
var theme = _ref10.theme;
|
|
15578
|
+
return theme.colors.blue;
|
|
15579
|
+
}, function (_ref11) {
|
|
15580
|
+
var theme = _ref11.theme;
|
|
15581
|
+
return theme.colors.white;
|
|
15582
|
+
}, function (_ref12) {
|
|
15583
|
+
var theme = _ref12.theme;
|
|
15584
|
+
return theme.spacings.s1;
|
|
15577
15585
|
});
|
|
15578
|
-
var
|
|
15579
|
-
|
|
15580
|
-
|
|
15586
|
+
var Input$2 = styled.input(_templateObject5$b || (_templateObject5$b = _taggedTemplateLiteralLoose(["\n appearance: none;\n width: 100%;\n height: 10px;\n background-color: transparent;\n outline: none;\n position: relative;\n z-index: 3;\n margin: 0;\n\n :not(:disabled) {\n cursor: pointer;\n }\n\n /** firefox */\n ::-moz-range-thumb {\n ", "\n }\n /** ie */\n ::-ms-thumb {\n ", "\n }\n /** chrome */\n ::-webkit-slider-thumb {\n ", "\n }\n"])), bullet, bullet, bullet);
|
|
15587
|
+
var LabelContainer$4 = styled.div(_templateObject6$a || (_templateObject6$a = _taggedTemplateLiteralLoose(["\n display: inline-block;\n margin-bottom: ", ";\n"])), function (_ref13) {
|
|
15588
|
+
var theme = _ref13.theme;
|
|
15589
|
+
return theme.spacings.s1;
|
|
15590
|
+
});
|
|
15591
|
+
var Label$5 = styled.label(_templateObject7$a || (_templateObject7$a = _taggedTemplateLiteralLoose(["\n ", ";\n line-height: 19px;\n\n width: ", ";\n box-sizing: border-box;\n display: block;\n position: relative;\n\n ", "\n\n > ", " {\n ", "\n }\n\n :not(:hover) ", " {\n height: 0;\n }\n"])), function (_ref14) {
|
|
15592
|
+
var theme = _ref14.theme;
|
|
15593
|
+
return theme.useTypography('p');
|
|
15594
|
+
}, function (_ref15) {
|
|
15595
|
+
var width = _ref15.width;
|
|
15596
|
+
return width || '100%';
|
|
15597
|
+
}, function (_ref16) {
|
|
15598
|
+
var disabled = _ref16.disabled;
|
|
15599
|
+
if (!disabled) return;
|
|
15600
|
+
return css(_templateObject8$8 || (_templateObject8$8 = _taggedTemplateLiteralLoose(["\n opacity: 0.5;\n "])));
|
|
15601
|
+
}, LabelContainer$4, function (_ref17) {
|
|
15602
|
+
var required = _ref17.required;
|
|
15603
|
+
return required && css(_templateObject9$8 || (_templateObject9$8 = _taggedTemplateLiteralLoose(["\n :after {\n content: ' *';\n }\n "])));
|
|
15604
|
+
}, NavBar);
|
|
15605
|
+
var InputContainer$1 = styled.div(_templateObject10$6 || (_templateObject10$6 = _taggedTemplateLiteralLoose(["\n flex: 1;\n display: flex;\n gap: 6px;\n\n > div {\n position: relative;\n }\n\n ", "\n"])), function (_ref18) {
|
|
15606
|
+
var theme = _ref18.theme,
|
|
15607
|
+
invalid = _ref18.invalid;
|
|
15581
15608
|
|
|
15582
15609
|
if (!invalid) {
|
|
15583
|
-
return css(
|
|
15610
|
+
return css(_templateObject11$4 || (_templateObject11$4 = _taggedTemplateLiteralLoose(["\n ", " > span {\n background-color: ", ";\n }\n\n ", " {\n /** firefox */\n ::-moz-range-thumb {\n border-color: ", ";\n }\n /** ie */\n ::-ms-thumb {\n border-color: ", ";\n }\n /** chrome */\n ::-webkit-slider-thumb {\n border-color: ", ";\n }\n }\n "])), SelectedArea, theme.colors.blue, Input$2, theme.colors.lightestGrey, theme.colors.lightestGrey, theme.colors.lightestGrey);
|
|
15584
15611
|
}
|
|
15585
15612
|
|
|
15586
|
-
return css(
|
|
15613
|
+
return css(_templateObject12$3 || (_templateObject12$3 = _taggedTemplateLiteralLoose(["\n ", " > span {\n background-color: ", ";\n }\n\n ", " {\n /** firefox */\n ::-moz-range-thumb {\n border-color: ", ";\n }\n /** ie */\n ::-ms-thumb {\n border-color: ", ";\n }\n /** chrome */\n ::-webkit-slider-thumb {\n border-color: ", ";\n }\n }\n "])), SelectedArea, theme.colors.warningRed, Input$2, theme.colors.warningRed, theme.colors.warningRed, theme.colors.warningRed);
|
|
15587
15614
|
});
|
|
15588
|
-
var MinMaxLabelContainer = styled.div(
|
|
15589
|
-
var LabelsContainer = styled.div(
|
|
15590
|
-
var position =
|
|
15615
|
+
var MinMaxLabelContainer = styled.div(_templateObject13$2 || (_templateObject13$2 = _taggedTemplateLiteralLoose(["\n display: flex;\n padding-bottom: 2px;\n"])));
|
|
15616
|
+
var LabelsContainer = styled.div(_templateObject14$2 || (_templateObject14$2 = _taggedTemplateLiteralLoose(["\n display: flex;\n gap: 7px;\n\n ", "\n"])), function (_ref19) {
|
|
15617
|
+
var position = _ref19.position;
|
|
15591
15618
|
|
|
15592
15619
|
if (position === 'bottom') {
|
|
15593
|
-
return css(
|
|
15620
|
+
return css(_templateObject15$2 || (_templateObject15$2 = _taggedTemplateLiteralLoose(["\n ", " {\n flex-direction: column-reverse;\n }\n\n ", " {\n :after {\n bottom: calc(100% + 10.5px);\n }\n }\n\n ", " {\n align-items: start;\n }\n "])), InputContainer$1, Marker, MinMaxLabelContainer);
|
|
15594
15621
|
}
|
|
15595
15622
|
|
|
15596
|
-
return css(
|
|
15623
|
+
return css(_templateObject16$2 || (_templateObject16$2 = _taggedTemplateLiteralLoose(["\n ", " {\n flex-direction: column;\n }\n\n ", " {\n :after {\n top: calc(100% + 8px);\n }\n }\n\n ", " {\n align-items: end;\n }\n "])), InputContainer$1, Marker, MinMaxLabelContainer);
|
|
15597
15624
|
});
|
|
15598
|
-
var SelectedArea = styled.div(
|
|
15599
|
-
var theme =
|
|
15625
|
+
var SelectedArea = styled.div(_templateObject17$2 || (_templateObject17$2 = _taggedTemplateLiteralLoose(["\n background-color: ", ";\n\n height: 3px;\n width: 100%;\n position: absolute;\n bottom: calc(50% - 2px);\n left: 0;\n display: flex;\n z-index: 1;\n\n > span {\n width: ", "%;\n display: block;\n box-sizing: border-box;\n height: 100%;\n }\n"])), function (_ref20) {
|
|
15626
|
+
var theme = _ref20.theme;
|
|
15600
15627
|
return theme.getColor('greyishBlue', 10);
|
|
15601
|
-
}, function (
|
|
15602
|
-
var percent =
|
|
15628
|
+
}, function (_ref21) {
|
|
15629
|
+
var percent = _ref21.percent;
|
|
15603
15630
|
return percent;
|
|
15604
15631
|
});
|
|
15605
|
-
var MarkersContainer = styled.div(
|
|
15606
|
-
var Marker = styled.div(
|
|
15607
|
-
var left =
|
|
15632
|
+
var MarkersContainer = styled.div(_templateObject18$2 || (_templateObject18$2 = _taggedTemplateLiteralLoose(["\n height: 17px;\n"])));
|
|
15633
|
+
var Marker = styled.div(_templateObject19$1 || (_templateObject19$1 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 0;\n width: 40px;\n text-align: center;\n left: ", ";\n z-index: 2;\n\n :first-child {\n left: 0;\n text-align: left;\n\n :after {\n left: 0;\n }\n }\n :last-child {\n right: 0;\n left: unset;\n text-align: right;\n\n :after {\n right: 0;\n left: unset;\n }\n }\n\n ", "\n"])), function (_ref22) {
|
|
15634
|
+
var left = _ref22.left;
|
|
15608
15635
|
return left;
|
|
15609
|
-
}, function (
|
|
15610
|
-
var bullet =
|
|
15611
|
-
theme =
|
|
15636
|
+
}, function (_ref23) {
|
|
15637
|
+
var bullet = _ref23.bullet,
|
|
15638
|
+
theme = _ref23.theme;
|
|
15612
15639
|
if (!bullet) return;
|
|
15613
|
-
return css(
|
|
15640
|
+
return css(_templateObject20$1 || (_templateObject20$1 = _taggedTemplateLiteralLoose(["\n :after {\n content: '';\n position: absolute;\n left: calc(50% - 5px);\n width: 10px;\n height: 10px;\n border-radius: 100%;\n border: 1px solid ", ";\n background-color: ", ";\n box-shadow: 0px 1px 3px ", ";\n }\n "])), theme.colors.lightestGrey, theme.colors.white, theme.getColor('black', 10));
|
|
15614
15641
|
});
|
|
15615
15642
|
|
|
15616
15643
|
var getMarkers = function getMarkers(props) {
|
|
@@ -15683,6 +15710,16 @@ var getMarkers = function getMarkers(props) {
|
|
|
15683
15710
|
};
|
|
15684
15711
|
};
|
|
15685
15712
|
|
|
15713
|
+
var getLeft = function getLeft(markers, percent, index) {
|
|
15714
|
+
var z = markers - 2;
|
|
15715
|
+
if (z < markers - 1) z = markers - 1;
|
|
15716
|
+
var y = 20 / z;
|
|
15717
|
+
var x = 20 - y * (z - index);
|
|
15718
|
+
var p = index * percent;
|
|
15719
|
+
var left = "calc(" + p + "% - 10px - " + x + "px)";
|
|
15720
|
+
return left;
|
|
15721
|
+
};
|
|
15722
|
+
|
|
15686
15723
|
var Range = React__default.forwardRef(function (props, ref) {
|
|
15687
15724
|
var label = props.label,
|
|
15688
15725
|
minLabel = props.minLabel,
|
|
@@ -15690,7 +15727,8 @@ var Range = React__default.forwardRef(function (props, ref) {
|
|
|
15690
15727
|
invalid = props.invalid,
|
|
15691
15728
|
disabled = props.disabled,
|
|
15692
15729
|
required = props.required,
|
|
15693
|
-
width = props.width
|
|
15730
|
+
width = props.width,
|
|
15731
|
+
setValue = props.setValue;
|
|
15694
15732
|
|
|
15695
15733
|
var _getMarkers = getMarkers(props),
|
|
15696
15734
|
min = _getMarkers.min,
|
|
@@ -15709,18 +15747,69 @@ var Range = React__default.forwardRef(function (props, ref) {
|
|
|
15709
15747
|
throw new Error('Invalid value');
|
|
15710
15748
|
}
|
|
15711
15749
|
|
|
15712
|
-
var
|
|
15713
|
-
|
|
15714
|
-
var onChange = strict ? function (event) {
|
|
15715
|
-
var index = parseInt(event.target.value);
|
|
15750
|
+
var getValue = strict ? function (v) {
|
|
15751
|
+
var index = typeof v === 'number' ? v : parseInt(v);
|
|
15716
15752
|
var value = markers[index].value;
|
|
15753
|
+
return value;
|
|
15754
|
+
} : function (v) {
|
|
15755
|
+
var value = typeof v === 'number' ? v : parseFloat(v);
|
|
15756
|
+
return value;
|
|
15757
|
+
};
|
|
15717
15758
|
|
|
15718
|
-
|
|
15719
|
-
|
|
15720
|
-
|
|
15759
|
+
var _onChange = props.onChange || function (_event, value) {
|
|
15760
|
+
return setValue(value);
|
|
15761
|
+
};
|
|
15762
|
+
|
|
15763
|
+
var onChange = function onChange(event) {
|
|
15764
|
+
var value = getValue(event.target.value);
|
|
15721
15765
|
|
|
15722
15766
|
_onChange(event, value);
|
|
15723
15767
|
};
|
|
15768
|
+
|
|
15769
|
+
var _ref = strict ? {
|
|
15770
|
+
increment: function increment() {
|
|
15771
|
+
setValue(function (prev) {
|
|
15772
|
+
var index = markers.findIndex(function (e) {
|
|
15773
|
+
return e.value === prev;
|
|
15774
|
+
});
|
|
15775
|
+
if (index < 0) return prev;
|
|
15776
|
+
var x = index + 1;
|
|
15777
|
+
return x < markers.length ? markers[x].value : prev;
|
|
15778
|
+
});
|
|
15779
|
+
},
|
|
15780
|
+
canIncrement: value + 1 < markers.length,
|
|
15781
|
+
decrement: function decrement() {
|
|
15782
|
+
setValue(function (prev) {
|
|
15783
|
+
var index = markers.findIndex(function (e) {
|
|
15784
|
+
return e.value === prev;
|
|
15785
|
+
});
|
|
15786
|
+
if (index < 0) return prev;
|
|
15787
|
+
var x = index - 1;
|
|
15788
|
+
return x >= 0 ? markers[x].value : prev;
|
|
15789
|
+
});
|
|
15790
|
+
},
|
|
15791
|
+
canDecrement: value - 1 >= 0
|
|
15792
|
+
} : {
|
|
15793
|
+
increment: function increment() {
|
|
15794
|
+
setValue(function (prev) {
|
|
15795
|
+
var x = prev + step;
|
|
15796
|
+
return x > max ? prev : x;
|
|
15797
|
+
});
|
|
15798
|
+
},
|
|
15799
|
+
canIncrement: value + step <= max,
|
|
15800
|
+
decrement: function decrement() {
|
|
15801
|
+
setValue(function (prev) {
|
|
15802
|
+
var x = prev - step;
|
|
15803
|
+
return x < min ? prev : x;
|
|
15804
|
+
});
|
|
15805
|
+
},
|
|
15806
|
+
canDecrement: value - step >= min
|
|
15807
|
+
},
|
|
15808
|
+
increment = _ref.increment,
|
|
15809
|
+
canIncrement = _ref.canIncrement,
|
|
15810
|
+
decrement = _ref.decrement,
|
|
15811
|
+
canDecrement = _ref.canDecrement;
|
|
15812
|
+
|
|
15724
15813
|
var inputProps = filterObject(props, ['label', 'minLabel', 'maxLabel', 'invalid', 'required', 'width', 'onChange', 'step', 'value'], {
|
|
15725
15814
|
min: min,
|
|
15726
15815
|
max: max,
|
|
@@ -15732,17 +15821,14 @@ var Range = React__default.forwardRef(function (props, ref) {
|
|
|
15732
15821
|
required: required ? 1 : 0,
|
|
15733
15822
|
disabled: disabled ? 1 : 0,
|
|
15734
15823
|
width: width
|
|
15735
|
-
}, React__default.createElement("div",
|
|
15824
|
+
}, label && React__default.createElement("div", {
|
|
15825
|
+
children: label
|
|
15826
|
+
}), React__default.createElement(LabelsContainer, {
|
|
15736
15827
|
position: position
|
|
15737
15828
|
}, minLabel && React__default.createElement(MinMaxLabelContainer, null, minLabel), React__default.createElement(InputContainer$1, {
|
|
15738
15829
|
invalid: invalid ? 1 : 0
|
|
15739
15830
|
}, markers.length > 0 && React__default.createElement(MarkersContainer, null, markers.map(function (marker, index) {
|
|
15740
|
-
var
|
|
15741
|
-
if (z < markers.length - 1) z = markers.length - 1;
|
|
15742
|
-
var y = 20 / z;
|
|
15743
|
-
var x = 20 - y * (z - index);
|
|
15744
|
-
var p = index * percent;
|
|
15745
|
-
var left = "calc(" + p + "% - 10px - " + x + "px)";
|
|
15831
|
+
var left = getLeft(markers.length, percent, index);
|
|
15746
15832
|
var bullet = marker.value > value ? 1 : 0;
|
|
15747
15833
|
return React__default.createElement(Marker, {
|
|
15748
15834
|
key: marker.value,
|
|
@@ -15751,7 +15837,20 @@ var Range = React__default.forwardRef(function (props, ref) {
|
|
|
15751
15837
|
}, marker.label);
|
|
15752
15838
|
})), React__default.createElement("div", null, React__default.createElement(Input$2, Object.assign({
|
|
15753
15839
|
ref: ref
|
|
15754
|
-
}, inputProps)), React__default.createElement(
|
|
15840
|
+
}, inputProps)), React__default.createElement(NavBar, {
|
|
15841
|
+
percent: value * 100 / max,
|
|
15842
|
+
position: position
|
|
15843
|
+
}, React__default.createElement("div", null, React__default.createElement(Icon, {
|
|
15844
|
+
type: 'feather',
|
|
15845
|
+
icon: 'minus_circle',
|
|
15846
|
+
color: 'white',
|
|
15847
|
+
onClick: canDecrement ? decrement : undefined
|
|
15848
|
+
}), getValue(value), React__default.createElement(Icon, {
|
|
15849
|
+
type: 'feather',
|
|
15850
|
+
icon: 'plus_circle',
|
|
15851
|
+
color: 'white',
|
|
15852
|
+
onClick: canIncrement ? increment : undefined
|
|
15853
|
+
}))), React__default.createElement(SelectedArea, {
|
|
15755
15854
|
percent: percent
|
|
15756
15855
|
}, Array(spans).fill(1).map(function (_value, index) {
|
|
15757
15856
|
return React__default.createElement("span", {
|
|
@@ -15762,7 +15861,7 @@ var Range = React__default.forwardRef(function (props, ref) {
|
|
|
15762
15861
|
Range.displayName = 'input';
|
|
15763
15862
|
|
|
15764
15863
|
var _templateObject$r, _templateObject2$n, _templateObject3$j, _templateObject4$e, _templateObject5$c, _templateObject6$b, _templateObject7$b;
|
|
15765
|
-
var LabelContainer$
|
|
15864
|
+
var LabelContainer$5 = styled.div(_templateObject$r || (_templateObject$r = _taggedTemplateLiteralLoose(["\n ", "\n display: flex;\n align-items: center;\n"])), function (_ref) {
|
|
15766
15865
|
var theme = _ref.theme;
|
|
15767
15866
|
return theme.useTypography('p');
|
|
15768
15867
|
});
|
|
@@ -15780,7 +15879,7 @@ var Label$6 = styled.label(_templateObject2$n || (_templateObject2$n = _taggedTe
|
|
|
15780
15879
|
}, function (_ref4) {
|
|
15781
15880
|
var required = _ref4.required;
|
|
15782
15881
|
if (!required) return;
|
|
15783
|
-
return css(_templateObject5$c || (_templateObject5$c = _taggedTemplateLiteralLoose(["\n > ", " {\n :after {\n content: ' *';\n }\n }\n "])), LabelContainer$
|
|
15882
|
+
return css(_templateObject5$c || (_templateObject5$c = _taggedTemplateLiteralLoose(["\n > ", " {\n :after {\n content: ' *';\n }\n }\n "])), LabelContainer$5);
|
|
15784
15883
|
}, function (_ref5) {
|
|
15785
15884
|
var invalid = _ref5.invalid;
|
|
15786
15885
|
|
|
@@ -15818,7 +15917,7 @@ var RadioButton = function RadioButton(props) {
|
|
|
15818
15917
|
invalid: invalid ? 1 : 0
|
|
15819
15918
|
}, React__default.createElement("input", Object.assign({}, htmlProps, {
|
|
15820
15919
|
type: 'radio'
|
|
15821
|
-
})), React__default.createElement("span", null), label && React__default.createElement(LabelContainer$
|
|
15920
|
+
})), React__default.createElement("span", null), label && React__default.createElement(LabelContainer$5, null, label));
|
|
15822
15921
|
};
|
|
15823
15922
|
|
|
15824
15923
|
var validate = function validate(_ref, min, max) {
|
|
@@ -16006,7 +16105,7 @@ var parse = function parse(value) {
|
|
|
16006
16105
|
|
|
16007
16106
|
var _templateObject$s, _templateObject2$o, _templateObject3$k, _templateObject4$f, _templateObject5$d, _templateObject6$c, _templateObject7$c, _templateObject8$9, _templateObject9$9, _templateObject10$7, _templateObject11$5, _templateObject12$4;
|
|
16008
16107
|
var RelativeContainer$5 = styled.div(_templateObject$s || (_templateObject$s = _taggedTemplateLiteralLoose(["\n position: relative;\n user-select: none;\n min-width: 220px;\n\n > input,\n > label > input {\n color: transparent;\n background-color: transparent;\n width: 1px;\n height: 1px;\n position: absolute;\n left: 0;\n bottom: 0;\n border: 0;\n padding: 0;\n overflow: hidden;\n outline: none;\n box-shadow: none;\n }\n"])));
|
|
16009
|
-
var LabelContainer$
|
|
16108
|
+
var LabelContainer$6 = styled.div(_templateObject2$o || (_templateObject2$o = _taggedTemplateLiteralLoose(["\n ", "\n line-height: 17px;\n flex: 1;\n\n :first-child {\n text-align: left;\n }\n :not(:first-child) {\n text-align: center;\n }\n\n ", "\n\n ", ";\n"])), function (_ref) {
|
|
16010
16109
|
var theme = _ref.theme;
|
|
16011
16110
|
return theme.useTypography('p');
|
|
16012
16111
|
}, function (_ref2) {
|
|
@@ -16174,7 +16273,7 @@ var Component$1 = React__default.forwardRef(function (props, ref) {
|
|
|
16174
16273
|
paddingless: props.paddingless ? 1 : 0,
|
|
16175
16274
|
borderless: props.borderless ? 1 : 0
|
|
16176
16275
|
}, function () {
|
|
16177
|
-
var label = React__default.createElement(LabelContainer$
|
|
16276
|
+
var label = React__default.createElement(LabelContainer$6, {
|
|
16178
16277
|
onClick: onClick
|
|
16179
16278
|
}, !value.some(function (v) {
|
|
16180
16279
|
return !isDateInstance(v);
|