diff --git a/app/javascript/flavours/glitch/features/compose/components/emoji_picker_dropdown.jsx b/app/javascript/flavours/glitch/features/compose/components/emoji_picker_dropdown.jsx index ee565390a3..d368fb6a20 100644 --- a/app/javascript/flavours/glitch/features/compose/components/emoji_picker_dropdown.jsx +++ b/app/javascript/flavours/glitch/features/compose/components/emoji_picker_dropdown.jsx @@ -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 (
- - - - - - + + + + + +
); } @@ -134,12 +133,12 @@ class ModifierPicker extends PureComponent { this.props.onClose(); }; - render () { + render() { const { active, modifier } = this.props; return (
- +
); @@ -291,7 +290,6 @@ class EmojiPickerMenuImpl extends PureComponent { notFound={notFoundFn} autoFocus={this.state.readyToFocus} emojiTooltip - native={useSystemEmojiFont} /> { 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; } } diff --git a/app/javascript/flavours/glitch/initial_state.ts b/app/javascript/flavours/glitch/initial_state.ts index 308654a3eb..8f5d164f71 100644 --- a/app/javascript/flavours/glitch/initial_state.ts +++ b/app/javascript/flavours/glitch/initial_state.ts @@ -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'); diff --git a/app/models/concerns/user/has_settings.rb b/app/models/concerns/user/has_settings.rb index 9759e17185..9e99107aa1 100644 --- a/app/models/concerns/user/has_settings.rb +++ b/app/models/concerns/user/has_settings.rb @@ -51,10 +51,6 @@ module User::HasSettings settings['web.use_system_font'] end - def setting_system_emoji_font - settings['web.use_system_emoji_font'] - end - def setting_system_scrollbars_ui settings['web.use_system_scrollbars'] end diff --git a/app/models/user_settings.rb b/app/models/user_settings.rb index 79aede1aed..856fc43a74 100644 --- a/app/models/user_settings.rb +++ b/app/models/user_settings.rb @@ -41,7 +41,6 @@ class UserSettings setting :expand_content_warnings, default: false setting :display_media, default: 'default', in: %w(default show_all hide_all) setting :auto_play, default: false - setting :use_system_emoji_font, default: false setting :emoji_style, default: 'auto', in: %w(auto native twemoji) end diff --git a/app/serializers/initial_state_serializer.rb b/app/serializers/initial_state_serializer.rb index e0340bdda6..f78618a026 100644 --- a/app/serializers/initial_state_serializer.rb +++ b/app/serializers/initial_state_serializer.rb @@ -46,7 +46,6 @@ class InitialStateSerializer < ActiveModel::Serializer store[:use_blurhash] = object_account_user.setting_use_blurhash store[:use_pending_items] = object_account_user.setting_use_pending_items store[:default_content_type] = object_account_user.setting_default_content_type - store[:system_emoji_font] = object_account_user.setting_system_emoji_font store[:show_trends] = Setting.trends && object_account_user.setting_trends store[:emoji_style] = object_account_user.settings['web.emoji_style'] else diff --git a/app/views/settings/preferences/appearance/show.html.haml b/app/views/settings/preferences/appearance/show.html.haml index 553c58f973..1f55952f71 100644 --- a/app/views/settings/preferences/appearance/show.html.haml +++ b/app/views/settings/preferences/appearance/show.html.haml @@ -52,7 +52,6 @@ = ff.input :'web.disable_swiping', wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_disable_swiping') = ff.input :'web.disable_hover_cards', wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_disable_hover_cards') = ff.input :'web.use_system_font', wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_system_font_ui') - = ff.input :'web.use_system_emoji_font', wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_system_emoji_font'), glitch_only: true = ff.input :'web.use_system_scrollbars', wrapper: :with_label, hint: I18n.t('simple_form.hints.defaults.setting_system_scrollbars_ui'), label: I18n.t('simple_form.labels.defaults.setting_system_scrollbars_ui') %h4= t 'appearance.discovery'