@transferwise/components 0.0.0-experimental-9b6c3f8 → 0.0.0-experimental-c70eb7d
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/build/Body/Body.js +1 -1
- package/build/Body/Body.js.map +1 -1
- package/build/Body/Body.mjs +1 -1
- package/build/Body/Body.mjs.map +1 -1
- package/build/Calendar/DayCalendar/Table/DayCalendarTable.js +1 -1
- package/build/Calendar/DayCalendar/Table/DayCalendarTable.js.map +1 -1
- package/build/Calendar/DayCalendar/Table/DayCalendarTable.mjs +1 -1
- package/build/Calendar/DayCalendar/Table/DayCalendarTable.mjs.map +1 -1
- package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.js +1 -1
- package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.js.map +1 -1
- package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.mjs +1 -1
- package/build/Calendar/MonthCalendar/Table/MonthCalendarTable.mjs.map +1 -1
- package/build/Calendar/TableLink/TableLink.js +1 -1
- package/build/Calendar/TableLink/TableLink.js.map +1 -1
- package/build/Calendar/TableLink/TableLink.mjs +1 -1
- package/build/Calendar/TableLink/TableLink.mjs.map +1 -1
- package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.js +1 -1
- package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.js.map +1 -1
- package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.mjs +1 -1
- package/build/FlowNavigation/AnimatedLabel/AnimatedLabel.mjs.map +1 -1
- package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.js +2 -2
- package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.js.map +1 -1
- package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.mjs +2 -2
- package/build/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.mjs.map +1 -1
- package/build/Inputs/SelectInput/Option/SelectInputOption.js +1 -1
- package/build/Inputs/SelectInput/Option/SelectInputOption.js.map +1 -1
- package/build/Inputs/SelectInput/Option/SelectInputOption.mjs +1 -1
- package/build/Inputs/SelectInput/Option/SelectInputOption.mjs.map +1 -1
- package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.js +3 -3
- package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.js.map +1 -1
- package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.mjs +3 -3
- package/build/Inputs/SelectInput/OptionContent/SelectInputOptionContent.mjs.map +1 -1
- package/build/Inputs/SelectInput/Popover/SelectInputPopover.js +2 -2
- package/build/Inputs/SelectInput/Popover/SelectInputPopover.js.map +1 -1
- package/build/Inputs/SelectInput/Popover/SelectInputPopover.mjs +2 -2
- package/build/Inputs/SelectInput/Popover/SelectInputPopover.mjs.map +1 -1
- package/build/Label/Label.js +1 -1
- package/build/Label/Label.js.map +1 -1
- package/build/Label/Label.mjs +1 -1
- package/build/Label/Label.mjs.map +1 -1
- package/build/Stepper/Stepper.js +1 -1
- package/build/Stepper/Stepper.js.map +1 -1
- package/build/Stepper/Stepper.mjs +1 -1
- package/build/Stepper/Stepper.mjs.map +1 -1
- package/build/Table/Header/TableHeader.js +1 -1
- package/build/Table/Header/TableHeader.js.map +1 -1
- package/build/Table/Header/TableHeader.mjs +1 -1
- package/build/Table/Header/TableHeader.mjs.map +1 -1
- package/build/Tabs/Tab/Tab.js +1 -1
- package/build/Tabs/Tab/Tab.js.map +1 -1
- package/build/Tabs/Tab/Tab.mjs +1 -1
- package/build/Tabs/Tab/Tab.mjs.map +1 -1
- package/build/Tag/Tag.js +1 -1
- package/build/Tag/Tag.js.map +1 -1
- package/build/Tag/Tag.mjs +1 -1
- package/build/Tag/Tag.mjs.map +1 -1
- package/build/Typeahead/TypeaheadOption/TypeaheadOption.js +2 -2
- package/build/Typeahead/TypeaheadOption/TypeaheadOption.js.map +1 -1
- package/build/Typeahead/TypeaheadOption/TypeaheadOption.mjs +2 -2
- package/build/Typeahead/TypeaheadOption/TypeaheadOption.mjs.map +1 -1
- package/build/Upload/Steps/UploadImageStep/UploadImageStep.js +2 -2
- package/build/Upload/Steps/UploadImageStep/UploadImageStep.js.map +1 -1
- package/build/Upload/Steps/UploadImageStep/UploadImageStep.mjs +2 -2
- package/build/Upload/Steps/UploadImageStep/UploadImageStep.mjs.map +1 -1
- package/build/_deprecated/ActionButton/ActionButton.js +1 -1
- package/build/_deprecated/ActionButton/ActionButton.js.map +1 -1
- package/build/_deprecated/ActionButton/ActionButton.mjs +1 -1
- package/build/_deprecated/ActionButton/ActionButton.mjs.map +1 -1
- package/build/_deprecated/Avatar/Avatar.js +1 -1
- package/build/_deprecated/Avatar/Avatar.js.map +1 -1
- package/build/_deprecated/Avatar/Avatar.mjs +1 -1
- package/build/_deprecated/Avatar/Avatar.mjs.map +1 -1
- package/build/_deprecated/Select/Select.js +2 -2
- package/build/_deprecated/Select/Select.js.map +1 -1
- package/build/_deprecated/Select/Select.mjs +2 -2
- package/build/_deprecated/Select/Select.mjs.map +1 -1
- package/build/common/PropsValues/typography.js +0 -6
- package/build/common/PropsValues/typography.js.map +1 -1
- package/build/common/PropsValues/typography.mjs +0 -6
- package/build/common/PropsValues/typography.mjs.map +1 -1
- package/build/main.css +98 -117
- package/build/styles/Accordion/Accordion.css +1 -2
- package/build/styles/Body/Body.css +1 -1
- package/build/styles/Chips/Chip/Chip.css +2 -4
- package/build/styles/Decision/Decision.css +1 -2
- package/build/styles/Inputs/Input/Input.css +38 -0
- package/build/styles/Inputs/TextArea/TextArea.css +38 -0
- package/build/styles/MoneyInput/MoneyInput.css +3 -6
- package/build/styles/Popover/Popover.css +38 -0
- package/build/styles/ProgressBar/ProgressBar.css +1 -2
- package/build/styles/Table/Table.css +5 -15
- package/build/styles/Tile/Tile.css +1 -2
- package/build/styles/Typeahead/Typeahead.css +2 -4
- package/build/styles/_deprecated/CriticalBanner/CriticalCommsBanner.css +1 -2
- package/build/styles/_deprecated/Select/Select.css +4 -17
- package/build/styles/main.css +98 -117
- package/build/types/common/PropsValues/typography.d.ts +1 -13
- package/build/types/common/PropsValues/typography.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/Accordion/Accordion.css +1 -2
- package/src/Accordion/Accordion.less +1 -2
- package/src/Body/Body.css +1 -1
- package/src/Body/Body.less +1 -1
- package/src/Body/Body.test.tsx +4 -4
- package/src/Body/Body.tsx +2 -2
- package/src/Calendar/DayCalendar/Table/DayCalendarTable.tsx +2 -2
- package/src/Calendar/MonthCalendar/Table/MonthCalendarTable.tsx +1 -1
- package/src/Calendar/TableLink/TableLink.tsx +1 -1
- package/src/Chips/Chip/Chip.css +2 -4
- package/src/Chips/Chip/Chip.less +1 -2
- package/src/Decision/Decision.css +1 -2
- package/src/Decision/Decision.less +1 -2
- package/src/DefinitionList/_stories/DefinitionList.story.tsx +1 -1
- package/src/Display/_stories/Display.story.tsx +6 -20
- package/src/FlowNavigation/AnimatedLabel/AnimatedLabel.tsx +1 -1
- package/src/Inputs/Input/Input.css +38 -0
- package/src/Inputs/SelectInput/BottomSheet/SelectInputBottomSheet.tsx +2 -2
- package/src/Inputs/SelectInput/Option/SelectInputOption.tsx +1 -1
- package/src/Inputs/SelectInput/OptionContent/SelectInputOptionContent.tsx +3 -3
- package/src/Inputs/SelectInput/Popover/SelectInputPopover.tsx +2 -2
- package/src/Inputs/SelectInput/_stories/SelectInput.story.tsx +1 -1
- package/src/Inputs/TextArea/TextArea.css +38 -0
- package/src/Inputs/_common.less +5 -5
- package/src/Label/Label.tsx +1 -1
- package/src/MoneyInput/MoneyInput.css +3 -6
- package/src/MoneyInput/MoneyInput.less +4 -7
- package/src/PocketSurface/_stories/PocketSurface.story.tsx +2 -2
- package/src/Popover/Popover.css +38 -0
- package/src/Popover/Popover.less +1 -1
- package/src/ProgressBar/ProgressBar.css +1 -2
- package/src/ProgressBar/ProgressBar.less +11 -12
- package/src/SentimentSurface/_stories/SentimentSurface.story.tsx +1 -1
- package/src/Stepper/Stepper.tsx +1 -1
- package/src/Table/Header/TableHeader.tsx +1 -1
- package/src/Table/StatusText/TableStatusText.test.tsx +5 -5
- package/src/Table/Table.css +5 -15
- package/src/Table/Table.less +6 -17
- package/src/Tabs/Tab/Tab.tsx +1 -1
- package/src/Tag/Tag.tsx +1 -1
- package/src/Tag/_stories/Tag.story.tsx +1 -1
- package/src/Tile/Tile.css +1 -2
- package/src/Tile/Tile.less +1 -2
- package/src/Typeahead/Typeahead.css +2 -4
- package/src/Typeahead/Typeahead.less +1 -2
- package/src/Typeahead/TypeaheadOption/TypeaheadOption.tsx +2 -2
- package/src/Upload/Steps/UploadImageStep/UploadImageStep.tsx +2 -2
- package/src/_deprecated/ActionButton/ActionButton.tsx +1 -1
- package/src/_deprecated/Avatar/Avatar.tsx +1 -1
- package/src/_deprecated/CriticalBanner/CriticalCommsBanner.css +1 -2
- package/src/_deprecated/CriticalBanner/CriticalCommsBanner.less +1 -2
- package/src/_deprecated/NavigationOption/_stories/NavigationOption.story.tsx +6 -6
- package/src/_deprecated/Select/Select.css +4 -17
- package/src/_deprecated/Select/Select.less +5 -10
- package/src/_deprecated/Select/Select.tsx +2 -2
- package/src/common/PropsValues/typography.ts +1 -20
- package/src/main.css +98 -117
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
.np-decision .decision {
|
|
2
2
|
display: flex;
|
|
3
3
|
}
|
|
4
|
-
.np-decision__tile--small .np-text-title-subsection
|
|
5
|
-
.np-decision__tile--small .wds-text-title-subsection {
|
|
4
|
+
.np-decision__tile--small .np-text-title-subsection {
|
|
6
5
|
font-size: 1rem;
|
|
7
6
|
font-size: var(--font-size-16);
|
|
8
7
|
line-height: 1.2;
|
|
@@ -118,40 +118,26 @@ export const Basic = () => {
|
|
|
118
118
|
export const Numbers = () => {
|
|
119
119
|
return (
|
|
120
120
|
<>
|
|
121
|
-
<Title type={Typography.TITLE_SCREEN}>Display Number
|
|
121
|
+
<Title type={Typography.TITLE_SCREEN}>Display Number</Title>
|
|
122
122
|
<hr />
|
|
123
|
-
<Display type={Typography.
|
|
123
|
+
<Display type={Typography.DISPLAY_NUMBER}>
|
|
124
124
|
<Money amount={1050.6} currency="UAH" />
|
|
125
125
|
</Display>
|
|
126
126
|
<hr />
|
|
127
|
-
<Display type={Typography.
|
|
127
|
+
<Display type={Typography.DISPLAY_NUMBER}>
|
|
128
128
|
<Money amount={10.17} currency="JPY" />
|
|
129
129
|
</Display>
|
|
130
|
-
|
|
131
|
-
<Title type={Typography.TITLE_SCREEN}>Display Number Medium</Title>
|
|
132
130
|
<hr />
|
|
133
|
-
<Display type={Typography.
|
|
131
|
+
<Display type={Typography.DISPLAY_NUMBER}>
|
|
134
132
|
<Money amount={0.01} currency="EUR" />
|
|
135
133
|
</Display>
|
|
136
134
|
<hr />
|
|
137
|
-
<Display type={Typography.
|
|
135
|
+
<Display type={Typography.DISPLAY_NUMBER}>
|
|
138
136
|
<Money amount={1000000} currency="EUR" />
|
|
139
137
|
</Display>
|
|
140
|
-
|
|
141
|
-
<Title type={Typography.TITLE_SCREEN}>Display Number Large</Title>
|
|
142
|
-
<hr />
|
|
143
|
-
<Display type={Typography.DISPLAY_NUMBER_LARGE}>
|
|
144
|
-
<Money amount={1000000} currency="GBP" />
|
|
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
138
|
<hr />
|
|
153
139
|
<Display type={Typography.DISPLAY_NUMBER}>
|
|
154
|
-
<Money amount={
|
|
140
|
+
<Money amount={1000000} currency="GBP" />
|
|
155
141
|
</Display>
|
|
156
142
|
</>
|
|
157
143
|
);
|
|
@@ -40,7 +40,7 @@ const AnimatedLabel = ({ activeLabel, className, steps }: AnimatedLabelProps) =>
|
|
|
40
40
|
className={clsx(
|
|
41
41
|
'np-animated-label',
|
|
42
42
|
'btn-unstyled',
|
|
43
|
-
'
|
|
43
|
+
'np-text-body-large-bold',
|
|
44
44
|
className,
|
|
45
45
|
)}
|
|
46
46
|
onClick={() => setShowSteps(true)}
|
|
@@ -219,10 +219,48 @@
|
|
|
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;
|
|
222
226
|
margin-block-end: initial;
|
|
223
227
|
block-size: 72px !important;
|
|
224
228
|
block-size: var(--size-72) !important;
|
|
225
229
|
}
|
|
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
|
+
}
|
|
226
264
|
.np-input::-moz-placeholder {
|
|
227
265
|
color: #768e9c;
|
|
228
266
|
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
|
|
125
|
+
<h2 className="np-bottom-sheet-v2-title np-text-title-body">{title}</h2>
|
|
126
126
|
) : null}
|
|
127
|
-
<div className="np-bottom-sheet-v2-body
|
|
127
|
+
<div className="np-bottom-sheet-v2-body np-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
|
|
37
|
+
'np-select-input-option-container np-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) && '
|
|
31
|
+
(note || description) && 'np-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
|
|
55
|
+
<span className="np-select-input-option-content-text-secondary np-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
|
|
64
|
+
'np-select-input-option-content-text-secondary np-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
|
|
127
|
+
<h2 className="np-popover-v2-title np-text-title-body">{title}</h2>
|
|
128
128
|
) : null}
|
|
129
|
-
<div className="np-popover-v2-content
|
|
129
|
+
<div className="np-popover-v2-content np-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
|
|
1279
|
+
<p className="m-b-3 np-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,10 +219,48 @@
|
|
|
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;
|
|
222
226
|
margin-block-end: initial;
|
|
223
227
|
block-size: 72px !important;
|
|
224
228
|
block-size: var(--size-72) !important;
|
|
225
229
|
}
|
|
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
|
+
}
|
|
226
264
|
.np-text-area {
|
|
227
265
|
min-block-size: 72px;
|
|
228
266
|
min-block-size: var(--size-72);
|
package/src/Inputs/_common.less
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@import (reference)
|
|
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
|
-
.
|
|
43
|
+
.np-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
|
-
.
|
|
57
|
+
.np-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
|
-
.
|
|
65
|
+
.np-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
|
-
.
|
|
73
|
+
.np-text-title-subsection;
|
|
74
74
|
height: var(--size-72) !important;
|
|
75
75
|
}
|
|
76
76
|
}
|
package/src/Label/Label.tsx
CHANGED
|
@@ -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
|
|
32
|
+
'np-label d-flex flex-column np-text-body-default-bold text-primary m-b-0',
|
|
33
33
|
className,
|
|
34
34
|
)}
|
|
35
35
|
>
|
|
@@ -4,8 +4,7 @@
|
|
|
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
|
|
8
|
-
.tw-money-input .tw-money-input__fixed-currency .wds-text-title-subsection {
|
|
7
|
+
.tw-money-input .tw-money-input__fixed-currency .np-text-title-subsection {
|
|
9
8
|
color: #768e9c;
|
|
10
9
|
color: var(--color-content-tertiary);
|
|
11
10
|
font-weight: 600;
|
|
@@ -21,16 +20,14 @@
|
|
|
21
20
|
.tw-money-input.input-group-sm .form-control {
|
|
22
21
|
min-block-size: 34px;
|
|
23
22
|
}
|
|
24
|
-
.tw-money-input.input-group-sm .np-text-title-subsection
|
|
25
|
-
.tw-money-input.input-group-sm .wds-text-title-subsection {
|
|
23
|
+
.tw-money-input.input-group-sm .np-text-title-subsection {
|
|
26
24
|
font-size: 0.875rem;
|
|
27
25
|
font-size: var(--font-size-14);
|
|
28
26
|
}
|
|
29
27
|
.tw-money-input.input-group-md .form-control {
|
|
30
28
|
min-block-size: 53px;
|
|
31
29
|
}
|
|
32
|
-
.tw-money-input.input-group-md .np-text-title-subsection
|
|
33
|
-
.tw-money-input.input-group-md .wds-text-title-subsection {
|
|
30
|
+
.tw-money-input.input-group-md .np-text-title-subsection {
|
|
34
31
|
font-size: 1rem;
|
|
35
32
|
font-size: var(--font-size-16);
|
|
36
33
|
}
|
|
@@ -5,14 +5,13 @@
|
|
|
5
5
|
.tw-money-input__fixed-currency {
|
|
6
6
|
padding-left: 0 !important;
|
|
7
7
|
|
|
8
|
-
.np-text-title-subsection
|
|
9
|
-
.wds-text-title-subsection {
|
|
8
|
+
.np-text-title-subsection {
|
|
10
9
|
color: var(--color-content-tertiary);
|
|
11
10
|
font-weight: var(--font-weight-semi-bold);
|
|
12
11
|
}
|
|
13
12
|
}
|
|
14
13
|
|
|
15
|
-
.money-input__number-input
|
|
14
|
+
.money-input__number-input{
|
|
16
15
|
[dir="rtl"] & {
|
|
17
16
|
text-align: end;
|
|
18
17
|
}
|
|
@@ -27,8 +26,7 @@
|
|
|
27
26
|
.form-control {
|
|
28
27
|
min-height: 34px;
|
|
29
28
|
}
|
|
30
|
-
.np-text-title-subsection
|
|
31
|
-
.wds-text-title-subsection {
|
|
29
|
+
.np-text-title-subsection {
|
|
32
30
|
font-size: var(--font-size-14);
|
|
33
31
|
}
|
|
34
32
|
}
|
|
@@ -37,8 +35,7 @@
|
|
|
37
35
|
.form-control {
|
|
38
36
|
min-height: 53px;
|
|
39
37
|
}
|
|
40
|
-
.np-text-title-subsection
|
|
41
|
-
.wds-text-title-subsection {
|
|
38
|
+
.np-text-title-subsection {
|
|
42
39
|
font-size: var(--font-size-16);
|
|
43
40
|
}
|
|
44
41
|
}
|
|
@@ -22,7 +22,7 @@ const PocketCard = ({ variant }: { variant?: PocketVariant } = {}) => (
|
|
|
22
22
|
{variant}
|
|
23
23
|
</span>
|
|
24
24
|
)}
|
|
25
|
-
<strong className="
|
|
25
|
+
<strong className="np-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
|
|
230
|
+
className="d-block m-b-2 text-capitalize np-text-title-body"
|
|
231
231
|
style={{ color: 'inherit' }}
|
|
232
232
|
>
|
|
233
233
|
{variant}
|
package/src/Popover/Popover.css
CHANGED
|
@@ -26,8 +26,46 @@
|
|
|
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;
|
|
29
33
|
margin-block-end: initial;
|
|
30
34
|
}
|
|
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
|
+
}
|
|
31
69
|
.np-popover__container.np-bottom-sheet .np-popover__content {
|
|
32
70
|
padding-block: 32px;
|
|
33
71
|
padding-block: var(--size-32);
|
package/src/Popover/Popover.less
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
.np-progress-bar {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
&__title {
|
|
3
|
+
.h4 {
|
|
4
|
+
color: var(--color-content-primary);
|
|
5
|
+
margin-bottom: var(--size-4);
|
|
6
|
+
}
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
p {
|
|
5
10
|
color: var(--color-content-primary);
|
|
6
|
-
margin-
|
|
11
|
+
margin-top: var(--size-4);
|
|
12
|
+
font-weight: var(--font-weight-semi-bold);
|
|
7
13
|
}
|
|
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
|
-
}
|
|
14
|
+
}
|
package/src/Stepper/Stepper.tsx
CHANGED
|
@@ -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 ? '
|
|
76
|
+
active ? 'np-text-body-default-bold tw-stepper__step--active' : 'np-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
|
|
53
|
+
className="np-table-header-content np-text-body-default-bold"
|
|
54
54
|
data-testid="np-table-empty-header"
|
|
55
55
|
>
|
|
56
56
|
|
|
@@ -13,7 +13,7 @@ describe('TableStatusText Component', () => {
|
|
|
13
13
|
it('renders the text and applies the default class', () => {
|
|
14
14
|
renderComponent();
|
|
15
15
|
expect(screen.getByText('Status Text')).toBeInTheDocument();
|
|
16
|
-
expect(screen.getByText('Status Text')).toHaveClass('
|
|
16
|
+
expect(screen.getByText('Status Text')).toHaveClass('np-text-body-default');
|
|
17
17
|
});
|
|
18
18
|
|
|
19
19
|
it('applies the custom class name', () => {
|
|
@@ -23,12 +23,12 @@ describe('TableStatusText Component', () => {
|
|
|
23
23
|
|
|
24
24
|
it('applies the default typography class when typography is not provided', () => {
|
|
25
25
|
renderComponent();
|
|
26
|
-
expect(screen.getByText('Status Text')).toHaveClass('
|
|
26
|
+
expect(screen.getByText('Status Text')).toHaveClass('np-text-body-default');
|
|
27
27
|
});
|
|
28
28
|
|
|
29
29
|
it('applies the typography class when typography equals `default-bold`', () => {
|
|
30
30
|
renderComponent({ typography: 'default-bold' });
|
|
31
|
-
expect(screen.getByText('Status Text')).toHaveClass('
|
|
31
|
+
expect(screen.getByText('Status Text')).toHaveClass('np-text-body-default-bold');
|
|
32
32
|
});
|
|
33
33
|
|
|
34
34
|
it('does not render any icon when status is not provided', () => {
|
|
@@ -39,14 +39,14 @@ describe('TableStatusText Component', () => {
|
|
|
39
39
|
|
|
40
40
|
it('applies the typography and status classes, renders the error icon when status equals `error`', () => {
|
|
41
41
|
renderComponent({ status: 'error' });
|
|
42
|
-
expect(screen.getByText('Status Text')).toHaveClass('
|
|
42
|
+
expect(screen.getByText('Status Text')).toHaveClass('np-text-body-default-bold');
|
|
43
43
|
expect(screen.getByText('Status Text')).toHaveClass('np-table-content--error');
|
|
44
44
|
expect(screen.getByTestId('alert-icon')).toBeInTheDocument();
|
|
45
45
|
});
|
|
46
46
|
|
|
47
47
|
it('applies the typography and status classes, renders the success icon when status equals `success`', () => {
|
|
48
48
|
renderComponent({ status: 'success' });
|
|
49
|
-
expect(screen.getByText('Status Text')).toHaveClass('
|
|
49
|
+
expect(screen.getByText('Status Text')).toHaveClass('np-text-body-default-bold');
|
|
50
50
|
expect(screen.getByText('Status Text')).toHaveClass('np-table-content--success');
|
|
51
51
|
expect(screen.getByTestId('check-icon')).toBeInTheDocument();
|
|
52
52
|
});
|
package/src/Table/Table.css
CHANGED
|
@@ -40,16 +40,10 @@
|
|
|
40
40
|
}
|
|
41
41
|
.np-table-inner-container {
|
|
42
42
|
background-image: linear-gradient(to right, var(--color-contrast-overlay), var(--color-contrast-overlay)), linear-gradient(to right, var(--color-contrast-overlay), var(--color-contrast-overlay)), linear-gradient(to right, rgba(0, 0, 0, 0.1), rgba(255, 255, 255, 0)), linear-gradient(to left, rgba(0, 0, 0, 0.1), rgba(255, 255, 255, 0));
|
|
43
|
-
background-position: left center,
|
|
44
|
-
right center,
|
|
45
|
-
left center,
|
|
46
|
-
right center;
|
|
43
|
+
background-position: left center, right center, left center, right center;
|
|
47
44
|
background-repeat: no-repeat;
|
|
48
45
|
background-color: var(--color-contrast-overlay);
|
|
49
|
-
background-size: 15px 100%,
|
|
50
|
-
15px 100%,
|
|
51
|
-
15px 100%,
|
|
52
|
-
15px 100%;
|
|
46
|
+
background-size: 15px 100%, 15px 100%, 15px 100%, 15px 100%;
|
|
53
47
|
background-attachment: local, local, scroll, scroll;
|
|
54
48
|
overflow-x: auto;
|
|
55
49
|
border-radius: 10px;
|
|
@@ -144,9 +138,7 @@
|
|
|
144
138
|
padding-inline-end: 0;
|
|
145
139
|
}
|
|
146
140
|
.np-table-header.np-table-header--right > .np-text-body-default,
|
|
147
|
-
.np-table-cell.np-table-cell--right > .np-text-body-default
|
|
148
|
-
.np-table-header.np-table-header--right > .wds-text-body-default,
|
|
149
|
-
.np-table-cell.np-table-cell--right > .wds-text-body-default {
|
|
141
|
+
.np-table-cell.np-table-cell--right > .np-text-body-default {
|
|
150
142
|
text-align: end;
|
|
151
143
|
}
|
|
152
144
|
.np-table-header.np-table-header--right + .np-table-header:not(.np-table-header--right),
|
|
@@ -205,8 +197,7 @@
|
|
|
205
197
|
.np-table-cell--primary {
|
|
206
198
|
min-inline-size: 200px;
|
|
207
199
|
}
|
|
208
|
-
.np-table-cell--currency .np-text-body-default
|
|
209
|
-
.np-table-cell--currency .wds-text-body-default {
|
|
200
|
+
.np-table-cell--currency .np-text-body-default {
|
|
210
201
|
white-space: nowrap;
|
|
211
202
|
}
|
|
212
203
|
.np-table-cell .tw-chevron {
|
|
@@ -223,8 +214,7 @@
|
|
|
223
214
|
background-color: var(--color-background-neutral);
|
|
224
215
|
padding: 0;
|
|
225
216
|
}
|
|
226
|
-
.np-table-cell .np-text-body-default-bold
|
|
227
|
-
.np-table-cell .wds-text-body-default-bold {
|
|
217
|
+
.np-table-cell .np-text-body-default-bold {
|
|
228
218
|
display: flex;
|
|
229
219
|
align-items: center;
|
|
230
220
|
color: #37517e;
|