@jx3box/jx3box-common-ui 5.4.9 → 5.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -162,11 +162,11 @@
162
162
  }
163
163
  .u-item {
164
164
  .size(60px);
165
- .u-txt {
166
- .pr;
167
- left:-3px;
168
- transform: scale(0.8);
169
- }
165
+ // .u-txt {
166
+ // .pr;
167
+ // left:-3px;
168
+ // transform: scale(0.8);
169
+ // }
170
170
  .u-pic {
171
171
  .size(28px);
172
172
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jx3box/jx3box-common-ui",
3
- "version": "5.4.9",
3
+ "version": "5.5.3",
4
4
  "description": "JX3BOX UI",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -33,7 +33,7 @@
33
33
  "@jx3box/jx3box-comment-ui": "^1.6.6",
34
34
  "@jx3box/jx3box-common": "^6.7.8",
35
35
  "@jx3box/jx3box-data": "^1.8.3",
36
- "@jx3box/jx3box-editor": "^1.1.2",
36
+ "@jx3box/jx3box-editor": "^1.1.7",
37
37
  "axios": "^0.19.2",
38
38
  "element-ui": "^2.13.2",
39
39
  "jquery": "^3.5.1",
package/src/Box.vue CHANGED
@@ -12,11 +12,11 @@
12
12
  <span class="u-txt">首页</span>
13
13
  </a>
14
14
  </li>
15
- <li v-for="(item,i) in data" :key="i" :class="{'u-app-start':item.lf}">
15
+ <li v-for="(item,i) in list" :key="i" :class="{'u-app-start':item.lf}">
16
16
  <a class="u-item" :href="item.href" :target="item.href | getTarget">
17
- <img class="u-pic" svg-inline :src="item.img | getBoxIcon" />
18
- <img class="u-pic-hover" svg-inline :src="item.hover | getBoxIcon" />
19
- <span class="u-txt">{{item.name}}</span>
17
+ <img class="u-pic" :src="item.img | getBoxIcon" />
18
+ <!-- <img class="u-pic-hover" svg-inline :src="item.hover | getBoxIcon" /> -->
19
+ <span class="u-txt">{{item.abbr}}</span>
20
20
  </a>
21
21
  </li>
22
22
  </ul>
@@ -56,8 +56,8 @@ export default {
56
56
  return __imgPath + "image/box/origin.svg";
57
57
  },
58
58
  list : function (){
59
- return this.data.map((item,i) => {
60
- return item.status && item.client == this.client
59
+ return this.data.filter((item,i) => {
60
+ return item.status && (item.client == this.client || item.client == 'all')
61
61
  })
62
62
  }
63
63
  },
@@ -100,7 +100,7 @@ export default {
100
100
  return __imgPath + "image/box/" + val;
101
101
  },
102
102
  getTarget: function (val) {
103
- if (window.innerWidth < 768 || val.startsWith("/")) {
103
+ if (window.innerWidth < 768 || val?.startsWith("/")) {
104
104
  return "_self";
105
105
  } else {
106
106
  return "_blank";
@@ -73,6 +73,9 @@ export default {
73
73
  };
74
74
  },
75
75
  computed: {
76
+ post_keys : function (){
77
+ return [this.postType,this.postId]
78
+ },
76
79
  params: function () {
77
80
  return {
78
81
  pageSize: this.per,
@@ -81,6 +84,13 @@ export default {
81
84
  },
82
85
  },
83
86
  watch: {
87
+ post_keys : {
88
+ immediate : true,
89
+ deep : true,
90
+ handler : function (){
91
+ this.postType && !!~~this.postId && this.loadData();
92
+ }
93
+ },
84
94
  params: {
85
95
  deep: true,
86
96
  handler: function () {
@@ -99,9 +109,6 @@ export default {
99
109
  }
100
110
  },
101
111
  methods: {
102
- init: function () {
103
- this.loadData();
104
- },
105
112
  loadData: function () {
106
113
  getPostBoxcoinRecords(this.postType, this.postId, this.params).then(
107
114
  (res) => {
@@ -138,9 +145,5 @@ export default {
138
145
  return showAvatar(val, 24);
139
146
  },
140
147
  },
141
- created: function () {},
142
- mounted: function () {
143
- this.init();
144
- },
145
148
  };
146
149
  </script>
@@ -52,8 +52,20 @@ export default {
52
52
  boxcoin_enable : 0
53
53
  };
54
54
  },
55
- computed: {},
56
- watch: {},
55
+ computed: {
56
+ post_keys : function (){
57
+ return [this.postId,this.postType]
58
+ }
59
+ },
60
+ watch: {
61
+ post_keys : {
62
+ immediate : true,
63
+ deep:true,
64
+ handler : function (){
65
+ this.postType && !!~~this.postId && this.loadBoxcoinConfig()
66
+ }
67
+ }
68
+ },
57
69
  methods: {
58
70
  loadBoxcoinConfig : function (){
59
71
  User.isLogin() && getPostBoxcoinConfig(this.postType).then((res) => {
@@ -80,15 +92,9 @@ export default {
80
92
  },
81
93
  }
82
94
  },
83
- init : function (){
84
- this.loadBoxcoinConfig()
85
- }
86
95
  },
87
96
  filters: {},
88
97
  created: function () {},
89
- mounted: function () {
90
- this.init()
91
- },
92
98
  };
93
99
  </script>
94
100