forked from NYANDEV/forgejo
Backport emoji fixes to 1.12 (#12327)
* Fix emoji detection in certain cases (#12320) * Fix emoji detection certain cases Previous tests weren't complicated enough so there were some situations where emojis were't detected properly. Find the earliest occurance in addition to checking for the longest combination. Fixes #12312 * ok spell bot Co-authored-by: Lauris BH <lauris@nix.lv> * Reduce emoji size (#12317) * Reduce emoji size Rendering should now pretty much match GitHub with 1.25em. I verified that emojis don't increase the line height and removed unecessary size overrides because now all emojis should appear similar in relation to the font size. * fix reaction hover Co-authored-by: mrsdizzie <info@mrsdizzie.com> Co-authored-by: Lauris BH <lauris@nix.lv>
This commit is contained in:
parent
8d1cd4d252
commit
ad68c9ccb2
4 changed files with 27 additions and 21 deletions
|
@ -266,6 +266,10 @@ func TestRender_emoji(t *testing.T) {
|
|||
test(
|
||||
"Some text with ππ 2 emoji next to each other",
|
||||
`<p>Some text with <span class="emoji" aria-label="grinning face with smiling eyes">π</span><span class="emoji" aria-label="grinning face with smiling eyes">π</span> 2 emoji next to each other</p>`)
|
||||
test(
|
||||
"ππ€ͺππ€β",
|
||||
`<p><span class="emoji" aria-label="smiling face with sunglasses">π</span><span class="emoji" aria-label="zany face">π€ͺ</span><span class="emoji" aria-label="locked with key">π</span><span class="emoji" aria-label="money-mouth face">π€</span><span class="emoji" aria-label="question mark">β</span></p>`)
|
||||
|
||||
// should match nothing
|
||||
test(
|
||||
"2001:0db8:85a3:0000:0000:8a2e:0370:7334",
|
||||
|
|
Loadingβ¦
Add table
Add a link
Reference in a new issue