@vention/machine-ui 5.30.3 → 5.30.5

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
@@ -4003,6 +4003,11 @@ const TYPOGRAPHY = {
4003
4003
  lineHeight: "20px"
4004
4004
  },
4005
4005
  // Code (monospace) Text
4006
+ code16Reg: {
4007
+ fontFamily: "Roboto Mono, monospace",
4008
+ fontSize: 16,
4009
+ lineHeight: "24px"
4010
+ },
4006
4011
  code14Reg: {
4007
4012
  fontFamily: "Roboto Mono, monospace",
4008
4013
  fontSize: 14,
@@ -11694,6 +11699,7 @@ const useStyles$e = tss.withParams().create(({
11694
11699
  return {
11695
11700
  root: {
11696
11701
  display: "flex",
11702
+ cursor: "pointer",
11697
11703
  visibility: isVisible ? "visible" : "hidden",
11698
11704
  alignItems: "center",
11699
11705
  transition: "transform 0.2s",
@@ -11720,7 +11726,8 @@ const defaultProps$2 = {
11720
11726
  isRenaming: false,
11721
11727
  classes: {},
11722
11728
  children: [],
11723
- collapsible: true
11729
+ collapsible: true,
11730
+ selectable: true
11724
11731
  };
11725
11732
  const VentionTreeItem = /*#__PURE__*/forwardRef((inputProps, ref) => {
11726
11733
  const theme = useTheme();
@@ -11745,7 +11752,8 @@ const VentionTreeItem = /*#__PURE__*/forwardRef((inputProps, ref) => {
11745
11752
  dataTestid,
11746
11753
  isRenaming,
11747
11754
  onRenaming,
11748
- collapsible
11755
+ collapsible,
11756
+ selectable
11749
11757
  } = applyDefaultProps(inputProps, defaultProps$2);
11750
11758
  const [isHovering, setIsHovering] = useState(false);
11751
11759
  const [label, setLabel] = useState(labelText);
@@ -11758,7 +11766,8 @@ const VentionTreeItem = /*#__PURE__*/forwardRef((inputProps, ref) => {
11758
11766
  isSelected: isSelected,
11759
11767
  isExpanded,
11760
11768
  captionsRight: captionsRight,
11761
- indentLevel: indentLevel
11769
+ indentLevel: indentLevel,
11770
+ selectable
11762
11771
  });
11763
11772
  const handleRenaming = () => {
11764
11773
  if (onRenaming) {
@@ -11907,7 +11916,8 @@ const useStyles$d = tss.withParams().withNestedSelectors().create(({
11907
11916
  theme,
11908
11917
  classes,
11909
11918
  indentLevel,
11910
- captionsRight
11919
+ captionsRight,
11920
+ selectable
11911
11921
  }) => {
11912
11922
  const getBackgroundColor = () => {
11913
11923
  if (isSelected) return theme.palette.button.shaded;
@@ -11924,7 +11934,7 @@ const useStyles$d = tss.withParams().withNestedSelectors().create(({
11924
11934
  root: {
11925
11935
  display: "flex",
11926
11936
  flexDirection: "column",
11927
- cursor: "pointer",
11937
+ cursor: selectable ? "pointer" : "default",
11928
11938
  backgroundColor: theme.palette.background.default,
11929
11939
  width: "100%"
11930
11940
  },
@@ -11945,7 +11955,7 @@ const useStyles$d = tss.withParams().withNestedSelectors().create(({
11945
11955
  visibility: "visible"
11946
11956
  },
11947
11957
  [`&:hover`]: {
11948
- border: isSelected ? invisibleBorder : `1px solid ${theme.palette.border.blueSelected}`
11958
+ border: !selectable || isSelected ? invisibleBorder : `1px solid ${theme.palette.border.blueSelected}`
11949
11959
  },
11950
11960
  overflow: "hidden",
11951
11961
  gap: theme.spacing(2),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vention/machine-ui",
3
- "version": "5.30.3",
3
+ "version": "5.30.5",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/VentionCo/machine-cloud.git"
@@ -38,6 +38,8 @@ interface VentionTreeItemProps {
38
38
  dataTestid?: string | undefined;
39
39
  isExpanded?: boolean | undefined;
40
40
  collapsible?: boolean | undefined;
41
+ /** When false, a row does not select and shows no hover highlight. The caret still works. Defaults to true. */
42
+ selectable?: boolean | undefined;
41
43
  }
42
44
  export declare const VentionTreeItem: ForwardRefExoticComponent<VentionTreeItemProps & RefAttributes<HTMLDivElement>>;
43
45
  declare const useStyles: import("tss-react").Tss.UseStyles<{
@@ -48,5 +50,6 @@ declare const useStyles: import("tss-react").Tss.UseStyles<{
48
50
  isExpanded: boolean;
49
51
  captionsRight: VentionTreeItemProps["captionsRight"];
50
52
  indentLevel: number;
53
+ selectable: boolean;
51
54
  }, "label" | "root" | "iconContainer" | "labelContainer" | "actionButton" | "trailingElement" | "trailingElementShowOnHover" | "mainContent" | "singleLineContainer" | "captionRightContainer" | "captionRight" | "captionRightLabel" | "clickableCaptionRight" | "actionButtonsContainer" | "showOnHover" | "childrenItems" | "alertIcon", import("tss-react/mui").MuiThemeStyleOverridesPluginParams>;
52
55
  export {};
@@ -22,6 +22,7 @@ declare module "@mui/material/styles" {
22
22
  paragraph16Medium: React.CSSProperties;
23
23
  paragraph16Regular: React.CSSProperties;
24
24
  paragraph14Regular: React.CSSProperties;
25
+ code16Reg: React.CSSProperties;
25
26
  code14Reg: React.CSSProperties;
26
27
  code12Reg: React.CSSProperties;
27
28
  uiText14SemiBold: React.CSSProperties;
@@ -225,6 +226,7 @@ declare module "@mui/material/Typography" {
225
226
  paragraph16Medium: true;
226
227
  paragraph16Regular: true;
227
228
  paragraph14Regular: true;
229
+ code16Reg: true;
228
230
  code14Reg: true;
229
231
  code12Reg: true;
230
232
  uiText18SemiBold: true;
@@ -69,6 +69,11 @@ export declare const TYPOGRAPHY: {
69
69
  fontWeight: number;
70
70
  lineHeight: string;
71
71
  };
72
+ code16Reg: {
73
+ fontFamily: string;
74
+ fontSize: number;
75
+ lineHeight: string;
76
+ };
72
77
  code14Reg: {
73
78
  fontFamily: string;
74
79
  fontSize: number;