@uniformdev/design-system 19.195.1-alpha.3 → 19.196.1-alpha.2

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/dist/esm/index.js CHANGED
@@ -13029,7 +13029,7 @@ var Input = React10.forwardRef(
13029
13029
  errorMessage ? inputError : void 0,
13030
13030
  icon ? inputWithIcon : ""
13031
13031
  ],
13032
- "aria-label": !showLabel ? label : void 0,
13032
+ "aria-label": showLabel || typeof label !== "string" ? void 0 : label,
13033
13033
  className: typeof classNameControl === "string" ? classNameControl : "",
13034
13034
  ...props,
13035
13035
  ref
@@ -15149,6 +15149,9 @@ var ChipOutlined = css49`
15149
15149
  border-color: var(--outline-color);
15150
15150
  }
15151
15151
  `;
15152
+ var ChipDisabled = css49`
15153
+ opacity: var(--opacity-50);
15154
+ `;
15152
15155
 
15153
15156
  // src/components/Chip/Chip.tsx
15154
15157
  import { Fragment as Fragment9, jsx as jsx62, jsxs as jsxs38 } from "@emotion/react/jsx-runtime";
@@ -15168,6 +15171,7 @@ var Chip = ({
15168
15171
  theme = "accent-light",
15169
15172
  variant = "solid",
15170
15173
  chipAction,
15174
+ isDisabled = false,
15171
15175
  as = "span",
15172
15176
  ...props
15173
15177
  }) => {
@@ -15184,7 +15188,8 @@ var Chip = ({
15184
15188
  ChipContainer,
15185
15189
  chipSize[size],
15186
15190
  chipTheme[theme],
15187
- variant === "outlined" ? ChipOutlined : void 0
15191
+ variant === "outlined" ? ChipOutlined : void 0,
15192
+ isDisabled ? ChipDisabled : void 0
15188
15193
  ],
15189
15194
  ...props,
15190
15195
  children: [
@@ -18637,8 +18642,9 @@ var modalContentStyles = css80`
18637
18642
  border-radius: var(--rounded-sm);
18638
18643
  ${scrollbarStyles}
18639
18644
  `;
18640
- var modalDialogWrapper = css80`
18641
- padding: 0 var(--spacing-lg) var(--spacing-md);
18645
+ var modalDialogWrapper = (hasCloseButton) => css80`
18646
+ height: 100%;
18647
+ padding: ${hasCloseButton ? 0 : "var(--spacing-md)"} var(--spacing-lg) var(--spacing-md);
18642
18648
  `;
18643
18649
  var modalDialogInnerStyles = css80`
18644
18650
  // we need to override the gap of the modalInnerStyles when using a modal dialog
@@ -18662,8 +18668,10 @@ var Modal = React20.forwardRef(
18662
18668
  modalSize = "lg",
18663
18669
  withoutContentPadding = false,
18664
18670
  withoutContentBackground = false,
18671
+ disableBodyScroll = false,
18665
18672
  ...modalProps
18666
18673
  }, ref) => {
18674
+ const mouseDownInsideModal = useRef9(false);
18667
18675
  const dialogRef = useRef9(null);
18668
18676
  const size = {
18669
18677
  sm: modalSizeSmall,
@@ -18672,7 +18680,7 @@ var Modal = React20.forwardRef(
18672
18680
  };
18673
18681
  useShortcut({
18674
18682
  handler: () => {
18675
- onRequestClose();
18683
+ onRequestClose == null ? void 0 : onRequestClose();
18676
18684
  },
18677
18685
  shortcut: "escape"
18678
18686
  });
@@ -18705,9 +18713,25 @@ var Modal = React20.forwardRef(
18705
18713
  }
18706
18714
  },
18707
18715
  css: [modalStyles, !width ? size[modalSize] : void 0],
18708
- style: { width, height: height === "auto" ? "min-content" : height },
18716
+ style: {
18717
+ width,
18718
+ height: height === "auto" ? "min-content" : height,
18719
+ // allows menus rendered in the PortalContext to overflow the modal contents
18720
+ // (internal scrolling of contents is handled on a child element)
18721
+ overflow: "visible"
18722
+ },
18709
18723
  "data-testid": "side-dialog",
18710
- onClick: onRequestClose,
18724
+ onClick: () => {
18725
+ if (mouseDownInsideModal.current) {
18726
+ return;
18727
+ }
18728
+ onRequestClose == null ? void 0 : onRequestClose();
18729
+ },
18730
+ onMouseUp: () => {
18731
+ setTimeout(() => {
18732
+ mouseDownInsideModal.current = false;
18733
+ });
18734
+ },
18711
18735
  onCancel: (e) => {
18712
18736
  e.preventDefault();
18713
18737
  },
@@ -18717,10 +18741,13 @@ var Modal = React20.forwardRef(
18717
18741
  {
18718
18742
  css: [modalInnerStyles, { height: height === "auto" ? "auto" : "100%" }],
18719
18743
  onClick: (e) => e.stopPropagation(),
18744
+ onMouseDown: () => {
18745
+ mouseDownInsideModal.current = true;
18746
+ },
18720
18747
  children: [
18721
- /* @__PURE__ */ jsxs67("div", { css: modalHeaderStyles, children: [
18722
- !header2 ? null : /* @__PURE__ */ jsx102("div", { css: modalHeaderHeaderStyles, children: header2 }),
18723
- /* @__PURE__ */ jsx102(
18748
+ header2 || onRequestClose ? /* @__PURE__ */ jsxs67("div", { css: modalHeaderStyles, children: [
18749
+ header2 ? /* @__PURE__ */ jsx102("div", { css: modalHeaderHeaderStyles, children: header2 }) : null,
18750
+ onRequestClose ? /* @__PURE__ */ jsx102(
18724
18751
  Button,
18725
18752
  {
18726
18753
  type: "button",
@@ -18731,15 +18758,16 @@ var Modal = React20.forwardRef(
18731
18758
  "data-testid": "close-dialog",
18732
18759
  children: /* @__PURE__ */ jsx102(Icon, { icon: CgClose4, iconColor: "currentColor", size: 24 })
18733
18760
  }
18734
- )
18735
- ] }),
18761
+ ) : null
18762
+ ] }) : null,
18736
18763
  /* @__PURE__ */ jsx102(
18737
18764
  "div",
18738
18765
  {
18739
18766
  css: [
18740
18767
  modalContentStyles,
18741
- !withoutContentPadding ? null : { padding: 0 },
18742
- !withoutContentBackground ? null : { background: "transparent" }
18768
+ withoutContentPadding ? { padding: 0 } : null,
18769
+ withoutContentBackground ? { background: "transparent" } : null,
18770
+ disableBodyScroll ? { overflow: "visible" } : null
18743
18771
  ],
18744
18772
  children
18745
18773
  }
@@ -18771,9 +18799,9 @@ var ModalDialog = forwardRef16(
18771
18799
  withoutContentPadding: true,
18772
18800
  css: modalDialogInnerStyles,
18773
18801
  width: "",
18774
- children: /* @__PURE__ */ jsxs68(VerticalRhythm, { css: modalDialogWrapper, children: [
18802
+ children: /* @__PURE__ */ jsxs68(VerticalRhythm, { css: modalDialogWrapper(Boolean(onRequestClose)), children: [
18775
18803
  /* @__PURE__ */ jsx103("div", { css: modalHeaderStyles, children: header2 }),
18776
- /* @__PURE__ */ jsx103("div", { children }),
18804
+ /* @__PURE__ */ jsx103("div", { css: { flex: 1 }, children }),
18777
18805
  /* @__PURE__ */ jsx103(HorizontalRhythm, { children: buttonGroup })
18778
18806
  ] })
18779
18807
  }
@@ -20151,7 +20179,7 @@ var ParameterImageInner = forwardRef19((props, ref) => {
20151
20179
  type: "text",
20152
20180
  id,
20153
20181
  ref,
20154
- "aria-label": hiddenLabel ? label : void 0,
20182
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
20155
20183
  autoComplete: "off",
20156
20184
  ...props
20157
20185
  }
@@ -20176,7 +20204,7 @@ var ParameterInputInner = forwardRef20(
20176
20204
  css: input3,
20177
20205
  id,
20178
20206
  type: props.type || "text",
20179
- "aria-label": hiddenLabel ? label : void 0,
20207
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
20180
20208
  autoComplete: "off",
20181
20209
  ref,
20182
20210
  ...props
@@ -20197,7 +20225,7 @@ var ParameterLink = forwardRef21(
20197
20225
  "data-testid": "link-parameter-editor",
20198
20226
  ...shellProps,
20199
20227
  label: innerProps.value ? shellProps.label : "",
20200
- title: !innerProps.value ? shellProps.label : void 0,
20228
+ title: !innerProps.value && typeof shellProps.label === "string" ? shellProps.label : void 0,
20201
20229
  children: /* @__PURE__ */ jsx126(
20202
20230
  ParameterLinkInner,
20203
20231
  {
@@ -20225,7 +20253,7 @@ var ParameterLinkInner = forwardRef21(
20225
20253
  readOnly: Boolean(props.value),
20226
20254
  id,
20227
20255
  ref,
20228
- "aria-label": hiddenLabel ? label : void 0,
20256
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
20229
20257
  ...props
20230
20258
  }
20231
20259
  ),
@@ -20275,7 +20303,7 @@ var ParameterMultiSelectInner = (props) => {
20275
20303
  isMulti: true,
20276
20304
  isClearable: (_a = props.isClearable) != null ? _a : false,
20277
20305
  id,
20278
- "aria-label": label,
20306
+ "aria-label": typeof label === "string" ? label : void 0,
20279
20307
  classNamePrefix: "parameter-multi-select-combobox",
20280
20308
  styles: {
20281
20309
  menuPortal: (base) => ({
@@ -23230,7 +23258,7 @@ var ParameterSelectInner = forwardRef23(
23230
23258
  {
23231
23259
  css: [input3, selectInput],
23232
23260
  id,
23233
- "aria-label": hiddenLabel ? label : void 0,
23261
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
23234
23262
  ref,
23235
23263
  ...props,
23236
23264
  children: [
@@ -23260,7 +23288,7 @@ var ParameterTextareaInner = forwardRef24(({ ...props }, ref) => {
23260
23288
  css: [input3, textarea2],
23261
23289
  id,
23262
23290
  ref,
23263
- "aria-label": hiddenLabel ? label : void 0,
23291
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
23264
23292
  ...props
23265
23293
  }
23266
23294
  );
@@ -24211,16 +24239,15 @@ var StatusBullet = ({
24211
24239
  Deleted: StatusDeleted
24212
24240
  };
24213
24241
  const statusSize = size === "base" ? StatusBulletBase : StatusBulletSmall;
24214
- return /* @__PURE__ */ jsx144(
24242
+ return /* @__PURE__ */ jsx144(Tooltip, { title: message != null ? message : status, children: /* @__PURE__ */ jsx144(
24215
24243
  "span",
24216
24244
  {
24217
24245
  role: "status",
24218
24246
  css: [StatusBulletContainer, currentStateStyles[status], statusSize],
24219
- title: message != null ? message : status,
24220
24247
  ...props,
24221
24248
  children: hideText ? null : message ? message : status
24222
24249
  }
24223
- );
24250
+ ) });
24224
24251
  };
24225
24252
  export {
24226
24253
  AddButton,
package/dist/index.d.mts CHANGED
@@ -21385,6 +21385,11 @@ type ChipProps = {
21385
21385
  * @default 'span'
21386
21386
  */
21387
21387
  as?: 'span' | 'button';
21388
+ /**
21389
+ * Whether the chip is visually disabled
21390
+ * @default false
21391
+ */
21392
+ isDisabled?: boolean;
21388
21393
  } & React.HTMLAttributes<HTMLSpanElement>;
21389
21394
  /**
21390
21395
  * @description Chips are used in a variety of ways
@@ -21393,7 +21398,7 @@ type ChipProps = {
21393
21398
  * To represent a different object, as a reference
21394
21399
  * @example <Chip text="productId" theme="accent-light" chipAction={<DismissibleChipAction onDismiss={() => {...}}/>} />
21395
21400
  */
21396
- declare const Chip: ({ icon, iconColor, text, size, theme, variant, chipAction, as, ...props }: ChipProps) => _emotion_react_jsx_runtime.JSX.Element;
21401
+ declare const Chip: ({ icon, iconColor, text, size, theme, variant, chipAction, isDisabled, as, ...props }: ChipProps) => _emotion_react_jsx_runtime.JSX.Element;
21397
21402
  type DismissibleChipActionProps = {
21398
21403
  onDismiss: () => void;
21399
21404
  } & HTMLAttributes<HTMLButtonElement>;
@@ -21922,7 +21927,7 @@ declare const InfoMessage: ({ message, testId, icon, ...props }: InfoMessageProp
21922
21927
 
21923
21928
  type InputProps = React$1.InputHTMLAttributes<HTMLInputElement> & {
21924
21929
  /** (optional) sets the label value */
21925
- label?: string;
21930
+ label?: string | React$1.ReactNode;
21926
21931
  /** (optional) sets caption text value */
21927
21932
  caption?: string | JSX.Element;
21928
21933
  /** (optional) add an input icon to the input field */
@@ -21965,7 +21970,7 @@ type InputProps = React$1.InputHTMLAttributes<HTMLInputElement> & {
21965
21970
  */
21966
21971
  declare const Input: React$1.ForwardRefExoticComponent<React$1.InputHTMLAttributes<HTMLInputElement> & {
21967
21972
  /** (optional) sets the label value */
21968
- label?: string;
21973
+ label?: string | React$1.ReactNode;
21969
21974
  /** (optional) sets caption text value */
21970
21975
  caption?: string | JSX.Element;
21971
21976
  /** (optional) add an input icon to the input field */
@@ -22758,6 +22763,9 @@ declare function MenuItemIcon({ icon }: {
22758
22763
  */
22759
22764
  declare function MenuItemEmptyIcon(): _emotion_react_jsx_runtime.JSX.Element;
22760
22765
 
22766
+ /**
22767
+ * @deprecated this is deprecated and will be removed in the next major release. Use MenuGroup instead.
22768
+ */
22761
22769
  declare const MenuItemHeading: ({ children }: {
22762
22770
  children: ReactNode;
22763
22771
  }) => _emotion_react_jsx_runtime.JSX.Element;
@@ -22826,8 +22834,11 @@ declare const MediaCard: ({ title, subtitle, infoPopover, cover, menuItems, side
22826
22834
  type ModalProps = {
22827
22835
  header?: React__default.ReactNode;
22828
22836
  children?: React__default.ReactNode;
22829
- /** Called when the close button is clicked, the Escape button is pressed, or when the modal's backdrop is clicked */
22830
- onRequestClose: () => void;
22837
+ /**
22838
+ * Called when the close button is clicked, the Escape button is pressed, or when the modal's backdrop is clicked.
22839
+ * If undefined is passed, the modal will not be closable by the user and the close button will not be rendered.
22840
+ */
22841
+ onRequestClose: (() => void) | undefined;
22831
22842
  /** The size sets the modal width to one of three options sm = 400px, md = 600px and lg = 800px
22832
22843
  * if a width attribute is used the size will be overridden by the width attribute
22833
22844
  * @default 'lg'
@@ -22847,6 +22858,12 @@ type ModalProps = {
22847
22858
  withoutContentBackground?: boolean;
22848
22859
  /** Places buttons at the bottom of the modal */
22849
22860
  buttonGroup?: ReactNode;
22861
+ /**
22862
+ * Disables scrolling of the modal body if the content exceeds the height.
22863
+ * Can be required for modals that have comboboxes where the menu items are expected
22864
+ * to overflow the bounds of the modal.
22865
+ */
22866
+ disableBodyScroll?: boolean;
22850
22867
  } & React__default.HTMLProps<HTMLDialogElement>;
22851
22868
  /**
22852
22869
  * A modal component to open a dialog with a backdrop that covers the whole page.
@@ -22992,7 +23009,7 @@ declare function Pagination({ limit, offset, total, onPageChange, }: {
22992
23009
 
22993
23010
  type CommonParameterProps = {
22994
23011
  /** sets the label value */
22995
- label: string;
23012
+ label: string | ReactNode;
22996
23013
  /** (optional): allows user to pass a component before the label */
22997
23014
  labelLeadingIcon?: ReactNode;
22998
23015
  /** (optional): allows user to pass a component after the label */
@@ -23047,7 +23064,7 @@ type CommonParameterSelectProps = {
23047
23064
  declare const ParameterShellContext: React$1.Context<CommonParameterProps>;
23048
23065
  declare const useParameterShell: () => {
23049
23066
  id: string;
23050
- label: string;
23067
+ label: React$1.ReactNode;
23051
23068
  hiddenLabel: boolean | undefined;
23052
23069
  errorMessage: string | undefined;
23053
23070
  handleManuallySetErrorMessage: ((message: string | undefined) => void) | undefined;
@@ -23401,7 +23418,7 @@ declare const ParameterSelectInner: React$1.ForwardRefExoticComponent<Omit<Param
23401
23418
  declare const extractParameterProps: <T>(props: T & CommonParameterInputProps) => {
23402
23419
  shellProps: {
23403
23420
  id: string;
23404
- label: string;
23421
+ label: ReactNode;
23405
23422
  caption: string | undefined;
23406
23423
  captionTestId: string | undefined;
23407
23424
  errorMessage: string | undefined;
package/dist/index.d.ts CHANGED
@@ -21385,6 +21385,11 @@ type ChipProps = {
21385
21385
  * @default 'span'
21386
21386
  */
21387
21387
  as?: 'span' | 'button';
21388
+ /**
21389
+ * Whether the chip is visually disabled
21390
+ * @default false
21391
+ */
21392
+ isDisabled?: boolean;
21388
21393
  } & React.HTMLAttributes<HTMLSpanElement>;
21389
21394
  /**
21390
21395
  * @description Chips are used in a variety of ways
@@ -21393,7 +21398,7 @@ type ChipProps = {
21393
21398
  * To represent a different object, as a reference
21394
21399
  * @example <Chip text="productId" theme="accent-light" chipAction={<DismissibleChipAction onDismiss={() => {...}}/>} />
21395
21400
  */
21396
- declare const Chip: ({ icon, iconColor, text, size, theme, variant, chipAction, as, ...props }: ChipProps) => _emotion_react_jsx_runtime.JSX.Element;
21401
+ declare const Chip: ({ icon, iconColor, text, size, theme, variant, chipAction, isDisabled, as, ...props }: ChipProps) => _emotion_react_jsx_runtime.JSX.Element;
21397
21402
  type DismissibleChipActionProps = {
21398
21403
  onDismiss: () => void;
21399
21404
  } & HTMLAttributes<HTMLButtonElement>;
@@ -21922,7 +21927,7 @@ declare const InfoMessage: ({ message, testId, icon, ...props }: InfoMessageProp
21922
21927
 
21923
21928
  type InputProps = React$1.InputHTMLAttributes<HTMLInputElement> & {
21924
21929
  /** (optional) sets the label value */
21925
- label?: string;
21930
+ label?: string | React$1.ReactNode;
21926
21931
  /** (optional) sets caption text value */
21927
21932
  caption?: string | JSX.Element;
21928
21933
  /** (optional) add an input icon to the input field */
@@ -21965,7 +21970,7 @@ type InputProps = React$1.InputHTMLAttributes<HTMLInputElement> & {
21965
21970
  */
21966
21971
  declare const Input: React$1.ForwardRefExoticComponent<React$1.InputHTMLAttributes<HTMLInputElement> & {
21967
21972
  /** (optional) sets the label value */
21968
- label?: string;
21973
+ label?: string | React$1.ReactNode;
21969
21974
  /** (optional) sets caption text value */
21970
21975
  caption?: string | JSX.Element;
21971
21976
  /** (optional) add an input icon to the input field */
@@ -22758,6 +22763,9 @@ declare function MenuItemIcon({ icon }: {
22758
22763
  */
22759
22764
  declare function MenuItemEmptyIcon(): _emotion_react_jsx_runtime.JSX.Element;
22760
22765
 
22766
+ /**
22767
+ * @deprecated this is deprecated and will be removed in the next major release. Use MenuGroup instead.
22768
+ */
22761
22769
  declare const MenuItemHeading: ({ children }: {
22762
22770
  children: ReactNode;
22763
22771
  }) => _emotion_react_jsx_runtime.JSX.Element;
@@ -22826,8 +22834,11 @@ declare const MediaCard: ({ title, subtitle, infoPopover, cover, menuItems, side
22826
22834
  type ModalProps = {
22827
22835
  header?: React__default.ReactNode;
22828
22836
  children?: React__default.ReactNode;
22829
- /** Called when the close button is clicked, the Escape button is pressed, or when the modal's backdrop is clicked */
22830
- onRequestClose: () => void;
22837
+ /**
22838
+ * Called when the close button is clicked, the Escape button is pressed, or when the modal's backdrop is clicked.
22839
+ * If undefined is passed, the modal will not be closable by the user and the close button will not be rendered.
22840
+ */
22841
+ onRequestClose: (() => void) | undefined;
22831
22842
  /** The size sets the modal width to one of three options sm = 400px, md = 600px and lg = 800px
22832
22843
  * if a width attribute is used the size will be overridden by the width attribute
22833
22844
  * @default 'lg'
@@ -22847,6 +22858,12 @@ type ModalProps = {
22847
22858
  withoutContentBackground?: boolean;
22848
22859
  /** Places buttons at the bottom of the modal */
22849
22860
  buttonGroup?: ReactNode;
22861
+ /**
22862
+ * Disables scrolling of the modal body if the content exceeds the height.
22863
+ * Can be required for modals that have comboboxes where the menu items are expected
22864
+ * to overflow the bounds of the modal.
22865
+ */
22866
+ disableBodyScroll?: boolean;
22850
22867
  } & React__default.HTMLProps<HTMLDialogElement>;
22851
22868
  /**
22852
22869
  * A modal component to open a dialog with a backdrop that covers the whole page.
@@ -22992,7 +23009,7 @@ declare function Pagination({ limit, offset, total, onPageChange, }: {
22992
23009
 
22993
23010
  type CommonParameterProps = {
22994
23011
  /** sets the label value */
22995
- label: string;
23012
+ label: string | ReactNode;
22996
23013
  /** (optional): allows user to pass a component before the label */
22997
23014
  labelLeadingIcon?: ReactNode;
22998
23015
  /** (optional): allows user to pass a component after the label */
@@ -23047,7 +23064,7 @@ type CommonParameterSelectProps = {
23047
23064
  declare const ParameterShellContext: React$1.Context<CommonParameterProps>;
23048
23065
  declare const useParameterShell: () => {
23049
23066
  id: string;
23050
- label: string;
23067
+ label: React$1.ReactNode;
23051
23068
  hiddenLabel: boolean | undefined;
23052
23069
  errorMessage: string | undefined;
23053
23070
  handleManuallySetErrorMessage: ((message: string | undefined) => void) | undefined;
@@ -23401,7 +23418,7 @@ declare const ParameterSelectInner: React$1.ForwardRefExoticComponent<Omit<Param
23401
23418
  declare const extractParameterProps: <T>(props: T & CommonParameterInputProps) => {
23402
23419
  shellProps: {
23403
23420
  id: string;
23404
- label: string;
23421
+ label: ReactNode;
23405
23422
  caption: string | undefined;
23406
23423
  captionTestId: string | undefined;
23407
23424
  errorMessage: string | undefined;
package/dist/index.js CHANGED
@@ -14764,7 +14764,7 @@ var Input = React10.forwardRef(
14764
14764
  errorMessage ? inputError : void 0,
14765
14765
  icon ? inputWithIcon : ""
14766
14766
  ],
14767
- "aria-label": !showLabel ? label : void 0,
14767
+ "aria-label": showLabel || typeof label !== "string" ? void 0 : label,
14768
14768
  className: typeof classNameControl === "string" ? classNameControl : "",
14769
14769
  ...props,
14770
14770
  ref
@@ -16917,6 +16917,9 @@ var ChipOutlined = import_react70.css`
16917
16917
  border-color: var(--outline-color);
16918
16918
  }
16919
16919
  `;
16920
+ var ChipDisabled = import_react70.css`
16921
+ opacity: var(--opacity-50);
16922
+ `;
16920
16923
 
16921
16924
  // src/components/Chip/Chip.tsx
16922
16925
  var import_jsx_runtime62 = require("@emotion/react/jsx-runtime");
@@ -16936,6 +16939,7 @@ var Chip = ({
16936
16939
  theme = "accent-light",
16937
16940
  variant = "solid",
16938
16941
  chipAction,
16942
+ isDisabled = false,
16939
16943
  as = "span",
16940
16944
  ...props
16941
16945
  }) => {
@@ -16952,7 +16956,8 @@ var Chip = ({
16952
16956
  ChipContainer,
16953
16957
  chipSize[size],
16954
16958
  chipTheme[theme],
16955
- variant === "outlined" ? ChipOutlined : void 0
16959
+ variant === "outlined" ? ChipOutlined : void 0,
16960
+ isDisabled ? ChipDisabled : void 0
16956
16961
  ],
16957
16962
  ...props,
16958
16963
  children: [
@@ -20489,8 +20494,9 @@ var modalContentStyles = import_react118.css`
20489
20494
  border-radius: var(--rounded-sm);
20490
20495
  ${scrollbarStyles}
20491
20496
  `;
20492
- var modalDialogWrapper = import_react118.css`
20493
- padding: 0 var(--spacing-lg) var(--spacing-md);
20497
+ var modalDialogWrapper = (hasCloseButton) => import_react118.css`
20498
+ height: 100%;
20499
+ padding: ${hasCloseButton ? 0 : "var(--spacing-md)"} var(--spacing-lg) var(--spacing-md);
20494
20500
  `;
20495
20501
  var modalDialogInnerStyles = import_react118.css`
20496
20502
  // we need to override the gap of the modalInnerStyles when using a modal dialog
@@ -20514,8 +20520,10 @@ var Modal = import_react120.default.forwardRef(
20514
20520
  modalSize = "lg",
20515
20521
  withoutContentPadding = false,
20516
20522
  withoutContentBackground = false,
20523
+ disableBodyScroll = false,
20517
20524
  ...modalProps
20518
20525
  }, ref) => {
20526
+ const mouseDownInsideModal = (0, import_react120.useRef)(false);
20519
20527
  const dialogRef = (0, import_react120.useRef)(null);
20520
20528
  const size = {
20521
20529
  sm: modalSizeSmall,
@@ -20524,7 +20532,7 @@ var Modal = import_react120.default.forwardRef(
20524
20532
  };
20525
20533
  useShortcut({
20526
20534
  handler: () => {
20527
- onRequestClose();
20535
+ onRequestClose == null ? void 0 : onRequestClose();
20528
20536
  },
20529
20537
  shortcut: "escape"
20530
20538
  });
@@ -20557,9 +20565,25 @@ var Modal = import_react120.default.forwardRef(
20557
20565
  }
20558
20566
  },
20559
20567
  css: [modalStyles, !width ? size[modalSize] : void 0],
20560
- style: { width, height: height === "auto" ? "min-content" : height },
20568
+ style: {
20569
+ width,
20570
+ height: height === "auto" ? "min-content" : height,
20571
+ // allows menus rendered in the PortalContext to overflow the modal contents
20572
+ // (internal scrolling of contents is handled on a child element)
20573
+ overflow: "visible"
20574
+ },
20561
20575
  "data-testid": "side-dialog",
20562
- onClick: onRequestClose,
20576
+ onClick: () => {
20577
+ if (mouseDownInsideModal.current) {
20578
+ return;
20579
+ }
20580
+ onRequestClose == null ? void 0 : onRequestClose();
20581
+ },
20582
+ onMouseUp: () => {
20583
+ setTimeout(() => {
20584
+ mouseDownInsideModal.current = false;
20585
+ });
20586
+ },
20563
20587
  onCancel: (e) => {
20564
20588
  e.preventDefault();
20565
20589
  },
@@ -20569,10 +20593,13 @@ var Modal = import_react120.default.forwardRef(
20569
20593
  {
20570
20594
  css: [modalInnerStyles, { height: height === "auto" ? "auto" : "100%" }],
20571
20595
  onClick: (e) => e.stopPropagation(),
20596
+ onMouseDown: () => {
20597
+ mouseDownInsideModal.current = true;
20598
+ },
20572
20599
  children: [
20573
- /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)("div", { css: modalHeaderStyles, children: [
20574
- !header2 ? null : /* @__PURE__ */ (0, import_jsx_runtime102.jsx)("div", { css: modalHeaderHeaderStyles, children: header2 }),
20575
- /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
20600
+ header2 || onRequestClose ? /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)("div", { css: modalHeaderStyles, children: [
20601
+ header2 ? /* @__PURE__ */ (0, import_jsx_runtime102.jsx)("div", { css: modalHeaderHeaderStyles, children: header2 }) : null,
20602
+ onRequestClose ? /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
20576
20603
  Button,
20577
20604
  {
20578
20605
  type: "button",
@@ -20583,15 +20610,16 @@ var Modal = import_react120.default.forwardRef(
20583
20610
  "data-testid": "close-dialog",
20584
20611
  children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(Icon, { icon: import_CgClose5.CgClose, iconColor: "currentColor", size: 24 })
20585
20612
  }
20586
- )
20587
- ] }),
20613
+ ) : null
20614
+ ] }) : null,
20588
20615
  /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(
20589
20616
  "div",
20590
20617
  {
20591
20618
  css: [
20592
20619
  modalContentStyles,
20593
- !withoutContentPadding ? null : { padding: 0 },
20594
- !withoutContentBackground ? null : { background: "transparent" }
20620
+ withoutContentPadding ? { padding: 0 } : null,
20621
+ withoutContentBackground ? { background: "transparent" } : null,
20622
+ disableBodyScroll ? { overflow: "visible" } : null
20595
20623
  ],
20596
20624
  children
20597
20625
  }
@@ -20624,9 +20652,9 @@ var ModalDialog = (0, import_react121.forwardRef)(
20624
20652
  withoutContentPadding: true,
20625
20653
  css: modalDialogInnerStyles,
20626
20654
  width: "",
20627
- children: /* @__PURE__ */ (0, import_jsx_runtime103.jsxs)(VerticalRhythm, { css: modalDialogWrapper, children: [
20655
+ children: /* @__PURE__ */ (0, import_jsx_runtime103.jsxs)(VerticalRhythm, { css: modalDialogWrapper(Boolean(onRequestClose)), children: [
20628
20656
  /* @__PURE__ */ (0, import_jsx_runtime103.jsx)("div", { css: modalHeaderStyles, children: header2 }),
20629
- /* @__PURE__ */ (0, import_jsx_runtime103.jsx)("div", { children }),
20657
+ /* @__PURE__ */ (0, import_jsx_runtime103.jsx)("div", { css: { flex: 1 }, children }),
20630
20658
  /* @__PURE__ */ (0, import_jsx_runtime103.jsx)(HorizontalRhythm, { children: buttonGroup })
20631
20659
  ] })
20632
20660
  }
@@ -22058,7 +22086,7 @@ var ParameterImageInner = (0, import_react142.forwardRef)((props, ref) => {
22058
22086
  type: "text",
22059
22087
  id,
22060
22088
  ref,
22061
- "aria-label": hiddenLabel ? label : void 0,
22089
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
22062
22090
  autoComplete: "off",
22063
22091
  ...props
22064
22092
  }
@@ -22084,7 +22112,7 @@ var ParameterInputInner = (0, import_react143.forwardRef)(
22084
22112
  css: input3,
22085
22113
  id,
22086
22114
  type: props.type || "text",
22087
- "aria-label": hiddenLabel ? label : void 0,
22115
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
22088
22116
  autoComplete: "off",
22089
22117
  ref,
22090
22118
  ...props
@@ -22106,7 +22134,7 @@ var ParameterLink = (0, import_react144.forwardRef)(
22106
22134
  "data-testid": "link-parameter-editor",
22107
22135
  ...shellProps,
22108
22136
  label: innerProps.value ? shellProps.label : "",
22109
- title: !innerProps.value ? shellProps.label : void 0,
22137
+ title: !innerProps.value && typeof shellProps.label === "string" ? shellProps.label : void 0,
22110
22138
  children: /* @__PURE__ */ (0, import_jsx_runtime126.jsx)(
22111
22139
  ParameterLinkInner,
22112
22140
  {
@@ -22134,7 +22162,7 @@ var ParameterLinkInner = (0, import_react144.forwardRef)(
22134
22162
  readOnly: Boolean(props.value),
22135
22163
  id,
22136
22164
  ref,
22137
- "aria-label": hiddenLabel ? label : void 0,
22165
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
22138
22166
  ...props
22139
22167
  }
22140
22168
  ),
@@ -22185,7 +22213,7 @@ var ParameterMultiSelectInner = (props) => {
22185
22213
  isMulti: true,
22186
22214
  isClearable: (_a = props.isClearable) != null ? _a : false,
22187
22215
  id,
22188
- "aria-label": label,
22216
+ "aria-label": typeof label === "string" ? label : void 0,
22189
22217
  classNamePrefix: "parameter-multi-select-combobox",
22190
22218
  styles: {
22191
22219
  menuPortal: (base) => ({
@@ -25073,7 +25101,7 @@ var ParameterSelectInner = (0, import_react160.forwardRef)(
25073
25101
  {
25074
25102
  css: [input3, selectInput],
25075
25103
  id,
25076
- "aria-label": hiddenLabel ? label : void 0,
25104
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
25077
25105
  ref,
25078
25106
  ...props,
25079
25107
  children: [
@@ -25104,7 +25132,7 @@ var ParameterTextareaInner = (0, import_react161.forwardRef)(({ ...props }, ref)
25104
25132
  css: [input3, textarea2],
25105
25133
  id,
25106
25134
  ref,
25107
- "aria-label": hiddenLabel ? label : void 0,
25135
+ "aria-label": hiddenLabel && typeof label === "string" ? label : void 0,
25108
25136
  ...props
25109
25137
  }
25110
25138
  );
@@ -26072,16 +26100,15 @@ var StatusBullet = ({
26072
26100
  Deleted: StatusDeleted
26073
26101
  };
26074
26102
  const statusSize = size === "base" ? StatusBulletBase : StatusBulletSmall;
26075
- return /* @__PURE__ */ (0, import_jsx_runtime144.jsx)(
26103
+ return /* @__PURE__ */ (0, import_jsx_runtime144.jsx)(Tooltip, { title: message != null ? message : status, children: /* @__PURE__ */ (0, import_jsx_runtime144.jsx)(
26076
26104
  "span",
26077
26105
  {
26078
26106
  role: "status",
26079
26107
  css: [StatusBulletContainer, currentStateStyles[status], statusSize],
26080
- title: message != null ? message : status,
26081
26108
  ...props,
26082
26109
  children: hideText ? null : message ? message : status
26083
26110
  }
26084
- );
26111
+ ) });
26085
26112
  };
26086
26113
  // Annotate the CommonJS export names for ESM import in node:
26087
26114
  0 && (module.exports = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uniformdev/design-system",
3
- "version": "19.195.1-alpha.3+0a17ec705c",
3
+ "version": "19.196.1-alpha.2+b5b5fd8fb8",
4
4
  "description": "Uniform design system components",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "main": "./dist/index.js",
@@ -26,8 +26,8 @@
26
26
  "@storybook/theming": "^8.3.3",
27
27
  "@types/react": "18.3.3",
28
28
  "@types/react-dom": "18.3.0",
29
- "@uniformdev/canvas": "^19.195.1-alpha.3+0a17ec705c",
30
- "@uniformdev/richtext": "^19.195.1-alpha.3+0a17ec705c",
29
+ "@uniformdev/canvas": "^19.196.1-alpha.2+b5b5fd8fb8",
30
+ "@uniformdev/richtext": "^19.196.1-alpha.2+b5b5fd8fb8",
31
31
  "autoprefixer": "10.4.16",
32
32
  "hygen": "6.2.11",
33
33
  "postcss": "8.4.38",
@@ -79,5 +79,5 @@
79
79
  "publishConfig": {
80
80
  "access": "public"
81
81
  },
82
- "gitHead": "0a17ec705cf1f0ecd6a944fd1606a857c491579b"
82
+ "gitHead": "b5b5fd8fb8c08700c600b0761efd6723cee2413f"
83
83
  }