Removes Switcher component

This commit is contained in:
Keviin Åberg Kultalahti 2021-04-21 13:44:36 +02:00
parent 630acef7fc
commit 0e786089f5
3 changed files with 0 additions and 75 deletions

View File

@ -1,47 +0,0 @@
<script>
import { createEventDispatcher } from "svelte"
const dispatch = createEventDispatcher()
export let headings
export let value
</script>
<section>
<header>
{#each headings as heading}
<span
class:selected={value === heading.key}
on:click={() => {
value = heading.key
dispatch('change', { heading })
}}>
{heading.title}
</span>
{/each}
</header>
<slot />
</section>
<style>
header {
font-family: var(--font-sans);
display: flex;
margin-bottom: var(--spacing-l);
}
span {
margin-right: var(--spacing-xl);
font-size: var(--font-size-m);
font-weight: 500;
color: var(--grey-5);
}
span:hover {
cursor: pointer;
}
.selected {
color: var(--ink);
}
</style>

View File

@ -1,27 +0,0 @@
<script>
import { View } from "svench";
import Switcher from "./Switcher.svelte";
const items = [
{
title: "Apps",
key: "APPS"
},
{
title: "Deploy",
key: "DEPLOY"
},
{
title: "Settings",
key: "SETTINGS"
}
]
let value = "APPS"
</script>
<View name="default">
<Switcher headings={items} bind:value={value}>
Content
</Switcher>
</View>

View File

@ -20,7 +20,6 @@ export { default as RadioGroup } from "./Form/RadioGroup.svelte"
export { default as Checkbox } from "./Form/Checkbox.svelte" export { default as Checkbox } from "./Form/Checkbox.svelte"
export { default as Home } from "./Links/Home.svelte" export { default as Home } from "./Links/Home.svelte"
export { default as DetailSummary } from "./List/Items/DetailSummary.svelte" export { default as DetailSummary } from "./List/Items/DetailSummary.svelte"
export { default as Switcher } from "./Switcher/Switcher.svelte"
export { default as DropdownMenu } from "./DropdownMenu/DropdownMenu.svelte" export { default as DropdownMenu } from "./DropdownMenu/DropdownMenu.svelte"
export { default as Popover } from "./Popover/Popover.svelte" export { default as Popover } from "./Popover/Popover.svelte"
export { default as ProgressBar } from "./ProgressBar/ProgressBar.svelte" export { default as ProgressBar } from "./ProgressBar/ProgressBar.svelte"