Skip to content

Commit

Permalink
feat(server): empty project dashboard design
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickhulce committed Nov 9, 2019
1 parent 4559ea0 commit 4d268a7
Show file tree
Hide file tree
Showing 5 changed files with 56 additions and 7 deletions.
2 changes: 1 addition & 1 deletion packages/server/src/ui/components/dropdown.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const Dropdown = props => {
</select>
</label>
<div className="dropdown__chevron">
<i className="material-icons">keyboard_arrow_down</i>
<i className="material-icons">arrow_drop_down</i>
</div>
</div>
);
Expand Down
5 changes: 1 addition & 4 deletions packages/server/src/ui/layout/page-sidebar.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@
height: var(--page-header-height);
width: 100%;
padding: var(--page-header-vertical-padding) var(--page-header-horizontal-padding);

border-bottom: 1px solid var(--inverted-border-color);

display: flex;
flex-direction: row;
align-items: center;
Expand All @@ -49,7 +46,7 @@
}

.page-sidebar__content {
padding: var(--page-header-vertical-padding) var(--page-header-horizontal-padding);
padding: 0 var(--page-header-horizontal-padding);
}

.page-sidebar__content ul {
Expand Down
1 change: 0 additions & 1 deletion packages/server/src/ui/layout/page-sidebar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ export const PageSidebar = props => {
>
<div className="page-sidebar__header" onClick={() => props.setIsOpen(false)}>
<div className="page-sidebar__logo" />
Lighthouse CI
</div>
<div className="page-sidebar__content">
<AsyncLoader
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
/**
* @license Copyright 2019 Google Inc. All Rights Reserved.
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
*/

.getting-started {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;

min-height: 70vh;

text-align: center;
}

.getting-started .paper {
max-width: 50vw;
padding: calc(var(--base-spacing) * 2);
}

.getting-started pre {
display: inline;
}

.getting-started img {
width: 80px;
margin-bottom: calc(var(--base-spacing) * 2);
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,33 @@
*/

import {h} from 'preact';
import {Paper} from '../../components/paper';
import './getting-started.css';

// @ts-ignore - tsc doesn't get parcel :)
const LH_LOGO_PATH = require('../../logo.svg');

/**
* @param {{project: LHCI.ServerCommand.Project}} props
*/
export const ProjectGettingStarted = props => {
return <h2>No build data yet for {props.project.name}!</h2>;
return (
<div className="getting-started">
<Paper>
<img src={LH_LOGO_PATH} />
<h2>
No build data yet for {props.project.name}! Add the <pre>@lhci/cli</pre> package to your
continuous integration to{' '}
<a
href="https://github.com/GoogleChrome/lighthouse-ci/blob/master/docs/getting-started.md"
target="_blank"
rel="noopener noreferrer"
>
get started
</a>
.
</h2>
</Paper>
</div>
);
};

0 comments on commit 4d268a7

Please sign in to comment.