@utahdts/utah-design-system 4.2.1 → 4.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -28,7 +28,7 @@
28
28
  }
29
29
  &__wrapper {
30
30
  min-width: 20px;
31
- background: color-swatches.$neutral-gray-08;
31
+ background: color-swatches.$neutral-gray-07;
32
32
  color: white;
33
33
  border-radius: var(--radius-circle);
34
34
  min-height: var(--form-ele-small3x);
package/dist/style.css CHANGED
@@ -3219,7 +3219,7 @@ component specific, BEM (Block, Element, Modifier)
3219
3219
  }
3220
3220
  .utah-design-system .switch__wrapper {
3221
3221
  min-width: 20px;
3222
- background: #7b7b7b;
3222
+ background: #6e6e6e;
3223
3223
  color: white;
3224
3224
  border-radius: var(--radius-circle);
3225
3225
  min-height: var(--form-ele-small3x);
@@ -7,7 +7,7 @@ import { castArray, trim, identity, isFunction, isEqual, uniq, split, cloneDeep,
7
7
  import { useImmer } from "use-immer";
8
8
  import { isValid, format, add, parse } from "date-fns";
9
9
  import { v4 } from "uuid";
10
- const version$1 = "4.2.1";
10
+ const version$1 = "4.3.0";
11
11
  const packageJson = {
12
12
  version: version$1
13
13
  };
@@ -703,6 +703,7 @@ function Accordion({
703
703
  {
704
704
  "aria-hidden": !stateIsOpen,
705
705
  "aria-labelledby": `accordion-button__${id}`,
706
+ inert: !stateIsOpen,
706
707
  className: joinClassNames(["accordion__content", contentClassName, stateIsOpen ? "accordion__content--open" : ""]),
707
708
  id: `accordion-content__${id}`,
708
709
  role: "region",
@@ -1165,6 +1166,7 @@ function TabPanel({ children, className, tabId }) {
1165
1166
  id: `tabpanel__${tabGroupId}__${tabId}`,
1166
1167
  role: "tabpanel",
1167
1168
  tabIndex: selectedTabId === tabId ? 0 : -1,
1169
+ inert: selectedTabId !== tabId,
1168
1170
  children
1169
1171
  }
1170
1172
  );
@@ -3396,7 +3398,6 @@ function MultiSelectComboBox({
3396
3398
  /* @__PURE__ */ jsx(
3397
3399
  IconButton,
3398
3400
  {
3399
- "aria-hidden": "true",
3400
3401
  className: joinClassNames(
3401
3402
  "multi-select__chevron",
3402
3403
  "icon-button--borderless",
@@ -4846,7 +4847,7 @@ function Pagination({
4846
4847
  // @ts-expect-error
4847
4848
  // eslint-disable-next-line react/jsx-props-no-spreading
4848
4849
  /* @__PURE__ */ jsx(WrapInElement, { ref: innerRef, className: joinClassNames("pagination", className), id, "aria-label": ariaLabel, ...rest, children: /* @__PURE__ */ jsxs("ul", { children: [
4849
- /* @__PURE__ */ jsx(
4850
+ /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
4850
4851
  IconButton,
4851
4852
  {
4852
4853
  appearance: ICON_BUTTON_APPEARANCE.BORDERLESS,
@@ -4856,15 +4857,14 @@ function Pagination({
4856
4857
  onClick: useCallback(() => currentOnChange(currentPageIndexRef.current - 1), [currentOnChange, currentPageIndexRef]),
4857
4858
  title: "Previous page"
4858
4859
  }
4859
- ),
4860
- paginationLinks.map((paginationLink, paginationLinkIndex) => paginationLink.isEllipsis ? /* @__PURE__ */ jsx(
4860
+ ) }),
4861
+ paginationLinks.map((paginationLink, paginationLinkIndex) => paginationLink.isEllipsis ? /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
4861
4862
  "span",
4862
4863
  {
4863
4864
  className: "pagination__ellipsis",
4864
4865
  children: /* @__PURE__ */ jsx("span", { className: "utds-icon-before-more-horizontal", "aria-hidden": "true" })
4865
- },
4866
- `pagination-link__ellipsis__${paginationLinkIndex}`
4867
- ) : /* @__PURE__ */ jsx(
4866
+ }
4867
+ ) }, `pagination-link__ellipsis__${paginationLinkIndex}`) : /* @__PURE__ */ jsx(
4868
4868
  PaginationLink,
4869
4869
  {
4870
4870
  currentPageIndex,
@@ -4875,7 +4875,7 @@ function Pagination({
4875
4875
  },
4876
4876
  `pagination-link__${paginationLink.pageIndex}__${paginationLink.title}`
4877
4877
  )),
4878
- /* @__PURE__ */ jsx(
4878
+ /* @__PURE__ */ jsx("li", { children: /* @__PURE__ */ jsx(
4879
4879
  IconButton,
4880
4880
  {
4881
4881
  appearance: ICON_BUTTON_APPEARANCE.BORDERLESS,
@@ -4885,7 +4885,7 @@ function Pagination({
4885
4885
  onClick: useCallback(() => currentOnChange(currentPageIndexRef.current + 1), [currentOnChange, currentPageIndexRef]),
4886
4886
  title: "Next page"
4887
4887
  }
4888
- )
4888
+ ) })
4889
4889
  ] }) })
4890
4890
  );
4891
4891
  }
@@ -5218,6 +5218,7 @@ function Popup({
5218
5218
  ),
5219
5219
  role,
5220
5220
  "data-popup-placement": middlewareData?.offset?.placement || placement,
5221
+ inert: !isVisible,
5221
5222
  ...rest,
5222
5223
  children: /* @__PURE__ */ jsxs("div", { className: "popup__content", children: [
5223
5224
  hasCloseButton ? /* @__PURE__ */ jsx(
@@ -6680,6 +6681,7 @@ function sortByFieldType(sortingRule, fieldValueA, fieldValueB) {
6680
6681
  return result;
6681
6682
  }
6682
6683
  function TableWrapper({
6684
+ allowScrollOverflow,
6683
6685
  children,
6684
6686
  className,
6685
6687
  id,
@@ -6809,7 +6811,17 @@ function TableWrapper({
6809
6811
  ),
6810
6812
  [setState, state, stateRef]
6811
6813
  );
6812
- return /* @__PURE__ */ jsx(TableContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx("div", { className: joinClassNames("table__wrapper", className), id, ref: innerRef, ...rest, children }) });
6814
+ return /* @__PURE__ */ jsx(TableContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx(
6815
+ "div",
6816
+ {
6817
+ className: joinClassNames("table__wrapper", className),
6818
+ id,
6819
+ ref: innerRef,
6820
+ tabIndex: allowScrollOverflow ? 0 : void 0,
6821
+ ...rest,
6822
+ children
6823
+ }
6824
+ ) });
6813
6825
  }
6814
6826
  function MainContent({
6815
6827
  children,
@@ -2,7 +2,7 @@
2
2
  typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("@utahdts/utah-design-system-header"), require("react/jsx-runtime"), require("react"), require("@floating-ui/react-dom"), require("lodash-es"), require("use-immer"), require("date-fns"), require("uuid")) : typeof define === "function" && define.amd ? define(["exports", "@utahdts/utah-design-system-header", "react/jsx-runtime", "react", "@floating-ui/react-dom", "lodash-es", "use-immer", "date-fns", "uuid"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global["@utahdts/utah-design-system"] = {}, global["@utahdts/utah-design-system-header"], global.jsxRuntime, global.React, global["@floating-ui/react-dom"], global["lodash-es"], global.useImmer, global.dateFns, global.uuid));
3
3
  })(this, (function(exports2, utahDesignSystemHeader, jsxRuntime, React, reactDom, lodashEs, useImmer, dateFns, uuid) {
4
4
  "use strict";
5
- const version$1 = "4.2.1";
5
+ const version$1 = "4.3.0";
6
6
  const packageJson = {
7
7
  version: version$1
8
8
  };
@@ -698,6 +698,7 @@
698
698
  {
699
699
  "aria-hidden": !stateIsOpen,
700
700
  "aria-labelledby": `accordion-button__${id}`,
701
+ inert: !stateIsOpen,
701
702
  className: joinClassNames(["accordion__content", contentClassName, stateIsOpen ? "accordion__content--open" : ""]),
702
703
  id: `accordion-content__${id}`,
703
704
  role: "region",
@@ -1160,6 +1161,7 @@
1160
1161
  id: `tabpanel__${tabGroupId}__${tabId}`,
1161
1162
  role: "tabpanel",
1162
1163
  tabIndex: selectedTabId === tabId ? 0 : -1,
1164
+ inert: selectedTabId !== tabId,
1163
1165
  children
1164
1166
  }
1165
1167
  );
@@ -3391,7 +3393,6 @@
3391
3393
  /* @__PURE__ */ jsxRuntime.jsx(
3392
3394
  IconButton,
3393
3395
  {
3394
- "aria-hidden": "true",
3395
3396
  className: joinClassNames(
3396
3397
  "multi-select__chevron",
3397
3398
  "icon-button--borderless",
@@ -4841,7 +4842,7 @@
4841
4842
  // @ts-expect-error
4842
4843
  // eslint-disable-next-line react/jsx-props-no-spreading
4843
4844
  /* @__PURE__ */ jsxRuntime.jsx(WrapInElement, { ref: innerRef, className: joinClassNames("pagination", className), id, "aria-label": ariaLabel, ...rest, children: /* @__PURE__ */ jsxRuntime.jsxs("ul", { children: [
4844
- /* @__PURE__ */ jsxRuntime.jsx(
4845
+ /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx(
4845
4846
  IconButton,
4846
4847
  {
4847
4848
  appearance: ICON_BUTTON_APPEARANCE.BORDERLESS,
@@ -4851,15 +4852,14 @@
4851
4852
  onClick: React.useCallback(() => currentOnChange(currentPageIndexRef.current - 1), [currentOnChange, currentPageIndexRef]),
4852
4853
  title: "Previous page"
4853
4854
  }
4854
- ),
4855
- paginationLinks.map((paginationLink, paginationLinkIndex) => paginationLink.isEllipsis ? /* @__PURE__ */ jsxRuntime.jsx(
4855
+ ) }),
4856
+ paginationLinks.map((paginationLink, paginationLinkIndex) => paginationLink.isEllipsis ? /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx(
4856
4857
  "span",
4857
4858
  {
4858
4859
  className: "pagination__ellipsis",
4859
4860
  children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "utds-icon-before-more-horizontal", "aria-hidden": "true" })
4860
- },
4861
- `pagination-link__ellipsis__${paginationLinkIndex}`
4862
- ) : /* @__PURE__ */ jsxRuntime.jsx(
4861
+ }
4862
+ ) }, `pagination-link__ellipsis__${paginationLinkIndex}`) : /* @__PURE__ */ jsxRuntime.jsx(
4863
4863
  PaginationLink,
4864
4864
  {
4865
4865
  currentPageIndex,
@@ -4870,7 +4870,7 @@
4870
4870
  },
4871
4871
  `pagination-link__${paginationLink.pageIndex}__${paginationLink.title}`
4872
4872
  )),
4873
- /* @__PURE__ */ jsxRuntime.jsx(
4873
+ /* @__PURE__ */ jsxRuntime.jsx("li", { children: /* @__PURE__ */ jsxRuntime.jsx(
4874
4874
  IconButton,
4875
4875
  {
4876
4876
  appearance: ICON_BUTTON_APPEARANCE.BORDERLESS,
@@ -4880,7 +4880,7 @@
4880
4880
  onClick: React.useCallback(() => currentOnChange(currentPageIndexRef.current + 1), [currentOnChange, currentPageIndexRef]),
4881
4881
  title: "Next page"
4882
4882
  }
4883
- )
4883
+ ) })
4884
4884
  ] }) })
4885
4885
  );
4886
4886
  }
@@ -5213,6 +5213,7 @@
5213
5213
  ),
5214
5214
  role,
5215
5215
  "data-popup-placement": middlewareData?.offset?.placement || placement,
5216
+ inert: !isVisible,
5216
5217
  ...rest,
5217
5218
  children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "popup__content", children: [
5218
5219
  hasCloseButton ? /* @__PURE__ */ jsxRuntime.jsx(
@@ -6675,6 +6676,7 @@
6675
6676
  return result;
6676
6677
  }
6677
6678
  function TableWrapper({
6679
+ allowScrollOverflow,
6678
6680
  children,
6679
6681
  className,
6680
6682
  id,
@@ -6804,7 +6806,17 @@
6804
6806
  ),
6805
6807
  [setState, state, stateRef]
6806
6808
  );
6807
- return /* @__PURE__ */ jsxRuntime.jsx(TableContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: joinClassNames("table__wrapper", className), id, ref: innerRef, ...rest, children }) });
6809
+ return /* @__PURE__ */ jsxRuntime.jsx(TableContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxRuntime.jsx(
6810
+ "div",
6811
+ {
6812
+ className: joinClassNames("table__wrapper", className),
6813
+ id,
6814
+ ref: innerRef,
6815
+ tabIndex: allowScrollOverflow ? 0 : void 0,
6816
+ ...rest,
6817
+ children
6818
+ }
6819
+ ) });
6808
6820
  }
6809
6821
  function MainContent({
6810
6822
  children,
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@utahdts/utah-design-system",
3
3
  "description": "Utah Design System React Library",
4
4
  "displayName": "Utah Design System React Library",
5
- "version": "4.2.1",
5
+ "version": "4.3.0",
6
6
  "exports": {
7
7
  ".": {
8
8
  "development-local": "./index.js",
@@ -58,7 +58,7 @@
58
58
  "utah",
59
59
  "components"
60
60
  ],
61
- "author": "DTS Digital Experience <dtsui@utah.gov>",
61
+ "author": "DTS Digital Experience <dxp@utah.gov>",
62
62
  "license": "Apache 2.0",
63
63
  "bugs": {
64
64
  "url": "https://github.com/utahdts/utah-design-system/issues"
@@ -68,26 +68,26 @@
68
68
  "react": "^18.0.0 || ^19.0.0"
69
69
  },
70
70
  "dependencies": {
71
- "@floating-ui/react-dom": "2.1.6",
72
- "@utahdts/utah-design-system-header": "4.2.1",
71
+ "@floating-ui/react-dom": "2.1.7",
72
+ "@utahdts/utah-design-system-header": "4.3.0",
73
73
  "date-fns": "4.1.0",
74
- "immer": "10.2.0",
75
- "lodash-es": "4.17.21",
74
+ "immer": "11.1.4",
75
+ "lodash-es": "4.17.23",
76
76
  "use-immer": "0.11.0",
77
77
  "uuid": "13.0.0"
78
78
  },
79
79
  "devDependencies": {
80
80
  "@types/lodash-es": "4.17.12",
81
- "@types/react": "^19.2.6",
82
- "@vitejs/plugin-react": "5.1.1",
83
- "@vitest/coverage-istanbul": "4.0.10",
84
- "@vitest/ui": "4.0.10",
85
- "jsdom": "27.2.0",
81
+ "@types/react": "^19.2.13",
82
+ "@vitejs/plugin-react": "5.1.4",
83
+ "@vitest/coverage-istanbul": "4.0.18",
84
+ "@vitest/ui": "4.0.18",
85
+ "jsdom": "28.0.0",
86
86
  "prop-types": "15.8.1",
87
- "sass": "1.94.1",
87
+ "sass": "1.97.3",
88
88
  "typescript": "5.9.3",
89
- "vite": "7.2.2",
90
- "vitest": "4.0.10"
89
+ "vite": "7.3.1",
90
+ "vitest": "4.0.18"
91
91
  },
92
92
  "type": "module"
93
93
  }
@@ -59,6 +59,7 @@ export function Accordion({
59
59
  <div
60
60
  aria-hidden={!stateIsOpen}
61
61
  aria-labelledby={`accordion-button__${id}`}
62
+ inert={!stateIsOpen}
62
63
  className={joinClassNames(['accordion__content', contentClassName, stateIsOpen ? 'accordion__content--open' : ''])}
63
64
  id={`accordion-content__${id}`}
64
65
  role="region"
@@ -24,6 +24,7 @@ export function TabPanel({ children, className, tabId }) {
24
24
  id={`tabpanel__${tabGroupId}__${tabId}`}
25
25
  role="tabpanel"
26
26
  tabIndex={selectedTabId === tabId ? 0 : -1}
27
+ inert={selectedTabId !== tabId}
27
28
  >
28
29
  {children}
29
30
  </div>
@@ -202,7 +202,6 @@ export function MultiSelectComboBox({
202
202
  </ComboBox>
203
203
  <MultiSelectClearIcon isClearable={isClearable} isDisabled={isDisabled} />
204
204
  <IconButton
205
- aria-hidden="true"
206
205
  className={joinClassNames(
207
206
  'multi-select__chevron',
208
207
  'icon-button--borderless',
@@ -84,26 +84,28 @@ export function Pagination({
84
84
  // eslint-disable-next-line react/jsx-props-no-spreading
85
85
  <WrapInElement ref={innerRef} className={joinClassNames('pagination', className)} id={id} aria-label={ariaLabel} {...rest}>
86
86
  <ul>
87
- <IconButton
88
- appearance={ICON_BUTTON_APPEARANCE.BORDERLESS}
89
- className="pagination__prev"
90
- icon={<span className="utds-icon-before-arrow-left" aria-hidden="true" />}
91
- isDisabled={currentPageIndex === 0}
92
- onClick={useCallback(() => currentOnChange(currentPageIndexRef.current - 1), [currentOnChange, currentPageIndexRef])}
93
- title="Previous page"
94
- />
87
+ <li>
88
+ <IconButton
89
+ appearance={ICON_BUTTON_APPEARANCE.BORDERLESS}
90
+ className="pagination__prev"
91
+ icon={<span className="utds-icon-before-arrow-left" aria-hidden="true" />}
92
+ isDisabled={currentPageIndex === 0}
93
+ onClick={useCallback(() => currentOnChange(currentPageIndexRef.current - 1), [currentOnChange, currentPageIndexRef])}
94
+ title="Previous page"
95
+ />
96
+ </li>
95
97
 
96
98
  {
97
99
  paginationLinks.map((paginationLink, paginationLinkIndex) => (
98
100
  paginationLink.isEllipsis
99
101
  ? (
100
- <span
101
- className="pagination__ellipsis"
102
- // eslint-disable-next-line react/no-array-index-key
103
- key={`pagination-link__ellipsis__${paginationLinkIndex}`}
104
- >
105
- <span className="utds-icon-before-more-horizontal" aria-hidden="true" />
106
- </span>
102
+ <li key={`pagination-link__ellipsis__${paginationLinkIndex}`}>
103
+ <span
104
+ className="pagination__ellipsis"
105
+ >
106
+ <span className="utds-icon-before-more-horizontal" aria-hidden="true" />
107
+ </span>
108
+ </li>
107
109
  )
108
110
  : (
109
111
  <PaginationLink
@@ -118,14 +120,16 @@ export function Pagination({
118
120
  ))
119
121
  }
120
122
 
121
- <IconButton
122
- appearance={ICON_BUTTON_APPEARANCE.BORDERLESS}
123
- className="pagination__next"
124
- icon={<span className="utds-icon-before-arrow-right" aria-hidden="true" />}
125
- isDisabled={currentPageIndex === numberOfPages - 1}
126
- onClick={useCallback(() => currentOnChange(currentPageIndexRef.current + 1), [currentOnChange, currentPageIndexRef])}
127
- title="Next page"
128
- />
123
+ <li>
124
+ <IconButton
125
+ appearance={ICON_BUTTON_APPEARANCE.BORDERLESS}
126
+ className="pagination__next"
127
+ icon={<span className="utds-icon-before-arrow-right" aria-hidden="true" />}
128
+ isDisabled={currentPageIndex === numberOfPages - 1}
129
+ onClick={useCallback(() => currentOnChange(currentPageIndexRef.current + 1), [currentOnChange, currentPageIndexRef])}
130
+ title="Next page"
131
+ />
132
+ </li>
129
133
  </ul>
130
134
  </WrapInElement>
131
135
  );
@@ -93,6 +93,7 @@ export function Popup({
93
93
  )}
94
94
  role={role}
95
95
  data-popup-placement={middlewareData?.offset?.placement || placement}
96
+ inert={!isVisible}
96
97
  {...rest}
97
98
  >
98
99
  <div className="popup__content">
@@ -57,6 +57,7 @@ function sortByFieldType(sortingRule, fieldValueA, fieldValueB) {
57
57
  /**
58
58
  * @template TableDataT extends TableDataT & { [x: string]: any; }
59
59
  * @param {object} props
60
+ * @param {boolean} [props.allowScrollOverflow]
60
61
  * @param {import('react').ReactNode} props.children
61
62
  * @param {string} [props.className]
62
63
  * @param {import('react').RefObject<HTMLDivElement>} [props.innerRef]
@@ -64,6 +65,7 @@ function sortByFieldType(sortingRule, fieldValueA, fieldValueB) {
64
65
  * @returns {import('react').JSX.Element}
65
66
  */
66
67
  export function TableWrapper({
68
+ allowScrollOverflow,
67
69
  children,
68
70
  className,
69
71
  id,
@@ -212,7 +214,12 @@ export function TableWrapper({
212
214
 
213
215
  return (
214
216
  <TableContext.Provider value={contextValue}>
215
- <div className={joinClassNames('table__wrapper', className)} id={id} ref={innerRef} {...rest}>
217
+ <div
218
+ className={joinClassNames('table__wrapper', className)}
219
+ id={id} ref={innerRef}
220
+ tabIndex={allowScrollOverflow ? 0 : undefined}
221
+ {...rest}
222
+ >
216
223
  {children}
217
224
  </div>
218
225
  </TableContext.Provider>