In Rails 4.2 `#asset_path` has changed. Prior to Rails 4.2, `#asset_path` would search all asset directories, and prepend the appropriate asset type directory name to the result: asset_path("emoji/unicode/<id>.png") #=> "/images/emoji/unicode/<id>.png" However, In Rails 4.2 `#asset_path` doesn't do that anymore, and assumes that you've specified the correct folder. Since Emoji images are copied to public/images/emoji/unicode, `#asset_path` would then generate the wrong URL path: asset_path("emoji/unicode/<id>.png") #=> "/emoji/unicode/<id>.png" Using `#image_path` fixes that, because that method looks specifically for images/ folder, so it will find the Emoji images.
http://www.glitchthegame.com/items/food/cold-taco/ Released under the public domain: http://www.glitchthegame.com/licensing/
Commands used: $ rake images:extract $ imageOptim -a -d images/emoji/unicode/ This required both ImageOptim and ImageAlpha to be installed as OS X apps.
We now operate on a new set of assumptions: - Characters with VARIATION_SELECTOR_15 shouldn't render as emoji, even if OS X doesn't respect that currently. This removes explicit aliases that include VARIATION_SELECTOR_15. - VARIATION_SELECTOR_16 is optional for most characters to render as emoji on OS X. For those that *don't* have it optional, we include VARIATION_SELECTOR_16 in their raw representation in `emoji.json`. Other characters list their form including VARIATION_SELECTOR_16 implicitly in `unicode_aliases`. - For emoji that consist of 2 characters + variation selector, we assume that the selector can come between the 2 characters or *after* them, so `find_by_unicode` now supports both forms. - The `db/aliases.html` script ensures that `emoji.json` only contains characters that Safari on OS X actually renders as emojis.
Otherwise canvas element defaults to a larger size.
Uses AppleScript to open Safari and filter the emojis by whether they render as actual emoji on OS X or not.
Unless these characters are followed by VARIATION SELECTOR-16, which indicates that the should be rendered as emoji, OS X renders these characters using plain font glyphs. Previously we assumed that the emoji list we get from `Category-Emoji.json` (OS X emoji character picker) are all valid emoji, but for some reason some plain Unicode characters are included in there without being suffixed with VARIATION SELECTOR-16.
Even if the emoji contains it, the filename on disk doesn't have to. This will reduce having to keep renaming PNGs on disk while we tweak the emoji database in the future in regard to which are required to have VARIATION_SELECTOR_16 and which are not.