doc: update v3 & qrcode

1.x
tangjinzhou 2021-10-17 09:24:18 +08:00
parent 233ef9f2cf
commit 11e0994012
2 changed files with 27 additions and 16 deletions

View File

@ -17,7 +17,7 @@ export default {
return { return {
visibleAdblockBanner: !!this.demoContext.blocked, visibleAdblockBanner: !!this.demoContext.blocked,
value: null, value: null,
showTopBanner: !localStorage.getItem('notification-key-2.2'), showTopBanner: !localStorage.getItem('notification-key-next'),
}; };
}, },
watch: { watch: {
@ -64,8 +64,8 @@ export default {
this.value = val; this.value = val;
}, },
closeTopBanner() {}, closeTopBanner() {},
changeVersion() { changeVersion(v) {
location.href = `https://2x.antdv.com${this.$route.fullPath}`; location.href = `https://${v}.antdv.com${this.$route.fullPath}`;
}, },
}, },
render() { render() {
@ -92,32 +92,32 @@ export default {
{isCN && this.showTopBanner && ( {isCN && this.showTopBanner && (
<div class="global-notification"> <div class="global-notification">
<span> <span>
当前文档是 1.x 版本如需使用 Vue 3 请访问&nbsp;&nbsp; v3 版本已发布请访问 &nbsp;&nbsp;
<a href="https://2x.antdv.com/" target="_blank"> <a href="https://next.antdv.com/" target="_blank">
2.x next.antdv.com
</a> </a>
&nbsp;&nbsp;版本文档 &nbsp;&nbsp;查看更多详情
</span> </span>
<a-icon <a-icon
type="close" type="close"
style="position: absolute;top: 13px;right: 15px;" style="position: absolute;top: 13px;right: 15px;"
onClick={() => this.handleClose('2.0')} onClick={() => this.handleClose('next')}
/> />
</div> </div>
)} )}
{!isCN && this.showTopBanner && ( {!isCN && this.showTopBanner && (
<div class="global-notification"> <div class="global-notification">
<span> <span>
Youre browsing the documentation for v1.x (support vue 2).&nbsp; v3 beta is out! Discover more about it on &nbsp;
<a href="https://2x.antdv.com/" target="_blank"> <a href="https://next.antdv.com/" target="_blank">
Click here next.antdv.com
</a> </a>
&nbsp;for v2.xsupport vue 3 documentation. &nbsp;
</span> </span>
<a-icon <a-icon
type="close" type="close"
style="position: absolute;top: 8px;right: 15px;" style="position: absolute;top: 8px;right: 15px;"
onClick={() => this.handleClose('2.0')} onClick={() => this.handleClose('next')}
/> />
</div> </div>
)} )}
@ -162,8 +162,11 @@ export default {
</a-button> </a-button>
<a-select size="small" defaultValue={packageInfo.version} class="version"> <a-select size="small" defaultValue={packageInfo.version} class="version">
<a-select-option value={packageInfo.version}>{packageInfo.version}</a-select-option> <a-select-option value={packageInfo.version}>{packageInfo.version}</a-select-option>
<a-select-option value="2.x" onClick={this.changeVersion}> <a-select-option value="2.x" onClick={() => this.changeVersion('2x')}>
2.x v2 LST
</a-select-option>
<a-select-option value="next" onClick={() => this.changeVersion('next')}>
v3 Current (Latest Features)
</a-select-option> </a-select-option>
</a-select> </a-select>
<a-menu selectedKeys={selectedKeys} mode="horizontal" class="menu-site" id="nav"> <a-menu selectedKeys={selectedKeys} mode="horizontal" class="menu-site" id="nav">

View File

@ -1,6 +1,12 @@
<template> <template>
<div id="right-bottom"> <div id="right-bottom">
<img v-if="isCN" width="150" alt="官方公众号" src="https://qn.antdv.com/wechat.jpeg"> <!-- <img v-if="isCN" width="150" alt="官方公众号" src="https://qn.antdv.com/wechat.jpeg"> -->
<img
v-if="isCN"
width="150"
alt="早早聊 Vue 专场大会"
:src="`https://next-antdv.oss-cn-beijing.aliyuncs.com/zaozaoliao.png?v=${Date.now()}`"
/>
<div v-if="isMobile" class="close" @click="visible = false"> <div v-if="isMobile" class="close" @click="visible = false">
<a-icon type="close" /> <a-icon type="close" />
</div> </div>
@ -44,6 +50,8 @@ export default {
bottom: 10px; bottom: 10px;
right: 10px; right: 10px;
width: 150px; width: 150px;
border-radius: 5px;
overflow: hidden;
.close { .close {
position: absolute; position: absolute;
text-align: center; text-align: center;