Skip to content

Commit e0e0268

Browse files
committed
[dashboard] v2 initial commit
1 parent 1927f7d commit e0e0268

File tree

215 files changed

+200093
-17049
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

215 files changed

+200093
-17049
lines changed

components/dashboard/.gitignore

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
# See https://help.github.com/ignore-files/ for more about ignoring files.
1+
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
22

33
# dependencies
44
/node_modules
5+
/.pnp
6+
.pnp.js
57

68
# testing
79
/coverage
@@ -19,9 +21,3 @@
1921
npm-debug.log*
2022
yarn-debug.log*
2123
yarn-error.log*
22-
23-
lib
24-
dist
25-
26-
/public/libs/*
27-
!/public/libs/.keep

components/dashboard/BUILD.yaml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ packages:
22
- name: app
33
type: yarn
44
srcs:
5-
- "public/images/**"
5+
- "public/**"
66
- "src/**/*.ts"
77
- "src/**/*.tsx"
88
- "src/**/*.css"
@@ -11,9 +11,7 @@ packages:
1111
- "ee/src/**/*.css"
1212
- "typings/**"
1313
- package.json
14-
- postinstall.js
15-
- webpack.config.js
16-
- webpack.entrypoints.js
14+
- tailwind.config.js
1715
- tsconfig.json
1816
deps:
1917
- components/gitpod-protocol:lib

components/dashboard/README.md

Lines changed: 27 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,31 @@
1-
# Gitpod Workspaces
1+
# Dashboard Redesign POC
22

3-
The workspaces page provides a UI for the gitpod server.
3+
The dashboard is written in TypeScript and React. For styling it uses TailwindCSS which is a bit nicer than inlining CSS as it supports pseudo classes and a is a little more abstract/reusable.
44

5-
## How to use
5+
The App.tsx is the entry point for the SPA and it uses React-Router to register all pages.
66

7-
Install it and run:
7+
```ts
8+
<Switch>
9+
<Route path="/" exact component={Workspaces} />
10+
<Route path="/profile" exact component={Profile} />
11+
<Route path="/notifications" exact component={Notifications} />
12+
<Route path="/subscriptions" exact component={Subscriptions} />
13+
<Route path="/env-vars" exact component={EnvVars} />
14+
<Route path="/git-integration" exact component={GitIntegration} />
15+
<Route path="/feature-preview" exact component={FeaturePreview} />
16+
<Route path="/default-ide" exact component={DefaultIDE} />
17+
</Switch>
18+
```
19+
Pages are loaded lazily using `React.lazy` so that not everything needs to be loaded up-front but only when needed:
820

9-
```bash
10-
yarn install
11-
yarn start
12-
```
21+
```ts
22+
const Notifications = React.lazy(() => import('./account/Notifications'));
23+
const Profile = React.lazy(() => import('./account/Profile'));
24+
const Subscriptions = React.lazy(() => import('./account/Subscriptions'));
25+
const DefaultIDE = React.lazy(() => import('./settings/DefaultIDE'));
26+
const EnvVars = React.lazy(() => import('./settings/EnvVars'));
27+
const FeaturePreview = React.lazy(() => import('./settings/FeaturePreview'));
28+
const GitIntegration = React.lazy(() => import('./settings/GitIntegration'));
29+
```
30+
31+
Global state is passed through `React.Context`.

components/dashboard/ee/public/admin/index.html

Lines changed: 0 additions & 34 deletions
This file was deleted.

components/dashboard/ee/public/license/index.html

Lines changed: 0 additions & 34 deletions
This file was deleted.

components/dashboard/ee/src/admin.tsx

Lines changed: 0 additions & 64 deletions
This file was deleted.

components/dashboard/ee/src/components/admin/datatable.tsx

Lines changed: 0 additions & 162 deletions
This file was deleted.

0 commit comments

Comments
 (0)