Remove glitch-soc system emoji font option now that it's superseded by upstream
This commit is contained in:
1 parent
24234e6632
commit
d04e6ec597
7 files changed
+12
-23
No files matched your search
+8
-10
@@ -12,7 +12,6 @@ import Overlay from 'react-overlays/Overlay';
|
||||
|
||||
import MoodIcon from '@/material-icons/400-20px/mood.svg?react';
|
||||
import { IconButton } from 'flavours/glitch/components/icon_button';
|
||||
import { useSystemEmojiFont } from 'flavours/glitch/initial_state';
|
||||
|
||||
import { buildCustomEmojis, categoriesFromEmojis } from '../../emoji/emoji';
|
||||
import { EmojiPicker as EmojiPickerAsync } from '../../ui/util/async-components';
|
||||
@@ -99,12 +98,12 @@ class ModifierPickerMenu extends PureComponent {
|
||||
|
||||
return (
|
||||
<div className='emoji-picker-dropdown__modifiers__menu' style={{ display: active ? 'block' : 'none' }} ref={this.setRef}>
|
||||
<button type='button' onClick={this.handleClick} data-index={1}><Emoji emoji='fist' size={22} skin={1} native={useSystemEmojiFont} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={2}><Emoji emoji='fist' size={22} skin={2} native={useSystemEmojiFont} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={3}><Emoji emoji='fist' size={22} skin={3} native={useSystemEmojiFont} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={4}><Emoji emoji='fist' size={22} skin={4} native={useSystemEmojiFont} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={5}><Emoji emoji='fist' size={22} skin={5} native={useSystemEmojiFont} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={6}><Emoji emoji='fist' size={22} skin={6} native={useSystemEmojiFont} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={1}><Emoji emoji='fist' size={22} skin={1} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={2}><Emoji emoji='fist' size={22} skin={2} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={3}><Emoji emoji='fist' size={22} skin={3} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={4}><Emoji emoji='fist' size={22} skin={4} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={5}><Emoji emoji='fist' size={22} skin={5} /></button>
|
||||
<button type='button' onClick={this.handleClick} data-index={6}><Emoji emoji='fist' size={22} skin={6} /></button>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -134,12 +133,12 @@ class ModifierPicker extends PureComponent {
|
||||
this.props.onClose();
|
||||
};
|
||||
|
||||
render () {
|
||||
render() {
|
||||
const { active, modifier } = this.props;
|
||||
|
||||
return (
|
||||
<div className='emoji-picker-dropdown__modifiers'>
|
||||
<Emoji emoji='fist' size={22} skin={modifier} onClick={this.handleClick} native={useSystemEmojiFont} />
|
||||
<Emoji emoji='fist' size={22} skin={modifier} onClick={this.handleClick} />
|
||||
<ModifierPickerMenu active={active} onSelect={this.handleSelect} onClose={this.props.onClose} />
|
||||
</div>
|
||||
);
|
||||
@@ -291,7 +290,6 @@ class EmojiPickerMenuImpl extends PureComponent {
|
||||
notFound={notFoundFn}
|
||||
autoFocus={this.state.readyToFocus}
|
||||
emojiTooltip
|
||||
native={useSystemEmojiFont}
|
||||
/>
|
||||
|
||||
<ModifierPicker
|
||||
|
||||
@@ -2,7 +2,7 @@ import Trie from 'substring-trie';
|
||||
|
||||
import { assetHost } from 'flavours/glitch/utils/config';
|
||||
|
||||
import { autoPlayGif, useSystemEmojiFont } from '../../initial_state';
|
||||
import { autoPlayGif } from '../../initial_state';
|
||||
|
||||
import { unicodeMapping } from './emoji_unicode_mapping_light';
|
||||
|
||||
@@ -39,13 +39,13 @@ const emojifyTextNode = (node, customEmojis) => {
|
||||
for (;;) {
|
||||
let unicode_emoji;
|
||||
|
||||
// Skip to the next potential emoji to replace (either custom emoji or custom emoji :shortcode:)
|
||||
// Skip to the next potential emoji to replace (either custom emoji or custom emoji :shortcode:
|
||||
if (customEmojis === null) {
|
||||
while (i < str.length && (useSystemEmojiFont || !(unicode_emoji = trie.search(str.slice(i))))) {
|
||||
while (i < str.length && !(unicode_emoji = trie.search(str.slice(i)))) {
|
||||
i += str.codePointAt(i) < 65536 ? 1 : 2;
|
||||
}
|
||||
} else {
|
||||
while (i < str.length && str[i] !== ':' && (useSystemEmojiFont || !(unicode_emoji = trie.search(str.slice(i))))) {
|
||||
while (i < str.length && str[i] !== ':' && !(unicode_emoji = trie.search(str.slice(i)))) {
|
||||
i += str.codePointAt(i) < 65536 ? 1 : 2;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -49,7 +49,6 @@ interface InitialStateMeta {
|
||||
status_page_url: string;
|
||||
terms_of_service_enabled: boolean;
|
||||
emoji_style?: string;
|
||||
system_emoji_font?: boolean;
|
||||
default_content_type: string;
|
||||
}
|
||||
|
||||
@@ -177,7 +176,6 @@ export const maxFeedHashtags = initialState?.max_feed_hashtags ?? 4;
|
||||
export const favouriteModal = getMeta('favourite_modal');
|
||||
export const pollLimits = initialState?.poll_limits;
|
||||
export const defaultContentType = getMeta('default_content_type');
|
||||
export const useSystemEmojiFont = getMeta('system_emoji_font');
|
||||
|
||||
export function getAccessToken(): string | undefined {
|
||||
return getMeta('access_token');
|
||||
|
||||
Reference in new issue
Block a user