fantasia-ui 0.2.32 → 0.2.36

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.
package/README.en.md CHANGED
@@ -57,7 +57,7 @@ npm install @vueuse/core
57
57
  // main.ts
58
58
  import { createApp } from 'vue'
59
59
  import FantasiaUI, { install } from 'fantasia-ui'
60
- import 'fantasia-ui/dist/index.css'
60
+ import 'fantasia-ui/dist/fantasia-ui.css'
61
61
  import App from './App.vue'
62
62
 
63
63
  const app = createApp(App)
@@ -70,7 +70,7 @@ app.mount('#app')
70
70
  ```vue
71
71
  <script setup lang="ts">
72
72
  import { FButton, FInput } from 'fantasia-ui'
73
- import 'fantasia-ui/dist/index.css'
73
+ import 'fantasia-ui/dist/fantasia-ui.css'
74
74
  </script>
75
75
 
76
76
  <template>
@@ -222,6 +222,48 @@ import { FRow, FCol, FSpace } from 'fantasia-ui'
222
222
  </template>
223
223
  ```
224
224
 
225
+ ### Message and Notification
226
+
227
+ ```vue
228
+ <script setup lang="ts">
229
+ import { FMessage, FNotification } from 'fantasia-ui'
230
+
231
+ // Message
232
+ const showMessage = () => {
233
+ FMessage.success('Success!')
234
+ }
235
+
236
+ // Notification
237
+ const showNotification = () => {
238
+ FNotification({
239
+ title: 'System Notification',
240
+ message: 'You have a new message',
241
+ type: 'info'
242
+ })
243
+ }
244
+
245
+ // Use in async operations
246
+ const handleSubmit = async () => {
247
+ try {
248
+ await submitForm()
249
+ FMessage.success('Submitted successfully!')
250
+ } catch (error) {
251
+ FMessage.error('Failed to submit, please try again')
252
+ }
253
+ }
254
+ </script>
255
+
256
+ <template>
257
+ <div>
258
+ <FButton @click="showMessage">Show Message</FButton>
259
+ <FButton @click="showNotification">Show Notification</FButton>
260
+ <FButton @click="handleSubmit">Submit Form</FButton>
261
+ </div>
262
+ </template>
263
+ ```
264
+
265
+ > 💡 View complete FMessage and FNotification API documentation: [Usage Guide](./MESSAGE_USAGE.md)
266
+
225
267
  ## 🎨 Theme Customization
226
268
 
227
269
  The component library supports theme customization via CSS variables:
@@ -296,10 +338,14 @@ Or add to `src/env.d.ts`:
296
338
 
297
339
  ## 🔗 Links
298
340
 
299
- - [Changelog](./CHANGELOG.md)
341
+ - [Changelog (中文)](./CHANGELOG.zh-CN.md)
342
+ - [Changelog (English)](./CHANGELOG.md)
343
+ - [Type Support Documentation](./TYPE_SUPPORT.md)
300
344
  - [Optimization Report](./OPTIMIZATION.md)
301
- - [Issues](https://github.com/shuster/fantasia-ui/issues)
345
+ - [Build Issue Solutions](./BUILD_FIX.md)
302
346
  - [Contributing Guide](./CONTRIBUTING.md)
347
+ - [Publish Guide](./.github/PUBLISH_GUIDE.md)
348
+ - [Issues](https://github.com/ShusterLi/fantasia-ui/issues)
303
349
 
304
350
  ## 📄 License
305
351
 
package/README.md CHANGED
@@ -57,7 +57,7 @@ npm install @vueuse/core
57
57
  // main.ts
58
58
  import { createApp } from 'vue'
59
59
  import FantasiaUI, { install } from 'fantasia-ui'
60
- import 'fantasia-ui/dist/index.css'
60
+ import 'fantasia-ui/dist/fantasia-ui.css'
61
61
  import App from './App.vue'
62
62
 
63
63
  const app = createApp(App)
@@ -70,7 +70,7 @@ app.mount('#app')
70
70
  ```vue
71
71
  <script setup lang="ts">
72
72
  import { FButton, FInput } from 'fantasia-ui'
73
- import 'fantasia-ui/dist/index.css'
73
+ import 'fantasia-ui/dist/fantasia-ui.css'
74
74
  </script>
75
75
 
76
76
  <template>
@@ -222,6 +222,48 @@ import { FRow, FCol, FSpace } from 'fantasia-ui'
222
222
  </template>
223
223
  ```
224
224
 
225
+ ### 消息提示和通知
226
+
227
+ ```vue
228
+ <script setup lang="ts">
229
+ import { FMessage, FNotification } from 'fantasia-ui'
230
+
231
+ // 消息提示
232
+ const showMessage = () => {
233
+ FMessage.success('操作成功!')
234
+ }
235
+
236
+ // 通知
237
+ const showNotification = () => {
238
+ FNotification({
239
+ title: '系统通知',
240
+ message: '您有一条新消息',
241
+ type: 'info'
242
+ })
243
+ }
244
+
245
+ // 在异步操作中使用
246
+ const handleSubmit = async () => {
247
+ try {
248
+ await submitForm()
249
+ FMessage.success('提交成功!')
250
+ } catch (error) {
251
+ FMessage.error('提交失败,请重试')
252
+ }
253
+ }
254
+ </script>
255
+
256
+ <template>
257
+ <div>
258
+ <FButton @click="showMessage">显示消息</FButton>
259
+ <FButton @click="showNotification">显示通知</FButton>
260
+ <FButton @click="handleSubmit">提交表单</FButton>
261
+ </div>
262
+ </template>
263
+ ```
264
+
265
+ > 💡 查看完整的 FMessage 和 FNotification API 文档:[使用指南](./MESSAGE_USAGE.md)
266
+
225
267
  ## 🎨 主题定制
226
268
 
227
269
  组件库支持 CSS 变量自定义主题:
@@ -298,7 +340,11 @@ const buttonProps: FButtonProps = {
298
340
 
299
341
  - [更新日志(中文)](./CHANGELOG.zh-CN.md)
300
342
  - [更新日志(English)](./CHANGELOG.md)
343
+ - [类型支持文档](./TYPE_SUPPORT.md)
301
344
  - [优化报告](./OPTIMIZATION.md)
345
+ - [构建问题解决方案](./BUILD_FIX.md)
346
+ - [贡献指南](./CONTRIBUTING.md)
347
+ - [发布指南](./.github/PUBLISH_GUIDE.md)
302
348
  - [问题反馈](https://github.com/ShusterLi/fantasia-ui/issues)
303
349
 
304
350
  ## 📄 开源协议
@@ -6823,7 +6823,7 @@ to {
6823
6823
  .f-input-number__stack-btn:disabled {
6824
6824
  opacity: 0.4;
6825
6825
  cursor: not-allowed;
6826
- }.f-result[data-v-c8f97d09] {
6826
+ }.f-result[data-v-1667a865] {
6827
6827
  display: flex;
6828
6828
  flex-direction: column;
6829
6829
  align-items: center;
@@ -6832,50 +6832,50 @@ to {
6832
6832
  padding: 48px 24px;
6833
6833
  --_color: var(--blue);
6834
6834
  }
6835
- .f-result--success[data-v-c8f97d09] {
6835
+ .f-result--success[data-v-1667a865] {
6836
6836
  --_color: var(--green);
6837
6837
  }
6838
- .f-result--error[data-v-c8f97d09] {
6838
+ .f-result--error[data-v-1667a865] {
6839
6839
  --_color: var(--red);
6840
6840
  }
6841
- .f-result--warning[data-v-c8f97d09] {
6841
+ .f-result--warning[data-v-1667a865] {
6842
6842
  --_color: var(--gold);
6843
6843
  }
6844
- .f-result--403[data-v-c8f97d09], .f-result--404[data-v-c8f97d09], .f-result--500[data-v-c8f97d09] {
6844
+ .f-result--403[data-v-1667a865], .f-result--404[data-v-1667a865], .f-result--500[data-v-1667a865] {
6845
6845
  --_color: var(--text-dim);
6846
6846
  }
6847
- .f-result__icon[data-v-c8f97d09] {
6847
+ .f-result__icon[data-v-1667a865] {
6848
6848
  display: flex;
6849
6849
  align-items: center;
6850
6850
  justify-content: center;
6851
6851
  margin-bottom: 24px;
6852
6852
  color: var(--_color);
6853
6853
  }
6854
- .f-result__code[data-v-c8f97d09] {
6854
+ .f-result__code[data-v-1667a865] {
6855
6855
  font-size: 56px;
6856
6856
  font-weight: 700;
6857
6857
  line-height: 1;
6858
6858
  letter-spacing: 2px;
6859
6859
  }
6860
- .f-result__title[data-v-c8f97d09] {
6860
+ .f-result__title[data-v-1667a865] {
6861
6861
  font-size: 20px;
6862
6862
  font-weight: 600;
6863
6863
  line-height: 1.4;
6864
6864
  color: var(--text);
6865
6865
  }
6866
- .f-result__subtitle[data-v-c8f97d09] {
6866
+ .f-result__subtitle[data-v-1667a865] {
6867
6867
  margin-top: 8px;
6868
6868
  font-size: 14px;
6869
6869
  line-height: 1.6;
6870
6870
  color: var(--text-muted);
6871
6871
  max-width: 480px;
6872
6872
  }
6873
- .f-result__extra[data-v-c8f97d09] {
6873
+ .f-result__extra[data-v-1667a865] {
6874
6874
  display: flex;
6875
6875
  gap: 12px;
6876
6876
  margin-top: 24px;
6877
6877
  }
6878
- .f-result__content[data-v-c8f97d09] {
6878
+ .f-result__content[data-v-1667a865] {
6879
6879
  margin-top: 24px;
6880
6880
  width: 100%;
6881
6881
  }.f-message[data-v-3aba692f] {