-
Notifications
You must be signed in to change notification settings - Fork 107
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
EPMUII-2947-Implement control of centering model on 3D view
- Loading branch information
Oleksandr Iefymchuk
committed
Jan 10, 2024
1 parent
919d4d7
commit 0245a3e
Showing
8 changed files
with
65 additions
and
11 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import React from 'react'; | ||
import { useDispatch } from 'react-redux'; | ||
|
||
import { connect } from 'react-redux'; | ||
import StoreActionType from '../../store/ActionTypes'; | ||
import { Container } from '../Layout/Container'; | ||
import { Tooltip } from '../Tooltip/Tooltip'; | ||
import { UIButton } from '../Button/Button'; | ||
|
||
const PositionTool3D = () => { | ||
const dispatch = useDispatch(); | ||
|
||
const positionReset = () => { | ||
dispatch({ type: StoreActionType.SET_DEFAULT_3D_POSITION, isDefault3dPosition: true }); | ||
}; | ||
|
||
return ( | ||
<Container direction="vertical"> | ||
<Tooltip content="Default position"> | ||
<UIButton icon="position" handler={positionReset} /> | ||
</Tooltip> | ||
</Container> | ||
); | ||
}; | ||
|
||
export default connect((store) => store)(PositionTool3D); |