diff options
Diffstat (limited to 'src/components/services/content/ServiceDisabled.js')
-rw-r--r-- | src/components/services/content/ServiceDisabled.js | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/src/components/services/content/ServiceDisabled.js b/src/components/services/content/ServiceDisabled.js deleted file mode 100644 index d874a354e..000000000 --- a/src/components/services/content/ServiceDisabled.js +++ /dev/null | |||
@@ -1,43 +0,0 @@ | |||
1 | import { Component } from 'react'; | ||
2 | import PropTypes from 'prop-types'; | ||
3 | import { observer } from 'mobx-react'; | ||
4 | import { defineMessages, injectIntl } from 'react-intl'; | ||
5 | |||
6 | import Button from '../../ui/button'; | ||
7 | import { H1 } from '../../ui/headline'; | ||
8 | |||
9 | const messages = defineMessages({ | ||
10 | headline: { | ||
11 | id: 'service.disabledHandler.headline', | ||
12 | defaultMessage: '{name} is disabled', | ||
13 | }, | ||
14 | action: { | ||
15 | id: 'service.disabledHandler.action', | ||
16 | defaultMessage: 'Enable {name}', | ||
17 | }, | ||
18 | }); | ||
19 | |||
20 | class ServiceDisabled extends Component { | ||
21 | static propTypes = { | ||
22 | name: PropTypes.string.isRequired, | ||
23 | enable: PropTypes.func.isRequired, | ||
24 | }; | ||
25 | |||
26 | render() { | ||
27 | const { name, enable } = this.props; | ||
28 | const { intl } = this.props; | ||
29 | |||
30 | return ( | ||
31 | <div className="services__info-layer"> | ||
32 | <H1>{intl.formatMessage(messages.headline, { name })}</H1> | ||
33 | <Button | ||
34 | label={intl.formatMessage(messages.action, { name })} | ||
35 | buttonType="inverted" | ||
36 | onClick={() => enable()} | ||
37 | /> | ||
38 | </div> | ||
39 | ); | ||
40 | } | ||
41 | } | ||
42 | |||
43 | export default injectIntl(observer(ServiceDisabled)); | ||