"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _genStyleHook = require("../../../theme/utils/genStyleHook");
var _tinycolor = require("@ctrl/tinycolor");
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
var RefactorTreeSelectStyleFunc = function RefactorTreeSelectStyleFunc(prefix) {
  var prepareComponentToken = function prepareComponentToken(token) {
    return {
      // fontWeight: 400,
    };
  };
  return (0, _genStyleHook.createStyleHook)(prefix, function (token) {
    var prefixCls = ".".concat(prefix);
    return [_defineProperty({}, prefixCls, _defineProperty({
      '&.refactor-disabled .refactor-tree-select-extra ': {
        color: token.colorTextDisabled,
        background: token.colorBgContainerDisabled
      },
      '.refactor-tree-select-extra': {
        background: token.colorBgContainer,
        height: token.controlHeight,
        padding: "1px 22px 1px ".concat(token.paddingXS + 3, "px")
      }
    }, '.tree-select-viewonly-list', {
      border: "1px solid ".concat(token.colorBorder),
      borderRadius: token.borderRadius,
      // padding: `${token.paddingXS}px ${token.paddingSM}px`,
      padding: "1px ".concat(token.paddingSM, "px"),
      '& .toggle-icon': {
        fontSize: token.fontSizeSM,
        color: token.colorTextSecondary,
        borderBottomLeftRadius: token.borderRadius,
        borderBottomRightRadius: token.borderRadius,
        // backgroundImage: `-webkit-gradient(linear, left top, left bottom, from(fade(@component-background, 0)), to(@component-background))`,
        // backgroundImage: `-webkit-linear-gradient(top, fade(@component-background, 0), @component-background)`,
        backgroundImage: "linear-gradient(-180deg, ".concat(new _tinycolor.TinyColor(token.colorBgContainer).setAlpha(0.).toRgbString(), ", ").concat(token.colorBgContainer, ")"),
        '&:hover': {
          color: token.colorPrimary
        }
      }
    }))];
  }, prepareComponentToken // 当前组件扩展的变量
  );
};
var _default = exports.default = RefactorTreeSelectStyleFunc;