This repository was archived by the owner on Mar 4, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 53
fix(attachment): themeing and redline #1033
Merged
Merged
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
4bb66d2
updates to Attachment Styles
bcalvery 643dda3
Merge branch 'master' of https://github.com/stardust-ui/react into fi…
bcalvery 8beceff
more refinement to attachment
bcalvery 987d284
Merge branch 'master' of https://github.com/stardust-ui/react into fi…
bcalvery 5facf85
making action icon color match text color
bcalvery 9136c24
updating Changelog entry for PR
bcalvery 1b97474
merge from master
bcalvery 633ccc3
fix file capitalization issue
bcalvery c27fcf8
fix accident put changelog entry in wrong place
bcalvery c2d06e2
merge in lastest
3030fa6
updating attachment styles
abb0bf2
Merge branch 'master' into fix/attachment-themeing
1e2e448
updating icon in the attachment examples and making it show filled st…
2fe565b
Merge branch 'master' into fix/attachment-themeing
5f8026b
updating color for attachment dark theme border and backgroundColor
2f7b696
Merge branch 'master' into fix/attachment-themeing
58cc768
updating changelog
facd76e
Merge branch 'master' into fix/attachment-themeing
codepretty File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
packages/react/src/themes/teams-dark/components/Attachment/attachmentVariables.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { AttachmentVariables } from '../../../teams/components/Attachment/attachmentVariables' | ||
|
||
export default (siteVariables: any): Partial<AttachmentVariables> => ({ | ||
textColor: siteVariables.colors.grey[50], | ||
textColorHover: siteVariables.colors.grey[50], | ||
|
||
backgroundColor: siteVariables.gray600, | ||
borderColor: siteVariables.gray850, | ||
boxShadow: siteVariables.shadowLevel1, | ||
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
packages/react/src/themes/teams-high-contrast/componentStyles.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
export { default as Attachment } from './components/Attachment/attachmentStyles' | ||
export { default as MenuItem } from './components/Menu/menuItemStyles' |
1 change: 1 addition & 0 deletions
1
packages/react/src/themes/teams-high-contrast/componentVariables.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
packages/react/src/themes/teams-high-contrast/components/Attachment/attachmentStyles.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
import { ComponentSlotStylesInput, ICSSInJSStyle } from '../../../types' | ||
import { AttachmentProps } from '../../../../components/Attachment/Attachment' | ||
import { AttachmentVariables } from '../../../teams/components/Attachment/attachmentVariables' | ||
import Button from '../../../../components/Button/Button' | ||
import Icon from '../../../../components/Icon/Icon' | ||
|
||
const attachmentStyles: ComponentSlotStylesInput<AttachmentProps, AttachmentVariables> = { | ||
root: ({ props: p, variables: v }): ICSSInJSStyle => ({ | ||
...((p.actionable || p.onClick) && { | ||
...(p.isFromKeyboard && { | ||
':focus': { | ||
backgroundColor: v.backgroundColorHover, | ||
color: v.textColorHover, | ||
|
||
[`& .${Button.className}`]: { | ||
color: v.textColorHover, | ||
}, | ||
|
||
[`& .${Icon.className}`]: { | ||
color: v.textColorHover, | ||
}, | ||
}, | ||
}), | ||
|
||
':hover': { | ||
[`& .${Button.className}`]: { | ||
color: v.textColorHover, | ||
}, | ||
|
||
[`& .${Icon.className}`]: { | ||
color: v.textColorHover, | ||
}, | ||
}, | ||
}), | ||
}), | ||
|
||
action: ({ variables: v }): ICSSInJSStyle => ({ | ||
':hover': { | ||
outline: `1px solid ${v.textColorHover}`, | ||
}, | ||
}), | ||
} | ||
|
||
export default attachmentStyles |
12 changes: 12 additions & 0 deletions
12
packages/react/src/themes/teams-high-contrast/components/Attachment/attachmentVariables.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { AttachmentVariables } from '../../../teams/components/Attachment/attachmentVariables' | ||
|
||
export default (siteVariables: any): Partial<AttachmentVariables> => ({ | ||
borderColor: siteVariables.colors.white, | ||
backgroundColor: siteVariables.colors.black, | ||
backgroundColorHover: siteVariables.accessibleYellow, | ||
textColor: siteVariables.colors.white, | ||
textColorHover: siteVariables.colors.black, | ||
boxShadow: undefined, | ||
progressColor: siteVariables.accessibleGreen, | ||
progressHeight: 6, | ||
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.