import styled from "@emotion/styled";
import { addFocus } from "../../../../../../mixins";
import { IconDisclosureRightCentered } from "../../../../../_Icon";
import { classes, tokens, constants } from "../../../../Combobox.tokens";
export const ItemWrapper = /*#__PURE__*/ styled("div", {
    target: "e1pl4fe20",
    label: "ItemWrapper"
})();
// TODO: Удалить после поддержки JS переменных в конфиге компонент
export const sizeMap = {
    xs: '1rem',
    s: '1.5rem'
};
export const StyledArrowLeft = /*#__PURE__*/ styled(IconDisclosureRightCentered, {
    target: "e1pl4fe21",
    label: "StyledArrowLeft"
})("width:", ({ size = 'xs' })=>`var(${tokens.disclosureIconSize}, ${sizeMap[size]})`, ";height:", ({ size = 'xs' })=>`var(${tokens.disclosureIconSize}, ${sizeMap[size]})`, ";&.", classes.arrowInverse, "{transform:rotate(90deg);}");
export const StyledArrowRight = /*#__PURE__*/ styled(IconDisclosureRightCentered, {
    target: "e1pl4fe22",
    label: "StyledArrowRight"
})("width:", ({ size = 'xs' })=>`var(${tokens.disclosureIconSize}, ${sizeMap[size]})`, ";height:", ({ size = 'xs' })=>`var(${tokens.disclosureIconSize}, ${sizeMap[size]})`, ";transform:rotate(90deg);&.", classes.arrowInverse, "{transform:rotate(-90deg);}");
export const DisclosureIconWrapper = /*#__PURE__*/ styled("div", {
    target: "e1pl4fe23",
    label: "DisclosureIconWrapper"
})("line-height:0;color:var(", tokens.disclosureIconColor, ");visibility:", ({ visibility })=>visibility || 'visible', ";&:hover{color:var(", tokens.disclosureIconColorHover, ");}");
export const Wrapper = /*#__PURE__*/ styled("div", {
    target: "e1pl4fe24",
    label: "Wrapper"
})("display:flex;align-items:center;gap:var(", tokens.itemGap, ");min-height:var(", tokens.itemHeight, ");margin:0;box-sizing:content-box;padding:", ({ variant })=>`var(${variant === 'tight' ? tokens.itemPaddingTight : tokens.itemPadding})`, ";font-family:var(", tokens.fontFamily, ");font-size:var(", tokens.fontSize, ");font-style:var(", tokens.fontStyle, ");font-weight:var(", tokens.fontWeight, ");letter-spacing:var(", tokens.fontLetterSpacing, ");line-height:var(", tokens.fontLineHeight, ");background-color:var(", constants.itemBackground, ");color:var(--text-primary);border-radius:calc(var(", tokens.borderRadius, ") - 0.125rem - var(", tokens.dropdownBorderWidth, ",0rem));user-select:none;background-clip:padding-box;&:hover:not(.", classes.dropdownItemIsDisabled, "){cursor:pointer;background-color:var(", tokens.itemBackgroundHover, ");}&.", classes.dropdownItemIsActive, "{background-color:var(", tokens.itemBackgroundHover, ");}&.", classes.dropdownItemIsDisabled, "{opacity:", constants.opacity, ";cursor:not-allowed;}:focus{outline:none;}", addFocus({
    outlineSize: '0',
    outlineOffset: '0',
    outlineColor: `var(${constants.focusColor})`,
    outlineRadius: `calc(var(${tokens.borderRadius}) - 0.125rem - var(${tokens.dropdownBorderWidth}, 0rem))`,
    hasTransition: false,
    customFocusRules: `
            &.${classes.dropdownItemIsFocused}:before {
                outline: none;
                box-shadow: inset 0 0 0 0.0625rem var(${constants.focusColor});
            }
        `
}), ";");
export const ChildItems = /*#__PURE__*/ styled("div", {
    target: "e1pl4fe25",
    label: "ChildItems"
})();
export const Offset = /*#__PURE__*/ styled("div", {
    target: "e1pl4fe26",
    label: "Offset"
})("width:calc(", ({ depth })=>depth || 0, " * var(", tokens.itemTreeOffsetWidth, "));flex:none;margin-right:calc(var(", tokens.itemGap, ") * -1);");
