refactor: replace Toast with Sonner

This commit is contained in:
tao.chen
2026-09-02 10:10:41 +08:00
committed by tao.chen
parent 635d80e3cf
commit ed58344add
18 changed files with 126 additions and 320 deletions
@@ -42,7 +42,7 @@ const saveBtnClass =
// 模块级变量存储刷新版本号,用于检测只读内容刷新
let _lastRefreshVersion = 0;
type ToastState = {
type Notice = {
tone: "success" | "error" | "info";
message: string;
};
@@ -71,7 +71,7 @@ type ScriptWorkspaceProps = {
onSwitchTab: (scriptId: string) => void;
onNewTab: () => void;
onPublish: () => void;
onInfo: (toast: ToastState) => void;
onInfo: (toast: Notice) => void;
pythonEditorBuffers: Record<string, PythonEditorBuffer>;
onOpenPythonEditor: () => void;