Skip to content
This repository was archived by the owner on Sep 14, 2022. It is now read-only.

Commit 43e7459

Browse files
committed
add split panel
1 parent 24d6aaa commit 43e7459

17 files changed

+570
-13
lines changed

package-lock.json

Lines changed: 163 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@
4747
"react": "^16.13.1",
4848
"react-bootstrap": "^1.3.0",
4949
"react-dom": "^16.13.1",
50+
"react-json-view": "^1.21.3",
51+
"recoil": "^0.3.1",
5052
"typescript": "4.1.2"
5153
},
5254
"devDependencies": {

src/App.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ import {
1717
BOOLEAN_ECMA_FEATURES,
1818
} from "@/constants";
1919
import { queryParamsState } from "@/shared/query-params-state";
20+
import {RecoilRoot} from 'recoil';
2021
import type { FC } from "react";
2122
import type { Linter } from "eslint";
2223
import type { ParserOptions, EcmaVersion } from "@typescript-eslint/types";
@@ -87,7 +88,7 @@ export const App: FC = () => {
8788
queryParamsState.set({ code, rules, parserOptions });
8889
}, [code, rules, parserOptions]);
8990
return (
90-
<>
91+
<RecoilRoot>
9192
<Header />
9293
<Container>
9394
<Row>
@@ -185,6 +186,6 @@ export const App: FC = () => {
185186
</Col>
186187
</Row>
187188
</Container>
188-
</>
189+
</RecoilRoot>
189190
);
190191
};

src/components/App/App.css

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
.app {
2+
display: flex;
3+
flex-direction: column;
4+
height: 100vh;
5+
max-height: 100vh;
6+
font-size: 13px;
7+
}
8+
9+
.top {
10+
width: 100%;
11+
}
12+
13+
.bottom {
14+
width: 100%;
15+
}
16+
17+
18+
.tab-content {
19+
height: calc(100% - 47px);
20+
}
21+
22+
.tab-pane {
23+
height: 100%;
24+
}
25+
26+
.rule-editor {
27+
height: 100%;
28+
}

0 commit comments

Comments
 (0)