0
0
Fork 0

Use the new JSX transform (#25064)

This commit is contained in:
Renaud Chaput 2023-05-23 10:52:27 +02:00 committed by GitHub
parent e387175fc9
commit 8f66126b10
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
241 changed files with 366 additions and 473 deletions

View file

@ -1,9 +1,9 @@
import React from 'react';
import { PureComponent } from 'react';
import PropTypes from 'prop-types';
import { FormattedMessage } from 'react-intl';
import { Icon } from 'mastodon/components/icon';
export default class ClearColumnButton extends React.PureComponent {
export default class ClearColumnButton extends PureComponent {
static propTypes = {
onClick: PropTypes.func.isRequired,

View file

@ -1,4 +1,4 @@
import React from 'react';
import { PureComponent } from 'react';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import { FormattedMessage } from 'react-intl';
@ -7,7 +7,7 @@ import GrantPermissionButton from './grant_permission_button';
import SettingToggle from './setting_toggle';
import { PERMISSION_MANAGE_USERS, PERMISSION_MANAGE_REPORTS } from 'mastodon/permissions';
export default class ColumnSettings extends React.PureComponent {
export default class ColumnSettings extends PureComponent {
static contextTypes = {
identity: PropTypes.object,

View file

@ -1,4 +1,4 @@
import React from 'react';
import { PureComponent } from 'react';
import PropTypes from 'prop-types';
import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
import { Icon } from 'mastodon/components/icon';
@ -12,7 +12,7 @@ const tooltips = defineMessages({
statuses: { id: 'notifications.filter.statuses', defaultMessage: 'Updates from people you follow' },
});
class FilterBar extends React.PureComponent {
class FilterBar extends PureComponent {
static propTypes = {
selectFilter: PropTypes.func.isRequired,

View file

@ -1,4 +1,4 @@
import React from 'react';
import { Fragment } from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { Avatar } from 'mastodon/components/avatar';
@ -31,10 +31,10 @@ class FollowRequest extends ImmutablePureComponent {
if (hidden) {
return (
<React.Fragment>
<Fragment>
{account.get('display_name')}
{account.get('username')}
</React.Fragment>
</Fragment>
);
}

View file

@ -1,8 +1,8 @@
import React from 'react';
import { PureComponent } from 'react';
import PropTypes from 'prop-types';
import { FormattedMessage } from 'react-intl';
export default class GrantPermissionButton extends React.PureComponent {
export default class GrantPermissionButton extends PureComponent {
static propTypes = {
onClick: PropTypes.func.isRequired,

View file

@ -1,4 +1,3 @@
import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import { injectIntl, FormattedMessage, defineMessages } from 'react-intl';
import { HotKeys } from 'react-hotkeys';

View file

@ -1,4 +1,4 @@
import React from 'react';
import { PureComponent } from 'react';
import { Icon } from 'mastodon/components/icon';
import Button from 'mastodon/components/button';
import { IconButton } from 'mastodon/components/icon_button';
@ -12,7 +12,7 @@ const messages = defineMessages({
close: { id: 'lightbox.close', defaultMessage: 'Close' },
});
class NotificationsPermissionBanner extends React.PureComponent {
class NotificationsPermissionBanner extends PureComponent {
static propTypes = {
dispatch: PropTypes.func.isRequired,

View file

@ -1,4 +1,4 @@
import React, { Fragment } from 'react';
import { Fragment } from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { defineMessages, FormattedMessage, injectIntl } from 'react-intl';

View file

@ -1,9 +1,9 @@
import React from 'react';
import { PureComponent } from 'react';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import Toggle from 'react-toggle';
export default class SettingToggle extends React.PureComponent {
export default class SettingToggle extends PureComponent {
static propTypes = {
prefix: PropTypes.string,