feat(ui): 添加全局Snackbar组件并替换局部实现
将原本分散在各组件的Snackbar功能统一为全局组件,通过Pinia store管理状态 移除CreateTemplateScreen中的局部Snackbar实现,改用全局组件 添加Snackbar store提供多种消息类型方法(success/error/warning/info)
This commit is contained in:
1 parent
55a85e7111
commit
ae20a30616
5 files changed
+191
-35
No files matched your search
@@ -2,6 +2,7 @@
|
||||
import { DefaultLayout } from '@/renderer/components/layout'
|
||||
import GlobalDialog from '@/renderer/components/GlobalDialog.vue'
|
||||
import UpdateDialog from '@/renderer/components/UpdateDialog.vue'
|
||||
import GlobalSnackbar from '@/renderer/components/GlobalSnackbar.vue'
|
||||
import { onMounted } from 'vue'
|
||||
import { useAppStore } from '@/renderer/store/app'
|
||||
|
||||
@@ -75,6 +76,7 @@ const checkForUpdates = async () => {
|
||||
</DefaultLayout>
|
||||
<GlobalDialog />
|
||||
<UpdateDialog />
|
||||
<GlobalSnackbar />
|
||||
</template>
|
||||
|
||||
<style>
|
||||
|
||||
Reference in new issue
Block a user