@dxc-technology/halstack-react 0.0.0-509f1eb → 0.0.0-51152f3
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/HalstackContext.d.ts +16 -14
- package/action-icon/ActionIcon.d.ts +2 -2
- package/action-icon/ActionIcon.js +8 -4
- package/action-icon/ActionIcon.stories.tsx +41 -0
- package/action-icon/ActionIcon.test.js +64 -0
- package/badge/Badge.d.ts +1 -1
- package/badge/Badge.js +140 -29
- package/badge/Badge.stories.tsx +210 -0
- package/badge/Badge.test.js +30 -0
- package/badge/types.d.ts +52 -3
- package/button/Button.test.js +3 -1
- package/common/coreTokens.js +2 -2
- package/common/variables.d.ts +16 -14
- package/common/variables.js +22 -20
- package/container/Container.js +1 -1
- package/dropdown/Dropdown.js +9 -7
- package/footer/Footer.d.ts +1 -1
- package/footer/Footer.js +25 -12
- package/footer/Footer.stories.tsx +19 -0
- package/footer/Icons.d.ts +1 -0
- package/footer/Icons.js +65 -1
- package/footer/types.d.ts +6 -0
- package/layout/ApplicationLayout.d.ts +1 -1
- package/main.d.ts +3 -2
- package/main.js +8 -1
- package/nav-tabs/NavTabs.js +1 -1
- package/nav-tabs/NavTabs.stories.tsx +6 -4
- package/nav-tabs/NavTabs.test.js +3 -2
- package/nav-tabs/Tab.js +5 -4
- package/number-input/NumberInput.js +21 -2
- package/number-input/NumberInput.test.js +165 -6
- package/package.json +1 -1
- package/resultset-table/ResultsetTable.d.ts +4 -1
- package/resultset-table/ResultsetTable.js +14 -6
- package/resultset-table/ResultsetTable.stories.tsx +86 -5
- package/resultset-table/ResultsetTable.test.js +66 -0
- package/resultset-table/types.d.ts +6 -0
- package/status-light/StatusLight.d.ts +4 -0
- package/status-light/StatusLight.js +51 -0
- package/status-light/StatusLight.stories.tsx +74 -0
- package/status-light/StatusLight.test.js +25 -0
- package/status-light/types.d.ts +17 -0
- package/status-light/types.js +5 -0
- package/table/ActionsCell.d.ts +4 -0
- package/table/ActionsCell.js +55 -0
- package/table/DropdownTheme.js +58 -0
- package/table/Table.d.ts +4 -1
- package/table/Table.js +22 -5
- package/table/Table.stories.tsx +261 -2
- package/table/Table.test.js +92 -0
- package/table/types.d.ts +39 -0
- package/tabs/Tab.js +7 -4
- package/tabs/Tabs.stories.tsx +1 -1
- package/text-input/TextInput.js +28 -35
- package/text-input/TextInput.test.js +96 -79
- package/useTheme.d.ts +16 -14
- package/utils/FocusLock.js +3 -0
package/badge/types.d.ts
CHANGED
|
@@ -1,5 +1,54 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
type SVG = React.ReactNode & React.SVGProps<SVGSVGElement>;
|
|
3
|
+
type ContextualProps = {
|
|
4
|
+
/**
|
|
5
|
+
* Text to be placed in the badge.
|
|
6
|
+
*/
|
|
7
|
+
label: string;
|
|
8
|
+
/**
|
|
9
|
+
* The available badge modes.
|
|
10
|
+
*/
|
|
11
|
+
mode?: "contextual";
|
|
12
|
+
/**
|
|
13
|
+
* In notification mode, if the number entered as label is greater that this notification limit, +99 will be shown. If not, the entered text will be shown as label.
|
|
14
|
+
*/
|
|
15
|
+
notificationLimit?: never;
|
|
16
|
+
/**
|
|
17
|
+
* Affects the visual style of the badge. It can be used following semantic purposes or not.
|
|
18
|
+
*/
|
|
19
|
+
color?: "grey" | "blue" | "green" | "orange" | "red" | "yellow" | "purple";
|
|
4
20
|
};
|
|
21
|
+
type NotificationProps = {
|
|
22
|
+
/**
|
|
23
|
+
* Text to be placed in the badge.
|
|
24
|
+
*/
|
|
25
|
+
label?: number;
|
|
26
|
+
/**
|
|
27
|
+
* The available badge modes.
|
|
28
|
+
*/
|
|
29
|
+
mode: "notification";
|
|
30
|
+
/**
|
|
31
|
+
* In notification mode, if the number entered as label is greater that this notification limit, +99 will be shown. If not, the entered text will be shown as label.
|
|
32
|
+
*/
|
|
33
|
+
notificationLimit?: number;
|
|
34
|
+
/**
|
|
35
|
+
* Affects the visual style of the badge. It can be used following semantic purposes or not.
|
|
36
|
+
*/
|
|
37
|
+
color?: never;
|
|
38
|
+
};
|
|
39
|
+
type CommonProps = {
|
|
40
|
+
/**
|
|
41
|
+
* Text representing advisory information related to the badge. Under the hood, this prop also serves as an accessible label for the component.
|
|
42
|
+
*/
|
|
43
|
+
title?: string;
|
|
44
|
+
/**
|
|
45
|
+
* Element or path used as the icon that will be placed next to the badge label in contextual mode.
|
|
46
|
+
*/
|
|
47
|
+
icon?: string | SVG;
|
|
48
|
+
/**
|
|
49
|
+
* Size of the component.
|
|
50
|
+
*/
|
|
51
|
+
size?: "small" | "medium" | "large";
|
|
52
|
+
};
|
|
53
|
+
type Props = (ContextualProps | NotificationProps) & CommonProps;
|
|
5
54
|
export default Props;
|
package/button/Button.test.js
CHANGED
|
@@ -26,11 +26,13 @@ describe("Button component tests", function () {
|
|
|
26
26
|
test("Renders with correct accessibility attributes", function () {
|
|
27
27
|
var _render3 = (0, _react2.render)( /*#__PURE__*/_react["default"].createElement(_Button["default"], {
|
|
28
28
|
label: "Home",
|
|
29
|
-
title: "Go home"
|
|
29
|
+
title: "Go home",
|
|
30
|
+
tabIndex: 1
|
|
30
31
|
})),
|
|
31
32
|
getByRole = _render3.getByRole;
|
|
32
33
|
var button = getByRole("button");
|
|
33
34
|
expect(button.getAttribute("aria-label")).toBe("Go home");
|
|
34
35
|
expect(button.getAttribute("title")).toBe("Go home");
|
|
36
|
+
expect(button.getAttribute("tabindex")).toBe("1");
|
|
35
37
|
});
|
|
36
38
|
});
|
package/common/coreTokens.js
CHANGED
|
@@ -9,7 +9,7 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
9
9
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
10
10
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2["default"])(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
11
11
|
/**
|
|
12
|
-
* Halstack Color Palette
|
|
12
|
+
* Halstack Color Palette
|
|
13
13
|
* @link https://developer.dxc.com/halstack/next/principles/color/#color-tokens-core-color-tokens
|
|
14
14
|
*/
|
|
15
15
|
var CoreColorTokens = {
|
|
@@ -112,7 +112,7 @@ var getCoreColorToken = exports.getCoreColorToken = function getCoreColorToken(k
|
|
|
112
112
|
return CoreColorTokens[key];
|
|
113
113
|
};
|
|
114
114
|
/**
|
|
115
|
-
* Halstack Spacing Principles
|
|
115
|
+
* Halstack Spacing Principles
|
|
116
116
|
* @link https://developer.dxc.com/halstack/next/principles/spacing/
|
|
117
117
|
*/
|
|
118
118
|
var SpacingTokens = {
|
package/common/variables.d.ts
CHANGED
|
@@ -282,8 +282,14 @@ export declare const componentTokens: {
|
|
|
282
282
|
buttonPaddingBottom: string;
|
|
283
283
|
buttonPaddingLeft: string;
|
|
284
284
|
buttonPaddingRight: string;
|
|
285
|
+
buttonHeight: string;
|
|
286
|
+
buttonBorderRadius: string;
|
|
287
|
+
buttonBorderStyle: string;
|
|
288
|
+
buttonBorderThickness: string;
|
|
289
|
+
buttonBorderColor: string;
|
|
285
290
|
disabledColor: string;
|
|
286
291
|
disabledButtonBackgroundColor: string;
|
|
292
|
+
disabledButtonBorderColor: string;
|
|
287
293
|
disabledBorderColor: string;
|
|
288
294
|
optionBackgroundColor: string;
|
|
289
295
|
hoverOptionBackgroundColor: string;
|
|
@@ -865,6 +871,16 @@ export declare const componentTokens: {
|
|
|
865
871
|
scrollBarThumbColor: string;
|
|
866
872
|
scrollBarTrackColor: string;
|
|
867
873
|
sortIconColor: string;
|
|
874
|
+
actionIconColor: string;
|
|
875
|
+
disabledActionIconColor: string;
|
|
876
|
+
hoverActionIconColor: string;
|
|
877
|
+
focusActionIconColor: string;
|
|
878
|
+
activeActionIconColor: string;
|
|
879
|
+
actionBackgroundColor: string;
|
|
880
|
+
disabledActionBackgroundColor: string;
|
|
881
|
+
hoverActionBackgroundColor: string;
|
|
882
|
+
focusActionBorderColor: string;
|
|
883
|
+
activeActionBackgroundColor: string;
|
|
868
884
|
};
|
|
869
885
|
tabs: {
|
|
870
886
|
fontFamily: string;
|
|
@@ -883,7 +899,6 @@ export declare const componentTokens: {
|
|
|
883
899
|
disabledFontColor: string;
|
|
884
900
|
disabledIconColor: string;
|
|
885
901
|
disabledFontStyle: string;
|
|
886
|
-
disabledBadgeBackgroundColor: string;
|
|
887
902
|
hoverBackgroundColor: string;
|
|
888
903
|
pressedBackgroundColor: string;
|
|
889
904
|
pressedFontWeight: string;
|
|
@@ -891,19 +906,6 @@ export declare const componentTokens: {
|
|
|
891
906
|
dividerThickness: string;
|
|
892
907
|
focusOutline: string;
|
|
893
908
|
scrollButtonsWidth: string;
|
|
894
|
-
badgeBackgroundColor: string;
|
|
895
|
-
badgeFontFamily: string;
|
|
896
|
-
badgeFontSize: string;
|
|
897
|
-
badgeFontStyle: string;
|
|
898
|
-
badgeFontWeight: string;
|
|
899
|
-
badgeFontColor: string;
|
|
900
|
-
badgeLetterSpacing: string;
|
|
901
|
-
badgeWidth: string;
|
|
902
|
-
badgeHeight: string;
|
|
903
|
-
badgeRadius: string;
|
|
904
|
-
badgeWidthWithNotificationNumber: string;
|
|
905
|
-
badgeHeightWithNotificationNumber: string;
|
|
906
|
-
badgeRadiusWithNotificationNumber: string;
|
|
907
909
|
};
|
|
908
910
|
tag: {
|
|
909
911
|
fontFamily: string;
|
package/common/variables.js
CHANGED
|
@@ -290,8 +290,14 @@ var componentTokens = exports.componentTokens = {
|
|
|
290
290
|
buttonPaddingBottom: "0px",
|
|
291
291
|
buttonPaddingLeft: "16px",
|
|
292
292
|
buttonPaddingRight: "16px",
|
|
293
|
+
buttonHeight: "40px",
|
|
294
|
+
buttonBorderRadius: "4px",
|
|
295
|
+
buttonBorderStyle: _coreTokens["default"].border_none,
|
|
296
|
+
buttonBorderThickness: _coreTokens["default"].border_width_0,
|
|
297
|
+
buttonBorderColor: _coreTokens["default"].color_transparent,
|
|
293
298
|
disabledColor: _coreTokens["default"].color_grey_500,
|
|
294
299
|
disabledButtonBackgroundColor: _coreTokens["default"].color_transparent,
|
|
300
|
+
disabledButtonBorderColor: _coreTokens["default"].color_transparent,
|
|
295
301
|
disabledBorderColor: _coreTokens["default"].color_transparent,
|
|
296
302
|
optionBackgroundColor: _coreTokens["default"].color_white,
|
|
297
303
|
hoverOptionBackgroundColor: _coreTokens["default"].color_grey_100,
|
|
@@ -850,10 +856,10 @@ var componentTokens = exports.componentTokens = {
|
|
|
850
856
|
dataFontWeight: _coreTokens["default"].type_regular,
|
|
851
857
|
dataFontColor: _coreTokens["default"].color_black,
|
|
852
858
|
dataFontTextTransform: "none",
|
|
853
|
-
dataPaddingTop: "
|
|
854
|
-
dataPaddingBottom: "
|
|
859
|
+
dataPaddingTop: "16px",
|
|
860
|
+
dataPaddingBottom: "16px",
|
|
855
861
|
dataPaddingRight: "20px",
|
|
856
|
-
dataPaddingLeft: "
|
|
862
|
+
dataPaddingLeft: "20px",
|
|
857
863
|
dataTextAlign: "left",
|
|
858
864
|
dataTextLineHeight: "normal",
|
|
859
865
|
headerBackgroundColor: _coreTokens["default"].color_purple_700,
|
|
@@ -867,12 +873,22 @@ var componentTokens = exports.componentTokens = {
|
|
|
867
873
|
headerPaddingTop: "16px",
|
|
868
874
|
headerPaddingBottom: "16px",
|
|
869
875
|
headerPaddingRight: "20px",
|
|
870
|
-
headerPaddingLeft: "
|
|
876
|
+
headerPaddingLeft: "20px",
|
|
871
877
|
headerTextAlign: "left",
|
|
872
878
|
headerTextLineHeight: "normal",
|
|
873
879
|
scrollBarThumbColor: _coreTokens["default"].color_grey_700,
|
|
874
880
|
scrollBarTrackColor: _coreTokens["default"].color_grey_300,
|
|
875
|
-
sortIconColor: _coreTokens["default"].color_white
|
|
881
|
+
sortIconColor: _coreTokens["default"].color_white,
|
|
882
|
+
actionIconColor: _coreTokens["default"].color_purple_700,
|
|
883
|
+
disabledActionIconColor: _coreTokens["default"].color_grey_500,
|
|
884
|
+
hoverActionIconColor: _coreTokens["default"].color_purple_700,
|
|
885
|
+
focusActionIconColor: _coreTokens["default"].color_purple_700,
|
|
886
|
+
activeActionIconColor: _coreTokens["default"].color_purple_700,
|
|
887
|
+
actionBackgroundColor: _coreTokens["default"].color_transparent,
|
|
888
|
+
disabledActionBackgroundColor: _coreTokens["default"].color_transparent,
|
|
889
|
+
hoverActionBackgroundColor: _coreTokens["default"].color_grey_100,
|
|
890
|
+
focusActionBorderColor: _coreTokens["default"].color_blue_600,
|
|
891
|
+
activeActionBackgroundColor: _coreTokens["default"].color_grey_300
|
|
876
892
|
},
|
|
877
893
|
tabs: {
|
|
878
894
|
fontFamily: _coreTokens["default"].type_sans,
|
|
@@ -891,27 +907,13 @@ var componentTokens = exports.componentTokens = {
|
|
|
891
907
|
disabledFontColor: _coreTokens["default"].color_grey_500,
|
|
892
908
|
disabledIconColor: _coreTokens["default"].color_grey_500,
|
|
893
909
|
disabledFontStyle: _coreTokens["default"].type_normal,
|
|
894
|
-
disabledBadgeBackgroundColor: "#0000004d",
|
|
895
910
|
hoverBackgroundColor: _coreTokens["default"].color_purple_100,
|
|
896
911
|
pressedBackgroundColor: _coreTokens["default"].color_purple_200,
|
|
897
912
|
pressedFontWeight: _coreTokens["default"].type_semibold,
|
|
898
913
|
dividerColor: _coreTokens["default"].color_grey_400,
|
|
899
914
|
dividerThickness: "1px",
|
|
900
915
|
focusOutline: _coreTokens["default"].color_purple_700,
|
|
901
|
-
scrollButtonsWidth: "48px"
|
|
902
|
-
badgeBackgroundColor: _coreTokens["default"].color_red_700,
|
|
903
|
-
badgeFontFamily: _coreTokens["default"].type_sans,
|
|
904
|
-
badgeFontSize: "10px",
|
|
905
|
-
badgeFontStyle: _coreTokens["default"].type_normal,
|
|
906
|
-
badgeFontWeight: "500",
|
|
907
|
-
badgeFontColor: _coreTokens["default"].color_white,
|
|
908
|
-
badgeLetterSpacing: _coreTokens["default"].type_spacing_wide_02,
|
|
909
|
-
badgeWidth: "16px",
|
|
910
|
-
badgeHeight: "16px",
|
|
911
|
-
badgeRadius: "10px",
|
|
912
|
-
badgeWidthWithNotificationNumber: "23px",
|
|
913
|
-
badgeHeightWithNotificationNumber: "17px",
|
|
914
|
-
badgeRadiusWithNotificationNumber: "10px"
|
|
916
|
+
scrollButtonsWidth: "48px"
|
|
915
917
|
},
|
|
916
918
|
tag: {
|
|
917
919
|
fontFamily: _coreTokens["default"].type_sans,
|
package/container/Container.js
CHANGED
|
@@ -44,7 +44,7 @@ var getBorderStyles = function getBorderStyles(direction, borderProperties) {
|
|
|
44
44
|
var _borderProperties$wid, _borderProperties$sty, _getCoreColorToken;
|
|
45
45
|
return "border-".concat(direction, ": ").concat((_borderProperties$wid = borderProperties === null || borderProperties === void 0 ? void 0 : borderProperties.width) !== null && _borderProperties$wid !== void 0 ? _borderProperties$wid : "", " ").concat((_borderProperties$sty = borderProperties === null || borderProperties === void 0 ? void 0 : borderProperties.style) !== null && _borderProperties$sty !== void 0 ? _borderProperties$sty : "", " ").concat((_getCoreColorToken = (0, _coreTokens.getCoreColorToken)(borderProperties === null || borderProperties === void 0 ? void 0 : borderProperties.color)) !== null && _getCoreColorToken !== void 0 ? _getCoreColorToken : "", ";");
|
|
46
46
|
};
|
|
47
|
-
var Container = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: ", ";\n display: ", ";\n width: ", ";\n height: ", ";\n max-width: ", ";\n max-height: ", ";\n min-width: ", ";\n min-height: ", ";\n position: ", ";\n top: ", ";\n right: ", ";\n bottom: ", ";\n left: ", ";\n float: ", ";\n z-index: ", ";\n box-shadow: ", ";\n\n background-attachment: ", ";\n background-clip: ", ";\n background-color: ", ";\n background-image: ", ";\n background-origin: ", ";\n background-position: ", ";\n background-repeat: ", ";\n background-size: ", ";\n\n border-radius: ", ";\n border-width: ", ";\n border-style: ", ";\n border-
|
|
47
|
+
var Container = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: ", ";\n display: ", ";\n width: ", ";\n height: ", ";\n max-width: ", ";\n max-height: ", ";\n min-width: ", ";\n min-height: ", ";\n position: ", ";\n top: ", ";\n right: ", ";\n bottom: ", ";\n left: ", ";\n float: ", ";\n z-index: ", ";\n box-shadow: ", ";\n\n background-attachment: ", ";\n background-clip: ", ";\n background-color: ", ";\n background-image: ", ";\n background-origin: ", ";\n background-position: ", ";\n background-repeat: ", ";\n background-size: ", ";\n\n border-radius: ", ";\n border-width: ", ";\n border-style: ", ";\n border-color: ", ";\n\n ", ";\n\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n\n outline: ", ";\n outline-offset: ", ";\n\n overflow: ", ";\n overflow-x: ", ";\n overflow-y: ", ";\n\n padding: ", ";\n padding-top: ", ";\n padding-right: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n"])), function (_ref2) {
|
|
48
48
|
var boxSizing = _ref2.boxSizing;
|
|
49
49
|
return boxSizing;
|
|
50
50
|
}, function (_ref3) {
|
package/dropdown/Dropdown.js
CHANGED
|
@@ -263,7 +263,7 @@ var sizes = {
|
|
|
263
263
|
var calculateWidth = function calculateWidth(margin, size) {
|
|
264
264
|
return size === "fillParent" ? "calc(".concat(sizes[size], " - ").concat((0, _utils.getMargin)(margin, "left"), " - ").concat((0, _utils.getMargin)(margin, "right"), ")") : sizes[size];
|
|
265
265
|
};
|
|
266
|
-
var DropdownContainer = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n
|
|
266
|
+
var DropdownContainer = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n width: ", ";\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n"])), function (props) {
|
|
267
267
|
return calculateWidth(props.margin, props.size);
|
|
268
268
|
}, function (props) {
|
|
269
269
|
return props.margin && (0, _typeof2["default"])(props.margin) !== "object" ? _variables.spaces[props.margin] : "0px";
|
|
@@ -276,18 +276,20 @@ var DropdownContainer = _styledComponents["default"].div(_templateObject || (_te
|
|
|
276
276
|
}, function (props) {
|
|
277
277
|
return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.left ? _variables.spaces[props.margin.left] : "";
|
|
278
278
|
});
|
|
279
|
-
var DropdownTrigger = _styledComponents["default"].button(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: ", ";\n width: 100%;\n
|
|
279
|
+
var DropdownTrigger = _styledComponents["default"].button(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n justify-content: space-between;\n align-items: center;\n gap: ", ";\n width: 100%;\n height: ", ";\n min-width: ", ";\n border-radius: ", ";\n border-width: ", ";\n border-style: ", ";\n border-color: ", ";\n padding-top: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n background-color: ", ";\n color: ", ";\n cursor: ", ";\n\n ", ";\n"])), function (props) {
|
|
280
280
|
return props.theme.caretIconSpacing;
|
|
281
|
+
}, function (props) {
|
|
282
|
+
return props.theme.buttonHeight;
|
|
281
283
|
}, function (props) {
|
|
282
284
|
return props.label === "" ? "0px" : calculateWidth(props.margin, props.size);
|
|
283
285
|
}, function (props) {
|
|
284
|
-
return props.theme.
|
|
286
|
+
return props.theme.buttonBorderRadius;
|
|
285
287
|
}, function (props) {
|
|
286
|
-
return props.theme.
|
|
288
|
+
return props.theme.buttonBorderThickness;
|
|
287
289
|
}, function (props) {
|
|
288
|
-
return props.theme.
|
|
290
|
+
return props.theme.buttonBorderStyle;
|
|
289
291
|
}, function (props) {
|
|
290
|
-
return props.disabled ? props.theme.
|
|
292
|
+
return props.disabled ? props.theme.disabledButtonBorderColor : props.theme.buttonBorderColor;
|
|
291
293
|
}, function (props) {
|
|
292
294
|
return props.theme.buttonPaddingTop;
|
|
293
295
|
}, function (props) {
|
|
@@ -303,7 +305,7 @@ var DropdownTrigger = _styledComponents["default"].button(_templateObject2 || (_
|
|
|
303
305
|
}, function (props) {
|
|
304
306
|
return props.disabled ? "not-allowed" : "pointer";
|
|
305
307
|
}, function (props) {
|
|
306
|
-
return !props.disabled && "\n &:focus {\n outline: ".concat(props.theme.focusColor, "
|
|
308
|
+
return !props.disabled && "\n &:focus {\n outline: 2px solid ".concat(props.theme.focusColor, ";\n }\n &:hover {\n background-color: ").concat(props.theme.hoverButtonBackgroundColor, ";\n }\n &:active {\n background-color: ").concat(props.theme.activeButtonBackgroundColor, ";\n }\n ");
|
|
307
309
|
});
|
|
308
310
|
var DropdownTriggerContent = _styledComponents["default"].span(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-items: center;\n gap: ", ";\n margin-left: 0px;\n margin-right: 0px;\n width: 100%;\n overflow: hidden;\n white-space: nowrap;\n"])), function (props) {
|
|
309
311
|
return props.theme.buttonIconSpacing;
|
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, margin, tabIndex, }: FooterPropsType) => JSX.Element;
|
|
3
|
+
declare const DxcFooter: ({ socialLinks, bottomLinks, copyright, children, margin, tabIndex, mode, }: FooterPropsType) => JSX.Element;
|
|
4
4
|
export default DxcFooter;
|
package/footer/Footer.js
CHANGED
|
@@ -24,11 +24,14 @@ var DxcFooter = function DxcFooter(_ref) {
|
|
|
24
24
|
children = _ref.children,
|
|
25
25
|
margin = _ref.margin,
|
|
26
26
|
_ref$tabIndex = _ref.tabIndex,
|
|
27
|
-
tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex
|
|
27
|
+
tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex,
|
|
28
|
+
_ref$mode = _ref.mode,
|
|
29
|
+
mode = _ref$mode === void 0 ? "default" : _ref$mode;
|
|
28
30
|
var colorsTheme = (0, _useTheme["default"])();
|
|
29
31
|
var translatedLabels = (0, _useTranslatedLabels["default"])();
|
|
30
32
|
var footerLogo = (0, _react.useMemo)(function () {
|
|
31
|
-
return !colorsTheme.footer.logo ? _Icons.dxcLogo : typeof colorsTheme.footer.logo === "string" ? /*#__PURE__*/_react["default"].createElement(LogoImg, {
|
|
33
|
+
return !colorsTheme.footer.logo ? mode === "default" ? _Icons.dxcLogo : _Icons.dxcSmallLogo : typeof colorsTheme.footer.logo === "string" ? /*#__PURE__*/_react["default"].createElement(LogoImg, {
|
|
34
|
+
mode: mode,
|
|
32
35
|
alt: translatedLabels.formFields.logoAlternativeText,
|
|
33
36
|
src: colorsTheme.footer.logo
|
|
34
37
|
}) : colorsTheme.footer.logo;
|
|
@@ -36,13 +39,16 @@ var DxcFooter = function DxcFooter(_ref) {
|
|
|
36
39
|
return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
|
|
37
40
|
theme: colorsTheme.footer
|
|
38
41
|
}, /*#__PURE__*/_react["default"].createElement(FooterContainer, {
|
|
39
|
-
margin: margin
|
|
42
|
+
margin: margin,
|
|
43
|
+
mode: mode
|
|
40
44
|
}, /*#__PURE__*/_react["default"].createElement(_Flex["default"], {
|
|
41
45
|
justifyContent: "space-between",
|
|
42
46
|
alignItems: "center",
|
|
43
47
|
wrap: "wrap",
|
|
44
48
|
gap: "1.5rem"
|
|
45
|
-
}, /*#__PURE__*/_react["default"].createElement(LogoContainer,
|
|
49
|
+
}, /*#__PURE__*/_react["default"].createElement(LogoContainer, {
|
|
50
|
+
mode: mode
|
|
51
|
+
}, footerLogo), mode === "default" && /*#__PURE__*/_react["default"].createElement(_Flex["default"], null, socialLinks === null || socialLinks === void 0 ? void 0 : socialLinks.map(function (link, index) {
|
|
46
52
|
return /*#__PURE__*/_react["default"].createElement(SocialAnchor, {
|
|
47
53
|
href: link.href,
|
|
48
54
|
tabIndex: tabIndex,
|
|
@@ -51,9 +57,10 @@ var DxcFooter = function DxcFooter(_ref) {
|
|
|
51
57
|
key: "social".concat(index).concat(link.href),
|
|
52
58
|
index: index
|
|
53
59
|
}, /*#__PURE__*/_react["default"].createElement(SocialIconContainer, null, typeof link.logo === "string" ? /*#__PURE__*/_react["default"].createElement("img", {
|
|
54
|
-
src: link.logo
|
|
60
|
+
src: link.logo,
|
|
61
|
+
alt: link.title
|
|
55
62
|
}) : link.logo));
|
|
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) {
|
|
63
|
+
}))), /*#__PURE__*/_react["default"].createElement(ChildComponents, null, children), mode === "default" && /*#__PURE__*/_react["default"].createElement(BottomContainer, null, /*#__PURE__*/_react["default"].createElement(BottomLinks, null, bottomLinks === null || bottomLinks === void 0 ? void 0 : bottomLinks.map(function (link, index) {
|
|
57
64
|
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
58
65
|
key: "bottom".concat(index).concat(link.text)
|
|
59
66
|
}, /*#__PURE__*/_react["default"].createElement(BottomLink, {
|
|
@@ -62,13 +69,19 @@ var DxcFooter = function DxcFooter(_ref) {
|
|
|
62
69
|
}, link.text));
|
|
63
70
|
})), /*#__PURE__*/_react["default"].createElement(Copyright, null, copyright || translatedLabels.footer.copyrightText(new Date().getFullYear())))));
|
|
64
71
|
};
|
|
65
|
-
var FooterContainer = _styledComponents["default"].footer(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: border-box;\n display: flex;\n flex-direction:
|
|
66
|
-
return props.theme.
|
|
72
|
+
var FooterContainer = _styledComponents["default"].footer(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n background-color: ", ";\n box-sizing: border-box;\n display: flex;\n flex-direction: ", ";\n justify-content: space-between;\n margin-top: ", ";\n min-height: ", ";\n width: 100%;\n gap: ", ";\n @media (min-width: ", "rem) {\n padding: ", ";\n }\n @media (max-width: ", "rem) {\n padding: 20px;\n flex-direction: column;\n }\n"])), function (props) {
|
|
73
|
+
return props.theme.backgroundColor;
|
|
74
|
+
}, function (props) {
|
|
75
|
+
return (props === null || props === void 0 ? void 0 : props.mode) === "default" ? "column" : "row";
|
|
67
76
|
}, function (props) {
|
|
68
77
|
return props.margin ? _variables.spaces[props.margin] : "0px";
|
|
69
78
|
}, function (props) {
|
|
70
|
-
return props.theme.
|
|
71
|
-
},
|
|
79
|
+
return (props === null || props === void 0 ? void 0 : props.mode) === "default" ? props.theme.height : "40px";
|
|
80
|
+
}, function (props) {
|
|
81
|
+
return (props === null || props === void 0 ? void 0 : props.mode) === "default" ? "0px" : "32px";
|
|
82
|
+
}, _variables.responsiveSizes.small, function (props) {
|
|
83
|
+
return (props === null || props === void 0 ? void 0 : props.mode) === "default" ? "24px 32px" : "12px 32px";
|
|
84
|
+
}, _variables.responsiveSizes.small);
|
|
72
85
|
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) {
|
|
73
86
|
return "".concat(props.theme.bottomLinksDividerThickness, " ").concat(props.theme.bottomLinksDividerStyle, " ").concat(props.theme.bottomLinksDividerColor);
|
|
74
87
|
});
|
|
@@ -87,12 +100,12 @@ var Copyright = _styledComponents["default"].div(_templateObject4 || (_templateO
|
|
|
87
100
|
return props.theme.copyrightFontColor;
|
|
88
101
|
}, _variables.responsiveSizes.small, _variables.responsiveSizes.small);
|
|
89
102
|
var LogoContainer = _styledComponents["default"].span(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n max-height: ", ";\n width: ", ";\n"])), function (props) {
|
|
90
|
-
return props.theme.logoHeight;
|
|
103
|
+
return (props === null || props === void 0 ? void 0 : props.mode) === "default" ? props.theme.logoHeight : "16px";
|
|
91
104
|
}, function (props) {
|
|
92
105
|
return props.theme.logoWidth;
|
|
93
106
|
});
|
|
94
107
|
var LogoImg = _styledComponents["default"].img(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n max-height: ", ";\n width: ", ";\n"])), function (props) {
|
|
95
|
-
return props.theme.logoHeight;
|
|
108
|
+
return (props === null || props === void 0 ? void 0 : props.mode) === "default" ? props.theme.logoHeight : "16px";
|
|
96
109
|
}, function (props) {
|
|
97
110
|
return props.theme.logoWidth;
|
|
98
111
|
});
|
|
@@ -3,6 +3,8 @@ import DxcFooter from "./Footer";
|
|
|
3
3
|
import Title from "../../.storybook/components/Title";
|
|
4
4
|
import ExampleContainer from "../../.storybook/components/ExampleContainer";
|
|
5
5
|
import { HalstackProvider } from "../HalstackContext";
|
|
6
|
+
import DxcFlex from "../flex/Flex";
|
|
7
|
+
import DxcTypography from "../typography/Typography";
|
|
6
8
|
|
|
7
9
|
const social = [
|
|
8
10
|
{
|
|
@@ -99,6 +101,11 @@ const opinionatedTheme = {
|
|
|
99
101
|
},
|
|
100
102
|
};
|
|
101
103
|
|
|
104
|
+
const info = [
|
|
105
|
+
{ label: "Example Label", text: "Example" },
|
|
106
|
+
{ label: "Example Label", text: "Example" },
|
|
107
|
+
];
|
|
108
|
+
|
|
102
109
|
export const Chromatic = () => (
|
|
103
110
|
<>
|
|
104
111
|
<ExampleContainer>
|
|
@@ -121,6 +128,18 @@ export const Chromatic = () => (
|
|
|
121
128
|
</div>
|
|
122
129
|
</DxcFooter>
|
|
123
130
|
</ExampleContainer>
|
|
131
|
+
<ExampleContainer>
|
|
132
|
+
<Title title="Reduced" theme="light" level={4} />
|
|
133
|
+
<DxcFooter mode="reduced">
|
|
134
|
+
<DxcFlex justifyContent="center" alignItems="center" gap={"1rem"}>
|
|
135
|
+
{info.map((tag, index) => (
|
|
136
|
+
<DxcTypography color="white" key={`tag${index}${tag.label}${tag.text}`} >
|
|
137
|
+
{tag.label}: {tag.text}
|
|
138
|
+
</DxcTypography>
|
|
139
|
+
))}
|
|
140
|
+
</DxcFlex>
|
|
141
|
+
</DxcFooter>
|
|
142
|
+
</ExampleContainer>
|
|
124
143
|
<Title title="Margins" theme="light" level={2} />
|
|
125
144
|
<ExampleContainer>
|
|
126
145
|
<Title title="Xxsmall margin" theme="light" level={4} />
|
package/footer/Icons.d.ts
CHANGED
package/footer/Icons.js
CHANGED
|
@@ -4,7 +4,7 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.dxcLogo = void 0;
|
|
7
|
+
exports.dxcSmallLogo = exports.dxcLogo = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var dxcLogo = exports.dxcLogo = /*#__PURE__*/_react["default"].createElement("svg", {
|
|
10
10
|
id: "g10",
|
|
@@ -69,4 +69,68 @@ var dxcLogo = exports.dxcLogo = /*#__PURE__*/_react["default"].createElement("sv
|
|
|
69
69
|
d: "M84.218-55.737a10.063,10.063,0,0,1,2.589-4.4,9.792,9.792,0,0,1,6.985-2.77h11.328V-69.3H93.792a17.041,17.041,0,0,0-11.8,4.759,16.344,16.344,0,0,0-3.547,5.115,13.247,13.247,0,0,0-1.122,3.688Zm0,4.877a10.065,10.065,0,0,0,2.589,4.4,9.793,9.793,0,0,0,6.985,2.77h11.328V-37.3H93.792a17.042,17.042,0,0,1-11.8-4.759,16.339,16.339,0,0,1-3.547-5.114,13.251,13.251,0,0,1-1.122-3.688ZM63.1-47.98,54.45-37.3H45.873l12.957-16-12.957-16H54.45L63.1-58.619l8.65-10.68h8.578l-12.957,16,12.957,16H71.749ZM48.875-55.737a13.212,13.212,0,0,0-1.122-3.688,16.359,16.359,0,0,0-3.546-5.115,17.043,17.043,0,0,0-11.8-4.759H21.08v6.393H32.408a9.79,9.79,0,0,1,6.985,2.77,10.072,10.072,0,0,1,2.59,4.4Zm0,4.877a13.215,13.215,0,0,1-1.122,3.688,16.353,16.353,0,0,1-3.546,5.114,17.044,17.044,0,0,1-11.8,4.759H21.08v-6.393H32.408a9.791,9.791,0,0,0,6.985-2.77,10.074,10.074,0,0,0,2.59-4.4h6.892",
|
|
70
70
|
transform: "translate(-21.08 69.298)",
|
|
71
71
|
fill: "#fff"
|
|
72
|
+
})));
|
|
73
|
+
var dxcSmallLogo = exports.dxcSmallLogo = /*#__PURE__*/_react["default"].createElement("svg", {
|
|
74
|
+
id: "g10",
|
|
75
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
76
|
+
width: "100%",
|
|
77
|
+
height: "16",
|
|
78
|
+
viewBox: "0 0 280.781 32"
|
|
79
|
+
}, /*#__PURE__*/_react["default"].createElement("title", null, "DXC Logo"), /*#__PURE__*/_react["default"].createElement("g", {
|
|
80
|
+
id: "g12"
|
|
81
|
+
}, /*#__PURE__*/_react["default"].createElement("path", {
|
|
82
|
+
id: "path14",
|
|
83
|
+
d: "M171.5-54.124v12.539h-3.6V-54.124h-4.973v-3.191h13.54v3.191H171.5",
|
|
84
|
+
transform: "translate(-68.528 65.45)",
|
|
85
|
+
fill: "#fff"
|
|
86
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
87
|
+
id: "path16",
|
|
88
|
+
d: "M189.96-41.585V-57.315h12.326v3.079h-8.753v3.191h7.7v3.078h-7.7v3.3h8.87v3.078H189.96",
|
|
89
|
+
transform: "translate(-77.56 65.45)",
|
|
90
|
+
fill: "#fff"
|
|
91
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
92
|
+
id: "path18",
|
|
93
|
+
d: "M223.558-41.438a8.1,8.1,0,0,1-8.382-8.1v-.045a8.161,8.161,0,0,1,8.522-8.146,8.6,8.6,0,0,1,6.444,2.431l-2.289,2.543a6.133,6.133,0,0,0-4.178-1.778,4.743,4.743,0,0,0-4.738,4.905v.045a4.752,4.752,0,0,0,4.738,4.95,6,6,0,0,0,4.295-1.845l2.288,2.228a8.491,8.491,0,0,1-6.7,2.813",
|
|
94
|
+
transform: "translate(-86.019 65.583)",
|
|
95
|
+
fill: "#fff"
|
|
96
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
97
|
+
id: "path20",
|
|
98
|
+
d: "M254.988-41.585V-47.9h-6.63v6.315h-3.6V-57.315h3.6v6.225h6.63v-6.225h3.594v15.731h-3.594",
|
|
99
|
+
transform: "translate(-95.903 65.45)",
|
|
100
|
+
fill: "#fff"
|
|
101
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
102
|
+
id: "path22",
|
|
103
|
+
d: "M285.991-41.585l-7.914-10v10h-3.549V-57.315h3.316l7.657,9.685v-9.685h3.549v15.731h-3.058",
|
|
104
|
+
transform: "translate(-105.869 65.45)",
|
|
105
|
+
fill: "#fff"
|
|
106
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
107
|
+
id: "path24",
|
|
108
|
+
d: "M317.2-49.583a4.869,4.869,0,0,0-4.949-4.95,4.793,4.793,0,0,0-4.9,4.905v.045a4.869,4.869,0,0,0,4.949,4.95,4.793,4.793,0,0,0,4.9-4.905Zm-4.949,8.145c-5.043,0-8.661-3.623-8.661-8.1v-.045c0-4.478,3.666-8.146,8.708-8.146s8.66,3.623,8.66,8.1v.045c0,4.477-3.664,8.145-8.708,8.145",
|
|
109
|
+
transform: "translate(-115.631 65.583)",
|
|
110
|
+
fill: "#fff"
|
|
111
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
112
|
+
id: "path26",
|
|
113
|
+
d: "M336.786-41.585V-57.315h3.6v12.584h8.148v3.146H336.786",
|
|
114
|
+
transform: "translate(-126.654 65.45)",
|
|
115
|
+
fill: "#fff"
|
|
116
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
117
|
+
id: "path28",
|
|
118
|
+
d: "M372.78-49.583a4.87,4.87,0,0,0-4.949-4.95,4.794,4.794,0,0,0-4.9,4.905v.045a4.869,4.869,0,0,0,4.949,4.95,4.794,4.794,0,0,0,4.9-4.905Zm-4.949,8.145c-5.043,0-8.662-3.623-8.662-8.1v-.045c0-4.478,3.666-8.146,8.708-8.146s8.661,3.623,8.661,8.1v.045c0,4.477-3.666,8.145-8.708,8.145",
|
|
119
|
+
transform: "translate(-135.016 65.583)",
|
|
120
|
+
fill: "#fff"
|
|
121
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
122
|
+
id: "path30",
|
|
123
|
+
d: "M399.735-41.438c-5.09,0-8.592-3.443-8.592-8.1v-.045a8.243,8.243,0,0,1,8.568-8.146,9.18,9.18,0,0,1,6.42,2.16l-2.265,2.634a6.141,6.141,0,0,0-4.272-1.6,4.807,4.807,0,0,0-4.692,4.905v.045a4.8,4.8,0,0,0,4.949,4.995,5.89,5.89,0,0,0,3.384-.945v-2.25h-3.618v-2.992h7.1v6.841a10.837,10.837,0,0,1-6.98,2.5",
|
|
124
|
+
transform: "translate(-145.284 65.583)",
|
|
125
|
+
fill: "#fff"
|
|
126
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
127
|
+
id: "path32",
|
|
128
|
+
d: "M428.664-47.855v6.27h-3.6v-6.2l-6.28-9.528h4.2L426.89-51l3.968-6.315h4.085l-6.28,9.46",
|
|
129
|
+
transform: "translate(-154.162 65.45)",
|
|
130
|
+
fill: "#fff"
|
|
131
|
+
}), /*#__PURE__*/_react["default"].createElement("path", {
|
|
132
|
+
id: "path34",
|
|
133
|
+
d: "M84.218-55.737a10.063,10.063,0,0,1,2.589-4.4,9.792,9.792,0,0,1,6.985-2.77h11.328V-69.3H93.792a17.041,17.041,0,0,0-11.8,4.759,16.344,16.344,0,0,0-3.547,5.115,13.247,13.247,0,0,0-1.122,3.688Zm0,4.877a10.065,10.065,0,0,0,2.589,4.4,9.793,9.793,0,0,0,6.985,2.77h11.328V-37.3H93.792a17.042,17.042,0,0,1-11.8-4.759,16.339,16.339,0,0,1-3.547-5.114,13.251,13.251,0,0,1-1.122-3.688ZM63.1-47.98,54.45-37.3H45.873l12.957-16-12.957-16H54.45L63.1-58.619l8.65-10.68h8.578l-12.957,16,12.957,16H71.749ZM48.875-55.737a13.212,13.212,0,0,0-1.122-3.688,16.359,16.359,0,0,0-3.546-5.115,17.043,17.043,0,0,0-11.8-4.759H21.08v6.393H32.408a9.79,9.79,0,0,1,6.985,2.77,10.072,10.072,0,0,1,2.59,4.4Zm0,4.877a13.215,13.215,0,0,1-1.122,3.688,16.353,16.353,0,0,1-3.546,5.114,17.044,17.044,0,0,1-11.8,4.759H21.08v-6.393H32.408a9.791,9.791,0,0,0,6.985-2.77,10.074,10.074,0,0,0,2.59-4.4h6.892",
|
|
134
|
+
transform: "translate(-21.08 69.298)",
|
|
135
|
+
fill: "#fff"
|
|
72
136
|
})));
|
package/footer/types.d.ts
CHANGED
|
@@ -54,5 +54,11 @@ type FooterPropsType = {
|
|
|
54
54
|
* inside the custom area.
|
|
55
55
|
*/
|
|
56
56
|
tabIndex?: number;
|
|
57
|
+
/**
|
|
58
|
+
* Determines the visual style and layout
|
|
59
|
+
* - "default": The default mode with full content and styling.
|
|
60
|
+
* - "reduced": A reduced mode with minimal content and styling.
|
|
61
|
+
*/
|
|
62
|
+
mode?: "default" | "reduced";
|
|
57
63
|
};
|
|
58
64
|
export default FooterPropsType;
|
|
@@ -7,7 +7,7 @@ declare const DxcApplicationLayout: {
|
|
|
7
7
|
Dropdown: (props: import("../dropdown/types").default) => React.JSX.Element;
|
|
8
8
|
};
|
|
9
9
|
Main: ({ children }: AppLayoutMainPropsType) => JSX.Element;
|
|
10
|
-
Footer: ({ socialLinks, bottomLinks, copyright, children, margin, tabIndex, }: import("../footer/types").default) => JSX.Element;
|
|
10
|
+
Footer: ({ socialLinks, bottomLinks, copyright, children, margin, tabIndex, mode, }: import("../footer/types").default) => JSX.Element;
|
|
11
11
|
SideNav: {
|
|
12
12
|
({ title, children }: import("../sidenav/types").default): JSX.Element;
|
|
13
13
|
Section: ({ children }: import("../sidenav/types").SidenavSectionPropsType) => JSX.Element;
|
package/main.d.ts
CHANGED
|
@@ -22,7 +22,6 @@ import DxcChip from "./chip/Chip";
|
|
|
22
22
|
import DxcApplicationLayout from "./layout/ApplicationLayout";
|
|
23
23
|
import DxcToggleGroup from "./toggle-group/ToggleGroup";
|
|
24
24
|
import DxcAccordionGroup from "./accordion-group/AccordionGroup";
|
|
25
|
-
import DxcBadge from "./badge/Badge";
|
|
26
25
|
import DxcTextInput from "./text-input/TextInput";
|
|
27
26
|
import DxcPasswordInput from "./password-input/PasswordInput";
|
|
28
27
|
import DxcDateInput from "./date-input/DateInput";
|
|
@@ -42,5 +41,7 @@ import DxcBulletedList from "./bulleted-list/BulletedList";
|
|
|
42
41
|
import DxcGrid from "./grid/Grid";
|
|
43
42
|
import DxcImage from "./image/Image";
|
|
44
43
|
import DxcContainer from "./container/Container";
|
|
44
|
+
import DxcBadge from "./badge/Badge";
|
|
45
|
+
import DxcStatusLight from "./status-light/StatusLight";
|
|
45
46
|
import HalstackContext, { HalstackProvider, HalstackLanguageContext } from "./HalstackContext";
|
|
46
|
-
export { DxcAlert, DxcButton, DxcCheckbox, DxcTextInput, DxcDropdown, DxcSwitch, DxcSlider, DxcTable, DxcTabs, DxcToggleGroup, DxcDialog, DxcCard, DxcProgressBar, DxcAccordion, DxcSpinner, DxcBox, DxcTag, DxcPaginator, DxcWizard, DxcLink, DxcHeading, DxcResultsetTable, DxcChip, DxcApplicationLayout, HalstackContext, HalstackLanguageContext, HalstackProvider, DxcAccordionGroup,
|
|
47
|
+
export { DxcAlert, DxcButton, DxcCheckbox, DxcTextInput, DxcDropdown, DxcSwitch, DxcSlider, DxcTable, DxcTabs, DxcToggleGroup, DxcDialog, DxcCard, DxcProgressBar, DxcAccordion, DxcSpinner, DxcBox, DxcTag, DxcPaginator, DxcWizard, DxcLink, DxcHeading, DxcResultsetTable, DxcChip, DxcApplicationLayout, HalstackContext, HalstackLanguageContext, HalstackProvider, DxcAccordionGroup, DxcPasswordInput, DxcDateInput, DxcNumberInput, DxcTextarea, DxcSelect, DxcFileInput, DxcRadioGroup, DxcBleed, DxcInset, DxcQuickNav, DxcNavTabs, DxcFlex, DxcTypography, DxcParagraph, DxcBulletedList, DxcGrid, DxcImage, DxcContainer, DxcBadge, DxcStatusLight, };
|
package/main.js
CHANGED
|
@@ -215,6 +215,12 @@ Object.defineProperty(exports, "DxcSpinner", {
|
|
|
215
215
|
return _Spinner["default"];
|
|
216
216
|
}
|
|
217
217
|
});
|
|
218
|
+
Object.defineProperty(exports, "DxcStatusLight", {
|
|
219
|
+
enumerable: true,
|
|
220
|
+
get: function get() {
|
|
221
|
+
return _StatusLight["default"];
|
|
222
|
+
}
|
|
223
|
+
});
|
|
218
224
|
Object.defineProperty(exports, "DxcSwitch", {
|
|
219
225
|
enumerable: true,
|
|
220
226
|
get: function get() {
|
|
@@ -311,7 +317,6 @@ var _Chip = _interopRequireDefault(require("./chip/Chip"));
|
|
|
311
317
|
var _ApplicationLayout = _interopRequireDefault(require("./layout/ApplicationLayout"));
|
|
312
318
|
var _ToggleGroup = _interopRequireDefault(require("./toggle-group/ToggleGroup"));
|
|
313
319
|
var _AccordionGroup = _interopRequireDefault(require("./accordion-group/AccordionGroup"));
|
|
314
|
-
var _Badge = _interopRequireDefault(require("./badge/Badge"));
|
|
315
320
|
var _TextInput = _interopRequireDefault(require("./text-input/TextInput"));
|
|
316
321
|
var _PasswordInput = _interopRequireDefault(require("./password-input/PasswordInput"));
|
|
317
322
|
var _DateInput = _interopRequireDefault(require("./date-input/DateInput"));
|
|
@@ -331,6 +336,8 @@ var _BulletedList = _interopRequireDefault(require("./bulleted-list/BulletedList
|
|
|
331
336
|
var _Grid = _interopRequireDefault(require("./grid/Grid"));
|
|
332
337
|
var _Image = _interopRequireDefault(require("./image/Image"));
|
|
333
338
|
var _Container = _interopRequireDefault(require("./container/Container"));
|
|
339
|
+
var _Badge = _interopRequireDefault(require("./badge/Badge"));
|
|
340
|
+
var _StatusLight = _interopRequireDefault(require("./status-light/StatusLight"));
|
|
334
341
|
var _HalstackContext = _interopRequireWildcard(require("./HalstackContext"));
|
|
335
342
|
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); }
|
|
336
343
|
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; }
|
package/nav-tabs/NavTabs.js
CHANGED
|
@@ -85,7 +85,7 @@ var DxcNavTabs = function DxcNavTabs(_ref) {
|
|
|
85
85
|
value: contextValue
|
|
86
86
|
}, children), /*#__PURE__*/_react["default"].createElement(Underline, null)));
|
|
87
87
|
};
|
|
88
|
-
var Underline = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n position: absolute;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 2px;\n background-color: ", ";\n
|
|
88
|
+
var Underline = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n position: absolute;\n bottom: 0;\n left: 0;\n width: 100%;\n height: 2px;\n background-color: ", ";\n"])), function (props) {
|
|
89
89
|
return props.theme.dividerColor;
|
|
90
90
|
});
|
|
91
91
|
DxcNavTabs.Tab = _Tab["default"];
|