blob: 475ce6b1c594d7e02dbec56268ba6c8c07ffad40 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
import React, { Component } from 'react'
import PropTypes from 'prop-types'
export default class PageContainerFooter extends Component {
static propTypes = {
onCancel: PropTypes.func,
onSubmit: PropTypes.func,
disabled: PropTypes.bool,
};
render () {
const { onCancel, onSubmit, disabled } = this.props
return (
<div className="page-container__footer">
<button
className="btn-secondary--lg page-container__footer-button"
onClick={() => onCancel()}
>
{this.context.t('cancel')}
</button>
<button
className="btn-primary--lg page-container__footer-button"
disabled={disabled}
onClick={(e) => onSubmit(e)}
>
{this.context.t('next')}
</button>
</div>
)
}
}
PageContainerFooter.contextTypes = {
t: PropTypes.func,
}
|