mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-11 10:38:11 +08:00
fix(composer-emoji): Only show replacement PNGs for OS X
This commit is contained in:
parent
872aae1bcd
commit
cbf9627029
3 changed files with 3 additions and 3 deletions
|
@ -269,7 +269,7 @@ class EmojiButtonPopover extends React.Component {
|
|||
ctx.fillStyle = 'black';
|
||||
if (this.state.categorizedEmoji[category].length === 0) return;
|
||||
this.state.categorizedEmoji[category].forEach((emojiName, j) => {
|
||||
if (missingEmojiList.indexOf(emojiName) === -1) {
|
||||
if (process.platform === "darwin" && missingEmojiList.indexOf(emojiName) === -1) {
|
||||
const emojiChar = emoji.get(emojiName);
|
||||
ctx.fillText(emojiChar, position.x, position.y);
|
||||
} else {
|
||||
|
|
|
@ -205,7 +205,7 @@ class EmojiComposerExtension extends ComposerExtension {
|
|||
}
|
||||
}
|
||||
const emojiChar = emoji.get(emojiName);
|
||||
if (missingEmojiList.indexOf(emojiName) !== -1) {
|
||||
if (process.platform === "darwin" && missingEmojiList.indexOf(emojiName) !== -1) {
|
||||
const html = `<span class="missing-emoji ${emojiName}"><img
|
||||
src="images/composer-emoji/missing-emoji/${emojiName}.png"
|
||||
width="14"
|
||||
|
|
|
@ -35,7 +35,7 @@ class EmojiPicker extends React.Component {
|
|||
this.props.emojiOptions.forEach((emojiOption, i) => {
|
||||
const emojiClass = emojiIndex === i ? "btn btn-icon emoji-option" : "btn btn-icon";
|
||||
let emojiChar = emoji.get(emojiOption);
|
||||
if (missingEmojiList.indexOf(emojiOption) !== -1) {
|
||||
if (process.platform === "darwin" && missingEmojiList.indexOf(emojiOption) !== -1) {
|
||||
emojiChar = (<img
|
||||
src={`images/composer-emoji/missing-emoji/${emojiOption}.png`}
|
||||
width="16"
|
||||
|
|
Loading…
Reference in a new issue