mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 18:31:06 +00:00
parent
493568f08d
commit
25ce57fd5a
4 changed files with 39 additions and 17 deletions
|
@ -5,9 +5,12 @@
|
|||
/** Set to `true` to check the radio button */
|
||||
export let checked = false;
|
||||
|
||||
/** et to `true` to disable the radio button */
|
||||
/** Set to `true` to disable the radio button */
|
||||
export let disabled = false;
|
||||
|
||||
/** Set to `true` to mark the field as required */
|
||||
export let required = false;
|
||||
|
||||
/**
|
||||
* Specify the label position
|
||||
* @type {"right" | "left"}
|
||||
|
@ -23,7 +26,7 @@
|
|||
/** Set an id for the input element */
|
||||
export let id = "ccs-" + Math.random().toString(36);
|
||||
|
||||
/** Specify a name attribute for the checkbox input */
|
||||
/** Specify a name attribute for the radio button input */
|
||||
export let name = "";
|
||||
|
||||
/** Obtain a reference to the input HTML element */
|
||||
|
@ -56,6 +59,7 @@
|
|||
name="{name}"
|
||||
checked="{checked}"
|
||||
disabled="{disabled}"
|
||||
required="{required}"
|
||||
value="{value}"
|
||||
class:bx--radio-button="{true}"
|
||||
on:change
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue