@transferwise/components 46.136.1 → 46.137.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (264) hide show
  1. package/build/common/hooks/useContainerSize.js +30 -0
  2. package/build/common/hooks/useContainerSize.js.map +1 -0
  3. package/build/common/hooks/useContainerSize.mjs +28 -0
  4. package/build/common/hooks/useContainerSize.mjs.map +1 -0
  5. package/build/common/hooks/useResizeObserver.js +3 -3
  6. package/build/common/hooks/useResizeObserver.js.map +1 -1
  7. package/build/common/hooks/useResizeObserver.mjs +3 -3
  8. package/build/common/hooks/useResizeObserver.mjs.map +1 -1
  9. package/build/criticalBanner/CriticalCommsBanner.js +3 -0
  10. package/build/criticalBanner/CriticalCommsBanner.js.map +1 -1
  11. package/build/criticalBanner/CriticalCommsBanner.mjs +3 -0
  12. package/build/criticalBanner/CriticalCommsBanner.mjs.map +1 -1
  13. package/build/field/Field.js +3 -2
  14. package/build/field/Field.js.map +1 -1
  15. package/build/field/Field.mjs +3 -2
  16. package/build/field/Field.mjs.map +1 -1
  17. package/build/i18n/cs.json +2 -0
  18. package/build/i18n/cs.json.js +2 -0
  19. package/build/i18n/cs.json.js.map +1 -1
  20. package/build/i18n/cs.json.mjs +2 -0
  21. package/build/i18n/cs.json.mjs.map +1 -1
  22. package/build/i18n/de.json +2 -0
  23. package/build/i18n/de.json.js +2 -0
  24. package/build/i18n/de.json.js.map +1 -1
  25. package/build/i18n/de.json.mjs +2 -0
  26. package/build/i18n/de.json.mjs.map +1 -1
  27. package/build/i18n/en.json +2 -0
  28. package/build/i18n/en.json.js +2 -0
  29. package/build/i18n/en.json.js.map +1 -1
  30. package/build/i18n/en.json.mjs +2 -0
  31. package/build/i18n/en.json.mjs.map +1 -1
  32. package/build/i18n/es.json +2 -0
  33. package/build/i18n/es.json.js +2 -0
  34. package/build/i18n/es.json.js.map +1 -1
  35. package/build/i18n/es.json.mjs +2 -0
  36. package/build/i18n/es.json.mjs.map +1 -1
  37. package/build/i18n/fr.json +2 -0
  38. package/build/i18n/fr.json.js +2 -0
  39. package/build/i18n/fr.json.js.map +1 -1
  40. package/build/i18n/fr.json.mjs +2 -0
  41. package/build/i18n/fr.json.mjs.map +1 -1
  42. package/build/i18n/hu.json +2 -0
  43. package/build/i18n/hu.json.js +2 -0
  44. package/build/i18n/hu.json.js.map +1 -1
  45. package/build/i18n/hu.json.mjs +2 -0
  46. package/build/i18n/hu.json.mjs.map +1 -1
  47. package/build/i18n/id.json +2 -0
  48. package/build/i18n/id.json.js +2 -0
  49. package/build/i18n/id.json.js.map +1 -1
  50. package/build/i18n/id.json.mjs +2 -0
  51. package/build/i18n/id.json.mjs.map +1 -1
  52. package/build/i18n/it.json +2 -0
  53. package/build/i18n/it.json.js +2 -0
  54. package/build/i18n/it.json.js.map +1 -1
  55. package/build/i18n/it.json.mjs +2 -0
  56. package/build/i18n/it.json.mjs.map +1 -1
  57. package/build/i18n/ja.json +2 -0
  58. package/build/i18n/ja.json.js +2 -0
  59. package/build/i18n/ja.json.js.map +1 -1
  60. package/build/i18n/ja.json.mjs +2 -0
  61. package/build/i18n/ja.json.mjs.map +1 -1
  62. package/build/i18n/nl.json +2 -0
  63. package/build/i18n/nl.json.js +2 -0
  64. package/build/i18n/nl.json.js.map +1 -1
  65. package/build/i18n/nl.json.mjs +2 -0
  66. package/build/i18n/nl.json.mjs.map +1 -1
  67. package/build/i18n/pl.json +2 -0
  68. package/build/i18n/pl.json.js +2 -0
  69. package/build/i18n/pl.json.js.map +1 -1
  70. package/build/i18n/pl.json.mjs +2 -0
  71. package/build/i18n/pl.json.mjs.map +1 -1
  72. package/build/i18n/pt.json +2 -0
  73. package/build/i18n/pt.json.js +2 -0
  74. package/build/i18n/pt.json.js.map +1 -1
  75. package/build/i18n/pt.json.mjs +2 -0
  76. package/build/i18n/pt.json.mjs.map +1 -1
  77. package/build/i18n/ro.json +2 -0
  78. package/build/i18n/ro.json.js +2 -0
  79. package/build/i18n/ro.json.js.map +1 -1
  80. package/build/i18n/ro.json.mjs +2 -0
  81. package/build/i18n/ro.json.mjs.map +1 -1
  82. package/build/i18n/ru.json +2 -0
  83. package/build/i18n/ru.json.js +2 -0
  84. package/build/i18n/ru.json.js.map +1 -1
  85. package/build/i18n/ru.json.mjs +2 -0
  86. package/build/i18n/ru.json.mjs.map +1 -1
  87. package/build/i18n/th.json +2 -0
  88. package/build/i18n/th.json.js +2 -0
  89. package/build/i18n/th.json.js.map +1 -1
  90. package/build/i18n/th.json.mjs +2 -0
  91. package/build/i18n/th.json.mjs.map +1 -1
  92. package/build/i18n/tr.json +2 -0
  93. package/build/i18n/tr.json.js +2 -0
  94. package/build/i18n/tr.json.js.map +1 -1
  95. package/build/i18n/tr.json.mjs +2 -0
  96. package/build/i18n/tr.json.mjs.map +1 -1
  97. package/build/i18n/zh-CN.json +2 -0
  98. package/build/i18n/zh-CN.json.js +2 -0
  99. package/build/i18n/zh-CN.json.js.map +1 -1
  100. package/build/i18n/zh-CN.json.mjs +2 -0
  101. package/build/i18n/zh-CN.json.mjs.map +1 -1
  102. package/build/i18n/zh-HK.json +2 -0
  103. package/build/i18n/zh-HK.json.js +2 -0
  104. package/build/i18n/zh-HK.json.js.map +1 -1
  105. package/build/i18n/zh-HK.json.mjs +2 -0
  106. package/build/i18n/zh-HK.json.mjs.map +1 -1
  107. package/build/index.js +2 -0
  108. package/build/index.js.map +1 -1
  109. package/build/index.mjs +1 -0
  110. package/build/index.mjs.map +1 -1
  111. package/build/listItem/Prompt/ListItemPrompt.js +3 -2
  112. package/build/listItem/Prompt/ListItemPrompt.js.map +1 -1
  113. package/build/listItem/Prompt/ListItemPrompt.mjs +3 -2
  114. package/build/listItem/Prompt/ListItemPrompt.mjs.map +1 -1
  115. package/build/logo/Logo.js +77 -25
  116. package/build/logo/Logo.js.map +1 -1
  117. package/build/logo/Logo.mjs +79 -27
  118. package/build/logo/Logo.mjs.map +1 -1
  119. package/build/logo/logo-assets.js +68 -97
  120. package/build/logo/logo-assets.js.map +1 -1
  121. package/build/logo/logo-assets.mjs +62 -90
  122. package/build/logo/logo-assets.mjs.map +1 -1
  123. package/build/main.css +225 -59
  124. package/build/prompt/ActionPrompt/ActionPrompt.js +8 -40
  125. package/build/prompt/ActionPrompt/ActionPrompt.js.map +1 -1
  126. package/build/prompt/ActionPrompt/ActionPrompt.mjs +8 -40
  127. package/build/prompt/ActionPrompt/ActionPrompt.mjs.map +1 -1
  128. package/build/prompt/CriticalBanner/CriticalBanner.js +143 -0
  129. package/build/prompt/CriticalBanner/CriticalBanner.js.map +1 -0
  130. package/build/prompt/CriticalBanner/CriticalBanner.mjs +141 -0
  131. package/build/prompt/CriticalBanner/CriticalBanner.mjs.map +1 -0
  132. package/build/prompt/CriticalBanner/helpers.js +29 -0
  133. package/build/prompt/CriticalBanner/helpers.js.map +1 -0
  134. package/build/prompt/CriticalBanner/helpers.mjs +26 -0
  135. package/build/prompt/CriticalBanner/helpers.mjs.map +1 -0
  136. package/build/prompt/InfoPrompt/InfoPrompt.js +3 -2
  137. package/build/prompt/InfoPrompt/InfoPrompt.js.map +1 -1
  138. package/build/prompt/InfoPrompt/InfoPrompt.mjs +3 -2
  139. package/build/prompt/InfoPrompt/InfoPrompt.mjs.map +1 -1
  140. package/build/prompt/PrimitivePrompt/PrimitivePrompt.js +11 -4
  141. package/build/prompt/PrimitivePrompt/PrimitivePrompt.js.map +1 -1
  142. package/build/prompt/PrimitivePrompt/PrimitivePrompt.mjs +11 -4
  143. package/build/prompt/PrimitivePrompt/PrimitivePrompt.mjs.map +1 -1
  144. package/build/prompt/common/Expander/Expander.js +35 -0
  145. package/build/prompt/common/Expander/Expander.js.map +1 -0
  146. package/build/prompt/common/Expander/Expander.messages.js +17 -0
  147. package/build/prompt/common/Expander/Expander.messages.js.map +1 -0
  148. package/build/prompt/common/Expander/Expander.messages.mjs +13 -0
  149. package/build/prompt/common/Expander/Expander.messages.mjs.map +1 -0
  150. package/build/prompt/common/Expander/Expander.mjs +33 -0
  151. package/build/prompt/common/Expander/Expander.mjs.map +1 -0
  152. package/build/prompt/helpers/promptMedia.js +52 -0
  153. package/build/prompt/helpers/promptMedia.js.map +1 -0
  154. package/build/prompt/helpers/promptMedia.mjs +50 -0
  155. package/build/prompt/helpers/promptMedia.mjs.map +1 -0
  156. package/build/styles/css/neptune.css +0 -1
  157. package/build/styles/logo/Logo.css +3 -23
  158. package/build/styles/main.css +225 -59
  159. package/build/styles/prompt/CriticalBanner/CriticalBanner.css +134 -0
  160. package/build/styles/prompt/CriticalBanner/CriticalBanner.vars.css +0 -0
  161. package/build/styles/prompt/InfoPrompt/InfoPrompt.css +24 -0
  162. package/build/styles/prompt/common/Expander/Expander.css +8 -0
  163. package/build/styles/styles/less/neptune.css +0 -1
  164. package/build/typeahead/Typeahead.js +3 -2
  165. package/build/typeahead/Typeahead.js.map +1 -1
  166. package/build/typeahead/Typeahead.mjs +3 -2
  167. package/build/typeahead/Typeahead.mjs.map +1 -1
  168. package/build/types/common/hooks/useContainerSize.d.ts +14 -0
  169. package/build/types/common/hooks/useContainerSize.d.ts.map +1 -0
  170. package/build/types/common/hooks/useResizeObserver.d.ts +1 -1
  171. package/build/types/common/hooks/useResizeObserver.d.ts.map +1 -1
  172. package/build/types/criticalBanner/CriticalCommsBanner.d.ts +3 -0
  173. package/build/types/criticalBanner/CriticalCommsBanner.d.ts.map +1 -1
  174. package/build/types/index.d.ts +2 -2
  175. package/build/types/index.d.ts.map +1 -1
  176. package/build/types/logo/Logo.d.ts +33 -1
  177. package/build/types/logo/Logo.d.ts.map +1 -1
  178. package/build/types/logo/logo-assets.d.ts +33 -9
  179. package/build/types/logo/logo-assets.d.ts.map +1 -1
  180. package/build/types/prompt/ActionPrompt/ActionPrompt.d.ts +2 -11
  181. package/build/types/prompt/ActionPrompt/ActionPrompt.d.ts.map +1 -1
  182. package/build/types/prompt/CriticalBanner/CriticalBanner.d.ts +39 -0
  183. package/build/types/prompt/CriticalBanner/CriticalBanner.d.ts.map +1 -0
  184. package/build/types/prompt/CriticalBanner/helpers.d.ts +18 -0
  185. package/build/types/prompt/CriticalBanner/helpers.d.ts.map +1 -0
  186. package/build/types/prompt/CriticalBanner/index.d.ts +3 -0
  187. package/build/types/prompt/CriticalBanner/index.d.ts.map +1 -0
  188. package/build/types/prompt/InfoPrompt/InfoPrompt.d.ts.map +1 -1
  189. package/build/types/prompt/PrimitivePrompt/PrimitivePrompt.d.ts +35 -3
  190. package/build/types/prompt/PrimitivePrompt/PrimitivePrompt.d.ts.map +1 -1
  191. package/build/types/prompt/common/Expander/Expander.d.ts +20 -0
  192. package/build/types/prompt/common/Expander/Expander.d.ts.map +1 -0
  193. package/build/types/prompt/common/Expander/Expander.messages.d.ts +14 -0
  194. package/build/types/prompt/common/Expander/Expander.messages.d.ts.map +1 -0
  195. package/build/types/prompt/helpers/promptMedia.d.ts +22 -0
  196. package/build/types/prompt/helpers/promptMedia.d.ts.map +1 -0
  197. package/build/types/prompt/index.d.ts +2 -0
  198. package/build/types/prompt/index.d.ts.map +1 -1
  199. package/build/types/test-utils/index.d.ts +4 -0
  200. package/build/types/test-utils/index.d.ts.map +1 -1
  201. package/package.json +22 -18
  202. package/src/alert/Alert.story.tsx +30 -1
  203. package/src/avatarWrapper/AvatarWrapper.story.tsx +1 -1
  204. package/src/button/_stories/Button.story.tsx +11 -0
  205. package/src/common/hooks/useContainerSize.test.tsx +125 -0
  206. package/src/common/hooks/useContainerSize.ts +32 -0
  207. package/src/common/hooks/useResizeObserver.ts +3 -2
  208. package/src/criticalBanner/CriticalCommsBanner.story.tsx +4 -0
  209. package/src/criticalBanner/CriticalCommsBanner.test.story.tsx +1 -1
  210. package/src/criticalBanner/CriticalCommsBanner.tsx +3 -0
  211. package/src/i18n/cs.json +2 -0
  212. package/src/i18n/de.json +2 -0
  213. package/src/i18n/en.json +2 -0
  214. package/src/i18n/es.json +2 -0
  215. package/src/i18n/fr.json +2 -0
  216. package/src/i18n/hu.json +2 -0
  217. package/src/i18n/id.json +2 -0
  218. package/src/i18n/it.json +2 -0
  219. package/src/i18n/ja.json +2 -0
  220. package/src/i18n/nl.json +2 -0
  221. package/src/i18n/pl.json +2 -0
  222. package/src/i18n/pt.json +2 -0
  223. package/src/i18n/ro.json +2 -0
  224. package/src/i18n/ru.json +2 -0
  225. package/src/i18n/th.json +2 -0
  226. package/src/i18n/tr.json +2 -0
  227. package/src/i18n/zh-CN.json +2 -0
  228. package/src/i18n/zh-HK.json +2 -0
  229. package/src/index.ts +2 -2
  230. package/src/logo/Logo.css +3 -23
  231. package/src/logo/Logo.less +3 -29
  232. package/src/logo/Logo.story.tsx +117 -89
  233. package/src/logo/Logo.test.story.tsx +15 -24
  234. package/src/logo/Logo.tsx +90 -28
  235. package/src/logo/logo-assets.tsx +36 -92
  236. package/src/main.css +225 -59
  237. package/src/main.less +3 -1
  238. package/src/prompt/ActionPrompt/ActionPrompt.tsx +9 -62
  239. package/src/prompt/CriticalBanner/CriticalBanner.accessibility.docs.mdx +113 -0
  240. package/src/prompt/CriticalBanner/CriticalBanner.css +134 -0
  241. package/src/prompt/CriticalBanner/CriticalBanner.less +155 -0
  242. package/src/prompt/CriticalBanner/CriticalBanner.story.tsx +635 -0
  243. package/src/prompt/CriticalBanner/CriticalBanner.test.story.tsx +422 -0
  244. package/src/prompt/CriticalBanner/CriticalBanner.tsx +179 -0
  245. package/src/prompt/CriticalBanner/CriticalBanner.vars.css +0 -0
  246. package/src/prompt/CriticalBanner/CriticalBanner.vars.less +6 -0
  247. package/src/prompt/CriticalBanner/helpers.ts +39 -0
  248. package/src/prompt/CriticalBanner/index.ts +2 -0
  249. package/src/prompt/InfoPrompt/InfoPrompt.css +24 -0
  250. package/src/prompt/InfoPrompt/InfoPrompt.less +23 -0
  251. package/src/prompt/InfoPrompt/InfoPrompt.tsx +5 -1
  252. package/src/prompt/PrimitivePrompt/PrimitivePrompt.tsx +56 -40
  253. package/src/prompt/common/Expander/Expander.css +8 -0
  254. package/src/prompt/common/Expander/Expander.less +9 -0
  255. package/src/prompt/common/Expander/Expander.messages.ts +14 -0
  256. package/src/prompt/common/Expander/Expander.test.tsx +167 -0
  257. package/src/prompt/common/Expander/Expander.tsx +83 -0
  258. package/src/prompt/helpers/promptMedia.tsx +79 -0
  259. package/src/prompt/index.ts +4 -0
  260. package/src/radio/Radio.story.tsx +1 -1
  261. package/src/section/Section.story.tsx +2 -8
  262. package/src/sentimentSurface/SentimentSurface.story.tsx +43 -17
  263. package/src/statusIcon/StatusIcon.test.tsx +0 -2
  264. package/src/styles/less/neptune.css +0 -1
@@ -0,0 +1,30 @@
1
+ 'use strict';
2
+
3
+ var React = require('react');
4
+ var useResizeObserver = require('./useResizeObserver.js');
5
+
6
+ /**
7
+ * Hook that returns a ref and a boolean indicating if the container
8
+ * has a width >= the specified breakpoint.
9
+ *
10
+ * Useful for synchronizing React state with CSS container queries.
11
+ *
12
+ * Uses content-box measurements to match CSS container query behavior
13
+ * (excludes padding and border).
14
+ *
15
+ * @param breakpoint - Minimum width in pixels
16
+ * @returns [ref, isAboveBreakpoint] tuple
17
+ */
18
+ function useContainerSize(breakpoint) {
19
+ const ref = React.useRef(null);
20
+ const [isAboveBreakpoint, setIsAboveBreakpoint] = React.useState(false);
21
+ useResizeObserver.useResizeObserver(ref, entry => {
22
+ // Use contentRect.width to match CSS container query box model (content-box)
23
+ const inlineSize = entry.contentRect.width;
24
+ setIsAboveBreakpoint(inlineSize >= breakpoint);
25
+ }, 'content-box');
26
+ return [ref, isAboveBreakpoint];
27
+ }
28
+
29
+ exports.useContainerSize = useContainerSize;
30
+ //# sourceMappingURL=useContainerSize.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useContainerSize.js","sources":["../../../src/common/hooks/useContainerSize.ts"],"sourcesContent":["import { useRef, useState } from 'react';\n\nimport { useResizeObserver } from './useResizeObserver';\n\n/**\n * Hook that returns a ref and a boolean indicating if the container\n * has a width >= the specified breakpoint.\n *\n * Useful for synchronizing React state with CSS container queries.\n *\n * Uses content-box measurements to match CSS container query behavior\n * (excludes padding and border).\n *\n * @param breakpoint - Minimum width in pixels\n * @returns [ref, isAboveBreakpoint] tuple\n */\nexport function useContainerSize(breakpoint: number): [React.RefObject<HTMLDivElement>, boolean] {\n const ref = useRef<HTMLDivElement>(null);\n const [isAboveBreakpoint, setIsAboveBreakpoint] = useState(false);\n\n useResizeObserver(\n ref,\n (entry) => {\n // Use contentRect.width to match CSS container query box model (content-box)\n const inlineSize = entry.contentRect.width;\n setIsAboveBreakpoint(inlineSize >= breakpoint);\n },\n 'content-box',\n );\n\n return [ref, isAboveBreakpoint];\n}\n"],"names":["useContainerSize","breakpoint","ref","useRef","isAboveBreakpoint","setIsAboveBreakpoint","useState","useResizeObserver","entry","inlineSize","contentRect","width"],"mappings":";;;;;AAIA;;;;;;;;;;;AAWG;AACG,SAAUA,gBAAgBA,CAACC,UAAkB,EAAA;AACjD,EAAA,MAAMC,GAAG,GAAGC,YAAM,CAAiB,IAAI,CAAC;EACxC,MAAM,CAACC,iBAAiB,EAAEC,oBAAoB,CAAC,GAAGC,cAAQ,CAAC,KAAK,CAAC;AAEjEC,EAAAA,mCAAiB,CACfL,GAAG,EACFM,KAAK,IAAI;AACR;AACA,IAAA,MAAMC,UAAU,GAAGD,KAAK,CAACE,WAAW,CAACC,KAAK;AAC1CN,IAAAA,oBAAoB,CAACI,UAAU,IAAIR,UAAU,CAAC;EAChD,CAAC,EACD,aAAa,CACd;AAED,EAAA,OAAO,CAACC,GAAG,EAAEE,iBAAiB,CAAC;AACjC;;;;"}
@@ -0,0 +1,28 @@
1
+ import { useRef, useState } from 'react';
2
+ import { useResizeObserver } from './useResizeObserver.mjs';
3
+
4
+ /**
5
+ * Hook that returns a ref and a boolean indicating if the container
6
+ * has a width >= the specified breakpoint.
7
+ *
8
+ * Useful for synchronizing React state with CSS container queries.
9
+ *
10
+ * Uses content-box measurements to match CSS container query behavior
11
+ * (excludes padding and border).
12
+ *
13
+ * @param breakpoint - Minimum width in pixels
14
+ * @returns [ref, isAboveBreakpoint] tuple
15
+ */
16
+ function useContainerSize(breakpoint) {
17
+ const ref = useRef(null);
18
+ const [isAboveBreakpoint, setIsAboveBreakpoint] = useState(false);
19
+ useResizeObserver(ref, entry => {
20
+ // Use contentRect.width to match CSS container query box model (content-box)
21
+ const inlineSize = entry.contentRect.width;
22
+ setIsAboveBreakpoint(inlineSize >= breakpoint);
23
+ }, 'content-box');
24
+ return [ref, isAboveBreakpoint];
25
+ }
26
+
27
+ export { useContainerSize };
28
+ //# sourceMappingURL=useContainerSize.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useContainerSize.mjs","sources":["../../../src/common/hooks/useContainerSize.ts"],"sourcesContent":["import { useRef, useState } from 'react';\n\nimport { useResizeObserver } from './useResizeObserver';\n\n/**\n * Hook that returns a ref and a boolean indicating if the container\n * has a width >= the specified breakpoint.\n *\n * Useful for synchronizing React state with CSS container queries.\n *\n * Uses content-box measurements to match CSS container query behavior\n * (excludes padding and border).\n *\n * @param breakpoint - Minimum width in pixels\n * @returns [ref, isAboveBreakpoint] tuple\n */\nexport function useContainerSize(breakpoint: number): [React.RefObject<HTMLDivElement>, boolean] {\n const ref = useRef<HTMLDivElement>(null);\n const [isAboveBreakpoint, setIsAboveBreakpoint] = useState(false);\n\n useResizeObserver(\n ref,\n (entry) => {\n // Use contentRect.width to match CSS container query box model (content-box)\n const inlineSize = entry.contentRect.width;\n setIsAboveBreakpoint(inlineSize >= breakpoint);\n },\n 'content-box',\n );\n\n return [ref, isAboveBreakpoint];\n}\n"],"names":["useContainerSize","breakpoint","ref","useRef","isAboveBreakpoint","setIsAboveBreakpoint","useState","useResizeObserver","entry","inlineSize","contentRect","width"],"mappings":";;;AAIA;;;;;;;;;;;AAWG;AACG,SAAUA,gBAAgBA,CAACC,UAAkB,EAAA;AACjD,EAAA,MAAMC,GAAG,GAAGC,MAAM,CAAiB,IAAI,CAAC;EACxC,MAAM,CAACC,iBAAiB,EAAEC,oBAAoB,CAAC,GAAGC,QAAQ,CAAC,KAAK,CAAC;AAEjEC,EAAAA,iBAAiB,CACfL,GAAG,EACFM,KAAK,IAAI;AACR;AACA,IAAA,MAAMC,UAAU,GAAGD,KAAK,CAACE,WAAW,CAACC,KAAK;AAC1CN,IAAAA,oBAAoB,CAACI,UAAU,IAAIR,UAAU,CAAC;EAChD,CAAC,EACD,aAAa,CACd;AAED,EAAA,OAAO,CAACC,GAAG,EAAEE,iBAAiB,CAAC;AACjC;;;;"}
@@ -3,7 +3,7 @@
3
3
  var React = require('react');
4
4
  var useEffectEvent = require('./useEffectEvent.js');
5
5
 
6
- function useResizeObserver(ref, callback) {
6
+ function useResizeObserver(ref, callback, box = 'border-box') {
7
7
  const handleCallback = useEffectEvent.useEffectEvent(callback);
8
8
  React.useEffect(() => {
9
9
  if (ref.current != null) {
@@ -11,14 +11,14 @@ function useResizeObserver(ref, callback) {
11
11
  handleCallback(entry);
12
12
  });
13
13
  resizeObserver.observe(ref.current, {
14
- box: 'border-box'
14
+ box
15
15
  });
16
16
  return () => {
17
17
  resizeObserver.disconnect();
18
18
  };
19
19
  }
20
20
  return () => {};
21
- }, [handleCallback, ref]);
21
+ }, [handleCallback, ref, box]);
22
22
  }
23
23
 
24
24
  exports.useResizeObserver = useResizeObserver;
@@ -1 +1 @@
1
- {"version":3,"file":"useResizeObserver.js","sources":["../../../src/common/hooks/useResizeObserver.ts"],"sourcesContent":["import { useEffect } from 'react';\n\nimport { useEffectEvent } from './useEffectEvent';\n\nexport function useResizeObserver(\n ref: React.MutableRefObject<Element | null>,\n callback: (entry: ResizeObserverEntry) => void,\n) {\n const handleCallback = useEffectEvent(callback);\n useEffect(() => {\n if (ref.current != null) {\n const resizeObserver = new ResizeObserver(([entry]) => {\n handleCallback(entry);\n });\n resizeObserver.observe(ref.current, { box: 'border-box' });\n return () => {\n resizeObserver.disconnect();\n };\n }\n return () => {};\n }, [handleCallback, ref]);\n}\n"],"names":["useResizeObserver","ref","callback","handleCallback","useEffectEvent","useEffect","current","resizeObserver","ResizeObserver","entry","observe","box","disconnect"],"mappings":";;;;;AAIM,SAAUA,iBAAiBA,CAC/BC,GAA2C,EAC3CC,QAA8C,EAAA;AAE9C,EAAA,MAAMC,cAAc,GAAGC,6BAAc,CAACF,QAAQ,CAAC;AAC/CG,EAAAA,eAAS,CAAC,MAAK;AACb,IAAA,IAAIJ,GAAG,CAACK,OAAO,IAAI,IAAI,EAAE;MACvB,MAAMC,cAAc,GAAG,IAAIC,cAAc,CAAC,CAAC,CAACC,KAAK,CAAC,KAAI;QACpDN,cAAc,CAACM,KAAK,CAAC;AACvB,MAAA,CAAC,CAAC;AACFF,MAAAA,cAAc,CAACG,OAAO,CAACT,GAAG,CAACK,OAAO,EAAE;AAAEK,QAAAA,GAAG,EAAE;AAAY,OAAE,CAAC;AAC1D,MAAA,OAAO,MAAK;QACVJ,cAAc,CAACK,UAAU,EAAE;MAC7B,CAAC;AACH,IAAA;IACA,OAAO,MAAK,CAAE,CAAC;AACjB,EAAA,CAAC,EAAE,CAACT,cAAc,EAAEF,GAAG,CAAC,CAAC;AAC3B;;;;"}
1
+ {"version":3,"file":"useResizeObserver.js","sources":["../../../src/common/hooks/useResizeObserver.ts"],"sourcesContent":["import { useEffect } from 'react';\n\nimport { useEffectEvent } from './useEffectEvent';\n\nexport function useResizeObserver(\n ref: React.MutableRefObject<Element | null>,\n callback: (entry: ResizeObserverEntry) => void,\n box: ResizeObserverBoxOptions = 'border-box',\n) {\n const handleCallback = useEffectEvent(callback);\n useEffect(() => {\n if (ref.current != null) {\n const resizeObserver = new ResizeObserver(([entry]) => {\n handleCallback(entry);\n });\n resizeObserver.observe(ref.current, { box });\n return () => {\n resizeObserver.disconnect();\n };\n }\n return () => {};\n }, [handleCallback, ref, box]);\n}\n"],"names":["useResizeObserver","ref","callback","box","handleCallback","useEffectEvent","useEffect","current","resizeObserver","ResizeObserver","entry","observe","disconnect"],"mappings":";;;;;AAIM,SAAUA,iBAAiBA,CAC/BC,GAA2C,EAC3CC,QAA8C,EAC9CC,MAAgC,YAAY,EAAA;AAE5C,EAAA,MAAMC,cAAc,GAAGC,6BAAc,CAACH,QAAQ,CAAC;AAC/CI,EAAAA,eAAS,CAAC,MAAK;AACb,IAAA,IAAIL,GAAG,CAACM,OAAO,IAAI,IAAI,EAAE;MACvB,MAAMC,cAAc,GAAG,IAAIC,cAAc,CAAC,CAAC,CAACC,KAAK,CAAC,KAAI;QACpDN,cAAc,CAACM,KAAK,CAAC;AACvB,MAAA,CAAC,CAAC;AACFF,MAAAA,cAAc,CAACG,OAAO,CAACV,GAAG,CAACM,OAAO,EAAE;AAAEJ,QAAAA;AAAG,OAAE,CAAC;AAC5C,MAAA,OAAO,MAAK;QACVK,cAAc,CAACI,UAAU,EAAE;MAC7B,CAAC;AACH,IAAA;IACA,OAAO,MAAK,CAAE,CAAC;EACjB,CAAC,EAAE,CAACR,cAAc,EAAEH,GAAG,EAAEE,GAAG,CAAC,CAAC;AAChC;;;;"}
@@ -1,7 +1,7 @@
1
1
  import { useEffect } from 'react';
2
2
  import { useEffectEvent } from './useEffectEvent.mjs';
3
3
 
4
- function useResizeObserver(ref, callback) {
4
+ function useResizeObserver(ref, callback, box = 'border-box') {
5
5
  const handleCallback = useEffectEvent(callback);
6
6
  useEffect(() => {
7
7
  if (ref.current != null) {
@@ -9,14 +9,14 @@ function useResizeObserver(ref, callback) {
9
9
  handleCallback(entry);
10
10
  });
11
11
  resizeObserver.observe(ref.current, {
12
- box: 'border-box'
12
+ box
13
13
  });
14
14
  return () => {
15
15
  resizeObserver.disconnect();
16
16
  };
17
17
  }
18
18
  return () => {};
19
- }, [handleCallback, ref]);
19
+ }, [handleCallback, ref, box]);
20
20
  }
21
21
 
22
22
  export { useResizeObserver };
@@ -1 +1 @@
1
- {"version":3,"file":"useResizeObserver.mjs","sources":["../../../src/common/hooks/useResizeObserver.ts"],"sourcesContent":["import { useEffect } from 'react';\n\nimport { useEffectEvent } from './useEffectEvent';\n\nexport function useResizeObserver(\n ref: React.MutableRefObject<Element | null>,\n callback: (entry: ResizeObserverEntry) => void,\n) {\n const handleCallback = useEffectEvent(callback);\n useEffect(() => {\n if (ref.current != null) {\n const resizeObserver = new ResizeObserver(([entry]) => {\n handleCallback(entry);\n });\n resizeObserver.observe(ref.current, { box: 'border-box' });\n return () => {\n resizeObserver.disconnect();\n };\n }\n return () => {};\n }, [handleCallback, ref]);\n}\n"],"names":["useResizeObserver","ref","callback","handleCallback","useEffectEvent","useEffect","current","resizeObserver","ResizeObserver","entry","observe","box","disconnect"],"mappings":";;;AAIM,SAAUA,iBAAiBA,CAC/BC,GAA2C,EAC3CC,QAA8C,EAAA;AAE9C,EAAA,MAAMC,cAAc,GAAGC,cAAc,CAACF,QAAQ,CAAC;AAC/CG,EAAAA,SAAS,CAAC,MAAK;AACb,IAAA,IAAIJ,GAAG,CAACK,OAAO,IAAI,IAAI,EAAE;MACvB,MAAMC,cAAc,GAAG,IAAIC,cAAc,CAAC,CAAC,CAACC,KAAK,CAAC,KAAI;QACpDN,cAAc,CAACM,KAAK,CAAC;AACvB,MAAA,CAAC,CAAC;AACFF,MAAAA,cAAc,CAACG,OAAO,CAACT,GAAG,CAACK,OAAO,EAAE;AAAEK,QAAAA,GAAG,EAAE;AAAY,OAAE,CAAC;AAC1D,MAAA,OAAO,MAAK;QACVJ,cAAc,CAACK,UAAU,EAAE;MAC7B,CAAC;AACH,IAAA;IACA,OAAO,MAAK,CAAE,CAAC;AACjB,EAAA,CAAC,EAAE,CAACT,cAAc,EAAEF,GAAG,CAAC,CAAC;AAC3B;;;;"}
1
+ {"version":3,"file":"useResizeObserver.mjs","sources":["../../../src/common/hooks/useResizeObserver.ts"],"sourcesContent":["import { useEffect } from 'react';\n\nimport { useEffectEvent } from './useEffectEvent';\n\nexport function useResizeObserver(\n ref: React.MutableRefObject<Element | null>,\n callback: (entry: ResizeObserverEntry) => void,\n box: ResizeObserverBoxOptions = 'border-box',\n) {\n const handleCallback = useEffectEvent(callback);\n useEffect(() => {\n if (ref.current != null) {\n const resizeObserver = new ResizeObserver(([entry]) => {\n handleCallback(entry);\n });\n resizeObserver.observe(ref.current, { box });\n return () => {\n resizeObserver.disconnect();\n };\n }\n return () => {};\n }, [handleCallback, ref, box]);\n}\n"],"names":["useResizeObserver","ref","callback","box","handleCallback","useEffectEvent","useEffect","current","resizeObserver","ResizeObserver","entry","observe","disconnect"],"mappings":";;;AAIM,SAAUA,iBAAiBA,CAC/BC,GAA2C,EAC3CC,QAA8C,EAC9CC,MAAgC,YAAY,EAAA;AAE5C,EAAA,MAAMC,cAAc,GAAGC,cAAc,CAACH,QAAQ,CAAC;AAC/CI,EAAAA,SAAS,CAAC,MAAK;AACb,IAAA,IAAIL,GAAG,CAACM,OAAO,IAAI,IAAI,EAAE;MACvB,MAAMC,cAAc,GAAG,IAAIC,cAAc,CAAC,CAAC,CAACC,KAAK,CAAC,KAAI;QACpDN,cAAc,CAACM,KAAK,CAAC;AACvB,MAAA,CAAC,CAAC;AACFF,MAAAA,cAAc,CAACG,OAAO,CAACV,GAAG,CAACM,OAAO,EAAE;AAAEJ,QAAAA;AAAG,OAAE,CAAC;AAC5C,MAAA,OAAO,MAAK;QACVK,cAAc,CAACI,UAAU,EAAE;MAC7B,CAAC;AACH,IAAA;IACA,OAAO,MAAK,CAAE,CAAC;EACjB,CAAC,EAAE,CAACR,cAAc,EAAEH,GAAG,EAAEE,GAAG,CAAC,CAAC;AAChC;;;;"}
@@ -68,6 +68,9 @@ const iconBySentiment = {
68
68
  })
69
69
  })
70
70
  };
71
+ /**
72
+ * @deprecated `CriticalCommsBanner` component is deprecated and now replaced by the `CriticalBanner` component.
73
+ */
71
74
  function CriticalCommsBanner({
72
75
  title,
73
76
  subtitle,
@@ -1 +1 @@
1
- {"version":3,"file":"CriticalCommsBanner.js","sources":["../../src/criticalBanner/CriticalCommsBanner.tsx"],"sourcesContent":["import { Alert as AlertIcon, ClockBorderless as ClockIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { PropsWithChildren } from 'react';\n\nimport Alert from '../alert';\nimport { Sentiment } from '../common';\nimport Circle, { CircleProps } from '../common/circle';\nimport SentimentSurface from '../sentimentSurface';\n\nexport type CriticalCommsBannerSentiment =\n | `${Sentiment.WARNING}`\n | `${Sentiment.NEGATIVE}`\n | `${Sentiment.NEUTRAL}`;\n\nexport type CriticalCommsBannerProps = {\n title: string;\n subtitle?: string;\n action?: {\n label: string;\n href?: string;\n target?: HTMLAnchorElement['target'];\n onClick?: () => void;\n };\n sentiment?: CriticalCommsBannerSentiment;\n className?: string;\n};\n\nconst makeSurface = (sentiment: CriticalCommsBannerSentiment) => {\n const Surface = (props: PropsWithChildren<Pick<CircleProps, 'className'>>) => (\n <SentimentSurface as=\"span\" emphasis=\"elevated\" sentiment={sentiment} {...props} />\n );\n Surface.displayName = `CriticalCommsSurface(${sentiment})`;\n return Surface;\n};\n\nconst iconBySentiment: Record<CriticalCommsBannerSentiment, React.ReactNode> = {\n [Sentiment.NEGATIVE]: (\n <Circle as={makeSurface(Sentiment.NEGATIVE)} size={32} className=\"status-circle negative\">\n <AlertIcon className=\"status-icon light\" />\n </Circle>\n ),\n [Sentiment.WARNING]: (\n <Circle as={makeSurface(Sentiment.WARNING)} size={32} className=\"status-circle warning\">\n <AlertIcon className=\"status-icon dark\" />\n </Circle>\n ),\n [Sentiment.NEUTRAL]: (\n <Circle as={makeSurface(Sentiment.NEUTRAL)} size={32} className=\"status-circle neutral\">\n <ClockIcon className=\"status-icon dark\" />\n </Circle>\n ),\n};\n\nfunction CriticalCommsBanner({\n title,\n subtitle,\n action,\n sentiment = Sentiment.NEGATIVE,\n className,\n}: CriticalCommsBannerProps) {\n return (\n <SentimentSurface\n sentiment={sentiment}\n emphasis=\"elevated\"\n className={clsx('critical-comms', className)}\n >\n <Alert\n title={title}\n message={subtitle}\n action={\n action && {\n onClick: action.onClick,\n href: action.href,\n target: action.target,\n text: action.label,\n as: 'button',\n }\n }\n className={className}\n type={sentiment}\n icon={iconBySentiment[sentiment]}\n />\n </SentimentSurface>\n );\n}\n\nexport default CriticalCommsBanner;\n"],"names":["makeSurface","sentiment","Surface","props","_jsx","SentimentSurface","as","emphasis","displayName","iconBySentiment","Sentiment","NEGATIVE","Circle","size","className","children","AlertIcon","WARNING","NEUTRAL","ClockIcon","CriticalCommsBanner","title","subtitle","action","clsx","Alert","message","onClick","href","target","text","label","type","icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BA,MAAMA,WAAW,GAAIC,SAAuC,IAAI;AAC9D,EAAA,MAAMC,OAAO,GAAIC,KAAwD,iBACvEC,cAAA,CAACC,wBAAgB,EAAA;AAACC,IAAAA,EAAE,EAAC,MAAM;AAACC,IAAAA,QAAQ,EAAC,UAAU;AAACN,IAAAA,SAAS,EAAEA,SAAU;IAAA,GAAKE;AAAK,GAAC,CACjF;AACDD,EAAAA,OAAO,CAACM,WAAW,GAAG,CAAA,qBAAA,EAAwBP,SAAS,CAAA,CAAA,CAAG;AAC1D,EAAA,OAAOC,OAAO;AAChB,CAAC;AAED,MAAMO,eAAe,GAA0D;AAC7E,EAAA,CAACC,mBAAS,CAACC,QAAQ,gBACjBP,cAAA,CAACQ,cAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN,WAAW,CAACU,mBAAS,CAACC,QAAQ,CAAE;AAACE,IAAAA,IAAI,EAAE,EAAG;AAACC,IAAAA,SAAS,EAAC,wBAAwB;IAAAC,QAAA,eACvFX,cAAA,CAACY,WAAS,EAAA;AAACF,MAAAA,SAAS,EAAC;KAAmB;AAC1C,GAAQ,CACT;AACD,EAAA,CAACJ,mBAAS,CAACO,OAAO,gBAChBb,cAAA,CAACQ,cAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN,WAAW,CAACU,mBAAS,CAACO,OAAO,CAAE;AAACJ,IAAAA,IAAI,EAAE,EAAG;AAACC,IAAAA,SAAS,EAAC,uBAAuB;IAAAC,QAAA,eACrFX,cAAA,CAACY,WAAS,EAAA;AAACF,MAAAA,SAAS,EAAC;KAAkB;AACzC,GAAQ,CACT;AACD,EAAA,CAACJ,mBAAS,CAACQ,OAAO,gBAChBd,cAAA,CAACQ,cAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN,WAAW,CAACU,mBAAS,CAACQ,OAAO,CAAE;AAACL,IAAAA,IAAI,EAAE,EAAG;AAACC,IAAAA,SAAS,EAAC,uBAAuB;IAAAC,QAAA,eACrFX,cAAA,CAACe,qBAAS,EAAA;AAACL,MAAAA,SAAS,EAAC;KAAkB;GACjC;CAEX;AAED,SAASM,mBAAmBA,CAAC;EAC3BC,KAAK;EACLC,QAAQ;EACRC,MAAM;aACNtB,WAAS,GAAGS,mBAAS,CAACC,QAAQ;AAC9BG,EAAAA;AAAS,CACgB,EAAA;EACzB,oBACEV,cAAA,CAACC,wBAAgB,EAAA;AACfJ,IAAAA,SAAS,EAAEA,WAAU;AACrBM,IAAAA,QAAQ,EAAC,UAAU;AACnBO,IAAAA,SAAS,EAAEU,SAAI,CAAC,gBAAgB,EAAEV,SAAS,CAAE;IAAAC,QAAA,eAE7CX,cAAA,CAACqB,aAAK,EAAA;AACJJ,MAAAA,KAAK,EAAEA,KAAM;AACbK,MAAAA,OAAO,EAAEJ,QAAS;MAClBC,MAAM,EACJA,MAAM,IAAI;QACRI,OAAO,EAAEJ,MAAM,CAACI,OAAO;QACvBC,IAAI,EAAEL,MAAM,CAACK,IAAI;QACjBC,MAAM,EAAEN,MAAM,CAACM,MAAM;QACrBC,IAAI,EAAEP,MAAM,CAACQ,KAAK;AAClBzB,QAAAA,EAAE,EAAE;OAEP;AACDQ,MAAAA,SAAS,EAAEA,SAAU;AACrBkB,MAAAA,IAAI,EAAE/B,WAAU;MAChBgC,IAAI,EAAExB,eAAe,CAACR,WAAS;KAAE;AAErC,GAAkB,CAAC;AAEvB;;;;"}
1
+ {"version":3,"file":"CriticalCommsBanner.js","sources":["../../src/criticalBanner/CriticalCommsBanner.tsx"],"sourcesContent":["import { Alert as AlertIcon, ClockBorderless as ClockIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { PropsWithChildren } from 'react';\n\nimport Alert from '../alert';\nimport { Sentiment } from '../common';\nimport Circle, { CircleProps } from '../common/circle';\nimport SentimentSurface from '../sentimentSurface';\n\nexport type CriticalCommsBannerSentiment =\n | `${Sentiment.WARNING}`\n | `${Sentiment.NEGATIVE}`\n | `${Sentiment.NEUTRAL}`;\n\nexport type CriticalCommsBannerProps = {\n title: string;\n subtitle?: string;\n action?: {\n label: string;\n href?: string;\n target?: HTMLAnchorElement['target'];\n onClick?: () => void;\n };\n sentiment?: CriticalCommsBannerSentiment;\n className?: string;\n};\n\nconst makeSurface = (sentiment: CriticalCommsBannerSentiment) => {\n const Surface = (props: PropsWithChildren<Pick<CircleProps, 'className'>>) => (\n <SentimentSurface as=\"span\" emphasis=\"elevated\" sentiment={sentiment} {...props} />\n );\n Surface.displayName = `CriticalCommsSurface(${sentiment})`;\n return Surface;\n};\n\nconst iconBySentiment: Record<CriticalCommsBannerSentiment, React.ReactNode> = {\n [Sentiment.NEGATIVE]: (\n <Circle as={makeSurface(Sentiment.NEGATIVE)} size={32} className=\"status-circle negative\">\n <AlertIcon className=\"status-icon light\" />\n </Circle>\n ),\n [Sentiment.WARNING]: (\n <Circle as={makeSurface(Sentiment.WARNING)} size={32} className=\"status-circle warning\">\n <AlertIcon className=\"status-icon dark\" />\n </Circle>\n ),\n [Sentiment.NEUTRAL]: (\n <Circle as={makeSurface(Sentiment.NEUTRAL)} size={32} className=\"status-circle neutral\">\n <ClockIcon className=\"status-icon dark\" />\n </Circle>\n ),\n};\n\n/**\n * @deprecated `CriticalCommsBanner` component is deprecated and now replaced by the `CriticalBanner` component.\n */\nfunction CriticalCommsBanner({\n title,\n subtitle,\n action,\n sentiment = Sentiment.NEGATIVE,\n className,\n}: CriticalCommsBannerProps) {\n return (\n <SentimentSurface\n sentiment={sentiment}\n emphasis=\"elevated\"\n className={clsx('critical-comms', className)}\n >\n <Alert\n title={title}\n message={subtitle}\n action={\n action && {\n onClick: action.onClick,\n href: action.href,\n target: action.target,\n text: action.label,\n as: 'button',\n }\n }\n className={className}\n type={sentiment}\n icon={iconBySentiment[sentiment]}\n />\n </SentimentSurface>\n );\n}\n\nexport default CriticalCommsBanner;\n"],"names":["makeSurface","sentiment","Surface","props","_jsx","SentimentSurface","as","emphasis","displayName","iconBySentiment","Sentiment","NEGATIVE","Circle","size","className","children","AlertIcon","WARNING","NEUTRAL","ClockIcon","CriticalCommsBanner","title","subtitle","action","clsx","Alert","message","onClick","href","target","text","label","type","icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BA,MAAMA,WAAW,GAAIC,SAAuC,IAAI;AAC9D,EAAA,MAAMC,OAAO,GAAIC,KAAwD,iBACvEC,cAAA,CAACC,wBAAgB,EAAA;AAACC,IAAAA,EAAE,EAAC,MAAM;AAACC,IAAAA,QAAQ,EAAC,UAAU;AAACN,IAAAA,SAAS,EAAEA,SAAU;IAAA,GAAKE;AAAK,GAAC,CACjF;AACDD,EAAAA,OAAO,CAACM,WAAW,GAAG,CAAA,qBAAA,EAAwBP,SAAS,CAAA,CAAA,CAAG;AAC1D,EAAA,OAAOC,OAAO;AAChB,CAAC;AAED,MAAMO,eAAe,GAA0D;AAC7E,EAAA,CAACC,mBAAS,CAACC,QAAQ,gBACjBP,cAAA,CAACQ,cAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN,WAAW,CAACU,mBAAS,CAACC,QAAQ,CAAE;AAACE,IAAAA,IAAI,EAAE,EAAG;AAACC,IAAAA,SAAS,EAAC,wBAAwB;IAAAC,QAAA,eACvFX,cAAA,CAACY,WAAS,EAAA;AAACF,MAAAA,SAAS,EAAC;KAAmB;AAC1C,GAAQ,CACT;AACD,EAAA,CAACJ,mBAAS,CAACO,OAAO,gBAChBb,cAAA,CAACQ,cAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN,WAAW,CAACU,mBAAS,CAACO,OAAO,CAAE;AAACJ,IAAAA,IAAI,EA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B;;;;"}
@@ -64,6 +64,9 @@ const iconBySentiment = {
64
64
  })
65
65
  })
66
66
  };
67
+ /**
68
+ * @deprecated `CriticalCommsBanner` component is deprecated and now replaced by the `CriticalBanner` component.
69
+ */
67
70
  function CriticalCommsBanner({
68
71
  title,
69
72
  subtitle,
@@ -1 +1 @@
1
- {"version":3,"file":"CriticalCommsBanner.mjs","sources":["../../src/criticalBanner/CriticalCommsBanner.tsx"],"sourcesContent":["import { Alert as AlertIcon, ClockBorderless as ClockIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { PropsWithChildren } from 'react';\n\nimport Alert from '../alert';\nimport { Sentiment } from '../common';\nimport Circle, { CircleProps } from '../common/circle';\nimport SentimentSurface from '../sentimentSurface';\n\nexport type CriticalCommsBannerSentiment =\n | `${Sentiment.WARNING}`\n | `${Sentiment.NEGATIVE}`\n | `${Sentiment.NEUTRAL}`;\n\nexport type CriticalCommsBannerProps = {\n title: string;\n subtitle?: string;\n action?: {\n label: string;\n href?: string;\n target?: HTMLAnchorElement['target'];\n onClick?: () => void;\n };\n sentiment?: CriticalCommsBannerSentiment;\n className?: string;\n};\n\nconst makeSurface = (sentiment: CriticalCommsBannerSentiment) => {\n const Surface = (props: PropsWithChildren<Pick<CircleProps, 'className'>>) => (\n <SentimentSurface as=\"span\" emphasis=\"elevated\" sentiment={sentiment} {...props} />\n );\n Surface.displayName = `CriticalCommsSurface(${sentiment})`;\n return Surface;\n};\n\nconst iconBySentiment: Record<CriticalCommsBannerSentiment, React.ReactNode> = {\n [Sentiment.NEGATIVE]: (\n <Circle as={makeSurface(Sentiment.NEGATIVE)} size={32} className=\"status-circle negative\">\n <AlertIcon className=\"status-icon light\" />\n </Circle>\n ),\n [Sentiment.WARNING]: (\n <Circle as={makeSurface(Sentiment.WARNING)} size={32} className=\"status-circle warning\">\n <AlertIcon className=\"status-icon dark\" />\n </Circle>\n ),\n [Sentiment.NEUTRAL]: (\n <Circle as={makeSurface(Sentiment.NEUTRAL)} size={32} className=\"status-circle neutral\">\n <ClockIcon className=\"status-icon dark\" />\n </Circle>\n ),\n};\n\nfunction CriticalCommsBanner({\n title,\n subtitle,\n action,\n sentiment = Sentiment.NEGATIVE,\n className,\n}: CriticalCommsBannerProps) {\n return (\n <SentimentSurface\n sentiment={sentiment}\n emphasis=\"elevated\"\n className={clsx('critical-comms', className)}\n >\n <Alert\n title={title}\n message={subtitle}\n action={\n action && {\n onClick: action.onClick,\n href: action.href,\n target: action.target,\n text: action.label,\n as: 'button',\n }\n }\n className={className}\n type={sentiment}\n icon={iconBySentiment[sentiment]}\n />\n </SentimentSurface>\n );\n}\n\nexport default CriticalCommsBanner;\n"],"names":["makeSurface","sentiment","Surface","props","_jsx","SentimentSurface","as","emphasis","displayName","iconBySentiment","Sentiment","NEGATIVE","Circle","size","className","children","AlertIcon","WARNING","NEUTRAL","ClockIcon","CriticalCommsBanner","title","subtitle","action","clsx","Alert","message","onClick","href","target","text","label","type","icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BA,MAAMA,WAAW,GAAIC,SAAuC,IAAI;AAC9D,EAAA,MAAMC,OAAO,GAAIC,KAAwD,iBACvEC,GAAA,CAACC,gBAAgB,EAAA;AAACC,IAAAA,EAAE,EAAC,MAAM;AAACC,IAAAA,QAAQ,EAAC,UAAU;AAACN,IAAAA,SAAS,EAAEA,SAAU;IAAA,GAAKE;AAAK,GAAC,CACjF;AACDD,EAAAA,OAAO,CAACM,WAAW,GAAG,CAAA,qBAAA,EAAwBP,SAAS,CAAA,CAAA,CAAG;AAC1D,EAAA,OAAOC,OAAO;AAChB,CAAC;AAED,MAAMO,eAAe,GAA0D;AAC7E,EAAA,CAACC,SAAS,CAACC,QAAQ,gBACjBP,GAAA,CAACQ,MAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN,WAAW,CAACU,SAAS,CAACC,QAAQ,CAAE;AAACE,IAAAA,IAAI,EAAE,EAAG;AAACC,IAAAA,SAAS,EAAC,wBAAwB;IA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,MAAM,CAACM,MAAM;QACrBC,IAAI,EAAEP,MAAM,CAACQ,KAAK;AAClBzB,QAAAA,EAAE,EAAE;OAEP;AACDQ,MAAAA,SAAS,EAAEA,SAAU;AACrBkB,MAAAA,IAAI,EAAE/B,SAAU;MAChBgC,IAAI,EAAExB,eAAe,CAACR,SAAS;KAAE;AAErC,GAAkB,CAAC;AAEvB;;;;"}
1
+ {"version":3,"file":"CriticalCommsBanner.mjs","sources":["../../src/criticalBanner/CriticalCommsBanner.tsx"],"sourcesContent":["import { Alert as AlertIcon, ClockBorderless as ClockIcon } from '@transferwise/icons';\nimport { clsx } from 'clsx';\nimport { PropsWithChildren } from 'react';\n\nimport Alert from '../alert';\nimport { Sentiment } from '../common';\nimport Circle, { CircleProps } from '../common/circle';\nimport SentimentSurface from '../sentimentSurface';\n\nexport type CriticalCommsBannerSentiment =\n | `${Sentiment.WARNING}`\n | `${Sentiment.NEGATIVE}`\n | `${Sentiment.NEUTRAL}`;\n\nexport type CriticalCommsBannerProps = {\n title: string;\n subtitle?: string;\n action?: {\n label: string;\n href?: string;\n target?: HTMLAnchorElement['target'];\n onClick?: () => void;\n };\n sentiment?: CriticalCommsBannerSentiment;\n className?: string;\n};\n\nconst makeSurface = (sentiment: CriticalCommsBannerSentiment) => {\n const Surface = (props: PropsWithChildren<Pick<CircleProps, 'className'>>) => (\n <SentimentSurface as=\"span\" emphasis=\"elevated\" sentiment={sentiment} {...props} />\n );\n Surface.displayName = `CriticalCommsSurface(${sentiment})`;\n return Surface;\n};\n\nconst iconBySentiment: Record<CriticalCommsBannerSentiment, React.ReactNode> = {\n [Sentiment.NEGATIVE]: (\n <Circle as={makeSurface(Sentiment.NEGATIVE)} size={32} className=\"status-circle negative\">\n <AlertIcon className=\"status-icon light\" />\n </Circle>\n ),\n [Sentiment.WARNING]: (\n <Circle as={makeSurface(Sentiment.WARNING)} size={32} className=\"status-circle warning\">\n <AlertIcon className=\"status-icon dark\" />\n </Circle>\n ),\n [Sentiment.NEUTRAL]: (\n <Circle as={makeSurface(Sentiment.NEUTRAL)} size={32} className=\"status-circle neutral\">\n <ClockIcon className=\"status-icon dark\" />\n </Circle>\n ),\n};\n\n/**\n * @deprecated `CriticalCommsBanner` component is deprecated and now replaced by the `CriticalBanner` component.\n */\nfunction CriticalCommsBanner({\n title,\n subtitle,\n action,\n sentiment = Sentiment.NEGATIVE,\n className,\n}: CriticalCommsBannerProps) {\n return (\n <SentimentSurface\n sentiment={sentiment}\n emphasis=\"elevated\"\n className={clsx('critical-comms', className)}\n >\n <Alert\n title={title}\n message={subtitle}\n action={\n action && {\n onClick: action.onClick,\n href: action.href,\n target: action.target,\n text: action.label,\n as: 'button',\n }\n }\n className={className}\n type={sentiment}\n icon={iconBySentiment[sentiment]}\n />\n </SentimentSurface>\n );\n}\n\nexport default CriticalCommsBanner;\n"],"names":["makeSurface","sentiment","Surface","props","_jsx","SentimentSurface","as","emphasis","displayName","iconBySentiment","Sentiment","NEGATIVE","Circle","size","className","children","AlertIcon","WARNING","NEUTRAL","ClockIcon","CriticalCommsBanner","title","subtitle","action","clsx","Alert","message","onClick","href","target","text","label","type","icon"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2BA,MAAMA,WAAW,GAAIC,SAAuC,IAAI;AAC9D,EAAA,MAAMC,OAAO,GAAIC,KAAwD,iBACvEC,GAAA,CAACC,gBAAgB,EAAA;AAACC,IAAAA,EAAE,EAAC,MAAM;AAACC,IAAAA,QAAQ,EAAC,UAAU;AAACN,IAAAA,SAAS,EAAEA,SAAU;IAAA,GAAKE;AAAK,GAAC,CACjF;AACDD,EAAAA,OAAO,CAACM,WAAW,GAAG,CAAA,qBAAA,EAAwBP,SAAS,CAAA,CAAA,CAAG;AAC1D,EAAA,OAAOC,OAAO;AAChB,CAAC;AAED,MAAMO,eAAe,GAA0D;AAC7E,EAAA,CAACC,SAAS,CAACC,QAAQ,gBACjBP,GAAA,CAACQ,MAAM,EAAA;AAACN,IAAAA,EAAE,EAAEN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AM,EACJA,MAAM,IAAI;QACRI,OAAO,EAAEJ,MAAM,CAACI,OAAO;QACvBC,IAAI,EAAEL,MAAM,CAACK,IAAI;QACjBC,MAAM,EAAEN,MAAM,CAACM,MAAM;QACrBC,IAAI,EAAEP,MAAM,CAACQ,KAAK;AAClBzB,QAAAA,EAAE,EAAE;OAEP;AACDQ,MAAAA,SAAS,EAAEA,SAAU;AACrBkB,MAAAA,IAAI,EAAE/B,SAAU;MAChBgC,IAAI,EAAExB,eAAe,CAACR,SAAS;KAAE;AAErC,GAAkB,CAAC;AAEvB;;;;"}
@@ -27,17 +27,18 @@ require('react-intl');
27
27
  require('../common/closeButton/CloseButton.messages.js');
28
28
  var jsxRuntime = require('react/jsx-runtime');
29
29
  var InlinePrompt = require('../prompt/InlinePrompt/InlinePrompt.js');
30
- require('../statusIcon/StatusIcon.js');
31
30
  require('../body/Body.js');
32
31
  require('../button/Button.resolver.js');
32
+ require('../prompt/PrimitivePrompt/PrimitivePrompt.js');
33
33
  require('../badge/Badge.js');
34
34
  require('@wise/art');
35
+ require('../statusIcon/StatusIcon.js');
35
36
  require('@transferwise/neptune-validation');
36
37
  require('../provider/direction/DirectionProvider.js');
37
- require('../sentimentSurface/SentimentSurface.js');
38
38
  require('../primitives/PrimitiveButton/PrimitiveButton.js');
39
39
  require('../primitives/PrimitiveAnchor/PrimitiveAnchor.js');
40
40
  require('../link/Link.messages.js');
41
+ require('../prompt/common/Expander/Expander.messages.js');
41
42
  var contexts = require('../inputs/contexts.js');
42
43
  var Label = require('../label/Label.js');
43
44
 
@@ -1 +1 @@
1
- {"version":3,"file":"Field.js","sources":["../../src/field/Field.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useRef } from 'react';\n\nimport { Sentiment } from '../common';\nimport { InlinePrompt, type InlinePromptProps } from '../prompt';\nimport {\n FieldLabelContextProvider,\n InputDescribedByProvider,\n InputIdContextProvider,\n InputInvalidProvider,\n} from '../inputs/contexts';\nimport { Label } from '../label';\n\nexport type FieldProps = {\n /** `null` disables auto-generating the `id` attribute, falling back to nesting-based label association over setting `htmlFor` explicitly. */\n id?: string | null;\n /** Should be specified unless the wrapped control has its own labeling mechanism, e.g. `Checkbox`. */\n label?: React.ReactNode;\n /** @default true */\n required?: boolean;\n /** @deprecated Use `description` prop instead. */\n hint?: React.ReactNode;\n message?: React.ReactNode;\n /**\n * Override for the [InlinePrompt icon's default, accessible name](/?path=/docs/other-statusicon-accessibility--docs)\n * announced by the screen readers\n * */\n messageIconLabel?: string;\n /**\n * If true, shows a loading spinner in place of the message icon of the InlinePrompt\n * @default false\n */\n messageLoading?: boolean;\n description?: React.ReactNode;\n /** @deprecated Use `message` and `type={Sentiment.NEGATIVE}` prop instead. */\n error?: React.ReactNode;\n /** @default Sentiment.NEUTRAL */\n sentiment?: InlinePromptProps['sentiment'];\n className?: string;\n children?: React.ReactNode;\n};\n\nexport const Field = ({\n id,\n label,\n required = true,\n message: propMessage,\n messageIconLabel,\n messageLoading,\n hint,\n description = hint,\n sentiment: propType = Sentiment.NEUTRAL,\n className,\n children,\n ...props\n}: FieldProps) => {\n const labelRef = useRef<HTMLLabelElement>(null);\n const sentiment = props.error ? Sentiment.NEGATIVE : propType;\n const message = propMessage || props.error;\n const hasError = sentiment === Sentiment.NEGATIVE;\n\n const labelId = useId();\n\n const fallbackInputId = useId();\n const inputId = id !== null ? (id ?? fallbackInputId) : undefined;\n\n const messageId = useId();\n const descriptionId = useId();\n\n /**\n * form control can have multiple messages to describe it,\n * e.g the description underneath the label and inline alert\n */\n function ariaDescribedbyByIds() {\n const messageIds = [];\n if (description) {\n messageIds.push(descriptionId);\n }\n if (message) {\n messageIds.push(messageId);\n }\n return messageIds.length > 0 ? messageIds.join(' ') : undefined;\n }\n\n return (\n <FieldLabelContextProvider value={{ id: labelId, ref: labelRef }}>\n <InputIdContextProvider value={inputId}>\n <InputDescribedByProvider value={ariaDescribedbyByIds()}>\n <InputInvalidProvider value={hasError}>\n <div\n className={clsx(\n 'np-field form-group d-block',\n {\n 'has-success': sentiment === Sentiment.POSITIVE,\n 'has-warning': sentiment === Sentiment.WARNING,\n 'has-error': hasError,\n 'has-info': sentiment === Sentiment.NEUTRAL,\n },\n className,\n )}\n >\n {label != null ? (\n <>\n <Label ref={labelRef} id={labelId} htmlFor={inputId}>\n {required ? label : <Label.Optional>{label}</Label.Optional>}\n </Label>\n <Label.Description id={descriptionId}>{description}</Label.Description>\n <div className=\"np-field-control\">{children}</div>\n </>\n ) : (\n children\n )}\n\n {message && (\n <InlinePrompt\n sentiment={sentiment}\n id={messageId}\n mediaLabel={messageIconLabel}\n className=\"np-field__prompt\"\n loading={messageLoading}\n width=\"full\"\n >\n {message}\n </InlinePrompt>\n )}\n </div>\n </InputInvalidProvider>\n </InputDescribedByProvider>\n </InputIdContextProvider>\n </FieldLabelContextProvider>\n );\n};\n"],"names":["Field","id","label","required","message","propMessage","messageIconLabel","messageLoading","hint","description","sentiment","propType","Sentiment","NEUTRAL","className","children","props","labelRef","useRef","error","NEGATIVE","hasError","labelId","useId","fallbackInputId","inputId","undefined","messageId","descriptionId","ariaDescribedbyByIds","messageIds","push","length","join","_jsx","FieldLabelContextProvider","value","ref","InputIdContextProvider","InputDescribedByProvider","InputInvalidProvider","_jsxs","clsx","POSITIVE","WARNING","_Fragment","Label","htmlFor","Optional","Description","InlinePrompt","mediaLabel","loading","width"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0CO,MAAMA,KAAK,GAAGA,CAAC;EACpBC,EAAE;EACFC,KAAK;AACLC,EAAAA,QAAQ,GAAG,IAAI;AACfC,EAAAA,OAAO,EAAEC,WAAW;EACpBC,gBAAgB;EAChBC,cAAc;EACdC,IAAI;AACJC,EAAAA,WAAW,GAAGD,IAAI;AAClBE,EAAAA,SAAS,EAAEC,QAAQ,GAAGC,mBAAS,CAACC,OAAO;EACvCC,SAAS;EACTC,QAAQ;EACR,GAAGC;AAAK,CACG,KAAI;AACf,EAAA,MAA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SAAS,EAAC,kBAAkB;AAC5BsC,cAAAA,OAAO,EAAE7C,cAAe;AACxB8C,cAAAA,KAAK,EAAC,MAAM;AAAAtC,cAAAA,QAAA,EAEXX;AAAO,aACI,CACf;WACE;SACe;OACE;KACJ;AAC1B,GAA2B,CAAC;AAEhC;;;;"}
1
+ {"version":3,"file":"Field.js","sources":["../../src/field/Field.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useRef } from 'react';\n\nimport { Sentiment } from '../common';\nimport { InlinePrompt, type InlinePromptProps } from '../prompt';\nimport {\n FieldLabelContextProvider,\n InputDescribedByProvider,\n InputIdContextProvider,\n InputInvalidProvider,\n} from '../inputs/contexts';\nimport { Label } from '../label';\n\nexport type FieldProps = {\n /** `null` disables auto-generating the `id` attribute, falling back to nesting-based label association over setting `htmlFor` explicitly. */\n id?: string | null;\n /** Should be specified unless the wrapped control has its own labeling mechanism, e.g. `Checkbox`. */\n label?: React.ReactNode;\n /** @default true */\n required?: boolean;\n /** @deprecated Use `description` prop instead. */\n hint?: React.ReactNode;\n message?: React.ReactNode;\n /**\n * Override for the [InlinePrompt icon's default, accessible name](/?path=/docs/other-statusicon-accessibility--docs)\n * announced by the screen readers\n * */\n messageIconLabel?: string;\n /**\n * If true, shows a loading spinner in place of the message icon of the InlinePrompt\n * @default false\n */\n messageLoading?: boolean;\n description?: React.ReactNode;\n /** @deprecated Use `message` and `type={Sentiment.NEGATIVE}` prop instead. */\n error?: React.ReactNode;\n /** @default Sentiment.NEUTRAL */\n sentiment?: InlinePromptProps['sentiment'];\n className?: string;\n children?: React.ReactNode;\n};\n\nexport const Field = ({\n id,\n label,\n required = true,\n message: propMessage,\n messageIconLabel,\n messageLoading,\n hint,\n description = hint,\n sentiment: propType = Sentiment.NEUTRAL,\n className,\n children,\n ...props\n}: FieldProps) => {\n const labelRef = useRef<HTMLLabelElement>(null);\n const sentiment = props.error ? Sentiment.NEGATIVE : propType;\n const message = propMessage || props.error;\n const hasError = sentiment === Sentiment.NEGATIVE;\n\n const labelId = useId();\n\n const fallbackInputId = useId();\n const inputId = id !== null ? (id ?? fallbackInputId) : undefined;\n\n const messageId = useId();\n const descriptionId = useId();\n\n /**\n * form control can have multiple messages to describe it,\n * e.g the description underneath the label and inline alert\n */\n function ariaDescribedbyByIds() {\n const messageIds = [];\n if (description) {\n messageIds.push(descriptionId);\n }\n if (message) {\n messageIds.push(messageId);\n }\n return messageIds.length > 0 ? messageIds.join(' ') : undefined;\n }\n\n return (\n <FieldLabelContextProvider value={{ id: labelId, ref: labelRef }}>\n <InputIdContextProvider value={inputId}>\n <InputDescribedByProvider value={ariaDescribedbyByIds()}>\n <InputInvalidProvider value={hasError}>\n <div\n className={clsx(\n 'np-field form-group d-block',\n {\n 'has-success': sentiment === Sentiment.POSITIVE,\n 'has-warning': sentiment === Sentiment.WARNING,\n 'has-error': hasError,\n 'has-info': sentiment === Sentiment.NEUTRAL,\n },\n className,\n )}\n >\n {label != null ? (\n <>\n <Label ref={labelRef} id={labelId} htmlFor={inputId}>\n {required ? label : <Label.Optional>{label}</Label.Optional>}\n </Label>\n <Label.Description id={descriptionId}>{description}</Label.Description>\n <div className=\"np-field-control\">{children}</div>\n </>\n ) : (\n children\n )}\n\n {message && (\n <InlinePrompt\n sentiment={sentiment}\n id={messageId}\n mediaLabel={messageIconLabel}\n className=\"np-field__prompt\"\n loading={messageLoading}\n width=\"full\"\n >\n {message}\n </InlinePrompt>\n )}\n </div>\n </InputInvalidProvider>\n </InputDescribedByProvider>\n </InputIdContextProvider>\n </FieldLabelContextProvider>\n );\n};\n"],"names":["Field","id","label","required","message","propMessage","messageIconLabel","messageLoading","hint","description","sentiment","propType","Sentiment","NEUTRAL","className","children","props","labelRef","useRef","error","NEGATIVE","hasError","labelId","useId","fallbackInputId","inputId","undefined","messageId","descriptionId","ariaDescribedbyByIds","messageIds","push","length","join","_jsx","FieldLabelContextProvider","value","ref","InputIdContextProvider","InputDescribedByProvider","InputInvalidProvider","_jsxs","clsx","POSITIV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,eACvD,CACP,eAAAgC,cAAA,CAACY,WAAK,CAACG,WAAW,EAAA;AAAChD,gBAAAA,EAAE,EAAE2B,aAAc;AAAAb,gBAAAA,QAAA,EAAEN;eAA+B,CACtE,eAAAyB,cAAA,CAAA,KAAA,EAAA;AAAKpB,gBAAAA,SAAS,EAAC,kBAAkB;AAAAC,gBAAAA,QAAA,EAAEA;AAAQ,eAAM,CACnD;aAAA,CAAG,GAEHA,QACD,EAEAX,OAAO,iBACN8B,cAAA,CAACgB,yBAAY,EAAA;AACXxC,cAAAA,SAAS,EAAEA,WAAU;AACrBT,cAAAA,EAAE,EAAE0B,SAAU;AACdwB,cAAAA,UAAU,EAAE7C,gBAAiB;AAC7BQ,cAAAA,SAAS,EAAC,kBAAkB;AAC5BsC,cAAAA,OAAO,EAAE7C,cAAe;AACxB8C,cAAAA,KAAK,EAAC,MAAM;AAAAtC,cAAAA,QAAA,EAEXX;AAAO,aACI,CACf;WACE;SACe;OACE;KACJ;AAC1B,GAA2B,CAAC;AAEhC;;;;"}
@@ -25,17 +25,18 @@ import 'react-intl';
25
25
  import '../common/closeButton/CloseButton.messages.mjs';
26
26
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
27
27
  import { InlinePrompt } from '../prompt/InlinePrompt/InlinePrompt.mjs';
28
- import '../statusIcon/StatusIcon.mjs';
29
28
  import '../body/Body.mjs';
30
29
  import '../button/Button.resolver.mjs';
30
+ import '../prompt/PrimitivePrompt/PrimitivePrompt.mjs';
31
31
  import '../badge/Badge.mjs';
32
32
  import '@wise/art';
33
+ import '../statusIcon/StatusIcon.mjs';
33
34
  import '@transferwise/neptune-validation';
34
35
  import '../provider/direction/DirectionProvider.mjs';
35
- import '../sentimentSurface/SentimentSurface.mjs';
36
36
  import '../primitives/PrimitiveButton/PrimitiveButton.mjs';
37
37
  import '../primitives/PrimitiveAnchor/PrimitiveAnchor.mjs';
38
38
  import '../link/Link.messages.mjs';
39
+ import '../prompt/common/Expander/Expander.messages.mjs';
39
40
  import { FieldLabelContextProvider, InputIdContextProvider, InputDescribedByProvider, InputInvalidProvider } from '../inputs/contexts.mjs';
40
41
  import { Label as LabelNamespace } from '../label/Label.mjs';
41
42
 
@@ -1 +1 @@
1
- {"version":3,"file":"Field.mjs","sources":["../../src/field/Field.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useRef } from 'react';\n\nimport { Sentiment } from '../common';\nimport { InlinePrompt, type InlinePromptProps } from '../prompt';\nimport {\n FieldLabelContextProvider,\n InputDescribedByProvider,\n InputIdContextProvider,\n InputInvalidProvider,\n} from '../inputs/contexts';\nimport { Label } from '../label';\n\nexport type FieldProps = {\n /** `null` disables auto-generating the `id` attribute, falling back to nesting-based label association over setting `htmlFor` explicitly. */\n id?: string | null;\n /** Should be specified unless the wrapped control has its own labeling mechanism, e.g. `Checkbox`. */\n label?: React.ReactNode;\n /** @default true */\n required?: boolean;\n /** @deprecated Use `description` prop instead. */\n hint?: React.ReactNode;\n message?: React.ReactNode;\n /**\n * Override for the [InlinePrompt icon's default, accessible name](/?path=/docs/other-statusicon-accessibility--docs)\n * announced by the screen readers\n * */\n messageIconLabel?: string;\n /**\n * If true, shows a loading spinner in place of the message icon of the InlinePrompt\n * @default false\n */\n messageLoading?: boolean;\n description?: React.ReactNode;\n /** @deprecated Use `message` and `type={Sentiment.NEGATIVE}` prop instead. */\n error?: React.ReactNode;\n /** @default Sentiment.NEUTRAL */\n sentiment?: InlinePromptProps['sentiment'];\n className?: string;\n children?: React.ReactNode;\n};\n\nexport const Field = ({\n id,\n label,\n required = true,\n message: propMessage,\n messageIconLabel,\n messageLoading,\n hint,\n description = hint,\n sentiment: propType = Sentiment.NEUTRAL,\n className,\n children,\n ...props\n}: FieldProps) => {\n const labelRef = useRef<HTMLLabelElement>(null);\n const sentiment = props.error ? Sentiment.NEGATIVE : propType;\n const message = propMessage || props.error;\n const hasError = sentiment === Sentiment.NEGATIVE;\n\n const labelId = useId();\n\n const fallbackInputId = useId();\n const inputId = id !== null ? (id ?? fallbackInputId) : undefined;\n\n const messageId = useId();\n const descriptionId = useId();\n\n /**\n * form control can have multiple messages to describe it,\n * e.g the description underneath the label and inline alert\n */\n function ariaDescribedbyByIds() {\n const messageIds = [];\n if (description) {\n messageIds.push(descriptionId);\n }\n if (message) {\n messageIds.push(messageId);\n }\n return messageIds.length > 0 ? messageIds.join(' ') : undefined;\n }\n\n return (\n <FieldLabelContextProvider value={{ id: labelId, ref: labelRef }}>\n <InputIdContextProvider value={inputId}>\n <InputDescribedByProvider value={ariaDescribedbyByIds()}>\n <InputInvalidProvider value={hasError}>\n <div\n className={clsx(\n 'np-field form-group d-block',\n {\n 'has-success': sentiment === Sentiment.POSITIVE,\n 'has-warning': sentiment === Sentiment.WARNING,\n 'has-error': hasError,\n 'has-info': sentiment === Sentiment.NEUTRAL,\n },\n className,\n )}\n >\n {label != null ? (\n <>\n <Label ref={labelRef} id={labelId} htmlFor={inputId}>\n {required ? label : <Label.Optional>{label}</Label.Optional>}\n </Label>\n <Label.Description id={descriptionId}>{description}</Label.Description>\n <div className=\"np-field-control\">{children}</div>\n </>\n ) : (\n children\n )}\n\n {message && (\n <InlinePrompt\n sentiment={sentiment}\n id={messageId}\n mediaLabel={messageIconLabel}\n className=\"np-field__prompt\"\n loading={messageLoading}\n width=\"full\"\n >\n {message}\n </InlinePrompt>\n )}\n </div>\n </InputInvalidProvider>\n </InputDescribedByProvider>\n </InputIdContextProvider>\n </FieldLabelContextProvider>\n );\n};\n"],"names":["Field","id","label","required","message","propMessage","messageIconLabel","messageLoading","hint","description","sentiment","propType","Sentiment","NEUTRAL","className","children","props","labelRef","useRef","error","NEGATIVE","hasError","labelId","useId","fallbackInputId","inputId","undefined","messageId","descriptionId","ariaDescribedbyByIds","messageIds","push","length","join","_jsx","FieldLabelContextProvider","value","ref","InputIdContextProvider","InputDescribedByProvider","InputInvalidProvider","_jsxs","clsx","POSITIVE","WARNING","_Fragment","Label","htmlFor","Optional","Description","InlinePrompt","mediaLabel","loading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AAA,EAAE,EAAE2B,aAAc;AAAAb,gBAAAA,QAAA,EAAEN;eAA+B,CACtE,eAAAyB,GAAA,CAAA,KAAA,EAAA;AAAKpB,gBAAAA,SAAS,EAAC,kBAAkB;AAAAC,gBAAAA,QAAA,EAAEA;AAAQ,eAAM,CACnD;aAAA,CAAG,GAEHA,QACD,EAEAX,OAAO,iBACN8B,GAAA,CAACgB,YAAY,EAAA;AACXxC,cAAAA,SAAS,EAAEA,SAAU;AACrBT,cAAAA,EAAE,EAAE0B,SAAU;AACdwB,cAAAA,UAAU,EAAE7C,gBAAiB;AAC7BQ,cAAAA,SAAS,EAAC,kBAAkB;AAC5BsC,cAAAA,OAAO,EAAE7C,cAAe;AACxB8C,cAAAA,KAAK,EAAC,MAAM;AAAAtC,cAAAA,QAAA,EAEXX;AAAO,aACI,CACf;WACE;SACe;OACE;KACJ;AAC1B,GAA2B,CAAC;AAEhC;;;;"}
1
+ {"version":3,"file":"Field.mjs","sources":["../../src/field/Field.tsx"],"sourcesContent":["import { clsx } from 'clsx';\nimport { useId, useRef } from 'react';\n\nimport { Sentiment } from '../common';\nimport { InlinePrompt, type InlinePromptProps } from '../prompt';\nimport {\n FieldLabelContextProvider,\n InputDescribedByProvider,\n InputIdContextProvider,\n InputInvalidProvider,\n} from '../inputs/contexts';\nimport { Label } from '../label';\n\nexport type FieldProps = {\n /** `null` disables auto-generating the `id` attribute, falling back to nesting-based label association over setting `htmlFor` explicitly. */\n id?: string | null;\n /** Should be specified unless the wrapped control has its own labeling mechanism, e.g. `Checkbox`. */\n label?: React.ReactNode;\n /** @default true */\n required?: boolean;\n /** @deprecated Use `description` prop instead. */\n hint?: React.ReactNode;\n message?: React.ReactNode;\n /**\n * Override for the [InlinePrompt icon's default, accessible name](/?path=/docs/other-statusicon-accessibility--docs)\n * announced by the screen readers\n * */\n messageIconLabel?: string;\n /**\n * If true, shows a loading spinner in place of the message icon of the InlinePrompt\n * @default false\n */\n messageLoading?: boolean;\n description?: React.ReactNode;\n /** @deprecated Use `message` and `type={Sentiment.NEGATIVE}` prop instead. */\n error?: React.ReactNode;\n /** @default Sentiment.NEUTRAL */\n sentiment?: InlinePromptProps['sentiment'];\n className?: string;\n children?: React.ReactNode;\n};\n\nexport const Field = ({\n id,\n label,\n required = true,\n message: propMessage,\n messageIconLabel,\n messageLoading,\n hint,\n description = hint,\n sentiment: propType = Sentiment.NEUTRAL,\n className,\n children,\n ...props\n}: FieldProps) => {\n const labelRef = useRef<HTMLLabelElement>(null);\n const sentiment = props.error ? Sentiment.NEGATIVE : propType;\n const message = propMessage || props.error;\n const hasError = sentiment === Sentiment.NEGATIVE;\n\n const labelId = useId();\n\n const fallbackInputId = useId();\n const inputId = id !== null ? (id ?? fallbackInputId) : undefined;\n\n const messageId = useId();\n const descriptionId = useId();\n\n /**\n * form control can have multiple messages to describe it,\n * e.g the description underneath the label and inline alert\n */\n function ariaDescribedbyByIds() {\n const messageIds = [];\n if (description) {\n messageIds.push(descriptionId);\n }\n if (message) {\n messageIds.push(messageId);\n }\n return messageIds.length > 0 ? messageIds.join(' ') : undefined;\n }\n\n return (\n <FieldLabelContextProvider value={{ id: labelId, ref: labelRef }}>\n <InputIdContextProvider value={inputId}>\n <InputDescribedByProvider value={ariaDescribedbyByIds()}>\n <InputInvalidProvider value={hasError}>\n <div\n className={clsx(\n 'np-field form-group d-block',\n {\n 'has-success': sentiment === Sentiment.POSITIVE,\n 'has-warning': sentiment === Sentiment.WARNING,\n 'has-error': hasError,\n 'has-info': sentiment === Sentiment.NEUTRAL,\n },\n className,\n )}\n >\n {label != null ? (\n <>\n <Label ref={labelRef} id={labelId} htmlFor={inputId}>\n {required ? label : <Label.Optional>{label}</Label.Optional>}\n </Label>\n <Label.Description id={descriptionId}>{description}</Label.Description>\n <div className=\"np-field-control\">{children}</div>\n </>\n ) : (\n children\n )}\n\n {message && (\n <InlinePrompt\n sentiment={sentiment}\n id={messageId}\n mediaLabel={messageIconLabel}\n className=\"np-field__prompt\"\n loading={messageLoading}\n width=\"full\"\n >\n {message}\n </InlinePrompt>\n )}\n </div>\n </InputInvalidProvider>\n </InputDescribedByProvider>\n </InputIdContextProvider>\n </FieldLabelContextProvider>\n );\n};\n"],"names":["Field","id","label","required","message","propMessage","messageIconLabel","messageLoading","hint","description","sentiment","propType","Sentiment","NEUTRAL","className","children","props","labelRef","useRef","error","NEGATIVE","hasError","labelId","useId","fallbackInputId","inputId","undefined","messageId","descriptionId","ariaDescribedbyByIds","messageIds","push","length","join","_jsx","FieldLabelContextProvider","value","ref","InputIdContextProvider","InputDescribedByProvider","InputInvalidProvider","_jsxs","clsx","POSITIVE","WARNING","_Fragment","Label","htmlFor","Optional","Description","InlinePrompt","mediaLabel","loading","width"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0CO,MAAMA,KAAK,GAAGA,CAAC;EACpBC,EAAE;EACFC,KAAK;AACLC,EAAAA,QAAQ,GAAG,IAAI;AACfC,EAAAA,OAAO,EAAEC,WAAW;EACpBC,gBAAgB;EAChBC,cAAc;EACdC,IAAI;AACJC,EAAAA,WAAW,GAAGD,IAAI;AAClBE,EAAAA,SAAS,EAAEC,QAAQ,GAAGC,SAAS,CAACC,OAAO;EACvCC,SAAS;EACTC,QAAQ;EACR,GAAGC;AAAK,CACG,KAAI;AACf,EAAA,MAAMC,QAAQ,GAAGC,MAAM,CAAmB,IAAI,CAAC;EAC/C,MAAMR,SAAS,GAAGM,KAAK,CAACG,KAAK,GAAGP,SAAS,CAACQ,QAAQ,GAAGT,QAAQ;AAC7D,EAAA,MAAMP,OAAO,GAAGC,WAAW,IAAIW,KAAK,CAACG,KAAK;AAC1C,EAAA,MAAME,QAAQ,GAAGX,SAAS,KAAKE,SAAS,CAACQ,QAAQ;AAEjD,EAAA,MAAME,OAAO,GAAGC,KAAK,EAAE;AAEvB,EAAA,MAAMC,eAAe,GAAGD,KAAK,EAAE;EAC/B,MAAME,OAAO,GAAGxB,EAAE,KAAK,IAAI,GAAIA,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AC,YAAAA,QAAA,GAEDb,KAAK,IAAI,IAAI,gBACZuC,IAAA,CAAAI,QAAA,EAAA;cAAA9B,QAAA,EAAA,cACEmB,GAAA,CAACY,cAAK,EAAA;AAACT,gBAAAA,GAAG,EAAEpB,QAAS;AAAChB,gBAAAA,EAAE,EAAEqB,OAAQ;AAACyB,gBAAAA,OAAO,EAAEtB,OAAQ;gBAAAV,QAAA,EACjDZ,QAAQ,GAAGD,KAAK,gBAAGgC,GAAA,CAACY,cAAK,CAACE,QAAQ,EAAA;AAAAjC,kBAAAA,QAAA,EAAEb;iBAAsB;AAAC,eACvD,CACP,eAAAgC,GAAA,CAACY,cAAK,CAACG,WAAW,EAAA;AAAChD,gBAAAA,EAAE,EAAE2B,aAAc;AAAAb,gBAAAA,QAAA,EAAEN;eAA+B,CACtE,eAAAyB,GAAA,CAAA,KAAA,EAAA;AAAKpB,gBAAAA,SAAS,EAAC,kBAAkB;AAAAC,gBAAAA,QAAA,EAAEA;AAAQ,eAAM,CACnD;aAAA,CAAG,GAEHA,QACD,EAEAX,OAAO,iBACN8B,GAAA,CAACgB,YAAY,EAAA;AACXxC,cAAAA,SAAS,EAAEA,SAAU;AACrBT,cAAAA,EAAE,EAAE0B,SAAU;AACdwB,cAAAA,UAAU,EAAE7C,gBAAiB;AAC7BQ,cAAAA,SAAS,EAAC,kBAAkB;AAC5BsC,cAAAA,OAAO,EAAE7C,cAAe;AACxB8C,cAAAA,KAAK,EAAC,MAAM;AAAAtC,cAAAA,QAAA,EAEXX;AAAO,aACI,CACf;WACE;SACe;OACE;KACJ;AAC1B,GAA2B,CAAC;AAEhC;;;;"}
@@ -16,6 +16,8 @@
16
16
  "neptune.DateLookup.selected": "vybráno",
17
17
  "neptune.DateLookup.twentyYears": "20 let",
18
18
  "neptune.DateLookup.year": "rok",
19
+ "neptune.Expander.collapseAriaLabel": "Sbalit",
20
+ "neptune.Expander.expandAriaLabel": "Rozbalit",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Napište měnu/zemi",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Vybrat měnu",
21
23
  "neptune.FlowNavigation.back": "zpět na předchozí krok",
@@ -20,6 +20,8 @@ var cs = {
20
20
  "neptune.DateLookup.selected": "vybráno",
21
21
  "neptune.DateLookup.twentyYears": "20 let",
22
22
  "neptune.DateLookup.year": "rok",
23
+ "neptune.Expander.collapseAriaLabel": "Sbalit",
24
+ "neptune.Expander.expandAriaLabel": "Rozbalit",
23
25
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Napište měnu/zemi",
24
26
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Vybrat měnu",
25
27
  "neptune.FlowNavigation.back": "zpět na předchozí krok",
@@ -1 +1 @@
1
- {"version":3,"file":"cs.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"cs.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@ var cs = {
16
16
  "neptune.DateLookup.selected": "vybráno",
17
17
  "neptune.DateLookup.twentyYears": "20 let",
18
18
  "neptune.DateLookup.year": "rok",
19
+ "neptune.Expander.collapseAriaLabel": "Sbalit",
20
+ "neptune.Expander.expandAriaLabel": "Rozbalit",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Napište měnu/zemi",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Vybrat měnu",
21
23
  "neptune.FlowNavigation.back": "zpět na předchozí krok",
@@ -1 +1 @@
1
- {"version":3,"file":"cs.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"cs.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@
16
16
  "neptune.DateLookup.selected": "ausgewählt",
17
17
  "neptune.DateLookup.twentyYears": "20 Jahre",
18
18
  "neptune.DateLookup.year": "Jahr",
19
+ "neptune.Expander.collapseAriaLabel": "Minimieren",
20
+ "neptune.Expander.expandAriaLabel": "Maximieren",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Gib eine Währung / ein Land ein",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Wähle eine Währung",
21
23
  "neptune.FlowNavigation.back": "zurück zum vorherigen Schritt",
@@ -20,6 +20,8 @@ var de = {
20
20
  "neptune.DateLookup.selected": "ausgewählt",
21
21
  "neptune.DateLookup.twentyYears": "20 Jahre",
22
22
  "neptune.DateLookup.year": "Jahr",
23
+ "neptune.Expander.collapseAriaLabel": "Minimieren",
24
+ "neptune.Expander.expandAriaLabel": "Maximieren",
23
25
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Gib eine Währung / ein Land ein",
24
26
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Wähle eine Währung",
25
27
  "neptune.FlowNavigation.back": "zurück zum vorherigen Schritt",
@@ -1 +1 @@
1
- {"version":3,"file":"de.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"de.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@ var de = {
16
16
  "neptune.DateLookup.selected": "ausgewählt",
17
17
  "neptune.DateLookup.twentyYears": "20 Jahre",
18
18
  "neptune.DateLookup.year": "Jahr",
19
+ "neptune.Expander.collapseAriaLabel": "Minimieren",
20
+ "neptune.Expander.expandAriaLabel": "Maximieren",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Gib eine Währung / ein Land ein",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Wähle eine Währung",
21
23
  "neptune.FlowNavigation.back": "zurück zum vorherigen Schritt",
@@ -1 +1 @@
1
- {"version":3,"file":"de.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"de.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@
16
16
  "neptune.DateLookup.selected": "selected",
17
17
  "neptune.DateLookup.twentyYears": "20 years",
18
18
  "neptune.DateLookup.year": "year",
19
+ "neptune.Expander.collapseAriaLabel": "Collapse",
20
+ "neptune.Expander.expandAriaLabel": "Expand",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Type a currency / country",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Select currency",
21
23
  "neptune.FlowNavigation.back": "back to previous step",
@@ -20,6 +20,8 @@ var en = {
20
20
  "neptune.DateLookup.selected": "selected",
21
21
  "neptune.DateLookup.twentyYears": "20 years",
22
22
  "neptune.DateLookup.year": "year",
23
+ "neptune.Expander.collapseAriaLabel": "Collapse",
24
+ "neptune.Expander.expandAriaLabel": "Expand",
23
25
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Type a currency / country",
24
26
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Select currency",
25
27
  "neptune.FlowNavigation.back": "back to previous step",
@@ -1 +1 @@
1
- {"version":3,"file":"en.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"en.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@ var en = {
16
16
  "neptune.DateLookup.selected": "selected",
17
17
  "neptune.DateLookup.twentyYears": "20 years",
18
18
  "neptune.DateLookup.year": "year",
19
+ "neptune.Expander.collapseAriaLabel": "Collapse",
20
+ "neptune.Expander.expandAriaLabel": "Expand",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Type a currency / country",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Select currency",
21
23
  "neptune.FlowNavigation.back": "back to previous step",
@@ -1 +1 @@
1
- {"version":3,"file":"en.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"en.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@
16
16
  "neptune.DateLookup.selected": "seleccionado",
17
17
  "neptune.DateLookup.twentyYears": "20 años",
18
18
  "neptune.DateLookup.year": "año",
19
+ "neptune.Expander.collapseAriaLabel": "Ocultar",
20
+ "neptune.Expander.expandAriaLabel": "Expandir",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Indica una divisa/país",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Seleccionar divisa",
21
23
  "neptune.FlowNavigation.back": "volver al paso anterior",
@@ -20,6 +20,8 @@ var es = {
20
20
  "neptune.DateLookup.selected": "seleccionado",
21
21
  "neptune.DateLookup.twentyYears": "20 años",
22
22
  "neptune.DateLookup.year": "año",
23
+ "neptune.Expander.collapseAriaLabel": "Ocultar",
24
+ "neptune.Expander.expandAriaLabel": "Expandir",
23
25
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Indica una divisa/país",
24
26
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Seleccionar divisa",
25
27
  "neptune.FlowNavigation.back": "volver al paso anterior",
@@ -1 +1 @@
1
- {"version":3,"file":"es.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"es.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@ var es = {
16
16
  "neptune.DateLookup.selected": "seleccionado",
17
17
  "neptune.DateLookup.twentyYears": "20 años",
18
18
  "neptune.DateLookup.year": "año",
19
+ "neptune.Expander.collapseAriaLabel": "Ocultar",
20
+ "neptune.Expander.expandAriaLabel": "Expandir",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Indica una divisa/país",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Seleccionar divisa",
21
23
  "neptune.FlowNavigation.back": "volver al paso anterior",
@@ -1 +1 @@
1
- {"version":3,"file":"es.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"es.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@
16
16
  "neptune.DateLookup.selected": "sélectionnée",
17
17
  "neptune.DateLookup.twentyYears": "20 ans",
18
18
  "neptune.DateLookup.year": "année",
19
+ "neptune.Expander.collapseAriaLabel": "Réduire",
20
+ "neptune.Expander.expandAriaLabel": "Développer",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Entrez une devise/un pays",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Sélectionnez une devise",
21
23
  "neptune.FlowNavigation.back": "revenir à l'étape précédente",
@@ -20,6 +20,8 @@ var fr = {
20
20
  "neptune.DateLookup.selected": "sélectionnée",
21
21
  "neptune.DateLookup.twentyYears": "20 ans",
22
22
  "neptune.DateLookup.year": "année",
23
+ "neptune.Expander.collapseAriaLabel": "Réduire",
24
+ "neptune.Expander.expandAriaLabel": "Développer",
23
25
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Entrez une devise/un pays",
24
26
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Sélectionnez une devise",
25
27
  "neptune.FlowNavigation.back": "revenir à l'étape précédente",
@@ -1 +1 @@
1
- {"version":3,"file":"fr.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"fr.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@ var fr = {
16
16
  "neptune.DateLookup.selected": "sélectionnée",
17
17
  "neptune.DateLookup.twentyYears": "20 ans",
18
18
  "neptune.DateLookup.year": "année",
19
+ "neptune.Expander.collapseAriaLabel": "Réduire",
20
+ "neptune.Expander.expandAriaLabel": "Développer",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Entrez une devise/un pays",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Sélectionnez une devise",
21
23
  "neptune.FlowNavigation.back": "revenir à l'étape précédente",
@@ -1 +1 @@
1
- {"version":3,"file":"fr.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"fr.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -16,6 +16,8 @@
16
16
  "neptune.DateLookup.selected": "kiválasztva",
17
17
  "neptune.DateLookup.twentyYears": "20 év",
18
18
  "neptune.DateLookup.year": "év",
19
+ "neptune.Expander.collapseAriaLabel": "Rövidebben",
20
+ "neptune.Expander.expandAriaLabel": "Több",
19
21
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Írj be egy pénznemet/országot",
20
22
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Pénznem kiválasztása",
21
23
  "neptune.FlowNavigation.back": "vissza az előző lépéshez",
@@ -20,6 +20,8 @@ var hu = {
20
20
  "neptune.DateLookup.selected": "kiválasztva",
21
21
  "neptune.DateLookup.twentyYears": "20 év",
22
22
  "neptune.DateLookup.year": "év",
23
+ "neptune.Expander.collapseAriaLabel": "Rövidebben",
24
+ "neptune.Expander.expandAriaLabel": "Több",
23
25
  "neptune.ExpressiveMoneyInput.currency.search.placeholder": "Írj be egy pénznemet/országot",
24
26
  "neptune.ExpressiveMoneyInput.currency.select.currency": "Pénznem kiválasztása",
25
27
  "neptune.FlowNavigation.back": "vissza az előző lépéshez",
@@ -1 +1 @@
1
- {"version":3,"file":"hu.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"hu.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}