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,8 +1,27 @@
<script>
/**
* Set the selected radio button value
* @type {string} [selected]
*/
export let selected = undefined;
/**
* Set to `true` to disable the radio buttons
* @type {boolean} [disabled=false]
*/
export let disabled = false;
export let labelPosition = "right"; // "right" | "left"
export let orientation = "horizontal"; // "horizontal" | "vertical"
/**
* Specify the label position
* @type {"right" | "left"} [labelPosition="right"]
*/
export let labelPosition = "right";
/**
* Specify the orientation of the radio buttons
* @type {"horizontal" | "vertical"} [orientation="horizontal"]
*/
export let orientation = "horizontal";
import { createEventDispatcher, setContext } from "svelte";
import { writable } from "svelte/store";
@ -17,9 +36,9 @@
selectedValue.set(value);
}
},
update: value => {
update: (value) => {
selectedValue.set(value);
}
},
});
$: selected = $selectedValue;