@transferwise/components 0.0.0-experimental-5ee49bb → 0.0.0-experimental-4560f77

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 (163) hide show
  1. package/build/Body/Body.js +1 -1
  2. package/build/Body/Body.js.map +1 -1
  3. package/build/Body/Body.mjs +1 -1
  4. package/build/Body/Body.mjs.map +1 -1
  5. package/build/Calendar/DayCalendar/Table/DayCalendarTable.js +1 -1
  6. package/build/Calendar/DayCalendar/Table/DayCalendarTable.js.map +1 -1
  7. package/build/Calendar/DayCalendar/Table/DayCalendarTable.mjs +1 -1
  8. package/build/Calendar/DayCalendar/Table/DayCalendarTable.mjs.map +1 -1
  9. package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.js +1 -1
  10. package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.js.map +1 -1
  11. package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.mjs +1 -1
  12. package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.mjs.map +1 -1
  13. package/build/Calendar/TableLink/TableLink.js +1 -1
  14. package/build/Calendar/TableLink/TableLink.js.map +1 -1
  15. package/build/Calendar/TableLink/TableLink.mjs +1 -1
  16. package/build/Calendar/TableLink/TableLink.mjs.map +1 -1
  17. package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.js +1 -1
  18. package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.js.map +1 -1
  19. package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.mjs +1 -1
  20. package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.mjs.map +1 -1
  21. package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.js +2 -2
  22. package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.js.map +1 -1
  23. package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.mjs +2 -2
  24. package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.mjs.map +1 -1
  25. package/build/Inputs/SelectInput/Option/SelectInputOption.js +1 -1
  26. package/build/Inputs/SelectInput/Option/SelectInputOption.js.map +1 -1
  27. package/build/Inputs/SelectInput/Option/SelectInputOption.mjs +1 -1
  28. package/build/Inputs/SelectInput/Option/SelectInputOption.mjs.map +1 -1
  29. package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.js +3 -3
  30. package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.js.map +1 -1
  31. package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.mjs +3 -3
  32. package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.mjs.map +1 -1
  33. package/build/Inputs/SelectInput/Popover/SelectInputPopover.js +2 -2
  34. package/build/Inputs/SelectInput/Popover/SelectInputPopover.js.map +1 -1
  35. package/build/Inputs/SelectInput/Popover/SelectInputPopover.mjs +2 -2
  36. package/build/Inputs/SelectInput/Popover/SelectInputPopover.mjs.map +1 -1
  37. package/build/Label/Label.js +1 -1
  38. package/build/Label/Label.js.map +1 -1
  39. package/build/Label/Label.mjs +1 -1
  40. package/build/Label/Label.mjs.map +1 -1
  41. package/build/Stepper/Stepper.js +1 -1
  42. package/build/Stepper/Stepper.js.map +1 -1
  43. package/build/Stepper/Stepper.mjs +1 -1
  44. package/build/Stepper/Stepper.mjs.map +1 -1
  45. package/build/Table/Header/TableHeader.js +1 -1
  46. package/build/Table/Header/TableHeader.js.map +1 -1
  47. package/build/Table/Header/TableHeader.mjs +1 -1
  48. package/build/Table/Header/TableHeader.mjs.map +1 -1
  49. package/build/Tabs/Tab/Tab.js +1 -1
  50. package/build/Tabs/Tab/Tab.js.map +1 -1
  51. package/build/Tabs/Tab/Tab.mjs +1 -1
  52. package/build/Tabs/Tab/Tab.mjs.map +1 -1
  53. package/build/Tag/Tag.js +1 -1
  54. package/build/Tag/Tag.js.map +1 -1
  55. package/build/Tag/Tag.mjs +1 -1
  56. package/build/Tag/Tag.mjs.map +1 -1
  57. package/build/Typeahead/TypeaheadOption/TypeaheadOption.js +2 -2
  58. package/build/Typeahead/TypeaheadOption/TypeaheadOption.js.map +1 -1
  59. package/build/Typeahead/TypeaheadOption/TypeaheadOption.mjs +2 -2
  60. package/build/Typeahead/TypeaheadOption/TypeaheadOption.mjs.map +1 -1
  61. package/build/Upload/Steps/UploadImageStep/UploadImageStep.js +2 -2
  62. package/build/Upload/Steps/UploadImageStep/UploadImageStep.js.map +1 -1
  63. package/build/Upload/Steps/UploadImageStep/UploadImageStep.mjs +2 -2
  64. package/build/Upload/Steps/UploadImageStep/UploadImageStep.mjs.map +1 -1
  65. package/build/_deprecated/ActionButton/ActionButton.js +1 -1
  66. package/build/_deprecated/ActionButton/ActionButton.js.map +1 -1
  67. package/build/_deprecated/ActionButton/ActionButton.mjs +1 -1
  68. package/build/_deprecated/ActionButton/ActionButton.mjs.map +1 -1
  69. package/build/_deprecated/Avatar/Avatar.js +1 -1
  70. package/build/_deprecated/Avatar/Avatar.js.map +1 -1
  71. package/build/_deprecated/Avatar/Avatar.mjs +1 -1
  72. package/build/_deprecated/Avatar/Avatar.mjs.map +1 -1
  73. package/build/_deprecated/Select/Select.js +2 -2
  74. package/build/_deprecated/Select/Select.js.map +1 -1
  75. package/build/_deprecated/Select/Select.mjs +2 -2
  76. package/build/_deprecated/Select/Select.mjs.map +1 -1
  77. package/build/common/PropsValues/typography.js +6 -0
  78. package/build/common/PropsValues/typography.js.map +1 -1
  79. package/build/common/PropsValues/typography.mjs +6 -0
  80. package/build/common/PropsValues/typography.mjs.map +1 -1
  81. package/build/main.css +117 -98
  82. package/build/styles/Accordion/Accordion.css +2 -1
  83. package/build/styles/Body/Body.css +1 -1
  84. package/build/styles/Chips/Chip/Chip.css +4 -2
  85. package/build/styles/Decision/Decision.css +2 -1
  86. package/build/styles/Inputs/Input/Input.css +0 -38
  87. package/build/styles/Inputs/TextArea/TextArea.css +0 -38
  88. package/build/styles/MoneyInput/MoneyInput.css +6 -3
  89. package/build/styles/Popover/Popover.css +0 -38
  90. package/build/styles/ProgressBar/ProgressBar.css +2 -1
  91. package/build/styles/Table/Table.css +15 -5
  92. package/build/styles/Tile/Tile.css +2 -1
  93. package/build/styles/Typeahead/Typeahead.css +4 -2
  94. package/build/styles/_deprecated/CriticalBanner/CriticalCommsBanner.css +2 -1
  95. package/build/styles/_deprecated/Select/Select.css +17 -4
  96. package/build/styles/main.css +117 -98
  97. package/build/types/Body/Body.d.ts +2 -2
  98. package/build/types/IconButton/IconButton.d.ts +1 -1
  99. package/build/types/MoneyInput/MoneyInput.d.ts +1 -1
  100. package/build/types/MoneyInput/MoneyInput.d.ts.map +1 -1
  101. package/build/types/Title/Title.d.ts +2 -2
  102. package/build/types/Upload/Steps/UploadImageStep/UploadImageStep.d.ts +1 -1
  103. package/build/types/UploadInput/UploadItem/UploadItemLink.d.ts +1 -1
  104. package/build/types/common/PropsValues/typography.d.ts +13 -1
  105. package/build/types/common/PropsValues/typography.d.ts.map +1 -1
  106. package/package.json +1 -1
  107. package/src/Accordion/Accordion.css +2 -1
  108. package/src/Accordion/Accordion.less +2 -1
  109. package/src/Body/Body.css +1 -1
  110. package/src/Body/Body.less +1 -1
  111. package/src/Body/Body.test.tsx +4 -4
  112. package/src/Body/Body.tsx +2 -2
  113. package/src/Calendar/DayCalendar/Table/DayCalendarTable.tsx +2 -2
  114. package/src/Calendar/MonthCalendar/Table/MonthCalendarTable.tsx +1 -1
  115. package/src/Calendar/TableLink/TableLink.tsx +1 -1
  116. package/src/Chips/Chip/Chip.css +4 -2
  117. package/src/Chips/Chip/Chip.less +2 -1
  118. package/src/Decision/Decision.css +2 -1
  119. package/src/Decision/Decision.less +2 -1
  120. package/src/DefinitionList/_stories/DefinitionList.story.tsx +1 -1
  121. package/src/Display/_stories/Display.story.tsx +20 -6
  122. package/src/FlowNavigation/AnimatedLabel/AnimatedLabel.tsx +1 -1
  123. package/src/Inputs/Input/Input.css +0 -38
  124. package/src/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.tsx +2 -2
  125. package/src/Inputs/SelectInput/Option/SelectInputOption.tsx +1 -1
  126. package/src/Inputs/SelectInput/OptionContent/SelectInputOptionContent.tsx +3 -3
  127. package/src/Inputs/SelectInput/Popover/SelectInputPopover.tsx +2 -2
  128. package/src/Inputs/SelectInput/_stories/SelectInput.story.tsx +1 -1
  129. package/src/Inputs/TextArea/TextArea.css +0 -38
  130. package/src/Inputs/_common.less +5 -5
  131. package/src/Label/Label.tsx +1 -1
  132. package/src/MoneyInput/MoneyInput.css +6 -3
  133. package/src/MoneyInput/MoneyInput.less +7 -4
  134. package/src/PocketSurface/_stories/PocketSurface.story.tsx +2 -2
  135. package/src/Popover/Popover.css +0 -38
  136. package/src/Popover/Popover.less +1 -1
  137. package/src/ProgressBar/ProgressBar.css +2 -1
  138. package/src/ProgressBar/ProgressBar.less +12 -11
  139. package/src/SentimentSurface/_stories/SentimentSurface.story.tsx +1 -1
  140. package/src/Stepper/Stepper.tsx +1 -1
  141. package/src/Table/Header/TableHeader.tsx +1 -1
  142. package/src/Table/StatusText/TableStatusText.test.tsx +5 -5
  143. package/src/Table/Table.css +15 -5
  144. package/src/Table/Table.less +17 -6
  145. package/src/Tabs/Tab/Tab.tsx +1 -1
  146. package/src/Tag/Tag.tsx +1 -1
  147. package/src/Tag/_stories/Tag.story.tsx +1 -1
  148. package/src/Tile/Tile.css +2 -1
  149. package/src/Tile/Tile.less +2 -1
  150. package/src/Typeahead/Typeahead.css +4 -2
  151. package/src/Typeahead/Typeahead.less +2 -1
  152. package/src/Typeahead/TypeaheadOption/TypeaheadOption.tsx +2 -2
  153. package/src/Upload/Steps/UploadImageStep/UploadImageStep.tsx +2 -2
  154. package/src/_deprecated/ActionButton/ActionButton.tsx +1 -1
  155. package/src/_deprecated/Avatar/Avatar.tsx +1 -1
  156. package/src/_deprecated/CriticalBanner/CriticalCommsBanner.css +2 -1
  157. package/src/_deprecated/CriticalBanner/CriticalCommsBanner.less +2 -1
  158. package/src/_deprecated/NavigationOption/_stories/NavigationOption.story.tsx +6 -6
  159. package/src/_deprecated/Select/Select.css +17 -4
  160. package/src/_deprecated/Select/Select.less +10 -5
  161. package/src/_deprecated/Select/Select.tsx +2 -2
  162. package/src/common/PropsValues/typography.ts +20 -1
  163. package/src/main.css +117 -98
@@ -9,7 +9,7 @@ describe('Body', () => {
9
9
  const copy = screen.getByText('Test');
10
10
  expect(copy).toBeInTheDocument();
11
11
  expect(copy.tagName).toBe('DIV');
12
- expect(copy).toHaveClass(`np-text-${Typography.BODY_DEFAULT}`);
12
+ expect(copy).toHaveClass(`wds-text-${Typography.BODY_DEFAULT}`);
13
13
  });
14
14
 
15
15
  it('enforces tag via `as` prop', () => {
@@ -17,7 +17,7 @@ describe('Body', () => {
17
17
  const copy = screen.getByText('Test');
18
18
  expect(copy).toBeInTheDocument();
19
19
  expect(copy.tagName).toBe('P');
20
- expect(copy).toHaveClass(`np-text-${Typography.BODY_DEFAULT}`);
20
+ expect(copy).toHaveClass(`wds-text-${Typography.BODY_DEFAULT}`);
21
21
  });
22
22
 
23
23
  it('supports native HTML attrs', () => {
@@ -35,7 +35,7 @@ describe('Body', () => {
35
35
  it('renders newlines as line breaks when preserveNewlines is true', () => {
36
36
  render(<Body preserveNewlines>{'Line 1.\nLine 2'}</Body>);
37
37
  const copy = screen.getByText(/Line 1\.\s*Line 2/);
38
- expect(copy).toHaveClass('np-text--pre-line');
38
+ expect(copy).toHaveClass('wds-text--pre-line');
39
39
  expect(copy).toHaveTextContent('Line 1.');
40
40
  expect(copy).toHaveTextContent('Line 2');
41
41
  });
@@ -47,6 +47,6 @@ describe('Body', () => {
47
47
  const copy = screen.getByText('Test');
48
48
  expect(copy).toBeInTheDocument();
49
49
  expect(copy.tagName).toBe('DIV');
50
- expect(copy).toHaveClass(`np-text-${Typography.BODY_DEFAULT}`);
50
+ expect(copy).toHaveClass(`wds-text-${Typography.BODY_DEFAULT}`);
51
51
  });
52
52
  });
package/src/Body/Body.tsx CHANGED
@@ -41,8 +41,8 @@ const Body = forwardRef(function Body(
41
41
  // See: https://fettblog.eu/typescript-react-generic-forward-refs/
42
42
  ref={reference}
43
43
  className={clsx(
44
- `np-text-${isTypeSupported ? type : DEFAULT_TYPE}`,
45
- preserveNewlines && 'np-text--pre-line',
44
+ `wds-text-${isTypeSupported ? type : DEFAULT_TYPE}`,
45
+ preserveNewlines && 'wds-text--pre-line',
46
46
  className,
47
47
  )}
48
48
  />
@@ -134,8 +134,8 @@ class DayCalendarTable extends PureComponent<DayCalendarTableProps> {
134
134
  key={day}
135
135
  className={
136
136
  index > 4
137
- ? 'text-xs-center np-text-body-default'
138
- : 'text-xs-center np-text-body-default-bold'
137
+ ? 'text-xs-center wds-text-body-default'
138
+ : 'text-xs-center wds-text-body-default-bold'
139
139
  }
140
140
  >
141
141
  <span className="hidden-xs">
@@ -76,7 +76,7 @@ const MonthCalendarTable = ({
76
76
  })();
77
77
 
78
78
  return (
79
- <table className="table table-condensed table-bordered tw-date-lookup-calendar np-text-body-default-bold m-b-0">
79
+ <table className="table table-condensed table-bordered tw-date-lookup-calendar wds-text-body-default-bold m-b-0">
80
80
  <thead className="sr-only">
81
81
  <tr>
82
82
  <th colSpan={COLS}>{placeholder}</th>
@@ -96,7 +96,7 @@ const TableLink = ({
96
96
  aria-pressed={active}
97
97
  className={clsx(
98
98
  `wds-Calendar__option--${type}`,
99
- `tw-date-lookup-${type}-option np-text-body-default-bold`,
99
+ `tw-date-lookup-${type}-option wds-text-body-default-bold`,
100
100
  { active: !!active },
101
101
  { today: !!today },
102
102
  { disabled: !!isUnavailable },
@@ -134,12 +134,14 @@
134
134
  .np-theme-personal .np-chip.np-chip--removable {
135
135
  position: relative;
136
136
  }
137
- .np-theme-personal .np-chip.np-chip--removable .np-text-body-default-bold {
137
+ .np-theme-personal .np-chip.np-chip--removable .np-text-body-default-bold,
138
+ .np-theme-personal .np-chip.np-chip--removable .wds-text-body-default-bold {
138
139
  padding-inline-end: 24px;
139
140
  padding-inline-end: var(--size-24);
140
141
  }
141
142
  @media (max-width: 320px) {
142
- .np-theme-personal .np-chip.np-chip--removable .np-text-body-default-bold {
143
+ .np-theme-personal .np-chip.np-chip--removable .np-text-body-default-bold,
144
+ .np-theme-personal .np-chip.np-chip--removable .wds-text-body-default-bold {
143
145
  padding-inline-end: 48px;
144
146
  padding-inline-end: var(--size-48);
145
147
  }
@@ -137,7 +137,8 @@
137
137
  &.np-chip--removable {
138
138
  position: relative;
139
139
 
140
- .np-text-body-default-bold {
140
+ .np-text-body-default-bold,
141
+ .wds-text-body-default-bold {
141
142
  padding-right: var(--size-24);
142
143
 
143
144
  @media (--screen-400-zoom) {
@@ -1,7 +1,8 @@
1
1
  .np-decision .decision {
2
2
  display: flex;
3
3
  }
4
- .np-decision__tile--small .np-text-title-subsection {
4
+ .np-decision__tile--small .np-text-title-subsection,
5
+ .np-decision__tile--small .wds-text-title-subsection {
5
6
  font-size: 1rem;
6
7
  font-size: var(--font-size-16);
7
8
  line-height: 1.2;
@@ -4,7 +4,8 @@
4
4
  }
5
5
 
6
6
  &__tile--small {
7
- .np-text-title-subsection {
7
+ .np-text-title-subsection,
8
+ .wds-text-title-subsection {
8
9
  font-size: var(--font-size-16);
9
10
  line-height: var(--line-height-title);
10
11
  }
@@ -32,7 +32,7 @@ const definitions = [
32
32
  },
33
33
  {
34
34
  title: 'Use wrapper elements to style',
35
- value: <span className="np-text-title-subsection">89.45GBP</span>,
35
+ value: <span className="wds-text-title-subsection">89.45GBP</span>,
36
36
  key: 'second',
37
37
  },
38
38
  {
@@ -118,27 +118,41 @@ export const Basic = () => {
118
118
  export const Numbers = () => {
119
119
  return (
120
120
  <>
121
- <Title type={Typography.TITLE_SCREEN}>Display Number</Title>
121
+ <Title type={Typography.TITLE_SCREEN}>Display Number Small</Title>
122
122
  <hr />
123
- <Display type={Typography.DISPLAY_NUMBER}>
123
+ <Display type={Typography.DISPLAY_NUMBER_SMALL}>
124
124
  <Money amount={1050.6} currency="UAH" />
125
125
  </Display>
126
126
  <hr />
127
- <Display type={Typography.DISPLAY_NUMBER}>
127
+ <Display type={Typography.DISPLAY_NUMBER_SMALL}>
128
128
  <Money amount={10.17} currency="JPY" />
129
129
  </Display>
130
+
131
+ <Title type={Typography.TITLE_SCREEN}>Display Number Medium</Title>
130
132
  <hr />
131
- <Display type={Typography.DISPLAY_NUMBER}>
133
+ <Display type={Typography.DISPLAY_NUMBER_MEDIUM}>
132
134
  <Money amount={0.01} currency="EUR" />
133
135
  </Display>
134
136
  <hr />
135
- <Display type={Typography.DISPLAY_NUMBER}>
137
+ <Display type={Typography.DISPLAY_NUMBER_MEDIUM}>
136
138
  <Money amount={1000000} currency="EUR" />
137
139
  </Display>
140
+
141
+ <Title type={Typography.TITLE_SCREEN}>Display Number Large</Title>
138
142
  <hr />
139
- <Display type={Typography.DISPLAY_NUMBER}>
143
+ <Display type={Typography.DISPLAY_NUMBER_LARGE}>
140
144
  <Money amount={1000000} currency="GBP" />
141
145
  </Display>
146
+ <hr />
147
+ <Display type={Typography.DISPLAY_NUMBER_LARGE}>
148
+ <Money amount={1050.6} currency="UAH" />
149
+ </Display>
150
+
151
+ <Title type={Typography.TITLE_SCREEN}>Display Number (Deprecated)</Title>
152
+ <hr />
153
+ <Display type={Typography.DISPLAY_NUMBER}>
154
+ <Money amount={1050.6} currency="UAH" />
155
+ </Display>
142
156
  </>
143
157
  );
144
158
  };
@@ -40,7 +40,7 @@ const AnimatedLabel = ({ activeLabel, className, steps }: AnimatedLabelProps) =>
40
40
  className={clsx(
41
41
  'np-animated-label',
42
42
  'btn-unstyled',
43
- 'np-text-body-large-bold',
43
+ 'wds-text-body-large-bold',
44
44
  className,
45
45
  )}
46
46
  onClick={() => setShowSteps(true)}
@@ -219,48 +219,10 @@
219
219
  }
220
220
  }
221
221
  .np-form-control--size-lg {
222
- margin: 0;
223
- color: #37517e;
224
- color: var(--color-content-primary);
225
- word-wrap: break-word;
226
222
  margin-block-end: initial;
227
223
  block-size: 72px !important;
228
224
  block-size: var(--size-72) !important;
229
225
  }
230
- @supports (hyphenate-limit-chars: 1) {
231
- .np-form-control--size-lg {
232
- hyphens: auto;
233
- hyphenate-limit-chars: 7 3;
234
- }
235
- @media (min-width: 840px) {
236
- .np-form-control--size-lg {
237
- hyphenate-limit-chars: 8 3;
238
- }
239
- }
240
- @media (min-width: 1160px) {
241
- .np-form-control--size-lg {
242
- hyphenate-limit-chars: 10 4 3;
243
- }
244
- }
245
- }
246
- @supports (not (hyphenate-limit-chars: 1)) and (-webkit-hyphenate-limit-before: 1) {
247
- .np-form-control--size-lg {
248
- hyphens: auto;
249
- -webkit-hyphenate-limit-before: 3;
250
- -webkit-hyphenate-limit-after: 3;
251
- }
252
- @media (min-width: 1160px) {
253
- .np-form-control--size-lg {
254
- -webkit-hyphenate-limit-before: 4;
255
- }
256
- }
257
- }
258
- .np-form-control--size-lg + p,
259
- .np-form-control--size-lg + ul:not(.list-unstyled),
260
- .np-form-control--size-lg + ol:not(.list-unstyled) {
261
- margin-block-start: 8px;
262
- margin-block-start: var(--size-8);
263
- }
264
226
  .np-input::-moz-placeholder {
265
227
  color: #768e9c;
266
228
  color: var(--color-content-tertiary);
@@ -122,9 +122,9 @@ export function SelectInputBottomSheet({
122
122
  )}
123
123
  >
124
124
  {title ? (
125
- <h2 className="np-bottom-sheet-v2-title np-text-title-body">{title}</h2>
125
+ <h2 className="np-bottom-sheet-v2-title wds-text-title-body">{title}</h2>
126
126
  ) : null}
127
- <div className="np-bottom-sheet-v2-body np-text-body-default">
127
+ <div className="np-bottom-sheet-v2-body wds-text-body-default">
128
128
  {children}
129
129
  </div>
130
130
  </div>
@@ -34,7 +34,7 @@ export function SelectInputOption<T = string>({
34
34
  disabled={disabled}
35
35
  className={({ active, disabled: uiDisabled }) =>
36
36
  clsx(
37
- 'np-select-input-option-container np-text-body-large',
37
+ 'np-select-input-option-container wds-text-body-large',
38
38
  active && 'np-select-input-option-container--active',
39
39
  uiDisabled && 'np-select-input-option-container--disabled',
40
40
  )
@@ -28,7 +28,7 @@ export function SelectInputOptionContent({
28
28
  <div
29
29
  className={clsx(
30
30
  'np-select-input-option-content-container',
31
- (note || description) && 'np-text-body-large',
31
+ (note || description) && 'wds-text-body-large',
32
32
  className,
33
33
  )}
34
34
  >
@@ -52,7 +52,7 @@ export function SelectInputOptionContent({
52
52
  >
53
53
  <div className="d-inline np-select-input-option-content-title">{title}</div>
54
54
  {note ? (
55
- <span className="np-select-input-option-content-text-secondary np-text-body-default">
55
+ <span className="np-select-input-option-content-text-secondary wds-text-body-default">
56
56
  {note}
57
57
  </span>
58
58
  ) : null}
@@ -61,7 +61,7 @@ export function SelectInputOptionContent({
61
61
  {description ? (
62
62
  <div
63
63
  className={clsx(
64
- 'np-select-input-option-content-text-secondary np-text-body-default',
64
+ 'np-select-input-option-content-text-secondary wds-text-body-default',
65
65
  withinTrigger &&
66
66
  'np-select-input-option-content-text-within-trigger np-select-input-option-description-in-trigger',
67
67
  )}
@@ -124,9 +124,9 @@ export function SelectInputPopover({
124
124
  })}
125
125
  >
126
126
  {title ? (
127
- <h2 className="np-popover-v2-title np-text-title-body">{title}</h2>
127
+ <h2 className="np-popover-v2-title wds-text-title-body">{title}</h2>
128
128
  ) : null}
129
- <div className="np-popover-v2-content np-text-body-default">{children}</div>
129
+ <div className="np-popover-v2-content wds-text-body-default">{children}</div>
130
130
  </div>
131
131
  </div>
132
132
  </FloatingFocusManager>
@@ -1276,7 +1276,7 @@ export const WithBuiltInSearchResultSorting: Story<CountryWithCurrency> = {
1276
1276
  decorators: [
1277
1277
  (Story) => (
1278
1278
  <div>
1279
- <p className="m-b-3 np-text-body-default" style={{ maxWidth: '600px' }}>
1279
+ <p className="m-b-3 wds-text-body-default" style={{ maxWidth: '600px' }}>
1280
1280
  This example uses the built-in <code>SelectInput.sortByRelevance</code> helper to sort
1281
1281
  filtered results by relevance (You can implement your own). This one prioritises: exact
1282
1282
  matches → starts with → contains → alphabetical.
@@ -219,48 +219,10 @@
219
219
  }
220
220
  }
221
221
  .np-form-control--size-lg {
222
- margin: 0;
223
- color: #37517e;
224
- color: var(--color-content-primary);
225
- word-wrap: break-word;
226
222
  margin-block-end: initial;
227
223
  block-size: 72px !important;
228
224
  block-size: var(--size-72) !important;
229
225
  }
230
- @supports (hyphenate-limit-chars: 1) {
231
- .np-form-control--size-lg {
232
- hyphens: auto;
233
- hyphenate-limit-chars: 7 3;
234
- }
235
- @media (min-width: 840px) {
236
- .np-form-control--size-lg {
237
- hyphenate-limit-chars: 8 3;
238
- }
239
- }
240
- @media (min-width: 1160px) {
241
- .np-form-control--size-lg {
242
- hyphenate-limit-chars: 10 4 3;
243
- }
244
- }
245
- }
246
- @supports (not (hyphenate-limit-chars: 1)) and (-webkit-hyphenate-limit-before: 1) {
247
- .np-form-control--size-lg {
248
- hyphens: auto;
249
- -webkit-hyphenate-limit-before: 3;
250
- -webkit-hyphenate-limit-after: 3;
251
- }
252
- @media (min-width: 1160px) {
253
- .np-form-control--size-lg {
254
- -webkit-hyphenate-limit-before: 4;
255
- }
256
- }
257
- }
258
- .np-form-control--size-lg + p,
259
- .np-form-control--size-lg + ul:not(.list-unstyled),
260
- .np-form-control--size-lg + ol:not(.list-unstyled) {
261
- margin-block-start: 8px;
262
- margin-block-start: var(--size-8);
263
- }
264
226
  .np-text-area {
265
227
  min-block-size: 72px;
266
228
  min-block-size: var(--size-72);
@@ -1,4 +1,4 @@
1
- @import (reference) './../styles/less/core/_typography.less';
1
+ @import (reference) "./../styles/less/core/_typography.less";
2
2
 
3
3
  .np-form-control {
4
4
  --ring-width: 1px;
@@ -40,7 +40,7 @@
40
40
  }
41
41
 
42
42
  &--size-auto {
43
- .np-text-body-large;
43
+ .wds-text-body-large;
44
44
  padding-top: var(--size-12);
45
45
  padding-bottom: var(--size-12);
46
46
  }
@@ -54,7 +54,7 @@
54
54
  }
55
55
 
56
56
  &--size-sm {
57
- .np-text-body-default;
57
+ .wds-text-body-default;
58
58
  height: var(--size-32) !important;
59
59
  @media (--screen-400-zoom) {
60
60
  height: var(--size-64) !important;
@@ -62,7 +62,7 @@
62
62
  }
63
63
 
64
64
  &--size-md {
65
- .np-text-body-large;
65
+ .wds-text-body-large;
66
66
  height: var(--size-48) !important;
67
67
  @media (--screen-400-zoom) {
68
68
  height: var(--size-72) !important;
@@ -70,7 +70,7 @@
70
70
  }
71
71
 
72
72
  &--size-lg {
73
- .np-text-title-subsection;
73
+ .wds-text-title-subsection;
74
74
  height: var(--size-72) !important;
75
75
  }
76
76
  }
@@ -29,7 +29,7 @@ const Label = forwardRef<HTMLLabelElement, LabelProps>(
29
29
  id={id}
30
30
  htmlFor={htmlFor}
31
31
  className={clsx(
32
- 'np-label d-flex flex-column np-text-body-default-bold text-primary m-b-0',
32
+ 'np-label d-flex flex-column wds-text-body-default-bold text-primary m-b-0',
33
33
  className,
34
34
  )}
35
35
  >
@@ -4,7 +4,8 @@
4
4
  .tw-money-input .tw-money-input__fixed-currency {
5
5
  padding-inline-start: 0 !important;
6
6
  }
7
- .tw-money-input .tw-money-input__fixed-currency .np-text-title-subsection {
7
+ .tw-money-input .tw-money-input__fixed-currency .np-text-title-subsection,
8
+ .tw-money-input .tw-money-input__fixed-currency .wds-text-title-subsection {
8
9
  color: #768e9c;
9
10
  color: var(--color-content-tertiary);
10
11
  font-weight: 600;
@@ -20,14 +21,16 @@
20
21
  .tw-money-input.input-group-sm .form-control {
21
22
  min-block-size: 34px;
22
23
  }
23
- .tw-money-input.input-group-sm .np-text-title-subsection {
24
+ .tw-money-input.input-group-sm .np-text-title-subsection,
25
+ .tw-money-input.input-group-sm .wds-text-title-subsection {
24
26
  font-size: 0.875rem;
25
27
  font-size: var(--font-size-14);
26
28
  }
27
29
  .tw-money-input.input-group-md .form-control {
28
30
  min-block-size: 53px;
29
31
  }
30
- .tw-money-input.input-group-md .np-text-title-subsection {
32
+ .tw-money-input.input-group-md .np-text-title-subsection,
33
+ .tw-money-input.input-group-md .wds-text-title-subsection {
31
34
  font-size: 1rem;
32
35
  font-size: var(--font-size-16);
33
36
  }
@@ -5,13 +5,14 @@
5
5
  .tw-money-input__fixed-currency {
6
6
  padding-left: 0 !important;
7
7
 
8
- .np-text-title-subsection {
8
+ .np-text-title-subsection,
9
+ .wds-text-title-subsection {
9
10
  color: var(--color-content-tertiary);
10
11
  font-weight: var(--font-weight-semi-bold);
11
12
  }
12
13
  }
13
14
 
14
- .money-input__number-input{
15
+ .money-input__number-input {
15
16
  [dir="rtl"] & {
16
17
  text-align: end;
17
18
  }
@@ -26,7 +27,8 @@
26
27
  .form-control {
27
28
  min-height: 34px;
28
29
  }
29
- .np-text-title-subsection {
30
+ .np-text-title-subsection,
31
+ .wds-text-title-subsection {
30
32
  font-size: var(--font-size-14);
31
33
  }
32
34
  }
@@ -35,7 +37,8 @@
35
37
  .form-control {
36
38
  min-height: 53px;
37
39
  }
38
- .np-text-title-subsection {
40
+ .np-text-title-subsection,
41
+ .wds-text-title-subsection {
39
42
  font-size: var(--font-size-16);
40
43
  }
41
44
  }
@@ -22,7 +22,7 @@ const PocketCard = ({ variant }: { variant?: PocketVariant } = {}) => (
22
22
  {variant}
23
23
  </span>
24
24
  )}
25
- <strong className="np-text-title-screen" style={{ color: 'inherit' }}>
25
+ <strong className="wds-text-title-screen" style={{ color: 'inherit' }}>
26
26
  Some headline text
27
27
  </strong>
28
28
  <p style={{ margin: 0 }}>A bit of body copy</p>
@@ -227,7 +227,7 @@ export const ExposedTokens: Story = {
227
227
  <PocketSurface key={variant} pocket={variant}>
228
228
  <div className="p-a-3">
229
229
  <h4
230
- className="d-block m-b-2 text-capitalize np-text-title-body"
230
+ className="d-block m-b-2 text-capitalize wds-text-title-body"
231
231
  style={{ color: 'inherit' }}
232
232
  >
233
233
  {variant}
@@ -26,46 +26,8 @@
26
26
  padding: var(--size-24);
27
27
  }
28
28
  .np-popover__container.np-bottom-sheet .np-popover__title {
29
- margin: 0;
30
- color: #37517e;
31
- color: var(--color-content-primary);
32
- word-wrap: break-word;
33
29
  margin-block-end: initial;
34
30
  }
35
- @supports (hyphenate-limit-chars: 1) {
36
- .np-popover__container.np-bottom-sheet .np-popover__title {
37
- hyphens: auto;
38
- hyphenate-limit-chars: 7 3;
39
- }
40
- @media (min-width: 840px) {
41
- .np-popover__container.np-bottom-sheet .np-popover__title {
42
- hyphenate-limit-chars: 8 3;
43
- }
44
- }
45
- @media (min-width: 1160px) {
46
- .np-popover__container.np-bottom-sheet .np-popover__title {
47
- hyphenate-limit-chars: 10 4 3;
48
- }
49
- }
50
- }
51
- @supports (not (hyphenate-limit-chars: 1)) and (-webkit-hyphenate-limit-before: 1) {
52
- .np-popover__container.np-bottom-sheet .np-popover__title {
53
- hyphens: auto;
54
- -webkit-hyphenate-limit-before: 3;
55
- -webkit-hyphenate-limit-after: 3;
56
- }
57
- @media (min-width: 1160px) {
58
- .np-popover__container.np-bottom-sheet .np-popover__title {
59
- -webkit-hyphenate-limit-before: 4;
60
- }
61
- }
62
- }
63
- .np-popover__container.np-bottom-sheet .np-popover__title + p,
64
- .np-popover__container.np-bottom-sheet .np-popover__title + ul:not(.list-unstyled),
65
- .np-popover__container.np-bottom-sheet .np-popover__title + ol:not(.list-unstyled) {
66
- margin-block-start: 8px;
67
- margin-block-start: var(--size-8);
68
- }
69
31
  .np-popover__container.np-bottom-sheet .np-popover__content {
70
32
  padding-block: 32px;
71
33
  padding-block: var(--size-32);
@@ -30,7 +30,7 @@
30
30
 
31
31
  &.np-bottom-sheet {
32
32
  .np-popover__title {
33
- .np-text-title-section();
33
+ .wds-text-title-section();
34
34
  }
35
35
 
36
36
  .np-popover__content {
@@ -1,4 +1,5 @@
1
- .np-progress-bar__title .h4 {
1
+ .np-progress-bar__title .h4,
2
+ .np-progress-bar__title .wds-text-title-body {
2
3
  color: #37517e;
3
4
  color: var(--color-content-primary);
4
5
  margin-block-end: 4px;
@@ -1,14 +1,15 @@
1
1
  .np-progress-bar {
2
- &__title {
3
- .h4 {
4
- color: var(--color-content-primary);
5
- margin-bottom: var(--size-4);
6
- }
7
- }
8
-
9
- p {
2
+ &__title {
3
+ .h4,
4
+ .wds-text-title-body {
10
5
  color: var(--color-content-primary);
11
- margin-top: var(--size-4);
12
- font-weight: var(--font-weight-semi-bold);
6
+ margin-bottom: var(--size-4);
13
7
  }
14
- }
8
+ }
9
+
10
+ p {
11
+ color: var(--color-content-primary);
12
+ margin-top: var(--size-4);
13
+ font-weight: var(--font-weight-semi-bold);
14
+ }
15
+ }
@@ -564,7 +564,7 @@ export const ExposedTokens: Story = {
564
564
  }}
565
565
  >
566
566
  <h4
567
- className="d-block m-b-2 text-capitalize np-text-title-body"
567
+ className="d-block m-b-2 text-capitalize wds-text-title-body"
568
568
  style={{
569
569
  color: 'inherit',
570
570
  }}
@@ -73,7 +73,7 @@ const Stepper = ({ steps, activeStep = 0, className, testId }: StepperProps) =>
73
73
  className={clsx(
74
74
  'hidden-xs',
75
75
  'tw-stepper__step',
76
- active ? 'np-text-body-default-bold tw-stepper__step--active' : 'np-text-body-default',
76
+ active ? 'wds-text-body-default-bold tw-stepper__step--active' : 'wds-text-body-default',
77
77
  clickable && 'tw-stepper__step--clickable',
78
78
  step.hoverLabel && 'tw-stepper__step--has-tooltip',
79
79
  )}
@@ -50,7 +50,7 @@ const TableHeader = ({
50
50
  // If headers are empty, we still should render empty headers to keep visual consistency
51
51
  return (
52
52
  <div
53
- className="np-table-header-content np-text-body-default-bold"
53
+ className="np-table-header-content wds-text-body-default-bold"
54
54
  data-testid="np-table-empty-header"
55
55
  >
56
56
  &nbsp;