|
@@ -1,11 +1,12 @@
|
|
|
import { EditorModule } from "..";
|
|
|
+import { CompCtrl } from "../components/CompUI/CompController";
|
|
|
|
|
|
export const helpers = EditorModule.helper({
|
|
|
designToNaturalSize(value: number) {
|
|
|
return value / 100 + "rem";
|
|
|
},
|
|
|
findParentComp(compId: string) {
|
|
|
- const { content } = this.store.designData;
|
|
|
+ const { content } = CompCtrl.state;
|
|
|
const comp = content.find((comp) => {
|
|
|
return Object.values(comp.children || {}).find((d) => d.id === compId);
|
|
|
});
|