|
1 | 1 | import { makeStyles } from "@material-ui/core/styles"
|
2 | 2 | import { FC } from "react"
|
3 | 3 | import * as TypesGen from "../../api/typesGenerated"
|
4 |
| -import { MONOSPACE_FONT_FAMILY } from "../../theme/constants" |
5 | 4 | import { BuildsTable } from "../BuildsTable/BuildsTable"
|
6 | 5 | import { Margins } from "../Margins/Margins"
|
7 | 6 | import { PageHeader, PageHeaderSubtitle, PageHeaderTitle } from "../PageHeader/PageHeader"
|
@@ -49,6 +48,7 @@ export const Workspace: FC<WorkspaceProps> = ({
|
49 | 48 | return (
|
50 | 49 | <Margins>
|
51 | 50 | <PageHeader
|
| 51 | + className={styles.header} |
52 | 52 | actions={
|
53 | 53 | <WorkspaceActions
|
54 | 54 | workspace={workspace}
|
@@ -89,29 +89,19 @@ export const Workspace: FC<WorkspaceProps> = ({
|
89 | 89 | )
|
90 | 90 | }
|
91 | 91 |
|
| 92 | +const spacerWidth = 300 |
| 93 | + |
92 | 94 | export const useStyles = makeStyles((theme) => {
|
93 | 95 | return {
|
94 | 96 | firstColumnSpacer: {
|
95 | 97 | flex: 2,
|
96 | 98 | },
|
97 | 99 | secondColumnSpacer: {
|
98 |
| - flex: "0 0 300px", |
| 100 | + flex: `0 0 ${spacerWidth}px`, |
99 | 101 | },
|
100 | 102 | header: {
|
101 |
| - paddingTop: theme.spacing(5), |
102 |
| - paddingBottom: theme.spacing(5), |
103 |
| - fontFamily: MONOSPACE_FONT_FAMILY, |
104 |
| - display: "flex", |
105 |
| - alignItems: "center", |
106 |
| - justifyContent: "space-between", |
107 |
| - }, |
108 |
| - title: { |
109 |
| - fontWeight: 600, |
110 |
| - fontFamily: "inherit", |
111 |
| - }, |
112 |
| - subtitle: { |
113 |
| - fontFamily: "inherit", |
114 |
| - marginTop: theme.spacing(0.5), |
| 103 | + // 100% - (the size of sidebar + the space between both ) |
| 104 | + maxWidth: `calc(100% - (${spacerWidth}px + ${theme.spacing(3)}px))`, |
115 | 105 | },
|
116 | 106 | layout: {
|
117 | 107 | alignItems: "flex-start",
|
|
0 commit comments