mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-01 13:01:15 +00:00
7263b3effe
It's now possible to change webhook-type in create-view. before: ![image](https://github.com/go-gitea/gitea/assets/72873130/9ee1b9fb-843b-4f28-b8d6-6361e5d184f1) after: ![image](https://github.com/go-gitea/gitea/assets/72873130/9dbf058f-5912-43af-9acd-487271212f2d) --------- Co-authored-by: silverwind <me@silverwind.io> Co-authored-by: Giteabot <teabot@gitea.io> (cherry picked from commit 374e886f5113a996e1e927a60d1775e77262c364) Conflicts: templates/repo/settings/webhook/base_list.tmpl templates/shared/webhook/icon.tmpl
30 lines
1.4 KiB
Go HTML Template
30 lines
1.4 KiB
Go HTML Template
{{$size := 26}}
|
|
{{if .Size}}
|
|
{{$size = .Size}}
|
|
{{end}}
|
|
{{if eq .HookType "forgejo"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/forgejo.svg">
|
|
{{else if eq .HookType "gitea"}}
|
|
{{svg "gitea-gitea" $size "img"}}
|
|
{{else if eq .HookType "gogs"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/gogs.ico">
|
|
{{else if eq .HookType "slack"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/slack.png">
|
|
{{else if eq .HookType "discord"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/discord.png">
|
|
{{else if eq .HookType "dingtalk"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/dingtalk.ico">
|
|
{{else if eq .HookType "telegram"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/telegram.png">
|
|
{{else if eq .HookType "msteams"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/msteams.png">
|
|
{{else if eq .HookType "feishu"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/feishu.png">
|
|
{{else if eq .HookType "matrix"}}
|
|
{{svg "gitea-matrix" $size "img"}}
|
|
{{else if eq .HookType "wechatwork"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/wechatwork.png">
|
|
{{else if eq .HookType "packagist"}}
|
|
<img width="{{$size}}" height="{{$size}}" src="{{AssetUrlPrefix}}/img/packagist.png">
|
|
{{end}}
|