@dxc-technology/halstack-react 0.0.0-da4b2be → 0.0.0-da9270d
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/BackgroundColorContext.d.ts +1 -10
- package/BackgroundColorContext.js +4 -21
- package/HalstackContext.d.ts +23 -124
- package/HalstackContext.js +10 -35
- package/README.md +47 -0
- package/accordion/Accordion.d.ts +1 -1
- package/accordion/Accordion.js +24 -76
- package/accordion/Accordion.stories.tsx +1 -113
- package/accordion/Accordion.test.js +18 -33
- package/accordion/types.d.ts +5 -17
- package/accordion-group/AccordionGroup.js +15 -42
- package/accordion-group/AccordionGroup.stories.tsx +78 -77
- package/accordion-group/AccordionGroup.test.js +43 -71
- package/accordion-group/AccordionGroupAccordion.js +9 -21
- package/accordion-group/types.d.ts +6 -18
- package/alert/Alert.js +15 -50
- package/alert/Alert.test.js +28 -45
- package/alert/types.d.ts +5 -5
- package/badge/Badge.js +4 -17
- package/badge/types.d.ts +1 -1
- package/bleed/Bleed.js +13 -21
- package/bleed/types.d.ts +2 -2
- package/box/Box.js +11 -33
- package/box/Box.test.js +1 -6
- package/box/types.d.ts +3 -3
- package/bulleted-list/BulletedList.js +18 -54
- package/bulleted-list/BulletedList.stories.tsx +1 -92
- package/bulleted-list/types.d.ts +5 -5
- package/button/Button.d.ts +1 -1
- package/button/Button.js +66 -99
- package/button/Button.stories.tsx +6 -87
- package/button/Button.test.js +17 -16
- package/button/types.d.ts +8 -4
- package/card/Card.d.ts +1 -1
- package/card/Card.js +39 -79
- package/card/Card.stories.tsx +0 -29
- package/card/Card.test.js +10 -21
- package/card/types.d.ts +6 -12
- package/checkbox/Checkbox.js +85 -120
- package/checkbox/Checkbox.stories.tsx +16 -54
- package/checkbox/Checkbox.test.js +107 -63
- package/checkbox/types.d.ts +8 -4
- package/chip/Chip.js +12 -31
- package/chip/Chip.stories.tsx +1 -1
- package/chip/Chip.test.js +15 -28
- package/chip/types.d.ts +4 -4
- package/common/coreTokens.d.ts +105 -14
- package/common/coreTokens.js +41 -24
- package/common/utils.js +2 -8
- package/common/variables.d.ts +23 -124
- package/common/variables.js +27 -135
- package/container/Container.d.ts +4 -0
- package/container/Container.js +194 -0
- package/container/Container.stories.tsx +214 -0
- package/container/types.d.ts +74 -0
- package/date-input/Calendar.js +15 -59
- package/date-input/DateInput.js +50 -96
- package/date-input/DateInput.stories.tsx +11 -30
- package/date-input/DateInput.test.js +674 -701
- package/date-input/DatePicker.js +11 -42
- package/date-input/Icons.d.ts +6 -6
- package/date-input/Icons.js +6 -23
- package/date-input/YearPicker.js +8 -34
- package/date-input/types.d.ts +27 -21
- package/dialog/Dialog.js +13 -40
- package/dialog/Dialog.stories.tsx +170 -0
- package/dialog/Dialog.test.js +125 -187
- package/dialog/types.d.ts +18 -13
- package/dropdown/Dropdown.js +39 -93
- package/dropdown/Dropdown.test.js +391 -378
- package/dropdown/DropdownMenu.js +8 -19
- package/dropdown/DropdownMenuItem.js +5 -17
- package/dropdown/types.d.ts +17 -19
- package/file-input/FileInput.js +180 -248
- package/file-input/FileInput.stories.tsx +1 -1
- package/file-input/FileInput.test.js +356 -354
- package/file-input/FileItem.js +14 -41
- package/file-input/types.d.ts +10 -10
- package/flex/Flex.js +25 -39
- package/flex/types.d.ts +6 -6
- package/footer/Footer.d.ts +1 -1
- package/footer/Footer.js +54 -112
- package/footer/Footer.stories.tsx +19 -95
- package/footer/Footer.test.js +21 -33
- package/footer/Icons.d.ts +2 -2
- package/footer/Icons.js +2 -7
- package/footer/types.d.ts +21 -29
- package/grid/Grid.d.ts +1 -1
- package/grid/Grid.js +2 -17
- package/grid/Grid.stories.tsx +38 -38
- package/grid/types.d.ts +10 -10
- package/header/Header.d.ts +2 -2
- package/header/Header.js +31 -114
- package/header/Header.stories.tsx +7 -71
- package/header/Header.test.js +12 -25
- package/header/Icons.d.ts +2 -2
- package/header/Icons.js +2 -7
- package/header/types.d.ts +5 -20
- package/heading/Heading.js +9 -31
- package/heading/Heading.test.js +70 -87
- package/heading/types.d.ts +7 -7
- package/image/Image.d.ts +4 -0
- package/image/Image.js +70 -0
- package/image/Image.stories.tsx +127 -0
- package/image/types.d.ts +72 -0
- package/inset/Inset.js +13 -21
- package/inset/types.d.ts +2 -2
- package/layout/ApplicationLayout.d.ts +3 -3
- package/layout/ApplicationLayout.js +28 -65
- package/layout/ApplicationLayout.stories.tsx +1 -1
- package/layout/Icons.d.ts +8 -5
- package/layout/Icons.js +51 -59
- package/layout/SidenavContext.d.ts +1 -1
- package/layout/SidenavContext.js +3 -9
- package/layout/types.d.ts +3 -3
- package/link/Link.js +21 -42
- package/link/Link.test.js +23 -41
- package/link/types.d.ts +14 -14
- package/main.d.ts +4 -3
- package/main.js +17 -58
- package/nav-tabs/NavTabs.js +11 -43
- package/nav-tabs/NavTabs.stories.tsx +1 -1
- package/nav-tabs/NavTabs.test.js +36 -43
- package/nav-tabs/Tab.js +16 -45
- package/nav-tabs/types.d.ts +9 -9
- package/number-input/NumberInput.d.ts +7 -0
- package/number-input/NumberInput.js +26 -35
- package/number-input/NumberInput.stories.tsx +42 -26
- package/number-input/NumberInput.test.js +700 -412
- package/number-input/types.d.ts +11 -5
- package/package.json +30 -28
- package/paginator/Icons.d.ts +5 -5
- package/paginator/Icons.js +5 -19
- package/paginator/Paginator.js +15 -43
- package/paginator/Paginator.test.js +224 -207
- package/paginator/types.d.ts +3 -3
- package/paragraph/Paragraph.js +3 -19
- package/paragraph/Paragraph.stories.tsx +0 -17
- package/password-input/Icons.d.ts +6 -0
- package/password-input/Icons.js +35 -0
- package/password-input/PasswordInput.js +57 -126
- package/password-input/PasswordInput.stories.tsx +1 -33
- package/password-input/PasswordInput.test.js +157 -140
- package/password-input/types.d.ts +8 -7
- package/progress-bar/ProgressBar.js +21 -53
- package/progress-bar/{ProgressBar.stories.jsx → ProgressBar.stories.tsx} +1 -1
- package/progress-bar/ProgressBar.test.js +35 -52
- package/progress-bar/types.d.ts +3 -3
- package/quick-nav/QuickNav.js +4 -27
- package/quick-nav/QuickNav.stories.tsx +1 -1
- package/quick-nav/types.d.ts +10 -10
- package/radio-group/Radio.d.ts +1 -1
- package/radio-group/Radio.js +22 -54
- package/radio-group/RadioGroup.js +37 -83
- package/radio-group/RadioGroup.stories.tsx +10 -10
- package/radio-group/RadioGroup.test.js +504 -470
- package/radio-group/types.d.ts +8 -8
- package/resultset-table/Icons.d.ts +7 -0
- package/{resultsetTable → resultset-table}/Icons.js +1 -5
- package/{resultsetTable → resultset-table}/ResultsetTable.js +23 -59
- package/{resultsetTable → resultset-table}/ResultsetTable.test.js +72 -92
- package/{resultsetTable → resultset-table}/types.d.ts +7 -7
- package/resultset-table/types.js +5 -0
- package/select/Icons.d.ts +7 -7
- package/select/Icons.js +1 -5
- package/select/Listbox.js +13 -39
- package/select/Option.js +9 -26
- package/select/Select.js +70 -155
- package/select/Select.stories.tsx +3 -3
- package/select/Select.test.js +1946 -1804
- package/select/types.d.ts +14 -15
- package/sidenav/Icons.d.ts +4 -4
- package/sidenav/Icons.js +1 -5
- package/sidenav/Sidenav.js +26 -68
- package/sidenav/Sidenav.test.js +3 -10
- package/sidenav/types.d.ts +18 -18
- package/slider/Slider.js +68 -125
- package/slider/Slider.test.js +107 -103
- package/slider/types.d.ts +4 -4
- package/spinner/Spinner.js +16 -54
- package/spinner/Spinner.test.js +25 -34
- package/spinner/types.d.ts +3 -3
- package/switch/Switch.js +49 -97
- package/switch/Switch.stories.tsx +0 -34
- package/switch/Switch.test.js +51 -96
- package/switch/types.d.ts +4 -4
- package/table/Table.js +5 -27
- package/table/Table.test.js +1 -6
- package/table/types.d.ts +8 -8
- package/tabs/Tab.js +10 -29
- package/tabs/Tabs.js +52 -129
- package/tabs/Tabs.test.js +62 -118
- package/tabs/types.d.ts +19 -19
- package/tag/Tag.js +21 -51
- package/tag/Tag.test.js +19 -30
- package/tag/types.d.ts +7 -7
- package/text-input/Icons.d.ts +5 -5
- package/text-input/Icons.js +1 -5
- package/text-input/Suggestion.js +9 -26
- package/text-input/Suggestions.d.ts +1 -1
- package/text-input/Suggestions.js +15 -65
- package/text-input/TextInput.js +204 -284
- package/text-input/TextInput.stories.tsx +48 -152
- package/text-input/TextInput.test.js +1210 -1194
- package/text-input/types.d.ts +25 -17
- package/textarea/Textarea.js +67 -109
- package/textarea/{Textarea.stories.jsx → Textarea.stories.tsx} +58 -100
- package/textarea/Textarea.test.js +150 -179
- package/textarea/types.d.ts +9 -5
- package/toggle-group/ToggleGroup.js +90 -107
- package/toggle-group/ToggleGroup.stories.tsx +7 -4
- package/toggle-group/ToggleGroup.test.js +68 -87
- package/toggle-group/types.d.ts +26 -17
- package/typography/Typography.js +4 -13
- package/typography/types.d.ts +1 -1
- package/useTheme.d.ts +20 -121
- package/useTheme.js +1 -8
- package/useTranslatedLabels.js +1 -7
- package/utils/BaseTypography.d.ts +2 -2
- package/utils/BaseTypography.js +16 -30
- package/utils/FocusLock.js +22 -39
- package/wizard/Wizard.js +14 -49
- package/wizard/Wizard.test.js +53 -80
- package/wizard/types.d.ts +6 -6
- package/card/ice-cream.jpg +0 -0
- package/number-input/NumberInputContext.d.ts +0 -4
- package/number-input/NumberInputContext.js +0 -19
- package/number-input/numberInputContextTypes.d.ts +0 -19
- package/resultsetTable/Icons.d.ts +0 -7
- package/slider/Slider.stories.tsx +0 -240
- /package/{resultsetTable → container}/types.js +0 -0
- /package/{number-input/numberInputContextTypes.js → image/types.js} +0 -0
- /package/{resultsetTable → resultset-table}/ResultsetTable.d.ts +0 -0
- /package/{resultsetTable → resultset-table}/ResultsetTable.stories.tsx +0 -0
- /package/spinner/{Spinner.stories.jsx → Spinner.stories.tsx} +0 -0
- /package/table/{Table.stories.jsx → Table.stories.tsx} +0 -0
package/file-input/FileItem.js
CHANGED
|
@@ -1,32 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
6
|
-
|
|
7
5
|
Object.defineProperty(exports, "__esModule", {
|
|
8
6
|
value: true
|
|
9
7
|
});
|
|
10
8
|
exports["default"] = void 0;
|
|
11
|
-
|
|
12
9
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
13
|
-
|
|
14
10
|
var _react = _interopRequireDefault(require("react"));
|
|
15
|
-
|
|
16
11
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
17
|
-
|
|
18
|
-
var _main = require("../main");
|
|
19
|
-
|
|
12
|
+
var _Flex = _interopRequireDefault(require("../flex/Flex"));
|
|
20
13
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
21
|
-
|
|
22
14
|
var _useTranslatedLabels = _interopRequireDefault(require("../useTranslatedLabels"));
|
|
23
|
-
|
|
24
15
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8;
|
|
25
|
-
|
|
26
|
-
function
|
|
27
|
-
|
|
28
|
-
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; }
|
|
29
|
-
|
|
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; }
|
|
30
18
|
var deleteIcon = /*#__PURE__*/_react["default"].createElement("svg", {
|
|
31
19
|
xmlns: "http://www.w3.org/2000/svg",
|
|
32
20
|
width: "24",
|
|
@@ -39,7 +27,6 @@ var deleteIcon = /*#__PURE__*/_react["default"].createElement("svg", {
|
|
|
39
27
|
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
40
28
|
d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z"
|
|
41
29
|
}));
|
|
42
|
-
|
|
43
30
|
var errorIcon = /*#__PURE__*/_react["default"].createElement("svg", {
|
|
44
31
|
xmlns: "http://www.w3.org/2000/svg",
|
|
45
32
|
height: "24px",
|
|
@@ -49,25 +36,22 @@ var errorIcon = /*#__PURE__*/_react["default"].createElement("svg", {
|
|
|
49
36
|
}, /*#__PURE__*/_react["default"].createElement("path", {
|
|
50
37
|
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"
|
|
51
38
|
}));
|
|
52
|
-
|
|
53
39
|
var FileItem = function FileItem(_ref) {
|
|
54
40
|
var _ref$fileName = _ref.fileName,
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
41
|
+
fileName = _ref$fileName === void 0 ? "" : _ref$fileName,
|
|
42
|
+
_ref$error = _ref.error,
|
|
43
|
+
error = _ref$error === void 0 ? "" : _ref$error,
|
|
44
|
+
singleFileMode = _ref.singleFileMode,
|
|
45
|
+
showPreview = _ref.showPreview,
|
|
46
|
+
preview = _ref.preview,
|
|
47
|
+
type = _ref.type,
|
|
48
|
+
onDelete = _ref.onDelete,
|
|
49
|
+
tabIndex = _ref.tabIndex;
|
|
64
50
|
var colorsTheme = (0, _useTheme["default"])();
|
|
65
51
|
var translatedLabels = (0, _useTranslatedLabels["default"])();
|
|
66
|
-
|
|
67
52
|
var getIconAriaLabel = function getIconAriaLabel() {
|
|
68
53
|
if (type.includes("video")) return "video";else if (type.includes("audio")) return "audio";else return "file";
|
|
69
54
|
};
|
|
70
|
-
|
|
71
55
|
return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
|
|
72
56
|
theme: colorsTheme.fileInput
|
|
73
57
|
}, /*#__PURE__*/_react["default"].createElement(MainContainer, {
|
|
@@ -80,7 +64,7 @@ var FileItem = function FileItem(_ref) {
|
|
|
80
64
|
}) : /*#__PURE__*/_react["default"].createElement(IconPreview, {
|
|
81
65
|
error: error,
|
|
82
66
|
"aria-label": getIconAriaLabel()
|
|
83
|
-
}, preview)), /*#__PURE__*/_react["default"].createElement(FileItemContent, null, /*#__PURE__*/_react["default"].createElement(FileName, null, fileName), /*#__PURE__*/_react["default"].createElement(
|
|
67
|
+
}, preview)), /*#__PURE__*/_react["default"].createElement(FileItemContent, null, /*#__PURE__*/_react["default"].createElement(FileName, null, fileName), /*#__PURE__*/_react["default"].createElement(_Flex["default"], {
|
|
84
68
|
gap: "0.25rem"
|
|
85
69
|
}, error && /*#__PURE__*/_react["default"].createElement(ErrorIcon, null, errorIcon), /*#__PURE__*/_react["default"].createElement(DeleteFileAction, {
|
|
86
70
|
onClick: function onClick() {
|
|
@@ -92,7 +76,6 @@ var FileItem = function FileItem(_ref) {
|
|
|
92
76
|
tabIndex: tabIndex
|
|
93
77
|
}, deleteIcon)), error && !singleFileMode && /*#__PURE__*/_react["default"].createElement(ErrorMessage, null, error))));
|
|
94
78
|
};
|
|
95
|
-
|
|
96
79
|
var MainContainer = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: border-box;\n display: flex;\n justify-content: center;\n gap: 0.75rem;\n width: ", ";\n padding: ", ";\n ", ";\n border-color: ", ";\n border-width: ", ";\n border-style: ", ";\n border-radius: ", ";\n"])), function (props) {
|
|
97
80
|
return props.singleFileMode ? "230px" : "320px";
|
|
98
81
|
}, function (props) {
|
|
@@ -108,17 +91,13 @@ var MainContainer = _styledComponents["default"].div(_templateObject || (_templa
|
|
|
108
91
|
}, function (props) {
|
|
109
92
|
return props.theme.fileItemBorderRadius;
|
|
110
93
|
});
|
|
111
|
-
|
|
112
94
|
var ImagePreview = _styledComponents["default"].img(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n width: 48px;\n height: 48px;\n border-radius: 2px;\n object-fit: contain;\n"])));
|
|
113
|
-
|
|
114
95
|
var IconPreview = _styledComponents["default"].span(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: ", ";\n width: 48px;\n height: 48px;\n padding: 15px;\n border-radius: 2px;\n color: ", ";\n\n svg {\n height: 18px;\n width: 18px;\n }\n"])), function (props) {
|
|
115
96
|
return props.error ? props.theme.errorFilePreviewBackgroundColor : props.theme.filePreviewBackgroundColor;
|
|
116
97
|
}, function (props) {
|
|
117
98
|
return props.error ? props.theme.errorFilePreviewIconColor : props.theme.filePreviewIconColor;
|
|
118
99
|
});
|
|
119
|
-
|
|
120
100
|
var FileItemContent = _styledComponents["default"].div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["\n flex-grow: 1;\n display: grid;\n grid-template-columns: auto min-content;\n grid-template-rows: min-content auto;\n column-gap: 0.25rem;\n"])));
|
|
121
|
-
|
|
122
101
|
var FileName = _styledComponents["default"].span(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n align-self: center;\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-weight: ", ";\n line-height: ", ";\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n"])), function (props) {
|
|
123
102
|
return props.theme.fileNameFontColor;
|
|
124
103
|
}, function (props) {
|
|
@@ -130,9 +109,7 @@ var FileName = _styledComponents["default"].span(_templateObject5 || (_templateO
|
|
|
130
109
|
}, function (props) {
|
|
131
110
|
return props.theme.fileItemLineHeight;
|
|
132
111
|
});
|
|
133
|
-
|
|
134
112
|
var ErrorIcon = _styledComponents["default"].span(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n flex-wrap: wrap;\n align-content: center;\n padding: 3px;\n height: 18px;\n width: 18px;\n color: #d0011b;\n"])));
|
|
135
|
-
|
|
136
113
|
var DeleteFileAction = _styledComponents["default"].button(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n flex-wrap: wrap;\n align-content: center;\n height: 24px;\n width: 24px;\n font-size: 1rem;\n font-family: ", ";\n border: 1px solid transparent;\n border-radius: 2px;\n background-color: transparent;\n box-shadow: 0 0 0 2px transparent;\n padding: 3px;\n cursor: pointer;\n color: ", ";\n\n svg {\n line-height: 18px;\n }\n &:hover {\n background-color: ", ";\n }\n &:focus,\n &:focus-visible {\n outline: none;\n box-shadow: 0 0 0 2px ", ";\n }\n &:active {\n background-color: ", ";\n }\n"])), function (props) {
|
|
137
114
|
return props.theme.fontFamily;
|
|
138
115
|
}, function (props) {
|
|
@@ -144,7 +121,6 @@ var DeleteFileAction = _styledComponents["default"].button(_templateObject7 || (
|
|
|
144
121
|
}, function (props) {
|
|
145
122
|
return props.theme.activeDeleteFileItemBackgroundColor;
|
|
146
123
|
});
|
|
147
|
-
|
|
148
124
|
var ErrorMessage = _styledComponents["default"].span(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2["default"])(["\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-weight: ", ";\n line-height: ", ";\n"])), function (props) {
|
|
149
125
|
return props.theme.errorMessageFontColor;
|
|
150
126
|
}, function (props) {
|
|
@@ -156,7 +132,4 @@ var ErrorMessage = _styledComponents["default"].span(_templateObject8 || (_templ
|
|
|
156
132
|
}, function (props) {
|
|
157
133
|
return props.theme.errorMessageLineHeight;
|
|
158
134
|
});
|
|
159
|
-
|
|
160
|
-
var _default = /*#__PURE__*/_react["default"].memo(FileItem);
|
|
161
|
-
|
|
162
|
-
exports["default"] = _default;
|
|
135
|
+
var _default = exports["default"] = /*#__PURE__*/_react["default"].memo(FileItem);
|
package/file-input/types.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
|
|
2
|
+
type Margin = {
|
|
3
3
|
top?: Space;
|
|
4
4
|
bottom?: Space;
|
|
5
5
|
left?: Space;
|
|
6
6
|
right?: Space;
|
|
7
7
|
};
|
|
8
|
-
|
|
8
|
+
export type FileData = {
|
|
9
9
|
/**
|
|
10
10
|
* Selected file.
|
|
11
11
|
*/
|
|
@@ -19,9 +19,9 @@ declare type FileData = {
|
|
|
19
19
|
*/
|
|
20
20
|
preview?: string;
|
|
21
21
|
};
|
|
22
|
-
|
|
22
|
+
type CommonProps = {
|
|
23
23
|
/**
|
|
24
|
-
* Name attribute.
|
|
24
|
+
* @deprecated Name attribute.
|
|
25
25
|
*/
|
|
26
26
|
name?: string;
|
|
27
27
|
/**
|
|
@@ -80,7 +80,7 @@ declare type CommonProps = {
|
|
|
80
80
|
*/
|
|
81
81
|
tabIndex?: number;
|
|
82
82
|
};
|
|
83
|
-
|
|
83
|
+
type DropModeProps = CommonProps & {
|
|
84
84
|
/**
|
|
85
85
|
* Uses one of the available file input modes:
|
|
86
86
|
* 'file': Files are selected by clicking the button and selecting it through the file explorer.
|
|
@@ -94,7 +94,7 @@ declare type DropModeProps = CommonProps & {
|
|
|
94
94
|
*/
|
|
95
95
|
dropAreaLabel?: string;
|
|
96
96
|
};
|
|
97
|
-
|
|
97
|
+
type FileModeProps = CommonProps & {
|
|
98
98
|
/**
|
|
99
99
|
* Uses one of the available file input modes:
|
|
100
100
|
* 'file': Files are selected by clicking the button and selecting it through the file explorer.
|
|
@@ -111,12 +111,12 @@ declare type FileModeProps = CommonProps & {
|
|
|
111
111
|
/**
|
|
112
112
|
* Reference to the component.
|
|
113
113
|
*/
|
|
114
|
-
export
|
|
115
|
-
|
|
114
|
+
export type RefType = HTMLDivElement;
|
|
115
|
+
type Props = DropModeProps | FileModeProps;
|
|
116
116
|
/**
|
|
117
117
|
* Single file item preview.
|
|
118
118
|
*/
|
|
119
|
-
export
|
|
119
|
+
export type FileItemProps = {
|
|
120
120
|
fileName?: string;
|
|
121
121
|
error?: string;
|
|
122
122
|
showPreview: boolean;
|
package/flex/Flex.js
CHANGED
|
@@ -1,46 +1,36 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports["default"] = void 0;
|
|
9
|
-
|
|
10
8
|
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
11
|
-
|
|
12
9
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
13
|
-
|
|
14
10
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
15
|
-
|
|
16
11
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
17
|
-
|
|
18
12
|
var _react = _interopRequireDefault(require("react"));
|
|
19
|
-
|
|
20
13
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
21
|
-
|
|
22
14
|
var _templateObject;
|
|
23
|
-
|
|
24
15
|
var _excluded = ["direction", "wrap", "gap", "order", "grow", "shrink", "basis", "children"],
|
|
25
|
-
|
|
26
|
-
|
|
16
|
+
_excluded2 = ["justifyContent", "alignItems", "alignContent", "alignSelf"];
|
|
27
17
|
var DxcFlex = function DxcFlex(_ref) {
|
|
28
18
|
var _ref$direction = _ref.direction,
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
19
|
+
direction = _ref$direction === void 0 ? "row" : _ref$direction,
|
|
20
|
+
_ref$wrap = _ref.wrap,
|
|
21
|
+
wrap = _ref$wrap === void 0 ? "nowrap" : _ref$wrap,
|
|
22
|
+
_ref$gap = _ref.gap,
|
|
23
|
+
gap = _ref$gap === void 0 ? "0rem" : _ref$gap,
|
|
24
|
+
_ref$order = _ref.order,
|
|
25
|
+
order = _ref$order === void 0 ? 0 : _ref$order,
|
|
26
|
+
_ref$grow = _ref.grow,
|
|
27
|
+
grow = _ref$grow === void 0 ? 0 : _ref$grow,
|
|
28
|
+
_ref$shrink = _ref.shrink,
|
|
29
|
+
shrink = _ref$shrink === void 0 ? 1 : _ref$shrink,
|
|
30
|
+
_ref$basis = _ref.basis,
|
|
31
|
+
basis = _ref$basis === void 0 ? "auto" : _ref$basis,
|
|
32
|
+
children = _ref.children,
|
|
33
|
+
props = (0, _objectWithoutProperties2["default"])(_ref, _excluded);
|
|
44
34
|
return /*#__PURE__*/_react["default"].createElement(Flex, (0, _extends2["default"])({
|
|
45
35
|
$direction: direction,
|
|
46
36
|
$wrap: wrap,
|
|
@@ -51,21 +41,17 @@ var DxcFlex = function DxcFlex(_ref) {
|
|
|
51
41
|
$gap: gap
|
|
52
42
|
}, props), children);
|
|
53
43
|
};
|
|
54
|
-
|
|
55
44
|
var Flex = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n ", "\n"])), function (_ref2) {
|
|
56
45
|
var _props$$gap, _props$$gap$rowGap, _props$$gap$columnGap;
|
|
57
|
-
|
|
58
46
|
var _ref2$justifyContent = _ref2.justifyContent,
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
47
|
+
justifyContent = _ref2$justifyContent === void 0 ? "flex-start" : _ref2$justifyContent,
|
|
48
|
+
_ref2$alignItems = _ref2.alignItems,
|
|
49
|
+
alignItems = _ref2$alignItems === void 0 ? "stretch" : _ref2$alignItems,
|
|
50
|
+
_ref2$alignContent = _ref2.alignContent,
|
|
51
|
+
alignContent = _ref2$alignContent === void 0 ? "normal" : _ref2$alignContent,
|
|
52
|
+
_ref2$alignSelf = _ref2.alignSelf,
|
|
53
|
+
alignSelf = _ref2$alignSelf === void 0 ? "auto" : _ref2$alignSelf,
|
|
54
|
+
props = (0, _objectWithoutProperties2["default"])(_ref2, _excluded2);
|
|
67
55
|
return "\n flex-direction: ".concat(props.$direction, "; \n flex-wrap: ").concat(props.$wrap, "; \n justify-content: ").concat(justifyContent, "; \n align-items: ").concat(alignItems, ";\n align-content: ").concat(alignContent, ";\n align-self: ").concat(alignSelf, ";\n gap: ").concat(props.$gap != null && typeof props.$gap === "string" ? (_props$$gap = props.$gap) !== null && _props$$gap !== void 0 ? _props$$gap : "" : "", "}\n row-gap: ").concat(props.$gap != null && (0, _typeof2["default"])(props.$gap) === "object" ? (_props$$gap$rowGap = props.$gap.rowGap) !== null && _props$$gap$rowGap !== void 0 ? _props$$gap$rowGap : "" : "", "}\n column-gap: ").concat(props.$gap != null && (0, _typeof2["default"])(props.$gap) === "object" ? (_props$$gap$columnGap = props.$gap.columnGap) !== null && _props$$gap$columnGap !== void 0 ? _props$$gap$columnGap : "" : "", "}\n order: ").concat(props.$order, ";\n flex-grow: ").concat(props.$grow, ";\n flex-shrink: ").concat(props.$shrink, ";\n flex-basis: ").concat(props.$basis, ";\n ");
|
|
68
56
|
});
|
|
69
|
-
|
|
70
|
-
var _default = DxcFlex;
|
|
71
|
-
exports["default"] = _default;
|
|
57
|
+
var _default = exports["default"] = DxcFlex;
|
package/flex/types.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
type Spaces = "0rem" | "0.125rem" | "0.25rem" | "0.5rem" | "1rem" | "1.5rem" | "2rem" | "3rem" | "4rem" | "5rem";
|
|
3
|
+
type Gap = {
|
|
4
4
|
rowGap: Spaces;
|
|
5
5
|
columnGap?: Spaces;
|
|
6
6
|
} | {
|
|
7
7
|
rowGap?: Spaces;
|
|
8
|
-
columnGap
|
|
8
|
+
columnGap: Spaces;
|
|
9
9
|
} | Spaces;
|
|
10
|
-
|
|
10
|
+
type CommonProps = {
|
|
11
11
|
/**
|
|
12
12
|
* Sets the justify-content CSS property.
|
|
13
13
|
*
|
|
@@ -33,7 +33,7 @@ declare type CommonProps = {
|
|
|
33
33
|
*/
|
|
34
34
|
alignSelf?: "auto" | "flex-start" | "flex-end" | "center" | "baseline" | "stretch";
|
|
35
35
|
};
|
|
36
|
-
|
|
36
|
+
type Props = CommonProps & {
|
|
37
37
|
/**
|
|
38
38
|
* Sets the flex-direction CSS property.
|
|
39
39
|
*
|
|
@@ -85,7 +85,7 @@ declare type Props = CommonProps & {
|
|
|
85
85
|
*/
|
|
86
86
|
children: React.ReactNode;
|
|
87
87
|
};
|
|
88
|
-
export
|
|
88
|
+
export type StyledProps = CommonProps & {
|
|
89
89
|
$direction?: "row" | "row-reverse" | "column" | "column-reverse";
|
|
90
90
|
$wrap?: "nowrap" | "wrap" | "wrap-reverse";
|
|
91
91
|
$gap?: Spaces | Gap;
|
package/footer/Footer.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import FooterPropsType from "./types";
|
|
3
|
-
declare const DxcFooter: ({ socialLinks, bottomLinks, copyright, children,
|
|
3
|
+
declare const DxcFooter: ({ socialLinks, bottomLinks, copyright, children, margin, tabIndex, }: FooterPropsType) => JSX.Element;
|
|
4
4
|
export default DxcFooter;
|
package/footer/Footer.js
CHANGED
|
@@ -1,125 +1,81 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
|
-
var _typeof3 = require("@babel/runtime/helpers/typeof");
|
|
6
|
-
|
|
4
|
+
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
7
5
|
Object.defineProperty(exports, "__esModule", {
|
|
8
6
|
value: true
|
|
9
7
|
});
|
|
10
8
|
exports["default"] = void 0;
|
|
11
|
-
|
|
12
|
-
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
13
|
-
|
|
14
9
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
15
|
-
|
|
16
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
17
|
-
|
|
18
11
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
19
|
-
|
|
20
12
|
var _variables = require("../common/variables");
|
|
21
|
-
|
|
22
13
|
var _useTheme = _interopRequireDefault(require("../useTheme"));
|
|
23
|
-
|
|
24
14
|
var _useTranslatedLabels = _interopRequireDefault(require("../useTranslatedLabels"));
|
|
25
|
-
|
|
26
|
-
var _BackgroundColorContext = require("../BackgroundColorContext");
|
|
27
|
-
|
|
28
15
|
var _Icons = require("./Icons");
|
|
29
|
-
|
|
30
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10
|
|
31
|
-
|
|
32
|
-
function
|
|
33
|
-
|
|
34
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof3(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; }
|
|
35
|
-
|
|
16
|
+
var _Flex = _interopRequireDefault(require("../flex/Flex"));
|
|
17
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
|
|
18
|
+
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); }
|
|
19
|
+
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; }
|
|
36
20
|
var DxcFooter = function DxcFooter(_ref) {
|
|
37
21
|
var socialLinks = _ref.socialLinks,
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex;
|
|
22
|
+
bottomLinks = _ref.bottomLinks,
|
|
23
|
+
copyright = _ref.copyright,
|
|
24
|
+
children = _ref.children,
|
|
25
|
+
margin = _ref.margin,
|
|
26
|
+
_ref$tabIndex = _ref.tabIndex,
|
|
27
|
+
tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex;
|
|
45
28
|
var colorsTheme = (0, _useTheme["default"])();
|
|
46
29
|
var translatedLabels = (0, _useTranslatedLabels["default"])();
|
|
47
30
|
var footerLogo = (0, _react.useMemo)(function () {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
31
|
+
return !colorsTheme.footer.logo ? _Icons.dxcLogo : typeof colorsTheme.footer.logo === "string" ? /*#__PURE__*/_react["default"].createElement(LogoImg, {
|
|
32
|
+
alt: translatedLabels.formFields.logoAlternativeText,
|
|
33
|
+
src: colorsTheme.footer.logo
|
|
34
|
+
}) : colorsTheme.footer.logo;
|
|
35
|
+
}, [colorsTheme]);
|
|
36
|
+
return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
|
|
37
|
+
theme: colorsTheme.footer
|
|
38
|
+
}, /*#__PURE__*/_react["default"].createElement(FooterContainer, {
|
|
39
|
+
margin: margin
|
|
40
|
+
}, /*#__PURE__*/_react["default"].createElement(_Flex["default"], {
|
|
41
|
+
justifyContent: "space-between",
|
|
42
|
+
alignItems: "center",
|
|
43
|
+
wrap: "wrap",
|
|
44
|
+
gap: "1.5rem"
|
|
45
|
+
}, /*#__PURE__*/_react["default"].createElement(LogoContainer, null, footerLogo), /*#__PURE__*/_react["default"].createElement(_Flex["default"], null, socialLinks === null || socialLinks === void 0 ? void 0 : socialLinks.map(function (link, index) {
|
|
62
46
|
return /*#__PURE__*/_react["default"].createElement(SocialAnchor, {
|
|
47
|
+
href: link.href,
|
|
63
48
|
tabIndex: tabIndex,
|
|
49
|
+
title: link.title,
|
|
50
|
+
"aria-label": link.title,
|
|
64
51
|
key: "social".concat(index).concat(link.href),
|
|
65
|
-
index: index
|
|
66
|
-
|
|
67
|
-
}, /*#__PURE__*/_react["default"].createElement(SocialIconContainer, null, typeof link.logo === "string" ? /*#__PURE__*/_react["default"].createElement(SocialIconImg, {
|
|
52
|
+
index: index
|
|
53
|
+
}, /*#__PURE__*/_react["default"].createElement(SocialIconContainer, null, typeof link.logo === "string" ? /*#__PURE__*/_react["default"].createElement("img", {
|
|
68
54
|
src: link.logo
|
|
69
55
|
}) : link.logo));
|
|
70
|
-
})
|
|
71
|
-
var bottomLink = bottomLinks === null || bottomLinks === void 0 ? void 0 : bottomLinks.map(function (link, index) {
|
|
56
|
+
}))), /*#__PURE__*/_react["default"].createElement(ChildComponents, null, children), /*#__PURE__*/_react["default"].createElement(BottomContainer, null, /*#__PURE__*/_react["default"].createElement(BottomLinks, null, bottomLinks === null || bottomLinks === void 0 ? void 0 : bottomLinks.map(function (link, index) {
|
|
72
57
|
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
73
58
|
key: "bottom".concat(index).concat(link.text)
|
|
74
59
|
}, /*#__PURE__*/_react["default"].createElement(BottomLink, {
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
}, link
|
|
78
|
-
});
|
|
79
|
-
return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
|
|
80
|
-
theme: colorsTheme.footer
|
|
81
|
-
}, /*#__PURE__*/_react["default"].createElement(FooterContainer, {
|
|
82
|
-
margin: margin
|
|
83
|
-
}, /*#__PURE__*/_react["default"].createElement(FooterHeader, null, /*#__PURE__*/_react["default"].createElement(LogoContainer, null, footerLogo), /*#__PURE__*/_react["default"].createElement(SocialLinkContainer, null, socialLink)), /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(ChildComponents, {
|
|
84
|
-
padding: padding
|
|
85
|
-
}, /*#__PURE__*/_react["default"].createElement(_BackgroundColorContext.BackgroundColorProvider, {
|
|
86
|
-
color: colorsTheme.footer.backgroundColor
|
|
87
|
-
}, children)), /*#__PURE__*/_react["default"].createElement(FooterFooter, {
|
|
88
|
-
className: "footerFooter"
|
|
89
|
-
}, /*#__PURE__*/_react["default"].createElement(BottomLinks, null, bottomLink), /*#__PURE__*/_react["default"].createElement(Copyright, null, copyright || translatedLabels.footer.copyrightText(new Date().getFullYear()))))));
|
|
60
|
+
href: link.href,
|
|
61
|
+
tabIndex: tabIndex
|
|
62
|
+
}, link.text));
|
|
63
|
+
})), /*#__PURE__*/_react["default"].createElement(Copyright, null, copyright || translatedLabels.footer.copyrightText(new Date().getFullYear())))));
|
|
90
64
|
};
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
return props.theme.backgroundColor;
|
|
65
|
+
var FooterContainer = _styledComponents["default"].footer(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n width: 100%;\n min-height: ", ";\n margin-top: ", ";\n background-color: ", ";\n\n @media (min-width: ", "rem) {\n padding: 24px 36px 24px 36px;\n }\n @media (max-width: ", "rem) {\n padding: 20px;\n }\n"])), function (props) {
|
|
66
|
+
return props.theme.height;
|
|
94
67
|
}, function (props) {
|
|
95
|
-
return props.margin
|
|
68
|
+
return props.margin ? _variables.spaces[props.margin] : "0px";
|
|
96
69
|
}, function (props) {
|
|
97
|
-
return props.theme.
|
|
98
|
-
});
|
|
99
|
-
|
|
100
|
-
var FooterHeader = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n justify-content: space-between;\n flex-wrap: wrap;\n row-gap: 24px;\n"])));
|
|
101
|
-
|
|
102
|
-
var FooterFooter = _styledComponents["default"].div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n justify-content: space-between;\n align-items: flex-end;\n\n @media (min-width: ", "rem) {\n flex-direction: row;\n }\n\n @media (max-width: ", "rem) {\n flex-direction: column;\n align-items: center;\n }\n\n border-top: ", ";\n margin-top: 16px;\n"])), _variables.responsiveSizes.small, _variables.responsiveSizes.small, function (props) {
|
|
70
|
+
return props.theme.backgroundColor;
|
|
71
|
+
}, _variables.responsiveSizes.small, _variables.responsiveSizes.small);
|
|
72
|
+
var BottomContainer = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n justify-content: space-between;\n align-items: flex-end;\n\n @media (min-width: ", "rem) {\n flex-direction: row;\n }\n @media (max-width: ", "rem) {\n flex-direction: column;\n align-items: center;\n }\n\n border-top: ", ";\n margin-top: 16px;\n"])), _variables.responsiveSizes.small, _variables.responsiveSizes.small, function (props) {
|
|
103
73
|
return "".concat(props.theme.bottomLinksDividerThickness, " ").concat(props.theme.bottomLinksDividerStyle, " ").concat(props.theme.bottomLinksDividerColor);
|
|
104
74
|
});
|
|
105
|
-
|
|
106
|
-
var
|
|
75
|
+
var ChildComponents = _styledComponents["default"].div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n min-height: 16px;\n overflow: hidden;\n"])));
|
|
76
|
+
var Copyright = _styledComponents["default"].div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["\n padding-top: ", ";\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n\n @media (min-width: ", "rem) {\n max-width: 40%;\n text-align: right;\n }\n\n @media (max-width: ", "rem) {\n max-width: 100%;\n width: 100%;\n text-align: left;\n }\n"])), function (props) {
|
|
107
77
|
return props.theme.bottomLinksDividerSpacing;
|
|
108
|
-
}, _variables.responsiveSizes.small, _variables.responsiveSizes.small);
|
|
109
|
-
|
|
110
|
-
var ChildComponents = _styledComponents["default"].div(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n min-height: 16px;\n padding: ", ";\n padding-top: ", ";\n padding-right: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n overflow: hidden;\n"])), function (props) {
|
|
111
|
-
return props.padding && (0, _typeof2["default"])(props.padding) !== "object" ? _variables.spaces[props.padding] : "0px";
|
|
112
78
|
}, function (props) {
|
|
113
|
-
return props.padding && (0, _typeof2["default"])(props.padding) === "object" && props.padding.top ? _variables.spaces[props.padding.top] : "";
|
|
114
|
-
}, function (props) {
|
|
115
|
-
return props.padding && (0, _typeof2["default"])(props.padding) === "object" && props.padding.right ? _variables.spaces[props.padding.right] : "";
|
|
116
|
-
}, function (props) {
|
|
117
|
-
return props.padding && (0, _typeof2["default"])(props.padding) === "object" && props.padding.bottom ? _variables.spaces[props.padding.bottom] : "";
|
|
118
|
-
}, function (props) {
|
|
119
|
-
return props.padding && (0, _typeof2["default"])(props.padding) === "object" && props.padding.left ? _variables.spaces[props.padding.left] : "";
|
|
120
|
-
});
|
|
121
|
-
|
|
122
|
-
var Copyright = _styledComponents["default"].div(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n\n @media (min-width: ", "rem) {\n max-width: 40%;\n text-align: right;\n }\n\n @media (max-width: ", "rem) {\n max-width: 100%;\n width: 100%;\n text-align: left;\n }\n\n padding-top: ", ";\n"])), function (props) {
|
|
123
79
|
return props.theme.copyrightFontFamily;
|
|
124
80
|
}, function (props) {
|
|
125
81
|
return props.theme.copyrightFontSize;
|
|
@@ -129,43 +85,31 @@ var Copyright = _styledComponents["default"].div(_templateObject6 || (_templateO
|
|
|
129
85
|
return props.theme.copyrightFontWeight;
|
|
130
86
|
}, function (props) {
|
|
131
87
|
return props.theme.copyrightFontColor;
|
|
132
|
-
}, _variables.responsiveSizes.small, _variables.responsiveSizes.small
|
|
133
|
-
|
|
134
|
-
});
|
|
135
|
-
|
|
136
|
-
var LogoContainer = _styledComponents["default"].div(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2["default"])(["\n max-height: ", ";\n width: ", ";\n"])), function (props) {
|
|
88
|
+
}, _variables.responsiveSizes.small, _variables.responsiveSizes.small);
|
|
89
|
+
var LogoContainer = _styledComponents["default"].span(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n max-height: ", ";\n width: ", ";\n"])), function (props) {
|
|
137
90
|
return props.theme.logoHeight;
|
|
138
91
|
}, function (props) {
|
|
139
92
|
return props.theme.logoWidth;
|
|
140
93
|
});
|
|
141
|
-
|
|
142
|
-
var LogoImg = _styledComponents["default"].img(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2["default"])(["\n max-height: ", ";\n width: ", ";\n"])), function (props) {
|
|
94
|
+
var LogoImg = _styledComponents["default"].img(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n max-height: ", ";\n width: ", ";\n"])), function (props) {
|
|
143
95
|
return props.theme.logoHeight;
|
|
144
96
|
}, function (props) {
|
|
145
97
|
return props.theme.logoWidth;
|
|
146
98
|
});
|
|
147
|
-
|
|
148
|
-
var SocialLinkContainer = _styledComponents["default"].div(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-self: center;\n"])));
|
|
149
|
-
|
|
150
|
-
var SocialAnchor = _styledComponents["default"].a(_templateObject10 || (_templateObject10 = (0, _taggedTemplateLiteral2["default"])(["\n & {\n display: inline-flex;\n margin-left: ", ";\n }\n"])), function (props) {
|
|
99
|
+
var SocialAnchor = _styledComponents["default"].a(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2["default"])(["\n display: inline-flex;\n margin-left: ", ";\n border-radius: 4px;\n\n &:focus {\n outline: 2px solid #0095ff;\n outline-offset: 2px;\n }\n"])), function (props) {
|
|
151
100
|
return props.index === 0 ? "0px" : props.theme.socialLinksGutter;
|
|
152
101
|
});
|
|
153
|
-
|
|
154
|
-
var SocialIconImg = _styledComponents["default"].img(_templateObject11 || (_templateObject11 = (0, _taggedTemplateLiteral2["default"])([""])));
|
|
155
|
-
|
|
156
|
-
var SocialIconContainer = _styledComponents["default"].div(_templateObject12 || (_templateObject12 = (0, _taggedTemplateLiteral2["default"])(["\n & {\n display: inline-flex;\n height: ", ";\n width: ", ";\n color: ", ";\n }\n\n overflow: hidden;\n img,\n svg {\n height: 100%;\n width: 100%;\n }\n"])), function (props) {
|
|
102
|
+
var SocialIconContainer = _styledComponents["default"].div(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-items: center;\n height: ", ";\n width: ", ";\n color: ", ";\n overflow: hidden;\n\n img,\n svg {\n height: 100%;\n width: 100%;\n }\n"])), function (props) {
|
|
157
103
|
return props.theme.socialLinksSize;
|
|
158
104
|
}, function (props) {
|
|
159
105
|
return props.theme.socialLinksSize;
|
|
160
106
|
}, function (props) {
|
|
161
107
|
return props.theme.socialLinksColor;
|
|
162
108
|
});
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
})
|
|
167
|
-
|
|
168
|
-
var BottomLink = _styledComponents["default"].a(_templateObject14 || (_templateObject14 = (0, _taggedTemplateLiteral2["default"])(["\n text-decoration: ", ";\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n"])), function (props) {
|
|
109
|
+
var BottomLinks = _styledComponents["default"].div(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2["default"])(["\n display: inline-flex;\n flex-wrap: wrap;\n align-self: center;\n padding-top: ", ";\n color: #fff;\n\n @media (min-width: ", "rem) {\n max-width: 60%;\n }\n @media (max-width: ", "rem) {\n max-width: 100%;\n width: 100%;\n }\n\n & > span:not(:first-child):before {\n content: \"\xB7\";\n padding: 0 0.5rem;\n }\n"])), function (props) {
|
|
110
|
+
return props.theme.bottomLinksDividerSpacing;
|
|
111
|
+
}, _variables.responsiveSizes.small, _variables.responsiveSizes.small);
|
|
112
|
+
var BottomLink = _styledComponents["default"].a(_templateObject10 || (_templateObject10 = (0, _taggedTemplateLiteral2["default"])(["\n text-decoration: ", ";\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n border-radius: 2px;\n\n &:focus {\n outline: 2px solid #0095ff;\n }\n"])), function (props) {
|
|
169
113
|
return props.theme.bottomLinksTextDecoration;
|
|
170
114
|
}, function (props) {
|
|
171
115
|
return props.theme.bottomLinksFontColor;
|
|
@@ -178,6 +122,4 @@ var BottomLink = _styledComponents["default"].a(_templateObject14 || (_templateO
|
|
|
178
122
|
}, function (props) {
|
|
179
123
|
return props.theme.bottomLinksFontWeight;
|
|
180
124
|
});
|
|
181
|
-
|
|
182
|
-
var _default = DxcFooter;
|
|
183
|
-
exports["default"] = _default;
|
|
125
|
+
var _default = exports["default"] = DxcFooter;
|