@activecollab/components 1.0.9 → 1.0.13
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/cjs/components/Autocomplete/Autocomplete.js +3 -8
- package/dist/cjs/components/Autocomplete/Autocomplete.js.map +1 -1
- package/dist/cjs/components/Autocomplete/Styles.js +17 -4
- package/dist/cjs/components/Autocomplete/Styles.js.map +1 -1
- package/dist/cjs/components/Menu/Menu.js +2 -1
- package/dist/cjs/components/Menu/Menu.js.map +1 -1
- package/dist/cjs/components/Pickers/Styles.js +5 -3
- package/dist/cjs/components/Pickers/Styles.js.map +1 -1
- package/dist/cjs/components/ScrollShadow/ScrollShadow.js.map +1 -1
- package/dist/cjs/components/SelectDate/DatePickerForm.js +4 -2
- package/dist/cjs/components/SelectDate/DatePickerForm.js.map +1 -1
- package/dist/cjs/components/SelectDate/Styles.js +4 -4
- package/dist/cjs/components/SelectDate/Styles.js.map +1 -1
- package/dist/cjs/components/Steppers/DateStepper/Styles.js +2 -2
- package/dist/cjs/components/Steppers/DateStepper/Styles.js.map +1 -1
- package/dist/esm/components/Autocomplete/Autocomplete.d.ts.map +1 -1
- package/dist/esm/components/Autocomplete/Autocomplete.js +4 -7
- package/dist/esm/components/Autocomplete/Autocomplete.js.map +1 -1
- package/dist/esm/components/Autocomplete/Styles.d.ts +4 -0
- package/dist/esm/components/Autocomplete/Styles.d.ts.map +1 -1
- package/dist/esm/components/Autocomplete/Styles.js +13 -3
- package/dist/esm/components/Autocomplete/Styles.js.map +1 -1
- package/dist/esm/components/Menu/Menu.d.ts +1 -0
- package/dist/esm/components/Menu/Menu.d.ts.map +1 -1
- package/dist/esm/components/Menu/Menu.js +3 -3
- package/dist/esm/components/Menu/Menu.js.map +1 -1
- package/dist/esm/components/Pickers/Styles.d.ts.map +1 -1
- package/dist/esm/components/Pickers/Styles.js +5 -3
- package/dist/esm/components/Pickers/Styles.js.map +1 -1
- package/dist/esm/components/ScrollShadow/ScrollShadow.d.ts +1 -2
- package/dist/esm/components/ScrollShadow/ScrollShadow.d.ts.map +1 -1
- package/dist/esm/components/ScrollShadow/ScrollShadow.js.map +1 -1
- package/dist/esm/components/SelectDate/DatePickerForm.d.ts.map +1 -1
- package/dist/esm/components/SelectDate/DatePickerForm.js +3 -2
- package/dist/esm/components/SelectDate/DatePickerForm.js.map +1 -1
- package/dist/esm/components/SelectDate/Styles.d.ts +1 -1
- package/dist/esm/components/SelectDate/Styles.d.ts.map +1 -1
- package/dist/esm/components/SelectDate/Styles.js +2 -3
- package/dist/esm/components/SelectDate/Styles.js.map +1 -1
- package/dist/esm/components/Steppers/DateStepper/Styles.d.ts.map +1 -1
- package/dist/esm/components/Steppers/DateStepper/Styles.js +2 -2
- package/dist/esm/components/Steppers/DateStepper/Styles.js.map +1 -1
- package/dist/index.js +227 -216
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/package.json +2 -3
package/dist/index.js
CHANGED
|
@@ -1106,7 +1106,7 @@
|
|
|
1106
1106
|
var StyledMonth = styled__default["default"].div.withConfig({
|
|
1107
1107
|
displayName: "Styles__StyledMonth",
|
|
1108
1108
|
componentId: "sc-1owijsg-3"
|
|
1109
|
-
})(["width:26%;transition-duration:0.3s;", " ", " ", " ", ""], {
|
|
1109
|
+
})(["width:26%;transition-duration:0.3s;", " ", " ", " ", " ", ""], {
|
|
1110
1110
|
"margin": "auto",
|
|
1111
1111
|
"cursor": "pointer",
|
|
1112
1112
|
"borderRadius": "1rem",
|
|
@@ -1118,9 +1118,11 @@
|
|
|
1118
1118
|
"color": "var(--color-theme-100)"
|
|
1119
1119
|
});
|
|
1120
1120
|
}, function (props) {
|
|
1121
|
-
return props.$isCurrent && styled.css(["", ""], {
|
|
1121
|
+
return props.$isCurrent && !props.$isSelected && styled.css(["", ""], {
|
|
1122
1122
|
"color": "var(--color-primary)"
|
|
1123
1123
|
});
|
|
1124
|
+
}, function (props) {
|
|
1125
|
+
return props.$isCurrent && props.$isSelected && styled.css(["color:var(--color-theme-100);"]);
|
|
1124
1126
|
}, function (props) {
|
|
1125
1127
|
return props.$isCurrentQuarter && styled.css(["background-color:var(--color-primary-300);"]);
|
|
1126
1128
|
});
|
|
@@ -1138,7 +1140,7 @@
|
|
|
1138
1140
|
var StyledYearMonthPickerNavBarItem = styled__default["default"].span.withConfig({
|
|
1139
1141
|
displayName: "Styles__StyledYearMonthPickerNavBarItem",
|
|
1140
1142
|
componentId: "sc-1owijsg-6"
|
|
1141
|
-
})(["", " transition-duration:0.3s;&:hover{background-color:var(--color-primary-300);border-radius:15px;}"], {
|
|
1143
|
+
})(["", " transition-duration:0.3s;margin-top:1px;display:inline-block;height:24px;&:hover{background-color:var(--color-primary-300);border-radius:15px;}"], {
|
|
1142
1144
|
"paddingLeft": "1rem",
|
|
1143
1145
|
"paddingRight": "1rem",
|
|
1144
1146
|
"cursor": "pointer"
|
|
@@ -1872,6 +1874,7 @@
|
|
|
1872
1874
|
_ref$position = _ref.position,
|
|
1873
1875
|
position = _ref$position === void 0 ? "bottom-start" : _ref$position,
|
|
1874
1876
|
target = _ref.target,
|
|
1877
|
+
className = _ref.className,
|
|
1875
1878
|
menuClassName = _ref.menuClassName,
|
|
1876
1879
|
popperClassName = _ref.popperClassName,
|
|
1877
1880
|
backgroundElementClass = _ref.backgroundElementClass,
|
|
@@ -1933,7 +1936,7 @@
|
|
|
1933
1936
|
className: popperClassName,
|
|
1934
1937
|
tabIndex: -1
|
|
1935
1938
|
}, /*#__PURE__*/React__default["default"].createElement(StyledMenu$1, {
|
|
1936
|
-
className: classnames__default["default"]("c-simple-menu__paper", "c-simple-menu__".concat(mode), menuClassName),
|
|
1939
|
+
className: classnames__default["default"]("c-simple-menu__paper", "c-simple-menu__".concat(mode), menuClassName, className),
|
|
1937
1940
|
$mode: mode,
|
|
1938
1941
|
onMouseDown: onMenuClick
|
|
1939
1942
|
}, /*#__PURE__*/React__default["default"].createElement(MenuContextProvider, {
|
|
@@ -1990,7 +1993,7 @@
|
|
|
1990
1993
|
var StyledButton = styled__default["default"].button.withConfig({
|
|
1991
1994
|
displayName: "Styles__StyledButton",
|
|
1992
1995
|
componentId: "sc-1v8h7mt-0"
|
|
1993
|
-
})(["", " ", " color:var(--color-theme-700);margin:0;padding:0;background:none;width:
|
|
1996
|
+
})(["", " ", " color:var(--color-theme-700);margin:0;padding:0;background:none;width:100%;height:auto;border:none;height:30px;transition:all 0.3s ease;", " svg{fill:currentColor;}&::-moz-focus-inner{border:0;}&:focus{outline:none;}&:hover{text-decoration:none;}&:disabled{cursor:default;opacity:50%;pointer-events:none;}"], FontStyle, BoxSizingStyle, {
|
|
1994
1997
|
"position": "relative",
|
|
1995
1998
|
"WebkitFontSmoothing": "antialiased",
|
|
1996
1999
|
"MozOsxFontSmoothing": "grayscale",
|
|
@@ -2027,7 +2030,7 @@
|
|
|
2027
2030
|
var StyledDiv = styled__default["default"].div.withConfig({
|
|
2028
2031
|
displayName: "Styles__StyledDiv",
|
|
2029
2032
|
componentId: "sc-1v8h7mt-4"
|
|
2030
|
-
})(["", " ", " ", " height:32px;transition:all 0.3s ease;
|
|
2033
|
+
})(["", " ", " ", " height:32px;transition:all 0.3s ease;background-color:transparent;border:solid 1px var(--color-theme-700);color:var(--color-theme-700);margin-right:-1px;svg{fill:currentColor;}&::-moz-focus-inner{border:0;}&:focus{outline:none;}&:disabled{cursor:default;opacity:50%;pointer-events:none;}&:hover{border-color:var(--color-primary);color:var(--color-primary);text-decoration:none;}&:active{border-color:var(--color-primary);color:var(--color-primary);background-color:var(--color-primary-200);}"], function (props) {
|
|
2031
2034
|
return props.$isTargetable && styled.css(["", ""], {
|
|
2032
2035
|
"pointerEvents": "none"
|
|
2033
2036
|
});
|
|
@@ -3775,156 +3778,6 @@
|
|
|
3775
3778
|
});
|
|
3776
3779
|
RadioButton.displayName = "RadioButton";
|
|
3777
3780
|
|
|
3778
|
-
var StyledScrollShadow = styled__default["default"].div.withConfig({
|
|
3779
|
-
displayName: "Styles__StyledScrollShadow",
|
|
3780
|
-
componentId: "sc-17pcaqo-0"
|
|
3781
|
-
})(["", ""], {
|
|
3782
|
-
"position": "relative"
|
|
3783
|
-
});
|
|
3784
|
-
var StyledScrollShadowTop = styled__default["default"].div.withConfig({
|
|
3785
|
-
displayName: "Styles__StyledScrollShadowTop",
|
|
3786
|
-
componentId: "sc-17pcaqo-1"
|
|
3787
|
-
})(["", " background-image:linear-gradient( to top,var(--page-paper-main-shadow),var(--page-paper-main) );"], {
|
|
3788
|
-
"position": "absolute",
|
|
3789
|
-
"top": "0px",
|
|
3790
|
-
"left": "0px",
|
|
3791
|
-
"right": "0px",
|
|
3792
|
-
"height": "0.5rem"
|
|
3793
|
-
});
|
|
3794
|
-
var StyledScrollShadowBottom = styled__default["default"].div.withConfig({
|
|
3795
|
-
displayName: "Styles__StyledScrollShadowBottom",
|
|
3796
|
-
componentId: "sc-17pcaqo-2"
|
|
3797
|
-
})(["", " background-image:linear-gradient( to top,var(--page-paper-main),var(--page-paper-main-shadow) );"], {
|
|
3798
|
-
"position": "absolute",
|
|
3799
|
-
"bottom": "0px",
|
|
3800
|
-
"left": "0px",
|
|
3801
|
-
"right": "0px",
|
|
3802
|
-
"height": "0.5rem"
|
|
3803
|
-
});
|
|
3804
|
-
var StyledScrollShadowLeft = styled__default["default"].div.withConfig({
|
|
3805
|
-
displayName: "Styles__StyledScrollShadowLeft",
|
|
3806
|
-
componentId: "sc-17pcaqo-3"
|
|
3807
|
-
})(["", " background-image:linear-gradient( to left,var(--page-paper-main-shadow),var(--page-paper-main) );"], {
|
|
3808
|
-
"position": "absolute",
|
|
3809
|
-
"left": "0px",
|
|
3810
|
-
"top": "0px",
|
|
3811
|
-
"bottom": "0px",
|
|
3812
|
-
"width": "0.5rem"
|
|
3813
|
-
});
|
|
3814
|
-
var StyledScrollShadowRight = styled__default["default"].div.withConfig({
|
|
3815
|
-
displayName: "Styles__StyledScrollShadowRight",
|
|
3816
|
-
componentId: "sc-17pcaqo-4"
|
|
3817
|
-
})(["", " background-image:linear-gradient( to right,var(--page-paper-main-shadow),var(--page-paper-main) );"], {
|
|
3818
|
-
"position": "absolute",
|
|
3819
|
-
"right": "0px",
|
|
3820
|
-
"top": "0px",
|
|
3821
|
-
"bottom": "0px",
|
|
3822
|
-
"width": "0.5rem"
|
|
3823
|
-
});
|
|
3824
|
-
StyledScrollShadow.displayName = "StyledScrollShadow";
|
|
3825
|
-
StyledScrollShadowTop.displayName = "StyledScrollShadowTop";
|
|
3826
|
-
StyledScrollShadowBottom.displayName = "StyledScrollShadowBottom";
|
|
3827
|
-
StyledScrollShadowLeft.displayName = "StyledScrollShadowLeft";
|
|
3828
|
-
StyledScrollShadowRight.displayName = "StyledScrollShadowRight";
|
|
3829
|
-
|
|
3830
|
-
var _excluded$o = ["children", "className", "disableVertical", "disableHorizontal", "invertHorizontal", "invertVertical"];
|
|
3831
|
-
var ScrollShadow = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
3832
|
-
var children = _ref.children,
|
|
3833
|
-
className = _ref.className,
|
|
3834
|
-
_ref$disableVertical = _ref.disableVertical,
|
|
3835
|
-
disableVertical = _ref$disableVertical === void 0 ? false : _ref$disableVertical,
|
|
3836
|
-
_ref$disableHorizonta = _ref.disableHorizontal,
|
|
3837
|
-
disableHorizontal = _ref$disableHorizonta === void 0 ? false : _ref$disableHorizonta,
|
|
3838
|
-
_ref$invertHorizontal = _ref.invertHorizontal,
|
|
3839
|
-
invertHorizontal = _ref$invertHorizontal === void 0 ? false : _ref$invertHorizontal,
|
|
3840
|
-
_ref$invertVertical = _ref.invertVertical,
|
|
3841
|
-
invertVertical = _ref$invertVertical === void 0 ? false : _ref$invertVertical,
|
|
3842
|
-
rest = _objectWithoutProperties(_ref, _excluded$o);
|
|
3843
|
-
|
|
3844
|
-
var _useState = React.useState({
|
|
3845
|
-
top: 0,
|
|
3846
|
-
right: 0,
|
|
3847
|
-
bottom: 0,
|
|
3848
|
-
left: 0
|
|
3849
|
-
}),
|
|
3850
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
3851
|
-
opacity = _useState2[0],
|
|
3852
|
-
setOpacity = _useState2[1];
|
|
3853
|
-
|
|
3854
|
-
var handleScroll = React.useCallback(function (event) {
|
|
3855
|
-
var _ref2 = event.target,
|
|
3856
|
-
scrollHeight = _ref2.scrollHeight,
|
|
3857
|
-
clientHeight = _ref2.clientHeight,
|
|
3858
|
-
scrollWidth = _ref2.scrollWidth,
|
|
3859
|
-
clientWidth = _ref2.clientWidth;
|
|
3860
|
-
var _ref3 = event.target,
|
|
3861
|
-
scrollTop = _ref3.scrollTop,
|
|
3862
|
-
scrollLeft = _ref3.scrollLeft;
|
|
3863
|
-
|
|
3864
|
-
if (scrollLeft < 0) {
|
|
3865
|
-
scrollLeft *= -1;
|
|
3866
|
-
}
|
|
3867
|
-
|
|
3868
|
-
if (scrollTop < 0) {
|
|
3869
|
-
scrollTop *= -1;
|
|
3870
|
-
}
|
|
3871
|
-
|
|
3872
|
-
setOpacity(function (prevState) {
|
|
3873
|
-
var top = 1 / 20 * Math.min(scrollTop, 20);
|
|
3874
|
-
var bottomScrollTop = scrollHeight - clientHeight;
|
|
3875
|
-
var bottom = 1 / 20 * (bottomScrollTop - Math.max(scrollTop, bottomScrollTop - 20));
|
|
3876
|
-
var left = 1 / 20 * Math.min(scrollLeft, 20);
|
|
3877
|
-
var offset = scrollWidth - clientWidth;
|
|
3878
|
-
var right = 1 / 20 * (offset - Math.max(scrollLeft, offset - 20));
|
|
3879
|
-
var newState = {
|
|
3880
|
-
top: 0,
|
|
3881
|
-
bottom: 0,
|
|
3882
|
-
left: 0,
|
|
3883
|
-
right: 0
|
|
3884
|
-
};
|
|
3885
|
-
|
|
3886
|
-
if (!disableVertical) {
|
|
3887
|
-
newState.top = invertVertical ? bottom : top;
|
|
3888
|
-
newState.bottom = invertVertical ? top : bottom;
|
|
3889
|
-
}
|
|
3890
|
-
|
|
3891
|
-
if (!disableHorizontal) {
|
|
3892
|
-
newState.left = invertHorizontal ? right : left;
|
|
3893
|
-
newState.right = invertHorizontal ? left : right;
|
|
3894
|
-
}
|
|
3895
|
-
|
|
3896
|
-
if (newState.top !== prevState.top || newState.bottom !== prevState.bottom || newState.left !== prevState.left || newState.right !== prevState.right) {
|
|
3897
|
-
return newState;
|
|
3898
|
-
}
|
|
3899
|
-
|
|
3900
|
-
return prevState;
|
|
3901
|
-
});
|
|
3902
|
-
}, [invertHorizontal, invertVertical, disableVertical, disableHorizontal]);
|
|
3903
|
-
return /*#__PURE__*/React__default["default"].createElement(StyledScrollShadow, _extends({}, rest, {
|
|
3904
|
-
ref: ref,
|
|
3905
|
-
className: classnames__default["default"]("c-scroll-shadow", className)
|
|
3906
|
-
}), children({
|
|
3907
|
-
onScroll: handleScroll
|
|
3908
|
-
}), !disableVertical ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowTop, {
|
|
3909
|
-
style: {
|
|
3910
|
-
opacity: opacity.top
|
|
3911
|
-
}
|
|
3912
|
-
}), /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowBottom, {
|
|
3913
|
-
style: {
|
|
3914
|
-
opacity: opacity.bottom
|
|
3915
|
-
}
|
|
3916
|
-
})) : null, !disableHorizontal ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowLeft, {
|
|
3917
|
-
style: {
|
|
3918
|
-
opacity: opacity.left
|
|
3919
|
-
}
|
|
3920
|
-
}), /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowRight, {
|
|
3921
|
-
style: {
|
|
3922
|
-
opacity: opacity.right
|
|
3923
|
-
}
|
|
3924
|
-
})) : null);
|
|
3925
|
-
});
|
|
3926
|
-
ScrollShadow.displayName = "ScrollShadow";
|
|
3927
|
-
|
|
3928
3781
|
var StyledHiglightedText = styled__default["default"].span.withConfig({
|
|
3929
3782
|
displayName: "useHighlightText__StyledHiglightedText",
|
|
3930
3783
|
componentId: "sc-13agf6o-0"
|
|
@@ -4101,14 +3954,208 @@
|
|
|
4101
3954
|
};
|
|
4102
3955
|
OptionGroup.displayName = "OptionGroup";
|
|
4103
3956
|
|
|
3957
|
+
var StyledScrollShadow = styled__default["default"].div.withConfig({
|
|
3958
|
+
displayName: "Styles__StyledScrollShadow",
|
|
3959
|
+
componentId: "sc-17pcaqo-0"
|
|
3960
|
+
})(["", ""], {
|
|
3961
|
+
"position": "relative"
|
|
3962
|
+
});
|
|
3963
|
+
var StyledScrollShadowTop = styled__default["default"].div.withConfig({
|
|
3964
|
+
displayName: "Styles__StyledScrollShadowTop",
|
|
3965
|
+
componentId: "sc-17pcaqo-1"
|
|
3966
|
+
})(["", " background-image:linear-gradient( to top,var(--page-paper-main-shadow),var(--page-paper-main) );"], {
|
|
3967
|
+
"position": "absolute",
|
|
3968
|
+
"top": "0px",
|
|
3969
|
+
"left": "0px",
|
|
3970
|
+
"right": "0px",
|
|
3971
|
+
"height": "0.5rem"
|
|
3972
|
+
});
|
|
3973
|
+
var StyledScrollShadowBottom = styled__default["default"].div.withConfig({
|
|
3974
|
+
displayName: "Styles__StyledScrollShadowBottom",
|
|
3975
|
+
componentId: "sc-17pcaqo-2"
|
|
3976
|
+
})(["", " background-image:linear-gradient( to top,var(--page-paper-main),var(--page-paper-main-shadow) );"], {
|
|
3977
|
+
"position": "absolute",
|
|
3978
|
+
"bottom": "0px",
|
|
3979
|
+
"left": "0px",
|
|
3980
|
+
"right": "0px",
|
|
3981
|
+
"height": "0.5rem"
|
|
3982
|
+
});
|
|
3983
|
+
var StyledScrollShadowLeft = styled__default["default"].div.withConfig({
|
|
3984
|
+
displayName: "Styles__StyledScrollShadowLeft",
|
|
3985
|
+
componentId: "sc-17pcaqo-3"
|
|
3986
|
+
})(["", " background-image:linear-gradient( to left,var(--page-paper-main-shadow),var(--page-paper-main) );"], {
|
|
3987
|
+
"position": "absolute",
|
|
3988
|
+
"left": "0px",
|
|
3989
|
+
"top": "0px",
|
|
3990
|
+
"bottom": "0px",
|
|
3991
|
+
"width": "0.5rem"
|
|
3992
|
+
});
|
|
3993
|
+
var StyledScrollShadowRight = styled__default["default"].div.withConfig({
|
|
3994
|
+
displayName: "Styles__StyledScrollShadowRight",
|
|
3995
|
+
componentId: "sc-17pcaqo-4"
|
|
3996
|
+
})(["", " background-image:linear-gradient( to right,var(--page-paper-main-shadow),var(--page-paper-main) );"], {
|
|
3997
|
+
"position": "absolute",
|
|
3998
|
+
"right": "0px",
|
|
3999
|
+
"top": "0px",
|
|
4000
|
+
"bottom": "0px",
|
|
4001
|
+
"width": "0.5rem"
|
|
4002
|
+
});
|
|
4003
|
+
StyledScrollShadow.displayName = "StyledScrollShadow";
|
|
4004
|
+
StyledScrollShadowTop.displayName = "StyledScrollShadowTop";
|
|
4005
|
+
StyledScrollShadowBottom.displayName = "StyledScrollShadowBottom";
|
|
4006
|
+
StyledScrollShadowLeft.displayName = "StyledScrollShadowLeft";
|
|
4007
|
+
StyledScrollShadowRight.displayName = "StyledScrollShadowRight";
|
|
4008
|
+
|
|
4009
|
+
var _excluded$o = ["children", "className", "disableVertical", "disableHorizontal", "invertHorizontal", "invertVertical"];
|
|
4010
|
+
var ScrollShadow = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
4011
|
+
var children = _ref.children,
|
|
4012
|
+
className = _ref.className,
|
|
4013
|
+
_ref$disableVertical = _ref.disableVertical,
|
|
4014
|
+
disableVertical = _ref$disableVertical === void 0 ? false : _ref$disableVertical,
|
|
4015
|
+
_ref$disableHorizonta = _ref.disableHorizontal,
|
|
4016
|
+
disableHorizontal = _ref$disableHorizonta === void 0 ? false : _ref$disableHorizonta,
|
|
4017
|
+
_ref$invertHorizontal = _ref.invertHorizontal,
|
|
4018
|
+
invertHorizontal = _ref$invertHorizontal === void 0 ? false : _ref$invertHorizontal,
|
|
4019
|
+
_ref$invertVertical = _ref.invertVertical,
|
|
4020
|
+
invertVertical = _ref$invertVertical === void 0 ? false : _ref$invertVertical,
|
|
4021
|
+
rest = _objectWithoutProperties(_ref, _excluded$o);
|
|
4022
|
+
|
|
4023
|
+
var _useState = React.useState({
|
|
4024
|
+
top: 0,
|
|
4025
|
+
right: 0,
|
|
4026
|
+
bottom: 0,
|
|
4027
|
+
left: 0
|
|
4028
|
+
}),
|
|
4029
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
4030
|
+
opacity = _useState2[0],
|
|
4031
|
+
setOpacity = _useState2[1];
|
|
4032
|
+
|
|
4033
|
+
var handleScroll = React.useCallback(function (event) {
|
|
4034
|
+
var _ref2 = event.target,
|
|
4035
|
+
scrollHeight = _ref2.scrollHeight,
|
|
4036
|
+
clientHeight = _ref2.clientHeight,
|
|
4037
|
+
scrollWidth = _ref2.scrollWidth,
|
|
4038
|
+
clientWidth = _ref2.clientWidth;
|
|
4039
|
+
var _ref3 = event.target,
|
|
4040
|
+
scrollTop = _ref3.scrollTop,
|
|
4041
|
+
scrollLeft = _ref3.scrollLeft;
|
|
4042
|
+
|
|
4043
|
+
if (scrollLeft < 0) {
|
|
4044
|
+
scrollLeft *= -1;
|
|
4045
|
+
}
|
|
4046
|
+
|
|
4047
|
+
if (scrollTop < 0) {
|
|
4048
|
+
scrollTop *= -1;
|
|
4049
|
+
}
|
|
4050
|
+
|
|
4051
|
+
setOpacity(function (prevState) {
|
|
4052
|
+
var top = 1 / 20 * Math.min(scrollTop, 20);
|
|
4053
|
+
var bottomScrollTop = scrollHeight - clientHeight;
|
|
4054
|
+
var bottom = 1 / 20 * (bottomScrollTop - Math.max(scrollTop, bottomScrollTop - 20));
|
|
4055
|
+
var left = 1 / 20 * Math.min(scrollLeft, 20);
|
|
4056
|
+
var offset = scrollWidth - clientWidth;
|
|
4057
|
+
var right = 1 / 20 * (offset - Math.max(scrollLeft, offset - 20));
|
|
4058
|
+
var newState = {
|
|
4059
|
+
top: 0,
|
|
4060
|
+
bottom: 0,
|
|
4061
|
+
left: 0,
|
|
4062
|
+
right: 0
|
|
4063
|
+
};
|
|
4064
|
+
|
|
4065
|
+
if (!disableVertical) {
|
|
4066
|
+
newState.top = invertVertical ? bottom : top;
|
|
4067
|
+
newState.bottom = invertVertical ? top : bottom;
|
|
4068
|
+
}
|
|
4069
|
+
|
|
4070
|
+
if (!disableHorizontal) {
|
|
4071
|
+
newState.left = invertHorizontal ? right : left;
|
|
4072
|
+
newState.right = invertHorizontal ? left : right;
|
|
4073
|
+
}
|
|
4074
|
+
|
|
4075
|
+
if (newState.top !== prevState.top || newState.bottom !== prevState.bottom || newState.left !== prevState.left || newState.right !== prevState.right) {
|
|
4076
|
+
return newState;
|
|
4077
|
+
}
|
|
4078
|
+
|
|
4079
|
+
return prevState;
|
|
4080
|
+
});
|
|
4081
|
+
}, [invertHorizontal, invertVertical, disableVertical, disableHorizontal]);
|
|
4082
|
+
return /*#__PURE__*/React__default["default"].createElement(StyledScrollShadow, _extends({}, rest, {
|
|
4083
|
+
ref: ref,
|
|
4084
|
+
className: classnames__default["default"]("c-scroll-shadow", className)
|
|
4085
|
+
}), children({
|
|
4086
|
+
onScroll: handleScroll
|
|
4087
|
+
}), !disableVertical ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowTop, {
|
|
4088
|
+
style: {
|
|
4089
|
+
opacity: opacity.top
|
|
4090
|
+
}
|
|
4091
|
+
}), /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowBottom, {
|
|
4092
|
+
style: {
|
|
4093
|
+
opacity: opacity.bottom
|
|
4094
|
+
}
|
|
4095
|
+
})) : null, !disableHorizontal ? /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowLeft, {
|
|
4096
|
+
style: {
|
|
4097
|
+
opacity: opacity.left
|
|
4098
|
+
}
|
|
4099
|
+
}), /*#__PURE__*/React__default["default"].createElement(StyledScrollShadowRight, {
|
|
4100
|
+
style: {
|
|
4101
|
+
opacity: opacity.right
|
|
4102
|
+
}
|
|
4103
|
+
})) : null);
|
|
4104
|
+
});
|
|
4105
|
+
ScrollShadow.displayName = "ScrollShadow";
|
|
4106
|
+
|
|
4107
|
+
var useInitScrollRef = function useInitScrollRef(element) {
|
|
4108
|
+
var invert = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
4109
|
+
var ref = React.useRef(element);
|
|
4110
|
+
React.useEffect(function () {
|
|
4111
|
+
if (ref.current) {
|
|
4112
|
+
ref.current.scrollTop = invert ? -1 : 1;
|
|
4113
|
+
ref.current.scrollTop = 0;
|
|
4114
|
+
ref.current.scrollLeft = invert ? -1 : 1;
|
|
4115
|
+
ref.current.scrollLeft = 0;
|
|
4116
|
+
}
|
|
4117
|
+
}, [invert]);
|
|
4118
|
+
return ref;
|
|
4119
|
+
};
|
|
4120
|
+
|
|
4121
|
+
var _excluded$n = ["as", "className", "invert"];
|
|
4122
|
+
var ScrollElement = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
4123
|
+
var _ref$as = _ref.as,
|
|
4124
|
+
as = _ref$as === void 0 ? "div" : _ref$as,
|
|
4125
|
+
className = _ref.className,
|
|
4126
|
+
_ref$invert = _ref.invert,
|
|
4127
|
+
invert = _ref$invert === void 0 ? false : _ref$invert,
|
|
4128
|
+
rest = _objectWithoutProperties(_ref, _excluded$n);
|
|
4129
|
+
|
|
4130
|
+
var internalRef = useInitScrollRef(null, invert);
|
|
4131
|
+
var handleRef = useForkRef(internalRef, ref);
|
|
4132
|
+
|
|
4133
|
+
var props = _objectSpread2(_objectSpread2({}, rest), {}, {
|
|
4134
|
+
ref: handleRef,
|
|
4135
|
+
className: classnames__default["default"]("c-scroll-element tw-overflow-auto", className)
|
|
4136
|
+
});
|
|
4137
|
+
|
|
4138
|
+
return /*#__PURE__*/React__default["default"].createElement(as, props);
|
|
4139
|
+
});
|
|
4140
|
+
ScrollElement.displayName = "ScrollElement";
|
|
4141
|
+
|
|
4142
|
+
var StyledAutocompleteScrollShadow = styled__default["default"](ScrollShadow).withConfig({
|
|
4143
|
+
displayName: "Styles__StyledAutocompleteScrollShadow",
|
|
4144
|
+
componentId: "sc-1bc1vz9-0"
|
|
4145
|
+
})(["margin-top:4px;", ""], function (props) {
|
|
4146
|
+
return props.$isHidden && styled.css(["", ";"], {
|
|
4147
|
+
"display": "none"
|
|
4148
|
+
});
|
|
4149
|
+
});
|
|
4150
|
+
StyledAutocompleteScrollShadow.displayName = "StyledAutocompleteScrollShadow";
|
|
4104
4151
|
var StyledAutocompleteBody = styled__default["default"].div.withConfig({
|
|
4105
4152
|
displayName: "Styles__StyledAutocompleteBody",
|
|
4106
|
-
componentId: "sc-1bc1vz9-
|
|
4153
|
+
componentId: "sc-1bc1vz9-1"
|
|
4107
4154
|
})(["max-height:340px;overflow:auto;margin-bottom:6px;"]);
|
|
4108
4155
|
StyledAutocompleteBody.displayName = "StyledAutocompleteBody";
|
|
4109
4156
|
var StyledAutocompleteNoResult = styled__default["default"].div.withConfig({
|
|
4110
4157
|
displayName: "Styles__StyledAutocompleteNoResult",
|
|
4111
|
-
componentId: "sc-1bc1vz9-
|
|
4158
|
+
componentId: "sc-1bc1vz9-2"
|
|
4112
4159
|
})(["", ";padding:6px 16px;margin:4px 0;&:hover{background-color:var(--color-theme-200);}color:var(--color-theme-600);"], {
|
|
4113
4160
|
"cursor": "pointer",
|
|
4114
4161
|
"userSelect": "none"
|
|
@@ -4116,7 +4163,7 @@
|
|
|
4116
4163
|
StyledAutocompleteNoResult.displayName = "StyledAutocompleteNoResult";
|
|
4117
4164
|
var StyledAutocompleteNewItem = styled__default["default"].label.withConfig({
|
|
4118
4165
|
displayName: "Styles__StyledAutocompleteNewItem",
|
|
4119
|
-
componentId: "sc-1bc1vz9-
|
|
4166
|
+
componentId: "sc-1bc1vz9-3"
|
|
4120
4167
|
})(["", ";padding:6px 16px;margin:4px 0;font-weight:normal;color:var(--color-primary);&:before{content:\"+ \";}", ""], {
|
|
4121
4168
|
"cursor": "pointer",
|
|
4122
4169
|
"userSelect": "none"
|
|
@@ -4457,10 +4504,9 @@
|
|
|
4457
4504
|
var renderNoResult = React.useMemo(function () {
|
|
4458
4505
|
return /*#__PURE__*/React__default["default"].createElement(StyledAutocompleteNoResult, null, noResultText);
|
|
4459
4506
|
}, [noResultText]);
|
|
4460
|
-
return /*#__PURE__*/React__default["default"].createElement(
|
|
4461
|
-
className:
|
|
4462
|
-
|
|
4463
|
-
}, AutocompleteClassName)
|
|
4507
|
+
return /*#__PURE__*/React__default["default"].createElement(StyledAutocompleteScrollShadow, {
|
|
4508
|
+
className: AutocompleteClassName,
|
|
4509
|
+
$isHidden: !defaultValue && !emptyValue && !noResultText && list.length < 1
|
|
4464
4510
|
}, function (_ref2) {
|
|
4465
4511
|
var onScroll = _ref2.onScroll;
|
|
4466
4512
|
return /*#__PURE__*/React__default["default"].createElement(StyledAutocompleteBody, {
|
|
@@ -4513,7 +4559,7 @@
|
|
|
4513
4559
|
});
|
|
4514
4560
|
StyledInput.displayName = "StyledInput";
|
|
4515
4561
|
|
|
4516
|
-
var _excluded$
|
|
4562
|
+
var _excluded$m = ["className", "type", "disabled"];
|
|
4517
4563
|
var Input = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
4518
4564
|
var _ref$className = _ref.className,
|
|
4519
4565
|
className = _ref$className === void 0 ? "" : _ref$className,
|
|
@@ -4521,7 +4567,7 @@
|
|
|
4521
4567
|
type = _ref$type === void 0 ? "text" : _ref$type,
|
|
4522
4568
|
_ref$disabled = _ref.disabled,
|
|
4523
4569
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
4524
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
4570
|
+
rest = _objectWithoutProperties(_ref, _excluded$m);
|
|
4525
4571
|
|
|
4526
4572
|
return /*#__PURE__*/React__default["default"].createElement(StyledInput, _extends({
|
|
4527
4573
|
ref: ref,
|
|
@@ -4580,7 +4626,7 @@
|
|
|
4580
4626
|
};
|
|
4581
4627
|
OptionContent.displayName = "OptionContent";
|
|
4582
4628
|
|
|
4583
|
-
var _excluded$
|
|
4629
|
+
var _excluded$l = ["type", "mode", "target", "options", "selected", "position", "onChange", "actionIcon", "actionLabel", "placeholder", "emptyAction", "disableSearch", "forceCloseMenu", "selectClassName", "keepSameOptionsOrder", "onSelectOpen", "onSelectClose"];
|
|
4584
4630
|
var Select = function Select(_ref) {
|
|
4585
4631
|
var _ref$type = _ref.type,
|
|
4586
4632
|
type = _ref$type === void 0 ? "single" : _ref$type,
|
|
@@ -4610,7 +4656,7 @@
|
|
|
4610
4656
|
keepSameOptionsOrder = _ref$keepSameOptionsO === void 0 ? false : _ref$keepSameOptionsO,
|
|
4611
4657
|
onSelectOpen = _ref.onSelectOpen,
|
|
4612
4658
|
onSelectClose = _ref.onSelectClose,
|
|
4613
|
-
prop = _objectWithoutProperties(_ref, _excluded$
|
|
4659
|
+
prop = _objectWithoutProperties(_ref, _excluded$l);
|
|
4614
4660
|
|
|
4615
4661
|
var _useState = React.useState(),
|
|
4616
4662
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -4885,7 +4931,7 @@
|
|
|
4885
4931
|
});
|
|
4886
4932
|
StyledNavAsMoreTarget.displayName = "StyledNavAsMoreTarget";
|
|
4887
4933
|
|
|
4888
|
-
var _excluded$
|
|
4934
|
+
var _excluded$k = ["children", "active", "disabled", "className", "role"];
|
|
4889
4935
|
var Item = /*#__PURE__*/React__default["default"].forwardRef(function (_ref, ref) {
|
|
4890
4936
|
var children = _ref.children,
|
|
4891
4937
|
_ref$active = _ref.active,
|
|
@@ -4894,7 +4940,7 @@
|
|
|
4894
4940
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
4895
4941
|
className = _ref.className,
|
|
4896
4942
|
role = _ref.role,
|
|
4897
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
4943
|
+
rest = _objectWithoutProperties(_ref, _excluded$k);
|
|
4898
4944
|
|
|
4899
4945
|
return /*#__PURE__*/React__default["default"].createElement(StyledNavListItem, _extends({
|
|
4900
4946
|
className: classnames__default["default"]("c-nav__item", {
|
|
@@ -4936,11 +4982,11 @@
|
|
|
4936
4982
|
});
|
|
4937
4983
|
StyledExpandSingle.displayName = "StyledExpandSingle";
|
|
4938
4984
|
|
|
4939
|
-
var _excluded$
|
|
4985
|
+
var _excluded$j = ["expanded"];
|
|
4940
4986
|
var ExpandSingle = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
4941
4987
|
var _ref$expanded = _ref.expanded,
|
|
4942
4988
|
expanded = _ref$expanded === void 0 ? false : _ref$expanded,
|
|
4943
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
4989
|
+
rest = _objectWithoutProperties(_ref, _excluded$j);
|
|
4944
4990
|
|
|
4945
4991
|
return /*#__PURE__*/React__default["default"].createElement(StyledExpandSingle, _extends({
|
|
4946
4992
|
ref: ref,
|
|
@@ -5253,11 +5299,11 @@
|
|
|
5253
5299
|
};
|
|
5254
5300
|
Nav.displayName = "Nav";
|
|
5255
5301
|
|
|
5256
|
-
var _excluded$
|
|
5302
|
+
var _excluded$i = ["expanded"];
|
|
5257
5303
|
var ExpandAll = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
5258
5304
|
var _ref$expanded = _ref.expanded,
|
|
5259
5305
|
expanded = _ref$expanded === void 0 ? false : _ref$expanded,
|
|
5260
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
5306
|
+
rest = _objectWithoutProperties(_ref, _excluded$i);
|
|
5261
5307
|
|
|
5262
5308
|
return /*#__PURE__*/React__default["default"].createElement(StyledExpand, _extends({
|
|
5263
5309
|
ref: ref,
|
|
@@ -5302,11 +5348,11 @@
|
|
|
5302
5348
|
})(["border-top:1px solid var(--border-primary);margin:12px 16px;height:1px;"]);
|
|
5303
5349
|
StyledListSeparator.displayName = "StyledListSeparator";
|
|
5304
5350
|
|
|
5305
|
-
var _excluded$
|
|
5351
|
+
var _excluded$h = ["children", "className"];
|
|
5306
5352
|
var List = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
5307
5353
|
var children = _ref.children,
|
|
5308
5354
|
className = _ref.className,
|
|
5309
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
5355
|
+
props = _objectWithoutProperties(_ref, _excluded$h);
|
|
5310
5356
|
|
|
5311
5357
|
return /*#__PURE__*/React__default["default"].createElement(StyledList, _extends({}, props, {
|
|
5312
5358
|
className: className,
|
|
@@ -5315,11 +5361,11 @@
|
|
|
5315
5361
|
});
|
|
5316
5362
|
List.displayName = "List";
|
|
5317
5363
|
|
|
5318
|
-
var _excluded$
|
|
5364
|
+
var _excluded$g = ["children", "className"];
|
|
5319
5365
|
var ListItem = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
5320
5366
|
var children = _ref.children,
|
|
5321
5367
|
className = _ref.className,
|
|
5322
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
5368
|
+
props = _objectWithoutProperties(_ref, _excluded$g);
|
|
5323
5369
|
|
|
5324
5370
|
return /*#__PURE__*/React__default["default"].createElement(StyledListItem, _extends({}, props, {
|
|
5325
5371
|
className: classnames__default["default"]("c-list-item", className),
|
|
@@ -5529,41 +5575,6 @@
|
|
|
5529
5575
|
};
|
|
5530
5576
|
MultiAvatar.displayName = "MultiAvatar";
|
|
5531
5577
|
|
|
5532
|
-
var useInitScrollRef = function useInitScrollRef(element) {
|
|
5533
|
-
var invert = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
5534
|
-
var ref = React.useRef(element);
|
|
5535
|
-
React.useEffect(function () {
|
|
5536
|
-
if (ref.current) {
|
|
5537
|
-
ref.current.scrollTop = invert ? -1 : 1;
|
|
5538
|
-
ref.current.scrollTop = 0;
|
|
5539
|
-
ref.current.scrollLeft = invert ? -1 : 1;
|
|
5540
|
-
ref.current.scrollLeft = 0;
|
|
5541
|
-
}
|
|
5542
|
-
}, [invert]);
|
|
5543
|
-
return ref;
|
|
5544
|
-
};
|
|
5545
|
-
|
|
5546
|
-
var _excluded$g = ["as", "className", "invert"];
|
|
5547
|
-
var ScrollElement = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
5548
|
-
var _ref$as = _ref.as,
|
|
5549
|
-
as = _ref$as === void 0 ? "div" : _ref$as,
|
|
5550
|
-
className = _ref.className,
|
|
5551
|
-
_ref$invert = _ref.invert,
|
|
5552
|
-
invert = _ref$invert === void 0 ? false : _ref$invert,
|
|
5553
|
-
rest = _objectWithoutProperties(_ref, _excluded$g);
|
|
5554
|
-
|
|
5555
|
-
var internalRef = useInitScrollRef(null, invert);
|
|
5556
|
-
var handleRef = useForkRef(internalRef, ref);
|
|
5557
|
-
|
|
5558
|
-
var props = _objectSpread2(_objectSpread2({}, rest), {}, {
|
|
5559
|
-
ref: handleRef,
|
|
5560
|
-
className: classnames__default["default"]("c-scroll-element tw-overflow-auto", className)
|
|
5561
|
-
});
|
|
5562
|
-
|
|
5563
|
-
return /*#__PURE__*/React__default["default"].createElement(as, props);
|
|
5564
|
-
});
|
|
5565
|
-
ScrollElement.displayName = "ScrollElement";
|
|
5566
|
-
|
|
5567
5578
|
var ActivityIcon = /*#__PURE__*/React__default["default"].forwardRef(function (props, svgRef) {
|
|
5568
5579
|
return /*#__PURE__*/React__default["default"].createElement("svg", _extends({
|
|
5569
5580
|
width: 24,
|
|
@@ -8355,10 +8366,10 @@
|
|
|
8355
8366
|
componentId: "sc-1jkx994-2"
|
|
8356
8367
|
})([".modal-header{padding:16px 30px;h1{margin:0;font-size:16px;}}.modal-body{padding:10px 30px;}.modal-divider{border-top:1px solid var(--border-primary);height:1px;}.modal-footer{padding:16px 30px;}"]);
|
|
8357
8368
|
StyledConfirmDialog.displayName = "StyledConfirmDialog";
|
|
8358
|
-
var StyledSelectDateDatePicker = styled__default["default"]
|
|
8369
|
+
var StyledSelectDateDatePicker = styled__default["default"].div.withConfig({
|
|
8359
8370
|
displayName: "Styles__StyledSelectDateDatePicker",
|
|
8360
8371
|
componentId: "sc-1jkx994-3"
|
|
8361
|
-
})(["", ""], {
|
|
8372
|
+
})(["", " color:red;"], {
|
|
8362
8373
|
"paddingTop": "1rem",
|
|
8363
8374
|
"paddingBottom": "0.5rem"
|
|
8364
8375
|
});
|
|
@@ -8449,7 +8460,7 @@
|
|
|
8449
8460
|
onKeyDown: handleOnKeyDown,
|
|
8450
8461
|
tabIndex: -1,
|
|
8451
8462
|
className: "date-picker-form"
|
|
8452
|
-
}, /*#__PURE__*/React__default["default"].createElement(StyledSelectDateDatePicker, {
|
|
8463
|
+
}, /*#__PURE__*/React__default["default"].createElement(StyledSelectDateDatePicker, null, /*#__PURE__*/React__default["default"].createElement(DatePicker, {
|
|
8453
8464
|
month: month,
|
|
8454
8465
|
onMonthChange: onMonthChange,
|
|
8455
8466
|
onChange: onChange,
|
|
@@ -8461,7 +8472,7 @@
|
|
|
8461
8472
|
modifiers: modifiers,
|
|
8462
8473
|
renderDay: renderDay,
|
|
8463
8474
|
localeUtils: MomentLocaleUtils__default["default"]
|
|
8464
|
-
}), mode === "atomic" || !dateRequired ? /*#__PURE__*/React__default["default"].createElement(StyledSelectDateFooter, {
|
|
8475
|
+
})), mode === "atomic" || !dateRequired ? /*#__PURE__*/React__default["default"].createElement(StyledSelectDateFooter, {
|
|
8465
8476
|
className: "date-picker-footer",
|
|
8466
8477
|
$mode: mode
|
|
8467
8478
|
}, mode === "atomic" ? /*#__PURE__*/React__default["default"].createElement(StyledSelectDateButtons, {
|