You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gitea/templates
wxiaoguang 8820191476
Improve template helper functions: string/slice (#24266)
Follow #23328

The improvements:

1. The `contains` functions are covered by tests
2. The inconsistent behavior of `containGeneric` is replaced by
`StringUtils.Contains` and `SliceUtils.Contains`
3. In the future we can move more help functions into XxxUtils to
simplify the `helper.go` and reduce unnecessary global functions.

FAQ:

1. Why it's called `StringUtils.Contains` but not `strings.Contains`
like Golang?

Because our `StringUtils` is not Golang's `strings` package. There will
be our own string functions.

---------

Co-authored-by: silverwind <me@silverwind.io>
2 years ago
..
admin Use auto-updating, natively hoverable, localized time elements (#23988) 2 years ago
api/packages/pypi Remove incorrect HTML self close tag (#23748) 2 years ago
base Fix footer display (#24251) 2 years ago
code Use data-tooltip-content for tippy tooltip (#23649) 2 years ago
custom Add footer extra links template (#9576) 5 years ago
devtest Refactor locale number (#24134) 2 years ago
explore Use auto-updating, natively hoverable, localized time elements (#23988) 2 years ago
mail Remove incorrect HTML self close tag (#23748) 2 years ago
org Limit avatar upload to valid image files (#24258) 2 years ago
package Remove untranslatable `on_date` key (#24106) 2 years ago
projects Add unset default project column (#23531) 2 years ago
repo Improve template helper functions: string/slice (#24266) 2 years ago
shared Add monospace toggle button to textarea (#24034) 2 years ago
status Show friendly 500 error page to users and developers (#24110) 2 years ago
swagger Add activity feeds API (#23494) 2 years ago
user Limit avatar upload to valid image files (#24258) 2 years ago
home.tmpl Improve home page template, fix Sort dropdown menu flash (#23856) 2 years ago
install.tmpl Remove incorrect HTML self close tag (#23748) 2 years ago
post-install.tmpl Remove incorrect HTML self close tag (#23748) 2 years ago