From 21b38cdb11a84ce7bf9848eda2bcb2b9a28d92fe Mon Sep 17 00:00:00 2001 From: yugasun Date: Wed, 18 Oct 2023 16:29:59 +0800 Subject: [PATCH] fix: subapp4 dev port --- packages/main/src/assets/styles/index.scss | 22 ++++++++++++++- packages/subapp2/src/index.css | 32 ---------------------- packages/subapp3/src/app.css | 32 ---------------------- packages/subapp4/vite.config.ts | 4 +-- 4 files changed, 23 insertions(+), 67 deletions(-) diff --git a/packages/main/src/assets/styles/index.scss b/packages/main/src/assets/styles/index.scss index 131bfdf..57da77b 100644 --- a/packages/main/src/assets/styles/index.scss +++ b/packages/main/src/assets/styles/index.scss @@ -20,7 +20,6 @@ button { font-size: 1em; font-weight: 500; font-family: inherit; - background-color: #1a1a1a; cursor: pointer; transition: border-color 0.25s; } @@ -34,6 +33,27 @@ button:focus-visible { outline: 4px auto -webkit-focus-ring-color; } +@media (prefers-color-scheme: light) { + :root { + color: #213547; + background-color: #fff; + } + + a:hover { + color: #747bff; + } + + button { + background-color: #f9f9f9; + } +} + +html.dark { + button { + background-color: #1a1a1a; + } +} + .card { padding: 2em; } diff --git a/packages/subapp2/src/index.css b/packages/subapp2/src/index.css index c677efa..78a56ae 100644 --- a/packages/subapp2/src/index.css +++ b/packages/subapp2/src/index.css @@ -2,35 +2,3 @@ h1 { font-size: 3.2em; line-height: 1.1; } - -button { - border-radius: 8px; - border: 1px solid transparent; - padding: 0.6em 1.2em; - font-size: 1em; - font-weight: 500; - font-family: inherit; - background-color: #1a1a1a; - cursor: pointer; - transition: border-color 0.25s; -} -button:hover { - border-color: #646cff; -} -button:focus, -button:focus-visible { - outline: 4px auto -webkit-focus-ring-color; -} - -@media (prefers-color-scheme: light) { - :root { - color: #213547; - background-color: #ffffff; - } - a:hover { - color: #747bff; - } - button { - background-color: #f9f9f9; - } -} diff --git a/packages/subapp3/src/app.css b/packages/subapp3/src/app.css index bd416c0..0485899 100644 --- a/packages/subapp3/src/app.css +++ b/packages/subapp3/src/app.css @@ -13,35 +13,3 @@ h1 { padding: 2rem; text-align: center; } - -button { - border-radius: 8px; - border: 1px solid transparent; - padding: 0.6em 1.2em; - font-size: 1em; - font-weight: 500; - font-family: inherit; - background-color: #1a1a1a; - cursor: pointer; - transition: border-color 0.25s; -} -button:hover { - border-color: #646cff; -} -button:focus, -button:focus-visible { - outline: 4px auto -webkit-focus-ring-color; -} - -@media (prefers-color-scheme: light) { - :root { - color: #213547; - background-color: #ffffff; - } - a:hover { - color: #747bff; - } - button { - background-color: #f9f9f9; - } -} diff --git a/packages/subapp4/vite.config.ts b/packages/subapp4/vite.config.ts index b9f6d55..3a5c373 100644 --- a/packages/subapp4/vite.config.ts +++ b/packages/subapp4/vite.config.ts @@ -5,9 +5,9 @@ import MicroVitePlugin from '@micro-fe/vite-plugin'; // TODO: change to real deploy domain const DEPLOY_URL = 'http://localhost:8004'; -const VITE_APP_NAME = 'subapp1'; +const VITE_APP_NAME = 'subapp4'; const DEV_HOST = 'localhost'; -const DEV_PORT = 8001; +const DEV_PORT = 8004; const isProd = process.env.NODE_ENV === 'production'; const isMicro = process.env.VITE_MICRO_MODE === 'true';