@iress-oss/ids-components 6.0.0-alpha.6 → 6.0.0-alpha.7

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.
Files changed (45) hide show
  1. package/dist/{Autocomplete-C5ubHBTi.js → Autocomplete-BQ_YPb5A.js} +1 -1
  2. package/dist/{Button-mmhMLwp9.js → Button-B4nt3P1v.js} +13 -22
  3. package/dist/{Provider-BPeo5YfI.js → Provider-CDIbqQK0.js} +2 -2
  4. package/dist/components/Alert/Alert.js +1 -1
  5. package/dist/components/Autocomplete/Autocomplete.js +2 -2
  6. package/dist/components/Autocomplete/index.js +1 -1
  7. package/dist/components/Button/Button.js +1 -1
  8. package/dist/components/Button/CloseButton/CloseButton.js +1 -1
  9. package/dist/components/Button/index.js +1 -1
  10. package/dist/components/Checkbox/Checkbox.styles.js +5 -2
  11. package/dist/components/CheckboxMark/CheckboxMark.styles.js +3 -3
  12. package/dist/components/Filter/Filter.js +2 -2
  13. package/dist/components/Filter/components/FilterResetButton.js +1 -1
  14. package/dist/components/Input/Input.js +1 -1
  15. package/dist/components/Input/Input.styles.js +2 -3
  16. package/dist/components/Label/LabelBase/LabelBase.js +28 -23
  17. package/dist/components/Modal/Modal.js +39 -38
  18. package/dist/components/Modal/Modal.styles.js +23 -0
  19. package/dist/components/Provider/Provider.js +2 -2
  20. package/dist/components/Provider/index.js +1 -1
  21. package/dist/components/Radio/Radio.js +41 -41
  22. package/dist/components/Radio/Radio.styles.js +7 -2
  23. package/dist/components/RichSelect/RichSelect.js +2 -2
  24. package/dist/components/RichSelect/SelectHeading/SelectHeading.js +1 -1
  25. package/dist/components/RichSelect/SelectLabel/SelectLabel.styles.js +2 -4
  26. package/dist/components/RichSelect/SelectTags/SelectTags.js +1 -1
  27. package/dist/components/RichSelect/SelectTags/SelectTags.styles.js +3 -5
  28. package/dist/components/RichSelect/index.js +1 -1
  29. package/dist/components/Select/Select.styles.js +4 -1
  30. package/dist/components/SkipLink/SkipLink.js +1 -1
  31. package/dist/components/Slideout/components/SlideoutInner.js +1 -1
  32. package/dist/components/Tag/Tag.js +1 -1
  33. package/dist/components/Toaster/components/Toast/Toast.js +1 -1
  34. package/dist/components/Toggle/Toggle.styles.js +4 -3
  35. package/dist/constants.js +1 -1
  36. package/dist/enums.js +3 -3
  37. package/dist/main.js +3 -3
  38. package/dist/patterns/Loading/components/ValidateLoading.js +1 -1
  39. package/dist/patterns/Shadow/Shadow.js +64 -64
  40. package/dist/src/components/Modal/Modal.d.ts +8 -1
  41. package/dist/src/components/Modal/Modal.styles.d.ts +23 -0
  42. package/dist/src/components/Radio/Radio.styles.d.ts +1 -1
  43. package/dist/src/enums.d.ts +2 -1
  44. package/dist/style.css +1 -1
  45. package/package.json +2 -2
@@ -31,7 +31,7 @@ import "./components/RichSelect/SelectMenu/SelectMenu.styles.js";
31
31
  import "./components/RichSelect/SelectSearch/SelectSearch.styles.js";
32
32
  import "./components/RichSelect/SelectSearchInput/SelectSearchInput.js";
33
33
  import "./components/RichSelect/SelectTags/SelectTags.styles.js";
34
- import "./Button-mmhMLwp9.js";
34
+ import "./Button-B4nt3P1v.js";
35
35
  import "./components/Button/CloseButton/CloseButton.js";
36
36
  import "./components/Tag/Tag.styles.js";
37
37
  import "./components/Tag/TagInput/TagInput.js";
@@ -172,15 +172,6 @@ const h = {}, Z = [
172
172
  }
173
173
  }
174
174
  },
175
- {
176
- mode: "primary",
177
- inButtonGroup: !0,
178
- css: {
179
- root: {
180
- boxShadow: "none"
181
- }
182
- }
183
- },
184
175
  {
185
176
  mode: "tertiary",
186
177
  inButtonGroup: !0,
@@ -265,25 +256,25 @@ const h = {}, Z = [
265
256
  append: e,
266
257
  children: t,
267
258
  className: d,
268
- element: p,
259
+ element: l,
269
260
  fluid: x,
270
261
  loading: r = !1,
271
262
  mode: y = "secondary",
272
- prepend: l,
263
+ prepend: p,
273
264
  noWrap: C = !1,
274
265
  onClick: b,
275
266
  status: F,
276
- value: w,
267
+ value: I,
277
268
  ...g
278
- }, B) => {
279
- const i = E(), I = w ?? (typeof t == "string" || typeof t == "number" || typeof t == "boolean" ? t : void 0), G = W(Y), m = k(null), n = U({ value: I }), H = u(() => n ? n.active ? "primary" : "tertiary" : y, [n, y]), s = so({
269
+ }, w) => {
270
+ const i = E(), B = I ?? (typeof t == "string" || typeof t == "number" || typeof t == "boolean" ? t : void 0), H = W(Y), m = k(null), n = U({ value: B }), G = u(() => n ? n.active ? "primary" : "tertiary" : y, [n, y]), s = so({
280
271
  active: (
281
272
  // eslint-disable-next-line react-hooks/refs -- ref needed for forwarding
282
- o ?? G?.isActiveActivator(m.current)
273
+ o ?? H?.isActiveActivator(m.current)
283
274
  ),
284
275
  fluid: x === !0 ? "true" : x,
285
276
  inButtonGroup: !!n,
286
- mode: H,
277
+ mode: G,
287
278
  loading: !!r,
288
279
  noWrap: C,
289
280
  status: F
@@ -298,7 +289,7 @@ const h = {}, Z = [
298
289
  ), P = u(
299
290
  () => ({
300
291
  children: /* @__PURE__ */ M(N, { children: [
301
- l && !r && /* @__PURE__ */ a("span", { className: s.prepend, children: l }),
292
+ p && !r && /* @__PURE__ */ a("span", { className: s.prepend, children: p }),
302
293
  !!r && /* @__PURE__ */ a(
303
294
  O,
304
295
  {
@@ -327,7 +318,7 @@ const h = {}, Z = [
327
318
  d,
328
319
  v,
329
320
  r,
330
- l,
321
+ p,
331
322
  i,
332
323
  _,
333
324
  s.append,
@@ -336,16 +327,16 @@ const h = {}, Z = [
336
327
  s.spinner
337
328
  ]
338
329
  );
339
- K(B, () => m.current);
330
+ K(w, () => m.current);
340
331
  const V = u(
341
- () => p ?? (c.href ? "a" : "button"),
342
- [p, c.href]
332
+ () => l ?? (c.href ? "a" : "button"),
333
+ [l, c.href]
343
334
  );
344
335
  return /* @__PURE__ */ a(
345
336
  V,
346
337
  {
347
338
  "aria-describedby": r ? i : void 0,
348
- type: p || !c.href ? "button" : void 0,
339
+ type: l || !c.href ? "button" : void 0,
349
340
  ...P,
350
341
  ...n?.props,
351
342
  ...c,
@@ -1,7 +1,7 @@
1
1
  import { jsxs as $, jsx as r } from "react/jsx-runtime";
2
2
  import "./components/Modal/Modal.styles.js";
3
3
  import "react";
4
- import "./Button-mmhMLwp9.js";
4
+ import "./Button-B4nt3P1v.js";
5
5
  import "./components/Button/CloseButton/CloseButton.js";
6
6
  import "./components/Modal/hooks/useModal.js";
7
7
  import { IressModalProvider as n } from "./components/Modal/ModalProvider.js";
@@ -16,7 +16,7 @@ import { IressSlideoutProvider as d } from "./components/Slideout/SlideoutProvid
16
16
  import { createPortal as y } from "react-dom";
17
17
  var o = /* @__PURE__ */ ((e) => (e.Color = "color", e.Dimension = "dimension", e.FontFamily = "fontFamily", e.FontSize = "fontSize", e.Background = "background", e.Border = "border", e.Radius = "radius", e.Shadow = "shadow", e.Typography = "typography", e))(o || {});
18
18
  o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color, o.Color;
19
- o.Shadow, o.Border, o.Shadow, o.Border, o.Shadow, o.Border, o.Shadow, o.Shadow, o.Color;
19
+ o.Shadow, o.Border, o.Shadow, o.Border, o.Shadow, o.Border, o.Shadow, o.Color, o.Shadow, o.Color;
20
20
  o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Radius, o.Radius, o.Radius, o.Radius;
21
21
  o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension, o.Dimension;
22
22
  const h = [
@@ -7,7 +7,7 @@ import { propagateTestid as h } from "../../helpers/utility/propagateTestid.js";
7
7
  import { alert as w } from "./Alert.styles.js";
8
8
  import { c as N } from "../../cx-DN21T1EH.js";
9
9
  import { GlobalCSSClass as B } from "../../enums.js";
10
- import { I as E } from "../../Button-mmhMLwp9.js";
10
+ import { I as E } from "../../Button-B4nt3P1v.js";
11
11
  import { IressCloseButton as V } from "../Button/CloseButton/CloseButton.js";
12
12
  import "../Inline/Inline.styles.js";
13
13
  import { IressInline as $ } from "../Inline/Inline.js";
@@ -16,7 +16,7 @@ import "../../helpers/form/getFormControlValueAsStringIfDefined.js";
16
16
  import "./hooks/useAutocompleteSearch.js";
17
17
  import "../Icon/Icon.js";
18
18
  import "./components/AutocompleteInstructions.js";
19
- import { a as R } from "../../Autocomplete-C5ubHBTi.js";
19
+ import { a as R } from "../../Autocomplete-BQ_YPb5A.js";
20
20
  import "../RichSelect/SelectBody/SelectBody.styles.js";
21
21
  import "../../enums.js";
22
22
  import "../Menu/Menu.js";
@@ -30,7 +30,7 @@ import "../RichSelect/SelectMenu/SelectMenu.js";
30
30
  import "../RichSelect/SelectSearch/SelectSearch.styles.js";
31
31
  import "../RichSelect/SelectSearchInput/SelectSearchInput.js";
32
32
  import "../RichSelect/SelectTags/SelectTags.styles.js";
33
- import "../../Button-mmhMLwp9.js";
33
+ import "../../Button-B4nt3P1v.js";
34
34
  import "../Button/CloseButton/CloseButton.js";
35
35
  import "../Tag/Tag.styles.js";
36
36
  import "../Tag/TagInput/TagInput.js";
@@ -1,4 +1,4 @@
1
- import { a as t } from "../../Autocomplete-C5ubHBTi.js";
1
+ import { a as t } from "../../Autocomplete-BQ_YPb5A.js";
2
2
  import { autoComplete as m } from "./Autocomplete.styles.js";
3
3
  import { useAutocompleteSearch as a } from "./hooks/useAutocompleteSearch.js";
4
4
  export {
@@ -9,7 +9,7 @@ import "../../cx-DN21T1EH.js";
9
9
  import "../../is-valid-prop-Ce0wiweq.js";
10
10
  import "../ButtonGroup/ButtonGroupProvider.js";
11
11
  import "../ButtonGroup/hooks/useButtonGroupItem.js";
12
- import { I as B } from "../../Button-mmhMLwp9.js";
12
+ import { I as B } from "../../Button-B4nt3P1v.js";
13
13
  import "../Popover/hooks/usePopover.js";
14
14
  export {
15
15
  B as IressButton
@@ -1,5 +1,5 @@
1
1
  import { jsx as o } from "react/jsx-runtime";
2
- import { I as e } from "../../../Button-mmhMLwp9.js";
2
+ import { I as e } from "../../../Button-B4nt3P1v.js";
3
3
  import { IressIcon as a } from "../../Icon/Icon.js";
4
4
  import "../../Icon/Icon.styles.js";
5
5
  import { forwardRef as i } from "react";
@@ -1,4 +1,4 @@
1
- import { I as s, b as r } from "../../Button-mmhMLwp9.js";
1
+ import { I as s, b as r } from "../../Button-B4nt3P1v.js";
2
2
  import { IressCloseButton as n } from "./CloseButton/CloseButton.js";
3
3
  export {
4
4
  s as IressButton,
@@ -16,7 +16,8 @@ const o = r({
16
16
  root: {
17
17
  color: "colour.primary.fill",
18
18
  display: "flex",
19
- position: "relative"
19
+ position: "relative",
20
+ textStyle: "typography.body.md"
20
21
  },
21
22
  input: {
22
23
  srOnly: !0
@@ -28,7 +29,9 @@ const o = r({
28
29
  display: "inline-flex",
29
30
  cursor: "pointer"
30
31
  },
31
- labelSpan: {},
32
+ labelSpan: {
33
+ font: "inherit"
34
+ },
32
35
  mark: {
33
36
  color: "[currentColor]",
34
37
  marginInlineEnd: "spacing.2",
@@ -5,9 +5,9 @@ const e = r({
5
5
  root: {
6
6
  display: "inline-flex",
7
7
  position: "relative",
8
- width: "[calc(1.5 * {sizes.typography.base})]",
9
- minWidth: "[calc(1.5 * {sizes.typography.base})]",
10
- height: "[calc(1.5 * {sizes.typography.base})]",
8
+ width: "[1.4em]",
9
+ minWidth: "[1.4em]",
10
+ height: "[1.4em]",
11
11
  borderWidth: "1px",
12
12
  borderStyle: "solid",
13
13
  borderColor: "colour.neutral.70",
@@ -7,10 +7,10 @@ import { IressPopover as ae } from "../Popover/Popover.js";
7
7
  import "../Popover/Popover.styles.js";
8
8
  import "../Popover/InputPopover/InputPopover.js";
9
9
  import "../Popover/hooks/usePopover.js";
10
- import { I as ne } from "../../Button-mmhMLwp9.js";
10
+ import { I as ne } from "../../Button-B4nt3P1v.js";
11
11
  import "../Button/CloseButton/CloseButton.js";
12
12
  import { useRichSelectState as me } from "../RichSelect/hooks/useRichSelectState.js";
13
- import "../../Autocomplete-C5ubHBTi.js";
13
+ import "../../Autocomplete-BQ_YPb5A.js";
14
14
  import "../RichSelect/SelectBody/SelectBody.styles.js";
15
15
  import { GlobalCSSClass as pe } from "../../enums.js";
16
16
  import { useIdIfNeeded as le } from "../../hooks/useIdIfNeeded.js";
@@ -1,5 +1,5 @@
1
1
  import { jsx as n } from "react/jsx-runtime";
2
- import { I as i } from "../../../Button-mmhMLwp9.js";
2
+ import { I as i } from "../../../Button-B4nt3P1v.js";
3
3
  import "../../Button/CloseButton/CloseButton.js";
4
4
  import { filter as p } from "../Filter.styles.js";
5
5
  import { usePopoverItem as f } from "../../Popover/hooks/usePopoverItem.js";
@@ -13,7 +13,7 @@ import { input as Q } from "./Input.styles.js";
13
13
  import { s as W } from "../../factory-oPXoMw9H.js";
14
14
  import { s as X } from "../../is-valid-prop-Ce0wiweq.js";
15
15
  import { useNoDefaultValueInForms as Y } from "../../patterns/Form/hooks/useNoDefaultValueInForms.js";
16
- import "../../Button-mmhMLwp9.js";
16
+ import "../../Button-B4nt3P1v.js";
17
17
  import { IressCloseButton as Z } from "../Button/CloseButton/CloseButton.js";
18
18
  const _ = ({ rows: a, ...f }, S) => {
19
19
  const {
@@ -1,5 +1,5 @@
1
1
  import { s as r } from "../../sva-OmxClA9g.js";
2
- const t = r({
2
+ const o = r({
3
3
  slots: ["root", "wrapper", "inline", "addon", "internal", "formControl"],
4
4
  base: {
5
5
  wrapper: {
@@ -12,7 +12,6 @@ const t = r({
12
12
  flexGrow: "1",
13
13
  border: "input",
14
14
  "&:has(input:focus, textarea:focus)": {
15
- borderColor: "colour.primary.fill",
16
15
  layerStyle: "elevation.focus"
17
16
  }
18
17
  },
@@ -205,5 +204,5 @@ const t = r({
205
204
  defaultVariants: {}
206
205
  });
207
206
  export {
208
- t as input
207
+ o as input
209
208
  };
@@ -1,47 +1,52 @@
1
- import { jsxs as l, jsx as a, Fragment as b } from "react/jsx-runtime";
2
- import { GlobalCSSClass as g } from "../../../enums.js";
1
+ import { jsxs as i, jsx as s, Fragment as g } from "react/jsx-runtime";
2
+ import { GlobalCSSClass as c } from "../../../enums.js";
3
3
  import { propagateTestid as y } from "../../../helpers/utility/propagateTestid.js";
4
4
  import { useState as C, useMemo as S } from "react";
5
5
  import { s as r } from "../../../factory-oPXoMw9H.js";
6
6
  import { label as j } from "../Label.styles.js";
7
7
  import { c as q } from "../../../cx-DN21T1EH.js";
8
- const R = ({
8
+ const M = ({
9
9
  append: o,
10
- children: c,
11
- className: p,
10
+ children: p,
11
+ className: d,
12
12
  "data-testid": m,
13
13
  element: n,
14
14
  hiddenLabel: t = !1,
15
- required: d,
16
- ...f
15
+ required: f,
16
+ ...u
17
17
  }) => {
18
- const [i, u] = C(), e = j({ hasAppend: !!o, hiddenLabel: t }), x = (h) => {
19
- const s = h?.textContent;
20
- s && s !== i && u(s);
21
- }, N = S(
18
+ const [l, x] = C(), e = j({ hasAppend: !!o, hiddenLabel: t }), N = (h) => {
19
+ const a = h?.textContent;
20
+ a && a !== l && x(a);
21
+ }, b = S(
22
22
  () => r(n ?? "label"),
23
23
  [n]
24
24
  );
25
- return /* @__PURE__ */ l(
26
- N,
25
+ return /* @__PURE__ */ i(
26
+ b,
27
27
  {
28
- className: q(p, g.FormLabel, e.root),
28
+ className: q(
29
+ d,
30
+ c.FormLabel,
31
+ c.Label,
32
+ e.root
33
+ ),
29
34
  "data-testid": m,
30
- ...f,
31
- "data-name": i,
35
+ ...u,
36
+ "data-name": l,
32
37
  children: [
33
- d && /* @__PURE__ */ l(b, { children: [
34
- !t && /* @__PURE__ */ a("span", { className: e.required, "aria-hidden": !0, children: "*" }),
35
- /* @__PURE__ */ a(r.span, { srOnly: !0, children: "Required" })
38
+ f && /* @__PURE__ */ i(g, { children: [
39
+ !t && /* @__PURE__ */ s("span", { className: e.required, "aria-hidden": !0, children: "*" }),
40
+ /* @__PURE__ */ s(r.span, { srOnly: !0, children: "Required" })
36
41
  ] }),
37
- /* @__PURE__ */ a(
42
+ /* @__PURE__ */ s(
38
43
  r.span,
39
44
  {
40
45
  className: e.text,
41
46
  "data-testid": y(m, "text"),
42
- ref: x,
47
+ ref: N,
43
48
  srOnly: t,
44
- children: c
49
+ children: p
45
50
  }
46
51
  ),
47
52
  o
@@ -50,5 +55,5 @@ const R = ({
50
55
  );
51
56
  };
52
57
  export {
53
- R as LabelBase
58
+ M as LabelBase
54
59
  };
@@ -1,8 +1,8 @@
1
- import { jsx as n, jsxs as w } from "react/jsx-runtime";
2
- import { useState as Z, useEffect as N, useMemo as oo } from "react";
3
- import "../../Button-mmhMLwp9.js";
1
+ import { jsx as n, jsxs as N } from "react/jsx-runtime";
2
+ import { useState as Z, useEffect as w, useMemo as oo } from "react";
3
+ import "../../Button-B4nt3P1v.js";
4
4
  import { IressCloseButton as eo } from "../Button/CloseButton/CloseButton.js";
5
- import { u as to, b as ro, c as so, d as no, e as ao, F as io, f as lo, g as co } from "../../floating-ui.react-BetVZ099.js";
5
+ import { u as to, b as so, c as ro, d as no, e as ao, F as io, f as lo, g as co } from "../../floating-ui.react-BetVZ099.js";
6
6
  import { idsLogger as mo } from "../../helpers/utility/idsLogger.js";
7
7
  import { propagateTestid as l } from "../../helpers/utility/propagateTestid.js";
8
8
  import { useIdIfNeeded as fo } from "../../hooks/useIdIfNeeded.js";
@@ -33,80 +33,81 @@ const Ro = ({
33
33
  onStatus: b,
34
34
  onTransitionEnd: _,
35
35
  show: c,
36
+ size: $ = "md",
36
37
  static: a,
37
- style: $,
38
+ style: G,
38
39
  ...m
39
40
  }) => {
40
- const [G, L] = Z(E);
41
+ const [L, U] = Z(E);
41
42
  let y = 240;
42
- const s = go(m.id), F = fo({ id: m.id }), f = `${F}--heading`, U = s.opened || c || G, I = (o) => {
43
- s.show(o), L(o), R?.(o);
43
+ const r = go(m.id), F = fo({ id: m.id }), f = `${F}--heading`, q = r.opened || c || L, I = (o) => {
44
+ r.show(o), U(o), R?.(o);
44
45
  }, { context: e } = to({
45
- open: U,
46
+ open: q,
46
47
  onOpenChange: I
47
- }), q = ro(e, {
48
+ }), z = so(e, {
48
49
  enabled: !B,
49
50
  outsidePress: (o) => !o.target.closest(`.${p.Toaster}`),
50
51
  outsidePressEvent: "mousedown"
51
- }), z = so(e), A = no([q, z]);
52
+ }), A = ro(e), H = no([z, A]);
52
53
  e.refs.floating.current && (y = yo(
53
54
  e.refs.floating.current,
54
55
  1.2,
55
56
  240
56
57
  ));
57
- const { isMounted: H, status: i } = ao(e, {
58
+ const { isMounted: J, status: i } = ao(e, {
58
59
  duration: {
59
60
  close: y
60
61
  }
61
- }), r = ho({
62
+ }), s = ho({
62
63
  fixedFooter: T,
64
+ size: $,
63
65
  static: a,
64
66
  status: i
65
- }), [J, K] = bo(m), { p: v = "lg", width: Q = "overlay.md", ...V } = J;
66
- N(() => {
67
- s.opened && c && mo(
67
+ }), [K, Q] = bo(m), { p: x = "lg", ...V } = K;
68
+ w(() => {
69
+ r.opened && c && mo(
68
70
  "IressModal: Please use either IressModalProvider for uncontrolled components, or the show prop for controlled components, rather than both. If you use both, the open state of the modal will become unpredictable. If you want to show a modal by default in uncontrolled mode, use the defaultShow prop."
69
71
  );
70
- }, [s.opened, c]), N(() => {
72
+ }, [r.opened, c]), w(() => {
71
73
  b?.(i);
72
74
  }, [i, b]);
73
- const x = oo(() => typeof d == "string" ? /* @__PURE__ */ n(
75
+ const M = oo(() => typeof d == "string" ? /* @__PURE__ */ n(
74
76
  po,
75
77
  {
76
- className: r.header,
78
+ className: s.header,
77
79
  id: f,
78
80
  element: "h2",
79
81
  "data-testid": l(t, "heading"),
80
82
  children: d
81
83
  }
82
- ) : d, [t, f, d, r.header]), W = (o) => {
84
+ ) : d, [t, f, d, s.header]), W = (o) => {
83
85
  _?.(o), !(!(o.propertyName === "opacity" || !o.propertyName) || o.target !== o.currentTarget) && (i === "open" ? (D?.(), a || e.refs.floating?.current?.focus()) : i === "close" && O?.());
84
86
  };
85
- if (!H) return null;
86
- const M = /* @__PURE__ */ n(
87
+ if (!J) return null;
88
+ const v = /* @__PURE__ */ n(
87
89
  io,
88
90
  {
89
- className: C(k, r.backdrop, p.ModalBackdrop),
91
+ className: C(k, s.backdrop, p.ModalBackdrop),
90
92
  "data-testid": l(t, "backdrop"),
91
93
  lockScroll: !a,
92
- style: $,
94
+ style: G,
93
95
  children: /* @__PURE__ */ n(
94
96
  lo,
95
97
  {
96
98
  context: e,
97
99
  initialFocus: e.refs.floating,
98
100
  disabled: a,
99
- children: /* @__PURE__ */ w(
101
+ children: /* @__PURE__ */ N(
100
102
  u.div,
101
103
  {
102
104
  ref: (o) => e.refs.setFloating(o),
103
- className: C(r.modal, uo(), p.Modal),
105
+ className: C(s.modal, uo(), p.Modal),
104
106
  id: F,
105
107
  "data-testid": t,
106
- "aria-labelledby": x ? f : void 0,
107
- ...A.getFloatingProps(K),
108
+ "aria-labelledby": M ? f : void 0,
109
+ ...H.getFloatingProps(Q),
108
110
  ...V,
109
- w: Q,
110
111
  onTransitionEnd: W,
111
112
  children: [
112
113
  !j && /* @__PURE__ */ n(
@@ -114,18 +115,18 @@ const Ro = ({
114
115
  {
115
116
  onClick: () => I(!1),
116
117
  screenreaderText: S,
117
- className: r.closeButton,
118
+ className: s.closeButton,
118
119
  "data-testid": l(t, "close-button__button")
119
120
  }
120
121
  ),
121
- /* @__PURE__ */ w(
122
+ /* @__PURE__ */ N(
122
123
  u.div,
123
124
  {
124
- className: r.content,
125
+ className: s.content,
125
126
  "data-testid": l(t, "content"),
126
- p: v,
127
+ p: x,
127
128
  children: [
128
- x,
129
+ M,
129
130
  P
130
131
  ]
131
132
  }
@@ -133,9 +134,9 @@ const Ro = ({
133
134
  h && /* @__PURE__ */ n(
134
135
  u.div,
135
136
  {
136
- className: r.footer,
137
+ className: s.footer,
137
138
  "data-testid": l(t, "footer"),
138
- p: v,
139
+ p: x,
139
140
  children: h
140
141
  }
141
142
  )
@@ -145,8 +146,8 @@ const Ro = ({
145
146
  }
146
147
  )
147
148
  }
148
- ), X = g ?? s?.container;
149
- return a && !X ? M : /* @__PURE__ */ n(co, { root: g ?? s?.container, children: M });
149
+ ), X = g ?? r?.container;
150
+ return a && !X ? v : /* @__PURE__ */ n(co, { root: g ?? r?.container, children: v });
150
151
  };
151
152
  export {
152
153
  Ro as IressModal
@@ -73,6 +73,29 @@ const o = [
73
73
  }
74
74
  }
75
75
  },
76
+ /**
77
+ * Size of the modal
78
+ * - `sm`: Small modals communicate the outcome of an irreversible action. They should be concise and straightforward, containing a single action and, in some cases, a single input field.
79
+ * - `md`: Medium modals provide optional supporting information to help users understand the context of a word or screen. They may contain a single action and, in some cases, a larger input such as a textarea.
80
+ * - `lg`: Large modals are used for more complex tasks that require multiple steps or a lot of information as well as media such as video and PDF documents. They can contain multiple actions, inputs, and supporting information.
81
+ */
82
+ size: {
83
+ sm: {
84
+ modal: {
85
+ width: "overlay.sm"
86
+ }
87
+ },
88
+ md: {
89
+ modal: {
90
+ width: "overlay.md"
91
+ }
92
+ },
93
+ lg: {
94
+ modal: {
95
+ width: "overlay.lg"
96
+ }
97
+ }
98
+ },
76
99
  /**
77
100
  * The state of the modal.
78
101
  */
@@ -1,7 +1,7 @@
1
1
  import "react/jsx-runtime";
2
2
  import "../Modal/Modal.styles.js";
3
3
  import "react";
4
- import "../../Button-mmhMLwp9.js";
4
+ import "../../Button-B4nt3P1v.js";
5
5
  import "../Button/CloseButton/CloseButton.js";
6
6
  import "../Modal/hooks/useModal.js";
7
7
  import "../Modal/ModalProvider.js";
@@ -14,7 +14,7 @@ import "../../index-aTLA1VIV.js";
14
14
  import "../Slideout/hooks/useSlideout.js";
15
15
  import "../Slideout/SlideoutProvider.js";
16
16
  import "react-dom";
17
- import { I as h } from "../../Provider-BPeo5YfI.js";
17
+ import { I as h } from "../../Provider-CDIbqQK0.js";
18
18
  export {
19
19
  h as IressProvider
20
20
  };
@@ -1,4 +1,4 @@
1
- import { I as o } from "../../Provider-BPeo5YfI.js";
1
+ import { I as o } from "../../Provider-CDIbqQK0.js";
2
2
  export {
3
3
  o as IressProvider
4
4
  };