@maz-ui/mcp 4.0.0-beta.26

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 (175) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +264 -0
  3. package/bin/maz-ui-mcp.mjs +7 -0
  4. package/dist/mcp.d.mts +13 -0
  5. package/dist/mcp.d.ts +13 -0
  6. package/dist/mcp.mjs +586 -0
  7. package/docs/generated-docs/maz-accordion.doc.md +21 -0
  8. package/docs/generated-docs/maz-animated-counter.doc.md +17 -0
  9. package/docs/generated-docs/maz-animated-element.doc.md +14 -0
  10. package/docs/generated-docs/maz-animated-text.doc.md +14 -0
  11. package/docs/generated-docs/maz-avatar.doc.md +44 -0
  12. package/docs/generated-docs/maz-backdrop.doc.md +61 -0
  13. package/docs/generated-docs/maz-badge.doc.md +16 -0
  14. package/docs/generated-docs/maz-bottom-sheet.doc.md +21 -0
  15. package/docs/generated-docs/maz-btn.doc.md +30 -0
  16. package/docs/generated-docs/maz-card-spotlight.doc.md +16 -0
  17. package/docs/generated-docs/maz-card.doc.md +39 -0
  18. package/docs/generated-docs/maz-carousel.doc.md +16 -0
  19. package/docs/generated-docs/maz-chart.doc.md +10 -0
  20. package/docs/generated-docs/maz-checkbox.doc.md +34 -0
  21. package/docs/generated-docs/maz-checklist.doc.md +30 -0
  22. package/docs/generated-docs/maz-circular-progress-bar.doc.md +27 -0
  23. package/docs/generated-docs/maz-date-picker.doc.md +52 -0
  24. package/docs/generated-docs/maz-dialog-confirm.doc.md +24 -0
  25. package/docs/generated-docs/maz-dialog.doc.md +22 -0
  26. package/docs/generated-docs/maz-drawer.doc.md +26 -0
  27. package/docs/generated-docs/maz-dropdown.doc.md +42 -0
  28. package/docs/generated-docs/maz-dropzone.doc.md +82 -0
  29. package/docs/generated-docs/maz-expand-animation.doc.md +12 -0
  30. package/docs/generated-docs/maz-fullscreen-loader.doc.md +13 -0
  31. package/docs/generated-docs/maz-gallery.doc.md +17 -0
  32. package/docs/generated-docs/maz-icon.doc.md +18 -0
  33. package/docs/generated-docs/maz-input-code.doc.md +25 -0
  34. package/docs/generated-docs/maz-input-number.doc.md +31 -0
  35. package/docs/generated-docs/maz-input-phone-number.doc.md +56 -0
  36. package/docs/generated-docs/maz-input-price.doc.md +26 -0
  37. package/docs/generated-docs/maz-input-tags.doc.md +24 -0
  38. package/docs/generated-docs/maz-input.doc.md +54 -0
  39. package/docs/generated-docs/maz-lazy-img.doc.md +31 -0
  40. package/docs/generated-docs/maz-link.doc.md +31 -0
  41. package/docs/generated-docs/maz-loading-bar.doc.md +6 -0
  42. package/docs/generated-docs/maz-pagination.doc.md +22 -0
  43. package/docs/generated-docs/maz-popover.doc.md +70 -0
  44. package/docs/generated-docs/maz-pull-to-refresh.doc.md +31 -0
  45. package/docs/generated-docs/maz-radio-buttons.doc.md +33 -0
  46. package/docs/generated-docs/maz-radio.doc.md +33 -0
  47. package/docs/generated-docs/maz-reading-progress-bar.doc.md +18 -0
  48. package/docs/generated-docs/maz-select-country.doc.md +44 -0
  49. package/docs/generated-docs/maz-select.doc.md +65 -0
  50. package/docs/generated-docs/maz-slider.doc.md +20 -0
  51. package/docs/generated-docs/maz-spinner.doc.md +6 -0
  52. package/docs/generated-docs/maz-stepper.doc.md +29 -0
  53. package/docs/generated-docs/maz-switch.doc.md +31 -0
  54. package/docs/generated-docs/maz-table-cell.doc.md +5 -0
  55. package/docs/generated-docs/maz-table-row.doc.md +11 -0
  56. package/docs/generated-docs/maz-table-title.doc.md +5 -0
  57. package/docs/generated-docs/maz-table.doc.md +66 -0
  58. package/docs/generated-docs/maz-tabs-bar.doc.md +18 -0
  59. package/docs/generated-docs/maz-tabs-content-item.doc.md +11 -0
  60. package/docs/generated-docs/maz-tabs-content.doc.md +5 -0
  61. package/docs/generated-docs/maz-tabs.doc.md +17 -0
  62. package/docs/generated-docs/maz-textarea.doc.md +41 -0
  63. package/docs/src/components/index.md +8 -0
  64. package/docs/src/components/maz-accordion.md +80 -0
  65. package/docs/src/components/maz-animated-counter.md +124 -0
  66. package/docs/src/components/maz-animated-element.md +36 -0
  67. package/docs/src/components/maz-animated-text.md +36 -0
  68. package/docs/src/components/maz-avatar.md +179 -0
  69. package/docs/src/components/maz-backdrop.md +16 -0
  70. package/docs/src/components/maz-badge.md +222 -0
  71. package/docs/src/components/maz-bottom-sheet.md +398 -0
  72. package/docs/src/components/maz-btn.md +526 -0
  73. package/docs/src/components/maz-card-spotlight.md +163 -0
  74. package/docs/src/components/maz-card.md +447 -0
  75. package/docs/src/components/maz-carousel.md +127 -0
  76. package/docs/src/components/maz-chart.md +346 -0
  77. package/docs/src/components/maz-checkbox.md +168 -0
  78. package/docs/src/components/maz-checklist.md +414 -0
  79. package/docs/src/components/maz-circular-progress-bar.md +147 -0
  80. package/docs/src/components/maz-date-picker.md +1078 -0
  81. package/docs/src/components/maz-dialog-confirm.md +240 -0
  82. package/docs/src/components/maz-dialog.md +208 -0
  83. package/docs/src/components/maz-drawer.md +177 -0
  84. package/docs/src/components/maz-dropdown.md +650 -0
  85. package/docs/src/components/maz-dropzone.md +442 -0
  86. package/docs/src/components/maz-expand-animation.md +99 -0
  87. package/docs/src/components/maz-fullscreen-loader.md +58 -0
  88. package/docs/src/components/maz-gallery.md +85 -0
  89. package/docs/src/components/maz-icon.md +85 -0
  90. package/docs/src/components/maz-input-code.md +61 -0
  91. package/docs/src/components/maz-input-number.md +81 -0
  92. package/docs/src/components/maz-input-phone-number.md +867 -0
  93. package/docs/src/components/maz-input-price.md +58 -0
  94. package/docs/src/components/maz-input-tags.md +114 -0
  95. package/docs/src/components/maz-input.md +453 -0
  96. package/docs/src/components/maz-lazy-img.md +24 -0
  97. package/docs/src/components/maz-link.md +156 -0
  98. package/docs/src/components/maz-loading-bar.md +26 -0
  99. package/docs/src/components/maz-pagination.md +81 -0
  100. package/docs/src/components/maz-popover.md +1414 -0
  101. package/docs/src/components/maz-pull-to-refresh.md +49 -0
  102. package/docs/src/components/maz-radio-buttons.md +456 -0
  103. package/docs/src/components/maz-radio.md +141 -0
  104. package/docs/src/components/maz-reading-progress-bar.md +74 -0
  105. package/docs/src/components/maz-select-country.md +636 -0
  106. package/docs/src/components/maz-select.md +439 -0
  107. package/docs/src/components/maz-slider.md +191 -0
  108. package/docs/src/components/maz-spinner.md +93 -0
  109. package/docs/src/components/maz-stepper.md +418 -0
  110. package/docs/src/components/maz-switch.md +92 -0
  111. package/docs/src/components/maz-table.md +571 -0
  112. package/docs/src/components/maz-tabs.md +231 -0
  113. package/docs/src/components/maz-textarea.md +218 -0
  114. package/docs/src/composables/use-aos.md +34 -0
  115. package/docs/src/composables/use-breakpoints.md +35 -0
  116. package/docs/src/composables/use-dialog.md +88 -0
  117. package/docs/src/composables/use-display-names.md +174 -0
  118. package/docs/src/composables/use-form-validator.md +1149 -0
  119. package/docs/src/composables/use-idle-timeout.md +256 -0
  120. package/docs/src/composables/use-reading-time.md +168 -0
  121. package/docs/src/composables/use-string-matching.md +63 -0
  122. package/docs/src/composables/use-swipe.md +223 -0
  123. package/docs/src/composables/use-timer.md +130 -0
  124. package/docs/src/composables/use-toast.md +71 -0
  125. package/docs/src/composables/use-user-visibility.md +169 -0
  126. package/docs/src/composables/use-wait.md +62 -0
  127. package/docs/src/composables/use-window-size.md +18 -0
  128. package/docs/src/demo/DemoAuthPage.vue +178 -0
  129. package/docs/src/demo/DemoDashboardPage.vue +298 -0
  130. package/docs/src/demo/DemoProductPage.vue +135 -0
  131. package/docs/src/directives/click-outside.md +275 -0
  132. package/docs/src/directives/fullscreen-img.md +101 -0
  133. package/docs/src/directives/lazy-img.md +184 -0
  134. package/docs/src/directives/tooltip.md +458 -0
  135. package/docs/src/directives/zoom-img.md +127 -0
  136. package/docs/src/guide/cli.md +144 -0
  137. package/docs/src/guide/getting-started.md +284 -0
  138. package/docs/src/guide/icon-set.md +60 -0
  139. package/docs/src/guide/icons.md +481 -0
  140. package/docs/src/guide/mcp.md +210 -0
  141. package/docs/src/guide/migration-v4.md +898 -0
  142. package/docs/src/guide/nuxt.md +411 -0
  143. package/docs/src/guide/resolvers.md +697 -0
  144. package/docs/src/guide/themes.md +789 -0
  145. package/docs/src/guide/translations.md +1173 -0
  146. package/docs/src/guide/vue.md +243 -0
  147. package/docs/src/helpers/camel-case.md +14 -0
  148. package/docs/src/helpers/capitalize.md +51 -0
  149. package/docs/src/helpers/check-availability.md +14 -0
  150. package/docs/src/helpers/country-code-to-unicode-flag.md +213 -0
  151. package/docs/src/helpers/currency.md +67 -0
  152. package/docs/src/helpers/date.md +67 -0
  153. package/docs/src/helpers/debounce-callback.md +14 -0
  154. package/docs/src/helpers/debounce-id.md +14 -0
  155. package/docs/src/helpers/debounce.md +14 -0
  156. package/docs/src/helpers/get-country-flag-url.md +156 -0
  157. package/docs/src/helpers/is-client.md +14 -0
  158. package/docs/src/helpers/is-equal.md +14 -0
  159. package/docs/src/helpers/is-standalone-mode.md +14 -0
  160. package/docs/src/helpers/kebab-case.md +14 -0
  161. package/docs/src/helpers/normalize-string.md +14 -0
  162. package/docs/src/helpers/number.md +65 -0
  163. package/docs/src/helpers/pascal-case.md +14 -0
  164. package/docs/src/helpers/script-loader.md +14 -0
  165. package/docs/src/helpers/sleep.md +14 -0
  166. package/docs/src/helpers/snake-case.md +14 -0
  167. package/docs/src/helpers/throttle-id.md +14 -0
  168. package/docs/src/helpers/throttle.md +14 -0
  169. package/docs/src/index.md +555 -0
  170. package/docs/src/made-with-maz-ui.md +58 -0
  171. package/docs/src/plugins/aos.md +347 -0
  172. package/docs/src/plugins/dialog.md +411 -0
  173. package/docs/src/plugins/toast.md +349 -0
  174. package/docs/src/plugins/wait.md +109 -0
  175. package/package.json +84 -0
@@ -0,0 +1,66 @@
1
+ ## Props
2
+
3
+ | Name | Description | Type | Required | Default | Possible values |
4
+ | ---------------------- | ---------------------------------------------------------------------------------------- | --------------------------------------------------- | -------- | ---------------------------------------- | ---------------------------- |
5
+ | **table-class** | CSS class of the table element | `HTMLAttributes['class']` | No | `undefined` | - |
6
+ | **table-style** | CSS style of the table element | `HTMLAttributes['style']` | No | `undefined` | - |
7
+ | **model-value** | `v-model` <br/>List of selected rows | `(string \| boolean \| number)[]` | No | `undefined` | - |
8
+ | **size** | Size of the table | `MazSize` | No | `'md'` | `xl, lg, md, sm, xs, mini` |
9
+ | **input-size** | Size of the search inputs | `MazSize` | No | `undefined` | `xl, lg, md, sm, xs, mini` |
10
+ | **title** | Title of the table | `string` | No | `undefined` | - |
11
+ | **headers** | Headers of the table | `MazTableHeader[]` | No | `undefined` | - |
12
+ | **sortable** | Enable sort feature on all columns | `boolean` | No | `false` | - |
13
+ | **headers-align** | Align all headers | `string` | No | `'left'` | - |
14
+ | **rows** | Rows of the table | `T[]` | No | `undefined` | - |
15
+ | **hoverable** | Add hover effect on rows | `boolean` | No | `false` | - |
16
+ | **search** | Enable search feature in table header | `boolean` | No | `false` | - |
17
+ | **hide-search-in-row** | Disable search in rows - useful to filter data yourself or make search request to server | `boolean` | No | `false` | - |
18
+ | **hide-search-by** | Disable search by column (remove select input "search by") | `boolean` | No | `false` | - |
19
+ | **search-query** | `v-model:search-query` <br/>Search query in input | `string` | No | `undefined` | - |
20
+ | **background-odd** | Add background color to odd rows | `boolean` | No | `false` | - |
21
+ | **background-even** | Add background color to even rows | `boolean` | No | `false` | - |
22
+ | **elevation** | Add shadow to the table | `boolean` | No | `false` | - |
23
+ | **divider** | No divider between rows | `boolean` | No | `false` | - |
24
+ | **caption** | Caption of the table | `string` | No | `undefined` | - |
25
+ | **caption-side** | Caption side | `string` | No | `'bottom'` | `top, bottom` |
26
+ | **pagination** | Add pagination in table footer | `boolean` | No | `false` | - |
27
+ | **page** | `v-model:page` <br/>Current page of pagination | `number` | No | `1` | - |
28
+ | **page-size** | `v-model:page-size` <br/>Number of items per page | `number` | No | `20` | - |
29
+ | **total-pages** | Total number of pages | `number` | No | `undefined` | - |
30
+ | **paginate-rows** | Don't paginate rows - useful to make pagination request with your server | `boolean` | No | `true` | - |
31
+ | **total-items** | Total number of items | `number` | No | `undefined` | - |
32
+ | **loading** | Loading state | `boolean` | No | `false` | - |
33
+ | **selectable** | Enable selection of rows | `boolean` | No | `false` | - |
34
+ | **selected-key** | Enable selection of rows - key of the selected row | `string` | No | `undefined` | - |
35
+ | **table-layout** | Table layout | `string` | No | `undefined` | `auto, fixed` |
36
+ | **color** | Color of the component | `MazColor` | No | `'primary'` | - |
37
+ | **translations** | Translations of the table | `DeepPartial<MazTranslationsNestedSchema['table']>` | No | `Translations from @maz-ui/translations` | - |
38
+ | **rounded-size** | Size radius of the component's border | `string` | No | `'lg'` | `none, sm, md, lg, xl, full` |
39
+ | **scrollable** | Enable scrollable on table | `boolean` | No | `false` | - |
40
+
41
+ ## Events
42
+
43
+ | Event name | Properties | Description |
44
+ | ------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------- |
45
+ | update:model-value | **value** `(Row \| string \| number \| boolean)[]` - List of selected rows (if selectedKey is defined, it will be the value of the selectedKey of the row) | Emitted when a row is selected |
46
+ | update:search-query | **searchQuery** `string` - Search query | Emitted when entering a value in the search input |
47
+ | update:page | **page** `number` - Current page | Emitted when the current page of pagination changes |
48
+ | update:page-size | **pageSize** `number` - Current page size | Emitted when the page size of pagination changes |
49
+
50
+ ## Slots
51
+
52
+ | Name | Description | Bindings |
53
+ | ---------------------------- | ----------------------------------------- | ---------------------------------------------------------------------------- |
54
+ | title | Replace the title of the table | |
55
+ | caption | Add caption on top or bottom of the table | |
56
+ | thead | Content in thead element | |
57
+ | header | Replace column header | **header** `Object` - Header data<br/>**label** `String` - Header label |
58
+ | `header-label-${header.key}` | Replace column header label | <br/>**header** `Object` - Header data<br/>**label** `String` - Header label |
59
+ | actions-header | Replace text of actions header | |
60
+ | default | | |
61
+ | select | Replace checkbox component | **row** `Object` - Row data<br/>**selected** `Boolean` - If selected or not |
62
+ | cell | Replace all row cells | **row** `Object` - Row data<br/>**value** `any` - Cell value |
63
+ | `cell-${key}` | Replace row cells of column | <br/>**row** `Object` - Row data<br/>**value** `any` - Cell value |
64
+ | actions | Add actions column | **row** `Object` - Row data |
65
+ | no-results | Replace the no results element | |
66
+ | no-results-text | replace no results test only | |
@@ -0,0 +1,18 @@
1
+ ## Props
2
+
3
+ | Name | Description | Type | Required | Default |
4
+ | --------------- | -------------------------------------------------------------------------- | ------------------ | -------- | ----------- |
5
+ | **items** | The items to display in the tabs bar | `MazTabsBarItem[]` | Yes | `undefined` |
6
+ | **persistent** | Will add a query param to the url to keep the selected tab on page refresh | `boolean` | No | `false` |
7
+ | **query-param** | The name of the query param to add to the url | `string` | No | `tab` |
8
+ | **block** | Will make the tabs bar full width | `boolean` | No | `false` |
9
+ | **elevation** | Will remove the elevation | `boolean` | No | `false` |
10
+ | **auto-scroll** | Will add a scroll on the tabs bar to show selected element | `boolean` | No | `true` |
11
+ | **bordered** | Will add a border to the tabs bar | `boolean` | No | `true` |
12
+
13
+ ## Slots
14
+
15
+ | Name | Description | Bindings |
16
+ | ------------- | ------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------- |
17
+ | item | Content of item to display in the tabs bar | **item** `MazTabsBarItem[]` - all data of the item<br/>**active** `boolean` - `true` if the tab is active<br/>**index** `number` - index of the item |
18
+ | badge-content | Content in the badge | **content** `string \| number \| boolean` - content of the badge provided in item |
@@ -0,0 +1,11 @@
1
+ ## Props
2
+
3
+ | Name | Description | Type | Required |
4
+ | ------- | ----------- | -------- | -------- |
5
+ | **tab** | | `number` | Yes |
6
+
7
+ ## Slots
8
+
9
+ | Name | Description | Bindings |
10
+ | ------- | ----------- | -------- |
11
+ | default | | |
@@ -0,0 +1,5 @@
1
+ ## Slots
2
+
3
+ | Name | Description | Bindings |
4
+ | ------- | ----------- | -------- |
5
+ | default | | |
@@ -0,0 +1,17 @@
1
+ ## Props
2
+
3
+ | Name | Description | Type | Required |
4
+ | --------------- | --------------------------- | -------- | -------- |
5
+ | **model-value** | The the selected tab number | `number` | No |
6
+
7
+ ## Events
8
+
9
+ | Event name | Properties | Description |
10
+ | ------------------ | ------------------------------------- | ------------------------------------ |
11
+ | update:model-value | **newValue** `number` - new value set | Emitted when the selected tab change |
12
+
13
+ ## Slots
14
+
15
+ | Name | Description | Bindings |
16
+ | ------- | ----------- | -------- |
17
+ | default | | |
@@ -0,0 +1,41 @@
1
+ ## Props
2
+
3
+ | Name | Description | Type | Required | Default | Possible values |
4
+ | ------------------ | -------------------------------------------- | ------------------------------------------------------------------------------------- | -------- | --------------- | ------------------------------------------------------------------------------------- |
5
+ | **style** | Style attribut of the component root element | `Native type` | No | `undefined` | - |
6
+ | **class** | Class attribut of the component root element | `Native type` | No | `undefined` | - |
7
+ | **model-value** | `v-model` <br/> | `T` | No | `undefined` | - |
8
+ | **id** | The id of the textarea | `string` | No | `undefined` | - |
9
+ | **name** | The name of the textarea | `string` | No | `'MazTextarea'` | - |
10
+ | **label** | The label of the textarea | `string` | No | `undefined` | - |
11
+ | **placeholder** | The placeholder of the textarea | `string` | No | `undefined` | - |
12
+ | **required** | If the textarea is required | `boolean` | No | `false` | - |
13
+ | **disabled** | If the textarea is disabled | `boolean` | No | `false` | - |
14
+ | **readonly** | If the textarea is readonly | `boolean` | No | `false` | - |
15
+ | **error** | If the textarea has an error | `boolean` | No | `false` | - |
16
+ | **success** | If the textarea has a success | `boolean` | No | `false` | - |
17
+ | **warning** | If the textarea has a warning | `boolean` | No | `false` | - |
18
+ | **hint** | The hint of the textarea | `string` | No | `undefined` | - |
19
+ | **color** | The color of the textarea | `MazColor` | No | `'primary'` | - |
20
+ | **rounded-size** | Size radius of the component's border | `"none" \| "sm" \| "md" \| "lg" \| "xl" \| "full"` | No | `undefined` | `'none' \| 'sm' \| 'md' \| 'lg' \| 'xl' \| 'full'` |
21
+ | **padding** | If the textarea has a padding | `boolean` | No | `true` | - |
22
+ | **transparent** | If the textarea has a transparent background | `boolean` | No | `false` | - |
23
+ | **border** | If the textarea has no border | `boolean` | No | `true` | - |
24
+ | **append-justify** | The alignment of the append slot | `"start" \| "end" \| "center" \| "space-between" \| "space-around" \| "space-evenly"` | No | `'end'` | `'start' \| 'end' \| 'center' \| 'space-between' \| 'space-around' \| 'space-evenly'` |
25
+
26
+ ## Events
27
+
28
+ | Event name | Properties | Description |
29
+ | ------------------ | ----------------------------------------------------------- | --------------------------------------------- |
30
+ | update:model-value | **value** `string \| undefined` - The value of the textarea | Emitted when the value of the textarea change |
31
+ | input | **value** `string \| undefined` - The value of the textarea | Emitted when the value of the textarea change |
32
+ | focus | **value** `Event` - The event | Emitted when the textarea is focused |
33
+ | blur | **value** `Event` - The event | Emitted when the textarea is blurred |
34
+ | change | **value** `Event` - The event | Emitted when the textarea value change |
35
+
36
+ ## Slots
37
+
38
+ | Name | Description | Bindings |
39
+ | ------ | ------------------ | -------- |
40
+ | Label | Replace the label | |
41
+ | Append | Replace the append | |
@@ -0,0 +1,8 @@
1
+ ---
2
+ title: Components
3
+ description: todo
4
+ ---
5
+
6
+ # {{ $frontmatter.title }}
7
+
8
+ {{ $frontmatter.description }}
@@ -0,0 +1,80 @@
1
+ ---
2
+ title: MazAccordion
3
+ description: MazAccordion is a standalone component that allows you to create an accordion with a title and content.
4
+ ---
5
+
6
+ # {{ $frontmatter.title }}
7
+
8
+ {{ $frontmatter.description }}
9
+
10
+ <!--@include: ./../.vitepress/mixins/getting-started.md-->
11
+
12
+ ## Basic usage
13
+
14
+ <MazAccordion class="maz-w-full">
15
+ <template #title-1>
16
+ Title 1
17
+ </template>
18
+ <template #content-1>
19
+ Content 1
20
+ </template>
21
+ <template #title-2>
22
+ Title 2
23
+ </template>
24
+ <template #content-2>
25
+ Content 2
26
+ </template>
27
+ <template #title-3>
28
+ Title 3
29
+ </template>
30
+ <template #content-3>
31
+ Content 3
32
+ </template>
33
+ <template #title-4>
34
+ Title 4
35
+ </template>
36
+ <template #content-4>
37
+ Content 4
38
+ </template>
39
+ </MazAccordion>
40
+
41
+ ```vue
42
+ <script lang="ts" setup>
43
+ import { MazAccordion } from 'maz-ui/components'
44
+ </script>
45
+
46
+ <template>
47
+ <MazAccordion>
48
+ <template #title-1>
49
+ Title 1
50
+ </template>
51
+ <template #content-1>
52
+ Content 1
53
+ </template>
54
+
55
+ <template #title-2>
56
+ Title 2
57
+ </template>
58
+ <template #content-2>
59
+ Content 2
60
+ </template>
61
+
62
+ <template #title-3>
63
+ Title 3
64
+ </template>
65
+ <template #content-3>
66
+ Content 3
67
+ </template>
68
+
69
+ <template #title-4>
70
+ Title 4
71
+ </template>
72
+ <template #content-4>
73
+ Content 4
74
+ </template>
75
+ <MazAccordion />
76
+ </mazaccordion>
77
+ </template>
78
+ ```
79
+
80
+ <!--@include: ./../../.vitepress/generated-docs/maz-accordion.doc.md-->
@@ -0,0 +1,124 @@
1
+ ---
2
+ title: MazAnimatedCounter
3
+ description: MazAnimatedCounter is a standalone component that allows you to animate a number from 0 to a specific value. Fully animated with CSS.
4
+ ---
5
+
6
+ # {{ $frontmatter.title }}
7
+
8
+ {{ $frontmatter.description }}
9
+
10
+ <!--@include: ./../.vitepress/mixins/getting-started.md-->
11
+
12
+ ## Basic usage
13
+
14
+ <ComponentDemo expanded>
15
+ <MazAnimatedCounter :count="count" />
16
+
17
+ <template #code>
18
+
19
+ ```vue
20
+ <script lang="ts" setup>
21
+ import { MazAnimatedCounter } from 'maz-ui/components'
22
+
23
+ const count = ref(Math.floor(Math.random() * 99999))
24
+
25
+ onMounted(() => {
26
+ setInterval(() => {
27
+ count.value = Math.floor(Math.random() * 99999)
28
+ }, 3000)
29
+ })
30
+ </script>
31
+
32
+ <template>
33
+ <MazAnimatedCounter :count="4000" />
34
+ </template>
35
+ ```
36
+
37
+ </template>
38
+ </ComponentDemo>
39
+
40
+ <script setup lang="ts">
41
+ import { ref, onMounted } from 'vue'
42
+ const count = ref(Math.floor(Math.random() * 99999))
43
+
44
+ onMounted(() => {
45
+ setInterval(() => {
46
+ count.value = Math.floor(Math.random() * 99999)
47
+ }, 3000)
48
+ })
49
+ </script>
50
+
51
+ ## duration
52
+
53
+ You can set the duration of the animation with the `duration` prop. The default value is `1000` ms.
54
+
55
+ <ComponentDemo>
56
+ <MazAnimatedCounter :count="4000" :duration="5000" />
57
+
58
+ <template #code>
59
+
60
+ ```vue
61
+ <MazAnimatedCounter :count="4000" :duration="5000" />
62
+ ```
63
+
64
+ </template>
65
+ </ComponentDemo>
66
+
67
+ ## prefix and suffix
68
+
69
+ You can add a prefix and a suffix to the number with props or slots.
70
+
71
+ Be careful, you can't use both at the same time.
72
+
73
+ <ComponentDemo>
74
+ <p class="maz-font-semibold">
75
+ Prefixed
76
+ </p>
77
+
78
+ <br />
79
+
80
+ <MazAnimatedCounter :count="20" prefix="$" />
81
+ <br />
82
+ <MazAnimatedCounter :count="20">
83
+ <template #prefix>$</template>
84
+ </MazAnimatedCounter>
85
+
86
+ <br />
87
+ <br />
88
+
89
+ <p class="maz-font-semibold">
90
+ Suffixed
91
+ </p>
92
+
93
+ <br />
94
+ <MazAnimatedCounter :count="100" suffix="%" />
95
+ <br />
96
+
97
+ <MazAnimatedCounter :count="100">
98
+ <template #suffix>%</template>
99
+ </MazAnimatedCounter>
100
+
101
+ <template #code>
102
+
103
+ ```html
104
+ <p class="maz-font-semibold">Prefixed</p>
105
+
106
+ <MazAnimatedCounter :count="20" prefix="$" />
107
+
108
+ <MazAnimatedCounter :count="20">
109
+ <template #prefix>$</template>
110
+ </MazAnimatedCounter>
111
+
112
+ <p class="maz-font-semibold">Suffixed</p>
113
+
114
+ <MazAnimatedCounter :count="100" suffix="%" />
115
+
116
+ <MazAnimatedCounter :count="100">
117
+ <template #suffix>%</template>
118
+ </MazAnimatedCounter>
119
+ ```
120
+
121
+ </template>
122
+ </ComponentDemo>
123
+
124
+ <!--@include: ./../../.vitepress/generated-docs/maz-animated-counter.doc.md-->
@@ -0,0 +1,36 @@
1
+ ---
2
+ title: MazAnimatedElement
3
+ description: MazAnimatedElement is a standalone component that animates its content with a sliding blur effect when it enters the viewport. It supports different animation directions (up, down, left, right) and allows customizing the animation delay and duration.
4
+ ---
5
+
6
+ # {{ $frontmatter.title }}
7
+
8
+ {{ $frontmatter.description }}
9
+
10
+ <!--@include: ./../.vitepress/mixins/getting-started.md-->
11
+
12
+ ## Basic usage
13
+
14
+ <ComponentDemo expanded>
15
+ <MazAnimatedElement direction="up" :delay="1000" :duration="2000">
16
+ <MazAvatar src="https://github.com/LouisMazel.png" size="lg" />
17
+ </MazAnimatedElement>
18
+
19
+ <template #code>
20
+
21
+ ```vue
22
+ <script lang="ts" setup>
23
+ import { MazAnimatedElement } from 'maz-ui/components'
24
+ </script>
25
+
26
+ <template>
27
+ <MazAnimatedElement direction="up" :delay="1000" :duration="2000">
28
+ <MazAvatar src="https://github.com/LouisMazel.png" size="lg" />
29
+ </MazAnimatedElement>
30
+ </template>
31
+ ```
32
+
33
+ </template>
34
+ </ComponentDemo>
35
+
36
+ <!--@include: ./../../.vitepress/generated-docs/maz-animated-element.doc.md-->
@@ -0,0 +1,36 @@
1
+ ---
2
+ title: MazAnimatedText
3
+ description: MazAnimatedText is a standalone component that animates text with a sliding blur effect. It can highlight the last word with a gradient background and supports different animation directions (up, down, left, right).
4
+ ---
5
+
6
+ # {{ $frontmatter.title }}
7
+
8
+ {{ $frontmatter.description }}
9
+
10
+ <!--@include: ./../.vitepress/mixins/getting-started.md-->
11
+
12
+ ## Basic usage
13
+
14
+ ::: tip
15
+ This component is SSR friendly. It will display the brut text on the server side with the chosen tag, and the animated text on the client side.
16
+ :::
17
+
18
+ <ComponentDemo expanded>
19
+ <MazAnimatedText tag="h1" text="Hello" last-word="world" :delay="1000" :duration="2000" direction="up" :column-gap="0.5" :row-gap="0.5" />
20
+
21
+ <template #code>
22
+
23
+ ```vue
24
+ <script lang="ts" setup>
25
+ import { MazAnimatedText } from 'maz-ui/components'
26
+ </script>
27
+
28
+ <template>
29
+ <MazAnimatedText tag="h1" text="Hello" last-word="world" :delay="1000" :duration="2000" direction="up" :column-gap="0.5" :row-gap="0.5" />
30
+ </template>
31
+ ```
32
+
33
+ </template>
34
+ </ComponentDemo>
35
+
36
+ <!--@include: ./../../.vitepress/generated-docs/maz-animated-text.doc.md-->
@@ -0,0 +1,179 @@
1
+ ---
2
+ title: MazAvatar
3
+ description: MazAvatar is a standalone component that displays an image or an icon with a caption. It can be used to display a user's profile picture, a placeholder image, or an icon.
4
+ ---
5
+
6
+ # {{ $frontmatter.title }}
7
+
8
+ {{ $frontmatter.description }}
9
+
10
+ <!--@include: ./../.vitepress/mixins/getting-started.md-->
11
+
12
+ ::: tip
13
+ This component uses [vLazyImg](./../directives/lazy-img.md) directive
14
+ :::
15
+
16
+ ## Basic usage
17
+
18
+ <MazAvatar :lazy="false" src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80" />
19
+
20
+ ```vue
21
+ <script lang="ts" setup>
22
+ import { MazAvatar } from 'maz-ui/components'
23
+ </script>
24
+
25
+ <template>
26
+ <MazAvatar src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80" />
27
+ </template>
28
+ ```
29
+
30
+ ## Options
31
+
32
+ ::: tip
33
+ See all the options props [here](#props-event-slots)
34
+ :::
35
+
36
+ <div class="flex space-between gap-05 items-center flex-wrap">
37
+ <MazAvatar
38
+ caption="Louis Mazel"
39
+ size="1.5rem"
40
+ />
41
+ <MazAvatar
42
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=maz-ui"
43
+ size="2rem"
44
+ href="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=maz-ui"
45
+ target="_blank"
46
+ rounded-size="none"
47
+ clickable
48
+ >
49
+ <template #icon>
50
+ <MazIcon name="eye" style="color: white;" size="2rem" />
51
+ </template>
52
+ </MazAvatar>
53
+
54
+ <MazAvatar
55
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=200"
56
+ size="2.5rem"
57
+ clickable
58
+ rounded-size="xl"
59
+ button-color="destructive"
60
+ @click="clicked"
61
+ />
62
+
63
+ <MazAvatar
64
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=600"
65
+ size="3rem"
66
+ bordered
67
+ noElevation
68
+ />
69
+
70
+ </div>
71
+
72
+ ```vue
73
+ <script lang="ts" setup>
74
+ import { MazAvatar } from 'maz-ui/components'
75
+ function clicked() { console.log('clicked') }
76
+ </script>
77
+
78
+ <template>
79
+ <MazAvatar
80
+ caption="Louis Mazel"
81
+ size="1.5rem"
82
+ />
83
+ <MazAvatar
84
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=maz-ui"
85
+ size="2rem"
86
+ href="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=maz-ui"
87
+ target="_blank"
88
+ rounded-size="none"
89
+ clickable
90
+ no-size
91
+ >
92
+ <template #icon>
93
+ <MazIcon name="eye" />
94
+ </template>
95
+ </MazAvatar>
96
+ <MazAvatar
97
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=200"
98
+ size="2.5rem"
99
+ clickable
100
+ rounded-size="xl"
101
+ @click="clicked"
102
+ />
103
+ <MazAvatar
104
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=600"
105
+ size="3rem"
106
+ bordered
107
+ />
108
+ </template>
109
+ ```
110
+
111
+ ## On Error
112
+
113
+ <MazAvatar @error="error" />
114
+
115
+ ```html
116
+ <MazAvatar @error="error" />
117
+ ```
118
+
119
+ ## Fallback image loaded on error
120
+
121
+ <MazAvatar
122
+ class="vp-raw"
123
+ src="https://broken-link-image-src.com"
124
+ fallback-src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=100"
125
+ />
126
+
127
+ ```html
128
+ <MazAvatar
129
+ src="https://broken-link-image-src.com"
130
+ fallback-src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=100"
131
+ />
132
+ ```
133
+
134
+ ## Loading
135
+
136
+ The props `loading` has 3 possible values: `intersecting`, `lazy`, or `eager`.
137
+
138
+ By default, the value is `intersecting` which means the image will be loaded when it's intersecting with the `IntersectionObserver` browser API. This mode uses the [`MazLazyImg`](./maz-lazy-img.md) component with [`vLazyImg`](./../directives/lazy-img.md) directive to handle the lazy loading.
139
+
140
+ Native modes:
141
+
142
+ - `lazy`: The image will be loaded only when it's in the viewport
143
+ - `eager`: The image will be loaded immediately
144
+
145
+ These modes are native use an `HTMLImageElement` with the `loading` attribute. (see [MDN](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img#attr-loading)). **Useful for SSR (Server Side Rendering) or when you want to load the image immediately.**
146
+
147
+ <div class="flex gap-05 items-center flex-wrap">
148
+ <MazAvatar
149
+ class="vp-raw"
150
+ loading="intersecting"
151
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=123"
152
+ />
153
+ <MazAvatar
154
+ class="vp-raw"
155
+ loading="lazy"
156
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=123"
157
+ />
158
+ <MazAvatar
159
+ class="vp-raw"
160
+ loading="eager"
161
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=123"
162
+ />
163
+ </div>
164
+
165
+ ```html
166
+ <MazAvatar
167
+ loading="intersecting"
168
+ src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=123"
169
+ />
170
+ <MazAvatar loading="lazy" src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=123" />
171
+ <MazAvatar loading="eager" src="https://api.dicebear.com/7.x/big-smile/svg?backgroundColor=1d90ff&scale=80&seed=123" />
172
+ ```
173
+
174
+ <script lang="ts" setup>
175
+ const clicked = () => { console.log('clicked') }
176
+ const error = (el) => { console.error('error', el) }
177
+ </script>
178
+
179
+ <!--@include: ./../../.vitepress/generated-docs/maz-avatar.doc.md-->