-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: support configure inline diff style (#122)
- Loading branch information
Showing
14 changed files
with
513 additions
and
448 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,28 @@ | ||
import { AINativeServerModule, IAppOpts, RuntimeConfig } from '@codeblitzjs/ide-sumi-core'; | ||
import { AINativeModule } from '@opensumi/ide-ai-native/lib/browser'; | ||
import { DesignModule } from '@opensumi/ide-design/lib/browser'; | ||
|
||
export function interceptAppOpts(opts: IAppOpts, runtimeConfig: RuntimeConfig) { | ||
const { modules } = opts; | ||
|
||
const newModules = [...modules]; | ||
|
||
if (runtimeConfig.aiNative?.enable) { | ||
if (modules.indexOf(AINativeModule) === -1) { | ||
modules.push(AINativeModule); | ||
modules.push(AINativeServerModule); | ||
newModules.push(AINativeModule); | ||
newModules.push(AINativeServerModule); | ||
} | ||
} | ||
|
||
if (opts.useLegacyDesign) { | ||
// remove design module | ||
const index = newModules.indexOf(DesignModule); | ||
if (index > -1) { | ||
newModules.splice(index, 1); | ||
} | ||
} | ||
|
||
opts.modules = newModules; | ||
|
||
return opts; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
/** | ||
* @deprecated `@opensumi/common-di` is renamed to `@opensumi/di` | ||
*/ | ||
|
||
export * from '@opensumi/di'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from '@opensumi/di'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"__OPENSUMI_VERSION__": "3.2.2-next-1722848438.0", | ||
"__WORKER_HOST__": "https://gw.alipayobjects.com/os/cloud-ide/codeblitz/worker-host.b874db95.js", | ||
"__OPENSUMI_VERSION__": "3.2.4-next-1723531705.0", | ||
"__WORKER_HOST__": "https://gw.alipayobjects.com/os/cloud-ide/codeblitz/worker-host.f5e00765.js", | ||
"__WEBVIEW_ENDPOINT__": "https://gw.alipayobjects.com/os/cloud-ide/codeblitz/webview.805ab470", | ||
"__WEBVIEW_SCRIPT__": "https://gw.alipayobjects.com/os/cloud-ide/codeblitz/webview.66e57793.js" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.