ISSUE-001 - Playing around quite a bit. Not sure I've figured out a method of constructing the tool page I'm happy with here. Want to take a different path and see what I can do.

This commit is contained in:
Kyle Geib committed 2021-12-20 15:45:53 -05:00
1 parent c6f5899510
commit c3b268da61
22 files changed
+412 -33

No files matched your search

@@ -0,0 +1,58 @@
import { Stack } from "@bedrock-layout/stack";
import { Column, Columns } from "@bedrock-layout/columns";
import { MockupBlock } from "../../Common/MockupBlock.styled";
import { ExpandedStack, ExpandedBlock } from "./styles";
type LayoutProps = {
headerHeight?: number,
};
export function Layout({ headerHeight }: LayoutProps) {
const headerOffset = headerHeight ? headerHeight + 5 : 0;
return (
<Stack gutter="none">
<Columns gutter="none" columns={7} dense>
<MockupBlock
color="#f7aeae"
minWidth="200px"
minHeight={`calc(65vh - ${headerOffset}px)`}
>Timing Board UI</MockupBlock>
<Column span={6}>
<MockupBlock
color="#c5c5c5"
minHeight="100%"
>Video Feed</MockupBlock>
</Column>
</Columns>
<Columns gutter="none" columns={7} dense>
<Column span={1}>
<ExpandedStack>
<ExpandedBlock>
<MockupBlock
color="#5576e2"
minWidth="200px"
minHeight="200px"
height="20vh"
>Race Status UI</MockupBlock>
</ExpandedBlock>
<ExpandedBlock>
<MockupBlock
color="#bc62ce"
minHeight="40px"
height="15vh"
>Race Director UI</MockupBlock>
</ExpandedBlock>
</ExpandedStack>
</Column>
<Column span={6}>
<MockupBlock
color="#4d828b"
minHeight="35vh"
>Broadcast Director UI</MockupBlock>
</Column>
</Columns>
</Stack>
);
}
+1
View File
@@ -0,0 +1 @@
export * from "./Layout";
+14
View File
@@ -0,0 +1,14 @@
import styled from "styled-components";
export const ExpandedStack = styled.div`
display: flex;
flex-flow: column;
/* height: 100%; */
`;
export const ExpandedBlock = styled.div`
/* flex: 1 1 auto; */
flex-grow: 1;
/* flex-shrink: 1;
flex-basis: auto; */
`;
@@ -0,0 +1,19 @@
import styled from "styled-components";
type MockupBlockProps = {
color: string,
height?: string,
width?: string,
minWidth?: string,
minHeight?: string,
};
export const MockupBlock = styled.div<MockupBlockProps>`
display: flex;
min-height: ${({ minHeight }) => minHeight ?? "0"};
min-width: ${({ minWidth }) => minWidth ?? "0"};
height: ${({ height }) => height ?? "100%"};
width: ${({ width }) => width ?? "100%"};
background-color: ${({ color }) => color};
flex: 1 1 auto;
`;
+7
View File
@@ -0,0 +1,7 @@
import styled from "styled-components";
export const Nav = styled.nav`
border-bottom: solid 1px;
padding-bottom: 1rem;
padding-left: 1rem;
`;
@@ -0,0 +1,16 @@
import React from "react";
import { Container } from "./styles";
type RouteHeaderProps = {
title: string,
};
export const RouteHeader = React.forwardRef<HTMLHeadElement, RouteHeaderProps>(
(props, ref) => (
<Container ref={ref}>
{props.title}
</Container>
),
);
RouteHeader.displayName = "RouteHeader"; // Required due to forwardRef().
@@ -0,0 +1 @@
export * from "./RouteHeader";
@@ -0,0 +1,11 @@
import styled from "styled-components";
export const Container = styled.header`
top: 0;
left: 0;
right: 0;
z-index: 5;
padding: 0;
background-color: ${p => p.theme.colors.grey};
height: 20px;
`;