diff options
author | silverwind <me@silverwind.io> | 2022-08-08 01:15:11 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-08 02:15:11 +0300 |
commit | abdebd2641e162791144fbd57acf480b4640baa8 (patch) | |
tree | 82554b58344e66a749957ee52196a99bb1827e45 /templates/repo/clone_buttons.tmpl | |
parent | be824890e4abac05526248fe8aed8eca6aceb1da (diff) | |
download | gitea-abdebd2641e162791144fbd57acf480b4640baa8.tar.gz gitea-abdebd2641e162791144fbd57acf480b4640baa8.zip |
Rework repo buttons (#20602)
* Rework repo buttons
- Replace "New PR" and "Go to File" button with Icon Button
- Move all "Add File" actions into a dropdown button
- Remove most custom styling of clone buttons
- Margin and wiki tweaks
Buttons are now all equal height, mobile layout wraps gracefully.
Fixes: https://github.com/go-gitea/gitea/issues/13671
Replaces: https://github.com/go-gitea/gitea/pull/20375
Co-authored-by: Lauris BH <lauris@nix.lv>
Co-authored-by: zeripath <art27@cantab.net>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'templates/repo/clone_buttons.tmpl')
-rw-r--r-- | templates/repo/clone_buttons.tmpl | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/templates/repo/clone_buttons.tmpl b/templates/repo/clone_buttons.tmpl index 0d0fe73014..7fb435e3c7 100644 --- a/templates/repo/clone_buttons.tmpl +++ b/templates/repo/clone_buttons.tmpl @@ -1,15 +1,15 @@ <!-- there is always at least one button (by context/repo.go) --> {{if $.CloneButtonShowHTTPS}} - <button class="ui basic clone button no-transition" id="repo-clone-https" data-link="{{$.CloneButtonOriginLink.HTTPS}}"> + <button class="ui basic small compact clone button no-transition" id="repo-clone-https" data-link="{{$.CloneButtonOriginLink.HTTPS}}"> {{if UseHTTPS}}HTTPS{{else}}HTTP{{end}} </button> {{end}} {{if $.CloneButtonShowSSH}} - <button class="ui basic clone button no-transition" id="repo-clone-ssh" data-link="{{$.CloneButtonOriginLink.SSH}}"> + <button class="ui basic small compact clone button no-transition" id="repo-clone-ssh" data-link="{{$.CloneButtonOriginLink.SSH}}"> SSH </button> {{end}} -<input id="repo-clone-url" class="js-clone-url" value="{{$.CloneButtonOriginLink.HTTPS}}" size="1" readonly> -<button class="ui basic icon button tooltip" id="clipboard-btn" data-content="{{.locale.Tr "copy_url"}}" data-clipboard-target="#repo-clone-url" aria-label="{{.locale.Tr "copy_url"}}"> - {{svg "octicon-paste"}} +<input id="repo-clone-url" size="20" class="js-clone-url br-0" value="{{$.CloneButtonOriginLink.HTTPS}}" readonly> +<button class="ui basic small compact icon button tooltip" id="clipboard-btn" data-content="{{.locale.Tr "copy_url"}}" data-clipboard-target="#repo-clone-url" aria-label="{{.locale.Tr "copy_url"}}"> + {{svg "octicon-copy" 14}} </button> |