summaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
authorFlorian Zschocke <florian.zschocke@devolo.de>2019-06-15 21:09:36 +0200
committerFlorian Zschocke <florian.zschocke@devolo.de>2019-06-15 21:09:36 +0200
commit988ef6b2f0e39a8f4cbda52bf419578a2675704a (patch)
tree54b3fc4817e096079295e0d624beeab271098402 /src/main
parent0bace7e0323ed7f4c7e773f647f6d73f563dea38 (diff)
downloadgitblit-988ef6b2f0e39a8f4cbda52bf419578a2675704a.tar.gz
gitblit-988ef6b2f0e39a8f4cbda52bf419578a2675704a.zip
Remove "folding outlines" and sort repositories before subfolders.
Remove guard rails at the left to get a cleaner look. To make it easier to determine which repositories belong to which folder, display the repositories first, then the subfolder. Decreased indentation a little.
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.html10
-rw-r--r--src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.java30
-rw-r--r--src/main/resources/gitblit.css1
3 files changed, 22 insertions, 19 deletions
diff --git a/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.html b/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.html
index 5f2aba21..5dfd27af 100644
--- a/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.html
+++ b/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.html
@@ -6,14 +6,11 @@
<body>
<wicket:panel>
<tr style="background-color: #bbb" wicket:id="nodeHeader" data-row-type="folder"></tr>
- <tr wicket:id="subFolders">
- <span wicket:id="rowContent"></span>
- </tr>
<wicket:container wicket:id="repositories">
<tr wicket:id="rowContent" data-row-type="repo">
<td wicket:id="firstColumn" class="left"
style="padding-left: 3px;">
- <div style="border-left: 1px solid black; margin-left:6px; width: 19px;display: inline-block;float: left;"
+ <div style="margin-left: 7px; width: 8px;display: inline-block;float: left;"
wicket:id="depth">&nbsp;</div>
<span wicket:id="repoIcon"></span><span
style="padding-left: 3px;" wicket:id="repositoryName">[repository
@@ -36,6 +33,9 @@
size]</span></td>
</tr>
</wicket:container>
+ <tr wicket:id="subFolders">
+ <span wicket:id="rowContent"></span>
+ </tr>
<wicket:fragment wicket:id="emptyFragment">
</wicket:fragment>
@@ -91,7 +91,7 @@
<wicket:fragment wicket:id="groupRepositoryRow">
<td wicket:id="firstColumn" style="" colspan="1">
- <div style="border-left: 1px solid black; margin-left:6px; width: 19px; display: inline-block;float: left;"
+ <div style="margin-left:6px; width: 10px; display: inline-block;float: left;"
wicket:id="depth">&nbsp;</div>
<span
wicket:id="groupCollapsible"></span><span wicket:id="groupName">[group
diff --git a/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.java b/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.java
index fbe1991d..cc5df1a1 100644
--- a/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.java
+++ b/src/main/java/com/gitblit/wicket/panels/NestedRepositoryTreePanel.java
@@ -68,20 +68,6 @@ public class NestedRepositoryTreePanel extends BasePanel {
}
WicketUtils.addCssClass(nodeHeader, "group collapsible tree");
- add(new ListView<TreeNodeModel>("subFolders", node.getSubFolders()) {
- private static final long serialVersionUID = 1L;
-
- @Override
- protected void populateItem(ListItem<TreeNodeModel> item) {
- item.add(new NestedRepositoryTreePanel("rowContent", item.getModel(), accessRestrictionTranslations, linksActive));
- }
-
- @Override
- public boolean isVisible() {
- return super.isVisible() && !node.getSubFolders().isEmpty();
- }
- });
-
add(new ListView<RepositoryModel>("repositories", node.getRepositories()) {
private static final long serialVersionUID = 1L;
@@ -220,6 +206,22 @@ public class NestedRepositoryTreePanel extends BasePanel {
}
});
+ add(new ListView<TreeNodeModel>("subFolders", node.getSubFolders()) {
+ private static final long serialVersionUID = 1L;
+
+ @Override
+ protected void populateItem(ListItem<TreeNodeModel> item) {
+ item.add(new NestedRepositoryTreePanel("rowContent", item.getModel(), accessRestrictionTranslations, linksActive));
+ }
+
+ @Override
+ public boolean isVisible() {
+ return super.isVisible() && !node.getSubFolders().isEmpty();
+ }
+ });
+
+
+
}
private void addChildOfNodeIdCssClassesToRow(Component row, TreeNodeModel parentNode) {
diff --git a/src/main/resources/gitblit.css b/src/main/resources/gitblit.css
index 5dabbec2..f7271788 100644
--- a/src/main/resources/gitblit.css
+++ b/src/main/resources/gitblit.css
@@ -45,6 +45,7 @@ a.bugtraq {
.octicon-centered {
text-align: center;
width: 16px;
+ padding-left: 17px;
}
tr:hover .octicon-centered {