@moda/om 21.2.0 → 21.2.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moda/om",
3
- "version": "21.2.0",
3
+ "version": "21.2.1",
4
4
  "description": "Moda Operandi design system",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",
@@ -48,106 +48,104 @@
48
48
  "react-router-dom": "^5.1.2"
49
49
  },
50
50
  "dependencies": {
51
- "@moda/icons": "^6.0.0",
52
- "@moda/tokens": "^6.3.4",
51
+ "@moda/icons": "^6.1.14",
52
+ "@moda/tokens": "^6.4.58",
53
53
  "@mona-health/react-input-mask": "^3.0.3",
54
54
  "@storybook/addon-styling": "^2.0.0",
55
55
  "classnames": "^2.5.1",
56
56
  "credit-card-type": "^10.0.2",
57
57
  "focus-visible": "^5.2.1",
58
58
  "proportional-scale": "^4.0.0",
59
- "react-focus-on": "^3.9.4",
59
+ "react-focus-on": "^3.10.0",
60
60
  "scroll-into-view-if-needed": "^3.1.0",
61
- "storybook": "^8.6.12",
61
+ "storybook": "^9.0.17",
62
62
  "use-cursor": "^1.2.3"
63
63
  },
64
64
  "devDependencies": {
65
- "@babel/core": "^7.26.10",
66
- "@babel/preset-env": "^7.26.9",
67
- "@babel/preset-react": "^7.26.3",
68
- "@babel/preset-typescript": "^7.27.0",
69
- "@commitlint/cli": "^19.8.0",
70
- "@commitlint/config-conventional": "^19.8.0",
71
- "@eslint/js": "^9.24.0",
65
+ "@babel/core": "^7.28.0",
66
+ "@babel/preset-env": "^7.28.0",
67
+ "@babel/preset-react": "^7.27.1",
68
+ "@babel/preset-typescript": "^7.27.1",
69
+ "@commitlint/cli": "^19.8.1",
70
+ "@commitlint/config-conventional": "^19.8.1",
71
+ "@eslint/js": "^9.31.0",
72
72
  "@moda/rollup-plugin-postcss": "^4.0.1",
73
73
  "@rollup/plugin-babel": "^6.0.4",
74
- "@rollup/plugin-commonjs": "^28.0.3",
74
+ "@rollup/plugin-commonjs": "^28.0.6",
75
75
  "@rollup/plugin-node-resolve": "^16.0.1",
76
- "@storybook/addon-actions": "^8.6.12",
77
- "@storybook/addon-essentials": "^8.6.12",
78
- "@storybook/addon-links": "^8.6.12",
76
+ "@storybook/addon-links": "^9.0.17",
79
77
  "@storybook/addon-postcss": "^2.0.0",
80
- "@storybook/addon-viewport": "^8.6.12",
81
78
  "@storybook/addon-webpack5-compiler-babel": "^3.0.6",
82
79
  "@storybook/addons": "^7.6.17",
83
- "@storybook/react": "^8.6.12",
84
- "@storybook/react-webpack5": "^8.6.12",
80
+ "@storybook/react": "^9.0.17",
81
+ "@storybook/react-webpack5": "^9.0.17",
85
82
  "@testing-library/jest-dom": "^6.6.3",
86
83
  "@testing-library/react": "^16.3.0",
87
84
  "@testing-library/user-event": "^14.6.1",
88
- "@types/cheerio": "^0.22.35",
85
+ "@types/chai": "^5.2.2",
86
+ "@types/cheerio": "^1.0.0",
89
87
  "@types/classnames": "^2.3.4",
90
88
  "@types/credit-card-type": "^9.0.3",
91
- "@types/jest": "^29.5.14",
89
+ "@types/jest": "^30.0.0",
92
90
  "@types/ramda": "^0.30.2",
93
- "@types/react": "^19.1.2",
94
- "@types/react-dom": "^19.1.2",
91
+ "@types/react": "^19.1.8",
92
+ "@types/react-dom": "^19.1.6",
95
93
  "@types/react-input-mask": "^3.0.6",
96
94
  "@types/react-router-dom": "^5.3.3",
97
- "@typescript-eslint/eslint-plugin": "^8.30.1",
98
- "@typescript-eslint/parser": "^8.30.1",
95
+ "@typescript-eslint/eslint-plugin": "^8.37.0",
96
+ "@typescript-eslint/parser": "^8.37.0",
99
97
  "autoprefixer": "^10.4.21",
100
98
  "babel-loader": "^10.0.0",
101
99
  "commitizen": "^4.3.1",
102
100
  "css-loader": "^7.1.2",
103
101
  "cz-conventional-changelog": "^3.3.0",
104
- "eslint": "^9.24.0",
105
- "eslint-config-prettier": "^10.1.2",
106
- "eslint-plugin-import": "^2.31.0",
102
+ "eslint": "^9.31.0",
103
+ "eslint-config-prettier": "^10.1.5",
104
+ "eslint-plugin-import": "^2.32.0",
107
105
  "eslint-plugin-jest-dom": "^5.5.0",
108
106
  "eslint-plugin-jsx-a11y": "^6.10.2",
109
107
  "eslint-plugin-no-loops": "^0.4.0",
110
108
  "eslint-plugin-node": "^11.1.0",
111
- "eslint-plugin-prettier": "^5.2.6",
109
+ "eslint-plugin-prettier": "^5.5.1",
112
110
  "eslint-plugin-promise": "^7.2.1",
113
111
  "eslint-plugin-react": "^7.37.5",
114
112
  "eslint-plugin-react-hooks": "^5.2.0",
115
113
  "eslint-plugin-standard": "^5.0.0",
116
- "eslint-plugin-testing-library": "^7.1.1",
117
- "globals": "^16.0.0",
114
+ "eslint-plugin-testing-library": "^7.6.0",
115
+ "globals": "^16.3.0",
118
116
  "husky": "^9.1.7",
119
117
  "identity-obj-proxy": "^3.0.0",
120
118
  "ignore-not-found-export-webpack-plugin": "^1.0.2",
121
- "jest": "^29.7.0",
122
- "jest-environment-jsdom": "^29.7.0",
119
+ "jest": "^30.0.4",
120
+ "jest-environment-jsdom": "^30.0.4",
123
121
  "jest-matchmedia-mock": "^1.1.0",
124
- "lint-staged": "^16.0.0",
122
+ "lint-staged": "^16.1.2",
125
123
  "node-sass-package-importer": "^5.3.3",
126
124
  "pinst": "^3.0.0",
127
- "postcss": "^8.5.3",
125
+ "postcss": "^8.5.6",
128
126
  "postcss-loader": "^8.1.1",
129
- "prettier": "^3.5.3",
130
- "ramda": "^0.30.1",
127
+ "prettier": "^3.6.2",
128
+ "ramda": "^0.31.3",
131
129
  "react": "^19.1.0",
132
130
  "react-dom": "^19.1.0",
133
131
  "react-router-dom": "^5.1.2",
134
- "rollup": "^4.40.0",
132
+ "rollup": "^4.45.1",
135
133
  "rollup-plugin-peer-deps-external": "^2.2.4",
136
134
  "rollup-plugin-scss": "^4.0.1",
137
- "sass": "^1.86.3",
135
+ "sass": "^1.89.2",
138
136
  "sass-loader": "^16.0.5",
139
- "semantic-release": "^24.2.3",
137
+ "semantic-release": "^24.2.7",
140
138
  "semantic-release-npm-github": "^5.0.0",
141
139
  "style-loader": "^4.0.0",
142
- "ts-jest": "^29.3.2",
140
+ "ts-jest": "^29.4.0",
143
141
  "typescript": "^5.8.3",
144
- "typescript-eslint": "^8.30.1",
142
+ "typescript-eslint": "^8.37.0",
145
143
  "waait": "^1.0.5",
146
- "webpack": "^5.99.5",
144
+ "webpack": "^5.100.2",
147
145
  "webpack-cli": "^6.0.1"
148
146
  },
149
147
  "overrides": {
150
- "@types/react": "^19.1.2",
148
+ "@types/react": "^19.1.8",
151
149
  "react": "^19.1.0",
152
150
  "react-dom": "^19.1.0"
153
151
  },
@@ -12,8 +12,8 @@ describe('Breadcrumbs', () => {
12
12
  <Breadcrumb>Three</Breadcrumb>
13
13
  </Breadcrumbs>
14
14
  );
15
- expect(screen.getAllByRole('listitem').at(0)).toHaveAttribute('itemprop');
16
- expect(screen.getAllByRole('listitem').at(0)).toHaveAttribute('itemscope');
17
- expect(screen.getAllByRole('listitem').at(0)).toHaveAttribute('itemtype');
15
+ expect(screen.getAllByRole('listitem')[0]).toHaveAttribute('itemprop');
16
+ expect(screen.getAllByRole('listitem')[0]).toHaveAttribute('itemscope');
17
+ expect(screen.getAllByRole('listitem')[0]).toHaveAttribute('itemtype');
18
18
  });
19
19
  });
@@ -1,6 +1,6 @@
1
1
  /* eslint-disable no-console */
2
2
  import React from 'react';
3
- import { action } from '@storybook/addon-actions';
3
+ import { action } from 'storybook/actions';
4
4
  import { breakpoints } from '@moda/tokens';
5
5
 
6
6
  import { Breakpoint } from './Breakpoint';
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { BrowserRouter } from 'react-router-dom';
3
- import { action } from '@storybook/addon-actions';
3
+ import { action } from 'storybook/actions';
4
4
  import Heart from '@moda/icons/favorite-outline-16';
5
5
 
6
6
  import { States } from '../../utilities';
@@ -17,6 +17,6 @@ describe('Button', () => {
17
17
  render(<Button onClick={onClick}>Click me</Button>);
18
18
 
19
19
  await user.click(screen.getByRole('button', { name: 'Click me' }));
20
- expect(onClick).toBeCalled();
20
+ expect(onClick).toHaveBeenCalled();
21
21
  });
22
22
  });
@@ -15,7 +15,7 @@ describe('Checkbox', () => {
15
15
 
16
16
  await userEvent.click(screen.getByTestId('checkbox'));
17
17
 
18
- expect(handleChange).toBeCalled();
18
+ expect(handleChange).toHaveBeenCalled();
19
19
  expect(screen.getByRole('checkbox') as HTMLInputElement).toBeChecked();
20
20
 
21
21
  rerender(<Checkbox data-testid='checkbox' checked={false} onChange={handleChange} />);
@@ -31,7 +31,7 @@ describe('Checkbox', () => {
31
31
 
32
32
  await userEvent.click(screen.getByTestId('checkbox'));
33
33
 
34
- expect(handleChange).toBeCalled();
34
+ expect(handleChange).toHaveBeenCalled();
35
35
  expect(screen.getByRole('checkbox') as HTMLInputElement).toBeChecked();
36
36
  });
37
37
  });
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { BrowserRouter } from 'react-router-dom';
4
4
  import { States } from '../../utilities';
5
5
  import { Clickable, ClickableProps } from './Clickable';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { States } from '../../utilities';
4
4
  import { Stack } from '../Stack';
5
5
  import { ColorSwatch, ColorSwatchProps, SKU_COLORS } from '.';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { BrowserRouter } from 'react-router-dom';
4
4
  import { States } from '../../utilities';
5
5
  import { ControlLink, ControlLinkProps } from './ControlLink';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { States } from '../../utilities';
4
4
  import { Textarea } from '../Textarea';
5
5
  import { Select } from '../Select';
@@ -24,11 +24,11 @@ describe('Modal', () => {
24
24
  const button = screen.getByTestId('button');
25
25
 
26
26
  await userEvent.click(button);
27
- expect(onClose).toBeCalledTimes(0);
28
- expect(onClickButton).toBeCalledTimes(1);
27
+ expect(onClose).toHaveBeenCalledTimes(0);
28
+ expect(onClickButton).toHaveBeenCalledTimes(1);
29
29
 
30
30
  await userEvent.click(modal);
31
- expect(onClose).toBeCalledTimes(1);
32
- expect(onClickButton).toBeCalledTimes(1);
31
+ expect(onClose).toHaveBeenCalledTimes(1);
32
+ expect(onClickButton).toHaveBeenCalledTimes(1);
33
33
  });
34
34
  });
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { Paginator } from './Paginator';
4
4
 
5
5
  export default { title: 'Components/Paginator' };
@@ -1,5 +1,5 @@
1
1
  import React, { useState, useEffect } from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { States } from '../../utilities';
4
4
  import { Text } from '../Text';
5
5
  import { SearchInput, SearchInputProps } from './SearchInput';
@@ -1,5 +1,5 @@
1
1
  import React, { useEffect, useState, useCallback } from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { States } from '../../utilities';
4
4
  import { Input } from '../Field';
5
5
  import { Select, SelectProps } from './Select';
@@ -65,7 +65,7 @@ describe('Select', () => {
65
65
  await userEvent.click(button);
66
66
  const option = screen.getByLabelText('Bar');
67
67
  await userEvent.click(option);
68
- expect(onChange).toBeCalledWith('bar');
68
+ expect(onChange).toHaveBeenCalledWith('bar');
69
69
  });
70
70
 
71
71
  it('does not call onChange when selecting a disabled option', async () => {
@@ -84,7 +84,7 @@ describe('Select', () => {
84
84
  await userEvent.click(button);
85
85
  const option = screen.getByLabelText('Baz');
86
86
  await userEvent.click(option);
87
- expect(onChange).not.toBeCalled();
87
+ expect(onChange).not.toHaveBeenCalled();
88
88
  });
89
89
 
90
90
  it('renders correctly with ":" between label and value if value is not undefined', async () => {
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
 
4
4
  import { States } from '../../utilities';
5
5
  import { Stack } from '../Stack';
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { States } from '../../utilities';
4
4
  import { Tag, TagProps } from './Tag';
5
5
 
@@ -11,6 +11,6 @@ describe('Tag', () => {
11
11
  expect(screen.getByText('Hello')).toBeInTheDocument();
12
12
 
13
13
  await userEvent.click(screen.getByRole('button'));
14
- expect(onRemove).toBeCalled();
14
+ expect(onRemove).toHaveBeenCalled();
15
15
  });
16
16
  });
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { action } from '@storybook/addon-actions';
2
+ import { action } from 'storybook/actions';
3
3
  import { States } from '../../utilities';
4
4
  import { Toast, ToastProps } from './Toast';
5
5
 
@@ -15,6 +15,6 @@ describe('Toast', () => {
15
15
  expect(screen.getByText('Hello')).toBeInTheDocument();
16
16
 
17
17
  await userEvent.click(screen.getByRole('button', { name: 'Remove' }));
18
- expect(onRemove).toBeCalled();
18
+ expect(onRemove).toHaveBeenCalled();
19
19
  });
20
20
  });
@@ -153,7 +153,7 @@ describe('useKeyboardListNavigation', () => {
153
153
 
154
154
  fireEvent.keyDown(window, { key: 'Enter' });
155
155
 
156
- expect(onEnter).toBeCalledTimes(1);
156
+ expect(onEnter).toHaveBeenCalledTimes(1);
157
157
  expect(onEnter).toHaveBeenCalledWith({
158
158
  element: 'first',
159
159
  event: expect.anything(),
@@ -166,7 +166,7 @@ describe('useKeyboardListNavigation', () => {
166
166
 
167
167
  fireEvent.keyDown(window, { key: 'Enter' });
168
168
 
169
- expect(onEnter).toBeCalledTimes(2);
169
+ expect(onEnter).toHaveBeenCalledTimes(2);
170
170
  expect(onEnter).toHaveBeenLastCalledWith({
171
171
  element: 'third',
172
172
  event: expect.anything(),
@@ -220,13 +220,13 @@ describe('useKeyboardListNavigation', () => {
220
220
 
221
221
  fireEvent.keyDown(window, { key: 'Enter' });
222
222
 
223
- expect(onEnter).toBeCalledTimes(0);
223
+ expect(onEnter).toHaveBeenCalledTimes(0);
224
224
 
225
225
  fireEvent.keyDown(window, { key: 'ArrowDown' });
226
226
 
227
227
  fireEvent.keyDown(window, { key: 'Enter' });
228
228
 
229
- expect(onEnter).toBeCalledTimes(1);
229
+ expect(onEnter).toHaveBeenCalledTimes(1);
230
230
  });
231
231
  });
232
232
  });