From c7c39aff0368329074deaae32ea13d77cb5acd6b Mon Sep 17 00:00:00 2001 From: sakuya <81883387@qq.com> Date: Sat, 20 Nov 2021 22:01:15 +0800 Subject: [PATCH] =?UTF-8?q?:hammer:=20=E9=87=8D=E6=9E=84=E4=BA=86=E6=A0=87?= =?UTF-8?q?=E7=AD=BE=E5=85=A8=E5=B1=8F=E7=9A=84=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layout/components/tags.vue | 9 ++++----- src/layout/index.vue | 6 ++++++ src/style/app.scss | 9 +++++++++ 3 files changed, 19 insertions(+), 5 deletions(-) diff --git a/src/layout/components/tags.vue b/src/layout/components/tags.vue index c01a2a95..9e75020a 100644 --- a/src/layout/components/tags.vue +++ b/src/layout/components/tags.vue @@ -17,7 +17,7 @@
  • 关闭标签
  • 关闭其他标签

  • -
  • 全屏当前标签
  • +
  • 最大化
  • 在新的窗口中打开
  • @@ -195,8 +195,8 @@ }) this.contextMenuVisible = false }, - //TAB 全屏标签 - screen(){ + //TAB 最大化 + maximize(){ var nowTag = this.contextMenuItem; this.contextMenuVisible = false //判断是否当前路由,否的话跳转 @@ -206,8 +206,7 @@ query: nowTag.query }) } - var element = document.getElementById('adminui-main') - this.$TOOL.screen(element) + document.getElementById('app').classList.add('main-maximize') }, //新窗口打开 openWindow(){ diff --git a/src/layout/index.vue b/src/layout/index.vue index 5657ade8..82064f46 100644 --- a/src/layout/index.vue +++ b/src/layout/index.vue @@ -165,6 +165,8 @@ +
    +
    @@ -281,6 +283,10 @@ newMap.push(item) }) return newMap; + }, + //退出最大化 + exitMaximize(){ + document.getElementById('app').classList.remove('main-maximize') } } } diff --git a/src/style/app.scss b/src/style/app.scss index 836103ee..862eb4c3 100644 --- a/src/style/app.scss +++ b/src/style/app.scss @@ -93,3 +93,12 @@ a,button,input,textarea{-webkit-tap-highlight-color:rgba(0,0,0,0);box-sizing: bo .adminui-tags li.sortable-ghost {opacity: 0;} .adminui-main {overflow: auto;background-color: #f6f8f9;flex: 1;} + +/*页面最大化*/ +.aminui.main-maximize { + .main-maximize-exit {display: block;} + .aminui-side-split, .aminui-side, .adminui-header, .adminui-topbar, .adminui-tags {display: none;} +} +.main-maximize-exit {display: none;position: fixed;z-index: 3000;top:-20px;left:50%;margin-left: -20px;border-radius: 50%;width: 40px;height: 40px;cursor: pointer;background: rgba(0,0,0,0.2);text-align: center;} +.main-maximize-exit i {font-size: 14px;margin-top: 22px;color: #fff;} +.main-maximize-exit:hover {background: rgba(0,0,0,0.4);} \ No newline at end of file