@spaced-out/ui-design-system 0.3.9 → 0.3.11
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/.cspell/custom-words.txt +1 -0
- package/CHANGELOG.md +19 -0
- package/lib/components/Banner/Banner.js +1 -0
- package/lib/components/Banner/Banner.js.flow +1 -0
- package/lib/components/ChatBubble/ChatBubble.js +152 -0
- package/lib/components/ChatBubble/ChatBubble.js.flow +218 -0
- package/lib/components/ChatBubble/ChatBubble.module.css +132 -0
- package/lib/components/ChatBubble/index.js +16 -0
- package/lib/components/ChatBubble/index.js.flow +3 -0
- package/lib/components/Disclaimer/Disclaimer.js +36 -0
- package/lib/components/Disclaimer/Disclaimer.js.flow +44 -0
- package/lib/components/Disclaimer/Disclaimer.module.css +14 -0
- package/lib/components/Disclaimer/index.js +16 -0
- package/lib/components/Disclaimer/index.js.flow +3 -0
- package/lib/components/InContextAlert/InContextAlert.js +17 -8
- package/lib/components/InContextAlert/InContextAlert.js.flow +11 -0
- package/lib/components/KPIBox/KPIBox.js.flow +1 -1
- package/lib/components/PromptChip/PromptChip.js +88 -0
- package/lib/components/PromptChip/PromptChip.js.flow +161 -0
- package/lib/components/PromptChip/PromptChip.module.css +82 -0
- package/lib/components/PromptChip/index.js +16 -0
- package/lib/components/PromptChip/index.js.flow +3 -0
- package/lib/components/PromptInput/PromptInput.js +119 -0
- package/lib/components/PromptInput/PromptInput.js.flow +190 -0
- package/lib/components/PromptInput/PromptInput.module.css +56 -0
- package/lib/components/PromptInput/index.js +16 -0
- package/lib/components/PromptInput/index.js.flow +3 -0
- package/lib/components/RadioTile/RadioTile.js +77 -0
- package/lib/components/RadioTile/RadioTile.js.flow +110 -0
- package/lib/components/RadioTile/RadioTile.module.css +41 -0
- package/lib/components/RadioTile/index.js +16 -0
- package/lib/components/RadioTile/index.js.flow +3 -0
- package/lib/components/Separator/Separator.js +41 -0
- package/lib/components/Separator/Separator.js.flow +60 -0
- package/lib/components/Separator/Separator.module.css +10 -0
- package/lib/components/Separator/index.js +16 -0
- package/lib/components/Separator/index.js.flow +3 -0
- package/lib/components/TextTile/TextTile.js +36 -0
- package/lib/components/TextTile/TextTile.js.flow +44 -0
- package/lib/components/TextTile/TextTile.module.css +27 -0
- package/lib/components/TextTile/index.js +16 -0
- package/lib/components/TextTile/index.js.flow +3 -0
- package/lib/components/Textarea/Textarea.js +2 -1
- package/lib/components/Textarea/Textarea.js.flow +2 -1
- package/lib/components/index.js +99 -0
- package/lib/components/index.js.flow +9 -0
- package/package.json +1 -1
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.TextTile = void 0;
|
|
7
|
+
var React = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _classify = _interopRequireDefault(require("../../utils/classify"));
|
|
9
|
+
var _Icon = require("../Icon");
|
|
10
|
+
var _Text = require("../Text");
|
|
11
|
+
var _TextTileModule = _interopRequireDefault(require("./TextTile.module.css"));
|
|
12
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
+
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
|
+
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
|
+
|
|
16
|
+
const TextTile = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
17
|
+
let {
|
|
18
|
+
header,
|
|
19
|
+
iconName = 'sparkles',
|
|
20
|
+
classNames,
|
|
21
|
+
description
|
|
22
|
+
} = _ref;
|
|
23
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
24
|
+
ref: ref,
|
|
25
|
+
"data-testid": "TextTile",
|
|
26
|
+
className: (0, _classify.default)(_TextTileModule.default.textTileWrapper, classNames?.wrapper)
|
|
27
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
28
|
+
className: (0, _classify.default)(_TextTileModule.default.textTileTitle, classNames?.title)
|
|
29
|
+
}, /*#__PURE__*/React.createElement(_Icon.Icon, {
|
|
30
|
+
size: _Icon.ICON_SIZE.large,
|
|
31
|
+
name: iconName,
|
|
32
|
+
type: _Icon.ICON_TYPE.solid,
|
|
33
|
+
className: _TextTileModule.default.sparkles
|
|
34
|
+
}), /*#__PURE__*/React.createElement(_Text.JumboMedium, null, header)), /*#__PURE__*/React.createElement(_Text.BodyLarge, null, description));
|
|
35
|
+
});
|
|
36
|
+
exports.TextTile = TextTile;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
// @flow strict
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
|
|
5
|
+
import classify from '../../utils/classify';
|
|
6
|
+
import {Icon, ICON_SIZE, ICON_TYPE} from '../Icon';
|
|
7
|
+
import {BodyLarge, JumboMedium} from '../Text';
|
|
8
|
+
|
|
9
|
+
import css from './TextTile.module.css';
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
type ClassNames = $ReadOnly<{wrapper?: string, title?: string}>;
|
|
13
|
+
|
|
14
|
+
export type TextTileProps = {
|
|
15
|
+
header?: string,
|
|
16
|
+
iconName?: string,
|
|
17
|
+
classNames?: ClassNames,
|
|
18
|
+
description?: string,
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
export const TextTile: React$AbstractComponent<TextTileProps, HTMLDivElement> =
|
|
22
|
+
React.forwardRef<TextTileProps, HTMLDivElement>(
|
|
23
|
+
(
|
|
24
|
+
{header, iconName = 'sparkles', classNames, description}: TextTileProps,
|
|
25
|
+
ref,
|
|
26
|
+
) => (
|
|
27
|
+
<div
|
|
28
|
+
ref={ref}
|
|
29
|
+
data-testid="TextTile"
|
|
30
|
+
className={classify(css.textTileWrapper, classNames?.wrapper)}
|
|
31
|
+
>
|
|
32
|
+
<div className={classify(css.textTileTitle, classNames?.title)}>
|
|
33
|
+
<Icon
|
|
34
|
+
size={ICON_SIZE.large}
|
|
35
|
+
name={iconName}
|
|
36
|
+
type={ICON_TYPE.solid}
|
|
37
|
+
className={css.sparkles}
|
|
38
|
+
/>
|
|
39
|
+
<JumboMedium>{header}</JumboMedium>
|
|
40
|
+
</div>
|
|
41
|
+
<BodyLarge>{description}</BodyLarge>
|
|
42
|
+
</div>
|
|
43
|
+
),
|
|
44
|
+
);
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
@value (
|
|
2
|
+
spaceSmall,
|
|
3
|
+
spaceXSmall
|
|
4
|
+
) from '../../styles/variables/_space.css';
|
|
5
|
+
@value (
|
|
6
|
+
colorFillPrimary,
|
|
7
|
+
colorInformation
|
|
8
|
+
) from '../../styles/variables/_color.css';
|
|
9
|
+
|
|
10
|
+
.textTileWrapper {
|
|
11
|
+
display: flex;
|
|
12
|
+
gap: spaceSmall;
|
|
13
|
+
flex-direction: column;
|
|
14
|
+
align-items: center;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.textTileTitle {
|
|
18
|
+
display: flex;
|
|
19
|
+
gap: spaceXSmall;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.sparkles {
|
|
24
|
+
background: linear-gradient(to right, colorFillPrimary, colorInformation);
|
|
25
|
+
background-clip: text;
|
|
26
|
+
-webkit-text-fill-color: transparent;
|
|
27
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
var _TextTile = require("./TextTile");
|
|
7
|
+
Object.keys(_TextTile).forEach(function (key) {
|
|
8
|
+
if (key === "default" || key === "__esModule") return;
|
|
9
|
+
if (key in exports && exports[key] === _TextTile[key]) return;
|
|
10
|
+
Object.defineProperty(exports, key, {
|
|
11
|
+
enumerable: true,
|
|
12
|
+
get: function () {
|
|
13
|
+
return _TextTile[key];
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
});
|
|
@@ -73,7 +73,8 @@ const Textarea_ = (props, ref) => {
|
|
|
73
73
|
value: value,
|
|
74
74
|
onChange: onChange,
|
|
75
75
|
onFocus: onFocus,
|
|
76
|
-
onBlur: onBlur
|
|
76
|
+
onBlur: onBlur,
|
|
77
|
+
className: classNames?.textarea
|
|
77
78
|
}))), (Boolean(helperText) || error) && /*#__PURE__*/React.createElement("div", {
|
|
78
79
|
className: _TextareaModule.default.info
|
|
79
80
|
}, /*#__PURE__*/React.createElement(_Text.BodySmall, {
|
|
@@ -7,7 +7,7 @@ import {BodySmall, FormLabelSmall} from '../Text';
|
|
|
7
7
|
import css from './Textarea.module.css';
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
type ClassNames = $ReadOnly<{box?: string}>;
|
|
10
|
+
type ClassNames = $ReadOnly<{box?: string, textarea?: string}>;
|
|
11
11
|
|
|
12
12
|
export type TextareaProps = {
|
|
13
13
|
value?: string,
|
|
@@ -112,6 +112,7 @@ const Textarea_ = (props: TextareaProps, ref): React.Node => {
|
|
|
112
112
|
onChange={onChange}
|
|
113
113
|
onFocus={onFocus}
|
|
114
114
|
onBlur={onBlur}
|
|
115
|
+
className={classNames?.textarea}
|
|
115
116
|
></textarea>
|
|
116
117
|
</div>
|
|
117
118
|
{(Boolean(helperText) || error) && (
|
package/lib/components/index.js
CHANGED
|
@@ -113,6 +113,17 @@ Object.keys(_Charts).forEach(function (key) {
|
|
|
113
113
|
}
|
|
114
114
|
});
|
|
115
115
|
});
|
|
116
|
+
var _ChatBubble = require("./ChatBubble");
|
|
117
|
+
Object.keys(_ChatBubble).forEach(function (key) {
|
|
118
|
+
if (key === "default" || key === "__esModule") return;
|
|
119
|
+
if (key in exports && exports[key] === _ChatBubble[key]) return;
|
|
120
|
+
Object.defineProperty(exports, key, {
|
|
121
|
+
enumerable: true,
|
|
122
|
+
get: function () {
|
|
123
|
+
return _ChatBubble[key];
|
|
124
|
+
}
|
|
125
|
+
});
|
|
126
|
+
});
|
|
116
127
|
var _Checkbox = require("./Checkbox");
|
|
117
128
|
Object.keys(_Checkbox).forEach(function (key) {
|
|
118
129
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -190,6 +201,17 @@ Object.keys(_Dialog).forEach(function (key) {
|
|
|
190
201
|
}
|
|
191
202
|
});
|
|
192
203
|
});
|
|
204
|
+
var _Disclaimer = require("./Disclaimer");
|
|
205
|
+
Object.keys(_Disclaimer).forEach(function (key) {
|
|
206
|
+
if (key === "default" || key === "__esModule") return;
|
|
207
|
+
if (key in exports && exports[key] === _Disclaimer[key]) return;
|
|
208
|
+
Object.defineProperty(exports, key, {
|
|
209
|
+
enumerable: true,
|
|
210
|
+
get: function () {
|
|
211
|
+
return _Disclaimer[key];
|
|
212
|
+
}
|
|
213
|
+
});
|
|
214
|
+
});
|
|
193
215
|
var _Dropdown = require("./Dropdown");
|
|
194
216
|
Object.keys(_Dropdown).forEach(function (key) {
|
|
195
217
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -443,6 +465,28 @@ Object.keys(_ProgressDonut).forEach(function (key) {
|
|
|
443
465
|
}
|
|
444
466
|
});
|
|
445
467
|
});
|
|
468
|
+
var _PromptChip = require("./PromptChip");
|
|
469
|
+
Object.keys(_PromptChip).forEach(function (key) {
|
|
470
|
+
if (key === "default" || key === "__esModule") return;
|
|
471
|
+
if (key in exports && exports[key] === _PromptChip[key]) return;
|
|
472
|
+
Object.defineProperty(exports, key, {
|
|
473
|
+
enumerable: true,
|
|
474
|
+
get: function () {
|
|
475
|
+
return _PromptChip[key];
|
|
476
|
+
}
|
|
477
|
+
});
|
|
478
|
+
});
|
|
479
|
+
var _PromptInput = require("./PromptInput");
|
|
480
|
+
Object.keys(_PromptInput).forEach(function (key) {
|
|
481
|
+
if (key === "default" || key === "__esModule") return;
|
|
482
|
+
if (key in exports && exports[key] === _PromptInput[key]) return;
|
|
483
|
+
Object.defineProperty(exports, key, {
|
|
484
|
+
enumerable: true,
|
|
485
|
+
get: function () {
|
|
486
|
+
return _PromptInput[key];
|
|
487
|
+
}
|
|
488
|
+
});
|
|
489
|
+
});
|
|
446
490
|
var _RadioButton = require("./RadioButton");
|
|
447
491
|
Object.keys(_RadioButton).forEach(function (key) {
|
|
448
492
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -454,6 +498,17 @@ Object.keys(_RadioButton).forEach(function (key) {
|
|
|
454
498
|
}
|
|
455
499
|
});
|
|
456
500
|
});
|
|
501
|
+
var _RadioTile = require("./RadioTile");
|
|
502
|
+
Object.keys(_RadioTile).forEach(function (key) {
|
|
503
|
+
if (key === "default" || key === "__esModule") return;
|
|
504
|
+
if (key in exports && exports[key] === _RadioTile[key]) return;
|
|
505
|
+
Object.defineProperty(exports, key, {
|
|
506
|
+
enumerable: true,
|
|
507
|
+
get: function () {
|
|
508
|
+
return _RadioTile[key];
|
|
509
|
+
}
|
|
510
|
+
});
|
|
511
|
+
});
|
|
457
512
|
var _RangeSlider = require("./RangeSlider");
|
|
458
513
|
Object.keys(_RangeSlider).forEach(function (key) {
|
|
459
514
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -465,6 +520,28 @@ Object.keys(_RangeSlider).forEach(function (key) {
|
|
|
465
520
|
}
|
|
466
521
|
});
|
|
467
522
|
});
|
|
523
|
+
var _Rating = require("./Rating");
|
|
524
|
+
Object.keys(_Rating).forEach(function (key) {
|
|
525
|
+
if (key === "default" || key === "__esModule") return;
|
|
526
|
+
if (key in exports && exports[key] === _Rating[key]) return;
|
|
527
|
+
Object.defineProperty(exports, key, {
|
|
528
|
+
enumerable: true,
|
|
529
|
+
get: function () {
|
|
530
|
+
return _Rating[key];
|
|
531
|
+
}
|
|
532
|
+
});
|
|
533
|
+
});
|
|
534
|
+
var _ScoreBar = require("./ScoreBar");
|
|
535
|
+
Object.keys(_ScoreBar).forEach(function (key) {
|
|
536
|
+
if (key === "default" || key === "__esModule") return;
|
|
537
|
+
if (key in exports && exports[key] === _ScoreBar[key]) return;
|
|
538
|
+
Object.defineProperty(exports, key, {
|
|
539
|
+
enumerable: true,
|
|
540
|
+
get: function () {
|
|
541
|
+
return _ScoreBar[key];
|
|
542
|
+
}
|
|
543
|
+
});
|
|
544
|
+
});
|
|
468
545
|
var _SearchInput = require("./SearchInput");
|
|
469
546
|
Object.keys(_SearchInput).forEach(function (key) {
|
|
470
547
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -476,6 +553,17 @@ Object.keys(_SearchInput).forEach(function (key) {
|
|
|
476
553
|
}
|
|
477
554
|
});
|
|
478
555
|
});
|
|
556
|
+
var _Separator = require("./Separator");
|
|
557
|
+
Object.keys(_Separator).forEach(function (key) {
|
|
558
|
+
if (key === "default" || key === "__esModule") return;
|
|
559
|
+
if (key in exports && exports[key] === _Separator[key]) return;
|
|
560
|
+
Object.defineProperty(exports, key, {
|
|
561
|
+
enumerable: true,
|
|
562
|
+
get: function () {
|
|
563
|
+
return _Separator[key];
|
|
564
|
+
}
|
|
565
|
+
});
|
|
566
|
+
});
|
|
479
567
|
var _Shimmer = require("./Shimmer");
|
|
480
568
|
Object.keys(_Shimmer).forEach(function (key) {
|
|
481
569
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -586,6 +674,17 @@ Object.keys(_Textarea).forEach(function (key) {
|
|
|
586
674
|
}
|
|
587
675
|
});
|
|
588
676
|
});
|
|
677
|
+
var _TextTile = require("./TextTile");
|
|
678
|
+
Object.keys(_TextTile).forEach(function (key) {
|
|
679
|
+
if (key === "default" || key === "__esModule") return;
|
|
680
|
+
if (key in exports && exports[key] === _TextTile[key]) return;
|
|
681
|
+
Object.defineProperty(exports, key, {
|
|
682
|
+
enumerable: true,
|
|
683
|
+
get: function () {
|
|
684
|
+
return _TextTile[key];
|
|
685
|
+
}
|
|
686
|
+
});
|
|
687
|
+
});
|
|
589
688
|
var _Toast = require("./Toast");
|
|
590
689
|
Object.keys(_Toast).forEach(function (key) {
|
|
591
690
|
if (key === "default" || key === "__esModule") return;
|
|
@@ -10,6 +10,7 @@ export * from './ButtonDropdown';
|
|
|
10
10
|
export * from './ButtonTabs';
|
|
11
11
|
export * from './Card';
|
|
12
12
|
export * from './Charts';
|
|
13
|
+
export * from './ChatBubble';
|
|
13
14
|
export * from './Checkbox';
|
|
14
15
|
export * from './Chip';
|
|
15
16
|
export * from './CircularLoader';
|
|
@@ -17,6 +18,7 @@ export * from './CollapsibleCard';
|
|
|
17
18
|
export * from './ConditionalWrapper';
|
|
18
19
|
export * from './DateRangePicker';
|
|
19
20
|
export * from './Dialog';
|
|
21
|
+
export * from './Disclaimer';
|
|
20
22
|
export * from './Dropdown';
|
|
21
23
|
export * from './EmptyState';
|
|
22
24
|
export * from './ErrorMessage';
|
|
@@ -40,9 +42,15 @@ export * from './PageTitle';
|
|
|
40
42
|
export * from './Pagination';
|
|
41
43
|
export * from './Panel';
|
|
42
44
|
export * from './ProgressDonut';
|
|
45
|
+
export * from './PromptChip';
|
|
46
|
+
export * from './PromptInput';
|
|
43
47
|
export * from './RadioButton';
|
|
48
|
+
export * from './RadioTile';
|
|
44
49
|
export * from './RangeSlider';
|
|
50
|
+
export * from './Rating';
|
|
51
|
+
export * from './ScoreBar';
|
|
45
52
|
export * from './SearchInput';
|
|
53
|
+
export * from './Separator';
|
|
46
54
|
export * from './Shimmer';
|
|
47
55
|
export * from './SideMenuLink';
|
|
48
56
|
export * from './StatusIndicator';
|
|
@@ -53,6 +61,7 @@ export * from './Table';
|
|
|
53
61
|
export * from './Tabs';
|
|
54
62
|
export * from './Text';
|
|
55
63
|
export * from './Textarea';
|
|
64
|
+
export * from './TextTile';
|
|
56
65
|
export * from './Toast';
|
|
57
66
|
export * from './Toggle';
|
|
58
67
|
export * from './Tooltip';
|