Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ability to style suggested action flippers #1883

Merged
merged 2 commits into from
Apr 8, 2019
Merged
Show file tree
Hide file tree
Changes from all 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 @@ -26,6 +26,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Add [#1524](https://github.com/Microsoft/BotFramework-WebChat/issues/1524) Offline UI connecting for the first time, by [@corinagum](https://github.com/corinagum), in PR [#1866](https://github.com/Microsoft/BotFramework-WebChat/pull/1866)
- Fix [#1768](https://github.com/Microsoft/BotFramework-WebChat/issues/1768). Add style option to modify all Send Box borders, by [@corinagum](https://github.com/corinagum) in PR [#1871](https://github.com/Microsoft/BotFramework-WebChat/pull/1871)
- Fix [#1827](https://github.com/Microsoft/BotFramework-WebChat/issues/1827). Remove renderer for unknown activities, by [@corinagum](https://github.com/corinagum) in PR [#1873](https://github.com/Microsoft/BotFramework-WebChat/pull/1873)
- Fix [#1586](https://github.com/Microsoft/BotFramework-WebChat/issues/1586). Fix theming of suggested actions buttons, by [@corinagum](https://github.com/corinagum) in PR [#1883](https://github.com/Microsoft/BotFramework-WebChat/pull/1883)

## [4.3.0] - 2019-03-04

Expand Down
33 changes: 31 additions & 2 deletions packages/component/src/Styles/StyleSet/SuggestedActions.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,37 @@
export default function createSuggestedActionsStyle({
paddingRegular
paddingRegular,
transcriptOverlayButtonBackground,
transcriptOverlayButtonBackgroundOnDisabled,
transcriptOverlayButtonBackgroundOnFocus,
transcriptOverlayButtonBackgroundOnHover,
transcriptOverlayButtonColor,
transcriptOverlayButtonColorOnDisabled,
transcriptOverlayButtonColorOnFocus,
transcriptOverlayButtonColorOnHover
}) {
return {
paddingLeft: paddingRegular / 2,
paddingRight: paddingRegular / 2
paddingRight: paddingRegular / 2,

'& button > div.slider > div': {
backgroundColor: transcriptOverlayButtonBackground,
color: transcriptOverlayButtonColor,
outline: 0
},

'& button:disabled > div.slider > div': {
backgroundColor: transcriptOverlayButtonBackgroundOnDisabled,
color: transcriptOverlayButtonColorOnDisabled
},

'& button:focus > div.slider > div': {
backgroundColor: transcriptOverlayButtonBackgroundOnFocus,
color: transcriptOverlayButtonColorOnFocus
},

'& button:hover > div.slider > div': {
backgroundColor: transcriptOverlayButtonBackgroundOnHover,
color: transcriptOverlayButtonColorOnHover
}
};
}
2 changes: 1 addition & 1 deletion packages/component/src/Styles/defaultStyleSetOptions.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ const DEFAULT_OPTIONS = {
// Timestamp
timestampColor: DEFAULT_SUBTLE,

// Transcript overlay buttons (e.g. carousel and scroll to bottom)
// Transcript overlay buttons (e.g. carousel and suggested action flippers, scroll to bottom, etc.)
transcriptOverlayButtonBackground: 'rgba(0, 0, 0, .6)',
transcriptOverlayButtonBackgroundOnFocus: 'rgba(0, 0, 0, .8)',
transcriptOverlayButtonBackgroundOnHover: 'rgba(0, 0, 0, .8)',
Expand Down