Skip to content

Commit

Permalink
wip: continue to work on new styles
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason Silberman committed Jul 1, 2019
1 parent 40b4dc3 commit c8a77c7
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 14 deletions.
2 changes: 1 addition & 1 deletion packages/@best/api-db/src/sql/db.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export abstract class SQLDatabase {
abstract query(text: string, params: any[]): Promise<SQLQueryResult>

fetchProjects(): Promise<SQLQueryResult> {
return this.query('SELECT * FROM projects', [])
return this.query('SELECT * FROM projects ORDER BY created_at', [])
}

fetchSnapshots(projectId: number, since: Date | undefined): Promise<SQLQueryResult> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
text-align: left;
min-width: 200px;
margin: 0 20px;
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.control.open {
Expand Down
1 change: 1 addition & 0 deletions packages/@best/frontend/src/modules/my/app/app.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
display: grid;
grid-template-columns: 300px auto;
min-height: 100vh;
background: #dee9ee;
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
:host {
box-shadow: 0 0 5px rgba(0, 0, 0, 0.175);
z-index: 1;
margin: 20px 20px 0 0;
border-radius: 6px 6px 0 0;
background: #fff;
}

.benchmark-wrapper {
position: relative;
}
Expand Down
29 changes: 20 additions & 9 deletions packages/@best/frontend/src/modules/view/sidebar/sidebar.css
Original file line number Diff line number Diff line change
@@ -1,41 +1,52 @@
:host {
background: #000;
/* background: #def1fa; */
}

.brand a {
text-decoration: none;
}

.brand h1 {
font-size: 64px;
color: #ff00a8;
color: #2d353d;
font-weight: bold;
text-align: center;
/* text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.35); */
}

section {
margin-top: 55px;
color: #fff;
color: #2d353d;
}

h3 {
margin: 0;
margin-left: 24px;
margin-bottom: 8px;
font-weight: normal;
/* font-weight: normal; */
text-transform: uppercase;
}

.item {
background: #4a4a4a;
padding: 12px 24px;
/* background: #4a4a4a; */
padding: 8px 16px;
cursor: pointer;

margin: 8px;
border-radius: 4px;
font-size: 1.2rem;
}

.item:hover {
background: #555;
/* background: #555; */
}

.item.selected {
background: #00a3ff;
/* background: #00a3ff; */
color: rgb(20, 72, 167);
/* font-weight: bold; */
}

.item.selected:hover {
background: #39b8ff;
/* background: #39b8ff; */
}
4 changes: 2 additions & 2 deletions packages/@best/frontend/src/modules/view/sidebar/sidebar.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<template>
<header class="brand">
<h1>Best</h1>
<a href="/"><h1>BEST</h1></a>
</header>
<section class="projects">
<h3>Projects</h3>
<template for:each={projects} for:item="project">
<div onclick={selectProject} key={project.id} data-id={project.id} class={project.classes}>
<span>{project.name}</span>
<span data-id={project.id}>{project.name}</span>
</div>
</template>
</section>
Expand Down
2 changes: 0 additions & 2 deletions packages/@best/frontend/src/modules/view/sidebar/sidebar.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ export default class ViewSidebar extends LightningElement {
const project = this.projects.find(proj => proj.id === projectId);
if (project) {
store.dispatch(selectProject(project, true));
} else {
throw new Error(`sidebar couldn't select project`, this.projects, projectId, project);
}
}
}

0 comments on commit c8a77c7

Please sign in to comment.