@happeouikit/banners
Advanced tools
Comparing version 1.1.5 to 1.1.6
# Changelog | ||
## 1.0.6 | ||
- Fix white background | ||
## 1.0.0 | ||
@@ -4,0 +8,0 @@ |
@@ -5,4 +5,6 @@ import React from "react"; | ||
import { TextZeta, BodyUI } from "@happeouikit/typography"; | ||
import { active, success, warn, alert, gray04 } from "@happeouikit/colors"; | ||
import { active, success, warn, alert, gray04, white } from "@happeouikit/colors"; | ||
import { IconError, IconInfoRound, IconCheckCircle } from "@happeouikit/icons"; | ||
import { jsx as _jsx } from "react/jsx-runtime"; | ||
import { jsxs as _jsxs } from "react/jsx-runtime"; | ||
export var BannerStateMap = { | ||
@@ -16,12 +18,12 @@ info: active, | ||
info: function info() { | ||
return React.createElement(IconInfoRound, null); | ||
return /*#__PURE__*/_jsx(IconInfoRound, {}); | ||
}, | ||
success: function success() { | ||
return React.createElement(IconCheckCircle, null); | ||
return /*#__PURE__*/_jsx(IconCheckCircle, {}); | ||
}, | ||
warn: function warn() { | ||
return React.createElement(IconError, null); | ||
return /*#__PURE__*/_jsx(IconError, {}); | ||
}, | ||
error: function error() { | ||
return React.createElement(IconError, null); | ||
return /*#__PURE__*/_jsx(IconError, {}); | ||
} | ||
@@ -37,20 +39,30 @@ }; | ||
rightAction = _ref.rightAction; | ||
return React.createElement(Container, { | ||
color: BannerStateMap[state] | ||
}, React.createElement(IconWrapper, { | ||
hasDescription: !!description, | ||
fill: BannerStateMap[state] | ||
}, icon || IconMap[state]()), React.createElement(Content, null, React.createElement(StackedContent, null, title && React.createElement(TextZeta, { | ||
bold: true | ||
}, title), description && React.createElement(BodyUI, { | ||
color: gray04, | ||
style: { | ||
paddingTop: "4px" | ||
} | ||
}, description), action && React.createElement(ActionWrapper, { | ||
"data-test-id": "banner-bottom-action-wrapper" | ||
}, action)), rightAction && React.createElement(RightActionWrapper, { | ||
hasDescription: !!description, | ||
"data-test-id": "banner-right-action-wrapper" | ||
}, rightAction))); | ||
return /*#__PURE__*/_jsxs(Container, { | ||
color: BannerStateMap[state], | ||
children: [/*#__PURE__*/_jsx(IconWrapper, { | ||
hasDescription: !!description, | ||
fill: BannerStateMap[state], | ||
children: icon || IconMap[state]() | ||
}), /*#__PURE__*/_jsxs(Content, { | ||
children: [/*#__PURE__*/_jsxs(StackedContent, { | ||
children: [title && /*#__PURE__*/_jsx(TextZeta, { | ||
bold: true, | ||
children: title | ||
}), description && /*#__PURE__*/_jsx(BodyUI, { | ||
color: gray04, | ||
style: { | ||
paddingTop: "4px" | ||
}, | ||
children: description | ||
}), action && /*#__PURE__*/_jsx(ActionWrapper, { | ||
"data-test-id": "banner-bottom-action-wrapper", | ||
children: action | ||
})] | ||
}), rightAction && /*#__PURE__*/_jsx(RightActionWrapper, { | ||
hasDescription: !!description, | ||
"data-test-id": "banner-right-action-wrapper", | ||
children: rightAction | ||
})] | ||
})] | ||
}); | ||
}; | ||
@@ -61,3 +73,3 @@ | ||
componentId: "sc-1puten-0" | ||
})(["display:flex;border-radius:6px;min-width:285px;padding:16px 40px 16px 16px;position:relative;box-shadow:0px 1px 4px rgba(186,198,208,0.5),0px 1px 4px rgba(0,157,255,0.05);:after{content:\"\";position:absolute;width:8px;left:0px;top:0;bottom:0;background:", ";border-top-left-radius:6px;border-bottom-left-radius:6px;}"], function (_ref2) { | ||
})(["display:flex;border-radius:6px;min-width:285px;padding:16px 40px 16px 16px;position:relative;box-shadow:0px 1px 4px rgba(186,198,208,0.5),0px 1px 4px rgba(0,157,255,0.05);background-color:", ";:after{content:\"\";position:absolute;width:8px;left:0px;top:0;bottom:0;background:", ";border-top-left-radius:6px;border-bottom-left-radius:6px;}"], white, function (_ref2) { | ||
var color = _ref2.color; | ||
@@ -64,0 +76,0 @@ return color; |
{ | ||
"name": "@happeouikit/banners", | ||
"version": "1.1.5", | ||
"version": "1.1.6", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6440
115
1