aboutsummaryrefslogtreecommitdiffstats
path: root/templates/repo/issue
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2023-06-22 12:27:35 +0200
committerGitHub <noreply@github.com>2023-06-22 10:27:35 +0000
commitaf094fbb6c066ba2e02b812dc3e5875d46e0db42 (patch)
treef3d45e5337ee8bf8e94730295338f4e42dd614ed /templates/repo/issue
parentff90c87c878b03e7beabac5f19396e0db2c25a1e (diff)
downloadgitea-af094fbb6c066ba2e02b812dc3e5875d46e0db42.tar.gz
gitea-af094fbb6c066ba2e02b812dc3e5875d46e0db42.zip
Introduce shared template for search inputs (#25338)
- Set [type=search](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/search) - Disable spellcheck - Set maxLength 255 that I found in `templates/repo/issue/search.tmpl` - Remove unnecessary `max-width`, it does nothing --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Giteabot <teabot@gitea.io>
Diffstat (limited to 'templates/repo/issue')
-rw-r--r--templates/repo/issue/milestones.tmpl2
-rw-r--r--templates/repo/issue/search.tmpl2
2 files changed, 2 insertions, 2 deletions
diff --git a/templates/repo/issue/milestones.tmpl b/templates/repo/issue/milestones.tmpl
index da239b694a..6655c70029 100644
--- a/templates/repo/issue/milestones.tmpl
+++ b/templates/repo/issue/milestones.tmpl
@@ -28,7 +28,7 @@
<form class="list-header-search ui form ignore-dirty">
<div class="ui small search fluid action input">
<input type="hidden" name="state" value="{{$.State}}">
- <input name="q" value="{{.Keyword}}" placeholder="{{.locale.Tr "explore.search"}}...">
+ {{template "shared/searchinput" dict "locale" .locale "Value" .Keyword}}
<button class="ui small icon button" type="submit" aria-label="{{.locale.Tr "explore.search"}}">
{{svg "octicon-search"}}
</button>
diff --git a/templates/repo/issue/search.tmpl b/templates/repo/issue/search.tmpl
index 13224680bd..ec7789b952 100644
--- a/templates/repo/issue/search.tmpl
+++ b/templates/repo/issue/search.tmpl
@@ -7,7 +7,7 @@
<input type="hidden" name="project" value="{{$.ProjectID}}">
<input type="hidden" name="assignee" value="{{$.AssigneeID}}">
<input type="hidden" name="poster" value="{{$.PosterID}}">
- <input name="q" value="{{.Keyword}}" placeholder="{{.locale.Tr "explore.search"}}..." maxlength="255">
+ {{template "shared/searchinput" dict "locale" .locale "Value" .Keyword}}
{{if .PageIsIssueList}}
<button id="issue-list-quick-goto" class="ui small icon button gt-hidden" data-tooltip-content="{{.locale.Tr "explore.go_to"}}" data-repo-link="{{.RepoLink}}">{{svg "octicon-hash"}}</button>
{{end}}