|
@@ -481,21 +481,6 @@ export class App extends React.Component<any, AppState> {
|
|
|
);
|
|
|
}
|
|
|
|
|
|
- private renderShapeLock() {
|
|
|
- const { elementLocked } = this.state;
|
|
|
- return (
|
|
|
- <LockIcon
|
|
|
- checked={elementLocked}
|
|
|
- onChange={() => {
|
|
|
- this.setState({
|
|
|
- elementLocked: !elementLocked,
|
|
|
- elementType: elementLocked ? "selection" : this.state.elementType,
|
|
|
- });
|
|
|
- }}
|
|
|
- />
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
private renderShapesSwitcher() {
|
|
|
const { t } = this.props;
|
|
|
|
|
@@ -525,7 +510,6 @@ export class App extends React.Component<any, AppState> {
|
|
|
></ToolButton>
|
|
|
);
|
|
|
})}
|
|
|
- {this.renderShapeLock()}
|
|
|
</>
|
|
|
);
|
|
|
}
|
|
@@ -623,10 +607,23 @@ export class App extends React.Component<any, AppState> {
|
|
|
</div>
|
|
|
</Stack.Col>
|
|
|
<Stack.Col gap={4} align="start">
|
|
|
- <Island padding={1}>
|
|
|
- <h2 className="visually-hidden">Shapes</h2>
|
|
|
- <Stack.Row gap={1}>{this.renderShapesSwitcher()}</Stack.Row>
|
|
|
- </Island>
|
|
|
+ <Stack.Row gap={1}>
|
|
|
+ <Island padding={1}>
|
|
|
+ <h2 className="visually-hidden">Shapes</h2>
|
|
|
+ <Stack.Row gap={1}>{this.renderShapesSwitcher()}</Stack.Row>
|
|
|
+ </Island>
|
|
|
+ <LockIcon
|
|
|
+ checked={this.state.elementLocked}
|
|
|
+ onChange={() => {
|
|
|
+ this.setState({
|
|
|
+ elementLocked: !this.state.elementLocked,
|
|
|
+ elementType: this.state.elementLocked
|
|
|
+ ? "selection"
|
|
|
+ : this.state.elementType,
|
|
|
+ });
|
|
|
+ }}
|
|
|
+ />
|
|
|
+ </Stack.Row>
|
|
|
</Stack.Col>
|
|
|
<div />
|
|
|
</div>
|