@digital-ai/dot-components 3.12.0 → 3.13.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$1i = 'dot-icon';
107
+ const rootClassName$1j = 'dot-icon';
108
108
  const StyledIcon = styled(Icon)`
109
109
  ${({
110
110
  theme
111
111
  }) => css`
112
- &.${rootClassName$1i} {
112
+ &.${rootClassName$1j} {
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$1i, className);
149
+ const rootClasses = useStylesWithRootClass(rootClassName$1j, 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$1h = 'dot-accordion';
210
+ const rootClassName$1i = '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$1h} .${summaryClassName} {
221
+ &.${rootClassName$1i} .${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$1h,
266
+ 'data-pendoid': dataPendoId = rootClassName$1i,
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$1h, className);
277
+ const rootClasses = useStylesWithRootClass(rootClassName$1i, 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$1g = 'dot-text-field';
393
+ const rootClassName$1h = '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$1g} {
441
+ &.${rootClassName$1h} {
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$1g} {
485
+ &.${rootSelectClassName}, &.${rootClassName$1h} {
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$1f = 'dot-action-toolbar';
576
+ const rootClassName$1g = 'dot-action-toolbar';
577
577
  const StyledToolbar = styled(Toolbar)`
578
578
  ${({
579
579
  theme
580
580
  }) => css`
581
- &.${rootClassName$1f} {
581
+ &.${rootClassName$1g} {
582
582
  border-bottom: 1px solid ${theme.palette.figma.border.default};
583
583
 
584
- .${rootClassName$1g} .MuiInputBase-root {
584
+ .${rootClassName$1h} .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$1f, className);
598
+ const rootClasses = useStylesWithRootClass(rootClassName$1g, 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$1e = 'dot-alert-banner';
1668
+ const rootClassName$1f = 'dot-alert-banner';
1669
1669
  const StyledAlertBanner = styled(Alert)`
1670
1670
  ${({
1671
1671
  theme
1672
1672
  }) => css`
1673
- &.${rootClassName$1e} {
1673
+ &.${rootClassName$1f} {
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$1e,
1708
+ 'data-pendoid': dataPendoId = rootClassName$1f,
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$1e, severity, className);
1716
+ const rootClasses = useStylesWithRootClass(rootClassName$1f, 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$1d = 'dot-avatar';
2394
+ const rootClassName$1e = '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$1d} {
2404
+ &.${rootClassName$1e} {
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$1d, className);
2516
+ const rootClasses = useStylesWithRootClass(rootClassName$1e, 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$1c = 'dot-button';
2555
+ const rootClassName$1d = 'dot-button';
2556
2556
  const StyledButton = styled(Button)`
2557
2557
  ${({
2558
2558
  theme
2559
2559
  }) => css`
2560
- &.${rootClassName$1c} {
2560
+ &.${rootClassName$1d} {
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$1c,
2644
+ 'data-pendoid': dataPendoId = rootClassName$1d,
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$1c, className);
2660
+ const rootClasses = useStylesWithRootClass(rootClassName$1d, 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$1c}-tooltip`,
2684
+ "data-testid": `${dataTestId || rootClassName$1d}-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$1c,
2693
+ "data-testid": dataTestId || rootClassName$1d,
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$1b = 'dot-link';
2712
+ const rootClassName$1c = 'dot-link';
2713
2713
  const StyledLink = styled(Link)`
2714
2714
  ${() => css`
2715
- &.${rootClassName$1b} {
2715
+ &.${rootClassName$1c} {
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$1b,
2731
+ 'data-pendoid': dataPendoId = rootClassName$1c,
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$1b, className);
2743
+ const rootClasses = useStylesWithRootClass(rootClassName$1c, 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$1a = 'dot-list';
2793
+ const rootClassName$1b = '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$1a} {
2801
+ &.${rootClassName$1b} {
2802
2802
  background: ${theme.palette.figma.background.level0.componentsBackground};
2803
2803
 
2804
2804
  .dot-icon {
@@ -2810,13 +2810,13 @@ const StyledList = styled(List)`
2810
2810
  }
2811
2811
 
2812
2812
  .MuiCollapse-root {
2813
- padding-top: ${theme.spacing(1)};
2814
- margin-bottom: ${theme.spacing(-1)};
2813
+ &.${nestedListClassName} .${listItemRootClass} {
2814
+ padding-left: ${theme.spacing(6)};
2815
+ padding-right: ${theme.spacing(2)};
2816
+ }
2815
2817
 
2816
2818
  .MuiCollapse-wrapper {
2817
- margin: ${theme.spacing(0, 2)};
2818
2819
  overflow: hidden;
2819
- width: calc(100% - ${theme.spacing(4)});
2820
2820
  }
2821
2821
 
2822
2822
  .MuiListSubheader-root .MuiTypography-root {
@@ -2881,12 +2881,12 @@ const DotListDivider = ({
2881
2881
  });
2882
2882
  };
2883
2883
 
2884
- const rootClassName$19 = 'dot-progress';
2884
+ const rootClassName$1a = 'dot-progress';
2885
2885
  const StyledProgress = styled.div`
2886
2886
  ${({
2887
2887
  theme
2888
2888
  }) => css`
2889
- &.${rootClassName$19} {
2889
+ &.${rootClassName$1a} {
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$19, className);
2940
+ const rootClasses = useStylesWithRootClass(rootClassName$1a, 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,112 @@ var variables = /*#__PURE__*/Object.freeze({
3003
3003
  levelTop: levelTop
3004
3004
  });
3005
3005
 
3006
- const rootClassName$18 = 'dot-popper';
3006
+ const rootClassName$19 = 'dot-popper';
3007
+ const arrowClassName = 'MuiPopper-arrow';
3007
3008
  const StyledPopper$1 = styled(Popper)`
3008
3009
  ${({
3009
3010
  theme
3010
3011
  }) => css`
3011
- &.${rootClassName$18} {
3012
+ &.${rootClassName$19} {
3012
3013
  font-family: ${theme.typography.fontFamily};
3013
3014
  font-size: ${theme.typography.body1.fontSize}px;
3015
+
3016
+ &[data-popper-placement='top'],
3017
+ &[data-popper-placement='top-start'],
3018
+ &[data-popper-placement='top-end'] {
3019
+ .${arrowClassName} {
3020
+ bottom: 0;
3021
+ left: 0;
3022
+ margin-bottom: -10px;
3023
+ &::before {
3024
+ transform-origin: 100% 0;
3025
+ }
3026
+ }
3027
+ }
3028
+
3029
+ &[data-popper-placement='right'],
3030
+ &[data-popper-placement='right-start'],
3031
+ &[data-popper-placement='right-end'] {
3032
+ .${arrowClassName} {
3033
+ left: 0;
3034
+ margin-left: -10px;
3035
+ height: 14px;
3036
+ width: 10px;
3037
+ &::before {
3038
+ transform-origin: 100% 100%;
3039
+ }
3040
+ }
3041
+ }
3042
+
3043
+ &[data-popper-placement='bottom'],
3044
+ &[data-popper-placement='bottom-start'],
3045
+ &[data-popper-placement='bottom-end'] {
3046
+ .${arrowClassName} {
3047
+ top: 0;
3048
+ left: 0;
3049
+ margin-top: -10px;
3050
+ &::before {
3051
+ transform-origin: 0 100%;
3052
+ }
3053
+ }
3054
+ }
3055
+
3056
+ &[data-popper-placement='left'],
3057
+ &[data-popper-placement='left-start'],
3058
+ &[data-popper-placement='left-end'] {
3059
+ .${arrowClassName} {
3060
+ right: 0;
3061
+ margin-right: -10px;
3062
+ height: 14px;
3063
+ width: 10px;
3064
+ &::before {
3065
+ transform-origin: 0 0;
3066
+ }
3067
+ }
3068
+ }
3014
3069
  }
3015
3070
 
3016
- &.${rootClassName$18}, &.${rootClassName$18} > .dot-popper-paper {
3071
+ &.${rootClassName$19}, &.${rootClassName$19} > .dot-popper-paper {
3017
3072
  background-color: ${theme.palette.figma.background.level1.white};
3018
3073
  }
3019
3074
  `}
3020
3075
  `;
3076
+ const StyledArrow = styled('span')`
3077
+ ${({
3078
+ theme
3079
+ }) => css`
3080
+ &.${arrowClassName} {
3081
+ overflow: hidden;
3082
+ position: absolute;
3083
+ width: 14px;
3084
+ height: 10px;
3085
+ box-sizing: border-box;
3086
+ &::before {
3087
+ content: '';
3088
+ margin: auto;
3089
+ display: block;
3090
+ width: 100%;
3091
+ height: 100%;
3092
+ background-color: ${theme.palette.figma.background.level1.white};
3093
+ box-shadow: ${theme.shadows[1]};
3094
+ transform: rotate(45deg);
3095
+ }
3096
+ }
3097
+ `}
3098
+ `;
3021
3099
 
3022
3100
  const flyoutMenuClassName = 'dot-flyout-menu';
3023
- const rootClassName$17 = 'dot-menu';
3101
+ const rootClassName$18 = 'dot-menu';
3024
3102
  const StyledPopper = styled(Popper)`
3025
3103
  ${({
3026
3104
  theme
3027
3105
  }) => css`
3028
- &.${rootClassName$18} {
3106
+ &.${rootClassName$19} {
3029
3107
  font-family: ${theme.typography.fontFamily};
3030
3108
  font-size: ${theme.typography.body1.fontSize}px;
3031
3109
  z-index: ${levelSecond};
3032
3110
  }
3033
- &.${rootClassName$17}, &.${rootClassName$18} {
3111
+ &.${rootClassName$18}, &.${rootClassName$19} {
3034
3112
  .MuiPaper-root {
3035
3113
  border: 1px solid ${theme.palette.layer.n100};
3036
3114
  }
@@ -3110,14 +3188,14 @@ const MENU_ITEM_HEIGHT_NORMAL = 48;
3110
3188
  const MENU_ITEM_HEIGHT_DENSE = 36;
3111
3189
  const DEFAULT_MAX_VISIBLE_ITEMS = 7;
3112
3190
 
3113
- const rootClassName$16 = 'dot-ul';
3191
+ const rootClassName$17 = 'dot-ul';
3114
3192
  const listItemClassName$1 = 'dot-li';
3115
3193
  const listItemWithSubmenuClassName = 'dot-li-with-submenu';
3116
3194
  const StyledMenuList = styled(MenuList)`
3117
3195
  ${({
3118
3196
  theme
3119
3197
  }) => css`
3120
- &.${rootClassName$16} {
3198
+ &.${rootClassName$17} {
3121
3199
  background: ${theme.palette.figma.background.level1.white};
3122
3200
 
3123
3201
  .dot-li {
@@ -3213,7 +3291,7 @@ const DotMenuList = forwardRef(({
3213
3291
  onSubMenuCreate,
3214
3292
  selectedKey
3215
3293
  }, ref) => {
3216
- const rootClasses = useStylesWithRootClass(rootClassName$16, className);
3294
+ const rootClasses = useStylesWithRootClass(rootClassName$17, className);
3217
3295
  const [activeSubmenu, setActiveSubmenu] = useState(null);
3218
3296
  const [subItemAnchorEl, setSubItemAnchorEl] = useState(null);
3219
3297
  const openSubmenu = (target, itemKey) => {
@@ -3324,7 +3402,7 @@ const DotMenu = ({
3324
3402
  open = false,
3325
3403
  selectedKey
3326
3404
  }) => {
3327
- const rootClasses = useStylesWithRootClass(rootClassName$17, className, loading ? 'loading' : '');
3405
+ const rootClasses = useStylesWithRootClass(rootClassName$18, className, loading ? 'loading' : '');
3328
3406
  const isSubmenu = checkIfSubmenu(anchorEl);
3329
3407
  const hasSubItems = checkForSubItems(menuItems);
3330
3408
  // Timeout object is customizable when Menu component is either submenu
@@ -3412,12 +3490,12 @@ const DotMenu = ({
3412
3490
  });
3413
3491
  };
3414
3492
 
3415
- const rootClassName$15 = 'dot-drawer';
3493
+ const rootClassName$16 = 'dot-drawer';
3416
3494
  const StyledDrawer = styled(Drawer)`
3417
3495
  ${({
3418
3496
  theme
3419
3497
  }) => css`
3420
- &.${rootClassName$15} .MuiBackdrop-root {
3498
+ &.${rootClassName$16} .MuiBackdrop-root {
3421
3499
  background-color: ${theme.palette.figma.overlay.default};
3422
3500
  }
3423
3501
 
@@ -3436,12 +3514,12 @@ const StyledDrawer = styled(Drawer)`
3436
3514
  `}
3437
3515
  `;
3438
3516
 
3439
- const rootClassName$14 = 'dot-drawer-header';
3517
+ const rootClassName$15 = 'dot-drawer-header';
3440
3518
  const StyleDrawerHeader = styled.div`
3441
3519
  ${({
3442
3520
  theme
3443
3521
  }) => css`
3444
- &.${rootClassName$14} {
3522
+ &.${rootClassName$15} {
3445
3523
  padding: ${theme.spacing(0, 0, 2)};
3446
3524
  display: flex;
3447
3525
  align-items: center;
@@ -3452,13 +3530,13 @@ const StyleDrawerHeader = styled.div`
3452
3530
  `}
3453
3531
  `;
3454
3532
 
3455
- const rootClassName$13 = 'dot-icon-btn';
3533
+ const rootClassName$14 = 'dot-icon-btn';
3456
3534
  const StyledIconButton = styled(IconButton)`
3457
3535
  ${({
3458
3536
  theme,
3459
3537
  color
3460
3538
  }) => css`
3461
- &.${rootClassName$13} {
3539
+ &.${rootClassName$14} {
3462
3540
  ${color === 'inherit' ? css`
3463
3541
  color: inherit;
3464
3542
  ` : ''}
@@ -3517,7 +3595,7 @@ const DotIconButton = ({
3517
3595
  ariaRole = 'button',
3518
3596
  className,
3519
3597
  color = 'inherit',
3520
- 'data-pendoid': dataPendoId = rootClassName$13,
3598
+ 'data-pendoid': dataPendoId = rootClassName$14,
3521
3599
  'data-testid': dataTestId,
3522
3600
  disableRipple = false,
3523
3601
  disabled = false,
@@ -3530,7 +3608,7 @@ const DotIconButton = ({
3530
3608
  tooltipPlacement
3531
3609
  }) => {
3532
3610
  const rippleClassName = disableRipple ? 'ripple-disabled' : '';
3533
- const rootClasses = useStylesWithRootClass(rootClassName$13, rippleClassName, `shape-${shape}`, className);
3611
+ const rootClasses = useStylesWithRootClass(rootClassName$14, rippleClassName, `shape-${shape}`, className);
3534
3612
  return jsx(DotTooltip, {
3535
3613
  "data-testid": "icon-button-tooltip",
3536
3614
  placement: tooltipPlacement,
@@ -3565,7 +3643,7 @@ const DotDrawerHeader = ({
3565
3643
  onClose,
3566
3644
  variant
3567
3645
  }) => {
3568
- const rootClasses = useStylesWithRootClass(rootClassName$14, className);
3646
+ const rootClasses = useStylesWithRootClass(rootClassName$15, className);
3569
3647
  return jsxs(StyleDrawerHeader, {
3570
3648
  "aria-label": ariaLabel,
3571
3649
  "aria-level": 2,
@@ -3582,10 +3660,10 @@ const DotDrawerHeader = ({
3582
3660
  });
3583
3661
  };
3584
3662
 
3585
- const rootClassName$12 = 'dot-drawer-body';
3663
+ const rootClassName$13 = 'dot-drawer-body';
3586
3664
  const StyleDrawerBody = styled.div`
3587
3665
  ${() => css`
3588
- &.${rootClassName$12} {
3666
+ &.${rootClassName$13} {
3589
3667
  display: flex;
3590
3668
  .dot-drawer-close-button {
3591
3669
  align-self: self-start;
@@ -3606,7 +3684,7 @@ const DotDrawerBody = ({
3606
3684
  onClose,
3607
3685
  variant
3608
3686
  }) => {
3609
- const rootClasses = useStylesWithRootClass(rootClassName$12, className);
3687
+ const rootClasses = useStylesWithRootClass(rootClassName$13, className);
3610
3688
  return jsxs(StyleDrawerBody, {
3611
3689
  "aria-label": ariaLabel,
3612
3690
  className: rootClasses,
@@ -3621,12 +3699,12 @@ const DotDrawerBody = ({
3621
3699
  });
3622
3700
  };
3623
3701
 
3624
- const rootClassName$11 = 'dot-drawer-footer';
3702
+ const rootClassName$12 = 'dot-drawer-footer';
3625
3703
  const StyleDrawerFooter = styled.div`
3626
3704
  ${({
3627
3705
  theme
3628
3706
  }) => css`
3629
- &.${rootClassName$11} {
3707
+ &.${rootClassName$12} {
3630
3708
  padding: ${theme.spacing(2, 0, 0)};
3631
3709
  }
3632
3710
  `}
@@ -3639,7 +3717,7 @@ const DotDrawerFooter = ({
3639
3717
  className,
3640
3718
  'data-testid': dataTestId
3641
3719
  }) => {
3642
- const rootClasses = useStylesWithRootClass(rootClassName$11, className);
3720
+ const rootClasses = useStylesWithRootClass(rootClassName$12, className);
3643
3721
  return jsx(StyleDrawerFooter, {
3644
3722
  "aria-label": ariaLabel,
3645
3723
  className: rootClasses,
@@ -3655,7 +3733,7 @@ const DotDrawer = ({
3655
3733
  ariaRole = 'dialog',
3656
3734
  className,
3657
3735
  children,
3658
- 'data-pendoid': dataPendoId = rootClassName$15,
3736
+ 'data-pendoid': dataPendoId = rootClassName$16,
3659
3737
  'data-testid': dataTestId,
3660
3738
  drawerBodyProps,
3661
3739
  drawerFooterProps,
@@ -3678,7 +3756,7 @@ const DotDrawer = ({
3678
3756
  onClose(event);
3679
3757
  }
3680
3758
  };
3681
- const rootClasses = useStylesWithRootClass(rootClassName$15, className);
3759
+ const rootClasses = useStylesWithRootClass(rootClassName$16, className);
3682
3760
  const backdropEnabled = variant === 'temporary' && !(ModalProps === null || ModalProps === void 0 ? void 0 : ModalProps.hideBackdrop);
3683
3761
  const headerExists = !!drawerHeaderProps;
3684
3762
  const bodyPendoId = drawerBodyProps ? drawerBodyProps['data-pendoid'] : 'drawer-body';
@@ -4073,12 +4151,14 @@ const DotList = ({
4073
4151
  items = [],
4074
4152
  menuPlacement = 'right-start',
4075
4153
  nestedDrawerLeftSpacing = 240,
4154
+ nestedListCloseOnClickAway = true,
4076
4155
  nestedListType = 'expandable',
4077
4156
  width = 240
4078
4157
  }) => {
4079
- const rootClasses = useStylesWithRootClass(rootClassName$1a, className);
4158
+ const rootClasses = useStylesWithRootClass(rootClassName$1b, className);
4080
4159
  const listWidth = typeof width === 'number' ? `${width}px` : width;
4081
4160
  const listRef = useRef();
4161
+ const disableCloseOnClickAway = !nestedListCloseOnClickAway && nestedListType === 'expandable';
4082
4162
  const [listItemIndex, setListItemIndex] = useState(null);
4083
4163
  const updateSelectedListItem = currentIndex => {
4084
4164
  currentIndex === listItemIndex ? setListItemIndex(null) : setListItemIndex(currentIndex);
@@ -4089,93 +4169,94 @@ const DotList = ({
4089
4169
  const handleHrefClick = index => () => {
4090
4170
  updateSelectedListItem(index);
4091
4171
  };
4092
- return jsx(DotClickAwayListener, {
4093
- onClickAway: handleClickAway,
4094
- children: jsxs(StyledList, {
4095
- "aria-label": ariaLabel,
4096
- classes: {
4097
- root: rootClasses
4098
- },
4099
- component: component,
4100
- "data-testid": dataTestId,
4101
- dense: dense,
4102
- disablePadding: disablePadding,
4103
- ref: listRef,
4104
- role: ariaRole,
4105
- style: {
4106
- width: listWidth
4107
- },
4108
- children: [items.map((item, index) => {
4172
+ const list = jsxs(StyledList, {
4173
+ "aria-label": ariaLabel,
4174
+ classes: {
4175
+ root: rootClasses
4176
+ },
4177
+ component: component,
4178
+ "data-testid": dataTestId,
4179
+ dense: dense,
4180
+ disablePadding: disablePadding,
4181
+ ref: listRef,
4182
+ role: ariaRole,
4183
+ style: {
4184
+ width: listWidth
4185
+ },
4186
+ children: [items.map((item, index) => {
4187
+ var _a;
4188
+ const handleListItemClick = e => {
4109
4189
  var _a;
4110
- const handleListItemClick = e => {
4111
- var _a;
4112
- const target = e.target;
4113
- e.stopPropagation();
4114
- (_a = item.onClick) === null || _a === void 0 ? void 0 : _a.call(item, e);
4115
- // If clicking on a nested list item, don't update the selected index
4116
- // Do nothing if clicking on the drawer itself
4117
- if (shouldToggleOpen(target.className)) {
4118
- updateSelectedListItem(index);
4119
- }
4120
- };
4121
- const determineOnClick = item.onClick || ((_a = item.items) === null || _a === void 0 ? void 0 : _a.length) ? handleListItemClick : null;
4122
- const handleMenuLeave = event => {
4123
- // TODO: Need to apply animation to open/close
4124
- var _a, _b;
4125
- // Remove index only if clicked element is not found within the list
4126
- if (!((_a = listRef.current) === null || _a === void 0 ? void 0 : _a.contains(event.target))) {
4127
- setListItemIndex(null);
4128
- (_b = item.onMenuLeave) === null || _b === void 0 ? void 0 : _b.call(item, event);
4129
- }
4130
- };
4131
- if (item.child) {
4132
- return jsx("div", {
4133
- onClick: item.onClick,
4134
- role: "listitem",
4135
- children: item.child
4136
- }, `item-child-${item.id || CreateUUID()}`);
4190
+ const target = e.target;
4191
+ e.stopPropagation();
4192
+ (_a = item.onClick) === null || _a === void 0 ? void 0 : _a.call(item, e);
4193
+ // If clicking on a nested list item, don't update the selected index
4194
+ // Do nothing if clicking on the drawer itself
4195
+ if (shouldToggleOpen(target.className)) {
4196
+ updateSelectedListItem(index);
4137
4197
  }
4138
- if (item.divider) {
4139
- return jsx(DotListDivider, {
4140
- index: index,
4141
- item: item
4142
- }, `divider-${item.id || CreateUUID()}`);
4198
+ };
4199
+ const determineOnClick = item.onClick || ((_a = item.items) === null || _a === void 0 ? void 0 : _a.length) ? handleListItemClick : null;
4200
+ const handleMenuLeave = event => {
4201
+ // TODO: Need to apply animation to open/close
4202
+ var _a, _b;
4203
+ // Remove index only if clicked element is not found within the list
4204
+ if (!((_a = listRef.current) === null || _a === void 0 ? void 0 : _a.contains(event.target))) {
4205
+ setListItemIndex(null);
4206
+ (_b = item.onMenuLeave) === null || _b === void 0 ? void 0 : _b.call(item, event);
4143
4207
  }
4144
- return jsx(DotListItem, {
4145
- ariaLabel: item.text || item.primaryText,
4146
- className: item.className,
4147
- component: item.component,
4148
- "data-testid": `${dataTestId}-item-${index}`,
4149
- endIcon: item.endIcon,
4150
- href: item.href,
4151
- isOpened: listItemIndex === index,
4152
- items: item.items,
4153
- menuPlacement: menuPlacement,
4154
- nestedDrawerLeftSpacing: nestedDrawerLeftSpacing,
4155
- nestedListType: nestedListType,
4156
- onClick: determineOnClick,
4157
- onHrefClick: item.href ? handleHrefClick(index) : undefined,
4158
- onMenuLeave: handleMenuLeave,
4159
- primaryText: item.primaryText,
4160
- secondaryText: item.secondaryText,
4161
- selected: item.selected,
4162
- startIcon: item.startIcon,
4163
- target: item.target,
4164
- text: item.text,
4165
- tooltip: item.tooltip,
4166
- tooltipPlacement: item.tooltipPlacement || DEFAULT_TOOLTIP_PLACEMENT
4167
- }, item.id || item.text);
4168
- }), children]
4169
- })
4208
+ };
4209
+ if (item.child) {
4210
+ return jsx("div", {
4211
+ onClick: item.onClick,
4212
+ role: "listitem",
4213
+ children: item.child
4214
+ }, `item-child-${item.id || CreateUUID()}`);
4215
+ }
4216
+ if (item.divider) {
4217
+ return jsx(DotListDivider, {
4218
+ index: index,
4219
+ item: item
4220
+ }, `divider-${item.id || CreateUUID()}`);
4221
+ }
4222
+ return jsx(DotListItem, {
4223
+ ariaLabel: item.text || item.primaryText,
4224
+ className: item.className,
4225
+ component: item.component,
4226
+ "data-testid": `${dataTestId}-item-${index}`,
4227
+ endIcon: item.endIcon,
4228
+ href: item.href,
4229
+ isOpened: item.isOpened ? item.isOpened : listItemIndex === index,
4230
+ items: item.items,
4231
+ menuPlacement: menuPlacement,
4232
+ nestedDrawerLeftSpacing: nestedDrawerLeftSpacing,
4233
+ nestedListType: nestedListType,
4234
+ onClick: determineOnClick,
4235
+ onHrefClick: item.href ? handleHrefClick(index) : undefined,
4236
+ onMenuLeave: handleMenuLeave,
4237
+ primaryText: item.primaryText,
4238
+ secondaryText: item.secondaryText,
4239
+ selected: item.selected,
4240
+ startIcon: item.startIcon,
4241
+ target: item.target,
4242
+ text: item.text,
4243
+ tooltip: item.tooltip,
4244
+ tooltipPlacement: item.tooltipPlacement || DEFAULT_TOOLTIP_PLACEMENT
4245
+ }, item.id || item.text);
4246
+ }), children]
4247
+ });
4248
+ return disableCloseOnClickAway ? list : jsx(DotClickAwayListener, {
4249
+ onClickAway: handleClickAway,
4250
+ children: list
4170
4251
  });
4171
4252
  };
4172
4253
 
4173
- const rootClassName$10 = 'dot-copy-button';
4254
+ const rootClassName$11 = 'dot-copy-button';
4174
4255
  const StyledCopyButton = styled.span`
4175
4256
  ${({
4176
4257
  theme
4177
4258
  }) => css`
4178
- &.${rootClassName$10} .copied-to-clipboard {
4259
+ &.${rootClassName$11} .copied-to-clipboard {
4179
4260
  color: ${theme.palette.figma.success.normal};
4180
4261
 
4181
4262
  &.MuiIcon-fontSizeSmall.button-size-small {
@@ -4201,7 +4282,7 @@ const DotCopyButton = ({
4201
4282
  color = 'inherit',
4202
4283
  copiedTooltip = 'Copied!',
4203
4284
  copyTooltip = 'Copy to clipboard',
4204
- 'data-pendoid': dataPendoId = rootClassName$10,
4285
+ 'data-pendoid': dataPendoId = rootClassName$11,
4205
4286
  'data-testid': dataTestId = 'dot-copy-button',
4206
4287
  disabled = false,
4207
4288
  disableRipple = false,
@@ -4249,7 +4330,7 @@ const DotCopyButton = ({
4249
4330
  return false;
4250
4331
  }, [value, showCopiedIcon, disabled, onClick]);
4251
4332
  return jsxs(StyledCopyButton, {
4252
- className: rootClassName$10,
4333
+ className: rootClassName$11,
4253
4334
  "data-testid": dataTestId,
4254
4335
  children: [!timedShowCopiedIcon && jsx(DotIconButton, {
4255
4336
  ariaLabel: ariaLabel,
@@ -4338,7 +4419,7 @@ const DotInputText = ({
4338
4419
  autoFocus,
4339
4420
  className,
4340
4421
  defaultValue,
4341
- 'data-pendoid': dataPendoId = rootClassName$1g,
4422
+ 'data-pendoid': dataPendoId = rootClassName$1h,
4342
4423
  'data-testid': dataTestId,
4343
4424
  disabled = false,
4344
4425
  error = false,
@@ -4384,7 +4465,7 @@ const DotInputText = ({
4384
4465
  const internalInputRef = useRef(null);
4385
4466
  const textFieldInputRef = inputRef || internalInputRef;
4386
4467
  const [inputTextState, setInputTextState] = useState(getInitialState(value));
4387
- const rootStyles = useStylesWithRootClass(rootClassName$1g, hasError, hasWarning, hasSuccess, readOnly && readOnlyClassName$1);
4468
+ const rootStyles = useStylesWithRootClass(rootClassName$1h, hasError, hasWarning, hasSuccess, readOnly && readOnlyClassName$1);
4388
4469
  useEffect(() => {
4389
4470
  if (value !== inputTextState.inputValue) {
4390
4471
  setInputTextState(getInitialState(value, defaultValue));
@@ -4520,10 +4601,10 @@ const DotInputText = ({
4520
4601
  });
4521
4602
  };
4522
4603
 
4523
- const rootClassName$$ = 'dot-search-input';
4604
+ const rootClassName$10 = 'dot-search-input';
4524
4605
  const StyledSearchInput = styled.span`
4525
4606
  ${() => css`
4526
- &.${rootClassName$$} {
4607
+ &.${rootClassName$10} {
4527
4608
  }
4528
4609
  `}
4529
4610
  `;
@@ -4540,7 +4621,7 @@ function SearchInput({
4540
4621
  tooltip = null,
4541
4622
  value
4542
4623
  }) {
4543
- const rootClasses = useStylesWithRootClass(rootClassName$$, className);
4624
+ const rootClasses = useStylesWithRootClass(rootClassName$10, className);
4544
4625
  const [searchText, setSearchText] = useState(value);
4545
4626
  let previousSearchText = '';
4546
4627
  const handleChange = useCallback(event => {
@@ -4796,12 +4877,12 @@ const recentAppInstancesSetter = (latestInstance, maxRecentItems
4796
4877
  };
4797
4878
  };
4798
4879
 
4799
- const rootClassName$_ = 'dot-app-switcher';
4880
+ const rootClassName$$ = 'dot-app-switcher';
4800
4881
  const StyledAppSwitcher = styled(DotDrawer)`
4801
4882
  ${({
4802
4883
  theme
4803
4884
  }) => css`
4804
- &.${rootClassName$_} {
4885
+ &.${rootClassName$$} {
4805
4886
  .dot-drawer-paper {
4806
4887
  padding: 0;
4807
4888
  width: 382px;
@@ -4911,7 +4992,7 @@ const DotAppSwitcherView = ({
4911
4992
  if (dotCoreApiContext !== null) {
4912
4993
  setSelectedAppType = dotCoreApiContext.setSelectedAppSwitcherAppType;
4913
4994
  }
4914
- const rootClasses = useStylesWithRootClass(rootClassName$_, className);
4995
+ const rootClasses = useStylesWithRootClass(rootClassName$$, className);
4915
4996
  const [appTypeMap, setAppTypeMap] = useState();
4916
4997
  const [appTypeLabels, setAppTypeLabels] = useState();
4917
4998
  const [appTypeMenuItems, setAppTypeMenuItems] = useState();
@@ -5289,12 +5370,12 @@ var SvgLogoDigitalAiWhite = function SvgLogoDigitalAiWhite(_ref, ref) {
5289
5370
  };
5290
5371
  var ForwardRef = /*#__PURE__*/forwardRef(SvgLogoDigitalAiWhite);
5291
5372
 
5292
- const rootClassName$Z = 'dot-sidebar';
5373
+ const rootClassName$_ = 'dot-sidebar';
5293
5374
  const StyledSidebar = styled.aside`
5294
5375
  ${({
5295
5376
  theme
5296
5377
  }) => css`
5297
- &.${rootClassName$Z} {
5378
+ &.${rootClassName$_} {
5298
5379
  align-items: stretch;
5299
5380
  background: ${theme.palette.figma.background.level1.white};
5300
5381
  border-width: 0 1px;
@@ -5588,10 +5669,10 @@ const StyledSidebar = styled.aside`
5588
5669
  `}
5589
5670
  `;
5590
5671
 
5591
- const rootClassName$Y = 'dot-truncate-with-tooltip';
5672
+ const rootClassName$Z = 'dot-truncate-with-tooltip';
5592
5673
  const StyledTruncateWithTooltip = styled(Tooltip)`
5593
5674
  ${() => css`
5594
- &.${rootClassName$Y} {
5675
+ &.${rootClassName$Z} {
5595
5676
  display: block;
5596
5677
  overflow: hidden;
5597
5678
  white-space: nowrap;
@@ -5622,7 +5703,7 @@ const DotTruncateWithTooltip = ({
5622
5703
  label,
5623
5704
  width
5624
5705
  }) => {
5625
- const rootClasses = useStylesWithRootClass(rootClassName$Y, className, charactersLimit ? 'dot-characters-limit' : '');
5706
+ const rootClasses = useStylesWithRootClass(rootClassName$Z, className, charactersLimit ? 'dot-characters-limit' : '');
5626
5707
  return jsx(StyledTruncateWithTooltip, {
5627
5708
  "aria-label": ariaLabel,
5628
5709
  arrow: arrow,
@@ -5746,7 +5827,7 @@ const DotSidebar = ({
5746
5827
  };
5747
5828
  }, [isOpen, collapsable]);
5748
5829
  const sidebarClasses = useStylesWithRootClass('side-nav', openClass);
5749
- const rootClasses = useStylesWithRootClass(rootClassName$Z, openClass, className);
5830
+ const rootClasses = useStylesWithRootClass(rootClassName$_, openClass, className);
5750
5831
  return jsxs(StyledSidebar, {
5751
5832
  "aria-label": ariaLabel,
5752
5833
  className: rootClasses,
@@ -5802,7 +5883,7 @@ const DotSidebar = ({
5802
5883
  children: jsx(DotIconButton, {
5803
5884
  ariaLabel: "collapse sidebar navigation",
5804
5885
  "data-testid": "toggle-nav",
5805
- iconId: isOpen ? 'collapse' : 'expand',
5886
+ iconId: isOpen ? 'push-left' : 'push-right',
5806
5887
  iconSize: "small",
5807
5888
  onClick: toggleNavCollapseState,
5808
5889
  size: "small"
@@ -5814,12 +5895,12 @@ const DotSidebar = ({
5814
5895
  });
5815
5896
  };
5816
5897
 
5817
- const rootClassName$X = 'dot-badge';
5898
+ const rootClassName$Y = 'dot-badge';
5818
5899
  const StyledBadge = styled(Badge)`
5819
5900
  ${({
5820
5901
  theme
5821
5902
  }) => css`
5822
- &.${rootClassName$X} {
5903
+ &.${rootClassName$Y} {
5823
5904
  color: ${theme.palette.figma.typography.black};
5824
5905
  word-break: normal;
5825
5906
 
@@ -5854,7 +5935,7 @@ const DotBadge = ({
5854
5935
  overlap,
5855
5936
  variant = 'dot'
5856
5937
  }) => {
5857
- const rootClasses = useStylesWithRootClass(rootClassName$X, className);
5938
+ const rootClasses = useStylesWithRootClass(rootClassName$Y, className);
5858
5939
  return jsx(StyledBadge, {
5859
5940
  "$badgeColor": badgeColor,
5860
5941
  anchorOrigin: {
@@ -5876,7 +5957,7 @@ const DotBadge = ({
5876
5957
  });
5877
5958
  };
5878
5959
 
5879
- const rootClassName$W = 'dot-app-toolbar';
5960
+ const rootClassName$X = 'dot-app-toolbar';
5880
5961
  const denseClassName = 'dense';
5881
5962
  const StyledMainMenu = styled(DotDrawer)`
5882
5963
  ${({
@@ -5916,7 +5997,7 @@ const StyledAppToolbar = styled.header`
5916
5997
  ${({
5917
5998
  theme
5918
5999
  }) => css`
5919
- &.${rootClassName$W} {
6000
+ &.${rootClassName$X} {
5920
6001
  align-items: center;
5921
6002
  background: ${theme.palette.figma.appToolbar.background};
5922
6003
  border-bottom: 4px solid ${theme.palette.figma.border.default};
@@ -6038,7 +6119,7 @@ const DotAppToolbar = ({
6038
6119
  const displayAppLogo = appLogo || appLogoSmall;
6039
6120
  const mainMenuRef = useRef(null);
6040
6121
  const denseClass = dense ? denseClassName : '';
6041
- const rootClasses = useStylesWithRootClass(rootClassName$W, className, denseClass, showMainMenu ? '' : 'without-menu-icon');
6122
+ const rootClasses = useStylesWithRootClass(rootClassName$X, className, denseClass, showMainMenu ? '' : 'without-menu-icon');
6042
6123
  const mainMenuClasses = useStylesWithRootClass('dot-main-menu', denseClass, menuOpen ? 'open' : '');
6043
6124
  const targetBreakpoint = useMediaQuery(theme => theme.breakpoints.up('lg'));
6044
6125
  useEffect(() => {
@@ -6168,14 +6249,14 @@ const DotAppToolbar = ({
6168
6249
  }) : appToolbar;
6169
6250
  };
6170
6251
 
6171
- const rootClassName$V = 'dot-autocomplete';
6252
+ const rootClassName$W = 'dot-autocomplete';
6172
6253
  const inputRootClassName = 'dot-input-root';
6173
6254
  const inputMediumClassName = 'dot-input-medium';
6174
6255
  const StyledAutocomplete = styled(Autocomplete)`
6175
6256
  ${({
6176
6257
  theme
6177
6258
  }) => css`
6178
- &.${rootClassName$V} {
6259
+ &.${rootClassName$W} {
6179
6260
  &.${inputMediumClassName} .dot-text-field .${inputRootClassName} {
6180
6261
  height: 56px;
6181
6262
  padding-left: ${theme.spacing(2)};
@@ -6212,12 +6293,12 @@ const StyledAutocomplete = styled(Autocomplete)`
6212
6293
  `}
6213
6294
  `;
6214
6295
 
6215
- const rootClassName$U = 'dot-chip';
6296
+ const rootClassName$V = 'dot-chip';
6216
6297
  const StyledChip = styled(Chip)`
6217
6298
  ${({
6218
6299
  theme
6219
6300
  }) => css`
6220
- &.${rootClassName$U} {
6301
+ &.${rootClassName$V} {
6221
6302
  background: ${theme.palette.figma.neutral.normal};
6222
6303
  border-color: ${theme.palette.figma.border.darker};
6223
6304
  color: ${theme.palette.figma.typography.black};
@@ -6323,7 +6404,7 @@ const DotChip = ({
6323
6404
  charactersLimit = DEFAULT_CHARACTERS_LIMIT,
6324
6405
  children,
6325
6406
  className,
6326
- 'data-pendoid': dataPendoId = rootClassName$U,
6407
+ 'data-pendoid': dataPendoId = rootClassName$V,
6327
6408
  'data-testid': dataTestId,
6328
6409
  disabled = false,
6329
6410
  error = false,
@@ -6336,7 +6417,7 @@ const DotChip = ({
6336
6417
  tabIndex
6337
6418
  }) => {
6338
6419
  const errorClass = error ? 'Mui-error' : '';
6339
- const rootClasses = useStylesWithRootClass(rootClassName$U, className, errorClass);
6420
+ const rootClasses = useStylesWithRootClass(rootClassName$V, className, errorClass);
6340
6421
  const getChipLabel = () => {
6341
6422
  if (charactersLimit <= 0 || children.length < charactersLimit) return children;
6342
6423
  const label = `${children.substring(0, charactersLimit)}...`;
@@ -6436,7 +6517,7 @@ const DotAutoComplete = ({
6436
6517
  autoFocus,
6437
6518
  autoHighlight,
6438
6519
  className,
6439
- 'data-pendoid': dataPendoId = rootClassName$V,
6520
+ 'data-pendoid': dataPendoId = rootClassName$W,
6440
6521
  'data-testid': dataTestId,
6441
6522
  defaultValue,
6442
6523
  dense = true,
@@ -6468,6 +6549,7 @@ const DotAutoComplete = ({
6468
6549
  persistentLabel,
6469
6550
  placeholder,
6470
6551
  popperClassName,
6552
+ preserveGroupOrder = false,
6471
6553
  readOnly = false,
6472
6554
  renderGroup,
6473
6555
  renderOption,
@@ -6488,10 +6570,10 @@ const DotAutoComplete = ({
6488
6570
  const popperOpen = !readOnly && (open || isOpened);
6489
6571
  const preventDuplicateInsertion = actionItem === null || actionItem === void 0 ? void 0 : actionItem.preventDuplicateInsertion;
6490
6572
  const textFieldWarningClassName = !error && warning && warningClassName;
6491
- const rootClasses = useStylesWithRootClass(rootClassName$V, size === 'medium' && inputMediumClassName, className);
6492
- const textFieldRootClasses = useStylesWithRootClass(rootClassName$1g, readOnly && readOnlyClassName$1, textFieldWarningClassName);
6573
+ const rootClasses = useStylesWithRootClass(rootClassName$W, size === 'medium' && inputMediumClassName, className);
6574
+ const textFieldRootClasses = useStylesWithRootClass(rootClassName$1h, readOnly && readOnlyClassName$1, textFieldWarningClassName);
6493
6575
  const inputRootClasses = useStylesWithRootClass(inputRootClassName, !dense && inputMediumClassName);
6494
- const popperClasses = useStylesWithRootClass(rootClassName$18, popperClassName);
6576
+ const popperClasses = useStylesWithRootClass(rootClassName$19, popperClassName);
6495
6577
  let highlightedOption = null;
6496
6578
  let textFieldInput;
6497
6579
  const textFieldRef = element => {
@@ -6517,11 +6599,12 @@ const DotAutoComplete = ({
6517
6599
  setShowPlaceholder(parseAutoCompleteValue(val) === '');
6518
6600
  };
6519
6601
  const sortOptions = () => {
6520
- return group ? options.sort((a, b) => {
6602
+ if (!group || preserveGroupOrder) return options;
6603
+ return options.sort((a, b) => {
6521
6604
  const aGroup = a.group ? a.group : '';
6522
6605
  const bGroup = b.group ? b.group : '';
6523
6606
  return -bGroup.localeCompare(aGroup);
6524
- }) : options;
6607
+ });
6525
6608
  };
6526
6609
  const handleBlur = event => {
6527
6610
  event.relatedTarget !== actionItemRef.current && setIsOpened(false);
@@ -6768,10 +6851,10 @@ const DotAutoComplete = ({
6768
6851
  });
6769
6852
  };
6770
6853
 
6771
- const rootClassName$T = 'dot-avatar-group';
6854
+ const rootClassName$U = 'dot-avatar-group';
6772
6855
  const StyledAvatarGroup = styled(AvatarGroup)`
6773
6856
  ${() => css`
6774
- &.${rootClassName$T} {
6857
+ &.${rootClassName$U} {
6775
6858
  justify-content: flex-end;
6776
6859
 
6777
6860
  .MuiAvatar-root {
@@ -6790,7 +6873,7 @@ const DotAvatarGroup = ({
6790
6873
  max = 3,
6791
6874
  spacing = 'medium'
6792
6875
  }) => {
6793
- const rootClasses = useStylesWithRootClass(rootClassName$T, className);
6876
+ const rootClasses = useStylesWithRootClass(rootClassName$U, className);
6794
6877
  return jsx(StyledAvatarGroup, {
6795
6878
  "aria-label": ariaLabel,
6796
6879
  classes: {
@@ -6805,13 +6888,13 @@ const DotAvatarGroup = ({
6805
6888
  });
6806
6889
  };
6807
6890
 
6808
- const rootClassName$S = 'dot-breadcrumbs';
6891
+ const rootClassName$T = 'dot-breadcrumbs';
6809
6892
  const breadcrumbsWrapperClass = 'dot-breadcrumbs-wrapper';
6810
6893
  const StyledBreadcrumbsWrapper = styled.div`
6811
6894
  ${({
6812
6895
  theme
6813
6896
  }) => css`
6814
- &.${rootClassName$S} {
6897
+ &.${rootClassName$T} {
6815
6898
  overflow: hidden;
6816
6899
 
6817
6900
  .dot-breadcrumbs-menu {
@@ -6831,7 +6914,7 @@ const StyledBreadcrumbs = styled(Breadcrumbs)`
6831
6914
  ${({
6832
6915
  theme
6833
6916
  }) => css`
6834
- &.${rootClassName$S} {
6917
+ &.${rootClassName$T} {
6835
6918
  margin-bottom: 0;
6836
6919
 
6837
6920
  .MuiBreadcrumbs-ol {
@@ -7159,7 +7242,7 @@ const DotBreadcrumbs = ({
7159
7242
  children: [jsx(StyledBreadcrumbs, {
7160
7243
  "aria-label": "breadcrumb",
7161
7244
  classes: {
7162
- root: rootClassName$S,
7245
+ root: rootClassName$T,
7163
7246
  ol: 'dot-ol',
7164
7247
  li: 'dot-li'
7165
7248
  },
@@ -7190,14 +7273,14 @@ const DotBreadcrumbs = ({
7190
7273
  });
7191
7274
  };
7192
7275
 
7193
- const rootClassName$R = 'dot-button-toggle';
7276
+ const rootClassName$S = 'dot-button-toggle';
7194
7277
  // TODO: need to update ripple color
7195
7278
  // https://github.com/mui/material-ui/issues/28543
7196
7279
  const StyledToggleButtonGroup = styled(ToggleButtonGroup)`
7197
7280
  ${({
7198
7281
  theme
7199
7282
  }) => css`
7200
- &.${rootClassName$R} {
7283
+ &.${rootClassName$S} {
7201
7284
  button:not(.MuiToggleButton-sizeLarge):not(.MuiToggleButton-sizeSmall) {
7202
7285
  /* Override height for medium size */
7203
7286
  height: ${theme.spacing(5)};
@@ -7313,7 +7396,7 @@ const DotButtonToggle = ({
7313
7396
  buttonOptions,
7314
7397
  className,
7315
7398
  color,
7316
- 'data-pendoid': dataPendoId = rootClassName$R,
7399
+ 'data-pendoid': dataPendoId = rootClassName$S,
7317
7400
  'data-testid': dataTestId = 'dot-toggle',
7318
7401
  disableFocusRipple = false,
7319
7402
  disableRipple = false,
@@ -7323,7 +7406,7 @@ const DotButtonToggle = ({
7323
7406
  size = 'medium',
7324
7407
  value
7325
7408
  }) => {
7326
- const rootClasses = useStylesWithRootClass(rootClassName$R, className);
7409
+ const rootClasses = useStylesWithRootClass(rootClassName$S, className);
7327
7410
  const renderToggleButton = ({
7328
7411
  ariaLabel: optionAriaLabel,
7329
7412
  badgeContent: optionBadgeContent,
@@ -7406,12 +7489,12 @@ const TooltipToggleButton = forwardRef((_a, ref) => {
7406
7489
  }));
7407
7490
  });
7408
7491
 
7409
- const rootClassName$Q = 'dot-card';
7492
+ const rootClassName$R = 'dot-card';
7410
7493
  const StyledCard = styled(Card)`
7411
7494
  ${({
7412
7495
  theme
7413
7496
  }) => css`
7414
- &.${rootClassName$Q} {
7497
+ &.${rootClassName$R} {
7415
7498
  background-color: ${theme.palette.figma.background.level1.white};
7416
7499
  }
7417
7500
  `}
@@ -7423,7 +7506,7 @@ const DotCard = ({
7423
7506
  className,
7424
7507
  'data-testid': dataTestId
7425
7508
  }) => {
7426
- const rootClasses = useStylesWithRootClass(rootClassName$Q, className);
7509
+ const rootClasses = useStylesWithRootClass(rootClassName$R, className);
7427
7510
  return jsx(StyledCard, {
7428
7511
  "aria-label": ariaLabel,
7429
7512
  classes: {
@@ -7452,12 +7535,12 @@ const DotCardContent = ({
7452
7535
  });
7453
7536
  };
7454
7537
 
7455
- const rootClassName$P = 'dot-card-footer';
7538
+ const rootClassName$Q = 'dot-card-footer';
7456
7539
  const StyledDiv = styled.div`
7457
7540
  ${({
7458
7541
  theme
7459
7542
  }) => css`
7460
- &.${rootClassName$P} {
7543
+ &.${rootClassName$Q} {
7461
7544
  padding: ${theme.spacing(2)};
7462
7545
  }
7463
7546
  `}
@@ -7469,7 +7552,7 @@ const DotCardFooter = ({
7469
7552
  className,
7470
7553
  'data-testid': dataTestId
7471
7554
  }) => {
7472
- const rootClasses = useStylesWithRootClass(rootClassName$P, className);
7555
+ const rootClasses = useStylesWithRootClass(rootClassName$Q, className);
7473
7556
  return jsx(StyledDiv, {
7474
7557
  "aria-label": ariaLabel,
7475
7558
  className: rootClasses,
@@ -7478,6 +7561,23 @@ const DotCardFooter = ({
7478
7561
  });
7479
7562
  };
7480
7563
 
7564
+ const rootClassName$P = 'dot-card-header';
7565
+ const StyledCardHeader = styled(CardHeader)`
7566
+ ${({
7567
+ theme
7568
+ }) => css`
7569
+ &.${rootClassName$P} {
7570
+ .MuiCardHeader-content {
7571
+ overflow-x: hidden;
7572
+
7573
+ .dot-card-subheader {
7574
+ color: ${theme.palette.figma.typography.gray};
7575
+ }
7576
+ }
7577
+ }
7578
+ `}
7579
+ `;
7580
+
7481
7581
  const DotCardHeader = ({
7482
7582
  action,
7483
7583
  ariaLabel,
@@ -7489,16 +7589,11 @@ const DotCardHeader = ({
7489
7589
  title,
7490
7590
  titleSize = 'large'
7491
7591
  }) => {
7492
- const rootClasses = useStylesWithRootClass('dot-card-header', className);
7493
- const titleVariant = titleSize === 'small' ? 'h4' : titleSize === 'medium' ? 'h3' : 'h2';
7494
- const titleTypographyProps = {
7495
- variant: titleVariant
7496
- };
7592
+ const rootClasses = useStylesWithRootClass(rootClassName$P, className);
7593
+ const nonSmallTitleSize = titleSize === 'medium' ? 'h3' : 'h2';
7594
+ const titleVariant = titleSize === 'small' ? 'h4' : nonSmallTitleSize;
7497
7595
  const subheaderVariant = subheaderSize === 'small' ? 'body2' : 'body1';
7498
- const subheaderTypographyProps = {
7499
- variant: subheaderVariant
7500
- };
7501
- return jsx(CardHeader, {
7596
+ return jsx(StyledCardHeader, {
7502
7597
  action: action,
7503
7598
  "aria-label": ariaLabel,
7504
7599
  avatar: avatar,
@@ -7506,10 +7601,26 @@ const DotCardHeader = ({
7506
7601
  root: rootClasses
7507
7602
  },
7508
7603
  "data-testid": dataTestId,
7509
- subheader: subheader,
7510
- subheaderTypographyProps: subheaderTypographyProps,
7511
- title: title,
7512
- titleTypographyProps: titleTypographyProps
7604
+ subheader: jsx(DotTooltip, {
7605
+ hoverVisibility: "overflow",
7606
+ title: subheader,
7607
+ children: jsx(DotTypography, {
7608
+ className: "dot-card-subheader",
7609
+ children: subheader,
7610
+ noWrap: true,
7611
+ variant: subheaderVariant
7612
+ })
7613
+ }),
7614
+ title: jsx(DotTooltip, {
7615
+ hoverVisibility: "overflow",
7616
+ title: title,
7617
+ children: jsx(DotTypography, {
7618
+ className: "dot-card-header-title",
7619
+ children: title,
7620
+ noWrap: true,
7621
+ variant: titleVariant
7622
+ })
7623
+ })
7513
7624
  });
7514
7625
  };
7515
7626
 
@@ -9679,7 +9790,7 @@ const StyledSnackbar = styled(Snackbar)`
9679
9790
  .MuiAlert-message {
9680
9791
  word-break: break-word;
9681
9792
  }
9682
- .${rootClassName$1e} {
9793
+ .${rootClassName$1f} {
9683
9794
  align-items: flex-start;
9684
9795
  }
9685
9796
  &.MuiSnackbar-anchorOriginTopLeft,
@@ -11707,7 +11818,7 @@ const StyledFormContainer = styled.div`
11707
11818
 
11708
11819
  .${rootClassName$M},
11709
11820
  .${rootClassName$O},
11710
- .${rootClassName$1g},
11821
+ .${rootClassName$1h},
11711
11822
  .${rootSelectClassName},
11712
11823
  .${rootClassName$A},
11713
11824
  .${rootClassName$z} {
@@ -11715,7 +11826,7 @@ const StyledFormContainer = styled.div`
11715
11826
  }
11716
11827
 
11717
11828
  label
11718
- + .${rootClassName$1g},
11829
+ + .${rootClassName$1h},
11719
11830
  label
11720
11831
  + .${rootSelectClassName},
11721
11832
  label
@@ -16279,25 +16390,34 @@ const DotPopper = ({
16279
16390
  className,
16280
16391
  'data-testid': dataTestId,
16281
16392
  disablePortal,
16393
+ hasArrow = false,
16282
16394
  modifiers,
16283
16395
  onClickAway,
16284
16396
  open,
16285
16397
  placement
16286
16398
  }) => {
16287
- const rootClasses = useStylesWithRootClass(rootClassName$18, className);
16399
+ const [arrowRef, setArrowRef] = useState(null);
16400
+ const rootClasses = useStylesWithRootClass(rootClassName$19, className);
16288
16401
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
16289
16402
  const handleClickAway = event => {
16290
16403
  if (onClickAway && (!anchorEl || !anchorEl.contains(event.currentTarget))) {
16291
16404
  onClickAway(event);
16292
16405
  }
16293
16406
  };
16407
+ const arrowModifier = {
16408
+ name: 'arrow',
16409
+ enabled: true,
16410
+ options: {
16411
+ element: arrowRef
16412
+ }
16413
+ };
16294
16414
  return jsx(StyledPopper$1, {
16295
16415
  anchorEl: anchorEl,
16296
16416
  "aria-label": ariaLabel,
16297
16417
  className: rootClasses,
16298
16418
  "data-testid": dataTestId,
16299
16419
  disablePortal: disablePortal,
16300
- modifiers: modifiers,
16420
+ modifiers: [...(modifiers || []), ...(hasArrow ? [arrowModifier] : [])],
16301
16421
  open: open,
16302
16422
  placement: placement,
16303
16423
  role: "presentation",
@@ -16305,16 +16425,20 @@ const DotPopper = ({
16305
16425
  children: ({
16306
16426
  TransitionProps
16307
16427
  }) => jsx(Fade, Object.assign({}, TransitionProps, {
16308
- children: jsx(Paper, {
16428
+ children: jsxs(Paper, {
16309
16429
  className: "dot-popper-paper",
16310
- children: jsx(ClickAwayListener, {
16430
+ children: [hasArrow && jsx(StyledArrow, {
16431
+ className: arrowClassName,
16432
+ "data-testid": "popper-arrow",
16433
+ ref: setArrowRef
16434
+ }), jsx(ClickAwayListener, {
16311
16435
  onClickAway: handleClickAway,
16312
16436
  children: jsx("div", {
16313
16437
  className: "dot-popper-content-wrapper",
16314
16438
  "data-testid": dataTestId && `${dataTestId}-content-wrapper`,
16315
16439
  children: children
16316
16440
  })
16317
- })
16441
+ })]
16318
16442
  })
16319
16443
  }))
16320
16444
  });
@@ -17914,4 +18038,4 @@ const BoardColumnSummary = ({
17914
18038
  });
17915
18039
  };
17916
18040
 
17917
- 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 };
18041
+ export { ApiError$1 as ApiError, BoardStatusProvider, Cell, ColumnStatusProvider, CreateUUID, CssCell, CssGrid, CssGridDebug, DashboardAppTypeOptions, DashboardView, 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 };