mirror of
https://github.com/astuto/astuto.git
synced 2025-12-16 03:37:56 +01:00
committed by
GitHub
parent
ba86e81aa0
commit
78049a820c
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import { Draggable } from 'react-beautiful-dnd';
|
||||
import { DescriptionText } from '../../shared/CustomTexts';
|
||||
@@ -82,7 +83,7 @@ class BoardsEditable extends React.Component<Props, State> {
|
||||
</div>
|
||||
|
||||
<div className="boardEditableActions">
|
||||
<a onClick={this.toggleEditMode}>Edit</a>
|
||||
<a onClick={this.toggleEditMode}>{I18n.t('common.buttons.edit')}</a>
|
||||
|
||||
<Separator />
|
||||
|
||||
@@ -90,7 +91,7 @@ class BoardsEditable extends React.Component<Props, State> {
|
||||
onClick={() => handleDelete(id)}
|
||||
data-confirm="Are you sure?"
|
||||
>
|
||||
Delete
|
||||
{I18n.t('common.buttons.delete')}
|
||||
</a>
|
||||
</div>
|
||||
</React.Fragment>
|
||||
@@ -107,7 +108,7 @@ class BoardsEditable extends React.Component<Props, State> {
|
||||
<a
|
||||
className="boardFormCancelButton"
|
||||
onClick={this.toggleEditMode}>
|
||||
Cancel
|
||||
{I18n.t('common.buttons.cancel')}
|
||||
</a>
|
||||
</React.Fragment>
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import Button from '../../shared/Button';
|
||||
|
||||
@@ -83,7 +84,7 @@ class BoardForm extends React.Component<Props, State> {
|
||||
<div className="boardMandatoryForm">
|
||||
<input
|
||||
type="text"
|
||||
placeholder="Board name"
|
||||
placeholder={I18n.t('site_settings.boards.form.name')}
|
||||
value={name}
|
||||
onChange={e => this.onNameChange(e.target.value)}
|
||||
className="form-control"
|
||||
@@ -94,12 +95,17 @@ class BoardForm extends React.Component<Props, State> {
|
||||
className="newBoardButton"
|
||||
disabled={!this.isFormValid()}
|
||||
>
|
||||
{mode === 'create' ? 'Create' : 'Save'}
|
||||
{
|
||||
mode === 'create' ?
|
||||
I18n.t('common.buttons.create')
|
||||
:
|
||||
I18n.t('common.buttons.update')
|
||||
}
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
<textarea
|
||||
placeholder="Optional board description"
|
||||
placeholder={I18n.t('site_settings.boards.form.description')}
|
||||
value={description}
|
||||
onChange={e => this.onDescriptionChange(e.target.value)}
|
||||
className="form-control"
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import { DragDropContext, Droppable } from 'react-beautiful-dnd';
|
||||
|
||||
@@ -90,7 +91,7 @@ class BoardsSiteSettingsP extends React.Component<Props> {
|
||||
return (
|
||||
<React.Fragment>
|
||||
<div className="content">
|
||||
<h2>Boards</h2>
|
||||
<h2>{I18n.t('site_settings.boards.title')}</h2>
|
||||
|
||||
{
|
||||
boards.items.length > 0 ?
|
||||
@@ -121,12 +122,12 @@ class BoardsSiteSettingsP extends React.Component<Props> {
|
||||
boards.areLoading ?
|
||||
<Spinner />
|
||||
:
|
||||
<CenteredMutedText>There are no boards. Create one below!</CenteredMutedText>
|
||||
<CenteredMutedText>{I18n.t('site_settings.boards.empty')}</CenteredMutedText>
|
||||
}
|
||||
</div>
|
||||
|
||||
<div className="content">
|
||||
<h2>New</h2>
|
||||
<h2>{I18n.t('site_settings.boards.new')}</h2>
|
||||
|
||||
<BoardForm mode='create' handleSubmit={this.handleSubmit} />
|
||||
</div>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import { Draggable } from 'react-beautiful-dnd';
|
||||
|
||||
@@ -74,7 +75,7 @@ class PostStatusEditable extends React.Component<Props, State> {
|
||||
<PostStatusLabel name={name} color={color} />
|
||||
|
||||
<div className="postStatusEditableActions">
|
||||
<a onClick={this.toggleEditMode}>Edit</a>
|
||||
<a onClick={this.toggleEditMode}>{I18n.t('common.buttons.edit')}</a>
|
||||
|
||||
<Separator />
|
||||
|
||||
@@ -82,7 +83,7 @@ class PostStatusEditable extends React.Component<Props, State> {
|
||||
onClick={() => handleDelete(id)}
|
||||
data-confirm="Are you sure?"
|
||||
>
|
||||
Delete
|
||||
{I18n.t('common.buttons.delete')}
|
||||
</a>
|
||||
</div>
|
||||
</React.Fragment>
|
||||
@@ -99,7 +100,7 @@ class PostStatusEditable extends React.Component<Props, State> {
|
||||
<a
|
||||
className="postStatusFormCancelButton"
|
||||
onClick={this.toggleEditMode}>
|
||||
Cancel
|
||||
{I18n.t('common.buttons.cancel')}
|
||||
</a>
|
||||
</React.Fragment>
|
||||
}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import Button from '../../shared/Button';
|
||||
|
||||
@@ -89,7 +90,7 @@ class PostStatusForm extends React.Component<Props, State> {
|
||||
<div className="postStatusForm">
|
||||
<input
|
||||
type="text"
|
||||
placeholder="Post status name"
|
||||
placeholder={I18n.t('site_settings.post_statuses.form.name')}
|
||||
value={name}
|
||||
onChange={e => this.onNameChange(e.target.value)}
|
||||
className="form-control"
|
||||
@@ -107,7 +108,12 @@ class PostStatusForm extends React.Component<Props, State> {
|
||||
className="newPostStatusButton"
|
||||
disabled={!this.isFormValid()}
|
||||
>
|
||||
{mode === 'create' ? 'Create' : 'Save'}
|
||||
{
|
||||
mode === 'create' ?
|
||||
I18n.t('common.buttons.create')
|
||||
:
|
||||
I18n.t('common.buttons.update')
|
||||
}
|
||||
</Button>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import * as React from 'react';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import { DragDropContext, Droppable } from 'react-beautiful-dnd';
|
||||
import IPostStatus from '../../../interfaces/IPostStatus';
|
||||
@@ -85,7 +86,7 @@ class PostStatusesSiteSettingsP extends React.Component<Props> {
|
||||
return (
|
||||
<React.Fragment>
|
||||
<div className="content">
|
||||
<h2>Post statuses</h2>
|
||||
<h2>{I18n.t('site_settings.post_statuses.title')}</h2>
|
||||
|
||||
{
|
||||
postStatuses.items.length > 0 ?
|
||||
@@ -116,12 +117,12 @@ class PostStatusesSiteSettingsP extends React.Component<Props> {
|
||||
postStatuses.areLoading ?
|
||||
<Spinner />
|
||||
:
|
||||
<CenteredMutedText>There are no post statuses. Create one below!</CenteredMutedText>
|
||||
<CenteredMutedText>{I18n.t('site_settings.post_statuses.empty')}</CenteredMutedText>
|
||||
}
|
||||
</div>
|
||||
|
||||
<div className="content">
|
||||
<h2>New</h2>
|
||||
<h2>{I18n.t('site_settings.post_statuses.new')}</h2>
|
||||
|
||||
<PostStatusForm mode='create' handleSubmit={this.handleSubmit} />
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user