uikit-react-public 0.43.2 → 0.43.4

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 (57) hide show
  1. package/dist/components/Paragraph/Paragraph.d.ts +1 -1
  2. package/dist/index.js +4108 -3963
  3. package/lib/components/Accordion/Accordion.Heading.tsx +0 -2
  4. package/lib/components/Accordion/__tests__/__snapshots__/Accordion.test.tsx.snap +2 -2
  5. package/lib/components/Alert/__tests__/__snapshots__/Alert.test.tsx.snap +4 -4
  6. package/lib/components/Avatar/Avatar.tsx +7 -1
  7. package/lib/components/Avatar/__tests__/__snapshots__/Avatar.test.tsx.snap +12 -12
  8. package/lib/components/Badge/Badge.tsx +6 -11
  9. package/lib/components/Badge/__tests__/__snapshots__/Badge.test.tsx.snap +9 -9
  10. package/lib/components/Button/Button.tsx +11 -7
  11. package/lib/components/Button/__tests__/__snapshots__/Button.test.tsx.snap +9 -9
  12. package/lib/components/Calendar/__tests__/__snapshots__/Calendar.test.tsx.snap +18 -18
  13. package/lib/components/Calendar/subcomponents/AcademicWeek.tsx +7 -5
  14. package/lib/components/Calendar/subcomponents/ColumnHeading.tsx +12 -7
  15. package/lib/components/Calendar/subcomponents/ControlsSelect.tsx +11 -6
  16. package/lib/components/Checkbox/__tests__/__snapshots__/Checkbox.test.tsx.snap +2 -2
  17. package/lib/components/Datepicker/__tests__/__snapshots__/Datepicker.test.tsx.snap +2 -2
  18. package/lib/components/DrawerMenu/DrawerMenu.tsx +4 -3
  19. package/lib/components/DropdownMenu/DropdownMenu.tsx +4 -3
  20. package/lib/components/DropdownUserMenu/DropdownUserMenu.tsx +8 -5
  21. package/lib/components/Field/CharacterCount.tsx +7 -6
  22. package/lib/components/Field/ErrorText.tsx +7 -6
  23. package/lib/components/FileInput/FileInput.tsx +11 -3
  24. package/lib/components/FileInput/__tests__/__snapshots__/FileInput.test.tsx.snap +4 -4
  25. package/lib/components/Footer/Footer.tsx +16 -3
  26. package/lib/components/Footer/FooterColumn.tsx +9 -4
  27. package/lib/components/Footer/__tests__/__snapshots__/Footer.test.tsx.snap +13 -11
  28. package/lib/components/FooterNew/BackToTop.tsx +12 -4
  29. package/lib/components/FooterNew/FooterColumn.tsx +4 -0
  30. package/lib/components/FooterNew/FooterNavLink.tsx +12 -6
  31. package/lib/components/FooterNew/LegalAndCopyright.tsx +11 -6
  32. package/lib/components/FooterNew/LogoAddressAndSocial.tsx +27 -15
  33. package/lib/components/FooterNew/__tests__/__snapshots__/Footer.test.tsx.snap +32 -26
  34. package/lib/components/HeaderDraft/HeaderBottomBreadcrumbs.tsx +6 -1
  35. package/lib/components/HeaderDraft/HeaderBottomHeadingAndAvatar.tsx +19 -8
  36. package/lib/components/HeaderDraft/HeaderBreadcrumb.tsx +11 -2
  37. package/lib/components/HeaderDraft/HeaderDraft.tsx +16 -5
  38. package/lib/components/HeaderDraft/__tests__/__snapshots__/Header.test.tsx.snap +7 -7
  39. package/lib/components/HeaderNew/HeaderItem.tsx +6 -0
  40. package/lib/components/Input/__tests__/__snapshots__/Input.test.tsx.snap +4 -4
  41. package/lib/components/Menu/MenuContent.tsx +9 -1
  42. package/lib/components/NativeDatepicker/NativeDatepicker.tsx +6 -2
  43. package/lib/components/Pagination/PaginationInfo.tsx +8 -6
  44. package/lib/components/Pagination/subcomponents/PaginationCompactControls.tsx +8 -2
  45. package/lib/components/Pagination/subcomponents/PaginationStandardControls.tsx +2 -1
  46. package/lib/components/Paragraph/Paragraph.tsx +6 -4
  47. package/lib/components/Paragraph/__tests__/Paragraph.test.tsx +1 -1
  48. package/lib/components/Paragraph/__tests__/__snapshots__/Paragraph.test.tsx.snap +9 -9
  49. package/lib/components/Radio/__tests__/__snapshots__/Radio.test.tsx.snap +2 -2
  50. package/lib/components/Search/__tests__/__snapshots__/Search.test.tsx.snap +2 -2
  51. package/lib/components/Select/__tests__/__snapshots__/Select.test.tsx.snap +1 -1
  52. package/lib/components/Table/subcomponents/Cell/__tests__/__snapshots__/Cell.test.tsx.snap +2 -2
  53. package/lib/components/Table/subcomponents/HeadCell/__tests__/__snapshots__/HeadCell.test.tsx.snap +1 -1
  54. package/lib/components/Textarea/__tests__/__snapshots__/Textarea.test.tsx.snap +4 -4
  55. package/lib/components/Tooltip/Tooltip.tsx +5 -8
  56. package/lib/components/Tooltip/__tests__/__snapshots__/tooltip.test.tsx.snap +2 -2
  57. package/package.json +2 -2
@@ -149,6 +149,14 @@ const PaginationCompactControls = ({
149
149
  `;
150
150
 
151
151
  const pageInputStyle = css`
152
+ && {
153
+ font-family: ${theme.typography.body.md.fontFamily};
154
+ font-feature-settings: ${theme.typography.body.md.fontSettings};
155
+ font-size: ${theme.typography.body.md.fontSize}px;
156
+ font-weight: ${theme.typography.body.md.fontWeight};
157
+ line-height: ${theme.typography.body.md.lineHeight}%;
158
+ }
159
+
152
160
  height: 48px;
153
161
  width: 48px;
154
162
  box-sizing: border-box;
@@ -157,8 +165,6 @@ const PaginationCompactControls = ({
157
165
  padding: 0;
158
166
  text-align: center;
159
167
  color: ${theme.colour.text.default};
160
- font-family: ${theme.typography.body.md.fontFamily};
161
- font-size: ${theme.typography.body.md.fontSize};
162
168
 
163
169
  &[aria-invalid='true'] {
164
170
  border-color: ${theme.colour.border.critical};
@@ -3,6 +3,7 @@ import { css, cx } from '@emotion/css';
3
3
  import useTheme from '../../../theme/useTheme';
4
4
  import { PaginationContext } from '../Pagination';
5
5
  import Button from '../../Button';
6
+ import Text from '../../Text';
6
7
  import getPaginationButtons from '../getPaginationButtons';
7
8
  import { useMediaQuery } from '../../../hooks';
8
9
 
@@ -187,7 +188,7 @@ const PaginationStandardControls = ({
187
188
  {paginationButtons.map((page) => (
188
189
  <li key={page}>
189
190
  {page === '...1' || page === '...2' ? (
190
- <span aria-hidden>...</span>
191
+ <Text aria-hidden>...</Text>
191
192
  ) : (
192
193
  <>
193
194
  {page !== currentPage && (
@@ -3,7 +3,7 @@ import { css, cx } from '@emotion/css';
3
3
  import useTheme from '../../theme/useTheme';
4
4
  import marginsStyle, { MarginProps } from '../common/marginsStyle';
5
5
 
6
- export const NAME = 'ucl-uikit-paragrah';
6
+ export const NAME = 'ucl-uikit-paragraph';
7
7
 
8
8
  export type ParagraphLevel =
9
9
  | 'lg'
@@ -84,9 +84,11 @@ const Paragraph = ({
84
84
  const baseStyle = css`
85
85
  font-family: ${md.fontFamily};
86
86
  font-feature-settings: ${md.fontSettings};
87
- color: ${emphasis === 'medium'
88
- ? theme.colour.text.secondary
89
- : theme.colour.text.default};
87
+ color: ${
88
+ emphasis === 'medium'
89
+ ? theme.colour.text.secondary
90
+ : theme.colour.text.default
91
+ };
90
92
  margin: 0;
91
93
  `;
92
94
 
@@ -60,7 +60,7 @@ describe('Paragraph', () => {
60
60
  <Paragraph>This is a test</Paragraph>
61
61
  </ThemeContextProvider>
62
62
  );
63
- const paragraph = screen.getByTestId('ucl-uikit-paragrah');
63
+ const paragraph = screen.getByTestId('ucl-uikit-paragraph');
64
64
  expect(paragraph).toBeDefined();
65
65
  });
66
66
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  exports[`Paragraph > snapshot: custom test id 1`] = `
4
4
  <p
5
- class="ucl-uikit-paragrah css-h12wmf"
5
+ class="ucl-uikit-paragraph css-h12wmf"
6
6
  data-testid="custom-test-id"
7
7
  >
8
8
  This is a test
@@ -11,8 +11,8 @@ exports[`Paragraph > snapshot: custom test id 1`] = `
11
11
 
12
12
  exports[`Paragraph > snapshot: emphasis 1`] = `
13
13
  <p
14
- class="ucl-uikit-paragrah css-h12wmf"
15
- data-testid="ucl-uikit-paragrah"
14
+ class="ucl-uikit-paragraph css-h12wmf"
15
+ data-testid="ucl-uikit-paragraph"
16
16
  >
17
17
  high emphasis
18
18
  </p>
@@ -20,8 +20,8 @@ exports[`Paragraph > snapshot: emphasis 1`] = `
20
20
 
21
21
  exports[`Paragraph > snapshot: minimal props 1`] = `
22
22
  <p
23
- class="ucl-uikit-paragrah css-h12wmf"
24
- data-testid="ucl-uikit-paragrah"
23
+ class="ucl-uikit-paragraph css-h12wmf"
24
+ data-testid="ucl-uikit-paragraph"
25
25
  >
26
26
  This is a test
27
27
  </p>
@@ -29,8 +29,8 @@ exports[`Paragraph > snapshot: minimal props 1`] = `
29
29
 
30
30
  exports[`Paragraph > snapshot: no margins 1`] = `
31
31
  <p
32
- class="ucl-uikit-paragrah css-1dosm7d"
33
- data-testid="ucl-uikit-paragrah"
32
+ class="ucl-uikit-paragraph css-1dosm7d"
33
+ data-testid="ucl-uikit-paragraph"
34
34
  >
35
35
  no margins
36
36
  </p>
@@ -38,8 +38,8 @@ exports[`Paragraph > snapshot: no margins 1`] = `
38
38
 
39
39
  exports[`Paragraph > snapshot: size 1`] = `
40
40
  <p
41
- class="ucl-uikit-paragrah css-h12wmf"
42
- data-testid="ucl-uikit-paragrah"
41
+ class="ucl-uikit-paragraph css-h12wmf"
42
+ data-testid="ucl-uikit-paragraph"
43
43
  >
44
44
  standfirst
45
45
  </p>
@@ -18,7 +18,7 @@ exports[`Radio > snapshot: checked prop 1`] = `
18
18
 
19
19
  exports[`Radio > snapshot: no props 1`] = `
20
20
  <span
21
- class="ucl-uikit-radio css-auet16"
21
+ class="ucl-uikit-radio css-v556ou"
22
22
  >
23
23
  <input
24
24
  class="css-19qtec1"
@@ -30,7 +30,7 @@ exports[`Radio > snapshot: no props 1`] = `
30
30
 
31
31
  exports[`Radio > snapshot: testId prop 1`] = `
32
32
  <span
33
- class="ucl-uikit-radio css-auet16"
33
+ class="ucl-uikit-radio css-v556ou"
34
34
  >
35
35
  <input
36
36
  class="css-19qtec1"
@@ -8,7 +8,7 @@ exports[`Search > snapshot: no props 1`] = `
8
8
  class="ucl-uikit-input css-1bpb1dw"
9
9
  >
10
10
  <input
11
- class="ucl-uikit-input__input css-1jgqttg"
11
+ class="ucl-uikit-input__input css-r12x3w"
12
12
  data-testid="ucl-uikit-search"
13
13
  id=""
14
14
  placeholder=""
@@ -87,7 +87,7 @@ exports[`Search > snapshot: testId prop 1`] = `
87
87
  class="ucl-uikit-input css-1bpb1dw"
88
88
  >
89
89
  <input
90
- class="ucl-uikit-input__input css-1jgqttg"
90
+ class="ucl-uikit-input__input css-r12x3w"
91
91
  data-testid="test123"
92
92
  id=""
93
93
  placeholder=""
@@ -4,7 +4,7 @@ exports[`Select > Snapshot: default 1`] = `
4
4
  <div
5
5
  aria-expanded="false"
6
6
  aria-haspopup="listbox"
7
- class="ucl-uikit-select css-1kou9w2"
7
+ class="ucl-uikit-select css-1gu3yiz"
8
8
  data-testid="ucl-uikit-select"
9
9
  role="combobox"
10
10
  tabindex="0"
@@ -47,7 +47,7 @@ exports[`Cell > Snapshot: variants 1`] = `
47
47
  data-testid="ucl-uikit-table__cell-content"
48
48
  >
49
49
  <span
50
- class="ucl-uikit-base-checkbox ucl-uikit-checkbox css-tfrbiv"
50
+ class="ucl-uikit-base-checkbox ucl-uikit-checkbox css-qoivhx"
51
51
  data-testid="ucl-uikit-checkbox__root"
52
52
  >
53
53
  <input
@@ -105,7 +105,7 @@ exports[`Cell > Snapshot: variants 1`] = `
105
105
  >
106
106
  <button
107
107
  aria-disabled="false"
108
- class="ucl-uikit-button css-1r34e1w"
108
+ class="ucl-uikit-button css-1o7ytg2"
109
109
  data-testid="ucl-uikit-button"
110
110
  >
111
111
  Button
@@ -14,7 +14,7 @@ exports[`HeadCell > Snapshot: checkbox variant 1`] = `
14
14
  data-testid="ucl-uikit-table__head-cell-content"
15
15
  >
16
16
  <span
17
- class="ucl-uikit-base-checkbox ucl-uikit-checkbox css-tfrbiv"
17
+ class="ucl-uikit-base-checkbox ucl-uikit-checkbox css-qoivhx"
18
18
  data-testid="ucl-uikit-checkbox__root"
19
19
  >
20
20
  <input
@@ -2,7 +2,7 @@
2
2
 
3
3
  exports[`Textarea > snapshot: Disabled 1`] = `
4
4
  <textarea
5
- class="ucl-uikit-textarea css-oemvy2"
5
+ class="ucl-uikit-textarea css-yfw4f5"
6
6
  data-testid="ucl-uikit-textarea"
7
7
  disabled=""
8
8
  id=""
@@ -11,7 +11,7 @@ exports[`Textarea > snapshot: Disabled 1`] = `
11
11
 
12
12
  exports[`Textarea > snapshot: Placeholder 1`] = `
13
13
  <textarea
14
- class="ucl-uikit-textarea css-1eo4yl8"
14
+ class="ucl-uikit-textarea css-1eai1zv"
15
15
  data-testid="ucl-uikit-textarea"
16
16
  id=""
17
17
  placeholder="test"
@@ -20,7 +20,7 @@ exports[`Textarea > snapshot: Placeholder 1`] = `
20
20
 
21
21
  exports[`Textarea > snapshot: custom test id 1`] = `
22
22
  <textarea
23
- class="ucl-uikit-textarea css-1eo4yl8"
23
+ class="ucl-uikit-textarea css-1eai1zv"
24
24
  data-testid="custom-test-id"
25
25
  id=""
26
26
  />
@@ -28,7 +28,7 @@ exports[`Textarea > snapshot: custom test id 1`] = `
28
28
 
29
29
  exports[`Textarea > snapshot: minimal props 1`] = `
30
30
  <textarea
31
- class="ucl-uikit-textarea css-1eo4yl8"
31
+ class="ucl-uikit-textarea css-1eai1zv"
32
32
  data-testid="ucl-uikit-textarea"
33
33
  id=""
34
34
  />
@@ -1,6 +1,7 @@
1
1
  import { memo, forwardRef, HTMLAttributes } from 'react';
2
2
  import { css, cx } from '@emotion/css';
3
3
  import { useTheme } from '../../theme';
4
+ import Text from '../Text';
4
5
 
5
6
  export const NAME = 'ucl-uikit-tooltip';
6
7
 
@@ -17,14 +18,9 @@ const Tooltip = forwardRef<Ref, TooltipProps>(
17
18
  const baseStyle = css`
18
19
  background-color: ${theme.colour.fill.brandPrimary};
19
20
  color: ${theme.colour.text.brandInverse};
20
- font-family: ${theme.typography.body.md.fontFamily};
21
- font-feature-settings: ${theme.typography.body.md.fontSettings};
22
21
  height: 32px;
23
22
  padding: 4px 8px 4px 8px;
24
23
  border-radius: ${theme.radius.r4};
25
- font-size: ${theme.typography.body.md.fontSize}px;
26
- font-weight: ${theme.typography.body.md.fontWeight};
27
- line-height: ${theme.typography.body.md.lineHeight}%;
28
24
  display: inline;
29
25
  white-space: nowrap;
30
26
  `;
@@ -32,14 +28,15 @@ const Tooltip = forwardRef<Ref, TooltipProps>(
32
28
  const style = cx(NAME, baseStyle, className);
33
29
 
34
30
  return (
35
- <span
31
+ <Text
36
32
  ref={ref}
33
+ level='md'
37
34
  className={style}
38
- data-testid={testId}
35
+ testId={testId}
39
36
  {...props}
40
37
  >
41
38
  {children}
42
- </span>
39
+ </Text>
43
40
  );
44
41
  }
45
42
  );
@@ -2,7 +2,7 @@
2
2
 
3
3
  exports[`Tooltip > snapshot: no props 1`] = `
4
4
  <span
5
- class="ucl-uikit-tooltip css-1ojzqhe"
5
+ class="ucl-uikit-text ucl-uikit-tooltip css-1s62y9x"
6
6
  data-testid="ucl-uikit-tooltip"
7
7
  >
8
8
  test
@@ -11,7 +11,7 @@ exports[`Tooltip > snapshot: no props 1`] = `
11
11
 
12
12
  exports[`Tooltip > snapshot: testId prop 1`] = `
13
13
  <span
14
- class="ucl-uikit-tooltip css-1ojzqhe"
14
+ class="ucl-uikit-text ucl-uikit-tooltip css-1s62y9x"
15
15
  data-testid="test123"
16
16
  >
17
17
  Info Tooltip
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "uikit-react-public",
3
3
  "private": false,
4
4
  "license": "UNLICENSED",
5
- "version": "0.43.2",
5
+ "version": "0.43.4",
6
6
  "type": "module",
7
7
  "main": "dist/index.js",
8
8
  "types": "dist/index.d.ts",
@@ -43,7 +43,7 @@
43
43
  "@emotion/css": "^11.13.5",
44
44
  "@emotion/react": "^11.14.0",
45
45
  "@floating-ui/react-dom": "^2.1.2",
46
- "design-system-foundations-public": "0.1.6"
46
+ "design-system-foundations-public": "0.1.7"
47
47
  },
48
48
  "peerDependencies": {
49
49
  "react": "^19.0.0",