diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-08-31 10:29:59 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-31 02:29:59 +0000 |
commit | 19a1e1b20ee45f02908c915c8540baab1396899c (patch) | |
tree | cceca2b1d7682a3d8420665910bea92a35df924b /templates/repo/wiki | |
parent | 98f2bf23bc57d734471a08e396c687be6d194313 (diff) | |
download | gitea-19a1e1b20ee45f02908c915c8540baab1396899c.tar.gz gitea-19a1e1b20ee45f02908c915c8540baab1396899c.zip |
Remove polluted `.ui.right` (#26825)
Each change is tested manually line by line. There are too many changes
so I can't share dozens of screenshots.
In short:
1. `ui right` could be still used in `ui top attached header`, because
there is a special case.
2. A lot of `ui right` are just no-op, so they can be removed safely.
3. Some of the `ui right` should be replaced by `gt-float-right` (to
avoid breaking, leave them to the future).
4. A few of the `ui right` could be rewritten by flex.
Diffstat (limited to 'templates/repo/wiki')
-rw-r--r-- | templates/repo/wiki/new.tmpl | 6 | ||||
-rw-r--r-- | templates/repo/wiki/view.tmpl | 4 |
2 files changed, 4 insertions, 6 deletions
diff --git a/templates/repo/wiki/new.tmpl b/templates/repo/wiki/new.tmpl index cda1924544..2098a76755 100644 --- a/templates/repo/wiki/new.tmpl +++ b/templates/repo/wiki/new.tmpl @@ -3,12 +3,10 @@ {{template "repo/header" .}} <div class="ui container"> {{template "base/alert" .}} - <div class="ui header"> + <div class="ui header flex-text-block gt-sb"> {{.locale.Tr "repo.wiki.new_page"}} {{if .PageIsWikiEdit}} - <div class="ui right gt-mb-3"> - <a class="ui green tiny button" href="{{.RepoLink}}/wiki?action=_new">{{.locale.Tr "repo.wiki.new_page_button"}}</a> - </div> + <a class="ui green tiny button" href="{{.RepoLink}}/wiki?action=_new">{{.locale.Tr "repo.wiki.new_page_button"}}</a> {{end}} </div> <form class="ui form" action="{{.Link}}?action={{if .PageIsWikiEdit}}_edit{{else}}_new{{end}}" method="post"> diff --git a/templates/repo/wiki/view.tmpl b/templates/repo/wiki/view.tmpl index a1b22d52c0..be59064d2b 100644 --- a/templates/repo/wiki/view.tmpl +++ b/templates/repo/wiki/view.tmpl @@ -79,7 +79,7 @@ {{if .sidebarPresent}} <div class="markup wiki-content-sidebar"> {{if and .CanWriteWiki (not .Repository.IsMirror)}} - <a class="ui right floated muted" href="{{.RepoLink}}/wiki/_Sidebar?action=_edit" aria-label="{{.locale.Tr "repo.wiki.edit_page_button"}}">{{svg "octicon-pencil"}}</a> + <a class="gt-float-right muted" href="{{.RepoLink}}/wiki/_Sidebar?action=_edit" aria-label="{{.locale.Tr "repo.wiki.edit_page_button"}}">{{svg "octicon-pencil"}}</a> {{end}} {{template "repo/unicode_escape_prompt" dict "EscapeStatus" .sidebarEscapeStatus "root" $}} {{.sidebarContent | Safe}} @@ -91,7 +91,7 @@ {{if .footerPresent}} <div class="markup wiki-content-footer"> {{if and .CanWriteWiki (not .Repository.IsMirror)}} - <a class="ui right floated muted" href="{{.RepoLink}}/wiki/_Footer?action=_edit" aria-label="{{.locale.Tr "repo.wiki.edit_page_button"}}">{{svg "octicon-pencil"}}</a> + <a class="gt-float-right muted" href="{{.RepoLink}}/wiki/_Footer?action=_edit" aria-label="{{.locale.Tr "repo.wiki.edit_page_button"}}">{{svg "octicon-pencil"}}</a> {{end}} {{template "repo/unicode_escape_prompt" dict "footerEscapeStatus" .sidebarEscapeStatus "root" $}} {{.footerContent | Safe}} |