diff --git a/src/DatabaseServices/EntityData.quo.ts b/__test__/EntityData.quo.ts similarity index 87% rename from src/DatabaseServices/EntityData.quo.ts rename to __test__/EntityData.quo.ts index e28f66e19..b16ed251e 100644 --- a/src/DatabaseServices/EntityData.quo.ts +++ b/__test__/EntityData.quo.ts @@ -1,7 +1,8 @@ +import * as console from 'console'; import { autorun } from 'mobx'; import * as mst from 'mobx-state-tree'; -import { EntityData, IEntityData, LineData } from './EntityData'; +import { EntityData, IEntityData, LineData } from '../src/DatabaseServices/EntityData'; class E { @@ -78,8 +79,9 @@ function add(a, b) { lst: mst.types.array(mst.types.number) }) - .actions(self =>{ - return{ + .actions(self => + { + return { remove(a) { this.lst.remove(a) @@ -88,7 +90,7 @@ function add(a, b) }) let l = L.create({ lst: [1, 2, 3] }) - mst.onPatch(l, (p,rp) => + mst.onPatch(l, (p, rp) => { console.log(p); }) diff --git a/src/UI/Store/CommandStore.ts b/src/UI/Store/CommandStore.ts index adb45555a..1472eb9a6 100644 --- a/src/UI/Store/CommandStore.ts +++ b/src/UI/Store/CommandStore.ts @@ -1,10 +1,11 @@ -import { observable, runInAction, autorun } from 'mobx'; -import { app } from '../../ApplicationServices/Application'; +import { observable } from 'mobx'; import * as xaop from 'xaop'; + +import { app } from '../../ApplicationServices/Application'; +import { IsChar, IsNumble } from '../../Common/Utils'; +import { commandMachine } from '../../Editor/CommandMachine'; import { Editor } from '../../Editor/Editor'; -import { IsNumble, IsChar } from '../../Common/Utils'; import { KeyBoardControls } from '../../Editor/KeyBoardControls'; -import { commandMachine } from '../../Editor/CommandMachine'; export interface CommandMsg { diff --git a/src/UI/Store/DownPanelStore.ts b/src/UI/Store/DownPanelStore.ts index 2eb8ae3f4..85724a3bf 100644 --- a/src/UI/Store/DownPanelStore.ts +++ b/src/UI/Store/DownPanelStore.ts @@ -1,8 +1,9 @@ -import { app } from '../../ApplicationServices/Application'; -import { Vector3 } from 'three'; import { observable } from 'mobx'; +import { Vector3 } from 'three'; import * as xaop from 'xaop'; +import { app } from '../../ApplicationServices/Application'; + //点转换为字符串. function PointToString(pt: Vector3): string