[Glitch] Use the new JSX transform in onboarding code

Port the remaining of 8f66126b10 to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
main
Renaud Chaput 2023-05-23 10:52:27 +02:00 committed by Claire
parent 6e4497ab2d
commit ba4c8a9b41
3 changed files with 9 additions and 9 deletions

View File

@ -1,4 +1,4 @@
import React from 'react';
import { Fragment } from 'react';
import PropTypes from 'prop-types';
import { Check } from 'flavours/glitch/components/check';
import classNames from 'classnames';
@ -6,13 +6,13 @@ import classNames from 'classnames';
const ProgressIndicator = ({ steps, completed }) => (
<div className='onboarding__progress-indicator'>
{(new Array(steps)).fill().map((_, i) => (
<React.Fragment key={i}>
<Fragment key={i}>
{i > 0 && <div className={classNames('onboarding__progress-indicator__line', { active: completed > i })} />}
<div className={classNames('onboarding__progress-indicator__step', { active: completed > i })}>
{completed > i && <Check />}
</div>
</React.Fragment>
</Fragment>
))}
</div>
);

View File

@ -1,4 +1,4 @@
import React from 'react';
import { PureComponent } from 'react';
import Column from 'flavours/glitch/components/column';
import ColumnBackButton from 'flavours/glitch/components/column_back_button';
import PropTypes from 'prop-types';
@ -23,7 +23,7 @@ const mapStateToProps = () => {
});
};
class Follows extends React.PureComponent {
class Follows extends PureComponent {
static propTypes = {
onBack: PropTypes.func,

View File

@ -1,4 +1,4 @@
import React from 'react';
import { PureComponent } from 'react';
import Column from 'flavours/glitch/components/column';
import ColumnBackButton from 'flavours/glitch/components/column_back_button';
import PropTypes from 'prop-types';
@ -20,7 +20,7 @@ const mapStateToProps = state => ({
account: state.getIn(['accounts', me]),
});
class CopyPasteText extends React.PureComponent {
class CopyPasteText extends PureComponent {
static propTypes = {
value: PropTypes.string,
@ -81,7 +81,7 @@ class CopyPasteText extends React.PureComponent {
}
class TipCarousel extends React.PureComponent {
class TipCarousel extends PureComponent {
static propTypes = {
children: PropTypes.node,
@ -135,7 +135,7 @@ class TipCarousel extends React.PureComponent {
}
class Share extends React.PureComponent {
class Share extends PureComponent {
static propTypes = {
onBack: PropTypes.func,