1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2025-08-03 00:45:22 +02:00

[Feature] Custom Reactions (#8886)

* add [ui] Reactions

* move contend check from form to go functions

* use else if

* check if reaction is allowed only on react
(so previous custom reaction can be still removed)

* use $.AllowedReactions in templates

* use ctx.Flash.Error

* use it there too

* add redirection

* back to server error
because a wrong reaction is a template issue ...

* add emoji list link

* add docs entry

* small wording nit
suggestions from @jolheiser - thx

* same reactions as github

* fix PR reactions

* handle error so template JS could check

* Add Integrations Test

* add REACTIONS setting to cheat-sheet doc page
This commit is contained in:
6543 2019-12-01 23:57:24 +01:00 committed by techknowlogick
parent 674bc772fb
commit 668eaf95d5
13 changed files with 76 additions and 18 deletions

View file

@ -422,6 +422,7 @@ func PrepareViewPullInfo(ctx *context.Context, issue *models.Issue) *git.Compare
ctx.Data["NumCommits"] = compareInfo.Commits.Len()
ctx.Data["NumFiles"] = compareInfo.NumFiles
ctx.Data["AllowedReactions"] = setting.UI.Reactions
return compareInfo
}