mirror of
https://github.com/muerwre/orchidmap-front.git
synced 2025-05-02 14:36:41 +07:00
fixed transition for stickers
This commit is contained in:
parent
5f7c036149
commit
b03c5ce0de
2 changed files with 14 additions and 7 deletions
src
|
@ -1,4 +1,4 @@
|
||||||
import React, { PureComponent } from 'react';
|
import React, { PureComponent, useState, useCallback } from 'react';
|
||||||
import { MODES } from '~/constants/modes';
|
import { MODES } from '~/constants/modes';
|
||||||
import classnames from 'classnames';
|
import classnames from 'classnames';
|
||||||
|
|
||||||
|
@ -23,9 +23,15 @@ const mapStateToProps = (state: IState) => {
|
||||||
const { mode, changed, editing, features, history } = selectEditor(state);
|
const { mode, changed, editing, features, history } = selectEditor(state);
|
||||||
const { route, stickers } = selectMap(state);
|
const { route, stickers } = selectMap(state);
|
||||||
return {
|
return {
|
||||||
mode, changed, editing, features, history, route, stickers,
|
mode,
|
||||||
}
|
changed,
|
||||||
}
|
editing,
|
||||||
|
features,
|
||||||
|
history,
|
||||||
|
route,
|
||||||
|
stickers,
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
const mapDispatchToProps = {
|
const mapDispatchToProps = {
|
||||||
editorChangeMode,
|
editorChangeMode,
|
||||||
|
@ -78,7 +84,8 @@ class EditorPanelUnconnected extends PureComponent<Props, void> {
|
||||||
editing,
|
editing,
|
||||||
features: { routing },
|
features: { routing },
|
||||||
history: { records, position },
|
history: { records, position },
|
||||||
route, stickers,
|
route,
|
||||||
|
stickers,
|
||||||
} = this.props;
|
} = this.props;
|
||||||
|
|
||||||
const can_undo = records.length > 0 && position > 0;
|
const can_undo = records.length > 0 && position > 0;
|
||||||
|
@ -165,7 +172,7 @@ class EditorPanelUnconnected extends PureComponent<Props, void> {
|
||||||
className={classnames({ primary: changed, inactive: !changed })}
|
className={classnames({ primary: changed, inactive: !changed })}
|
||||||
onClick={this.startSaveMode}
|
onClick={this.startSaveMode}
|
||||||
>
|
>
|
||||||
<span className="desktop-only">СОХРАНИТЬ</span>
|
<span className="desktop-only">СОХРАНИТЬ</span>
|
||||||
<Icon icon="icon-check-1" />
|
<Icon icon="icon-check-1" />
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -55,7 +55,7 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@media(hover: none) {
|
@media(hover: hover) {
|
||||||
transition: none;
|
transition: none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue