Make WordPress Core

Ticket #46404: 46404.2.diff

File 46404.2.diff, 2.2 KB (added by pento, 7 years ago)
  • src/js/_enqueues/lib/emoji-loader.js

    diff --git a/src/js/_enqueues/lib/emoji-loader.js b/src/js/_enqueues/lib/emoji-loader.js
    index 910ec1b4d5..8866cf3151 100644
    a b  
    7676                                 * the browser doesn't render it correctly ([U] + [N]).
    7777                                 */
    7878                                isIdentical = emojiSetsRenderIdentically(
    79                                         [ 55356, 56826, 55356, 56819 ],
    80                                         [ 55356, 56826, 8203, 55356, 56819 ]
     79                                        [ 0xD83C, 0xDDFA, 0xD83C, 0xDDF3 ],
     80                                        [ 0xD83C, 0xDDFA, 0x200B, 0xD83C, 0xDDF3 ]
    8181                                );
    8282
    8383                                if ( isIdentical ) {
     
    9292                                 * the browser doesn't render it correctly (black flag emoji + [G] + [B] + [E] + [N] + [G]).
    9393                                 */
    9494                                isIdentical = emojiSetsRenderIdentically(
    95                                         [ 55356, 57332, 56128, 56423, 56128, 56418, 56128, 56421, 56128, 56430, 56128, 56423, 56128, 56447 ],
    96                                         [ 55356, 57332, 8203, 56128, 56423, 8203, 56128, 56418, 8203, 56128, 56421, 8203, 56128, 56430, 8203, 56128, 56423, 8203, 56128, 56447 ]
     95                                        [ 0xD83C, 0xDFF4, 0xDB40, 0xDC67, 0xDB40, 0xDC62, 0xDB40, 0xDC65, 0xDB40, 0xDC6E, 0xDB40, 0xDC67, 0xDB40, 0xDC7F ],
     96                                        [ 0xD83C, 0xDFF4, 0x200B, 0xDB40, 0xDC67, 0x200B, 0xDB40, 0xDC62, 0x200B, 0xDB40, 0xDC65, 0x200B, 0xDB40, 0xDC6E, 0x200B, 0xDB40, 0xDC67, 0x200B, 0xDB40, 0xDC7F ]
    9797                                );
    9898
    9999                                return ! isIdentical;
    100100                        case 'emoji':
    101101                                /*
    102                                  * She's the hero Emoji deserves, but not the one it needs right now.
     102                                 * Love is love.
    103103                                 *
    104                                  * To test for support, try to render a new emoji (female superhero),
    105                                  * then compare it to how it would look if the browser doesn't render it correctly
    106                                  * (superhero + female sign) .
     104                                 * To test for Emoji 12 support, try to render a new emoji: men holding hands, with different skin
     105                                 * tone modifiers.
     106                                 *
     107                                 * When updating this test for future Emoji releases, ensure that individual emoji that make up the
     108                                 * sequence come from older emoji standards.
    107109                                 */
    108110                                isIdentical = emojiSetsRenderIdentically(
    109                                         [55358, 56760, 9792, 65039],
    110                                         [55358, 56760, 8203, 9792, 65039]
     111                                        [0xD83D, 0xDC68, 0xD83C, 0xDFFE, 0x200D, 0xD83E, 0xDD1D, 0x200D, 0xD83D, 0xDC68, 0xD83C, 0xDFFC],
     112                                        [0xD83D, 0xDC68, 0xD83C, 0xDFFE, 0x200B, 0xD83E, 0xDD1D, 0x200B, 0xD83D, 0xDC68, 0xD83C, 0xDFFC]
    111113                                );
    112114
    113115                                return ! isIdentical;