Skip to content

Commit

Permalink
docs(components): add spinner docs
Browse files Browse the repository at this point in the history
  • Loading branch information
joshuagraber committed Jun 10, 2024
1 parent 31f52b5 commit 0364da7
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/components/Spinner/PdapSpinner.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,18 @@ withDefaults(defineProps<PdapSpinnerProps>(), {
});
</script>

<script lang="ts">
/**
* # `Spinner`
* Loading spinner component
*
* @preserve
*/
export default {
name: 'PdapSpinner',
};
</script>

<style>
@tailwind components;
Expand Down
17 changes: 17 additions & 0 deletions src/components/Spinner/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Breadcrumbs

The spinner component renders a layered SVG that rotates while it is displayed. Useful for loading states.

## Props

| name | required? | types | description | default |
| ------- | --------- | --------- | ----------------------------- | ---------------- |
| `color` | no | `string` | Color | `'currentColor'` |
| `size` | no | `string` | Size in pixels | `24` |
| `text` | no | `string` | Text to display while loading | `''` |
| `show` | yes | `boolean` | When to show the spinner | `false` |


## Example

See [Component demo](../../demo/pages/ComponentDemo.vue) for multiple examples, including

0 comments on commit 0364da7

Please sign in to comment.