mirror of
https://github.com/zulip/zulip.git
synced 2025-11-03 13:33:24 +00:00
emoji: Refactor get_emoji_details_by_name function.
This is a prep commit for typescript migration of `emoji.js`. This commit refactors the code for generating emoji rendering details such that we avoid writing an ugly code which will involve writing an incomplete type object when we migrate to TypeScript.
This commit is contained in:
@@ -76,6 +76,7 @@ run_test("get_emoji_details_by_name", () => {
|
||||
reaction_type: "zulip_extra_emoji",
|
||||
emoji_code: "zulip",
|
||||
url: "/static/generated/emoji/images/emoji/unicode/zulip.png",
|
||||
still_url: null,
|
||||
});
|
||||
|
||||
// Test adding realm emoji.
|
||||
@@ -97,6 +98,7 @@ run_test("get_emoji_details_by_name", () => {
|
||||
reaction_type: "realm_emoji",
|
||||
emoji_code: "102",
|
||||
url: "/some/path/to/emoji",
|
||||
still_url: null,
|
||||
});
|
||||
|
||||
// Test sending without emoji name.
|
||||
|
||||
Reference in New Issue
Block a user