@lvce-editor/renderer-process 30.82.2 → 30.82.4
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/dist/rendererProcessMain.js +20 -5
- package/package.json +1 -1
|
@@ -1989,8 +1989,14 @@ const dispose$p = async () => {
|
|
|
1989
1989
|
|
|
1990
1990
|
const initialize = () => {
|
|
1991
1991
|
try {
|
|
1992
|
-
const
|
|
1993
|
-
|
|
1992
|
+
const isChatRoute = /(?:^|\/)chat\/?$/.test(location.pathname);
|
|
1993
|
+
let savedLayout;
|
|
1994
|
+
try {
|
|
1995
|
+
savedLayout = JSON.parse(localStorage.getItem('Layout') || 'null');
|
|
1996
|
+
} catch {
|
|
1997
|
+
savedLayout = null;
|
|
1998
|
+
}
|
|
1999
|
+
if (savedLayout?.aiNativeLayout !== true && !isChatRoute) return;
|
|
1994
2000
|
let settings;
|
|
1995
2001
|
try {
|
|
1996
2002
|
settings = JSON.parse(localStorage.getItem('settings') || 'null');
|
|
@@ -11213,12 +11219,21 @@ const removeWorkspaceUri = () => {
|
|
|
11213
11219
|
const isChatPath = pathName => {
|
|
11214
11220
|
return /(?:^|\/)chat\/?$/.test(pathName);
|
|
11215
11221
|
};
|
|
11222
|
+
const isBoardPath = pathName => {
|
|
11223
|
+
return /(?:^|\/)board\/?$/.test(pathName);
|
|
11224
|
+
};
|
|
11225
|
+
const executeExtensionCommand = command => {
|
|
11226
|
+
send$1('ExtensionHost.executeCommand', command);
|
|
11227
|
+
};
|
|
11216
11228
|
const handlePopState = () => {
|
|
11217
11229
|
const pathName = getPathName();
|
|
11218
|
-
if (
|
|
11230
|
+
if (isBoardPath(pathName)) {
|
|
11231
|
+
executeExtensionCommand('chat2.showBoardLayout');
|
|
11232
|
+
} else if (isChatPath(pathName)) {
|
|
11219
11233
|
send$1('Layout.enterAiNativeLayout');
|
|
11220
|
-
|
|
11221
|
-
|
|
11234
|
+
executeExtensionCommand('chat2.show');
|
|
11235
|
+
} else if (isChatPath(state$3.lastPathName) || isBoardPath(state$3.lastPathName)) {
|
|
11236
|
+
executeExtensionCommand('chat2.showIdeLayout');
|
|
11222
11237
|
}
|
|
11223
11238
|
state$3.lastPathName = pathName;
|
|
11224
11239
|
};
|