Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dont merge] branch page some enhancements (-> PRs #7602 #7603 #7604) #7520

Closed
wants to merge 32 commits into from
Closed
Show file tree
Hide file tree
Changes from 17 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
5441182
add download butons (template from home.tmpl)
6543 Jul 18, 2019
d9fc4a2
add $
6543 Jul 18, 2019
b6b22d9
add download buton, when no user logon
6543 Jul 18, 2019
bce9f3a
fix download menue of default branch
6543 Jul 19, 2019
f524cd8
fix download menue (dont fly away)
6543 Jul 19, 2019
0e92e5f
mv download buton in extra colum
6543 Jul 19, 2019
27880b0
commit x/y diagram doesnt break
6543 Jul 19, 2019
c9d98c8
show protected symbol onece
6543 Jul 19, 2019
d75e2b4
add download colum
6543 Jul 19, 2019
8fba697
correct placement
6543 Jul 19, 2019
05463ca
switch colum download <-> delete
6543 Jul 19, 2019
1b9918f
found css style wich position the menue
6543 Jul 19, 2019
0e1405c
del useless inline css
6543 Jul 19, 2019
63a714f
add needet css to less file
6543 Jul 19, 2019
cae8ab5
update css with "make css"
6543 Jul 19, 2019
2337499
template: switch from inline css to less
6543 Jul 19, 2019
f5fb8c9
use wrong values because of browser caching
6543 Jul 19, 2019
fa1521e
all buttons with border
6543 Jul 22, 2019
f31cb05
add Translation for button Messages
6543 Jul 22, 2019
b934303
Add Message to Button
6543 Jul 22, 2019
dad98cf
delete table header because of overhead
6543 Jul 22, 2019
bcaea37
dont ned position absolute for download anymore
6543 Jul 22, 2019
ce87533
rm ugly css
6543 Jul 22, 2019
81a7a01
add css class download-column
6543 Jul 22, 2019
15eead7
use css class download-column
6543 Jul 22, 2019
33d54e1
follow Contirb guidlines
6543 Jul 22, 2019
e8c4217
name things corectly
6543 Jul 22, 2019
190ba85
Merge branch 'master' into wip-branch-page-add-download
6543 Jul 22, 2019
eac8103
also change info message on default branch
6543 Jul 23, 2019
a178dff
Merge remote-tracking branch 'main/master' into wip-branch-page-add-d…
6543 Jul 23, 2019
1d98e88
Apply suggestions from code review
6543 Jul 23, 2019
99470a8
remove diff for merge
6543 Jul 24, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions public/css/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,7 @@ footer .ui.left,footer .ui.right{line-height:40px}
.repository.branches .commit-divergence .bar{height:4px;position:absolute;background-color:#d4d4d5}
.repository.branches .commit-divergence .bar.bar-behind{right:0}
.repository.branches .commit-divergence .bar.bar-ahead{left:0}
.repository.branches .dlmenu{position:absolute;margin-left:-38px;margin-top:-18px}
.repository.commits .header .search input{font-weight:400;padding:5px 10px}
.repository #commits-table thead th:first-of-type{padding-left:15px}
.repository #commits-table thead .sha{width:140px}
Expand Down
5 changes: 5 additions & 0 deletions public/less/_repository.less
Original file line number Diff line number Diff line change
Expand Up @@ -1233,6 +1233,11 @@
}
}
}
.dlmenu {
position: absolute;
margin-left: -38px;
margin-top: -18px;
}
6543 marked this conversation as resolved.
Show resolved Hide resolved
}

&.commits {
Expand Down
32 changes: 25 additions & 7 deletions templates/repo/branch/list.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,15 @@
{{end}}
{{end}}
</td>
<td class="right aligned">
<div class="ui basic jump dropdown icon button poping up dlmenu" data-content="{{$.i18n.Tr "repo.download_archive"}}" data-variation="tiny inverted" data-position="top right">
<i class="download icon"></i>
<div class="menu">
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.DefaultBranch}}.zip"><i class="octicon octicon-file-zip"></i> ZIP</a>
<a class="item" href="{{$.RepoLink}}/archive/{{EscapePound $.DefaultBranch}}.tar.gz"><i class="octicon octicon-file-zip"></i> TAR.GZ</a>
</div>
</div>
</td>
</tr>
</tbody>
</table>
Expand All @@ -37,10 +46,11 @@
<thead>
<tr>
<th class="six wide">{{.i18n.Tr "repo.branch.name"}}</th>
<th class="three wide"></th>
<th class="two wide"></th>
<th class="two wide"></th>
<th class="one wide right alinged"></th>
{{if and $.IsWriter (not $.IsMirror)}}
<th class="one wide right aligned">{{.i18n.Tr "repo.branch.delete_head"}}</th>
<th class="one wide">{{.i18n.Tr "repo.branch.delete_head"}}</th>
{{end}}
</tr>
</thead>
Expand All @@ -53,9 +63,6 @@
<s><a href="{{$.RepoLink}}/src/branch/{{.Name | EscapePound}}">{{.Name}}</a></s>
<p class="info">{{$.i18n.Tr "repo.branch.deleted_by" .DeletedBranch.DeletedBy.Name}} {{TimeSinceUnix .DeletedBranch.DeletedUnix $.i18n.Lang}}</p>
{{else}}
{{if .IsProtected}}
6543 marked this conversation as resolved.
Show resolved Hide resolved
<i class="octicon octicon-shield"></i>
{{end}}
<a href="{{$.RepoLink}}/src/branch/{{.Name | EscapePound}}">{{.Name}}</a>
<p class="info"><i class="octicon octicon-git-commit"></i><a href="{{$.RepoLink}}/commit/{{.Commit.ID.String}}">{{ShortSha .Commit.ID.String}}</a> · <span class="commit-message">{{RenderCommitMessage .Commit.CommitMessage $.RepoLink $.Repository.ComposeMetas}}</span> · {{$.i18n.Tr "org.repo_updated"}} {{TimeSince .Commit.Committer.When $.i18n.Lang}}</p>
{{end}}
Expand All @@ -69,7 +76,7 @@
</div>
<div class="bar-group">
<div class="count count-ahead">{{.CommitsAhead}}</div>
<div class="bar bar-ahead" style="width: {{percentage .CommitsAhead .CommitsBehind .CommitsAhead}}%"></div>
<div class="bar bar-ahead" style="width: {{percentage .CommitsAhead .CommitsBehind .CommitsAhead}}%"></div>
</div>
</div>
{{end}}
Expand All @@ -92,8 +99,19 @@
{{end}}
{{end}}
</td>
<td class="right aligned">
{{if not .IsDeleted}}
<div class="ui basic jump dropdown icon button poping up dlmenu" data-content="{{$.i18n.Tr "repo.download_archive"}}" data-variation="tiny inverted" data-position="top right">
<i class="download icon"></i>
<div class="menu">
<a class="item" href="{{$.RepoLink}}/archive/{{.Name | EscapePound}}.zip"><i class="octicon octicon-file-zip"></i> ZIP</a>
<a class="item" href="{{$.RepoLink}}/archive/{{.Name | EscapePound}}.tar.gz"><i class="octicon octicon-file-zip"></i> TAR.GZ</a>
</div>
</div>
{{end}}
</td>
{{if and $.IsWriter (not $.IsMirror)}}
<td class="right aligned">
<td class="center aligned">
{{if .IsProtected}}
<i class="octicon octicon-shield"></i>
{{else if .IsDeleted}}
Expand Down