Don't render field label components unless a label exists
This commit is contained in:
parent
e28bbf594b
commit
aab06cdc36
|
@ -10,7 +10,9 @@
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<div class="spectrum-Form-item" class:above={labelPosition === 'above'}>
|
<div class="spectrum-Form-item" class:above={labelPosition === 'above'}>
|
||||||
<FieldLabel forId={id} {label} position={labelPosition} />
|
{#if label}
|
||||||
|
<FieldLabel forId={id} {label} position={labelPosition} />
|
||||||
|
{/if}
|
||||||
<div class="spectrum-Form-itemField">
|
<div class="spectrum-Form-itemField">
|
||||||
<slot />
|
<slot />
|
||||||
{#if error}
|
{#if error}
|
||||||
|
|
Loading…
Reference in New Issue