Skip to content

Commit

Permalink
Merge pull request #80 from cloudcity/tetra/about-page-styling
Browse files Browse the repository at this point in the history
updated about page styles
  • Loading branch information
adccb committed Nov 29, 2018
2 parents b9b34f1 + 82bc8cb commit 67841a9
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/components/About/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ div.about-container {
position: absolute;
z-index: 100000;
background-color: white;
top: 0;
top: 60px;
left: 0;
height: 100vh;
height: calc(100vh - 60px);
width: 100vw;
display: flex;
justify-content: center;
Expand Down
1 change: 1 addition & 0 deletions src/components/App/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@ class App_ extends React.Component<AppProps, AppState> {
focusPerson: subjectId => this.focusPerson(subjectId),
goHome: () => this.props.goHome(),
toggleAbout: () => this.props.toggleAboutPage(),
showAboutPage: this.props.showAboutPage,
submitSearch: name => this.submitSearch(name),
searchString: this.props.searchString,
})
Expand Down
10 changes: 9 additions & 1 deletion src/components/Navbar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ type NavbarProps = {
goHome: () => void,
toggleAbout: () => void,
submitSearch: string => void,
showAboutPage: boolean,
}

class Navbar extends React.Component<NavbarProps, NavbarState> {
Expand All @@ -31,9 +32,16 @@ class Navbar extends React.Component<NavbarProps, NavbarState> {
goHome,
submitSearch,
toggleAbout,
showAboutPage,
} = this.props

const about = React.createElement('a', { onClick: toggleAbout }, 'About')
const about = React.createElement(
'a',
showAboutPage
? { className: 'shown', onClick: () => null }
: { onClick: toggleAbout },
'About',
)
const logo = React.createElement(
'div',
{ onClick: goHome },
Expand Down
21 changes: 17 additions & 4 deletions src/components/Navbar/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,16 @@ nav {
color: white;
}

nav > * { flex: 1; }
nav > div { display: flex; align-items: center; }
nav > div h1 { cursor: pointer; }
nav > * {
flex: 1;
}
nav > div {
display: flex;
align-items: center;
}
nav > div h1 {
cursor: pointer;
}

nav img {
height: 40px;
Expand All @@ -35,5 +42,11 @@ nav a {
cursor: pointer;
}

nav div.right { display: flex; justify-content: flex-end; }
nav div.right {
display: flex;
justify-content: flex-end;
}

nav a.shown {
color: rgba(180, 200, 255, 0.35);
}

0 comments on commit 67841a9

Please sign in to comment.