@dolanske/vui 1.0.1 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (194) hide show
  1. package/LICENSE +673 -673
  2. package/README.md +42 -42
  3. package/dist/components/Accordion/Accordion.vue.d.ts +2 -3
  4. package/dist/components/Accordion/AccordionGroup.vue.d.ts +2 -5
  5. package/dist/components/Alert/Alert.vue.d.ts +2 -3
  6. package/dist/components/Avatar/Avatar.vue.d.ts +2 -3
  7. package/dist/components/Badge/Badge.vue.d.ts +2 -3
  8. package/dist/components/Breadcrumbs/BreadcrumbItem.vue.d.ts +2 -3
  9. package/dist/components/Breadcrumbs/Breadcrumbs.vue.d.ts +2 -3
  10. package/dist/components/Button/Button.vue.d.ts +2 -3
  11. package/dist/components/ButtonGroup/ButtonGroup.vue.d.ts +2 -3
  12. package/dist/components/Calendar/Calendar.vue.d.ts +6 -6
  13. package/dist/components/Card/Card.vue.d.ts +3 -4
  14. package/dist/components/Checkbox/Checkbox.vue.d.ts +6 -7
  15. package/dist/components/CopyClipboard/CopyClipboard.vue.d.ts +1 -2
  16. package/dist/components/Divider/Divider.vue.d.ts +2 -3
  17. package/dist/components/Drawer/Drawer.vue.d.ts +5 -6
  18. package/dist/components/Dropdown/Dropdown.vue.d.ts +3 -66
  19. package/dist/components/Dropdown/DropdownItem.vue.d.ts +2 -3
  20. package/dist/components/Dropdown/DropdownTitle.vue.d.ts +6 -6
  21. package/dist/components/Flex/Flex.vue.d.ts +2 -3
  22. package/dist/components/Grid/Grid.vue.d.ts +2 -3
  23. package/dist/components/Input/Color.vue.d.ts +5 -5
  24. package/dist/components/Input/Counter.vue.d.ts +5 -5
  25. package/dist/components/Input/Dropzone.vue.d.ts +10 -95
  26. package/dist/components/Input/File.vue.d.ts +3 -4
  27. package/dist/components/Input/Input.vue.d.ts +6 -7
  28. package/dist/components/Input/Password.vue.d.ts +1 -1
  29. package/dist/components/Input/Textarea.vue.d.ts +6 -7
  30. package/dist/components/Kbd/Kbd.vue.d.ts +1 -1
  31. package/dist/components/Kbd/KbdGroup.vue.d.ts +1 -2
  32. package/dist/components/Modal/Confirm.vue.d.ts +5 -6
  33. package/dist/components/Modal/Modal.vue.d.ts +5 -6
  34. package/dist/components/OTP/OTP.vue.d.ts +6 -7
  35. package/dist/components/OTP/OTPItem.vue.d.ts +1 -1
  36. package/dist/components/Pagination/Pagination.vue.d.ts +2 -3
  37. package/dist/components/Popout/Popout.vue.d.ts +2 -3
  38. package/dist/components/Progress/Progress.vue.d.ts +5 -5
  39. package/dist/components/Radio/Radio.vue.d.ts +6 -7
  40. package/dist/components/Radio/RadioGroup.vue.d.ts +6 -7
  41. package/dist/components/Select/Select.vue.d.ts +8 -4
  42. package/dist/components/Sheet/Sheet.vue.d.ts +5 -6
  43. package/dist/components/Sidebar/Sidebar.vue.d.ts +6 -7
  44. package/dist/components/Skeleton/Skeleton.vue.d.ts +1 -1
  45. package/dist/components/Spinner/Spinner.vue.d.ts +1 -1
  46. package/dist/components/Switch/Switch.vue.d.ts +6 -7
  47. package/dist/components/Table/Cell.vue.d.ts +2 -5
  48. package/dist/components/Table/Head.vue.d.ts +2 -3
  49. package/dist/components/Table/Root.vue.d.ts +2 -3
  50. package/dist/components/Table/table.d.ts +2 -2
  51. package/dist/components/Tabs/Tab.vue.d.ts +2 -3
  52. package/dist/components/Tabs/Tabs.vue.d.ts +6 -7
  53. package/dist/components/Toast/toast.d.ts +6 -6
  54. package/dist/components/Tooltip/Tooltip.vue.d.ts +1 -2
  55. package/dist/internal/Backdrop/Backdrop.vue.d.ts +2 -3
  56. package/dist/{vui.css → style.css} +1 -1
  57. package/dist/vui.js +5318 -5449
  58. package/package.json +72 -72
  59. package/src/App.vue +95 -95
  60. package/src/components/Accordion/Accordion.vue +91 -91
  61. package/src/components/Accordion/AccordionGroup.vue +43 -43
  62. package/src/components/Accordion/accordion.scss +82 -82
  63. package/src/components/Alert/Alert.vue +59 -59
  64. package/src/components/Alert/alert.scss +161 -161
  65. package/src/components/Avatar/Avatar.vue +53 -53
  66. package/src/components/Avatar/avatar.scss +52 -52
  67. package/src/components/Badge/Badge.vue +21 -21
  68. package/src/components/Badge/badge.scss +206 -206
  69. package/src/components/Breadcrumbs/BreadcrumbItem.vue +26 -26
  70. package/src/components/Breadcrumbs/Breadcrumbs.vue +30 -32
  71. package/src/components/Breadcrumbs/breadcrumbs.scss +31 -31
  72. package/src/components/Button/Button.vue +85 -85
  73. package/src/components/Button/button.scss +279 -279
  74. package/src/components/ButtonGroup/ButtonGroup.vue +28 -28
  75. package/src/components/ButtonGroup/button-group.scss +51 -51
  76. package/src/components/Calendar/Calendar.vue +66 -66
  77. package/src/components/Calendar/calendar.scss +83 -83
  78. package/src/components/Card/Card.vue +48 -48
  79. package/src/components/Card/card.scss +53 -53
  80. package/src/components/Checkbox/Checkbox.vue +54 -54
  81. package/src/components/Checkbox/checkbox.scss +80 -80
  82. package/src/components/CopyClipboard/CopyClipboard.vue +91 -91
  83. package/src/components/CopyClipboard/copy-clipboard.scss +25 -25
  84. package/src/components/Divider/Divider.vue +44 -44
  85. package/src/components/Divider/divider.scss +35 -35
  86. package/src/components/Drawer/Drawer.vue +97 -97
  87. package/src/components/Drawer/drawer.scss +37 -37
  88. package/src/components/Dropdown/Dropdown.vue +135 -135
  89. package/src/components/Dropdown/DropdownItem.vue +33 -33
  90. package/src/components/Dropdown/DropdownTitle.vue +14 -14
  91. package/src/components/Dropdown/dropdown-item.scss +84 -84
  92. package/src/components/Dropdown/dropdown.scss +53 -53
  93. package/src/components/Flex/Flex.vue +113 -113
  94. package/src/components/Grid/Grid.vue +80 -80
  95. package/src/components/Input/Color.vue +26 -26
  96. package/src/components/Input/Counter.vue +66 -66
  97. package/src/components/Input/Dropzone.vue +65 -65
  98. package/src/components/Input/File.vue +15 -15
  99. package/src/components/Input/Input.vue +123 -123
  100. package/src/components/Input/Password.vue +35 -35
  101. package/src/components/Input/Textarea.vue +78 -78
  102. package/src/components/Input/input.scss +302 -302
  103. package/src/components/Kbd/Kbd.vue +48 -48
  104. package/src/components/Kbd/KbdGroup.vue +27 -27
  105. package/src/components/Kbd/kbd.scss +19 -19
  106. package/src/components/Modal/Confirm.vue +56 -56
  107. package/src/components/Modal/Modal.vue +99 -99
  108. package/src/components/Modal/modal.scss +54 -54
  109. package/src/components/OTP/OTP.vue +133 -133
  110. package/src/components/OTP/OTPItem.vue +37 -37
  111. package/src/components/OTP/otp.scss +84 -84
  112. package/src/components/Pagination/Pagination.vue +77 -77
  113. package/src/components/Pagination/pagination.ts +78 -78
  114. package/src/components/Popout/Popout.vue +52 -52
  115. package/src/components/Popout/popout.scss +15 -15
  116. package/src/components/Progress/Progress.vue +103 -103
  117. package/src/components/Progress/progress.scss +47 -47
  118. package/src/components/Radio/Radio.vue +38 -38
  119. package/src/components/Radio/RadioGroup.vue +40 -40
  120. package/src/components/Radio/radio.scss +78 -78
  121. package/src/components/Select/Select.vue +211 -211
  122. package/src/components/Select/select.scss +77 -77
  123. package/src/components/Sheet/Sheet.vue +98 -98
  124. package/src/components/Sheet/sheet.scss +69 -69
  125. package/src/components/Sidebar/Sidebar.vue +115 -115
  126. package/src/components/Sidebar/sidebar.scss +124 -124
  127. package/src/components/Skeleton/Skeleton.vue +43 -43
  128. package/src/components/Skeleton/skeleton.scss +14 -14
  129. package/src/components/Spinner/Spinner.vue +42 -42
  130. package/src/components/Spinner/spinner.scss +47 -47
  131. package/src/components/Switch/Switch.vue +31 -31
  132. package/src/components/Switch/switch.scss +93 -93
  133. package/src/components/Table/Cell.vue +23 -23
  134. package/src/components/Table/Head.vue +59 -59
  135. package/src/components/Table/Root.vue +66 -66
  136. package/src/components/Table/SelectAll.vue +23 -23
  137. package/src/components/Table/SelectRow.vue +30 -30
  138. package/src/components/Table/index.ts +7 -7
  139. package/src/components/Table/table.scss +154 -154
  140. package/src/components/Table/table.ts +248 -248
  141. package/src/components/Tabs/Tab.vue +25 -25
  142. package/src/components/Tabs/Tabs.vue +89 -89
  143. package/src/components/Tabs/tabs.scss +87 -87
  144. package/src/components/Toast/Toasts.vue +52 -52
  145. package/src/components/Toast/toast.scss +45 -45
  146. package/src/components/Toast/toast.ts +75 -75
  147. package/src/components/Tooltip/Tooltip.vue +86 -86
  148. package/src/components/Tooltip/tooltip.scss +8 -8
  149. package/src/examples/ExampleAccordions.vue +58 -58
  150. package/src/examples/ExampleAlerts.vue +78 -78
  151. package/src/examples/ExampleAvatars.vue +44 -44
  152. package/src/examples/ExampleBadges.vue +48 -48
  153. package/src/examples/ExampleBreadcrumbs.vue +46 -46
  154. package/src/examples/ExampleButtons.vue +140 -140
  155. package/src/examples/ExampleCalendars.vue +40 -40
  156. package/src/examples/ExampleCards.vue +94 -94
  157. package/src/examples/ExampleCheckboxes.vue +123 -123
  158. package/src/examples/ExampleCopyClipboard.vue +47 -47
  159. package/src/examples/ExampleDividers.vue +39 -39
  160. package/src/examples/ExampleDrawers.vue +67 -67
  161. package/src/examples/ExampleDropdowns.vue +114 -114
  162. package/src/examples/ExampleFlexGrid.vue +122 -122
  163. package/src/examples/ExampleInputs.vue +234 -234
  164. package/src/examples/ExampleKBD.vue +65 -65
  165. package/src/examples/ExampleModals.vue +143 -143
  166. package/src/examples/ExamplePalette.vue +159 -159
  167. package/src/examples/ExamplePopouts.vue +41 -41
  168. package/src/examples/ExampleSheets.vue +77 -77
  169. package/src/examples/ExampleSidebars.vue +270 -270
  170. package/src/examples/ExampleSkeletons.vue +26 -26
  171. package/src/examples/ExampleSpinners.vue +78 -78
  172. package/src/examples/ExampleTables.vue +195 -195
  173. package/src/examples/ExampleTabs.vue +119 -119
  174. package/src/examples/ExampleToasts.vue +96 -96
  175. package/src/examples/ExampleTooltips.vue +70 -70
  176. package/src/examples/shared/ExampleColor.vue +28 -28
  177. package/src/index.scss +1 -1
  178. package/src/index.ts +116 -116
  179. package/src/internal/Backdrop/Backdrop.vue +22 -22
  180. package/src/internal/Backdrop/backdrop.scss +34 -34
  181. package/src/main.ts +5 -5
  182. package/src/shared/helpers.ts +117 -117
  183. package/src/shared/theme.ts +22 -22
  184. package/src/shared/types.ts +29 -29
  185. package/src/style/animation.scss +22 -22
  186. package/src/style/core.scss +125 -125
  187. package/src/style/layout.scss +233 -233
  188. package/src/style/media-query.scss +29 -29
  189. package/src/style/reset.scss +135 -135
  190. package/src/style/text.scss +124 -92
  191. package/src/style/theme.scss +195 -195
  192. package/src/style/tooltip.scss +146 -146
  193. package/src/style/typography.scss +415 -415
  194. package/src/style/utils.scss +36 -36
@@ -1,44 +1,44 @@
1
- <script setup lang='ts'>
2
- import Avatar from '../components/Avatar/Avatar.vue'
3
- import Flex from '../components/Flex/Flex.vue'
4
-
5
- const variants = ['s', 'm', 'l', 96] as const
6
- </script>
7
-
8
- <template>
9
- <div class="mb-xxl">
10
- <h3 class="mb-l">
11
- Avatars
12
- </h3>
13
- <table>
14
- <tbody>
15
- <tr>
16
- <th>Base S, M, L <br> + custom size</th>
17
- <td>
18
- <Flex>
19
- <Avatar v-for="size in variants" :key="size" :size />
20
- </Flex>
21
- </td>
22
- </tr>
23
- <tr>
24
- <th>Photo</th>
25
- <td>
26
- <Flex>
27
- <Avatar v-for="size in variants" :key="size" :size url="https://i.imgur.com/bHWgZfD.jpeg" />
28
- </Flex>
29
- </td>
30
- </tr>
31
- <tr>
32
- <th>Abbreviation</th>
33
- <td>
34
- <Flex>
35
- <Avatar v-for="size in variants" :key="size" :size>
36
- AB
37
- </Avatar>
38
- </Flex>
39
- </td>
40
- </tr>
41
- </tbody>
42
- </table>
43
- </div>
44
- </template>
1
+ <script setup lang='ts'>
2
+ import Avatar from '../components/Avatar/Avatar.vue'
3
+ import Flex from '../components/Flex/Flex.vue'
4
+
5
+ const variants = ['s', 'm', 'l', 96] as const
6
+ </script>
7
+
8
+ <template>
9
+ <div class="mb-xxl">
10
+ <h3 class="mb-l">
11
+ Avatars
12
+ </h3>
13
+ <table>
14
+ <tbody>
15
+ <tr>
16
+ <th>Base S, M, L <br> + custom size</th>
17
+ <td>
18
+ <Flex>
19
+ <Avatar v-for="size in variants" :key="size" :size />
20
+ </Flex>
21
+ </td>
22
+ </tr>
23
+ <tr>
24
+ <th>Photo</th>
25
+ <td>
26
+ <Flex>
27
+ <Avatar v-for="size in variants" :key="size" :size url="https://i.imgur.com/bHWgZfD.jpeg" />
28
+ </Flex>
29
+ </td>
30
+ </tr>
31
+ <tr>
32
+ <th>Abbreviation</th>
33
+ <td>
34
+ <Flex>
35
+ <Avatar v-for="size in variants" :key="size" :size>
36
+ AB
37
+ </Avatar>
38
+ </Flex>
39
+ </td>
40
+ </tr>
41
+ </tbody>
42
+ </table>
43
+ </div>
44
+ </template>
@@ -1,48 +1,48 @@
1
- <script setup lang='ts'>
2
- import Badge from '../components/Badge/Badge.vue'
3
- import Flex from '../components/Flex/Flex.vue'
4
-
5
- const variants = ['neutral', 'danger', 'warning', 'success', 'info', 'accent'] as const
6
- </script>
7
-
8
- <template>
9
- <div class="mb-xxl">
10
- <h3 class="mb-l">
11
- Badges
12
- </h3>
13
- <table>
14
- <tbody>
15
- <tr>
16
- <th>Base</th>
17
- <td>
18
- <Flex>
19
- <Badge v-for="variant in variants" :key="variant" :variant>
20
- Badge
21
- </Badge>
22
- </Flex>
23
- </td>
24
- </tr>
25
- <tr>
26
- <th>Outline</th>
27
- <td>
28
- <Flex>
29
- <Badge v-for="variant in variants" :key="variant" :variant outline>
30
- Badge
31
- </Badge>
32
- </Flex>
33
- </td>
34
- </tr>
35
- <tr>
36
- <th>Filled</th>
37
- <td>
38
- <Flex>
39
- <Badge v-for="variant in variants" :key="variant" :variant filled>
40
- Badge
41
- </Badge>
42
- </Flex>
43
- </td>
44
- </tr>
45
- </tbody>
46
- </table>
47
- </div>
48
- </template>
1
+ <script setup lang='ts'>
2
+ import Badge from '../components/Badge/Badge.vue'
3
+ import Flex from '../components/Flex/Flex.vue'
4
+
5
+ const variants = ['neutral', 'danger', 'warning', 'success', 'info', 'accent'] as const
6
+ </script>
7
+
8
+ <template>
9
+ <div class="mb-xxl">
10
+ <h3 class="mb-l">
11
+ Badges
12
+ </h3>
13
+ <table>
14
+ <tbody>
15
+ <tr>
16
+ <th>Base</th>
17
+ <td>
18
+ <Flex>
19
+ <Badge v-for="variant in variants" :key="variant" :variant>
20
+ Badge
21
+ </Badge>
22
+ </Flex>
23
+ </td>
24
+ </tr>
25
+ <tr>
26
+ <th>Outline</th>
27
+ <td>
28
+ <Flex>
29
+ <Badge v-for="variant in variants" :key="variant" :variant outline>
30
+ Badge
31
+ </Badge>
32
+ </Flex>
33
+ </td>
34
+ </tr>
35
+ <tr>
36
+ <th>Filled</th>
37
+ <td>
38
+ <Flex>
39
+ <Badge v-for="variant in variants" :key="variant" :variant filled>
40
+ Badge
41
+ </Badge>
42
+ </Flex>
43
+ </td>
44
+ </tr>
45
+ </tbody>
46
+ </table>
47
+ </div>
48
+ </template>
@@ -1,46 +1,46 @@
1
- <script setup lang='ts'>
2
- import { Icon } from '@iconify/vue'
3
- import BreadcrumbItem from '../components/Breadcrumbs/BreadcrumbItem.vue'
4
- import Breadcrumbs from '../components/Breadcrumbs/Breadcrumbs.vue'
5
- import Button from '../components/Button/Button.vue'
6
- </script>
7
-
8
- <template>
9
- <div class="mb-xxl">
10
- <h3 class="mb-l">
11
- Breadcrumbs
12
- </h3>
13
-
14
- <table>
15
- <tbody>
16
- <tr>
17
- <th>Base with links</th>
18
- <td>
19
- <Breadcrumbs>
20
- <BreadcrumbItem label="Home" href="#" />
21
- <BreadcrumbItem label="About" href="#" />
22
- <BreadcrumbItem label="You" />
23
- </Breadcrumbs>
24
- </td>
25
- </tr>
26
- <tr>
27
- <th>With components</th>
28
- <td>
29
- <Breadcrumbs>
30
- <BreadcrumbItem label="Home" href="#" />
31
- <BreadcrumbItem label="About" href="#" />
32
- <BreadcrumbItem>
33
- <Button size="s">
34
- Switch
35
- <template #end>
36
- <Icon icon="ph:caret-down" />
37
- </template>
38
- </Button>
39
- </BreadcrumbItem>
40
- </Breadcrumbs>
41
- </td>
42
- </tr>
43
- </tbody>
44
- </table>
45
- </div>
46
- </template>
1
+ <script setup lang='ts'>
2
+ import { Icon } from '@iconify/vue'
3
+ import BreadcrumbItem from '../components/Breadcrumbs/BreadcrumbItem.vue'
4
+ import Breadcrumbs from '../components/Breadcrumbs/Breadcrumbs.vue'
5
+ import Button from '../components/Button/Button.vue'
6
+ </script>
7
+
8
+ <template>
9
+ <div class="mb-xxl">
10
+ <h3 class="mb-l">
11
+ Breadcrumbs
12
+ </h3>
13
+
14
+ <table>
15
+ <tbody>
16
+ <tr>
17
+ <th>Base with links</th>
18
+ <td>
19
+ <Breadcrumbs>
20
+ <BreadcrumbItem label="Home" href="#" />
21
+ <BreadcrumbItem label="About" href="#" />
22
+ <BreadcrumbItem label="You" />
23
+ </Breadcrumbs>
24
+ </td>
25
+ </tr>
26
+ <tr>
27
+ <th>With components</th>
28
+ <td>
29
+ <Breadcrumbs>
30
+ <BreadcrumbItem label="Home" href="#" />
31
+ <BreadcrumbItem label="About" href="#" />
32
+ <BreadcrumbItem>
33
+ <Button size="s">
34
+ Switch
35
+ <template #end>
36
+ <Icon icon="ph:caret-down" />
37
+ </template>
38
+ </Button>
39
+ </BreadcrumbItem>
40
+ </Breadcrumbs>
41
+ </td>
42
+ </tr>
43
+ </tbody>
44
+ </table>
45
+ </div>
46
+ </template>
@@ -1,140 +1,140 @@
1
- <script setup lang='ts'>
2
- import { Icon } from '@iconify/vue'
3
- import Button from '../components/Button/Button.vue'
4
- import ButtonGroup from '../components/ButtonGroup/ButtonGroup.vue'
5
- import Flex from '../components/Flex/Flex.vue'
6
-
7
- const variants = ['gray', 'fill', 'danger', 'success', 'link', 'accent'] as const
8
- </script>
9
-
10
- <template>
11
- <div class="mb-xxl">
12
- <h3 class="mb-l">
13
- Buttons
14
- </h3>
15
- <table>
16
- <tbody>
17
- <tr>
18
- <th>Base</th>
19
- <td>
20
- <Flex gap="s">
21
- <Button v-for="btn in variants" :key="btn" :variant="btn">
22
- Button
23
- </Button>
24
- </Flex>
25
- </td>
26
- </tr>
27
- <tr>
28
- <th>Base + large</th>
29
- <td>
30
- <Flex gap="s">
31
- <Button v-for="btn in variants" :key="btn" :variant="btn" size="l">
32
- Button
33
- </Button>
34
- </Flex>
35
- </td>
36
- </tr>
37
- <tr>
38
- <th>Base + small</th>
39
- <td>
40
- <Flex gap="s">
41
- <Button v-for="btn in variants" :key="btn" :variant="btn" size="s">
42
- Button
43
- </Button>
44
- </Flex>
45
- </td>
46
- </tr>
47
- <tr>
48
- <th>Plain</th>
49
- <td>
50
- <Flex gap="s">
51
- <Button v-for="btn in variants" :key="btn" :variant="btn" plain>
52
- Button
53
- </Button>
54
- </Flex>
55
- </td>
56
- </tr>
57
- <tr>
58
- <th>Outline</th>
59
- <td>
60
- <Flex gap="s">
61
- <Button v-for="btn in variants" :key="btn" :variant="btn" outline>
62
- Button
63
- </Button>
64
- </Flex>
65
- </td>
66
- </tr>
67
- <tr>
68
- <th>Disabled</th>
69
- <td>
70
- <Flex gap="s">
71
- <Button v-for="btn in variants" :key="btn" :variant="btn" disabled>
72
- Button
73
- </Button>
74
- </Flex>
75
- </td>
76
- </tr>
77
- <tr>
78
- <th>Squar + icon</th>
79
- <td>
80
- <Flex gap="s">
81
- <Button v-for="btn in variants" :key="btn" :variant="btn" square icon="ph:info" />
82
- </Flex>
83
- </td>
84
- </tr>
85
- <tr>
86
- <th>Squar + icon + small</th>
87
- <td>
88
- <Flex gap="s">
89
- <Button v-for="btn in variants" :key="btn" :variant="btn" square icon="ph:info" size="s" />
90
- </Flex>
91
- </td>
92
- </tr>
93
- <tr>
94
- <th>Squar + icon + large</th>
95
- <td>
96
- <Flex gap="s">
97
- <Button v-for="btn in variants" :key="btn" :variant="btn" square icon="ph:info" size="l" />
98
- </Flex>
99
- </td>
100
- </tr>
101
- <tr>
102
- <th>Icon + text</th>
103
- <td>
104
- <Flex gap="s">
105
- <Button v-for="btn in variants" :key="btn" :variant="btn">
106
- <template #start>
107
- <Icon icon="ph:arrow-left" />
108
- </template>
109
- Prev
110
- <template #end>
111
- <Icon icon="ph:arrow-right" />
112
- </template>
113
- </Button>
114
- </Flex>
115
- </td>
116
- </tr>
117
- <tr>
118
- <td>Button group</td>
119
- <td>
120
- <Flex gap="s" wrap>
121
- <ButtonGroup v-for="btn in variants" :key="btn">
122
- <Button :variant="btn">
123
- Hello
124
- </Button>
125
- <Button :variant="btn" icon="ph:caret-down" />
126
- </ButtonGroup>
127
-
128
- <ButtonGroup>
129
- <Button square icon="ph:text-b-bold" active />
130
- <Button square icon="ph:text-bold" />
131
- <Button square icon="ph:text-italic" />
132
- <Button square icon="ph:text-a-underline" />
133
- </ButtonGroup>
134
- </Flex>
135
- </td>
136
- </tr>
137
- </tbody>
138
- </table>
139
- </div>
140
- </template>
1
+ <script setup lang='ts'>
2
+ import { Icon } from '@iconify/vue'
3
+ import Button from '../components/Button/Button.vue'
4
+ import ButtonGroup from '../components/ButtonGroup/ButtonGroup.vue'
5
+ import Flex from '../components/Flex/Flex.vue'
6
+
7
+ const variants = ['gray', 'fill', 'danger', 'success', 'link', 'accent'] as const
8
+ </script>
9
+
10
+ <template>
11
+ <div class="mb-xxl">
12
+ <h3 class="mb-l">
13
+ Buttons
14
+ </h3>
15
+ <table>
16
+ <tbody>
17
+ <tr>
18
+ <th>Base</th>
19
+ <td>
20
+ <Flex gap="s">
21
+ <Button v-for="btn in variants" :key="btn" :variant="btn">
22
+ Button
23
+ </Button>
24
+ </Flex>
25
+ </td>
26
+ </tr>
27
+ <tr>
28
+ <th>Base + large</th>
29
+ <td>
30
+ <Flex gap="s">
31
+ <Button v-for="btn in variants" :key="btn" :variant="btn" size="l">
32
+ Button
33
+ </Button>
34
+ </Flex>
35
+ </td>
36
+ </tr>
37
+ <tr>
38
+ <th>Base + small</th>
39
+ <td>
40
+ <Flex gap="s">
41
+ <Button v-for="btn in variants" :key="btn" :variant="btn" size="s">
42
+ Button
43
+ </Button>
44
+ </Flex>
45
+ </td>
46
+ </tr>
47
+ <tr>
48
+ <th>Plain</th>
49
+ <td>
50
+ <Flex gap="s">
51
+ <Button v-for="btn in variants" :key="btn" :variant="btn" plain>
52
+ Button
53
+ </Button>
54
+ </Flex>
55
+ </td>
56
+ </tr>
57
+ <tr>
58
+ <th>Outline</th>
59
+ <td>
60
+ <Flex gap="s">
61
+ <Button v-for="btn in variants" :key="btn" :variant="btn" outline>
62
+ Button
63
+ </Button>
64
+ </Flex>
65
+ </td>
66
+ </tr>
67
+ <tr>
68
+ <th>Disabled</th>
69
+ <td>
70
+ <Flex gap="s">
71
+ <Button v-for="btn in variants" :key="btn" :variant="btn" disabled>
72
+ Button
73
+ </Button>
74
+ </Flex>
75
+ </td>
76
+ </tr>
77
+ <tr>
78
+ <th>Squar + icon</th>
79
+ <td>
80
+ <Flex gap="s">
81
+ <Button v-for="btn in variants" :key="btn" :variant="btn" square icon="ph:info" />
82
+ </Flex>
83
+ </td>
84
+ </tr>
85
+ <tr>
86
+ <th>Squar + icon + small</th>
87
+ <td>
88
+ <Flex gap="s">
89
+ <Button v-for="btn in variants" :key="btn" :variant="btn" square icon="ph:info" size="s" />
90
+ </Flex>
91
+ </td>
92
+ </tr>
93
+ <tr>
94
+ <th>Squar + icon + large</th>
95
+ <td>
96
+ <Flex gap="s">
97
+ <Button v-for="btn in variants" :key="btn" :variant="btn" square icon="ph:info" size="l" />
98
+ </Flex>
99
+ </td>
100
+ </tr>
101
+ <tr>
102
+ <th>Icon + text</th>
103
+ <td>
104
+ <Flex gap="s">
105
+ <Button v-for="btn in variants" :key="btn" :variant="btn">
106
+ <template #start>
107
+ <Icon icon="ph:arrow-left" />
108
+ </template>
109
+ Prev
110
+ <template #end>
111
+ <Icon icon="ph:arrow-right" />
112
+ </template>
113
+ </Button>
114
+ </Flex>
115
+ </td>
116
+ </tr>
117
+ <tr>
118
+ <td>Button group</td>
119
+ <td>
120
+ <Flex gap="s" wrap>
121
+ <ButtonGroup v-for="btn in variants" :key="btn">
122
+ <Button :variant="btn">
123
+ Hello
124
+ </Button>
125
+ <Button :variant="btn" icon="ph:caret-down" />
126
+ </ButtonGroup>
127
+
128
+ <ButtonGroup>
129
+ <Button square icon="ph:text-b-bold" active />
130
+ <Button square icon="ph:text-bold" />
131
+ <Button square icon="ph:text-italic" />
132
+ <Button square icon="ph:text-a-underline" />
133
+ </ButtonGroup>
134
+ </Flex>
135
+ </td>
136
+ </tr>
137
+ </tbody>
138
+ </table>
139
+ </div>
140
+ </template>
@@ -1,40 +1,40 @@
1
- <script setup lang="ts">
2
- import { ref } from 'vue'
3
- import Button from '../components/Button/Button.vue'
4
- import Calendar from '../components/Calendar/Calendar.vue'
5
-
6
- const date = ref(Date.now())
7
- </script>
8
-
9
- <template>
10
- <div class="mb-xxl">
11
- <h3 class="mb-l">
12
- Calendars
13
- </h3>
14
-
15
- <p class="mb-s">
16
- Using the <a href="https://vue3datepicker.com/" target="_blank">Vue Datepicker</a> component. By default it always outputs a javascript Date object. So it is up to the user to format the dates themselves.
17
- </p>
18
-
19
- <table>
20
- <tbody>
21
- <tr>
22
- <th>Base</th>
23
- <td>
24
- <Calendar v-model="date" format="dd/MM/yyyy">
25
- <template #trigger>
26
- <Button>{{ date ?? 'Choose date' }}</Button>
27
- </template>
28
- </Calendar>
29
- </td>
30
- </tr>
31
- <tr>
32
- <th>Inline</th>
33
- <th>
34
- <Calendar inline />
35
- </th>
36
- </tr>
37
- </tbody>
38
- </table>
39
- </div>
40
- </template>
1
+ <script setup lang="ts">
2
+ import { ref } from 'vue'
3
+ import Button from '../components/Button/Button.vue'
4
+ import Calendar from '../components/Calendar/Calendar.vue'
5
+
6
+ const date = ref(Date.now())
7
+ </script>
8
+
9
+ <template>
10
+ <div class="mb-xxl">
11
+ <h3 class="mb-l">
12
+ Calendars
13
+ </h3>
14
+
15
+ <p class="mb-s">
16
+ Using the <a href="https://vue3datepicker.com/" target="_blank">Vue Datepicker</a> component. By default it always outputs a javascript Date object. So it is up to the user to format the dates themselves.
17
+ </p>
18
+
19
+ <table>
20
+ <tbody>
21
+ <tr>
22
+ <th>Base</th>
23
+ <td>
24
+ <Calendar v-model="date" format="dd/MM/yyyy">
25
+ <template #trigger>
26
+ <Button>{{ date ?? 'Choose date' }}</Button>
27
+ </template>
28
+ </Calendar>
29
+ </td>
30
+ </tr>
31
+ <tr>
32
+ <th>Inline</th>
33
+ <th>
34
+ <Calendar inline />
35
+ </th>
36
+ </tr>
37
+ </tbody>
38
+ </table>
39
+ </div>
40
+ </template>