chore: complete first pass of apply jsdoc annotations to component props

This commit is contained in:
Eric Liu 2020-07-26 17:42:12 -07:00
commit f30755b237
97 changed files with 2327 additions and 259 deletions

View file

@ -1,11 +1,50 @@
<script>
/**
* Specify the accepted file types
* @type {string[]} [accept=[]]
*/
export let accept = [];
/**
* Set to `true` to allow multiple files
* @type {boolean} [multiple=false]
*/
export let multiple = false;
/**
* Set to `true` to disable the input
* @type {boolean} [disabled=false]
*/
export let disabled = false;
/**
* Set to `true` to disable label changes
* @type {boolean} [disableLabelChanges=false]
*/
export let disableLabelChanges = false;
export let kind = "primary"; // Button.kind
/**
* Specify the kind of file uploader button
* @type {"primary" | "secondary" | "tertiary" | "ghost" | "danger"} [kind="primary"]
*/
export let kind = "primary";
/**
* Specify the label text
* @type {string} [labelText="Add file"]
*/
export let labelText = "Add file";
/**
* Specify the label role
* @type {string} [role="button"]
*/
export let role = "button";
/**
* Specify `tabindex` attribute
* @type {string} [tabindex="0"]
*/
export let tabindex = "0";
/**
@ -13,7 +52,17 @@
* @type {string} [id]
*/
export let id = "ccs-" + Math.random().toString(36);
/**
* Specify a name attribute for the input
* @type {string} [name]
*/
export let name = "";
/**
* Obtain a reference to the input HTML element
* @type {null | HTMLInputElement} [ref=null]
*/
export let ref = null;
</script>