|
|
@@ -133,6 +133,7 @@ class ShareLinkForm extends React.Component {
|
|
|
|
|
|
renderExpirationTypeOptions() {
|
|
|
const { expirationType } = this.state;
|
|
|
+ const { t } = this.props;
|
|
|
|
|
|
return (
|
|
|
<div className="form-group">
|
|
|
@@ -146,7 +147,7 @@ class ShareLinkForm extends React.Component {
|
|
|
checked={expirationType === 'unlimited'}
|
|
|
onChange={() => { this.handleChangeExpirationType('unlimited') }}
|
|
|
/>
|
|
|
- <label className="custom-control-label" htmlFor="customRadio1">Unlimited</label>
|
|
|
+ <label className="custom-control-label" htmlFor="customRadio1">{t('share_links.Unlimited')}</label>
|
|
|
</div>
|
|
|
|
|
|
<div className="custom-control custom-radio offset-4 mb-2">
|
|
|
@@ -170,7 +171,7 @@ class ShareLinkForm extends React.Component {
|
|
|
onFocus={() => { this.handleChangeExpirationType('numberOfDays') }}
|
|
|
onChange={e => this.handleChangeNumberOfDays(Number(e.target.value))}
|
|
|
/>
|
|
|
- <span className="col-auto">Days</span>
|
|
|
+ <span className="col-auto">{t('share_links.Days')}</span>
|
|
|
</div>
|
|
|
</label>
|
|
|
</div>
|
|
|
@@ -186,7 +187,7 @@ class ShareLinkForm extends React.Component {
|
|
|
onChange={() => { this.handleChangeExpirationType('custom') }}
|
|
|
/>
|
|
|
<label className="custom-control-label" htmlFor="customRadio3">
|
|
|
- Custom
|
|
|
+ {t('share_links.Custom')}
|
|
|
</label>
|
|
|
<input
|
|
|
type="date"
|
|
|
@@ -210,15 +211,16 @@ class ShareLinkForm extends React.Component {
|
|
|
}
|
|
|
|
|
|
renderDescriptionForm() {
|
|
|
+ const { t } = this.props;
|
|
|
return (
|
|
|
<div className="form-group row">
|
|
|
- <label htmlFor="inputDesc" className="col-md-4 col-form-label">Description</label>
|
|
|
+ <label htmlFor="inputDesc" className="col-md-4 col-form-label">{t('share_links.description')}</label>
|
|
|
<div className="col-md-4">
|
|
|
<input
|
|
|
type="text"
|
|
|
className="form-control"
|
|
|
id="inputDesc"
|
|
|
- placeholder="Enter description"
|
|
|
+ placeholder={t('share_links.enter_desc')}
|
|
|
value={this.state.description}
|
|
|
onChange={e => this.handleChangeDescription(e.target.value)}
|
|
|
/>
|
|
|
@@ -228,15 +230,16 @@ class ShareLinkForm extends React.Component {
|
|
|
}
|
|
|
|
|
|
render() {
|
|
|
+ const { t } = this.props;
|
|
|
return (
|
|
|
<div className="share-link-form border p-3">
|
|
|
- <h4>Expiration Date</h4>
|
|
|
+ <h4>{t('share_links.expire')}</h4>
|
|
|
{this.renderExpirationTypeOptions()}
|
|
|
<hr />
|
|
|
{this.renderDescriptionForm()}
|
|
|
<div className="text-right">
|
|
|
<button type="button" className="btn btn-primary" onClick={this.handleIssueShareLink}>
|
|
|
- Issue
|
|
|
+ {t('share_links.Issue')}
|
|
|
</button>
|
|
|
</div>
|
|
|
</div>
|