import{css as i}from"styled-components";import{Button as r}from"@redocly/theme/components/Button/Button";import{DropdownMenuItem as n}from"@redocly/theme/components/Dropdown/DropdownMenuItem";import{ITEM_WIDTH as o}from"./constants.js";import{styled as t}from"../../styled-components.js";const d=t.span`
  display: flex;
  justify-content: space-between;
  align-items: center;
`,g=t.span`
  max-width: 150px;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
  padding: 0 var(--spacing-xxs);
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  font-weight: ${({active:e})=>e?"var(--font-weight-medium)":"var(--font-weight-regular)"};
`,x=t.span`
  width: 100%;
  display: inherit;
  gap: inherit;
  flex-direction: inherit;
  justify-content: inherit;
  align-items: inherit;
`,f=t.span`
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
`,h=t.div`
  display: flex;
  justify-content: ${({$justifyContent:e="start"})=>e};
  align-items: center;
  width: 100%;
`,u=t.button`
  background: none;
  border: none;
  width: ${o}px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  cursor: pointer;
  flex-direction: column;
  gap: calc(var(--spacing-unit) * 0.5);
  padding: var(--spacing-xs) 0;
  color: ${({active:e})=>e?"var(--text-color-primary)":"var(--text-color-description)"};
  border-radius: var(--border-radius);
  text-align: center;
  position: relative;

  :hover {
    color: var(--text-color-primary);
  }

  ${({active:e})=>e&&i`
      &::before {
        position: absolute;
        top: -21px;
        border-top: 3px solid var(--text-color-primary);
        width: 100%;
        content: '';
        border-bottom-left-radius: calc(var(--border-radius) / 2);
        border-bottom-right-radius: calc(var(--border-radius) / 2);
      }
    `}
`,m=t(n)`
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-xs);
  padding: calc(var(--spacing-unit) * 1.5) var(--spacing-xs) calc(var(--spacing-unit) * 1.5)
    var(--spacing-sm);
  width: ${({$width:e=204})=>e}px;
  fill: var(--menu-content-color-active);
`,v=t(r)`
  display: inline-flex;

  line-height: var(--line-height-base);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-medium);
  cursor: pointer;
`;export{d as Container,v as DropdownTriggerButton,f as LanguageIcon,h as LanguageListContainer,u as LanguageListItem,g as LanguageTitle,x as LanguageTitleContainer,m as StyledDropdownMenuItem};
