replace ElMessage with Sonner

This commit is contained in:
pa
2026-01-07 19:16:31 +09:00
committed by Natsumi
parent f819a3f500
commit 7e4de15ef2
85 changed files with 574 additions and 1144 deletions
+4 -7
View File
@@ -1,6 +1,7 @@
import { computed, reactive, ref, watch } from 'vue';
import { ElMessage, ElNotification } from 'element-plus';
import { ElNotification } from 'element-plus';
import { defineStore } from 'pinia';
import { toast } from 'vue-sonner';
import { useI18n } from 'vue-i18n';
import { useFriendStore } from './friend';
@@ -38,12 +39,8 @@ export const useChartsStore = defineStore('Charts', () => {
const friendCount = computed(() => friendStore.friends.size || 0);
function showInfoMessage(message, type) {
ElMessage({
message,
type,
duration: 4000,
grouping: true
});
const toastFn = toast[type] ?? toast;
toastFn(message, { duration: 4000 });
}
watch(