Skip to content

Commit

Permalink
polishing: Add consistent background colors matching ethereum.org
Browse files Browse the repository at this point in the history
  • Loading branch information
mohamedmansour committed Jul 24, 2021
1 parent acb24a8 commit cecfb20
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 12 deletions.
3 changes: 3 additions & 0 deletions frontend/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@
*:focus {
box-shadow: none !important;
}
#root {
background: inherit
}
</style>
</style>
</head>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/organisms/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export function Note() {
}

return (
<Alert status="info" onClick={hideNote}>
<Alert status="info" onClick={hideNote} mt={4}>
<AlertIcon />
This crawler only has a partial view of the Ethereum network. This is not a full count of every node on the network.
<Spacer /><Button variant="ghost" iconSpacing={0} size="sm" leftIcon={<VscClose />} title="Remove note" />
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/organisms/Loader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ interface LoaderProps {

export function Loader(props: LoaderProps) {
return (
<Center position="fixed" top={0} left={0} right={0} bottom={0} color="brand.primaryText">
<Center position="fixed" top={0} left={0} right={0} bottom={0} color="brand.primaryText" bg="inherit">
<VStack>
<Logo width={100} height={100}/>
<Text>{props.children}</Text>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/pages/Home.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ function Home() {
}, [history, location])

if (!data) {
return <Loader>Processing data</Loader>
return <Loader>Loading data...</Loader>
}

const renderLabelContent: React.FunctionComponent = (props: any) => {
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/pages/London.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ export function London() {
}, [])

if (!data) {
return <Loader>Processing data</Loader>
return <Loader>Loading data...</Loader>
}

const renderLabelContent = (props: any): any => {
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/templates/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ interface LayoutProps {

export function Layout(props: LayoutProps) {
return (
<VStack minH="100vh" align="flex-start" justify="flex-start">
<VStack minH="100vh" align="flex-start" justify="flex-start" bg="inherit">
<Header />
<VStack spacing={LayoutEightPadding} pl={LayoutEightPadding} pr={LayoutEightPadding} pb={LayoutEightPadding} width="100%">
<VStack spacing={LayoutEightPadding} pl={LayoutEightPadding} pr={LayoutEightPadding} pb={LayoutEightPadding} width="100%" bg="inherit">
{props.children}
</VStack>
<Footer />
Expand Down
14 changes: 8 additions & 6 deletions frontend/src/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@ import { extendTheme } from "@chakra-ui/react"


export const theme = extendTheme({
global: (props: any) => ({
body: {
bg: mode('gray-800', 'blue')(props),
color: mode('gray.100', '#141214')(props)
}
})
styles: {
global: (props: any) => ({
body: {
bg: mode('white', 'rgb(34, 34, 34)')(props),
color: mode('rgb(51, 51, 51)', 'rgb(242, 242, 242)')(props)
}
})
}
});

0 comments on commit cecfb20

Please sign in to comment.