@transferwise/components 0.0.0-experimental-4c97d70 → 0.0.0-experimental-862fadc

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 (450) hide show
  1. package/build/accordion/AccordionItem/AccordionItem.js +1 -0
  2. package/build/accordion/AccordionItem/AccordionItem.js.map +1 -1
  3. package/build/accordion/AccordionItem/AccordionItem.mjs +1 -0
  4. package/build/accordion/AccordionItem/AccordionItem.mjs.map +1 -1
  5. package/build/actionButton/ActionButton.js +1 -0
  6. package/build/actionButton/ActionButton.js.map +1 -1
  7. package/build/actionButton/ActionButton.mjs +1 -0
  8. package/build/actionButton/ActionButton.mjs.map +1 -1
  9. package/build/actionOption/ActionOption.js +1 -0
  10. package/build/actionOption/ActionOption.js.map +1 -1
  11. package/build/actionOption/ActionOption.mjs +1 -0
  12. package/build/actionOption/ActionOption.mjs.map +1 -1
  13. package/build/alert/Alert.js +1 -0
  14. package/build/alert/Alert.js.map +1 -1
  15. package/build/alert/Alert.mjs +1 -0
  16. package/build/alert/Alert.mjs.map +1 -1
  17. package/build/alert/inlineMarkdown/InlineMarkdown.js +1 -0
  18. package/build/alert/inlineMarkdown/InlineMarkdown.js.map +1 -1
  19. package/build/alert/inlineMarkdown/InlineMarkdown.mjs +1 -0
  20. package/build/alert/inlineMarkdown/InlineMarkdown.mjs.map +1 -1
  21. package/build/avatar/Avatar.js +1 -0
  22. package/build/avatar/Avatar.js.map +1 -1
  23. package/build/avatar/Avatar.mjs +1 -0
  24. package/build/avatar/Avatar.mjs.map +1 -1
  25. package/build/avatarView/AvatarView.js +1 -0
  26. package/build/avatarView/AvatarView.js.map +1 -1
  27. package/build/avatarView/AvatarView.mjs +1 -0
  28. package/build/avatarView/AvatarView.mjs.map +1 -1
  29. package/build/avatarWrapper/AvatarWrapper.js +1 -0
  30. package/build/avatarWrapper/AvatarWrapper.js.map +1 -1
  31. package/build/avatarWrapper/AvatarWrapper.mjs +1 -0
  32. package/build/avatarWrapper/AvatarWrapper.mjs.map +1 -1
  33. package/build/badge/Badge.js +1 -0
  34. package/build/badge/Badge.js.map +1 -1
  35. package/build/badge/Badge.mjs +1 -0
  36. package/build/badge/Badge.mjs.map +1 -1
  37. package/build/badge/BadgeAssets.js +2 -1
  38. package/build/badge/BadgeAssets.js.map +1 -1
  39. package/build/badge/BadgeAssets.mjs +2 -1
  40. package/build/badge/BadgeAssets.mjs.map +1 -1
  41. package/build/button/Button.js +1 -0
  42. package/build/button/Button.js.map +1 -1
  43. package/build/button/Button.mjs +1 -0
  44. package/build/button/Button.mjs.map +1 -1
  45. package/build/button/LegacyButton.js +1 -0
  46. package/build/button/LegacyButton.js.map +1 -1
  47. package/build/button/LegacyButton.mjs +1 -0
  48. package/build/button/LegacyButton.mjs.map +1 -1
  49. package/build/button/classMap.js +1 -0
  50. package/build/button/classMap.js.map +1 -1
  51. package/build/button/classMap.mjs +1 -0
  52. package/build/button/classMap.mjs.map +1 -1
  53. package/build/button/legacyUtils/legacyUtils.js +1 -0
  54. package/build/button/legacyUtils/legacyUtils.js.map +1 -1
  55. package/build/button/legacyUtils/legacyUtils.mjs +1 -0
  56. package/build/button/legacyUtils/legacyUtils.mjs.map +1 -1
  57. package/build/card/Card.js +1 -0
  58. package/build/card/Card.js.map +1 -1
  59. package/build/card/Card.mjs +1 -0
  60. package/build/card/Card.mjs.map +1 -1
  61. package/build/checkbox/Checkbox.js +1 -0
  62. package/build/checkbox/Checkbox.js.map +1 -1
  63. package/build/checkbox/Checkbox.mjs +1 -0
  64. package/build/checkbox/Checkbox.mjs.map +1 -1
  65. package/build/chevron/Chevron.js +1 -0
  66. package/build/chevron/Chevron.js.map +1 -1
  67. package/build/chevron/Chevron.mjs +1 -0
  68. package/build/chevron/Chevron.mjs.map +1 -1
  69. package/build/chips/Chip.js +1 -0
  70. package/build/chips/Chip.js.map +1 -1
  71. package/build/chips/Chip.mjs +1 -0
  72. package/build/chips/Chip.mjs.map +1 -1
  73. package/build/circularButton/CircularButton.js +1 -0
  74. package/build/circularButton/CircularButton.js.map +1 -1
  75. package/build/circularButton/CircularButton.mjs +1 -0
  76. package/build/circularButton/CircularButton.mjs.map +1 -1
  77. package/build/common/locale/index.js +9 -4
  78. package/build/common/locale/index.js.map +1 -1
  79. package/build/common/locale/index.mjs +9 -4
  80. package/build/common/locale/index.mjs.map +1 -1
  81. package/build/common/panel/Panel.js +50 -54
  82. package/build/common/panel/Panel.js.map +1 -1
  83. package/build/common/panel/Panel.mjs +55 -59
  84. package/build/common/panel/Panel.mjs.map +1 -1
  85. package/build/common/responsivePanel/ResponsivePanel.js +1 -0
  86. package/build/common/responsivePanel/ResponsivePanel.js.map +1 -1
  87. package/build/common/responsivePanel/ResponsivePanel.mjs +1 -0
  88. package/build/common/responsivePanel/ResponsivePanel.mjs.map +1 -1
  89. package/build/criticalBanner/CriticalCommsBanner.js +1 -0
  90. package/build/criticalBanner/CriticalCommsBanner.js.map +1 -1
  91. package/build/criticalBanner/CriticalCommsBanner.mjs +1 -0
  92. package/build/criticalBanner/CriticalCommsBanner.mjs.map +1 -1
  93. package/build/dateInput/DateInput.js +1 -1
  94. package/build/dateInput/DateInput.mjs +1 -1
  95. package/build/dateLookup/DateLookup.js +1 -1
  96. package/build/dateLookup/DateLookup.mjs +1 -1
  97. package/build/dateLookup/dateHeader/DateHeader.js +1 -0
  98. package/build/dateLookup/dateHeader/DateHeader.js.map +1 -1
  99. package/build/dateLookup/dateHeader/DateHeader.mjs +1 -0
  100. package/build/dateLookup/dateHeader/DateHeader.mjs.map +1 -1
  101. package/build/decision/Decision.js +1 -0
  102. package/build/decision/Decision.js.map +1 -1
  103. package/build/decision/Decision.mjs +1 -0
  104. package/build/decision/Decision.mjs.map +1 -1
  105. package/build/definitionList/DefinitionList.js +1 -0
  106. package/build/definitionList/DefinitionList.js.map +1 -1
  107. package/build/definitionList/DefinitionList.mjs +1 -0
  108. package/build/definitionList/DefinitionList.mjs.map +1 -1
  109. package/build/dimmer/Dimmer.js +1 -0
  110. package/build/dimmer/Dimmer.js.map +1 -1
  111. package/build/dimmer/Dimmer.mjs +1 -0
  112. package/build/dimmer/Dimmer.mjs.map +1 -1
  113. package/build/display/Display.js +1 -0
  114. package/build/display/Display.js.map +1 -1
  115. package/build/display/Display.mjs +1 -0
  116. package/build/display/Display.mjs.map +1 -1
  117. package/build/drawer/Drawer.js +1 -0
  118. package/build/drawer/Drawer.js.map +1 -1
  119. package/build/drawer/Drawer.mjs +1 -0
  120. package/build/drawer/Drawer.mjs.map +1 -1
  121. package/build/expressiveMoneyInput/currencySelector/CurrencySelector.js +4 -3
  122. package/build/expressiveMoneyInput/currencySelector/CurrencySelector.js.map +1 -1
  123. package/build/expressiveMoneyInput/currencySelector/CurrencySelector.mjs +4 -3
  124. package/build/expressiveMoneyInput/currencySelector/CurrencySelector.mjs.map +1 -1
  125. package/build/field/Field.js +5 -5
  126. package/build/field/Field.mjs +5 -5
  127. package/build/flowNavigation/FlowNavigation.js +1 -0
  128. package/build/flowNavigation/FlowNavigation.js.map +1 -1
  129. package/build/flowNavigation/FlowNavigation.mjs +1 -0
  130. package/build/flowNavigation/FlowNavigation.mjs.map +1 -1
  131. package/build/header/Header.js +1 -0
  132. package/build/header/Header.js.map +1 -1
  133. package/build/header/Header.mjs +1 -0
  134. package/build/header/Header.mjs.map +1 -1
  135. package/build/i18n/en.json +0 -2
  136. package/build/i18n/en.json.js +0 -2
  137. package/build/i18n/en.json.js.map +1 -1
  138. package/build/i18n/en.json.mjs +0 -2
  139. package/build/i18n/en.json.mjs.map +1 -1
  140. package/build/index.js +0 -2
  141. package/build/index.js.map +1 -1
  142. package/build/index.mjs +0 -1
  143. package/build/index.mjs.map +1 -1
  144. package/build/info/Info.js +1 -0
  145. package/build/info/Info.js.map +1 -1
  146. package/build/info/Info.mjs +1 -0
  147. package/build/info/Info.mjs.map +1 -1
  148. package/build/inlineAlert/InlineAlert.js +1 -0
  149. package/build/inlineAlert/InlineAlert.js.map +1 -1
  150. package/build/inlineAlert/InlineAlert.mjs +1 -0
  151. package/build/inlineAlert/InlineAlert.mjs.map +1 -1
  152. package/build/inputs/SearchInput.js +1 -0
  153. package/build/inputs/SearchInput.js.map +1 -1
  154. package/build/inputs/SearchInput.mjs +1 -0
  155. package/build/inputs/SearchInput.mjs.map +1 -1
  156. package/build/instructionsList/InstructionsList.js +1 -0
  157. package/build/instructionsList/InstructionsList.js.map +1 -1
  158. package/build/instructionsList/InstructionsList.mjs +1 -0
  159. package/build/instructionsList/InstructionsList.mjs.map +1 -1
  160. package/build/link/Link.js +1 -0
  161. package/build/link/Link.js.map +1 -1
  162. package/build/link/Link.mjs +1 -0
  163. package/build/link/Link.mjs.map +1 -1
  164. package/build/listItem/AdditionalInfo/ListItemAdditionalInfo.js +1 -0
  165. package/build/listItem/AdditionalInfo/ListItemAdditionalInfo.js.map +1 -1
  166. package/build/listItem/AdditionalInfo/ListItemAdditionalInfo.mjs +1 -0
  167. package/build/listItem/AdditionalInfo/ListItemAdditionalInfo.mjs.map +1 -1
  168. package/build/listItem/ListItem.js +1 -0
  169. package/build/listItem/ListItem.js.map +1 -1
  170. package/build/listItem/ListItem.mjs +1 -0
  171. package/build/listItem/ListItem.mjs.map +1 -1
  172. package/build/listItem/Prompt/ListItemPrompt.js +5 -5
  173. package/build/listItem/Prompt/ListItemPrompt.mjs +5 -5
  174. package/build/loader/Loader.js +1 -0
  175. package/build/loader/Loader.js.map +1 -1
  176. package/build/loader/Loader.mjs +1 -0
  177. package/build/loader/Loader.mjs.map +1 -1
  178. package/build/main.css +66 -133
  179. package/build/markdown/Markdown.js +1 -0
  180. package/build/markdown/Markdown.js.map +1 -1
  181. package/build/markdown/Markdown.mjs +1 -0
  182. package/build/markdown/Markdown.mjs.map +1 -1
  183. package/build/modal/Modal.js +1 -0
  184. package/build/modal/Modal.js.map +1 -1
  185. package/build/modal/Modal.mjs +1 -0
  186. package/build/modal/Modal.mjs.map +1 -1
  187. package/build/moneyInput/MoneyInput.js +28 -12
  188. package/build/moneyInput/MoneyInput.js.map +1 -1
  189. package/build/moneyInput/MoneyInput.mjs +30 -14
  190. package/build/moneyInput/MoneyInput.mjs.map +1 -1
  191. package/build/moneyInput/currencyFormatting.js +8 -2
  192. package/build/moneyInput/currencyFormatting.js.map +1 -1
  193. package/build/moneyInput/currencyFormatting.mjs +5 -4
  194. package/build/moneyInput/currencyFormatting.mjs.map +1 -1
  195. package/build/navigationOption/NavigationOption.js +1 -0
  196. package/build/navigationOption/NavigationOption.js.map +1 -1
  197. package/build/navigationOption/NavigationOption.mjs +1 -0
  198. package/build/navigationOption/NavigationOption.mjs.map +1 -1
  199. package/build/nudge/Nudge.js +1 -0
  200. package/build/nudge/Nudge.js.map +1 -1
  201. package/build/nudge/Nudge.mjs +1 -0
  202. package/build/nudge/Nudge.mjs.map +1 -1
  203. package/build/overlayHeader/OverlayHeader.js +1 -0
  204. package/build/overlayHeader/OverlayHeader.js.map +1 -1
  205. package/build/overlayHeader/OverlayHeader.mjs +1 -0
  206. package/build/overlayHeader/OverlayHeader.mjs.map +1 -1
  207. package/build/phoneNumberInput/PhoneNumberInput.js +1 -0
  208. package/build/phoneNumberInput/PhoneNumberInput.js.map +1 -1
  209. package/build/phoneNumberInput/PhoneNumberInput.mjs +1 -0
  210. package/build/phoneNumberInput/PhoneNumberInput.mjs.map +1 -1
  211. package/build/popover/Popover.js +1 -0
  212. package/build/popover/Popover.js.map +1 -1
  213. package/build/popover/Popover.mjs +1 -0
  214. package/build/popover/Popover.mjs.map +1 -1
  215. package/build/processIndicator/ProcessIndicator.js +1 -0
  216. package/build/processIndicator/ProcessIndicator.js.map +1 -1
  217. package/build/processIndicator/ProcessIndicator.mjs +1 -0
  218. package/build/processIndicator/ProcessIndicator.mjs.map +1 -1
  219. package/build/progressBar/ProgressBar.js +1 -0
  220. package/build/progressBar/ProgressBar.js.map +1 -1
  221. package/build/progressBar/ProgressBar.mjs +1 -0
  222. package/build/progressBar/ProgressBar.mjs.map +1 -1
  223. package/build/promoCard/PromoCard.js +1 -0
  224. package/build/promoCard/PromoCard.js.map +1 -1
  225. package/build/promoCard/PromoCard.mjs +1 -0
  226. package/build/promoCard/PromoCard.mjs.map +1 -1
  227. package/build/promoCard/PromoCardIndicator.js +1 -0
  228. package/build/promoCard/PromoCardIndicator.js.map +1 -1
  229. package/build/promoCard/PromoCardIndicator.mjs +1 -0
  230. package/build/promoCard/PromoCardIndicator.mjs.map +1 -1
  231. package/build/prompt/ActionPrompt/ActionPrompt.js +41 -8
  232. package/build/prompt/ActionPrompt/ActionPrompt.js.map +1 -1
  233. package/build/prompt/ActionPrompt/ActionPrompt.mjs +41 -8
  234. package/build/prompt/ActionPrompt/ActionPrompt.mjs.map +1 -1
  235. package/build/prompt/InfoPrompt/InfoPrompt.js +1 -0
  236. package/build/prompt/InfoPrompt/InfoPrompt.js.map +1 -1
  237. package/build/prompt/InfoPrompt/InfoPrompt.mjs +1 -0
  238. package/build/prompt/InfoPrompt/InfoPrompt.mjs.map +1 -1
  239. package/build/prompt/InlinePrompt/InlinePrompt.js +1 -0
  240. package/build/prompt/InlinePrompt/InlinePrompt.js.map +1 -1
  241. package/build/prompt/InlinePrompt/InlinePrompt.mjs +1 -0
  242. package/build/prompt/InlinePrompt/InlinePrompt.mjs.map +1 -1
  243. package/build/prompt/PrimitivePrompt/PrimitivePrompt.js +0 -2
  244. package/build/prompt/PrimitivePrompt/PrimitivePrompt.js.map +1 -1
  245. package/build/prompt/PrimitivePrompt/PrimitivePrompt.mjs +0 -2
  246. package/build/prompt/PrimitivePrompt/PrimitivePrompt.mjs.map +1 -1
  247. package/build/radio/Radio.js +1 -0
  248. package/build/radio/Radio.js.map +1 -1
  249. package/build/radio/Radio.mjs +1 -0
  250. package/build/radio/Radio.mjs.map +1 -1
  251. package/build/segmentedControl/SegmentedControl.js +1 -0
  252. package/build/segmentedControl/SegmentedControl.js.map +1 -1
  253. package/build/segmentedControl/SegmentedControl.mjs +1 -0
  254. package/build/segmentedControl/SegmentedControl.mjs.map +1 -1
  255. package/build/select/Select.js +2 -1
  256. package/build/select/Select.js.map +1 -1
  257. package/build/select/Select.mjs +2 -1
  258. package/build/select/Select.mjs.map +1 -1
  259. package/build/select/option/Option.js +1 -0
  260. package/build/select/option/Option.js.map +1 -1
  261. package/build/select/option/Option.mjs +1 -0
  262. package/build/select/option/Option.mjs.map +1 -1
  263. package/build/statusIcon/StatusIcon.js +1 -0
  264. package/build/statusIcon/StatusIcon.js.map +1 -1
  265. package/build/statusIcon/StatusIcon.mjs +1 -0
  266. package/build/statusIcon/StatusIcon.mjs.map +1 -1
  267. package/build/stepper/Stepper.js +1 -0
  268. package/build/stepper/Stepper.js.map +1 -1
  269. package/build/stepper/Stepper.mjs +1 -0
  270. package/build/stepper/Stepper.mjs.map +1 -1
  271. package/build/sticky/Sticky.js +1 -0
  272. package/build/sticky/Sticky.js.map +1 -1
  273. package/build/sticky/Sticky.mjs +1 -0
  274. package/build/sticky/Sticky.mjs.map +1 -1
  275. package/build/styles/css/neptune.css +33 -22
  276. package/build/styles/less/neptune-tokens.less +5 -4
  277. package/build/styles/main.css +66 -133
  278. package/build/styles/modal/Modal.css +2 -2
  279. package/build/styles/props/neptune-tokens.css +3 -2
  280. package/build/styles/select/Select.css +2 -1
  281. package/build/styles/styles/less/neptune.css +33 -22
  282. package/build/summary/Summary.js +1 -0
  283. package/build/summary/Summary.js.map +1 -1
  284. package/build/summary/Summary.mjs +1 -0
  285. package/build/summary/Summary.mjs.map +1 -1
  286. package/build/table/Table.js +1 -0
  287. package/build/table/Table.js.map +1 -1
  288. package/build/table/Table.mjs +1 -0
  289. package/build/table/Table.mjs.map +1 -1
  290. package/build/table/TableRow.js +1 -0
  291. package/build/table/TableRow.js.map +1 -1
  292. package/build/table/TableRow.mjs +1 -0
  293. package/build/table/TableRow.mjs.map +1 -1
  294. package/build/table/TableStatusText.js +1 -0
  295. package/build/table/TableStatusText.js.map +1 -1
  296. package/build/table/TableStatusText.mjs +1 -0
  297. package/build/table/TableStatusText.mjs.map +1 -1
  298. package/build/tabs/Tabs.js +1 -0
  299. package/build/tabs/Tabs.js.map +1 -1
  300. package/build/tabs/Tabs.mjs +1 -0
  301. package/build/tabs/Tabs.mjs.map +1 -1
  302. package/build/tile/Tile.js +1 -0
  303. package/build/tile/Tile.js.map +1 -1
  304. package/build/tile/Tile.mjs +1 -0
  305. package/build/tile/Tile.mjs.map +1 -1
  306. package/build/title/Title.js +1 -0
  307. package/build/title/Title.js.map +1 -1
  308. package/build/title/Title.mjs +1 -0
  309. package/build/title/Title.mjs.map +1 -1
  310. package/build/tooltip/Tooltip.js +30 -50
  311. package/build/tooltip/Tooltip.js.map +1 -1
  312. package/build/tooltip/Tooltip.mjs +31 -51
  313. package/build/tooltip/Tooltip.mjs.map +1 -1
  314. package/build/typeahead/Typeahead.js +5 -5
  315. package/build/typeahead/Typeahead.mjs +5 -5
  316. package/build/types/badge/BadgeAssets.d.ts.map +1 -1
  317. package/build/types/common/locale/index.d.ts +1 -1
  318. package/build/types/common/locale/index.d.ts.map +1 -1
  319. package/build/types/common/panel/Panel.d.ts.map +1 -1
  320. package/build/types/expressiveMoneyInput/currencySelector/CurrencySelector.d.ts.map +1 -1
  321. package/build/types/index.d.ts +2 -2
  322. package/build/types/index.d.ts.map +1 -1
  323. package/build/types/moneyInput/MoneyInput.d.ts +6 -0
  324. package/build/types/moneyInput/MoneyInput.d.ts.map +1 -1
  325. package/build/types/moneyInput/currencyFormatting.d.ts +4 -3
  326. package/build/types/moneyInput/currencyFormatting.d.ts.map +1 -1
  327. package/build/types/prompt/ActionPrompt/ActionPrompt.d.ts +11 -2
  328. package/build/types/prompt/ActionPrompt/ActionPrompt.d.ts.map +1 -1
  329. package/build/types/prompt/PrimitivePrompt/PrimitivePrompt.d.ts +3 -8
  330. package/build/types/prompt/PrimitivePrompt/PrimitivePrompt.d.ts.map +1 -1
  331. package/build/types/prompt/index.d.ts +0 -2
  332. package/build/types/prompt/index.d.ts.map +1 -1
  333. package/build/types/test-utils/index.d.ts +0 -4
  334. package/build/types/test-utils/index.d.ts.map +1 -1
  335. package/build/types/tooltip/Tooltip.d.ts.map +1 -1
  336. package/build/upload/Upload.js +1 -0
  337. package/build/upload/Upload.js.map +1 -1
  338. package/build/upload/Upload.mjs +1 -0
  339. package/build/upload/Upload.mjs.map +1 -1
  340. package/build/upload/steps/completeStep/completeStep.js +1 -0
  341. package/build/upload/steps/completeStep/completeStep.js.map +1 -1
  342. package/build/upload/steps/completeStep/completeStep.mjs +1 -0
  343. package/build/upload/steps/completeStep/completeStep.mjs.map +1 -1
  344. package/build/upload/steps/processingStep/processingStep.js +1 -0
  345. package/build/upload/steps/processingStep/processingStep.js.map +1 -1
  346. package/build/upload/steps/processingStep/processingStep.mjs +1 -0
  347. package/build/upload/steps/processingStep/processingStep.mjs.map +1 -1
  348. package/build/upload/steps/uploadImageStep/uploadImageStep.js +1 -0
  349. package/build/upload/steps/uploadImageStep/uploadImageStep.js.map +1 -1
  350. package/build/upload/steps/uploadImageStep/uploadImageStep.mjs +1 -0
  351. package/build/upload/steps/uploadImageStep/uploadImageStep.mjs.map +1 -1
  352. package/build/uploadInput/UploadInput.js +1 -0
  353. package/build/uploadInput/UploadInput.js.map +1 -1
  354. package/build/uploadInput/UploadInput.mjs +1 -0
  355. package/build/uploadInput/UploadInput.mjs.map +1 -1
  356. package/build/uploadInput/uploadButton/UploadButton.js +1 -0
  357. package/build/uploadInput/uploadButton/UploadButton.js.map +1 -1
  358. package/build/uploadInput/uploadButton/UploadButton.mjs +1 -0
  359. package/build/uploadInput/uploadButton/UploadButton.mjs.map +1 -1
  360. package/build/uploadInput/uploadButton/defaults.js +1 -0
  361. package/build/uploadInput/uploadButton/defaults.js.map +1 -1
  362. package/build/uploadInput/uploadButton/defaults.mjs +1 -0
  363. package/build/uploadInput/uploadButton/defaults.mjs.map +1 -1
  364. package/build/uploadInput/uploadItem/UploadItem.js +1 -0
  365. package/build/uploadInput/uploadItem/UploadItem.js.map +1 -1
  366. package/build/uploadInput/uploadItem/UploadItem.mjs +1 -0
  367. package/build/uploadInput/uploadItem/UploadItem.mjs.map +1 -1
  368. package/build/withDisplayFormat/WithDisplayFormat.js +1 -0
  369. package/build/withDisplayFormat/WithDisplayFormat.js.map +1 -1
  370. package/build/withDisplayFormat/WithDisplayFormat.mjs +1 -0
  371. package/build/withDisplayFormat/WithDisplayFormat.mjs.map +1 -1
  372. package/package.json +19 -21
  373. package/src/avatarView/AvatarView.story.tsx +1 -1
  374. package/src/avatarView/AvatarView.test.story.tsx +108 -1
  375. package/src/badge/BadgeAssets.tsx +2 -0
  376. package/src/common/locale/index.test.ts +13 -4
  377. package/src/common/locale/index.ts +9 -3
  378. package/src/common/panel/Panel.tsx +56 -49
  379. package/src/expressiveMoneyInput/ExpressiveMoneyInput.story.tsx +18 -0
  380. package/src/expressiveMoneyInput/currencySelector/CurrencySelector.test.tsx +119 -1
  381. package/src/expressiveMoneyInput/currencySelector/CurrencySelector.tsx +4 -3
  382. package/src/i18n/en.json +0 -2
  383. package/src/index.ts +2 -2
  384. package/src/main.css +66 -133
  385. package/src/main.less +1 -3
  386. package/src/modal/Modal.css +2 -2
  387. package/src/modal/Modal.less +1 -1
  388. package/src/moneyInput/MoneyInput.story.tsx +10 -1
  389. package/src/moneyInput/MoneyInput.test.story.tsx +141 -1
  390. package/src/moneyInput/MoneyInput.test.tsx +45 -0
  391. package/src/moneyInput/MoneyInput.tsx +27 -3
  392. package/src/moneyInput/currencyFormatting.ts +11 -5
  393. package/src/prompt/ActionPrompt/ActionPrompt.tsx +62 -9
  394. package/src/prompt/PrimitivePrompt/PrimitivePrompt.tsx +2 -9
  395. package/src/prompt/index.ts +0 -4
  396. package/src/select/Select.css +2 -1
  397. package/src/select/Select.less +6 -5
  398. package/src/select/Select.test.story.tsx +59 -0
  399. package/src/select/Select.tsx +1 -1
  400. package/src/sentimentSurface/SentimentSurface.story.tsx +17 -43
  401. package/src/styles/less/neptune.css +33 -22
  402. package/src/tooltip/Tooltip.tsx +26 -45
  403. package/build/prompt/CriticalBanner/CriticalBanner.js +0 -143
  404. package/build/prompt/CriticalBanner/CriticalBanner.js.map +0 -1
  405. package/build/prompt/CriticalBanner/CriticalBanner.mjs +0 -141
  406. package/build/prompt/CriticalBanner/CriticalBanner.mjs.map +0 -1
  407. package/build/prompt/CriticalBanner/helpers.js +0 -29
  408. package/build/prompt/CriticalBanner/helpers.js.map +0 -1
  409. package/build/prompt/CriticalBanner/helpers.mjs +0 -26
  410. package/build/prompt/CriticalBanner/helpers.mjs.map +0 -1
  411. package/build/prompt/common/Expander/Expander.js +0 -47
  412. package/build/prompt/common/Expander/Expander.js.map +0 -1
  413. package/build/prompt/common/Expander/Expander.messages.js +0 -17
  414. package/build/prompt/common/Expander/Expander.messages.js.map +0 -1
  415. package/build/prompt/common/Expander/Expander.messages.mjs +0 -13
  416. package/build/prompt/common/Expander/Expander.messages.mjs.map +0 -1
  417. package/build/prompt/common/Expander/Expander.mjs +0 -44
  418. package/build/prompt/common/Expander/Expander.mjs.map +0 -1
  419. package/build/prompt/helpers/promptMedia.js +0 -52
  420. package/build/prompt/helpers/promptMedia.js.map +0 -1
  421. package/build/prompt/helpers/promptMedia.mjs +0 -50
  422. package/build/prompt/helpers/promptMedia.mjs.map +0 -1
  423. package/build/styles/prompt/CriticalBanner/CriticalBanner.css +0 -59
  424. package/build/styles/prompt/common/Expander/Expander.css +0 -8
  425. package/build/types/prompt/CriticalBanner/CriticalBanner.d.ts +0 -33
  426. package/build/types/prompt/CriticalBanner/CriticalBanner.d.ts.map +0 -1
  427. package/build/types/prompt/CriticalBanner/helpers.d.ts +0 -18
  428. package/build/types/prompt/CriticalBanner/helpers.d.ts.map +0 -1
  429. package/build/types/prompt/CriticalBanner/index.d.ts +0 -3
  430. package/build/types/prompt/CriticalBanner/index.d.ts.map +0 -1
  431. package/build/types/prompt/common/Expander/Expander.d.ts +0 -20
  432. package/build/types/prompt/common/Expander/Expander.d.ts.map +0 -1
  433. package/build/types/prompt/common/Expander/Expander.messages.d.ts +0 -14
  434. package/build/types/prompt/common/Expander/Expander.messages.d.ts.map +0 -1
  435. package/build/types/prompt/helpers/promptMedia.d.ts +0 -22
  436. package/build/types/prompt/helpers/promptMedia.d.ts.map +0 -1
  437. package/src/prompt/CriticalBanner/CriticalBanner.accessibility.docs.mdx +0 -113
  438. package/src/prompt/CriticalBanner/CriticalBanner.css +0 -59
  439. package/src/prompt/CriticalBanner/CriticalBanner.less +0 -64
  440. package/src/prompt/CriticalBanner/CriticalBanner.story.tsx +0 -632
  441. package/src/prompt/CriticalBanner/CriticalBanner.test.story.tsx +0 -285
  442. package/src/prompt/CriticalBanner/CriticalBanner.tsx +0 -182
  443. package/src/prompt/CriticalBanner/helpers.ts +0 -39
  444. package/src/prompt/CriticalBanner/index.ts +0 -2
  445. package/src/prompt/common/Expander/Expander.css +0 -8
  446. package/src/prompt/common/Expander/Expander.less +0 -9
  447. package/src/prompt/common/Expander/Expander.messages.ts +0 -14
  448. package/src/prompt/common/Expander/Expander.test.tsx +0 -167
  449. package/src/prompt/common/Expander/Expander.tsx +0 -83
  450. package/src/prompt/helpers/promptMedia.tsx +0 -79
@@ -24,7 +24,7 @@ import {
24
24
  import Title from '../title';
25
25
 
26
26
  import messages from './MoneyInput.messages';
27
- import { formatAmount, parseAmount } from './currencyFormatting';
27
+ import { formatAmount, formatNumber, getCurrencyDecimals, parseAmount } from './currencyFormatting';
28
28
  import withId from '../withId';
29
29
 
30
30
  export interface CurrencyOptionItem {
@@ -48,24 +48,34 @@ const formatAmountIfSet = ({
48
48
  amount,
49
49
  currency,
50
50
  locale,
51
+ decimals,
51
52
  }: {
52
53
  amount: number | null | undefined;
53
54
  currency: string;
54
55
  locale: string;
56
+ decimals?: number;
55
57
  }) => {
56
- return typeof amount === 'number' ? formatAmount(amount, currency, locale) : '';
58
+ if (typeof amount !== 'number') {
59
+ return '';
60
+ }
61
+ if (decimals != null && getCurrencyDecimals(currency) !== 0) {
62
+ return formatNumber(amount, locale, decimals);
63
+ }
64
+ return formatAmount(amount, currency, locale);
57
65
  };
58
66
 
59
67
  const parseNumber = ({
60
68
  amount,
61
69
  currency,
62
70
  locale,
71
+ decimals,
63
72
  }: {
64
73
  amount: string;
65
74
  currency: string;
66
75
  locale: string;
76
+ decimals?: number;
67
77
  }) => {
68
- return parseAmount(amount, currency, locale);
78
+ return parseAmount(amount, currency, locale, decimals);
69
79
  };
70
80
 
71
81
  const allowedInputKeys = new Set([
@@ -102,6 +112,12 @@ export interface MoneyInputProps extends WrappedComponentProps {
102
112
  onCustomAction?: () => void;
103
113
  classNames?: Record<string, string>;
104
114
  selectProps?: Partial<SelectInputProps<CurrencyOptionItem>>;
115
+ /**
116
+ * Specify the number of decimal places to format the amount. When not specified, the number of
117
+ * decimals is determined by the selected currency (e.g. 2 for EUR, 0 for JPY, 3 for BHD).
118
+ * This override is ignored for zero-decimal currencies (e.g. JPY, KRW, HUF), which always use 0.
119
+ */
120
+ decimals?: number;
105
121
  }
106
122
 
107
123
  export type MoneyInputPropsWithInputAttributes = MoneyInputProps &
@@ -133,6 +149,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
133
149
  amount: props.amount,
134
150
  currency: props.selectedCurrency.currency,
135
151
  locale: props.intl.locale,
152
+ decimals: props.decimals,
136
153
  }),
137
154
  locale: props.intl.locale,
138
155
  };
@@ -147,6 +164,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
147
164
  amount: nextProps.amount,
148
165
  currency: nextProps.selectedCurrency.currency,
149
166
  locale: nextProps.intl.locale,
167
+ decimals: nextProps.decimals,
150
168
  }),
151
169
  });
152
170
  }
@@ -174,6 +192,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
174
192
  amount: paste,
175
193
  currency: this.props.selectedCurrency.currency,
176
194
  locale,
195
+ decimals: this.props.decimals,
177
196
  });
178
197
 
179
198
  if (isNumberOrNull(parsed)) {
@@ -182,6 +201,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
182
201
  amount: parsed,
183
202
  currency: this.props.selectedCurrency.currency,
184
203
  locale,
204
+ decimals: this.props.decimals,
185
205
  }),
186
206
  });
187
207
  this.props.onAmountChange?.(parsed);
@@ -201,6 +221,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
201
221
  amount: value,
202
222
  currency: this.props.selectedCurrency.currency,
203
223
  locale: this.state.locale,
224
+ decimals: this.props.decimals,
204
225
  });
205
226
  if (isNumberOrNull(parsed)) {
206
227
  this.props.onAmountChange?.(parsed);
@@ -248,6 +269,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
248
269
  amount: previousState.formattedAmount,
249
270
  currency: this.props.selectedCurrency.currency,
250
271
  locale: previousState.locale,
272
+ decimals: this.props.decimals,
251
273
  });
252
274
  if (!isNumberOrNull(parsed)) {
253
275
  return {
@@ -259,6 +281,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
259
281
  amount: parsed,
260
282
  currency: this.props.selectedCurrency.currency,
261
283
  locale: previousState.locale,
284
+ decimals: this.props.decimals,
262
285
  }),
263
286
  };
264
287
  });
@@ -340,6 +363,7 @@ class MoneyInput extends Component<MoneyInputPropsWithInputAttributes, MoneyInpu
340
363
  amount: this.props.placeholder,
341
364
  currency: this.props.selectedCurrency.currency,
342
365
  locale: this.state.locale,
366
+ decimals: this.props.decimals,
343
367
  })}
344
368
  autoComplete="off"
345
369
  aria-describedby={selectedCurrencyElementId}
@@ -1,8 +1,8 @@
1
- import { formatAmount } from '@transferwise/formatting';
1
+ import { formatAmount, formatNumber } from '@transferwise/formatting';
2
2
 
3
3
  import { DEFAULT_LOCALE } from '../common/locale';
4
4
 
5
- export { formatAmount };
5
+ export { formatAmount, formatNumber };
6
6
 
7
7
  // TODO: do not duplicate this between formatting and components
8
8
  const currencyDecimals: Record<string, number> = {
@@ -52,7 +52,7 @@ function getValidLocale(locale: string) {
52
52
  }
53
53
  }
54
54
 
55
- function getCurrencyDecimals(currency: string) {
55
+ export function getCurrencyDecimals(currency: string) {
56
56
  const upperCaseCurrency = currency.toUpperCase();
57
57
  return currencyDecimals[upperCaseCurrency] ?? DEFAULT_CURRENCY_DECIMALS;
58
58
  }
@@ -61,10 +61,16 @@ function getDecimalSeparator(locale: string) {
61
61
  return isNumberLocaleSupported() ? (1.1).toLocaleString(locale)[1] : '.';
62
62
  }
63
63
 
64
- export function parseAmount(number: string, currency: string, locale = DEFAULT_LOCALE) {
64
+ export function parseAmount(
65
+ number: string,
66
+ currency: string,
67
+ locale = DEFAULT_LOCALE,
68
+ decimals?: number,
69
+ ) {
65
70
  const validLocale = getValidLocale(locale);
66
71
 
67
- const precision = getCurrencyDecimals(currency);
72
+ const currencyDefault = getCurrencyDecimals(currency);
73
+ const precision = currencyDefault === 0 ? 0 : (decimals ?? currencyDefault);
68
74
  const groupSeparator = isNumberLocaleSupported() ? (10000).toLocaleString(validLocale)[2] : ',';
69
75
  const decimalSeparator = getDecimalSeparator(validLocale);
70
76
  const numberWithStandardDecimalSeparator = (number || '')
@@ -1,19 +1,31 @@
1
1
  import { AriaAttributes, ReactNode, useId } from 'react';
2
2
  import { clsx } from 'clsx';
3
3
 
4
+ import StatusIcon from '../../statusIcon';
4
5
  import Body from '../../body';
5
6
  import Button from '../../button';
6
7
  import { Breakpoint, Typography } from '../../common';
8
+ import AvatarView, { AvatarViewProps } from '../../avatarView';
9
+ import Image from '../../image';
7
10
  import { ButtonProps } from '../../button/Button.types';
8
11
  import { PrimitivePrompt, PrimitivePromptProps } from '../PrimitivePrompt';
12
+ import { BadgeAssetsProps } from '../../badge';
13
+ import { GiftBox } from '@transferwise/icons';
9
14
  import { useScreenSize } from '../../common/hooks/useScreenSize';
10
- import { renderPromptMedia, PromptMedia } from '../helpers/promptMedia';
11
15
 
12
16
  export type ActionPromptProps = {
13
17
  title: ReactNode;
14
18
  description?: ReactNode;
15
19
  /** @default {} */
16
- media?: PromptMedia;
20
+ media?: {
21
+ imgSrc?: string;
22
+ avatar?: Pick<AvatarViewProps, 'imgSrc' | 'profileName' | 'profileType'> & {
23
+ asset?: AvatarViewProps['children'];
24
+ badge?: Pick<BadgeAssetsProps, 'flagCode'>;
25
+ };
26
+ 'aria-label'?: string;
27
+ 'aria-hidden'?: boolean;
28
+ };
17
29
  action: Pick<ButtonProps, 'onClick' | 'href' | 'target'> & {
18
30
  label: ButtonProps['children'];
19
31
  };
@@ -62,13 +74,54 @@ export const ActionPrompt = ({
62
74
  .filter(Boolean)
63
75
  .join(' ');
64
76
 
65
- const renderMedia = () =>
66
- renderPromptMedia({
67
- media,
68
- sentiment,
69
- mediaId,
70
- imgClassName: 'wds-action-prompt--media-image',
71
- });
77
+ const renderMedia = () => {
78
+ if (media?.imgSrc) {
79
+ return (
80
+ <Image
81
+ id={mediaId}
82
+ src={media.imgSrc}
83
+ className="wds-action-prompt--media-image"
84
+ alt={media['aria-label'] ?? ''}
85
+ />
86
+ );
87
+ }
88
+ if (media?.avatar) {
89
+ const badge = media.avatar.badge
90
+ ? media.avatar.badge
91
+ : sentiment === 'proposition'
92
+ ? {}
93
+ : { status: sentiment };
94
+ return (
95
+ <AvatarView
96
+ {...media.avatar}
97
+ badge={badge}
98
+ aria-label={media['aria-label']}
99
+ aria-hidden={media['aria-hidden']}
100
+ id={mediaId}
101
+ size={48}
102
+ >
103
+ {media.avatar.asset}
104
+ </AvatarView>
105
+ );
106
+ }
107
+ return sentiment === 'proposition' ? (
108
+ <AvatarView
109
+ id={mediaId}
110
+ size={48}
111
+ aria-label={media['aria-label']}
112
+ aria-hidden={media['aria-hidden']}
113
+ >
114
+ <GiftBox />
115
+ </AvatarView>
116
+ ) : (
117
+ <StatusIcon
118
+ id={mediaId}
119
+ size={48}
120
+ sentiment={sentiment}
121
+ iconLabel={media['aria-hidden'] ? null : media['aria-label']}
122
+ />
123
+ );
124
+ };
72
125
 
73
126
  return (
74
127
  <PrimitivePrompt
@@ -1,6 +1,6 @@
1
1
  import { Cross } from '@transferwise/icons';
2
2
  import { clsx } from 'clsx';
3
- import SentimentSurface, { Emphasis, Sentiment } from '../../sentimentSurface';
3
+ import SentimentSurface, { Sentiment } from '../../sentimentSurface';
4
4
  import IconButton from '../../iconButton';
5
5
  import { useIntl } from 'react-intl';
6
6
  import closeBtnMessages from '../../common/closeButton/CloseButton.messages';
@@ -8,15 +8,10 @@ import { HTMLAttributes, ReactNode } from 'react';
8
8
 
9
9
  export type PrimitivePromptProps = HTMLAttributes<HTMLDivElement> & {
10
10
  /**
11
- * The sentiment determines the colour scheme.
11
+ * The sentiment determines the colour scheme
12
12
  * @default success
13
13
  */
14
14
  sentiment?: Sentiment;
15
- /**
16
- * The emphasis level affecting background and text contrast.
17
- * @default 'base
18
- */
19
- emphasis?: Emphasis;
20
15
  /**
21
16
  * Media to be displayed on the prompt (icon/image/etc).
22
17
  */
@@ -40,7 +35,6 @@ export type PrimitivePromptProps = HTMLAttributes<HTMLDivElement> & {
40
35
  * Uses several css variables to handle styling from within the consuming component, e.g. --Prompt-padding. */
41
36
  export const PrimitivePrompt = ({
42
37
  sentiment = 'success',
43
- emphasis = 'base',
44
38
  media,
45
39
  actions,
46
40
  onDismiss,
@@ -53,7 +47,6 @@ export const PrimitivePrompt = ({
53
47
  return (
54
48
  <SentimentSurface
55
49
  sentiment={sentiment}
56
- emphasis={emphasis}
57
50
  className={clsx('wds-prompt', `wds-prompt--${sentiment}`, className)}
58
51
  {...restProps}
59
52
  >
@@ -12,7 +12,3 @@ export { ActionPrompt } from './ActionPrompt';
12
12
  // InfoPrompt
13
13
  export type { InfoPromptProps, InfoPromptAction, InfoPromptMedia } from './InfoPrompt';
14
14
  export { InfoPrompt } from './InfoPrompt';
15
-
16
- // CriticalBanner
17
- export type { CriticalBannerProps } from './CriticalBanner';
18
- export { CriticalBanner } from './CriticalBanner';
@@ -123,14 +123,15 @@
123
123
  max-width: calc(100% - 32px);
124
124
  }
125
125
  .np-dropdown-menu-desktop {
126
- max-height: 70vh;
127
126
  max-height: 70svh;
127
+ max-height: var(--np-panel-available-height, 70svh);
128
128
  min-width: 160px;
129
129
  max-width: calc(100vw - 32px);
130
130
  }
131
131
  @media (min-height: 592px) {
132
132
  .np-dropdown-menu-desktop {
133
133
  max-height: 592px;
134
+ max-height: var(--np-panel-available-height, 592px);
134
135
  }
135
136
  }
136
137
  .np-dropdown-menu {
@@ -81,7 +81,7 @@
81
81
 
82
82
  // Override some of Button component styles
83
83
  .btn {
84
- &:not(.disabled,:disabled,.btn-loading) {
84
+ &:not(.disabled, :disabled, .btn-loading) {
85
85
  color: var(--color-content-primary);
86
86
 
87
87
  &:hover {
@@ -108,15 +108,14 @@
108
108
  }
109
109
 
110
110
  .np-dropdown-menu-desktop {
111
- max-height: 70vh;
112
- max-height: 70svh;
111
+ max-height: var(--np-panel-available-height, 70svh);
113
112
  min-width: 160px;
114
113
  max-width: ~"calc(100vw - 32px)";
115
114
  }
116
115
 
117
116
  @media (min-height: 592px) {
118
117
  .np-dropdown-menu-desktop {
119
- max-height: 592px;
118
+ max-height: var(--np-panel-available-height, 592px);
120
119
  }
121
120
  }
122
121
 
@@ -270,7 +269,9 @@
270
269
  /* stylelint-disable-next-line no-duplicate-selectors */
271
270
  .np-select .np-dropdown-toggle {
272
271
  background-color: unset;
273
- transition: background-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
272
+ transition:
273
+ background-color 0.3s ease-in-out,
274
+ box-shadow 0.3s ease-in-out;
274
275
  border: none;
275
276
  box-shadow: inset 0 0 0 1px var(--color-interactive-secondary);
276
277
 
@@ -0,0 +1,59 @@
1
+ import type { Meta, StoryObj } from '@storybook/react-webpack5';
2
+ import { userEvent, within } from 'storybook/test';
3
+ import { useState } from 'react';
4
+
5
+ import { withVariantConfig } from '../../.storybook/helpers';
6
+ import Select, { SelectOptionItem } from './Select';
7
+
8
+ const meta = {
9
+ title: 'Forms/Select/Tests',
10
+ component: Select,
11
+ tags: ['!autodocs', '!manifest'],
12
+ } satisfies Meta<typeof Select>;
13
+ export default meta;
14
+
15
+ type Story = StoryObj<typeof Select>;
16
+
17
+ const options: SelectOptionItem[] = Array.from({ length: 10 }, (_, i) => ({
18
+ value: i + 1,
19
+ label: `Option ${i + 1}`,
20
+ }));
21
+
22
+ /**
23
+ * Visual regression story: Select placed at the bottom of the viewport so the dropdown
24
+ * flips to the top when opened. The play function opens the dropdown automatically.
25
+ */
26
+ export const DropdownFlipsToTop: Story = {
27
+ render: function Render() {
28
+ const [selected, setSelected] = useState<SelectOptionItem>(options[0]);
29
+ return (
30
+ <div
31
+ style={{
32
+ display: 'flex',
33
+ flexDirection: 'column',
34
+ justifyContent: 'flex-end',
35
+ minHeight: '50vh',
36
+ }}
37
+ >
38
+ <Select
39
+ id="flip-test-select"
40
+ size="md"
41
+ block
42
+ options={options}
43
+ selected={selected}
44
+ onChange={(option) => {
45
+ if (option && 'value' in option) {
46
+ setSelected(option as SelectOptionItem);
47
+ }
48
+ }}
49
+ />
50
+ </div>
51
+ );
52
+ },
53
+ play: async ({ canvasElement }) => {
54
+ const canvas = within(canvasElement);
55
+ const trigger = canvas.getByRole('button', { name: /Option 1/i });
56
+ await userEvent.click(trigger);
57
+ },
58
+ ...withVariantConfig(['default']),
59
+ };
@@ -608,8 +608,8 @@ export default function Select({
608
608
  ) : (
609
609
  <Panel
610
610
  open={open}
611
- flip={false}
612
611
  altAxis
612
+ considerHeight
613
613
  anchorRef={selectReference}
614
614
  anchorWidth={isDropdownAutoWidth}
615
615
  position={dropdownUp ? Position.TOP : Position.BOTTOM}
@@ -202,26 +202,18 @@ const TokenSwatch = ({ token }: { token: string }) => (
202
202
  export const EmphasisLevels: Story = {
203
203
  render: (args) => (
204
204
  <>
205
- {sentiments.map((sentiment) => (
206
- <div key={sentiment}>
207
- <SentimentSurface
208
- key={`${sentiment}-base`}
209
- {...args}
210
- sentiment={sentiment}
211
- emphasis="base"
212
- >
213
- <div className="p-a-2 text-capitalize">{sentiment} - Base emphasis</div>
214
- </SentimentSurface>
215
- <SentimentSurface
216
- key={`${sentiment}-elevated`}
217
- {...args}
218
- sentiment={sentiment}
219
- emphasis="elevated"
220
- >
221
- <div className="p-a-2 text-capitalize">{sentiment} - Elevated emphasis</div>
222
- </SentimentSurface>
223
- </div>
224
- ))}
205
+ <SentimentSurface {...args} sentiment="negative" emphasis="base">
206
+ <div className="p-a-2">Negative - Base emphasis</div>
207
+ </SentimentSurface>
208
+ <SentimentSurface {...args} sentiment="negative" emphasis="elevated">
209
+ <div className="p-a-2">Negative - Elevated emphasis</div>
210
+ </SentimentSurface>
211
+ <SentimentSurface {...args} sentiment="success" emphasis="base">
212
+ <div className="p-a-2">Success - Base emphasis</div>
213
+ </SentimentSurface>
214
+ <SentimentSurface {...args} sentiment="success" emphasis="elevated">
215
+ <div className="p-a-2">Success - Elevated emphasis</div>
216
+ </SentimentSurface>
225
217
  </>
226
218
  ),
227
219
  parameters: {
@@ -377,8 +369,8 @@ export const SentimentAwareComponents: Story = {
377
369
  {STATUS_NEGATIVE}
378
370
  </div>
379
371
 
380
- <Header level="group" title="Success sentiment surface - Base emphasis" />
381
- <SentimentSurface sentiment="success" emphasis="base">
372
+ <Header level="group" title="Success sentiment surface" />
373
+ <SentimentSurface sentiment="success">
382
374
  <div className="p-a-2 m-b-2 sentimentAwareComponent">
383
375
  {BODY}
384
376
  {AVATAR_SUCCESS}
@@ -386,26 +378,8 @@ export const SentimentAwareComponents: Story = {
386
378
  </div>
387
379
  </SentimentSurface>
388
380
 
389
- <Header level="group" title="Success sentiment surface - Elevated emphasis" />
390
- <SentimentSurface sentiment="success" emphasis="elevated">
391
- <div className="p-a-2 m-b-2 sentimentAwareComponent">
392
- {BODY}
393
- {AVATAR_SUCCESS}
394
- {STATUS_SUCCESS}
395
- </div>
396
- </SentimentSurface>
397
-
398
- <Header level="group" title="Negative sentiment surface - Base emphasis" />
399
- <SentimentSurface sentiment="negative" emphasis="base">
400
- <div className="p-a-2 m-b-2 sentimentAwareComponent">
401
- {BODY}
402
- {AVATAR_NEGATIVE}
403
- {STATUS_NEGATIVE}
404
- </div>
405
- </SentimentSurface>
406
-
407
- <Header level="group" title="Negative sentiment surface - Elevated emphasis" />
408
- <SentimentSurface sentiment="negative" emphasis="elevated">
381
+ <Header level="group" title="Negative sentiment surface" />
382
+ <SentimentSurface sentiment="negative">
409
383
  <div className="p-a-2 m-b-2 sentimentAwareComponent">
410
384
  {BODY}
411
385
  {AVATAR_NEGATIVE}
@@ -453,7 +427,7 @@ function CustomCard({ children, className }: { className?: string; children: Rea
453
427
 
454
428
  export const CustomComponents: Story = {
455
429
  tags: ['!autodocs', '!dev'],
456
- render: () => (
430
+ render: (args) => (
457
431
  <>
458
432
  <style>{`
459
433
  .custom-card {