0
0
Fork 0
mirror of https://github.com/go-gitea/gitea synced 2024-10-30 18:59:12 +01:00
gitea/templates
Nanguan Lin db545b208b
Implement actions badge svgs (#28102)
replace #27187 
close #23688
The badge has two parts: label(workflow name) and message(action
status). 5 colors are provided with 7 statuses.
Color mapping:
```go
var statusColorMap = map[actions_model.Status]string{
	actions_model.StatusSuccess:   "#4c1",    // Green
	actions_model.StatusSkipped:   "#dfb317", // Yellow
	actions_model.StatusUnknown:   "#97ca00", // Light Green
	actions_model.StatusFailure:   "#e05d44", // Red
	actions_model.StatusCancelled: "#fe7d37", // Orange
	actions_model.StatusWaiting:   "#dfb317", // Yellow
	actions_model.StatusRunning:   "#dfb317", // Yellow
	actions_model.StatusBlocked:   "#dfb317", // Yellow
}
```
preview:

![1](https://github.com/go-gitea/gitea/assets/70063547/5465cbaf-23cd-4437-9848-2738c3cb8985)

![2](https://github.com/go-gitea/gitea/assets/70063547/ec393d26-c6e6-4d38-b72c-51f2494c5e71)

![3](https://github.com/go-gitea/gitea/assets/70063547/3edb4fdf-1b08-4a02-ab2a-6bdd7f532fb2)

![4](https://github.com/go-gitea/gitea/assets/70063547/8c189de2-2169-4251-b115-0e39a52f3df8)

![5](https://github.com/go-gitea/gitea/assets/70063547/3fe22c73-c2d7-4fec-9ea4-c501a1e4e3bd)

---------

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Co-authored-by: Giteabot <teabot@gitea.io>
Co-authored-by: delvh <dev.lh@web.de>
2024-02-27 18:56:18 +01:00
..
admin Use tailwind instead of gt-[wh]- helper classes (#29423) 2024-02-27 14:31:41 +00:00
api/packages/pypi Remove incorrect HTML self close tag (#23748) 2023-03-27 18:05:51 +02:00
base Use tailwind instead of gt-[wh]- helper classes (#29423) 2024-02-27 14:31:41 +00:00
code Remove incorrect and unnecessary Escape from templates (#29394) 2024-02-25 14:02:20 +00:00
custom
devtest Use tailwind instead of gt-[wh]- helper classes (#29423) 2024-02-27 14:31:41 +00:00
explore Only use supported sort order for "explore/users" page (#29430) 2024-02-27 17:10:51 +08:00
mail Fix mail template error (#29410) 2024-02-26 22:31:30 +00:00
org Refactor Safe modifier (#29392) 2024-02-25 10:45:56 +00:00
package Remove incorrect and unnecessary Escape from templates (#29394) 2024-02-25 14:02:20 +00:00
projects Use full width for project boards (#28225) 2023-11-27 17:43:52 +00:00
repo Use tailwind instead of gt-[wh]- helper classes (#29423) 2024-02-27 14:31:41 +00:00
shared Implement actions badge svgs (#28102) 2024-02-27 18:56:18 +01:00
status Use tailwind instead of gt-[wh]- helper classes (#29423) 2024-02-27 14:31:41 +00:00
swagger Add API to get PR by base/head (#29242) 2024-02-26 02:39:01 +00:00
user Allow to change primary email before account activation (#29412) 2024-02-27 10:55:13 +00:00
webhook Change webhook-type in create-view (#29114) 2024-02-15 14:59:48 +01:00
home.tmpl Remove unnecessary "Str2html" modifier from templates (#29319) 2024-02-22 18:05:47 +00:00
install.tmpl Remove unnecessary "Safe" modifier from templates (#29318) 2024-02-22 17:02:33 +00:00
post-install.tmpl Always use ctx.Locale.Tr inside templates (#27231) 2023-09-25 08:56:50 +00:00