From 9fb9883562503faa82a142ade8efaa7e535ea970 Mon Sep 17 00:00:00 2001 From: scarqin <1054139596@qq.com> Date: Mon, 9 May 2022 18:57:22 +0800 Subject: [PATCH] stash iframe --- src/app/electron-main/main.ts | 1 + src/core/market/browser/package.json | 4 ++-- src/core/market/browser/src/main.js | 2 +- src/workbench/browser/src/app/pages/pages.component.html | 1 + .../src/app/shared/components/sidebar/sidebar.component.ts | 2 +- 5 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/app/electron-main/main.ts b/src/app/electron-main/main.ts index d8d2bccbb..a81575328 100644 --- a/src/app/electron-main/main.ts +++ b/src/app/electron-main/main.ts @@ -43,6 +43,7 @@ function createWindow(): BrowserWindow { contextIsolation: false, // false if you want to run e2e test with Spectron }, }); + // main if (['serve'].includes(processEnv)) { require('electron-reload')(__dirname, { electron: require(path.join(__dirname, '../node_modules/electron')), diff --git a/src/core/market/browser/package.json b/src/core/market/browser/package.json index a4874ae30..73454d528 100644 --- a/src/core/market/browser/package.json +++ b/src/core/market/browser/package.json @@ -10,7 +10,7 @@ "logo": "icon-apps", "main_debug": "http://localhost:8080", "moduleID": "default", - "moduleName": "插件广场", + "moduleName": "拓展广场", "moduleType": "app", "features": { "export": { @@ -21,7 +21,7 @@ "extension": "json" }, "configuration": { - "title": "插件广场配置", + "title": "拓展广场配置", "properties": { "core.market.url": { "type": "string", diff --git a/src/core/market/browser/src/main.js b/src/core/market/browser/src/main.js index ac1417c4f..19ec93cc7 100644 --- a/src/core/market/browser/src/main.js +++ b/src/core/market/browser/src/main.js @@ -5,5 +5,5 @@ import App from './App.vue'; import router from './router.js'; import 'windi.css'; import { createPinia } from 'pinia'; - +window.eo=window.parent.eo; createApp(App).use(router).use(Antd).use(createPinia()).mount('#app'); diff --git a/src/workbench/browser/src/app/pages/pages.component.html b/src/workbench/browser/src/app/pages/pages.component.html index 6e45ffde8..4950febfc 100644 --- a/src/workbench/browser/src/app/pages/pages.component.html +++ b/src/workbench/browser/src/app/pages/pages.component.html @@ -1,6 +1,7 @@ <eo-navbar></eo-navbar> <div class="home_container f_row"> <eo-sidebar></eo-sidebar> + <iframe src="http://localhost:8080" style="width: 100vw;"></iframe> <div class="home fg1"> <router-outlet></router-outlet> </div> diff --git a/src/workbench/browser/src/app/shared/components/sidebar/sidebar.component.ts b/src/workbench/browser/src/app/shared/components/sidebar/sidebar.component.ts index a11dedcaa..479235f65 100644 --- a/src/workbench/browser/src/app/shared/components/sidebar/sidebar.component.ts +++ b/src/workbench/browser/src/app/shared/components/sidebar/sidebar.component.ts @@ -69,7 +69,7 @@ export class SidebarComponent implements OnInit, OnDestroy { ]; if (!this.electron.isElectron) { defaultModule.push({ - moduleName: '插件广场', + moduleName: '拓展广场', moduleID: '@eo-core-extension', logo: 'icon-apps', activeRoute: 'home/preview',