From 9a0ad49b74fbf428ecc6442d96c08b3b2ef37629 Mon Sep 17 00:00:00 2001 From: Andrew Kingston Date: Fri, 16 Apr 2021 17:12:22 +0100 Subject: [PATCH] Add switch and fix modal titles --- packages/bbui/package.json | 1 + packages/bbui/src/Button/Button.svelte | 5 + packages/bbui/src/Form/Core/Switch.svelte | 27 ++++ packages/bbui/src/Form/Slider.svelte | 88 ----------- packages/bbui/src/Form/Toggle.svelte | 124 +++------------ packages/bbui/src/Modal/ModalContent.svelte | 8 +- packages/bbui/src/index.js | 1 - packages/bbui/yarn.lock | 138 +---------------- .../buttons/CreateColumnButton.svelte | 8 +- .../DataTable/modals/CreateEditColumn.svelte | 144 +++++++----------- 10 files changed, 115 insertions(+), 429 deletions(-) create mode 100644 packages/bbui/src/Form/Core/Switch.svelte delete mode 100644 packages/bbui/src/Form/Slider.svelte diff --git a/packages/bbui/package.json b/packages/bbui/package.json index 18190c89e3..ec5e7f6c31 100644 --- a/packages/bbui/package.json +++ b/packages/bbui/package.json @@ -54,6 +54,7 @@ "@spectrum-css/progressbar": "^1.0.2", "@spectrum-css/progresscircle": "^1.0.2", "@spectrum-css/radio": "^3.0.2", + "@spectrum-css/switch": "^1.0.2", "@spectrum-css/table": "^3.0.1", "@spectrum-css/tabs": "^3.0.1", "@spectrum-css/textfield": "^3.0.1", diff --git a/packages/bbui/src/Button/Button.svelte b/packages/bbui/src/Button/Button.svelte index 1148387a94..d85b9da1ee 100644 --- a/packages/bbui/src/Button/Button.svelte +++ b/packages/bbui/src/Button/Button.svelte @@ -39,4 +39,9 @@ diff --git a/packages/bbui/src/Form/Core/Switch.svelte b/packages/bbui/src/Form/Core/Switch.svelte new file mode 100644 index 0000000000..520b8ebff1 --- /dev/null +++ b/packages/bbui/src/Form/Core/Switch.svelte @@ -0,0 +1,27 @@ + + +
+ + + +
diff --git a/packages/bbui/src/Form/Slider.svelte b/packages/bbui/src/Form/Slider.svelte deleted file mode 100644 index c8a4c0122e..0000000000 --- a/packages/bbui/src/Form/Slider.svelte +++ /dev/null @@ -1,88 +0,0 @@ - - -
- {#if label} - - {/if} -
- {#if showRange && min != null}{min}{/if} - - {#if showRange && max != null}{max}{/if} -
-
- - diff --git a/packages/bbui/src/Form/Toggle.svelte b/packages/bbui/src/Form/Toggle.svelte index 56e70f7e70..30cc49db3f 100644 --- a/packages/bbui/src/Form/Toggle.svelte +++ b/packages/bbui/src/Form/Toggle.svelte @@ -1,110 +1,22 @@ -