@elliemae/ds-banner 2.0.0-alpha.5 → 2.0.0-alpha.6
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/cjs/DSBanner.js +6 -6
- package/cjs/index.js +1 -1
- package/cjs/styles.js +7 -7
- package/cjs/utils/icons.js +4 -4
- package/package.json +3 -3
package/cjs/DSBanner.js
CHANGED
|
@@ -23,7 +23,7 @@ var _CloseX;
|
|
|
23
23
|
|
|
24
24
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
25
25
|
|
|
26
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default[
|
|
26
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
27
27
|
|
|
28
28
|
const DSBanner = ({
|
|
29
29
|
type,
|
|
@@ -70,9 +70,9 @@ const DSBanner = ({
|
|
|
70
70
|
isAnimating: isAnimating,
|
|
71
71
|
"data-testid": "ds-banner",
|
|
72
72
|
role: "alert",
|
|
73
|
-
children: [/*#__PURE__*/_jsx__default[
|
|
73
|
+
children: [/*#__PURE__*/_jsx__default["default"](styles.StyledIconContainer, {
|
|
74
74
|
"data-testid": "ds-banner-icon"
|
|
75
|
-
}, void 0, icons.icons[type]), /*#__PURE__*/_jsx__default[
|
|
75
|
+
}, void 0, icons.icons[type]), /*#__PURE__*/_jsx__default["default"](styles.StyledTitle, {}, void 0, label), /*#__PURE__*/_jsx__default["default"](styles.StyledSubTitle, {}, void 0, /*#__PURE__*/_jsx__default["default"]("span", {}, void 0, body), actionLink && /*#__PURE__*/jsxRuntime.jsx(styles.StyledActionLink, {
|
|
76
76
|
"data-testid": "ds-banner-action-link",
|
|
77
77
|
onClick: actionLink.onClick,
|
|
78
78
|
href: actionLink.href,
|
|
@@ -81,12 +81,12 @@ const DSBanner = ({
|
|
|
81
81
|
tabIndex: 0,
|
|
82
82
|
isBodyEmpty: body,
|
|
83
83
|
children: actionLink.label
|
|
84
|
-
})), showCloseButton && /*#__PURE__*/_jsx__default[
|
|
84
|
+
})), showCloseButton && /*#__PURE__*/_jsx__default["default"](styles.StyledCloseButton, {
|
|
85
85
|
"data-testid": "ds-banner-close-button",
|
|
86
86
|
buttonType: "secondary",
|
|
87
87
|
onClick: onClose,
|
|
88
88
|
"aria-label": "Close icon",
|
|
89
|
-
icon: _CloseX || (_CloseX = /*#__PURE__*/_jsx__default[
|
|
89
|
+
icon: _CloseX || (_CloseX = /*#__PURE__*/_jsx__default["default"](CloseX__default["default"], {
|
|
90
90
|
width: "12px",
|
|
91
91
|
height: "12px"
|
|
92
92
|
}))
|
|
@@ -100,4 +100,4 @@ const DSBannerWithSchema = reactDesc.describe(DSBanner);
|
|
|
100
100
|
DSBannerWithSchema.propTypes = propTypes.propTypes;
|
|
101
101
|
|
|
102
102
|
exports.DSBannerWithSchema = DSBannerWithSchema;
|
|
103
|
-
exports[
|
|
103
|
+
exports["default"] = DSBanner;
|
package/cjs/index.js
CHANGED
package/cjs/styles.js
CHANGED
|
@@ -11,7 +11,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
11
11
|
var styled__default = /*#__PURE__*/_interopDefaultLegacy(styled);
|
|
12
12
|
var DSButton__default = /*#__PURE__*/_interopDefaultLegacy(DSButton);
|
|
13
13
|
|
|
14
|
-
const StyledBannerContainer = /*#__PURE__*/styled__default[
|
|
14
|
+
const StyledBannerContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
15
15
|
componentId: "sc-ffu2hq-0"
|
|
16
16
|
})(["overflow:hidden;height:", ";", ";"], ({
|
|
17
17
|
isOpen
|
|
@@ -20,7 +20,7 @@ const StyledBannerContainer = /*#__PURE__*/styled__default['default'].div.withCo
|
|
|
20
20
|
isOpen,
|
|
21
21
|
height
|
|
22
22
|
}) => styleHelpers.handleAnimation(isAnimating, isOpen, height));
|
|
23
|
-
const StyledInnerContainer = /*#__PURE__*/styled__default[
|
|
23
|
+
const StyledInnerContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
24
24
|
componentId: "sc-ffu2hq-1"
|
|
25
25
|
})(["padding-right:6px;display:flex;align-items:center;min-height:41px;width:100%;background-color:", ";border-bottom:5px solid ", ";", ";"], ({
|
|
26
26
|
theme
|
|
@@ -31,14 +31,14 @@ const StyledInnerContainer = /*#__PURE__*/styled__default['default'].div.withCon
|
|
|
31
31
|
isAnimating,
|
|
32
32
|
isOpen
|
|
33
33
|
}) => styleHelpers.handleAnimation(isAnimating, isOpen));
|
|
34
|
-
const StyledIconContainer = /*#__PURE__*/styled__default[
|
|
34
|
+
const StyledIconContainer = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
35
35
|
componentId: "sc-ffu2hq-2"
|
|
36
36
|
})(["margin-right:", ";margin-left:", ";"], ({
|
|
37
37
|
theme
|
|
38
38
|
}) => theme.space.xxs, ({
|
|
39
39
|
theme
|
|
40
40
|
}) => theme.space.xs);
|
|
41
|
-
const StyledTitle = /*#__PURE__*/styled__default[
|
|
41
|
+
const StyledTitle = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
42
42
|
componentId: "sc-ffu2hq-3"
|
|
43
43
|
})(["color:", ";font-size:", ";font-weight:", ";white-space:nowrap;"], ({
|
|
44
44
|
theme
|
|
@@ -47,7 +47,7 @@ const StyledTitle = /*#__PURE__*/styled__default['default'].div.withConfig({
|
|
|
47
47
|
}) => theme.fontSizes.label[400], ({
|
|
48
48
|
theme
|
|
49
49
|
}) => theme.fontWeights.semibold);
|
|
50
|
-
const StyledSubTitle = /*#__PURE__*/styled__default[
|
|
50
|
+
const StyledSubTitle = /*#__PURE__*/styled__default["default"].div.withConfig({
|
|
51
51
|
componentId: "sc-ffu2hq-4"
|
|
52
52
|
})(["width:100%;margin-left:", ";font-size:", ";font-weight:", ";"], ({
|
|
53
53
|
theme
|
|
@@ -56,7 +56,7 @@ const StyledSubTitle = /*#__PURE__*/styled__default['default'].div.withConfig({
|
|
|
56
56
|
}) => theme.fontSizes.subTitle[400], ({
|
|
57
57
|
theme
|
|
58
58
|
}) => theme.fontWeights.regular);
|
|
59
|
-
const StyledActionLink = /*#__PURE__*/styled__default[
|
|
59
|
+
const StyledActionLink = /*#__PURE__*/styled__default["default"].a.withConfig({
|
|
60
60
|
componentId: "sc-ffu2hq-5"
|
|
61
61
|
})(["margin-left:", ";white-space:nowrap;text-decoration:none;line-height:1.1;font-size:", ";font-weight:", ";color:", ";"], ({
|
|
62
62
|
theme,
|
|
@@ -68,7 +68,7 @@ const StyledActionLink = /*#__PURE__*/styled__default['default'].a.withConfig({
|
|
|
68
68
|
}) => theme.fontWeights.regular, ({
|
|
69
69
|
theme
|
|
70
70
|
}) => theme.colors.brand[600]);
|
|
71
|
-
const StyledCloseButton = /*#__PURE__*/styled__default[
|
|
71
|
+
const StyledCloseButton = /*#__PURE__*/styled__default["default"](DSButton__default["default"]).withConfig({
|
|
72
72
|
componentId: "sc-ffu2hq-6"
|
|
73
73
|
})(["margin-left:", ";&:not(focus){border:transparent;}"], ({
|
|
74
74
|
theme
|
package/cjs/utils/icons.js
CHANGED
|
@@ -18,22 +18,22 @@ var AlertsDetailFill__default = /*#__PURE__*/_interopDefaultLegacy(AlertsDetailF
|
|
|
18
18
|
var WarningSquare__default = /*#__PURE__*/_interopDefaultLegacy(WarningSquare);
|
|
19
19
|
|
|
20
20
|
const icons = {
|
|
21
|
-
success: /*#__PURE__*/_jsx__default[
|
|
21
|
+
success: /*#__PURE__*/_jsx__default["default"](SuccessFill__default["default"], {
|
|
22
22
|
fill: "#207e56",
|
|
23
23
|
width: "20px",
|
|
24
24
|
height: "20px"
|
|
25
25
|
}),
|
|
26
|
-
info: /*#__PURE__*/_jsx__default[
|
|
26
|
+
info: /*#__PURE__*/_jsx__default["default"](InfoFill__default["default"], {
|
|
27
27
|
fill: "#1e79c2",
|
|
28
28
|
width: "20px",
|
|
29
29
|
height: "20px"
|
|
30
30
|
}),
|
|
31
|
-
danger: /*#__PURE__*/_jsx__default[
|
|
31
|
+
danger: /*#__PURE__*/_jsx__default["default"](AlertsDetailFill__default["default"], {
|
|
32
32
|
fill: "#c64252",
|
|
33
33
|
width: "20px",
|
|
34
34
|
height: "20px"
|
|
35
35
|
}),
|
|
36
|
-
warning: /*#__PURE__*/_jsx__default[
|
|
36
|
+
warning: /*#__PURE__*/_jsx__default["default"](WarningSquare__default["default"], {
|
|
37
37
|
fill: "#d17a00",
|
|
38
38
|
width: "20px",
|
|
39
39
|
height: "20px"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-banner",
|
|
3
|
-
"version": "2.0.0-alpha.
|
|
3
|
+
"version": "2.0.0-alpha.6",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Banner",
|
|
6
6
|
"module": "./esm/index.js",
|
|
@@ -60,8 +60,8 @@
|
|
|
60
60
|
"build": "node ../../scripts/build/build.js"
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
|
-
"@elliemae/ds-basic": "2.0.0-alpha.
|
|
64
|
-
"@elliemae/ds-classnames": "2.0.0-alpha.
|
|
63
|
+
"@elliemae/ds-basic": "2.0.0-alpha.6",
|
|
64
|
+
"@elliemae/ds-classnames": "2.0.0-alpha.6"
|
|
65
65
|
},
|
|
66
66
|
"devDependencies": {
|
|
67
67
|
"styled-components": "~5.3.1"
|