mirror of
https://github.com/balena-io/etcher.git
synced 2025-07-23 11:16:39 +00:00
Remove useless StepSelection component
Change-type: patch
This commit is contained in:
parent
95ff5c98a8
commit
6db0172a50
@ -36,7 +36,6 @@ import { scanner as driveScanner } from '../../modules/drive-scanner';
|
||||
import * as imageWriter from '../../modules/image-writer';
|
||||
import * as progressStatus from '../../modules/progress-status';
|
||||
import * as notification from '../../os/notification';
|
||||
import { StepSelection } from '../../styled-components';
|
||||
|
||||
const COMPLETED_PERCENTAGE = 100;
|
||||
const SPEED_PRECISION = 2;
|
||||
@ -261,33 +260,31 @@ export class FlashStep extends React.PureComponent<
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className="space-vertical-large">
|
||||
<StepSelection>
|
||||
<ProgressButton
|
||||
type={this.props.step}
|
||||
active={this.props.isFlashing}
|
||||
percentage={this.props.percentage}
|
||||
label={getProgressButtonLabel(
|
||||
this.props.isFlashing,
|
||||
this.props.step,
|
||||
this.props.position,
|
||||
this.props.percentage,
|
||||
)}
|
||||
disabled={this.props.shouldFlashStepBeDisabled}
|
||||
callback={() => {
|
||||
this.tryFlash();
|
||||
}}
|
||||
/>
|
||||
{this.props.isFlashing && (
|
||||
<IconButton
|
||||
icon={<FontAwesomeIcon icon={faTimes} />}
|
||||
plain
|
||||
onClick={imageWriter.cancel}
|
||||
color="#fff"
|
||||
hoverIndicator={{ dark: true }}
|
||||
/>
|
||||
<div className="space-vertical-large" style={{ display: 'flex' }}>
|
||||
<ProgressButton
|
||||
type={this.props.step}
|
||||
active={this.props.isFlashing}
|
||||
percentage={this.props.percentage}
|
||||
label={getProgressButtonLabel(
|
||||
this.props.isFlashing,
|
||||
this.props.step,
|
||||
this.props.position,
|
||||
this.props.percentage,
|
||||
)}
|
||||
</StepSelection>
|
||||
disabled={this.props.shouldFlashStepBeDisabled}
|
||||
callback={() => {
|
||||
this.tryFlash();
|
||||
}}
|
||||
/>
|
||||
{this.props.isFlashing && (
|
||||
<IconButton
|
||||
icon={<FontAwesomeIcon icon={faTimes} />}
|
||||
plain
|
||||
onClick={imageWriter.cancel}
|
||||
color="#fff"
|
||||
hoverIndicator={{ dark: true }}
|
||||
/>
|
||||
)}
|
||||
|
||||
{!_.isNil(this.props.speed) &&
|
||||
this.props.percentage !== COMPLETED_PERCENTAGE && (
|
||||
|
@ -123,10 +123,6 @@ export const StepNameButton = styled(Button)`
|
||||
}
|
||||
}
|
||||
`;
|
||||
export const StepSelection = styled(Flex)`
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
`;
|
||||
export const Footer = styled(Txt)`
|
||||
margin-top: 10px;
|
||||
color: ${colors.dark.disabled.foreground};
|
||||
|
Loading…
x
Reference in New Issue
Block a user