From 819f035bd96d78b31b515bc950dbe27d85506533 Mon Sep 17 00:00:00 2001 From: Catouse Date: Mon, 15 Oct 2018 15:35:25 +0800 Subject: [PATCH] * improve UI of doc views, code for task #5032. --- module/doc/css/common.css | 13 +++++++------ module/doc/js/common.js | 11 +++-------- module/doc/view/alllibs.html.php | 2 +- module/doc/view/alllibsbylist.html.php | 8 ++++---- module/doc/view/browse.html.php | 12 ++++++------ module/doc/view/browsebygrid.html.php | 6 +++--- module/doc/view/objectlibsbylist.html.php | 6 +++--- module/doc/view/showfiles.html.php | 7 ++++--- 8 files changed, 31 insertions(+), 34 deletions(-) diff --git a/module/doc/css/common.css b/module/doc/css/common.css index 4c8dd422bb..778bd79d7f 100644 --- a/module/doc/css/common.css +++ b/module/doc/css/common.css @@ -49,16 +49,17 @@ .files-grid .img-holder {height: 64px; line-height: 64px; margin: 0 auto 8px; width: 100%; background-size: contain; background-repeat: no-repeat; background-position: center;} .files-grid .img-holder > img {max-height: 64px; opacity: 0; width: 100%;} -.panel{padding-bottom: 40px;} -.panel .table-footer{position: absolute; bottom: 0; width: 100%;} - @keyframes flash-icon { 0% {color: #666;} 100% {color: #fff;} } -.main-col > .panel > .panel-body {padding-top: 20px;} -.main-col .panel-title a.active{color: #0c64eb} +.main-col > .panel > .panel-body {padding: 5px 10px;} +.main-col .panel-title a.active {color: #0c64eb} -#mainRow .cell{overflow: hidden auto} +.side-col > .cell {overflow: hidden auto; padding: 0; position: relative;} +.side-col > .cell > header {position: absolute; top: 10px; right: 10px; left: 10px;} +.side-col > .cell > header > .c-sm {padding-right: 20px; width: 60px;;} +.side-col #docsTree {position: absolute; top: 53px; left: 0; right: 0; bottom: 0; overflow: auto; padding: 10px;} +.main-col .block-files > .panel-body {position: absolute; top: 45px; left: 0; right: 0; bottom: 0; overflow: auto;} \ No newline at end of file diff --git a/module/doc/js/common.js b/module/doc/js/common.js index 0e9c545aab..1be29f58bc 100644 --- a/module/doc/js/common.js +++ b/module/doc/js/common.js @@ -131,16 +131,11 @@ $(document).ready(function() }; var resizeCols = function() { - var cellHeight = $(window).height() - 230; - var $cells = $cols.children('.panel,.cell').height(cellHeight); - if($firstCol.next('.col-spliter').css('display') != 'none') - { - var bestHeight = $firstCol.height(); - $cells.css('height', bestHeight); - } + var cellHeight = $(window).height() - $('#footer').outerHeight() - $('#header').outerHeight() - 40; + $cols.children('.panel,.cell').height(cellHeight).css('maxHeight', cellHeight); }; - $element.find('.tree').on('resize', resizeCols); + $(window).on('resize', resizeCols); $firstCol.on('resize', function(e) {fixColClass($firstCol);}); $secondCol.on('resize', function(e) {fixColClass($secondCol);}); fixColClass($firstCol); diff --git a/module/doc/view/alllibs.html.php b/module/doc/view/alllibs.html.php index 0a483d2313..24f0b7e758 100644 --- a/module/doc/view/alllibs.html.php +++ b/module/doc/view/alllibs.html.php @@ -65,8 +65,8 @@ + - diff --git a/module/doc/view/alllibsbylist.html.php b/module/doc/view/alllibsbylist.html.php index 46be1eb702..08eca0f9f0 100644 --- a/module/doc/view/alllibsbylist.html.php +++ b/module/doc/view/alllibsbylist.html.php @@ -15,8 +15,8 @@ -
- +
+
@@ -29,7 +29,7 @@ - + @@ -62,7 +62,7 @@
doc->addedBy;?> doc->addedDate;?> actions;?>actions;?>
+
- diff --git a/module/doc/view/browse.html.php b/module/doc/view/browse.html.php index a478cd9eac..f4d807df7b 100644 --- a/module/doc/view/browse.html.php +++ b/module/doc/view/browse.html.php @@ -66,8 +66,8 @@ var browseType = '';

-
- +
+
@@ -75,7 +75,7 @@ var browseType = ''; - + @@ -132,10 +132,10 @@ var browseType = '';
doc->title;?>doc->addedBy;?> doc->addedDate;?> doc->editedDate;?>actions;?>actions;?>
+ + +
- - - diff --git a/module/doc/view/browsebygrid.html.php b/module/doc/view/browsebygrid.html.php index e6b154e69f..245678cc34 100644 --- a/module/doc/view/browsebygrid.html.php +++ b/module/doc/view/browsebygrid.html.php @@ -62,10 +62,10 @@ + + + - - - diff --git a/module/doc/view/objectlibsbylist.html.php b/module/doc/view/objectlibsbylist.html.php index 774a5c3242..00d20916cd 100644 --- a/module/doc/view/objectlibsbylist.html.php +++ b/module/doc/view/objectlibsbylist.html.php @@ -34,13 +34,13 @@ -
- +
+
- + diff --git a/module/doc/view/showfiles.html.php b/module/doc/view/showfiles.html.php index 9c0c28b9f2..e4770c1b44 100644 --- a/module/doc/view/showfiles.html.php +++ b/module/doc/view/showfiles.html.php @@ -48,8 +48,8 @@ -
-
doc->libName;?> doc->num;?>actions;?>actions;?>
+
+
@@ -85,6 +85,7 @@
doc->id;?>
+
@@ -141,9 +142,9 @@
+ -