@vention/machine-ui 6.3.1 → 6.4.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/index.esm.js
CHANGED
|
@@ -11922,18 +11922,18 @@ const VentionTreeItem = /*#__PURE__*/forwardRef((inputProps, ref) => {
|
|
|
11922
11922
|
className: classes.captionsContainer,
|
|
11923
11923
|
"data-testid": `${testId}-captions`,
|
|
11924
11924
|
children: captions.map((caption, index) => {
|
|
11925
|
-
var _a, _b;
|
|
11925
|
+
var _a, _b, _c;
|
|
11926
11926
|
return jsx(VentionBadge, {
|
|
11927
|
-
variant: "filled",
|
|
11927
|
+
variant: (_a = caption.variant) !== null && _a !== void 0 ? _a : "filled",
|
|
11928
11928
|
size: size === "xx-large" ? "medium" : "small",
|
|
11929
|
-
color: (
|
|
11929
|
+
color: (_b = caption.color) !== null && _b !== void 0 ? _b : "slate",
|
|
11930
11930
|
className: classes.caption,
|
|
11931
11931
|
text: caption.text,
|
|
11932
11932
|
onClick: caption.onClick ? event => {
|
|
11933
11933
|
event.stopPropagation();
|
|
11934
11934
|
caption.onClick(event);
|
|
11935
11935
|
} : undefined,
|
|
11936
|
-
"data-testid": `${testId}-${(
|
|
11936
|
+
"data-testid": `${testId}-${(_c = caption.testId) !== null && _c !== void 0 ? _c : `caption-${index}`}`
|
|
11937
11937
|
}, index);
|
|
11938
11938
|
})
|
|
11939
11939
|
});
|
|
@@ -12139,11 +12139,15 @@ const useStyles$d = tss.withParams().withNestedSelectors().create(({
|
|
|
12139
12139
|
display: "flex",
|
|
12140
12140
|
overflow: "hidden"
|
|
12141
12141
|
},
|
|
12142
|
-
caption: {
|
|
12142
|
+
caption: Object.assign({
|
|
12143
12143
|
overflow: "hidden",
|
|
12144
12144
|
textOverflow: "ellipsis",
|
|
12145
12145
|
maxWidth: "100%"
|
|
12146
|
-
},
|
|
12146
|
+
}, size === "medium" && {
|
|
12147
|
+
"& .MuiTypography-root": {
|
|
12148
|
+
fontSize: "10px"
|
|
12149
|
+
}
|
|
12150
|
+
}),
|
|
12147
12151
|
actionButtonsContainer: {
|
|
12148
12152
|
gap: theme.spacing(1),
|
|
12149
12153
|
display: "flex",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ReactElement, MouseEvent, ForwardRefExoticComponent, RefAttributes } from "react";
|
|
2
2
|
import { DEFAULT_VENTION_TREE_ITEM_HEIGHT } from "./vention-collapsible-caret-button";
|
|
3
|
-
import { VentionBadgeColors } from "../vention-badge/vention-badge";
|
|
3
|
+
import { VentionBadgeColors, VentionBadgeVariants } from "../vention-badge/vention-badge";
|
|
4
4
|
import { Sizes, StrictExtract } from "../../theme/machine-ui-theme";
|
|
5
5
|
export { DEFAULT_VENTION_TREE_ITEM_HEIGHT };
|
|
6
6
|
export interface TrailingElementItem {
|
|
@@ -10,6 +10,7 @@ export interface TrailingElementItem {
|
|
|
10
10
|
export interface VentionTreeItemCaption {
|
|
11
11
|
text: string;
|
|
12
12
|
color?: VentionBadgeColors | undefined;
|
|
13
|
+
variant?: VentionBadgeVariants | undefined;
|
|
13
14
|
testId?: string | undefined;
|
|
14
15
|
onClick?: (e: MouseEvent) => void;
|
|
15
16
|
}
|