@transferwise/components 46.168.0 → 46.168.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/build/Prompt/Snackbar/Snackbar.js +4 -7
- package/build/Prompt/Snackbar/Snackbar.js.map +1 -1
- package/build/Prompt/Snackbar/Snackbar.mjs +4 -7
- package/build/Prompt/Snackbar/Snackbar.mjs.map +1 -1
- package/build/Prompt/Snackbar/useSnackbarSwipeDismiss.js +33 -46
- package/build/Prompt/Snackbar/useSnackbarSwipeDismiss.js.map +1 -1
- package/build/Prompt/Snackbar/useSnackbarSwipeDismiss.mjs +34 -47
- package/build/Prompt/Snackbar/useSnackbarSwipeDismiss.mjs.map +1 -1
- package/build/Provider/Provider.js +1 -24
- package/build/Provider/Provider.js.map +1 -1
- package/build/Provider/Provider.mjs +1 -24
- package/build/Provider/Provider.mjs.map +1 -1
- package/build/WithDisplayFormat/WithDisplayFormat.js +20 -8
- package/build/WithDisplayFormat/WithDisplayFormat.js.map +1 -1
- package/build/WithDisplayFormat/WithDisplayFormat.mjs +20 -8
- package/build/WithDisplayFormat/WithDisplayFormat.mjs.map +1 -1
- package/build/i18n/cs.json +1 -0
- package/build/i18n/cs.json.js +1 -0
- package/build/i18n/cs.json.js.map +1 -1
- package/build/i18n/cs.json.mjs +1 -0
- package/build/i18n/cs.json.mjs.map +1 -1
- package/build/i18n/es.json +1 -0
- package/build/i18n/es.json.js +1 -0
- package/build/i18n/es.json.js.map +1 -1
- package/build/i18n/es.json.mjs +1 -0
- package/build/i18n/es.json.mjs.map +1 -1
- package/build/i18n/id.json +1 -0
- package/build/i18n/id.json.js +1 -0
- package/build/i18n/id.json.js.map +1 -1
- package/build/i18n/id.json.mjs +1 -0
- package/build/i18n/id.json.mjs.map +1 -1
- package/build/i18n/ja.json +1 -0
- package/build/i18n/ja.json.js +1 -0
- package/build/i18n/ja.json.js.map +1 -1
- package/build/i18n/ja.json.mjs +1 -0
- package/build/i18n/ja.json.mjs.map +1 -1
- package/build/i18n/nl.json +1 -0
- package/build/i18n/nl.json.js +1 -0
- package/build/i18n/nl.json.js.map +1 -1
- package/build/i18n/nl.json.mjs +1 -0
- package/build/i18n/nl.json.mjs.map +1 -1
- package/build/i18n/pt.json +1 -0
- package/build/i18n/pt.json.js +1 -0
- package/build/i18n/pt.json.js.map +1 -1
- package/build/i18n/pt.json.mjs +1 -0
- package/build/i18n/pt.json.mjs.map +1 -1
- package/build/i18n/ro.json +1 -0
- package/build/i18n/ro.json.js +1 -0
- package/build/i18n/ro.json.js.map +1 -1
- package/build/i18n/ro.json.mjs +1 -0
- package/build/i18n/ro.json.mjs.map +1 -1
- package/build/i18n/ru.json +1 -0
- package/build/i18n/ru.json.js +1 -0
- package/build/i18n/ru.json.js.map +1 -1
- package/build/i18n/ru.json.mjs +1 -0
- package/build/i18n/ru.json.mjs.map +1 -1
- package/build/i18n/uk.json +1 -0
- package/build/i18n/uk.json.js +1 -0
- package/build/i18n/uk.json.js.map +1 -1
- package/build/i18n/uk.json.mjs +1 -0
- package/build/i18n/uk.json.mjs.map +1 -1
- package/build/i18n/zh-HK.json +1 -0
- package/build/i18n/zh-HK.json.js +1 -0
- package/build/i18n/zh-HK.json.js.map +1 -1
- package/build/i18n/zh-HK.json.mjs +1 -0
- package/build/i18n/zh-HK.json.mjs.map +1 -1
- package/build/main.css +1 -0
- package/build/styles/Inputs/InputGroup/InputGroup.css +1 -0
- package/build/styles/main.css +1 -0
- package/build/test-utils/assets/apple-pay-logo.svg +0 -0
- package/build/types/Prompt/Snackbar/Snackbar.d.ts.map +1 -1
- package/build/types/Prompt/Snackbar/useSnackbarSwipeDismiss.d.ts +6 -8
- package/build/types/Prompt/Snackbar/useSnackbarSwipeDismiss.d.ts.map +1 -1
- package/build/types/WithDisplayFormat/WithDisplayFormat.d.ts +6 -4
- package/build/types/WithDisplayFormat/WithDisplayFormat.d.ts.map +1 -1
- package/package.json +15 -15
- package/src/InputWithDisplayFormat/_stories/InputWithDisplayFormat.story.tsx +39 -0
- package/src/Inputs/InputGroup/InputGroup.css +1 -0
- package/src/Inputs/InputGroup/InputGroup.less +1 -0
- package/src/Inputs/InputGroup/_stories/InputGroup.test.story.tsx +16 -0
- package/src/Inputs/SearchInput/_stories/SearchInput.test.story.tsx +9 -0
- package/src/Inputs/SelectInput/_stories/SelectInput.test.story.tsx +12 -0
- package/src/MoneyInput/_stories/MoneyInput.test.story.tsx +11 -0
- package/src/PhoneNumberInput/_stories/PhoneNumberInput.test.story.tsx +30 -0
- package/src/Prompt/Snackbar/Snackbar.test.tsx +1 -69
- package/src/Prompt/Snackbar/Snackbar.tsx +4 -6
- package/src/Prompt/Snackbar/useSnackbarSwipeDismiss.ts +39 -54
- package/src/Provider/Provider.tsx +1 -1
- package/src/WithDisplayFormat/WithDisplayFormat.test.js +90 -7
- package/src/WithDisplayFormat/WithDisplayFormat.tsx +30 -9
- package/src/i18n/cs.json +1 -0
- package/src/i18n/es.json +1 -0
- package/src/i18n/id.json +1 -0
- package/src/i18n/ja.json +1 -0
- package/src/i18n/nl.json +1 -0
- package/src/i18n/pt.json +1 -0
- package/src/i18n/ro.json +1 -0
- package/src/i18n/ru.json +1 -0
- package/src/i18n/uk.json +1 -0
- package/src/i18n/zh-HK.json +1 -0
- package/src/main.css +1 -0
- package/src/test-utils/assets/apple-pay-logo.svg +0 -0
package/build/i18n/ro.json
CHANGED
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Prefix",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "Caută...",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "Nu s-a găsit niciun rezultat",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "Apasă pe Escape pentru a închide.",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "Eroare:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "Informații:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "În așteptare:",
|
package/build/i18n/ro.json.js
CHANGED
|
@@ -42,6 +42,7 @@ var ro = {
|
|
|
42
42
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Prefix",
|
|
43
43
|
"neptune.Select.searchPlaceholder": "Caută...",
|
|
44
44
|
"neptune.SelectInput.noResultsFound": "Nu s-a găsit niciun rezultat",
|
|
45
|
+
"neptune.Snackbar.escapeDismissHint": "Apasă pe Escape pentru a închide.",
|
|
45
46
|
"neptune.StatusIcon.iconLabel.error": "Eroare:",
|
|
46
47
|
"neptune.StatusIcon.iconLabel.information": "Informații:",
|
|
47
48
|
"neptune.StatusIcon.iconLabel.pending": "În așteptare:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ro.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ro.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/i18n/ro.json.mjs
CHANGED
|
@@ -38,6 +38,7 @@ var ro = {
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Prefix",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "Caută...",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "Nu s-a găsit niciun rezultat",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "Apasă pe Escape pentru a închide.",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "Eroare:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "Informații:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "În așteptare:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ro.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ro.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/i18n/ru.json
CHANGED
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Код страны",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "Поиск...",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "Ничего не найдено",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "Нажмите Escape, чтобы закрыть.",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "Ошибка:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "Информация:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "В ожидании:",
|
package/build/i18n/ru.json.js
CHANGED
|
@@ -42,6 +42,7 @@ var ru = {
|
|
|
42
42
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Код страны",
|
|
43
43
|
"neptune.Select.searchPlaceholder": "Поиск...",
|
|
44
44
|
"neptune.SelectInput.noResultsFound": "Ничего не найдено",
|
|
45
|
+
"neptune.Snackbar.escapeDismissHint": "Нажмите Escape, чтобы закрыть.",
|
|
45
46
|
"neptune.StatusIcon.iconLabel.error": "Ошибка:",
|
|
46
47
|
"neptune.StatusIcon.iconLabel.information": "Информация:",
|
|
47
48
|
"neptune.StatusIcon.iconLabel.pending": "В ожидании:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ru.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ru.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/i18n/ru.json.mjs
CHANGED
|
@@ -38,6 +38,7 @@ var ru = {
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Код страны",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "Поиск...",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "Ничего не найдено",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "Нажмите Escape, чтобы закрыть.",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "Ошибка:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "Информация:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "В ожидании:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ru.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ru.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/i18n/uk.json
CHANGED
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Префікс",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "Пошук…",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "Нічого не знайдено",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "Натисніть Escape, щоб закрити.",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "Помилка:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "Інформація:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "Обробка:",
|
package/build/i18n/uk.json.js
CHANGED
|
@@ -42,6 +42,7 @@ var uk = {
|
|
|
42
42
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Префікс",
|
|
43
43
|
"neptune.Select.searchPlaceholder": "Пошук…",
|
|
44
44
|
"neptune.SelectInput.noResultsFound": "Нічого не знайдено",
|
|
45
|
+
"neptune.Snackbar.escapeDismissHint": "Натисніть Escape, щоб закрити.",
|
|
45
46
|
"neptune.StatusIcon.iconLabel.error": "Помилка:",
|
|
46
47
|
"neptune.StatusIcon.iconLabel.information": "Інформація:",
|
|
47
48
|
"neptune.StatusIcon.iconLabel.pending": "Обробка:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uk.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"uk.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/i18n/uk.json.mjs
CHANGED
|
@@ -38,6 +38,7 @@ var uk = {
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "Префікс",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "Пошук…",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "Нічого не знайдено",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "Натисніть Escape, щоб закрити.",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "Помилка:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "Інформація:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "Обробка:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"uk.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"uk.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/i18n/zh-HK.json
CHANGED
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "前綴",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "搜尋…",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "找不到任何結果",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "按下Escape鍵以關閉。",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "錯誤:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "資訊:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "處理中:",
|
package/build/i18n/zh-HK.json.js
CHANGED
|
@@ -42,6 +42,7 @@ var zhHK = {
|
|
|
42
42
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "前綴",
|
|
43
43
|
"neptune.Select.searchPlaceholder": "搜尋…",
|
|
44
44
|
"neptune.SelectInput.noResultsFound": "找不到任何結果",
|
|
45
|
+
"neptune.Snackbar.escapeDismissHint": "按下Escape鍵以關閉。",
|
|
45
46
|
"neptune.StatusIcon.iconLabel.error": "錯誤:",
|
|
46
47
|
"neptune.StatusIcon.iconLabel.information": "資訊:",
|
|
47
48
|
"neptune.StatusIcon.iconLabel.pending": "處理中:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"zh-HK.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"zh-HK.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -38,6 +38,7 @@ var zhHK = {
|
|
|
38
38
|
"neptune.PhoneNumberInput.phoneNumberPrefix": "前綴",
|
|
39
39
|
"neptune.Select.searchPlaceholder": "搜尋…",
|
|
40
40
|
"neptune.SelectInput.noResultsFound": "找不到任何結果",
|
|
41
|
+
"neptune.Snackbar.escapeDismissHint": "按下Escape鍵以關閉。",
|
|
41
42
|
"neptune.StatusIcon.iconLabel.error": "錯誤:",
|
|
42
43
|
"neptune.StatusIcon.iconLabel.information": "資訊:",
|
|
43
44
|
"neptune.StatusIcon.iconLabel.pending": "處理中:",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"zh-HK.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"zh-HK.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/build/main.css
CHANGED
|
@@ -29649,6 +29649,7 @@ button.np-option {
|
|
|
29649
29649
|
display: inline-grid;
|
|
29650
29650
|
inline-size: 100%;
|
|
29651
29651
|
grid-auto-columns: minmax(0, 1fr);
|
|
29652
|
+
isolation: isolate;
|
|
29652
29653
|
/* Prevent unwanted `group-hover/input` triggers */
|
|
29653
29654
|
border-radius: var(--radius-full);
|
|
29654
29655
|
}
|
package/build/styles/main.css
CHANGED
|
@@ -29649,6 +29649,7 @@ button.np-option {
|
|
|
29649
29649
|
display: inline-grid;
|
|
29650
29650
|
inline-size: 100%;
|
|
29651
29651
|
grid-auto-columns: minmax(0, 1fr);
|
|
29652
|
+
isolation: isolate;
|
|
29652
29653
|
/* Prevent unwanted `group-hover/input` triggers */
|
|
29653
29654
|
border-radius: var(--radius-full);
|
|
29654
29655
|
}
|
|
File without changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Snackbar.d.ts","sourceRoot":"","sources":["../../../../src/Prompt/Snackbar/Snackbar.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAG1D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAKxD,OAAO,KAAK,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAIzE;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,mGAAmG;IACnG,MAAM,CAAC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C,EAAE,gBAAgB,CAAC;IAC5B;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,iFAAiF;IACjF,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACxB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,kGAAkG;IAClG,gBAAgB,EAAE,MAAM,IAAI,CAAC;IAC7B,kGAAkG;IAClG,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB;;;OAGG;IACH,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,kGAAkG;IAClG,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC;IACtB,6EAA6E;IAC7E,KAAK,CAAC,EAAE,UAAU,GAAG,SAAS,CAAC;IAC/B;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,8FAA8F;IAC9F,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,0EAA0E;IAC1E,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,eAAO,MAAM,QAAQ,GAAI,uHAYtB,aAAa,gCAuJf,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
|
@@ -1,19 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
* Release dismisses at half the surface height; shorter
|
|
4
|
-
*
|
|
5
|
-
* follow-up click so dragging from the action cannot activate it.
|
|
2
|
+
* Follows one primary pointer's downward, mostly vertical movement without re-rendering.
|
|
3
|
+
* Release dismisses at half the surface height; shorter or cancelled gestures settle back.
|
|
4
|
+
* A drag consumes its follow-up click, so dragging from the action cannot activate it.
|
|
6
5
|
*/
|
|
7
|
-
declare const useSnackbarSwipeDismiss: ({ onDismissRequest, onSwipeChange,
|
|
6
|
+
declare const useSnackbarSwipeDismiss: ({ onDismissRequest, onSwipeChange, }: {
|
|
8
7
|
onDismissRequest: () => void;
|
|
9
8
|
/** Reports when a gesture starts and ends so auto-dismiss can pause beneath the pointer. */
|
|
10
9
|
onSwipeChange: (swiping: boolean) => void;
|
|
11
|
-
visible: boolean;
|
|
12
10
|
}) => {
|
|
13
|
-
|
|
11
|
+
cancelSwipe: () => void;
|
|
14
12
|
containerRef: import("react").RefObject<HTMLDivElement>;
|
|
15
13
|
handleClickCapture: (event: React.MouseEvent<HTMLDivElement>) => void;
|
|
16
|
-
handlePointerCancel: (event:
|
|
14
|
+
handlePointerCancel: (event: React.PointerEvent<HTMLDivElement>) => void;
|
|
17
15
|
handlePointerDown: (event: React.PointerEvent<HTMLDivElement>) => void;
|
|
18
16
|
handlePointerMove: (event: React.PointerEvent<HTMLDivElement>) => void;
|
|
19
17
|
handlePointerUp: (event: React.PointerEvent<HTMLDivElement>) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSnackbarSwipeDismiss.d.ts","sourceRoot":"","sources":["../../../../src/Prompt/Snackbar/useSnackbarSwipeDismiss.ts"],"names":[],"mappings":"AAeA
|
|
1
|
+
{"version":3,"file":"useSnackbarSwipeDismiss.d.ts","sourceRoot":"","sources":["../../../../src/Prompt/Snackbar/useSnackbarSwipeDismiss.ts"],"names":[],"mappings":"AAeA;;;;GAIG;AACH,QAAA,MAAM,uBAAuB,GAAI,sCAG9B;IACD,gBAAgB,EAAE,MAAM,IAAI,CAAC;IAC7B,4FAA4F;IAC5F,aAAa,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;CAC3C;;;gCA2GoC,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC;iCArB/B,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC;+BAvEpC,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC;+BAoBlC,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC;6BAepC,KAAK,CAAC,YAAY,CAAC,cAAc,CAAC;CA0EnE,CAAC;AAEF,eAAe,uBAAuB,CAAC"}
|
|
@@ -7,6 +7,7 @@ type TextElementProps = InputProps | TextAreaProps;
|
|
|
7
7
|
export type EventType = 'KeyDown' | 'Paste' | 'Cut' | 'Undo' | 'Redo' | 'Backspace' | 'Delete' | 'Initial';
|
|
8
8
|
interface WithDisplayFormatState {
|
|
9
9
|
value: string;
|
|
10
|
+
prevValue: string;
|
|
10
11
|
historyNavigator: HistoryNavigator;
|
|
11
12
|
prevDisplayPattern: string;
|
|
12
13
|
triggerType: EventType;
|
|
@@ -40,12 +41,13 @@ declare class WithDisplayFormat<T extends TextElementProps> extends React.Compon
|
|
|
40
41
|
value: string;
|
|
41
42
|
};
|
|
42
43
|
constructor(props: WithDisplayFormatProps);
|
|
43
|
-
static getDerivedStateFromProps({ displayPattern }: WithDisplayFormatProps, { prevDisplayPattern, value, historyNavigator }: WithDisplayFormatState): {
|
|
44
|
+
static getDerivedStateFromProps({ displayPattern, value: propValue }: WithDisplayFormatProps, { prevDisplayPattern, prevValue, value, historyNavigator, }: WithDisplayFormatState): {
|
|
45
|
+
triggerType?: null | undefined;
|
|
46
|
+
triggerEvent?: null | undefined;
|
|
47
|
+
pastedLength?: number | undefined;
|
|
44
48
|
prevDisplayPattern: string;
|
|
49
|
+
prevValue: string;
|
|
45
50
|
value: string;
|
|
46
|
-
triggerType: null;
|
|
47
|
-
triggerEvent: null;
|
|
48
|
-
pastedLength: number;
|
|
49
51
|
} | null;
|
|
50
52
|
getUserAction: (unformattedValue: string) => EventType | string;
|
|
51
53
|
resetEvent: () => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WithDisplayFormat.d.ts","sourceRoot":"","sources":["../../../src/WithDisplayFormat/WithDisplayFormat.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAS7C,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAE5D,KAAK,eAAe,GAAG,gBAAgB,GAAG,mBAAmB,CAAC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B5D;IAEF,UAAU,aAMR;IAEF,cAAc,GAAI,OAAO,KAAK,CAAC,aAAa,CAAC,eAAe,CAAC,4BAK3D;IAEF,eAAe,EAAE,KAAK,CAAC,oBAAoB,CAAC,eAAe,CAAC,CAuB1D;IAEF,aAAa,EAAE,KAAK,CAAC,qBAAqB,CAAC,eAAe,CAAC,CAQzD;IAEF,WAAW,EAAE,KAAK,CAAC,qBAAqB,CAAC,eAAe,CAAC,CAEvD;IAEF,YAAY,GAAI,QAAQ,SAAS,GAAG,MAAM,aAKxC;IAEF,cAAc,EAAE,KAAK,CAAC,kBAAkB,CAAC,eAAe,CAAC,CA0BvD;IAEF,YAAY,EAAE,KAAK,CAAC,iBAAiB,CAAC,eAAe,CAAC,CAEpD;IAEF,aAAa,EAAE,KAAK,CAAC,iBAAiB,CAAC,eAAe,CAAC,CAKrD;IAEF,YAAY,GAAI,kBAAkB,MAAM,EAAE,QAAQ,SAAS,YAuBzD;IAEF,uBAAuB,GAAI,QAAQ,MAAM,UAkBvC;IAEF,MAAM;CAqCP;AAED,eAAe,iBAAiB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@transferwise/components",
|
|
3
|
-
"version": "46.168.
|
|
3
|
+
"version": "46.168.1",
|
|
4
4
|
"description": "Neptune React components",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -39,33 +39,33 @@
|
|
|
39
39
|
"!**/*.tsbuildinfo"
|
|
40
40
|
],
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@babel/core": "^7.29.
|
|
42
|
+
"@babel/core": "^7.29.13",
|
|
43
43
|
"@babel/plugin-transform-runtime": "^7.29.7",
|
|
44
44
|
"@babel/preset-env": "^7.29.7",
|
|
45
45
|
"@babel/preset-react": "^7.29.7",
|
|
46
46
|
"@babel/preset-typescript": "^7.29.7",
|
|
47
|
-
"@formatjs/cli": "^6.
|
|
47
|
+
"@formatjs/cli": "^6.18.0",
|
|
48
48
|
"@rollup/plugin-babel": "^7.1.0",
|
|
49
49
|
"@rollup/plugin-json": "^6.1.0",
|
|
50
50
|
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
51
|
-
"@rollup/plugin-typescript": "^12.3.
|
|
51
|
+
"@rollup/plugin-typescript": "^12.3.1",
|
|
52
52
|
"@rollup/plugin-url": "^8.0.2",
|
|
53
|
-
"@storybook/addon-a11y": "^10.6.
|
|
54
|
-
"@storybook/addon-docs": "^10.6.
|
|
55
|
-
"@storybook/addon-mcp": "^
|
|
53
|
+
"@storybook/addon-a11y": "^10.6.6",
|
|
54
|
+
"@storybook/addon-docs": "^10.6.6",
|
|
55
|
+
"@storybook/addon-mcp": "^10.6.6",
|
|
56
56
|
"@storybook/addon-webpack5-compiler-babel": "^4.0.1",
|
|
57
|
-
"@storybook/react-webpack5": "^10.6.
|
|
57
|
+
"@storybook/react-webpack5": "^10.6.6",
|
|
58
58
|
"@testing-library/dom": "^10.4.2",
|
|
59
59
|
"@testing-library/jest-dom": "^6.9.1",
|
|
60
60
|
"@testing-library/react": "^16.3.3",
|
|
61
|
-
"@testing-library/user-event": "^14.6.
|
|
61
|
+
"@testing-library/user-event": "^14.6.8",
|
|
62
62
|
"@transferwise/icons": "^4.7.0",
|
|
63
63
|
"@transferwise/less-config": "3.2.0",
|
|
64
64
|
"@tsconfig/recommended": "^1.0.13",
|
|
65
65
|
"@types/babel__core": "^7.20.5",
|
|
66
66
|
"@types/commonmark": "^0.27.10",
|
|
67
67
|
"@types/jest": "^29.5.14",
|
|
68
|
-
"@types/lodash": "4.17.
|
|
68
|
+
"@types/lodash": "4.17.27",
|
|
69
69
|
"@types/lodash.clamp": "^4.0.9",
|
|
70
70
|
"@types/lodash.debounce": "^4.0.9",
|
|
71
71
|
"@types/react": "^18.3.31",
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
"@wise/wds-configs": "0.0.0",
|
|
81
81
|
"babel-plugin-formatjs": "^11.3.16",
|
|
82
82
|
"eslint": "^9.39.5",
|
|
83
|
-
"eslint-plugin-storybook": "^10.6.
|
|
83
|
+
"eslint-plugin-storybook": "^10.6.5",
|
|
84
84
|
"gulp": "^5.0.1",
|
|
85
85
|
"jest": "^29.7.0",
|
|
86
86
|
"jest-environment-jsdom": "^29.7.0",
|
|
@@ -89,9 +89,9 @@
|
|
|
89
89
|
"lodash.times": "^4.3.2",
|
|
90
90
|
"react-intl": "^7.1.14",
|
|
91
91
|
"react-live": "^4.1.8",
|
|
92
|
-
"rollup": "^4.
|
|
92
|
+
"rollup": "^4.67.5",
|
|
93
93
|
"rollup-preserve-directives": "^1.1.3",
|
|
94
|
-
"storybook": "^10.6.
|
|
94
|
+
"storybook": "^10.6.6",
|
|
95
95
|
"storybook-addon-tag-badges": "^3.1.0",
|
|
96
96
|
"storybook-addon-test-codegen": "^3.0.4"
|
|
97
97
|
},
|
|
@@ -105,7 +105,7 @@
|
|
|
105
105
|
"react-intl": ">=5.10.0 <11.0.0"
|
|
106
106
|
},
|
|
107
107
|
"dependencies": {
|
|
108
|
-
"@babel/runtime": "^7.29.
|
|
108
|
+
"@babel/runtime": "^7.29.13",
|
|
109
109
|
"@floating-ui/react": "^0.27.20",
|
|
110
110
|
"@headlessui/react": "^2.2.10",
|
|
111
111
|
"@react-aria/focus": "^3.22.1",
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
"@transferwise/neptune-validation": "^3.3.4",
|
|
116
116
|
"clsx": "^2.1.1",
|
|
117
117
|
"commonmark": "^0.31.2",
|
|
118
|
-
"core-js": "^3.
|
|
118
|
+
"core-js": "^3.51.0",
|
|
119
119
|
"motion": "^12.43.0",
|
|
120
120
|
"lodash.clamp": "^4.0.3",
|
|
121
121
|
"lodash.debounce": "^4.0.8",
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { useState } from 'react';
|
|
2
|
+
|
|
1
3
|
import {
|
|
2
4
|
createSandboxStory,
|
|
3
5
|
globalScope,
|
|
@@ -86,3 +88,40 @@ export const SecurityPin: Story = {
|
|
|
86
88
|
displayPattern: '*-*-*-*-*-*',
|
|
87
89
|
},
|
|
88
90
|
};
|
|
91
|
+
|
|
92
|
+
export const PropUpdates: Story = {
|
|
93
|
+
render: () => {
|
|
94
|
+
const [value, setValue] = useState('123456');
|
|
95
|
+
const [displayPattern, setDisplayPattern] = useState('**-**-**');
|
|
96
|
+
|
|
97
|
+
return (
|
|
98
|
+
<>
|
|
99
|
+
<Field id="prop-updates" label="Value and display pattern">
|
|
100
|
+
<InputWithDisplayFormat
|
|
101
|
+
id="prop-updates"
|
|
102
|
+
value={value}
|
|
103
|
+
displayPattern={displayPattern}
|
|
104
|
+
onChange={setValue}
|
|
105
|
+
/>
|
|
106
|
+
</Field>
|
|
107
|
+
<div>
|
|
108
|
+
<button type="button" onClick={() => setValue('654321')}>
|
|
109
|
+
Change value
|
|
110
|
+
</button>{' '}
|
|
111
|
+
<button type="button" onClick={() => setDisplayPattern('**/**/**')}>
|
|
112
|
+
Change pattern
|
|
113
|
+
</button>{' '}
|
|
114
|
+
<button
|
|
115
|
+
type="button"
|
|
116
|
+
onClick={() => {
|
|
117
|
+
setValue('987654');
|
|
118
|
+
setDisplayPattern('** ** **');
|
|
119
|
+
}}
|
|
120
|
+
>
|
|
121
|
+
Change both
|
|
122
|
+
</button>
|
|
123
|
+
</div>
|
|
124
|
+
</>
|
|
125
|
+
);
|
|
126
|
+
},
|
|
127
|
+
};
|
|
@@ -6,6 +6,7 @@ import { useRtlDiffI18n, withRTLDiff } from '../../../../.storybook/decorators/R
|
|
|
6
6
|
import Button from '../../../Button';
|
|
7
7
|
import { Input } from '../../Input/Input';
|
|
8
8
|
import { InputGroup } from '../InputGroup';
|
|
9
|
+
import { WithOverlaidAbsoluteElement } from '../../../../.storybook/components/WithOverlaidAbsoluteElement';
|
|
9
10
|
|
|
10
11
|
export default {
|
|
11
12
|
component: InputGroup,
|
|
@@ -88,3 +89,18 @@ export const RTLDiff: Story = {
|
|
|
88
89
|
},
|
|
89
90
|
}),
|
|
90
91
|
};
|
|
92
|
+
|
|
93
|
+
export const StackingContext: Story = {
|
|
94
|
+
render: () => (
|
|
95
|
+
<WithOverlaidAbsoluteElement>
|
|
96
|
+
<InputGroup
|
|
97
|
+
addonStart={{
|
|
98
|
+
content: <Search size={24} />,
|
|
99
|
+
initialContentWidth: 24,
|
|
100
|
+
}}
|
|
101
|
+
>
|
|
102
|
+
<Input placeholder="addonStart only" defaultValue="non-RTL value" />
|
|
103
|
+
</InputGroup>
|
|
104
|
+
</WithOverlaidAbsoluteElement>
|
|
105
|
+
),
|
|
106
|
+
};
|
|
@@ -3,6 +3,7 @@ import type { Meta, StoryObj } from '@storybook/react-webpack5';
|
|
|
3
3
|
import { useRtlDiffI18n, withRTLDiff } from '../../../../.storybook/decorators/RtlDiffDecorator';
|
|
4
4
|
import { Size } from '../../../common';
|
|
5
5
|
import { SearchInput } from '../SearchInput';
|
|
6
|
+
import { WithOverlaidAbsoluteElement } from '../../../../.storybook/components/WithOverlaidAbsoluteElement';
|
|
6
7
|
|
|
7
8
|
export default {
|
|
8
9
|
component: SearchInput,
|
|
@@ -38,3 +39,11 @@ export const RTLDiff: Story = {
|
|
|
38
39
|
},
|
|
39
40
|
}),
|
|
40
41
|
};
|
|
42
|
+
|
|
43
|
+
export const StackingContext: Story = {
|
|
44
|
+
render: () => (
|
|
45
|
+
<WithOverlaidAbsoluteElement>
|
|
46
|
+
<SearchInput placeholder="Search" defaultValue="Search value" />
|
|
47
|
+
</WithOverlaidAbsoluteElement>
|
|
48
|
+
),
|
|
49
|
+
};
|
|
@@ -24,6 +24,7 @@ import {
|
|
|
24
24
|
SelectInputOptionContent,
|
|
25
25
|
type SelectInputProps,
|
|
26
26
|
} from '..';
|
|
27
|
+
import { WithOverlaidAbsoluteElement } from '../../../../.storybook/components/WithOverlaidAbsoluteElement';
|
|
27
28
|
|
|
28
29
|
const meta = {
|
|
29
30
|
title: 'Forms/SelectInput/Tests',
|
|
@@ -1967,3 +1968,14 @@ export const FlagClipping: Story<TestCurrency> = {
|
|
|
1967
1968
|
),
|
|
1968
1969
|
args: flagClippingArgs,
|
|
1969
1970
|
};
|
|
1971
|
+
|
|
1972
|
+
export const StackingContext: Story<TestCurrency> = {
|
|
1973
|
+
render: (args) => (
|
|
1974
|
+
<WithOverlaidAbsoluteElement>
|
|
1975
|
+
<Field label="Overlaid element">
|
|
1976
|
+
<SelectInput {...args} />
|
|
1977
|
+
</Field>
|
|
1978
|
+
</WithOverlaidAbsoluteElement>
|
|
1979
|
+
),
|
|
1980
|
+
args: flagClippingArgs,
|
|
1981
|
+
};
|
|
@@ -6,6 +6,7 @@ import { lorem500 } from '../../test-utils';
|
|
|
6
6
|
import Field from '../../Field/Field';
|
|
7
7
|
import Body from '../../Body';
|
|
8
8
|
import MoneyInput from '../MoneyInput';
|
|
9
|
+
import { WithOverlaidAbsoluteElement } from '../../../.storybook/components/WithOverlaidAbsoluteElement';
|
|
9
10
|
|
|
10
11
|
const meta = {
|
|
11
12
|
title: 'Forms/MoneyInput/Tests',
|
|
@@ -243,3 +244,13 @@ export const DecimalsFormatParity: Story = {
|
|
|
243
244
|
},
|
|
244
245
|
},
|
|
245
246
|
};
|
|
247
|
+
|
|
248
|
+
export const StackingContext: Story = {
|
|
249
|
+
render: (args) => (
|
|
250
|
+
<WithOverlaidAbsoluteElement>
|
|
251
|
+
<Field label="Overlaid element">
|
|
252
|
+
<MoneyInput {...args} />
|
|
253
|
+
</Field>
|
|
254
|
+
</WithOverlaidAbsoluteElement>
|
|
255
|
+
),
|
|
256
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react-webpack5';
|
|
2
|
+
|
|
3
|
+
import { WithOverlaidAbsoluteElement } from '../../../.storybook/components/WithOverlaidAbsoluteElement';
|
|
4
|
+
import Field from '../../Field/Field';
|
|
5
|
+
import PhoneNumberInput from '..';
|
|
6
|
+
|
|
7
|
+
const meta = {
|
|
8
|
+
component: PhoneNumberInput,
|
|
9
|
+
title: 'Forms/PhoneNumberInput/Tests',
|
|
10
|
+
tags: ['!autodocs', '!manifest'],
|
|
11
|
+
args: {
|
|
12
|
+
onChange: () => {},
|
|
13
|
+
},
|
|
14
|
+
} satisfies Meta<typeof PhoneNumberInput>;
|
|
15
|
+
|
|
16
|
+
export default meta;
|
|
17
|
+
|
|
18
|
+
type Story = StoryObj<typeof meta>;
|
|
19
|
+
|
|
20
|
+
export const StackingContext: Story = {
|
|
21
|
+
render: (args) => {
|
|
22
|
+
return (
|
|
23
|
+
<WithOverlaidAbsoluteElement>
|
|
24
|
+
<Field label="Phone number">
|
|
25
|
+
<PhoneNumberInput {...args} />
|
|
26
|
+
</Field>
|
|
27
|
+
</WithOverlaidAbsoluteElement>
|
|
28
|
+
);
|
|
29
|
+
},
|
|
30
|
+
};
|