wiki增加导航和拖动改变左侧菜单宽度功能,编辑器默认改为markdown模式

This commit is contained in:
暮光:城中城
2021-12-02 23:18:31 +08:00
parent af645464e4
commit 22a73b445a
28 changed files with 502 additions and 353 deletions

View File

@@ -2,8 +2,8 @@
ENV = 'development' ENV = 'development'
# base api # base api
VUE_APP_BASE_API = 'http://local.zyplayer.com:8083/zyplayer-doc-manage' # VUE_APP_BASE_API = 'http://local.zyplayer.com:8083/zyplayer-doc-manage'
# VUE_APP_BASE_API = 'http://doc.zyplayer.com/zyplayer-doc-manage' VUE_APP_BASE_API = 'http://doc.zyplayer.com/zyplayer-doc-manage'
VUE_CLI_BABEL_TRANSPILE_MODULES = true VUE_CLI_BABEL_TRANSPILE_MODULES = true

View File

@@ -0,0 +1,115 @@
export default {
/**
* 生成目录树
* ========================================================
* 说明:代码修改至 yaohaixiao 的 autoc.js
* 项目 gitee 地址https://gitee.com/yaohaixiao/AutocJS
* ========================================================
*/
createNavigationHeading() {
let headArr = [];
let headNodeArr = document.querySelector('.wiki-page-content').querySelectorAll('h1,h2,h3,h4,h5,h6');
if (headNodeArr.length <= 0) {
return [];
}
headNodeArr.forEach(node => {
headArr.push({
node: node,
level: parseInt(node.tagName.replace(/[h]/i, ''), 10)
});
});
let chapters = []
let previous = 1
let level = 0
headArr.forEach((heading, i) => {
let current = heading.level
let pid = -1
// 当前标题的(标题标签)序号 > 前一个标题的序号:两个相连的标题是父标题 -> 子标题关系;
// h2 (前一个标题)
// h3 (当前标题)
if (current > previous) {
level += 1
// 第一层级的 pid 是 -1
if (level === 1) {
pid = -1
} else {
pid = i - 1
}
}
// 当前标题的(标题标签)序号 = 前一个标题的序号
// h2 (前一个标题)
// h2 (当前标题)
// 当前标题的(标题标签)序号 < 前一个标题的序号,并且当前标题序号 > 当前的级别
// h2
// h4 (前一个标题)
// h3 (当前标题:这种情况我们还是任务 h3 是 h2 的下一级章节)
else if (current === previous || (current < previous && current > level)) {
// H1 的层级肯定是 1
if (current === 1) {
level = 1
pid = -1
} else {
pid = chapters[i - 1].pid
}
} else if (current <= level) {
// H1 的层级肯定是 1
if (current === 1) {
level = 1
} else {
level = level - (previous - current)
if (level <= 1) {
level = 1
}
}
// 第一级的标题
if (level === 1) {
pid = -1
} else {
// 虽然看上去差点,不过能工作啊
pid = this.generatePid(chapters, previous - current, i)
}
}
previous = current
chapters.push({
id: i,
pid: pid,
level: level,
node: heading.node,
text: this.stripTags(this.trim(heading.node.innerHTML))
});
})
console.log(chapters);
return chapters;
},
trim: (str) => {
return str.replace(/^\s+/g, '').replace(/\s+$/g, '')
},
stripTags: (str) => {
return str.replace(/<\/?[^>]+(>|$)/g, '')
},
generatePid(chapters, differ, index) {
let pid
// 最大只有 5 级的差距
switch (differ) {
case 2:
pid = chapters[chapters[chapters[index - 1].pid].pid].pid
break
case 3:
pid = chapters[chapters[chapters[chapters[index - 1].pid].pid].pid].pid
break
case 4:
pid = chapters[chapters[chapters[chapters[chapters[index - 1].pid].pid].pid].pid].pid
break
case 5:
pid = chapters[chapters[chapters[chapters[chapters[chapters[index - 1].pid].pid].pid].pid].pid].pid
break
default:
pid = chapters[chapters[index - 1].pid].pid
break
}
return pid
},
}

View File

@@ -0,0 +1,26 @@
export default {
computeFileSize(fileSize) {
if (!fileSize) {
return '-';
}
let size = "";
if (fileSize < 0.1 * 1024) {
size = fileSize.toFixed(2) + "B"
} else if (fileSize < 0.1 * 1024 * 1024) {
size = (fileSize / 1024).toFixed(2) + "KB"
} else if (fileSize < 0.1 * 1024 * 1024 * 1024) {
size = (fileSize / (1024 * 1024)).toFixed(2) + "MB"
} else {
size = (fileSize / (1024 * 1024 * 1024)).toFixed(2) + "GB"
}
let sizeStr = size + "";
let index = sizeStr.indexOf(".");
let dou = sizeStr.substr(index + 1, 2);
if (dou == "00") {
return sizeStr.substring(0, index) + sizeStr.substr(index + 3, 2)
}
return size;
},
}

View File

@@ -1,90 +0,0 @@
import vue from '../../main'
export default {
data: {
accessToken: '',
},
setAccessToken: function (token) {
this.data.accessToken = token;
},
getAccessToken: function () {
if (!this.data.accessToken) {
var arr, reg = new RegExp("(^| )accessToken=([^;]*)(;|$)");
if (arr = document.cookie.match(reg)) {
this.data.accessToken = unescape(arr[2]);
}
}
return this.data.accessToken;
},
validateResult: function (res) {
return new Promise(function (resolve, reject) {
if (!!res.message) {
vue.$message('请求错误:' + res.message);
} else if (res.data.errCode == 400) {
vue.$message('请先登录');
var href = encodeURIComponent(window.location.href);
window.location = process.env.VUE_APP_BASE_API + "#/user/login?redirect=" + href;
} else if (res.data.errCode == 402) {
vue.$router.push("/common/noAuth");
} else if (res.data.errCode !== 200) {
vue.$message(res.data.errMsg || "未知错误");
} else {
resolve(res.data);
}
});
},
/**
* 返回不为空的字符串为空返回def
*/
getNotEmptyStr(str, def) {
if (isEmpty(str)) {
return isEmpty(def) ? "" : def;
}
return str;
},
/**
* 是否是空对象
* @param obj
* @returns
*/
isEmptyObject(obj) {
return isEmpty(obj) || $.isEmptyObject(obj);
},
/**
* 是否是空字符串
* @param str
* @returns
*/
isEmpty(str) {
return (str == "" || str == null || str == undefined);
},
/**
* 是否不是空字符串
* @param str
* @returns
*/
isNotEmpty(str) {
return !isEmpty(str);
},
/**
* param 将要转为URL参数字符串的对象
* key URL参数字符串的前缀
* encode true/false 是否进行URL编码,默认为true
* return URL参数字符串
*/
objUrlEncode(param, key, encode) {
if (param == null) return '';
var paramStr = '';
var t = typeof (param);
if (t == 'string' || t == 'number' || t == 'boolean') {
paramStr += '&' + key + '=' + ((encode == null || encode) ? encodeURIComponent(param) : param);
} else {
for (var i in param) {
var k = key == null ? i : key + (param instanceof Array ? '[' + i + ']' : '.' + i);
paramStr += urlEncode(param[i], k, encode);
}
}
return paramStr;
}
}

View File

@@ -1,7 +1,7 @@
<template> <template>
<div class="global-layout-vue"> <div class="global-layout-vue">
<el-container> <el-container>
<el-aside v-show="leftCollapse"> <el-aside v-show="leftCollapse" :style="{ width: rightAsideWidth + 'px' }">
<div style="padding: 10px;height: 100%;box-sizing: border-box;background: #fafafa;"> <div style="padding: 10px;height: 100%;box-sizing: border-box;background: #fafafa;">
<div style="margin-bottom: 10px;"> <div style="margin-bottom: 10px;">
<el-select :value="choiceSpace" @change="spaceChangeEvents" filterable placeholder="选择空间" style="width: 100%;"> <el-select :value="choiceSpace" @change="spaceChangeEvents" filterable placeholder="选择空间" style="width: 100%;">
@@ -31,10 +31,11 @@
</div> </div>
</div> </div>
</el-aside> </el-aside>
<RightResize v-model="rightAsideWidth" v-show="leftCollapse"></RightResize>
<el-container> <el-container>
<el-header> <el-header>
<i class="el-icon-upload2" v-if="leftCollapse" @click="turnLeftCollapse"></i> <i class="el-icon-fold el-icon-s-fold" v-if="leftCollapse" @click="turnLeftCollapse"></i>
<i class="el-icon-download" v-else @click="turnLeftCollapse"></i> <i class="el-icon-fold el-icon-s-unfold" v-else @click="turnLeftCollapse"></i>
<span class="header-right-user-name">{{userSelfInfo.userName}}</span> <span class="header-right-user-name">{{userSelfInfo.userName}}</span>
<el-popover placement="bottom" width="600" trigger="click" v-model="userMessagePopVisible"> <el-popover placement="bottom" width="600" trigger="click" v-model="userMessagePopVisible">
<el-badge :is-dot="haveNotReadUserMessage" slot="reference" style="line-height: 20px;margin: 0 15px;"> <el-badge :is-dot="haveNotReadUserMessage" slot="reference" style="line-height: 20px;margin: 0 15px;">
@@ -98,6 +99,7 @@
import userApi from '../../common/api/user' import userApi from '../../common/api/user'
import pageApi from '../../common/api/page' import pageApi from '../../common/api/page'
import CreateSpace from '../space/CreateSpace' import CreateSpace from '../space/CreateSpace'
import RightResize from './RightResize.vue'
import aboutDialog from "../../views/common/AboutDialog"; import aboutDialog from "../../views/common/AboutDialog";
export default { export default {
@@ -134,9 +136,11 @@
pageNum: 1, pageNum: 1,
pageSize: 20, pageSize: 20,
}, },
rightAsideWidth: 300,
} }
}, },
components: { components: {
RightResize,
"create-space": CreateSpace, "create-space": CreateSpace,
'about-dialog': aboutDialog 'about-dialog': aboutDialog
}, },
@@ -376,8 +380,8 @@
} }
.header-right-user-name{color: #fff;padding-right: 5px;} .header-right-user-name{color: #fff;padding-right: 5px;}
.el-header {color: #333; line-height: 40px; text-align: right;height: 40px !important;} .el-header {color: #333; line-height: 40px; text-align: right;height: 40px !important;}
.el-icon-download,.el-icon-upload2{transform: rotate(-90deg);float: left;font-size: 25px;color: #aaa;margin-top: 8px;cursor: pointer;} .el-icon-fold{float: left;font-size: 25px;color: #aaa;margin-top: 8px;cursor: pointer;}
.el-icon-download:hover,.el-icon-upload2:hover{color: #eee;} .el-icon-fold:hover{color: #eee;}
.head-icon{margin-right: 15px; font-size: 16px;cursor: pointer;color: #fff;} .head-icon{margin-right: 15px; font-size: 16px;cursor: pointer;color: #fff;}
.header-user-message .page-info-box{text-align: right;margin-top: 10px;} .header-user-message .page-info-box{text-align: right;margin-top: 10px;}
.upgrade-info{max-height: 150px;overflow-y: auto;word-break: break-all; white-space: pre-wrap; line-height: 26px;} .upgrade-info{max-height: 150px;overflow-y: auto;word-break: break-all; white-space: pre-wrap; line-height: 26px;}

View File

@@ -0,0 +1,76 @@
<template>
<div ref="rightResize" class="right-resize">
<i ref="rightResizeBar">...</i>
</div>
</template>
<script>
export default {
data() {
return {
rightAsideWidth: 300,
}
},
mounted() {
this.dragChangeRightAsideWidth();
},
methods: {
dragChangeRightAsideWidth() {
// 保留this引用
let resize = this.$refs.rightResize;
let resizeBar = this.$refs.rightResizeBar;
resize.onmousedown = e => {
let startX = e.clientX;
// 颜色改变提醒
resize.style.background = "#ccc";
resizeBar.style.background = "#aaa";
resize.left = resize.offsetLeft;
document.onmousemove = e2 => {
// 计算并应用位移量
let endX = e2.clientX;
let moveLen = startX - endX;
if ((moveLen < 0 && this.rightAsideWidth < 600) || (moveLen > 0 && this.rightAsideWidth > 300)) {
startX = endX;
this.rightAsideWidth -= moveLen;
if (this.rightAsideWidth < 300) {
this.rightAsideWidth = 300;
}
this.$emit('input', this.rightAsideWidth);
}
};
document.onmouseup = () => {
// 颜色恢复
resize.style.background = "#fafafa";
resizeBar.style.background = "#ccc";
document.onmousemove = null;
document.onmouseup = null;
};
return false;
};
}
}
};
</script>
<style scoped>
.right-resize {
width: 5px;
height: 100%;
cursor: w-resize;
background: #fafafa;
}
.right-resize i {
margin-top: 300px;
width: 5px;
height: 35px;
display: inline-block;
word-wrap: break-word;
word-break: break-all;
line-height: 8px;
border-radius: 5px;
background: #ccc;
color: #888;
}
</style>

View File

@@ -1,7 +1,7 @@
<template> <template>
<div style="height: 100%;"> <div style="height: 100%;">
<el-container> <el-container>
<el-aside width="300px" style="background-color: #fafafa;" v-show="leftCollapse"> <el-aside width="300px" style="background-color: #fafafa;" :style="{ width: rightAsideWidth + 'px' }" v-show="leftCollapse">
<div class="logo">{{nowSpaceShow.name}}</div> <div class="logo">{{nowSpaceShow.name}}</div>
<div style="padding: 10px;box-sizing: border-box;background: #fafafa;"> <div style="padding: 10px;box-sizing: border-box;background: #fafafa;">
<el-input v-model="searchKeywords" @keyup.enter.native="searchByKeywords" placeholder="搜索文档" style="margin: 10px 0;"> <el-input v-model="searchKeywords" @keyup.enter.native="searchByKeywords" placeholder="搜索文档" style="margin: 10px 0;">
@@ -17,6 +17,7 @@
<div class="build-info">本文档使用<a target="_blank" href="https://gitee.com/zyplayer/zyplayer-doc">zyplayer-doc</a>构建</div> <div class="build-info">本文档使用<a target="_blank" href="https://gitee.com/zyplayer/zyplayer-doc">zyplayer-doc</a>构建</div>
</div> </div>
</el-aside> </el-aside>
<RightResize v-model="rightAsideWidth" v-show="leftCollapse"></RightResize>
<el-container> <el-container>
<el-main class="doc-body-box"> <el-main class="doc-body-box">
<router-view></router-view> <router-view></router-view>
@@ -28,6 +29,7 @@
<script> <script>
import pageApi from '../../common/api/page' import pageApi from '../../common/api/page'
import RightResize from './RightResize.vue'
export default { export default {
data() { data() {
@@ -46,8 +48,10 @@
// 页面展示相关 // 页面展示相关
wikiPageList:[], wikiPageList:[],
wikiPageExpandedKeys: [], wikiPageExpandedKeys: [],
rightAsideWidth: 300,
} }
}, },
components: {RightResize},
mounted: function () { mounted: function () {
this.spaceUuid = this.$route.query.space || ''; this.spaceUuid = this.$route.query.space || '';
this.getSpaceInfo(); this.getSpaceInfo();

View File

@@ -6,8 +6,8 @@
<template v-if="pageId"> <template v-if="pageId">
<span>编辑方式</span> <span>编辑方式</span>
<el-select v-model="wikiPageEdit.editorType" v-on:change="editorTypeChange" :disabled="!!pageId"> <el-select v-model="wikiPageEdit.editorType" v-on:change="editorTypeChange" :disabled="!!pageId">
<el-option label="HTML" :value="1"></el-option>
<el-option label="Markdown" :value="2"></el-option> <el-option label="Markdown" :value="2"></el-option>
<el-option label="HTML" :value="1"></el-option>
</el-select> </el-select>
</template> </template>
<template v-else> <template v-else>
@@ -17,8 +17,8 @@
</el-tooltip> </el-tooltip>
<span style="margin-left: 50px;">编辑方式</span> <span style="margin-left: 50px;">编辑方式</span>
<el-select v-model="wikiPageEdit.editorType" v-on:change="editorTypeChange" :disabled="!!pageId"> <el-select v-model="wikiPageEdit.editorType" v-on:change="editorTypeChange" :disabled="!!pageId">
<el-option label="HTML" :value="1"></el-option>
<el-option label="Markdown" :value="2"></el-option> <el-option label="Markdown" :value="2"></el-option>
<el-option label="HTML" :value="1"></el-option>
</el-select> </el-select>
</template> </template>
</el-col> </el-col>
@@ -54,7 +54,7 @@
editor: {}, editor: {},
// 编辑相关 // 编辑相关
wikiPageEdit: { wikiPageEdit: {
editorType: 1, editorType: 2,
pageTitle: "", pageTitle: "",
}, },
wikiPage: {}, wikiPage: {},

View File

@@ -2,85 +2,89 @@
<div class="page-show-vue"> <div class="page-show-vue">
<el-row type="border-card" style="height: 100%;"> <el-row type="border-card" style="height: 100%;">
<el-col :span="actionTabVisible?18:24" style="padding: 20px;border-right: 1px solid #f1f1f1;height: 100%;overflow: auto;"> <el-col :span="actionTabVisible?18:24" style="padding: 20px;border-right: 1px solid #f1f1f1;height: 100%;overflow: auto;">
<div style="max-width: 1000px;margin: 0 auto;"> <el-row>
<div class="wiki-title">{{wikiPage.name}}</div> <el-col :xs="0" :sm="4" :md="4" :lg="6" :xl="6" v-if="navigationList.length > 0">
<div class="wiki-author"> <Navigation :heading="navigationList"></Navigation>
<div> </el-col>
<span v-if="wikiPage.updateUserName">{{wikiPage.updateUserName}}  {{wikiPage.updateTime}} 修改</span> <el-col :xs="24" :sm="navigationList.length > 0?20:24" :md="navigationList.length > 0?20:24" :lg="navigationList.length > 0?18:24" :xl="navigationList.length > 0?18:24">
<span v-else class="create-user-time">{{wikiPage.createUserName}}  {{wikiPage.createTime}} 创建</span> <div style="max-width: 1000px;margin: 0 auto;padding-left: 10px;">
<div style="float: right;"> <div class="wiki-title" ref="wikiTitle">{{wikiPage.name}}</div>
<el-button type="text" icon="el-icon-chat-line-round" @click="showCommentWiki" style="margin-right: 10px;">评论</el-button> <div class="wiki-author">
<el-upload v-if="wikiPageAuth.canUploadFile==1" <div>
class="upload-page-file" :action="uploadFileUrl" <span v-if="wikiPage.updateUserName">{{wikiPage.updateUserName}}  {{wikiPage.updateTime}} 修改</span>
:with-credentials="true" <span v-else class="create-user-time">{{wikiPage.createUserName}}  {{wikiPage.createTime}} 创建</span>
:on-success="uploadFileSuccess" :on-error="uploadFileError" <div style="float: right;">
name="files" show-file-list multiple :data="uploadFormData" :limit="999" <el-button type="text" icon="el-icon-chat-line-round" @click="showCommentWiki" style="margin-right: 10px;">评论</el-button>
style="display: inline;margin-right: 10px;"> <el-upload v-if="wikiPageAuth.canUploadFile==1"
<el-button type="text" icon="el-icon-upload">上传附件</el-button> class="upload-page-file" :action="uploadFileUrl"
</el-upload> :with-credentials="true"
<el-button v-if="wikiPageAuth.canEdit==1" type="text" icon="el-icon-edit" @click="editWiki">编辑</el-button> :on-success="uploadFileSuccess" :on-error="uploadFileError"
<el-dropdown style="margin-left: 10px;" @command="handleMoreCommand"> name="files" show-file-list multiple :data="uploadFormData" :limit="999"
<el-button type="text"> style="display: inline;margin-right: 10px;">
更多<i class="el-icon-arrow-down el-icon--right"></i> <el-button type="text" icon="el-icon-upload">上传附件</el-button>
</el-button> </el-upload>
<el-dropdown-menu slot="dropdown"> <el-button v-if="wikiPageAuth.canEdit==1" type="text" icon="el-icon-edit" @click="editWiki">编辑</el-button>
<el-dropdown-item command="showPageHistory" icon="el-icon-time">查看历史版本</el-dropdown-item> <el-dropdown style="margin-left: 10px;" @command="handleMoreCommand">
<el-dropdown-item command="deletePage" v-if="wikiPageAuth.canDelete==1" icon="el-icon-delete">删除</el-dropdown-item> <el-button type="text">
<el-dropdown-item command="editAuth" v-if="wikiPageAuth.canConfigAuth==1" icon="el-icon-s-check">权限设置</el-dropdown-item> 更多<i class="el-icon-arrow-down el-icon--right"></i>
<el-dropdown-item command="showOpenPage" v-if="spaceInfo.openDoc == 1" icon="el-icon-share">查看开放文档</el-dropdown-item> </el-button>
<el-dropdown-item command="showMobileView" v-if="spaceInfo.openDoc == 1" icon="el-icon-mobile-phone">手机端查看</el-dropdown-item> <el-dropdown-menu slot="dropdown">
</el-dropdown-menu> <el-dropdown-item command="showPageHistory" icon="el-icon-time">查看历史版本</el-dropdown-item>
</el-dropdown> <el-dropdown-item command="deletePage" v-if="wikiPageAuth.canDelete==1" icon="el-icon-delete">删除</el-dropdown-item>
<el-dropdown-item command="editAuth" v-if="wikiPageAuth.canConfigAuth==1" icon="el-icon-s-check">权限设置</el-dropdown-item>
<el-dropdown-item command="showOpenPage" v-if="spaceInfo.openDoc == 1" icon="el-icon-share">查看开放文档</el-dropdown-item>
<el-dropdown-item command="showMobileView" v-if="spaceInfo.openDoc == 1" icon="el-icon-mobile-phone">手机端查看</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</div>
</div>
<div class="wiki-files">
<el-table v-show="pageFileList.length > 0" :data="pageFileList" border style="width: 100%; margin-bottom: 5px;">
<el-table-column label="文件名">
<template slot-scope="scope">
<a target="_blank" :href="scope.row.fileUrl">{{scope.row.fileName}}</a>
</template>
</el-table-column>
<el-table-column prop="createUserName" label="创建人"></el-table-column>
<el-table-column label="文件大小">
<template slot-scope="scope">{{computeFileSize(scope.row.fileSize)}}</template>
</el-table-column>
<el-table-column prop="createTime" label="创建时间" width="180px"></el-table-column>
<el-table-column prop="downloadNum" label="下载次数" width="80px"></el-table-column>
<el-table-column label="操作" width="100px" v-if="wikiPageAuth.canDeleteFile==1">
<template slot-scope="scope">
<el-button size="small" v-on:click="deletePageFile(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
</div>
<div ref="pageContent" class="wiki-page-content">
<div v-html="pageShowDetail" class="markdown-body" v-if="wikiPage.editorType == 2" v-highlight></div>
<div v-html="pageShowDetail" class="wang-editor-body" v-else></div>
</div>
<div style="margin-top: 40px; font-size: 14px;">
<span style="vertical-align: top;" class="is-link">
<span v-show="wikiPage.selfZan == 0" v-on:click="zanPage(1)"><img src="../../assets/img/zan.png" style="vertical-align: middle;"> </span>
<span v-show="wikiPage.selfZan == 1" v-on:click="zanPage(0)"><img src="../../assets/img/zan.png" style="vertical-align: middle;transform: rotateX(180deg);"> </span>
</span>
<span style="margin-left: 10px;vertical-align: top;">
<span v-if="wikiPage.selfZan == 0 && wikiPage.zanNum <= 0">成为第一个赞同者</span>
<span v-else-if="wikiPage.selfZan == 0 && wikiPage.zanNum > 0">
<span class="is-link" v-on:click="showZanPageUser">{{wikiPage.zanNum}}</span>赞了它
</span>
<span v-else-if="wikiPage.selfZan == 1 && wikiPage.zanNum <= 1">我赞了它</span>
<span v-else-if="wikiPage.selfZan == 1 && wikiPage.zanNum > 1">
<span class="is-link" v-on:click="showZanPageUser">我和{{wikiPage.zanNum-1}}个其他人</span>赞了它
</span>
</span>
<span style="margin-left: 10px;">
<i class="el-icon-view" style="font-size: 16px;color: #666;"></i> {{wikiPage.viewNum}}次阅读
</span>
</div> </div>
</div> </div>
</div> </el-col>
<div class="wiki-files"> </el-row>
<el-table v-show="pageFileList.length > 0" :data="pageFileList" border style="width: 100%; margin-bottom: 5px;">
<el-table-column label="文件名">
<template slot-scope="scope">
<a target="_blank" :href="scope.row.fileUrl">{{scope.row.fileName}}</a>
</template>
</el-table-column>
<el-table-column prop="createUserName" label="创建人"></el-table-column>
<el-table-column label="文件大小">
<template slot-scope="scope">{{computeFileSize(scope.row.fileSize)}}</template>
</el-table-column>
<el-table-column prop="createTime" label="创建时间" width="180px"></el-table-column>
<el-table-column prop="downloadNum" label="下载次数" width="80px"></el-table-column>
<el-table-column label="操作" width="100px" v-if="wikiPageAuth.canDeleteFile==1">
<template slot-scope="scope">
<el-button size="small" v-on:click="deletePageFile(scope.row)">删除</el-button>
</template>
</el-table-column>
</el-table>
</div>
<div ref="pageContent" class="wiki-page-content">
<!-- <mavon-editor v-if="wikiPage.editorType == 2" ref="mavonEditor" :editable="false"-->
<!-- :subfield="false" defaultOpen="preview" v-model="pageShowDetail"-->
<!-- :toolbars="markdownToolbars"-->
<!-- :externalLink="false" v-highlight-->
<!-- :boxShadow="false"-->
<!-- class="page-content-editor wang-editor-body"-->
<!-- />-->
<div v-html="pageShowDetail" class="markdown-body" v-if="wikiPage.editorType == 2" v-highlight></div>
<div v-html="pageShowDetail" class="wang-editor-body" v-else></div>
</div>
<div style="margin-top: 40px; font-size: 14px;">
<span style="vertical-align: top;" class="is-link">
<span v-show="wikiPage.selfZan == 0" v-on:click="zanPage(1)"><img src="../../assets/img/zan.png" style="vertical-align: middle;"> </span>
<span v-show="wikiPage.selfZan == 1" v-on:click="zanPage(0)"><img src="../../assets/img/zan.png" style="vertical-align: middle;transform: rotateX(180deg);"> </span>
</span>
<span style="margin-left: 10px;vertical-align: top;">
<span v-if="wikiPage.selfZan == 0 && wikiPage.zanNum <= 0">成为第一个赞同者</span>
<span v-else-if="wikiPage.selfZan == 0 && wikiPage.zanNum > 0"><span class="is-link" v-on:click="showZanPageUser">{{wikiPage.zanNum}}</span>赞了它</span>
<span v-else-if="wikiPage.selfZan == 1 && wikiPage.zanNum <= 1">我赞了它</span>
<span v-else-if="wikiPage.selfZan == 1 && wikiPage.zanNum > 1"><span class="is-link" v-on:click="showZanPageUser">我和{{wikiPage.zanNum-1}}个其他人</span>赞了它</span>
</span>
<span style="margin-left: 10px;">
<i class="el-icon-view" style="font-size: 16px;color: #666;"></i> {{wikiPage.viewNum}}次阅读
</span>
</div>
</div>
</el-col> </el-col>
<el-col :span="6" style="height: 100%;" v-show="actionTabVisible"> <el-col :span="6" style="height: 100%;" v-show="actionTabVisible">
<i class="el-icon-close close-action-tab" @click="closeActionTab"></i> <i class="el-icon-close close-action-tab" @click="closeActionTab"></i>
@@ -187,13 +191,16 @@
<script> <script>
import QRCode from 'qrcodejs2' import QRCode from 'qrcodejs2'
import common from '../../common/lib/common' import unitUtil from '../../common/lib/UnitUtil.js'
import htmlUtil from '../../common/lib/HtmlUtil.js'
import pageApi from '../../common/api/page' import pageApi from '../../common/api/page'
import userApi from '../../common/api/user' import userApi from '../../common/api/user'
import Navigation from './components/Navigation.vue'
import {mavonEditor, markdownIt} from 'mavon-editor' import {mavonEditor, markdownIt} from 'mavon-editor'
import ElImageViewer from 'element-ui/packages/image/src/image-viewer' import ElImageViewer from 'element-ui/packages/image/src/image-viewer'
import 'mavon-editor/dist/markdown/github-markdown.min.css' import 'mavon-editor/dist/markdown/github-markdown.min.css'
import 'mavon-editor/dist/css/index.css' import 'mavon-editor/dist/css/index.css'
import vue from "../../main";
var page = { var page = {
colorArr: ["#67C23A", "#409EFF", "#E6A23C", "#F56C6C", "#909399", "#303133"], colorArr: ["#67C23A", "#409EFF", "#E6A23C", "#F56C6C", "#909399", "#303133"],
@@ -201,7 +208,7 @@
}; };
export default { export default {
props: ['spaceInfo'], props: ['spaceInfo'],
components: {'el-image-viewer': ElImageViewer, mavonEditor}, components: {'el-image-viewer': ElImageViewer, mavonEditor, Navigation},
data() { data() {
return { return {
// 页面展示相关 // 页面展示相关
@@ -236,6 +243,8 @@
pageHistoryChoice: {}, pageHistoryChoice: {},
pageHistoryList: [], pageHistoryList: [],
pageHistoryPageNum: 1, pageHistoryPageNum: 1,
// 左侧导航菜单
navigationList: [],
// 大图预览 // 大图预览
previewInitialIndex: 0, previewInitialIndex: 0,
showImagePreview: false, showImagePreview: false,
@@ -459,26 +468,7 @@
this.pageShowDetail = this.pageContent.content; this.pageShowDetail = this.pageContent.content;
}, },
computeFileSize(fileSize) { computeFileSize(fileSize) {
if (!fileSize) { return unitUtil.computeFileSize(fileSize);
return '-';
}
let size = "";
if (fileSize < 0.1 * 1024) {
size = fileSize.toFixed(2) + "B"
} else if (fileSize < 0.1 * 1024 * 1024) {
size = (fileSize / 1024).toFixed(2) + "KB"
} else if (fileSize < 0.1 * 1024 * 1024 * 1024) {
size = (fileSize / (1024 * 1024)).toFixed(2) + "MB"
} else {
size = (fileSize / (1024 * 1024 * 1024)).toFixed(2) + "GB"
}
let sizeStr = size + "";
let index = sizeStr.indexOf(".");
let dou = sizeStr.substr(index + 1, 2);
if (dou == "00") {
return sizeStr.substring(0, index) + sizeStr.substr(index + 3, 2)
}
return size;
}, },
loadPageDetail(pageId) { loadPageDetail(pageId) {
this.clearHistory(); this.clearHistory();
@@ -500,16 +490,11 @@
}; };
if (this.wikiPage.editorType === 2) { if (this.wikiPage.editorType === 2) {
this.pageContent.content = markdownIt.render(this.pageContent.content); this.pageContent.content = markdownIt.render(this.pageContent.content);
// setTimeout(() => {
// // if (this.$refs.mavonEditor) {
// // this.$refs.mavonEditor.toolbar_right_click('read');
// // }
// this.createHeading();
// }, 0);
} }
this.pageShowDetail = this.pageContent.content; this.pageShowDetail = this.pageContent.content;
// 修改标题 // 修改标题
document.title = wikiPage.name || 'WIKI-内容展示'; let wikiTile = wikiPage.name || 'WIKI-内容展示';
document.title = wikiTile;
// 修改最后点击的项,保证刷新后点击编辑能展示编辑的项 // 修改最后点击的项,保证刷新后点击编辑能展示编辑的项
// if (!this.lastClickNode.id) { // if (!this.lastClickNode.id) {
// this.lastClickNode = {id: wikiPage.id, nodePath: wikiPage.name}; // this.lastClickNode = {id: wikiPage.id, nodePath: wikiPage.name};
@@ -518,7 +503,19 @@
this.$emit('switchSpace', this.wikiPage.spaceId); this.$emit('switchSpace', this.wikiPage.spaceId);
// 调用父方法展开目录树 // 调用父方法展开目录树
this.$emit('changeExpandedKeys', pageId); this.$emit('changeExpandedKeys', pageId);
setTimeout(() => this.previewPageImage(), 500); setTimeout(() => {
this.previewPageImage();
let navigationList = htmlUtil.createNavigationHeading();
// 标题加到导航里面去
if (navigationList.length > 0) {
navigationList.unshift({
level: 1,
node: this.$refs.wikiTitle,
text: wikiTile
});
}
this.navigationList = navigationList;
}, 500);
}); });
this.loadCommentList(pageId); this.loadCommentList(pageId);
this.getPageHistory(pageId, 1); this.getPageHistory(pageId, 1);
@@ -526,112 +523,6 @@
closeImagePreview() { closeImagePreview() {
this.showImagePreview = false; this.showImagePreview = false;
}, },
/**
* 生成目录树
* ========================================================
* 说明:代码修改至 yaohaixiao 的 autoc.js
* 项目 gitee 地址https://gitee.com/yaohaixiao/AutocJS
* ========================================================
*/
createHeading() {
let headArr = [];
let headNodeArr = document.querySelector('.wiki-page-content').querySelectorAll('h1,h2,h3,h4,h5,h6,h7,h8,h9');
headNodeArr.forEach(node => {
headArr.push({
node: node,
level: parseInt(node.tagName.replace(/[h]/i, ''), 10)
});
});
let chapters = []
let previous = 1
let level = 0
headArr.forEach((heading, i) => {
let current = heading.level
let pid = -1
// 当前标题的(标题标签)序号 > 前一个标题的序号:两个相连的标题是父标题 -> 子标题关系;
// h2 (前一个标题)
// h3 (当前标题)
if (current > previous) {
level += 1
// 第一层级的 pid 是 -1
if (level === 1) {
pid = -1
} else {
pid = i - 1
}
}
// 当前标题的(标题标签)序号 = 前一个标题的序号
// h2 (前一个标题)
// h2 (当前标题)
// 当前标题的(标题标签)序号 < 前一个标题的序号,并且当前标题序号 > 当前的级别
// h2
// h4 (前一个标题)
// h3 (当前标题:这种情况我们还是任务 h3 是 h2 的下一级章节)
else if (current === previous || (current < previous && current > level)) {
// H1 的层级肯定是 1
if (current === 1) {
level = 1
pid = -1
} else {
pid = chapters[i - 1].pid
}
} else if (current <= level) {
// H1 的层级肯定是 1
if (current === 1) {
level = 1
} else {
level = level - (previous - current)
if (level <= 1) {
level = 1
}
}
// 第一级的标题
if (level === 1) {
pid = -1
} else {
// 虽然看上去差点,不过能工作啊
pid = this.generatePid(chapters, previous - current, i)
}
}
previous = current
chapters.push({
id: i,
pid: pid,
level: level,
text: this.stripTags(this.trim(heading.node.innerHTML))
});
})
console.log(chapters)
},
trim: (str) => {
return str.replace(/^\s+/g, '').replace(/\s+$/g, '')
},
stripTags: (str) => {
return str.replace(/<\/?[^>]+(>|$)/g, '')
},
generatePid(chapters, differ, index) {
let pid
// 最大只有 5 级的差距
switch (differ) {
case 2:
pid = chapters[chapters[chapters[index - 1].pid].pid].pid
break
case 3:
pid = chapters[chapters[chapters[chapters[index - 1].pid].pid].pid].pid
break
case 4:
pid = chapters[chapters[chapters[chapters[chapters[index - 1].pid].pid].pid].pid].pid
break
case 5:
pid = chapters[chapters[chapters[chapters[chapters[chapters[index - 1].pid].pid].pid].pid].pid].pid
break
default:
pid = chapters[chapters[index - 1].pid].pid
break
}
return pid
},
previewPageImage() { previewPageImage() {
const imgArr = []; const imgArr = [];
const imgSelector = this.$refs.pageContent.querySelectorAll('img'); const imgSelector = this.$refs.pageContent.querySelectorAll('img');
@@ -728,10 +619,12 @@
this.$message.error("上传失败," + err); this.$message.error("上传失败," + err);
}, },
uploadFileSuccess(response) { uploadFileSuccess(response) {
common.validateResult({data: response}).then(() => { if (response.errCode == 200) {
this.pageFileList.push(response.data); this.pageFileList.push(response.data);
this.$message.success("上传成功!"); this.$message.success("上传成功!");
}); } else {
vue.$message('上传失败:' + (response.errMsg || "未知错误"));
}
}, },
deletePageFile(row) { deletePageFile(row) {
this.$confirm('确定要删除此文件吗?', '提示', { this.$confirm('确定要删除此文件吗?', '提示', {

View File

@@ -0,0 +1,97 @@
<template>
<div class="navigation">
<div ref="navigation" style="display: inline-block;width: 100%;"></div>
<div class="navigation-heading" :style="{width: navigationWidth}">
<div v-for="item in heading" :class="'heading-item heading-'+item.level" @click="headingItemClick(item)">
{{item.text}}
</div>
</div>
</div>
</template>
<script>
export default {
props: {
heading: {
type: Array,
default: []
},
},
data() {
return {
navigationWidth: '100px'
};
},
mounted() {
window.onresize = () => {
this.computeNavigationWidth();
}
setTimeout(() => this.computeNavigationWidth(), 100);
},
methods: {
computeNavigationWidth() {
this.navigationWidth = window.getComputedStyle(this.$refs.navigation, null).width;
},
headingItemClick(item) {
// 滚动到指定节点
item.node.scrollIntoView({behavior: "smooth", block: "start", inline: "nearest"});
// 距离顶部高度
//console.log(item.node.offsetTop - item.node.scrollHeight)
},
}
}
</script>
<style>
.navigation {
width: 100%;
}
.navigation-heading {
position: fixed;
z-index: 4;
top: 150px;
height: calc(100vh - 250px);
width: 100%;
overflow-y: auto;
padding-left: 16px;
box-sizing: border-box;
}
.navigation-heading .heading-item {
padding: 5px 0;
cursor: pointer;
color: #646a73;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.navigation-heading .heading-item:hover {
color: #3370ff;
}
.navigation-heading .heading-1 {
padding-left: 0;
}
.navigation-heading .heading-2 {
padding-left: 16px;
}
.navigation-heading .heading-3 {
padding-left: 32px;
}
.navigation-heading .heading-4 {
padding-left: 48px;
}
.navigation-heading .heading-5 {
padding-left: 64px;
}
.navigation-heading .heading-6 {
padding-left: 80px;
}
</style>

View File

@@ -1,31 +1,38 @@
<template> <template>
<div class="page-share-view-vue"> <div class="page-share-view-vue">
<el-row type="border-card"> <el-row type="border-card">
<div style="max-width: 950px;margin: 0 auto;"> <el-row>
<div class="wiki-title">{{wikiPage.name}}</div> <el-col :xs="0" :sm="4" :md="4" :lg="6" :xl="6" v-if="navigationList.length > 0">
<div class="wiki-author"> <Navigation :heading="navigationList"></Navigation>
<span v-if="wikiPage.updateTime">最后修改{{wikiPage.updateTime}}</span> </el-col>
<span v-else>创建时间{{wikiPage.createTime}}</span> <el-col :xs="24" :sm="navigationList.length > 0?20:24" :md="navigationList.length > 0?20:24" :lg="navigationList.length > 0?18:24" :xl="navigationList.length > 0?18:24">
</div> <div style="max-width: 1000px;padding-left: 10px;margin: 0 auto;">
<div class="wiki-files"> <div class="wiki-title" ref="wikiTitle">{{wikiPage.name}}</div>
<el-table v-show="pageFileList.length > 0" :data="pageFileList" border style="width: 100%; margin-bottom: 5px;"> <div class="wiki-author">
<el-table-column label="文件名"> <span v-if="wikiPage.updateTime">最后修改{{wikiPage.updateTime}}</span>
<template slot-scope="scope"> <span v-else>创建时间{{wikiPage.createTime}}</span>
<a target="_blank" :href="scope.row.fileUrl">{{scope.row.fileName}}</a> </div>
</template> <div class="wiki-files">
</el-table-column> <el-table v-show="pageFileList.length > 0" :data="pageFileList" border style="width: 100%; margin-bottom: 5px;">
<el-table-column label="文件大小"> <el-table-column label="文件">
<template slot-scope="scope">{{computeFileSize(scope.row.fileSize)}}</template> <template slot-scope="scope">
</el-table-column> <a target="_blank" :href="scope.row.fileUrl">{{scope.row.fileName}}</a>
<el-table-column prop="createTime" label="创建时间" width="180px"></el-table-column> </template>
<el-table-column prop="downloadNum" label="下载次数" width="80px"></el-table-column> </el-table-column>
</el-table> <el-table-column label="文件大小">
</div> <template slot-scope="scope">{{computeFileSize(scope.row.fileSize)}}</template>
<div ref="pageContent" class="wiki-page-content"> </el-table-column>
<div v-html="pageShowDetail" class="markdown-body" v-if="wikiPage.editorType == 2"></div> <el-table-column prop="createTime" label="创建时间" width="180px"></el-table-column>
<div v-html="pageShowDetail" class="wang-editor-body" v-else></div> <el-table-column prop="downloadNum" label="下载次数" width="80px"></el-table-column>
</div> </el-table>
</div> </div>
<div ref="pageContent" class="wiki-page-content">
<div v-html="pageShowDetail" class="markdown-body" v-if="wikiPage.editorType == 2"></div>
<div v-html="pageShowDetail" class="wang-editor-body" v-else></div>
</div>
</div>
</el-col>
</el-row>
</el-row> </el-row>
<div ref="imagePreview"> <div ref="imagePreview">
<el-image-viewer v-if="showImagePreview" :url-list="showImagePreviewList" :on-close="closeImagePreview" :initial-index="previewInitialIndex"></el-image-viewer> <el-image-viewer v-if="showImagePreview" :url-list="showImagePreviewList" :on-close="closeImagePreview" :initial-index="previewInitialIndex"></el-image-viewer>
@@ -36,6 +43,9 @@
<script> <script>
import pageApi from '../../../../common/api/page' import pageApi from '../../../../common/api/page'
import {mavonEditor, markdownIt} from 'mavon-editor' import {mavonEditor, markdownIt} from 'mavon-editor'
import unitUtil from '../../../../common/lib/UnitUtil.js'
import htmlUtil from '../../../../common/lib/HtmlUtil.js'
import Navigation from '../../components/Navigation.vue'
import ElImageViewer from 'element-ui/packages/image/src/image-viewer' import ElImageViewer from 'element-ui/packages/image/src/image-viewer'
import 'mavon-editor/dist/markdown/github-markdown.min.css' import 'mavon-editor/dist/markdown/github-markdown.min.css'
import 'mavon-editor/dist/css/index.css' import 'mavon-editor/dist/css/index.css'
@@ -53,9 +63,10 @@
previewInitialIndex: 0, previewInitialIndex: 0,
showImagePreview: false, showImagePreview: false,
showImagePreviewList: [], showImagePreviewList: [],
navigationList: [],
}; };
}, },
components: {'el-image-viewer': ElImageViewer}, components: {'el-image-viewer': ElImageViewer, Navigation},
beforeRouteUpdate(to, from, next) { beforeRouteUpdate(to, from, next) {
this.initQueryParam(to); this.initQueryParam(to);
next(); next();
@@ -76,8 +87,21 @@
pageContent.content = markdownIt.render(pageContent.content); pageContent.content = markdownIt.render(pageContent.content);
} }
this.pageShowDetail = pageContent.content; this.pageShowDetail = pageContent.content;
document.title = wikiPage.name || 'WIKI-内容展示'; let wikiTile = wikiPage.name || 'WIKI-内容展示';
setTimeout(() => this.previewPageImage(), 500); document.title = wikiTile;
setTimeout(() => {
this.previewPageImage();
let navigationList = htmlUtil.createNavigationHeading();
// 标题加到导航里面去
if (navigationList.length > 0) {
navigationList.unshift({
level: 1,
node: this.$refs.wikiTitle,
text: wikiTile
});
}
this.navigationList = navigationList;
}, 500);
}); });
}, },
initQueryParam(to) { initQueryParam(to) {

View File

@@ -1 +0,0 @@
.page-show-vue{height:100%;overflow:hidden}.page-show-vue .icon-collapse{float:left;font-size:25px;color:#aaa;margin-top:8px;cursor:pointer}.page-show-vue .icon-collapse:hover{color:#eee}.page-show-vue .wiki-title{font-size:20px;text-align:center;font-weight:700}.page-show-vue .create-user-time{margin-right:20px}.page-show-vue .wiki-author{font-size:14px;color:#888;padding:20px 0;height:40px;line-height:40px}.page-show-vue .wiki-page-content img{cursor:pointer;max-width:100%}.page-show-vue .wiki-page-content img:hover{-webkit-box-shadow:0 2px 6px 0 rgba(0,0,0,.3);box-shadow:0 2px 6px 0 rgba(0,0,0,.3)}.page-show-vue .upload-page-file .el-upload-list{display:none}.page-show-vue .is-link{color:#1e88e5;cursor:pointer}.page-show-vue #newPageContentDiv .w-e-text-container{height:600px!important}.page-show-vue .head{float:left;background-color:#ccc;border-radius:50%;margin-right:10px;width:45px;height:45px;line-height:45px;text-align:center;color:#fff}.page-show-vue .el-tabs__header{margin:0}.page-show-vue .el-tabs__nav-wrap{padding:0 20px}.page-show-vue .close-action-tab{position:absolute;right:15px;top:12px;cursor:pointer;z-index:1}.page-show-vue .action-tab-box{height:calc(100vh - 120px);overflow:auto;padding:20px 10px}.page-show-vue .action-box-empty{text-align:center;padding-top:30px;color:#888;font-size:14px}.page-show-vue .history-item{height:55px;line-height:25px;cursor:pointer;vertical-align:middle}.page-show-vue .history-loading-status{margin-left:5px;color:#67c23a}.page-show-vue .history-loading-status.el-icon-circle-close{color:#f56c6c}.page-show-vue .el-timeline{-webkit-padding-start:0;padding-inline-start:0}.page-show-vue .comment-user-name{margin-bottom:10px}.page-show-vue .comment-content{padding:0;color:#666;margin:0;white-space:pre-wrap;word-wrap:break-word;line-height:20px}.page-show-vue .comment-input-box{position:absolute;bottom:0;width:100%;background:#fff;border-top:1px solid #f1f1f1}.page-show-vue .comment-input-box textarea{resize:none;width:100%;-webkit-box-sizing:border-box;box-sizing:border-box;border:0;outline:none!important;padding:10px}.page-show-vue .comment-card .comment-user-name .el-icon-delete{color:#888;font-size:13px;cursor:pointer;float:right;display:none}.mobile-qr,.page-show-vue .comment-card:hover .comment-user-name .el-icon-delete{display:inline-block}.mobile-qr{width:250px;height:250px;border:1px solid #ccc;border-radius:4px;margin-bottom:10px;padding:5px}

View File

@@ -1 +0,0 @@
.page-share-view-vue .wiki-title{font-size:20px;text-align:center}.page-share-view-vue .wiki-author{font-size:14px;color:#888;padding:20px 0;height:40px;line-height:40px}.page-share-view-vue .wiki-page-content img{cursor:pointer;max-width:100%}.page-share-view-vue .wiki-page-content img:hover{-webkit-box-shadow:0 2px 6px 0 rgba(0,0,0,.3);box-shadow:0 2px 6px 0 rgba(0,0,0,.3)}.page-share-view-vue .upload-page-file .el-upload-list{display:none}.page-share-view-vue .is-link{color:#1e88e5;cursor:pointer}

View File

@@ -0,0 +1 @@
.navigation{width:100%}.navigation-heading{position:fixed;z-index:4;top:150px;height:calc(100vh - 250px);width:100%;overflow-y:auto;padding-left:16px;-webkit-box-sizing:border-box;box-sizing:border-box}.navigation-heading .heading-item{padding:5px 0;cursor:pointer;color:#646a73;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.navigation-heading .heading-item:hover{color:#3370ff}.navigation-heading .heading-1{padding-left:0}.navigation-heading .heading-2{padding-left:16px}.navigation-heading .heading-3{padding-left:32px}.navigation-heading .heading-4{padding-left:48px}.navigation-heading .heading-5{padding-left:64px}.navigation-heading .heading-6{padding-left:80px}.page-show-vue{height:100%;overflow:hidden}.page-show-vue .icon-collapse{float:left;font-size:25px;color:#aaa;margin-top:8px;cursor:pointer}.page-show-vue .icon-collapse:hover{color:#eee}.page-show-vue .wiki-title{font-size:20px;text-align:center;font-weight:700}.page-show-vue .create-user-time{margin-right:20px}.page-show-vue .wiki-author{font-size:14px;color:#888;padding:20px 0;height:40px;line-height:40px}.page-show-vue .wiki-page-content img{cursor:pointer;max-width:100%}.page-show-vue .wiki-page-content img:hover{-webkit-box-shadow:0 2px 6px 0 rgba(0,0,0,.3);box-shadow:0 2px 6px 0 rgba(0,0,0,.3)}.page-show-vue .upload-page-file .el-upload-list{display:none}.page-show-vue .is-link{color:#1e88e5;cursor:pointer}.page-show-vue #newPageContentDiv .w-e-text-container{height:600px!important}.page-show-vue .head{float:left;background-color:#ccc;border-radius:50%;margin-right:10px;width:45px;height:45px;line-height:45px;text-align:center;color:#fff}.page-show-vue .el-tabs__header{margin:0}.page-show-vue .el-tabs__nav-wrap{padding:0 20px}.page-show-vue .close-action-tab{position:absolute;right:15px;top:12px;cursor:pointer;z-index:1}.page-show-vue .action-tab-box{height:calc(100vh - 120px);overflow:auto;padding:20px 10px}.page-show-vue .action-box-empty{text-align:center;padding-top:30px;color:#888;font-size:14px}.page-show-vue .history-item{height:55px;line-height:25px;cursor:pointer;vertical-align:middle}.page-show-vue .history-loading-status{margin-left:5px;color:#67c23a}.page-show-vue .history-loading-status.el-icon-circle-close{color:#f56c6c}.page-show-vue .el-timeline{-webkit-padding-start:0;padding-inline-start:0}.page-show-vue .comment-user-name{margin-bottom:10px}.page-show-vue .comment-content{padding:0;color:#666;margin:0;white-space:pre-wrap;word-wrap:break-word;line-height:20px}.page-show-vue .comment-input-box{position:absolute;bottom:0;width:100%;background:#fff;border-top:1px solid #f1f1f1}.page-show-vue .comment-input-box textarea{resize:none;width:100%;-webkit-box-sizing:border-box;box-sizing:border-box;border:0;outline:none!important;padding:10px}.page-show-vue .comment-card .comment-user-name .el-icon-delete{color:#888;font-size:13px;cursor:pointer;float:right;display:none}.mobile-qr,.page-show-vue .comment-card:hover .comment-user-name .el-icon-delete{display:inline-block}.mobile-qr{width:250px;height:250px;border:1px solid #ccc;border-radius:4px;margin-bottom:10px;padding:5px}

View File

@@ -0,0 +1 @@
.navigation{width:100%}.navigation-heading{position:fixed;z-index:4;top:150px;height:calc(100vh - 250px);width:100%;overflow-y:auto;padding-left:16px;-webkit-box-sizing:border-box;box-sizing:border-box}.navigation-heading .heading-item{padding:5px 0;cursor:pointer;color:#646a73;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.navigation-heading .heading-item:hover{color:#3370ff}.navigation-heading .heading-1{padding-left:0}.navigation-heading .heading-2{padding-left:16px}.navigation-heading .heading-3{padding-left:32px}.navigation-heading .heading-4{padding-left:48px}.navigation-heading .heading-5{padding-left:64px}.navigation-heading .heading-6{padding-left:80px}.page-share-view-vue .wiki-title{font-size:20px;text-align:center}.page-share-view-vue .wiki-author{font-size:14px;color:#888;padding:20px 0;height:40px;line-height:40px}.page-share-view-vue .wiki-page-content img{cursor:pointer;max-width:100%}.page-share-view-vue .wiki-page-content img:hover{-webkit-box-shadow:0 2px 6px 0 rgba(0,0,0,.3);box-shadow:0 2px 6px 0 rgba(0,0,0,.3)}.page-share-view-vue .upload-page-file .el-upload-list{display:none}.page-share-view-vue .is-link{color:#1e88e5;cursor:pointer}

View File

@@ -1 +0,0 @@
::-webkit-scrollbar{width:6px;height:9px;-webkit-appearance:none}::-webkit-scrollbar-thumb{background:#ddd;border-radius:10px}::-webkit-scrollbar-track-piece{background:#eee}.create-space-vue .empty-news{text-align:center;padding:100px}.create-space-vue .text-link{color:#444}.create-space-vue .line-box{color:#666;border-bottom:1px solid #eee;padding:20px 0}.create-space-vue .line-title{font-size:14px}.create-space-vue .page-preview-title{font-size:18px;margin:10px 0 5px 0;color:#3a8ee6;cursor:pointer}.create-space-vue .page-preview-content{font-size:16px;margin-bottom:5px}.create-space-vue .zan-img{vertical-align:middle;margin-top:-3px}.create-space-vue .view-img{font-size:16px;color:#666}.create-space-vue .page-info-box{text-align:right;margin:20px 0 50px 0}.about-zyplayer-doc{text-align:left;line-height:normal}.about-zyplayer-doc .el-dialog__body{padding:20px}body,html{margin:0;padding:0}#app,.el-container,.el-menu,.global-layout-vue,body,html{height:100%}.el-header{background-color:#1d4e89!important}.header-right-user-name{color:#fff;padding-right:5px}.el-header{color:#333;line-height:40px;text-align:right;height:40px!important}.el-icon-download,.el-icon-upload2{-webkit-transform:rotate(-90deg);transform:rotate(-90deg);float:left;font-size:25px;color:#aaa;margin-top:8px;cursor:pointer}.el-icon-download:hover,.el-icon-upload2:hover{color:#eee}.head-icon{margin-right:15px;font-size:16px;cursor:pointer;color:#fff}.header-user-message .page-info-box{text-align:right;margin-top:10px}.upgrade-info{max-height:150px;overflow-y:auto;word-break:break-all;white-space:pre-wrap;line-height:26px}#app[data-v-d209bcd8],body[data-v-d209bcd8],html[data-v-d209bcd8]{margin:0;padding:0;height:100%}pre[data-v-d209bcd8]{margin:0;white-space:pre-wrap;font-size:14px;font-family:auto}.el-menu[data-v-d209bcd8]{-webkit-box-sizing:border-box;box-sizing:border-box;border-right:0;margin-right:3px}.el-header[data-v-d209bcd8]{background-color:#409eff;color:#333;line-height:40px;text-align:right;height:40px!important}.doc-body-box[data-v-d209bcd8]{overflow-x:hidden;overflow-y:auto;width:100%;padding:10px;border-left:1px solid #f1f1f1;-webkit-box-sizing:border-box;box-sizing:border-box}.el-tree[data-v-d209bcd8]{margin-right:3px}.logo[data-v-d209bcd8]{border-bottom:1px solid #f1f1f1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding:5px 10px;width:260px;height:40px;line-height:40px;font-size:25px;color:#666;text-align:center}.icon-collapse[data-v-d209bcd8]{float:left;font-size:25px;color:#aaa;cursor:pointer;position:fixed}.icon-collapse[data-v-d209bcd8]:hover{color:#ccc}.comment-box .head[data-v-d209bcd8]{float:left;background-color:#ccc;border-radius:50%;margin-right:10px;width:45px;height:45px;line-height:45px;text-align:center;color:#fff}.build-info[data-v-d209bcd8]{position:fixed;bottom:0;left:0;background:#fafafa;width:240px;text-align:center;padding:5px 0;color:#aaa;font-size:12px}.build-info a[data-v-d209bcd8]{color:#4183c4;cursor:pointer;text-decoration:none}#app[data-v-12cfde59],body[data-v-12cfde59],html[data-v-12cfde59]{margin:0;padding:0;height:100%}.share-mobile-layout[data-v-12cfde59]{height:100%}.popup-module .header[data-v-12cfde59]{width:100%;height:46px}.popup-module .main[data-v-12cfde59]{position:absolute;top:46px;bottom:0;right:0;left:0;overflow:auto}.popup-module .footer[data-v-12cfde59]{width:100%;height:26px;position:fixed;bottom:0}pre[data-v-12cfde59]{margin:0;white-space:pre-wrap;font-size:14px;font-family:auto}.el-menu[data-v-12cfde59]{-webkit-box-sizing:border-box;box-sizing:border-box;border-right:0;margin-right:3px}.el-header[data-v-12cfde59]{background-color:#409eff;color:#333;line-height:40px;text-align:right;height:40px!important}.doc-body-box[data-v-12cfde59]{overflow-x:hidden;overflow-y:auto;width:100%;padding:10px;border-left:1px solid #f1f1f1;-webkit-box-sizing:border-box;box-sizing:border-box}.el-tree[data-v-12cfde59]{margin-right:3px}.logo[data-v-12cfde59]{border-bottom:1px solid #f1f1f1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding:5px 10px;width:260px;height:40px;line-height:40px;font-size:25px;color:#666;text-align:center}.icon-collapse[data-v-12cfde59]{float:left;font-size:25px;color:#aaa;cursor:pointer;position:fixed}.icon-collapse[data-v-12cfde59]:hover{color:#ccc}.comment-box .head[data-v-12cfde59]{float:left;background-color:#ccc;border-radius:50%;margin-right:10px;width:45px;height:45px;line-height:45px;text-align:center;color:#fff}.build-info[data-v-12cfde59]{text-align:center;padding:5px 0;color:#aaa;font-size:12px;margin:10px 0}.build-info a[data-v-12cfde59]{color:#4183c4;cursor:pointer;text-decoration:none}

View File

@@ -0,0 +1 @@
::-webkit-scrollbar{width:6px;height:9px;-webkit-appearance:none}::-webkit-scrollbar-thumb{background:#ddd;border-radius:10px}::-webkit-scrollbar-track-piece{background:#eee}.create-space-vue .empty-news{text-align:center;padding:100px}.create-space-vue .text-link{color:#444}.create-space-vue .line-box{color:#666;border-bottom:1px solid #eee;padding:20px 0}.create-space-vue .line-title{font-size:14px}.create-space-vue .page-preview-title{font-size:18px;margin:10px 0 5px 0;color:#3a8ee6;cursor:pointer}.create-space-vue .page-preview-content{font-size:16px;margin-bottom:5px}.create-space-vue .zan-img{vertical-align:middle;margin-top:-3px}.create-space-vue .view-img{font-size:16px;color:#666}.create-space-vue .page-info-box{text-align:right;margin:20px 0 50px 0}.right-resize[data-v-49e22d62]{width:5px;height:100%;cursor:w-resize;background:#fafafa}.right-resize i[data-v-49e22d62]{margin-top:300px;width:5px;height:35px;display:inline-block;word-wrap:break-word;word-break:break-all;line-height:8px;border-radius:5px;background:#ccc;color:#888}.about-zyplayer-doc{text-align:left;line-height:normal}.about-zyplayer-doc .el-dialog__body{padding:20px}body,html{margin:0;padding:0}#app,.el-container,.el-menu,.global-layout-vue,body,html{height:100%}.el-header{background-color:#1d4e89!important}.header-right-user-name{color:#fff;padding-right:5px}.el-header{color:#333;line-height:40px;text-align:right;height:40px!important}.el-icon-fold{float:left;font-size:25px;color:#aaa;margin-top:8px;cursor:pointer}.el-icon-fold:hover{color:#eee}.head-icon{margin-right:15px;font-size:16px;cursor:pointer;color:#fff}.header-user-message .page-info-box{text-align:right;margin-top:10px}.upgrade-info{max-height:150px;overflow-y:auto;word-break:break-all;white-space:pre-wrap;line-height:26px}#app[data-v-a8a86fe2],body[data-v-a8a86fe2],html[data-v-a8a86fe2]{margin:0;padding:0;height:100%}pre[data-v-a8a86fe2]{margin:0;white-space:pre-wrap;font-size:14px;font-family:auto}.el-menu[data-v-a8a86fe2]{-webkit-box-sizing:border-box;box-sizing:border-box;border-right:0;margin-right:3px}.el-header[data-v-a8a86fe2]{background-color:#409eff;color:#333;line-height:40px;text-align:right;height:40px!important}.doc-body-box[data-v-a8a86fe2]{overflow-x:hidden;overflow-y:auto;width:100%;padding:10px;border-left:1px solid #f1f1f1;-webkit-box-sizing:border-box;box-sizing:border-box}.el-tree[data-v-a8a86fe2]{margin-right:3px}.logo[data-v-a8a86fe2]{border-bottom:1px solid #f1f1f1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding:5px 10px;width:260px;height:40px;line-height:40px;font-size:25px;color:#666;text-align:center}.icon-collapse[data-v-a8a86fe2]{float:left;font-size:25px;color:#aaa;cursor:pointer;position:fixed}.icon-collapse[data-v-a8a86fe2]:hover{color:#ccc}.comment-box .head[data-v-a8a86fe2]{float:left;background-color:#ccc;border-radius:50%;margin-right:10px;width:45px;height:45px;line-height:45px;text-align:center;color:#fff}.build-info[data-v-a8a86fe2]{position:fixed;bottom:0;left:0;background:#fafafa;width:240px;text-align:center;padding:5px 0;color:#aaa;font-size:12px}.build-info a[data-v-a8a86fe2]{color:#4183c4;cursor:pointer;text-decoration:none}#app[data-v-12cfde59],body[data-v-12cfde59],html[data-v-12cfde59]{margin:0;padding:0;height:100%}.share-mobile-layout[data-v-12cfde59]{height:100%}.popup-module .header[data-v-12cfde59]{width:100%;height:46px}.popup-module .main[data-v-12cfde59]{position:absolute;top:46px;bottom:0;right:0;left:0;overflow:auto}.popup-module .footer[data-v-12cfde59]{width:100%;height:26px;position:fixed;bottom:0}pre[data-v-12cfde59]{margin:0;white-space:pre-wrap;font-size:14px;font-family:auto}.el-menu[data-v-12cfde59]{-webkit-box-sizing:border-box;box-sizing:border-box;border-right:0;margin-right:3px}.el-header[data-v-12cfde59]{background-color:#409eff;color:#333;line-height:40px;text-align:right;height:40px!important}.doc-body-box[data-v-12cfde59]{overflow-x:hidden;overflow-y:auto;width:100%;padding:10px;border-left:1px solid #f1f1f1;-webkit-box-sizing:border-box;box-sizing:border-box}.el-tree[data-v-12cfde59]{margin-right:3px}.logo[data-v-12cfde59]{border-bottom:1px solid #f1f1f1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding:5px 10px;width:260px;height:40px;line-height:40px;font-size:25px;color:#666;text-align:center}.icon-collapse[data-v-12cfde59]{float:left;font-size:25px;color:#aaa;cursor:pointer;position:fixed}.icon-collapse[data-v-12cfde59]:hover{color:#ccc}.comment-box .head[data-v-12cfde59]{float:left;background-color:#ccc;border-radius:50%;margin-right:10px;width:45px;height:45px;line-height:45px;text-align:center;color:#fff}.build-info[data-v-12cfde59]{text-align:center;padding:5px 0;color:#aaa;font-size:12px;margin:10px 0}.build-info a[data-v-12cfde59]{color:#4183c4;cursor:pointer;text-decoration:none}

View File

@@ -1 +1 @@
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=favicon-wiki.png><title>WIKI文档管理系统</title><link href=css/chunk-1ca8e011.d02f27be.css rel=prefetch><link href=css/chunk-32cc5643.5a5b2ca1.css rel=prefetch><link href=css/chunk-34407190.57bbfb51.css rel=prefetch><link href=css/chunk-3ce84b17.ab8b8fd2.css rel=prefetch><link href=css/chunk-49c0ba36.ec6236ec.css rel=prefetch><link href=css/chunk-4cdf76bb.bb45a557.css rel=prefetch><link href=css/chunk-53af6df9.17d2b8a1.css rel=prefetch><link href=css/chunk-55738a8b.a38bf186.css rel=prefetch><link href=css/chunk-578c28a7.83c6d32d.css rel=prefetch><link href=css/chunk-6853a088.50949d53.css rel=prefetch><link href=css/chunk-72e49b1a.8ccc36ca.css rel=prefetch><link href=css/chunk-7ecd39ac.bf68cbeb.css rel=prefetch><link href=js/chunk-1ca8e011.762634f5.js rel=prefetch><link href=js/chunk-2d207ece.e10076eb.js rel=prefetch><link href=js/chunk-32cc5643.93647ea4.js rel=prefetch><link href=js/chunk-34407190.acdd458d.js rel=prefetch><link href=js/chunk-3ce84b17.7344d2a7.js rel=prefetch><link href=js/chunk-49c0ba36.5941cad9.js rel=prefetch><link href=js/chunk-4cdf76bb.e2eee9d0.js rel=prefetch><link href=js/chunk-53af6df9.fed2ef07.js rel=prefetch><link href=js/chunk-55738a8b.de766eb2.js rel=prefetch><link href=js/chunk-578c28a7.d172d229.js rel=prefetch><link href=js/chunk-6853a088.5b8a6628.js rel=prefetch><link href=js/chunk-72e49b1a.e821cfe4.js rel=prefetch><link href=js/chunk-7ecd39ac.e449af2c.js rel=prefetch><link href=css/chunk-vendors.3aff4100.css rel=preload as=style><link href=css/index.1abcb287.css rel=preload as=style><link href=js/chunk-vendors.2dfa4edd.js rel=preload as=script><link href=js/index.a56b1d38.js rel=preload as=script><link href=css/chunk-vendors.3aff4100.css rel=stylesheet><link href=css/index.1abcb287.css rel=stylesheet></head><body><noscript><strong>We're sorry but zyplayer-wiki-ui doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=js/chunk-vendors.2dfa4edd.js></script><script src=js/index.a56b1d38.js></script></body></html> <!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=favicon-wiki.png><title>WIKI文档管理系统</title><link href=css/chunk-32cc5643.5a5b2ca1.css rel=prefetch><link href=css/chunk-34407190.57bbfb51.css rel=prefetch><link href=css/chunk-49c0ba36.ec6236ec.css rel=prefetch><link href=css/chunk-4cdf76bb.bb45a557.css rel=prefetch><link href=css/chunk-53af6df9.17d2b8a1.css rel=prefetch><link href=css/chunk-578c28a7.83c6d32d.css rel=prefetch><link href=css/chunk-65ea754d.d02f27be.css rel=prefetch><link href=css/chunk-6853a088.50949d53.css rel=prefetch><link href=css/chunk-72e49b1a.8ccc36ca.css rel=prefetch><link href=css/chunk-7ecd39ac.bf68cbeb.css rel=prefetch><link href=css/chunk-d1fffbb4.3a83823c.css rel=prefetch><link href=css/chunk-dd791ad2.08702abb.css rel=prefetch><link href=js/chunk-2d207ece.e10076eb.js rel=prefetch><link href=js/chunk-32cc5643.93647ea4.js rel=prefetch><link href=js/chunk-34407190.acdd458d.js rel=prefetch><link href=js/chunk-49c0ba36.5941cad9.js rel=prefetch><link href=js/chunk-4cdf76bb.e2eee9d0.js rel=prefetch><link href=js/chunk-53af6df9.fed2ef07.js rel=prefetch><link href=js/chunk-578c28a7.d172d229.js rel=prefetch><link href=js/chunk-65ea754d.d3400891.js rel=prefetch><link href=js/chunk-6853a088.1eb66613.js rel=prefetch><link href=js/chunk-72e49b1a.e821cfe4.js rel=prefetch><link href=js/chunk-7ecd39ac.e449af2c.js rel=prefetch><link href=js/chunk-d1fffbb4.99468681.js rel=prefetch><link href=js/chunk-dd791ad2.243c8db2.js rel=prefetch><link href=css/chunk-vendors.3aff4100.css rel=preload as=style><link href=css/index.d85761f2.css rel=preload as=style><link href=js/chunk-vendors.2dfa4edd.js rel=preload as=script><link href=js/index.1210d458.js rel=preload as=script><link href=css/chunk-vendors.3aff4100.css rel=stylesheet><link href=css/index.d85761f2.css rel=stylesheet></head><body><noscript><strong>We're sorry but zyplayer-wiki-ui doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=js/chunk-vendors.2dfa4edd.js></script><script src=js/index.1210d458.js></script></body></html>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-55738a8b"],{"4aa7":function(e,i,t){"use strict";t.r(i);var a=function(){var e=this,i=e.$createElement,t=e._self._c||i;return t("div",{staticClass:"page-share-view-vue"},[t("el-row",{attrs:{type:"border-card"}},[t("div",{staticStyle:{"max-width":"950px",margin:"0 auto"}},[t("div",{staticClass:"wiki-title"},[e._v(e._s(e.wikiPage.name))]),t("div",{staticClass:"wiki-author"},[e.wikiPage.updateTime?t("span",[e._v("最后修改:"+e._s(e.wikiPage.updateTime))]):t("span",[e._v("创建时间:"+e._s(e.wikiPage.createTime))])]),t("div",{staticClass:"wiki-files"},[t("el-table",{directives:[{name:"show",rawName:"v-show",value:e.pageFileList.length>0,expression:"pageFileList.length > 0"}],staticStyle:{width:"100%","margin-bottom":"5px"},attrs:{data:e.pageFileList,border:""}},[t("el-table-column",{attrs:{label:"文件名"},scopedSlots:e._u([{key:"default",fn:function(i){return[t("a",{attrs:{target:"_blank",href:i.row.fileUrl}},[e._v(e._s(i.row.fileName))])]}}])}),t("el-table-column",{attrs:{label:"文件大小"},scopedSlots:e._u([{key:"default",fn:function(i){return[e._v(e._s(e.computeFileSize(i.row.fileSize)))]}}])}),t("el-table-column",{attrs:{prop:"createTime",label:"创建时间",width:"180px"}}),t("el-table-column",{attrs:{prop:"downloadNum",label:"下载次数",width:"80px"}})],1)],1),t("div",{ref:"pageContent",staticClass:"wiki-page-content"},[2==e.wikiPage.editorType?t("div",{staticClass:"markdown-body",domProps:{innerHTML:e._s(e.pageShowDetail)}}):t("div",{staticClass:"wang-editor-body",domProps:{innerHTML:e._s(e.pageShowDetail)}})])])]),t("div",{ref:"imagePreview"},[e.showImagePreview?t("el-image-viewer",{attrs:{"url-list":e.showImagePreviewList,"on-close":e.closeImagePreview,"initial-index":e.previewInitialIndex}}):e._e()],1)],1)},n=[],s=(t("4160"),t("c975"),t("b0c0"),t("b680"),t("159b"),t("0a79")),r=t("b2d8"),o=t("08a9"),l=(t("c350"),t("64e1"),{data:function(){return{spaceUuid:"",nowPageId:"",wikiPage:{},pageFileList:[],pageShowDetail:"",previewInitialIndex:0,showImagePreview:!1,showImagePreviewList:[]}},components:{"el-image-viewer":o["a"]},beforeRouteUpdate:function(e,i,t){this.initQueryParam(e),t()},mounted:function(){this.initQueryParam(this.$route)},methods:{loadPageDetail:function(e){var i=this,t={pageId:e,space:this.spaceUuid};s["a"].openPageDetail(t).then((function(e){var t=e.data.wikiPage||{};t.selfZan=e.data.selfZan||0,i.wikiPage=t;var a=e.data.pageContent||{};i.pageFileList=e.data.fileList||[],2===i.wikiPage.editorType&&(a.content=r["markdownIt"].render(a.content)),i.pageShowDetail=a.content,document.title=t.name||"WIKI-内容展示",setTimeout((function(){return i.previewPageImage()}),500)}))},initQueryParam:function(e){this.spaceUuid=e.query.space,this.nowPageId=e.query.pageId,this.nowPageId&&this.loadPageDetail(this.nowPageId)},computeFileSize:function(e){if(!e)return"-";var i="";i=e<102.4?e.toFixed(2)+"B":e<104857.6?(e/1024).toFixed(2)+"KB":e<107374182.4?(e/1048576).toFixed(2)+"MB":(e/1073741824).toFixed(2)+"GB";var t=i+"",a=t.indexOf("."),n=t.substr(a+1,2);return"00"==n?t.substring(0,a)+t.substr(a+3,2):i},closeImagePreview:function(){this.showImagePreview=!1},previewPageImage:function(){var e=this,i=[],t=this.$refs.pageContent.querySelectorAll("img");t.forEach((function(t,a){i.push(t.src),t.onclick=function(){e.previewInitialIndex=a,e.showImagePreviewList=i,e.showImagePreview=!0,setTimeout((function(){return e.initImageViewerMask()}),0)}}))},initImageViewerMask:function(){var e=this,i=this.$refs.imagePreview.querySelectorAll(".el-image-viewer__mask");i.forEach((function(i){i.onclick=function(){return e.showImagePreview=!1}}))}}}),c=l,u=(t("6afb"),t("2877")),w=Object(u["a"])(c,a,n,!1,null,null,null);i["default"]=w.exports},"6afb":function(e,i,t){"use strict";var a=t("aae1"),n=t.n(a);n.a},aae1:function(e,i,t){}}]);

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long