docs(theme): add examples

This commit is contained in:
Eric Y Liu 2021-07-10 15:31:39 -07:00
commit a97f72d3e3
8 changed files with 112 additions and 4 deletions

View file

@ -1,5 +1,17 @@
<script>
import { Theme } from "carbon-components-svelte";
import {
Theme,
RadioButtonGroup,
RadioButton,
} from "carbon-components-svelte";
let theme = "g90";
</script>
<Theme theme="g90" />
<Theme bind:theme />
<RadioButtonGroup legendText="Carbon theme" bind:selected="{theme}">
{#each ["white", "g10", "g80", "g90", "g100"] as value}
<RadioButton labelText="{value}" value="{value}" />
{/each}
</RadioButtonGroup>