@@ -59,6 +59,12 @@ Description:
59
59
</section >
60
60
</template >
61
61
62
+ <script >
63
+ export default {
64
+ name: " HTMLQueue" ,
65
+ };
66
+ </script >
67
+
62
68
<script setup lang="ts">
63
69
import { ref , computed , watch } from " vue" ;
64
70
import { useStore } from " ../../store/main.js" ;
@@ -136,8 +142,8 @@ const moreExceptions = () => {
136
142
return childComponent ;
137
143
};
138
144
139
- const parentSelected: typeof store .parentSelected = (payload : any ) =>
140
- store .parentSelected (payload );
145
+ // const parentSelected: typeof store.parentSelected = (payload: any) =>
146
+ // store.parentSelected(payload);
141
147
142
148
const setActiveHTML: typeof store .setActiveHTML = (payload ) =>
143
149
store .setActiveHTML (payload );
@@ -187,12 +193,12 @@ const setActiveElement = (element: string[]) => {
187
193
188
194
const setLayer = (element : { text: string ; id: string }) => {
189
195
setActiveLayer (element );
190
- element .id = activeHTML .value ;
196
+ element .id = activeHTML .value as string ;
191
197
};
192
198
193
199
const setParentLayer = () => {
194
200
if (activeLayer .value .id !== " " ) {
195
- upOneLayer (activeLayer .value .id );
201
+ upOneLayer (activeLayer .value .id as string );
196
202
}
197
203
};
198
204
@@ -228,7 +234,7 @@ const endDrag = (event: MouseEvent) => {
228
234
else dragDropSortHtmlElements ();
229
235
};
230
236
231
- const submitClass = (element : string , idNum : string ) => {
237
+ const submitClass = (element : string , idNum : number ) => {
232
238
if (element === " " ) {
233
239
return ;
234
240
}
@@ -237,6 +243,7 @@ const submitClass = (element: string, idNum: string) => {
237
243
class: element ,
238
244
id: idNum ,
239
245
};
246
+
240
247
addActiveComponentClass (payload );
241
248
classText .value = " " ;
242
249
};
@@ -245,7 +252,7 @@ const addBinding = (input: string, idNum: number) => {
245
252
if (input === " " ) {
246
253
return ;
247
254
}
248
- const payload: { binding: string ; id: number } = {
255
+ const payload : {binding: string , id: number } = {
249
256
binding: input ,
250
257
id: idNum ,
251
258
};
@@ -257,13 +264,13 @@ watch(attributeModalOpen, () => {
257
264
attributeModal .value = attributeModalOpen .value ;
258
265
});
259
266
260
- // watch(activeComponent, () => {
261
- // if (activeComponent.value !== "") {
262
- // (store.componentMap[activeComponent.value] as Component).isActive = true;
263
- // } else {
264
- // (store.componentMap[activeComponent.value] as Component).isActive = false;
265
- // }
266
- // });
267
+ watch (activeComponent , () => {
268
+ if (activeComponent .value !== " " ) {
269
+ (store .componentMap [activeComponent .value ] as Component ).isActive = true ;
270
+ } else {
271
+ (store .componentMap [activeComponent .value ] as Component ).isActive = false ;
272
+ }
273
+ });
267
274
</script >
268
275
269
276
<!-- <script>
0 commit comments