diff options
author | 2017-11-10 15:40:01 +0100 | |
---|---|---|
committer | 2017-11-10 15:40:01 +0100 | |
commit | f39e31af92f3ae6689697685d008f0487a5be351 (patch) | |
tree | c00654dbb28817cbfdca8223c1f86d38c706e163 /src/components/services/content/ServiceWebview.js | |
parent | feat(App): Respect System DoNotDisturb mode for service audio (diff) | |
parent | Merge pull request #248 from meetfranz/feature/192-display-disabled-services (diff) | |
download | ferdium-app-f39e31af92f3ae6689697685d008f0487a5be351.tar.gz ferdium-app-f39e31af92f3ae6689697685d008f0487a5be351.tar.zst ferdium-app-f39e31af92f3ae6689697685d008f0487a5be351.zip |
Merge branch 'develop' into feature/mute-service
# Conflicts:
# src/components/services/content/ServiceWebview.js
# src/components/services/content/Services.js
# src/components/services/tabs/TabItem.js
# src/containers/layout/AppLayoutContainer.js
Diffstat (limited to 'src/components/services/content/ServiceWebview.js')
-rw-r--r-- | src/components/services/content/ServiceWebview.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/components/services/content/ServiceWebview.js b/src/components/services/content/ServiceWebview.js index 60bdf7e47..08ba5f33d 100644 --- a/src/components/services/content/ServiceWebview.js +++ b/src/components/services/content/ServiceWebview.js | |||
@@ -8,6 +8,7 @@ import classnames from 'classnames'; | |||
8 | import ServiceModel from '../../../models/Service'; | 8 | import ServiceModel from '../../../models/Service'; |
9 | import StatusBarTargetUrl from '../../ui/StatusBarTargetUrl'; | 9 | import StatusBarTargetUrl from '../../ui/StatusBarTargetUrl'; |
10 | import WebviewCrashHandler from './WebviewCrashHandler'; | 10 | import WebviewCrashHandler from './WebviewCrashHandler'; |
11 | import ServiceDisabled from './ServiceDisabled'; | ||
11 | 12 | ||
12 | @observer | 13 | @observer |
13 | export default class ServiceWebview extends Component { | 14 | export default class ServiceWebview extends Component { |
@@ -15,7 +16,11 @@ export default class ServiceWebview extends Component { | |||
15 | service: PropTypes.instanceOf(ServiceModel).isRequired, | 16 | service: PropTypes.instanceOf(ServiceModel).isRequired, |
16 | setWebviewReference: PropTypes.func.isRequired, | 17 | setWebviewReference: PropTypes.func.isRequired, |
17 | reload: PropTypes.func.isRequired, | 18 | reload: PropTypes.func.isRequired, |
19 | <<<<<<< HEAD | ||
18 | isAppMuted: PropTypes.bool.isRequired, | 20 | isAppMuted: PropTypes.bool.isRequired, |
21 | ======= | ||
22 | enable: PropTypes.func.isRequired, | ||
23 | >>>>>>> develop | ||
19 | }; | 24 | }; |
20 | 25 | ||
21 | static defaultProps = { | 26 | static defaultProps = { |
@@ -58,6 +63,7 @@ export default class ServiceWebview extends Component { | |||
58 | setWebviewReference, | 63 | setWebviewReference, |
59 | reload, | 64 | reload, |
60 | isAppMuted, | 65 | isAppMuted, |
66 | enable, | ||
61 | } = this.props; | 67 | } = this.props; |
62 | 68 | ||
63 | const webviewClasses = classnames({ | 69 | const webviewClasses = classnames({ |
@@ -82,6 +88,13 @@ export default class ServiceWebview extends Component { | |||
82 | reload={reload} | 88 | reload={reload} |
83 | /> | 89 | /> |
84 | )} | 90 | )} |
91 | {!service.isEnabled && ( | ||
92 | <ServiceDisabled | ||
93 | name={service.recipe.name} | ||
94 | webview={service.webview} | ||
95 | enable={enable} | ||
96 | /> | ||
97 | )} | ||
85 | <Webview | 98 | <Webview |
86 | ref={(element) => { this.webview = element; }} | 99 | ref={(element) => { this.webview = element; }} |
87 | autosize | 100 | autosize |