@hitachivantara/uikit-react-core 5.24.1 → 5.24.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/BulkActions/BulkActions.cjs +0 -4
- package/dist/cjs/components/BulkActions/BulkActions.cjs.map +1 -1
- package/dist/cjs/components/Card/Card.cjs +2 -2
- package/dist/cjs/components/Card/Card.cjs.map +1 -1
- package/dist/cjs/components/Card/Card.styles.cjs +1 -1
- package/dist/cjs/components/Card/Card.styles.cjs.map +1 -1
- package/dist/cjs/components/CheckBoxGroup/CheckBoxGroup.styles.cjs +0 -4
- package/dist/cjs/components/CheckBoxGroup/CheckBoxGroup.styles.cjs.map +1 -1
- package/dist/cjs/components/DropDownMenu/DropDownMenu.styles.cjs +1 -1
- package/dist/cjs/components/DropDownMenu/DropDownMenu.styles.cjs.map +1 -1
- package/dist/cjs/components/FilterGroup/RightPanel/RightPanel.styles.cjs +0 -4
- package/dist/cjs/components/FilterGroup/RightPanel/RightPanel.styles.cjs.map +1 -1
- package/dist/cjs/components/Footer/Footer.cjs +2 -2
- package/dist/cjs/components/Footer/Footer.cjs.map +1 -1
- package/dist/cjs/components/GlobalActions/GlobalActions.cjs +38 -17
- package/dist/cjs/components/GlobalActions/GlobalActions.cjs.map +1 -1
- package/dist/cjs/components/GlobalActions/GlobalActions.styles.cjs +42 -89
- package/dist/cjs/components/GlobalActions/GlobalActions.styles.cjs.map +1 -1
- package/dist/cjs/components/List/List.styles.cjs +13 -28
- package/dist/cjs/components/List/List.styles.cjs.map +1 -1
- package/dist/cjs/components/ListContainer/ListContainer.cjs +8 -4
- package/dist/cjs/components/ListContainer/ListContainer.cjs.map +1 -1
- package/dist/cjs/components/ListContainer/ListContainer.styles.cjs +12 -0
- package/dist/cjs/components/ListContainer/ListContainer.styles.cjs.map +1 -0
- package/dist/cjs/components/ListContainer/ListContext/ListContext.cjs.map +1 -1
- package/dist/cjs/components/ListContainer/ListItem/ListItem.cjs +43 -31
- package/dist/cjs/components/ListContainer/ListItem/ListItem.cjs.map +1 -1
- package/dist/cjs/components/ListContainer/ListItem/ListItem.styles.cjs +47 -75
- package/dist/cjs/components/ListContainer/ListItem/ListItem.styles.cjs.map +1 -1
- package/dist/cjs/components/Loading/Loading.cjs +18 -13
- package/dist/cjs/components/Loading/Loading.cjs.map +1 -1
- package/dist/cjs/components/Loading/Loading.styles.cjs +44 -96
- package/dist/cjs/components/Loading/Loading.styles.cjs.map +1 -1
- package/dist/cjs/components/RadioGroup/RadioGroup.styles.cjs +0 -4
- package/dist/cjs/components/RadioGroup/RadioGroup.styles.cjs.map +1 -1
- package/dist/cjs/components/ScrollTo/Horizontal/ScrollToHorizontal.cjs +2 -2
- package/dist/cjs/components/ScrollTo/Horizontal/ScrollToHorizontal.cjs.map +1 -1
- package/dist/cjs/components/ScrollTo/Vertical/ScrollToVertical.cjs +2 -2
- package/dist/cjs/components/ScrollTo/Vertical/ScrollToVertical.cjs.map +1 -1
- package/dist/cjs/components/SelectionList/SelectionList.cjs +25 -15
- package/dist/cjs/components/SelectionList/SelectionList.cjs.map +1 -1
- package/dist/cjs/components/SelectionList/SelectionList.styles.cjs +41 -119
- package/dist/cjs/components/SelectionList/SelectionList.styles.cjs.map +1 -1
- package/dist/cjs/components/Stack/Stack.cjs +8 -7
- package/dist/cjs/components/Stack/Stack.cjs.map +1 -1
- package/dist/cjs/components/Stack/Stack.styles.cjs +18 -37
- package/dist/cjs/components/Stack/Stack.styles.cjs.map +1 -1
- package/dist/cjs/components/Tab/Tab.cjs +12 -8
- package/dist/cjs/components/Tab/Tab.cjs.map +1 -1
- package/dist/cjs/components/Tab/Tab.styles.cjs +53 -57
- package/dist/cjs/components/Tab/Tab.styles.cjs.map +1 -1
- package/dist/cjs/components/Table/Table.styles.cjs +6 -7
- package/dist/cjs/components/Table/Table.styles.cjs.map +1 -1
- package/dist/cjs/components/Table/TableRow/TableRow.styles.cjs +6 -22
- package/dist/cjs/components/Table/TableRow/TableRow.styles.cjs.map +1 -1
- package/dist/cjs/components/Table/hooks/useSticky.cjs +5 -1
- package/dist/cjs/components/Table/hooks/useSticky.cjs.map +1 -1
- package/dist/cjs/components/Table/utils/utils.cjs +15 -42
- package/dist/cjs/components/Table/utils/utils.cjs.map +1 -1
- package/dist/cjs/components/Tabs/Tabs.cjs +11 -8
- package/dist/cjs/components/Tabs/Tabs.cjs.map +1 -1
- package/dist/cjs/components/Tabs/Tabs.styles.cjs +16 -20
- package/dist/cjs/components/Tabs/Tabs.styles.cjs.map +1 -1
- package/dist/cjs/components/TagsInput/TagsInput.styles.cjs +4 -4
- package/dist/cjs/components/TagsInput/TagsInput.styles.cjs.map +1 -1
- package/dist/cjs/components/TextArea/TextArea.cjs +32 -21
- package/dist/cjs/components/TextArea/TextArea.cjs.map +1 -1
- package/dist/cjs/components/TextArea/TextArea.styles.cjs +45 -142
- package/dist/cjs/components/TextArea/TextArea.styles.cjs.map +1 -1
- package/dist/cjs/components/Typography/Typography.cjs +2 -2
- package/dist/cjs/components/Typography/Typography.cjs.map +1 -1
- package/dist/cjs/components/VerticalNavigation/NavigationSlider/NavigationSlider.styles.cjs +3 -3
- package/dist/cjs/components/VerticalNavigation/NavigationSlider/NavigationSlider.styles.cjs.map +1 -1
- package/dist/cjs/components/VerticalNavigation/TreeView/TreeViewItem.styles.cjs +4 -11
- package/dist/cjs/components/VerticalNavigation/TreeView/TreeViewItem.styles.cjs.map +1 -1
- package/dist/cjs/components/VerticalNavigation/TreeView/descendants.cjs +1 -9
- package/dist/cjs/components/VerticalNavigation/TreeView/descendants.cjs.map +1 -1
- package/dist/cjs/index.cjs +18 -18
- package/dist/esm/components/BulkActions/BulkActions.js +0 -4
- package/dist/esm/components/BulkActions/BulkActions.js.map +1 -1
- package/dist/esm/components/Card/Card.js +2 -2
- package/dist/esm/components/Card/Card.js.map +1 -1
- package/dist/esm/components/Card/Card.styles.js +1 -1
- package/dist/esm/components/Card/Card.styles.js.map +1 -1
- package/dist/esm/components/CheckBoxGroup/CheckBoxGroup.styles.js +0 -4
- package/dist/esm/components/CheckBoxGroup/CheckBoxGroup.styles.js.map +1 -1
- package/dist/esm/components/DropDownMenu/DropDownMenu.styles.js +1 -1
- package/dist/esm/components/DropDownMenu/DropDownMenu.styles.js.map +1 -1
- package/dist/esm/components/FilterGroup/RightPanel/RightPanel.styles.js +0 -4
- package/dist/esm/components/FilterGroup/RightPanel/RightPanel.styles.js.map +1 -1
- package/dist/esm/components/Footer/Footer.js +2 -2
- package/dist/esm/components/Footer/Footer.js.map +1 -1
- package/dist/esm/components/GlobalActions/GlobalActions.js +44 -22
- package/dist/esm/components/GlobalActions/GlobalActions.js.map +1 -1
- package/dist/esm/components/GlobalActions/GlobalActions.styles.js +42 -87
- package/dist/esm/components/GlobalActions/GlobalActions.styles.js.map +1 -1
- package/dist/esm/components/List/List.styles.js +13 -28
- package/dist/esm/components/List/List.styles.js.map +1 -1
- package/dist/esm/components/ListContainer/ListContainer.js +10 -5
- package/dist/esm/components/ListContainer/ListContainer.js.map +1 -1
- package/dist/esm/components/ListContainer/ListContainer.styles.js +12 -0
- package/dist/esm/components/ListContainer/ListContainer.styles.js.map +1 -0
- package/dist/esm/components/ListContainer/ListContext/ListContext.js.map +1 -1
- package/dist/esm/components/ListContainer/ListItem/ListItem.js +46 -33
- package/dist/esm/components/ListContainer/ListItem/ListItem.js.map +1 -1
- package/dist/esm/components/ListContainer/ListItem/ListItem.styles.js +47 -73
- package/dist/esm/components/ListContainer/ListItem/ListItem.styles.js.map +1 -1
- package/dist/esm/components/Loading/Loading.js +21 -15
- package/dist/esm/components/Loading/Loading.js.map +1 -1
- package/dist/esm/components/Loading/Loading.styles.js +44 -94
- package/dist/esm/components/Loading/Loading.styles.js.map +1 -1
- package/dist/esm/components/RadioGroup/RadioGroup.styles.js +0 -4
- package/dist/esm/components/RadioGroup/RadioGroup.styles.js.map +1 -1
- package/dist/esm/components/ScrollTo/Horizontal/ScrollToHorizontal.js +2 -2
- package/dist/esm/components/ScrollTo/Horizontal/ScrollToHorizontal.js.map +1 -1
- package/dist/esm/components/ScrollTo/Vertical/ScrollToVertical.js +2 -2
- package/dist/esm/components/ScrollTo/Vertical/ScrollToVertical.js.map +1 -1
- package/dist/esm/components/SelectionList/SelectionList.js +28 -17
- package/dist/esm/components/SelectionList/SelectionList.js.map +1 -1
- package/dist/esm/components/SelectionList/SelectionList.styles.js +41 -117
- package/dist/esm/components/SelectionList/SelectionList.styles.js.map +1 -1
- package/dist/esm/components/Stack/Stack.js +11 -9
- package/dist/esm/components/Stack/Stack.js.map +1 -1
- package/dist/esm/components/Stack/Stack.styles.js +18 -35
- package/dist/esm/components/Stack/Stack.styles.js.map +1 -1
- package/dist/esm/components/Tab/Tab.js +15 -10
- package/dist/esm/components/Tab/Tab.js.map +1 -1
- package/dist/esm/components/Tab/Tab.styles.js +53 -55
- package/dist/esm/components/Tab/Tab.styles.js.map +1 -1
- package/dist/esm/components/Table/Table.styles.js +6 -7
- package/dist/esm/components/Table/Table.styles.js.map +1 -1
- package/dist/esm/components/Table/TableRow/TableRow.styles.js +6 -22
- package/dist/esm/components/Table/TableRow/TableRow.styles.js.map +1 -1
- package/dist/esm/components/Table/hooks/useSticky.js +5 -1
- package/dist/esm/components/Table/hooks/useSticky.js.map +1 -1
- package/dist/esm/components/Table/utils/utils.js +15 -42
- package/dist/esm/components/Table/utils/utils.js.map +1 -1
- package/dist/esm/components/Tabs/Tabs.js +14 -10
- package/dist/esm/components/Tabs/Tabs.js.map +1 -1
- package/dist/esm/components/Tabs/Tabs.styles.js +16 -18
- package/dist/esm/components/Tabs/Tabs.styles.js.map +1 -1
- package/dist/esm/components/TagsInput/TagsInput.styles.js +6 -6
- package/dist/esm/components/TextArea/TextArea.js +35 -23
- package/dist/esm/components/TextArea/TextArea.js.map +1 -1
- package/dist/esm/components/TextArea/TextArea.styles.js +45 -140
- package/dist/esm/components/TextArea/TextArea.styles.js.map +1 -1
- package/dist/esm/components/Typography/Typography.js +2 -2
- package/dist/esm/components/Typography/Typography.js.map +1 -1
- package/dist/esm/components/VerticalNavigation/NavigationSlider/NavigationSlider.styles.js +3 -3
- package/dist/esm/components/VerticalNavigation/NavigationSlider/NavigationSlider.styles.js.map +1 -1
- package/dist/esm/components/VerticalNavigation/TreeView/TreeViewItem.styles.js +4 -11
- package/dist/esm/components/VerticalNavigation/TreeView/TreeViewItem.styles.js.map +1 -1
- package/dist/esm/components/VerticalNavigation/TreeView/descendants.js +1 -9
- package/dist/esm/components/VerticalNavigation/TreeView/descendants.js.map +1 -1
- package/dist/esm/index.js +236 -236
- package/dist/types/index.d.ts +452 -385
- package/package.json +3 -3
- package/dist/cjs/components/GlobalActions/globalActionsClasses.cjs +0 -8
- package/dist/cjs/components/GlobalActions/globalActionsClasses.cjs.map +0 -1
- package/dist/cjs/components/ListContainer/ListItem/listItemClasses.cjs +0 -8
- package/dist/cjs/components/ListContainer/ListItem/listItemClasses.cjs.map +0 -1
- package/dist/cjs/components/ListContainer/listContainerClasses.cjs +0 -8
- package/dist/cjs/components/ListContainer/listContainerClasses.cjs.map +0 -1
- package/dist/cjs/components/Loading/loadingClasses.cjs +0 -8
- package/dist/cjs/components/Loading/loadingClasses.cjs.map +0 -1
- package/dist/cjs/components/SelectionList/selectionListClasses.cjs +0 -8
- package/dist/cjs/components/SelectionList/selectionListClasses.cjs.map +0 -1
- package/dist/cjs/components/Stack/stackClasses.cjs +0 -8
- package/dist/cjs/components/Stack/stackClasses.cjs.map +0 -1
- package/dist/cjs/components/Tab/tabClasses.cjs +0 -8
- package/dist/cjs/components/Tab/tabClasses.cjs.map +0 -1
- package/dist/cjs/components/Tabs/tabsClasses.cjs +0 -8
- package/dist/cjs/components/Tabs/tabsClasses.cjs.map +0 -1
- package/dist/cjs/components/TextArea/textAreaClasses.cjs +0 -8
- package/dist/cjs/components/TextArea/textAreaClasses.cjs.map +0 -1
- package/dist/esm/components/GlobalActions/globalActionsClasses.js +0 -8
- package/dist/esm/components/GlobalActions/globalActionsClasses.js.map +0 -1
- package/dist/esm/components/ListContainer/ListItem/listItemClasses.js +0 -8
- package/dist/esm/components/ListContainer/ListItem/listItemClasses.js.map +0 -1
- package/dist/esm/components/ListContainer/listContainerClasses.js +0 -8
- package/dist/esm/components/ListContainer/listContainerClasses.js.map +0 -1
- package/dist/esm/components/Loading/loadingClasses.js +0 -8
- package/dist/esm/components/Loading/loadingClasses.js.map +0 -1
- package/dist/esm/components/SelectionList/selectionListClasses.js +0 -8
- package/dist/esm/components/SelectionList/selectionListClasses.js.map +0 -1
- package/dist/esm/components/Stack/stackClasses.js +0 -8
- package/dist/esm/components/Stack/stackClasses.js.map +0 -1
- package/dist/esm/components/Tab/tabClasses.js +0 -8
- package/dist/esm/components/Tab/tabClasses.js.map +0 -1
- package/dist/esm/components/Tabs/tabsClasses.js +0 -8
- package/dist/esm/components/Tabs/tabsClasses.js.map +0 -1
- package/dist/esm/components/TextArea/textAreaClasses.js +0 -8
- package/dist/esm/components/TextArea/textAreaClasses.js.map +0 -1
|
@@ -3,13 +3,11 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
3
3
|
const React = require("react");
|
|
4
4
|
const styles = require("@mui/material/styles");
|
|
5
5
|
const MuiDivider = require("@mui/material/Divider");
|
|
6
|
-
const clsx = require("clsx");
|
|
7
6
|
const isString = require("lodash/isString");
|
|
8
7
|
const isBoolean = require("lodash/isBoolean");
|
|
9
8
|
const useWidth = require("../../hooks/useWidth.cjs");
|
|
10
9
|
const useDefaultProps = require("../../hooks/useDefaultProps.cjs");
|
|
11
10
|
const Stack_styles = require("./Stack.styles.cjs");
|
|
12
|
-
const stackClasses = require("./stackClasses.cjs");
|
|
13
11
|
const jsxRuntime = require("@emotion/react/jsx-runtime");
|
|
14
12
|
const Focus = require("../Focus/Focus.cjs");
|
|
15
13
|
const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
|
|
@@ -29,7 +27,7 @@ const getDirection = (direction, width, breakpoints) => {
|
|
|
29
27
|
};
|
|
30
28
|
const HvStack = (props) => {
|
|
31
29
|
const {
|
|
32
|
-
classes,
|
|
30
|
+
classes: classesProp,
|
|
33
31
|
className,
|
|
34
32
|
children,
|
|
35
33
|
direction = "column",
|
|
@@ -39,6 +37,10 @@ const HvStack = (props) => {
|
|
|
39
37
|
dividerProps = {},
|
|
40
38
|
...others
|
|
41
39
|
} = useDefaultProps.useDefaultProps("HvStack", props);
|
|
40
|
+
const {
|
|
41
|
+
classes,
|
|
42
|
+
cx
|
|
43
|
+
} = Stack_styles.useClasses(classesProp);
|
|
42
44
|
const width = useWidth.useWidth();
|
|
43
45
|
const containerRef = React.useRef(null);
|
|
44
46
|
const {
|
|
@@ -56,11 +58,9 @@ const HvStack = (props) => {
|
|
|
56
58
|
}
|
|
57
59
|
return divider;
|
|
58
60
|
}, [divider, dividerProps, processedDirection]);
|
|
59
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
61
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", {
|
|
60
62
|
ref: containerRef,
|
|
61
|
-
className:
|
|
62
|
-
$direction: processedDirection,
|
|
63
|
-
$breakpoint: spacing,
|
|
63
|
+
className: cx(classes.root, classes[processedDirection], classes[spacing], className),
|
|
64
64
|
...others,
|
|
65
65
|
children: React__default.default.Children.map(children, (child, i) => {
|
|
66
66
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
@@ -79,5 +79,6 @@ const HvStack = (props) => {
|
|
|
79
79
|
})
|
|
80
80
|
});
|
|
81
81
|
};
|
|
82
|
+
exports.stackClasses = Stack_styles.staticClasses;
|
|
82
83
|
exports.HvStack = HvStack;
|
|
83
84
|
//# sourceMappingURL=Stack.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Stack.cjs","sources":["../../../../src/components/Stack/Stack.tsx"],"sourcesContent":["import React, { useMemo, useRef, useCallback } from \"react\";\n\nimport { useTheme } from \"@mui/material/styles\";\nimport MuiDivider, {\n DividerProps as MuiDividerProps,\n} from \"@mui/material/Divider\";\n\nimport
|
|
1
|
+
{"version":3,"file":"Stack.cjs","sources":["../../../../src/components/Stack/Stack.tsx"],"sourcesContent":["import React, { useMemo, useRef, useCallback } from \"react\";\n\nimport { useTheme } from \"@mui/material/styles\";\nimport MuiDivider, {\n DividerProps as MuiDividerProps,\n} from \"@mui/material/Divider\";\n\nimport isString from \"lodash/isString\";\nimport isBoolean from \"lodash/isBoolean\";\n\nimport { useWidth } from \"@core/hooks/useWidth\";\nimport { useDefaultProps } from \"@core/hooks/useDefaultProps\";\nimport { HvBaseProps } from \"@core/types/generic\";\nimport { HvFocus } from \"@core/components/Focus\";\nimport { HvBreakpoints } from \"@core/types/tokens\";\nimport { ExtractNames } from \"@core/utils/classes\";\n\nimport { useClasses, staticClasses } from \"./Stack.styles\";\n\nexport { staticClasses as stackClasses };\n\nexport type HvStackClasses = ExtractNames<typeof useClasses>;\n\nexport type HvStackDirection = \"column\" | \"row\" | Partial<HvStackBreakpoints>;\nexport interface HvStackBreakpoints extends Record<HvBreakpoints, string> {}\n\nexport interface HvStackProps extends HvBaseProps {\n /** The direction of the stack. Can be either a string or an object that states the direction for each breakpoint. */\n direction?: HvStackDirection;\n /** The spacing between elements of the stack. */\n spacing?: HvBreakpoints;\n /** The divider component to be used between the stack elements.\n * - If `true` the Material-UI Divider component will be used.\n * - If a React node is passed then the custom divider will be used.\n */\n divider?: boolean | React.ReactNode;\n /** The properties to pass on to the Material-UI component. */\n dividerProps?: MuiDividerProps;\n /** Sets whether or not there should be arrow navigation between the stack elements. */\n withNavigation?: boolean;\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: HvStackClasses;\n}\n\n/**\n * @returns {string} - Returns a direction for the stack: column or row. If the\n * `direction` property is a string and a valid direction then we\n * use it. If it's an object with multiple directions by breakpoint\n * we use the appropriate one or search for the nearest breakpoint\n * smaller than the current one to use.\n */\nconst getDirection = (direction, width, breakpoints) => {\n if (isString(direction)) return direction;\n\n for (let i = breakpoints.indexOf(width); i >= 0; i -= 1) {\n if (direction[breakpoints[i]] !== undefined) {\n return direction[breakpoints[i]];\n }\n }\n return \"column\";\n};\n\n/**\n * A Stack component allows the organization of its children in a vertical or horizontal layout.\n *\n * It also allows the specification of the spacing between the stack elements and the addition of a divider between the elements.\n */\nexport const HvStack = (props: HvStackProps) => {\n const {\n classes: classesProp,\n className,\n children,\n direction = \"column\",\n spacing = \"sm\",\n divider = false,\n withNavigation = false,\n dividerProps = {},\n ...others\n } = useDefaultProps(\"HvStack\", props);\n const { classes, cx } = useClasses(classesProp);\n\n const width = useWidth();\n const containerRef = useRef(null);\n const { breakpoints } = useTheme();\n\n const processedDirection = useMemo(\n () => getDirection(direction, width, breakpoints.keys),\n [direction, width, breakpoints]\n );\n\n /**\n * @returns {node} - The divider component to use. If the property `divider` is\n * set to `true` then the Material-UI divider is used, otherwise\n * we use the custom divider the user passed.\n */\n const getDividerComponent = useCallback(() => {\n if (isBoolean(divider) && divider) {\n return (\n <MuiDivider\n orientation={\n processedDirection === \"column\" ? \"horizontal\" : \"vertical\"\n }\n flexItem={processedDirection === \"row\"}\n role=\"separator\"\n {...dividerProps}\n />\n );\n }\n return divider;\n }, [divider, dividerProps, processedDirection]);\n\n return (\n <div\n ref={containerRef}\n className={cx(\n classes.root,\n classes[processedDirection],\n classes[spacing],\n className\n )}\n {...others}\n >\n {React.Children.map(children, (child, i) => {\n return (\n <>\n {divider && i !== 0 && getDividerComponent()}\n {withNavigation ? (\n <HvFocus\n rootRef={containerRef}\n focusDisabled={false}\n strategy=\"grid\"\n navigationJump={\n processedDirection === \"column\"\n ? 1\n : React.Children.count(children) || 0\n }\n filterClass=\"child\"\n >\n <div className=\"child\">{child}</div>\n </HvFocus>\n ) : (\n child\n )}\n </>\n );\n })}\n </div>\n );\n};\n"],"names":["getDirection","direction","width","breakpoints","isString","i","indexOf","undefined","HvStack","props","classes","classesProp","className","children","spacing","divider","withNavigation","dividerProps","others","useDefaultProps","cx","useClasses","useWidth","containerRef","useRef","useTheme","processedDirection","useMemo","keys","getDividerComponent","useCallback","isBoolean","MuiDivider","orientation","flexItem","role","ref","root","React","Children","map","child","_Fragment","_jsx","HvFocus","rootRef","focusDisabled","strategy","navigationJump","count","filterClass"],"mappings":";;;;;;;;;;;;;;;;;AAmDA,MAAMA,eAAeA,CAACC,WAAWC,OAAOC,gBAAgB;AACtD,MAAIC,kBAAAA,QAASH,SAAS;AAAUA,WAAAA;AAEvBI,WAAAA,IAAIF,YAAYG,QAAQJ,KAAK,GAAGG,KAAK,GAAGA,KAAK,GAAG;AACvD,QAAIJ,UAAUE,YAAYE,CAAC,CAAC,MAAME,QAAW;AACpCN,aAAAA,UAAUE,YAAYE,CAAC,CAAC;AAAA,IACjC;AAAA,EACF;AACO,SAAA;AACT;AAOaG,MAAAA,UAAUA,CAACC,UAAwB;AACxC,QAAA;AAAA,IACJC,SAASC;AAAAA,IACTC;AAAAA,IACAC;AAAAA,IACAZ,YAAY;AAAA,IACZa,UAAU;AAAA,IACVC,UAAU;AAAA,IACVC,iBAAiB;AAAA,IACjBC,eAAe,CAAC;AAAA,IAChB,GAAGC;AAAAA,EAAAA,IACDC,gBAAgB,gBAAA,WAAWV,KAAK;AAC9B,QAAA;AAAA,IAAEC;AAAAA,IAASU;AAAAA,EAAAA,IAAOC,aAAAA,WAAWV,WAAW;AAE9C,QAAMT,QAAQoB,SAAAA;AACRC,QAAAA,eAAeC,aAAO,IAAI;AAC1B,QAAA;AAAA,IAAErB;AAAAA,MAAgBsB,OAAS,SAAA;AAEjC,QAAMC,qBAAqBC,MAAAA,QACzB,MAAM3B,aAAaC,WAAWC,OAAOC,YAAYyB,IAAI,GACrD,CAAC3B,WAAWC,OAAOC,WAAW,CAChC;AAOM0B,QAAAA,sBAAsBC,MAAAA,YAAY,MAAM;AACxCC,QAAAA,mBAAAA,QAAUhB,OAAO,KAAKA,SAAS;AACjC,4CACGiB,oBAAAA,SAAU;AAAA,QACTC,aACEP,uBAAuB,WAAW,eAAe;AAAA,QAEnDQ,UAAUR,uBAAuB;AAAA,QACjCS,MAAK;AAAA,QAAW,GACZlB;AAAAA,MAAAA,CACL;AAAA,IAEL;AACOF,WAAAA;AAAAA,EACN,GAAA,CAACA,SAASE,cAAcS,kBAAkB,CAAC;AAE9C,wCACE,OAAA;AAAA,IACEU,KAAKb;AAAAA,IACLX,WAAWQ,GACTV,QAAQ2B,MACR3B,QAAQgB,kBAAkB,GAC1BhB,QAAQI,OAAO,GACfF,SACF;AAAA,IAAE,GACEM;AAAAA,IAAML,UAETyB,eAAMC,QAAAA,SAASC,IAAI3B,UAAU,CAAC4B,OAAOpC,MAAM;AAC1C,6CACEqC,WAAAA,UAAA;AAAA,QAAA7B,UACGE,CAAAA,WAAWV,MAAM,KAAKwB,uBACtBb,iBACC2B,2BAAAA,IAACC,eAAO;AAAA,UACNC,SAAStB;AAAAA,UACTuB,eAAe;AAAA,UACfC,UAAS;AAAA,UACTC,gBACEtB,uBAAuB,WACnB,IACAY,uBAAMC,SAASU,MAAMpC,QAAQ,KAAK;AAAA,UAExCqC,aAAY;AAAA,UAAOrC,yCAEnB,OAAA;AAAA,YAAKD,WAAU;AAAA,YAAOC,UAAE4B;AAAAA,UAAAA,CAAW;AAAA,QAC5B,CAAA,IAETA,KACD;AAAA,MAAA,CACD;AAAA,IAAA,CAEL;AAAA,EAAA,CACE;AAET;;;"}
|
|
@@ -1,55 +1,36 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const _styled = require("@emotion/styled/base");
|
|
4
3
|
const uikitStyles = require("@hitachivantara/uikit-styles");
|
|
5
|
-
const
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
target[key] = source[key];
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
return target;
|
|
19
|
-
};
|
|
20
|
-
return _extends.apply(this, arguments);
|
|
21
|
-
}
|
|
22
|
-
const StyledRoot = /* @__PURE__ */ _styled__default.default("div", process.env.NODE_ENV === "production" ? _extends({}, {
|
|
23
|
-
target: "evwozt80"
|
|
24
|
-
}, transientOptions.transientOptions) : _extends({}, {
|
|
25
|
-
target: "evwozt80",
|
|
26
|
-
label: "StyledRoot"
|
|
27
|
-
}, transientOptions.transientOptions))(({
|
|
28
|
-
$direction,
|
|
29
|
-
$breakpoint
|
|
30
|
-
}) => ({
|
|
31
|
-
display: "flex",
|
|
32
|
-
...$direction === "column" && {
|
|
4
|
+
const classes = require("../../utils/classes.cjs");
|
|
5
|
+
const {
|
|
6
|
+
staticClasses,
|
|
7
|
+
useClasses
|
|
8
|
+
} = classes.createClasses("HvStack", {
|
|
9
|
+
root: {
|
|
10
|
+
display: "flex"
|
|
11
|
+
},
|
|
12
|
+
column: {
|
|
33
13
|
flexDirection: "column"
|
|
34
14
|
},
|
|
35
|
-
|
|
15
|
+
row: {
|
|
36
16
|
flexDirection: "row"
|
|
37
17
|
},
|
|
38
|
-
|
|
18
|
+
xs: {
|
|
39
19
|
gap: uikitStyles.theme.space.xs
|
|
40
20
|
},
|
|
41
|
-
|
|
21
|
+
sm: {
|
|
42
22
|
gap: uikitStyles.theme.space.sm
|
|
43
23
|
},
|
|
44
|
-
|
|
24
|
+
md: {
|
|
45
25
|
gap: uikitStyles.theme.spacing(4)
|
|
46
26
|
},
|
|
47
|
-
|
|
27
|
+
lg: {
|
|
48
28
|
gap: uikitStyles.theme.spacing(6)
|
|
49
29
|
},
|
|
50
|
-
|
|
30
|
+
xl: {
|
|
51
31
|
gap: uikitStyles.theme.spacing(11)
|
|
52
32
|
}
|
|
53
|
-
})
|
|
54
|
-
exports.
|
|
33
|
+
});
|
|
34
|
+
exports.staticClasses = staticClasses;
|
|
35
|
+
exports.useClasses = useClasses;
|
|
55
36
|
//# sourceMappingURL=Stack.styles.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Stack.styles.cjs","sources":["../../../../src/components/Stack/Stack.styles.tsx"],"sourcesContent":["import
|
|
1
|
+
{"version":3,"file":"Stack.styles.cjs","sources":["../../../../src/components/Stack/Stack.styles.tsx"],"sourcesContent":["import { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { createClasses } from \"@core/utils/classes\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvStack\", {\n root: {\n display: \"flex\",\n },\n column: {\n flexDirection: \"column\",\n },\n row: {\n flexDirection: \"row\",\n },\n xs: {\n gap: theme.space.xs,\n },\n sm: {\n gap: theme.space.sm,\n },\n md: {\n gap: theme.spacing(4),\n },\n lg: {\n gap: theme.spacing(6),\n },\n xl: {\n gap: theme.spacing(11),\n },\n});\n"],"names":["staticClasses","useClasses","createClasses","root","display","column","flexDirection","row","xs","gap","theme","space","sm","md","spacing","lg","xl"],"mappings":";;;;AAIa,MAAA;AAAA,EAAEA;AAAAA,EAAeC;AAAW,IAAIC,QAAAA,cAAc,WAAW;AAAA,EACpEC,MAAM;AAAA,IACJC,SAAS;AAAA,EACX;AAAA,EACAC,QAAQ;AAAA,IACNC,eAAe;AAAA,EACjB;AAAA,EACAC,KAAK;AAAA,IACHD,eAAe;AAAA,EACjB;AAAA,EACAE,IAAI;AAAA,IACFC,KAAKC,YAAAA,MAAMC,MAAMH;AAAAA,EACnB;AAAA,EACAI,IAAI;AAAA,IACFH,KAAKC,YAAAA,MAAMC,MAAMC;AAAAA,EACnB;AAAA,EACAC,IAAI;AAAA,IACFJ,KAAKC,YAAAA,MAAMI,QAAQ,CAAC;AAAA,EACtB;AAAA,EACAC,IAAI;AAAA,IACFN,KAAKC,YAAAA,MAAMI,QAAQ,CAAC;AAAA,EACtB;AAAA,EACAE,IAAI;AAAA,IACFP,KAAKC,YAAAA,MAAMI,QAAQ,EAAE;AAAA,EACvB;AACF,CAAC;;;"}
|
|
@@ -1,30 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
+
const material = require("@mui/material");
|
|
3
4
|
const useDefaultProps = require("../../hooks/useDefaultProps.cjs");
|
|
4
|
-
const clsx = require("clsx");
|
|
5
5
|
const Tab_styles = require("./Tab.styles.cjs");
|
|
6
|
-
const tabClasses = require("./tabClasses.cjs");
|
|
7
6
|
const jsxRuntime = require("@emotion/react/jsx-runtime");
|
|
8
7
|
const HvTab = (props) => {
|
|
9
8
|
const {
|
|
10
|
-
classes,
|
|
9
|
+
classes: classesProp,
|
|
11
10
|
iconPosition = "top",
|
|
12
11
|
disabled = false,
|
|
13
12
|
...others
|
|
14
13
|
} = useDefaultProps.useDefaultProps("HvTab", props);
|
|
15
|
-
|
|
14
|
+
const {
|
|
15
|
+
classes,
|
|
16
|
+
cx
|
|
17
|
+
} = Tab_styles.useClasses(classesProp);
|
|
18
|
+
return /* @__PURE__ */ jsxRuntime.jsx(material.Tab, {
|
|
16
19
|
classes: {
|
|
17
|
-
root:
|
|
18
|
-
selected:
|
|
19
|
-
disabled:
|
|
20
|
+
root: classes.root,
|
|
21
|
+
selected: classes.selected,
|
|
22
|
+
disabled: classes.disabled
|
|
20
23
|
},
|
|
21
24
|
disableRipple: true,
|
|
22
25
|
disableTouchRipple: true,
|
|
23
|
-
focusVisibleClassName:
|
|
26
|
+
focusVisibleClassName: cx("HvIsFocusVisible", classes.focusVisible),
|
|
24
27
|
disabled,
|
|
25
28
|
iconPosition,
|
|
26
29
|
...others
|
|
27
30
|
});
|
|
28
31
|
};
|
|
32
|
+
exports.tabClasses = Tab_styles.staticClasses;
|
|
29
33
|
exports.HvTab = HvTab;
|
|
30
34
|
//# sourceMappingURL=Tab.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tab.cjs","sources":["../../../../src/components/Tab/Tab.tsx"],"sourcesContent":["import { TabProps as MuiTabProps } from \"@mui/material\";\nimport { useDefaultProps } from \"@core/hooks/useDefaultProps\";\
|
|
1
|
+
{"version":3,"file":"Tab.cjs","sources":["../../../../src/components/Tab/Tab.tsx"],"sourcesContent":["import { Tab, TabProps as MuiTabProps } from \"@mui/material\";\nimport { useDefaultProps } from \"@core/hooks/useDefaultProps\";\nimport { HvBaseProps } from \"@core/types/generic\";\nimport { ExtractNames } from \"@core/utils/classes\";\nimport { staticClasses, useClasses } from \"./Tab.styles\";\n\nexport { staticClasses as tabClasses };\n\nexport type HvTabClasses = ExtractNames<typeof useClasses>;\n\n// Mui Tab props: https://mui.com/material-ui/api/tab/#props\nexport interface HvTabProps\n extends Omit<MuiTabProps, \"children\">,\n HvBaseProps<HTMLDivElement, \"children\"> {\n /** If `true`, the tab will be disabled. */\n disabled?: boolean;\n /** The icon element. */\n icon?: React.ReactElement | string;\n /** The label element. */\n label?: React.ReactNode;\n /** The position of the icon relative to the label. */\n iconPosition?: \"bottom\" | \"end\" | \"start\" | \"top\";\n /** A Jss Object used to override or extend the component styles. */\n classes?: HvTabClasses;\n}\n\nexport const HvTab = (props: HvTabProps) => {\n const {\n classes: classesProp,\n iconPosition = \"top\",\n disabled = false,\n ...others\n } = useDefaultProps(\"HvTab\", props);\n const { classes, cx } = useClasses(classesProp);\n\n return (\n <Tab\n classes={{\n root: classes.root,\n selected: classes.selected,\n disabled: classes.disabled,\n }}\n disableRipple\n disableTouchRipple\n // expose the global class HvIsFocusVisible as a marker\n // not to be styled directly, only as helper in specific css queries\n focusVisibleClassName={cx(\"HvIsFocusVisible\", classes.focusVisible)}\n disabled={disabled}\n iconPosition={iconPosition}\n {...others}\n />\n );\n};\n"],"names":["HvTab","props","classes","classesProp","iconPosition","disabled","others","useDefaultProps","cx","useClasses","Tab","root","selected","disableRipple","disableTouchRipple","focusVisibleClassName","focusVisible"],"mappings":";;;;;;AA0BaA,MAAAA,QAAQA,CAACC,UAAsB;AACpC,QAAA;AAAA,IACJC,SAASC;AAAAA,IACTC,eAAe;AAAA,IACfC,WAAW;AAAA,IACX,GAAGC;AAAAA,EAAAA,IACDC,gBAAgB,gBAAA,SAASN,KAAK;AAC5B,QAAA;AAAA,IAAEC;AAAAA,IAASM;AAAAA,EAAAA,IAAOC,WAAAA,WAAWN,WAAW;AAE9C,wCACGO,SAAAA,KAAG;AAAA,IACFR,SAAS;AAAA,MACPS,MAAMT,QAAQS;AAAAA,MACdC,UAAUV,QAAQU;AAAAA,MAClBP,UAAUH,QAAQG;AAAAA,IACpB;AAAA,IACAQ,eAAa;AAAA,IACbC,oBAAkB;AAAA,IAGlBC,uBAAuBP,GAAG,oBAAoBN,QAAQc,YAAY;AAAA,IAClEX;AAAAA,IACAD;AAAAA,IAA2B,GACvBE;AAAAA,EAAAA,CACL;AAEL;;;"}
|
|
@@ -1,68 +1,64 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const
|
|
3
|
+
const classes = require("../../utils/classes.cjs");
|
|
4
4
|
const uikitStyles = require("@hitachivantara/uikit-styles");
|
|
5
|
-
const material = require("@mui/material");
|
|
6
5
|
const focusUtils = require("../../utils/focusUtils.cjs");
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
6
|
+
const {
|
|
7
|
+
staticClasses,
|
|
8
|
+
useClasses
|
|
9
|
+
} = classes.createClasses("HvTab", {
|
|
10
|
+
root: {
|
|
11
|
+
marginTop: "3px",
|
|
12
|
+
padding: uikitStyles.theme.tab.padding,
|
|
13
|
+
minWidth: 70,
|
|
14
|
+
minHeight: 32,
|
|
15
|
+
textTransform: "none",
|
|
16
|
+
fontFamily: uikitStyles.theme.fontFamily.body,
|
|
17
|
+
...uikitStyles.theme.typography.body,
|
|
18
|
+
"&:hover": {
|
|
19
|
+
backgroundColor: uikitStyles.theme.tab.hoverBackgroundColor,
|
|
20
|
+
borderRadius: uikitStyles.theme.tab.hoverBackgroundBorderRadius,
|
|
21
|
+
"&::after": {
|
|
22
|
+
height: "1px",
|
|
23
|
+
backgroundColor: uikitStyles.theme.tab.hoverUnderlineBackgroundColor
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
"&$selected": {
|
|
27
|
+
color: uikitStyles.theme.typography.label.color,
|
|
28
|
+
fontWeight: uikitStyles.theme.typography.label.fontWeight,
|
|
29
|
+
lineHeight: uikitStyles.theme.typography.label.lineHeight,
|
|
30
|
+
letterSpacing: uikitStyles.theme.typography.label.letterSpacing
|
|
31
|
+
},
|
|
32
|
+
"&$disabled": {
|
|
33
|
+
color: uikitStyles.theme.colors.secondary_60,
|
|
34
|
+
cursor: "not-allowed",
|
|
35
|
+
pointerEvents: "all",
|
|
36
|
+
opacity: 1,
|
|
37
|
+
"&:hover": {
|
|
38
|
+
background: "none"
|
|
39
|
+
}
|
|
40
|
+
},
|
|
41
|
+
opacity: 1,
|
|
36
42
|
"&::after": {
|
|
43
|
+
position: "absolute",
|
|
44
|
+
left: 0,
|
|
45
|
+
top: "calc(100% - 1px)",
|
|
37
46
|
height: "1px",
|
|
38
|
-
|
|
47
|
+
width: "100%",
|
|
48
|
+
backgroundColor: uikitStyles.theme.colors.atmo4,
|
|
49
|
+
content: "''"
|
|
50
|
+
},
|
|
51
|
+
// Override Mui styling: https://mui.com/material-ui/api/tab/#css
|
|
52
|
+
"& .MuiTab-iconWrapper": {
|
|
53
|
+
margin: 0
|
|
39
54
|
}
|
|
40
55
|
},
|
|
41
|
-
|
|
56
|
+
focusVisible: {
|
|
42
57
|
...focusUtils.outlineStyles
|
|
43
58
|
},
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
color: uikitStyles.theme.colors.secondary,
|
|
50
|
-
letterSpacing: uikitStyles.theme.typography.label.letterSpacing,
|
|
51
|
-
lineHeight: uikitStyles.theme.typography.label.lineHeight,
|
|
52
|
-
fontWeight: uikitStyles.theme.typography.label.fontWeight
|
|
53
|
-
},
|
|
54
|
-
"&.Mui-disabled": {
|
|
55
|
-
color: uikitStyles.theme.colors.secondary_60,
|
|
56
|
-
cursor: "not-allowed",
|
|
57
|
-
pointerEvents: "all",
|
|
58
|
-
opacity: 1,
|
|
59
|
-
"&:hover": {
|
|
60
|
-
background: "none"
|
|
61
|
-
}
|
|
62
|
-
},
|
|
63
|
-
"& .MuiTab-iconWrapper": {
|
|
64
|
-
margin: 0
|
|
65
|
-
}
|
|
66
|
-
}, process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi9ob21lL3J1bm5lci93b3JrL2h2LXVpa2l0LXJlYWN0L2h2LXVpa2l0LXJlYWN0L3BhY2thZ2VzL2NvcmUvc3JjL2NvbXBvbmVudHMvVGFiL1RhYi5zdHlsZXMudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQVV5QiIsImZpbGUiOiIvaG9tZS9ydW5uZXIvd29yay9odi11aWtpdC1yZWFjdC9odi11aWtpdC1yZWFjdC9wYWNrYWdlcy9jb3JlL3NyYy9jb21wb25lbnRzL1RhYi9UYWIuc3R5bGVzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IENTU1Byb3BlcnRpZXMgfSBmcm9tIFwicmVhY3RcIjtcblxuaW1wb3J0IHN0eWxlZCBmcm9tIFwiQGVtb3Rpb24vc3R5bGVkXCI7XG5cbmltcG9ydCB7IHRoZW1lIH0gZnJvbSBcIkBoaXRhY2hpdmFudGFyYS91aWtpdC1zdHlsZXNcIjtcblxuaW1wb3J0IHsgVGFiIGFzIE11aVRhYiB9IGZyb20gXCJAbXVpL21hdGVyaWFsXCI7XG5cbmltcG9ydCB7IG91dGxpbmVTdHlsZXMgfSBmcm9tIFwiQGNvcmUvdXRpbHMvZm9jdXNVdGlsc1wiO1xuXG5leHBvcnQgY29uc3QgU3R5bGVkVGFiID0gc3R5bGVkKE11aVRhYikoe1xuICAvLyBSb290XG4gIG1hcmdpblRvcDogXCIzcHhcIixcbiAgcGFkZGluZzogdGhlbWUudGFiLnBhZGRpbmcsXG4gIG1pbldpZHRoOiA3MCxcbiAgbWluSGVpZ2h0OiAzMixcbiAgdGV4dFRyYW5zZm9ybTogXCJub25lXCIsXG4gIGZvbnRGYW1pbHk6IHRoZW1lLmZvbnRGYW1pbHkuYm9keSxcbiAgLi4uKHRoZW1lLnR5cG9ncmFwaHkuYm9keSBhcyBDU1NQcm9wZXJ0aWVzKSxcbiAgb3BhY2l0eTogMSxcbiAgXCImOjphZnRlclwiOiB7XG4gICAgcG9zaXRpb246IFwiYWJzb2x1dGVcIixcbiAgICBsZWZ0OiAwLFxuICAgIHRvcDogXCJjYWxjKDEwMCUgLSAxcHgpXCIsXG4gICAgaGVpZ2h0OiBcIjFweFwiLFxuICAgIHdpZHRoOiBcIjEwMCVcIixcbiAgICBiYWNrZ3JvdW5kQ29sb3I6IHRoZW1lLmNvbG9ycy5hdG1vNCxcbiAgICBjb250ZW50OiBcIicnXCIsXG4gIH0sXG4gIFwiJjpob3ZlclwiOiB7XG4gICAgYmFja2dyb3VuZENvbG9yOiB0aGVtZS50YWIuaG92ZXJCYWNrZ3JvdW5kQ29sb3IsXG4gICAgYm9yZGVyUmFkaXVzOiB0aGVtZS50YWIuaG92ZXJCYWNrZ3JvdW5kQm9yZGVyUmFkaXVzLFxuICAgIFwiJjo6YWZ0ZXJcIjoge1xuICAgICAgaGVpZ2h0OiBcIjFweFwiLFxuICAgICAgYmFja2dyb3VuZENvbG9yOiB0aGVtZS50YWIuaG92ZXJVbmRlcmxpbmVCYWNrZ3JvdW5kQ29sb3IsXG4gICAgfSxcbiAgfSxcbiAgXCImOmZvY3VzLXZpc2libGVcIjoge1xuICAgIC4uLm91dGxpbmVTdHlsZXMsXG4gIH0sXG4gIFwiJjpmb2N1c1wiOiB7XG4gICAgb3V0bGluZTogXCJub25lXCIsXG4gIH0sXG5cbiAgLy8gT3ZlcnJpZGUgTXVpIHN0eWxpbmc6IGh0dHBzOi8vbXVpLmNvbS9tYXRlcmlhbC11aS9hcGkvdGFiLyNjc3NcbiAgXCImLk11aS1zZWxlY3RlZFwiOiB7XG4gICAgY29sb3I6IHRoZW1lLmNvbG9ycy5zZWNvbmRhcnksXG4gICAgbGV0dGVyU3BhY2luZzogdGhlbWUudHlwb2dyYXBoeS5sYWJlbC5sZXR0ZXJTcGFjaW5nLFxuICAgIGxpbmVIZWlnaHQ6IHRoZW1lLnR5cG9ncmFwaHkubGFiZWwubGluZUhlaWdodCxcbiAgICBmb250V2VpZ2h0OiB0aGVtZS50eXBvZ3JhcGh5LmxhYmVsLmZvbnRXZWlnaHQsXG4gIH0sXG4gIFwiJi5NdWktZGlzYWJsZWRcIjoge1xuICAgIGNvbG9yOiB0aGVtZS5jb2xvcnMuc2Vjb25kYXJ5XzYwLFxuICAgIGN1cnNvcjogXCJub3QtYWxsb3dlZFwiLFxuICAgIHBvaW50ZXJFdmVudHM6IFwiYWxsXCIsXG4gICAgb3BhY2l0eTogMSxcbiAgICBcIiY6aG92ZXJcIjoge1xuICAgICAgYmFja2dyb3VuZDogXCJub25lXCIsXG4gICAgfSxcbiAgfSxcbiAgXCImIC5NdWlUYWItaWNvbldyYXBwZXJcIjoge1xuICAgIG1hcmdpbjogMCxcbiAgfSxcbn0pO1xuIl19 */");
|
|
67
|
-
exports.StyledTab = StyledTab;
|
|
59
|
+
selected: {},
|
|
60
|
+
disabled: {}
|
|
61
|
+
});
|
|
62
|
+
exports.staticClasses = staticClasses;
|
|
63
|
+
exports.useClasses = useClasses;
|
|
68
64
|
//# sourceMappingURL=Tab.styles.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tab.styles.cjs","sources":["../../../../src/components/Tab/Tab.styles.tsx"],"sourcesContent":["import { CSSProperties } from \"react\";\
|
|
1
|
+
{"version":3,"file":"Tab.styles.cjs","sources":["../../../../src/components/Tab/Tab.styles.tsx"],"sourcesContent":["import { CSSProperties } from \"react\";\nimport { createClasses } from \"@core/utils/classes\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\nimport { outlineStyles } from \"@core/utils/focusUtils\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTab\", {\n root: {\n marginTop: \"3px\",\n padding: theme.tab.padding,\n minWidth: 70,\n minHeight: 32,\n textTransform: \"none\",\n fontFamily: theme.fontFamily.body,\n ...(theme.typography.body as CSSProperties),\n \"&:hover\": {\n backgroundColor: theme.tab.hoverBackgroundColor,\n borderRadius: theme.tab.hoverBackgroundBorderRadius,\n \"&::after\": {\n height: \"1px\",\n backgroundColor: theme.tab.hoverUnderlineBackgroundColor,\n },\n },\n \"&$selected\": {\n color: theme.typography.label.color,\n fontWeight: theme.typography.label.fontWeight,\n lineHeight: theme.typography.label.lineHeight,\n letterSpacing: theme.typography.label.letterSpacing,\n },\n \"&$disabled\": {\n color: theme.colors.secondary_60,\n cursor: \"not-allowed\",\n pointerEvents: \"all\",\n opacity: 1,\n \"&:hover\": {\n background: \"none\",\n },\n },\n opacity: 1,\n \"&::after\": {\n position: \"absolute\",\n left: 0,\n top: \"calc(100% - 1px)\",\n height: \"1px\",\n width: \"100%\",\n backgroundColor: theme.colors.atmo4,\n content: \"''\",\n },\n // Override Mui styling: https://mui.com/material-ui/api/tab/#css\n \"& .MuiTab-iconWrapper\": {\n margin: 0,\n },\n },\n focusVisible: {\n ...outlineStyles,\n },\n selected: {},\n disabled: {},\n});\n"],"names":["staticClasses","useClasses","createClasses","root","marginTop","padding","theme","tab","minWidth","minHeight","textTransform","fontFamily","body","typography","backgroundColor","hoverBackgroundColor","borderRadius","hoverBackgroundBorderRadius","height","hoverUnderlineBackgroundColor","color","label","fontWeight","lineHeight","letterSpacing","colors","secondary_60","cursor","pointerEvents","opacity","background","position","left","top","width","atmo4","content","margin","focusVisible","outlineStyles","selected","disabled"],"mappings":";;;;;AAKa,MAAA;AAAA,EAAEA;AAAAA,EAAeC;AAAW,IAAIC,QAAAA,cAAc,SAAS;AAAA,EAClEC,MAAM;AAAA,IACJC,WAAW;AAAA,IACXC,SAASC,YAAAA,MAAMC,IAAIF;AAAAA,IACnBG,UAAU;AAAA,IACVC,WAAW;AAAA,IACXC,eAAe;AAAA,IACfC,YAAYL,YAAAA,MAAMK,WAAWC;AAAAA,IAC7B,GAAIN,YAAAA,MAAMO,WAAWD;AAAAA,IACrB,WAAW;AAAA,MACTE,iBAAiBR,YAAAA,MAAMC,IAAIQ;AAAAA,MAC3BC,cAAcV,YAAAA,MAAMC,IAAIU;AAAAA,MACxB,YAAY;AAAA,QACVC,QAAQ;AAAA,QACRJ,iBAAiBR,YAAAA,MAAMC,IAAIY;AAAAA,MAC7B;AAAA,IACF;AAAA,IACA,cAAc;AAAA,MACZC,OAAOd,YAAMO,MAAAA,WAAWQ,MAAMD;AAAAA,MAC9BE,YAAYhB,YAAMO,MAAAA,WAAWQ,MAAMC;AAAAA,MACnCC,YAAYjB,YAAMO,MAAAA,WAAWQ,MAAME;AAAAA,MACnCC,eAAelB,YAAMO,MAAAA,WAAWQ,MAAMG;AAAAA,IACxC;AAAA,IACA,cAAc;AAAA,MACZJ,OAAOd,YAAAA,MAAMmB,OAAOC;AAAAA,MACpBC,QAAQ;AAAA,MACRC,eAAe;AAAA,MACfC,SAAS;AAAA,MACT,WAAW;AAAA,QACTC,YAAY;AAAA,MACd;AAAA,IACF;AAAA,IACAD,SAAS;AAAA,IACT,YAAY;AAAA,MACVE,UAAU;AAAA,MACVC,MAAM;AAAA,MACNC,KAAK;AAAA,MACLf,QAAQ;AAAA,MACRgB,OAAO;AAAA,MACPpB,iBAAiBR,YAAAA,MAAMmB,OAAOU;AAAAA,MAC9BC,SAAS;AAAA,IACX;AAAA;AAAA,IAEA,yBAAyB;AAAA,MACvBC,QAAQ;AAAA,IACV;AAAA,EACF;AAAA,EACAC,cAAc;AAAA,IACZ,GAAGC,WAAAA;AAAAA,EACL;AAAA,EACAC,UAAU,CAAC;AAAA,EACXC,UAAU,CAAC;AACb,CAAC;;;"}
|
|
@@ -10,9 +10,7 @@ const {
|
|
|
10
10
|
position: "relative",
|
|
11
11
|
width: "100%",
|
|
12
12
|
...uikitStyles.theme.typography.body,
|
|
13
|
-
|
|
14
|
-
borderSpacing: 0
|
|
15
|
-
},
|
|
13
|
+
borderSpacing: 0,
|
|
16
14
|
"& caption": {
|
|
17
15
|
...uikitStyles.theme.typography.body,
|
|
18
16
|
padding: uikitStyles.theme.space.xs,
|
|
@@ -22,12 +20,13 @@ const {
|
|
|
22
20
|
},
|
|
23
21
|
stickyHeader: {},
|
|
24
22
|
stickyColumns: {
|
|
25
|
-
backgroundColor: uikitStyles.theme.colors.atmo2
|
|
23
|
+
backgroundColor: uikitStyles.theme.colors.atmo2,
|
|
24
|
+
"&": {
|
|
25
|
+
borderSpacing: 0
|
|
26
|
+
}
|
|
26
27
|
},
|
|
27
28
|
listRow: {
|
|
28
|
-
|
|
29
|
-
borderSpacing: `0 ${uikitStyles.theme.space.xs}`
|
|
30
|
-
}
|
|
29
|
+
borderSpacing: `0 ${uikitStyles.theme.space.xs}`
|
|
31
30
|
}
|
|
32
31
|
});
|
|
33
32
|
exports.staticClasses = staticClasses;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Table.styles.cjs","sources":["../../../../src/components/Table/Table.styles.tsx"],"sourcesContent":["import { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { createClasses } from \"@core/utils/classes\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTable\", {\n root: {\n position: \"relative\",\n width: \"100%\",\n\n ...theme.typography.body,\n\n
|
|
1
|
+
{"version":3,"file":"Table.styles.cjs","sources":["../../../../src/components/Table/Table.styles.tsx"],"sourcesContent":["import { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { createClasses } from \"@core/utils/classes\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTable\", {\n root: {\n position: \"relative\",\n width: \"100%\",\n\n ...theme.typography.body,\n\n borderSpacing: 0,\n\n \"& caption\": {\n ...theme.typography.body,\n padding: theme.space.xs,\n textAlign: \"left\",\n captionSide: \"bottom\",\n },\n },\n stickyHeader: {},\n stickyColumns: {\n backgroundColor: theme.colors.atmo2,\n \"&\": {\n borderSpacing: 0,\n },\n },\n listRow: {\n borderSpacing: `0 ${theme.space.xs}`,\n },\n});\n"],"names":["staticClasses","useClasses","createClasses","root","position","width","theme","typography","body","borderSpacing","padding","space","xs","textAlign","captionSide","stickyHeader","stickyColumns","backgroundColor","colors","atmo2","listRow"],"mappings":";;;;AAIa,MAAA;AAAA,EAAEA;AAAAA,EAAeC;AAAW,IAAIC,QAAAA,cAAc,WAAW;AAAA,EACpEC,MAAM;AAAA,IACJC,UAAU;AAAA,IACVC,OAAO;AAAA,IAEP,GAAGC,YAAAA,MAAMC,WAAWC;AAAAA,IAEpBC,eAAe;AAAA,IAEf,aAAa;AAAA,MACX,GAAGH,YAAAA,MAAMC,WAAWC;AAAAA,MACpBE,SAASJ,YAAAA,MAAMK,MAAMC;AAAAA,MACrBC,WAAW;AAAA,MACXC,aAAa;AAAA,IACf;AAAA,EACF;AAAA,EACAC,cAAc,CAAC;AAAA,EACfC,eAAe;AAAA,IACbC,iBAAiBX,YAAAA,MAAMY,OAAOC;AAAAA,IAC9B,KAAK;AAAA,MACHV,eAAe;AAAA,IACjB;AAAA,EACF;AAAA,EACAW,SAAS;AAAA,IACPX,eAAgB,KAAIH,YAAAA,MAAMK,MAAMC;AAAAA,EAClC;AACF,CAAC;;;"}
|
|
@@ -12,21 +12,10 @@ const {
|
|
|
12
12
|
color: "inherit",
|
|
13
13
|
backgroundColor: uikitStyles.theme.table.rowBackgroundColor,
|
|
14
14
|
verticalAlign: "middle",
|
|
15
|
-
outline: 0
|
|
16
|
-
minHeight: 32,
|
|
17
|
-
"tr&": {
|
|
18
|
-
height: 32
|
|
19
|
-
}
|
|
15
|
+
outline: 0
|
|
20
16
|
},
|
|
21
17
|
/** Styles applied to the component root when inside a `HvTableHead`. */
|
|
22
|
-
head: {
|
|
23
|
-
"&:first-of-type": {
|
|
24
|
-
height: 52
|
|
25
|
-
},
|
|
26
|
-
"tr&:first-of-type": {
|
|
27
|
-
height: 52
|
|
28
|
-
}
|
|
29
|
-
},
|
|
18
|
+
head: {},
|
|
30
19
|
/** Styles applied to the component root when inside a `HvTableBody`. */
|
|
31
20
|
body: {},
|
|
32
21
|
/** Styles applied to the component root when inside a `HvTableFooter`. */
|
|
@@ -53,9 +42,11 @@ const {
|
|
|
53
42
|
},
|
|
54
43
|
/** Styles applied to the component root when its table variant is list. */
|
|
55
44
|
variantList: {
|
|
45
|
+
// only applied on custom `display`
|
|
46
|
+
marginBottom: uikitStyles.theme.space.xs,
|
|
47
|
+
borderRadius: uikitStyles.theme.table.rowListBorderRadius,
|
|
56
48
|
...utils.getBorderStyles("row", uikitStyles.theme.table.rowListBorderColor, uikitStyles.theme.table.rowListBorderRadius),
|
|
57
49
|
backgroundColor: uikitStyles.theme.colors.atmo1,
|
|
58
|
-
height: 52,
|
|
59
50
|
"&$selected": {
|
|
60
51
|
...utils.getBorderStyles("row", uikitStyles.theme.colors.secondary, uikitStyles.theme.table.rowListBorderRadius),
|
|
61
52
|
"&:hover": {
|
|
@@ -71,14 +62,7 @@ const {
|
|
|
71
62
|
},
|
|
72
63
|
/** Styles applied to the component root when its table variant is list. */
|
|
73
64
|
variantListHead: {
|
|
74
|
-
backgroundColor: uikitStyles.theme.table.rowListBackgroundColor
|
|
75
|
-
height: 16,
|
|
76
|
-
"&:first-of-type": {
|
|
77
|
-
height: 16
|
|
78
|
-
},
|
|
79
|
-
"tr&:first-of-type": {
|
|
80
|
-
height: 16
|
|
81
|
-
}
|
|
65
|
+
backgroundColor: uikitStyles.theme.table.rowListBackgroundColor
|
|
82
66
|
}
|
|
83
67
|
});
|
|
84
68
|
exports.staticClasses = staticClasses;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableRow.styles.cjs","sources":["../../../../../src/components/Table/TableRow/TableRow.styles.tsx"],"sourcesContent":["import { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { createClasses } from \"@core/utils/classes\";\n\nimport { getBorderStyles } from \"../utils/utils\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTableRow\", {\n /** Styles applied to the component root class. */\n root: {\n color: \"inherit\",\n backgroundColor: theme.table.rowBackgroundColor,\n verticalAlign: \"middle\",\n outline: 0,\n
|
|
1
|
+
{"version":3,"file":"TableRow.styles.cjs","sources":["../../../../../src/components/Table/TableRow/TableRow.styles.tsx"],"sourcesContent":["import { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { createClasses } from \"@core/utils/classes\";\n\nimport { getBorderStyles } from \"../utils/utils\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTableRow\", {\n /** Styles applied to the component root class. */\n root: {\n color: \"inherit\",\n backgroundColor: theme.table.rowBackgroundColor,\n verticalAlign: \"middle\",\n outline: 0,\n },\n /** Styles applied to the component root when inside a `HvTableHead`. */\n head: {},\n /** Styles applied to the component root when inside a `HvTableBody`. */\n body: {},\n /** Styles applied to the component root when inside a `HvTableFooter`. */\n footer: {},\n /** Styles applied to the component root when selected. */\n selected: {\n backgroundColor: theme.table.selectedRowBackgroundColor,\n },\n /** Styles applied to the component root when expanded. */\n expanded: {\n backgroundColor: theme.colors.atmo1,\n \"& > *[role=cell]\": {\n borderBottom: \"none\",\n },\n },\n /** Styles applied to the component root when striped. */\n striped: {},\n /** Styles applied to the component root on hover. */\n hover: {\n transition: \"background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms\",\n \"&:hover\": {\n backgroundColor: theme.table.rowHoverColor,\n },\n },\n /** Styles applied to the component root when its table variant is list. */\n variantList: {\n // only applied on custom `display`\n marginBottom: theme.space.xs,\n borderRadius: theme.table.rowListBorderRadius,\n\n ...getBorderStyles(\n \"row\",\n theme.table.rowListBorderColor,\n theme.table.rowListBorderRadius\n ),\n backgroundColor: theme.colors.atmo1,\n \"&$selected\": {\n ...getBorderStyles(\n \"row\",\n theme.colors.secondary,\n theme.table.rowListBorderRadius\n ),\n\n \"&:hover\": {\n ...getBorderStyles(\n \"row\",\n theme.table.rowHoverBorderColor,\n theme.table.rowListBorderRadius\n ),\n },\n },\n\n \"&:hover\": {\n ...getBorderStyles(\n \"row\",\n theme.table.rowHoverBorderColor,\n theme.table.rowListBorderRadius\n ),\n },\n \"&.HvIsFocused\": {\n borderRadius: theme.table.rowListBorderRadius,\n },\n },\n /** Styles applied to the component root when its table variant is list. */\n variantListHead: {\n backgroundColor: theme.table.rowListBackgroundColor,\n },\n});\n"],"names":["staticClasses","useClasses","createClasses","root","color","backgroundColor","theme","table","rowBackgroundColor","verticalAlign","outline","head","body","footer","selected","selectedRowBackgroundColor","expanded","colors","atmo1","borderBottom","striped","hover","transition","rowHoverColor","variantList","marginBottom","space","xs","borderRadius","rowListBorderRadius","getBorderStyles","rowListBorderColor","secondary","rowHoverBorderColor","variantListHead","rowListBackgroundColor"],"mappings":";;;;;AAMa,MAAA;AAAA,EAAEA;AAAAA,EAAeC;AAAW,IAAIC,QAAAA,cAAc,cAAc;AAAA;AAAA,EAEvEC,MAAM;AAAA,IACJC,OAAO;AAAA,IACPC,iBAAiBC,YAAAA,MAAMC,MAAMC;AAAAA,IAC7BC,eAAe;AAAA,IACfC,SAAS;AAAA,EACX;AAAA;AAAA,EAEAC,MAAM,CAAC;AAAA;AAAA,EAEPC,MAAM,CAAC;AAAA;AAAA,EAEPC,QAAQ,CAAC;AAAA;AAAA,EAETC,UAAU;AAAA,IACRT,iBAAiBC,YAAAA,MAAMC,MAAMQ;AAAAA,EAC/B;AAAA;AAAA,EAEAC,UAAU;AAAA,IACRX,iBAAiBC,YAAAA,MAAMW,OAAOC;AAAAA,IAC9B,oBAAoB;AAAA,MAClBC,cAAc;AAAA,IAChB;AAAA,EACF;AAAA;AAAA,EAEAC,SAAS,CAAC;AAAA;AAAA,EAEVC,OAAO;AAAA,IACLC,YAAY;AAAA,IACZ,WAAW;AAAA,MACTjB,iBAAiBC,YAAAA,MAAMC,MAAMgB;AAAAA,IAC/B;AAAA,EACF;AAAA;AAAA,EAEAC,aAAa;AAAA;AAAA,IAEXC,cAAcnB,YAAAA,MAAMoB,MAAMC;AAAAA,IAC1BC,cAActB,YAAAA,MAAMC,MAAMsB;AAAAA,IAE1B,GAAGC,sBACD,OACAxB,kBAAMC,MAAMwB,oBACZzB,YAAAA,MAAMC,MAAMsB,mBACd;AAAA,IACAxB,iBAAiBC,YAAAA,MAAMW,OAAOC;AAAAA,IAC9B,cAAc;AAAA,MACZ,GAAGY,sBACD,OACAxB,kBAAMW,OAAOe,WACb1B,YAAAA,MAAMC,MAAMsB,mBACd;AAAA,MAEA,WAAW;AAAA,QACT,GAAGC,sBACD,OACAxB,kBAAMC,MAAM0B,qBACZ3B,YAAAA,MAAMC,MAAMsB,mBACd;AAAA,MACF;AAAA,IACF;AAAA,IAEA,WAAW;AAAA,MACT,GAAGC,sBACD,OACAxB,kBAAMC,MAAM0B,qBACZ3B,YAAAA,MAAMC,MAAMsB,mBACd;AAAA,IACF;AAAA,IACA,iBAAiB;AAAA,MACfD,cAActB,YAAAA,MAAMC,MAAMsB;AAAAA,IAC5B;AAAA,EACF;AAAA;AAAA,EAEAK,iBAAiB;AAAA,IACf7B,iBAAiBC,YAAAA,MAAMC,MAAM4B;AAAAA,EAC/B;AACF,CAAC;;;"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
3
|
const reactTable = require("react-table");
|
|
4
|
+
const uikitStyles = require("@hitachivantara/uikit-styles");
|
|
4
5
|
const isSticky = (value) => /left|right/i.test(value);
|
|
5
6
|
const getStickyValue = ({
|
|
6
7
|
sticky,
|
|
@@ -119,7 +120,10 @@ const getCellProps = (header, isHeaderCell) => {
|
|
|
119
120
|
alignItems: isHeaderCell ? "start" : "center",
|
|
120
121
|
justifyContent: header.align,
|
|
121
122
|
width: `${header.totalWidth}px`,
|
|
122
|
-
minWidth: `${header.totalMinWidth}px
|
|
123
|
+
minWidth: `${header.totalMinWidth}px`,
|
|
124
|
+
...isHeaderCell && {
|
|
125
|
+
backgroundColor: uikitStyles.theme.colors.atmo2
|
|
126
|
+
}
|
|
123
127
|
}
|
|
124
128
|
};
|
|
125
129
|
if (header.sticky != null) {
|