From 7a58e3c81769178c24fc860455941f47986edbe7 Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Mon, 9 Aug 2021 15:47:30 +0100 Subject: [PATCH] Add Quiet and Emphasized variants to the Tabs and Tab components --- packages/bbui/src/Tabs/Tab.svelte | 7 +++++++ packages/bbui/src/Tabs/Tabs.svelte | 14 +++++++++++--- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/packages/bbui/src/Tabs/Tab.svelte b/packages/bbui/src/Tabs/Tab.svelte index b0f59c76f0..3644280edf 100644 --- a/packages/bbui/src/Tabs/Tab.svelte +++ b/packages/bbui/src/Tabs/Tab.svelte @@ -30,6 +30,7 @@ on:click={onClick} class:is-selected={$selected.title === title} class="spectrum-Tabs-item" + class:emphasized={$selected.title === title && $selected.emphasized} tabindex="0" > {#if icon} @@ -49,3 +50,9 @@ {/if} + + diff --git a/packages/bbui/src/Tabs/Tabs.svelte b/packages/bbui/src/Tabs/Tabs.svelte index 77a8526a15..bcfe7b1750 100644 --- a/packages/bbui/src/Tabs/Tabs.svelte +++ b/packages/bbui/src/Tabs/Tabs.svelte @@ -6,9 +6,11 @@ export let selected export let vertical = false export let noPadding = false + export let quiet = false + export let emphasized = false let _id = id() - const tab = writable({ title: selected, id: _id }) + const tab = writable({ title: selected, id: _id, emphasized }) setContext("tab", tab) let container @@ -56,7 +58,9 @@
@@ -64,7 +68,7 @@ {#if $tab.info}
{/if}
@@ -75,6 +79,10 @@ />