Browse Source

Merge branch 'master' of http://192.168.4.246:3000/zhangs/surveyMaker

# Conflicts:
#	src/views/h5editor/index.vue
曹冬冬 5 năm trước cách đây
mục cha
commit
9409ce0eaf

+ 22 - 16
src/components/EditPanel.vue

@@ -4,25 +4,29 @@
       <div class="tab" @click="function () { panelTabState = 0 }">
         <div v-show="panelState === 11 || panelState === 14" class="selected-tab"
           :class="{ active: panelTabState === 0 }">
-          <img style="width:12px; height:15px; vertical-align: middle" src="../assets/images/tab-selected-icon.png"
+          <img style="width:12px; height:15px; vertical-align: middle"
+            :src="panelTabState === 0?'http://yun-image.elab-plus.com/images/dyb/tab-selected-txt.png':'http://yun-image.elab-plus.com/images/dyb/tab-unselected-txt.png'"
             alt="">
           <span class="tab-text">文本</span>
         </div>
         <div v-show="panelState === 12 || panelState === 13" class="selected-tab"
           :class="{ active: panelTabState === 0 }">
-          <img style="width:12px; height:15px; vertical-align: middle" src="../assets/images/tab-selected-icon.png"
+          <img style="width:12px; height:15px; vertical-align: middle"
+            :src="panelTabState === 0?'http://yun-image.elab-plus.com/images/dyb/tab-selected-element.png':'http://yun-image.elab-plus.com/images/dyb/tab-unselected-element.png'"
             alt="">
           <span class="tab-text">元素</span>
         </div>
         <div v-show="panelState === 15" class="selected-tab" :class="{ active: panelTabState === 0 }">
-          <img style="width:12px; height:15px; vertical-align: middle" src="../assets/images/tab-selected-icon.png"
+          <img style="width:12px; height:15px; vertical-align: middle"
+            :src="panelTabState === 0?'http://yun-image.elab-plus.com/images/dyb/tab-selected-txt.png':'http://yun-image.elab-plus.com/images/dyb/tab-unselected-txt.png'"
             alt="">
           <span class="tab-text">按钮</span>
         </div>
       </div>
       <div class="tab" @click="function () { panelTabState = 1 }">
         <div class="selected-tab" :class="{ active: panelTabState === 1 }">
-          <img style="width:14px; height:14px; vertical-align: middle" src="../assets/images/property-selected-icon.png"
+          <img style="width:14px; height:14px; vertical-align: middle"
+            :src="panelTabState === 1?'http://yun-image.elab-plus.com/images/dyb/tab-selected-property.png':'http://yun-image.elab-plus.com/images/dyb/tab-unselected-property.png'"
             alt="">
           <span class="tab-text">属性动作</span>
         </div>
@@ -163,7 +167,7 @@
               <div
                 :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','width':'100%', 'background': element.textAlign=='left'? 'white':''}">
                 <img style="width:62px;height:24px;"
-                  src="http://yun-image.elab-plus.com/images/dyb/icon_text_left.png" />
+                  :src="element.textAlign=='left'?'http://yun-image.elab-plus.com/images/dyb/icon_text_left_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_text_left.png'" />
               </div>
             </div>
             <div style="display: inline-flex; overflow: hidden;width: 30%; cursor: pointer;" title="居中"
@@ -171,7 +175,7 @@
               <div
                 :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','width':'100%', 'background': element.textAlign=='center'? 'white':''}">
                 <img style="width:62px;height:24px;"
-                  src="http://yun-image.elab-plus.com/images/dyb/icon_text_centered.png" />
+                  :src="element.textAlign=='center'? 'http://yun-image.elab-plus.com/images/dyb/icon_text_centered_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_text_centered.png'" />
               </div>
 
             </div>
@@ -180,7 +184,7 @@
               <div
                 :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','width':'100%', 'background': element.textAlign=='right'? 'white':''}">
                 <img style="width:62px;height:24px;"
-                  src="http://yun-image.elab-plus.com/images/dyb/icon_text_right.png" />
+                  :src="element.textAlign=='right'?'http://yun-image.elab-plus.com/images/dyb/icon_text_right_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_text_right.png'" />
               </div>
 
             </div>
@@ -191,7 +195,7 @@
                 :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','width':'100%', 'background': element.verticalAlign=='top'? 'white':''}"
                 @click="element.verticalAlign = 'top';element.display = 'table-cell'">
                 <img style="width:62px;height:24px;"
-                  src="http://yun-image.elab-plus.com/images/dyb/icon_text_top.png" />
+                  :src="element.verticalAlign=='top'?'http://yun-image.elab-plus.com/images/dyb/icon_text_top_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_text_top.png'" />
               </div>
             </div>
             <div style="display: inline-flex; overflow: hidden;width: 30%; cursor: pointer;" title="居中">
@@ -199,7 +203,7 @@
                 :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','width':'100%', 'background': element.verticalAlign=='middle'? 'white':''}"
                 @click="element.verticalAlign = 'middle';element.display = 'table-cell'">
                 <img style="width:62px;height:24px;"
-                  src="http://yun-image.elab-plus.com/images/dyb/icon_text_centered.png" />
+                  :src="element.verticalAlign=='middle'?'http://yun-image.elab-plus.com/images/dyb/icon_text_centered_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_text_centered.png'" />
               </div>
 
             </div>
@@ -208,7 +212,7 @@
               <div
                 :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','width':'100%', 'background': element.verticalAlign=='bottom'? 'white':''}">
                 <img style="width:62px;height:24px;"
-                  src="http://yun-image.elab-plus.com/images/dyb/icon_text_bottom.png" />
+                  :src="element.verticalAlign=='bottom'?'http://yun-image.elab-plus.com/images/dyb/icon_text_bottom_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_text_bottom.png'" />
               </div>
 
             </div>
@@ -216,8 +220,7 @@
 
         </div>
 
-        <div style="text-align: center;border-bottom: #E2E4EE solid 1px;padding-top: 12px;padding-bottom: 12px;"
-          v-show="panelState!=15">
+        <div style="text-align: center;border-bottom: #E2E4EE solid 1px;padding-top: 12px;padding-bottom: 12px;">
           <div style="width:100%; display: flex;flex-direction: row">
             <div
               style="display: inline-flex; overflow: hidden;cursor: pointer;width:50%;justify-content: left; margin-left: 20px;">
@@ -356,14 +359,15 @@
           display: inline-block;
           text-align: center;
           line-height: 24px;
-          color:rgba(255,255,255,1);" @click="setGroup(element)">复制</div>
+          color:rgba(255,255,255,1);">复制</div>
           </div>
 
           <div style="display: inline-flex; overflow: hidden; cursor: pointer; text-align: left;width: 23%">
             <div title="左对齐"
               :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','text-align':'center','width':'100%', 'background': element.left=='0'? 'white':''}"
               @click="element.left = '0';">
-              <img style="width: 44px; height:24px;" src="http://yun-image.elab-plus.com/images/dyb/icon_left.png" />
+              <img style="width: 44px; height:24px;"
+                :src="element.left=='0'?'http://yun-image.elab-plus.com/images/dyb/icon_left_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_left.png'" />
             </div>
 
           </div>
@@ -371,7 +375,8 @@
             @click="element.left = 375-element.width/2;">
             <div
               :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','text-align':'center','width':'100%', 'background': element.left==375-element.width/2? 'white':''}">
-              <img style="width: 44px; height:24px;" src="http://yun-image.elab-plus.com/images/dyb/icon_center.png" />
+              <img style="width: 44px; height:24px;"
+                :src="element.left==375-element.width/2?'http://yun-image.elab-plus.com/images/dyb/icon_center_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_center.png'" />
             </div>
 
           </div>
@@ -379,7 +384,8 @@
             @click="element.left = 750-element.width;">
             <div
               :style="{'font-size': '12px','letter-spacing': 0, 'word-break':'keep-all','text-align':'center','width':'100%', 'background': element.left==750-element.width? 'white':''}">
-              <img style="width: 44px; height:24px;" src="http://yun-image.elab-plus.com/images/dyb/icon_left.png" />
+              <img style="width: 44px; height:24px;"
+                :src="element.left==750-element.width?'http://yun-image.elab-plus.com/images/dyb/icon_left_active.png':'http://yun-image.elab-plus.com/images/dyb/icon_left.png'" />
             </div>
           </div>
         </div>

+ 1 - 0
src/components/Element/ButtonElement.vue

@@ -308,6 +308,7 @@
       styleBasic () {
         return {
           width: this.element['width'] + 'px',
+          height: this.element['height'] + 'px',
           lineHeight: this.element['lineHeight'],
           color: this.element['color'],
           backgroundColor: this.element['allTransparent'] || this.element['backgroundColor'],

+ 1 - 1
src/views/spaeditor/index.vue

@@ -857,7 +857,7 @@ export default {
     left: -50px;
     top: 0;
     width: 50px;
-    .func {
+    .func { 
       color: #b2bcba;
       background: #fff;
       cursor: pointer;