mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 18:31:06 +00:00
chore(dropdown): move helper text below input
This commit is contained in:
parent
05bc19d96c
commit
95e3a6eb12
2 changed files with 8 additions and 7 deletions
|
@ -26,6 +26,7 @@ export const Default = () => ({
|
||||||
disabled: boolean("Disabled (disabled)", false),
|
disabled: boolean("Disabled (disabled)", false),
|
||||||
light: boolean("Light variant (light)", false),
|
light: boolean("Light variant (light)", false),
|
||||||
titleText: text("Title (titleText)", "This is not a dropdown title."),
|
titleText: text("Title (titleText)", "This is not a dropdown title."),
|
||||||
|
helperText: text("Helper text (helperText)", "Optional helper text here"),
|
||||||
invalid: boolean("Show form validation UI (invalid)", false),
|
invalid: boolean("Show form validation UI (invalid)", false),
|
||||||
invalidText: text(
|
invalidText: text(
|
||||||
"Form validation UI content (invalidText)",
|
"Form validation UI content (invalidText)",
|
||||||
|
|
|
@ -166,13 +166,6 @@
|
||||||
{titleText}
|
{titleText}
|
||||||
</label>
|
</label>
|
||||||
{/if}
|
{/if}
|
||||||
{#if !inline && helperText}
|
|
||||||
<div
|
|
||||||
class:bx--form__helper-text="{true}"
|
|
||||||
class:bx--form__helper-text--disabled="{disabled}">
|
|
||||||
{helperText}
|
|
||||||
</div>
|
|
||||||
{/if}
|
|
||||||
<ListBox
|
<ListBox
|
||||||
type="{type}"
|
type="{type}"
|
||||||
size="{size}"
|
size="{size}"
|
||||||
|
@ -250,4 +243,11 @@
|
||||||
</ListBoxMenu>
|
</ListBoxMenu>
|
||||||
{/if}
|
{/if}
|
||||||
</ListBox>
|
</ListBox>
|
||||||
|
{#if !inline && !invalid && helperText}
|
||||||
|
<div
|
||||||
|
class:bx--form__helper-text="{true}"
|
||||||
|
class:bx--form__helper-text--disabled="{disabled}">
|
||||||
|
{helperText}
|
||||||
|
</div>
|
||||||
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue