구성 요소
접기/펼치기
콘텐츠 영역 하나를 숨기거나 표시합니다.
사용법
기본
Cache, workers, and build flags live here.
HTML
<bs:bsui-collapsible>
<bs:bsui-collapsible-trigger trigger_label="Show advanced options" trigger_variant="outline" />
<bs:bsui-collapsible-panel>
<bs:bsui-text content="Cache, workers, and build flags live here." variant="muted" />
</bs:bsui-collapsible-panel>
</bs:bsui-collapsible>기본적으로 열림
보통 읽어볼 만한 세부 정보가 펼쳐진 상태로 시작합니다.
Faster page sync, a new table block, and fourteen bug fixes.
HTML
<bs:bsui-collapsible defaultOpen="true">
<bs:bsui-collapsible-trigger trigger_label="Release notes" trigger_variant="ghost" trigger_size="sm" />
<bs:bsui-collapsible-panel>
<bs:bsui-text content="Faster page sync, a new table block, and fourteen bug fixes." variant="muted" />
</bs:bsui-collapsible-panel>
</bs:bsui-collapsible>점진적 공개
잘 쓰이지 않는 옵션은 사용자가 요청할 때까지 보이지 않게 둡니다.
Deploy to production
Builds the current branch and swaps the live release.
HTML
<bs:bsui-card>
<bs:bsui-card-header>
<bs:bsui-card-title label="Deploy to production" />
<bs:bsui-card-description label="Builds the current branch and swaps the live release." />
</bs:bsui-card-header>
<bs:bsui-card-content>
<bs:bsui-collapsible>
<bs:bsui-collapsible-trigger trigger_label="Show advanced options" trigger_variant="ghost" trigger_size="sm" />
<bs:bsui-collapsible-panel>
<bs:bsui-stack direction="column" gap="3" align="start">
<bs:bsui-switch label="Skip the build cache" />
<bs:bsui-switch label="Warm the static pages afterwards" defaultChecked="true" />
</bs:bsui-stack>
</bs:bsui-collapsible-panel>
</bs:bsui-collapsible>
</bs:bsui-card-content>
<bs:bsui-card-footer>
<bs:bsui-button label="Deploy" />
</bs:bsui-card-footer>
</bs:bsui-card>구조
접기/펼치기의 구성 블록은 아래와 같습니다. 각 블록은 별도의 블록이며 부모 블록 안에서만 렌더링됩니다.
bsui/collapsiblebsui/collapsible-panelbsui/collapsible-trigger
속성
| 속성 | 유형 | 기본값 |
|---|---|---|
defaultOpen | toggle | false |
disabled | toggle | false |
bsui/collapsible-panel
이 블록은 속성을 받지 않습니다.
bsui/collapsible-trigger
| 속성 | 유형 | 기본값 |
|---|---|---|
trigger | text | — |
trigger_block | text | bsui/button |
trigger_label | richtext | — |
trigger_icon | icon | — |
trigger_iconPosition | left | |
trigger_href | text | — |
trigger_variant | default | |
trigger_size | default | |
trigger_disabled | toggle | false |