"use strict";var __createBinding=this&&this.__createBinding||(Object.create?function(e,t,a,i){void 0===i&&(i=a);var n=Object.getOwnPropertyDescriptor(t,a);n&&!("get"in n?!t.__esModule:n.writable||n.configurable)||(n={enumerable:!0,get:function(){return t[a]}}),Object.defineProperty(e,i,n)}:function(e,t,a,i){void 0===i&&(i=a),e[i]=t[a]}),__setModuleDefault=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),__importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)"default"!==a&&Object.prototype.hasOwnProperty.call(e,a)&&__createBinding(t,e,a);return __setModuleDefault(t,e),t};Object.defineProperty(exports,"__esModule",{value:!0}),exports.Row=exports.SamplesPanel=exports.Section=exports.SamplesMiddlePanel=void 0;const theme_1=require("@redocly/theme"),styled_components_1=__importStar(require("styled-components")),constants_1=require("../../constants");exports.SamplesMiddlePanel=styled_components_1.default.div`
  ${({compact:e,isStacked:t,fullWidth:a})=>{const i=e?0:"var(--spacing-vertical)";return styled_components_1.css`
      display: flex;
      flex-direction: column;
      width: 100%;
      padding: ${i} var(--panel-gap-horizontal);

      &:empty {
        display: none;
      }

      @media screen and (min-width: ${theme_1.breakpoints.large}) {
        width: ${a?"100%":"calc(100% - var(--panel-samples-width))"};
        padding-left: ${t?"var(--panel-gap-horizontal)":"calc(var(--panel-gap-horizontal) * 2)"};
        padding-right: ${t?"var(--panel-gap-vertical)":"var(--panel-gap-horizontal)"};
        padding-top: 0;
        padding-bottom: ${t?"var(--spacing-vertical)":0};
      }

      @media print {
        width: 100%;
        padding-top: ${i};
        padding-bottom: ${i};
      }
    `}};
  & & {
    padding-left: 0;
    padding-right: 0;
  }

  &:last-child > ${theme_1.Markdown} :last-child,
  ${theme_1.Markdown} article :last-child {
    margin-bottom: 0;
  }
`,exports.Section=styled_components_1.default.div.attrs((e=>({[constants_1.SECTION_ATTR]:e.sectionId,id:e.id})))`
  z-index: 0;
  padding: 0;
  width: 100%;

  ${({expanded:e})=>e&&styled_components_1.css`
      background-color: var(--layer-color);
      border-bottom: 1px solid var(--border-color-secondary);
      --code-block-bg-color: var(--bg-color);
      --code-block-controls-bg-color: var(--bg-color);
    `}

  & > &:last-child {
    min-height: initial;
  }

  @media screen and (min-width: ${theme_1.breakpoints.medium}) {
    padding-top: var(--spacing-xs);

    ${({expanded:e})=>!e&&styled_components_1.css`
        padding-bottom: var(--spacing-xs);
      `}
  }

  @media print {
    padding: 0;
  }

  ${({underlined:e})=>e&&styled_components_1.css`
      position: relative;

      &:not(:last-of-type):after {
        position: absolute;
        bottom: 0;
        width: 100%;
        display: block;
        content: '';
        border-bottom: 1px solid var(--border-color-primary);
      }
    `}
  ${theme_1.H2} {
    position: relative;
  }
`,exports.SamplesPanel=styled_components_1.default.div`
  color: var(--panel-samples-text-color);
  width: 100%;
  height: fit-content;
  padding-top: var(--panel-gap-vertical);
  padding-bottom: var(--panel-gap-vertical);
  padding-left: var(--panel-gap-horizontal);
  padding-right: var(--panel-gap-horizontal);

  position: sticky;
  z-index: var(--panel-z-index);
  top: calc(var(--navbar-height) + var(--panel-gap-vertical));

  &:empty {
    display: none;
  }

  @media screen and (min-width: ${theme_1.breakpoints.large}) {
    width: var(--panel-samples-width);
    padding-top: 0;
    padding-bottom: 0;
    padding-left: ${({isStacked:e})=>e?"var(--panel-gap-vertical)":"var(--panel-gap-horizontal)"};
    padding-right: ${({isStacked:e})=>e?"var(--panel-gap-horizontal)":"calc(var(--panel-gap-horizontal) * 2)"};
  }

  @media print {
    width: 100%;
    padding-top: var(--spacing-vertical);
    padding-bottom: var(--spacing-vertical);
  }
`,exports.Row=styled_components_1.default.div`
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
  padding: 0;

  @media screen and (min-width: ${theme_1.breakpoints.large}) {
    flex-direction: ${({layout:e})=>e!==theme_1.LayoutVariant.STACKED?"row":"column"};
  }

  @media print {
    flex-direction: column;
  }
`;
//# sourceMappingURL=panels.js.map