@jx3box/jx3box-editor 1.2.2 → 1.2.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.
- package/assets/css/resource.less +4 -3
- package/package.json +1 -1
- package/src/Resource.vue +24 -13
package/assets/css/resource.less
CHANGED
|
@@ -29,18 +29,19 @@
|
|
|
29
29
|
|
|
30
30
|
.u-item {
|
|
31
31
|
.db;
|
|
32
|
-
border:
|
|
32
|
+
border: 2px solid @border-hr;
|
|
33
33
|
background: #fafbfc;
|
|
34
34
|
margin-bottom: 10px;
|
|
35
35
|
padding: 10px 10px 10px 70px;
|
|
36
36
|
min-height: 60px;
|
|
37
|
-
.r(
|
|
37
|
+
.r(6px);
|
|
38
38
|
&:hover {
|
|
39
39
|
background-color: #e7f9ff;
|
|
40
40
|
}
|
|
41
41
|
&.on {
|
|
42
42
|
border-color: #34d058;
|
|
43
43
|
background-color: #fff;
|
|
44
|
+
box-shadow: 0 0 8px rgba(0, 0, 0, 0.2);
|
|
44
45
|
// &:hover{
|
|
45
46
|
// border:1px dashed #ddd;
|
|
46
47
|
// background-color:#eee;
|
|
@@ -95,7 +96,7 @@
|
|
|
95
96
|
.mb(5px);
|
|
96
97
|
.db;
|
|
97
98
|
|
|
98
|
-
.u-map, .u-life
|
|
99
|
+
.u-map, .u-life {
|
|
99
100
|
.mr(20px)
|
|
100
101
|
}
|
|
101
102
|
}
|
package/package.json
CHANGED
package/src/Resource.vue
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="c-resource">
|
|
3
3
|
<!-- 上传触发按钮 -->
|
|
4
|
-
<el-button class="u-switch" type="primary" @click="openDialog" :disabled="!enable"> <img class="u-icon" svg-inline src="../assets/img/jx3.svg"
|
|
4
|
+
<el-button class="u-switch" type="primary" @click="openDialog" :disabled="!enable"> <img class="u-icon" svg-inline src="../assets/img/jx3.svg" />插入资源 </el-button>
|
|
5
5
|
|
|
6
6
|
<!-- 弹出界面 -->
|
|
7
7
|
<el-dialog class="c-large-dialog" title="剑三数据库" :visible.sync="dialogVisible">
|
|
@@ -97,15 +97,19 @@
|
|
|
97
97
|
<i class="el-icon-s-data"></i> 共找到 <b>{{ item.length }}</b> 条记录
|
|
98
98
|
</p>
|
|
99
99
|
<ul class="m-resource-list" v-if="item.length">
|
|
100
|
-
<
|
|
101
|
-
<
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
100
|
+
<el-popover popper-class="m-item-pop" :visible-arrow="false" trigger="hover" placement="left" v-for="(o, i) in item" :key="i">
|
|
101
|
+
<li slot="reference" class="u-item" :class="{ on: o.isSelected }" @click="selectItem(o, i)" ref="item">
|
|
102
|
+
<span class="u-id">ID:{{ o.id }}</span>
|
|
103
|
+
<img class="u-pic" :title="'IconID:' + o.IconID" :src="iconURL(o.IconID)" />
|
|
104
|
+
<span class="u-name">{{ o.Name }}</span>
|
|
105
|
+
<span class="u-content" v-html="o.DescHtml"></span>
|
|
106
|
+
<span class="u-remark">
|
|
107
|
+
{{ o.Requirement }}
|
|
108
|
+
</span>
|
|
109
|
+
</li>
|
|
110
|
+
|
|
111
|
+
<jx3-item :item_id="o.id"></jx3-item>
|
|
112
|
+
</el-popover>
|
|
109
113
|
</ul>
|
|
110
114
|
<el-alert v-if="!item.length && done" title="没有找到相关条目" type="info" show-icon></el-alert>
|
|
111
115
|
</el-tab-pane>
|
|
@@ -193,12 +197,11 @@
|
|
|
193
197
|
</template>
|
|
194
198
|
|
|
195
199
|
<script>
|
|
196
|
-
import axios from "axios";
|
|
197
200
|
import { loadResource, loadStat, getIcons } from "../service/database";
|
|
198
201
|
import { __ossRoot, __iconPath, __Root, __OriginRoot } from "@jx3box/jx3box-common/data/jx3box.json";
|
|
199
202
|
import detach_types from "../assets/data/detach_type.json";
|
|
200
|
-
import User from "@jx3box/jx3box-common/js/user";
|
|
201
203
|
import { iconLink,getLink } from "@jx3box/jx3box-common/js/utils";
|
|
204
|
+
import Item from './Item.vue';
|
|
202
205
|
export default {
|
|
203
206
|
name: "Resource",
|
|
204
207
|
props: {
|
|
@@ -454,10 +457,18 @@ export default {
|
|
|
454
457
|
created: function() {
|
|
455
458
|
this.checkUA();
|
|
456
459
|
},
|
|
457
|
-
components: {
|
|
460
|
+
components: {
|
|
461
|
+
'jx3-item': Item
|
|
462
|
+
},
|
|
458
463
|
};
|
|
459
464
|
</script>
|
|
460
465
|
|
|
461
466
|
<style lang="less">
|
|
462
467
|
@import "../assets/css/resource.less";
|
|
468
|
+
|
|
469
|
+
.m-item-pop {
|
|
470
|
+
padding: 0 !important;
|
|
471
|
+
background: none !important;
|
|
472
|
+
border: none;
|
|
473
|
+
}
|
|
463
474
|
</style>
|