diff options
author | fnuesse <felix.nuesse@t-online.de> | 2018-06-27 00:35:28 +0200 |
---|---|---|
committer | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2018-07-12 16:49:38 +0200 |
commit | 55ebdc9344dc8edb665491bf89595f406cfc4d62 (patch) | |
tree | 23bdc47aea07adf307dc70718d427acb17eb3e92 /apps/files/templates | |
parent | 9b914bd68dc53d5fe5ac98e9bbeb3b8da436096e (diff) | |
download | nextcloud-server-55ebdc9344dc8edb665491bf89595f406cfc4d62.tar.gz nextcloud-server-55ebdc9344dc8edb665491bf89595f406cfc4d62.zip |
Fix collapsible-Button when list was emptied (or got first element)
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Fixed Bad url-generation in javascript for new quickaccessitems
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Fixed vertical scrolling in sortable-list which leads to "hidden" navbar
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Removed unnessessary console logs
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Fixed Bounds in custom sorting
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Reformatted code
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Fixed horizontalscroll on sortable-list
Fixed "stuck element" where you could not switch back to the original ordering in the sortable-list
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Diffstat (limited to 'apps/files/templates')
-rw-r--r-- | apps/files/templates/appnavigation.php | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/apps/files/templates/appnavigation.php b/apps/files/templates/appnavigation.php index 56a84edf3b6..1302225c919 100644 --- a/apps/files/templates/appnavigation.php +++ b/apps/files/templates/appnavigation.php @@ -5,7 +5,7 @@ $pinned = 0; foreach ($_['navigationItems'] as $item) { - $pinned = NavigationListElements($item, $pinned, $l); + $pinned = NavigationListElements($item, $l, $pinned); } ?> @@ -58,18 +58,18 @@ * Prints the HTML for a single Entry. * * @param $item The item to be added - * @param $pinned IntegerValue to count the pinned entries at the bottom * @param $l Translator + * @param $pinned IntegerValue to count the pinned entries at the bottom * * @return int Returns the pinned value */ -function NavigationListElements($item, $pinned, $l) { +function NavigationListElements($item, $l, $pinned) { strpos($item['classes'], 'pinned') !== false ? $pinned++ : ''; ?> <li <?php if (isset($item['sublist'])){ ?>id="button-collapse-parent-<?php p($item['id']); ?>"<?php } ?> data-id="<?php p(isset($item['href']) ? $item['href'] : $item['id']) ?> " class="nav-<?php p($item['id']) ?> <?php p($item['classes']) ?> <?php p($pinned === 1 ? 'first-pinned' : '') ?> <?php if ($item['defaultExpandedState'] === 'true') { ?> open<?php } ?>" - <?php if (isset($item['folderPosition'])) { ?> folderPos="<?php p($item['folderPosition']); ?>" <?php } ?>> + <?php if (isset($item['folderPosition'])) { ?> folderposition="<?php p($item['folderPosition']); ?>" <?php } ?>> <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> @@ -80,11 +80,11 @@ function NavigationListElements($item, $pinned, $l) { if (isset($item['sublist'])) { ?> <button id="button-collapse-<?php p($item['id']); ?>" - class="collapse"></button> - <ul id="sublist-<?php p($item['id']); ?>" <?php if ($item['draggableSublist'] === 'true') { ?> draggable="true"<?php } ?>> + class="collapse" <?php if (sizeof($item['sublist']) == 0) { ?> style="display: none" <?php } ?>></button> + <ul id="sublist-<?php p($item['id']); ?>" <?php if ($item['draggableSublist'] === 'true') { ?> draggable="true" style="resize: none;"<?php } ?>> <?php foreach ($item['sublist'] as $item) { - $pinned = NavigationListElements($item, $pinned, $l); + $pinned = NavigationListElements($item, $l, $pinned); } ?> </ul> |