@transferwise/components 0.0.0-experimental-991400c → 0.0.0-experimental-fb447f5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/build/index.js CHANGED
@@ -1167,12 +1167,6 @@ const Alert = props => {
1167
1167
  });
1168
1168
  }
1169
1169
  }
1170
- function calculateAriaLive() {
1171
- if ([exports.Sentiment.NEGATIVE, exports.Sentiment.POSITIVE, exports.Sentiment.WARNING].includes(mappedType)) {
1172
- return 'assertive';
1173
- }
1174
- return 'polite';
1175
- }
1176
1170
  const handleTouchStart = () => setShouldFire(true);
1177
1171
  const handleTouchMove = () => setShouldFire(false);
1178
1172
  const handleTouchEnd = event => {
@@ -1190,7 +1184,6 @@ const Alert = props => {
1190
1184
  };
1191
1185
  return /*#__PURE__*/jsxRuntime.jsxs("div", {
1192
1186
  role: "alert",
1193
- "aria-live": calculateAriaLive(),
1194
1187
  className: classNames__default.default('alert d-flex', `alert-${mappedType}`, className),
1195
1188
  onTouchStart: handleTouchStart,
1196
1189
  onTouchEnd: handleTouchEnd,
@@ -7270,16 +7263,12 @@ InputWithDisplayFormat.propTypes = {
7270
7263
  };
7271
7264
  var InputWithDisplayFormat$1 = InputWithDisplayFormat;
7272
7265
 
7273
- const InstructionsList = props => {
7274
- const {
7275
- isModern
7276
- } = componentsTheming.useTheme();
7277
- const {
7278
- dos,
7279
- donts
7280
- } = props;
7281
- const DontIcon = isModern ? icons.CrossCircleFill : icons.CrossCircle;
7282
- const DoIcon = isModern ? icons.CheckCircleFill : icons.CheckCircle;
7266
+ const InstructionsList = ({
7267
+ dos,
7268
+ donts,
7269
+ 'do-aria-label': doAriaLabel = undefined,
7270
+ 'dont-aria-label': dontAriaLabel = undefined
7271
+ }) => {
7283
7272
  return /*#__PURE__*/jsxRuntime.jsxs("div", {
7284
7273
  className: "tw-instructions",
7285
7274
  children: [dos && dos.map((doThis, index) =>
@@ -7287,9 +7276,10 @@ const InstructionsList = props => {
7287
7276
  // eslint-disable-next-line react/no-array-index-key
7288
7277
  jsxRuntime.jsxs("div", {
7289
7278
  className: "instruction",
7290
- children: [/*#__PURE__*/jsxRuntime.jsx(DoIcon, {
7279
+ children: [/*#__PURE__*/jsxRuntime.jsx(icons.CheckCircleFill, {
7291
7280
  size: 24,
7292
- className: "do"
7281
+ className: "do",
7282
+ title: doAriaLabel
7293
7283
  }), /*#__PURE__*/jsxRuntime.jsx(Body, {
7294
7284
  className: "text-primary",
7295
7285
  type: exports.Typography.BODY_LARGE,
@@ -7300,9 +7290,10 @@ const InstructionsList = props => {
7300
7290
  // eslint-disable-next-line react/no-array-index-key
7301
7291
  jsxRuntime.jsxs("div", {
7302
7292
  className: "instruction",
7303
- children: [/*#__PURE__*/jsxRuntime.jsx(DontIcon, {
7293
+ children: [/*#__PURE__*/jsxRuntime.jsx(icons.CrossCircleFill, {
7304
7294
  size: 24,
7305
- className: "dont"
7295
+ className: "dont",
7296
+ title: dontAriaLabel
7306
7297
  }), /*#__PURE__*/jsxRuntime.jsx(Body, {
7307
7298
  className: "text-primary",
7308
7299
  type: exports.Typography.BODY_LARGE,