import { Search } from '@transferwise/icons';
import { forwardRef } from 'react';
import { Input } from './Input.mjs';
import { InputGroup } from './InputGroup.mjs';
import { jsx } from 'react/jsx-runtime';
import { Size } from '../common/propsValues/size.mjs';

const SearchInput = /*#__PURE__*/forwardRef(function SearchInput({
  shape = 'pill',
  size = Size.MEDIUM,
  disabled,
  className,
  ...restProps
}, ref) {
  return /*#__PURE__*/jsx(InputGroup, {
    addonStart: {
      content: /*#__PURE__*/jsx(Search, {
        size: size === Size.SMALL ? 16 : 24
      }),
      initialContentWidth: size === Size.SMALL ? 16 : 24
    },
    disabled: disabled,
    className: className,
    children: /*#__PURE__*/jsx(Input, {
      ref: ref,
      role: "searchbox",
      inputMode: "search",
      shape: shape,
      size: size,
      ...restProps
    })
  });
});

export { SearchInput };
//# sourceMappingURL=SearchInput.mjs.map
