Skip to content

Commit 3769ec8

Browse files
authored
refactor(flat-pages): update styles in room (netless-io#1766)
1 parent ada1a75 commit 3769ec8

File tree

20 files changed

+80
-49
lines changed

20 files changed

+80
-49
lines changed

.eslintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ dist/
44
public/
55
storybook-static/
66
.eslintrc.js
7+
*.json

cspell.config.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@ module.exports = {
9595
"pickone", // chance
9696
"viewports", // storybook
9797
"videojs", // @videojs/vhs-utils
98-
"telebox", // @netless/widnow-manager
98+
"tele", // @netless/widnow-manager
99+
"telebox",
99100
"Buildin", // @netless/widnow-manager
100101
"zindex", // antd
101102
"geogebra", // @netless/app-geogebra

desktop/renderer-app/src/tasks/init-ui.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ import { StoreProvider } from "@netless/flat-pages/src/components/StoreProvider"
1111
import { FlatServicesContextProvider } from "@netless/flat-pages/src/components/FlatServicesContext";
1212
import { ipcStore } from "../stores/ipc-store";
1313
import { IPCContext } from "../components/IPCContext";
14+
import { windowsBtnContext } from "../components/WindowsBtnContext";
15+
import { runtime } from "../utils/runtime";
1416

1517
/** configure right after import */
1618
import { configure } from "mobx";
17-
import { windowsBtnContext } from "../components/WindowsBtnContext";
1819
configure({
1920
isolateGlobalState: true,
2021
});
@@ -24,7 +25,7 @@ const App: React.FC = () => {
2425

2526
return (
2627
<AntdProvider lang={language}>
27-
<StoreProvider WindowsBtnContext={windowsBtnContext}>
28+
<StoreProvider WindowsBtnContext={windowsBtnContext} runtime={runtime}>
2829
<IPCContext.Provider value={ipcStore}>
2930
<FlatServicesContextProvider>
3031
<AppRoutes />

packages/flat-components/src/components/ChatPanel/style.less

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
}
1616

1717
.ant-tabs-tab.ant-tabs-tab-active .ant-tabs-tab-btn {
18-
color: var(--primary);
18+
color: var(--primary-strong);
1919
}
2020

2121
.ant-tabs-top > .ant-tabs-nav::before {
@@ -45,20 +45,11 @@
4545

4646
.flat-color-scheme-dark {
4747
.chat-panel {
48-
.ant-tabs-tab.ant-tabs-tab-active .ant-tabs-tab-btn {
49-
color: var(--grey-0);
50-
}
5148
.ant-tabs-ink-bar {
52-
background: var(--grey-0);
49+
background: var(--primary-strong);
5350
}
5451
.ant-tabs-top > .ant-tabs-nav::before {
5552
border-bottom-color: var(--grey-8);
5653
}
57-
.ant-tabs-tab:hover {
58-
color: var(--grey-4);
59-
}
60-
.ant-tabs-tab-btn:focus {
61-
color: var(--grey-0);
62-
}
6354
}
6455
}

packages/flat-components/src/components/ClassroomPage/TopBar/TopBarRightBtn/style.less

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@
3131

3232
.flat-color-scheme-dark {
3333
.topbar-right-btn {
34-
background-color: var(--grey-10);
34+
background-color: transparent;
3535

3636
&:hover {
37-
background-color: var(--grey-11);
37+
background-color: var(--grey-7);
3838
}
3939

4040
&:active {

packages/flat-components/src/components/ClassroomPage/TopBar/style.less

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
padding: 0 8px;
2020
font-size: 16px;
2121
user-select: none;
22+
2223
&.isMac {
2324
border-top: none;
2425
}
@@ -48,6 +49,7 @@
4849
.flat-color-scheme-dark {
4950
.topbar-box {
5051
border-color: var(--grey-8);
52+
background: linear-gradient(270deg, #383B42 0%, #2B2F38 100%);
5153
}
5254

5355
.topbar-divider,

packages/flat-pages/src/BigClassPage/BigClassPage.less

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@
5858
.big-class-realtime-container,
5959
.big-class-realtime-box {
6060
color: var(--text);
61-
background-color: var(--grey-10);
61+
background-color: var(--grey-9);
6262
}
6363

6464
.big-class-realtime-box .topbar-box {

packages/flat-pages/src/BigClassPage/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ import { useLoginCheck } from "../utils/use-login-check";
3535
import { withClassroomStore, WithClassroomStoreProps } from "../utils/with-classroom-store";
3636
import { WindowsSystemBtnContext } from "../components/StoreProvider";
3737
import { ShareScreenPicker } from "../components/ShareScreen/ShareScreenPicker";
38+
import { ExtraPadding } from "../components/ExtraPadding";
3839

3940
export type BigClassPageProps = {};
4041

@@ -103,6 +104,7 @@ export const BigClassPage = withClassroomStore<BigClassPageProps>(
103104
function renderTopBarLeft(): React.ReactNode {
104105
return (
105106
<>
107+
<ExtraPadding />
106108
<NetworkStatus networkQuality={classroomStore.networkQuality} />
107109
{classroomStore.isCreator ? (
108110
classroomStore.roomInfo?.beginTime && (

packages/flat-pages/src/OneToOnePage/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ import { useLoginCheck } from "../utils/use-login-check";
3535
import { withClassroomStore, WithClassroomStoreProps } from "../utils/with-classroom-store";
3636
import { WindowsSystemBtnContext } from "../components/StoreProvider";
3737
import { ShareScreenPicker } from "../components/ShareScreen/ShareScreenPicker";
38+
import { ExtraPadding } from "../components/ExtraPadding";
3839

3940
export type OneToOnePageProps = {};
4041

@@ -97,6 +98,7 @@ export const OneToOnePage = withClassroomStore<OneToOnePageProps>(
9798
function renderTopBarLeft(): React.ReactNode {
9899
return (
99100
<>
101+
<ExtraPadding />
100102
<NetworkStatus networkQuality={classroomStore.networkQuality} />
101103
{classroomStore.isCreator ? (
102104
classroomStore.roomInfo?.beginTime && (

packages/flat-pages/src/SmallClassPage/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ import { useLoginCheck } from "../utils/use-login-check";
3737
import { withClassroomStore, WithClassroomStoreProps } from "../utils/with-classroom-store";
3838
import { WindowsSystemBtnContext } from "../components/StoreProvider";
3939
import { ShareScreenPicker } from "../components/ShareScreen/ShareScreenPicker";
40+
import { ExtraPadding } from "../components/ExtraPadding";
4041

4142
export type SmallClassPageProps = {};
4243

@@ -134,6 +135,7 @@ export const SmallClassPage = withClassroomStore<SmallClassPageProps>(
134135
function renderTopBarLeft(): React.ReactNode {
135136
return (
136137
<>
138+
<ExtraPadding />
137139
<NetworkStatus networkQuality={classroomStore.networkQuality} />
138140
{classroomStore.isCreator ? (
139141
classroomStore.roomInfo?.beginTime && (

0 commit comments

Comments
 (0)