@mw-kit/mw-ui 1.7.41 → 1.7.42
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.
|
@@ -9,7 +9,7 @@ export interface StyledButtonProps extends React.ButtonHTMLAttributes<HTMLButton
|
|
|
9
9
|
/**
|
|
10
10
|
* Specifies if the button style is solid, bordered or text only.
|
|
11
11
|
*/
|
|
12
|
-
appearance: 'solid' | 'bordered' | 'link' | '
|
|
12
|
+
appearance: 'solid' | 'bordered' | 'link' | 'borderless';
|
|
13
13
|
/**
|
|
14
14
|
* Define the color of button.
|
|
15
15
|
*/
|
|
@@ -8,10 +8,14 @@ export interface DateIntervalPickerProps extends React.HTMLAttributes<HTMLInputE
|
|
|
8
8
|
value: Value;
|
|
9
9
|
setValue: (value: Value) => void;
|
|
10
10
|
getLabel?: (value: Value) => string;
|
|
11
|
+
center?: {
|
|
12
|
+
x: number;
|
|
13
|
+
y: number;
|
|
14
|
+
};
|
|
11
15
|
max?: Date;
|
|
12
16
|
min?: Date;
|
|
13
17
|
only?: IntervalType;
|
|
14
|
-
calendar?: Omit<AbsoluteIntervalCalendarProps, 'initialValue' | 'onSubmit' | 'invalid' | 'open'>;
|
|
18
|
+
calendar?: Omit<AbsoluteIntervalCalendarProps, 'initialValue' | 'onSubmit' | 'invalid' | 'open' | 'center'>;
|
|
15
19
|
}
|
|
16
20
|
export interface Variation {
|
|
17
21
|
label: (prev: [Date, Date]) => string;
|
package/dist/index.js
CHANGED
|
@@ -13698,7 +13698,7 @@ var Button = styled__default.button(_templateObject$e || (_templateObject$e = _t
|
|
|
13698
13698
|
var appearance = _ref4.appearance,
|
|
13699
13699
|
color = _ref4.color,
|
|
13700
13700
|
theme = _ref4.theme;
|
|
13701
|
-
var bgColor = ['bordered', 'link', '
|
|
13701
|
+
var bgColor = ['bordered', 'link', 'borderless'].includes(appearance) ? 'transparent' : theme.getColor(color || 'blue');
|
|
13702
13702
|
var borderColor = appearance !== 'bordered' ? bgColor : theme.getColor(color || 'blue');
|
|
13703
13703
|
return styled.css(_templateObject3$b || (_templateObject3$b = _taggedTemplateLiteralLoose(["\n background-color: ", ";\n border: 1px solid ", ";\n "])), bgColor, borderColor);
|
|
13704
13704
|
}, function (_ref5) {
|
|
@@ -13708,7 +13708,7 @@ var Button = styled__default.button(_templateObject$e || (_templateObject$e = _t
|
|
|
13708
13708
|
theme = _ref5.theme;
|
|
13709
13709
|
if (loading) return 'transparent';
|
|
13710
13710
|
|
|
13711
|
-
if (['link', '
|
|
13711
|
+
if (['link', 'borderless'].includes(appearance)) {
|
|
13712
13712
|
return color ? theme.colors[color] : theme.getColor('greyishBlue', 50);
|
|
13713
13713
|
}
|
|
13714
13714
|
|
|
@@ -13722,7 +13722,7 @@ var Button = styled__default.button(_templateObject$e || (_templateObject$e = _t
|
|
|
13722
13722
|
loading = _ref6.loading,
|
|
13723
13723
|
theme = _ref6.theme;
|
|
13724
13724
|
|
|
13725
|
-
if (['bordered', 'link', '
|
|
13725
|
+
if (['bordered', 'link', 'borderless'].includes(appearance)) {
|
|
13726
13726
|
return styled.css(_templateObject4$9 || (_templateObject4$9 = _taggedTemplateLiteralLoose(["\n opacity: 0.3;\n pointer-events: none;\n "])));
|
|
13727
13727
|
}
|
|
13728
13728
|
|
|
@@ -13738,7 +13738,7 @@ var Button = styled__default.button(_templateObject$e || (_templateObject$e = _t
|
|
|
13738
13738
|
|
|
13739
13739
|
if (appearance === 'bordered') {
|
|
13740
13740
|
return styled.css(_templateObject6$7 || (_templateObject6$7 = _taggedTemplateLiteralLoose(["\n color: ", ";\n border: 1px solid ", ";\n "])), theme.getColor(color || 'blue', 70), theme.getColor(color || 'blue', 70));
|
|
13741
|
-
} else if (['link', '
|
|
13741
|
+
} else if (['link', 'borderless'].includes(appearance)) {
|
|
13742
13742
|
return styled.css(_templateObject7$7 || (_templateObject7$7 = _taggedTemplateLiteralLoose(["\n color: ", ";\n "])), theme.colors.blue);
|
|
13743
13743
|
}
|
|
13744
13744
|
|
|
@@ -13752,7 +13752,7 @@ var Button = styled__default.button(_templateObject$e || (_templateObject$e = _t
|
|
|
13752
13752
|
return styled.css(_templateObject9$6 || (_templateObject9$6 = _taggedTemplateLiteralLoose(["\n background-color: ", ";\n "])), theme.getColor('iceWhite'));
|
|
13753
13753
|
}
|
|
13754
13754
|
|
|
13755
|
-
if (['link', '
|
|
13755
|
+
if (['link', 'borderless'].includes(appearance)) {
|
|
13756
13756
|
return styled.css(_templateObject10$5 || (_templateObject10$5 = _taggedTemplateLiteralLoose(["\n color: ", ";\n "])), theme.getColor('blue', 50));
|
|
13757
13757
|
}
|
|
13758
13758
|
|
|
@@ -16166,6 +16166,10 @@ var LabelText$1 = styled__default.label(_templateObject11$5 || (_templateObject1
|
|
|
16166
16166
|
});
|
|
16167
16167
|
|
|
16168
16168
|
var Component$1 = React__default.forwardRef(function (props, ref) {
|
|
16169
|
+
var center = props.center || {
|
|
16170
|
+
x: 50,
|
|
16171
|
+
y: 50
|
|
16172
|
+
};
|
|
16169
16173
|
var value = parse(props.value);
|
|
16170
16174
|
|
|
16171
16175
|
var _useState = React.useState(null),
|
|
@@ -16319,6 +16323,10 @@ var Component$1 = React__default.forwardRef(function (props, ref) {
|
|
|
16319
16323
|
close: function close() {
|
|
16320
16324
|
return setOpen(null);
|
|
16321
16325
|
},
|
|
16326
|
+
center: center,
|
|
16327
|
+
references: {
|
|
16328
|
+
bottom: '35px'
|
|
16329
|
+
},
|
|
16322
16330
|
options: [{
|
|
16323
16331
|
label: 'Hoje',
|
|
16324
16332
|
onClick: function onClick() {
|
|
@@ -16350,6 +16358,7 @@ var Component$1 = React__default.forwardRef(function (props, ref) {
|
|
|
16350
16358
|
itemSpacing: 's3',
|
|
16351
16359
|
bordered: true
|
|
16352
16360
|
}), React__default.createElement(Calendar, Object.assign({}, props.calendar || {}, {
|
|
16361
|
+
center: center,
|
|
16353
16362
|
type: 'interval',
|
|
16354
16363
|
absolute: true,
|
|
16355
16364
|
open: open === 'calendar',
|
|
@@ -18053,7 +18062,7 @@ var ConfirmDelete = function ConfirmDelete(props) {
|
|
|
18053
18062
|
color: 'greyishBlue',
|
|
18054
18063
|
inverted: true,
|
|
18055
18064
|
footer: [{
|
|
18056
|
-
appearance: '
|
|
18065
|
+
appearance: 'borderless',
|
|
18057
18066
|
content: 'Cancelar',
|
|
18058
18067
|
onClick: cancelAction
|
|
18059
18068
|
}, {
|
|
@@ -18131,7 +18140,7 @@ var Audit = function Audit(props) {
|
|
|
18131
18140
|
color: 'greyishBlue',
|
|
18132
18141
|
inverted: true,
|
|
18133
18142
|
footer: [{
|
|
18134
|
-
appearance: '
|
|
18143
|
+
appearance: 'borderless',
|
|
18135
18144
|
content: 'Cancelar',
|
|
18136
18145
|
onClick: cancelAction
|
|
18137
18146
|
}, {
|