maz-ui 5.0.0 → 5.1.0-beta.0

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 (186) hide show
  1. package/dist/assets/{MazDropzone.DJ8au25t.css → MazDropzone.BW2grpTi.css} +1 -1
  2. package/dist/chunks/{MazDrawer.DANxKYxJ.js → MazDrawer.CC8zomfx.js} +2 -2
  3. package/dist/chunks/{MazDropzone.POH3pmfi.js → MazDropzone.Dez5j0WP.js} +2 -2
  4. package/dist/components/MazDrawer.js +1 -1
  5. package/dist/components/MazDropzone.js +1 -1
  6. package/dist/components/MazDropzone.vue.d.ts +2 -2
  7. package/dist/components/MazInputPrice.vue.d.ts +1 -1
  8. package/dist/components/index.js +2 -2
  9. package/docs/README.md +207 -0
  10. package/docs/agents/agents-md.md +52 -0
  11. package/docs/agents/claude-rule.md +52 -0
  12. package/docs/components/maz-accordion.md +76 -0
  13. package/docs/components/maz-alert.md +241 -0
  14. package/docs/components/maz-animated-counter.md +87 -0
  15. package/docs/components/maz-animated-element.md +46 -0
  16. package/docs/components/maz-animated-text.md +53 -0
  17. package/docs/components/maz-avatar.md +193 -0
  18. package/docs/components/maz-backdrop.md +178 -0
  19. package/docs/components/maz-badge.md +167 -0
  20. package/docs/components/maz-bottom-sheet.md +257 -0
  21. package/docs/components/maz-btn-group.md +316 -0
  22. package/docs/components/maz-btn.md +423 -0
  23. package/docs/components/maz-card-spotlight.md +84 -0
  24. package/docs/components/maz-card.md +321 -0
  25. package/docs/components/maz-carousel.md +153 -0
  26. package/docs/components/maz-chart.md +206 -0
  27. package/docs/components/maz-checkbox.md +138 -0
  28. package/docs/components/maz-checklist.md +251 -0
  29. package/docs/components/maz-circular-progress-bar.md +109 -0
  30. package/docs/components/maz-code-highlight.md +155 -0
  31. package/docs/components/maz-container.md +241 -0
  32. package/docs/components/maz-date-picker.md +791 -0
  33. package/docs/components/maz-dialog-confirm.md +215 -0
  34. package/docs/components/maz-dialog.md +143 -0
  35. package/docs/components/maz-drawer.md +106 -0
  36. package/docs/components/maz-dropdown.md +419 -0
  37. package/docs/components/maz-dropzone.md +387 -0
  38. package/docs/components/maz-expand-animation.md +82 -0
  39. package/docs/components/maz-fullscreen-loader.md +58 -0
  40. package/docs/components/maz-gallery.md +79 -0
  41. package/docs/components/maz-icon.md +203 -0
  42. package/docs/components/maz-input-code.md +73 -0
  43. package/docs/components/maz-input-number.md +79 -0
  44. package/docs/components/maz-input-phone-number.md +536 -0
  45. package/docs/components/maz-input-price.md +68 -0
  46. package/docs/components/maz-input-tags.md +112 -0
  47. package/docs/components/maz-input.md +334 -0
  48. package/docs/components/maz-lazy-img.md +113 -0
  49. package/docs/components/maz-link.md +146 -0
  50. package/docs/components/maz-loading-bar.md +38 -0
  51. package/docs/components/maz-markdown-editor.md +320 -0
  52. package/docs/components/maz-pagination.md +82 -0
  53. package/docs/components/maz-popover.md +794 -0
  54. package/docs/components/maz-pull-to-refresh.md +222 -0
  55. package/docs/components/maz-radio-buttons.md +313 -0
  56. package/docs/components/maz-radio.md +119 -0
  57. package/docs/components/maz-read-more.md +209 -0
  58. package/docs/components/maz-reading-progress-bar.md +96 -0
  59. package/docs/components/maz-select-country.md +513 -0
  60. package/docs/components/maz-select.md +318 -0
  61. package/docs/components/maz-sidebar-content.md +25 -0
  62. package/docs/components/maz-sidebar-footer.md +25 -0
  63. package/docs/components/maz-sidebar-group.md +27 -0
  64. package/docs/components/maz-sidebar-header.md +25 -0
  65. package/docs/components/maz-sidebar-menu-button.md +41 -0
  66. package/docs/components/maz-sidebar-menu-item.md +25 -0
  67. package/docs/components/maz-sidebar-menu-sub.md +32 -0
  68. package/docs/components/maz-sidebar-menu.md +25 -0
  69. package/docs/components/maz-sidebar-separator.md +21 -0
  70. package/docs/components/maz-sidebar-trigger.md +25 -0
  71. package/docs/components/maz-sidebar.md +507 -0
  72. package/docs/components/maz-skeleton.md +226 -0
  73. package/docs/components/maz-slider.md +165 -0
  74. package/docs/components/maz-spinner.md +84 -0
  75. package/docs/components/maz-stepper.md +301 -0
  76. package/docs/components/maz-switch.md +86 -0
  77. package/docs/components/maz-table-cell.md +27 -0
  78. package/docs/components/maz-table-row.md +28 -0
  79. package/docs/components/maz-table-title.md +27 -0
  80. package/docs/components/maz-table-virtualizer.md +31 -0
  81. package/docs/components/maz-table.md +426 -0
  82. package/docs/components/maz-tabs-bar.md +43 -0
  83. package/docs/components/maz-tabs-content-item.md +27 -0
  84. package/docs/components/maz-tabs-content.md +27 -0
  85. package/docs/components/maz-tabs.md +308 -0
  86. package/docs/components/maz-textarea.md +255 -0
  87. package/docs/components/maz-ticker.md +427 -0
  88. package/docs/components/maz-timeline.md +304 -0
  89. package/docs/components/maz-ui-provider.md +26 -0
  90. package/docs/components/maz-window-mockup.md +182 -0
  91. package/docs/composables/use-aos.md +41 -0
  92. package/docs/composables/use-breakpoints.md +42 -0
  93. package/docs/composables/use-dialog.md +58 -0
  94. package/docs/composables/use-display-names.md +130 -0
  95. package/docs/composables/use-drag.md +185 -0
  96. package/docs/composables/use-form-validator.md +1123 -0
  97. package/docs/composables/use-idle-timeout.md +172 -0
  98. package/docs/composables/use-pull-to-refresh.md +86 -0
  99. package/docs/composables/use-reading-time.md +132 -0
  100. package/docs/composables/use-string-matching.md +41 -0
  101. package/docs/composables/use-swipe.md +171 -0
  102. package/docs/composables/use-timer.md +104 -0
  103. package/docs/composables/use-toast.md +50 -0
  104. package/docs/composables/use-user-visibility.md +127 -0
  105. package/docs/composables/use-wait.md +50 -0
  106. package/docs/composables/use-window-size.md +25 -0
  107. package/docs/directives/click-outside.md +182 -0
  108. package/docs/directives/fullscreen-img.md +83 -0
  109. package/docs/directives/lazy-img.md +182 -0
  110. package/docs/directives/tooltip.md +298 -0
  111. package/docs/directives/zoom-img.md +100 -0
  112. package/docs/ecosystem/eslint-config.md +289 -0
  113. package/docs/ecosystem/icons/icon-set.md +25 -0
  114. package/docs/ecosystem/icons/index.md +584 -0
  115. package/docs/ecosystem/mcp.md +165 -0
  116. package/docs/ecosystem/node/exec-promise.md +93 -0
  117. package/docs/ecosystem/node/index.md +53 -0
  118. package/docs/ecosystem/node/logger.md +152 -0
  119. package/docs/ecosystem/node/print-banner.md +101 -0
  120. package/docs/ecosystem/node/setup-agents.md +102 -0
  121. package/docs/ecosystem/nuxt.md +551 -0
  122. package/docs/ecosystem/stylelint-config.md +310 -0
  123. package/docs/ecosystem/themes.md +966 -0
  124. package/docs/ecosystem/translations.md +1173 -0
  125. package/docs/ecosystem/utils/camel-case.md +37 -0
  126. package/docs/ecosystem/utils/capitalize.md +37 -0
  127. package/docs/ecosystem/utils/check-availability.md +85 -0
  128. package/docs/ecosystem/utils/cookie.md +86 -0
  129. package/docs/ecosystem/utils/country-code-to-unicode-flag.md +128 -0
  130. package/docs/ecosystem/utils/currency.md +53 -0
  131. package/docs/ecosystem/utils/date.md +53 -0
  132. package/docs/ecosystem/utils/debounce-callback.md +44 -0
  133. package/docs/ecosystem/utils/debounce-id.md +75 -0
  134. package/docs/ecosystem/utils/debounce.md +71 -0
  135. package/docs/ecosystem/utils/fetch-locale-ip.md +39 -0
  136. package/docs/ecosystem/utils/format-json.md +39 -0
  137. package/docs/ecosystem/utils/format-phone-number.md +43 -0
  138. package/docs/ecosystem/utils/get-browser-locale.md +35 -0
  139. package/docs/ecosystem/utils/get-country-flag-url.md +67 -0
  140. package/docs/ecosystem/utils/get-error-message.md +45 -0
  141. package/docs/ecosystem/utils/idle-timeout.md +96 -0
  142. package/docs/ecosystem/utils/index.md +57 -0
  143. package/docs/ecosystem/utils/is-client.md +38 -0
  144. package/docs/ecosystem/utils/is-equal.md +44 -0
  145. package/docs/ecosystem/utils/is-ios.md +43 -0
  146. package/docs/ecosystem/utils/is-server.md +37 -0
  147. package/docs/ecosystem/utils/is-standalone-mode.md +49 -0
  148. package/docs/ecosystem/utils/kebab-case.md +42 -0
  149. package/docs/ecosystem/utils/normalize-string.md +83 -0
  150. package/docs/ecosystem/utils/number.md +51 -0
  151. package/docs/ecosystem/utils/pascal-case.md +41 -0
  152. package/docs/ecosystem/utils/prevent-ios-input-zoom.md +72 -0
  153. package/docs/ecosystem/utils/script-loader.md +85 -0
  154. package/docs/ecosystem/utils/sleep.md +65 -0
  155. package/docs/ecosystem/utils/snake-case.md +42 -0
  156. package/docs/ecosystem/utils/swipe-handler.md +97 -0
  157. package/docs/ecosystem/utils/textarea-autogrow.md +47 -0
  158. package/docs/ecosystem/utils/throttle-id.md +54 -0
  159. package/docs/ecosystem/utils/throttle.md +63 -0
  160. package/docs/ecosystem/utils/truthy-filter.md +37 -0
  161. package/docs/ecosystem/utils/types/deep-key-of.md +54 -0
  162. package/docs/ecosystem/utils/types/deep-partial.md +48 -0
  163. package/docs/ecosystem/utils/types/deep-required.md +45 -0
  164. package/docs/ecosystem/utils/types/flatten-object-keys.md +50 -0
  165. package/docs/ecosystem/utils/types/generic-instance-type.md +48 -0
  166. package/docs/ecosystem/utils/types/infer-maybe-ref.md +41 -0
  167. package/docs/ecosystem/utils/upper-first.md +38 -0
  168. package/docs/ecosystem/utils/user-visibility.md +75 -0
  169. package/docs/guide/ai-agents.md +237 -0
  170. package/docs/guide/browser-support.md +88 -0
  171. package/docs/guide/getting-started.md +191 -0
  172. package/docs/guide/global-defaults.md +103 -0
  173. package/docs/guide/maz-ui-provider.md +231 -0
  174. package/docs/guide/migration-v5.md +871 -0
  175. package/docs/guide/resolvers.md +650 -0
  176. package/docs/guide/tailwind.md +483 -0
  177. package/docs/guide/vue.md +286 -0
  178. package/docs/manifest.json +1 -0
  179. package/docs/plugins/aos.md +312 -0
  180. package/docs/plugins/dialog.md +269 -0
  181. package/docs/plugins/toast.md +221 -0
  182. package/docs/plugins/wait.md +78 -0
  183. package/docs/reference/icons.md +46 -0
  184. package/docs/reference/tailwind-tokens.md +191 -0
  185. package/docs/rules.md +57 -0
  186. package/package.json +31 -4
@@ -0,0 +1,221 @@
1
+ ---
2
+ title: "Toast"
3
+ description: "A powerful toast notification system for Vue.js that displays user-friendly messages with customizable positioning, styling, and behavior options"
4
+ package: "maz-ui"
5
+ url: "https://maz-ui.com/plugins/toast"
6
+ ---
7
+
8
+ # Toast
9
+
10
+ > A powerful toast notification system for Vue.js that displays user-friendly messages with customizable positioning, styling, and behavior options
11
+
12
+ - Package: `maz-ui`
13
+ - Import: `import { ToastPlugin } from 'maz-ui/plugins/toast'`
14
+ - Web: https://maz-ui.com/plugins/toast
15
+
16
+ **Tip:**
17
+
18
+ This plugin has a composable for easier use, after installing it you can use [useToast](../composables/use-toast.md)
19
+
20
+ ## Installation
21
+
22
+ ```ts [Vue]
23
+ import { ToastPlugin } from 'maz-ui/plugins/toast'
24
+ import { createApp } from 'vue'
25
+
26
+ const app = createApp(App)
27
+
28
+ const toastOptions: ToastOptions = {
29
+ position: 'bottom-right',
30
+ timeout: 10_000,
31
+ persistent: false,
32
+ }
33
+
34
+ app.use(ToastPlugin, toastOptions)
35
+ app.mount('#app')
36
+ ```
37
+
38
+ ```ts [Nuxt]
39
+ export default defineNuxtConfig({
40
+ modules: ['@maz-ui/nuxt'],
41
+ mazUi: {
42
+ composables: {
43
+ useToast: true,
44
+ },
45
+ },
46
+ })
47
+ ```
48
+
49
+ ## Basic usage
50
+
51
+ ```vue
52
+ <script lang="ts" setup>
53
+ import { useToast } from 'maz-ui/composables/useToast'
54
+
55
+ const toast = useToast()
56
+ </script>
57
+
58
+ <template>
59
+ <MazBtn color="contrast" @click="toast.message('Message text')">
60
+ Message
61
+ </MazBtn>
62
+ <MazBtn color="info" @click="toast.info('Info message', { position: 'top', button: { href: 'https://www.loicmazuel.com' } })">
63
+ Info toast on top
64
+ </MazBtn>
65
+ <MazBtn color="destructive" @click="toast.error('Error message', { position: 'bottom', timeout: 1000 })">
66
+ Error toast on bottom with 1s timeout
67
+ </MazBtn>
68
+ <MazBtn color="warning" @click="toast.warning('Warning message', { position: 'top-right' })">
69
+ Warning toast on top right
70
+ </MazBtn>
71
+ <MazBtn color="contrast" @click="toast.message(`<ul><li>Item <b>1</b></li><li>Item <b>2</b></li><li>Item <b>3</b></li></ul>`, { position: 'bottom-left', html: true })">
72
+ Toast with html content
73
+ </MazBtn>
74
+ <MazBtn color="contrast" @click="toast.message('No timeout toast', { timeout: false })">
75
+ Persistent with no timeout
76
+ </MazBtn>
77
+ </template>
78
+ ```
79
+
80
+ ### Action and link
81
+
82
+ Toast can have a link or an action
83
+
84
+ ```vue
85
+ <script lang="ts" setup>
86
+ import { useToast } from 'maz-ui/composables/useToast'
87
+
88
+ const toast = useToast()
89
+
90
+ function showInfoWithLink() {
91
+ toast.info('Toast with link, click -->', {
92
+ button: {
93
+ href: 'https://www.loicmazuel.com',
94
+ }
95
+ })
96
+ }
97
+
98
+ function showInfoWithExternalLink() {
99
+ toast.warning('Toast with link', {
100
+ button: {
101
+ href: 'https://www.loicmazuel.com',
102
+ target: '_blank',
103
+ closeToast: true,
104
+ text: 'Follow link'
105
+ }
106
+ })
107
+ }
108
+
109
+ function showInfoWithAction() {
110
+ toast.error('Toast with action', {
111
+ button: {
112
+ onClick: () => new Promise((resolve) => {
113
+ sleep(3000)
114
+ resolve()
115
+ toast.success('Promise executed')
116
+ }),
117
+ text: 'Exec promise',
118
+ closeToast: true,
119
+ },
120
+ })
121
+ }
122
+ </script>
123
+
124
+ <template>
125
+ <MazBtn color="info" @click="showInfoWithLink">
126
+ Toast with link
127
+ </MazBtn>
128
+ <MazBtn color="warning" @click="showInfoWithExternalLink">
129
+ Toast with blank link
130
+ </MazBtn>
131
+ <MazBtn color="destructive" @click="showInfoWithAction">
132
+ Toast with action
133
+ </MazBtn>
134
+ </template>
135
+ ```
136
+
137
+ ## Close toast programmatically
138
+
139
+ You can close a toast programmatically by using the `close` method returned by the `toast` function
140
+
141
+ ```typescript
142
+ function showToast() {
143
+ const toastMessage = toast.message('Toast message closed by code')
144
+
145
+ setTimeout(() => {
146
+ toastMessage.close()
147
+ }, 2000)
148
+ }
149
+ ```
150
+
151
+ ### Type
152
+
153
+ ```ts
154
+ interface ToastOptions {
155
+ /**
156
+ * The position of the toast on the screen
157
+ * @default 'bottom-right'
158
+ */
159
+ position?: ToastPosition
160
+ /**
161
+ * The timeout is in ms, it's the time before the toast is automatically closed
162
+ * if set to `false`, the toast will not be closed automatically
163
+ * @default 10000
164
+ */
165
+ timeout?: number | boolean
166
+ /**
167
+ * If the toast is persistent, it can't be closed by user interaction (only on timeout or programmatically)
168
+ * @default false
169
+ */
170
+ persistent?: boolean
171
+ /**
172
+ * Display an icon in the toast
173
+ * @default true
174
+ */
175
+ icon?: boolean
176
+ /**
177
+ * The action will be displayed as a button in the toast
178
+ * @default undefined
179
+ */
180
+ button?: MazBtnProps & {
181
+ text: string
182
+ onClick: () => unknown
183
+ href?: string
184
+ text?: string
185
+ /** @default _self */
186
+ target?: string
187
+ /** @default false */
188
+ closeToast?: boolean
189
+ }
190
+ buttons?: (MazBtnProps & {
191
+ text: string
192
+ onClick: () => unknown
193
+ href?: string
194
+ text?: string
195
+ /** @default _self */
196
+ target?: string
197
+ /** @default false */
198
+ closeToast?: boolean
199
+ })[]
200
+ /**
201
+ * If the toast is queued, it will be displayed in the order of the toasts
202
+ * @default false
203
+ */
204
+ queue?: boolean
205
+ /**
206
+ * The maximum number of toasts to display
207
+ * @default false
208
+ */
209
+ maxToasts?: number | boolean
210
+ /**
211
+ * If the toast is paused on hover, it will be paused when the mouse is over the toast
212
+ * @default true
213
+ */
214
+ pauseOnHover?: boolean
215
+ /**
216
+ * If the message is HTML
217
+ * @default false
218
+ */
219
+ html?: boolean
220
+ }
221
+ ```
@@ -0,0 +1,78 @@
1
+ ---
2
+ title: "wait"
3
+ description: "A comprehensive loading state management plugin for Vue.js that provides easy-to-use utilities for handling async operations, loading indicators, and user feedback during data processing or any other async operation"
4
+ package: "maz-ui"
5
+ url: "https://maz-ui.com/plugins/wait"
6
+ ---
7
+
8
+ # wait
9
+
10
+ > A comprehensive loading state management plugin for Vue.js that provides easy-to-use utilities for handling async operations, loading indicators, and user feedback during data processing or any other async operation
11
+
12
+ - Package: `maz-ui`
13
+ - Import: `import { WaitPlugin } from 'maz-ui/plugins/wait'`
14
+ - Web: https://maz-ui.com/plugins/wait
15
+
16
+ **Tip:**
17
+
18
+ This plugin has a composable for easier use, after installing it you can use [useWait](../composables/use-wait.md)
19
+
20
+ ## Installation
21
+
22
+ ```ts [Vue]
23
+ import { WaitPlugin } from 'maz-ui/plugins/wait'
24
+ import { createApp } from 'vue'
25
+
26
+ const app = createApp(App)
27
+
28
+ app.use(WaitPlugin)
29
+ app.mount('#app')
30
+ ```
31
+
32
+ ```ts [Nuxt]
33
+ export default defineNuxtConfig({
34
+ modules: ['@maz-ui/nuxt'],
35
+ mazUi: {
36
+ composables: {
37
+ useWait: true,
38
+ },
39
+ },
40
+ })
41
+ ```
42
+
43
+ ## Basic usage
44
+
45
+ ```vue
46
+ <script lang="ts" setup>
47
+ import { useWait } from 'maz-ui/composables'
48
+ import { ref } from 'vue'
49
+
50
+ const wait = useWait()
51
+
52
+ const submitted = ref(false)
53
+
54
+ function sleep(ms: number) {
55
+ return new Promise(resolve => setTimeout(resolve, ms))
56
+ }
57
+
58
+ async function submitData() {
59
+ submitted.value = false
60
+ wait.start('DATA_SUBMITTING')
61
+
62
+ await sleep(2000)
63
+
64
+ submitted.value = true
65
+ wait.stop('DATA_SUBMITTING')
66
+ }
67
+ </script>
68
+
69
+ <template>
70
+ <MazBtn :loading="wait.isLoading('DATA_SUBMITTING')" @click="submitData">
71
+ Submit Data
72
+ </MazBtn>
73
+
74
+ <div v-if="submitted">
75
+ Data Submitted
76
+ </div>
77
+ </template>
78
+ ```
@@ -0,0 +1,46 @@
1
+ # Icons reference
2
+
3
+ > The 861 icons of `@maz-ui/icons`. Use them instead of inline SVG or another icon library.
4
+
5
+ ## Usage
6
+
7
+ ```vue
8
+ <script setup lang="ts">
9
+ import { MazTrash } from '@maz-ui/icons/static/MazTrash' // one icon, tree-shakable
10
+ import { MazXMark } from '@maz-ui/icons/lazy/MazXMark' // lazy-loaded async component
11
+ </script>
12
+
13
+ <template>
14
+ <MazTrash class="size-5 text-destructive" />
15
+ <MazBtn :start-icon="MazTrash" color="destructive">Delete</MazBtn>
16
+ </template>
17
+ ```
18
+
19
+ - Barrel import: `import { MazTrash, LazyMazTrash } from '@maz-ui/icons'`. Raw SVG string: `import { MazTrash } from '@maz-ui/icons/raw/MazTrash'`.
20
+ - Auto-import with unplugin-vue-components: `import { MazIconsResolver } from '@maz-ui/icons/resolvers'`.
21
+ - maz-ui components accept icons as props (`start-icon`, `end-icon`, `icon`...): pass the component itself, not a string.
22
+ - Size and color come from CSS: `class="size-5 text-primary"` (icons use `currentColor`).
23
+
24
+ ## Interface icons (329)
25
+
26
+ Heroicons-based outline icons (`MazTrash`, `MazXMark`, `MazMagnifyingGlass`...)
27
+
28
+ MazAcademicCap, MazAdjustmentsHorizontal, MazAdjustmentsVertical, MazArchiveBox, MazArchiveBoxArrowDown, MazArchiveBoxXMark, MazArrowDown, MazArrowDownCircle, MazArrowDownLeft, MazArrowDownOnSquare, MazArrowDownOnSquareStack, MazArrowDownRight, MazArrowDownTray, MazArrowLeft, MazArrowLeftCircle, MazArrowLeftEndOnRectangle, MazArrowLeftOnRectangle, MazArrowLeftStartOnRectangle, MazArrowLongDown, MazArrowLongLeft, MazArrowLongRight, MazArrowLongUp, MazArrowPath, MazArrowPathRoundedSquare, MazArrowRight, MazArrowRightCircle, MazArrowRightEndOnRectangle, MazArrowRightOnRectangle, MazArrowRightStartOnRectangle, MazArrowSmallDown, MazArrowSmallLeft, MazArrowSmallRight, MazArrowSmallUp, MazArrowsPointingIn, MazArrowsPointingOut, MazArrowsRightLeft, MazArrowsUpDown, MazArrowTopRightOnSquare, MazArrowTrendingDown, MazArrowTrendingUp, MazArrowTurnDownLeft, MazArrowTurnDownRight, MazArrowTurnLeftDown, MazArrowTurnLeftUp, MazArrowTurnRightDown, MazArrowTurnRightUp, MazArrowTurnUpLeft, MazArrowTurnUpRight, MazArrowUp, MazArrowUpCircle, MazArrowUpLeft, MazArrowUpOnSquare, MazArrowUpOnSquareStack, MazArrowUpRight, MazArrowUpTray, MazArrowUturnDown, MazArrowUturnLeft, MazArrowUturnRight, MazArrowUturnUp, MazAtSymbol, MazBackspace, MazBackward, MazBanknotes, MazBars2, MazBars3, MazBars3BottomLeft, MazBars3BottomRight, MazBars3CenterLeft, MazBars4, MazBarsArrowDown, MazBarsArrowUp, MazBattery0, MazBattery100, MazBattery50, MazBeaker, MazBell, MazBellAlert, MazBellSlash, MazBellSnooze, MazBold, MazBolt, MazBoltSlash, MazBookmark, MazBookmarkSlash, MazBookmarkSquare, MazBookOpen, MazBriefcase, MazBugAnt, MazBuildingLibrary, MazBuildingOffice, MazBuildingOffice2, MazBuildingStorefront, MazCake, MazCalculator, MazCalendar, MazCalendarDateRange, MazCalendarDays, MazCamera, MazChartBar, MazChartBarSquare, MazChartPie, MazChatBubbleBottomCenter, MazChatBubbleBottomCenterText, MazChatBubbleLeft, MazChatBubbleLeftEllipsis, MazChatBubbleLeftRight, MazChatBubbleOvalLeft, MazChatBubbleOvalLeftEllipsis, MazCheck, MazCheckBadge, MazCheckCircle, MazChevronDoubleDown, MazChevronDoubleLeft, MazChevronDoubleRight, MazChevronDoubleUp, MazChevronDown, MazChevronLeft, MazChevronRight, MazChevronUp, MazChevronUpDown, MazCircleStack, MazClipboard, MazClipboardDocument, MazClipboardDocumentCheck, MazClipboardDocumentList, MazClock, MazCloud, MazCloudArrowDown, MazCloudArrowUp, MazCodeBracket, MazCodeBracketSquare, MazCog, MazCog6Tooth, MazCog8Tooth, MazCommandLine, MazComputerDesktop, MazCpuChip, MazCreditCard, MazCube, MazCubeTransparent, MazCurrencyBangladeshi, MazCurrencyDollar, MazCurrencyEuro, MazCurrencyPound, MazCurrencyRupee, MazCurrencyYen, MazCursorArrowRays, MazCursorArrowRipple, MazDevicePhoneMobile, MazDeviceTablet, MazDivide, MazDocumentArrowDown, MazDocumentArrowUp, MazDocumentChartBar, MazDocumentCheck, MazDocumentCurrencyBangladeshi, MazDocumentCurrencyDollar, MazDocumentCurrencyEuro, MazDocumentCurrencyPound, MazDocumentCurrencyRupee, MazDocumentCurrencyYen, MazDocumentDuplicate, MazDocumentIcon, MazDocumentMagnifyingGlass, MazDocumentMinus, MazDocumentPlus, MazDocumentText, MazEllipsisHorizontal, MazEllipsisHorizontalCircle, MazEllipsisVertical, MazEnvelope, MazEnvelopeOpen, MazEquals, MazExclamationCircle, MazExclamationTriangle, MazEye, MazEyeDropper, MazEyeSlash, MazFaceFrown, MazFaceSmile, MazFilm, MazFingerPrint, MazFire, MazFlag, MazFolder, MazFolderArrowDown, MazFolderMinus, MazFolderOpen, MazFolderPlus, MazFork, MazForward, MazFunnel, MazGif, MazGift, MazGiftTop, MazGithub, MazGlobeAlt, MazGlobeAmericas, MazGlobeAsiaAustralia, MazGlobeEuropeAfrica, MazH1, MazH2, MazH3, MazHandRaised, MazHandThumbDown, MazHandThumbUp, MazHashtag, MazHeart, MazHome, MazHomeModern, MazIdentification, MazInbox, MazInboxArrowDown, MazInboxStack, MazInformationCircle, MazItalic, MazKey, MazLanguage, MazLifebuoy, MazLightBulb, MazLinkIcon, MazLinkSlash, MazListBullet, MazLockClosed, MazLockOpen, MazMagnifyingGlass, MazMagnifyingGlassCircle, MazMagnifyingGlassMinus, MazMagnifyingGlassPlus, MazMapIcon, MazMapPin, MazMegaphone, MazMicrophone, MazMinus, MazMinusCircle, MazMinusSmall, MazMoon, MazMusicalNote, MazNewspaper, MazNoImage, MazNoSymbol, MazNumberedList, MazPaintBrush, MazPaperAirplane, MazPaperClip, MazPause, MazPauseCircle, MazPencil, MazPencilSquare, MazPercentBadge, MazPhone, MazPhoneArrowDownLeft, MazPhoneArrowUpRight, MazPhoneXMark, MazPhoto, MazPlay, MazPlayCircle, MazPlayPause, MazPlus, MazPlusCircle, MazPlusSmall, MazPower, MazPresentationChartBar, MazPresentationChartLine, MazPrinter, MazPuzzlePiece, MazQrCode, MazQuestionMarkCircle, MazQueueList, MazQuote, MazRadioIcon, MazReceiptPercent, MazReceiptRefund, MazRectangleGroup, MazRectangleStack, MazRocketLaunch, MazRss, MazScale, MazScissors, MazServer, MazServerStack, MazShare, MazShieldCheck, MazShieldExclamation, MazShoppingBag, MazShoppingCart, MazSignal, MazSignalSlash, MazSlash, MazSparkles, MazSpeakerWave, MazSpeakerXMark, MazSquare2Stack, MazSquare3Stack3d, MazSquares2x2, MazSquaresPlus, MazStar, MazStarSolid, MazStop, MazStopCircle, MazStrikethrough, MazSun, MazSwatch, MazTableCells, MazTag, MazTelevision, MazTicket, MazTrash, MazTrophy, MazTruck, MazUnderline, MazUser, MazUserCircle, MazUserGroup, MazUserMinus, MazUserPlus, MazUsers, MazVariable, MazVideoCamera, MazVideoCameraSlash, MazViewColumns, MazViewfinderCircle, MazWallet, MazWifi, MazWindowIcon, MazWrench, MazWrenchScrewdriver, MazXCircle, MazXMark
29
+
30
+ ## Logos (20)
31
+
32
+ Brand and file-type logos
33
+
34
+ MazLogoAndroid, MazLogoApple, MazLogoCsv, MazLogoFacebook, MazLogoHtml, MazLogoInstagram, MazLogoJs, MazLogoJson, MazLogoLinkedin, MazLogoMarkdown, MazLogoNpm, MazLogoProperties, MazLogoReact, MazLogoTwitter, MazLogoTxt, MazLogoTypescript, MazLogoVue, MazLogoXliff, MazLogoXls, MazLogoXml
35
+
36
+ ## Country flags (3x2) (256)
37
+
38
+ `MazFlag` + ISO 3166-1 alpha-2 code in uppercase (`MazFlagFR`, `MazFlagUS`)
39
+
40
+ MazFlagAC, MazFlagAD, MazFlagAE, MazFlagAF, MazFlagAG, MazFlagAI, MazFlagAL, MazFlagAM, MazFlagAO, MazFlagAQ, MazFlagAR, MazFlagAS, MazFlagAT, MazFlagAU, MazFlagAW, MazFlagAX, MazFlagAZ, MazFlagBA, MazFlagBB, MazFlagBD, MazFlagBE, MazFlagBF, MazFlagBG, MazFlagBH, MazFlagBI, MazFlagBJ, MazFlagBL, MazFlagBM, MazFlagBN, MazFlagBO, MazFlagBQ, MazFlagBR, MazFlagBS, MazFlagBT, MazFlagBV, MazFlagBW, MazFlagBY, MazFlagBZ, MazFlagCA, MazFlagCC, MazFlagCD, MazFlagCF, MazFlagCG, MazFlagCH, MazFlagCI, MazFlagCK, MazFlagCL, MazFlagCM, MazFlagCN, MazFlagCO, MazFlagCR, MazFlagCU, MazFlagCV, MazFlagCW, MazFlagCX, MazFlagCY, MazFlagCZ, MazFlagDE, MazFlagDJ, MazFlagDK, MazFlagDM, MazFlagDO, MazFlagDZ, MazFlagEC, MazFlagEE, MazFlagEG, MazFlagEH, MazFlagER, MazFlagES, MazFlagET, MazFlagEU, MazFlagFI, MazFlagFJ, MazFlagFK, MazFlagFM, MazFlagFO, MazFlagFR, MazFlagGA, MazFlagGB, MazFlagGD, MazFlagGE, MazFlagGEAB, MazFlagGEOS, MazFlagGF, MazFlagGG, MazFlagGH, MazFlagGI, MazFlagGL, MazFlagGM, MazFlagGN, MazFlagGP, MazFlagGQ, MazFlagGR, MazFlagGS, MazFlagGT, MazFlagGU, MazFlagGW, MazFlagGY, MazFlagHK, MazFlagHM, MazFlagHN, MazFlagHR, MazFlagHT, MazFlagHU, MazFlagIC, MazFlagID, MazFlagIE, MazFlagIL, MazFlagIM, MazFlagIN, MazFlagIO, MazFlagIQ, MazFlagIR, MazFlagIS, MazFlagIT, MazFlagJE, MazFlagJM, MazFlagJO, MazFlagJP, MazFlagKE, MazFlagKG, MazFlagKH, MazFlagKI, MazFlagKM, MazFlagKN, MazFlagKP, MazFlagKR, MazFlagKW, MazFlagKY, MazFlagKZ, MazFlagLA, MazFlagLB, MazFlagLC, MazFlagLI, MazFlagLK, MazFlagLR, MazFlagLS, MazFlagLT, MazFlagLU, MazFlagLV, MazFlagLY, MazFlagMA, MazFlagMC, MazFlagMD, MazFlagME, MazFlagMF, MazFlagMG, MazFlagMH, MazFlagMK, MazFlagML, MazFlagMM, MazFlagMN, MazFlagMO, MazFlagMP, MazFlagMQ, MazFlagMR, MazFlagMS, MazFlagMT, MazFlagMU, MazFlagMV, MazFlagMW, MazFlagMX, MazFlagMY, MazFlagMZ, MazFlagNA, MazFlagNC, MazFlagNE, MazFlagNF, MazFlagNG, MazFlagNI, MazFlagNL, MazFlagNO, MazFlagNP, MazFlagNR, MazFlagNU, MazFlagNZ, MazFlagOM, MazFlagPA, MazFlagPE, MazFlagPF, MazFlagPG, MazFlagPH, MazFlagPK, MazFlagPL, MazFlagPM, MazFlagPN, MazFlagPR, MazFlagPS, MazFlagPT, MazFlagPW, MazFlagPY, MazFlagQA, MazFlagRE, MazFlagRO, MazFlagRS, MazFlagRU, MazFlagRW, MazFlagSA, MazFlagSB, MazFlagSC, MazFlagSD, MazFlagSE, MazFlagSG, MazFlagSH, MazFlagSI, MazFlagSJ, MazFlagSK, MazFlagSL, MazFlagSM, MazFlagSN, MazFlagSO, MazFlagSR, MazFlagSS, MazFlagST, MazFlagSV, MazFlagSX, MazFlagSY, MazFlagSZ, MazFlagTA, MazFlagTC, MazFlagTD, MazFlagTF, MazFlagTG, MazFlagTH, MazFlagTJ, MazFlagTK, MazFlagTL, MazFlagTM, MazFlagTN, MazFlagTO, MazFlagTR, MazFlagTT, MazFlagTV, MazFlagTW, MazFlagTZ, MazFlagUA, MazFlagUG, MazFlagUM, MazFlagUS, MazFlagUY, MazFlagUZ, MazFlagVA, MazFlagVC, MazFlagVE, MazFlagVG, MazFlagVI, MazFlagVN, MazFlagVU, MazFlagWF, MazFlagWS, MazFlagXK, MazFlagYE, MazFlagYT, MazFlagZA, MazFlagZM, MazFlagZW
41
+
42
+ ## Country flags (1x1) (256)
43
+
44
+ `MazFlagSquare` + ISO code (`MazFlagSquareFR`)
45
+
46
+ MazFlagSquareAC, MazFlagSquareAD, MazFlagSquareAE, MazFlagSquareAF, MazFlagSquareAG, MazFlagSquareAI, MazFlagSquareAL, MazFlagSquareAM, MazFlagSquareAO, MazFlagSquareAQ, MazFlagSquareAR, MazFlagSquareAS, MazFlagSquareAT, MazFlagSquareAU, MazFlagSquareAW, MazFlagSquareAX, MazFlagSquareAZ, MazFlagSquareBA, MazFlagSquareBB, MazFlagSquareBD, MazFlagSquareBE, MazFlagSquareBF, MazFlagSquareBG, MazFlagSquareBH, MazFlagSquareBI, MazFlagSquareBJ, MazFlagSquareBL, MazFlagSquareBM, MazFlagSquareBN, MazFlagSquareBO, MazFlagSquareBQ, MazFlagSquareBR, MazFlagSquareBS, MazFlagSquareBT, MazFlagSquareBV, MazFlagSquareBW, MazFlagSquareBY, MazFlagSquareBZ, MazFlagSquareCA, MazFlagSquareCC, MazFlagSquareCD, MazFlagSquareCF, MazFlagSquareCG, MazFlagSquareCH, MazFlagSquareCI, MazFlagSquareCK, MazFlagSquareCL, MazFlagSquareCM, MazFlagSquareCN, MazFlagSquareCO, MazFlagSquareCR, MazFlagSquareCU, MazFlagSquareCV, MazFlagSquareCW, MazFlagSquareCX, MazFlagSquareCY, MazFlagSquareCZ, MazFlagSquareDE, MazFlagSquareDJ, MazFlagSquareDK, MazFlagSquareDM, MazFlagSquareDO, MazFlagSquareDZ, MazFlagSquareEC, MazFlagSquareEE, MazFlagSquareEG, MazFlagSquareEH, MazFlagSquareER, MazFlagSquareES, MazFlagSquareET, MazFlagSquareEU, MazFlagSquareFI, MazFlagSquareFJ, MazFlagSquareFK, MazFlagSquareFM, MazFlagSquareFO, MazFlagSquareFR, MazFlagSquareGA, MazFlagSquareGB, MazFlagSquareGD, MazFlagSquareGE, MazFlagSquareGEAB, MazFlagSquareGEOS, MazFlagSquareGF, MazFlagSquareGG, MazFlagSquareGH, MazFlagSquareGI, MazFlagSquareGL, MazFlagSquareGM, MazFlagSquareGN, MazFlagSquareGP, MazFlagSquareGQ, MazFlagSquareGR, MazFlagSquareGS, MazFlagSquareGT, MazFlagSquareGU, MazFlagSquareGW, MazFlagSquareGY, MazFlagSquareHK, MazFlagSquareHM, MazFlagSquareHN, MazFlagSquareHR, MazFlagSquareHT, MazFlagSquareHU, MazFlagSquareIC, MazFlagSquareID, MazFlagSquareIE, MazFlagSquareIL, MazFlagSquareIM, MazFlagSquareIN, MazFlagSquareIO, MazFlagSquareIQ, MazFlagSquareIR, MazFlagSquareIS, MazFlagSquareIT, MazFlagSquareJE, MazFlagSquareJM, MazFlagSquareJO, MazFlagSquareJP, MazFlagSquareKE, MazFlagSquareKG, MazFlagSquareKH, MazFlagSquareKI, MazFlagSquareKM, MazFlagSquareKN, MazFlagSquareKP, MazFlagSquareKR, MazFlagSquareKW, MazFlagSquareKY, MazFlagSquareKZ, MazFlagSquareLA, MazFlagSquareLB, MazFlagSquareLC, MazFlagSquareLI, MazFlagSquareLK, MazFlagSquareLR, MazFlagSquareLS, MazFlagSquareLT, MazFlagSquareLU, MazFlagSquareLV, MazFlagSquareLY, MazFlagSquareMA, MazFlagSquareMC, MazFlagSquareMD, MazFlagSquareME, MazFlagSquareMF, MazFlagSquareMG, MazFlagSquareMH, MazFlagSquareMK, MazFlagSquareML, MazFlagSquareMM, MazFlagSquareMN, MazFlagSquareMO, MazFlagSquareMP, MazFlagSquareMQ, MazFlagSquareMR, MazFlagSquareMS, MazFlagSquareMT, MazFlagSquareMU, MazFlagSquareMV, MazFlagSquareMW, MazFlagSquareMX, MazFlagSquareMY, MazFlagSquareMZ, MazFlagSquareNA, MazFlagSquareNC, MazFlagSquareNE, MazFlagSquareNF, MazFlagSquareNG, MazFlagSquareNI, MazFlagSquareNL, MazFlagSquareNO, MazFlagSquareNP, MazFlagSquareNR, MazFlagSquareNU, MazFlagSquareNZ, MazFlagSquareOM, MazFlagSquarePA, MazFlagSquarePE, MazFlagSquarePF, MazFlagSquarePG, MazFlagSquarePH, MazFlagSquarePK, MazFlagSquarePL, MazFlagSquarePM, MazFlagSquarePN, MazFlagSquarePR, MazFlagSquarePS, MazFlagSquarePT, MazFlagSquarePW, MazFlagSquarePY, MazFlagSquareQA, MazFlagSquareRE, MazFlagSquareRO, MazFlagSquareRS, MazFlagSquareRU, MazFlagSquareRW, MazFlagSquareSA, MazFlagSquareSB, MazFlagSquareSC, MazFlagSquareSD, MazFlagSquareSE, MazFlagSquareSG, MazFlagSquareSH, MazFlagSquareSI, MazFlagSquareSJ, MazFlagSquareSK, MazFlagSquareSL, MazFlagSquareSM, MazFlagSquareSN, MazFlagSquareSO, MazFlagSquareSR, MazFlagSquareSS, MazFlagSquareST, MazFlagSquareSV, MazFlagSquareSX, MazFlagSquareSY, MazFlagSquareSZ, MazFlagSquareTA, MazFlagSquareTC, MazFlagSquareTD, MazFlagSquareTF, MazFlagSquareTG, MazFlagSquareTH, MazFlagSquareTJ, MazFlagSquareTK, MazFlagSquareTL, MazFlagSquareTM, MazFlagSquareTN, MazFlagSquareTO, MazFlagSquareTR, MazFlagSquareTT, MazFlagSquareTV, MazFlagSquareTW, MazFlagSquareTZ, MazFlagSquareUA, MazFlagSquareUG, MazFlagSquareUM, MazFlagSquareUS, MazFlagSquareUY, MazFlagSquareUZ, MazFlagSquareVA, MazFlagSquareVC, MazFlagSquareVE, MazFlagSquareVG, MazFlagSquareVI, MazFlagSquareVN, MazFlagSquareVU, MazFlagSquareWF, MazFlagSquareWS, MazFlagSquareXK, MazFlagSquareYE, MazFlagSquareYT, MazFlagSquareZA, MazFlagSquareZM, MazFlagSquareZW
@@ -0,0 +1,191 @@
1
+ # Tailwind CSS theme reference
2
+
3
+ > Every Tailwind utility, variant and CSS variable provided by the maz-ui 5.0.1-beta.0 theme. Generated from the `maz-ui/tailwindcss/*.css` sources: it is always in sync with the installed version.
4
+
5
+ ## Setup
6
+
7
+ ```css
8
+ /* your Tailwind entry, e.g. app/assets/css/main.css */
9
+ @import 'tailwindcss';
10
+ @import 'maz-ui/tailwindcss/theme.css';
11
+ @import 'maz-ui/tailwindcss/utilities.css';
12
+ ```
13
+
14
+ - Use the classes **without prefix**: `bg-primary`, `rounded-md`, `tab-m:flex`. The `maz:` prefix you may see in the library sources is internal to maz-ui and does not exist in your project.
15
+ - Every value is a runtime CSS variable driven by the active `@maz-ui/themes` preset: switching preset or color mode restyles every utility without rebuild.
16
+ - See `guide/tailwind.md` to extend the theme (custom colors, fonts, animations, variants).
17
+
18
+ ### Entry points
19
+
20
+ | Import | Content |
21
+ | --- | --- |
22
+ | `maz-ui/tailwindcss/theme.css` | Every theme token (colors, spacing, radius, breakpoints, shadows, z-index, typography, component surfaces, dark variant) |
23
+ | `maz-ui/tailwindcss/utilities.css` | maz-ui custom utilities (flex-center, padded-container, cap-f, disabled-*...) |
24
+ | `maz-ui/tailwindcss/theme-colors.css` | Colors only |
25
+ | `maz-ui/tailwindcss/theme-spacing.css` | Spacing scale only |
26
+ | `maz-ui/tailwindcss/theme-radius.css` | Border radius only |
27
+ | `maz-ui/tailwindcss/theme-breakpoints.css` | Breakpoints only |
28
+ | `maz-ui/tailwindcss/theme-shadows.css` | Shadows only |
29
+ | `maz-ui/tailwindcss/theme-z-index.css` | z-index scale only |
30
+ | `maz-ui/tailwindcss/theme-typography.css` | Fonts, border width, durations and easings only |
31
+ | `maz-ui/tailwindcss/theme-components.css` | bg-container and bg-input surfaces only |
32
+ | `maz-ui/tailwindcss/theme-variants.css` | `dark:` variant wired to the `.dark` class only |
33
+
34
+ ## Colors
35
+
36
+ Each color works with every color utility (bg-, text-, border-, ring-, outline-, fill-, stroke-, divide-, from-, via-, to-, decoration-, placeholder-, accent-, caret-, shadow-) and with opacity modifiers (`bg-primary/50`). Colors are light/dark aware (`light-dark()`): **do not add `dark:` overrides for theme colors**.
37
+
38
+ | Color | Utilities | Foreground | Scale | CSS variable | Use for |
39
+ | --- | --- | --- | --- | --- | --- |
40
+ | `primary` | `bg-primary` `text-primary` `border-primary` | `text-primary-foreground` | `-50` to `-950` | `--maz-primary` | Brand primary: main actions, links, focus |
41
+ | `secondary` | `bg-secondary` `text-secondary` `border-secondary` | `text-secondary-foreground` | `-50` to `-950` | `--maz-secondary` | Brand secondary |
42
+ | `accent` | `bg-accent` `text-accent` `border-accent` | `text-accent-foreground` | `-50` to `-950` | `--maz-accent` | Brand accent, highlights |
43
+ | `destructive` | `bg-destructive` `text-destructive` `border-destructive` | `text-destructive-foreground` | `-50` to `-950` | `--maz-destructive` | Error / danger state, destructive actions |
44
+ | `success` | `bg-success` `text-success` `border-success` | `text-success-foreground` | `-50` to `-950` | `--maz-success` | Success state |
45
+ | `warning` | `bg-warning` `text-warning` `border-warning` | `text-warning-foreground` | `-50` to `-950` | `--maz-warning` | Warning state |
46
+ | `info` | `bg-info` `text-info` `border-info` | `text-info-foreground` | `-50` to `-950` | `--maz-info` | Informational state |
47
+ | `contrast` | `bg-contrast` `text-contrast` `border-contrast` | `text-contrast-foreground` | `-50` to `-950` | `--maz-contrast` | Neutral high-contrast color (near black in light mode, near white in dark mode) |
48
+ | `surface` | `bg-surface` `text-surface` `border-surface` | - | `-50` to `-950` | `--maz-surface` | Page and container backgrounds |
49
+ | `foreground` | `bg-foreground` `text-foreground` `border-foreground` | - | `-50` to `-950` | `--maz-foreground` | Body text |
50
+ | `divider` | `bg-divider` `text-divider` `border-divider` | - | `-50` to `-950` | `--maz-divider` | Borders and separators |
51
+ | `shadow` | `shadow-shadow/20` `bg-shadow` | - | `-50` to `-950` | `--maz-shadow` | Shadow tint (used by the shadow-* utilities) |
52
+ | `overlay` | `bg-overlay` `bg-overlay/60` | - | `-50` to `-950` | `--maz-overlay` | Backdrops and scrims behind dialogs |
53
+ | `muted` | `bg-muted` `text-muted` `border-muted` | - | `-50` to `-950` | `--maz-muted` | Secondary text, placeholders, disabled content |
54
+ | `container` | `bg-container` | - | - | `--maz-container-bg` | Background of MazCard, MazContainer, MazDialog, MazPopover, MazDrawer... (follows the preset `components.container`) |
55
+ | `input` | `bg-input` | - | - | `--maz-input-bg` | Background of MazInput, MazSelect, MazTextarea, MazCheckbox... (follows the preset `components.input`) |
56
+
57
+ - `-foreground` is the readable text color on top of the base color: `bg-primary text-primary-foreground`.
58
+ - Scales go from light (`-50`) to dark (`-950`), `-500` is the base color. They are derived from the base color in OKLCh, so they follow the preset.
59
+ - Never use the Tailwind default palette (`bg-blue-500`, `text-gray-600`, `bg-white`, `text-black`) nor hard-coded colors (`#fff`, `rgb()`): pick the matching theme color (`bg-surface`, `text-foreground`, `text-muted`, `border-divider`, `bg-primary`...).
60
+
61
+ ## Border radius
62
+
63
+ | Utility | Value |
64
+ | --- | --- |
65
+ | `rounded-xs` | `var(--maz-rounded-xs)` |
66
+ | `rounded-sm` | `var(--maz-rounded-sm)` |
67
+ | `rounded-md` | `var(--maz-rounded-md)` |
68
+ | `rounded-lg` | `var(--maz-rounded-lg)` |
69
+ | `rounded-xl` | `var(--maz-rounded-xl)` |
70
+ | `rounded-2xl` | `var(--maz-rounded-2xl)` |
71
+ | `rounded-3xl` | `var(--maz-rounded-3xl)` |
72
+ | `rounded` | `var(--maz-rounded-md)` |
73
+
74
+ `rounded-full` and `rounded-none` keep their Tailwind values.
75
+
76
+ ## Shadows
77
+
78
+ | Utility | Value |
79
+ | --- | --- |
80
+ | `shadow-xs` | `0 1px 2px 0 color-mix(in srgb, var(--color-elevation) 5%, transparent)` |
81
+ | `shadow-sm` | `var(--maz-shadow-style-sm)` |
82
+ | `shadow-md` | `var(--maz-shadow-style-md)` |
83
+ | `shadow-lg` | `var(--maz-shadow-style-lg)` |
84
+ | `shadow-xl` | `var(--maz-shadow-style-xl)` |
85
+ | `shadow-elevation` | `var(--maz-shadow-style-elevation)` |
86
+
87
+ Use `shadow-elevation` for raised surfaces (cards, popovers, menus).
88
+
89
+ ## Spacing
90
+
91
+ `--spacing` is `var(--maz-space)` (`0.25rem` by default): every spacing utility (`p-4`, `gap-2`, `mt-6`, `w-10`, `inset-1`...) is a multiple of the preset `space` token. Use the scale, avoid arbitrary values like `p-[13px]`.
92
+
93
+ ## Breakpoints
94
+
95
+ Mobile-first `min-width` variants, added on top of the Tailwind defaults (`sm:` to `2xl:` still work). Prefix them with `max-` for max-width queries (`max-tab-m:hidden`).
96
+
97
+ | Variant | Min width |
98
+ | --- | --- |
99
+ | `mob-s:` | 320px |
100
+ | `mob-m:` | 425px |
101
+ | `mob-l:` | 576px |
102
+ | `tab-s:` | 640px |
103
+ | `tab-m:` | 768px |
104
+ | `tab-l:` | 992px |
105
+ | `lap-s:` | 1024px |
106
+ | `lap-m:` | 1280px |
107
+ | `lap-l:` | 1366px |
108
+ | `lap-xl:` | 1440px |
109
+ | `lap-2xl:` | 1680px |
110
+ | `lap-3xl:` | 1920px |
111
+
112
+ In TypeScript: `import { screens } from 'maz-ui/tailwindcss'`, or the `useBreakpoints` composable.
113
+
114
+ ## Typography and motion
115
+
116
+ | Utility | Value |
117
+ | --- | --- |
118
+ | `font-sans` | `var(--maz-font-family)` |
119
+ | `font-mono` | `var(--maz-font-mono-stack)` |
120
+ | `font-display` | `var(--maz-font-display-stack)` |
121
+ | `duration-(--duration-fast)` | `var(--maz-motion-fast, 100ms)` |
122
+ | `duration-(--duration-normal)` | `var(--maz-motion-normal, 200ms)` |
123
+ | `duration-(--duration-slow)` | `var(--maz-motion-slow, 300ms)` |
124
+ | `ease-out` | `var(--maz-easing-out, cubic-bezier(0.4, 0, 0.2, 1))` |
125
+ | `ease-in` | `var(--maz-easing-in, cubic-bezier(0.4, 0, 1, 1))` |
126
+ | `ease-in-out` | `var(--maz-easing-in-out, cubic-bezier(0.4, 0, 0.2, 1))` |
127
+
128
+ - The default border width and the default transition duration and easing also follow the preset.
129
+ - Durations are theme variables, use them with the arbitrary syntax: `transition-colors duration-(--duration-fast)`.
130
+
131
+ ## z-index
132
+
133
+ | Utility | Value |
134
+ | --- | --- |
135
+ | `z-1` | `1` |
136
+ | `z-2` | `2` |
137
+ | `z-3` | `3` |
138
+ | `z-4` | `4` |
139
+ | `z-5` | `5` |
140
+ | `z-15` | `15` |
141
+ | `z-25` | `25` |
142
+ | `z-35` | `35` |
143
+ | `z-45` | `45` |
144
+ | `z-75` | `75` |
145
+ | `z-100` | `100` |
146
+ | `z-default-backdrop` | `1050` |
147
+
148
+ ## Custom utilities
149
+
150
+ From `maz-ui/tailwindcss/utilities.css`:
151
+
152
+ | Utility | CSS |
153
+ | --- | --- |
154
+ | `flex-center` | `align-items: center; justify-content: center;` |
155
+ | `z-default-backdrop` | `z-index: 1050;` |
156
+ | `padded-container-no-p` | `inline-size: 100%; padding-inline: calc(50% - var(--maz-container-max-width) / 2);` |
157
+ | `padded-container` | `inline-size: 100%; padding-inline: var(--maz-container-padding);` |
158
+ | `cap-f` | `&::first-letter { text-transform: capitalize; }` |
159
+ | `disabled-cursor` | `cursor: var(--maz-disabled-cursor);` |
160
+ | `disabled-opacity` | `opacity: var(--maz-disabled-opacity);` |
161
+ | `disabled-state` | `cursor: var(--maz-disabled-cursor); opacity: var(--maz-disabled-opacity);` |
162
+
163
+ ## Variants
164
+
165
+ | Variant | Selector |
166
+ | --- | --- |
167
+ | `dark:` | `&:where(.dark, .dark *)` |
168
+
169
+ `dark:` matches the `.dark` class toggled by `useTheme()` (`darkModeStrategy: 'class'`, the default). Theme colors already adapt to dark mode: keep `dark:` for real layout or content differences.
170
+
171
+ ## Layout variables
172
+
173
+ Override them in your CSS (`:root { --maz-container-max-width: 1024px; }`), they drive the `padded-container` utilities:
174
+
175
+ | Variable | Default |
176
+ | --- | --- |
177
+ | `--maz-container-padding-mobile` | `1rem` |
178
+ | `--maz-container-padding-tablet` | `2rem` |
179
+ | `--maz-container-padding-desktop` | `2.5rem` |
180
+ | `--maz-container-padding-value` | `var(--maz-container-padding-mobile)` |
181
+ | `--maz-container-width` | `calc(100% - var(--maz-container-padding-value) * 2)` |
182
+ | `--maz-container-padding` | `calc(50% - var(--maz-container-width) / 2)` |
183
+ | `--maz-container-max-width` | `1440px` |
184
+
185
+ ## Vue transitions
186
+
187
+ Transition names shipped in `maz-ui/style.css`, usable with `<Transition name="...">`: `maz-expand`, `maz-scale`, `maz-scale-fade`, `maz-scale-loading`, `maz-slide`, `maz-slideinvert`, `maz-slidevnext`, `maz-slidevprev`, `maz-tags`, `maz-tags-invert`.
188
+
189
+ ## CSS variables in custom CSS
190
+
191
+ In `<style>` blocks or plain CSS, use the runtime variables instead of literal values: `var(--maz-primary)`, `var(--maz-surface)`, `var(--maz-foreground)`, `var(--maz-divider)`, `var(--maz-rounded-md)`, `var(--maz-shadow-style-elevation)`, `calc(var(--maz-space) * 4)`, `var(--maz-font-family)`, `var(--maz-easing-out)`. With Tailwind, prefer `@apply` after `@reference "<your tailwind entry>"` in Vue SFC style blocks.
package/docs/rules.md ADDED
@@ -0,0 +1,57 @@
1
+ ---
2
+ title: "maz-ui rules for AI agents"
3
+ description: "How to use maz-ui and its ecosystem in this project: look-up workflow, components, icons, helpers, Tailwind theme tokens, imports."
4
+ ---
5
+
6
+ # maz-ui rules for AI agents
7
+
8
+ > maz-ui 5.0.1-beta.0 is installed: these rules and the docs in `node_modules/maz-ui/docs` match this version.
9
+
10
+ This project is built with **maz-ui** and its ecosystem (`@maz-ui/themes`, `@maz-ui/icons`, `@maz-ui/utils`, `@maz-ui/translations`, `@maz-ui/nuxt`). Reuse what it provides instead of re-implementing it: most UI elements, helpers, icons and styles you need already exist.
11
+
12
+ ### Look it up before you write it
13
+
14
+ Before creating a component, composable, helper, icon or style, check what maz-ui offers:
15
+
16
+ - **MCP server `maz-ui`** (when available): `search_docs` (describe the need: "confirm before delete", "phone input"), `get_component_api` (exact props, events, slots), `find_icons`, `get_theme_tokens` (Tailwind classes), `get_doc`, `review_code`.
17
+ - **Version-matched docs** in `node_modules/maz-ui/docs/` (start with `README.md`; in a monorepo, resolve `maz-ui` from the app package). Read the relevant page before using an API.
18
+
19
+ Never guess an API: only use props, events, slots and imports that are documented.
20
+
21
+ ### Components
22
+
23
+ - Use `Maz*` components instead of native elements or hand-made widgets: `MazBtn` (not `<button>`), `MazInput`, `MazSelect`, `MazCheckbox`, `MazSwitch`, `MazTextarea`, `MazDialog`, `MazDialogConfirm`, `MazDrawer`, `MazBottomSheet`, `MazPopover`, `MazDropdown`, `MazTabs`, `MazTable`, `MazCard`, `MazAvatar`, `MazBadge`, `MazAlert`, `MazSkeleton`, `MazSpinner`, `MazDatePicker`, `MazInputPhoneNumber`, `MazDropzone`, `MazStepper`, `MazSidebar`, `MazPagination`...
24
+ - Prop values are typed: colors are `primary | secondary | accent | info | success | warning | destructive | contrast | transparent` (plus `surface` on some components), sizes `mini | xs | sm | md | lg | xl`.
25
+ - Feedback and overlays: `useToast()` for notifications, `useDialog()` or `MazDialogConfirm` for confirmations, `useWait()` for loading states.
26
+ - Forms: `useFormValidator` / `useFormField` with your Standard Schema library (Zod, Valibot, ArkType).
27
+
28
+ ### Icons
29
+
30
+ Use `@maz-ui/icons` (860+ icons: `MazTrash`, `MazXMark`, `MazMagnifyingGlass`, `MazFlagFR`, `MazLogoVue`...). Never inline SVG or add another icon library. Pass icon components to icon props: `<MazBtn :start-icon="MazTrash">`.
31
+
32
+ ### Helpers and composables
33
+
34
+ Use `@maz-ui/utils` and maz-ui composables instead of lodash, VueUse or hand-written code: `debounce`, `throttle`, `sleep`, `isEqual`, `capitalize`, `formatCurrency`, `formatDate`, `formatNumber`, `formatPhoneNumber`, `getCookie`/`setCookie`, `useBreakpoints`, `useWindowSize`, `useTimer`, `useIdleTimeout`, `useSwipe`, `vClickOutside`, `vTooltip`, `vLazyImg`...
35
+
36
+ ### Styling with Tailwind
37
+
38
+ The maz-ui theme is exposed to Tailwind (`@import 'maz-ui/tailwindcss/theme.css'`). Only use its tokens:
39
+
40
+ - Colors: `primary`, `secondary`, `accent`, `info`, `success`, `warning`, `destructive`, `contrast` (each with `-foreground` and `-50` to `-950`), `surface`, `foreground`, `muted`, `divider`, `overlay`, plus `bg-container` and `bg-input`. Example: `bg-surface text-foreground border-divider`, `bg-primary text-primary-foreground`, `text-muted`.
41
+ - Never use the default Tailwind palette (`bg-blue-500`, `text-gray-600`, `bg-white`, `text-black`) nor hard-coded colors (`#fff`, `rgb()`, `bg-[#...]`). Theme colors already adapt to dark mode: do not add `dark:` color overrides.
42
+ - Radius `rounded-*`, shadows `shadow-sm` to `shadow-xl` and `shadow-elevation`, spacing scale (`p-4`, `gap-2`), breakpoints `mob-*`, `tab-*`, `lap-*` (plus `sm` to `2xl`), utilities `flex-center`, `padded-container`.
43
+ - **No `maz:` prefix** in this project: it is internal to the maz-ui library and its documentation.
44
+ - In custom CSS, use the variables: `var(--maz-primary)`, `var(--maz-rounded-md)`, `calc(var(--maz-space) * 4)`.
45
+
46
+ ### Theme
47
+
48
+ Brand colors, fonts, radius and spacing come from a `@maz-ui/themes` preset (`definePreset`), not from overrides scattered in CSS. Use `useTheme()` for dark mode and presets (`toggleDarkMode`, `setColorMode`, `updateTheme`), never toggle the `dark` class or store the mode yourself.
49
+
50
+ ### Imports
51
+
52
+ - Deep imports: `maz-ui/components/MazBtn`, `maz-ui/composables/useToast`, `maz-ui/directives/vTooltip`, `@maz-ui/utils/helpers/debounce`, `@maz-ui/icons/static/MazTrash`. The `maz-ui` root entry only exports types. Never import from `maz-ui/src` or `maz-ui/dist`.
53
+ - With `@maz-ui/nuxt`, components and composables are auto-imported: do not import them.
54
+
55
+ ### Before you finish
56
+
57
+ Run `review_code` (MCP) on the files you changed, or `npx @maz-ui/mcp review <files>`, and fix every finding.