diff options
-rw-r--r-- | images/emoji/custom/README.md | 17 | ||||
-rw-r--r-- | images/emoji/emojitwo/README (renamed from images/emoji/README) | 0 | ||||
-rw-r--r-- | images/emoji/emojitwo/astonished_face.png (renamed from images/emoji/astonished_face.png) | bin | 4130 -> 4130 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/bottle_with_popping_cork.png (renamed from images/emoji/bottle_with_popping_cork.png) | bin | 4780 -> 4780 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/clapping_hands.png (renamed from images/emoji/clapping_hands.png) | bin | 5377 -> 5377 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/disappointed_face.png (renamed from images/emoji/disappointed_face.png) | bin | 3504 -> 3504 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/grinning_face.png (renamed from images/emoji/grinning_face.png) | bin | 3449 -> 3449 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/kiss_mark.png (renamed from images/emoji/kiss_mark.png) | bin | 4603 -> 4603 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/red_heart.png (renamed from images/emoji/red_heart.png) | bin | 1839 -> 1839 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/sleeping_face.png (renamed from images/emoji/sleeping_face.png) | bin | 4538 -> 4538 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/slightly_smiling_face.png (renamed from images/emoji/slightly_smiling_face.png) | bin | 2872 -> 2872 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/smiling_face_with_halo.png (renamed from images/emoji/smiling_face_with_halo.png) | bin | 4102 -> 4102 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/smiling_face_with_horns.png (renamed from images/emoji/smiling_face_with_horns.png) | bin | 4554 -> 4554 bytes | |||
-rw-r--r-- | images/emoji/emojitwo/winking_face_with_tongue.png (renamed from images/emoji/winking_face_with_tongue.png) | bin | 3989 -> 3989 bytes | |||
-rw-r--r-- | images/emoji/hubzilla/hubzilla.png | bin | 0 -> 3948 bytes | |||
-rw-r--r-- | images/emoji/hubzilla/smiley-facepalm.gif | bin | 0 -> 582 bytes | |||
-rw-r--r-- | images/red-koala.png | bin | 14669 -> 14991 bytes | |||
-rw-r--r-- | include/text.php | 43 | ||||
-rw-r--r-- | view/tpl/conv_item.tpl | 2 | ||||
-rw-r--r-- | view/tpl/conv_list.tpl | 2 |
20 files changed, 47 insertions, 17 deletions
diff --git a/images/emoji/custom/README.md b/images/emoji/custom/README.md new file mode 100644 index 000000000..96718270c --- /dev/null +++ b/images/emoji/custom/README.md @@ -0,0 +1,17 @@ +# Custom site emojis + +Create a file called custom_emojis.json and add your custom emojis to this folder (or anywhere else you like). +The content of custom_emojis.json should look as follows: + +``` +{ + "some_emoji": { + "shortname": ":some_emoji:", + "filepath": "images/emoji/custom/some_emoji.png" + }, + "another_emoji": { + "shortname": ":another_emoji:", + "filepath": "images/emoji/custom/another_emoji.png" + }, +} +```
\ No newline at end of file diff --git a/images/emoji/README b/images/emoji/emojitwo/README index 6ac43096d..6ac43096d 100644 --- a/images/emoji/README +++ b/images/emoji/emojitwo/README diff --git a/images/emoji/astonished_face.png b/images/emoji/emojitwo/astonished_face.png Binary files differindex 6f326e925..6f326e925 100644 --- a/images/emoji/astonished_face.png +++ b/images/emoji/emojitwo/astonished_face.png diff --git a/images/emoji/bottle_with_popping_cork.png b/images/emoji/emojitwo/bottle_with_popping_cork.png Binary files differindex 90ddd0e03..90ddd0e03 100644 --- a/images/emoji/bottle_with_popping_cork.png +++ b/images/emoji/emojitwo/bottle_with_popping_cork.png diff --git a/images/emoji/clapping_hands.png b/images/emoji/emojitwo/clapping_hands.png Binary files differindex 4da00ec4d..4da00ec4d 100644 --- a/images/emoji/clapping_hands.png +++ b/images/emoji/emojitwo/clapping_hands.png diff --git a/images/emoji/disappointed_face.png b/images/emoji/emojitwo/disappointed_face.png Binary files differindex c7c2f397b..c7c2f397b 100644 --- a/images/emoji/disappointed_face.png +++ b/images/emoji/emojitwo/disappointed_face.png diff --git a/images/emoji/grinning_face.png b/images/emoji/emojitwo/grinning_face.png Binary files differindex 643459c53..643459c53 100644 --- a/images/emoji/grinning_face.png +++ b/images/emoji/emojitwo/grinning_face.png diff --git a/images/emoji/kiss_mark.png b/images/emoji/emojitwo/kiss_mark.png Binary files differindex d563361d6..d563361d6 100644 --- a/images/emoji/kiss_mark.png +++ b/images/emoji/emojitwo/kiss_mark.png diff --git a/images/emoji/red_heart.png b/images/emoji/emojitwo/red_heart.png Binary files differindex f05141f78..f05141f78 100644 --- a/images/emoji/red_heart.png +++ b/images/emoji/emojitwo/red_heart.png diff --git a/images/emoji/sleeping_face.png b/images/emoji/emojitwo/sleeping_face.png Binary files differindex 9e524b9b4..9e524b9b4 100644 --- a/images/emoji/sleeping_face.png +++ b/images/emoji/emojitwo/sleeping_face.png diff --git a/images/emoji/slightly_smiling_face.png b/images/emoji/emojitwo/slightly_smiling_face.png Binary files differindex 281e068e4..281e068e4 100644 --- a/images/emoji/slightly_smiling_face.png +++ b/images/emoji/emojitwo/slightly_smiling_face.png diff --git a/images/emoji/smiling_face_with_halo.png b/images/emoji/emojitwo/smiling_face_with_halo.png Binary files differindex 1bfee01ae..1bfee01ae 100644 --- a/images/emoji/smiling_face_with_halo.png +++ b/images/emoji/emojitwo/smiling_face_with_halo.png diff --git a/images/emoji/smiling_face_with_horns.png b/images/emoji/emojitwo/smiling_face_with_horns.png Binary files differindex 50f938ea8..50f938ea8 100644 --- a/images/emoji/smiling_face_with_horns.png +++ b/images/emoji/emojitwo/smiling_face_with_horns.png diff --git a/images/emoji/winking_face_with_tongue.png b/images/emoji/emojitwo/winking_face_with_tongue.png Binary files differindex e786f0e47..e786f0e47 100644 --- a/images/emoji/winking_face_with_tongue.png +++ b/images/emoji/emojitwo/winking_face_with_tongue.png diff --git a/images/emoji/hubzilla/hubzilla.png b/images/emoji/hubzilla/hubzilla.png Binary files differnew file mode 100644 index 000000000..4e7c25eb4 --- /dev/null +++ b/images/emoji/hubzilla/hubzilla.png diff --git a/images/emoji/hubzilla/smiley-facepalm.gif b/images/emoji/hubzilla/smiley-facepalm.gif Binary files differnew file mode 100644 index 000000000..724370369 --- /dev/null +++ b/images/emoji/hubzilla/smiley-facepalm.gif diff --git a/images/red-koala.png b/images/red-koala.png Binary files differindex 005a37fe2..723e79ba2 100644 --- a/images/red-koala.png +++ b/images/red-koala.png diff --git a/include/text.php b/include/text.php index fe238a297..52a6440cb 100644 --- a/include/text.php +++ b/include/text.php @@ -1272,25 +1272,38 @@ function sslify($s) { function get_emojis() { $emojis = [ // Reactions (emojitwo emojis) - 'astonished_face' => ['shortname' => ':astonished_face:', 'filepath' => 'images/emoji/astonished_face.png'], - 'bottle_with_popping_cork' => ['shortname' => ':bottle_with_popping_cork:', 'filepath' => 'images/emoji/bottle_with_popping_cork.png'], - 'clapping_hands' => ['shortname' => ':clapping_hands:', 'filepath' => 'images/emoji/clapping_hands.png'], - 'disappointed_face' => ['shortname' => ':disappointed_face:', 'filepath' => 'images/emoji/disappointed_face.png'], - 'grinning_face' => ['shortname' => ':grinning_face:', 'filepath' => 'images/emoji/grinning_face.png'], - 'kiss_mark' => ['shortname' => ':kiss_mark:', 'filepath' => 'images/emoji/kiss_mark.png'], - 'red_heart' => ['shortname' => ':red_heart:', 'filepath' => 'images/emoji/red_heart.png'], - 'sleeping_face' => ['shortname' => ':sleeping_face:', 'filepath' => 'images/emoji/sleeping_face.png'], - 'slightly_smiling_face' => ['shortname' => ':slightly_smiling_face:', 'filepath' => 'images/emoji/slightly_smiling_face.png'], - 'smiling_face_with_halo' => ['shortname' => ':smiling_face_with_halo:', 'filepath' => 'images/emoji/smiling_face_with_halo.png'], - 'smiling_face_with_horns' => ['shortname' => ':smiling_face_with_horns:', 'filepath' => 'images/emoji/smiling_face_with_horns.png'], - 'winking_face_with_tongue' => ['shortname' => ':winking_face_with_tongue:', 'filepath' => 'images/emoji/winking_face_with_tongue.png'], - - 'facepalm' => ['shortname' => ':facepalm:', 'filepath' => 'images/emoticons/smiley-facepalm.gif'], - 'hubzilla' => ['shortname' => ':hubzilla:', 'filepath' => 'images/hubzilla.png'] + 'astonished_face' => ['shortname' => ':astonished_face:', 'filepath' => 'images/emoji/emojitwo/astonished_face.png'], + 'bottle_with_popping_cork' => ['shortname' => ':bottle_with_popping_cork:', 'filepath' => 'images/emoji/emojitwo/bottle_with_popping_cork.png'], + 'clapping_hands' => ['shortname' => ':clapping_hands:', 'filepath' => 'images/emoji/emojitwo/clapping_hands.png'], + 'disappointed_face' => ['shortname' => ':disappointed_face:', 'filepath' => 'images/emoji/emojitwo/disappointed_face.png'], + 'grinning_face' => ['shortname' => ':grinning_face:', 'filepath' => 'images/emoji/emojitwo/grinning_face.png'], + 'kiss_mark' => ['shortname' => ':kiss_mark:', 'filepath' => 'images/emoji/emojitwo/kiss_mark.png'], + 'red_heart' => ['shortname' => ':red_heart:', 'filepath' => 'images/emoji/emojitwo/red_heart.png'], + 'sleeping_face' => ['shortname' => ':sleeping_face:', 'filepath' => 'images/emoji/emojitwo/sleeping_face.png'], + 'slightly_smiling_face' => ['shortname' => ':slightly_smiling_face:', 'filepath' => 'images/emoji/emojitwo/slightly_smiling_face.png'], + 'smiling_face_with_halo' => ['shortname' => ':smiling_face_with_halo:', 'filepath' => 'images/emoji/emojitwo/smiling_face_with_halo.png'], + 'smiling_face_with_horns' => ['shortname' => ':smiling_face_with_horns:', 'filepath' => 'images/emoji/emojitwo/smiling_face_with_horns.png'], + 'winking_face_with_tongue' => ['shortname' => ':winking_face_with_tongue:', 'filepath' => 'images/emoji/emojitwo/winking_face_with_tongue.png'], + + // Hubzilla custom + 'facepalm' => ['shortname' => ':facepalm:', 'filepath' => 'images/emoji/hubzilla/smiley-facepalm.gif'], + 'hubzilla' => ['shortname' => ':hubzilla:', 'filepath' => 'images/emoji/hubzilla/hubzilla.png'] ]; + // Provided by addon call_hooks('get_emojis', $emojis); + // Custom site emojis + $custom_json_path = 'images/emoji/custom/custom_emojis.json'; + if (file_exists($custom_json_path)) { + $custom_json = file_get_contents($custom_json_path); + $custom_arr = json_decode($custom_json, true); + + if ($custom_arr) { + $emojis = array_merge($emojis, $custom_arr); + } + } + return $emojis; } diff --git a/view/tpl/conv_item.tpl b/view/tpl/conv_item.tpl index 96e6f57df..da1e5a472 100644 --- a/view/tpl/conv_item.tpl +++ b/view/tpl/conv_item.tpl @@ -162,7 +162,7 @@ <div class="row g-0"> {{foreach $item.reactions as $react}} <div class="col-3 p-2"> - <a class="" href="#" onclick="jotReact({{$item.id}},'{{$react}}'); return false;"><img class="menu-img-1" src="/images/emoji/{{$react}}.png" alt="{{$react}}" /></a> + <a class="" href="#" onclick="jotReact({{$item.id}},'{{$react}}'); return false;"><img class="menu-img-1" src="/images/emoji/emojitwo/{{$react}}.png" alt="{{$react}}" /></a> </div> {{/foreach}} </div> diff --git a/view/tpl/conv_list.tpl b/view/tpl/conv_list.tpl index 6143e156e..ad54fce7e 100644 --- a/view/tpl/conv_list.tpl +++ b/view/tpl/conv_list.tpl @@ -167,7 +167,7 @@ <div class="row g-0"> {{foreach $item.reactions as $react}} <div class="col-3 p-2"> - <a class="" href="#" onclick="jotReact({{$item.id}},'{{$react}}'); return false;"><img class="menu-img-1" src="/images/emoji/{{$react}}.png" alt="{{$react}}" /></a> + <a class="" href="#" onclick="jotReact({{$item.id}},'{{$react}}'); return false;"><img class="menu-img-1" src="/images/emoji/emojitwo/{{$react}}.png" alt="{{$react}}" /></a> </div> {{/foreach}} </div> |