forked from joypixels/emojione
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request joypixels#473 from kevinranks/3.0
EmojiOne 3.0 Update
- Loading branch information
Showing
10,244 changed files
with
39,244 additions
and
25,707 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,3 +13,4 @@ build/ | |
emojipy-*/ | ||
emojipy.egg-info/ | ||
npm-debug.log | ||
lib/js/tests/npm-debug.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
### Installation | ||
|
||
We've teamed up with [JSDelivr](http://www.jsdelivr.com/#!emojione) to provide a simple way to install these emoji on any javascript-enabled website. Add the following script and stylesheet links to the head of your webpage: | ||
|
||
``` | ||
<script src="https://cdn.jsdelivr.net/emojione/3.0/lib/js/emojione.min.js"></script> | ||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/emojione/3.0/assets/css/emojione.min.css"/> | ||
``` | ||
|
||
Alternatively, CDNjs is also available as a [CDN Host for EmojiOne](https://cdnjs.com/libraries/emojione). | ||
|
||
Quick installs can also be done using NPM and Bower (for the Javascript toolkit) or Composer (for the PHP toolkit). **If you wish to serve image assets locally you'll need to install [emojione-assets](https://www.github.com/Ranks/emojione-assets) and include the pngs and/or sprites into your project.** Many of our [demos](https://demos.emojione.com/latest/) use assets locally simply by pointing the `imagePathPNG` variable to your local asset location. | ||
|
||
#### NPM | ||
``` | ||
> npm install emojione | ||
``` | ||
|
||
#### Bower | ||
``` | ||
> bower install emojione | ||
``` | ||
|
||
|
||
#### Composer | ||
``` | ||
$ composer require emojione/emojione | ||
``` | ||
|
||
#### Meteor | ||
``` | ||
meteor add emojione:emojione | ||
``` | ||
|
||
### Version 2 Installation | ||
If you're looking to use emojione < version 3.0, refer to the 2.2.7 branch. **CDN (jsdelivr) dependency has been preserved for version 2.** | ||
|
||
|
||
### Character Encoding — UTF-8 | ||
|
||
If you're getting serious about implementing emoji into your website, you will want to consider your web stack's character encoding. You should make sure that all connection points are using the same encoding. There are a lot of options and configuration possibilities here, so you'll have to figure what works best for your own situation. | ||
|
||
A quick Google search will bring up a lot of information on how to get your entire web stack to use UTF-8, which is needed to properly handle Unicode emoji. | ||
|
||
To get you started, here's a nice guide: [UTF-8: The Secret of Character Encoding](http://htmlpurifier.org/docs/enduser-utf8.html). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
#### EmojiOne Artwork | ||
|
||
* Applies to all PNG and SVG files as well as any adaptations made. | ||
* Applies to all PNG files found in the emojione-assets repo as well as any adaptations made. | ||
* License: Creative Commons Attribution 4.0 International | ||
* Human Readable License: http://creativecommons.org/licenses/by/4.0/ | ||
* Complete Legal Terms: http://creativecommons.org/licenses/by/4.0/legalcode | ||
|
||
|
||
#### EmojiOne Non-Artwork | ||
|
||
* Applies to the Javascript, JSON, PHP, CSS, HTML files, and everything else not covered under the artwork license above. | ||
* Applies to the Javascript, JSON, PHP, CSS, HTML files, and everything else not covered under the artwork license above, found in both the emojione and emojione-assets repos. | ||
* License: MIT | ||
* Complete Legal Terms: http://opensource.org/licenses/MIT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
# Upgrading from emojione v2 to emojione v3 | ||
|
||
* emojione v3 brings about several breaking changes and new considerations | ||
* please review EmojiOne Licensing for more information on using SVG or PNG (larger than 128px) assets | ||
|
||
## Libraries | ||
**JS** | ||
- Deprecated vars: | ||
- [emojione.js] imagePathSVG, imagePathSVGSprites, imageType (now defaulted to png) | ||
- Tests also updated (added explicit protocol for cdn, included previously-added title attribute to img tag) | ||
- Added vars: | ||
- emojiVersion (str) | ||
- emojiSize (str) | ||
- matchGreedy (bool) | ||
|
||
**PHP** | ||
- Deprecated vars: | ||
- [src/Client.php] imagePathSVG, imagePathSVGSprites | ||
- [src/Emojione.php] imagePathSVG, imagePathSVGSprites, imageType | ||
- Added vars: | ||
- emojiVersion (str) | ||
- emojiSize (str) | ||
- matchGreedy (bool) | ||
- Tests | ||
- [tests/ConversionTest.php] removed testSmileyInsideAnObject() | ||
- [tests/ConversionTest.php] removed testShortnameInsideOfObjectTag() | ||
|
||
## Demos | ||
Replaced by ‘examples’. Contains code snippets of each of the functions previously demonstrated. Updated demos can be found at <a href="https://demos.emojione.com/latest"></a>. | ||
|
||
## JSON Files | ||
**EMOJI.JSON (updated)** | ||
- primary key is now *base code point* rather than shortname | ||
- base code point is the full unicode code point minus VS16 and ZWJ | ||
- base code point is used as an identifier for emoji file names (PNG) as well as within sprites (CSS) | ||
- **unicode** (str) and **unicode_alt** (str) are depricated. code points are now organized within **code_points** (array) | ||
- **output** (str) is the recommended code point to use for conversion to native unicode | ||
- **match_default** (array) contains one or more code points used to identify native unicode | ||
- **match_greedy** (array) contains one or more code points used to identify potential native unicode variants | ||
- note: the match_greedy code point(s) may replace non-emoji variants producing undesired results | ||
- **decimal** (str) replaces **code_decimal** (str) | ||
- **emoji_order** (int) is now simply **order** (int) | ||
- **display** (int) determines whether an emoji should be shown on a keyboard | ||
- **aliases** (array) is now **shortname_alternates** (array) | ||
- **aliases_ascii** (array) is now **ascii** (array) | ||
- **diversity** (str) is either `null` or the base code point of the corresponding Fitzpatrick Emoji Modifier | ||
- **diversities** (array) contains the base code points of the diversity children for a diversity parent (non-diverse, diversity base) | ||
- **gender** (str) is either `null` or the base code point of the corresponding male/female emoji symbol | ||
- **genders** (array) contains the base code points of the gender children for a gender parent (gender-neutral, gender base) | ||
|
||
**EMOJI_STRATEGY.JSON (updated)** | ||
- primary key is now *base code point* rather than short name | ||
- **aliases** (str) is now **shortname_alternates** (array) | ||
- **keywords** (str) is now **keywords** (array) | ||
- **unicode** (str) is now **unicode_output** (str) | ||
|
||
**EMOJI_CATEGORIES.JSON (new)** | ||
- **order** (str) | ||
- **category** (str) | ||
- **category_label** (str) | ||
|
||
## Shortname Changes | ||
Along with the many changes to emojione version 3.0 comes a number of shortname updates. **Any shortnames that change will still appear as an alternate shortname (or alias) in the data files.** You can view the complete list of primary shortname changes in the [extras/alpha-codes readme](extras/alpha-codes/). |
Oops, something went wrong.