From c8587c743235ae4ca98542d670142322ab80fd3d Mon Sep 17 00:00:00 2001 From: Moritz Bischof Date: Tue, 4 May 2021 19:21:57 +0200 Subject: [PATCH 1/4] add exception for Playground.svelte in svelte.config.js --- docs/svelte.config.js | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/svelte.config.js b/docs/svelte.config.js index fbf33fcbf6..5f37b09b90 100644 --- a/docs/svelte.config.js +++ b/docs/svelte.config.js @@ -61,6 +61,7 @@ function plugin() { if ( node.lang !== "svelte" && !node.value.startsWith("") && !node.value.match(/svx-ignore/g) ) { From f60535b88169bad8b9d24f189baf619fcb18e7df Mon Sep 17 00:00:00 2001 From: Moritz Bischof Date: Tue, 4 May 2021 19:23:59 +0200 Subject: [PATCH 2/4] add Checkbox and TextInput wrapper components --- docs/src/components/playground/Checkbox.svelte | 7 +++++++ docs/src/components/playground/TextInput.svelte | 7 +++++++ 2 files changed, 14 insertions(+) create mode 100644 docs/src/components/playground/Checkbox.svelte create mode 100644 docs/src/components/playground/TextInput.svelte diff --git a/docs/src/components/playground/Checkbox.svelte b/docs/src/components/playground/Checkbox.svelte new file mode 100644 index 0000000000..ac235ff9aa --- /dev/null +++ b/docs/src/components/playground/Checkbox.svelte @@ -0,0 +1,7 @@ + + + diff --git a/docs/src/components/playground/TextInput.svelte b/docs/src/components/playground/TextInput.svelte new file mode 100644 index 0000000000..4da95d1396 --- /dev/null +++ b/docs/src/components/playground/TextInput.svelte @@ -0,0 +1,7 @@ + + + From 088524da82523dc931ecfc91fd4eb395e53c878c Mon Sep 17 00:00:00 2001 From: Moritz Bischof Date: Tue, 4 May 2021 19:24:11 +0200 Subject: [PATCH 3/4] implement Playground --- .../components/playground/Playground.svelte | 65 +++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 docs/src/components/playground/Playground.svelte diff --git a/docs/src/components/playground/Playground.svelte b/docs/src/components/playground/Playground.svelte new file mode 100644 index 0000000000..5e57f01c68 --- /dev/null +++ b/docs/src/components/playground/Playground.svelte @@ -0,0 +1,65 @@ + + +
+
+
+ +
+
+ +
+

Options

+
+
+ {#each Object.entries(props) as [name, prop]} + + {/each} + +
+
+
+ + From eb8ca16a14705c7a560078c95053a05b76d9da53 Mon Sep 17 00:00:00 2001 From: Moritz Bischof Date: Tue, 4 May 2021 19:24:27 +0200 Subject: [PATCH 4/4] add example usage to Checkbox docs --- docs/src/pages/components/Checkbox.svx | 30 ++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/docs/src/pages/components/Checkbox.svx b/docs/src/pages/components/Checkbox.svx index 8bbd26c4ba..1710fb0fff 100644 --- a/docs/src/pages/components/Checkbox.svx +++ b/docs/src/pages/components/Checkbox.svx @@ -1,8 +1,38 @@ + + ### Default (unchecked)