@digital-ai/dot-components 3.10.1 → 3.11.1

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
@@ -104,12 +104,12 @@ const DotTooltip = ({
104
104
  }) : children;
105
105
  };
106
106
 
107
- const rootClassName$1g = 'dot-icon';
107
+ const rootClassName$1i = 'dot-icon';
108
108
  const StyledIcon = styled(Icon)`
109
109
  ${({
110
110
  theme
111
111
  }) => css`
112
- &.${rootClassName$1g} {
112
+ &.${rootClassName$1i} {
113
113
  color: ${theme.palette.figma.icon.black};
114
114
  font-size: 20px;
115
115
 
@@ -146,7 +146,7 @@ const DotIcon = ({
146
146
  iconId,
147
147
  tooltip
148
148
  }) => {
149
- const rootClasses = useStylesWithRootClass(rootClassName$1g, className);
149
+ const rootClasses = useStylesWithRootClass(rootClassName$1i, className);
150
150
  return jsx(DotTooltip, {
151
151
  title: tooltip,
152
152
  children: jsx(StyledIcon, {
@@ -207,7 +207,7 @@ const DotTypography = ({
207
207
  });
208
208
  };
209
209
 
210
- const rootClassName$1f = 'dot-accordion';
210
+ const rootClassName$1h = 'dot-accordion';
211
211
  const summaryClassName = 'dot-accordion-summary';
212
212
  const detailClassName = 'dot-accordion-details';
213
213
  const StyledAccordion = styled(Accordion)`
@@ -218,7 +218,7 @@ const StyledAccordion = styled(Accordion)`
218
218
  background: ${theme.palette.figma.background.level1.white};
219
219
  }
220
220
 
221
- &.${rootClassName$1f} .${summaryClassName} {
221
+ &.${rootClassName$1h} .${summaryClassName} {
222
222
  align-items: center;
223
223
  background: ${theme.palette.figma.background.level1.white};
224
224
  color: ${theme.palette.figma.typography.black};
@@ -263,7 +263,7 @@ const DotAccordion = ({
263
263
  ariaLabel,
264
264
  children,
265
265
  className,
266
- 'data-pendoid': dataPendoId = rootClassName$1f,
266
+ 'data-pendoid': dataPendoId = rootClassName$1h,
267
267
  'data-testid': dataTestId = 'dot-accordion',
268
268
  disabled = false,
269
269
  expanded,
@@ -274,7 +274,7 @@ const DotAccordion = ({
274
274
  summary,
275
275
  noWrap = true
276
276
  }) => {
277
- const rootClasses = useStylesWithRootClass(rootClassName$1f, className);
277
+ const rootClasses = useStylesWithRootClass(rootClassName$1h, className);
278
278
  const [elevation, setElevation] = useState();
279
279
  useEffect(() => {
280
280
  if (onChange && expanded === undefined) {
@@ -390,7 +390,7 @@ const readOnlyStyles = theme => css`
390
390
  }
391
391
  `;
392
392
 
393
- const rootClassName$1e = 'dot-text-field';
393
+ const rootClassName$1g = 'dot-text-field';
394
394
  const rootSelectClassName = 'dot-select-field';
395
395
  const labelClassName = 'dot-input-label';
396
396
  const errorClassName = 'dot-error';
@@ -438,7 +438,7 @@ const StyledTextField = styled(TextField)`
438
438
  theme,
439
439
  InputProps
440
440
  }) => css`
441
- &.${rootClassName$1e} {
441
+ &.${rootClassName$1g} {
442
442
  .MuiInputBase-root {
443
443
  margin-bottom: 0;
444
444
  }
@@ -482,7 +482,7 @@ const StyledTextField = styled(TextField)`
482
482
  margin-right: ${theme.spacing(2)};
483
483
  }
484
484
 
485
- &.${rootSelectClassName}, &.${rootClassName$1e} {
485
+ &.${rootSelectClassName}, &.${rootClassName$1g} {
486
486
  .${adornmentIconClassName} {
487
487
  color: ${theme.palette.figma.icon.black};
488
488
  p {
@@ -573,15 +573,15 @@ const StyledTextField = styled(TextField)`
573
573
  `}
574
574
  `;
575
575
 
576
- const rootClassName$1d = 'dot-action-toolbar';
576
+ const rootClassName$1f = 'dot-action-toolbar';
577
577
  const StyledToolbar = styled(Toolbar)`
578
578
  ${({
579
579
  theme
580
580
  }) => css`
581
- &.${rootClassName$1d} {
581
+ &.${rootClassName$1f} {
582
582
  border-bottom: 1px solid ${theme.palette.figma.border.default};
583
583
 
584
- .${rootClassName$1e} .MuiInputBase-root {
584
+ .${rootClassName$1g} .MuiInputBase-root {
585
585
  margin-bottom: 0;
586
586
  }
587
587
  }
@@ -595,7 +595,7 @@ const DotActionToolbar = ({
595
595
  'data-testid': dataTestId,
596
596
  variant = 'dense'
597
597
  }) => {
598
- const rootClasses = useStylesWithRootClass(rootClassName$1d, className);
598
+ const rootClasses = useStylesWithRootClass(rootClassName$1f, className);
599
599
  return jsx(StyledToolbar, {
600
600
  "aria-label": ariaLabel,
601
601
  className: rootClasses,
@@ -1665,12 +1665,12 @@ const renderNodeOrTypography = (content, typographyVariant = 'body1') => {
1665
1665
  const checkIfArrowUpPressed = event => event.key === 'ArrowUp';
1666
1666
  const checkIfArrowDownPressed = event => event.key === 'ArrowDown';
1667
1667
 
1668
- const rootClassName$1c = 'dot-alert-banner';
1668
+ const rootClassName$1e = 'dot-alert-banner';
1669
1669
  const StyledAlertBanner = styled(Alert)`
1670
1670
  ${({
1671
1671
  theme
1672
1672
  }) => css`
1673
- &.${rootClassName$1c} {
1673
+ &.${rootClassName$1e} {
1674
1674
  align-items: center;
1675
1675
  box-sizing: border-box;
1676
1676
  min-height: 48px;
@@ -1705,7 +1705,7 @@ const DotAlertBanner = ({
1705
1705
  ariaLabel,
1706
1706
  children,
1707
1707
  className,
1708
- 'data-pendoid': dataPendoId = rootClassName$1c,
1708
+ 'data-pendoid': dataPendoId = rootClassName$1e,
1709
1709
  'data-testid': dataTestId,
1710
1710
  onClose,
1711
1711
  roundedCorners = true,
@@ -1713,7 +1713,7 @@ const DotAlertBanner = ({
1713
1713
  textVariant = 'body1',
1714
1714
  width
1715
1715
  }) => {
1716
- const rootClasses = useStylesWithRootClass(rootClassName$1c, severity, className);
1716
+ const rootClasses = useStylesWithRootClass(rootClassName$1e, severity, className);
1717
1717
  /* For simple string use default component, for everything else use 'div' */
1718
1718
  const typographyComponent = isString$2(children) ? undefined : 'div';
1719
1719
  return jsx(StyledAlertBanner, {
@@ -2391,7 +2391,7 @@ const useDotCoreApiContext = () => {
2391
2391
  return useContext(DotCoreApiContext);
2392
2392
  };
2393
2393
 
2394
- const rootClassName$1b = 'dot-avatar';
2394
+ const rootClassName$1d = 'dot-avatar';
2395
2395
  const avatarSpacing = {
2396
2396
  small: 3,
2397
2397
  medium: 5,
@@ -2401,7 +2401,7 @@ const StyledAvatar = styled(Avatar)`
2401
2401
  ${({
2402
2402
  theme
2403
2403
  }) => css`
2404
- &.${rootClassName$1b} {
2404
+ &.${rootClassName$1d} {
2405
2405
  display: inline-flex;
2406
2406
  background-color: ${({
2407
2407
  color
@@ -2513,7 +2513,7 @@ const DotAvatar = ({
2513
2513
  variant = 'circular',
2514
2514
  style
2515
2515
  }) => {
2516
- const rootClasses = useStylesWithRootClass(rootClassName$1b, className);
2516
+ const rootClasses = useStylesWithRootClass(rootClassName$1d, className);
2517
2517
  const getAvatarColor = () => {
2518
2518
  if ((style === null || style === void 0 ? void 0 : style.color) !== undefined) return 'inherit';
2519
2519
  if (color) return color;
@@ -2552,12 +2552,12 @@ const DotAvatar = ({
2552
2552
  });
2553
2553
  };
2554
2554
 
2555
- const rootClassName$1a = 'dot-button';
2555
+ const rootClassName$1c = 'dot-button';
2556
2556
  const StyledButton = styled(Button)`
2557
2557
  ${({
2558
2558
  theme
2559
2559
  }) => css`
2560
- &.${rootClassName$1a} {
2560
+ &.${rootClassName$1c} {
2561
2561
  background-color: ${theme.palette.figma.primary.normal};
2562
2562
  margin: ${theme.spacing(0.5)};
2563
2563
  padding: ${theme.spacing(0.75, 2)};
@@ -2641,7 +2641,7 @@ const DotButton = forwardRef(({
2641
2641
  autoFocus = false,
2642
2642
  children,
2643
2643
  className,
2644
- 'data-pendoid': dataPendoId = rootClassName$1a,
2644
+ 'data-pendoid': dataPendoId = rootClassName$1c,
2645
2645
  'data-testid': dataTestId,
2646
2646
  disabled = false,
2647
2647
  disableRipple = false,
@@ -2657,7 +2657,7 @@ const DotButton = forwardRef(({
2657
2657
  tooltipPlacement,
2658
2658
  type = 'primary'
2659
2659
  }, ref) => {
2660
- const rootClasses = useStylesWithRootClass(rootClassName$1a, className);
2660
+ const rootClasses = useStylesWithRootClass(rootClassName$1c, className);
2661
2661
  let color;
2662
2662
  let variant;
2663
2663
  switch (type) {
@@ -2681,7 +2681,7 @@ const DotButton = forwardRef(({
2681
2681
  return jsx(DotTooltip, {
2682
2682
  placement: tooltipPlacement,
2683
2683
  title: tooltip,
2684
- "data-testid": `${dataTestId || rootClassName$1a}-tooltip`,
2684
+ "data-testid": `${dataTestId || rootClassName$1c}-tooltip`,
2685
2685
  children: jsx(StyledButton, {
2686
2686
  "aria-label": ariaLabel,
2687
2687
  autoFocus: autoFocus,
@@ -2690,7 +2690,7 @@ const DotButton = forwardRef(({
2690
2690
  },
2691
2691
  color: color,
2692
2692
  "data-pendoid": dataPendoId,
2693
- "data-testid": dataTestId || rootClassName$1a,
2693
+ "data-testid": dataTestId || rootClassName$1c,
2694
2694
  disableRipple: disableRipple,
2695
2695
  disabled: disabled,
2696
2696
  endIcon: endIcon,
@@ -2709,10 +2709,10 @@ const DotButton = forwardRef(({
2709
2709
  });
2710
2710
  });
2711
2711
 
2712
- const rootClassName$19 = 'dot-link';
2712
+ const rootClassName$1b = 'dot-link';
2713
2713
  const StyledLink = styled(Link)`
2714
2714
  ${() => css`
2715
- &.${rootClassName$19} {
2715
+ &.${rootClassName$1b} {
2716
2716
  cursor: pointer;
2717
2717
 
2718
2718
  &:hover.MuiLink-underlineHover {
@@ -2728,7 +2728,7 @@ const DotLink = ({
2728
2728
  children,
2729
2729
  className,
2730
2730
  color = 'primary',
2731
- 'data-pendoid': dataPendoId = rootClassName$19,
2731
+ 'data-pendoid': dataPendoId = rootClassName$1b,
2732
2732
  'data-testid': dataTestId,
2733
2733
  href,
2734
2734
  onClick,
@@ -2740,7 +2740,7 @@ const DotLink = ({
2740
2740
  tooltip,
2741
2741
  underline = 'always'
2742
2742
  }) => {
2743
- const rootClasses = useStylesWithRootClass(rootClassName$19, className);
2743
+ const rootClasses = useStylesWithRootClass(rootClassName$1b, className);
2744
2744
  useEffect(() => {
2745
2745
  // Include a console warning if the link is not a string and no ariaLabel is provided
2746
2746
  if (!isString$2(children) && !ariaLabel) {
@@ -2790,7 +2790,7 @@ const CreateUUID = () => {
2790
2790
  });
2791
2791
  };
2792
2792
 
2793
- const rootClassName$18 = 'dot-list';
2793
+ const rootClassName$1a = 'dot-list';
2794
2794
  const listItemRootClass = 'dot-list-item';
2795
2795
  const nestedListClassName = 'dot-nested-list';
2796
2796
  const nestedDrawerClassName = 'dot-nested-drawer';
@@ -2798,7 +2798,7 @@ const StyledList = styled(List)`
2798
2798
  ${({
2799
2799
  theme
2800
2800
  }) => css`
2801
- &.${rootClassName$18} {
2801
+ &.${rootClassName$1a} {
2802
2802
  background: ${theme.palette.figma.background.level0.componentsBackground};
2803
2803
 
2804
2804
  .dot-icon {
@@ -2881,12 +2881,12 @@ const DotListDivider = ({
2881
2881
  });
2882
2882
  };
2883
2883
 
2884
- const rootClassName$17 = 'dot-progress';
2884
+ const rootClassName$19 = 'dot-progress';
2885
2885
  const StyledProgress = styled.div`
2886
2886
  ${({
2887
2887
  theme
2888
2888
  }) => css`
2889
- &.${rootClassName$17} {
2889
+ &.${rootClassName$19} {
2890
2890
  line-height: 0;
2891
2891
 
2892
2892
  .dot-progress-with-label-wrapper {
@@ -2937,7 +2937,7 @@ const DotProgress = ({
2937
2937
  value,
2938
2938
  variant = 'indeterminate'
2939
2939
  }) => {
2940
- const rootClasses = useStylesWithRootClass(rootClassName$17, className);
2940
+ const rootClasses = useStylesWithRootClass(rootClassName$19, className);
2941
2941
  useEffect(() => {
2942
2942
  if (!ariaLabel) {
2943
2943
  console.warn('a11y: DotProgress must have an ariaLabel to describe the progress component');
@@ -3003,34 +3003,34 @@ var variables = /*#__PURE__*/Object.freeze({
3003
3003
  levelTop: levelTop
3004
3004
  });
3005
3005
 
3006
- const rootClassName$16 = 'dot-popper';
3006
+ const rootClassName$18 = 'dot-popper';
3007
3007
  const StyledPopper$1 = styled(Popper)`
3008
3008
  ${({
3009
3009
  theme
3010
3010
  }) => css`
3011
- &.${rootClassName$16} {
3011
+ &.${rootClassName$18} {
3012
3012
  font-family: ${theme.typography.fontFamily};
3013
3013
  font-size: ${theme.typography.body1.fontSize}px;
3014
3014
  }
3015
3015
 
3016
- &.${rootClassName$16}, &.${rootClassName$16} > .dot-popper-paper {
3016
+ &.${rootClassName$18}, &.${rootClassName$18} > .dot-popper-paper {
3017
3017
  background-color: ${theme.palette.figma.background.level1.white};
3018
3018
  }
3019
3019
  `}
3020
3020
  `;
3021
3021
 
3022
3022
  const flyoutMenuClassName = 'dot-flyout-menu';
3023
- const rootClassName$15 = 'dot-menu';
3023
+ const rootClassName$17 = 'dot-menu';
3024
3024
  const StyledPopper = styled(Popper)`
3025
3025
  ${({
3026
3026
  theme
3027
3027
  }) => css`
3028
- &.${rootClassName$16} {
3028
+ &.${rootClassName$18} {
3029
3029
  font-family: ${theme.typography.fontFamily};
3030
3030
  font-size: ${theme.typography.body1.fontSize}px;
3031
3031
  z-index: ${levelSecond};
3032
3032
  }
3033
- &.${rootClassName$15}, &.${rootClassName$16} {
3033
+ &.${rootClassName$17}, &.${rootClassName$18} {
3034
3034
  .MuiPaper-root {
3035
3035
  border: 1px solid ${theme.palette.layer.n100};
3036
3036
  }
@@ -3110,14 +3110,14 @@ const MENU_ITEM_HEIGHT_NORMAL = 48;
3110
3110
  const MENU_ITEM_HEIGHT_DENSE = 36;
3111
3111
  const DEFAULT_MAX_VISIBLE_ITEMS = 7;
3112
3112
 
3113
- const rootClassName$14 = 'dot-ul';
3113
+ const rootClassName$16 = 'dot-ul';
3114
3114
  const listItemClassName$1 = 'dot-li';
3115
3115
  const listItemWithSubmenuClassName = 'dot-li-with-submenu';
3116
3116
  const StyledMenuList = styled(MenuList)`
3117
3117
  ${({
3118
3118
  theme
3119
3119
  }) => css`
3120
- &.${rootClassName$14} {
3120
+ &.${rootClassName$16} {
3121
3121
  background: ${theme.palette.figma.background.level1.white};
3122
3122
 
3123
3123
  .dot-li {
@@ -3213,7 +3213,7 @@ const DotMenuList = forwardRef(({
3213
3213
  onSubMenuCreate,
3214
3214
  selectedKey
3215
3215
  }, ref) => {
3216
- const rootClasses = useStylesWithRootClass(rootClassName$14, className);
3216
+ const rootClasses = useStylesWithRootClass(rootClassName$16, className);
3217
3217
  const [activeSubmenu, setActiveSubmenu] = useState(null);
3218
3218
  const [subItemAnchorEl, setSubItemAnchorEl] = useState(null);
3219
3219
  const openSubmenu = (target, itemKey) => {
@@ -3324,7 +3324,7 @@ const DotMenu = ({
3324
3324
  open = false,
3325
3325
  selectedKey
3326
3326
  }) => {
3327
- const rootClasses = useStylesWithRootClass(rootClassName$15, className, loading ? 'loading' : '');
3327
+ const rootClasses = useStylesWithRootClass(rootClassName$17, className, loading ? 'loading' : '');
3328
3328
  const isSubmenu = checkIfSubmenu(anchorEl);
3329
3329
  const hasSubItems = checkForSubItems(menuItems);
3330
3330
  // Timeout object is customizable when Menu component is either submenu
@@ -3412,12 +3412,12 @@ const DotMenu = ({
3412
3412
  });
3413
3413
  };
3414
3414
 
3415
- const rootClassName$13 = 'dot-drawer';
3415
+ const rootClassName$15 = 'dot-drawer';
3416
3416
  const StyledDrawer = styled(Drawer)`
3417
3417
  ${({
3418
3418
  theme
3419
3419
  }) => css`
3420
- &.${rootClassName$13} .MuiBackdrop-root {
3420
+ &.${rootClassName$15} .MuiBackdrop-root {
3421
3421
  background-color: ${theme.palette.figma.overlay.default};
3422
3422
  }
3423
3423
 
@@ -3436,12 +3436,12 @@ const StyledDrawer = styled(Drawer)`
3436
3436
  `}
3437
3437
  `;
3438
3438
 
3439
- const rootClassName$12 = 'dot-drawer-header';
3439
+ const rootClassName$14 = 'dot-drawer-header';
3440
3440
  const StyleDrawerHeader = styled.div`
3441
3441
  ${({
3442
3442
  theme
3443
3443
  }) => css`
3444
- &.${rootClassName$12} {
3444
+ &.${rootClassName$14} {
3445
3445
  padding: ${theme.spacing(0, 0, 2)};
3446
3446
  display: flex;
3447
3447
  align-items: center;
@@ -3452,13 +3452,13 @@ const StyleDrawerHeader = styled.div`
3452
3452
  `}
3453
3453
  `;
3454
3454
 
3455
- const rootClassName$11 = 'dot-icon-btn';
3455
+ const rootClassName$13 = 'dot-icon-btn';
3456
3456
  const StyledIconButton = styled(IconButton)`
3457
3457
  ${({
3458
3458
  theme,
3459
3459
  color
3460
3460
  }) => css`
3461
- &.${rootClassName$11} {
3461
+ &.${rootClassName$13} {
3462
3462
  ${color === 'inherit' ? css`
3463
3463
  color: inherit;
3464
3464
  ` : ''}
@@ -3517,7 +3517,7 @@ const DotIconButton = ({
3517
3517
  ariaRole = 'button',
3518
3518
  className,
3519
3519
  color = 'inherit',
3520
- 'data-pendoid': dataPendoId = rootClassName$11,
3520
+ 'data-pendoid': dataPendoId = rootClassName$13,
3521
3521
  'data-testid': dataTestId,
3522
3522
  disableRipple = false,
3523
3523
  disabled = false,
@@ -3530,7 +3530,7 @@ const DotIconButton = ({
3530
3530
  tooltipPlacement
3531
3531
  }) => {
3532
3532
  const rippleClassName = disableRipple ? 'ripple-disabled' : '';
3533
- const rootClasses = useStylesWithRootClass(rootClassName$11, rippleClassName, `shape-${shape}`, className);
3533
+ const rootClasses = useStylesWithRootClass(rootClassName$13, rippleClassName, `shape-${shape}`, className);
3534
3534
  return jsx(DotTooltip, {
3535
3535
  "data-testid": "icon-button-tooltip",
3536
3536
  placement: tooltipPlacement,
@@ -3565,7 +3565,7 @@ const DotDrawerHeader = ({
3565
3565
  onClose,
3566
3566
  variant
3567
3567
  }) => {
3568
- const rootClasses = useStylesWithRootClass(rootClassName$12, className);
3568
+ const rootClasses = useStylesWithRootClass(rootClassName$14, className);
3569
3569
  return jsxs(StyleDrawerHeader, {
3570
3570
  "aria-label": ariaLabel,
3571
3571
  "aria-level": 2,
@@ -3582,10 +3582,10 @@ const DotDrawerHeader = ({
3582
3582
  });
3583
3583
  };
3584
3584
 
3585
- const rootClassName$10 = 'dot-drawer-body';
3585
+ const rootClassName$12 = 'dot-drawer-body';
3586
3586
  const StyleDrawerBody = styled.div`
3587
3587
  ${() => css`
3588
- &.${rootClassName$10} {
3588
+ &.${rootClassName$12} {
3589
3589
  display: flex;
3590
3590
  .dot-drawer-close-button {
3591
3591
  align-self: self-start;
@@ -3606,7 +3606,7 @@ const DotDrawerBody = ({
3606
3606
  onClose,
3607
3607
  variant
3608
3608
  }) => {
3609
- const rootClasses = useStylesWithRootClass(rootClassName$10, className);
3609
+ const rootClasses = useStylesWithRootClass(rootClassName$12, className);
3610
3610
  return jsxs(StyleDrawerBody, {
3611
3611
  "aria-label": ariaLabel,
3612
3612
  className: rootClasses,
@@ -3621,12 +3621,12 @@ const DotDrawerBody = ({
3621
3621
  });
3622
3622
  };
3623
3623
 
3624
- const rootClassName$$ = 'dot-drawer-footer';
3624
+ const rootClassName$11 = 'dot-drawer-footer';
3625
3625
  const StyleDrawerFooter = styled.div`
3626
3626
  ${({
3627
3627
  theme
3628
3628
  }) => css`
3629
- &.${rootClassName$$} {
3629
+ &.${rootClassName$11} {
3630
3630
  padding: ${theme.spacing(2, 0, 0)};
3631
3631
  }
3632
3632
  `}
@@ -3639,7 +3639,7 @@ const DotDrawerFooter = ({
3639
3639
  className,
3640
3640
  'data-testid': dataTestId
3641
3641
  }) => {
3642
- const rootClasses = useStylesWithRootClass(rootClassName$$, className);
3642
+ const rootClasses = useStylesWithRootClass(rootClassName$11, className);
3643
3643
  return jsx(StyleDrawerFooter, {
3644
3644
  "aria-label": ariaLabel,
3645
3645
  className: rootClasses,
@@ -3655,7 +3655,7 @@ const DotDrawer = ({
3655
3655
  ariaRole = 'dialog',
3656
3656
  className,
3657
3657
  children,
3658
- 'data-pendoid': dataPendoId = rootClassName$13,
3658
+ 'data-pendoid': dataPendoId = rootClassName$15,
3659
3659
  'data-testid': dataTestId,
3660
3660
  drawerBodyProps,
3661
3661
  drawerFooterProps,
@@ -3678,7 +3678,7 @@ const DotDrawer = ({
3678
3678
  onClose(event);
3679
3679
  }
3680
3680
  };
3681
- const rootClasses = useStylesWithRootClass(rootClassName$13, className);
3681
+ const rootClasses = useStylesWithRootClass(rootClassName$15, className);
3682
3682
  const backdropEnabled = variant === 'temporary' && !(ModalProps === null || ModalProps === void 0 ? void 0 : ModalProps.hideBackdrop);
3683
3683
  const headerExists = !!drawerHeaderProps;
3684
3684
  const bodyPendoId = drawerBodyProps ? drawerBodyProps['data-pendoid'] : 'drawer-body';
@@ -4076,7 +4076,7 @@ const DotList = ({
4076
4076
  nestedListType = 'expandable',
4077
4077
  width = 240
4078
4078
  }) => {
4079
- const rootClasses = useStylesWithRootClass(rootClassName$18, className);
4079
+ const rootClasses = useStylesWithRootClass(rootClassName$1a, className);
4080
4080
  const listWidth = typeof width === 'number' ? `${width}px` : width;
4081
4081
  const listRef = useRef();
4082
4082
  const [listItemIndex, setListItemIndex] = useState(null);
@@ -4170,12 +4170,12 @@ const DotList = ({
4170
4170
  });
4171
4171
  };
4172
4172
 
4173
- const rootClassName$_ = 'dot-copy-button';
4173
+ const rootClassName$10 = 'dot-copy-button';
4174
4174
  const StyledCopyButton = styled.span`
4175
4175
  ${({
4176
4176
  theme
4177
4177
  }) => css`
4178
- &.${rootClassName$_} .copied-to-clipboard {
4178
+ &.${rootClassName$10} .copied-to-clipboard {
4179
4179
  color: ${theme.palette.figma.success.normal};
4180
4180
 
4181
4181
  &.MuiIcon-fontSizeSmall.button-size-small {
@@ -4201,7 +4201,7 @@ const DotCopyButton = ({
4201
4201
  color = 'inherit',
4202
4202
  copiedTooltip = 'Copied!',
4203
4203
  copyTooltip = 'Copy to clipboard',
4204
- 'data-pendoid': dataPendoId = rootClassName$_,
4204
+ 'data-pendoid': dataPendoId = rootClassName$10,
4205
4205
  'data-testid': dataTestId = 'dot-copy-button',
4206
4206
  disabled = false,
4207
4207
  disableRipple = false,
@@ -4249,7 +4249,7 @@ const DotCopyButton = ({
4249
4249
  return false;
4250
4250
  }, [value, showCopiedIcon, disabled, onClick]);
4251
4251
  return jsxs(StyledCopyButton, {
4252
- className: rootClassName$_,
4252
+ className: rootClassName$10,
4253
4253
  "data-testid": dataTestId,
4254
4254
  children: [!timedShowCopiedIcon && jsx(DotIconButton, {
4255
4255
  ariaLabel: ariaLabel,
@@ -4338,7 +4338,7 @@ const DotInputText = ({
4338
4338
  autoFocus,
4339
4339
  className,
4340
4340
  defaultValue,
4341
- 'data-pendoid': dataPendoId = rootClassName$1e,
4341
+ 'data-pendoid': dataPendoId = rootClassName$1g,
4342
4342
  'data-testid': dataTestId,
4343
4343
  disabled = false,
4344
4344
  error = false,
@@ -4384,7 +4384,7 @@ const DotInputText = ({
4384
4384
  const internalInputRef = useRef(null);
4385
4385
  const textFieldInputRef = inputRef || internalInputRef;
4386
4386
  const [inputTextState, setInputTextState] = useState(getInitialState(value));
4387
- const rootStyles = useStylesWithRootClass(rootClassName$1e, hasError, hasWarning, hasSuccess, readOnly && readOnlyClassName$1);
4387
+ const rootStyles = useStylesWithRootClass(rootClassName$1g, hasError, hasWarning, hasSuccess, readOnly && readOnlyClassName$1);
4388
4388
  useEffect(() => {
4389
4389
  if (value !== inputTextState.inputValue) {
4390
4390
  setInputTextState(getInitialState(value, defaultValue));
@@ -4520,10 +4520,10 @@ const DotInputText = ({
4520
4520
  });
4521
4521
  };
4522
4522
 
4523
- const rootClassName$Z = 'dot-search-input';
4523
+ const rootClassName$$ = 'dot-search-input';
4524
4524
  const StyledSearchInput = styled.span`
4525
4525
  ${() => css`
4526
- &.${rootClassName$Z} {
4526
+ &.${rootClassName$$} {
4527
4527
  }
4528
4528
  `}
4529
4529
  `;
@@ -4540,7 +4540,7 @@ function SearchInput({
4540
4540
  tooltip = null,
4541
4541
  value
4542
4542
  }) {
4543
- const rootClasses = useStylesWithRootClass(rootClassName$Z, className);
4543
+ const rootClasses = useStylesWithRootClass(rootClassName$$, className);
4544
4544
  const [searchText, setSearchText] = useState(value);
4545
4545
  let previousSearchText = '';
4546
4546
  const handleChange = useCallback(event => {
@@ -4796,12 +4796,12 @@ const recentAppInstancesSetter = (latestInstance, maxRecentItems
4796
4796
  };
4797
4797
  };
4798
4798
 
4799
- const rootClassName$Y = 'dot-app-switcher';
4799
+ const rootClassName$_ = 'dot-app-switcher';
4800
4800
  const StyledAppSwitcher = styled(DotDrawer)`
4801
4801
  ${({
4802
4802
  theme
4803
4803
  }) => css`
4804
- &.${rootClassName$Y} {
4804
+ &.${rootClassName$_} {
4805
4805
  .dot-drawer-paper {
4806
4806
  padding: 0;
4807
4807
  width: 382px;
@@ -4911,7 +4911,7 @@ const DotAppSwitcherView = ({
4911
4911
  if (dotCoreApiContext !== null) {
4912
4912
  setSelectedAppType = dotCoreApiContext.setSelectedAppSwitcherAppType;
4913
4913
  }
4914
- const rootClasses = useStylesWithRootClass(rootClassName$Y, className);
4914
+ const rootClasses = useStylesWithRootClass(rootClassName$_, className);
4915
4915
  const [appTypeMap, setAppTypeMap] = useState();
4916
4916
  const [appTypeLabels, setAppTypeLabels] = useState();
4917
4917
  const [appTypeMenuItems, setAppTypeMenuItems] = useState();
@@ -5289,12 +5289,12 @@ var SvgLogoDigitalAiWhite = function SvgLogoDigitalAiWhite(_ref, ref) {
5289
5289
  };
5290
5290
  var ForwardRef = /*#__PURE__*/forwardRef(SvgLogoDigitalAiWhite);
5291
5291
 
5292
- const rootClassName$X = 'dot-sidebar';
5292
+ const rootClassName$Z = 'dot-sidebar';
5293
5293
  const StyledSidebar = styled.aside`
5294
5294
  ${({
5295
5295
  theme
5296
5296
  }) => css`
5297
- &.${rootClassName$X} {
5297
+ &.${rootClassName$Z} {
5298
5298
  align-items: stretch;
5299
5299
  background: ${theme.palette.figma.background.level1.white};
5300
5300
  border-width: 0 1px;
@@ -5588,10 +5588,10 @@ const StyledSidebar = styled.aside`
5588
5588
  `}
5589
5589
  `;
5590
5590
 
5591
- const rootClassName$W = 'dot-truncate-with-tooltip';
5591
+ const rootClassName$Y = 'dot-truncate-with-tooltip';
5592
5592
  const StyledTruncateWithTooltip = styled(Tooltip)`
5593
5593
  ${() => css`
5594
- &.${rootClassName$W} {
5594
+ &.${rootClassName$Y} {
5595
5595
  display: block;
5596
5596
  overflow: hidden;
5597
5597
  white-space: nowrap;
@@ -5622,7 +5622,7 @@ const DotTruncateWithTooltip = ({
5622
5622
  label,
5623
5623
  width
5624
5624
  }) => {
5625
- const rootClasses = useStylesWithRootClass(rootClassName$W, className, charactersLimit ? 'dot-characters-limit' : '');
5625
+ const rootClasses = useStylesWithRootClass(rootClassName$Y, className, charactersLimit ? 'dot-characters-limit' : '');
5626
5626
  return jsx(StyledTruncateWithTooltip, {
5627
5627
  "aria-label": ariaLabel,
5628
5628
  arrow: arrow,
@@ -5746,7 +5746,7 @@ const DotSidebar = ({
5746
5746
  };
5747
5747
  }, [isOpen, collapsable]);
5748
5748
  const sidebarClasses = useStylesWithRootClass('side-nav', openClass);
5749
- const rootClasses = useStylesWithRootClass(rootClassName$X, openClass, className);
5749
+ const rootClasses = useStylesWithRootClass(rootClassName$Z, openClass, className);
5750
5750
  return jsxs(StyledSidebar, {
5751
5751
  "aria-label": ariaLabel,
5752
5752
  className: rootClasses,
@@ -5814,12 +5814,12 @@ const DotSidebar = ({
5814
5814
  });
5815
5815
  };
5816
5816
 
5817
- const rootClassName$V = 'dot-badge';
5817
+ const rootClassName$X = 'dot-badge';
5818
5818
  const StyledBadge = styled(Badge)`
5819
5819
  ${({
5820
5820
  theme
5821
5821
  }) => css`
5822
- &.${rootClassName$V} {
5822
+ &.${rootClassName$X} {
5823
5823
  color: ${theme.palette.figma.typography.black};
5824
5824
  word-break: normal;
5825
5825
 
@@ -5854,7 +5854,7 @@ const DotBadge = ({
5854
5854
  overlap,
5855
5855
  variant = 'dot'
5856
5856
  }) => {
5857
- const rootClasses = useStylesWithRootClass(rootClassName$V, className);
5857
+ const rootClasses = useStylesWithRootClass(rootClassName$X, className);
5858
5858
  return jsx(StyledBadge, {
5859
5859
  "$badgeColor": badgeColor,
5860
5860
  anchorOrigin: {
@@ -5876,7 +5876,7 @@ const DotBadge = ({
5876
5876
  });
5877
5877
  };
5878
5878
 
5879
- const rootClassName$U = 'dot-app-toolbar';
5879
+ const rootClassName$W = 'dot-app-toolbar';
5880
5880
  const denseClassName = 'dense';
5881
5881
  const StyledMainMenu = styled(DotDrawer)`
5882
5882
  ${({
@@ -5916,7 +5916,7 @@ const StyledAppToolbar = styled.header`
5916
5916
  ${({
5917
5917
  theme
5918
5918
  }) => css`
5919
- &.${rootClassName$U} {
5919
+ &.${rootClassName$W} {
5920
5920
  align-items: center;
5921
5921
  background: ${theme.palette.figma.appToolbar.background};
5922
5922
  border-bottom: 4px solid ${theme.palette.figma.border.default};
@@ -6038,7 +6038,7 @@ const DotAppToolbar = ({
6038
6038
  const displayAppLogo = appLogo || appLogoSmall;
6039
6039
  const mainMenuRef = useRef(null);
6040
6040
  const denseClass = dense ? denseClassName : '';
6041
- const rootClasses = useStylesWithRootClass(rootClassName$U, className, denseClass, showMainMenu ? '' : 'without-menu-icon');
6041
+ const rootClasses = useStylesWithRootClass(rootClassName$W, className, denseClass, showMainMenu ? '' : 'without-menu-icon');
6042
6042
  const mainMenuClasses = useStylesWithRootClass('dot-main-menu', denseClass, menuOpen ? 'open' : '');
6043
6043
  const targetBreakpoint = useMediaQuery(theme => theme.breakpoints.up('lg'));
6044
6044
  useEffect(() => {
@@ -6168,14 +6168,14 @@ const DotAppToolbar = ({
6168
6168
  }) : appToolbar;
6169
6169
  };
6170
6170
 
6171
- const rootClassName$T = 'dot-autocomplete';
6171
+ const rootClassName$V = 'dot-autocomplete';
6172
6172
  const inputRootClassName = 'dot-input-root';
6173
6173
  const inputMediumClassName = 'dot-input-medium';
6174
6174
  const StyledAutocomplete = styled(Autocomplete)`
6175
6175
  ${({
6176
6176
  theme
6177
6177
  }) => css`
6178
- &.${rootClassName$T} {
6178
+ &.${rootClassName$V} {
6179
6179
  &.${inputMediumClassName} .dot-text-field .${inputRootClassName} {
6180
6180
  height: 56px;
6181
6181
  padding-left: ${theme.spacing(2)};
@@ -6212,12 +6212,12 @@ const StyledAutocomplete = styled(Autocomplete)`
6212
6212
  `}
6213
6213
  `;
6214
6214
 
6215
- const rootClassName$S = 'dot-chip';
6215
+ const rootClassName$U = 'dot-chip';
6216
6216
  const StyledChip = styled(Chip)`
6217
6217
  ${({
6218
6218
  theme
6219
6219
  }) => css`
6220
- &.${rootClassName$S} {
6220
+ &.${rootClassName$U} {
6221
6221
  background: ${theme.palette.figma.neutral.normal};
6222
6222
  border-color: ${theme.palette.figma.border.darker};
6223
6223
  color: ${theme.palette.figma.typography.black};
@@ -6323,7 +6323,7 @@ const DotChip = ({
6323
6323
  charactersLimit = DEFAULT_CHARACTERS_LIMIT,
6324
6324
  children,
6325
6325
  className,
6326
- 'data-pendoid': dataPendoId = rootClassName$S,
6326
+ 'data-pendoid': dataPendoId = rootClassName$U,
6327
6327
  'data-testid': dataTestId,
6328
6328
  disabled = false,
6329
6329
  error = false,
@@ -6336,7 +6336,7 @@ const DotChip = ({
6336
6336
  tabIndex
6337
6337
  }) => {
6338
6338
  const errorClass = error ? 'Mui-error' : '';
6339
- const rootClasses = useStylesWithRootClass(rootClassName$S, className, errorClass);
6339
+ const rootClasses = useStylesWithRootClass(rootClassName$U, className, errorClass);
6340
6340
  const getChipLabel = () => {
6341
6341
  if (charactersLimit <= 0 || children.length < charactersLimit) return children;
6342
6342
  const label = `${children.substring(0, charactersLimit)}...`;
@@ -6436,7 +6436,7 @@ const DotAutoComplete = ({
6436
6436
  autoFocus,
6437
6437
  autoHighlight,
6438
6438
  className,
6439
- 'data-pendoid': dataPendoId = rootClassName$T,
6439
+ 'data-pendoid': dataPendoId = rootClassName$V,
6440
6440
  'data-testid': dataTestId,
6441
6441
  defaultValue,
6442
6442
  dense = true,
@@ -6488,10 +6488,10 @@ const DotAutoComplete = ({
6488
6488
  const popperOpen = !readOnly && (open || isOpened);
6489
6489
  const preventDuplicateInsertion = actionItem === null || actionItem === void 0 ? void 0 : actionItem.preventDuplicateInsertion;
6490
6490
  const textFieldWarningClassName = !error && warning && warningClassName;
6491
- const rootClasses = useStylesWithRootClass(rootClassName$T, size === 'medium' && inputMediumClassName, className);
6492
- const textFieldRootClasses = useStylesWithRootClass(rootClassName$1e, readOnly && readOnlyClassName$1, textFieldWarningClassName);
6491
+ const rootClasses = useStylesWithRootClass(rootClassName$V, size === 'medium' && inputMediumClassName, className);
6492
+ const textFieldRootClasses = useStylesWithRootClass(rootClassName$1g, readOnly && readOnlyClassName$1, textFieldWarningClassName);
6493
6493
  const inputRootClasses = useStylesWithRootClass(inputRootClassName, !dense && inputMediumClassName);
6494
- const popperClasses = useStylesWithRootClass(rootClassName$16, popperClassName);
6494
+ const popperClasses = useStylesWithRootClass(rootClassName$18, popperClassName);
6495
6495
  let highlightedOption = null;
6496
6496
  let textFieldInput;
6497
6497
  const textFieldRef = element => {
@@ -6768,10 +6768,10 @@ const DotAutoComplete = ({
6768
6768
  });
6769
6769
  };
6770
6770
 
6771
- const rootClassName$R = 'dot-avatar-group';
6771
+ const rootClassName$T = 'dot-avatar-group';
6772
6772
  const StyledAvatarGroup = styled(AvatarGroup)`
6773
6773
  ${() => css`
6774
- &.${rootClassName$R} {
6774
+ &.${rootClassName$T} {
6775
6775
  justify-content: flex-end;
6776
6776
 
6777
6777
  .MuiAvatar-root {
@@ -6790,7 +6790,7 @@ const DotAvatarGroup = ({
6790
6790
  max = 3,
6791
6791
  spacing = 'medium'
6792
6792
  }) => {
6793
- const rootClasses = useStylesWithRootClass(rootClassName$R, className);
6793
+ const rootClasses = useStylesWithRootClass(rootClassName$T, className);
6794
6794
  return jsx(StyledAvatarGroup, {
6795
6795
  "aria-label": ariaLabel,
6796
6796
  classes: {
@@ -6805,13 +6805,13 @@ const DotAvatarGroup = ({
6805
6805
  });
6806
6806
  };
6807
6807
 
6808
- const rootClassName$Q = 'dot-breadcrumbs';
6808
+ const rootClassName$S = 'dot-breadcrumbs';
6809
6809
  const breadcrumbsWrapperClass = 'dot-breadcrumbs-wrapper';
6810
6810
  const StyledBreadcrumbsWrapper = styled.div`
6811
6811
  ${({
6812
6812
  theme
6813
6813
  }) => css`
6814
- &.${rootClassName$Q} {
6814
+ &.${rootClassName$S} {
6815
6815
  overflow: hidden;
6816
6816
 
6817
6817
  .dot-breadcrumbs-menu {
@@ -6831,7 +6831,7 @@ const StyledBreadcrumbs = styled(Breadcrumbs)`
6831
6831
  ${({
6832
6832
  theme
6833
6833
  }) => css`
6834
- &.${rootClassName$Q} {
6834
+ &.${rootClassName$S} {
6835
6835
  margin-bottom: 0;
6836
6836
 
6837
6837
  .MuiBreadcrumbs-ol {
@@ -7159,7 +7159,7 @@ const DotBreadcrumbs = ({
7159
7159
  children: [jsx(StyledBreadcrumbs, {
7160
7160
  "aria-label": "breadcrumb",
7161
7161
  classes: {
7162
- root: rootClassName$Q,
7162
+ root: rootClassName$S,
7163
7163
  ol: 'dot-ol',
7164
7164
  li: 'dot-li'
7165
7165
  },
@@ -7190,14 +7190,14 @@ const DotBreadcrumbs = ({
7190
7190
  });
7191
7191
  };
7192
7192
 
7193
- const rootClassName$P = 'dot-button-toggle';
7193
+ const rootClassName$R = 'dot-button-toggle';
7194
7194
  // TODO: need to update ripple color
7195
7195
  // https://github.com/mui/material-ui/issues/28543
7196
7196
  const StyledToggleButtonGroup = styled(ToggleButtonGroup)`
7197
7197
  ${({
7198
7198
  theme
7199
7199
  }) => css`
7200
- &.${rootClassName$P} {
7200
+ &.${rootClassName$R} {
7201
7201
  button:not(.MuiToggleButton-sizeLarge):not(.MuiToggleButton-sizeSmall) {
7202
7202
  /* Override height for medium size */
7203
7203
  height: ${theme.spacing(5)};
@@ -7313,7 +7313,7 @@ const DotButtonToggle = ({
7313
7313
  buttonOptions,
7314
7314
  className,
7315
7315
  color,
7316
- 'data-pendoid': dataPendoId = rootClassName$P,
7316
+ 'data-pendoid': dataPendoId = rootClassName$R,
7317
7317
  'data-testid': dataTestId = 'dot-toggle',
7318
7318
  disableFocusRipple = false,
7319
7319
  disableRipple = false,
@@ -7323,7 +7323,7 @@ const DotButtonToggle = ({
7323
7323
  size = 'medium',
7324
7324
  value
7325
7325
  }) => {
7326
- const rootClasses = useStylesWithRootClass(rootClassName$P, className);
7326
+ const rootClasses = useStylesWithRootClass(rootClassName$R, className);
7327
7327
  const renderToggleButton = ({
7328
7328
  ariaLabel: optionAriaLabel,
7329
7329
  badgeContent: optionBadgeContent,
@@ -7406,12 +7406,12 @@ const TooltipToggleButton = forwardRef((_a, ref) => {
7406
7406
  }));
7407
7407
  });
7408
7408
 
7409
- const rootClassName$O = 'dot-card';
7409
+ const rootClassName$Q = 'dot-card';
7410
7410
  const StyledCard = styled(Card)`
7411
7411
  ${({
7412
7412
  theme
7413
7413
  }) => css`
7414
- &.${rootClassName$O} {
7414
+ &.${rootClassName$Q} {
7415
7415
  background-color: ${theme.palette.figma.background.level1.white};
7416
7416
  }
7417
7417
  `}
@@ -7423,7 +7423,7 @@ const DotCard = ({
7423
7423
  className,
7424
7424
  'data-testid': dataTestId
7425
7425
  }) => {
7426
- const rootClasses = useStylesWithRootClass(rootClassName$O, className);
7426
+ const rootClasses = useStylesWithRootClass(rootClassName$Q, className);
7427
7427
  return jsx(StyledCard, {
7428
7428
  "aria-label": ariaLabel,
7429
7429
  classes: {
@@ -7452,12 +7452,12 @@ const DotCardContent = ({
7452
7452
  });
7453
7453
  };
7454
7454
 
7455
- const rootClassName$N = 'dot-card-footer';
7455
+ const rootClassName$P = 'dot-card-footer';
7456
7456
  const StyledDiv = styled.div`
7457
7457
  ${({
7458
7458
  theme
7459
7459
  }) => css`
7460
- &.${rootClassName$N} {
7460
+ &.${rootClassName$P} {
7461
7461
  padding: ${theme.spacing(2)};
7462
7462
  }
7463
7463
  `}
@@ -7469,7 +7469,7 @@ const DotCardFooter = ({
7469
7469
  className,
7470
7470
  'data-testid': dataTestId
7471
7471
  }) => {
7472
- const rootClasses = useStylesWithRootClass(rootClassName$N, className);
7472
+ const rootClasses = useStylesWithRootClass(rootClassName$P, className);
7473
7473
  return jsx(StyledDiv, {
7474
7474
  "aria-label": ariaLabel,
7475
7475
  className: rootClasses,
@@ -7513,9 +7513,9 @@ const DotCardHeader = ({
7513
7513
  });
7514
7514
  };
7515
7515
 
7516
- const rootClassName$M = 'dot-form-control-label';
7516
+ const rootClassName$O = 'dot-form-control-label';
7517
7517
  const StyledFormControlLabel = styled(FormControlLabel)`
7518
- &.${rootClassName$M} {
7518
+ &.${rootClassName$O} {
7519
7519
  .MuiFormControlLabel-label {
7520
7520
  margin-bottom: 0;
7521
7521
  padding: 0 0 0 4px;
@@ -7538,12 +7538,12 @@ const StyledFormControlLabel = styled(FormControlLabel)`
7538
7538
  }
7539
7539
  `;
7540
7540
 
7541
- const rootClassName$L = 'dot-checkbox';
7541
+ const rootClassName$N = 'dot-checkbox';
7542
7542
  const StyledCheckbox = styled(Checkbox)`
7543
7543
  ${({
7544
7544
  theme
7545
7545
  }) => css`
7546
- &.${rootClassName$L} {
7546
+ &.${rootClassName$N} {
7547
7547
  padding: ${theme.spacing(1)};
7548
7548
 
7549
7549
  &.MuiCheckbox-indeterminate {
@@ -7562,7 +7562,7 @@ function DotCheckbox({
7562
7562
  ariaLabelledby,
7563
7563
  checked,
7564
7564
  className,
7565
- 'data-pendoid': dataPendoId = rootClassName$M,
7565
+ 'data-pendoid': dataPendoId = rootClassName$O,
7566
7566
  'data-testid': dataTestId,
7567
7567
  disabled,
7568
7568
  disableRipple,
@@ -7577,14 +7577,14 @@ function DotCheckbox({
7577
7577
  size = 'medium',
7578
7578
  value
7579
7579
  }) {
7580
- const rootClasses = useStylesWithRootClass(rootClassName$M, className);
7580
+ const rootClasses = useStylesWithRootClass(rootClassName$O, className);
7581
7581
  const handleChange = event => {
7582
7582
  onChange && onChange(event, event.target.value);
7583
7583
  };
7584
7584
  const checkboxControl = jsx(StyledCheckbox, {
7585
7585
  checked: checked,
7586
7586
  classes: {
7587
- root: rootClassName$L
7587
+ root: rootClassName$N
7588
7588
  },
7589
7589
  color: "primary",
7590
7590
  "data-pendoid": dataPendoId,
@@ -7613,13 +7613,13 @@ function DotCheckbox({
7613
7613
  });
7614
7614
  }
7615
7615
 
7616
- const rootClassName$K = 'dot-form-group';
7616
+ const rootClassName$M = 'dot-form-group';
7617
7617
  const groupLabelClassName = 'dot-form-group-label';
7618
7618
  const startAdornmentClassName = 'dot-start-adornment';
7619
7619
  const endAdornmentClassName = 'dot-end-adornment';
7620
7620
  const placementClassName = 'dot-';
7621
7621
  const StyledFormControl = styled(FormControl)`
7622
- &.${rootClassName$K} {
7622
+ &.${rootClassName$M} {
7623
7623
  .MuiFormLabel-root {
7624
7624
  width: 100%;
7625
7625
  line-height: 24px;
@@ -7650,7 +7650,7 @@ const StyledFormControl = styled(FormControl)`
7650
7650
  }
7651
7651
  `;
7652
7652
 
7653
- const rootClassName$J = 'dot-checkbox-group';
7653
+ const rootClassName$L = 'dot-checkbox-group';
7654
7654
  const wrapperClassName$1 = 'dot-checkbox-group-wrapper';
7655
7655
  const checkboxListClassName = 'dot-checkbox-list';
7656
7656
  const checkboxListItemClassName = 'dot-checkbox-list-item';
@@ -7659,7 +7659,7 @@ const StyledCheckboxGroup = styled.div`
7659
7659
  theme
7660
7660
  }) => css`{
7661
7661
  &.${wrapperClassName$1} {
7662
- .${rootClassName$J} {
7662
+ .${rootClassName$L} {
7663
7663
  width: 100%;
7664
7664
  }
7665
7665
 
@@ -7686,7 +7686,7 @@ const StyledCheckboxGroup = styled.div`
7686
7686
  margin-top: 0;
7687
7687
  padding-left: ${theme.spacing(2.5)};
7688
7688
 
7689
- .${rootClassName$M} {
7689
+ .${rootClassName$O} {
7690
7690
  margin: 0;
7691
7691
  }
7692
7692
  }
@@ -7694,13 +7694,13 @@ const StyledCheckboxGroup = styled.div`
7694
7694
  `}
7695
7695
  `;
7696
7696
 
7697
- const rootClassName$I = 'dot-form-group';
7697
+ const rootClassName$K = 'dot-form-group';
7698
7698
  const StyledFormGroup = styled(FormGroup)`
7699
7699
  ${({
7700
7700
  theme,
7701
7701
  row
7702
7702
  }) => css`
7703
- &.${rootClassName$I} > * {
7703
+ &.${rootClassName$K} > * {
7704
7704
  margin: ${row ? `${theme.spacing(0.5)}` : 0};
7705
7705
  }
7706
7706
  `}
@@ -7713,7 +7713,7 @@ function DotFormGroup({
7713
7713
  'data-testid': dataTestId,
7714
7714
  row
7715
7715
  }) {
7716
- const rootClasses = useStylesWithRootClass(rootClassName$K, className);
7716
+ const rootClasses = useStylesWithRootClass(rootClassName$M, className);
7717
7717
  return jsx(StyledFormGroup, {
7718
7718
  "aria-label": ariaLabel,
7719
7719
  classes: {
@@ -7752,7 +7752,7 @@ function DotCheckboxGroup({
7752
7752
  size = 'medium'
7753
7753
  }) {
7754
7754
  const placement = `${placementClassName}${labelPlacement}`;
7755
- const rootClasses = useStylesWithRootClass(rootClassName$K, rootClassName$J, className, placement);
7755
+ const rootClasses = useStylesWithRootClass(rootClassName$M, rootClassName$L, className, placement);
7756
7756
  const [selectedOptions, setSelectedOptions] = useState(defaultValues);
7757
7757
  const [allChecked, setAllChecked] = useState(false);
7758
7758
  /* This will ensure that state can be updated from the outside */
@@ -7837,12 +7837,99 @@ function DotCheckboxGroup({
7837
7837
  });
7838
7838
  }
7839
7839
 
7840
- const rootClassName$H = 'dot-dialog';
7840
+ const rootClassName$J = 'chip-list';
7841
+ const StyledChipList = styled.div`
7842
+ ${({
7843
+ theme
7844
+ }) => css`
7845
+ &.${rootClassName$J} {
7846
+ display: flex;
7847
+ gap: ${theme.spacing(1)};
7848
+ }
7849
+ `}
7850
+ `;
7851
+
7852
+ const formatListForTooltip = words => {
7853
+ const elements = [];
7854
+ if (words.length > 1) {
7855
+ words.forEach(word => {
7856
+ elements.push(jsx("div", {
7857
+ children: word
7858
+ }));
7859
+ });
7860
+ return jsx("div", {
7861
+ children: elements
7862
+ });
7863
+ }
7864
+ return '';
7865
+ };
7866
+ function DotChipList({
7867
+ dataTestId,
7868
+ items,
7869
+ maxChars = -1,
7870
+ size = 'small',
7871
+ style = {}
7872
+ }) {
7873
+ const [chips, setChips] = useState([]);
7874
+ useEffect(() => {
7875
+ const extraItems = [];
7876
+ let itemElements = [];
7877
+ if (items && maxChars > 0) {
7878
+ let chars = 0;
7879
+ for (let i = 0; i < items.length; i++) {
7880
+ const item = items[i];
7881
+ const label = item.label;
7882
+ if (chars + label.length <= maxChars && extraItems.length === 0) {
7883
+ chars += label.length;
7884
+ itemElements.push(jsx(DotChip, {
7885
+ size: size,
7886
+ children: label
7887
+ }, item.key));
7888
+ } else if (i === 0) {
7889
+ // With first item, truncate if item is too long rather than pushing to extraItems.
7890
+ const truncatedItem = label.substring(0, maxChars - 3) + '...';
7891
+ chars = truncatedItem.length;
7892
+ itemElements.push(jsx(DotTooltip, {
7893
+ title: label,
7894
+ children: jsx(DotChip, {
7895
+ size: size,
7896
+ children: truncatedItem
7897
+ }, item.key)
7898
+ }, item.key));
7899
+ } else {
7900
+ extraItems.push(label);
7901
+ }
7902
+ }
7903
+ if (extraItems.length > 0) {
7904
+ itemElements.push(jsx(DotTooltip, {
7905
+ title: formatListForTooltip(items === null || items === void 0 ? void 0 : items.map(item => item.label)),
7906
+ children: jsxs(DotTypography, {
7907
+ children: ["+", extraItems.length]
7908
+ })
7909
+ }));
7910
+ }
7911
+ } else {
7912
+ itemElements = items === null || items === void 0 ? void 0 : items.map(item => jsx(DotChip, {
7913
+ size: size,
7914
+ children: item.label
7915
+ }, item.key));
7916
+ }
7917
+ setChips(itemElements);
7918
+ }, [items, maxChars]);
7919
+ return jsx(StyledChipList, {
7920
+ className: rootClassName$J,
7921
+ "data-testid": dataTestId,
7922
+ style: style,
7923
+ children: chips
7924
+ });
7925
+ }
7926
+
7927
+ const rootClassName$I = 'dot-dialog';
7841
7928
  const StyledDialog = styled(Dialog)`
7842
7929
  ${({
7843
7930
  theme
7844
7931
  }) => css`
7845
- &.${rootClassName$H} {
7932
+ &.${rootClassName$I} {
7846
7933
  .MuiDialog-paper {
7847
7934
  background: ${theme.palette.figma.background.level1.white};
7848
7935
  color: ${theme.palette.figma.typography.black};
@@ -7888,7 +7975,7 @@ const DotDialog = ({
7888
7975
  cancelButtonProps,
7889
7976
  cancelButtonVisible = true,
7890
7977
  className,
7891
- 'data-pendoid': dataPendoId = rootClassName$H,
7978
+ 'data-pendoid': dataPendoId = rootClassName$I,
7892
7979
  'data-testid': dataTestId,
7893
7980
  children,
7894
7981
  closeIconVisible,
@@ -7901,7 +7988,7 @@ const DotDialog = ({
7901
7988
  submitButtonProps,
7902
7989
  title
7903
7990
  }) => {
7904
- const rootClasses = useStylesWithRootClass(rootClassName$H, className);
7991
+ const rootClasses = useStylesWithRootClass(rootClassName$I, className);
7905
7992
  const cancelClasses = useStylesWithRootClass(cancelButtonProps === null || cancelButtonProps === void 0 ? void 0 : cancelButtonProps.className, 'cancel-button');
7906
7993
  const [isOpen, setIsOpen] = useState(open);
7907
7994
  useEffect(() => {
@@ -8019,7 +8106,7 @@ const DotConfirmationDialog = ({
8019
8106
  });
8020
8107
  };
8021
8108
 
8022
- const rootClassName$G = 'dot-grid';
8109
+ const rootClassName$H = 'dot-grid';
8023
8110
  const frGetter = value => typeof value === 'number' ? `repeat(${value}, 1fr)` : value;
8024
8111
  const breakpointsGetter$1 = (theme, columnsBreakpoints, columnGap, rowGap) => `${theme.breakpoints.up('xs')} {
8025
8112
  column-gap: ${`${columnGap.xs}px`};
@@ -8071,7 +8158,7 @@ const Grid = ({
8071
8158
  className,
8072
8159
  children
8073
8160
  }) => {
8074
- const rootClasses = useStylesWithRootClass(rootClassName$G, className);
8161
+ const rootClasses = useStylesWithRootClass(rootClassName$H, className);
8075
8162
  return jsx("div", {
8076
8163
  className: rootClasses,
8077
8164
  children: children
@@ -8090,7 +8177,7 @@ const StyledGrid = styled(Grid)`
8090
8177
  theme,
8091
8178
  width
8092
8179
  }) => css`
8093
- &.${rootClassName$G} {
8180
+ &.${rootClassName$H} {
8094
8181
  display: grid;
8095
8182
  grid-template-rows: ${frGetter(rows)};
8096
8183
  ${columns ? `${columns && `grid-template-columns: ${frGetter(columns)}`};` : breakpointsGetter$1(theme, columnsBreakpoints, columnGap, rowGap)}
@@ -8296,114 +8383,151 @@ const CssGridDebug = ({
8296
8383
  });
8297
8384
  };
8298
8385
 
8299
- const DotInputSelect = ({
8386
+ const rootClassName$G = 'dot-pill';
8387
+ const StyledPill = styled(Chip)`
8388
+ ${({
8389
+ theme
8390
+ }) => css`
8391
+ &.${rootClassName$G} {
8392
+ background-color: ${({
8393
+ backgroundcolor,
8394
+ variant
8395
+ }) => {
8396
+ const defaultBackground = variant === 'filled' ? theme.palette.grey[200] : theme.palette.grey[50];
8397
+ return backgroundcolor !== null && backgroundcolor !== void 0 ? backgroundcolor : defaultBackground;
8398
+ }};
8399
+ border-color: ${({
8400
+ bordercolor
8401
+ }) => {
8402
+ return bordercolor ? bordercolor : theme.palette.grey[200];
8403
+ }};
8404
+ color: ${({
8405
+ labelcolor
8406
+ }) => {
8407
+ return labelcolor ? labelcolor : theme.palette.layer.n700;
8408
+ }};
8409
+ .dot-icon {
8410
+ color: ${({
8411
+ labelcolor
8412
+ }) => {
8413
+ return labelcolor ? labelcolor : theme.palette.grey.main;
8414
+ }};
8415
+ margin: ${theme.spacing(0, -0.5, 0, 1)};
8416
+ }
8417
+
8418
+ &.MuiChip-sizeSmall .dot-icon {
8419
+ margin-left: 5px;
8420
+ }
8421
+
8422
+ &.MuiChip-outlined {
8423
+ &.error {
8424
+ background-color: ${theme.palette.error[50]};
8425
+ border-color: ${theme.palette.error.main};
8426
+ color: ${theme.palette.layer.n700};
8427
+ .dot-icon {
8428
+ color: ${theme.palette.error.main};
8429
+ }
8430
+ }
8431
+
8432
+ &.success {
8433
+ background-color: ${theme.palette.figma.success.light};
8434
+ border-color: ${theme.palette.figma.success.normal};
8435
+ color: ${theme.palette.layer.n700};
8436
+ .dot-icon {
8437
+ color: ${theme.palette.success.main};
8438
+ }
8439
+ }
8440
+
8441
+ &.warning {
8442
+ background-color: ${theme.palette.figma.warning.light};
8443
+ border-color: ${theme.palette.figma.warning.normal};
8444
+ color: ${theme.palette.layer.n700};
8445
+ .dot-icon {
8446
+ color: ${theme.palette.warning.main};
8447
+ }
8448
+ }
8449
+
8450
+ &.in-progress {
8451
+ background-color: ${theme.palette.figma.primary.light};
8452
+ border-color: ${theme.palette.figma.primary.normal};
8453
+ color: ${theme.palette.layer.n700};
8454
+ .dot-icon {
8455
+ color: ${theme.palette.primary.main};
8456
+ }
8457
+ }
8458
+ }
8459
+
8460
+ &.MuiChip-filled {
8461
+ &.error {
8462
+ background-color: ${theme.palette.error.main};
8463
+ border-color: ${theme.palette.error.main};
8464
+ color: ${theme.palette.layer.n0};
8465
+ .dot-icon {
8466
+ color: ${theme.palette.layer.n0};
8467
+ }
8468
+ }
8469
+
8470
+ &.success {
8471
+ background-color: ${theme.palette.success.main};
8472
+ border-color: ${theme.palette.success.main};
8473
+ color: ${theme.palette.layer.n0};
8474
+ .dot-icon {
8475
+ color: ${theme.palette.layer.n0};
8476
+ }
8477
+ }
8478
+
8479
+ &.warning {
8480
+ background-color: ${theme.palette.warning.main};
8481
+ border-color: ${theme.palette.warning.main};
8482
+ color: ${theme.palette.layer.n700};
8483
+ .dot-icon {
8484
+ color: ${theme.palette.layer.n700};
8485
+ }
8486
+ }
8487
+
8488
+ &.in-progress {
8489
+ background-color: ${theme.palette.primary.main};
8490
+ border-color: ${theme.palette.primary.main};
8491
+ color: ${theme.palette.layer.n0};
8492
+ .dot-icon {
8493
+ color: ${theme.palette.layer.n0};
8494
+ }
8495
+ }
8496
+ }
8497
+ }
8498
+ `}
8499
+ `;
8500
+
8501
+ const DotPill = ({
8300
8502
  ariaLabel,
8301
- autoFocus,
8503
+ backgroundcolor,
8504
+ bordercolor,
8302
8505
  className,
8303
- 'data-pendoid': dataPendoId = rootSelectClassName,
8304
8506
  'data-testid': dataTestId,
8305
- defaultValue,
8306
- disabled = false,
8307
- endIcon,
8308
- endText,
8309
- error = false,
8310
- fullWidth = true,
8311
- helperText,
8312
- id,
8313
- inputRef,
8507
+ icon,
8314
8508
  label,
8315
- name,
8316
- onBlur,
8317
- onChange,
8318
- onFocus,
8319
- onKeyDown,
8320
- options = [],
8321
- persistentLabel,
8322
- readOnly = false,
8323
- required,
8324
- shrink,
8325
- size = 'small',
8326
- startIcon,
8327
- success,
8328
- value,
8329
- warning = false
8509
+ labelcolor,
8510
+ onClick,
8511
+ size = 'medium',
8512
+ status = 'default',
8513
+ variant = 'filled'
8330
8514
  }) => {
8331
- const hasWarning = !error && warning && warningClassName;
8332
- const hasSuccess = !error && !warning && success && successClassName;
8333
- const endAdornment = endIcon || endText;
8334
- const inputStyles = useStylesWithRootClass('dot-select', readOnly && readOnlyClassName$1);
8335
- const rootStyles = useStylesWithRootClass(rootSelectClassName, hasSuccess, hasWarning);
8336
- const getOption = option => {
8337
- return typeof option === 'string' ? option : option.option;
8338
- };
8339
- const getValue = option => {
8340
- return typeof option === 'string' ? option : (option === null || option === void 0 ? void 0 : option.value) || option.option;
8341
- };
8342
- return jsxs("div", {
8343
- className: className,
8344
- children: [persistentLabel && jsx(DotInputLabel, {
8345
- disabled,
8346
- error,
8347
- id,
8348
- label,
8349
- required
8350
- }), jsx(StyledTextField, {
8351
- InputProps: {
8352
- startAdornment: startIcon && jsx(StyledAdornment, {
8353
- className: `${adornmentIconClassName} start`,
8354
- position: "start",
8355
- children: startIcon
8356
- }),
8357
- endAdornment: endAdornment && jsx(StyledAdornment, {
8358
- className: `${adornmentIconClassName} end`,
8359
- position: "end",
8360
- children: endAdornment
8361
- })
8362
- },
8363
- SelectProps: {
8364
- native: !readOnly,
8365
- readOnly,
8366
- open: readOnly ? false : undefined
8367
- },
8368
- "aria-label": ariaLabel || label,
8369
- autoFocus: autoFocus,
8370
- className: rootStyles,
8371
- defaultValue: defaultValue,
8372
- disabled: disabled,
8373
- error: error,
8374
- fullWidth: fullWidth,
8375
- helperText: helperText,
8376
- id: id,
8377
- InputLabelProps: {
8378
- shrink: shrink
8379
- },
8380
- inputProps: {
8381
- 'aria-label': ariaLabel,
8382
- 'data-pendoid': dataPendoId,
8383
- 'data-testid': dataTestId,
8384
- className: inputStyles,
8385
- readOnly
8386
- },
8387
- inputRef: inputRef,
8388
- label: persistentLabel ? null : label,
8389
- multiline: false,
8390
- name: name,
8391
- onBlur: onBlur,
8392
- onChange: onChange,
8393
- onFocus: onFocus,
8394
- onKeyDown: onKeyDown,
8395
- required: required,
8396
- role: "textbox",
8397
- select: true,
8398
- size: size,
8399
- value: value,
8400
- variant: "outlined",
8401
- children: options.map(option => jsx("option", {
8402
- className: "dot-option",
8403
- value: getValue(option),
8404
- children: getOption(option)
8405
- }, getValue(option)))
8406
- })]
8515
+ const rootClasses = useStylesWithRootClass(rootClassName$G, className, status);
8516
+ return jsx(StyledPill, {
8517
+ "aria-label": ariaLabel,
8518
+ bordercolor: bordercolor,
8519
+ backgroundcolor: backgroundcolor,
8520
+ classes: {
8521
+ root: rootClasses
8522
+ },
8523
+ clickable: !!onClick,
8524
+ "data-testid": dataTestId,
8525
+ icon: icon,
8526
+ label: label,
8527
+ labelcolor: labelcolor,
8528
+ onClick: onClick,
8529
+ size: size,
8530
+ variant: variant
8407
8531
  });
8408
8532
  };
8409
8533
 
@@ -9121,6 +9245,26 @@ class HelpContentService {
9121
9245
  }
9122
9246
  }
9123
9247
 
9248
+ function DotDashboardStatusPill({
9249
+ status
9250
+ }) {
9251
+ if (status === DashboardView.lifecycle_state.DRAFT) {
9252
+ return jsx(DotPill, {
9253
+ label: "Draft",
9254
+ size: "small",
9255
+ variant: "outlined",
9256
+ status: "in-progress"
9257
+ });
9258
+ } else {
9259
+ return jsx(DotPill, {
9260
+ status: "success",
9261
+ label: "Published",
9262
+ size: "small",
9263
+ variant: "outlined"
9264
+ });
9265
+ }
9266
+ }
9267
+
9124
9268
  const helpContent = {
9125
9269
  id: 'test-help-content-1',
9126
9270
  content: '<html><h1>Test</h1></html>'
@@ -9143,7 +9287,9 @@ const helpContent = {
9143
9287
  bi_type: DashboardView.bi_type.SUPERSET,
9144
9288
  is_ootb_dashboard: false,
9145
9289
  thumbnail: '',
9146
- external_object: {},
9290
+ external_object: {
9291
+ page_count: 3
9292
+ },
9147
9293
  embed_config: {},
9148
9294
  help_content_id: helpContent.id,
9149
9295
  filter_configuration: [],
@@ -9299,17 +9445,19 @@ const DotMetadataApiProvider = ({
9299
9445
  const [dashboards, setDashboards] = useState();
9300
9446
  const [dashboardsLoading, setDashboardsLoading] = useState(true);
9301
9447
  const [helpContentLoading, setHelpContentLoading] = useState(true);
9448
+ const [openedDashboardDetails, setOpenedDashboardDetails] = useState(null);
9302
9449
  const [dashboardsError, setDashboardsError] = useState(null);
9303
9450
  const [platformConsoleUrl, setPlatformConsoleUrl] = useState(null);
9304
9451
  const MOCK_API_URL = 'https://demo-mock-api';
9305
9452
  const memoizedValues = useMemo(() => ({
9306
9453
  categories,
9307
9454
  categoriesLoading,
9308
- dashboards,
9309
9455
  dashboardsError,
9310
9456
  dashboardsLoading,
9311
9457
  helpContentLoading,
9458
+ openedDashboardDetails,
9312
9459
  platformConsoleUrl,
9460
+ setOpenedDashboardDetails,
9313
9461
  setOverrideAccountId: id => {
9314
9462
  setAccountId(id);
9315
9463
  },
@@ -9436,7 +9584,7 @@ const DotMetadataApiProvider = ({
9436
9584
  });
9437
9585
  }
9438
9586
  })
9439
- }), [categories, categoriesLoading, dashboards, dashboardsError, dashboardsLoading, platformConsoleUrl]);
9587
+ }), [categories, categoriesLoading, dashboardsError, dashboardsLoading, openedDashboardDetails, platformConsoleUrl]);
9440
9588
  if (apiUrl && OpenAPI.BASE !== apiUrl) {
9441
9589
  OpenAPI.BASE = apiUrl;
9442
9590
  }
@@ -9456,74 +9604,734 @@ const useDotMetadataApiContext = () => {
9456
9604
  return useContext(DotMetadataApiContext);
9457
9605
  };
9458
9606
 
9459
- const StyledDashboardDialog = styled(DotDialog)`
9607
+ const getSnackbarTitleFromSeverity = severity => {
9608
+ switch (severity) {
9609
+ case 'success':
9610
+ return 'Success';
9611
+ case 'warning':
9612
+ return 'Warning';
9613
+ case 'error':
9614
+ return 'Error';
9615
+ case 'info':
9616
+ return 'Info';
9617
+ default:
9618
+ return 'Success';
9619
+ }
9620
+ };
9621
+ function getErrorText(error) {
9622
+ var _a, _b;
9623
+ if ('status' in error && error.status === 304) {
9624
+ return 'No changes made';
9625
+ } else if ('body' in error) {
9626
+ return ((_b = (_a = error.body) === null || _a === void 0 ? void 0 : _a.error) === null || _b === void 0 ? void 0 : _b.message) ? error.body.error.message : 'Unexpected API error';
9627
+ } else if ('message' in error) {
9628
+ return error.message;
9629
+ }
9630
+ return 'Unexpected API error';
9631
+ }
9632
+
9633
+ function addAutoHideDuration(severity) {
9634
+ return severity === 'error' ? null : 10000;
9635
+ }
9636
+
9637
+ const rootClassName$F = 'dot-snackbar';
9638
+ const StyledSnackbar = styled(Snackbar)`
9460
9639
  ${({
9461
- theme
9640
+ theme,
9641
+ width,
9642
+ $anchorOriginTop
9462
9643
  }) => css`
9463
- .dot-text-field {
9464
- margin-bottom: ${theme.spacing(2)};
9465
- width: 40vw;
9466
- }
9467
- .dot-autocomplete {
9468
- margin-top: ${theme.spacing(1.5)};
9469
- }
9470
- .dot-input-select {
9471
- margin-bottom: ${theme.spacing(2)};
9644
+ &.${rootClassName$F} {
9645
+ .MuiAlert-message {
9646
+ word-break: break-word;
9647
+ }
9648
+ .${rootClassName$1e} {
9649
+ align-items: flex-start;
9650
+ }
9651
+ &.MuiSnackbar-anchorOriginTopLeft,
9652
+ &.MuiSnackbar-anchorOriginTopCenter,
9653
+ &.MuiSnackbar-anchorOriginTopRight {
9654
+ top: ${$anchorOriginTop}px;
9655
+ z-index: ${levelFourth};
9656
+ }
9657
+
9658
+ .dot-snackbar-actions {
9659
+ display: flex;
9660
+ align-items: center;
9661
+ margin-top: ${theme.spacing(1)};
9662
+ gap: ${theme.spacing(2)};
9663
+
9664
+ .primary-action-btn {
9665
+ background-color: transparent;
9666
+ }
9667
+ }
9668
+
9669
+ .MuiAlert-root {
9670
+ max-width: ${width ? 'unset' : '500px'};
9671
+ min-width: ${width ? 'unset' : '344px'};
9672
+ z-index: ${levelFourth};
9673
+ }
9472
9674
  }
9473
9675
  `}
9474
9676
  `;
9475
- const StyledDialogActions = styled(DialogActions)`
9476
- padding-right: 0;
9477
- `;
9478
9677
 
9479
- const DashboardAppTypeOptions = [
9480
- // Matches target_app values in Dashboard model
9481
- {
9482
- option: 'Agility',
9483
- value: 'AGILITY'
9484
- }, {
9485
- option: 'Release',
9486
- value: 'RELEASE'
9487
- }, {
9488
- option: 'Deploy',
9489
- value: 'DEPLOY'
9490
- }, {
9491
- option: 'Continuous Testing',
9492
- value: 'CONTINUOUSTEST'
9493
- }, {
9494
- option: 'TeamForge',
9495
- value: 'TEAMFORGE'
9496
- }];
9497
- const initialFormState = {
9498
- categories: [],
9499
- description: '',
9500
- name: ''
9678
+ const DEFAULT_ANCHOR_ORIGIN = {
9679
+ vertical: 'top',
9680
+ horizontal: 'right'
9501
9681
  };
9502
- const DASHBOARD_NAME_MAX_LENGTH = 250;
9503
- const DASHBOARD_DESCRIPTION_MAX_LENGTH = 250;
9504
- function DotDashboardDialog({
9505
- availableCategories,
9506
- copyDashboard,
9507
- editDashboard,
9508
- open,
9682
+ const DotSnackbar = ({
9683
+ anchorOrigin = DEFAULT_ANCHOR_ORIGIN,
9684
+ anchorOriginTop = 108,
9685
+ ariaLabel,
9686
+ autoHideDuration,
9687
+ children,
9688
+ className,
9689
+ 'data-testid': dataTestId,
9690
+ hideOnClickAway = true,
9509
9691
  onClose,
9510
- onSubmit,
9511
- onContinue,
9512
- title
9513
- }) {
9514
- const [isDirty, setIsDirty] = useState(false);
9515
- const [isLoadingSubmit, setIsLoadingSubmit] = useState(false);
9516
- const [nameError, setNameError] = useState(null);
9517
- const [formValues, setFormValues] = useState(initialFormState);
9518
- const {
9519
- categories,
9520
- description,
9521
- name
9522
- } = formValues;
9523
- const {
9524
- searchDashboards
9525
- } = useDotMetadataApiContext();
9526
- const {
9692
+ open,
9693
+ primaryAction,
9694
+ secondaryAction,
9695
+ severity,
9696
+ width
9697
+ }) => {
9698
+ const hasActions = !!(primaryAction || secondaryAction);
9699
+ const calculatedAutoHideDuration = autoHideDuration === null || autoHideDuration > 0 ? autoHideDuration : addAutoHideDuration(severity);
9700
+ const rootClasses = useStylesWithRootClass(rootClassName$F, className);
9701
+ const handleSnackbarClose = reason => {
9702
+ if (!reason || hideOnClickAway || !hideOnClickAway && reason !== 'clickaway') {
9703
+ onClose();
9704
+ }
9705
+ };
9706
+ return jsx(StyledSnackbar, {
9707
+ anchorOrigin: anchorOrigin,
9708
+ "$anchorOriginTop": anchorOriginTop,
9709
+ "aria-label": ariaLabel,
9710
+ autoHideDuration: calculatedAutoHideDuration,
9711
+ classes: {
9712
+ root: rootClasses
9713
+ },
9714
+ "data-testid": dataTestId,
9715
+ onClose: (_e, r) => handleSnackbarClose(r),
9716
+ open: open,
9717
+ severity: severity,
9718
+ width: width,
9719
+ children: jsx("div", {
9720
+ children: jsx(DotAlertBanner, {
9721
+ severity: severity,
9722
+ width: width,
9723
+ onClose: _e => handleSnackbarClose(),
9724
+ children: jsxs("div", {
9725
+ children: [jsx(DotTypography, {
9726
+ variant: "subtitle2",
9727
+ noMarginBottom: false,
9728
+ children: getSnackbarTitleFromSeverity(severity)
9729
+ }), isString$2(children) ? jsx(DotTypography, {
9730
+ ariaLabel: severity,
9731
+ variant: "body1",
9732
+ children: children
9733
+ }) : jsx("span", {
9734
+ "aria-label": severity,
9735
+ children: children
9736
+ }), hasActions && jsxs("div", {
9737
+ className: "dot-snackbar-actions",
9738
+ children: [primaryAction && jsx(DotButton, {
9739
+ className: "primary-action-btn",
9740
+ "data-testid": "primary-action-btn",
9741
+ onClick: primaryAction.onClick,
9742
+ size: "small",
9743
+ type: "outlined",
9744
+ children: primaryAction.label
9745
+ }), secondaryAction && jsx(DotLink, {
9746
+ "data-testid": "secondary-action-link",
9747
+ href: secondaryAction.href,
9748
+ color: "inherit",
9749
+ children: secondaryAction.label
9750
+ })]
9751
+ })]
9752
+ })
9753
+ })
9754
+ })
9755
+ });
9756
+ };
9757
+
9758
+ const rootClassName$E = 'dot-snackbar-container';
9759
+ const StyledSnackbarContainer = styled.div`
9760
+ ${() => css`
9761
+ &.${rootClassName$E} {
9762
+ position: absolute;
9763
+ top: 0;
9764
+ width: 250px;
9765
+ height: auto;
9766
+ right: 0;
9767
+ & > div {
9768
+ position: relative;
9769
+ }
9770
+ }
9771
+ `}
9772
+ `;
9773
+
9774
+ const DotSnackbarContext = createContext({
9775
+ alerts: [],
9776
+ enqueueMessage: (_message, _severity, _autoHideDuration, _primaryAction, _secondaryAction) => null,
9777
+ removeMessage: _id => null
9778
+ });
9779
+ const DotSnackbarContainer = ({
9780
+ hideOnClickAway
9781
+ }) => {
9782
+ const {
9783
+ alerts,
9784
+ removeMessage
9785
+ } = useDotSnackbarContext();
9786
+ function handleClose(id) {
9787
+ return () => {
9788
+ removeMessage(id);
9789
+ };
9790
+ }
9791
+ return jsx(StyledSnackbarContainer, {
9792
+ className: rootClassName$E,
9793
+ children: jsx("div", {
9794
+ className: rootClassName$E,
9795
+ "data-testid": rootClassName$E,
9796
+ children: alerts.slice().reverse().map(alert => {
9797
+ return jsx(DotSnackbar, {
9798
+ autoHideDuration: alert.autoHideDuration,
9799
+ hideOnClickAway: hideOnClickAway,
9800
+ onClose: handleClose(alert.id),
9801
+ open: alert.open,
9802
+ severity: alert.severity,
9803
+ primaryAction: alert.primaryAction,
9804
+ secondaryAction: alert.secondaryAction,
9805
+ children: alert.message
9806
+ }, alert.id);
9807
+ })
9808
+ })
9809
+ });
9810
+ };
9811
+ const DotSnackbarProvider = ({
9812
+ children,
9813
+ hideOnClickAway = true
9814
+ }) => {
9815
+ const [alerts, setAlerts] = useState([]);
9816
+ function enqueueMessage(message, severity, autoHideDuration, primaryAction, secondaryAction) {
9817
+ const id = CreateUUID();
9818
+ const queue = {
9819
+ id,
9820
+ message,
9821
+ severity,
9822
+ open: true,
9823
+ autoHideDuration,
9824
+ primaryAction,
9825
+ secondaryAction
9826
+ };
9827
+ setAlerts(prevState => {
9828
+ return [...prevState, Object.assign({}, queue)];
9829
+ });
9830
+ return id;
9831
+ }
9832
+ const removeMessage = id => {
9833
+ setAlerts(prev => {
9834
+ return prev.map(a => {
9835
+ return a.id === id ? Object.assign(Object.assign({}, a), {
9836
+ open: false
9837
+ }) : a;
9838
+ });
9839
+ });
9840
+ };
9841
+ const DotSnackbarValues = {
9842
+ alerts,
9843
+ enqueueMessage,
9844
+ removeMessage
9845
+ };
9846
+ const memoizedValues = useMemo(() => DotSnackbarValues, [alerts]);
9847
+ return jsxs(DotSnackbarContext.Provider, {
9848
+ value: memoizedValues,
9849
+ children: [jsx(DotSnackbarContainer, {
9850
+ hideOnClickAway: hideOnClickAway
9851
+ }), children]
9852
+ });
9853
+ };
9854
+ const useDotSnackbarContext = () => {
9855
+ return useContext(DotSnackbarContext);
9856
+ };
9857
+ const useEnqueueErrorMessage = error => {
9858
+ const {
9859
+ enqueueMessage
9860
+ } = useDotSnackbarContext();
9861
+ useEffect(() => {
9862
+ error && enqueueMessage(getErrorText(error), 'error');
9863
+ }, [error]);
9864
+ };
9865
+
9866
+ const rootClassName$D = 'dot-dashboard-details';
9867
+ const StyledDashboardDetails = styled(DotDrawer)`
9868
+ ${({
9869
+ theme
9870
+ }) => css`
9871
+ &.${rootClassName$D} {
9872
+ .dot-drawer-paper {
9873
+ padding: 0;
9874
+ width: 382px;
9875
+ }
9876
+ .dot-card {
9877
+ border: none;
9878
+ padding: ${theme.spacing(0, 2)};
9879
+
9880
+ .dot-card-header {
9881
+ padding: ${theme.spacing(2, 1, 0, 0)};
9882
+ }
9883
+ .dot-card-content {
9884
+ padding: ${theme.spacing(0, 0, 3, 0)};
9885
+ }
9886
+ }
9887
+ .content {
9888
+ overflow-y: auto;
9889
+ }
9890
+ .dot-avatar {
9891
+ flex-basis: 40px;
9892
+ }
9893
+ .section-title {
9894
+ display: flex;
9895
+ align-items: center;
9896
+ padding: ${theme.spacing(2)};
9897
+ }
9898
+ .section-title-border {
9899
+ margin: ${theme.spacing(1, -2, 0)};
9900
+ border-bottom: 1px solid ${theme.palette.figma.border.default};
9901
+ }
9902
+ .dot-icon {
9903
+ flex-basis: content;
9904
+ }
9905
+ .field-value {
9906
+ margin-top: ${theme.spacing(2)};
9907
+ .dashboard-details-label {
9908
+ margin-bottom: ${theme.spacing(0.5)};
9909
+ }
9910
+ }
9911
+ .dashboard-details-header {
9912
+ align-items: end;
9913
+ border-bottom: 1px solid ${theme.palette.figma.border.default};
9914
+ display: flex;
9915
+ justify-content: space-between;
9916
+ padding: ${theme.spacing(0, 2, 1, 2)};
9917
+
9918
+ .dashboard-details-header-title {
9919
+ display: flex;
9920
+ align-items: center;
9921
+ gap: ${theme.spacing(2)};
9922
+ }
9923
+ }
9924
+ }
9925
+ `}
9926
+ `;
9927
+
9928
+ const DashboardDetailsField = ({
9929
+ children,
9930
+ className,
9931
+ label,
9932
+ value
9933
+ }) => {
9934
+ let c = 'field-value';
9935
+ if (className) {
9936
+ c += ` ${className}`;
9937
+ }
9938
+ return jsxs("div", {
9939
+ className: c,
9940
+ children: [jsx(DotTypography, {
9941
+ ariaRole: "heading",
9942
+ className: "dashboard-details-label",
9943
+ component: "h4",
9944
+ variant: "h4",
9945
+ children: label
9946
+ }), value && jsx(DotTypography, {
9947
+ className: "dashboard-details-value",
9948
+ children: value
9949
+ }), children]
9950
+ });
9951
+ };
9952
+ const DashboardDetailsSectionHeading = ({
9953
+ className,
9954
+ label
9955
+ }) => {
9956
+ let c = 'section-title';
9957
+ if (className) {
9958
+ c += ` ${className}`;
9959
+ }
9960
+ return jsx("div", {
9961
+ className: "section-title-border",
9962
+ children: jsx(DotTypography, {
9963
+ ariaRole: "heading",
9964
+ ariaLevel: 2,
9965
+ className: c,
9966
+ component: "div",
9967
+ variant: "body1",
9968
+ children: label
9969
+ })
9970
+ });
9971
+ };
9972
+ const DotDashboardDetailsView = ({
9973
+ className,
9974
+ dashboard,
9975
+ onClose,
9976
+ onFavorite,
9977
+ open,
9978
+ yOffset = 56,
9979
+ zIndex = 990
9980
+ }) => {
9981
+ var _a, _b;
9982
+ const rootClasses = useStylesWithRootClass(rootClassName$D, className);
9983
+ const closeHandler = useCallback(event => {
9984
+ onClose && onClose(event);
9985
+ }, [onClose]);
9986
+ const favoriteHandler = useCallback(() => {
9987
+ const favoriteValue = !dashboard.favorite;
9988
+ onFavorite && onFavorite(dashboard.id, favoriteValue);
9989
+ }, [dashboard]);
9990
+ const header = useMemo(() => ({
9991
+ className: 'dashboard-details-header',
9992
+ children: jsxs("div", {
9993
+ "aria-level": 1,
9994
+ className: "dashboard-details-header-title",
9995
+ role: "heading",
9996
+ style: {
9997
+ marginTop: yOffset + 'px',
9998
+ width: '80%'
9999
+ },
10000
+ children: [jsx(DotAvatar, {
10001
+ iconId: "file-lines",
10002
+ alt: "dashboard details image",
10003
+ type: "image",
10004
+ variant: "circular"
10005
+ }), jsx(DotTypography, {
10006
+ ariaRole: "heading",
10007
+ ariaLevel: 1,
10008
+ className: "dashboard-details-label",
10009
+ children: "Details"
10010
+ })]
10011
+ })
10012
+ }), [yOffset]);
10013
+ return jsx(StyledDashboardDetails, {
10014
+ ariaLabel: "Dashboard details",
10015
+ ariaRole: "dialog",
10016
+ "aria-modal": "true",
10017
+ className: rootClasses,
10018
+ drawerHeaderProps: header,
10019
+ ModalProps: {
10020
+ style: {
10021
+ zIndex
10022
+ }
10023
+ },
10024
+ open: open,
10025
+ onClose: closeHandler,
10026
+ width: "340px",
10027
+ variant: "temporary",
10028
+ children: jsx("div", {
10029
+ className: "content",
10030
+ role: "contentinfo",
10031
+ children: jsxs(DotCard, {
10032
+ "data-testid": "dashboard-details-card",
10033
+ children: [jsx(DotCardHeader, {
10034
+ action: jsx("div", {
10035
+ children: jsx(DotIconButton, {
10036
+ iconId: `star-favorites-${dashboard.favorite ? 'active' : 'default'}`,
10037
+ "data-testid": `dashboard-favorite-icon-${dashboard.id}`,
10038
+ tooltip: dashboard.favorite ? 'Remove from favorites' : 'Add to favorites',
10039
+ onClick: favoriteHandler
10040
+ })
10041
+ }),
10042
+ avatar: jsx(DotAvatar, {
10043
+ alt: "dashboard avatar",
10044
+ iconId: dashboard.is_ootb_dashboard ? 'lock' : 'dashboard',
10045
+ type: "icon"
10046
+ }),
10047
+ title: dashboard.name,
10048
+ subheader: `by ${dashboard.is_ootb_dashboard ? 'Digital.ai' : dashboard.author_fullname}`
10049
+ }), jsxs(DotCardContent, {
10050
+ children: [jsx(DashboardDetailsSectionHeading, {
10051
+ label: "GENERAL"
10052
+ }), jsx(DashboardDetailsField, {
10053
+ className: "dashboard-details-description",
10054
+ label: "Description",
10055
+ value: dashboard.description
10056
+ }), jsx(DashboardDetailsField, {
10057
+ className: "dashboard-details-author",
10058
+ label: "Created by",
10059
+ value: dashboard.author_fullname
10060
+ }), jsx(DashboardDetailsField, {
10061
+ className: "dashboard-details-status",
10062
+ label: "Status",
10063
+ children: jsx(DotDashboardStatusPill, {
10064
+ status: dashboard.lifecycle_state
10065
+ })
10066
+ }), jsx(DashboardDetailsField, {
10067
+ className: "dashboard-details-category",
10068
+ label: "Category",
10069
+ children: jsx(DotChipList, {
10070
+ items: (_a = dashboard.categories) === null || _a === void 0 ? void 0 : _a.map(c => ({
10071
+ key: c,
10072
+ label: c
10073
+ })),
10074
+ maxChars: 30
10075
+ })
10076
+ }), ((_b = dashboard.external_object) === null || _b === void 0 ? void 0 : _b.page_count) && jsxs(Fragment, {
10077
+ children: [jsx(DashboardDetailsSectionHeading, {
10078
+ label: "DASHBOARD PAGE SUMMARY"
10079
+ }), jsx(DashboardDetailsField, {
10080
+ className: "dashboard-details-pages",
10081
+ label: "Pages",
10082
+ value: dashboard.external_object.page_count
10083
+ })]
10084
+ }), jsx(DashboardDetailsSectionHeading, {
10085
+ label: "ADDITIONAL DETAILS"
10086
+ }), jsx(DashboardDetailsField, {
10087
+ className: "dashboard-details-created-dt",
10088
+ label: "Created on",
10089
+ value: dashboard.created_dt
10090
+ }), dashboard.updated_dt && jsx(DashboardDetailsField, {
10091
+ className: "dashboard-details-updated-dt",
10092
+ label: "Modified on",
10093
+ value: dashboard.updated_dt
10094
+ }), dashboard.updated_by_fullname && jsx(DashboardDetailsField, {
10095
+ className: "dashboard-details-updated-by",
10096
+ label: "Modified by",
10097
+ value: dashboard.updated_by_fullname
10098
+ })]
10099
+ })]
10100
+ })
10101
+ })
10102
+ });
10103
+ };
10104
+ const DotDashboardDetails = _a => {
10105
+ var {
10106
+ dashboard,
10107
+ onClose,
10108
+ onFavorite
10109
+ } = _a,
10110
+ commonProps = __rest(_a, ["dashboard", "onClose", "onFavorite"]);
10111
+ const [_openedDashboard, _setOpenedDashboard] = useState(dashboard);
10112
+ const metadataApiContext = useDotMetadataApiContext();
10113
+ const {
10114
+ openedDashboardDetails: openedDashboard,
10115
+ setOpenedDashboardDetails: setOpenedDashboard
10116
+ } = metadataApiContext ? metadataApiContext : {
10117
+ openedDashboardDetails: _openedDashboard,
10118
+ setOpenedDashboardDetails: _setOpenedDashboard
10119
+ };
10120
+ const {
10121
+ dashboardsError,
10122
+ favoriteDashboard,
10123
+ setOpenedDashboardDetails
10124
+ } = useDotMetadataApiContext();
10125
+ const {
10126
+ enqueueMessage
10127
+ } = useDotSnackbarContext();
10128
+ useEnqueueErrorMessage(dashboardsError);
10129
+ const closeHandler = useCallback(event => {
10130
+ setOpenedDashboard(null);
10131
+ onClose && onClose(event);
10132
+ }, [onClose]);
10133
+ const favoriteHandler = useCallback((dashboardId, favoriteValue) => {
10134
+ // being optimistic; if the api call fails, there will be an error message
10135
+ enqueueMessage(`Dashboard has been ${favoriteValue ? '' : 'un-'}favorited.`, 'success');
10136
+ onFavorite && onFavorite(dashboardId, favoriteValue);
10137
+ setOpenedDashboardDetails(Object.assign(Object.assign({}, openedDashboard), {
10138
+ favorite: favoriteValue
10139
+ }));
10140
+ favoriteDashboard(openedDashboard.id, favoriteValue).then(response => {
10141
+ setOpenedDashboardDetails(response);
10142
+ });
10143
+ }, [openedDashboard]);
10144
+ const viewProps = Object.assign({}, commonProps);
10145
+ if (openedDashboard) {
10146
+ return jsx(DotDashboardDetailsView, Object.assign({}, viewProps, {
10147
+ dashboard: openedDashboard,
10148
+ open: true,
10149
+ onFavorite: favoriteHandler,
10150
+ onClose: closeHandler
10151
+ }));
10152
+ }
10153
+ return null;
10154
+ };
10155
+
10156
+ const DotInputSelect = ({
10157
+ ariaLabel,
10158
+ autoFocus,
10159
+ className,
10160
+ 'data-pendoid': dataPendoId = rootSelectClassName,
10161
+ 'data-testid': dataTestId,
10162
+ defaultValue,
10163
+ disabled = false,
10164
+ endIcon,
10165
+ endText,
10166
+ error = false,
10167
+ fullWidth = true,
10168
+ helperText,
10169
+ id,
10170
+ inputRef,
10171
+ label,
10172
+ name,
10173
+ onBlur,
10174
+ onChange,
10175
+ onFocus,
10176
+ onKeyDown,
10177
+ options = [],
10178
+ persistentLabel,
10179
+ readOnly = false,
10180
+ required,
10181
+ shrink,
10182
+ size = 'small',
10183
+ startIcon,
10184
+ success,
10185
+ value,
10186
+ warning = false
10187
+ }) => {
10188
+ const hasWarning = !error && warning && warningClassName;
10189
+ const hasSuccess = !error && !warning && success && successClassName;
10190
+ const endAdornment = endIcon || endText;
10191
+ const inputStyles = useStylesWithRootClass('dot-select', readOnly && readOnlyClassName$1);
10192
+ const rootStyles = useStylesWithRootClass(rootSelectClassName, hasSuccess, hasWarning);
10193
+ const getOption = option => {
10194
+ return typeof option === 'string' ? option : option.option;
10195
+ };
10196
+ const getValue = option => {
10197
+ return typeof option === 'string' ? option : (option === null || option === void 0 ? void 0 : option.value) || option.option;
10198
+ };
10199
+ return jsxs("div", {
10200
+ className: className,
10201
+ children: [persistentLabel && jsx(DotInputLabel, {
10202
+ disabled,
10203
+ error,
10204
+ id,
10205
+ label,
10206
+ required
10207
+ }), jsx(StyledTextField, {
10208
+ InputProps: {
10209
+ startAdornment: startIcon && jsx(StyledAdornment, {
10210
+ className: `${adornmentIconClassName} start`,
10211
+ position: "start",
10212
+ children: startIcon
10213
+ }),
10214
+ endAdornment: endAdornment && jsx(StyledAdornment, {
10215
+ className: `${adornmentIconClassName} end`,
10216
+ position: "end",
10217
+ children: endAdornment
10218
+ })
10219
+ },
10220
+ SelectProps: {
10221
+ native: !readOnly,
10222
+ readOnly,
10223
+ open: readOnly ? false : undefined
10224
+ },
10225
+ "aria-label": ariaLabel || label,
10226
+ autoFocus: autoFocus,
10227
+ className: rootStyles,
10228
+ defaultValue: defaultValue,
10229
+ disabled: disabled,
10230
+ error: error,
10231
+ fullWidth: fullWidth,
10232
+ helperText: helperText,
10233
+ id: id,
10234
+ InputLabelProps: {
10235
+ shrink: shrink
10236
+ },
10237
+ inputProps: {
10238
+ 'aria-label': ariaLabel,
10239
+ 'data-pendoid': dataPendoId,
10240
+ 'data-testid': dataTestId,
10241
+ className: inputStyles,
10242
+ readOnly
10243
+ },
10244
+ inputRef: inputRef,
10245
+ label: persistentLabel ? null : label,
10246
+ multiline: false,
10247
+ name: name,
10248
+ onBlur: onBlur,
10249
+ onChange: onChange,
10250
+ onFocus: onFocus,
10251
+ onKeyDown: onKeyDown,
10252
+ required: required,
10253
+ role: "textbox",
10254
+ select: true,
10255
+ size: size,
10256
+ value: value,
10257
+ variant: "outlined",
10258
+ children: options.map(option => jsx("option", {
10259
+ className: "dot-option",
10260
+ value: getValue(option),
10261
+ children: getOption(option)
10262
+ }, getValue(option)))
10263
+ })]
10264
+ });
10265
+ };
10266
+
10267
+ const StyledDashboardDialog = styled(DotDialog)`
10268
+ ${({
10269
+ theme
10270
+ }) => css`
10271
+ .dot-text-field {
10272
+ margin-bottom: ${theme.spacing(2)};
10273
+ width: 40vw;
10274
+ }
10275
+ .dot-autocomplete {
10276
+ margin-top: ${theme.spacing(1.5)};
10277
+ }
10278
+ .dot-input-select {
10279
+ margin-bottom: ${theme.spacing(2)};
10280
+ }
10281
+ `}
10282
+ `;
10283
+ const StyledDialogActions = styled(DialogActions)`
10284
+ padding-right: 0;
10285
+ `;
10286
+
10287
+ const DashboardAppTypeOptions = [
10288
+ // Matches target_app values in Dashboard model
10289
+ {
10290
+ option: 'Agility',
10291
+ value: 'AGILITY'
10292
+ }, {
10293
+ option: 'Release',
10294
+ value: 'RELEASE'
10295
+ }, {
10296
+ option: 'Deploy',
10297
+ value: 'DEPLOY'
10298
+ }, {
10299
+ option: 'Continuous Testing',
10300
+ value: 'CONTINUOUSTEST'
10301
+ }, {
10302
+ option: 'TeamForge',
10303
+ value: 'TEAMFORGE'
10304
+ }];
10305
+ const initialFormState = {
10306
+ categories: [],
10307
+ description: '',
10308
+ name: ''
10309
+ };
10310
+ const DASHBOARD_NAME_MAX_LENGTH = 250;
10311
+ const DASHBOARD_DESCRIPTION_MAX_LENGTH = 250;
10312
+ function DotDashboardDialog({
10313
+ availableCategories,
10314
+ copyDashboard,
10315
+ editDashboard,
10316
+ open,
10317
+ onClose,
10318
+ onSubmit,
10319
+ onContinue,
10320
+ title
10321
+ }) {
10322
+ const [isDirty, setIsDirty] = useState(false);
10323
+ const [isLoadingSubmit, setIsLoadingSubmit] = useState(false);
10324
+ const [nameError, setNameError] = useState(null);
10325
+ const [formValues, setFormValues] = useState(initialFormState);
10326
+ const {
10327
+ categories,
10328
+ description,
10329
+ name
10330
+ } = formValues;
10331
+ const {
10332
+ searchDashboards
10333
+ } = useDotMetadataApiContext();
10334
+ const {
9527
10335
  cancelablePromise
9528
10336
  } = useCancelablePromise();
9529
10337
  useEffect(() => {
@@ -9707,277 +10515,18 @@ function DotDashboardDialog({
9707
10515
  disabled: isLoadingSubmit || !isDirty,
9708
10516
  onClick: handleSubmitEditExit,
9709
10517
  type: "outlined",
9710
- children: "Save and exit"
9711
- }), jsx(DotButton, {
9712
- "data-testid": "save-edit-continue-dashboard-button",
9713
- disabled: isLoadingSubmit,
9714
- onClick: handleSubmitEditContinue,
9715
- type: "primary",
9716
- children: isDirty ? 'Save and continue' : 'Continue'
9717
- })]
9718
- })
9719
- })]
9720
- });
9721
- }
9722
-
9723
- const getSnackbarTitleFromSeverity = severity => {
9724
- switch (severity) {
9725
- case 'success':
9726
- return 'Success';
9727
- case 'warning':
9728
- return 'Warning';
9729
- case 'error':
9730
- return 'Error';
9731
- case 'info':
9732
- return 'Info';
9733
- default:
9734
- return 'Success';
9735
- }
9736
- };
9737
- function getErrorText(error) {
9738
- var _a, _b;
9739
- if ('status' in error && error.status === 304) {
9740
- return 'No changes made';
9741
- } else if ('body' in error) {
9742
- return ((_b = (_a = error.body) === null || _a === void 0 ? void 0 : _a.error) === null || _b === void 0 ? void 0 : _b.message) ? error.body.error.message : 'Unexpected API error';
9743
- } else if ('message' in error) {
9744
- return error.message;
9745
- }
9746
- return 'Unexpected API error';
9747
- }
9748
-
9749
- function addAutoHideDuration(severity) {
9750
- return severity === 'error' ? null : 10000;
9751
- }
9752
-
9753
- const rootClassName$F = 'dot-snackbar';
9754
- const StyledSnackbar = styled(Snackbar)`
9755
- ${({
9756
- theme,
9757
- width,
9758
- $anchorOriginTop
9759
- }) => css`
9760
- &.${rootClassName$F} {
9761
- .MuiAlert-message {
9762
- word-break: break-word;
9763
- }
9764
- .${rootClassName$1c} {
9765
- align-items: flex-start;
9766
- }
9767
- &.MuiSnackbar-anchorOriginTopLeft,
9768
- &.MuiSnackbar-anchorOriginTopCenter,
9769
- &.MuiSnackbar-anchorOriginTopRight {
9770
- top: ${$anchorOriginTop}px;
9771
- z-index: ${levelFourth};
9772
- }
9773
-
9774
- .dot-snackbar-actions {
9775
- display: flex;
9776
- align-items: center;
9777
- margin-top: ${theme.spacing(1)};
9778
- gap: ${theme.spacing(2)};
9779
-
9780
- .primary-action-btn {
9781
- background-color: transparent;
9782
- }
9783
- }
9784
-
9785
- .MuiAlert-root {
9786
- max-width: ${width ? 'unset' : '500px'};
9787
- min-width: ${width ? 'unset' : '344px'};
9788
- z-index: ${levelFourth};
9789
- }
9790
- }
9791
- `}
9792
- `;
9793
-
9794
- const DEFAULT_ANCHOR_ORIGIN = {
9795
- vertical: 'top',
9796
- horizontal: 'right'
9797
- };
9798
- const DotSnackbar = ({
9799
- anchorOrigin = DEFAULT_ANCHOR_ORIGIN,
9800
- anchorOriginTop = 108,
9801
- ariaLabel,
9802
- autoHideDuration,
9803
- children,
9804
- className,
9805
- 'data-testid': dataTestId,
9806
- hideOnClickAway = true,
9807
- onClose,
9808
- open,
9809
- primaryAction,
9810
- secondaryAction,
9811
- severity,
9812
- width
9813
- }) => {
9814
- const hasActions = !!(primaryAction || secondaryAction);
9815
- const calculatedAutoHideDuration = autoHideDuration === null || autoHideDuration > 0 ? autoHideDuration : addAutoHideDuration(severity);
9816
- const rootClasses = useStylesWithRootClass(rootClassName$F, className);
9817
- const handleSnackbarClose = reason => {
9818
- if (!reason || hideOnClickAway || !hideOnClickAway && reason !== 'clickaway') {
9819
- onClose();
9820
- }
9821
- };
9822
- return jsx(StyledSnackbar, {
9823
- anchorOrigin: anchorOrigin,
9824
- "$anchorOriginTop": anchorOriginTop,
9825
- "aria-label": ariaLabel,
9826
- autoHideDuration: calculatedAutoHideDuration,
9827
- classes: {
9828
- root: rootClasses
9829
- },
9830
- "data-testid": dataTestId,
9831
- onClose: (_e, r) => handleSnackbarClose(r),
9832
- open: open,
9833
- severity: severity,
9834
- width: width,
9835
- children: jsx("div", {
9836
- children: jsx(DotAlertBanner, {
9837
- severity: severity,
9838
- width: width,
9839
- onClose: _e => handleSnackbarClose(),
9840
- children: jsxs("div", {
9841
- children: [jsx(DotTypography, {
9842
- variant: "subtitle2",
9843
- noMarginBottom: false,
9844
- children: getSnackbarTitleFromSeverity(severity)
9845
- }), isString$2(children) ? jsx(DotTypography, {
9846
- ariaLabel: severity,
9847
- variant: "body1",
9848
- children: children
9849
- }) : jsx("span", {
9850
- "aria-label": severity,
9851
- children: children
9852
- }), hasActions && jsxs("div", {
9853
- className: "dot-snackbar-actions",
9854
- children: [primaryAction && jsx(DotButton, {
9855
- className: "primary-action-btn",
9856
- "data-testid": "primary-action-btn",
9857
- onClick: primaryAction.onClick,
9858
- size: "small",
9859
- type: "outlined",
9860
- children: primaryAction.label
9861
- }), secondaryAction && jsx(DotLink, {
9862
- "data-testid": "secondary-action-link",
9863
- href: secondaryAction.href,
9864
- color: "inherit",
9865
- children: secondaryAction.label
9866
- })]
9867
- })]
9868
- })
9869
- })
9870
- })
9871
- });
9872
- };
9873
-
9874
- const rootClassName$E = 'dot-snackbar-container';
9875
- const StyledSnackbarContainer = styled.div`
9876
- ${() => css`
9877
- &.${rootClassName$E} {
9878
- position: absolute;
9879
- top: 0;
9880
- width: 250px;
9881
- height: auto;
9882
- right: 0;
9883
- & > div {
9884
- position: relative;
9885
- }
9886
- }
9887
- `}
9888
- `;
9889
-
9890
- const DotSnackbarContext = createContext({
9891
- alerts: [],
9892
- enqueueMessage: (_message, _severity, _autoHideDuration, _primaryAction, _secondaryAction) => null,
9893
- removeMessage: _id => null
9894
- });
9895
- const DotSnackbarContainer = ({
9896
- hideOnClickAway
9897
- }) => {
9898
- const {
9899
- alerts,
9900
- removeMessage
9901
- } = useDotSnackbarContext();
9902
- function handleClose(id) {
9903
- return () => {
9904
- removeMessage(id);
9905
- };
9906
- }
9907
- return jsx(StyledSnackbarContainer, {
9908
- className: rootClassName$E,
9909
- children: jsx("div", {
9910
- className: rootClassName$E,
9911
- "data-testid": rootClassName$E,
9912
- children: alerts.slice().reverse().map(alert => {
9913
- return jsx(DotSnackbar, {
9914
- autoHideDuration: alert.autoHideDuration,
9915
- hideOnClickAway: hideOnClickAway,
9916
- onClose: handleClose(alert.id),
9917
- open: alert.open,
9918
- severity: alert.severity,
9919
- primaryAction: alert.primaryAction,
9920
- secondaryAction: alert.secondaryAction,
9921
- children: alert.message
9922
- }, alert.id);
10518
+ children: "Save and exit"
10519
+ }), jsx(DotButton, {
10520
+ "data-testid": "save-edit-continue-dashboard-button",
10521
+ disabled: isLoadingSubmit,
10522
+ onClick: handleSubmitEditContinue,
10523
+ type: "primary",
10524
+ children: isDirty ? 'Save and continue' : 'Continue'
10525
+ })]
9923
10526
  })
9924
- })
9925
- });
9926
- };
9927
- const DotSnackbarProvider = ({
9928
- children,
9929
- hideOnClickAway = true
9930
- }) => {
9931
- const [alerts, setAlerts] = useState([]);
9932
- function enqueueMessage(message, severity, autoHideDuration, primaryAction, secondaryAction) {
9933
- const id = CreateUUID();
9934
- const queue = {
9935
- id,
9936
- message,
9937
- severity,
9938
- open: true,
9939
- autoHideDuration,
9940
- primaryAction,
9941
- secondaryAction
9942
- };
9943
- setAlerts(prevState => {
9944
- return [...prevState, Object.assign({}, queue)];
9945
- });
9946
- return id;
9947
- }
9948
- const removeMessage = id => {
9949
- setAlerts(prev => {
9950
- return prev.map(a => {
9951
- return a.id === id ? Object.assign(Object.assign({}, a), {
9952
- open: false
9953
- }) : a;
9954
- });
9955
- });
9956
- };
9957
- const DotSnackbarValues = {
9958
- alerts,
9959
- enqueueMessage,
9960
- removeMessage
9961
- };
9962
- const memoizedValues = useMemo(() => DotSnackbarValues, [alerts]);
9963
- return jsxs(DotSnackbarContext.Provider, {
9964
- value: memoizedValues,
9965
- children: [jsx(DotSnackbarContainer, {
9966
- hideOnClickAway: hideOnClickAway
9967
- }), children]
10527
+ })]
9968
10528
  });
9969
- };
9970
- const useDotSnackbarContext = () => {
9971
- return useContext(DotSnackbarContext);
9972
- };
9973
- const useEnqueueErrorMessage = error => {
9974
- const {
9975
- enqueueMessage
9976
- } = useDotSnackbarContext();
9977
- useEffect(() => {
9978
- error && enqueueMessage(getErrorText(error), 'error');
9979
- }, [error]);
9980
- };
10529
+ }
9981
10530
 
9982
10531
  const InlineMessage = styled(DotTypography)`
9983
10532
  ${({
@@ -10374,8 +10923,14 @@ function DotDashboardPublishConfirm({
10374
10923
  }
10375
10924
 
10376
10925
  const StyledDotMenu = styled(DotMenu)`
10377
- ${() => css`
10926
+ ${({
10927
+ theme
10928
+ }) => css`
10378
10929
  z-index: 9999;
10930
+
10931
+ .dot-link .dot-icon {
10932
+ margin-right: ${theme.spacing(1)};
10933
+ }
10379
10934
  `}
10380
10935
  `;
10381
10936
 
@@ -10384,7 +10939,8 @@ function DotDashboardOptionsMenu({
10384
10939
  isEdit = false,
10385
10940
  onStartDuplicate,
10386
10941
  onStartStatusChange,
10387
- onViewMode
10942
+ onViewMode,
10943
+ onDetails
10388
10944
  }) {
10389
10945
  const [anchorEl, setAnchorEl] = useState(null);
10390
10946
  const [open, setOpen] = useState(false);
@@ -10458,6 +11014,21 @@ function DotDashboardOptionsMenu({
10458
11014
  onclick: handleDuplicateClick
10459
11015
  });
10460
11016
  }
11017
+ if (onDetails) {
11018
+ menuItems.push({
11019
+ children: jsxs(DotLink, {
11020
+ ariaLabel: "Dashboard details",
11021
+ color: "inherit",
11022
+ onClick: () => onDetails(dashboard),
11023
+ underline: "none",
11024
+ children: [jsx(DotIcon, {
11025
+ iconId: "file-lines"
11026
+ }), " Details"]
11027
+ }),
11028
+ key: 'dashboard-details',
11029
+ onClick: () => onDetails(dashboard)
11030
+ });
11031
+ }
10461
11032
  return menuItems.length > 0 ? jsxs(Fragment, {
10462
11033
  children: [jsx(DotIconButton, {
10463
11034
  className: "expand-button",
@@ -10564,7 +11135,8 @@ function DotDashboardActions({
10564
11135
  onFavorite,
10565
11136
  onStatusChanged,
10566
11137
  onDuplicated,
10567
- onViewMode
11138
+ onViewMode,
11139
+ onDetails
10568
11140
  }) {
10569
11141
  // NOTE: useState functions need to stay at the top of the file so that
10570
11142
  // they are evaluated before any context imports. If they are evaluated
@@ -10573,7 +11145,8 @@ function DotDashboardActions({
10573
11145
  const [dashboardToPublish, setDashboardToPublish] = useState(null);
10574
11146
  const [dashboardToUnpublish, setDashboardToUnpublish] = useState(null);
10575
11147
  const {
10576
- duplicateDashboard
11148
+ duplicateDashboard,
11149
+ setOpenedDashboardDetails
10577
11150
  } = useDotMetadataApiContext();
10578
11151
  const handlePublishConfirm = useCallback(publishedDashboard => {
10579
11152
  setDashboardToPublish(null);
@@ -10635,7 +11208,8 @@ function DotDashboardActions({
10635
11208
  isEdit: isEdit,
10636
11209
  onViewMode: onViewMode,
10637
11210
  onStartStatusChange: handleStartStatusChangeIfConfig,
10638
- onStartDuplicate: handleStartDuplicateIfConfig
11211
+ onStartDuplicate: handleStartDuplicateIfConfig,
11212
+ onDetails: () => setOpenedDashboardDetails(dashboard)
10639
11213
  }), jsx(CloseButton, {
10640
11214
  dashboard: dashboard,
10641
11215
  onClose: onClose
@@ -10703,7 +11277,7 @@ function DotDashboardHeader({
10703
11277
  });
10704
11278
  }
10705
11279
 
10706
- const rootClassName$D = 'dot-empty-state';
11280
+ const rootClassName$C = 'dot-empty-state';
10707
11281
  const StyledEmptyState = styled.div`
10708
11282
  ${({
10709
11283
  theme
@@ -10738,9 +11312,9 @@ const StyledEmptyState = styled.div`
10738
11312
  `}
10739
11313
  `;
10740
11314
 
10741
- const rootClassName$C = 'dot-illustration';
11315
+ const rootClassName$B = 'dot-illustration';
10742
11316
  const StyledIllustration = styled.span`
10743
- &.${rootClassName$C} {
11317
+ &.${rootClassName$B} {
10744
11318
  display: inline-block;
10745
11319
  }
10746
11320
  `;
@@ -10757,16 +11331,16 @@ const DotIllustration = ({
10757
11331
  tooltip,
10758
11332
  tooltipPlacement = 'right-end'
10759
11333
  }) => {
10760
- const rootClasses = useStylesWithRootClass(rootClassName$C, className);
11334
+ const rootClasses = useStylesWithRootClass(rootClassName$B, className);
10761
11335
  return jsx(DotTooltip, {
10762
11336
  title: tooltip,
10763
11337
  placement: tooltipPlacement,
10764
- "data-testid": `${dataTestId || rootClassName$C}-tooltip`,
11338
+ "data-testid": `${dataTestId || rootClassName$B}-tooltip`,
10765
11339
  children: jsx(StyledIllustration, {
10766
11340
  "aria-hidden": "false",
10767
11341
  "aria-label": ariaLabel || title || 'Illustration',
10768
11342
  className: rootClasses,
10769
- "data-testid": dataTestId || rootClassName$C,
11343
+ "data-testid": dataTestId || rootClassName$B,
10770
11344
  role: ariaRole,
10771
11345
  children: jsx("img", {
10772
11346
  alt: alt || 'Illustration',
@@ -10791,7 +11365,7 @@ const DotEmptyState = ({
10791
11365
  subtitle,
10792
11366
  title
10793
11367
  }) => {
10794
- const rootClasses = useStylesWithRootClass(rootClassName$D, className);
11368
+ const rootClasses = useStylesWithRootClass(rootClassName$C, className);
10795
11369
  return jsxs(StyledEmptyState, {
10796
11370
  "aria-label": ariaLabel,
10797
11371
  className: rootClasses,
@@ -10872,20 +11446,20 @@ const StyledRadioGroup = styled(RadioGroup)`
10872
11446
  &.${groupClassName} {
10873
11447
  padding-left: ${theme.spacing(2.5)};
10874
11448
 
10875
- .${rootClassName$M} {
11449
+ .${rootClassName$O} {
10876
11450
  margin: 0;
10877
11451
  }
10878
11452
  }
10879
11453
  `}
10880
11454
  `;
10881
11455
 
10882
- const rootClassName$B = 'dot-date-picker';
11456
+ const rootClassName$A = 'dot-date-picker';
10883
11457
  const popperClassName = 'dot-date-picker-popper';
10884
11458
  const containerClassName$2 = 'dot-date-picker-container';
10885
11459
  const rectanglePickersDayClassName = 'dot-rectangle-pickers-day';
10886
11460
  const StyledDatePickerContainer = styled.div`
10887
11461
  ${() => css`
10888
- &.${rootClassName$B} .full-width {
11462
+ &.${rootClassName$A} .full-width {
10889
11463
  width: 100%;
10890
11464
  }
10891
11465
  `}
@@ -10894,7 +11468,7 @@ const StyledDatePicker = styled(DatePicker)`
10894
11468
  ${({
10895
11469
  theme
10896
11470
  }) => css`
10897
- &.${rootClassName$B} {
11471
+ &.${rootClassName$A} {
10898
11472
  ${pickerInputStyles(theme)};
10899
11473
 
10900
11474
  .Mui-disabled.MuiInputBase-root,
@@ -10934,7 +11508,7 @@ const StyledPickersDay = styled(PickersDay)`
10934
11508
  `}
10935
11509
  `;
10936
11510
 
10937
- const rootClassName$A = 'dot-time-picker';
11511
+ const rootClassName$z = 'dot-time-picker';
10938
11512
  const containerClassName$1 = 'dot-time-picker-container';
10939
11513
  const TIME_SELECTION_HEIGHT_SPACING = 34.5;
10940
11514
  const TIME_SELECTION_WIDTH_SPACING = 14.5;
@@ -11005,7 +11579,7 @@ const StyledTimePicker = styled(TimePicker)`
11005
11579
  ${({
11006
11580
  theme
11007
11581
  }) => css`
11008
- &.${rootClassName$A} {
11582
+ &.${rootClassName$z} {
11009
11583
  ${pickerInputStyles(theme)};
11010
11584
 
11011
11585
  .Mui-disabled.MuiInputBase-root,
@@ -11024,36 +11598,36 @@ const StyledTimePicker = styled(TimePicker)`
11024
11598
  `}
11025
11599
  `;
11026
11600
 
11027
- const rootClassName$z = 'dot-form';
11601
+ const rootClassName$y = 'dot-form';
11028
11602
  const StyledFormContainer = styled.div`
11029
11603
  ${({
11030
11604
  theme
11031
11605
  }) => css`
11032
- &.${rootClassName$z} {
11606
+ &.${rootClassName$y} {
11033
11607
  margin: ${theme.spacing(3, 0)};
11034
11608
 
11035
- .${rootClassName$K},
11036
- .${rootClassName$M},
11037
- .${rootClassName$1e},
11609
+ .${rootClassName$M},
11610
+ .${rootClassName$O},
11611
+ .${rootClassName$1g},
11038
11612
  .${rootSelectClassName},
11039
- .${rootClassName$B},
11040
- .${rootClassName$A} {
11613
+ .${rootClassName$A},
11614
+ .${rootClassName$z} {
11041
11615
  margin: ${theme.spacing(1, 0)};
11042
11616
  }
11043
11617
 
11044
11618
  label
11045
- + .${rootClassName$1e},
11619
+ + .${rootClassName$1g},
11046
11620
  label
11047
11621
  + .${rootSelectClassName},
11048
11622
  label
11049
- + .${rootClassName$B},
11623
+ + .${rootClassName$A},
11050
11624
  label
11051
- + .${rootClassName$A} {
11625
+ + .${rootClassName$z} {
11052
11626
  margin: ${theme.spacing(0, 0, 1, 0)};
11053
11627
  }
11054
11628
 
11055
- .${rootClassName$J}, .${groupClassName} {
11056
- .${rootClassName$M} {
11629
+ .${rootClassName$L}, .${groupClassName} {
11630
+ .${rootClassName$O} {
11057
11631
  margin: 0;
11058
11632
  }
11059
11633
  }
@@ -11068,7 +11642,7 @@ const DotForm = ({
11068
11642
  'data-testid': dataTestId,
11069
11643
  onSubmit
11070
11644
  }) => {
11071
- const rootClasses = useStylesWithRootClass(rootClassName$z, className);
11645
+ const rootClasses = useStylesWithRootClass(rootClassName$y, className);
11072
11646
  return jsx("form", {
11073
11647
  "aria-label": ariaLabel,
11074
11648
  "data-testid": dataTestId,
@@ -11081,10 +11655,10 @@ const DotForm = ({
11081
11655
  });
11082
11656
  };
11083
11657
 
11084
- const rootClassName$y = 'dot-dynamic-form';
11658
+ const rootClassName$x = 'dot-dynamic-form';
11085
11659
  const StyledDynamicForm = styled(DotForm)`
11086
11660
  ${() => css`
11087
- &.${rootClassName$y} {
11661
+ &.${rootClassName$x} {
11088
11662
  }
11089
11663
  `}
11090
11664
  `;
@@ -11264,12 +11838,12 @@ const checkIfFormDataValid = formState => {
11264
11838
  return true;
11265
11839
  };
11266
11840
 
11267
- const rootClassName$x = 'dot-progress-button';
11841
+ const rootClassName$w = 'dot-progress-button';
11268
11842
  const StyledProgressButton = styled(DotButton)`
11269
11843
  ${({
11270
11844
  theme
11271
11845
  }) => css`
11272
- &.${rootClassName$x} {
11846
+ &.${rootClassName$w} {
11273
11847
  .hidden {
11274
11848
  // hide children but preserve its space so that
11275
11849
  // button's dimensions don't change
@@ -11294,7 +11868,7 @@ const DotProgressButton = ({
11294
11868
  ariaLabel,
11295
11869
  children,
11296
11870
  className,
11297
- 'data-pendoid': dataPendoId = rootClassName$x,
11871
+ 'data-pendoid': dataPendoId = rootClassName$w,
11298
11872
  'data-testid': dataTestId,
11299
11873
  disabled = false,
11300
11874
  disableRipple = false,
@@ -11307,7 +11881,7 @@ const DotProgressButton = ({
11307
11881
  tooltip,
11308
11882
  type = 'primary'
11309
11883
  }) => {
11310
- const rootClasses = useStylesWithRootClass(rootClassName$x, className);
11884
+ const rootClasses = useStylesWithRootClass(rootClassName$w, className);
11311
11885
  const isButtonDisabled = disabled || isLoading;
11312
11886
  const titleClasses = useStylesWithRootClass(isLoading ? 'hidden' : '');
11313
11887
  const progressCircleSize = size === 'large' ? SPINNER_LARGE_SIZE : SPINNER_DEFAULT_SIZE;
@@ -11336,12 +11910,12 @@ const DotProgressButton = ({
11336
11910
  });
11337
11911
  };
11338
11912
 
11339
- const rootClassName$w = 'dot-radio';
11913
+ const rootClassName$v = 'dot-radio';
11340
11914
  const StyledRadioButton = styled(Radio)`
11341
11915
  ${({
11342
11916
  theme
11343
11917
  }) => css`
11344
- &.${rootClassName$w} {
11918
+ &.${rootClassName$v} {
11345
11919
  padding: 8px;
11346
11920
 
11347
11921
  svg {
@@ -11359,7 +11933,7 @@ function DotRadioButton({
11359
11933
  ariaLabel,
11360
11934
  checked,
11361
11935
  className,
11362
- 'data-pendoid': dataPendoId = rootClassName$M,
11936
+ 'data-pendoid': dataPendoId = rootClassName$O,
11363
11937
  'data-testid': dataTestId,
11364
11938
  disabled,
11365
11939
  id,
@@ -11372,7 +11946,7 @@ function DotRadioButton({
11372
11946
  size = 'medium',
11373
11947
  value
11374
11948
  }) {
11375
- const rootClasses = useStylesWithRootClass(rootClassName$M, className);
11949
+ const rootClasses = useStylesWithRootClass(rootClassName$O, className);
11376
11950
  const handleChange = event => {
11377
11951
  onChange && onChange(event, event.target.value);
11378
11952
  };
@@ -11380,7 +11954,7 @@ function DotRadioButton({
11380
11954
  const radioControl = jsx(StyledRadioButton, {
11381
11955
  checked: checked,
11382
11956
  classes: {
11383
- root: rootClassName$w
11957
+ root: rootClassName$v
11384
11958
  },
11385
11959
  color: "primary",
11386
11960
  "data-pendoid": dataPendoId,
@@ -11426,7 +12000,7 @@ const DotRadioGroup = ({
11426
12000
  size = 'medium'
11427
12001
  }) => {
11428
12002
  const placement = `${placementClassName}${labelPlacement}`;
11429
- const rootClasses = useStylesWithRootClass(rootClassName$K, className, placement);
12003
+ const rootClasses = useStylesWithRootClass(rootClassName$M, className, placement);
11430
12004
  const radioValue = value || defaultValue;
11431
12005
  const [selectedValue, setSelectedValue] = useState(radioValue);
11432
12006
  /* This will ensure that value can be updated from the outside */
@@ -11491,7 +12065,7 @@ const DotRadioGroup = ({
11491
12065
  });
11492
12066
  };
11493
12067
 
11494
- const rootClassName$v = 'dot-switch';
12068
+ const rootClassName$u = 'dot-switch';
11495
12069
  const StyledSwitch = styled(Switch)`
11496
12070
  ${({
11497
12071
  theme
@@ -11520,7 +12094,7 @@ const DotSwitch = ({
11520
12094
  checked,
11521
12095
  className,
11522
12096
  color,
11523
- 'data-pendoid': dataPendoId = rootClassName$v,
12097
+ 'data-pendoid': dataPendoId = rootClassName$u,
11524
12098
  'data-testid': dataTestId,
11525
12099
  disabled = false,
11526
12100
  id,
@@ -11530,7 +12104,7 @@ const DotSwitch = ({
11530
12104
  onChange,
11531
12105
  size = 'medium'
11532
12106
  }) => {
11533
- const rootClasses = useStylesWithRootClass(rootClassName$v, className);
12107
+ const rootClasses = useStylesWithRootClass(rootClassName$u, className);
11534
12108
  const handleChange = event => {
11535
12109
  onChange && onChange(event);
11536
12110
  };
@@ -11560,7 +12134,7 @@ const DotSwitch = ({
11560
12134
  tabIndex: 0
11561
12135
  });
11562
12136
  return jsx(StyledFormControlLabel, {
11563
- className: rootClassName$M,
12137
+ className: rootClassName$O,
11564
12138
  control: switchControl,
11565
12139
  label: label,
11566
12140
  labelPlacement: labelPlacement
@@ -11881,7 +12455,7 @@ const DotDynamicForm = ({
11881
12455
  onChange,
11882
12456
  onSubmit
11883
12457
  }) => {
11884
- const rootClasses = useStylesWithRootClass(rootClassName$y, className);
12458
+ const rootClasses = useStylesWithRootClass(rootClassName$x, className);
11885
12459
  // Memoize this operation so that is doesn't get executed each time this
11886
12460
  // component re-renders
11887
12461
  const initialFormState = useMemo(() => getInitialFormState(config, liveValidation), [config, liveValidation, getInitialFormState]);
@@ -12127,7 +12701,7 @@ const DotDynamicForm = ({
12127
12701
  });
12128
12702
  };
12129
12703
 
12130
- const rootClassName$u = 'dot-inline-edit';
12704
+ const rootClassName$t = 'dot-inline-edit';
12131
12705
  const editModeClassName = 'dot-edit-mode';
12132
12706
  const viewModeClassName = 'dot-view-mode';
12133
12707
  const placeholderClassName = 'dot-placeholder';
@@ -12139,7 +12713,7 @@ const StyledInlineEdit = styled.div`
12139
12713
  theme,
12140
12714
  fullWidth
12141
12715
  }) => css`
12142
- &.${rootClassName$u} {
12716
+ &.${rootClassName$t} {
12143
12717
  align-items: center;
12144
12718
  color: ${theme.palette.figma.typography.black};
12145
12719
  display: ${fullWidth ? 'flex' : 'inline-flex'};
@@ -12351,7 +12925,7 @@ const DotInlineEdit = ({
12351
12925
  bindings,
12352
12926
  charactersLimit,
12353
12927
  className,
12354
- 'data-pendoid': dataPendoId = rootClassName$u,
12928
+ 'data-pendoid': dataPendoId = rootClassName$t,
12355
12929
  'data-testid': dataTestId,
12356
12930
  fullWidth = true,
12357
12931
  hideActionButtons,
@@ -12384,7 +12958,7 @@ const DotInlineEdit = ({
12384
12958
  }
12385
12959
  }, [value]);
12386
12960
  const isSaveDisabled = checkIfEmptyValue(inputValue);
12387
- const rootClasses = useStylesWithRootClass(rootClassName$u, className, editing ? editModeClassName : '');
12961
+ const rootClasses = useStylesWithRootClass(rootClassName$t, className, editing ? editModeClassName : '');
12388
12962
  const handleShowTooltip = visible => {
12389
12963
  if (!editing) {
12390
12964
  setShowTooltip(visible);
@@ -12563,13 +13137,13 @@ const DotInlineEdit = ({
12563
13137
  });
12564
13138
  };
12565
13139
 
12566
- const rootClassName$t = 'dot-navigation-rail';
13140
+ const rootClassName$s = 'dot-navigation-rail';
12567
13141
  const StyledNavigationRail = styled.div`
12568
13142
  ${({
12569
13143
  theme,
12570
13144
  railItemPosition
12571
13145
  }) => css`
12572
- &.${rootClassName$t} {
13146
+ &.${rootClassName$s} {
12573
13147
  background: ${theme.palette.figma.neutral.elevated};
12574
13148
  border-left: 1px solid ${theme.palette.figma.border.default};
12575
13149
  display: flex;
@@ -12616,7 +13190,7 @@ const DotNavigationRail = ({
12616
13190
  railItems,
12617
13191
  selectedIndex = 0
12618
13192
  }) => {
12619
- const rootClasses = useStylesWithRootClass(rootClassName$t, className);
13193
+ const rootClasses = useStylesWithRootClass(rootClassName$s, className);
12620
13194
  const [selectedItemIndex, setSelectedItemIndex] = useState(selectedIndex);
12621
13195
  /* Used to change selected index programmatically from the consumer component */
12622
13196
  useEffect(() => {
@@ -12667,154 +13241,6 @@ const DotNavigationRail = ({
12667
13241
  });
12668
13242
  };
12669
13243
 
12670
- const rootClassName$s = 'dot-pill';
12671
- const StyledPill = styled(Chip)`
12672
- ${({
12673
- theme
12674
- }) => css`
12675
- &.${rootClassName$s} {
12676
- background-color: ${({
12677
- backgroundcolor,
12678
- variant
12679
- }) => {
12680
- const defaultBackground = variant === 'filled' ? theme.palette.grey[200] : theme.palette.grey[50];
12681
- return backgroundcolor !== null && backgroundcolor !== void 0 ? backgroundcolor : defaultBackground;
12682
- }};
12683
- border-color: ${({
12684
- bordercolor
12685
- }) => {
12686
- return bordercolor ? bordercolor : theme.palette.grey[200];
12687
- }};
12688
- color: ${({
12689
- labelcolor
12690
- }) => {
12691
- return labelcolor ? labelcolor : theme.palette.layer.n700;
12692
- }};
12693
- .dot-icon {
12694
- color: ${({
12695
- labelcolor
12696
- }) => {
12697
- return labelcolor ? labelcolor : theme.palette.grey.main;
12698
- }};
12699
- margin: ${theme.spacing(0, -0.5, 0, 1)};
12700
- }
12701
-
12702
- &.MuiChip-sizeSmall .dot-icon {
12703
- margin-left: 5px;
12704
- }
12705
-
12706
- &.MuiChip-outlined {
12707
- &.error {
12708
- background-color: ${theme.palette.error[50]};
12709
- border-color: ${theme.palette.error.main};
12710
- color: ${theme.palette.layer.n700};
12711
- .dot-icon {
12712
- color: ${theme.palette.error.main};
12713
- }
12714
- }
12715
-
12716
- &.success {
12717
- background-color: ${theme.palette.figma.success.light};
12718
- border-color: ${theme.palette.figma.success.normal};
12719
- color: ${theme.palette.layer.n700};
12720
- .dot-icon {
12721
- color: ${theme.palette.success.main};
12722
- }
12723
- }
12724
-
12725
- &.warning {
12726
- background-color: ${theme.palette.figma.warning.light};
12727
- border-color: ${theme.palette.figma.warning.normal};
12728
- color: ${theme.palette.layer.n700};
12729
- .dot-icon {
12730
- color: ${theme.palette.warning.main};
12731
- }
12732
- }
12733
-
12734
- &.in-progress {
12735
- background-color: ${theme.palette.figma.primary.light};
12736
- border-color: ${theme.palette.figma.primary.normal};
12737
- color: ${theme.palette.layer.n700};
12738
- .dot-icon {
12739
- color: ${theme.palette.primary.main};
12740
- }
12741
- }
12742
- }
12743
-
12744
- &.MuiChip-filled {
12745
- &.error {
12746
- background-color: ${theme.palette.error.main};
12747
- border-color: ${theme.palette.error.main};
12748
- color: ${theme.palette.layer.n0};
12749
- .dot-icon {
12750
- color: ${theme.palette.layer.n0};
12751
- }
12752
- }
12753
-
12754
- &.success {
12755
- background-color: ${theme.palette.success.main};
12756
- border-color: ${theme.palette.success.main};
12757
- color: ${theme.palette.layer.n0};
12758
- .dot-icon {
12759
- color: ${theme.palette.layer.n0};
12760
- }
12761
- }
12762
-
12763
- &.warning {
12764
- background-color: ${theme.palette.warning.main};
12765
- border-color: ${theme.palette.warning.main};
12766
- color: ${theme.palette.layer.n700};
12767
- .dot-icon {
12768
- color: ${theme.palette.layer.n700};
12769
- }
12770
- }
12771
-
12772
- &.in-progress {
12773
- background-color: ${theme.palette.primary.main};
12774
- border-color: ${theme.palette.primary.main};
12775
- color: ${theme.palette.layer.n0};
12776
- .dot-icon {
12777
- color: ${theme.palette.layer.n0};
12778
- }
12779
- }
12780
- }
12781
- }
12782
- `}
12783
- `;
12784
-
12785
- const DotPill = ({
12786
- ariaLabel,
12787
- backgroundcolor,
12788
- bordercolor,
12789
- className,
12790
- 'data-testid': dataTestId,
12791
- icon,
12792
- label,
12793
- labelcolor,
12794
- onClick,
12795
- size = 'medium',
12796
- status = 'default',
12797
- variant = 'filled'
12798
- }) => {
12799
- const rootClasses = useStylesWithRootClass(rootClassName$s, className, status);
12800
- return jsx(StyledPill, {
12801
- "aria-label": ariaLabel,
12802
- bordercolor: bordercolor,
12803
- backgroundcolor: backgroundcolor,
12804
- classes: {
12805
- root: rootClasses
12806
- },
12807
- clickable: !!onClick,
12808
- "data-testid": dataTestId,
12809
- icon: icon,
12810
- label: label,
12811
- labelcolor: labelcolor,
12812
- onClick: onClick,
12813
- size: size,
12814
- variant: variant
12815
- });
12816
- };
12817
-
12818
13244
  const rootClassName$r = 'dot-skeleton';
12819
13245
  const StyledSkeleton = styled(Skeleton)`
12820
13246
  ${({
@@ -15759,7 +16185,7 @@ const DotPopper = ({
15759
16185
  open,
15760
16186
  placement
15761
16187
  }) => {
15762
- const rootClasses = useStylesWithRootClass(rootClassName$16, className);
16188
+ const rootClasses = useStylesWithRootClass(rootClassName$18, className);
15763
16189
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
15764
16190
  const handleClickAway = event => {
15765
16191
  if (onClickAway && (!anchorEl || !anchorEl.contains(event.currentTarget))) {
@@ -15999,7 +16425,7 @@ const DotDatePicker = ({
15999
16425
  autoFocus = false,
16000
16426
  className,
16001
16427
  closeOnSelect = true,
16002
- 'data-pendoid': dataPendoId = rootClassName$B,
16428
+ 'data-pendoid': dataPendoId = rootClassName$A,
16003
16429
  'data-testid': dataTestId,
16004
16430
  defaultValue,
16005
16431
  disableOpenPicker,
@@ -16039,7 +16465,7 @@ const DotDatePicker = ({
16039
16465
  const hasBothValueAndDefaultValue = value !== undefined && defaultValue !== undefined;
16040
16466
  const isInputReadOnly = readOnly || hasValueWithoutChangeHandler || hasBothValueAndDefaultValue;
16041
16467
  const inputRef = useRef(null);
16042
- const rootClasses = useStylesWithRootClass(rootClassName$B, className, isInputReadOnly ? 'read-only' : '');
16468
+ const rootClasses = useStylesWithRootClass(rootClassName$A, className, isInputReadOnly ? 'read-only' : '');
16043
16469
  const containerClasses = useStylesWithRootClass(containerClassName$2, fullWidth ? 'full-width' : '', className);
16044
16470
  const focusInput = ref => {
16045
16471
  setTimeout(() => {
@@ -16258,7 +16684,7 @@ const DotTimePicker = ({
16258
16684
  ariaLabel,
16259
16685
  autoFocus = false,
16260
16686
  className,
16261
- 'data-pendoid': dataPendoId = rootClassName$A,
16687
+ 'data-pendoid': dataPendoId = rootClassName$z,
16262
16688
  'data-testid': dataTestId,
16263
16689
  defaultValue,
16264
16690
  disableOpenPicker = false,
@@ -16290,7 +16716,7 @@ const DotTimePicker = ({
16290
16716
  const hasValueWithoutChangeHandler = value !== undefined && onChange === undefined;
16291
16717
  const hasBothValueAndDefaultValue = value !== undefined && defaultValue !== undefined;
16292
16718
  const isComponentReadOnly = readOnly || hasValueWithoutChangeHandler || hasBothValueAndDefaultValue;
16293
- const rootClasses = useStylesWithRootClass(rootClassName$A, className, isComponentReadOnly ? 'read-only' : '');
16719
+ const rootClasses = useStylesWithRootClass(rootClassName$z, className, isComponentReadOnly ? 'read-only' : '');
16294
16720
  const containerClasses = useStylesWithRootClass(containerClassName$1, fullWidth ? 'full-width' : '', className);
16295
16721
  const inputRef = useRef(null);
16296
16722
  const [isPickerOpened, setIsPickerOpened] = useState(false);
@@ -17389,4 +17815,4 @@ const BoardColumnSummary = ({
17389
17815
  });
17390
17816
  };
17391
17817
 
17392
- export { ApiError$1 as ApiError, BoardStatusProvider, Cell, ColumnStatusProvider, CreateUUID, CssCell, CssGrid, CssGridDebug, DashboardAppTypeOptions, DatePickerKeydownContext, Daytime, DotAccordion, DotActionToolbar, DotAlertBanner, DotAppLogo, DotAppSwitcher, DotAppToolbar, DotAutoComplete, DotAvatar, DotAvatarGroup, DotBadge, Board as DotBoard, BoardColumn as DotBoardColumn, BoardColumnActionBar as DotBoardColumnActionBar, BoardColumnCollapse as DotBoardColumnCollapse, BoardColumnExpand as DotBoardColumnExpand, BoardColumnHeader as DotBoardColumnHeader, BoardColumnItems as DotBoardColumnItems, BoardColumnSummary as DotBoardColumnSummary, DotBreadcrumbs, DotButton, DotButtonToggle, DotCard, DotCardContent, DotCardFooter, DotCardHeader, DotCarousel, DotCheckbox, DotCheckboxGroup, DotChip, DotClickAwayListener, DotConfirmationDialog, DotCopyButton, DotCoreApiProvider, DotDashboardActions, DotDashboardDialog, DotDashboardHeader, DotDashboardOptionsMenu, DotDashboardPublishConfirm, DotDatePicker, DotDialog, DotDivider, DotDraggableList, DotDrawer, DotDynamicForm, DotEmptyFilterState, DotEmptyState, DotFileListItem, DotFileUpload, DotForm, DotFormGroup, DotHeaderRow, DotIcon, DotIconButton, DotIllustration, DotInlineEdit, DotInputSelect, DotInputText, DotLinearProgress, DotLink, DotList, DotMenu, DotMetadataApiProvider, DotNavigationRail, DotPill, DotPopper, DotProgress, DotProgressButton, DotRadioButton, DotRadioGroup, DotSidebar, DotSkeleton, DotSnackbar, DotSnackbarContainer, DotSnackbarProvider, DotSplitButton, DotStepper, DotStickyWithBorder, DotSwitch, DotTable, DotTableAction, DotTableActions, DotTablePagination, DotTabs, DotThemeProvider, DotTimePicker, DotTooltip, DotTruncateWithTooltip, DotTypography, avatarColors, breakpointOptions, checkIfValidDate, darkFigmaColors, lightThemeColors as lightColors, lightFigmaColors, mockScrollIntoView, parseAutoCompleteValue, variables as themeVariables, typographyOptions, useBoardStatus, useColumnStatus, useDotCoreApiContext, useDotMetadataApiContext, useDotSnackbarContext, useEnqueueErrorMessage };
17818
+ export { ApiError$1 as ApiError, BoardStatusProvider, Cell, ColumnStatusProvider, CreateUUID, CssCell, CssGrid, CssGridDebug, DashboardAppTypeOptions, DatePickerKeydownContext, Daytime, DotAccordion, DotActionToolbar, DotAlertBanner, DotAppLogo, DotAppSwitcher, DotAppToolbar, DotAutoComplete, DotAvatar, DotAvatarGroup, DotBadge, Board as DotBoard, BoardColumn as DotBoardColumn, BoardColumnActionBar as DotBoardColumnActionBar, BoardColumnCollapse as DotBoardColumnCollapse, BoardColumnExpand as DotBoardColumnExpand, BoardColumnHeader as DotBoardColumnHeader, BoardColumnItems as DotBoardColumnItems, BoardColumnSummary as DotBoardColumnSummary, DotBreadcrumbs, DotButton, DotButtonToggle, DotCard, DotCardContent, DotCardFooter, DotCardHeader, DotCarousel, DotCheckbox, DotCheckboxGroup, DotChip, DotChipList, DotClickAwayListener, DotConfirmationDialog, DotCopyButton, DotCoreApiProvider, DotDashboardActions, DotDashboardDetails, DotDashboardDialog, DotDashboardHeader, DotDashboardOptionsMenu, DotDashboardPublishConfirm, DotDashboardStatusPill, DotDatePicker, DotDialog, DotDivider, DotDraggableList, DotDrawer, DotDynamicForm, DotEmptyFilterState, DotEmptyState, DotFileListItem, DotFileUpload, DotForm, DotFormGroup, DotHeaderRow, DotIcon, DotIconButton, DotIllustration, DotInlineEdit, DotInputSelect, DotInputText, DotLinearProgress, DotLink, DotList, DotMenu, DotMetadataApiProvider, DotNavigationRail, DotPill, DotPopper, DotProgress, DotProgressButton, DotRadioButton, DotRadioGroup, DotSidebar, DotSkeleton, DotSnackbar, DotSnackbarContainer, DotSnackbarProvider, DotSplitButton, DotStepper, DotStickyWithBorder, DotSwitch, DotTable, DotTableAction, DotTableActions, DotTablePagination, DotTabs, DotThemeProvider, DotTimePicker, DotTooltip, DotTruncateWithTooltip, DotTypography, avatarColors, breakpointOptions, checkIfValidDate, darkFigmaColors, lightThemeColors as lightColors, lightFigmaColors, mockScrollIntoView, parseAutoCompleteValue, variables as themeVariables, typographyOptions, useBoardStatus, useColumnStatus, useDotCoreApiContext, useDotMetadataApiContext, useDotSnackbarContext, useEnqueueErrorMessage };