import './Textfield.styles_xdjw8f.css';
import { styled } from '@linaria/react';
import { tokens } from '../../../../Select.tokens.js';
import { IconDisclosureDownCentered } from '../../../../../_Icon/Icons/IconDisclosureDownCentered.js';
import { component, mergeConfig } from '../../../../../../engines/common.js';
import { textFieldConfig } from '../../../../../TextField/TextField.js';

var mergedConfig = /*#__PURE__*/mergeConfig(textFieldConfig);
var TextField = /*#__PURE__*/component(mergedConfig);
var _exp = function _exp() {
  return TextField;
};
var _exp5 = function _exp5() {
  return function (_ref) {
    var opened = _ref.opened;
    return opened ? "var(".concat(tokens.textFieldBackgroundColorFocus, ")") : "var(".concat(tokens.textFieldBackgroundColor, ")");
  };
};
var _exp7 = function _exp7() {
  return function (_ref2) {
    var opened = _ref2.opened;
    return opened ? "var(".concat(tokens.textFieldBorderColorFocus, ")") : "var(".concat(tokens.textFieldBorderColor, ")");
  };
};
var _exp29 = function _exp29() {
  return function (_ref3) {
    var opened = _ref3.opened;
    return opened ? "var(".concat(tokens.textFieldPlaceholderColorFocus, ")") : "var(".concat(tokens.textFieldPlaceholderColor, ")");
  };
};
var StyledTextField = /*#__PURE__*/styled(_exp())({
  name: "StyledTextField",
  "class": "s1yhwv5r",
  propsAsIs: true,
  vars: {
    "s1yhwv5r-0": [/*#__PURE__*/_exp5()],
    "s1yhwv5r-1": [/*#__PURE__*/_exp7()],
    "s1yhwv5r-2": [/*#__PURE__*/_exp29()]
  }
});
var _exp289 = function _exp289() {
  return function (_ref4) {
    var disabled = _ref4.disabled,
      readOnly = _ref4.readOnly;
    return disabled || readOnly ? 'inherit' : 'pointer';
  };
};
var _exp291 = function _exp291() {
  return function (_ref5) {
    var disabled = _ref5.disabled,
      readOnly = _ref5.readOnly;
    return disabled || readOnly ? "var(".concat(tokens.disclosureIconColor, ")") : "var(".concat(tokens.disclosureIconColorHover, ")");
  };
};
var _exp292 = function _exp292() {
  return function (_ref6) {
    var readOnly = _ref6.readOnly;
    return readOnly ? "var(".concat(tokens.disclosureIconOpacityReadOnly, ")") : '';
  };
};
var IconArrowWrapper = /*#__PURE__*/styled('div')({
  name: "IconArrowWrapper",
  "class": "i7x5udn",
  propsAsIs: false,
  vars: {
    "i7x5udn-0": [/*#__PURE__*/_exp289()],
    "i7x5udn-1": [/*#__PURE__*/_exp291()],
    "i7x5udn-2": [/*#__PURE__*/_exp292()]
  }
});
var _exp293 = function _exp293() {
  return IconDisclosureDownCentered;
};
var _exp295 = function _exp295() {
  return function (_ref7) {
    var _ref7$size = _ref7.size,
      size = _ref7$size === void 0 ? 'xs' : _ref7$size;
    return "var(".concat(tokens.disclosureIconSize, ", ").concat({
      xs: "1rem",
      s: "1.5rem"
    }[size], ")");
  };
};
var StyledArrow = /*#__PURE__*/styled(_exp293())({
  name: "StyledArrow",
  "class": "s2oocb4",
  propsAsIs: true,
  vars: {
    "s2oocb4-0": [/*#__PURE__*/_exp295()]
  }
});
var StyledLeftHelper = /*#__PURE__*/styled('span')({
  name: "StyledLeftHelper",
  "class": "s1kxyc50",
  propsAsIs: false
});

export { IconArrowWrapper, StyledArrow, StyledLeftHelper, StyledTextField };
//# sourceMappingURL=Textfield.styles.js.map
