@hitachivantara/uikit-react-core 5.77.0 → 5.78.0
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/Footer/Footer.cjs +1 -1
- package/dist/cjs/Loading/Loading.styles.cjs +4 -2
- package/dist/cjs/MultiButton/MultiButton.cjs +12 -39
- package/dist/cjs/MultiButton/MultiButton.styles.cjs +25 -56
- package/dist/cjs/Select/Select.styles.cjs +1 -0
- package/dist/cjs/Table/TableCell/TableCell.styles.cjs +3 -0
- package/dist/cjs/Table/TableHeader/TableHeader.styles.cjs +3 -0
- package/dist/cjs/Table/TableRow/TableRow.styles.cjs +1 -0
- package/dist/cjs/Table/hooks/useRowExpand.cjs +3 -3
- package/dist/cjs/Tooltip/Tooltip.styles.cjs +12 -6
- package/dist/esm/Footer/Footer.js +1 -1
- package/dist/esm/Footer/Footer.js.map +1 -1
- package/dist/esm/Loading/Loading.styles.js +4 -2
- package/dist/esm/Loading/Loading.styles.js.map +1 -1
- package/dist/esm/MultiButton/MultiButton.js +15 -42
- package/dist/esm/MultiButton/MultiButton.js.map +1 -1
- package/dist/esm/MultiButton/MultiButton.styles.js +25 -56
- package/dist/esm/MultiButton/MultiButton.styles.js.map +1 -1
- package/dist/esm/Select/Select.styles.js +1 -0
- package/dist/esm/Select/Select.styles.js.map +1 -1
- package/dist/esm/Table/TableCell/TableCell.styles.js +3 -0
- package/dist/esm/Table/TableCell/TableCell.styles.js.map +1 -1
- package/dist/esm/Table/TableHeader/TableHeader.styles.js +3 -0
- package/dist/esm/Table/TableHeader/TableHeader.styles.js.map +1 -1
- package/dist/esm/Table/TableRow/TableRow.styles.js +1 -0
- package/dist/esm/Table/TableRow/TableRow.styles.js.map +1 -1
- package/dist/esm/Table/hooks/useRowExpand.js +4 -4
- package/dist/esm/Table/hooks/useRowExpand.js.map +1 -1
- package/dist/esm/Tooltip/Tooltip.js.map +1 -1
- package/dist/esm/Tooltip/Tooltip.styles.js +12 -6
- package/dist/esm/Tooltip/Tooltip.styles.js.map +1 -1
- package/dist/types/index.d.ts +10 -15
- package/package.json +6 -6
|
@@ -11,7 +11,7 @@ const useMediaQuery__default = /* @__PURE__ */ _interopDefault(useMediaQuery);
|
|
|
11
11
|
const HvFooter = (props) => {
|
|
12
12
|
const {
|
|
13
13
|
name = "Hitachi Vantara",
|
|
14
|
-
copyright = `© Hitachi Vantara
|
|
14
|
+
copyright = `© Hitachi Vantara LLC ${(/* @__PURE__ */ new Date()).getFullYear()}. All Rights Reserved.`,
|
|
15
15
|
links,
|
|
16
16
|
classes: classesProp,
|
|
17
17
|
className,
|
|
@@ -12,13 +12,14 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvLoading",
|
|
|
12
12
|
},
|
|
13
13
|
barContainer: {
|
|
14
14
|
display: "flex",
|
|
15
|
+
alignItems: "center",
|
|
15
16
|
justifyContent: "space-around",
|
|
16
17
|
":has($regular)": {
|
|
17
18
|
width: 30,
|
|
18
19
|
height: 30
|
|
19
20
|
},
|
|
20
21
|
":has($small)": {
|
|
21
|
-
"--
|
|
22
|
+
"--height": "40%",
|
|
22
23
|
width: 18,
|
|
23
24
|
height: 18
|
|
24
25
|
}
|
|
@@ -29,9 +30,10 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvLoading",
|
|
|
29
30
|
animation: "loading 1s ease-in-out infinite",
|
|
30
31
|
// TODO: make this the default when it has better support
|
|
31
32
|
width: "round(up, 0.11em, 2px)",
|
|
33
|
+
height: "100%",
|
|
32
34
|
"@keyframes loading": {
|
|
33
35
|
"50%": {
|
|
34
|
-
|
|
36
|
+
height: "var(--height, 60%)",
|
|
35
37
|
backgroundColor: `var(--customColor, ${uikitStyles.theme.colors.secondary})`
|
|
36
38
|
}
|
|
37
39
|
},
|
|
@@ -3,11 +3,9 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
3
3
|
const jsxRuntime = require("react/jsx-runtime");
|
|
4
4
|
const React = require("react");
|
|
5
5
|
const uikitReactUtils = require("@hitachivantara/uikit-react-utils");
|
|
6
|
-
const setId = require("../utils/setId.cjs");
|
|
7
6
|
const MultiButton_styles = require("./MultiButton.styles.cjs");
|
|
8
7
|
const HvMultiButton = (props) => {
|
|
9
8
|
const {
|
|
10
|
-
id,
|
|
11
9
|
className,
|
|
12
10
|
children,
|
|
13
11
|
classes: classesProp,
|
|
@@ -18,13 +16,7 @@ const HvMultiButton = (props) => {
|
|
|
18
16
|
split,
|
|
19
17
|
...others
|
|
20
18
|
} = uikitReactUtils.useDefaultProps("HvMultiButton", props);
|
|
21
|
-
const { classes, cx
|
|
22
|
-
const [color, type] = React.useMemo(() => {
|
|
23
|
-
const result = variant.split(/(?=[A-Z])/);
|
|
24
|
-
if (result[0] === "ghost" || result[0] === "semantic" || result[0] === "secondary" && !result[1])
|
|
25
|
-
return [];
|
|
26
|
-
return result.map((x) => x.toLowerCase());
|
|
27
|
-
}, [variant]);
|
|
19
|
+
const { classes, cx } = MultiButton_styles.useClasses(classesProp);
|
|
28
20
|
const buttons = React.useMemo(() => {
|
|
29
21
|
const btns = [];
|
|
30
22
|
React.Children.forEach(children, (child) => {
|
|
@@ -37,7 +29,6 @@ const HvMultiButton = (props) => {
|
|
|
37
29
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
38
30
|
"div",
|
|
39
31
|
{
|
|
40
|
-
id,
|
|
41
32
|
className: cx(
|
|
42
33
|
classes.root,
|
|
43
34
|
{
|
|
@@ -53,35 +44,17 @@ const HvMultiButton = (props) => {
|
|
|
53
44
|
...others,
|
|
54
45
|
children: buttons.map((child, index) => {
|
|
55
46
|
const childIsSelected = !!child.props.selected;
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}),
|
|
68
|
-
split && index < buttons.length - 1 && /* @__PURE__ */ jsxRuntime.jsx(
|
|
69
|
-
"div",
|
|
70
|
-
{
|
|
71
|
-
className: cx(
|
|
72
|
-
classes.splitContainer,
|
|
73
|
-
color && css(MultiButton_styles.getSplitContainerColor(color, type, disabled)),
|
|
74
|
-
size && css(MultiButton_styles.getSplitContainerHeight(size)),
|
|
75
|
-
{
|
|
76
|
-
[classes.splitDisabled]: disabled
|
|
77
|
-
},
|
|
78
|
-
classes[variant]
|
|
79
|
-
// TODO - remove in v6
|
|
80
|
-
),
|
|
81
|
-
children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: classes.split })
|
|
82
|
-
}
|
|
83
|
-
)
|
|
84
|
-
] }, btnKey);
|
|
47
|
+
return React.cloneElement(child, {
|
|
48
|
+
key: index,
|
|
49
|
+
variant,
|
|
50
|
+
disabled: disabled || child.props.disabled,
|
|
51
|
+
size,
|
|
52
|
+
className: cx(child.props.className, classes.button, {
|
|
53
|
+
[classes.firstButton]: index === 0,
|
|
54
|
+
[classes.lastButton]: index === buttons.length - 1,
|
|
55
|
+
[classes.selected]: childIsSelected
|
|
56
|
+
})
|
|
57
|
+
});
|
|
85
58
|
})
|
|
86
59
|
}
|
|
87
60
|
);
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const uikitReactUtils = require("@hitachivantara/uikit-react-utils");
|
|
4
4
|
const uikitStyles = require("@hitachivantara/uikit-styles");
|
|
5
|
-
const Button_styles = require("../Button/Button.styles.cjs");
|
|
6
5
|
const DropDownMenu_styles = require("../DropDownMenu/DropDownMenu.styles.cjs");
|
|
7
6
|
require("../DropDownMenu/DropDownMenu.cjs");
|
|
8
7
|
const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvMultiButton", {
|
|
@@ -98,44 +97,40 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvMultiButt
|
|
|
98
97
|
splitGroup: {
|
|
99
98
|
width: "fit-content",
|
|
100
99
|
background: uikitStyles.theme.colors.atmo1,
|
|
101
|
-
//
|
|
102
|
-
"& button$button": {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
marginLeft: -1
|
|
108
|
-
}
|
|
109
|
-
},
|
|
110
|
-
"&$lastButton": {
|
|
111
|
-
borderTopLeftRadius: 0,
|
|
112
|
-
borderBottomLeftRadius: 0
|
|
113
|
-
}
|
|
114
|
-
},
|
|
115
|
-
// Dropdown Menu
|
|
116
|
-
[`& .${DropDownMenu_styles.staticClasses.root}`]: {
|
|
117
|
-
"&:has($firstButton)": {
|
|
118
|
-
"& + div$splitContainer": {
|
|
119
|
-
marginRight: -1
|
|
120
|
-
}
|
|
100
|
+
// HvButton, HvDropDownMenu
|
|
101
|
+
"& button$button:not($firstButton), & $button:not($firstButton) button": {
|
|
102
|
+
borderTopLeftRadius: 0,
|
|
103
|
+
borderBottomLeftRadius: 0,
|
|
104
|
+
"&:not([aria-controls])": {
|
|
105
|
+
borderLeftWidth: 0
|
|
121
106
|
}
|
|
122
107
|
},
|
|
123
|
-
|
|
124
|
-
|
|
108
|
+
// HvButton, HvDropDownMenu
|
|
109
|
+
"& button$button:not($lastButton), & $button:not($lastButton) button": {
|
|
125
110
|
borderTopRightRadius: 0,
|
|
126
|
-
borderBottomRightRadius: 0
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
111
|
+
borderBottomRightRadius: 0,
|
|
112
|
+
"&:not([aria-controls])": {
|
|
113
|
+
borderRightWidth: 0
|
|
114
|
+
},
|
|
115
|
+
"&::after": {
|
|
116
|
+
content: "''",
|
|
117
|
+
position: "absolute",
|
|
118
|
+
inset: "4px -1px 4px auto",
|
|
119
|
+
width: 1,
|
|
120
|
+
zIndex: 1,
|
|
121
|
+
height: "auto",
|
|
122
|
+
backgroundColor: "currentcolor"
|
|
123
|
+
}
|
|
132
124
|
},
|
|
125
|
+
// HvDropDownMenu
|
|
133
126
|
[`& .${DropDownMenu_styles.staticClasses.iconSelected}`]: {
|
|
134
127
|
zIndex: 2
|
|
135
128
|
}
|
|
136
129
|
},
|
|
137
130
|
splitGroupDisabled: { background: uikitStyles.theme.colors.atmo3 },
|
|
138
|
-
button: {
|
|
131
|
+
button: {
|
|
132
|
+
position: "relative"
|
|
133
|
+
},
|
|
139
134
|
selected: {},
|
|
140
135
|
vertical: {
|
|
141
136
|
flexDirection: "column",
|
|
@@ -197,23 +192,6 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvMultiButt
|
|
|
197
192
|
}
|
|
198
193
|
}
|
|
199
194
|
},
|
|
200
|
-
split: {
|
|
201
|
-
width: 1,
|
|
202
|
-
height: "100%",
|
|
203
|
-
background: "currentColor"
|
|
204
|
-
},
|
|
205
|
-
splitContainer: {
|
|
206
|
-
display: "flex",
|
|
207
|
-
justifyContent: "center",
|
|
208
|
-
zIndex: 1,
|
|
209
|
-
width: 2,
|
|
210
|
-
paddingTop: 4,
|
|
211
|
-
paddingBottom: 4,
|
|
212
|
-
height: "calc(32px - 2px)"
|
|
213
|
-
},
|
|
214
|
-
splitDisabled: {
|
|
215
|
-
color: uikitStyles.theme.colors.secondary_60
|
|
216
|
-
},
|
|
217
195
|
firstButton: {},
|
|
218
196
|
lastButton: {},
|
|
219
197
|
// TODO - review the need for these classes in v6
|
|
@@ -224,14 +202,5 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvMultiButt
|
|
|
224
202
|
secondarySubtle: {},
|
|
225
203
|
secondaryGhost: {}
|
|
226
204
|
});
|
|
227
|
-
const getSplitContainerColor = (color, type, disabled) => ({
|
|
228
|
-
color: Button_styles.getColoringStyle(color, type).color,
|
|
229
|
-
backgroundColor: disabled ? uikitStyles.theme.colors.atmo3 : type === "subtle" ? uikitStyles.theme.colors.atmo1 : "transparent"
|
|
230
|
-
});
|
|
231
|
-
const getSplitContainerHeight = (size) => ({
|
|
232
|
-
height: `calc(${Button_styles.getSizeStyles(size).height} - 2px)`
|
|
233
|
-
});
|
|
234
|
-
exports.getSplitContainerColor = getSplitContainerColor;
|
|
235
|
-
exports.getSplitContainerHeight = getSplitContainerHeight;
|
|
236
205
|
exports.staticClasses = staticClasses;
|
|
237
206
|
exports.useClasses = useClasses;
|
|
@@ -28,6 +28,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvSelect",
|
|
|
28
28
|
zIndex: uikitStyles.theme.zIndices.popover
|
|
29
29
|
},
|
|
30
30
|
panel: {
|
|
31
|
+
maxHeight: 400,
|
|
31
32
|
border: `1px solid ${uikitStyles.theme.colors.secondary}`,
|
|
32
33
|
marginTop: -1,
|
|
33
34
|
marginBottom: -1
|
|
@@ -7,6 +7,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableCell
|
|
|
7
7
|
/** Styles applied to the component root class. */
|
|
8
8
|
root: {
|
|
9
9
|
verticalAlign: "inherit",
|
|
10
|
+
alignContent: "inherit",
|
|
10
11
|
textAlign: "left",
|
|
11
12
|
padding: `calc(${uikitStyles.theme.space.xs} - 2px ) ${uikitStyles.theme.space.xs} calc(${uikitStyles.theme.space.xs} - 3px ) ${uikitStyles.theme.spacing(4)}`,
|
|
12
13
|
borderBottom: `1px solid ${uikitStyles.theme.colors.atmo4}`
|
|
@@ -15,6 +16,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableCell
|
|
|
15
16
|
head: {
|
|
16
17
|
height: 52,
|
|
17
18
|
verticalAlign: "top",
|
|
19
|
+
alignContent: "start",
|
|
18
20
|
backgroundColor: uikitStyles.theme.colors.atmo1,
|
|
19
21
|
borderTop: "1px solid transparent",
|
|
20
22
|
borderBottom: `1px solid ${uikitStyles.theme.colors.atmo4}`,
|
|
@@ -99,6 +101,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableCell
|
|
|
99
101
|
/** Styles applied to the cell when its variant is list and actions. */
|
|
100
102
|
variantListactions: {
|
|
101
103
|
verticalAlign: "middle",
|
|
104
|
+
alignContent: "center",
|
|
102
105
|
borderLeft: "none",
|
|
103
106
|
paddingLeft: "0",
|
|
104
107
|
textAlign: "center",
|
|
@@ -8,6 +8,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableHead
|
|
|
8
8
|
"--cell-height": "32px",
|
|
9
9
|
height: "var(--cell-height)",
|
|
10
10
|
verticalAlign: "inherit",
|
|
11
|
+
alignContent: "inherit",
|
|
11
12
|
textAlign: "left",
|
|
12
13
|
padding: uikitStyles.theme.spacing(0, 1, 0, 4),
|
|
13
14
|
borderBottom: `1px solid ${uikitStyles.theme.colors.atmo4}`
|
|
@@ -15,6 +16,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableHead
|
|
|
15
16
|
head: {
|
|
16
17
|
paddingTop: 8,
|
|
17
18
|
verticalAlign: "top",
|
|
19
|
+
alignContent: "start",
|
|
18
20
|
...uikitStyles.theme.typography.label,
|
|
19
21
|
transition: "background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms",
|
|
20
22
|
backgroundColor: uikitStyles.theme.colors.atmo1,
|
|
@@ -32,6 +34,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableHead
|
|
|
32
34
|
},
|
|
33
35
|
"&$sortable": {
|
|
34
36
|
verticalAlign: "initial",
|
|
37
|
+
alignContent: "initial",
|
|
35
38
|
paddingTop: 0,
|
|
36
39
|
paddingLeft: 0,
|
|
37
40
|
cursor: "pointer",
|
|
@@ -9,6 +9,7 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTableRow"
|
|
|
9
9
|
color: "inherit",
|
|
10
10
|
backgroundColor: uikitStyles.theme.colors.atmo1,
|
|
11
11
|
verticalAlign: "middle",
|
|
12
|
+
alignContent: "center",
|
|
12
13
|
outline: 0
|
|
13
14
|
},
|
|
14
15
|
/** Styles applied to the component root when inside a `HvTableHead`. */
|
|
@@ -15,7 +15,7 @@ const CellWithExpandButton = ({
|
|
|
15
15
|
labels: labelsProp
|
|
16
16
|
}) => {
|
|
17
17
|
const labels = useLabels.useLabels(DEFAULT_LABELS, labelsProp);
|
|
18
|
-
const
|
|
18
|
+
const rowProps = row.getToggleRowExpandedProps?.();
|
|
19
19
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
20
20
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
21
21
|
Button.HvButton,
|
|
@@ -23,8 +23,8 @@ const CellWithExpandButton = ({
|
|
|
23
23
|
icon: true,
|
|
24
24
|
"aria-label": row.isExpanded ? labels.collapseRowButtonAriaLabel : labels.expandRowButtonAriaLabel,
|
|
25
25
|
"aria-expanded": row.isExpanded,
|
|
26
|
-
onClick,
|
|
27
|
-
children:
|
|
26
|
+
onClick: rowProps?.onClick,
|
|
27
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(uikitReactIcons.DropDownXS, { style: { rotate: row.isExpanded ? "180deg" : void 0 } })
|
|
28
28
|
}
|
|
29
29
|
),
|
|
30
30
|
cell?.value && /* @__PURE__ */ jsxRuntime.jsx(Typography.HvTypography, { variant: "label", component: "span", children: cell.value })
|
|
@@ -6,13 +6,9 @@ const uikitStyles = require("@hitachivantara/uikit-styles");
|
|
|
6
6
|
const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTooltip", {
|
|
7
7
|
root: {},
|
|
8
8
|
tooltip: {},
|
|
9
|
-
tooltipMulti: {},
|
|
10
9
|
popper: {
|
|
11
|
-
|
|
12
|
-
opacity: 1
|
|
13
|
-
},
|
|
10
|
+
// TODO: move this to `tooltip` in v6 and make class always be applied
|
|
14
11
|
[`& .${Tooltip.tooltipClasses.tooltip}`]: {
|
|
15
|
-
fontFamily: uikitStyles.theme.fontFamily.body,
|
|
16
12
|
...uikitStyles.theme.typography.body,
|
|
17
13
|
display: "flex",
|
|
18
14
|
width: "fit-content",
|
|
@@ -56,19 +52,29 @@ const { staticClasses, useClasses } = uikitReactUtils.createClasses("HvTooltip",
|
|
|
56
52
|
padding: uikitStyles.theme.space.sm
|
|
57
53
|
},
|
|
58
54
|
"& $tooltip": {
|
|
59
|
-
padding:
|
|
55
|
+
padding: uikitStyles.theme.space.sm,
|
|
60
56
|
borderRadius: uikitStyles.theme.radii.round,
|
|
61
57
|
"& p": {
|
|
62
58
|
wordBreak: "break-word"
|
|
63
59
|
}
|
|
64
60
|
}
|
|
65
61
|
},
|
|
62
|
+
// TODO: remove in v6
|
|
63
|
+
/** @deprecated */
|
|
64
|
+
tooltipMulti: {},
|
|
65
|
+
/** @deprecated */
|
|
66
66
|
title: {},
|
|
67
|
+
/** @deprecated */
|
|
67
68
|
valuesContainer: {},
|
|
69
|
+
/** @deprecated */
|
|
68
70
|
values: {},
|
|
71
|
+
/** @deprecated */
|
|
69
72
|
color: {},
|
|
73
|
+
/** @deprecated */
|
|
70
74
|
separatorColor: {},
|
|
75
|
+
/** @deprecated */
|
|
71
76
|
separator: {},
|
|
77
|
+
/** @deprecated */
|
|
72
78
|
valueWrapper: {}
|
|
73
79
|
});
|
|
74
80
|
exports.staticClasses = staticClasses;
|
|
@@ -8,7 +8,7 @@ import { HvTypography } from "../Typography/Typography.js";
|
|
|
8
8
|
const HvFooter = (props) => {
|
|
9
9
|
const {
|
|
10
10
|
name = "Hitachi Vantara",
|
|
11
|
-
copyright = `© Hitachi Vantara
|
|
11
|
+
copyright = `© Hitachi Vantara LLC ${(/* @__PURE__ */ new Date()).getFullYear()}. All Rights Reserved.`,
|
|
12
12
|
links,
|
|
13
13
|
classes: classesProp,
|
|
14
14
|
className,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Footer.js","sources":["../../../src/Footer/Footer.tsx"],"sourcesContent":["import { useTheme } from \"@mui/material/styles\";\nimport useMediaQuery from \"@mui/material/useMediaQuery\";\nimport {\n useDefaultProps,\n type ExtractNames,\n} from \"@hitachivantara/uikit-react-utils\";\n\nimport { HvBaseProps } from \"../types/generic\";\nimport { HvTypography } from \"../Typography\";\nimport { staticClasses, useClasses } from \"./Footer.styles\";\n\nexport { staticClasses as footerClasses };\n\nexport type HvFooterClasses = ExtractNames<typeof useClasses>;\n\nexport interface HvFooterProps extends HvBaseProps {\n /** Footer name. */\n name?: React.ReactNode;\n /** Footer copyright. */\n copyright?: React.ReactNode;\n /** Footer links. */\n links?: React.ReactNode;\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: HvFooterClasses;\n}\n\n/**\n * A Footer is a way of providing extra information at the end of a page.\n */\nexport const HvFooter = (props: HvFooterProps) => {\n const {\n name = \"Hitachi Vantara\",\n copyright = `© Hitachi Vantara
|
|
1
|
+
{"version":3,"file":"Footer.js","sources":["../../../src/Footer/Footer.tsx"],"sourcesContent":["import { useTheme } from \"@mui/material/styles\";\nimport useMediaQuery from \"@mui/material/useMediaQuery\";\nimport {\n useDefaultProps,\n type ExtractNames,\n} from \"@hitachivantara/uikit-react-utils\";\n\nimport { HvBaseProps } from \"../types/generic\";\nimport { HvTypography } from \"../Typography\";\nimport { staticClasses, useClasses } from \"./Footer.styles\";\n\nexport { staticClasses as footerClasses };\n\nexport type HvFooterClasses = ExtractNames<typeof useClasses>;\n\nexport interface HvFooterProps extends HvBaseProps {\n /** Footer name. */\n name?: React.ReactNode;\n /** Footer copyright. */\n copyright?: React.ReactNode;\n /** Footer links. */\n links?: React.ReactNode;\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: HvFooterClasses;\n}\n\n/**\n * A Footer is a way of providing extra information at the end of a page.\n */\nexport const HvFooter = (props: HvFooterProps) => {\n const {\n name = \"Hitachi Vantara\",\n copyright = `© Hitachi Vantara LLC ${new Date().getFullYear()}. All Rights Reserved.`,\n links,\n classes: classesProp,\n className,\n ...others\n } = useDefaultProps(\"HvFooter\", props);\n const muiTheme = useTheme();\n const { classes, cx } = useClasses(classesProp);\n\n const isSmDown = useMediaQuery(muiTheme.breakpoints.down(\"sm\"));\n\n return (\n <footer\n className={cx(classes.root, { [classes.small]: isSmDown }, className)}\n {...others}\n >\n <HvTypography variant=\"label\" className={classes.name}>\n {name}\n </HvTypography>\n <div className={classes.rightContainer}>\n <HvTypography className={classes.copyright}>{copyright}</HvTypography>\n {links && <div className={classes.separator} />}\n {links}\n </div>\n </footer>\n );\n};\n"],"names":[],"mappings":";;;;;;;AA6Ba,MAAA,WAAW,CAAC,UAAyB;AAC1C,QAAA;AAAA,IACJ,OAAO;AAAA,IACP,YAAY,0BAAyB,oBAAI,KAAK,GAAE,YAAa,CAAA;AAAA,IAC7D;AAAA,IACA,SAAS;AAAA,IACT;AAAA,IACA,GAAG;AAAA,EAAA,IACD,gBAAgB,YAAY,KAAK;AACrC,QAAM,WAAW;AACjB,QAAM,EAAE,SAAS,GAAG,IAAI,WAAW,WAAW;AAE9C,QAAM,WAAW,cAAc,SAAS,YAAY,KAAK,IAAI,CAAC;AAG5D,SAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAW,GAAG,QAAQ,MAAM,EAAE,CAAC,QAAQ,KAAK,GAAG,SAAS,GAAG,SAAS;AAAA,MACnE,GAAG;AAAA,MAEJ,UAAA;AAAA,QAAA,oBAAC,gBAAa,SAAQ,SAAQ,WAAW,QAAQ,MAC9C,UACH,MAAA;AAAA,QACC,qBAAA,OAAA,EAAI,WAAW,QAAQ,gBACtB,UAAA;AAAA,UAAA,oBAAC,cAAa,EAAA,WAAW,QAAQ,WAAY,UAAU,WAAA;AAAA,UACtD,SAAS,oBAAC,OAAI,EAAA,WAAW,QAAQ,WAAW;AAAA,UAC5C;AAAA,QAAA,GACH;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGN;"}
|
|
@@ -10,13 +10,14 @@ const { staticClasses, useClasses } = createClasses("HvLoading", {
|
|
|
10
10
|
},
|
|
11
11
|
barContainer: {
|
|
12
12
|
display: "flex",
|
|
13
|
+
alignItems: "center",
|
|
13
14
|
justifyContent: "space-around",
|
|
14
15
|
":has($regular)": {
|
|
15
16
|
width: 30,
|
|
16
17
|
height: 30
|
|
17
18
|
},
|
|
18
19
|
":has($small)": {
|
|
19
|
-
"--
|
|
20
|
+
"--height": "40%",
|
|
20
21
|
width: 18,
|
|
21
22
|
height: 18
|
|
22
23
|
}
|
|
@@ -27,9 +28,10 @@ const { staticClasses, useClasses } = createClasses("HvLoading", {
|
|
|
27
28
|
animation: "loading 1s ease-in-out infinite",
|
|
28
29
|
// TODO: make this the default when it has better support
|
|
29
30
|
width: "round(up, 0.11em, 2px)",
|
|
31
|
+
height: "100%",
|
|
30
32
|
"@keyframes loading": {
|
|
31
33
|
"50%": {
|
|
32
|
-
|
|
34
|
+
height: "var(--height, 60%)",
|
|
33
35
|
backgroundColor: `var(--customColor, ${theme.colors.secondary})`
|
|
34
36
|
}
|
|
35
37
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Loading.styles.js","sources":["../../../src/Loading/Loading.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvLoading\", {\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n gap: theme.space.xs,\n },\n barContainer: {\n display: \"flex\",\n justifyContent: \"space-around\",\n\n \":has($regular)\": {\n width: 30,\n height: 30,\n },\n\n \":has($small)\": {\n \"--
|
|
1
|
+
{"version":3,"file":"Loading.styles.js","sources":["../../../src/Loading/Loading.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvLoading\", {\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n alignItems: \"center\",\n justifyContent: \"center\",\n gap: theme.space.xs,\n },\n barContainer: {\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"space-around\",\n\n \":has($regular)\": {\n width: 30,\n height: 30,\n },\n\n \":has($small)\": {\n \"--height\": \"40%\",\n width: 18,\n height: 18,\n },\n },\n loadingBar: {\n backgroundColor: \"currentcolor\",\n display: \"inline-block\",\n animation: \"loading 1s ease-in-out infinite\",\n // TODO: make this the default when it has better support\n width: \"round(up, 0.11em, 2px)\",\n height: \"100%\",\n\n \"@keyframes loading\": {\n \"50%\": {\n height: \"var(--height, 60%)\",\n backgroundColor: `var(--customColor, ${theme.colors.secondary})`,\n },\n },\n\n \":nth-of-type(2)\": { animationDelay: \"0.22s\" },\n \":nth-of-type(3)\": { animationDelay: \"0.44s\" },\n },\n label: {},\n overlay: {},\n blur: {},\n hidden: { display: \"none\" },\n small: {\n width: 2,\n },\n regular: {\n width: 4,\n },\n smallColor: {},\n regularColor: {},\n});\n"],"names":[],"mappings":";;AAGO,MAAM,EAAE,eAAe,eAAe,cAAc,aAAa;AAAA,EACtE,MAAM;AAAA,IACJ,SAAS;AAAA,IACT,eAAe;AAAA,IACf,YAAY;AAAA,IACZ,gBAAgB;AAAA,IAChB,KAAK,MAAM,MAAM;AAAA,EACnB;AAAA,EACA,cAAc;AAAA,IACZ,SAAS;AAAA,IACT,YAAY;AAAA,IACZ,gBAAgB;AAAA,IAEhB,kBAAkB;AAAA,MAChB,OAAO;AAAA,MACP,QAAQ;AAAA,IACV;AAAA,IAEA,gBAAgB;AAAA,MACd,YAAY;AAAA,MACZ,OAAO;AAAA,MACP,QAAQ;AAAA,IACV;AAAA,EACF;AAAA,EACA,YAAY;AAAA,IACV,iBAAiB;AAAA,IACjB,SAAS;AAAA,IACT,WAAW;AAAA;AAAA,IAEX,OAAO;AAAA,IACP,QAAQ;AAAA,IAER,sBAAsB;AAAA,MACpB,OAAO;AAAA,QACL,QAAQ;AAAA,QACR,iBAAiB,sBAAsB,MAAM,OAAO,SAAS;AAAA,MAC/D;AAAA,IACF;AAAA,IAEA,mBAAmB,EAAE,gBAAgB,QAAQ;AAAA,IAC7C,mBAAmB,EAAE,gBAAgB,QAAQ;AAAA,EAC/C;AAAA,EACA,OAAO,CAAC;AAAA,EACR,SAAS,CAAC;AAAA,EACV,MAAM,CAAC;AAAA,EACP,QAAQ,EAAE,SAAS,OAAO;AAAA,EAC1B,OAAO;AAAA,IACL,OAAO;AAAA,EACT;AAAA,EACA,SAAS;AAAA,IACP,OAAO;AAAA,EACT;AAAA,EACA,YAAY,CAAC;AAAA,EACb,cAAc,CAAC;AACjB,CAAC;"}
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import { jsx
|
|
2
|
-
import { useMemo, Children, isValidElement,
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo, Children, isValidElement, cloneElement } from "react";
|
|
3
3
|
import { useDefaultProps } from "@hitachivantara/uikit-react-utils";
|
|
4
|
-
import {
|
|
5
|
-
import { useClasses, getSplitContainerColor, getSplitContainerHeight } from "./MultiButton.styles.js";
|
|
4
|
+
import { useClasses } from "./MultiButton.styles.js";
|
|
6
5
|
import { staticClasses } from "./MultiButton.styles.js";
|
|
7
6
|
const HvMultiButton = (props) => {
|
|
8
7
|
const {
|
|
9
|
-
id,
|
|
10
8
|
className,
|
|
11
9
|
children,
|
|
12
10
|
classes: classesProp,
|
|
@@ -17,13 +15,7 @@ const HvMultiButton = (props) => {
|
|
|
17
15
|
split,
|
|
18
16
|
...others
|
|
19
17
|
} = useDefaultProps("HvMultiButton", props);
|
|
20
|
-
const { classes, cx
|
|
21
|
-
const [color, type] = useMemo(() => {
|
|
22
|
-
const result = variant.split(/(?=[A-Z])/);
|
|
23
|
-
if (result[0] === "ghost" || result[0] === "semantic" || result[0] === "secondary" && !result[1])
|
|
24
|
-
return [];
|
|
25
|
-
return result.map((x) => x.toLowerCase());
|
|
26
|
-
}, [variant]);
|
|
18
|
+
const { classes, cx } = useClasses(classesProp);
|
|
27
19
|
const buttons = useMemo(() => {
|
|
28
20
|
const btns = [];
|
|
29
21
|
Children.forEach(children, (child) => {
|
|
@@ -36,7 +28,6 @@ const HvMultiButton = (props) => {
|
|
|
36
28
|
return /* @__PURE__ */ jsx(
|
|
37
29
|
"div",
|
|
38
30
|
{
|
|
39
|
-
id,
|
|
40
31
|
className: cx(
|
|
41
32
|
classes.root,
|
|
42
33
|
{
|
|
@@ -52,35 +43,17 @@ const HvMultiButton = (props) => {
|
|
|
52
43
|
...others,
|
|
53
44
|
children: buttons.map((child, index) => {
|
|
54
45
|
const childIsSelected = !!child.props.selected;
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
}),
|
|
67
|
-
split && index < buttons.length - 1 && /* @__PURE__ */ jsx(
|
|
68
|
-
"div",
|
|
69
|
-
{
|
|
70
|
-
className: cx(
|
|
71
|
-
classes.splitContainer,
|
|
72
|
-
color && css(getSplitContainerColor(color, type, disabled)),
|
|
73
|
-
size && css(getSplitContainerHeight(size)),
|
|
74
|
-
{
|
|
75
|
-
[classes.splitDisabled]: disabled
|
|
76
|
-
},
|
|
77
|
-
classes[variant]
|
|
78
|
-
// TODO - remove in v6
|
|
79
|
-
),
|
|
80
|
-
children: /* @__PURE__ */ jsx("div", { className: classes.split })
|
|
81
|
-
}
|
|
82
|
-
)
|
|
83
|
-
] }, btnKey);
|
|
46
|
+
return cloneElement(child, {
|
|
47
|
+
key: index,
|
|
48
|
+
variant,
|
|
49
|
+
disabled: disabled || child.props.disabled,
|
|
50
|
+
size,
|
|
51
|
+
className: cx(child.props.className, classes.button, {
|
|
52
|
+
[classes.firstButton]: index === 0,
|
|
53
|
+
[classes.lastButton]: index === buttons.length - 1,
|
|
54
|
+
[classes.selected]: childIsSelected
|
|
55
|
+
})
|
|
56
|
+
});
|
|
84
57
|
})
|
|
85
58
|
}
|
|
86
59
|
);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MultiButton.js","sources":["../../../src/MultiButton/MultiButton.tsx"],"sourcesContent":["import {\n Children,\n cloneElement,\n
|
|
1
|
+
{"version":3,"file":"MultiButton.js","sources":["../../../src/MultiButton/MultiButton.tsx"],"sourcesContent":["import {\n Children,\n cloneElement,\n isValidElement,\n ReactElement,\n useMemo,\n} from \"react\";\nimport {\n useDefaultProps,\n type ExtractNames,\n} from \"@hitachivantara/uikit-react-utils\";\n\nimport { HvButtonSize, HvButtonVariant } from \"../Button\";\nimport { HvBaseProps } from \"../types/generic\";\nimport { staticClasses, useClasses } from \"./MultiButton.styles\";\n\nexport { staticClasses as multiButtonClasses };\nexport type HvMultiButtonClasses = ExtractNames<typeof useClasses>;\n\nexport interface HvMultiButtonProps extends HvBaseProps {\n /** If all the buttons are disabled. */\n disabled?: boolean;\n /** If the MultiButton is to be displayed vertically. */\n vertical?: boolean;\n /** Category of button to use */\n variant?: HvButtonVariant;\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: HvMultiButtonClasses;\n /** Button size. */\n size?: HvButtonSize;\n /** Add a split between buttons */\n split?: boolean;\n}\n\nexport const HvMultiButton = (props: HvMultiButtonProps) => {\n const {\n className,\n children,\n classes: classesProp,\n disabled = false,\n vertical = false,\n variant = \"secondarySubtle\",\n size,\n split,\n ...others\n } = useDefaultProps(\"HvMultiButton\", props);\n const { classes, cx } = useClasses(classesProp);\n\n // Filter children: remove invalid and undefined/null\n const buttons = useMemo(() => {\n const btns: ReactElement[] = [];\n Children.forEach(children, (child) => {\n if (child && isValidElement(child)) {\n btns.push(child);\n }\n });\n return btns;\n }, [children]);\n\n return (\n <div\n className={cx(\n classes.root,\n {\n [classes.multiple]: !split,\n [classes.vertical]: vertical,\n [classes[variant as keyof HvMultiButtonClasses]]: variant, // TODO - remove in v6\n [classes.splitGroup]: split,\n [classes.splitGroupDisabled]: split && disabled,\n },\n className,\n )}\n {...others}\n >\n {buttons.map((child, index) => {\n const childIsSelected = !!child.props.selected;\n return cloneElement(child, {\n key: index,\n variant,\n disabled: disabled || child.props.disabled,\n size,\n className: cx(child.props.className, classes.button, {\n [classes.firstButton]: index === 0,\n [classes.lastButton]: index === butt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C,QAAQ,UAAU,GAAG,UAAU,QAAQ,SAAS;AAAA,YACjD,CAAC,QAAQ,QAAQ,GAAG;AAAA,UAAA,CACrB;AAAA,QAAA,CACF;AAAA,MAAA,CACF;AAAA,IAAA;AAAA,EAAA;AAGP;"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { createClasses } from "@hitachivantara/uikit-react-utils";
|
|
2
2
|
import { theme } from "@hitachivantara/uikit-styles";
|
|
3
|
-
import { getColoringStyle, getSizeStyles } from "../Button/Button.styles.js";
|
|
4
3
|
import { staticClasses as staticClasses$1 } from "../DropDownMenu/DropDownMenu.styles.js";
|
|
5
4
|
import "../DropDownMenu/DropDownMenu.js";
|
|
6
5
|
const { staticClasses, useClasses } = createClasses("HvMultiButton", {
|
|
@@ -96,44 +95,40 @@ const { staticClasses, useClasses } = createClasses("HvMultiButton", {
|
|
|
96
95
|
splitGroup: {
|
|
97
96
|
width: "fit-content",
|
|
98
97
|
background: theme.colors.atmo1,
|
|
99
|
-
//
|
|
100
|
-
"& button$button": {
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
marginLeft: -1
|
|
106
|
-
}
|
|
107
|
-
},
|
|
108
|
-
"&$lastButton": {
|
|
109
|
-
borderTopLeftRadius: 0,
|
|
110
|
-
borderBottomLeftRadius: 0
|
|
111
|
-
}
|
|
112
|
-
},
|
|
113
|
-
// Dropdown Menu
|
|
114
|
-
[`& .${staticClasses$1.root}`]: {
|
|
115
|
-
"&:has($firstButton)": {
|
|
116
|
-
"& + div$splitContainer": {
|
|
117
|
-
marginRight: -1
|
|
118
|
-
}
|
|
98
|
+
// HvButton, HvDropDownMenu
|
|
99
|
+
"& button$button:not($firstButton), & $button:not($firstButton) button": {
|
|
100
|
+
borderTopLeftRadius: 0,
|
|
101
|
+
borderBottomLeftRadius: 0,
|
|
102
|
+
"&:not([aria-controls])": {
|
|
103
|
+
borderLeftWidth: 0
|
|
119
104
|
}
|
|
120
105
|
},
|
|
121
|
-
|
|
122
|
-
|
|
106
|
+
// HvButton, HvDropDownMenu
|
|
107
|
+
"& button$button:not($lastButton), & $button:not($lastButton) button": {
|
|
123
108
|
borderTopRightRadius: 0,
|
|
124
|
-
borderBottomRightRadius: 0
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
109
|
+
borderBottomRightRadius: 0,
|
|
110
|
+
"&:not([aria-controls])": {
|
|
111
|
+
borderRightWidth: 0
|
|
112
|
+
},
|
|
113
|
+
"&::after": {
|
|
114
|
+
content: "''",
|
|
115
|
+
position: "absolute",
|
|
116
|
+
inset: "4px -1px 4px auto",
|
|
117
|
+
width: 1,
|
|
118
|
+
zIndex: 1,
|
|
119
|
+
height: "auto",
|
|
120
|
+
backgroundColor: "currentcolor"
|
|
121
|
+
}
|
|
130
122
|
},
|
|
123
|
+
// HvDropDownMenu
|
|
131
124
|
[`& .${staticClasses$1.iconSelected}`]: {
|
|
132
125
|
zIndex: 2
|
|
133
126
|
}
|
|
134
127
|
},
|
|
135
128
|
splitGroupDisabled: { background: theme.colors.atmo3 },
|
|
136
|
-
button: {
|
|
129
|
+
button: {
|
|
130
|
+
position: "relative"
|
|
131
|
+
},
|
|
137
132
|
selected: {},
|
|
138
133
|
vertical: {
|
|
139
134
|
flexDirection: "column",
|
|
@@ -195,23 +190,6 @@ const { staticClasses, useClasses } = createClasses("HvMultiButton", {
|
|
|
195
190
|
}
|
|
196
191
|
}
|
|
197
192
|
},
|
|
198
|
-
split: {
|
|
199
|
-
width: 1,
|
|
200
|
-
height: "100%",
|
|
201
|
-
background: "currentColor"
|
|
202
|
-
},
|
|
203
|
-
splitContainer: {
|
|
204
|
-
display: "flex",
|
|
205
|
-
justifyContent: "center",
|
|
206
|
-
zIndex: 1,
|
|
207
|
-
width: 2,
|
|
208
|
-
paddingTop: 4,
|
|
209
|
-
paddingBottom: 4,
|
|
210
|
-
height: "calc(32px - 2px)"
|
|
211
|
-
},
|
|
212
|
-
splitDisabled: {
|
|
213
|
-
color: theme.colors.secondary_60
|
|
214
|
-
},
|
|
215
193
|
firstButton: {},
|
|
216
194
|
lastButton: {},
|
|
217
195
|
// TODO - review the need for these classes in v6
|
|
@@ -222,16 +200,7 @@ const { staticClasses, useClasses } = createClasses("HvMultiButton", {
|
|
|
222
200
|
secondarySubtle: {},
|
|
223
201
|
secondaryGhost: {}
|
|
224
202
|
});
|
|
225
|
-
const getSplitContainerColor = (color, type, disabled) => ({
|
|
226
|
-
color: getColoringStyle(color, type).color,
|
|
227
|
-
backgroundColor: disabled ? theme.colors.atmo3 : type === "subtle" ? theme.colors.atmo1 : "transparent"
|
|
228
|
-
});
|
|
229
|
-
const getSplitContainerHeight = (size) => ({
|
|
230
|
-
height: `calc(${getSizeStyles(size).height} - 2px)`
|
|
231
|
-
});
|
|
232
203
|
export {
|
|
233
|
-
getSplitContainerColor,
|
|
234
|
-
getSplitContainerHeight,
|
|
235
204
|
staticClasses,
|
|
236
205
|
useClasses
|
|
237
206
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MultiButton.styles.js","sources":["../../../src/MultiButton/MultiButton.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { HvButtonSize } from \"../Button\";\nimport { getColoringStyle, getSizeStyles } from \"../Button/Button.styles\";\nimport { dropDownMenuClasses } from \"../DropDownMenu\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvMultiButton\", {\n root: {\n display: \"flex\",\n alignItems: \"center\",\n transition: \"none\",\n position: \"relative\",\n zIndex: 0,\n },\n multiple: {\n background: theme.colors.atmo2,\n\n // prevent the focus ring to be hidden by sibling hover background\n \"&>.HvIsFocusVisible\": {\n zIndex: 5,\n },\n\n \"& button$button\": {\n minWidth: \"unset\",\n width: \"100%\",\n maxWidth: 200,\n padding: 0,\n transition: \"none\",\n flex: \"1 0 0px\",\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n borderLeft: \"solid 1px transparent\",\n borderRight: \"solid 1px transparent\",\n borderRadius: 0,\n fontWeight: theme.typography.body.fontWeight,\n fontSize: theme.typography.body.fontSize,\n \"&:disabled\": {\n color: theme.colors.secondary_60,\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n \"&:hover\": {\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n borderLeft: \"solid 1px transparent\",\n borderRight: \"solid 1px transparent\",\n },\n },\n \"&$firstButton\": {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderTopLeftRadius: theme.radii.base,\n borderBottomLeftRadius: theme.radii.base,\n \"&:disabled\": {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n \"&$lastButton\": {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTopRightRadius: theme.radii.base,\n borderBottomRightRadius: theme.radii.base,\n \"&:disabled\": {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n \"&:disabled:hover\": {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n \"&:not($firstButton)\": {\n marginLeft: \"-1px\",\n },\n \"&$selected\": {\n background: theme.colors.atmo1,\n ...theme.typography.label,\n borderRadius: theme.radii.base,\n border: `solid 1px ${theme.colors.secondary}`,\n zIndex: 2,\n \"&:hover\": {\n background: theme.colors.atmo3,\n \"&:not(:disabled)\": {\n border: `solid 1px ${theme.colors.secondary}`,\n },\n \"&:disabled\": {\n border: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n // prevent the focus ring to be hidden by sibling hover background\n // even when selected\n \"&.HvIsFocusVisible\": {\n zIndex: 5,\n },\n \"&:disabled\": {\n zIndex: 1,\n color: theme.colors.secondary_60,\n background: theme.colors.atmo1,\n border: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n },\n },\n splitGroup: {\n width: \"fit-content\",\n background: theme.colors.atmo1,\n\n // Button\n \"& button$button\": {\n \"&$firstButton\": {\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0,\n \"& + div$splitContainer\": {\n marginLeft: -1,\n },\n },\n \"&$lastButton\": {\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n },\n },\n\n // Dropdown Menu\n [`& .${dropDownMenuClasses.root}`]: {\n \"&:has($firstButton)\": {\n \"& + div$splitContainer\": {\n marginRight: -1,\n },\n },\n },\n \"& $button$firstButton > button\": {\n marginRight: -1.5,\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0,\n },\n \"& $button$lastButton > button\": {\n marginLeft: -1.5,\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n },\n [`& .${dropDownMenuClasses.iconSelected}`]: {\n zIndex: 2,\n },\n },\n splitGroupDisabled: { background: theme.colors.atmo3 },\n button: {},\n selected: {},\n vertical: {\n flexDirection: \"column\",\n height: \"auto\",\n \"& button$button\": {\n minWidth: 32,\n width: \"100%\",\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTop: \"solid 1px transparent\",\n borderBottom: \"solid 1px transparent\",\n \"&:disabled\": {\n color: theme.colors.secondary_60,\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTop: \"solid 1px transparent\",\n borderBottom: \"solid 1px transparent\",\n \"&:hover\": {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTop: \"solid 1px transparent\",\n borderBottom: \"solid 1px transparent\",\n },\n },\n \"&$firstButton\": {\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderTopLeftRadius: theme.radii.base,\n borderTopRightRadius: theme.radii.base,\n },\n \"&$lastButton\": {\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n borderBottomLeftRadius: theme.radii.base,\n borderBottomRightRadius: theme.radii.base,\n \"&:disabled:hover\": {\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n \"&:not($firstButton)\": {\n marginLeft: 0,\n marginTop: -1,\n },\n \"&$selected\": {\n height: 32,\n width: `calc(100% + 2px) !important`,\n background: theme.colors.atmo1,\n ...theme.typography.label,\n borderRadius: theme.radii.base,\n border: `solid 1px ${theme.colors.secondary}`,\n zIndex: 2,\n \"&:hover, &:focus\": {\n background: theme.colors.atmo3,\n },\n \"&:disabled\": {\n zIndex: 1,\n color: theme.colors.secondary_60,\n background: theme.colors.atmo1,\n border: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n },\n },\n split: {\n width: 1,\n height: \"100%\",\n background: \"currentColor\",\n },\n splitContainer: {\n display: \"flex\",\n justifyContent: \"center\",\n zIndex: 1,\n width: 2,\n paddingTop: 4,\n paddingBottom: 4,\n height: \"calc(32px - 2px)\",\n },\n splitDisabled: {\n color: theme.colors.secondary_60,\n },\n firstButton: {},\n lastButton: {},\n\n // TODO - review the need for these classes in v6\n primary: {},\n primarySubtle: {},\n primaryGhost: {},\n secondary: {},\n secondarySubtle: {},\n secondaryGhost: {},\n});\n\nexport const getSplitContainerColor = (\n color: string,\n type?: string,\n disabled?: boolean,\n) => ({\n color: getColoringStyle(color, type).color,\n backgroundColor: disabled\n ? theme.colors.atmo3\n : type === \"subtle\"\n ? theme.colors.atmo1\n : \"transparent\",\n});\n\nexport const getSplitContainerHeight = (size: HvButtonSize) => ({\n height: `calc(${getSizeStyles(size).height} - 2px)`,\n});\n"],"names":["dropDownMenuClasses"],"mappings":";;;;;AAOO,MAAM,EAAE,eAAe,eAAe,cAAc,iBAAiB;AAAA,EAC1E,MAAM;AAAA,IACJ,SAAS;AAAA,IACT,YAAY;AAAA,IACZ,YAAY;AAAA,IACZ,UAAU;AAAA,IACV,QAAQ;AAAA,EACV;AAAA,EACA,UAAU;AAAA,IACR,YAAY,MAAM,OAAO;AAAA;AAAA,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AY,MAAM,OAAO;AAAA,QACzB,GAAG,MAAM,WAAW;AAAA,QACpB,cAAc,MAAM,MAAM;AAAA,QAC1B,QAAQ,aAAa,MAAM,OAAO,SAAS;AAAA,QAC3C,QAAQ;AAAA,QACR,oBAAoB;AAAA,UAClB,YAAY,MAAM,OAAO;AAAA,QAC3B;AAAA,QACA,cAAc;AAAA,UACZ,QAAQ;AAAA,UACR,OAAO,MAAM,OAAO;AAAA,UACpB,YAAY,MAAM,OAAO;AAAA,UACzB,QAAQ,aAAa,MAAM,OAAO,KAAK;AAAA,QACzC;AAAA,MACF;AAAA,IACF;AAAA,EACF;AAAA,EACA,OAAO;AAAA,IACL,OAAO;AAAA,IACP,QAAQ;AAAA,IACR,YAAY;AAAA,EACd;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,IACT,gBAAgB;AAAA,IAChB,QAAQ;AAAA,IACR,OAAO;AAAA,IACP,YAAY;AAAA,IACZ,eAAe;AAAA,IACf,QAAQ;AAAA,EACV;AAAA,EACA,eAAe;AAAA,IACb,OAAO,MAAM,OAAO;AAAA,EACtB;AAAA,EACA,aAAa,CAAC;AAAA,EACd,YAAY,CAAC;AAAA;AAAA,EAGb,SAAS,CAAC;AAAA,EACV,eAAe,CAAC;AAAA,EAChB,cAAc,CAAC;AAAA,EACf,WAAW,CAAC;AAAA,EACZ,iBAAiB,CAAC;AAAA,EAClB,gBAAgB,CAAC;AACnB,CAAC;AAEM,MAAM,yBAAyB,CACpC,OACA,MACA,cACI;AAAA,EACJ,OAAO,iBAAiB,OAAO,IAAI,EAAE;AAAA,EACrC,iBAAiB,WACb,MAAM,OAAO,QACb,SAAS,WACP,MAAM,OAAO,QACb;AACR;AAEa,MAAA,0BAA0B,CAAC,UAAwB;AAAA,EAC9D,QAAQ,QAAQ,cAAc,IAAI,EAAE,MAAM;AAC5C;"}
|
|
1
|
+
{"version":3,"file":"MultiButton.styles.js","sources":["../../../src/MultiButton/MultiButton.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nimport { dropDownMenuClasses } from \"../DropDownMenu\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvMultiButton\", {\n root: {\n display: \"flex\",\n alignItems: \"center\",\n transition: \"none\",\n position: \"relative\",\n zIndex: 0,\n },\n multiple: {\n background: theme.colors.atmo2,\n\n // prevent the focus ring to be hidden by sibling hover background\n \"&>.HvIsFocusVisible\": {\n zIndex: 5,\n },\n\n \"& button$button\": {\n minWidth: \"unset\",\n width: \"100%\",\n maxWidth: 200,\n padding: 0,\n transition: \"none\",\n flex: \"1 0 0px\",\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n borderLeft: \"solid 1px transparent\",\n borderRight: \"solid 1px transparent\",\n borderRadius: 0,\n fontWeight: theme.typography.body.fontWeight,\n fontSize: theme.typography.body.fontSize,\n \"&:disabled\": {\n color: theme.colors.secondary_60,\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n \"&:hover\": {\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n borderLeft: \"solid 1px transparent\",\n borderRight: \"solid 1px transparent\",\n },\n },\n \"&$firstButton\": {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderTopLeftRadius: theme.radii.base,\n borderBottomLeftRadius: theme.radii.base,\n \"&:disabled\": {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n \"&$lastButton\": {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTopRightRadius: theme.radii.base,\n borderBottomRightRadius: theme.radii.base,\n \"&:disabled\": {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n \"&:disabled:hover\": {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n \"&:not($firstButton)\": {\n marginLeft: \"-1px\",\n },\n \"&$selected\": {\n background: theme.colors.atmo1,\n ...theme.typography.label,\n borderRadius: theme.radii.base,\n border: `solid 1px ${theme.colors.secondary}`,\n zIndex: 2,\n \"&:hover\": {\n background: theme.colors.atmo3,\n \"&:not(:disabled)\": {\n border: `solid 1px ${theme.colors.secondary}`,\n },\n \"&:disabled\": {\n border: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n // prevent the focus ring to be hidden by sibling hover background\n // even when selected\n \"&.HvIsFocusVisible\": {\n zIndex: 5,\n },\n \"&:disabled\": {\n zIndex: 1,\n color: theme.colors.secondary_60,\n background: theme.colors.atmo1,\n border: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n },\n },\n splitGroup: {\n width: \"fit-content\",\n background: theme.colors.atmo1,\n\n // HvButton, HvDropDownMenu\n \"& button$button:not($firstButton), & $button:not($firstButton) button\": {\n borderTopLeftRadius: 0,\n borderBottomLeftRadius: 0,\n \"&:not([aria-controls])\": {\n borderLeftWidth: 0,\n },\n },\n // HvButton, HvDropDownMenu\n \"& button$button:not($lastButton), & $button:not($lastButton) button\": {\n borderTopRightRadius: 0,\n borderBottomRightRadius: 0,\n \"&:not([aria-controls])\": {\n borderRightWidth: 0,\n },\n\n \"&::after\": {\n content: \"''\",\n position: \"absolute\",\n inset: \"4px -1px 4px auto\",\n width: 1,\n zIndex: 1,\n height: \"auto\",\n backgroundColor: \"currentcolor\",\n },\n },\n // HvDropDownMenu\n [`& .${dropDownMenuClasses.iconSelected}`]: {\n zIndex: 2,\n },\n },\n splitGroupDisabled: { background: theme.colors.atmo3 },\n button: {\n position: \"relative\",\n },\n selected: {},\n vertical: {\n flexDirection: \"column\",\n height: \"auto\",\n \"& button$button\": {\n minWidth: 32,\n width: \"100%\",\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTop: \"solid 1px transparent\",\n borderBottom: \"solid 1px transparent\",\n \"&:disabled\": {\n color: theme.colors.secondary_60,\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTop: \"solid 1px transparent\",\n borderBottom: \"solid 1px transparent\",\n \"&:hover\": {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n borderTop: \"solid 1px transparent\",\n borderBottom: \"solid 1px transparent\",\n },\n },\n \"&$firstButton\": {\n borderTop: `solid 1px ${theme.colors.atmo4}`,\n borderTopLeftRadius: theme.radii.base,\n borderTopRightRadius: theme.radii.base,\n },\n \"&$lastButton\": {\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n borderBottomLeftRadius: theme.radii.base,\n borderBottomRightRadius: theme.radii.base,\n \"&:disabled:hover\": {\n borderBottom: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n \"&:not($firstButton)\": {\n marginLeft: 0,\n marginTop: -1,\n },\n \"&$selected\": {\n height: 32,\n width: `calc(100% + 2px) !important`,\n background: theme.colors.atmo1,\n ...theme.typography.label,\n borderRadius: theme.radii.base,\n border: `solid 1px ${theme.colors.secondary}`,\n zIndex: 2,\n \"&:hover, &:focus\": {\n background: theme.colors.atmo3,\n },\n \"&:disabled\": {\n zIndex: 1,\n color: theme.colors.secondary_60,\n background: theme.colors.atmo1,\n border: `solid 1px ${theme.colors.atmo4}`,\n },\n },\n },\n },\n firstButton: {},\n lastButton: {},\n\n // TODO - review the need for these classes in v6\n primary: {},\n primarySubtle: {},\n primaryGhost: {},\n secondary: {},\n secondarySubtle: {},\n secondaryGhost: {},\n});\n"],"names":["dropDownMenuClasses"],"mappings":";;;;AAKO,MAAM,EAAE,eAAe,eAAe,cAAc,iBAAiB;AAAA,EAC1E,MAAM;AAAA,IACJ,SAAS;AAAA,IACT,YAAY;AAAA,IACZ,YAAY;AAAA,IACZ,UAAU;AAAA,IACV,QAAQ;AAAA,EACV;AAAA,EACA,UAAU;AAAA,IACR,YAAY,MAAM,OAAO;AAAA;AAAA,IAGzB,uBA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AC3C,QAAQ;AAAA,QACR,oBAAoB;AAAA,UAClB,YAAY,MAAM,OAAO;AAAA,QAC3B;AAAA,QACA,cAAc;AAAA,UACZ,QAAQ;AAAA,UACR,OAAO,MAAM,OAAO;AAAA,UACpB,YAAY,MAAM,OAAO;AAAA,UACzB,QAAQ,aAAa,MAAM,OAAO,KAAK;AAAA,QACzC;AAAA,MACF;AAAA,IACF;AAAA,EACF;AAAA,EACA,aAAa,CAAC;AAAA,EACd,YAAY,CAAC;AAAA;AAAA,EAGb,SAAS,CAAC;AAAA,EACV,eAAe,CAAC;AAAA,EAChB,cAAc,CAAC;AAAA,EACf,WAAW,CAAC;AAAA,EACZ,iBAAiB,CAAC;AAAA,EAClB,gBAAgB,CAAC;AACnB,CAAC;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.styles.js","sources":["../../../src/Select/Select.styles.ts"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvSelect\", {\n root: {\n position: \"relative\",\n \"&$disabled,&$readOnly\": {\n pointerEvents: \"none\",\n },\n },\n disabled: {},\n readOnly: {},\n invalid: {\n border: `1px solid ${theme.colors.negative}`,\n },\n labelContainer: {\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n label: {\n display: \"block\",\n paddingBottom: 6,\n },\n description: {},\n select: {},\n popper: {\n zIndex: theme.zIndices.popover,\n },\n panel: {\n border: `1px solid ${theme.colors.secondary}`,\n marginTop: -1,\n marginBottom: -1,\n },\n panelOpenedUp: {\n borderRadius: `${theme.radii.base} ${theme.radii.base} 0 0`,\n },\n panelOpenedDown: {\n borderRadius: `0 0 ${theme.radii.base} ${theme.radii.base}`,\n },\n error: {},\n});\n"],"names":[],"mappings":";;AAGO,MAAM,EAAE,eAAe,eAAe,cAAc,YAAY;AAAA,EACrE,MAAM;AAAA,IACJ,UAAU;AAAA,IACV,yBAAyB;AAAA,MACvB,eAAe;AAAA,IACjB;AAAA,EACF;AAAA,EACA,UAAU,CAAC;AAAA,EACX,UAAU,CAAC;AAAA,EACX,SAAS;AAAA,IACP,QAAQ,aAAa,MAAM,OAAO,QAAQ;AAAA,EAC5C;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,IACT,YAAY;AAAA,EACd;AAAA,EACA,OAAO;AAAA,IACL,SAAS;AAAA,IACT,eAAe;AAAA,EACjB;AAAA,EACA,aAAa,CAAC;AAAA,EACd,QAAQ,CAAC;AAAA,EACT,QAAQ;AAAA,IACN,QAAQ,MAAM,SAAS;AAAA,EACzB;AAAA,EACA,OAAO;AAAA,IACL,QAAQ,aAAa,MAAM,OAAO,SAAS;AAAA,IAC3C,WAAW;AAAA,IACX,cAAc;AAAA,EAChB;AAAA,EACA,eAAe;AAAA,IACb,cAAc,GAAG,MAAM,MAAM,IAAI,IAAI,MAAM,MAAM,IAAI;AAAA,EACvD;AAAA,EACA,iBAAiB;AAAA,IACf,cAAc,OAAO,MAAM,MAAM,IAAI,IAAI,MAAM,MAAM,IAAI;AAAA,EAC3D;AAAA,EACA,OAAO,CAAC;AACV,CAAC;"}
|
|
1
|
+
{"version":3,"file":"Select.styles.js","sources":["../../../src/Select/Select.styles.ts"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvSelect\", {\n root: {\n position: \"relative\",\n \"&$disabled,&$readOnly\": {\n pointerEvents: \"none\",\n },\n },\n disabled: {},\n readOnly: {},\n invalid: {\n border: `1px solid ${theme.colors.negative}`,\n },\n labelContainer: {\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n label: {\n display: \"block\",\n paddingBottom: 6,\n },\n description: {},\n select: {},\n popper: {\n zIndex: theme.zIndices.popover,\n },\n panel: {\n maxHeight: 400,\n border: `1px solid ${theme.colors.secondary}`,\n marginTop: -1,\n marginBottom: -1,\n },\n panelOpenedUp: {\n borderRadius: `${theme.radii.base} ${theme.radii.base} 0 0`,\n },\n panelOpenedDown: {\n borderRadius: `0 0 ${theme.radii.base} ${theme.radii.base}`,\n },\n error: {},\n});\n"],"names":[],"mappings":";;AAGO,MAAM,EAAE,eAAe,eAAe,cAAc,YAAY;AAAA,EACrE,MAAM;AAAA,IACJ,UAAU;AAAA,IACV,yBAAyB;AAAA,MACvB,eAAe;AAAA,IACjB;AAAA,EACF;AAAA,EACA,UAAU,CAAC;AAAA,EACX,UAAU,CAAC;AAAA,EACX,SAAS;AAAA,IACP,QAAQ,aAAa,MAAM,OAAO,QAAQ;AAAA,EAC5C;AAAA,EACA,gBAAgB;AAAA,IACd,SAAS;AAAA,IACT,YAAY;AAAA,EACd;AAAA,EACA,OAAO;AAAA,IACL,SAAS;AAAA,IACT,eAAe;AAAA,EACjB;AAAA,EACA,aAAa,CAAC;AAAA,EACd,QAAQ,CAAC;AAAA,EACT,QAAQ;AAAA,IACN,QAAQ,MAAM,SAAS;AAAA,EACzB;AAAA,EACA,OAAO;AAAA,IACL,WAAW;AAAA,IACX,QAAQ,aAAa,MAAM,OAAO,SAAS;AAAA,IAC3C,WAAW;AAAA,IACX,cAAc;AAAA,EAChB;AAAA,EACA,eAAe;AAAA,IACb,cAAc,GAAG,MAAM,MAAM,IAAI,IAAI,MAAM,MAAM,IAAI;AAAA,EACvD;AAAA,EACA,iBAAiB;AAAA,IACf,cAAc,OAAO,MAAM,MAAM,IAAI,IAAI,MAAM,MAAM,IAAI;AAAA,EAC3D;AAAA,EACA,OAAO,CAAC;AACV,CAAC;"}
|
|
@@ -5,6 +5,7 @@ const { staticClasses, useClasses } = createClasses("HvTableCell", {
|
|
|
5
5
|
/** Styles applied to the component root class. */
|
|
6
6
|
root: {
|
|
7
7
|
verticalAlign: "inherit",
|
|
8
|
+
alignContent: "inherit",
|
|
8
9
|
textAlign: "left",
|
|
9
10
|
padding: `calc(${theme.space.xs} - 2px ) ${theme.space.xs} calc(${theme.space.xs} - 3px ) ${theme.spacing(4)}`,
|
|
10
11
|
borderBottom: `1px solid ${theme.colors.atmo4}`
|
|
@@ -13,6 +14,7 @@ const { staticClasses, useClasses } = createClasses("HvTableCell", {
|
|
|
13
14
|
head: {
|
|
14
15
|
height: 52,
|
|
15
16
|
verticalAlign: "top",
|
|
17
|
+
alignContent: "start",
|
|
16
18
|
backgroundColor: theme.colors.atmo1,
|
|
17
19
|
borderTop: "1px solid transparent",
|
|
18
20
|
borderBottom: `1px solid ${theme.colors.atmo4}`,
|
|
@@ -97,6 +99,7 @@ const { staticClasses, useClasses } = createClasses("HvTableCell", {
|
|
|
97
99
|
/** Styles applied to the cell when its variant is list and actions. */
|
|
98
100
|
variantListactions: {
|
|
99
101
|
verticalAlign: "middle",
|
|
102
|
+
alignContent: "center",
|
|
100
103
|
borderLeft: "none",
|
|
101
104
|
paddingLeft: "0",
|
|
102
105
|
textAlign: "center",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableCell.styles.js","sources":["../../../../src/Table/TableCell/TableCell.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nconst sortedColor = theme.alpha(\"primary\", 0.1);\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTableCell\", {\n /** Styles applied to the component root class. */\n root: {\n verticalAlign: \"inherit\",\n textAlign: \"left\",\n padding: `calc(${theme.space.xs} - 2px ) ${theme.space.xs} calc(${\n theme.space.xs\n } - 3px ) ${theme.spacing(4)}`,\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n },\n /** Styles applied to the cell when it's in the table head. */\n head: {\n height: 52,\n verticalAlign: \"top\",\n\n backgroundColor: theme.colors.atmo1,\n borderTop: \"1px solid transparent\",\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n ...(theme.typography.label as React.CSSProperties),\n },\n /** Styles applied to the cell when it's in the table body. */\n body: {\n minHeight: 32,\n \"td&\": {\n height: 32,\n },\n backgroundColor: \"inherit\",\n ...(theme.typography.body as React.CSSProperties),\n fontFamily: theme.fontFamily.body,\n\n \"&$sorted\": {\n backgroundImage: `linear-gradient(to right, ${sortedColor}, ${sortedColor})`,\n },\n },\n /** Styles applied to the cell when it's in the table footer. */\n footer: {},\n /** Styles applied to the cell when it's part of a sorted column. */\n sorted: {},\n /** Styles applied to the component root when it is left aligned */\n alignLeft: {\n textAlign: \"left\",\n },\n /** Styles applied to the component root when it is center aligned */\n alignCenter: {\n textAlign: \"center\",\n },\n /** Styles applied to the component root when it is right aligned */\n alignRight: {\n textAlign: \"right\",\n flexDirection: \"row-reverse\",\n },\n /** Styles applied to the component root when it is justified */\n alignJustify: {\n textAlign: \"justify\",\n },\n\n /** Styles applied to the component root when its variant is none */\n variantNone: {\n padding: 0,\n },\n /** Styles applied to the component root when its variant is checkbox */\n variantCheckbox: {\n boxSizing: \"content-box\",\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the component root when its variant is actions */\n variantActions: {\n boxSizing: \"content-box\",\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the component root when its variant is expand */\n variantExpand: {\n paddingLeft: 0,\n paddingTop: 0,\n paddingBottom: 0,\n },\n /** Styles applied to the component root when its variant is list */\n variantList: {\n minHeight: 52,\n \"td&\": {\n height: 52,\n },\n padding: \"0, 0, 0, 32px\",\n border: 0,\n },\n /** Styles applied to the cell when its variant is list and the type is head. */\n variantListHead: {\n backgroundColor: \"inherit\",\n \"td&\": {\n height: 16,\n },\n },\n /** Styles applied to the cell when its variant is list and actions. */\n variantListactions: {\n verticalAlign: \"middle\",\n borderLeft: \"none\",\n paddingLeft: \"0\",\n textAlign: \"center\",\n width: 130,\n maxWidth: 130,\n },\n /** Styles applied to the cell when its variant is list and checkbox. */\n variantListcheckbox: {\n borderRight: \"none\",\n padding: 0,\n textAlign: \"center\",\n width: 34,\n maxWidth: 34,\n },\n /** Styles applied to the cell when it's part of a sticky column. */\n stickyColumn: {\n position: \"sticky\",\n zIndex: 2,\n backgroundColor: theme.colors.atmo2,\n\n \"&$groupColumnMostRight+$stickyColumn\": {\n borderLeft: 0,\n },\n },\n /** Styles applied to the cell when it's part of the last sticky to the left column. */\n stickyColumnMostLeft: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the cell when it's part of the first right sticky column. */\n stickyColumnLeastRight: {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n\n /** Styles applied to the cell when it's part of the first column in the group. */\n groupColumnMostLeft: {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n\n \"&:first-of-type\": {\n borderLeft: 0,\n },\n },\n /** Styles applied to the cell when it's part of the last column in the group. */\n groupColumnMostRight: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n\n // due to the \":has()\" selector not being supported in browsers,\n // this need to be managed with inline styles\n // To be uncommented when not needed (see comment in src/Table/hooks/useSticky.js)\n // \"&:last-child,&:has(+ $stickyColumnLeastRight)\": {\n \"&:last-child\": {\n borderRight: 0,\n },\n\n \"&+:not($stickyColumn)\": {\n borderLeft: 0,\n },\n },\n\n /** Styles applied to the cell when it's part of a resizable column. */\n resizable: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the cell when it's part of a resizing column. */\n resizing: {\n borderRight: `solid 2px ${theme.colors.secondary}`,\n },\n});\n"],"names":[],"mappings":";;AAGA,MAAM,cAAc,MAAM,MAAM,WAAW,GAAG;AAEvC,MAAM,EAAE,eAAe,eAAe,cAAc,eAAe;AAAA;AAAA,EAExE,MAAM;AAAA,IACJ,eAAe;AAAA,IACf,WAAW;AAAA,IACX,SAAS,QAAQ,MAAM,MAAM,EAAE,YAAY,MAAM,MAAM,EAAE,SACvD,MAAM,MAAM,EACd,YAAY,MAAM,QAAQ,CAAC,CAAC;AAAA,IAC5B,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,EAC/C;AAAA;AAAA,EAEA,MAAM;AAAA,IACJ,QAAQ;AAAA,IACR,eAAe;AAAA,
|
|
1
|
+
{"version":3,"file":"TableCell.styles.js","sources":["../../../../src/Table/TableCell/TableCell.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nconst sortedColor = theme.alpha(\"primary\", 0.1);\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTableCell\", {\n /** Styles applied to the component root class. */\n root: {\n verticalAlign: \"inherit\",\n alignContent: \"inherit\",\n textAlign: \"left\",\n padding: `calc(${theme.space.xs} - 2px ) ${theme.space.xs} calc(${\n theme.space.xs\n } - 3px ) ${theme.spacing(4)}`,\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n },\n /** Styles applied to the cell when it's in the table head. */\n head: {\n height: 52,\n verticalAlign: \"top\",\n alignContent: \"start\",\n\n backgroundColor: theme.colors.atmo1,\n borderTop: \"1px solid transparent\",\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n ...(theme.typography.label as React.CSSProperties),\n },\n /** Styles applied to the cell when it's in the table body. */\n body: {\n minHeight: 32,\n \"td&\": {\n height: 32,\n },\n backgroundColor: \"inherit\",\n ...(theme.typography.body as React.CSSProperties),\n fontFamily: theme.fontFamily.body,\n\n \"&$sorted\": {\n backgroundImage: `linear-gradient(to right, ${sortedColor}, ${sortedColor})`,\n },\n },\n /** Styles applied to the cell when it's in the table footer. */\n footer: {},\n /** Styles applied to the cell when it's part of a sorted column. */\n sorted: {},\n /** Styles applied to the component root when it is left aligned */\n alignLeft: {\n textAlign: \"left\",\n },\n /** Styles applied to the component root when it is center aligned */\n alignCenter: {\n textAlign: \"center\",\n },\n /** Styles applied to the component root when it is right aligned */\n alignRight: {\n textAlign: \"right\",\n flexDirection: \"row-reverse\",\n },\n /** Styles applied to the component root when it is justified */\n alignJustify: {\n textAlign: \"justify\",\n },\n\n /** Styles applied to the component root when its variant is none */\n variantNone: {\n padding: 0,\n },\n /** Styles applied to the component root when its variant is checkbox */\n variantCheckbox: {\n boxSizing: \"content-box\",\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the component root when its variant is actions */\n variantActions: {\n boxSizing: \"content-box\",\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the component root when its variant is expand */\n variantExpand: {\n paddingLeft: 0,\n paddingTop: 0,\n paddingBottom: 0,\n },\n /** Styles applied to the component root when its variant is list */\n variantList: {\n minHeight: 52,\n \"td&\": {\n height: 52,\n },\n padding: \"0, 0, 0, 32px\",\n border: 0,\n },\n /** Styles applied to the cell when its variant is list and the type is head. */\n variantListHead: {\n backgroundColor: \"inherit\",\n \"td&\": {\n height: 16,\n },\n },\n /** Styles applied to the cell when its variant is list and actions. */\n variantListactions: {\n verticalAlign: \"middle\",\n alignContent: \"center\",\n borderLeft: \"none\",\n paddingLeft: \"0\",\n textAlign: \"center\",\n width: 130,\n maxWidth: 130,\n },\n /** Styles applied to the cell when its variant is list and checkbox. */\n variantListcheckbox: {\n borderRight: \"none\",\n padding: 0,\n textAlign: \"center\",\n width: 34,\n maxWidth: 34,\n },\n /** Styles applied to the cell when it's part of a sticky column. */\n stickyColumn: {\n position: \"sticky\",\n zIndex: 2,\n backgroundColor: theme.colors.atmo2,\n\n \"&$groupColumnMostRight+$stickyColumn\": {\n borderLeft: 0,\n },\n },\n /** Styles applied to the cell when it's part of the last sticky to the left column. */\n stickyColumnMostLeft: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the cell when it's part of the first right sticky column. */\n stickyColumnLeastRight: {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n\n /** Styles applied to the cell when it's part of the first column in the group. */\n groupColumnMostLeft: {\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n\n \"&:first-of-type\": {\n borderLeft: 0,\n },\n },\n /** Styles applied to the cell when it's part of the last column in the group. */\n groupColumnMostRight: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n\n // due to the \":has()\" selector not being supported in browsers,\n // this need to be managed with inline styles\n // To be uncommented when not needed (see comment in src/Table/hooks/useSticky.js)\n // \"&:last-child,&:has(+ $stickyColumnLeastRight)\": {\n \"&:last-child\": {\n borderRight: 0,\n },\n\n \"&+:not($stickyColumn)\": {\n borderLeft: 0,\n },\n },\n\n /** Styles applied to the cell when it's part of a resizable column. */\n resizable: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n /** Styles applied to the cell when it's part of a resizing column. */\n resizing: {\n borderRight: `solid 2px ${theme.colors.secondary}`,\n },\n});\n"],"names":[],"mappings":";;AAGA,MAAM,cAAc,MAAM,MAAM,WAAW,GAAG;AAEvC,MAAM,EAAE,eAAe,eAAe,cAAc,eAAe;AAAA;AAAA,EAExE,MAAM;AAAA,IACJ,eAAe;AAAA,IACf,cAAc;AAAA,IACd,WAAW;AAAA,IACX,SAAS,QAAQ,MAAM,MAAM,EAAE,YAAY,MAAM,MAAM,EAAE,SACvD,MAAM,MAAM,EACd,YAAY,MAAM,QAAQ,CAAC,CAAC;AAAA,IAC5B,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,EAC/C;AAAA;AAAA,EAEA,MAAM;AAAA,IACJ,QAAQ;AAAA,IACR,eAAe;AAAA,IACf,cAAc;AAAA,IAEd,iBAAiB,MAAM,OAAO;AAAA,IAC9B,WAAW;AAAA,IACX,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,IAC7C,GAAI,MAAM,WAAW;AAAA,EACvB;AAAA;AAAA,EAEA,MAAM;AAAA,IACJ,WAAW;AAAA,IACX,OAAO;AAAA,MACL,QAAQ;AAAA,IACV;AAAA,IACA,iBAAiB;AAAA,IACjB,GAAI,MAAM,WAAW;AAAA,IACrB,YAAY,MAAM,WAAW;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AAAA,IACnB,aAAa;AAAA,IACb,SAAS;AAAA,IACT,WAAW;AAAA,IACX,OAAO;AAAA,IACP,UAAU;AAAA,EACZ;AAAA;AAAA,EAEA,cAAc;AAAA,IACZ,UAAU;AAAA,IACV,QAAQ;AAAA,IACR,iBAAiB,MAAM,OAAO;AAAA,IAE9B,wCAAwC;AAAA,MACtC,YAAY;AAAA,IACd;AAAA,EACF;AAAA;AAAA,EAEA,sBAAsB;AAAA,IACpB,aAAa,aAAa,MAAM,OAAO,KAAK;AAAA,EAC9C;AAAA;AAAA,EAEA,wBAAwB;AAAA,IACtB,YAAY,aAAa,MAAM,OAAO,KAAK;AAAA,EAC7C;AAAA;AAAA,EAGA,qBAAqB;AAAA,IACnB,YAAY,aAAa,MAAM,OAAO,KAAK;AAAA,IAE3C,mBAAmB;AAAA,MACjB,YAAY;AAAA,IACd;AAAA,EACF;AAAA;AAAA,EAEA,sBAAsB;AAAA,IACpB,aAAa,aAAa,MAAM,OAAO,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA,IAM5C,gBAAgB;AAAA,MACd,aAAa;AAAA,IACf;AAAA,IAEA,yBAAyB;AAAA,MACvB,YAAY;AAAA,IACd;AAAA,EACF;AAAA;AAAA,EAGA,WAAW;AAAA,IACT,aAAa,aAAa,MAAM,OAAO,KAAK;AAAA,EAC9C;AAAA;AAAA,EAEA,UAAU;AAAA,IACR,aAAa,aAAa,MAAM,OAAO,SAAS;AAAA,EAClD;AACF,CAAC;"}
|
|
@@ -6,6 +6,7 @@ const { staticClasses, useClasses } = createClasses("HvTableHeader", {
|
|
|
6
6
|
"--cell-height": "32px",
|
|
7
7
|
height: "var(--cell-height)",
|
|
8
8
|
verticalAlign: "inherit",
|
|
9
|
+
alignContent: "inherit",
|
|
9
10
|
textAlign: "left",
|
|
10
11
|
padding: theme.spacing(0, 1, 0, 4),
|
|
11
12
|
borderBottom: `1px solid ${theme.colors.atmo4}`
|
|
@@ -13,6 +14,7 @@ const { staticClasses, useClasses } = createClasses("HvTableHeader", {
|
|
|
13
14
|
head: {
|
|
14
15
|
paddingTop: 8,
|
|
15
16
|
verticalAlign: "top",
|
|
17
|
+
alignContent: "start",
|
|
16
18
|
...theme.typography.label,
|
|
17
19
|
transition: "background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms",
|
|
18
20
|
backgroundColor: theme.colors.atmo1,
|
|
@@ -30,6 +32,7 @@ const { staticClasses, useClasses } = createClasses("HvTableHeader", {
|
|
|
30
32
|
},
|
|
31
33
|
"&$sortable": {
|
|
32
34
|
verticalAlign: "initial",
|
|
35
|
+
alignContent: "initial",
|
|
33
36
|
paddingTop: 0,
|
|
34
37
|
paddingLeft: 0,
|
|
35
38
|
cursor: "pointer",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableHeader.styles.js","sources":["../../../../src/Table/TableHeader/TableHeader.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTableHeader\", {\n root: {\n \"--first-row-cell-height\": \"52px\",\n \"--cell-height\": \"32px\",\n height: \"var(--cell-height)\",\n verticalAlign: \"inherit\",\n textAlign: \"left\",\n padding: theme.spacing(0, 1, 0, 4),\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n },\n head: {\n paddingTop: 8,\n verticalAlign: \"top\",\n ...theme.typography.label,\n transition: \"background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms\",\n backgroundColor: theme.colors.atmo1,\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n\n \"*:first-of-type > &\": {\n height: \"var(--first-row-cell-height)\",\n borderTop: \"1px solid transparent\",\n },\n\n \"&$variantList\": {\n backgroundColor: \"inherit\",\n borderBottom: 0,\n \"*:first-of-type > &\": {\n borderTop: 0,\n },\n },\n\n \"&$sortable\": {\n verticalAlign: \"initial\",\n paddingTop: 0,\n paddingLeft: 0,\n cursor: \"pointer\",\n\n \"&:hover\": {\n backgroundColor: \"transparent\",\n\n \"& $sortIcon\": {\n visibility: \"visible\",\n },\n },\n \"&:focus-within\": {\n backgroundColor: \"transparent\",\n\n \"& $sortIcon\": {\n visibility: \"visible\",\n },\n },\n },\n },\n body: {\n backgroundColor: \"inherit\",\n ...theme.typography.body,\n \"&$sortable:not($variantNone)\": {\n paddingLeft: 32,\n },\n },\n footer: {},\n stickyColumn: {\n position: \"sticky\",\n zIndex: 2,\n\n \"&$groupColumnMostRight+$stickyColumn\": {\n borderLeft: 0,\n },\n },\n stickyColumnMostLeft: { borderRight: `solid 1px ${theme.colors.atmo4}` },\n stickyColumnLeastRight: { borderLeft: `solid 1px ${theme.colors.atmo4}` },\n groupColumnMostLeft: { borderLeft: `solid 1px ${theme.colors.atmo4}` },\n groupColumnMostRight: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n // due to the \":has()\" selector not being supported in browsers,\n // this need to be managed with inline styles\n // To be uncommented when not needed (see comment in src/Table/hooks/useSticky.js)\n // \"&:last-child,&:has(+ $stickyColumnLeastRight)\": {\n \"&:last-child\": {\n borderRight: 0,\n },\n \"&+:not($stickyColumn)\": {\n borderLeft: 0,\n },\n },\n headerContent: { display: \"flex\", alignItems: \"flex-start\", width: \"100%\" },\n headerText: { overflow: \"hidden\", textOverflow: \"ellipsis\" },\n headerParagraph: { overflow: \"hidden\", display: \"-webkit-box\" },\n sortableHeaderText: { paddingTop: \"8px\" },\n sorted: {\n \"& $sortIcon\": {\n visibility: \"visible\",\n },\n },\n sortable: {},\n sortButton: {\n \"$root$sortable &\": {\n boxShadow: \"none\",\n backgroundColor: \"transparent\",\n \"&:hover\": {\n backgroundColor: theme.colors.primary_20,\n },\n },\n },\n sortIcon: { display: \"inline-flex\", visibility: \"hidden\" },\n alignLeft: { textAlign: \"left\" },\n alignRight: { textAlign: \"right\", flexDirection: \"row-reverse\" },\n alignCenter: { textAlign: \"center\" },\n alignJustify: { textAlign: \"justify\" },\n alignFlexLeft: { justifyContent: \"flex-start\" },\n alignFlexRight: { justifyContent: \"flex-end\" },\n alignFlexCenter: { justifyContent: \"center\" },\n alignFlexJustify: { textAlign: \"justify\" },\n variantCheckbox: {\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n variantExpand: {},\n variantActions: {\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n variantNone: { padding: 0 },\n variantList: {\n backgroundColor: \"inherit\",\n borderBottom: 0,\n height: 16,\n \":first-of-type > &\": {\n borderTop: 0,\n height: 16,\n },\n },\n resizable: { borderRight: `solid 1px ${theme.colors.atmo4}` },\n resizing: { borderRight: `solid 2px ${theme.colors.secondary}` },\n resizer: {\n display: \"inline-block\",\n width: 10,\n height: \"100%\",\n position: \"absolute\",\n right: 0,\n top: 0,\n transform: \"translateX(50%)\",\n zIndex: 1,\n touchAction: \"none\",\n },\n});\n"],"names":[],"mappings":";;AAGO,MAAM,EAAE,eAAe,eAAe,cAAc,iBAAiB;AAAA,EAC1E,MAAM;AAAA,IACJ,2BAA2B;AAAA,IAC3B,iBAAiB;AAAA,IACjB,QAAQ;AAAA,IACR,eAAe;AAAA,IACf,WAAW;AAAA,IACX,SAAS,MAAM,QAAQ,GAAG,GAAG,GAAG,CAAC;AAAA,IACjC,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,EAC/C;AAAA,EACA,MAAM;AAAA,IACJ,YAAY;AAAA,IACZ,eAAe;AAAA,IACf,GAAG,MAAM,WAAW;AAAA,IACpB,YAAY;AAAA,IACZ,iBAAiB,MAAM,OAAO;AAAA,IAC9B,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,IAE7C,uBAAuB;AAAA,MACrB,QAAQ;AAAA,MACR,WAAW;AAAA,IACb;AAAA,IAEA,iBAAiB;AAAA,MACf,iBAAiB;AAAA,MACjB,cAAc;AAAA,MACd,uBAAuB;AAAA,QACrB,WAAW;AAAA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V,OAAO;AAAA,IACP,KAAK;AAAA,IACL,WAAW;AAAA,IACX,QAAQ;AAAA,IACR,aAAa;AAAA,EACf;AACF,CAAC;"}
|
|
1
|
+
{"version":3,"file":"TableHeader.styles.js","sources":["../../../../src/Table/TableHeader/TableHeader.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTableHeader\", {\n root: {\n \"--first-row-cell-height\": \"52px\",\n \"--cell-height\": \"32px\",\n height: \"var(--cell-height)\",\n verticalAlign: \"inherit\",\n alignContent: \"inherit\",\n textAlign: \"left\",\n padding: theme.spacing(0, 1, 0, 4),\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n },\n head: {\n paddingTop: 8,\n verticalAlign: \"top\",\n alignContent: \"start\",\n ...theme.typography.label,\n transition: \"background-color 150ms cubic-bezier(0.4, 0, 0.2, 1) 0ms\",\n backgroundColor: theme.colors.atmo1,\n borderBottom: `1px solid ${theme.colors.atmo4}`,\n\n \"*:first-of-type > &\": {\n height: \"var(--first-row-cell-height)\",\n borderTop: \"1px solid transparent\",\n },\n\n \"&$variantList\": {\n backgroundColor: \"inherit\",\n borderBottom: 0,\n \"*:first-of-type > &\": {\n borderTop: 0,\n },\n },\n\n \"&$sortable\": {\n verticalAlign: \"initial\",\n alignContent: \"initial\",\n paddingTop: 0,\n paddingLeft: 0,\n cursor: \"pointer\",\n\n \"&:hover\": {\n backgroundColor: \"transparent\",\n\n \"& $sortIcon\": {\n visibility: \"visible\",\n },\n },\n \"&:focus-within\": {\n backgroundColor: \"transparent\",\n\n \"& $sortIcon\": {\n visibility: \"visible\",\n },\n },\n },\n },\n body: {\n backgroundColor: \"inherit\",\n ...theme.typography.body,\n \"&$sortable:not($variantNone)\": {\n paddingLeft: 32,\n },\n },\n footer: {},\n stickyColumn: {\n position: \"sticky\",\n zIndex: 2,\n\n \"&$groupColumnMostRight+$stickyColumn\": {\n borderLeft: 0,\n },\n },\n stickyColumnMostLeft: { borderRight: `solid 1px ${theme.colors.atmo4}` },\n stickyColumnLeastRight: { borderLeft: `solid 1px ${theme.colors.atmo4}` },\n groupColumnMostLeft: { borderLeft: `solid 1px ${theme.colors.atmo4}` },\n groupColumnMostRight: {\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n // due to the \":has()\" selector not being supported in browsers,\n // this need to be managed with inline styles\n // To be uncommented when not needed (see comment in src/Table/hooks/useSticky.js)\n // \"&:last-child,&:has(+ $stickyColumnLeastRight)\": {\n \"&:last-child\": {\n borderRight: 0,\n },\n \"&+:not($stickyColumn)\": {\n borderLeft: 0,\n },\n },\n headerContent: { display: \"flex\", alignItems: \"flex-start\", width: \"100%\" },\n headerText: { overflow: \"hidden\", textOverflow: \"ellipsis\" },\n headerParagraph: { overflow: \"hidden\", display: \"-webkit-box\" },\n sortableHeaderText: { paddingTop: \"8px\" },\n sorted: {\n \"& $sortIcon\": {\n visibility: \"visible\",\n },\n },\n sortable: {},\n sortButton: {\n \"$root$sortable &\": {\n boxShadow: \"none\",\n backgroundColor: \"transparent\",\n \"&:hover\": {\n backgroundColor: theme.colors.primary_20,\n },\n },\n },\n sortIcon: { display: \"inline-flex\", visibility: \"hidden\" },\n alignLeft: { textAlign: \"left\" },\n alignRight: { textAlign: \"right\", flexDirection: \"row-reverse\" },\n alignCenter: { textAlign: \"center\" },\n alignJustify: { textAlign: \"justify\" },\n alignFlexLeft: { justifyContent: \"flex-start\" },\n alignFlexRight: { justifyContent: \"flex-end\" },\n alignFlexCenter: { justifyContent: \"center\" },\n alignFlexJustify: { textAlign: \"justify\" },\n variantCheckbox: {\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderRight: `solid 1px ${theme.colors.atmo4}`,\n },\n variantExpand: {},\n variantActions: {\n padding: 0,\n width: 32,\n maxWidth: 32,\n borderLeft: `solid 1px ${theme.colors.atmo4}`,\n },\n variantNone: { padding: 0 },\n variantList: {\n backgroundColor: \"inherit\",\n borderBottom: 0,\n height: 16,\n \":first-of-type > &\": {\n borderTop: 0,\n height: 16,\n },\n },\n resizable: { borderRight: `solid 1px ${theme.colors.atmo4}` },\n resizing: { borderRight: `solid 2px ${theme.colors.secondary}` },\n resizer: {\n display: \"inline-block\",\n width: 10,\n height: \"100%\",\n position: \"absolute\",\n right: 0,\n top: 0,\n transform: \"translateX(50%)\",\n zIndex: 1,\n touchAction: \"none\",\n },\n});\n"],"names":[],"mappings":";;AAGO,MAAM,EAAE,eAAe,eAAe,cAAc,iBAAiB;AAAA,EAC1E,MAAM;AAAA,IACJ,2BAA2B;AAAA,IAC3B,iBAAiB;AAAA,IACjB,QAAQ;AAAA,IACR,eAAe;AAAA,IACf,cAAc;AAAA,IACd,WAAW;AAAA,IACX,SAAS,MAAM,QAAQ,GAAG,GAAG,GAAG,CAAC;AAAA,IACjC,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,EAC/C;AAAA,EACA,MAAM;AAAA,IACJ,YAAY;AAAA,IACZ,eAAe;AAAA,IACf,cAAc;AAAA,IACd,GAAG,MAAM,WAAW;AAAA,IACpB,YAAY;AAAA,IACZ,iBAAiB,MAAM,OAAO;AAAA,IAC9B,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,IAE7C,uBAAuB;AAAA,MACrB,QAAQ;AAAA,MACR,WAAW;AAAA,IACb;AAAA,IAEA,iBAAiB;AAAA,MACf,iBAAiB;AAAA,MACjB,cAAc;AAAA,MACd,uBAAuB;AAAA,QACrB,WAAW;AAAA,MACb;AAAA,IACF;AAAA,IAEA,cAAc;AAAA,MACZ,eAAe;AAAA,MACf,cAAc;AAAA,MACd,YAAY;AAAA,MACZ,aAAa;AAAA,MACb,QAAQ;AAAA,MAER,WAAW;AAAA,QACT,iBAAiB;AAAA,QAEjB,eAAe;AAAA,UACb,YAAY;AAAA,QACd;AAAA,MACF;AAAA,MACA,kBAAkB;AAAA,QAChB,iBAAiB;AAAA,QAEjB,eAAe;AAAA,UACb,Y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AAAA,EAC/B,YAAY,EAAE,WAAW,SAAS,eAAe,cAAc;AAAA,EAC/D,aAAa,EAAE,WAAW,SAAS;AAAA,EACnC,cAAc,EAAE,WAAW,UAAU;AAAA,EACrC,eAAe,EAAE,gBAAgB,aAAa;AAAA,EAC9C,gBAAgB,EAAE,gBAAgB,WAAW;AAAA,EAC7C,iBAAiB,EAAE,gBAAgB,SAAS;AAAA,EAC5C,kBAAkB,EAAE,WAAW,UAAU;AAAA,EACzC,iBAAiB;AAAA,IACf,SAAS;AAAA,IACT,OAAO;AAAA,IACP,UAAU;AAAA,IACV,aAAa,aAAa,MAAM,OAAO,KAAK;AAAA,EAC9C;AAAA,EACA,eAAe,CAAC;AAAA,EAChB,gBAAgB;AAAA,IACd,SAAS;AAAA,IACT,OAAO;AAAA,IACP,UAAU;AAAA,IACV,YAAY,aAAa,MAAM,OAAO,KAAK;AAAA,EAC7C;AAAA,EACA,aAAa,EAAE,SAAS,EAAE;AAAA,EAC1B,aAAa;AAAA,IACX,iBAAiB;AAAA,IACjB,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,sBAAsB;AAAA,MACpB,WAAW;AAAA,MACX,QAAQ;AAAA,IACV;AAAA,EACF;AAAA,EACA,WAAW,EAAE,aAAa,aAAa,MAAM,OAAO,KAAK,GAAG;AAAA,EAC5D,UAAU,EAAE,aAAa,aAAa,MAAM,OAAO,SAAS,GAAG;AAAA,EAC/D,SAAS;AAAA,IACP,SAAS;AAAA,IACT,OAAO;AAAA,IACP,QAAQ;AAAA,IACR,UAAU;AAAA,IACV,OAAO;AAAA,IACP,KAAK;AAAA,IACL,WAAW;AAAA,IACX,QAAQ;AAAA,IACR,aAAa;AAAA,EACf;AACF,CAAC;"}
|
|
@@ -7,6 +7,7 @@ const { staticClasses, useClasses } = createClasses("HvTableRow", {
|
|
|
7
7
|
color: "inherit",
|
|
8
8
|
backgroundColor: theme.colors.atmo1,
|
|
9
9
|
verticalAlign: "middle",
|
|
10
|
+
alignContent: "center",
|
|
10
11
|
outline: 0
|
|
11
12
|
},
|
|
12
13
|
/** Styles applied to the component root when inside a `HvTableHead`. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TableRow.styles.js","sources":["../../../../src/Table/TableRow/TableRow.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\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.colors.atmo1,\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.colors.atmo2,\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 \"&:nth-of-type(even)\": {\n backgroundColor: theme.alpha(\"atmo1\", 0.6),\n\n \"&:hover\": {\n backgroundColor: theme.colors.containerBackgroundHover,\n },\n },\n \"&:nth-of-type(odd)\": {\n backgroundColor: \"transparent\",\n\n \"&:hover\": {\n backgroundColor: theme.colors.containerBackgroundHover,\n },\n },\n },\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.colors.containerBackgroundHover,\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.radii.round,\n\n ...getBorderStyles(theme.colors.atmo4, theme.radii.round),\n backgroundColor: theme.colors.atmo1,\n \"&$selected\": {\n ...getBorderStyles(theme.colors.secondary, theme.radii.round),\n\n \"&:hover\": {\n ...getBorderStyles(theme.colors.atmo4, theme.radii.round),\n },\n },\n\n \"&:hover\": {\n ...getBorderStyles(theme.colors.atmo4, theme.radii.round),\n },\n \"&.HvIsFocused\": {\n borderRadius: theme.radii.round,\n },\n },\n /** Styles applied to the component root when its table variant is list. */\n variantListHead: {\n backgroundColor: \"transparent\",\n },\n});\n"],"names":[],"mappings":";;;AAKO,MAAM,EAAE,eAAe,eAAe,cAAc,cAAc;AAAA;AAAA,EAEvE,MAAM;AAAA,IACJ,OAAO;AAAA,IACP,iBAAiB,MAAM,OAAO;AAAA,IAC9B,eAAe;AAAA,IACf,SAAS;AAAA,EACX;AAAA;AAAA,EAEA,MAAM,CAAC;AAAA;AAAA,EAEP,MAAM,CAAC;AAAA;AAAA,EAEP,QAAQ,CAAC;AAAA;AAAA,EAET,UAAU;AAAA,IACR,iBAAiB,MAAM,OAAO;AAAA,EAChC;AAAA;AAAA,EAEA,UAAU;AAAA,IACR,iBAAiB,MAAM,OAAO;AAAA,IAC9B,oBAAoB;AAAA,MAClB,cAAc;AAAA,IAChB;AAAA,EACF;AAAA;AAAA,EAEA,SAAS;AAAA,IACP,uBAAuB;AAAA,MACrB,iBAAiB,MAAM,MAAM,SAAS,GAAG;AAAA,MAEzC,WAAW;AAAA,QACT,iBAAiB,MAAM,OAAO;AAAA,MAChC;AAAA,IACF;AAAA,IACA,sBAAsB;AAAA,MACpB,iBAAiB;AAAA,MAEjB,WAAW;AAAA,QACT,iBAAiB,MAAM,OAAO;AAAA,MAChC;AAAA,IACF;AAAA,EACF;AAAA;AAAA,EAEA,OAAO;AAAA,IACL,YAAY;AAAA,IACZ,WAAW;AAAA,MACT,iBAAiB,MAAM,OAAO;AAAA,IAChC;AAAA,EACF;AAAA;AAAA,EAEA,aAAa;AAAA;AAAA,IAEX,cAAc,MAAM,MAAM;AAAA,IAC1B,cAAc,MAAM,MAAM;AAAA,IAE1B,GAAG,gBAAgB,MAAM,OAAO,OAAO,MAAM,MAAM,KAAK;AAAA,IACxD,iBAAiB,MAAM,OAAO;AAAA,IAC9B,cAAc;AAAA,MACZ,GAAG,gBAAgB,MAAM,OAAO,WAAW,MAAM,MAAM,KAAK;AAAA,MAE5D,WAAW;AAAA,QACT,GAAG,gBAAgB,MAAM,OAAO,OAAO,MAAM,MAAM,KAAK;AAAA,MAC1D;AAAA,IACF;AAAA,IAEA,WAAW;AAAA,MACT,GAAG,gBAAgB,MAAM,OAAO,OAAO,MAAM,MAAM,KAAK;AAAA,IAC1D;AAAA,IACA,iBAAiB;AAAA,MACf,cAAc,MAAM,MAAM;AAAA,IAC5B;AAAA,EACF;AAAA;AAAA,EAEA,iBAAiB;AAAA,IACf,iBAAiB;AAAA,EACnB;AACF,CAAC;"}
|
|
1
|
+
{"version":3,"file":"TableRow.styles.js","sources":["../../../../src/Table/TableRow/TableRow.styles.tsx"],"sourcesContent":["import { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\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.colors.atmo1,\n verticalAlign: \"middle\",\n alignContent: \"center\",\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.colors.atmo2,\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 \"&:nth-of-type(even)\": {\n backgroundColor: theme.alpha(\"atmo1\", 0.6),\n\n \"&:hover\": {\n backgroundColor: theme.colors.containerBackgroundHover,\n },\n },\n \"&:nth-of-type(odd)\": {\n backgroundColor: \"transparent\",\n\n \"&:hover\": {\n backgroundColor: theme.colors.containerBackgroundHover,\n },\n },\n },\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.colors.containerBackgroundHover,\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.radii.round,\n\n ...getBorderStyles(theme.colors.atmo4, theme.radii.round),\n backgroundColor: theme.colors.atmo1,\n \"&$selected\": {\n ...getBorderStyles(theme.colors.secondary, theme.radii.round),\n\n \"&:hover\": {\n ...getBorderStyles(theme.colors.atmo4, theme.radii.round),\n },\n },\n\n \"&:hover\": {\n ...getBorderStyles(theme.colors.atmo4, theme.radii.round),\n },\n \"&.HvIsFocused\": {\n borderRadius: theme.radii.round,\n },\n },\n /** Styles applied to the component root when its table variant is list. */\n variantListHead: {\n backgroundColor: \"transparent\",\n },\n});\n"],"names":[],"mappings":";;;AAKO,MAAM,EAAE,eAAe,eAAe,cAAc,cAAc;AAAA;AAAA,EAEvE,MAAM;AAAA,IACJ,OAAO;AAAA,IACP,iBAAiB,MAAM,OAAO;AAAA,IAC9B,eAAe;AAAA,IACf,cAAc;AAAA,IACd,SAAS;AAAA,EACX;AAAA;AAAA,EAEA,MAAM,CAAC;AAAA;AAAA,EAEP,MAAM,CAAC;AAAA;AAAA,EAEP,QAAQ,CAAC;AAAA;AAAA,EAET,UAAU;AAAA,IACR,iBAAiB,MAAM,OAAO;AAAA,EAChC;AAAA;AAAA,EAEA,UAAU;AAAA,IACR,iBAAiB,MAAM,OAAO;AAAA,IAC9B,oBAAoB;AAAA,MAClB,cAAc;AAAA,IAChB;AAAA,EACF;AAAA;AAAA,EAEA,SAAS;AAAA,IACP,uBAAuB;AAAA,MACrB,iBAAiB,MAAM,MAAM,SAAS,GAAG;AAAA,MAEzC,WAAW;AAAA,QACT,iBAAiB,MAAM,OAAO;AAAA,MAChC;AAAA,IACF;AAAA,IACA,sBAAsB;AAAA,MACpB,iBAAiB;AAAA,MAEjB,WAAW;AAAA,QACT,iBAAiB,MAAM,OAAO;AAAA,MAChC;AAAA,IACF;AAAA,EACF;AAAA;AAAA,EAEA,OAAO;AAAA,IACL,YAAY;AAAA,IACZ,WAAW;AAAA,MACT,iBAAiB,MAAM,OAAO;AAAA,IAChC;AAAA,EACF;AAAA;AAAA,EAEA,aAAa;AAAA;AAAA,IAEX,cAAc,MAAM,MAAM;AAAA,IAC1B,cAAc,MAAM,MAAM;AAAA,IAE1B,GAAG,gBAAgB,MAAM,OAAO,OAAO,MAAM,MAAM,KAAK;AAAA,IACxD,iBAAiB,MAAM,OAAO;AAAA,IAC9B,cAAc;AAAA,MACZ,GAAG,gBAAgB,MAAM,OAAO,WAAW,MAAM,MAAM,KAAK;AAAA,MAE5D,WAAW;AAAA,QACT,GAAG,gBAAgB,MAAM,OAAO,OAAO,MAAM,MAAM,KAAK;AAAA,MAC1D;AAAA,IACF;AAAA,IAEA,WAAW;AAAA,MACT,GAAG,gBAAgB,MAAM,OAAO,OAAO,MAAM,MAAM,KAAK;AAAA,IAC1D;AAAA,IACA,iBAAiB;AAAA,MACf,cAAc,MAAM,MAAM;AAAA,IAC5B;AAAA,EACF;AAAA;AAAA,EAEA,iBAAiB;AAAA,IACf,iBAAiB;AAAA,EACnB;AACF,CAAC;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { DropDownXS
|
|
2
|
+
import { DropDownXS } from "@hitachivantara/uikit-react-icons";
|
|
3
3
|
import { useLabels } from "../../hooks/useLabels.js";
|
|
4
4
|
import { HvButton } from "../../Button/Button.js";
|
|
5
5
|
import { HvTypography } from "../../Typography/Typography.js";
|
|
@@ -13,7 +13,7 @@ const CellWithExpandButton = ({
|
|
|
13
13
|
labels: labelsProp
|
|
14
14
|
}) => {
|
|
15
15
|
const labels = useLabels(DEFAULT_LABELS, labelsProp);
|
|
16
|
-
const
|
|
16
|
+
const rowProps = row.getToggleRowExpandedProps?.();
|
|
17
17
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
18
18
|
/* @__PURE__ */ jsx(
|
|
19
19
|
HvButton,
|
|
@@ -21,8 +21,8 @@ const CellWithExpandButton = ({
|
|
|
21
21
|
icon: true,
|
|
22
22
|
"aria-label": row.isExpanded ? labels.collapseRowButtonAriaLabel : labels.expandRowButtonAriaLabel,
|
|
23
23
|
"aria-expanded": row.isExpanded,
|
|
24
|
-
onClick,
|
|
25
|
-
children:
|
|
24
|
+
onClick: rowProps?.onClick,
|
|
25
|
+
children: /* @__PURE__ */ jsx(DropDownXS, { style: { rotate: row.isExpanded ? "180deg" : void 0 } })
|
|
26
26
|
}
|
|
27
27
|
),
|
|
28
28
|
cell?.value && /* @__PURE__ */ jsx(HvTypography, { variant: "label", component: "span", children: cell.value })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRowExpand.js","sources":["../../../../src/Table/hooks/useRowExpand.tsx"],"sourcesContent":["import {\n Hooks,\n TableExpandedToggleProps,\n UseExpandedRowProps,\n} from \"react-table\";\nimport { DropDownXS
|
|
1
|
+
{"version":3,"file":"useRowExpand.js","sources":["../../../../src/Table/hooks/useRowExpand.tsx"],"sourcesContent":["import {\n Hooks,\n TableExpandedToggleProps,\n UseExpandedRowProps,\n} from \"react-table\";\nimport { DropDownXS } from \"@hitachivantara/uikit-react-icons\";\n\nimport { HvButton } from \"../../Button\";\nimport { useLabels } from \"../../hooks/useLabels\";\nimport { HvTypography } from \"../../Typography\";\nimport type { HvCellProps } from \"./useTable\";\n\n// #region ##### TYPES #####\n\nexport interface UseHvRowExpandTableRowProps {\n expanded?: boolean;\n}\n\nexport type UseHvRowExpandTableOptions = {\n disableCreateExpandButton?: boolean;\n};\n\nexport interface UseHvRowExpandRowToggleProps extends TableExpandedToggleProps {\n onClick?: React.MouseEventHandler<unknown>;\n}\n\nexport interface UseHvRowExpandRowInstance<\n D extends object = Record<string, unknown>,\n> extends UseExpandedRowProps<D> {\n getToggleRowExpandedProps: (\n props?: Partial<TableExpandedToggleProps>,\n ) => UseHvRowExpandRowToggleProps;\n}\n\nexport type UseRowExpandProps = (<D extends object = Record<string, unknown>>(\n hooks: Hooks<D>,\n) => void) & { pluginName: string };\n\n// #endregion ##### TYPES #####\n\nconst DEFAULT_LABELS = {\n expandRowButtonAriaLabel: \"Expand this row\",\n collapseRowButtonAriaLabel: \"Collapse this row\",\n};\n\nexport const CellWithExpandButton = ({\n row,\n cell,\n labels: labelsProp,\n}: HvCellProps<any>) => {\n const labels = useLabels(DEFAULT_LABELS, labelsProp);\n const rowProps = row.getToggleRowExpandedProps?.();\n\n return (\n <>\n <HvButton\n icon\n aria-label={\n row.isExpanded\n ? labels.collapseRowButtonAriaLabel\n : labels.expandRowButtonAriaLabel\n }\n aria-expanded={row.isExpanded}\n onClick={rowProps?.onClick}\n >\n <DropDownXS style={{ rotate: row.isExpanded ? \"180deg\" : undefined }} />\n </HvButton>\n {cell?.value && (\n <HvTypography variant=\"label\" component=\"span\">\n {cell.value}\n </HvTypography>\n )}\n </>\n );\n};\n\nconst visibleColumnsHook = (columns: any, { instance }: any) => {\n if (instance.disableCreateExpandButton) {\n return columns;\n }\n\n // add a button to first data column, unless it has a custom renderer\n // if so, add an extra column instead\n const firstDataColumnIndex = columns.findIndex(\n (c: any) => c.id?.indexOf(\"_hv_\") !== 0,\n );\n\n if (firstDataColumnIndex !== -1) {\n const firstDataColumn = columns[firstDataColumnIndex];\n\n if (firstDataColumn.Cell == null) {\n firstDataColumn.Cell = CellWithExpandButton;\n firstDataColumn.variant = \"expand\";\n\n return columns;\n }\n }\n\n const expandColumn = {\n id: \"_hv_expand\",\n variant: \"none\",\n\n width: 32,\n\n // this will only work when using useHvTableSticky\n // but ensures it stays left of any sticky column\n sticky: \"left\",\n\n Cell: CellWithExpandButton,\n };\n\n const columnsCopy = [...columns];\n columnsCopy.splice(\n firstDataColumnIndex !== -1 ? firstDataColumnIndex : 0,\n 0,\n expandColumn,\n );\n\n return columnsCopy;\n};\n\nconst getRowPropsHook = (props: any, { row }: any) => {\n const nextProps: UseHvRowExpandTableRowProps = {\n expanded: row.isExpanded,\n };\n\n return [props, nextProps];\n};\n\nconst useRowExpand: UseRowExpandProps = (hooks) => {\n hooks.visibleColumns.push(visibleColumnsHook);\n hooks.getRowProps.push(getRowPropsHook);\n};\nuseRowExpand.pluginName = \"useHvRowExpand\";\n\nexport default useRowExpand;\n"],"names":[],"mappings":";;;;;AAwCA,MAAM,iBAAiB;AAAA,EACrB,0BAA0B;AAAA,EAC1B,4BAA4B;AAC9B;AAEO,MAAM,uBAAuB,CAAC;AAAA,EACnC;AAAA,EACA;AAAA,EACA,QAAQ;AACV,MAAwB;AAChB,QAAA,SAAS,UAAU,gBAAgB,UAAU;AAC7C,QAAA,WAAW,IAAI;AAErB,SAEI,qBAAA,UAAA,EAAA,UAAA;AAAA,IAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,MAAI;AAAA,QACJ,cACE,IAAI,aACA,OAAO,6BACP,OAAO;AAAA,QAEb,iBAAe,IAAI;AAAA,QACnB,SAAS,UAAU;AAAA,QAEnB,UAAA,oBAAC,cAAW,OAAO,EAAE,QAAQ,IAAI,aAAa,WAAW,OAAa,EAAA,CAAA;AAAA,MAAA;AAAA,IACxE;AAAA,IACC,MAAM,SACJ,oBAAA,cAAA,EAAa,SAAQ,SAAQ,WAAU,QACrC,UAAA,KAAK,MACR,CAAA;AAAA,EAEJ,EAAA,CAAA;AAEJ;AAEA,MAAM,qBAAqB,CAAC,SAAc,EAAE,eAAoB;AAC9D,MAAI,SAAS,2BAA2B;AAC/B,WAAA;AAAA,EACT;AAIA,QAAM,uBAAuB,QAAQ;AAAA,IACnC,CAAC,MAAW,EAAE,IAAI,QAAQ,MAAM,MAAM;AAAA,EAAA;AAGxC,MAAI,yBAAyB,IAAI;AACzB,UAAA,kBAAkB,QAAQ,oBAAoB;AAEhD,QAAA,gBAAgB,QAAQ,MAAM;AAChC,sBAAgB,OAAO;AACvB,sBAAgB,UAAU;AAEnB,aAAA;AAAA,IACT;AAAA,EACF;AAEA,QAAM,eAAe;AAAA,IACnB,IAAI;AAAA,IACJ,SAAS;AAAA,IAET,OAAO;AAAA;AAAA;AAAA,IAIP,QAAQ;AAAA,IAER,MAAM;AAAA,EAAA;AAGF,QAAA,cAAc,CAAC,GAAG,OAAO;AACnB,cAAA;AAAA,IACV,yBAAyB,KAAK,uBAAuB;AAAA,IACrD;AAAA,IACA;AAAA,EAAA;AAGK,SAAA;AACT;AAEA,MAAM,kBAAkB,CAAC,OAAY,EAAE,UAAe;AACpD,QAAM,YAAyC;AAAA,IAC7C,UAAU,IAAI;AAAA,EAAA;AAGT,SAAA,CAAC,OAAO,SAAS;AAC1B;AAEM,MAAA,eAAkC,CAAC,UAAU;AAC3C,QAAA,eAAe,KAAK,kBAAkB;AACtC,QAAA,YAAY,KAAK,eAAe;AACxC;AACA,aAAa,aAAa;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.js","sources":["../../../src/Tooltip/Tooltip.tsx"],"sourcesContent":["import { forwardRef, useEffect, useState } from \"react\";\nimport Fade from \"@mui/material/Fade\";\nimport Tooltip, {\n TooltipProps as MuiTooltipProps,\n} from \"@mui/material/Tooltip\";\nimport {\n useDefaultProps,\n useTheme,\n type ExtractNames,\n} from \"@hitachivantara/uikit-react-utils\";\n\nimport { getElementById } from \"../utils/document\";\nimport { staticClasses, useClasses } from \"./Tooltip.styles\";\n\nexport { staticClasses as tooltipClasses };\n\nexport type HvTooltipClasses = ExtractNames<typeof useClasses>;\nexport type HvTooltipPlacementType = MuiTooltipProps[\"placement\"];\n\nexport interface HvTooltipProps extends Omit<MuiTooltipProps, \"classes\"> {\n /**\n * Class names to be applied.\n */\n className?: string;\n /**\n * A Jss Object used to override or extend the styles applied.\n */\n classes?: HvTooltipClasses;\n /**\n * If true, the tooltip is shown.\n */\n open?: boolean;\n /**\n * Tooltip placement.\n */\n placement?: HvTooltipPlacementType;\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This property won't impact the enter touch delay (enterTouchDelay).\n */\n enterDelay?: number;\n /** @inheritdoc */\n title: MuiTooltipProps[\"title\"];\n /** @inheritdoc */\n TransitionComponent?: MuiTooltipProps[\"TransitionComponent\"];\n /** @inheritdoc */\n TransitionProps?: MuiTooltipProps[\"TransitionProps\"];\n /**\n * Defines if should use a single or multiline tooltip.\n */\n useSingle?: boolean;\n /**\n * Node to apply the tooltip.\n */\n children: React.ReactElement;\n /**\n * Id attribute value of an HTML Element to have the tooltip appended to it.\n */\n containerId?: string;\n}\n\n/**\n * Tooltips display informative text when users hover over, focus on, or tap an element.\n * Accessibility-wise, the tooltip automatically labels the `children` content.\n *\n * If you are looking to wrap an icon only button with a tooltip, take a look at the `HvIconButton` component\n * which offers you thus behavior out of the box.\n */\nexport const HvTooltip = forwardRef((props: HvTooltipProps, ref) => {\n const {\n className,\n classes: classesProp,\n open,\n enterDelay = 300,\n placement = \"top\",\n useSingle = true,\n children,\n title,\n TransitionComponent = Fade,\n TransitionProps = { timeout: 400, placement: \"top\" },\n containerId,\n ...others\n } = useDefaultProps(\"HvTooltip\", props);\n\n const { rootId } = useTheme();\n const { classes } = useClasses(classesProp);\n const [container, setContainer] = useState(() =>\n getElementById(containerId ?? rootId),\n );\n\n // force extra render to get the correct container DOM element\n useEffect(() => {\n setContainer(getElementById(containerId ?? rootId));\n }, [containerId, rootId]);\n\n return (\n <Tooltip\n ref={ref}\n open={open}\n enterDelay={enterDelay}\n placement={placement}\n TransitionComponent={TransitionComponent}\n TransitionProps={TransitionProps}\n className={className}\n classes={{\n tooltip: useSingle ? classes.tooltip : classes.tooltipMulti,\n popper: classes.popper,\n }}\n title={title}\n PopperProps={{ container }}\n {...others}\n >\n {children}\n </Tooltip>\n );\n});\n"],"names":[],"mappings":";;;;;;;;
|
|
1
|
+
{"version":3,"file":"Tooltip.js","sources":["../../../src/Tooltip/Tooltip.tsx"],"sourcesContent":["import { forwardRef, useEffect, useState } from \"react\";\nimport Fade from \"@mui/material/Fade\";\nimport Tooltip, {\n TooltipProps as MuiTooltipProps,\n} from \"@mui/material/Tooltip\";\nimport {\n useDefaultProps,\n useTheme,\n type ExtractNames,\n} from \"@hitachivantara/uikit-react-utils\";\n\nimport { getElementById } from \"../utils/document\";\nimport { staticClasses, useClasses } from \"./Tooltip.styles\";\n\nexport { staticClasses as tooltipClasses };\n\nexport type HvTooltipClasses = ExtractNames<typeof useClasses>;\nexport type HvTooltipPlacementType = MuiTooltipProps[\"placement\"];\n\nexport interface HvTooltipProps extends Omit<MuiTooltipProps, \"classes\"> {\n /**\n * Class names to be applied.\n */\n className?: string;\n /**\n * A Jss Object used to override or extend the styles applied.\n */\n classes?: HvTooltipClasses;\n /**\n * If true, the tooltip is shown.\n */\n open?: boolean;\n /**\n * Tooltip placement.\n */\n placement?: HvTooltipPlacementType;\n /**\n * The number of milliseconds to wait before showing the tooltip.\n * This property won't impact the enter touch delay (enterTouchDelay).\n */\n enterDelay?: number;\n /** @inheritdoc */\n title: MuiTooltipProps[\"title\"];\n /** @inheritdoc */\n TransitionComponent?: MuiTooltipProps[\"TransitionComponent\"];\n /** @inheritdoc */\n TransitionProps?: MuiTooltipProps[\"TransitionProps\"];\n /**\n * Defines if should use a single or multiline tooltip.\n * @deprecated tooltips already support multiline and can be styled accordingly.\n */\n useSingle?: boolean;\n /**\n * Node to apply the tooltip.\n */\n children: React.ReactElement;\n /**\n * Id attribute value of an HTML Element to have the tooltip appended to it.\n */\n containerId?: string;\n}\n\n/**\n * Tooltips display informative text when users hover over, focus on, or tap an element.\n * Accessibility-wise, the tooltip automatically labels the `children` content.\n *\n * If you are looking to wrap an icon only button with a tooltip, take a look at the `HvIconButton` component\n * which offers you thus behavior out of the box.\n */\nexport const HvTooltip = forwardRef((props: HvTooltipProps, ref) => {\n const {\n className,\n classes: classesProp,\n open,\n enterDelay = 300,\n placement = \"top\",\n useSingle = true,\n children,\n title,\n TransitionComponent = Fade,\n TransitionProps = { timeout: 400, placement: \"top\" },\n containerId,\n ...others\n } = useDefaultProps(\"HvTooltip\", props);\n\n const { rootId } = useTheme();\n const { classes } = useClasses(classesProp);\n const [container, setContainer] = useState(() =>\n getElementById(containerId ?? rootId),\n );\n\n // force extra render to get the correct container DOM element\n useEffect(() => {\n setContainer(getElementById(containerId ?? rootId));\n }, [containerId, rootId]);\n\n return (\n <Tooltip\n ref={ref}\n open={open}\n enterDelay={enterDelay}\n placement={placement}\n TransitionComponent={TransitionComponent}\n TransitionProps={TransitionProps}\n className={className}\n classes={{\n tooltip: useSingle ? classes.tooltip : classes.tooltipMulti,\n popper: classes.popper,\n }}\n title={title}\n PopperProps={{ container }}\n {...others}\n >\n {children}\n </Tooltip>\n );\n});\n"],"names":[],"mappings":";;;;;;;;AAqEO,MAAM,YAAY,WAAW,CAAC,OAAuB,QAAQ;AAC5D,QAAA;AAAA,IACJ;AAAA,IACA,SAAS;AAAA,IACT;AAAA,IACA,aAAa;AAAA,IACb,YAAY;AAAA,IACZ,YAAY;AAAA,IACZ;AAAA,IACA;AAAA,IACA,sBAAsB;AAAA,IACtB,kBAAkB,EAAE,SAAS,KAAK,WAAW,MAAM;AAAA,IACnD;AAAA,IACA,GAAG;AAAA,EAAA,IACD,gBAAgB,aAAa,KAAK;AAEhC,QAAA,EAAE,WAAW;AACnB,QAAM,EAAE,QAAA,IAAY,WAAW,WAAW;AACpC,QAAA,CAAC,WAAW,YAAY,IAAI;AAAA,IAAS,MACzC,eAAe,eAAe,MAAM;AAAA,EAAA;AAItC,YAAU,MAAM;AACD,iBAAA,eAAe,eAAe,MAAM,CAAC;AAAA,EAAA,GACjD,CAAC,aAAa,MAAM,CAAC;AAGtB,SAAA;AAAA,IAAC;AAAA,IAAA;AAAA,MACC;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA,SAAS;AAAA,QACP,SAAS,YAAY,QAAQ,UAAU,QAAQ;AAAA,QAC/C,QAAQ,QAAQ;AAAA,MAClB;AAAA,MACA;AAAA,MACA,aAAa,EAAE,UAAU;AAAA,MACxB,GAAG;AAAA,MAEH;AAAA,IAAA;AAAA,EAAA;AAGP,CAAC;"}
|
|
@@ -4,13 +4,9 @@ import { theme } from "@hitachivantara/uikit-styles";
|
|
|
4
4
|
const { staticClasses, useClasses } = createClasses("HvTooltip", {
|
|
5
5
|
root: {},
|
|
6
6
|
tooltip: {},
|
|
7
|
-
tooltipMulti: {},
|
|
8
7
|
popper: {
|
|
9
|
-
|
|
10
|
-
opacity: 1
|
|
11
|
-
},
|
|
8
|
+
// TODO: move this to `tooltip` in v6 and make class always be applied
|
|
12
9
|
[`& .${tooltipClasses.tooltip}`]: {
|
|
13
|
-
fontFamily: theme.fontFamily.body,
|
|
14
10
|
...theme.typography.body,
|
|
15
11
|
display: "flex",
|
|
16
12
|
width: "fit-content",
|
|
@@ -54,19 +50,29 @@ const { staticClasses, useClasses } = createClasses("HvTooltip", {
|
|
|
54
50
|
padding: theme.space.sm
|
|
55
51
|
},
|
|
56
52
|
"& $tooltip": {
|
|
57
|
-
padding:
|
|
53
|
+
padding: theme.space.sm,
|
|
58
54
|
borderRadius: theme.radii.round,
|
|
59
55
|
"& p": {
|
|
60
56
|
wordBreak: "break-word"
|
|
61
57
|
}
|
|
62
58
|
}
|
|
63
59
|
},
|
|
60
|
+
// TODO: remove in v6
|
|
61
|
+
/** @deprecated */
|
|
62
|
+
tooltipMulti: {},
|
|
63
|
+
/** @deprecated */
|
|
64
64
|
title: {},
|
|
65
|
+
/** @deprecated */
|
|
65
66
|
valuesContainer: {},
|
|
67
|
+
/** @deprecated */
|
|
66
68
|
values: {},
|
|
69
|
+
/** @deprecated */
|
|
67
70
|
color: {},
|
|
71
|
+
/** @deprecated */
|
|
68
72
|
separatorColor: {},
|
|
73
|
+
/** @deprecated */
|
|
69
74
|
separator: {},
|
|
75
|
+
/** @deprecated */
|
|
70
76
|
valueWrapper: {}
|
|
71
77
|
});
|
|
72
78
|
export {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.styles.js","sources":["../../../src/Tooltip/Tooltip.styles.tsx"],"sourcesContent":["import { tooltipClasses as MuitooltipClasses } from \"@mui/material/Tooltip\";\nimport { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTooltip\", {\n root: {},\n tooltip: {},\n
|
|
1
|
+
{"version":3,"file":"Tooltip.styles.js","sources":["../../../src/Tooltip/Tooltip.styles.tsx"],"sourcesContent":["import { tooltipClasses as MuitooltipClasses } from \"@mui/material/Tooltip\";\nimport { createClasses } from \"@hitachivantara/uikit-react-utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvTooltip\", {\n root: {},\n tooltip: {},\n popper: {\n // TODO: move this to `tooltip` in v6 and make class always be applied\n [`& .${MuitooltipClasses.tooltip}`]: {\n ...theme.typography.body,\n display: \"flex\",\n width: \"fit-content\",\n maxWidth: 532,\n backgroundColor: theme.colors.atmo1,\n boxShadow: theme.colors.shadow,\n padding: 0,\n\n \"& p\": {\n display: \"-webkit-box\",\n width: \"fit-content\",\n boxOrient: \"vertical\",\n textOverflow: \"ellipsis\",\n overflow: \"hidden\",\n },\n },\n \"& $title\": {\n padding: \"15px 20px\",\n borderBottom: `3px solid ${theme.colors.atmo2}`,\n },\n \"& $valuesContainer\": {\n padding: theme.space.sm,\n },\n \"& $values\": {\n display: \"flex\",\n justifyContent: \"space-between\",\n paddingBottom: \"10px\",\n \"&:last-child\": {\n paddingBottom: 0,\n },\n },\n \"& $color\": {\n width: theme.space.xs,\n },\n \"& $separator\": {\n width: theme.space.xs,\n },\n \"& $separatorColor\": {\n width: \"5px\",\n },\n \"& $valueWrapper\": {\n padding: theme.space.sm,\n },\n \"& $tooltip\": {\n padding: theme.space.sm,\n borderRadius: theme.radii.round,\n \"& p\": {\n wordBreak: \"break-word\",\n },\n },\n },\n // TODO: remove in v6\n /** @deprecated */\n tooltipMulti: {},\n /** @deprecated */\n title: {},\n /** @deprecated */\n valuesContainer: {},\n /** @deprecated */\n values: {},\n /** @deprecated */\n color: {},\n /** @deprecated */\n separatorColor: {},\n /** @deprecated */\n separator: {},\n /** @deprecated */\n valueWrapper: {},\n});\n"],"names":["MuitooltipClasses"],"mappings":";;;AAIO,MAAM,EAAE,eAAe,eAAe,cAAc,aAAa;AAAA,EACtE,MAAM,CAAC;AAAA,EACP,SAAS,CAAC;AAAA,EACV,QAAQ;AAAA;AAAA,IAEN,CAAC,MAAMA,eAAkB,OAAO,EAAE,GAAG;AAAA,MACnC,GAAG,MAAM,WAAW;AAAA,MACpB,SAAS;AAAA,MACT,OAAO;AAAA,MACP,UAAU;AAAA,MACV,iBAAiB,MAAM,OAAO;AAAA,MAC9B,WAAW,MAAM,OAAO;AAAA,MACxB,SAAS;AAAA,MAET,OAAO;AAAA,QACL,SAAS;AAAA,QACT,OAAO;AAAA,QACP,WAAW;AAAA,QACX,cAAc;AAAA,QACd,UAAU;AAAA,MACZ;AAAA,IACF;AAAA,IACA,YAAY;AAAA,MACV,SAAS;AAAA,MACT,cAAc,aAAa,MAAM,OAAO,KAAK;AAAA,IAC/C;AAAA,IACA,sBAAsB;AAAA,MACpB,SAAS,MAAM,MAAM;AAAA,IACvB;AAAA,IACA,aAAa;AAAA,MACX,SAAS;AAAA,MACT,gBAAgB;AAAA,MAChB,eAAe;AAAA,MACf,gBAAgB;AAAA,QACd,eAAe;AAAA,MACjB;AAAA,IACF;AAAA,IACA,YAAY;AAAA,MACV,OAAO,MAAM,MAAM;AAAA,IACrB;AAAA,IACA,gBAAgB;AAAA,MACd,OAAO,MAAM,MAAM;AAAA,IACrB;AAAA,IACA,qBAAqB;AAAA,MACnB,OAAO;AAAA,IACT;AAAA,IACA,mBAAmB;AAAA,MACjB,SAAS,MAAM,MAAM;AAAA,IACvB;AAAA,IACA,cAAc;AAAA,MACZ,SAAS,MAAM,MAAM;AAAA,MACrB,cAAc,MAAM,MAAM;AAAA,MAC1B,OAAO;AAAA,QACL,WAAW;AAAA,MACb;AAAA,IACF;AAAA,EACF;AAAA;AAAA;AAAA,EAGA,cAAc,CAAC;AAAA;AAAA,EAEf,OAAO,CAAC;AAAA;AAAA,EAER,iBAAiB,CAAC;AAAA;AAAA,EAElB,QAAQ,CAAC;AAAA;AAAA,EAET,OAAO,CAAC;AAAA;AAAA,EAER,gBAAgB,CAAC;AAAA;AAAA,EAEjB,WAAW,CAAC;AAAA;AAAA,EAEZ,cAAc,CAAC;AACjB,CAAC;"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -536,7 +536,7 @@ declare type CellValue<V = any> = V;
|
|
|
536
536
|
|
|
537
537
|
export declare const CellWithCheckBox: ({ row, labels: labelsProp }: any) => JSX_3.Element;
|
|
538
538
|
|
|
539
|
-
export declare const CellWithExpandButton: ({ row, cell, labels: labelsProp, }: any) => JSX_3.Element;
|
|
539
|
+
export declare const CellWithExpandButton: ({ row, cell, labels: labelsProp, }: HvCellProps<any>) => JSX_3.Element;
|
|
540
540
|
|
|
541
541
|
export declare const charCounterClasses: {
|
|
542
542
|
root: string;
|
|
@@ -6999,6 +6999,7 @@ export declare interface HvTooltipProps extends Omit<TooltipProps, "classes"> {
|
|
|
6999
6999
|
TransitionProps?: TooltipProps["TransitionProps"];
|
|
7000
7000
|
/**
|
|
7001
7001
|
* Defines if should use a single or multiline tooltip.
|
|
7002
|
+
* @deprecated tooltips already support multiline and can be styled accordingly.
|
|
7002
7003
|
*/
|
|
7003
7004
|
useSingle?: boolean;
|
|
7004
7005
|
/**
|
|
@@ -7695,9 +7696,6 @@ export declare const multiButtonClasses: {
|
|
|
7695
7696
|
button: string;
|
|
7696
7697
|
selected: string;
|
|
7697
7698
|
vertical: string;
|
|
7698
|
-
split: string;
|
|
7699
|
-
splitContainer: string;
|
|
7700
|
-
splitDisabled: string;
|
|
7701
7699
|
firstButton: string;
|
|
7702
7700
|
lastButton: string;
|
|
7703
7701
|
primary: string;
|
|
@@ -8274,8 +8272,8 @@ export declare const timePickerClasses: {
|
|
|
8274
8272
|
export declare const tooltipClasses: {
|
|
8275
8273
|
root: string;
|
|
8276
8274
|
tooltip: string;
|
|
8277
|
-
tooltipMulti: string;
|
|
8278
8275
|
popper: string;
|
|
8276
|
+
tooltipMulti: string;
|
|
8279
8277
|
title: string;
|
|
8280
8278
|
valuesContainer: string;
|
|
8281
8279
|
values: string;
|
|
@@ -9219,7 +9217,7 @@ declare const useClasses_31: (classesProp?: Partial<Record<"warning" | "root" |
|
|
|
9219
9217
|
readonly cx: (...args: any) => string;
|
|
9220
9218
|
};
|
|
9221
9219
|
|
|
9222
|
-
declare const useClasses_32: (classesProp?: Partial<Record<"root" | "disabled" | "semantic" | "icon" | "checked" | "
|
|
9220
|
+
declare const useClasses_32: (classesProp?: Partial<Record<"root" | "disabled" | "semantic" | "icon" | "checked" | "indeterminate" | "focusVisible", string>>, addStatic?: boolean) => {
|
|
9223
9221
|
readonly classes: {
|
|
9224
9222
|
root: string;
|
|
9225
9223
|
disabled: string;
|
|
@@ -9290,7 +9288,7 @@ declare const useClasses_36: (classesProp?: Partial<Record<"root" | "semantic" |
|
|
|
9290
9288
|
readonly cx: (...args: any) => string;
|
|
9291
9289
|
};
|
|
9292
9290
|
|
|
9293
|
-
declare const useClasses_37: (classesProp?: Partial<Record<"container" | "label" | "root" | "disabled" | "semantic" | "checkbox" | "checked" | "
|
|
9291
|
+
declare const useClasses_37: (classesProp?: Partial<Record<"container" | "label" | "root" | "disabled" | "semantic" | "checkbox" | "checked" | "indeterminate" | "focusVisible" | "invalidContainer" | "invalidCheckbox", string>>, addStatic?: boolean) => {
|
|
9294
9292
|
readonly classes: {
|
|
9295
9293
|
root: string;
|
|
9296
9294
|
container: string;
|
|
@@ -9669,7 +9667,7 @@ declare const useClasses_57: (classesProp?: Partial<Record<"root" | "sortDropdow
|
|
|
9669
9667
|
readonly cx: (...args: any) => string;
|
|
9670
9668
|
};
|
|
9671
9669
|
|
|
9672
|
-
declare const useClasses_58: (classesProp?: Partial<Record<"label" | "root" | "placeholder" | "disabled" | "readOnly" | "placeholderClosed" | "error" | "
|
|
9670
|
+
declare const useClasses_58: (classesProp?: Partial<Record<"label" | "root" | "placeholder" | "disabled" | "readOnly" | "placeholderClosed" | "error" | "description" | "arrow" | "labelContainer" | "dropdown" | "selectionDisabled" | "rootList" | "dropdownListContainer" | "dropdownHeader" | "dropdownHeaderInvalid" | "dropdownHeaderOpen", string>>, addStatic?: boolean) => {
|
|
9673
9671
|
readonly classes: {
|
|
9674
9672
|
root: string;
|
|
9675
9673
|
labelContainer: string;
|
|
@@ -9720,7 +9718,7 @@ declare const useClasses_6: (classesProp?: Partial<Record<"root" | "counterDisab
|
|
|
9720
9718
|
readonly cx: (...args: any) => string;
|
|
9721
9719
|
};
|
|
9722
9720
|
|
|
9723
|
-
declare const useClasses_60: (classesProp?: Partial<Record<"container" | "label" | "root" | "panel" | "icon" | "inputText" | "action" | "error" | "
|
|
9721
|
+
declare const useClasses_60: (classesProp?: Partial<Record<"container" | "label" | "root" | "panel" | "icon" | "inputText" | "action" | "error" | "description" | "labelContainer" | "dropdown" | "actionContainer" | "dropdownHeaderInvalid" | "dropdownHeaderOpen" | "leftContainer" | "rightContainer" | "dateText", string>>, addStatic?: boolean) => {
|
|
9724
9722
|
readonly classes: {
|
|
9725
9723
|
root: string;
|
|
9726
9724
|
actionContainer: string;
|
|
@@ -10115,7 +10113,7 @@ declare const useClasses_85: (classesProp?: Partial<Record<"link" | "root" | "it
|
|
|
10115
10113
|
readonly cx: (...args: any) => string;
|
|
10116
10114
|
};
|
|
10117
10115
|
|
|
10118
|
-
declare const useClasses_86: (classesProp?: Partial<Record<"overlay" | "label" | "small" | "root" | "hidden" | "
|
|
10116
|
+
declare const useClasses_86: (classesProp?: Partial<Record<"overlay" | "label" | "small" | "root" | "hidden" | "loadingBar" | "blur" | "regular" | "barContainer" | "smallColor" | "regularColor", string>>, addStatic?: boolean) => {
|
|
10119
10117
|
readonly classes: {
|
|
10120
10118
|
root: string;
|
|
10121
10119
|
barContainer: string;
|
|
@@ -10151,7 +10149,7 @@ declare const useClasses_88: (classesProp?: Partial<Record<"root" | "formContain
|
|
|
10151
10149
|
readonly cx: (...args: any) => string;
|
|
10152
10150
|
};
|
|
10153
10151
|
|
|
10154
|
-
declare const useClasses_89: (classesProp?: Partial<Record<"secondary" | "primary" | "vertical" | "root" | "secondarySubtle" | "selected" | "button" | "secondaryGhost" | "
|
|
10152
|
+
declare const useClasses_89: (classesProp?: Partial<Record<"secondary" | "primary" | "vertical" | "root" | "secondarySubtle" | "selected" | "button" | "secondaryGhost" | "multiple" | "primaryGhost" | "primarySubtle" | "splitGroup" | "splitGroupDisabled" | "firstButton" | "lastButton", string>>, addStatic?: boolean) => {
|
|
10155
10153
|
readonly classes: {
|
|
10156
10154
|
root: string;
|
|
10157
10155
|
multiple: string;
|
|
@@ -10160,9 +10158,6 @@ declare const useClasses_89: (classesProp?: Partial<Record<"secondary" | "primar
|
|
|
10160
10158
|
button: string;
|
|
10161
10159
|
selected: string;
|
|
10162
10160
|
vertical: string;
|
|
10163
|
-
split: string;
|
|
10164
|
-
splitContainer: string;
|
|
10165
|
-
splitDisabled: string;
|
|
10166
10161
|
firstButton: string;
|
|
10167
10162
|
lastButton: string;
|
|
10168
10163
|
primary: string;
|
|
@@ -10200,8 +10195,8 @@ declare const useClasses_91: (classesProp?: Partial<Record<"color" | "root" | "t
|
|
|
10200
10195
|
readonly classes: {
|
|
10201
10196
|
root: string;
|
|
10202
10197
|
tooltip: string;
|
|
10203
|
-
tooltipMulti: string;
|
|
10204
10198
|
popper: string;
|
|
10199
|
+
tooltipMulti: string;
|
|
10205
10200
|
title: string;
|
|
10206
10201
|
valuesContainer: string;
|
|
10207
10202
|
values: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hitachivantara/uikit-react-core",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.78.0",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": "Hitachi Vantara UI Kit Team",
|
|
6
6
|
"description": "Core React components for the NEXT Design System.",
|
|
@@ -32,10 +32,10 @@
|
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@emotion/cache": "^11.11.0",
|
|
34
34
|
"@emotion/serialize": "^1.1.2",
|
|
35
|
-
"@hitachivantara/uikit-react-icons": "^5.12.
|
|
36
|
-
"@hitachivantara/uikit-react-shared": "^5.3.
|
|
37
|
-
"@hitachivantara/uikit-react-utils": "^0.2.
|
|
38
|
-
"@hitachivantara/uikit-styles": "^5.
|
|
35
|
+
"@hitachivantara/uikit-react-icons": "^5.12.4",
|
|
36
|
+
"@hitachivantara/uikit-react-shared": "^5.3.9",
|
|
37
|
+
"@hitachivantara/uikit-react-utils": "^0.2.9",
|
|
38
|
+
"@hitachivantara/uikit-styles": "^5.36.0",
|
|
39
39
|
"@internationalized/date": "^3.2.0",
|
|
40
40
|
"@mui/base": "^5.0.0-beta.40",
|
|
41
41
|
"@popperjs/core": "^2.11.8",
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
"access": "public",
|
|
63
63
|
"directory": "package"
|
|
64
64
|
},
|
|
65
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "38ee933a412961b131a5e4a157ca195a362ea3dc",
|
|
66
66
|
"exports": {
|
|
67
67
|
".": {
|
|
68
68
|
"types": "./dist/types/index.d.ts",
|