mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-19 20:09:35 +00:00
feat(dropdown): add hideLabel prop
This commit is contained in:
parent
6b75607dce
commit
1cb9345653
5 changed files with 27 additions and 0 deletions
|
@ -69,6 +69,9 @@
|
|||
*/
|
||||
export let label = undefined;
|
||||
|
||||
/** Set to `true` to visually hide the label text */
|
||||
export let hideLabel = false;
|
||||
|
||||
/**
|
||||
* Override the default translation ids
|
||||
* @type {(id: any) => string}
|
||||
|
@ -145,6 +148,7 @@
|
|||
for="{id}"
|
||||
class:bx--label="{true}"
|
||||
class:bx--label--disabled="{disabled}"
|
||||
class:bx--visually-hidden="{hideLabel}"
|
||||
>
|
||||
{titleText}
|
||||
</label>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue