diff options
Diffstat (limited to 'apps/files')
-rw-r--r-- | apps/files/css/files.scss | 14 | ||||
-rw-r--r-- | apps/files/img/quota.svg | 4 | ||||
-rw-r--r-- | apps/files/templates/appnavigation.php | 21 | ||||
-rw-r--r-- | apps/files/tests/Controller/ViewControllerTest.php | 8 |
4 files changed, 26 insertions, 21 deletions
diff --git a/apps/files/css/files.scss b/apps/files/css/files.scss index 741ea329c84..10f37840580 100644 --- a/apps/files/css/files.scss +++ b/apps/files/css/files.scss @@ -108,9 +108,8 @@ .nav-icon-trashbin { background-image: url('../img/delete.svg?v=1'); } -/* no icon for the quota bar */ .nav-icon-quota { - padding-left: 15px !important; + background-image: url('../img/quota.svg?v=1'); } #app-navigation .nav-files a.nav-icon-files { @@ -777,11 +776,7 @@ table.dragshadow td.size { margin: 0 !important; border: none; border-radius: 0; - position: fixed !important; - bottom: 44px; - width: inherit !important; - background-color: #fff; - border-right: 1px solid #eee; + background-color: transparent; z-index:1; .quota-container { @@ -795,11 +790,6 @@ table.dragshadow td.size { } } -/* increase the padding of the last item to not hide below the quota item */ -.app-files #app-navigation > ul li:nth-last-child(1) { - margin-bottom: 44px; -} - #quotatext { padding: 0; height: 30px; diff --git a/apps/files/img/quota.svg b/apps/files/img/quota.svg new file mode 100644 index 00000000000..1ab0936af1b --- /dev/null +++ b/apps/files/img/quota.svg @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="UTF-8"?> +<svg width="16" height="16" version="1" xmlns="http://www.w3.org/2000/svg"> + <path d="m8 1c-3.8553 0-7 3.1448-7 7 0 3.8552 3.1448 7 7 7 3.8553 0 7-3.1448 7-7 0-3.8553-3.1447-7-7-7zm0 1.75c2.9103 0 5.25 2.3398 5.25 5.25 0 1.4192-0.55825 2.7011-1.4665 3.6435l-3.7835-3.6435z" /> +</svg> diff --git a/apps/files/templates/appnavigation.php b/apps/files/templates/appnavigation.php index bbd78079d39..09b02943688 100644 --- a/apps/files/templates/appnavigation.php +++ b/apps/files/templates/appnavigation.php @@ -1,6 +1,17 @@ <div id="app-navigation"> <ul class="with-icon"> - <li id="quota" class="section <?php + <?php $pinned = 0 ?> + <?php foreach ($_['navigationItems'] as $item) { + strpos($item['classes'], 'pinned')!==false ? $pinned++ : ''; + ?> + <li data-id="<?php p($item['id']) ?>" class="nav-<?php p($item['id']) ?> <?php p($item['classes']) ?> <?php p($pinned===1?'first-pinned':'') ?>"> + <a href="<?php p(isset($item['href']) ? $item['href'] : '#') ?>" + class="nav-icon-<?php p($item['icon'] !== '' ? $item['icon'] : $item['id']) ?> svg"> + <?php p($item['name']);?> + </a> + </li> + <?php } ?> + <li id="quota" class="section pinned <?php if ($_['quota'] !== \OCP\Files\FileInfo::SPACE_UNLIMITED) { ?>has-tooltip" title="<?php p($_['usage_relative'] . '%'); } ?>"> @@ -18,14 +29,6 @@ </div> </a> </li> - <?php foreach ($_['navigationItems'] as $item) { ?> - <li data-id="<?php p($item['id']) ?>" class="nav-<?php p($item['id']) ?>"> - <a href="<?php p(isset($item['href']) ? $item['href'] : '#') ?>" - class="nav-icon-<?php p($item['icon'] !== '' ? $item['icon'] : $item['id']) ?> svg"> - <?php p($item['name']);?> - </a> - </li> - <?php } ?> </ul> <div id="app-settings"> <div id="app-settings-header"> diff --git a/apps/files/tests/Controller/ViewControllerTest.php b/apps/files/tests/Controller/ViewControllerTest.php index e0965d43143..007335b948d 100644 --- a/apps/files/tests/Controller/ViewControllerTest.php +++ b/apps/files/tests/Controller/ViewControllerTest.php @@ -142,6 +142,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'recent', @@ -152,6 +153,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'favorites', @@ -162,6 +164,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'sharingin', @@ -172,6 +175,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'sharingout', @@ -182,6 +186,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'sharinglinks', @@ -192,6 +197,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'systemtagsfilter', @@ -202,6 +208,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => '', ], [ 'id' => 'trashbin', @@ -212,6 +219,7 @@ class ViewControllerTest extends TestCase { 'active' => false, 'icon' => '', 'type' => 'link', + 'classes' => 'pinned', ], ]); |