@transferwise/components 0.0.0-experimental-e3c198b → 0.0.0-experimental-fcfae09

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
@@ -1811,8 +1811,9 @@ const SlidingPanel = /*#__PURE__*/React.forwardRef(({
1811
1811
  }, reference) => {
1812
1812
  /** @type {RefObject<HTMLDivElement>} */
1813
1813
  const localReference = React.useRef(null);
1814
- return /*#__PURE__*/jsxRuntime.jsx(reactTransitionGroup.CSSTransition, {
1814
+ return /*#__PURE__*/React.createElement(reactTransitionGroup.CSSTransition, {
1815
1815
  ...rest,
1816
+ key: `sliding-panel--open-${position}`,
1816
1817
  nodeRef: localReference,
1817
1818
  in: open
1818
1819
  // Wait for animation to finish before unmount.
@@ -1825,13 +1826,12 @@ const SlidingPanel = /*#__PURE__*/React.forwardRef(({
1825
1826
  'sliding-panel--fixed': slidingPanelPositionFixed
1826
1827
  }, 'sliding-panel'),
1827
1828
  appear: true,
1828
- unmountOnExit: true,
1829
- children: /*#__PURE__*/jsxRuntime.jsx("div", {
1830
- ref: mergeRefs__default.default([reference, localReference]),
1831
- className: classNames__default.default('sliding-panel', `sliding-panel--open-${position}`, className),
1832
- children: children
1833
- })
1834
- });
1829
+ unmountOnExit: true
1830
+ }, /*#__PURE__*/jsxRuntime.jsx("div", {
1831
+ ref: mergeRefs__default.default([reference, localReference]),
1832
+ className: classNames__default.default('sliding-panel', `sliding-panel--open-${position}`, className),
1833
+ children: children
1834
+ }));
1835
1835
  });
1836
1836
  SlidingPanel.propTypes = {
1837
1837
  children: PropTypes__default.default.node,
@@ -12299,12 +12299,7 @@ class Typeahead extends React.Component {
12299
12299
  query = item.label;
12300
12300
  }
12301
12301
  this.updateSelectedValue(selected);
12302
- if (!item.keepFocusOnSelect) {
12303
- this.hideMenu();
12304
- }
12305
- if (item.clearQueryOnSelect) {
12306
- query = '';
12307
- }
12302
+ this.hideMenu();
12308
12303
  this.setState({
12309
12304
  query
12310
12305
  });
@@ -12531,10 +12526,10 @@ class Typeahead extends React.Component {
12531
12526
  children: /*#__PURE__*/jsxRuntime.jsx(icons.Cross, {})
12532
12527
  })
12533
12528
  })]
12534
- }), displayAlert ? /*#__PURE__*/jsxRuntime.jsx(InlineAlert, {
12529
+ }), displayAlert && /*#__PURE__*/jsxRuntime.jsx(InlineAlert, {
12535
12530
  type: alert.type,
12536
12531
  children: alert.message
12537
- }) : menu]
12532
+ }), menu]
12538
12533
  })
12539
12534
  });
12540
12535
  }