@driveflux/beam 3.0.0 → 3.0.2
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/alert/Alert.js +13 -1
- package/dist/badge/Badge.js +1 -0
- package/dist/toast/ToastBox.js +18 -9
- package/package.json +1 -1
package/dist/alert/Alert.js
CHANGED
|
@@ -89,6 +89,11 @@ var AlertIcon = /*#__PURE__*/ React.forwardRef(function(_param, ref) {
|
|
|
89
89
|
"className",
|
|
90
90
|
"variant"
|
|
91
91
|
]);
|
|
92
|
+
if (!variant) {
|
|
93
|
+
return /*#__PURE__*/ _jsx(IconInfo, _object_spread({
|
|
94
|
+
ref: ref
|
|
95
|
+
}, props));
|
|
96
|
+
}
|
|
92
97
|
switch(variant){
|
|
93
98
|
case 'error':
|
|
94
99
|
return /*#__PURE__*/ _jsx(IconInfo, _object_spread({
|
|
@@ -102,10 +107,17 @@ var AlertIcon = /*#__PURE__*/ React.forwardRef(function(_param, ref) {
|
|
|
102
107
|
variant: 'filled',
|
|
103
108
|
className: cn('text-warning4', className)
|
|
104
109
|
}, props));
|
|
105
|
-
default:
|
|
110
|
+
case 'default':
|
|
106
111
|
return /*#__PURE__*/ _jsx(IconInfo, _object_spread({
|
|
107
112
|
ref: ref
|
|
108
113
|
}, props));
|
|
114
|
+
default:
|
|
115
|
+
{
|
|
116
|
+
var _exhaustiveCheck = variant;
|
|
117
|
+
return /*#__PURE__*/ _jsx(IconInfo, _object_spread({
|
|
118
|
+
ref: ref
|
|
119
|
+
}, props));
|
|
120
|
+
}
|
|
109
121
|
}
|
|
110
122
|
});
|
|
111
123
|
AlertIcon.displayName = 'AlertIcon';
|
package/dist/badge/Badge.js
CHANGED
package/dist/toast/ToastBox.js
CHANGED
|
@@ -66,6 +66,18 @@ var splitText = function(text, isNumbered) {
|
|
|
66
66
|
});
|
|
67
67
|
};
|
|
68
68
|
var getStyles = function(status) {
|
|
69
|
+
var defaultStyles = {
|
|
70
|
+
icon: /*#__PURE__*/ _jsx(IconInfo, {
|
|
71
|
+
size: '24px'
|
|
72
|
+
}),
|
|
73
|
+
bgColor: 'bg-info-50',
|
|
74
|
+
titleColor: 'text-info-300',
|
|
75
|
+
textColor: 'text-info-600',
|
|
76
|
+
borderColor: 'border-info-300'
|
|
77
|
+
};
|
|
78
|
+
if (!status) {
|
|
79
|
+
return defaultStyles;
|
|
80
|
+
}
|
|
69
81
|
switch(status){
|
|
70
82
|
case 'error':
|
|
71
83
|
return {
|
|
@@ -98,16 +110,13 @@ var getStyles = function(status) {
|
|
|
98
110
|
textColor: 'text-warning-600',
|
|
99
111
|
borderColor: 'border-warning-300'
|
|
100
112
|
};
|
|
113
|
+
case 'info':
|
|
114
|
+
return defaultStyles;
|
|
101
115
|
default:
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
bgColor: 'bg-info-50',
|
|
107
|
-
titleColor: 'text-info-300',
|
|
108
|
-
textColor: 'text-info-600',
|
|
109
|
-
borderColor: 'border-info-300'
|
|
110
|
-
};
|
|
116
|
+
{
|
|
117
|
+
var _exhaustiveCheck = status;
|
|
118
|
+
return defaultStyles;
|
|
119
|
+
}
|
|
111
120
|
}
|
|
112
121
|
};
|
|
113
122
|
export default ToastBox;
|