Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to latest emoji-datasource #78

Merged
merged 8 commits into from
May 27, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
"babel-plugin-transform-object-rest-spread": "6.8.0",
"babel-preset-es2015": "6.6.0",
"babel-preset-react": "6.5.0",
"emoji-datasource": "2.4.4",
"emojilib": "2.0.2",
"emoji-datasource": "^3.0.0",
"emojilib": "^2.2.1",
"inflection": "1.10.0",
"jasmine-core": "^2.5.2",
"karma": "^1.4.0",
Expand Down
4 changes: 2 additions & 2 deletions src/components/emoji.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import data from '../../data'

import { getData, getSanitizedData, unifiedToNative } from '../utils'

const SHEET_COLUMNS = 41
const SHEET_COLUMNS = 49

export default class Emoji extends React.Component {
constructor(props) {
Expand Down Expand Up @@ -127,7 +127,7 @@ Emoji.defaultProps = {
sheetSize: 64,
native: false,
forceSize: false,
backgroundImageFn: ((set, sheetSize) => `https://unpkg.com/emoji-datasource@${EMOJI_DATASOURCE_VERSION}/sheet_${set}_${sheetSize}.png`),
backgroundImageFn: ((set, sheetSize) => `https://unpkg.com/emoji-datasource-${set}@${EMOJI_DATASOURCE_VERSION}/img/${set}/sheets/${sheetSize}.png`),
onOver: (() => {}),
onLeave: (() => {}),
onClick: (() => {}),
Expand Down
3 changes: 1 addition & 2 deletions src/utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,7 @@ function getData(emoji, skin, set) {
emojiData = JSON.parse(JSON.stringify(emojiData))

var skinKey = SKINS[skin - 1],
variationKey = `${emojiData.unified}-${skinKey}`,
variationData = emojiData.skin_variations[variationKey]
variationData = emojiData.skin_variations[skinKey]

if (!variationData.variations && emojiData.variations) {
delete emojiData.variations
Expand Down
12 changes: 6 additions & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -989,13 +989,13 @@ ee-first@1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d"

emoji-datasource@2.4.4:
version "2.4.4"
resolved "https://registry.yarnpkg.com/emoji-datasource/-/emoji-datasource-2.4.4.tgz#b97ac1896bc208ecf1833564a20687a5215d0389"
emoji-datasource@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/emoji-datasource/-/emoji-datasource-3.0.0.tgz#3c46c5aa4c39bb7a0c8e6877ae02cc94dbc1b12f"

emojilib@2.0.2:
version "2.0.2"
resolved "https://registry.yarnpkg.com/emojilib/-/emojilib-2.0.2.tgz#df91c45ede69f2d0ffd3d80acf8c72771b2a5ea1"
emojilib@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/emojilib/-/emojilib-2.2.1.tgz#36723c8197a80917c422b1160af900f61ea28772"

emojis-list@^2.0.0:
version "2.1.0"
Expand Down