beem-component 1.6.7 → 1.7.0
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/components/ChatComponents/ChatBody/chatBody.js +7 -2
- package/dist/components/ChatComponents/ChatBody/sessionTimeline.js +44 -0
- package/dist/components/Modals/modal.js +1 -1
- package/dist/components/Tags/tags.js +10 -5
- package/dist/components/Tags/tags.stories.js +7 -1
- package/package.json +4 -3
- package/src/App.js +86 -2
- package/src/lib/components/ChatComponents/ChatBody/chatBody.js +5 -0
- package/src/lib/components/ChatComponents/ChatBody/sessionTimeline.js +29 -0
- package/src/lib/components/Modals/modal.js +1 -1
- package/src/lib/components/Tags/tags.js +13 -3
- package/src/lib/components/Tags/tags.stories.js +14 -1
|
@@ -21,11 +21,13 @@ var _iconStyles = require("../../iconStyles");
|
|
|
21
21
|
|
|
22
22
|
var _sessionDetails = require("./sessionDetails");
|
|
23
23
|
|
|
24
|
+
var _sessionTimeline = require("./sessionTimeline");
|
|
25
|
+
|
|
24
26
|
var _colors = require("../../colors");
|
|
25
27
|
|
|
26
28
|
var _excluded = ["state", "file", "src", "fileName", "onDownload", "link"],
|
|
27
29
|
_excluded2 = ["state", "src", "fileName"],
|
|
28
|
-
_excluded3 = ["children", "state", "displayTime", "status", "session", "src", "file", "fileName", "sessionDetails"];
|
|
30
|
+
_excluded3 = ["children", "state", "displayTime", "status", "session", "src", "file", "fileName", "sessionDetails", "sessionTimeline"];
|
|
29
31
|
|
|
30
32
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11;
|
|
31
33
|
|
|
@@ -247,9 +249,12 @@ BmChat.Details = function (_ref14) {
|
|
|
247
249
|
file = _ref14.file,
|
|
248
250
|
fileName = _ref14.fileName,
|
|
249
251
|
sessionDetails = _ref14.sessionDetails,
|
|
252
|
+
sessionTimeline = _ref14.sessionTimeline,
|
|
250
253
|
rest = _objectWithoutProperties(_ref14, _excluded3);
|
|
251
254
|
|
|
252
|
-
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null,
|
|
255
|
+
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, sessionTimeline && /*#__PURE__*/_react.default.createElement(_sessionTimeline.SessionTimeline, _extends({
|
|
256
|
+
message: sessionTimeline.message
|
|
257
|
+
}, rest)), sessionDetails && /*#__PURE__*/_react.default.createElement(_sessionDetails.SessionDetails, _extends({
|
|
253
258
|
time: sessionDetails.time,
|
|
254
259
|
message: sessionDetails.message
|
|
255
260
|
}, rest)), /*#__PURE__*/_react.default.createElement(Details, _extends({
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.SessionTimeline = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
11
|
+
|
|
12
|
+
var _colors = require("../../colors");
|
|
13
|
+
|
|
14
|
+
var _excluded = ["message", "time"];
|
|
15
|
+
|
|
16
|
+
var _templateObject, _templateObject2;
|
|
17
|
+
|
|
18
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
|
+
|
|
20
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
21
|
+
|
|
22
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
23
|
+
|
|
24
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
25
|
+
|
|
26
|
+
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
27
|
+
|
|
28
|
+
var SessionTimelineWrapper = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n text-align: center;\n"])));
|
|
29
|
+
|
|
30
|
+
var container = _styledComponents.default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n border-radius: 0.714rem 0.714rem 0.714rem 0.714rem;\n border: 0.071rem solid ", ";\n padding: 0.5rem;\n background-color: ", ";\n"])), _colors.BmBgGreyBlue, _colors.BmSecondaryBlue12);
|
|
31
|
+
|
|
32
|
+
SessionTimelineWrapper.Container = container;
|
|
33
|
+
|
|
34
|
+
var SessionTimeline = function SessionTimeline(_ref) {
|
|
35
|
+
var message = _ref.message,
|
|
36
|
+
time = _ref.time,
|
|
37
|
+
rest = _objectWithoutProperties(_ref, _excluded);
|
|
38
|
+
|
|
39
|
+
return /*#__PURE__*/_react.default.createElement(SessionTimelineWrapper, _extends({
|
|
40
|
+
message: message
|
|
41
|
+
}, rest), /*#__PURE__*/_react.default.createElement(SessionTimelineWrapper.Container, null, message || /*#__PURE__*/_react.default.createElement("p", null, "\xA0")));
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
exports.SessionTimeline = SessionTimeline;
|
|
@@ -149,7 +149,7 @@ BmModal.Footer = _styledComponents.default.div(_templateObject7 || (_templateObj
|
|
|
149
149
|
BmModal.propTypes = {
|
|
150
150
|
size: _propTypes.default.string,
|
|
151
151
|
centered: _propTypes.default.bool,
|
|
152
|
-
show: _propTypes.default.bool
|
|
152
|
+
show: _propTypes.default.bool,
|
|
153
153
|
onHide: _propTypes.default.func.isRequired,
|
|
154
154
|
closeButton: _propTypes.default.bool
|
|
155
155
|
};
|
|
@@ -19,7 +19,7 @@ var _iconStyles = require("../iconStyles");
|
|
|
19
19
|
|
|
20
20
|
var _colors = require("../colors");
|
|
21
21
|
|
|
22
|
-
var _excluded = ["variant", "size", "disabled", "children", "leadingIcon", "trailingIcon", "color", "closeButton", "onHide"];
|
|
22
|
+
var _excluded = ["variant", "size", "disabled", "children", "leadingIcon", "trailingIcon", "color", "bgColor", "closeButton", "onHide"];
|
|
23
23
|
|
|
24
24
|
var _templateObject;
|
|
25
25
|
|
|
@@ -53,7 +53,7 @@ var Color = function Color(_ref) {
|
|
|
53
53
|
var variant = _ref.variant,
|
|
54
54
|
color = _ref.color;
|
|
55
55
|
|
|
56
|
-
if (variant === 'success' || variant === 'warning' || variant === 'danger') {
|
|
56
|
+
if (variant === 'success' || variant === 'warning' || variant === 'danger' || variant === 'primary') {
|
|
57
57
|
return "".concat(_colors.BmPrimaryWhite);
|
|
58
58
|
}
|
|
59
59
|
|
|
@@ -76,13 +76,16 @@ var BeemTag = _styledComponents.default.button(_templateObject || (_templateObje
|
|
|
76
76
|
|
|
77
77
|
return show ? 'flex' : 'none';
|
|
78
78
|
}, function (_ref3) {
|
|
79
|
-
var variant = _ref3.variant
|
|
79
|
+
var variant = _ref3.variant,
|
|
80
|
+
bgColor = _ref3.bgColor;
|
|
81
|
+
if (bgColor && !variant) return bgColor;
|
|
80
82
|
if (variant === 'neutral') return "".concat(_colors.BmGrey100);
|
|
81
83
|
if (variant === 'success') return "".concat(_colors.BmSecondaryDarkGreen);
|
|
82
84
|
if (variant === 'warning') return "".concat(_colors.BmPrimaryGold);
|
|
83
85
|
if (variant === 'danger') return "".concat(_colors.BmSecondaryRed);
|
|
84
86
|
if (variant === 'light') return "".concat(_colors.BmPrimaryWhite);
|
|
85
|
-
if (
|
|
87
|
+
if (variant === 'primary') return "".concat(_colors.BmPrimaryBlue);
|
|
88
|
+
if (!variant && !bgColor) return "".concat(_colors.BmGrey100);
|
|
86
89
|
}, function (_ref4) {
|
|
87
90
|
var variant = _ref4.variant;
|
|
88
91
|
if (variant === 'neutral') return "".concat(_colors.BmGrey100);
|
|
@@ -113,6 +116,7 @@ var BmTag = function BmTag(props) {
|
|
|
113
116
|
leadingIcon = props.leadingIcon,
|
|
114
117
|
trailingIcon = props.trailingIcon,
|
|
115
118
|
color = props.color,
|
|
119
|
+
bgColor = props.bgColor,
|
|
116
120
|
closeButton = props.closeButton,
|
|
117
121
|
onHide = props.onHide,
|
|
118
122
|
rest = _objectWithoutProperties(props, _excluded);
|
|
@@ -124,7 +128,8 @@ var BmTag = function BmTag(props) {
|
|
|
124
128
|
children: children,
|
|
125
129
|
color: color,
|
|
126
130
|
closeButton: closeButton,
|
|
127
|
-
show: toggle
|
|
131
|
+
show: toggle,
|
|
132
|
+
bgColor: bgColor
|
|
128
133
|
}, rest), leadingIcon && /*#__PURE__*/_react.default.createElement(_iconStyles.BmIcons, {
|
|
129
134
|
disabled: disabled,
|
|
130
135
|
icon: leadingIcon,
|
|
@@ -24,6 +24,12 @@ var _default = {
|
|
|
24
24
|
},
|
|
25
25
|
description: 'Color of the Icons and Text, will work only if variant is not present'
|
|
26
26
|
},
|
|
27
|
+
bgColor: {
|
|
28
|
+
control: {
|
|
29
|
+
type: 'text'
|
|
30
|
+
},
|
|
31
|
+
description: 'Background Color of Tags, will work only if variant is not present'
|
|
32
|
+
},
|
|
27
33
|
closeButton: {
|
|
28
34
|
control: {
|
|
29
35
|
type: 'boolean'
|
|
@@ -44,7 +50,7 @@ var _default = {
|
|
|
44
50
|
}
|
|
45
51
|
},
|
|
46
52
|
variant: {
|
|
47
|
-
options: ['success', 'warning', 'danger', 'light', 'neutral', undefined],
|
|
53
|
+
options: ['success', 'warning', 'danger', 'light', 'neutral', 'primary', undefined],
|
|
48
54
|
control: {
|
|
49
55
|
type: 'select'
|
|
50
56
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "beem-component",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"main": "dist/components/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -52,9 +52,10 @@
|
|
|
52
52
|
},
|
|
53
53
|
"devDependencies": {
|
|
54
54
|
"@babel/cli": "^7.16.0",
|
|
55
|
-
"@babel/core": "^7.
|
|
55
|
+
"@babel/core": "^7.17.8",
|
|
56
|
+
"@babel/eslint-parser": "^7.18.2",
|
|
56
57
|
"@babel/preset-env": "^7.14.8",
|
|
57
|
-
"@babel/preset-react": "^7.
|
|
58
|
+
"@babel/preset-react": "^7.18.6",
|
|
58
59
|
"@commitlint/cli": "^14.1.0",
|
|
59
60
|
"@commitlint/config-conventional": "^14.1.0",
|
|
60
61
|
"@commitlint/travis-cli": "^14.1.0",
|
package/src/App.js
CHANGED
|
@@ -1,8 +1,92 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
import AttachFileIcon from '@mui/icons-material/AttachFile';
|
|
4
|
+
import EmojiEmotionsIcon from '@mui/icons-material/EmojiEmotions';
|
|
5
|
+
import SendIcon from '@mui/icons-material/Send';
|
|
6
|
+
import QuickreplyIcon from '@mui/icons-material/Quickreply';
|
|
7
|
+
import { BmChat, BmInput, BmIcons, GlobalStyle } from './lib/components';
|
|
3
8
|
|
|
4
9
|
const Chat = () => {
|
|
5
|
-
|
|
10
|
+
const image =
|
|
11
|
+
'https://bm-chatbot-images.s3.eu-west-1.amazonaws.com/1225211.jpg?AWSAccessKeyId=AKIAVCAYXA54EPKHSRGL&Expires=1734873821&Signature=ySZ23PaUxUeUVA4lCZCE1RZIrnc%3D';
|
|
12
|
+
return (
|
|
13
|
+
<>
|
|
14
|
+
<GlobalStyle />
|
|
15
|
+
<BmChat>
|
|
16
|
+
<BmChat.Body>
|
|
17
|
+
<BmChat.Details
|
|
18
|
+
state="inbound"
|
|
19
|
+
session="sms"
|
|
20
|
+
displayTime={<p>12:00pm</p>}
|
|
21
|
+
status="sent"
|
|
22
|
+
sessionTimeline={{
|
|
23
|
+
message: <p>2022-07-28</p>,
|
|
24
|
+
// time: <p>12:00pm</p>,
|
|
25
|
+
}}
|
|
26
|
+
>
|
|
27
|
+
<p>Inbound Text Message</p>
|
|
28
|
+
</BmChat.Details>
|
|
29
|
+
<BmChat.Details
|
|
30
|
+
state="inbound"
|
|
31
|
+
session="live"
|
|
32
|
+
displayTime={<p>12:00pm</p>}
|
|
33
|
+
status="sent"
|
|
34
|
+
fileName={<p>chat.png</p>}
|
|
35
|
+
src={image}
|
|
36
|
+
sessionDetails={{
|
|
37
|
+
message: <h3>Session Message</h3>,
|
|
38
|
+
time: <p>12:00pm</p>,
|
|
39
|
+
}}
|
|
40
|
+
/>
|
|
41
|
+
<BmChat.Details
|
|
42
|
+
state="inbound"
|
|
43
|
+
session="live"
|
|
44
|
+
displayTime={<p>10:00am</p>}
|
|
45
|
+
status="failed"
|
|
46
|
+
fileName={<p>file.csv</p>}
|
|
47
|
+
file={image}
|
|
48
|
+
/>
|
|
49
|
+
<BmChat.Details
|
|
50
|
+
state="outbound"
|
|
51
|
+
session="bot"
|
|
52
|
+
displayTime={<p>12:00pm</p>}
|
|
53
|
+
status="sent"
|
|
54
|
+
>
|
|
55
|
+
<p>Outbound Text Message</p>
|
|
56
|
+
</BmChat.Details>
|
|
57
|
+
<BmChat.Details
|
|
58
|
+
state="outbound"
|
|
59
|
+
session="live"
|
|
60
|
+
displayTime={<p>12:00pm</p>}
|
|
61
|
+
status="sent"
|
|
62
|
+
fileName={<p>chat.png</p>}
|
|
63
|
+
src={image}
|
|
64
|
+
/>
|
|
65
|
+
<BmChat.Details
|
|
66
|
+
state="outbound"
|
|
67
|
+
session="live"
|
|
68
|
+
displayTime={<p>10:00am</p>}
|
|
69
|
+
status="failed"
|
|
70
|
+
fileName={<p>file.csv</p>}
|
|
71
|
+
file={image}
|
|
72
|
+
link={image}
|
|
73
|
+
onDownload={() => {
|
|
74
|
+
alert('hello');
|
|
75
|
+
}}
|
|
76
|
+
/>
|
|
77
|
+
</BmChat.Body>
|
|
78
|
+
<BmChat.Footer>
|
|
79
|
+
<div className="chat-footer">
|
|
80
|
+
<BmIcons icon={<EmojiEmotionsIcon />} size="xlarge" />
|
|
81
|
+
<BmIcons icon={<AttachFileIcon />} size="xlarge" />
|
|
82
|
+
<BmIcons icon={<QuickreplyIcon />} size="xlarge" />
|
|
83
|
+
<BmInput placeholder="Enter Message" style={{ flex: '1' }} />
|
|
84
|
+
<BmIcons icon={<SendIcon />} size="xlarge" />
|
|
85
|
+
</div>
|
|
86
|
+
</BmChat.Footer>
|
|
87
|
+
</BmChat>
|
|
88
|
+
</>
|
|
89
|
+
);
|
|
6
90
|
};
|
|
7
91
|
|
|
8
92
|
export default Chat;
|
|
@@ -7,6 +7,7 @@ import styled from 'styled-components';
|
|
|
7
7
|
import BmAvatar from '../../Avatars/avatars';
|
|
8
8
|
import { BmIcons } from '../../iconStyles';
|
|
9
9
|
import { SessionDetails } from './sessionDetails';
|
|
10
|
+
import { SessionTimeline } from './sessionTimeline';
|
|
10
11
|
import {
|
|
11
12
|
BmPrimaryWhite,
|
|
12
13
|
BmPrimaryBlue,
|
|
@@ -250,10 +251,14 @@ BmChat.Details = ({
|
|
|
250
251
|
file,
|
|
251
252
|
fileName,
|
|
252
253
|
sessionDetails,
|
|
254
|
+
sessionTimeline,
|
|
253
255
|
...rest
|
|
254
256
|
}) => {
|
|
255
257
|
return (
|
|
256
258
|
<>
|
|
259
|
+
{sessionTimeline && (
|
|
260
|
+
<SessionTimeline message={sessionTimeline.message} {...rest} />
|
|
261
|
+
)}
|
|
257
262
|
{sessionDetails && (
|
|
258
263
|
<SessionDetails
|
|
259
264
|
time={sessionDetails.time}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import styled from 'styled-components';
|
|
3
|
+
import { BmSecondaryBlue12, BmBgGreyBlue } from '../../colors';
|
|
4
|
+
|
|
5
|
+
const SessionTimelineWrapper = styled.div`
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: row;
|
|
8
|
+
justify-content: center;
|
|
9
|
+
align-items: center;
|
|
10
|
+
text-align: center;
|
|
11
|
+
`;
|
|
12
|
+
|
|
13
|
+
const container = styled.div`
|
|
14
|
+
border-radius: 0.714rem 0.714rem 0.714rem 0.714rem;
|
|
15
|
+
border: 0.071rem solid ${BmBgGreyBlue};
|
|
16
|
+
padding: 0.5rem;
|
|
17
|
+
background-color: ${BmSecondaryBlue12};
|
|
18
|
+
`;
|
|
19
|
+
SessionTimelineWrapper.Container = container;
|
|
20
|
+
|
|
21
|
+
export const SessionTimeline = ({ message, time, ...rest }) => {
|
|
22
|
+
return (
|
|
23
|
+
<SessionTimelineWrapper message={message} {...rest}>
|
|
24
|
+
<SessionTimelineWrapper.Container>
|
|
25
|
+
{message || <p> </p>}
|
|
26
|
+
</SessionTimelineWrapper.Container>
|
|
27
|
+
</SessionTimelineWrapper>
|
|
28
|
+
);
|
|
29
|
+
};
|
|
@@ -164,7 +164,7 @@ BmModal.Footer = styled.div`
|
|
|
164
164
|
BmModal.propTypes = {
|
|
165
165
|
size: PropTypes.string,
|
|
166
166
|
centered: PropTypes.bool,
|
|
167
|
-
show: PropTypes.bool
|
|
167
|
+
show: PropTypes.bool,
|
|
168
168
|
onHide: PropTypes.func.isRequired,
|
|
169
169
|
closeButton: PropTypes.bool,
|
|
170
170
|
};
|
|
@@ -13,10 +13,16 @@ import {
|
|
|
13
13
|
BmGrey100,
|
|
14
14
|
BmGrey400,
|
|
15
15
|
BmPrimaryGold,
|
|
16
|
+
BmPrimaryBlue,
|
|
16
17
|
} from '../colors';
|
|
17
18
|
|
|
18
19
|
const Color = ({ variant, color }) => {
|
|
19
|
-
if (
|
|
20
|
+
if (
|
|
21
|
+
variant === 'success' ||
|
|
22
|
+
variant === 'warning' ||
|
|
23
|
+
variant === 'danger' ||
|
|
24
|
+
variant === 'primary'
|
|
25
|
+
) {
|
|
20
26
|
return `${BmPrimaryWhite}`;
|
|
21
27
|
}
|
|
22
28
|
if (!variant && color) {
|
|
@@ -38,13 +44,15 @@ const BeemTag = styled.button`
|
|
|
38
44
|
align-items: center;
|
|
39
45
|
padding: 0.25rem 0.5rem;
|
|
40
46
|
border-radius: 0.25rem;
|
|
41
|
-
background: ${({ variant }) => {
|
|
47
|
+
background: ${({ variant, bgColor }) => {
|
|
48
|
+
if (bgColor && !variant) return bgColor;
|
|
42
49
|
if (variant === 'neutral') return `${BmGrey100}`;
|
|
43
50
|
if (variant === 'success') return `${BmSecondaryDarkGreen}`;
|
|
44
51
|
if (variant === 'warning') return `${BmPrimaryGold}`;
|
|
45
52
|
if (variant === 'danger') return `${BmSecondaryRed}`;
|
|
46
53
|
if (variant === 'light') return `${BmPrimaryWhite}`;
|
|
47
|
-
if (
|
|
54
|
+
if (variant === 'primary') return `${BmPrimaryBlue}`;
|
|
55
|
+
if (!variant && !bgColor) return `${BmGrey100}`;
|
|
48
56
|
}};
|
|
49
57
|
border: 0.071rem solid
|
|
50
58
|
${({ variant }) => {
|
|
@@ -76,6 +84,7 @@ export const BmTag = (props) => {
|
|
|
76
84
|
leadingIcon,
|
|
77
85
|
trailingIcon,
|
|
78
86
|
color,
|
|
87
|
+
bgColor,
|
|
79
88
|
closeButton,
|
|
80
89
|
onHide,
|
|
81
90
|
...rest
|
|
@@ -90,6 +99,7 @@ export const BmTag = (props) => {
|
|
|
90
99
|
color={color}
|
|
91
100
|
closeButton={closeButton}
|
|
92
101
|
show={toggle}
|
|
102
|
+
bgColor={bgColor}
|
|
93
103
|
{...rest}
|
|
94
104
|
>
|
|
95
105
|
{leadingIcon && (
|
|
@@ -12,6 +12,11 @@ export default {
|
|
|
12
12
|
description:
|
|
13
13
|
'Color of the Icons and Text, will work only if variant is not present',
|
|
14
14
|
},
|
|
15
|
+
bgColor: {
|
|
16
|
+
control: { type: 'text' },
|
|
17
|
+
description:
|
|
18
|
+
'Background Color of Tags, will work only if variant is not present',
|
|
19
|
+
},
|
|
15
20
|
closeButton: {
|
|
16
21
|
control: { type: 'boolean' },
|
|
17
22
|
description: 'Will display (x) - Optional',
|
|
@@ -27,7 +32,15 @@ export default {
|
|
|
27
32
|
defaultValue: { summary: 'small' },
|
|
28
33
|
},
|
|
29
34
|
variant: {
|
|
30
|
-
options: [
|
|
35
|
+
options: [
|
|
36
|
+
'success',
|
|
37
|
+
'warning',
|
|
38
|
+
'danger',
|
|
39
|
+
'light',
|
|
40
|
+
'neutral',
|
|
41
|
+
'primary',
|
|
42
|
+
undefined,
|
|
43
|
+
],
|
|
31
44
|
control: { type: 'select' },
|
|
32
45
|
description: 'Type of tag',
|
|
33
46
|
defaultValue: { summary: 'neutral' },
|