mirror of
https://github.com/xibyte/jsketcher
synced 2025-12-14 20:33:30 +01:00
implement datum copy option for move operation
This commit is contained in:
parent
19c6551bbd
commit
2c720f37b6
2 changed files with 2 additions and 2 deletions
|
|
@ -1,7 +1,6 @@
|
|||
import React from 'react';
|
||||
import {Group} from '../../wizard/components/form/Form';
|
||||
import {CheckboxField, NumberField, ReadOnlyValueField} from '../../wizard/components/form/Fields';
|
||||
import ReadOnlyValueControl from 'ui/components/controls/ReadOnlyValueControl';
|
||||
|
||||
export default function MoveDatumWizard() {
|
||||
return <Group>
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ import {renderPoint} from 'renders';
|
|||
import {MDatum} from '../../../model/mdatum';
|
||||
import MoveDatumWizard from './MoveDatumWizard';
|
||||
import {roundInteractiveInput} from '../../wizard/roundUtils';
|
||||
import {EMPTY_ARRAY} from '../../../../../../modules/gems/iterables';
|
||||
|
||||
|
||||
function move(params, {cadRegistry}) {
|
||||
|
|
@ -15,7 +16,7 @@ function move(params, {cadRegistry}) {
|
|||
csys.origin.z += params.z;
|
||||
|
||||
return {
|
||||
consumed: [mDatum],
|
||||
consumed: params.copy ? EMPTY_ARRAY : [mDatum],
|
||||
created: [new MDatum(csys)]
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue