import './EmbeddedButton.styles_131jfji.css';
import { styled } from '@linaria/react';
import { tokens } from './EmbeddedButton.tokens.js';
import { component, mergeConfig } from '../../../engines/common.js';
import { spinnerConfig } from '../../Spinner/Spinner.js';

var mergedConfig = /*#__PURE__*/mergeConfig(spinnerConfig);
var Spinner = /*#__PURE__*/component(mergedConfig);
var _exp = function _exp() {
  return function (_ref) {
    var isLoading = _ref.isLoading;
    return isLoading ? "var(".concat(tokens.loadingIconOpacity, ")") : '1';
  };
};
var _exp2 = function _exp2() {
  return function (_ref2) {
    var position = _ref2.position;
    return {
      center: "center",
      "center-left": "center",
      "center-right": "center",
      top: "start",
      "top-left": "start",
      "top-right": "start",
      bottom: "end",
      "bottom-left": "end",
      "bottom-right": "end"
    }[position];
  };
};
var _exp3 = function _exp3() {
  return function (_ref3) {
    var position = _ref3.position;
    return {
      center: "center",
      "center-left": "start",
      "center-right": "end",
      top: "center",
      "top-left": "start",
      "top-right": "end",
      bottom: "center",
      "bottom-left": "start",
      "bottom-right": "end"
    }[position];
  };
};
var LoadWrap = /*#__PURE__*/styled('div')({
  name: "LoadWrap",
  "class": "lvtj00l",
  propsAsIs: false,
  vars: {
    "lvtj00l-0": [/*#__PURE__*/_exp()],
    "lvtj00l-1": [/*#__PURE__*/_exp2()],
    "lvtj00l-2": [/*#__PURE__*/_exp3()]
  }
});
var IconContainer = /*#__PURE__*/styled('div')({
  name: "IconContainer",
  "class": "i1d4hnia",
  propsAsIs: false
});
var Loader = /*#__PURE__*/styled('div')({
  name: "Loader",
  "class": "l1ae79jo",
  propsAsIs: false
});
var _exp4 = function _exp4() {
  return Spinner;
};
var StyledSpinner = /*#__PURE__*/styled(_exp4())({
  name: "StyledSpinner",
  "class": "s1y4l06s",
  propsAsIs: true
});
var base = "b96c0v2";

export { IconContainer, LoadWrap, Loader, StyledSpinner, base };
