From 6458c97c1ab6ab122c960d6a834b3d42361f566c Mon Sep 17 00:00:00 2001 From: brunnerh Date: Mon, 3 Jan 2022 19:46:12 +0100 Subject: [PATCH] Add `required` prop to Select. (#968) Upgrade sveld to set paths correctly on Windows. Make Prettier script compatible with Windows and run it. --- COMPONENT_INDEX.md | 1 + docs/src/COMPONENT_API.json | 11 +++++++++++ .../src/pages/framed/Breakpoint/Breakpoint.svelte | 2 +- package.json | 4 ++-- src/CodeSnippet/CodeSnippet.svelte | 15 +++++---------- src/DatePicker/DatePicker.svelte | 3 +-- src/Dropdown/Dropdown.svelte | 12 ++++-------- src/MultiSelect/MultiSelect.svelte | 12 ++++-------- src/ProgressIndicator/ProgressStep.svelte | 3 +-- src/Select/Select.svelte | 5 +++++ src/TextInput/PasswordInput.svelte | 6 ++---- src/TreeView/TreeViewNode.svelte | 9 ++------- types/Select/Select.svelte.d.ts | 6 ++++++ yarn.lock | 8 ++++---- 14 files changed, 49 insertions(+), 48 deletions(-) diff --git a/COMPONENT_INDEX.md b/COMPONENT_INDEX.md index 0b59bc73..f70be063 100644 --- a/COMPONENT_INDEX.md +++ b/COMPONENT_INDEX.md @@ -3242,6 +3242,7 @@ None. | noLabel | let | No | boolean | false | Set to `true` to not render a label | | labelText | let | No | string | "" | Specify the label text | | hideLabel | let | No | boolean | false | Set to `true` to visually hide the label text | +| required | let | No | boolean | false | Set to `true` to mark the field as required | ### Slots diff --git a/docs/src/COMPONENT_API.json b/docs/src/COMPONENT_API.json index 69c3bfac..32415d3d 100644 --- a/docs/src/COMPONENT_API.json +++ b/docs/src/COMPONENT_API.json @@ -9419,6 +9419,17 @@ "isFunctionDeclaration": false, "constant": false, "reactive": true + }, + { + "name": "required", + "kind": "let", + "description": "Set to `true` to mark the field as required", + "type": "boolean", + "value": "false", + "isFunction": false, + "isFunctionDeclaration": false, + "constant": false, + "reactive": false } ], "slots": [ diff --git a/docs/src/pages/framed/Breakpoint/Breakpoint.svelte b/docs/src/pages/framed/Breakpoint/Breakpoint.svelte index d47affd2..83116706 100644 --- a/docs/src/pages/framed/Breakpoint/Breakpoint.svelte +++ b/docs/src/pages/framed/Breakpoint/Breakpoint.svelte @@ -13,7 +13,7 @@
on:match
-  {JSON.stringify(events,null, 2)}
+  {JSON.stringify(events, null, 2)}