@maz-ui/mcp 5.0.0-beta.2 → 5.0.0-beta.24

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 (142) hide show
  1. package/README.md +1 -1
  2. package/dist/mcp.d.mts +22 -9
  3. package/dist/mcp.d.ts +22 -9
  4. package/dist/mcp.mjs +160 -83
  5. package/docs/generated-docs/maz-avatar.doc.md +25 -25
  6. package/docs/generated-docs/maz-btn.doc.md +1 -1
  7. package/docs/generated-docs/maz-checkbox.doc.md +16 -17
  8. package/docs/generated-docs/maz-circular-progress-bar.doc.md +1 -1
  9. package/docs/generated-docs/maz-code-highlight.doc.md +11 -0
  10. package/docs/generated-docs/maz-date-picker.doc.md +41 -41
  11. package/docs/generated-docs/maz-drawer.doc.md +7 -8
  12. package/docs/generated-docs/maz-expand-animation.doc.md +4 -4
  13. package/docs/generated-docs/maz-fullscreen-loader.doc.md +5 -5
  14. package/docs/generated-docs/maz-gallery.doc.md +15 -15
  15. package/docs/generated-docs/maz-input-code.doc.md +16 -16
  16. package/docs/generated-docs/maz-input-phone-number.doc.md +42 -38
  17. package/docs/generated-docs/maz-input-price.doc.md +14 -14
  18. package/docs/generated-docs/maz-input-tags.doc.md +16 -16
  19. package/docs/generated-docs/maz-input.doc.md +33 -33
  20. package/docs/generated-docs/maz-lazy-img.doc.md +14 -14
  21. package/docs/generated-docs/maz-loading-bar.doc.md +4 -4
  22. package/docs/generated-docs/maz-pull-to-refresh.doc.md +10 -10
  23. package/docs/generated-docs/maz-radio-buttons.doc.md +17 -17
  24. package/docs/generated-docs/maz-radio.doc.md +16 -16
  25. package/docs/generated-docs/maz-reading-progress-bar.doc.md +4 -4
  26. package/docs/generated-docs/maz-sidebar-content.doc.md +5 -0
  27. package/docs/generated-docs/maz-sidebar-footer.doc.md +5 -0
  28. package/docs/generated-docs/maz-sidebar-group.doc.md +11 -0
  29. package/docs/generated-docs/maz-sidebar-header.doc.md +5 -0
  30. package/docs/generated-docs/maz-sidebar-menu-button.doc.md +27 -0
  31. package/docs/generated-docs/maz-sidebar-menu-item.doc.md +5 -0
  32. package/docs/generated-docs/maz-sidebar-menu-sub.doc.md +16 -0
  33. package/docs/generated-docs/maz-sidebar-menu.doc.md +5 -0
  34. package/docs/generated-docs/maz-sidebar-separator.doc.md +0 -0
  35. package/docs/generated-docs/maz-sidebar-trigger.doc.md +5 -0
  36. package/docs/generated-docs/maz-sidebar.doc.md +36 -0
  37. package/docs/generated-docs/maz-slider.doc.md +1 -1
  38. package/docs/generated-docs/maz-spinner.doc.md +4 -4
  39. package/docs/generated-docs/maz-switch.doc.md +14 -14
  40. package/docs/generated-docs/maz-table.doc.md +5 -5
  41. package/docs/generated-docs/maz-textarea.doc.md +25 -24
  42. package/docs/generated-docs/maz-ticker.doc.md +1 -1
  43. package/docs/generated-docs/maz-window-mockup.doc.md +23 -0
  44. package/docs/src/blog/v4.md +1 -1
  45. package/docs/src/blog/v5.md +5 -7
  46. package/docs/src/components/maz-btn.md +1 -1
  47. package/docs/src/components/maz-code-highlight.md +233 -0
  48. package/docs/src/components/maz-container.md +2 -2
  49. package/docs/src/components/maz-date-picker.md +1 -1
  50. package/docs/src/components/maz-dialog.md +46 -0
  51. package/docs/src/components/maz-icon.md +2 -2
  52. package/docs/src/components/maz-input-phone-number.md +106 -103
  53. package/docs/src/components/maz-sidebar.md +719 -0
  54. package/docs/src/components/maz-textarea.md +27 -1
  55. package/docs/src/components/maz-timeline.md +60 -0
  56. package/docs/src/components/maz-window-mockup.md +249 -0
  57. package/docs/src/directives/click-outside.md +8 -15
  58. package/docs/src/directives/fullscreen-img.md +1 -1
  59. package/docs/src/directives/lazy-img.md +5 -5
  60. package/docs/src/directives/tooltip.md +24 -1
  61. package/docs/src/directives/zoom-img.md +1 -1
  62. package/docs/src/ecosystem/eslint-config.md +95 -1
  63. package/docs/src/{guide/icons.md → ecosystem/icons/index.md} +1 -1
  64. package/docs/src/ecosystem/node/exec-promise.md +87 -0
  65. package/docs/src/ecosystem/node/index.md +53 -0
  66. package/docs/src/ecosystem/node/logger.md +146 -0
  67. package/docs/src/ecosystem/node/print-banner.md +93 -0
  68. package/docs/src/{guide → ecosystem}/nuxt.md +81 -47
  69. package/docs/src/{guide → ecosystem}/themes.md +153 -72
  70. package/docs/src/{guide → ecosystem}/translations.md +1 -1
  71. package/docs/src/ecosystem/utils/camel-case.md +31 -0
  72. package/docs/src/{helpers → ecosystem/utils}/capitalize.md +2 -3
  73. package/docs/src/ecosystem/utils/check-availability.md +79 -0
  74. package/docs/src/ecosystem/utils/cookie.md +80 -0
  75. package/docs/src/{helpers → ecosystem/utils}/currency.md +2 -2
  76. package/docs/src/{helpers → ecosystem/utils}/date.md +2 -2
  77. package/docs/src/ecosystem/utils/debounce-callback.md +38 -0
  78. package/docs/src/ecosystem/utils/debounce-id.md +69 -0
  79. package/docs/src/ecosystem/utils/debounce.md +65 -0
  80. package/docs/src/ecosystem/utils/fetch-locale-ip.md +33 -0
  81. package/docs/src/ecosystem/utils/format-json.md +33 -0
  82. package/docs/src/ecosystem/utils/format-phone-number.md +37 -0
  83. package/docs/src/ecosystem/utils/get-browser-locale.md +29 -0
  84. package/docs/src/ecosystem/utils/get-error-message.md +39 -0
  85. package/docs/src/ecosystem/utils/idle-timeout.md +90 -0
  86. package/docs/src/ecosystem/utils/index.md +60 -0
  87. package/docs/src/ecosystem/utils/is-client.md +32 -0
  88. package/docs/src/ecosystem/utils/is-equal.md +38 -0
  89. package/docs/src/ecosystem/utils/is-server.md +31 -0
  90. package/docs/src/ecosystem/utils/is-standalone-mode.md +43 -0
  91. package/docs/src/ecosystem/utils/kebab-case.md +36 -0
  92. package/docs/src/ecosystem/utils/normalize-string.md +77 -0
  93. package/docs/src/{helpers → ecosystem/utils}/number.md +2 -2
  94. package/docs/src/ecosystem/utils/pascal-case.md +35 -0
  95. package/docs/src/ecosystem/utils/script-loader.md +77 -0
  96. package/docs/src/ecosystem/utils/sleep.md +59 -0
  97. package/docs/src/ecosystem/utils/snake-case.md +36 -0
  98. package/docs/src/ecosystem/utils/swipe-handler.md +91 -0
  99. package/docs/src/ecosystem/utils/textarea-autogrow.md +41 -0
  100. package/docs/src/ecosystem/utils/throttle-id.md +48 -0
  101. package/docs/src/ecosystem/utils/throttle.md +57 -0
  102. package/docs/src/ecosystem/utils/truthy-filter.md +31 -0
  103. package/docs/src/ecosystem/utils/types/deep-key-of.md +48 -0
  104. package/docs/src/ecosystem/utils/types/deep-partial.md +42 -0
  105. package/docs/src/ecosystem/utils/types/deep-required.md +39 -0
  106. package/docs/src/ecosystem/utils/types/flatten-object-keys.md +44 -0
  107. package/docs/src/ecosystem/utils/types/generic-instance-type.md +42 -0
  108. package/docs/src/ecosystem/utils/types/infer-maybe-ref.md +35 -0
  109. package/docs/src/ecosystem/utils/upper-first.md +32 -0
  110. package/docs/src/ecosystem/utils/user-visibility.md +69 -0
  111. package/docs/src/guide/getting-started.md +15 -13
  112. package/docs/src/guide/global-defaults.md +101 -0
  113. package/docs/src/guide/maz-ui-provider.md +6 -3
  114. package/docs/src/guide/migration-v4.md +13 -9
  115. package/docs/src/guide/migration-v5.md +67 -12
  116. package/docs/src/guide/resolvers.md +7 -7
  117. package/docs/src/guide/tailwind.md +4 -0
  118. package/docs/src/guide/vue.md +4 -4
  119. package/docs/src/index.md +12 -12
  120. package/docs/src/plugins/aos.md +1 -1
  121. package/docs/src/plugins/wait.md +1 -1
  122. package/package.json +6 -5
  123. package/docs/src/helpers/camel-case.md +0 -14
  124. package/docs/src/helpers/check-availability.md +0 -14
  125. package/docs/src/helpers/debounce-callback.md +0 -14
  126. package/docs/src/helpers/debounce-id.md +0 -14
  127. package/docs/src/helpers/debounce.md +0 -14
  128. package/docs/src/helpers/is-client.md +0 -14
  129. package/docs/src/helpers/is-equal.md +0 -14
  130. package/docs/src/helpers/is-standalone-mode.md +0 -14
  131. package/docs/src/helpers/kebab-case.md +0 -14
  132. package/docs/src/helpers/normalize-string.md +0 -14
  133. package/docs/src/helpers/pascal-case.md +0 -14
  134. package/docs/src/helpers/script-loader.md +0 -14
  135. package/docs/src/helpers/sleep.md +0 -14
  136. package/docs/src/helpers/snake-case.md +0 -14
  137. package/docs/src/helpers/throttle-id.md +0 -14
  138. package/docs/src/helpers/throttle.md +0 -14
  139. /package/docs/src/{guide → ecosystem/icons}/icon-set.md +0 -0
  140. /package/docs/src/{guide → ecosystem}/mcp.md +0 -0
  141. /package/docs/src/{helpers → ecosystem/utils}/country-code-to-unicode-flag.md +0 -0
  142. /package/docs/src/{helpers → ecosystem/utils}/get-country-flag-url.md +0 -0
@@ -68,34 +68,28 @@ const results = ref<MazInputPhoneNumberData>()
68
68
  Control which countries appear in the dropdown and their order.
69
69
 
70
70
  <ComponentDemo>
71
- <div class="maz:space-y-4">
72
- <div>
73
- <h4 class="maz:font-semibold maz:mb-2">Preferred Countries</h4>
74
- <p class="maz:text-sm maz:text-muted maz:mb-2">Show your most common countries first</p>
75
- <MazInputPhoneNumber
76
- v-model="phone1"
77
- :preferred-countries="['US', 'FR', 'GB', 'DE', 'CA']"
78
- placeholder="Common countries appear first"
79
- />
80
- </div>
81
- <div>
82
- <h4 class="maz:font-semibold maz:mb-2">Only Specific Countries</h4>
83
- <p class="maz:text-sm maz:text-muted maz:mb-2">Limit to certain countries only</p>
84
- <MazInputPhoneNumber
85
- v-model="phone2"
86
- :only-countries="['US', 'FR', 'GB', 'DE', 'IT', 'ES']"
87
- placeholder="Only European + North American countries"
88
- />
89
- </div>
90
- <div>
91
- <h4 class="maz:font-semibold maz:mb-2">Ignore Countries</h4>
92
- <p class="maz:text-sm maz:text-muted maz:mb-2">Remove unwanted countries</p>
93
- <MazInputPhoneNumber
94
- v-model="phone3"
95
- :ignored-countries="['AF', 'AL', 'DZ']"
96
- placeholder="Some countries are hidden"
97
- />
98
- </div>
71
+ <div class="maz:flex maz:flex-col maz:gap-4">
72
+ <MazInputPhoneNumber
73
+ top-label="Preferred Countries"
74
+ assistive-text="Show your most common countries first"
75
+ v-model="phone1"
76
+ :preferred-countries="['US', 'FR', 'GB', 'DE', 'CA']"
77
+ placeholder="Common countries appear first"
78
+ />
79
+ <MazInputPhoneNumber
80
+ top-label="Only Specific Countries"
81
+ assistive-text="Limit to certain countries only"
82
+ v-model="phone2"
83
+ :only-countries="['US', 'FR', 'GB', 'DE', 'IT', 'ES']"
84
+ placeholder="Only European + North American countries"
85
+ />
86
+ <MazInputPhoneNumber
87
+ top-label="Ignore Countries"
88
+ assistive-text="Remove unwanted countries"
89
+ v-model="phone3"
90
+ :ignored-countries="['AF', 'AL', 'DZ']"
91
+ placeholder="Some countries are hidden"
92
+ />
99
93
  </div>
100
94
 
101
95
  <template #code>
@@ -133,22 +127,22 @@ Control which countries appear in the dropdown and their order.
133
127
  Choose how the country selector and phone input are arranged.
134
128
 
135
129
  <ComponentDemo>
136
- <div class="maz:space-y-6">
137
- <div>
138
- <h4 class="maz:font-semibold maz:mb-2">Responsive (Default)</h4>
139
- <p class="maz:text-sm maz:text-muted maz:mb-2">Stacks on mobile, side-by-side on desktop</p>
140
- <MazInputPhoneNumber orientation="responsive" />
141
- </div>
142
- <div>
143
- <h4 class="maz:font-semibold maz:mb-2">Always Row</h4>
144
- <p class="maz:text-sm maz:text-muted maz:mb-2">Side-by-side on all screen sizes</p>
145
- <MazInputPhoneNumber orientation="row" />
146
- </div>
147
- <div>
148
- <h4 class="maz:font-semibold maz:mb-2">Always Column</h4>
149
- <p class="maz:text-sm maz:text-muted maz:mb-2">Stacked on all screen sizes</p>
150
- <MazInputPhoneNumber orientation="col" />
151
- </div>
130
+ <div class="maz:flex maz:flex-col maz:gap-6">
131
+ <MazInputPhoneNumber
132
+ top-label="Responsive"
133
+ assistive-text="Stacks on mobile, side-by-side on desktop"
134
+ orientation="responsive"
135
+ />
136
+ <MazInputPhoneNumber
137
+ top-label="Always Row"
138
+ assistive-text="Side-by-side on all screen sizes"
139
+ orientation="row"
140
+ />
141
+ <MazInputPhoneNumber
142
+ top-label="Always Column"
143
+ assistive-text="Stacked on all screen sizes"
144
+ orientation="col"
145
+ />
152
146
  </div>
153
147
 
154
148
  <template #code>
@@ -156,13 +150,25 @@ Choose how the country selector and phone input are arranged.
156
150
  ```vue
157
151
  <template>
158
152
  <!-- Responsive layout (default) -->
159
- <MazInputPhoneNumber orientation="responsive" />
153
+ <MazInputPhoneNumber
154
+ top-label="Responsive"
155
+ assistive-text="Stacks on mobile, side-by-side on desktop"
156
+ orientation="responsive"
157
+ />
160
158
 
161
159
  <!-- Always side-by-side -->
162
- <MazInputPhoneNumber orientation="row" />
160
+ <MazInputPhoneNumber
161
+ top-label="Always Row"
162
+ assistive-text="Side-by-side on all screen sizes"
163
+ orientation="row"
164
+ />
163
165
 
164
166
  <!-- Always stacked -->
165
- <MazInputPhoneNumber orientation="col" />
167
+ <MazInputPhoneNumber
168
+ top-label="Always Column"
169
+ assistive-text="Stacked on all screen sizes"
170
+ orientation="col"
171
+ />
166
172
  </template>
167
173
  ```
168
174
 
@@ -174,34 +180,30 @@ Choose how the country selector and phone input are arranged.
174
180
  Customize what information is shown to users.
175
181
 
176
182
  <ComponentDemo>
177
- <div class="maz:space-y-6">
178
- <div>
179
- <h4 class="maz:font-semibold maz:mb-2">Show Country Names</h4>
180
- <p class="maz:text-sm maz:text-muted maz:mb-2">Display country names instead of calling codes</p>
181
- <MazInputPhoneNumber
182
- display-country-name
183
- :translations="{
184
- countrySelect: { placeholder: 'Choose country' }
185
- }"
186
- />
187
- </div>
188
- <div>
189
- <h4 class="maz:font-semibold maz:mb-2">Show Calling Codes in List</h4>
190
- <p class="maz:text-sm maz:text-muted maz:mb-2">Help users see the dialing codes</p>
191
- <MazInputPhoneNumber show-code-in-list />
192
- </div>
193
- <div>
194
- <h4 class="maz:font-semibold maz:mb-2">Hide Phone Examples</h4>
195
- <p class="maz:text-sm maz:text-muted maz:mb-2">
196
- Remove the example phone number hints (visible when the phone input is focused)
197
- </p>
198
- <MazInputPhoneNumber :example="false" />
199
- </div>
200
- <div>
201
- <h4 class="maz:font-semibold maz:mb-2">Hide Country Flags</h4>
202
- <p class="maz:text-sm maz:text-muted maz:mb-2">Text-only country selection</p>
203
- <MazInputPhoneNumber hide-flags />
204
- </div>
183
+ <div class="maz:flex maz:flex-col maz:gap-4">
184
+ <MazInputPhoneNumber
185
+ top-label="Show Country Names"
186
+ assistive-text="Display country names instead of calling codes"
187
+ display-country-name
188
+ :translations="{
189
+ countrySelect: { placeholder: 'Choose country' }
190
+ }"
191
+ />
192
+ <MazInputPhoneNumber
193
+ top-label="Show Calling Codes in List"
194
+ assistive-text="Help users see the dialing codes"
195
+ show-code-in-list
196
+ />
197
+ <MazInputPhoneNumber
198
+ top-label="Hide Phone Examples"
199
+ assistive-text="Remove the example phone number hints (visible when the phone input is focused)"
200
+ :example="false"
201
+ />
202
+ <MazInputPhoneNumber
203
+ top-label="Hide Country Flags"
204
+ assistive-text="Text-only country selection"
205
+ hide-flags
206
+ />
205
207
  </div>
206
208
 
207
209
  <template #code>
@@ -762,34 +764,35 @@ const mobilePhone = ref()
762
764
  Understanding what data the component provides.
763
765
 
764
766
  <ComponentDemo>
765
- <div class="maz:space-y-4">
766
- <MazInputPhoneNumber
767
- v-model="dataPhone"
768
- v-model:country-code="dataCountry"
769
- label="Enter a phone number to see data"
770
- @data="phoneData = $event"
771
- />
772
- <div v-if="phoneData" class="maz:bg-surface-400 maz:p-4 maz:rounded-md">
773
- <h4 class="maz:font-semibold maz:mb-3">📊 Phone Number Data</h4>
774
- <div class="maz:grid maz:grid-cols-1 maz:md:grid-cols-2 maz:gap-4 maz:text-sm">
775
- <div>
776
- <strong>Valid:</strong> {{ phoneData?.isValid ? '✅' : '❌' }}
777
- </div>
778
- <div>
779
- <strong>Country:</strong> {{ phoneData?.countryCode || 'None' }}
780
- </div>
781
- <div>
782
- <strong>National Format:</strong> {{ phoneData?.formatNational || 'None' }}
783
- </div>
784
- <div>
785
- <strong>International:</strong> {{ phoneData?.formatInternational || 'None' }}
786
- </div>
787
- <div>
788
- <strong>E164 Format:</strong> {{ phoneData?.e164 || 'None' }}
789
- </div>
790
- <div>
791
- <strong>Phone Type:</strong> {{ phoneData?.type || 'Unknown' }}
792
- </div>
767
+ <MazInputPhoneNumber
768
+ v-model="dataPhone"
769
+ v-model:country-code="dataCountry"
770
+ top-label="Your phone number"
771
+ placeholder="Enter a phone number to see data"
772
+ assistive-text="Enter your phone number in international format (e.g. +33612345678)"
773
+ @data="phoneData = $event"
774
+ />
775
+
776
+ <div v-if="phoneData" class="maz:bg-surface-400 maz:pt-8 maz:rounded-md">
777
+ <h4 class="maz:font-semibold maz:mb-3">📊 Phone Number Data</h4>
778
+ <div class="maz:grid maz:grid-cols-1 maz:md:grid-cols-2 maz:gap-4 maz:text-sm">
779
+ <div>
780
+ <strong>Valid:</strong> {{ phoneData?.isValid ? '✅' : '❌' }}
781
+ </div>
782
+ <div>
783
+ <strong>Country:</strong> {{ phoneData?.countryCode || 'None' }}
784
+ </div>
785
+ <div>
786
+ <strong>National Format:</strong> {{ phoneData?.formatNational || 'None' }}
787
+ </div>
788
+ <div>
789
+ <strong>International:</strong> {{ phoneData?.formatInternational || 'None' }}
790
+ </div>
791
+ <div>
792
+ <strong>E164 Format:</strong> {{ phoneData?.e164 || 'None' }}
793
+ </div>
794
+ <div>
795
+ <strong>Phone Type:</strong> {{ phoneData?.type || 'Unknown' }}
793
796
  </div>
794
797
  </div>
795
798
  </div>