@dxc-technology/halstack-react 0.0.0-e4ccd42 → 0.0.0-e690193
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/README.md +1 -2
- package/dist/index.d.mts +3923 -0
- package/dist/index.d.ts +3923 -0
- package/dist/index.js +14133 -0
- package/dist/index.mjs +14045 -0
- package/package.json +83 -67
- package/BackgroundColorContext.d.ts +0 -1
- package/BackgroundColorContext.js +0 -30
- package/HalstackContext.d.ts +0 -1249
- package/HalstackContext.js +0 -310
- package/accordion/Accordion.d.ts +0 -4
- package/accordion/Accordion.js +0 -182
- package/accordion/Accordion.stories.tsx +0 -283
- package/accordion/Accordion.test.js +0 -56
- package/accordion/types.d.ts +0 -57
- package/accordion/types.js +0 -5
- package/accordion-group/AccordionGroup.d.ts +0 -8
- package/accordion-group/AccordionGroup.js +0 -101
- package/accordion-group/AccordionGroup.stories.tsx +0 -252
- package/accordion-group/AccordionGroup.test.js +0 -98
- package/accordion-group/AccordionGroupAccordion.d.ts +0 -4
- package/accordion-group/AccordionGroupAccordion.js +0 -31
- package/accordion-group/types.d.ts +0 -67
- package/accordion-group/types.js +0 -5
- package/action-icon/ActionIcon.d.ts +0 -4
- package/action-icon/ActionIcon.js +0 -47
- package/action-icon/ActionIcon.stories.tsx +0 -41
- package/action-icon/ActionIcon.test.js +0 -64
- package/action-icon/types.d.ts +0 -26
- package/action-icon/types.js +0 -5
- package/alert/Alert.d.ts +0 -4
- package/alert/Alert.js +0 -254
- package/alert/Alert.stories.tsx +0 -198
- package/alert/Alert.test.js +0 -75
- package/alert/types.d.ts +0 -49
- package/alert/types.js +0 -5
- package/badge/Badge.d.ts +0 -4
- package/badge/Badge.js +0 -159
- package/badge/Badge.stories.tsx +0 -210
- package/badge/Badge.test.js +0 -30
- package/badge/types.d.ts +0 -54
- package/badge/types.js +0 -5
- package/bleed/Bleed.d.ts +0 -3
- package/bleed/Bleed.js +0 -43
- package/bleed/Bleed.stories.tsx +0 -342
- package/bleed/types.d.ts +0 -37
- package/bleed/types.js +0 -5
- package/box/Box.d.ts +0 -4
- package/box/Box.js +0 -75
- package/box/Box.stories.tsx +0 -119
- package/box/Box.test.js +0 -13
- package/box/types.d.ts +0 -32
- package/box/types.js +0 -5
- package/bulleted-list/BulletedList.d.ts +0 -7
- package/bulleted-list/BulletedList.js +0 -89
- package/bulleted-list/BulletedList.stories.tsx +0 -115
- package/bulleted-list/types.d.ts +0 -38
- package/bulleted-list/types.js +0 -5
- package/button/Button.d.ts +0 -4
- package/button/Button.js +0 -120
- package/button/Button.stories.tsx +0 -344
- package/button/Button.test.js +0 -38
- package/button/types.d.ts +0 -57
- package/button/types.js +0 -5
- package/card/Card.d.ts +0 -4
- package/card/Card.js +0 -120
- package/card/Card.stories.tsx +0 -171
- package/card/Card.test.js +0 -39
- package/card/types.d.ts +0 -62
- package/card/types.js +0 -5
- package/checkbox/Checkbox.d.ts +0 -4
- package/checkbox/Checkbox.js +0 -215
- package/checkbox/Checkbox.stories.tsx +0 -222
- package/checkbox/Checkbox.test.js +0 -199
- package/checkbox/types.d.ts +0 -72
- package/checkbox/types.js +0 -5
- package/chip/Chip.d.ts +0 -4
- package/chip/Chip.js +0 -121
- package/chip/Chip.stories.tsx +0 -214
- package/chip/Chip.test.js +0 -41
- package/chip/types.d.ts +0 -45
- package/chip/types.js +0 -5
- package/common/OpenSans.css +0 -69
- package/common/coreTokens.d.ts +0 -237
- package/common/coreTokens.js +0 -184
- package/common/fonts/OpenSans-Bold.ttf +0 -0
- package/common/fonts/OpenSans-BoldItalic.ttf +0 -0
- package/common/fonts/OpenSans-ExtraBold.ttf +0 -0
- package/common/fonts/OpenSans-ExtraBoldItalic.ttf +0 -0
- package/common/fonts/OpenSans-Italic.ttf +0 -0
- package/common/fonts/OpenSans-Light.ttf +0 -0
- package/common/fonts/OpenSans-LightItalic.ttf +0 -0
- package/common/fonts/OpenSans-Regular.ttf +0 -0
- package/common/fonts/OpenSans-SemiBold.ttf +0 -0
- package/common/fonts/OpenSans-SemiBoldItalic.ttf +0 -0
- package/common/utils.d.ts +0 -1
- package/common/utils.js +0 -16
- package/common/variables.d.ts +0 -1395
- package/common/variables.js +0 -1267
- package/container/Container.d.ts +0 -4
- package/container/Container.js +0 -194
- package/container/Container.stories.tsx +0 -214
- package/container/types.d.ts +0 -74
- package/container/types.js +0 -5
- package/date-input/Calendar.d.ts +0 -4
- package/date-input/Calendar.js +0 -214
- package/date-input/DateInput.d.ts +0 -4
- package/date-input/DateInput.js +0 -223
- package/date-input/DateInput.stories.tsx +0 -285
- package/date-input/DateInput.test.js +0 -808
- package/date-input/DatePicker.d.ts +0 -4
- package/date-input/DatePicker.js +0 -115
- package/date-input/Icons.d.ts +0 -6
- package/date-input/Icons.js +0 -58
- package/date-input/YearPicker.d.ts +0 -4
- package/date-input/YearPicker.js +0 -100
- package/date-input/types.d.ts +0 -164
- package/date-input/types.js +0 -5
- package/dialog/Dialog.d.ts +0 -4
- package/dialog/Dialog.js +0 -104
- package/dialog/Dialog.stories.tsx +0 -365
- package/dialog/Dialog.test.js +0 -307
- package/dialog/types.d.ts +0 -36
- package/dialog/types.js +0 -5
- package/dropdown/Dropdown.d.ts +0 -4
- package/dropdown/Dropdown.js +0 -336
- package/dropdown/Dropdown.stories.tsx +0 -438
- package/dropdown/Dropdown.test.js +0 -599
- package/dropdown/DropdownMenu.d.ts +0 -4
- package/dropdown/DropdownMenu.js +0 -63
- package/dropdown/DropdownMenuItem.d.ts +0 -4
- package/dropdown/DropdownMenuItem.js +0 -67
- package/dropdown/types.d.ts +0 -98
- package/dropdown/types.js +0 -5
- package/file-input/FileInput.d.ts +0 -4
- package/file-input/FileInput.js +0 -479
- package/file-input/FileInput.stories.tsx +0 -618
- package/file-input/FileInput.test.js +0 -459
- package/file-input/FileItem.d.ts +0 -4
- package/file-input/FileItem.js +0 -135
- package/file-input/types.d.ts +0 -129
- package/file-input/types.js +0 -5
- package/flex/Flex.d.ts +0 -4
- package/flex/Flex.js +0 -57
- package/flex/Flex.stories.tsx +0 -112
- package/flex/types.d.ts +0 -97
- package/flex/types.js +0 -5
- package/footer/Footer.d.ts +0 -4
- package/footer/Footer.js +0 -138
- package/footer/Footer.stories.tsx +0 -171
- package/footer/Footer.test.js +0 -85
- package/footer/Icons.d.ts +0 -3
- package/footer/Icons.js +0 -136
- package/footer/types.d.ts +0 -64
- package/footer/types.js +0 -5
- package/grid/Grid.d.ts +0 -7
- package/grid/Grid.js +0 -76
- package/grid/Grid.stories.tsx +0 -219
- package/grid/types.d.ts +0 -115
- package/grid/types.js +0 -5
- package/header/Header.d.ts +0 -8
- package/header/Header.js +0 -220
- package/header/Header.stories.tsx +0 -251
- package/header/Header.test.js +0 -66
- package/header/Icons.d.ts +0 -2
- package/header/Icons.js +0 -29
- package/header/types.d.ts +0 -33
- package/header/types.js +0 -5
- package/heading/Heading.d.ts +0 -4
- package/heading/Heading.js +0 -137
- package/heading/Heading.stories.tsx +0 -54
- package/heading/Heading.test.js +0 -169
- package/heading/types.d.ts +0 -33
- package/heading/types.js +0 -5
- package/image/Image.d.ts +0 -4
- package/image/Image.js +0 -70
- package/image/Image.stories.tsx +0 -129
- package/image/types.d.ts +0 -72
- package/image/types.js +0 -5
- package/inset/Inset.d.ts +0 -3
- package/inset/Inset.js +0 -43
- package/inset/Inset.stories.tsx +0 -230
- package/inset/types.d.ts +0 -37
- package/inset/types.js +0 -5
- package/layout/ApplicationLayout.d.ts +0 -20
- package/layout/ApplicationLayout.js +0 -134
- package/layout/ApplicationLayout.stories.tsx +0 -162
- package/layout/Icons.d.ts +0 -8
- package/layout/Icons.js +0 -58
- package/layout/SidenavContext.d.ts +0 -5
- package/layout/SidenavContext.js +0 -13
- package/layout/types.d.ts +0 -41
- package/layout/types.js +0 -5
- package/link/Link.d.ts +0 -4
- package/link/Link.js +0 -115
- package/link/Link.stories.tsx +0 -253
- package/link/Link.test.js +0 -63
- package/link/types.d.ts +0 -54
- package/link/types.js +0 -5
- package/main.d.ts +0 -47
- package/main.js +0 -343
- package/nav-tabs/NavTabs.d.ts +0 -8
- package/nav-tabs/NavTabs.js +0 -93
- package/nav-tabs/NavTabs.stories.tsx +0 -276
- package/nav-tabs/NavTabs.test.js +0 -76
- package/nav-tabs/Tab.d.ts +0 -4
- package/nav-tabs/Tab.js +0 -118
- package/nav-tabs/types.d.ts +0 -52
- package/nav-tabs/types.js +0 -5
- package/number-input/NumberInput.d.ts +0 -11
- package/number-input/NumberInput.js +0 -86
- package/number-input/NumberInput.stories.tsx +0 -131
- package/number-input/NumberInput.test.js +0 -989
- package/number-input/types.d.ts +0 -130
- package/number-input/types.js +0 -5
- package/paginator/Icons.d.ts +0 -5
- package/paginator/Icons.js +0 -40
- package/paginator/Paginator.d.ts +0 -4
- package/paginator/Paginator.js +0 -135
- package/paginator/Paginator.stories.tsx +0 -87
- package/paginator/Paginator.test.js +0 -335
- package/paginator/types.d.ts +0 -38
- package/paginator/types.js +0 -5
- package/paragraph/Paragraph.d.ts +0 -5
- package/paragraph/Paragraph.js +0 -22
- package/paragraph/Paragraph.stories.tsx +0 -27
- package/password-input/Icons.d.ts +0 -6
- package/password-input/Icons.js +0 -35
- package/password-input/PasswordInput.d.ts +0 -4
- package/password-input/PasswordInput.js +0 -97
- package/password-input/PasswordInput.stories.tsx +0 -99
- package/password-input/PasswordInput.test.js +0 -198
- package/password-input/types.d.ts +0 -111
- package/password-input/types.js +0 -5
- package/progress-bar/ProgressBar.d.ts +0 -4
- package/progress-bar/ProgressBar.js +0 -144
- package/progress-bar/ProgressBar.stories.tsx +0 -93
- package/progress-bar/ProgressBar.test.js +0 -93
- package/progress-bar/types.d.ts +0 -37
- package/progress-bar/types.js +0 -5
- package/quick-nav/QuickNav.d.ts +0 -4
- package/quick-nav/QuickNav.js +0 -94
- package/quick-nav/QuickNav.stories.tsx +0 -356
- package/quick-nav/types.d.ts +0 -21
- package/quick-nav/types.js +0 -5
- package/radio-group/Radio.d.ts +0 -4
- package/radio-group/Radio.js +0 -124
- package/radio-group/RadioGroup.d.ts +0 -4
- package/radio-group/RadioGroup.js +0 -235
- package/radio-group/RadioGroup.stories.tsx +0 -214
- package/radio-group/RadioGroup.test.js +0 -756
- package/radio-group/types.d.ts +0 -114
- package/radio-group/types.js +0 -5
- package/resultset-table/Icons.d.ts +0 -7
- package/resultset-table/Icons.js +0 -47
- package/resultset-table/ResultsetTable.d.ts +0 -7
- package/resultset-table/ResultsetTable.js +0 -166
- package/resultset-table/ResultsetTable.stories.tsx +0 -397
- package/resultset-table/ResultsetTable.test.js +0 -371
- package/resultset-table/types.d.ts +0 -73
- package/resultset-table/types.js +0 -5
- package/select/Icons.d.ts +0 -10
- package/select/Icons.js +0 -89
- package/select/Listbox.d.ts +0 -4
- package/select/Listbox.js +0 -143
- package/select/Option.d.ts +0 -4
- package/select/Option.js +0 -87
- package/select/Select.d.ts +0 -4
- package/select/Select.js +0 -590
- package/select/Select.stories.tsx +0 -971
- package/select/Select.test.js +0 -2370
- package/select/types.d.ts +0 -209
- package/select/types.js +0 -5
- package/sidenav/Icons.d.ts +0 -7
- package/sidenav/Icons.js +0 -47
- package/sidenav/Sidenav.d.ts +0 -10
- package/sidenav/Sidenav.js +0 -196
- package/sidenav/Sidenav.stories.tsx +0 -282
- package/sidenav/Sidenav.test.js +0 -37
- package/sidenav/types.d.ts +0 -76
- package/sidenav/types.js +0 -5
- package/slider/Slider.d.ts +0 -4
- package/slider/Slider.js +0 -285
- package/slider/Slider.test.js +0 -254
- package/slider/types.d.ts +0 -86
- package/slider/types.js +0 -5
- package/spinner/Spinner.d.ts +0 -4
- package/spinner/Spinner.js +0 -206
- package/spinner/Spinner.stories.tsx +0 -129
- package/spinner/Spinner.test.js +0 -55
- package/spinner/types.d.ts +0 -32
- package/spinner/types.js +0 -5
- package/status-light/StatusLight.d.ts +0 -4
- package/status-light/StatusLight.js +0 -51
- package/status-light/StatusLight.stories.tsx +0 -74
- package/status-light/StatusLight.test.js +0 -25
- package/status-light/types.d.ts +0 -17
- package/status-light/types.js +0 -5
- package/switch/Switch.d.ts +0 -4
- package/switch/Switch.js +0 -214
- package/switch/Switch.stories.tsx +0 -137
- package/switch/Switch.test.js +0 -180
- package/switch/types.d.ts +0 -66
- package/switch/types.js +0 -5
- package/table/DropdownTheme.js +0 -62
- package/table/Table.d.ts +0 -8
- package/table/Table.js +0 -170
- package/table/Table.stories.tsx +0 -658
- package/table/Table.test.js +0 -113
- package/table/types.d.ts +0 -63
- package/table/types.js +0 -5
- package/tabs/Tab.d.ts +0 -4
- package/tabs/Tab.js +0 -116
- package/tabs/Tabs.d.ts +0 -4
- package/tabs/Tabs.js +0 -384
- package/tabs/Tabs.stories.tsx +0 -226
- package/tabs/Tabs.test.js +0 -294
- package/tabs/types.d.ts +0 -92
- package/tabs/types.js +0 -5
- package/tag/Tag.d.ts +0 -4
- package/tag/Tag.js +0 -151
- package/tag/Tag.stories.tsx +0 -155
- package/tag/Tag.test.js +0 -49
- package/tag/types.d.ts +0 -69
- package/tag/types.js +0 -5
- package/text-input/Icons.d.ts +0 -8
- package/text-input/Icons.js +0 -56
- package/text-input/Suggestion.d.ts +0 -4
- package/text-input/Suggestion.js +0 -67
- package/text-input/Suggestions.d.ts +0 -4
- package/text-input/Suggestions.js +0 -84
- package/text-input/TextInput.d.ts +0 -4
- package/text-input/TextInput.js +0 -565
- package/text-input/TextInput.stories.tsx +0 -465
- package/text-input/TextInput.test.js +0 -1756
- package/text-input/types.d.ts +0 -205
- package/text-input/types.js +0 -5
- package/textarea/Textarea.d.ts +0 -4
- package/textarea/Textarea.js +0 -234
- package/textarea/Textarea.stories.tsx +0 -174
- package/textarea/Textarea.test.js +0 -406
- package/textarea/types.d.ts +0 -141
- package/textarea/types.js +0 -5
- package/toggle-group/ToggleGroup.d.ts +0 -4
- package/toggle-group/ToggleGroup.js +0 -201
- package/toggle-group/ToggleGroup.stories.tsx +0 -218
- package/toggle-group/ToggleGroup.test.js +0 -137
- package/toggle-group/types.d.ts +0 -114
- package/toggle-group/types.js +0 -5
- package/typography/Typography.d.ts +0 -4
- package/typography/Typography.js +0 -23
- package/typography/Typography.stories.tsx +0 -198
- package/typography/types.d.ts +0 -18
- package/typography/types.js +0 -5
- package/useTheme.d.ts +0 -1148
- package/useTheme.js +0 -15
- package/useTranslatedLabels.d.ts +0 -85
- package/useTranslatedLabels.js +0 -14
- package/utils/BaseTypography.d.ts +0 -21
- package/utils/BaseTypography.js +0 -94
- package/utils/FocusLock.d.ts +0 -13
- package/utils/FocusLock.js +0 -124
- package/wizard/Wizard.d.ts +0 -4
- package/wizard/Wizard.js +0 -250
- package/wizard/Wizard.stories.tsx +0 -253
- package/wizard/Wizard.test.js +0 -114
- package/wizard/types.d.ts +0 -64
- package/wizard/types.js +0 -5
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
10
|
-
var _react = _interopRequireDefault(require("react"));
|
|
11
|
-
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
12
|
-
var _Flex = _interopRequireDefault(require("../flex/Flex"));
|
|
13
|
-
var _Typography = _interopRequireDefault(require("../typography/Typography"));
|
|
14
|
-
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
15
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9;
|
|
16
|
-
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
17
|
-
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
18
|
-
var BulletedListItem = function BulletedListItem(_ref) {
|
|
19
|
-
var children = _ref.children;
|
|
20
|
-
return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, children);
|
|
21
|
-
};
|
|
22
|
-
var DxcBulletedList = function DxcBulletedList(_ref2) {
|
|
23
|
-
var children = _ref2.children,
|
|
24
|
-
_ref2$type = _ref2.type,
|
|
25
|
-
type = _ref2$type === void 0 ? "disc" : _ref2$type,
|
|
26
|
-
_ref2$icon = _ref2.icon,
|
|
27
|
-
icon = _ref2$icon === void 0 ? "" : _ref2$icon;
|
|
28
|
-
var colorsTheme = (0, _useTheme["default"])();
|
|
29
|
-
return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
|
|
30
|
-
theme: colorsTheme.bulletedList
|
|
31
|
-
}, /*#__PURE__*/_react["default"].createElement(ListContainer, null, /*#__PURE__*/_react["default"].createElement(_Flex["default"], {
|
|
32
|
-
direction: "column",
|
|
33
|
-
as: type === "number" ? "ol" : "ul",
|
|
34
|
-
gap: "0.125rem"
|
|
35
|
-
}, _react["default"].Children.map(children, function (child, index) {
|
|
36
|
-
return /*#__PURE__*/_react["default"].createElement(ListItem, null, /*#__PURE__*/_react["default"].createElement(GeneralContent, null, type === "number" ? /*#__PURE__*/_react["default"].createElement(Number, null, /*#__PURE__*/_react["default"].createElement(_Typography["default"], {
|
|
37
|
-
color: colorsTheme.bulletedList.fontColor
|
|
38
|
-
}, index + 1, ".")) : type === "square" ? /*#__PURE__*/_react["default"].createElement(Bullet, null, /*#__PURE__*/_react["default"].createElement(Square, null)) : type === "circle" ? /*#__PURE__*/_react["default"].createElement(Bullet, null, /*#__PURE__*/_react["default"].createElement(Circle, null)) : type === "icon" ? /*#__PURE__*/_react["default"].createElement(Bullet, null, /*#__PURE__*/_react["default"].createElement(Icon, null, typeof icon === "string" ? /*#__PURE__*/_react["default"].createElement("img", {
|
|
39
|
-
src: icon
|
|
40
|
-
}) : icon)) : /*#__PURE__*/_react["default"].createElement(Bullet, null, /*#__PURE__*/_react["default"].createElement(Disc, null)), /*#__PURE__*/_react["default"].createElement(_Typography["default"], {
|
|
41
|
-
color: colorsTheme.bulletedList.fontColor
|
|
42
|
-
}, child)));
|
|
43
|
-
}))));
|
|
44
|
-
};
|
|
45
|
-
DxcBulletedList.Item = BulletedListItem;
|
|
46
|
-
var ListContainer = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n ul,\n ol {\n padding: 0;\n margin: 0;\n }\n"])));
|
|
47
|
-
var Bullet = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-self: flex-start;\n align-items: center;\n height: 1.5rem;\n"])));
|
|
48
|
-
var GeneralContent = _styledComponents["default"].div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n display: grid;\n grid-template-columns: auto 1fr;\n align-items: center;\n"])));
|
|
49
|
-
var Icon = _styledComponents["default"].div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["\n height: 1.5rem;\n width: auto;\n margin-right: ", ";\n align-content: center;\n color: ", ";\n\n svg,\n img {\n height: ", ";\n width: ", ";\n }\n"])), function (props) {
|
|
50
|
-
return props.theme.bulletMarginRight;
|
|
51
|
-
}, function (props) {
|
|
52
|
-
return props.theme.fontColor;
|
|
53
|
-
}, function (props) {
|
|
54
|
-
return props.theme.bulletIconHeight;
|
|
55
|
-
}, function (props) {
|
|
56
|
-
return props.theme.bulletIconWidth;
|
|
57
|
-
});
|
|
58
|
-
var Number = _styledComponents["default"].div(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n user-select: none;\n margin-right: ", ";\n display: flex;\n box-sizing: border-box;\n align-self: flex-start;\n min-width: 0;\n"])), function (props) {
|
|
59
|
-
return props.theme.bulletMarginRight;
|
|
60
|
-
});
|
|
61
|
-
var Square = _styledComponents["default"].div(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n background-color: ", ";\n height: ", ";\n width: ", ";\n margin-right: ", ";\n"])), function (props) {
|
|
62
|
-
return props.theme.fontColor;
|
|
63
|
-
}, function (props) {
|
|
64
|
-
return props.theme.bulletHeight;
|
|
65
|
-
}, function (props) {
|
|
66
|
-
return props.theme.bulletWidth;
|
|
67
|
-
}, function (props) {
|
|
68
|
-
return props.theme.bulletMarginRight;
|
|
69
|
-
});
|
|
70
|
-
var Circle = _styledComponents["default"].div(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2["default"])(["\n height: ", ";\n width: ", ";\n border-radius: 50%;\n border: 1px solid;\n border-color: ", ";\n margin-right: ", ";\n"])), function (props) {
|
|
71
|
-
return props.theme.bulletHeight;
|
|
72
|
-
}, function (props) {
|
|
73
|
-
return props.theme.bulletWidth;
|
|
74
|
-
}, function (props) {
|
|
75
|
-
return props.theme.fontColor;
|
|
76
|
-
}, function (props) {
|
|
77
|
-
return props.theme.bulletMarginRight;
|
|
78
|
-
});
|
|
79
|
-
var Disc = _styledComponents["default"].div(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2["default"])(["\n background-color: ", ";\n height: ", ";\n width: ", ";\n border-radius: 50%;\n margin-right: ", ";\n"])), function (props) {
|
|
80
|
-
return props.theme.fontColor;
|
|
81
|
-
}, function (props) {
|
|
82
|
-
return props.theme.bulletHeight;
|
|
83
|
-
}, function (props) {
|
|
84
|
-
return props.theme.bulletWidth;
|
|
85
|
-
}, function (props) {
|
|
86
|
-
return props.theme.bulletMarginRight;
|
|
87
|
-
});
|
|
88
|
-
var ListItem = _styledComponents["default"].li(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n margin: 0px;\n padding: 0px;\n list-style: none;\n font-size: 1em;\n"])));
|
|
89
|
-
var _default = exports["default"] = DxcBulletedList;
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
import styled from "styled-components";
|
|
3
|
-
import Title from "../../.storybook/components/Title";
|
|
4
|
-
import ExampleContainer from "../../.storybook/components/ExampleContainer";
|
|
5
|
-
import DxcBulletedList from "./BulletedList";
|
|
6
|
-
|
|
7
|
-
export default {
|
|
8
|
-
title: "Bulleted List",
|
|
9
|
-
component: DxcBulletedList,
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
const icon = (
|
|
13
|
-
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 0 24 24" width="24px" fill="currentColor">
|
|
14
|
-
<path d="M0 0h24v24H0V0z" fill="none" />
|
|
15
|
-
<path d="M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z" />
|
|
16
|
-
</svg>
|
|
17
|
-
);
|
|
18
|
-
|
|
19
|
-
export const Chromatic = () => (
|
|
20
|
-
<>
|
|
21
|
-
<ExampleContainer>
|
|
22
|
-
<Title title="Icon list (SVG)" level={4} />
|
|
23
|
-
<DxcBulletedList type="icon" icon={icon}>
|
|
24
|
-
<DxcBulletedList.Item>Code</DxcBulletedList.Item>
|
|
25
|
-
<DxcBulletedList.Item>Usage</DxcBulletedList.Item>
|
|
26
|
-
<DxcBulletedList.Item>Specifications</DxcBulletedList.Item>
|
|
27
|
-
</DxcBulletedList>
|
|
28
|
-
<Title title="Icon list (path)" level={4} />
|
|
29
|
-
<DxcBulletedList type="icon" icon="https://upload.wikimedia.org/wikipedia/commons/e/e0/Check_green_icon.svg">
|
|
30
|
-
<DxcBulletedList.Item>Code</DxcBulletedList.Item>
|
|
31
|
-
<DxcBulletedList.Item>Usage</DxcBulletedList.Item>
|
|
32
|
-
<DxcBulletedList.Item>Specifications</DxcBulletedList.Item>
|
|
33
|
-
</DxcBulletedList>
|
|
34
|
-
<Title title="Number list" level={4} />
|
|
35
|
-
<DxcBulletedList type="number">
|
|
36
|
-
<DxcBulletedList.Item>Code</DxcBulletedList.Item>
|
|
37
|
-
<DxcBulletedList.Item>Usage</DxcBulletedList.Item>
|
|
38
|
-
<DxcBulletedList.Item>Specifications</DxcBulletedList.Item>
|
|
39
|
-
</DxcBulletedList>
|
|
40
|
-
<Title title="Square" level={4} />
|
|
41
|
-
<DxcBulletedList type="square">
|
|
42
|
-
<DxcBulletedList.Item>Code</DxcBulletedList.Item>
|
|
43
|
-
<DxcBulletedList.Item>Usage</DxcBulletedList.Item>
|
|
44
|
-
<DxcBulletedList.Item>Specifications</DxcBulletedList.Item>
|
|
45
|
-
</DxcBulletedList>
|
|
46
|
-
<Title title="Circle" level={4} />
|
|
47
|
-
<DxcBulletedList type="circle">
|
|
48
|
-
<DxcBulletedList.Item>Code</DxcBulletedList.Item>
|
|
49
|
-
<DxcBulletedList.Item>Usage</DxcBulletedList.Item>
|
|
50
|
-
<DxcBulletedList.Item>Specifications</DxcBulletedList.Item>
|
|
51
|
-
</DxcBulletedList>
|
|
52
|
-
<Title title="Disc" level={4} />
|
|
53
|
-
<DxcBulletedList>
|
|
54
|
-
<DxcBulletedList.Item>Code</DxcBulletedList.Item>
|
|
55
|
-
<DxcBulletedList.Item>Usage</DxcBulletedList.Item>
|
|
56
|
-
<DxcBulletedList.Item>Specifications</DxcBulletedList.Item>
|
|
57
|
-
</DxcBulletedList>
|
|
58
|
-
<Title title="Multiple lines" level={4} />
|
|
59
|
-
<Container>
|
|
60
|
-
<Title title="Number" level={4} />
|
|
61
|
-
<DxcBulletedList type="number">
|
|
62
|
-
<DxcBulletedList.Item>
|
|
63
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
|
|
64
|
-
dolore magna aliqua.
|
|
65
|
-
</DxcBulletedList.Item>
|
|
66
|
-
<DxcBulletedList.Item>Text 2.</DxcBulletedList.Item>
|
|
67
|
-
</DxcBulletedList>
|
|
68
|
-
</Container>
|
|
69
|
-
<Container>
|
|
70
|
-
<Title title="Square" level={4} />
|
|
71
|
-
<DxcBulletedList type="square">
|
|
72
|
-
<DxcBulletedList.Item>
|
|
73
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
|
|
74
|
-
dolore magna aliqua.
|
|
75
|
-
</DxcBulletedList.Item>
|
|
76
|
-
<DxcBulletedList.Item>Text 2.</DxcBulletedList.Item>
|
|
77
|
-
</DxcBulletedList>
|
|
78
|
-
</Container>
|
|
79
|
-
<Container>
|
|
80
|
-
<Title title="Circle" level={4} />
|
|
81
|
-
<DxcBulletedList type="circle">
|
|
82
|
-
<DxcBulletedList.Item>
|
|
83
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
|
|
84
|
-
dolore magna aliqua.
|
|
85
|
-
</DxcBulletedList.Item>
|
|
86
|
-
<DxcBulletedList.Item>Text 2.</DxcBulletedList.Item>
|
|
87
|
-
</DxcBulletedList>
|
|
88
|
-
</Container>
|
|
89
|
-
<Title title="Disc" level={4} />
|
|
90
|
-
<Container>
|
|
91
|
-
<DxcBulletedList>
|
|
92
|
-
<DxcBulletedList.Item>
|
|
93
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
|
|
94
|
-
dolore magna aliqua.
|
|
95
|
-
</DxcBulletedList.Item>
|
|
96
|
-
<DxcBulletedList.Item>Text 2.</DxcBulletedList.Item>
|
|
97
|
-
</DxcBulletedList>
|
|
98
|
-
</Container>
|
|
99
|
-
<Container>
|
|
100
|
-
<Title title="Icon" level={4} />
|
|
101
|
-
<DxcBulletedList type="icon" icon={icon}>
|
|
102
|
-
<DxcBulletedList.Item>
|
|
103
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et
|
|
104
|
-
dolore magna aliqua.
|
|
105
|
-
</DxcBulletedList.Item>
|
|
106
|
-
<DxcBulletedList.Item>Text 2.</DxcBulletedList.Item>
|
|
107
|
-
</DxcBulletedList>
|
|
108
|
-
</Container>
|
|
109
|
-
</ExampleContainer>
|
|
110
|
-
</>
|
|
111
|
-
);
|
|
112
|
-
|
|
113
|
-
const Container = styled.div`
|
|
114
|
-
width: 400px;
|
|
115
|
-
`;
|
package/bulleted-list/types.d.ts
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
type SVG = React.ReactNode & React.SVGProps<SVGSVGElement>;
|
|
3
|
-
type IconProps = {
|
|
4
|
-
/**
|
|
5
|
-
* Defines the style of the bullet point in the list.
|
|
6
|
-
*/
|
|
7
|
-
type: "icon";
|
|
8
|
-
/**
|
|
9
|
-
* Icon to display as bullet.
|
|
10
|
-
*/
|
|
11
|
-
icon: string | SVG;
|
|
12
|
-
/**
|
|
13
|
-
* Text to be shown in the list.
|
|
14
|
-
*/
|
|
15
|
-
children: React.ReactNode;
|
|
16
|
-
};
|
|
17
|
-
type OtherProps = {
|
|
18
|
-
/**
|
|
19
|
-
* Defines the style of the bullet point in the list.
|
|
20
|
-
*/
|
|
21
|
-
type?: "disc" | "circle" | "square" | "number";
|
|
22
|
-
/**
|
|
23
|
-
* Icon to display as bullet.
|
|
24
|
-
*/
|
|
25
|
-
icon?: never;
|
|
26
|
-
/**
|
|
27
|
-
* Text to be shown in the list.
|
|
28
|
-
*/
|
|
29
|
-
children: React.ReactNode;
|
|
30
|
-
};
|
|
31
|
-
type Props = IconProps | OtherProps;
|
|
32
|
-
export default Props;
|
|
33
|
-
export type BulletedListItemPropsType = {
|
|
34
|
-
/**
|
|
35
|
-
* Text to be shown in the list.
|
|
36
|
-
*/
|
|
37
|
-
children?: React.ReactNode;
|
|
38
|
-
};
|
package/bulleted-list/types.js
DELETED
package/button/Button.d.ts
DELETED
package/button/Button.js
DELETED
|
@@ -1,120 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
var _typeof3 = require("@babel/runtime/helpers/typeof");
|
|
5
|
-
Object.defineProperty(exports, "__esModule", {
|
|
6
|
-
value: true
|
|
7
|
-
});
|
|
8
|
-
exports["default"] = void 0;
|
|
9
|
-
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
10
|
-
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
11
|
-
var _react = _interopRequireDefault(require("react"));
|
|
12
|
-
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
13
|
-
var _variables = require("../common/variables");
|
|
14
|
-
var _utils = require("../common/utils");
|
|
15
|
-
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
16
|
-
var _templateObject, _templateObject2, _templateObject3;
|
|
17
|
-
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
18
|
-
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof3(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
19
|
-
var DxcButton = function DxcButton(_ref) {
|
|
20
|
-
var _ref$label = _ref.label,
|
|
21
|
-
label = _ref$label === void 0 ? "" : _ref$label,
|
|
22
|
-
_ref$mode = _ref.mode,
|
|
23
|
-
mode = _ref$mode === void 0 ? "primary" : _ref$mode,
|
|
24
|
-
_ref$disabled = _ref.disabled,
|
|
25
|
-
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
26
|
-
_ref$iconPosition = _ref.iconPosition,
|
|
27
|
-
iconPosition = _ref$iconPosition === void 0 ? "before" : _ref$iconPosition,
|
|
28
|
-
title = _ref.title,
|
|
29
|
-
_ref$type = _ref.type,
|
|
30
|
-
type = _ref$type === void 0 ? "button" : _ref$type,
|
|
31
|
-
icon = _ref.icon,
|
|
32
|
-
_ref$onClick = _ref.onClick,
|
|
33
|
-
_onClick = _ref$onClick === void 0 ? function () {} : _ref$onClick,
|
|
34
|
-
margin = _ref.margin,
|
|
35
|
-
_ref$size = _ref.size,
|
|
36
|
-
size = _ref$size === void 0 ? "fitContent" : _ref$size,
|
|
37
|
-
_ref$tabIndex = _ref.tabIndex,
|
|
38
|
-
tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex;
|
|
39
|
-
var colorsTheme = (0, _useTheme["default"])();
|
|
40
|
-
return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
|
|
41
|
-
theme: colorsTheme.button
|
|
42
|
-
}, /*#__PURE__*/_react["default"].createElement(Button, {
|
|
43
|
-
"aria-label": title,
|
|
44
|
-
disabled: disabled,
|
|
45
|
-
onClick: function onClick() {
|
|
46
|
-
_onClick();
|
|
47
|
-
},
|
|
48
|
-
tabIndex: disabled ? -1 : tabIndex,
|
|
49
|
-
title: title,
|
|
50
|
-
type: type,
|
|
51
|
-
$mode: mode !== "primary" && mode !== "secondary" && mode !== "text" ? "primary" : mode,
|
|
52
|
-
hasLabel: label ? true : false,
|
|
53
|
-
hasIcon: icon ? true : false,
|
|
54
|
-
iconPosition: iconPosition,
|
|
55
|
-
size: size,
|
|
56
|
-
margin: margin
|
|
57
|
-
}, label && /*#__PURE__*/_react["default"].createElement(LabelContainer, null, label), icon && /*#__PURE__*/_react["default"].createElement(IconContainer, null, typeof icon === "string" ? /*#__PURE__*/_react["default"].createElement("img", {
|
|
58
|
-
src: icon
|
|
59
|
-
}) : icon)));
|
|
60
|
-
};
|
|
61
|
-
var sizes = {
|
|
62
|
-
small: "42px",
|
|
63
|
-
medium: "120px",
|
|
64
|
-
large: "240px",
|
|
65
|
-
fillParent: "100%",
|
|
66
|
-
fitContent: "fit-content"
|
|
67
|
-
};
|
|
68
|
-
var calculateWidth = function calculateWidth(margin, size) {
|
|
69
|
-
return size === "fillParent" ? "calc(".concat(sizes[size], " - ").concat((0, _utils.getMargin)(margin, "left"), " - ").concat((0, _utils.getMargin)(margin, "right"), ")") : sizes[size];
|
|
70
|
-
};
|
|
71
|
-
var getButtonStyles = function getButtonStyles($mode, theme) {
|
|
72
|
-
return "\n border-color: ".concat($mode === "secondary" ? theme.secondaryBorderColor : "", ";\n border-radius: ").concat($mode === "primary" ? theme.primaryBorderRadius : $mode === "secondary" ? theme.secondaryBorderRadius : theme.textBorderRadius, ";\n border-width: ").concat($mode === "primary" ? theme.primaryBorderThickness : $mode === "secondary" ? theme.secondaryBorderThickness : theme.textBorderThickness, ";\n border-style: ").concat($mode === "primary" ? theme.primaryBorderStyle : $mode === "secondary" ? theme.secondaryBorderStyle : theme.textBorderStyle, ";\n font-family: ").concat($mode === "primary" ? theme.primaryFontFamily : $mode === "secondary" ? theme.secondaryFontFamily : theme.textFontFamily, ";\n font-size: ").concat($mode === "primary" ? theme.primaryFontSize : $mode === "secondary" ? theme.secondaryFontSize : theme.textFontSize, ";\n font-weight: ").concat($mode === "primary" ? theme.primaryFontWeight : $mode === "secondary" ? theme.secondaryFontWeight : theme.textFontWeight, ";\n background-color: ").concat($mode === "primary" ? theme.primaryBackgroundColor : $mode === "secondary" ? theme.secondaryBackgroundColor : theme.textBackgroundColor, ";\n color: ").concat($mode === "primary" ? theme.primaryFontColor : $mode === "secondary" ? theme.secondaryFontColor : theme.textFontColor, ";\n ");
|
|
73
|
-
};
|
|
74
|
-
var getButtonStates = function getButtonStates(disabled, $mode, theme) {
|
|
75
|
-
return "\n &:hover {\n background-color: ".concat($mode === "primary" ? theme.primaryHoverBackgroundColor : $mode === "secondary" ? theme.secondaryHoverBackgroundColor : theme.textHoverBackgroundColor, ";\n color: ").concat($mode === "secondary" ? theme.secondaryHoverFontColor : "", ";\n }\n &:focus {\n border-color: ").concat($mode === "secondary" ? "transparent" : "", ";\n }\n &:active {\n background-color: ").concat($mode === "primary" ? theme.primaryActiveBackgroundColor : $mode === "secondary" ? theme.secondaryActiveBackgroundColor : theme.textActiveBackgroundColor, ";\n color: ").concat($mode === "secondary" ? theme.secondaryHoverFontColor : "", ";\n border-color: ").concat($mode === "secondary" ? "transparent" : "", ";\n outline: none;\n box-shadow: ").concat(!disabled ? "0 0 0 2px ".concat(theme.focusBorderColor) : "", ";\n }\n &:disabled {\n cursor: not-allowed;\n background-color: ").concat($mode === "primary" ? theme.primaryDisabledBackgroundColor : $mode === "secondary" ? theme.secondaryDisabledBackgroundColor : theme.textDisabledBackgroundColor, ";\n color: ").concat($mode === "primary" ? theme.primaryDisabledFontColor : $mode === "secondary" ? theme.secondaryDisabledFontColor : theme.textDisabledFontColor, ";\n border-color: ").concat($mode === "secondary" ? theme.secondaryDisabledBorderColor : "", ";\n }\n");
|
|
76
|
-
};
|
|
77
|
-
var Button = _styledComponents["default"].button(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n display: inline-flex;\n flex-direction: ", ";\n gap: 0.5rem;\n align-items: center;\n justify-content: center;\n width: ", ";\n height: 40px;\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n padding-top: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n box-shadow: 0 0 0 2px transparent;\n font-family: ", ";\n font-size: ", ";\n font-weight: ", ";\n letter-spacing: ", ";\n cursor: pointer;\n\n &:focus {\n outline: none;\n box-shadow: 0 0 0 2px ", ";\n }\n\n ", "\n ", "\n"])), function (props) {
|
|
78
|
-
return props.iconPosition === "after" ? "row" : "row-reverse";
|
|
79
|
-
}, function (props) {
|
|
80
|
-
return calculateWidth(props.margin, props.size);
|
|
81
|
-
}, function (props) {
|
|
82
|
-
return props.margin && (0, _typeof2["default"])(props.margin) !== "object" ? _variables.spaces[props.margin] : "0px";
|
|
83
|
-
}, function (props) {
|
|
84
|
-
return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.top ? _variables.spaces[props.margin.top] : "";
|
|
85
|
-
}, function (props) {
|
|
86
|
-
return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.right ? _variables.spaces[props.margin.right] : "";
|
|
87
|
-
}, function (props) {
|
|
88
|
-
return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.bottom ? _variables.spaces[props.margin.bottom] : "";
|
|
89
|
-
}, function (props) {
|
|
90
|
-
return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.left ? _variables.spaces[props.margin.left] : "";
|
|
91
|
-
}, function (props) {
|
|
92
|
-
return props.theme.paddingTop;
|
|
93
|
-
}, function (props) {
|
|
94
|
-
return props.theme.paddingBottom;
|
|
95
|
-
}, function (props) {
|
|
96
|
-
return props.hasIcon && !props.hasLabel ? props.theme.paddingLeft : "calc(".concat(props.theme.paddingLeft, " + 8px)");
|
|
97
|
-
}, function (props) {
|
|
98
|
-
return props.hasIcon && !props.hasLabel ? props.theme.paddingRight : "calc(".concat(props.theme.paddingRight, " + 8px)");
|
|
99
|
-
}, function (props) {
|
|
100
|
-
return props.theme.fontFamily;
|
|
101
|
-
}, function (props) {
|
|
102
|
-
return props.theme.fontSize;
|
|
103
|
-
}, function (props) {
|
|
104
|
-
return props.theme.fontWeight;
|
|
105
|
-
}, function (props) {
|
|
106
|
-
return props.theme.labelLetterSpacing;
|
|
107
|
-
}, function (props) {
|
|
108
|
-
return props.theme.focusBorderColor;
|
|
109
|
-
}, function (props) {
|
|
110
|
-
return getButtonStyles(props.$mode, props.theme);
|
|
111
|
-
}, function (props) {
|
|
112
|
-
return getButtonStates(props.disabled, props.$mode, props.theme);
|
|
113
|
-
});
|
|
114
|
-
var LabelContainer = _styledComponents["default"].span(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n line-height: ", ";\n font-size: ", ";\n text-overflow: ellipsis;\n overflow: hidden;\n text-transform: none;\n white-space: nowrap;\n"])), function (props) {
|
|
115
|
-
return props.theme.labelFontLineHeight;
|
|
116
|
-
}, function (props) {
|
|
117
|
-
return props.theme.fontSize;
|
|
118
|
-
});
|
|
119
|
-
var IconContainer = _styledComponents["default"].div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n\n img,\n svg {\n height: 24px;\n width: 24px;\n }\n"])));
|
|
120
|
-
var _default = exports["default"] = DxcButton;
|