@@ -11,9 +11,7 @@ Description:
11
11
<div class =" top-p" v-if =" this.activeComponent === ''" >
12
12
Select a component
13
13
</div >
14
- <div v-else >{{ `${this.activeComponent}.vue` }}</div > <button class =" refreshCode" >
15
- <q-icon size =" 25px" z-layer =" 0" name =" refresh" @click =" this.snippetInvoke" />
16
- </button >
14
+ <div v-else >{{ `${this.activeComponent}.vue` }}</div >
17
15
<prism-editor v-model =" code" :highlight =" highlighter" line-numbers class =" my-editor" readonly />
18
16
</div >
19
17
</template >
@@ -76,16 +74,7 @@ export default {
76
74
// Creates beginner boilerplate
77
75
createTemplate (componentName ) {
78
76
let templateTagStr = this .writeTemplateTag (componentName);
79
- <<<<<< < HEAD
80
- if (this .activeComponentObj .htmlAttributes .class !== " " ) return ` <template>\n <div class = "${ this .activeComponentObj .htmlAttributes .class } ">\n ${ templateTagStr} </div>\n </template>` ;
81
- else return ` <template>\n <div>\n ${ templateTagStr} </div>\n </template>` ;
82
-
83
- ====== =
84
- console .log (this .activeComponentObj )
85
- // if(this.activeComponentObj.htmlAttributes.class !== "") return `<template>\n <div class = "${this.activeComponentObj.htmlAttributes.class}">\n${templateTagStr} </div>\n</template>`;
86
- // else return `<template>\n <div>\n${templateTagStr} </div>\n</template>`;
87
-
88
- >>>>>> > d43111c7d7f70bf069d8763816730ae516810d3f
77
+ return ` <template>\n <div>\n ${ templateTagStr} </div>\n </template>` ;
89
78
},
90
79
// Creates <template> boilerplate
91
80
writeTemplateTag (componentName ) {
@@ -207,7 +196,7 @@ export default {
207
196
children .forEach ((name ) => {
208
197
childrenComponentNames += ` ${ name} ,\n ` ;
209
198
});
210
-
199
+ console . log ( " lets look at data " , this . componentMap [ this . activeComponent ])
211
200
// if true add data section and populate with props
212
201
let data = " " ;
213
202
if (this .componentMap [this .activeComponent ].props .length ) {
@@ -246,21 +235,10 @@ export default {
246
235
247
236
let htmlArray = this .componentMap [componentName].htmlList ;
248
237
let styleString = " " ;
249
-
250
- if (this .activeComponentObj .htmlAttributes .class !== " " ) {
251
- styleString += ` .${ this .activeComponentObj .htmlAttributes .class } {\n background-color: ${ this .activeComponentObj .color } ;
252
- width: ${ this .activeComponentObj .w } px;
253
- height: ${ this .activeComponentObj .h } px;
254
- z-index: ${ this .activeComponentObj .z } px;
255
- }\n `
256
- }
257
-
258
238
for (const html of htmlArray) {
259
239
if (html .class === ' ' ) styleString = " " ;
260
240
if (html .class ) {
261
- console .log (this .activeComponentObj )
262
- styleString += ` .${ html .class } {\n
263
- }\n `
241
+ styleString += ` .${ html .class } {\n }\n `
264
242
}
265
243
}
266
244
@@ -352,17 +330,5 @@ z-index: ${this.activeComponentObj.z}px;
352
330
.prism-editor__textarea :focus {
353
331
outline : none ;
354
332
}
355
-
356
- .refreshCode {
357
- position : absolute ;
358
- background-color : black ;
359
- color : $secondary ;
360
- bottom : 96% ;
361
- right : 5% ;
362
- }
363
-
364
- .refreshCode :hover {
365
- cursor : pointer ;
366
- }
367
333
</style >
368
334
0 commit comments