[MM-54878] Replace usage of LocalizedIcon in 'plain_log_list.tsx' with i/span tags (#25135)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
bcc60ed692
Коммит
6dda6e3540
@@ -2,28 +2,25 @@
|
|||||||
// See LICENSE.txt for license information.
|
// See LICENSE.txt for license information.
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import {FormattedMessage} from 'react-intl';
|
import {FormattedMessage, injectIntl, type WrappedComponentProps} from 'react-intl';
|
||||||
|
|
||||||
import LocalizedIcon from 'components/localized_icon';
|
|
||||||
import NextIcon from 'components/widgets/icons/fa_next_icon';
|
import NextIcon from 'components/widgets/icons/fa_next_icon';
|
||||||
|
|
||||||
import {t} from 'utils/i18n';
|
|
||||||
|
|
||||||
const NEXT_BUTTON_TIMEOUT = 500;
|
const NEXT_BUTTON_TIMEOUT = 500;
|
||||||
|
|
||||||
type Props = {
|
interface Props extends WrappedComponentProps {
|
||||||
logs: string[];
|
logs: string[];
|
||||||
page: number;
|
page: number;
|
||||||
perPage: number;
|
perPage: number;
|
||||||
nextPage: () => void;
|
nextPage: () => void;
|
||||||
previousPage: () => void;
|
previousPage: () => void;
|
||||||
};
|
}
|
||||||
|
|
||||||
type State = {
|
type State = {
|
||||||
nextDisabled: boolean;
|
nextDisabled: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
export default class PlainLogList extends React.PureComponent<Props, State> {
|
class PlainLogList extends React.PureComponent<Props, State> {
|
||||||
private logPanel: React.RefObject<HTMLDivElement>;
|
private logPanel: React.RefObject<HTMLDivElement>;
|
||||||
|
|
||||||
constructor(props: Props) {
|
constructor(props: Props) {
|
||||||
@@ -96,9 +93,9 @@ export default class PlainLogList extends React.PureComponent<Props, State> {
|
|||||||
className='btn btn-tertiary filter-control filter-control__prev'
|
className='btn btn-tertiary filter-control filter-control__prev'
|
||||||
onClick={this.previousPage}
|
onClick={this.previousPage}
|
||||||
>
|
>
|
||||||
<LocalizedIcon
|
<i
|
||||||
className='fa fa-angle-left'
|
className='fa fa-angle-left'
|
||||||
title={{id: t('generic_icons.previous'), defaultMessage: 'Previous Icon'}}
|
title={this.props.intl.formatMessage({id: 'generic_icons.previous', defaultMessage: 'Previous Icon'})}
|
||||||
/>
|
/>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='admin.logs.prev'
|
id='admin.logs.prev'
|
||||||
@@ -147,3 +144,5 @@ export default class PlainLogList extends React.PureComponent<Props, State> {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export default injectIntl(PlainLogList);
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user