mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 02:11:05 +00:00
refactor: update/fix JSDoc props
This commit is contained in:
parent
3c04f122b0
commit
d38e6d8be6
204 changed files with 992 additions and 2359 deletions
|
@ -1,110 +1,68 @@
|
|||
<script>
|
||||
/**
|
||||
* Set the size of the input
|
||||
* @type {"sm" | "xl"} [size]
|
||||
* @type {"sm" | "xl"}
|
||||
*/
|
||||
export let size = undefined;
|
||||
|
||||
/**
|
||||
* Specify the input value
|
||||
* @type {string} [value=""]
|
||||
*/
|
||||
/** Specify the input value */
|
||||
export let value = "";
|
||||
|
||||
/**
|
||||
* Specify the input type
|
||||
* @type {string} [type=""]
|
||||
*/
|
||||
/** Specify the input type */
|
||||
export let type = "";
|
||||
|
||||
/**
|
||||
* Specify the placeholder text
|
||||
* @type {string} [placeholder=""]
|
||||
*/
|
||||
/** Specify the placeholder text */
|
||||
export let placeholder = "";
|
||||
|
||||
/**
|
||||
* Set to `true` to enable the light variant
|
||||
* @type {boolean} [light=false]
|
||||
*/
|
||||
/** Set to `true` to enable the light variant */
|
||||
export let light = false;
|
||||
|
||||
/**
|
||||
* Set to `true` to disable the input
|
||||
* @type {boolean} [disabled=false]
|
||||
*/
|
||||
/** Set to `true` to disable the input */
|
||||
export let disabled = false;
|
||||
|
||||
/**
|
||||
* Specify the helper text
|
||||
* @type {string} [helperText=""]
|
||||
*/
|
||||
/** Specify the helper text */
|
||||
export let helperText = "";
|
||||
|
||||
/**
|
||||
* Set an id for the input element
|
||||
* @type {string} [id]
|
||||
* @type {string}
|
||||
*/
|
||||
export let id = "ccs-" + Math.random().toString(36);
|
||||
|
||||
/**
|
||||
* Specify a name attribute for the input
|
||||
* @type {string} [name]
|
||||
* @type {string}
|
||||
*/
|
||||
export let name = undefined;
|
||||
|
||||
/**
|
||||
* Specify the label text
|
||||
* @type {string} [labelText=""]
|
||||
*/
|
||||
/** Specify the label text */
|
||||
export let labelText = "";
|
||||
|
||||
/**
|
||||
* Set to `true` to visually hide the label text
|
||||
* @type {boolean} [hideLabel=false]
|
||||
*/
|
||||
/** Set to `true` to visually hide the label text */
|
||||
export let hideLabel = false;
|
||||
|
||||
/**
|
||||
* Set to `true` to indicate an invalid state
|
||||
* @type {boolean} [invalid=false]
|
||||
*/
|
||||
/** Set to `true` to indicate an invalid state */
|
||||
export let invalid = false;
|
||||
|
||||
/**
|
||||
* Specify the invalid state text
|
||||
* @type {string} [invalidText=""]
|
||||
*/
|
||||
/** Specify the invalid state text */
|
||||
export let invalidText = "";
|
||||
|
||||
/**
|
||||
* Set to `true` to indicate an warning state
|
||||
* @type {boolean} [warn=false]
|
||||
*/
|
||||
/** Set to `true` to indicate an warning state */
|
||||
export let warn = false;
|
||||
|
||||
/**
|
||||
* Specify the warning state text
|
||||
* @type {string} [warnText=""]
|
||||
*/
|
||||
/** Specify the warning state text */
|
||||
export let warnText = "";
|
||||
|
||||
/**
|
||||
* Obtain a reference to the input HTML element
|
||||
* @type {null | HTMLInputElement} [ref=null]
|
||||
* @type {null | HTMLInputElement}
|
||||
*/
|
||||
export let ref = null;
|
||||
|
||||
/**
|
||||
* Set to `true` to mark the field as required
|
||||
* @type {boolean} [required=false]
|
||||
*/
|
||||
/** Set to `true` to mark the field as required */
|
||||
export let required = false;
|
||||
|
||||
/**
|
||||
* Set to `true` to use inline version
|
||||
* @type {boolean} [inline=false]
|
||||
*/
|
||||
/** Set to `true` to use inline version */
|
||||
export let inline = false;
|
||||
|
||||
import { getContext } from "svelte";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue