@vention/machine-ui 3.39.0 → 3.41.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/README.md CHANGED
@@ -4,7 +4,7 @@ Machine UI is Vention's component library for building applications and Human-Ma
4
4
 
5
5
  ## 📚 Documentation
6
6
 
7
- Complete documentation, including component examples, design system guidelines, and usage instructions, can be found at:
7
+ Complete documentation, including component examples, design system guidelines, and usage instructions can be found at:
8
8
 
9
9
  **[https://assets.vention.com/machine-ui-storybook/](https://assets.vention.com/machine-ui-storybook/index.html?path=/docs/guides-introduction--documentation)**
10
10
 
package/index.esm.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
2
- import { Typography, Button, Stack, Box as Box$1, Grid, IconButton, ClickAwayListener, Modal, linearProgressClasses, LinearProgress, InputAdornment, TextField, Radio, FormControlLabel, FormControl, Select, MenuItem, FormHelperText, ButtonGroup, Paper, Card, CardMedia, CardContent, ListItemIcon, ListItemText, Popover, MenuList, useTheme as useTheme$1, Drawer, Tooltip, Checkbox } from '@mui/material';
2
+ import { Typography, Button, Stack, Box as Box$1, Grid, IconButton, ClickAwayListener, Modal, CircularProgress as CircularProgress$1, linearProgressClasses, LinearProgress, InputAdornment, TextField, Radio, FormControlLabel, FormControl, Select, MenuItem, FormHelperText, ButtonGroup, Paper, Card, CardMedia, CardContent, ListItemIcon, ListItemText, Popover, MenuList, useTheme as useTheme$1, Drawer, Tooltip, Checkbox } from '@mui/material';
3
3
  import { IconCheck, IconAlertTriangleFilled, IconAlertTriangle, IconExclamationMark, IconExternalLink, IconX, IconInfoCircleFilled, IconCircleCheckFilled, IconChevronUp, IconChevronDown, IconInfoCircle, IconInfoSmall, IconMinus, IconPlus, IconLoader2, IconCaretRightFilled, IconChevronsRight, IconChevronsLeft, IconChevronRight } from '@tabler/icons-react';
4
4
  import { forwardRef, useState, cloneElement, useRef, useEffect, useCallback, lazy, memo, Suspense, useMemo, createContext, useContext, useImperativeHandle, Children, Fragment as Fragment$1, useReducer } from 'react';
5
5
  import { tss } from 'tss-react/mui';
@@ -4178,7 +4178,9 @@ const VentionModal = props => {
4178
4178
  "data-testid": ventionModalTestIds.positiveIcon
4179
4179
  })), props.type === "info" && jsx(IconInfoSmall, Object.assign({}, iconProps, {
4180
4180
  "data-testid": ventionModalTestIds.infoIcon
4181
- })), props.type === "warning" && jsx(IconAlertTriangle, Object.assign({}, iconProps, {
4181
+ })), props.type === "loading" && jsx(CircularProgress$1, {
4182
+ "data-testid": ventionModalTestIds.loadingIcon
4183
+ }), props.type === "warning" && jsx(IconAlertTriangle, Object.assign({}, iconProps, {
4182
4184
  "data-testid": ventionModalTestIds.warningIcon
4183
4185
  })), props.type === "negative" && jsx(IconAlertTriangle, Object.assign({}, iconProps, {
4184
4186
  "data-testid": ventionModalTestIds.negativeIcon
@@ -4253,7 +4255,7 @@ const useStyles$w = tss.withParams().create(({
4253
4255
  statusCircle: {
4254
4256
  width: status.containerSize,
4255
4257
  height: status.containerSize,
4256
- display: "flex",
4258
+ display: type === "loading" ? "block" : "flex",
4257
4259
  justifyContent: "center",
4258
4260
  alignItems: "center",
4259
4261
  borderRadius: "50%",
@@ -4283,8 +4285,8 @@ const ALIGN_ITEMS = {
4283
4285
  left: "flex-start",
4284
4286
  center: "center"
4285
4287
  };
4286
- const getColors$2 = (type, theme) => {
4287
- switch (type) {
4288
+ const getColors$2 = (modelType, theme) => {
4289
+ switch (modelType) {
4288
4290
  case "positive":
4289
4291
  return {
4290
4292
  statusContainerColor: theme.palette.background.success,
@@ -4305,6 +4307,7 @@ const getColors$2 = (type, theme) => {
4305
4307
  statusContainerColor: theme.palette.background.destructive,
4306
4308
  statusGlowColor: theme.palette.background.subtleDestructive
4307
4309
  };
4310
+ case "loading":
4308
4311
  case "none":
4309
4312
  return {
4310
4313
  statusContainerColor: "transparent",
@@ -4341,6 +4344,7 @@ const getBodyTextTypography = (modalSize, isTouchDevice) => {
4341
4344
  const ventionModalTestIds = {
4342
4345
  positiveIcon: "vention-modal-positive-icon",
4343
4346
  infoIcon: "vention-modal-info-icon",
4347
+ loadingIcon: "vention-modal-loading-icon",
4344
4348
  warningIcon: "vention-modal-warning-icon",
4345
4349
  negativeIcon: "vention-modal-negative-icon",
4346
4350
  modalActions: "vention-modal-actions"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vention/machine-ui",
3
- "version": "3.39.0",
3
+ "version": "3.41.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/VentionCo/machine-cloud.git"
@@ -8,7 +8,7 @@ export interface VentionModalProps {
8
8
  * This can be a simple string or your own React Component.
9
9
  */
10
10
  body: string | React.ReactElement;
11
- type: "positive" | "info" | "warning" | "negative" | "none";
11
+ type: "positive" | "info" | "warning" | "negative" | "loading" | "none";
12
12
  modalSize?: VentionModalBaseProps["modalSize"];
13
13
  isTouchDevice?: boolean;
14
14
  isOpen: VentionModalBaseProps["isOpen"];
@@ -46,6 +46,7 @@ export declare const VentionModal: (props: VentionModalProps) => import("react/j
46
46
  export declare const ventionModalTestIds: {
47
47
  positiveIcon: string;
48
48
  infoIcon: string;
49
+ loadingIcon: string;
49
50
  warningIcon: string;
50
51
  negativeIcon: string;
51
52
  modalActions: string;