Browse Source

feat: 样式修改

cuiyalong 3 years ago
parent
commit
568611dc13

+ 1 - 0
src/App.vue

@@ -22,6 +22,7 @@ export default {
 <style lang="scss">
 @import "~@/assets/style/common.scss";
 @import "~@/assets/style/reset-ele.scss";
+@import "~@/assets/style/reset-qiankun.scss";
 .v-w1200 {
   width: 1200px;
   margin: 0 auto;

+ 8 - 0
src/assets/style/reset-qiankun.scss

@@ -0,0 +1,8 @@
+@import './_mixin';
+@import './_variables';
+
+.in-app {
+  .v-w1200 {
+    width: 100%;
+  }
+}

+ 1 - 0
src/components/common/ContentLayout.vue

@@ -115,6 +115,7 @@ export default {
     }
   }
   .content-main {
+    width: 100%;
     flex: 1;
     transition: .1s;
   }

+ 3 - 0
src/utils/globalDirectives.js

@@ -29,6 +29,8 @@ Vue.directive('auto-focus', {
 // 传入距离顶部高度x,当滚动高度大于x则添加fix定位
 Vue.directive('stickyed', {
   inserted (el, binding) {
+    const inApp = window.__POWERED_BY_QIANKUN__
+    if (inApp) return
     const $el = $(el)
     const conf = {
       className: ['fixed-nav'], // 置顶后添加的默认类名
@@ -54,6 +56,7 @@ Vue.directive('stickyed', {
       }
       el.windowScrollStickyEventCallback && el.windowScrollStickyEventCallback(el, conf)
     }
+
     window.addEventListener('scroll', el.handleWindowScrollStickyEvent, false)
   },
   unbind (el) {

+ 5 - 1
src/views/vipsubscribe/Buy.vue

@@ -670,7 +670,11 @@ export default {
       const { data, error_msg } = await this.submitXHR()
       if (data) {
         if (this.token) {
-          return window.close()
+          this.$toast('帮助用户下单成功')
+          setTimeout(() => {
+            history.back()
+          }, 1500)
+          return
         }
         const orderCode = data.order_code
         if (data.needPay) {

+ 11 - 9
src/views/vipsubscribe/components/Contrast.vue

@@ -295,6 +295,8 @@ export default {
     .contrast-main-center {
       display: flex;
       justify-content: center;
+      padding: 0 32px;
+      width: 100%;
       .gray {
         background: #F5F5FB;
       }
@@ -305,14 +307,14 @@ export default {
       /* 功能/价格 */
       /* li+li表示选中除第一个li其他所有的li */
       .center-left {
-        width: 468px;
+        flex: 4;
         & > ul {
-          width: 468px;
+          width: 100%;
           margin: 0;
           li + li {
             color: rgba(29, 29, 29, 1);
             padding-left: 24px;
-            width: 468px;
+            width: 100%;
             opacity: 1;
             border-left: 1px solid #ececec;
             border-bottom: 1px solid $border-color;
@@ -359,15 +361,15 @@ export default {
 
       // 免费版
       .center-center {
-        width: 336px;
+        flex: 3;
         transition: all 0.5s;
         & > ul {
-          width: 336px;
+          width: 100%;
           transition: all 0.5s;
           margin: 0;
           li + li {
             transition: all 0.5s;
-            width: 336px;
+            width: 100%;
             text-align: center;
             font-size: 14px;
             font-family: Microsoft YaHei;
@@ -449,17 +451,17 @@ export default {
 
       /* VIP订阅专属服务 */
       .center-right {
-        width: 336px;
+        flex: 3;
         transition: all 0.5s;
         border-right: 1px solid $border-color;
 
         & > ul {
-          width: 336px;
+          width: 100%;
           margin: 0;
           transition: all 0.5s;
 
           li + li {
-            width: 336px;
+            width: 100%;
             text-align: center;
             transition: all 0.5s;
             font-size: 14px;