Skip to content
This repository was archived by the owner on Mar 4, 2020. It is now read-only.

fix(Header): Adding dark and contrast styles for Header #427

Merged
merged 7 commits into from
Nov 12, 2018
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

### Fixes
- Fix endMedia to not be removed from DOM on mouseleave for `ListItem` @musingh1 ([#278](https://github.com/stardust-ui/react/pull/278))
- Added Dark and Contrast theme variables for `Header` @bcalvery ([#427](https://github.com/stardust-ui/react/pull/427))

### Features
- Make `Grid` keyboard navigable by implementing `gridBehavior` @sophieH29 ([#398](https://github.com/stardust-ui/react/pull/398))
Expand Down
1 change: 1 addition & 0 deletions src/themes/teams-dark/componentVariables.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
export { default as Button } from './components/Button/buttonVariables'
export { default as Text } from './components/Text/textVariables'
export { default as Divider } from './components/Divider/dividerVariables'
export { default as Header } from './components/Header/headerVariables'
9 changes: 9 additions & 0 deletions src/themes/teams-dark/components/Header/headerVariables.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { HeaderVariables } from '../../../teams/components/Header/headerVariables'
import { Partial } from 'types/utils'

export default (siteVars: any): Partial<HeaderVariables> => {
return {
color: siteVars.white,
descriptionColor: siteVars.gray02,
}
}
4 changes: 1 addition & 3 deletions src/themes/teams-high-contrast/componentVariables.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
export { default as Avatar } from './components/Avatar/avatarVariables'

export { default as Button } from './components/Button/buttonVariables'

export { default as Divider } from './components/Divider/dividerVariables'

export { default as Header } from './components/Header/headerVariables'
export { default as Text } from './components/Text/textVariables'
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { HeaderVariables } from '../../../teams/components/Header/headerVariables'
import { Partial } from 'types/utils'

export default (siteVars: any): Partial<HeaderVariables> => {
return {
color: siteVars.white,
descriptionColor: siteVars.white,
}
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export default siteVariables => ({
color: 'rgba(0,0,0,.6)',
color: siteVariables.gray04,
})
15 changes: 11 additions & 4 deletions src/themes/teams/components/Header/headerVariables.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
export default siteVariables => ({
color: 'black',
descriptionColor: undefined,
})
export interface HeaderVariables {
color: string
descriptionColor: string
}

export default (siteVars: any): HeaderVariables => {
return {
color: 'black',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be siteVars.black?

descriptionColor: undefined,
}
}