@raspberrypifoundation/design-system-react 2.7.3 → 2.9.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.
Files changed (49) hide show
  1. package/README.md +16 -7
  2. package/dist/design-system-react.css +1 -1
  3. package/dist/design-system-react.js +3284 -830
  4. package/dist/design-system-react.umd.cjs +16 -13
  5. package/dist/scss/components/switch.scss +179 -0
  6. package/dist/scss/design-system-core.scss +3 -2
  7. package/dist/scss/properties/colors/_greys.scss +1 -0
  8. package/dist/scss/utility/_visually-hidden.scss +11 -0
  9. package/dist/types/lib/main.d.ts +10 -0
  10. package/dist/types/lib/main.d.ts.map +1 -1
  11. package/dist/types/src/components/Accordion/index.d.ts +1 -1
  12. package/dist/types/src/components/Accordion/index.d.ts.map +1 -1
  13. package/dist/types/src/components/Button/index.d.ts.map +1 -1
  14. package/dist/types/src/components/Form/Switch/Switch.spec.d.ts +2 -0
  15. package/dist/types/src/components/Form/Switch/Switch.spec.d.ts.map +1 -0
  16. package/dist/types/src/components/Form/Switch/Switch.types.d.ts +24 -0
  17. package/dist/types/src/components/Form/Switch/Switch.types.d.ts.map +1 -0
  18. package/dist/types/src/components/Form/Switch/index.d.ts +16 -0
  19. package/dist/types/src/components/Form/Switch/index.d.ts.map +1 -0
  20. package/dist/types/src/components/Menu/Menu.types.d.ts +6 -0
  21. package/dist/types/src/components/Menu/Menu.types.d.ts.map +1 -0
  22. package/dist/types/src/components/Menu/MenuButton/MenuButton.types.d.ts +7 -0
  23. package/dist/types/src/components/Menu/MenuButton/MenuButton.types.d.ts.map +1 -0
  24. package/dist/types/src/components/Menu/MenuButton/index.d.ts +4 -0
  25. package/dist/types/src/components/Menu/MenuButton/index.d.ts.map +1 -0
  26. package/dist/types/src/components/Menu/MenuItem/MenuItem.types.d.ts +11 -0
  27. package/dist/types/src/components/Menu/MenuItem/MenuItem.types.d.ts.map +1 -0
  28. package/dist/types/src/components/Menu/MenuItem/index.d.ts +6 -0
  29. package/dist/types/src/components/Menu/MenuItem/index.d.ts.map +1 -0
  30. package/dist/types/src/components/Menu/MenuTitle/MenuTitle.types.d.ts +4 -0
  31. package/dist/types/src/components/Menu/MenuTitle/MenuTitle.types.d.ts.map +1 -0
  32. package/dist/types/src/components/Menu/MenuTitle/index.d.ts +5 -0
  33. package/dist/types/src/components/Menu/MenuTitle/index.d.ts.map +1 -0
  34. package/dist/types/src/components/Menu/index.d.ts +5 -0
  35. package/dist/types/src/components/Menu/index.d.ts.map +1 -0
  36. package/dist/types/src/stories/Accordion.stories.d.ts +17 -0
  37. package/dist/types/src/stories/Accordion.stories.d.ts.map +1 -1
  38. package/dist/types/src/stories/Menu/Menu.stories.d.ts +8 -0
  39. package/dist/types/src/stories/Menu/Menu.stories.d.ts.map +1 -0
  40. package/dist/types/src/stories/Menu/MenuButton.stories.d.ts +7 -0
  41. package/dist/types/src/stories/Menu/MenuButton.stories.d.ts.map +1 -0
  42. package/dist/types/src/stories/Menu/MenuItem.stories.d.ts +9 -0
  43. package/dist/types/src/stories/Menu/MenuItem.stories.d.ts.map +1 -0
  44. package/dist/types/src/stories/Menu/MenuTitle.stories.d.ts +7 -0
  45. package/dist/types/src/stories/Menu/MenuTitle.stories.d.ts.map +1 -0
  46. package/dist/types/src/stories/forms/Switch.stories.d.ts +54 -0
  47. package/dist/types/src/stories/forms/Switch.stories.d.ts.map +1 -0
  48. package/package.json +18 -13
  49. package/CHANGELOG.md +0 -334
package/CHANGELOG.md DELETED
@@ -1,334 +0,0 @@
1
- # Changelog
2
-
3
- All notable changes to this project will be documented in this file.
4
-
5
- The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
-
7
- ## 2.7.3 - 2025-12-05
8
-
9
- ### Changed
10
-
11
- - Allow form components to use native props in typed applications. (#172)
12
-
13
- ## 2.7.2 - 2025-11-28
14
-
15
- ### Changed
16
-
17
- - Fieldset, InputField, SelectInput, TextareaInput, TextInput, RadioInput and InputLabel have Typescript typing for props. (#169)
18
-
19
- ## 2.7.1 - 2025-11-13
20
-
21
- ### Changed
22
-
23
- - The HeaderCell component now uses Lucide arrow icons for sortable columns to make it clear which columns are sortable and which columns are currently being sorted. (#166)
24
-
25
- ## 2.7.0 - 2025-10-21
26
-
27
- ### Added
28
-
29
- - Add support for using React 19, but keeping react 18 as the default for now. (#159)
30
-
31
- ### Changed
32
-
33
- - Table, HeaderCell and BodyCell have Typescript typing for props. (#162)
34
- - The HeaderCell is clickable if it has a sort direction, and adds `aria-sort`. (#163)
35
-
36
- ## 2.6.2 - 2025-09-18
37
-
38
- ### Changed
39
-
40
- - Types are now exported in `main.ts` for CheckboxInput, SearchInput, Alert, Button, Tag and ProgressBar. (#160)
41
-
42
- ## 2.6.1 - 2025-09-18
43
-
44
- ### Changed
45
-
46
- - CheckboxInput, SearchInput, Alert, Button, Tag and ProgressBar have Typescript typing for props. (#156)
47
- - `Alert` props are now enforced at the type level - you cannot have `title` and `titleChildren` at the same time, nor `text` and `children`.
48
-
49
- ## 2.6.0 - 2025-09-12
50
-
51
- ### Added
52
-
53
- - Migration-optimised Typescript configuration (#149)
54
- - Modal component, including typing
55
-
56
- ## 2.5.0 - 2025-09-11
57
-
58
- ### Changed
59
-
60
- - `Alert` title can accept custom children (#152)
61
-
62
- ## 2.4.2 - 2025-07-30
63
-
64
- ### Changed
65
-
66
- - Improved `SearchInput` accessibility:
67
- - Wrapped component in semantic `<search>` element and a `<form>` element
68
- - Moved `onClick` handler to the `form` element
69
- - Changed button type to `submit`
70
-
71
- It should now be possible for users to submit their input using the keyboard 'enter' key without having to tab to the button.
72
-
73
- ## 2.4.1 - 2025-07-30
74
-
75
- ### Changed
76
-
77
- - Upgrade Design System Core to v2.3.1
78
-
79
- ## 2.4.0 - 2025-07-15
80
-
81
- ### Changed
82
-
83
- - Material Symbols now loads using Google Fonts instead of a local package to better support use in web components
84
-
85
- ## 2.3.0 - 2025-07-02
86
-
87
- ### Added
88
-
89
- - `complete` prop to `ProgressBar`
90
- - `className` prop to `ProgressBar`
91
-
92
- ### Changed
93
-
94
- - Upgrade Design System Core to v2.3.0
95
-
96
- ## Fixed
97
-
98
- - Checkbox using the wrong HTML causing styling issues.
99
-
100
- ## 2.2.0 - 2025-04-14
101
-
102
- ### Changed
103
-
104
- - Modify build output to ensure CRA based projects are able to import the components correctly
105
- - Upgrade dependencies and improve storybook loading
106
-
107
- ### Removed
108
-
109
- - Remove react-router-dom Link from the Button component, instead optionally allow it to be passed in as a prop.
110
- To use it:
111
-
112
- ```jsx
113
- import { Link } from "react-router-dom";
114
- import { Button } from "@raspberrypifoundation/design-system-react";
115
-
116
- <Button
117
- href="/some-path"
118
- linkComponent={Link}
119
- // other props
120
- />;
121
- ```
122
-
123
- ## 2.1.0 - 2025-02-26
124
-
125
- ### Added
126
-
127
- - Checkbox component now supports a custom class (122)
128
-
129
- ## 2.0 - 2025-02-12
130
-
131
- - Updated Storybook Introduction (#119)
132
- - Moved to use Vite for development (#114)
133
- - Include all design-system-core components into the package so design system core can be removed as dependency from library users
134
- (see [UPDATING.md](UPDATING.md) for more details)
135
- - design-system-core version included is 2.0.0
136
-
137
- ## v1.7.0 - 2024-12-03
138
-
139
- ### Added
140
-
141
- - Added support for closing `Alert`s (#112)
142
- - Update the design-system-core requirement to >2.0.0
143
-
144
- ### Changed
145
-
146
- - Update README so labels show (#110)
147
-
148
- ## v1.6.0 - 2024-10-24
149
-
150
- ### Changed
151
-
152
- - Update to use yarn instead of npm and set peerdependency for react-router-dom (#98)
153
- - Update InputField, SearchInput, SelectInput, TextInput and TextareaInput to link label to input field correctly using id (#107)
154
- - Update `README.md` to include global header (#97)
155
- - Update the search input to accept an onChange function and a default value. Add button type to the search button. (#108)
156
-
157
- ## v1.5.0
158
-
159
- ## Fixed
160
-
161
- - Fix (#103) using wrong version number (#106)
162
- - Fix (#101) being added to wrong release in changelog (#103)
163
-
164
- ### Changed
165
-
166
- - Alert component can now accept children (#101)
167
-
168
- ## v1.4.0
169
-
170
- ### Added
171
-
172
- - Table component (#92)
173
-
174
- ## v1.3.1
175
-
176
- ### Fixed
177
-
178
- - Fixed `exports` change in 1.3.0 (#89) to use relative path in `package.json`
179
-
180
- ## v1.3.0
181
-
182
- ### Changed
183
-
184
- - Use `exports` instead of `main`/`module` in `package.json` to define what is exported (#89)
185
-
186
- ## v1.2.1
187
-
188
- ### Fixed
189
-
190
- - Added missing Tag export
191
-
192
- ## v1.2.0
193
-
194
- ### Added
195
-
196
- - SearchInput component (#82)
197
- - InputLabel component (#71)
198
- - Fieldset component (#70)
199
- - Add changelog update check to github workflow (#73)
200
- - Tag component (#81)
201
- - Add details to `README.md` on using `npm link` with `design-system-core` (#80)
202
-
203
- ### Changed
204
-
205
- - Update design-system-core to v1.3.2
206
- - Update nodejs to latest LTS release (v20.16.0) to match design-system-core (#77)
207
-
208
- ## Fixed
209
-
210
- - Update `.nvmrc` to match `.tool_versions` in order to fix builds (#84)
211
-
212
- ## v1.1.16
213
-
214
- ### Added
215
-
216
- - TextareaInput component
217
- - RadioInput component
218
- - Updated `design-system-core` to `v1.1.1`
219
-
220
- ## v1.1.15
221
-
222
- ### Fixed
223
-
224
- - Updated Core to v1.1.0
225
- - Update `ProgressBar` as per https://github.com/RaspberryPiFoundation/design-system-core/pull/124
226
- - This does not result in breaking changes to this library
227
-
228
- ## v1.1.14
229
-
230
- ### Fixed
231
-
232
- - Remove defaultProps from accordion
233
-
234
- ## v1.1.13
235
-
236
- ### Fixed
237
-
238
- - Ensure aria-label on button is passed through unchanged
239
-
240
- ## v1.1.12
241
-
242
- ### Fixed
243
-
244
- - Only change the paragraph spacing of the alerts
245
-
246
- ## v1.1.11
247
-
248
- ### Fixed
249
-
250
- - Fix linting by assigning options to a variable
251
- - Remove reliance on defaultProps (to be deprecated)
252
- - Tidy up alert padding
253
-
254
- ## v1.1.9
255
-
256
- - Fixing `rollup` config
257
-
258
- ## v1.1.8
259
-
260
- ### Changed
261
-
262
- - `Button` component now uses the `react-router-dom` `Link` component for links rather than a plain anchor tag
263
-
264
- ## v1.1.7
265
-
266
- ### Fixed
267
-
268
- - Fixed legacy `Button` component use case with React element as icon
269
-
270
- ## v1.1.6
271
-
272
- ### Fixed
273
-
274
- - Exports Alert component
275
-
276
- ## v1.1.5
277
-
278
- ### Added
279
-
280
- - Alert component added
281
-
282
- ## v1.1.4
283
-
284
- ### Fixed
285
-
286
- - Fixes bug with SelectInput to allow setting of placeholder value
287
-
288
- ## v1.1.0
289
-
290
- ### Added
291
-
292
- - v1.1 TextInput component added
293
- - v1.1 SelectInput component added
294
- - v1.1 CheckboxInput component added
295
- - v1.1 ProgressBar component added
296
-
297
- ## v1.0.0
298
-
299
- ### Added
300
-
301
- - Button additions to bring in line with Core ([#15](https://github.com/RaspberryPiFoundation/design-system-react/pull/15))
302
- - Added: Icon library/font (same as core)
303
- - Added prop: iconPosition
304
- - Added prop: variant, danger
305
- - Added prop: fullWidth
306
- - Storybook: Enabled icon changing
307
- - Storybook: Added link to icon names
308
- - Storybook: Added button docs
309
- - General storybook additions ([#15](https://github.com/RaspberryPiFoundation/design-system-react/pull/15))
310
- - Storybook: Added pseudo-state addon
311
- - Storybook: Added "Install" docs
312
- - Storybook: Added docs styles
313
-
314
- ### Changed
315
-
316
- - Button changes to bring in line with Core ([#15](https://github.com/RaspberryPiFoundation/design-system-react/pull/15))
317
- - Renamed prop: enabled -> disabled
318
- - Renamed prop: textAlways -> iconOnly
319
- - Renamed prop: small -> size
320
- - Removed prop: active
321
- - Removed prop: textOnHover (not actually used/functional)
322
- - Changed prop: icon, now uses same icon font as core.
323
-
324
- ### Removed
325
-
326
- - Button changes to bring in line with Core ([#15](https://github.com/RaspberryPiFoundation/design-system-react/pull/15))
327
- - Removed prop: active
328
- - Removed prop: textOnHover (not actually used/functional)
329
-
330
- ### Fixed
331
-
332
- - General storybook improvements ([#15](https://github.com/RaspberryPiFoundation/design-system-react/pull/15))
333
- - Storybook: Updated "Introduction" docs
334
- - Storybook: Reordered addons