parent
85a6631709
commit
e3c71cb3e4
14 changed files with 61 additions and 36 deletions
|
@ -28,7 +28,7 @@ import Card from '../features/status/components/card';
|
||||||
// to use the progress bar to show download progress
|
// to use the progress bar to show download progress
|
||||||
import Bundle from '../features/ui/components/bundle';
|
import Bundle from '../features/ui/components/bundle';
|
||||||
import { MediaGallery, Video, Audio } from '../features/ui/util/async-components';
|
import { MediaGallery, Video, Audio } from '../features/ui/util/async-components';
|
||||||
import { displayMedia, enableEmojiReaction, showEmojiReactionOnTimeline, showQuoteInHome, showQuoteInPublic } from '../initial_state';
|
import { displayMedia, enableEmojiReaction, isShowItem } from '../initial_state';
|
||||||
|
|
||||||
import { Avatar } from './avatar';
|
import { Avatar } from './avatar';
|
||||||
import { AvatarOverlay } from './avatar_overlay';
|
import { AvatarOverlay } from './avatar_overlay';
|
||||||
|
@ -610,7 +610,7 @@ class Status extends ImmutablePureComponent {
|
||||||
if (!this.props.withoutEmojiReactions && status.get('emoji_reactions')) {
|
if (!this.props.withoutEmojiReactions && status.get('emoji_reactions')) {
|
||||||
const emojiReactions = status.get('emoji_reactions');
|
const emojiReactions = status.get('emoji_reactions');
|
||||||
if (emojiReactions.size > 0 && enableEmojiReaction) {
|
if (emojiReactions.size > 0 && enableEmojiReaction) {
|
||||||
emojiReactionsBar = <StatusEmojiReactionsBar emojiReactions={emojiReactions} myReactionOnly={!showEmojiReactionOnTimeline} status={status} onEmojiReact={this.props.onEmojiReact} onUnEmojiReact={this.props.onUnEmojiReact} />;
|
emojiReactionsBar = <StatusEmojiReactionsBar emojiReactions={emojiReactions} myReactionOnly={!isShowItem('emoji_reaction_on_timeline')} status={status} onEmojiReact={this.props.onEmojiReact} onUnEmojiReact={this.props.onUnEmojiReact} />;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -622,7 +622,7 @@ class Status extends ImmutablePureComponent {
|
||||||
const withReference = (!withQuote && status.get('status_references_count') > 0) ? <span className='status__visibility-icon'><Icon id='link' icon={ReferenceIcon} title='Reference' /></span> : null;
|
const withReference = (!withQuote && status.get('status_references_count') > 0) ? <span className='status__visibility-icon'><Icon id='link' icon={ReferenceIcon} title='Reference' /></span> : null;
|
||||||
const withExpiration = status.get('expires_at') ? <span className='status__visibility-icon'><Icon id='clock-o' icon={TimerIcon} title='Expiration' /></span> : null;
|
const withExpiration = status.get('expires_at') ? <span className='status__visibility-icon'><Icon id='clock-o' icon={TimerIcon} title='Expiration' /></span> : null;
|
||||||
|
|
||||||
const quote = !muted && status.get('quote_id') && (['public', 'community'].includes(contextType) ? showQuoteInPublic : showQuoteInHome) && <CompactedStatusContainer id={status.get('quote_id')} history={this.props.history} />;
|
const quote = !muted && status.get('quote_id') && (['public', 'community'].includes(contextType) ? isShowItem('quote_in_public') : isShowItem('quote_in_home')) && <CompactedStatusContainer id={status.get('quote_id')} history={this.props.history} />;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<HotKeys handlers={handlers}>
|
<HotKeys handlers={handlers}>
|
||||||
|
|
|
@ -26,7 +26,7 @@ import { WithRouterPropTypes } from 'mastodon/utils/react_router';
|
||||||
|
|
||||||
import DropdownMenuContainer from '../containers/dropdown_menu_container';
|
import DropdownMenuContainer from '../containers/dropdown_menu_container';
|
||||||
import EmojiPickerDropdown from '../features/compose/containers/emoji_picker_dropdown_container';
|
import EmojiPickerDropdown from '../features/compose/containers/emoji_picker_dropdown_container';
|
||||||
import { enableEmojiReaction , bookmarkCategoryNeeded, simpleTimelineMenu, me, hideEmojiReactionUnavailableServer } from '../initial_state';
|
import { enableEmojiReaction , bookmarkCategoryNeeded, simpleTimelineMenu, me, isHideItem } from '../initial_state';
|
||||||
|
|
||||||
import { IconButton } from './icon_button';
|
import { IconButton } from './icon_button';
|
||||||
|
|
||||||
|
@ -453,7 +453,7 @@ class StatusActionBar extends ImmutablePureComponent {
|
||||||
<IconButton className='status__action-bar__button' title={intl.formatMessage(messages.hide)} icon='eye' iconComponent={VisibilityIcon} onClick={this.handleHideClick} />
|
<IconButton className='status__action-bar__button' title={intl.formatMessage(messages.hide)} icon='eye' iconComponent={VisibilityIcon} onClick={this.handleHideClick} />
|
||||||
);
|
);
|
||||||
|
|
||||||
const emojiReactionAvailableServer = !hideEmojiReactionUnavailableServer || status.get('emoji_reaction_available_server');
|
const emojiReactionAvailableServer = !isHideItem('emoji_reaction_unavailable_server') || status.get('emoji_reaction_available_server');
|
||||||
const emojiReactionPolicy = account.getIn(['other_settings', 'emoji_reaction_policy']) || 'allow';
|
const emojiReactionPolicy = account.getIn(['other_settings', 'emoji_reaction_policy']) || 'allow';
|
||||||
const following = emojiReactionPolicy !== 'following_only' || (relationship && relationship.get('following'));
|
const following = emojiReactionPolicy !== 'following_only' || (relationship && relationship.get('following'));
|
||||||
const followed = emojiReactionPolicy !== 'followers_only' || (relationship && relationship.get('followed_by'));
|
const followed = emojiReactionPolicy !== 'followers_only' || (relationship && relationship.get('followed_by'));
|
||||||
|
|
|
@ -2,7 +2,7 @@ import { Map as ImmutableMap, List as ImmutableList } from 'immutable';
|
||||||
import { connect } from 'react-redux';
|
import { connect } from 'react-redux';
|
||||||
import { createSelector } from 'reselect';
|
import { createSelector } from 'reselect';
|
||||||
|
|
||||||
import { hideRecentEmojis } from 'mastodon/initial_state';
|
import { isHideItem } from 'mastodon/initial_state';
|
||||||
|
|
||||||
import { useEmoji } from '../../../actions/emojis';
|
import { useEmoji } from '../../../actions/emojis';
|
||||||
import { changeSetting } from '../../../actions/settings';
|
import { changeSetting } from '../../../actions/settings';
|
||||||
|
@ -51,7 +51,7 @@ const getFrequentlyUsedEmojis = createSelector([
|
||||||
deckEmojis = [...new Set(deckEmojis)];
|
deckEmojis = [...new Set(deckEmojis)];
|
||||||
|
|
||||||
let emojis;
|
let emojis;
|
||||||
if (!hideRecentEmojis) {
|
if (!isHideItem('recent_emojis')) {
|
||||||
emojis = emojiCounters
|
emojis = emojiCounters
|
||||||
.keySeq()
|
.keySeq()
|
||||||
.filter((ee) => deckEmojis.indexOf(ee) < 0)
|
.filter((ee) => deckEmojis.indexOf(ee) < 0)
|
||||||
|
|
|
@ -25,7 +25,7 @@ import { WithRouterPropTypes } from 'mastodon/utils/react_router';
|
||||||
|
|
||||||
import { IconButton } from '../../../components/icon_button';
|
import { IconButton } from '../../../components/icon_button';
|
||||||
import DropdownMenuContainer from '../../../containers/dropdown_menu_container';
|
import DropdownMenuContainer from '../../../containers/dropdown_menu_container';
|
||||||
import { enableEmojiReaction , bookmarkCategoryNeeded, me, hideEmojiReactionUnavailableServer } from '../../../initial_state';
|
import { enableEmojiReaction , bookmarkCategoryNeeded, me, isHideItem } from '../../../initial_state';
|
||||||
import EmojiPickerDropdown from '../../compose/containers/emoji_picker_dropdown_container';
|
import EmojiPickerDropdown from '../../compose/containers/emoji_picker_dropdown_container';
|
||||||
|
|
||||||
const messages = defineMessages({
|
const messages = defineMessages({
|
||||||
|
@ -358,7 +358,7 @@ class ActionBar extends PureComponent {
|
||||||
reblogTitle = intl.formatMessage(messages.cannot_reblog);
|
reblogTitle = intl.formatMessage(messages.cannot_reblog);
|
||||||
}
|
}
|
||||||
|
|
||||||
const emojiReactionAvailableServer = !hideEmojiReactionUnavailableServer || status.get('emoji_reaction_available_server');
|
const emojiReactionAvailableServer = !isHideItem('emoji_reaction_unavailable_server') || status.get('emoji_reaction_available_server');
|
||||||
const emojiReactionPolicy = account.getIn(['other_settings', 'emoji_reaction_policy']) || 'allow';
|
const emojiReactionPolicy = account.getIn(['other_settings', 'emoji_reaction_policy']) || 'allow';
|
||||||
const following = emojiReactionPolicy !== 'following_only' || (relationship && relationship.get('following'));
|
const following = emojiReactionPolicy !== 'following_only' || (relationship && relationship.get('following'));
|
||||||
const followed = emojiReactionPolicy !== 'followers_only' || (relationship && relationship.get('followed_by'));
|
const followed = emojiReactionPolicy !== 'followers_only' || (relationship && relationship.get('followed_by'));
|
||||||
|
|
|
@ -21,7 +21,7 @@ import { Icon } from 'mastodon/components/icon';
|
||||||
import PictureInPicturePlaceholder from 'mastodon/components/picture_in_picture_placeholder';
|
import PictureInPicturePlaceholder from 'mastodon/components/picture_in_picture_placeholder';
|
||||||
import { SearchabilityIcon } from 'mastodon/components/searchability_icon';
|
import { SearchabilityIcon } from 'mastodon/components/searchability_icon';
|
||||||
import { VisibilityIcon } from 'mastodon/components/visibility_icon';
|
import { VisibilityIcon } from 'mastodon/components/visibility_icon';
|
||||||
import { enableEmojiReaction, hideEmojiReactionUnavailableServer } from 'mastodon/initial_state';
|
import { enableEmojiReaction, isHideItem } from 'mastodon/initial_state';
|
||||||
import { WithRouterPropTypes } from 'mastodon/utils/react_router';
|
import { WithRouterPropTypes } from 'mastodon/utils/react_router';
|
||||||
|
|
||||||
import { Avatar } from '../../../components/avatar';
|
import { Avatar } from '../../../components/avatar';
|
||||||
|
@ -233,7 +233,7 @@ class DetailedStatus extends ImmutablePureComponent {
|
||||||
if (status.get('emoji_reactions')) {
|
if (status.get('emoji_reactions')) {
|
||||||
const emojiReactions = status.get('emoji_reactions');
|
const emojiReactions = status.get('emoji_reactions');
|
||||||
const emojiReactionPolicy = status.getIn(['account', 'other_settings', 'emoji_reaction_policy']) || 'allow';
|
const emojiReactionPolicy = status.getIn(['account', 'other_settings', 'emoji_reaction_policy']) || 'allow';
|
||||||
const emojiReactionAvailableServer = !hideEmojiReactionUnavailableServer || status.get('emoji_reaction_available_server');
|
const emojiReactionAvailableServer = !isHideItem('emoji_reaction_unavailable_server') || status.get('emoji_reaction_available_server');
|
||||||
if (emojiReactions.size > 0 && enableEmojiReaction && emojiReactionAvailableServer && emojiReactionPolicy !== 'block') {
|
if (emojiReactions.size > 0 && enableEmojiReaction && emojiReactionAvailableServer && emojiReactionPolicy !== 'block') {
|
||||||
emojiReactionsBar = <StatusEmojiReactionsBar emojiReactions={emojiReactions} status={status} onEmojiReact={this.props.onEmojiReact} onUnEmojiReact={this.props.onUnEmojiReact} />;
|
emojiReactionsBar = <StatusEmojiReactionsBar emojiReactions={emojiReactions} status={status} onEmojiReact={this.props.onEmojiReact} onUnEmojiReact={this.props.onUnEmojiReact} />;
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,7 +21,7 @@ import { ReactComponent as AntennaIcon } from '@material-symbols/svg-600/outline
|
||||||
|
|
||||||
import { WordmarkLogo } from 'mastodon/components/logo';
|
import { WordmarkLogo } from 'mastodon/components/logo';
|
||||||
import { NavigationPortal } from 'mastodon/components/navigation_portal';
|
import { NavigationPortal } from 'mastodon/components/navigation_portal';
|
||||||
import { enableDtlMenu, timelinePreview, trendsEnabled, dtlTag, enableLocalTimeline } from 'mastodon/initial_state';
|
import { enableDtlMenu, timelinePreview, trendsEnabled, dtlTag, enableLocalTimeline, isHideItem } from 'mastodon/initial_state';
|
||||||
import { transientSingleColumn } from 'mastodon/is_mobile';
|
import { transientSingleColumn } from 'mastodon/is_mobile';
|
||||||
|
|
||||||
import ColumnLink from './column_link';
|
import ColumnLink from './column_link';
|
||||||
|
@ -151,7 +151,7 @@ class NavigationPanel extends Component {
|
||||||
{signedIn && (
|
{signedIn && (
|
||||||
<>
|
<>
|
||||||
<ColumnLink transparent to='/bookmark_categories' icon='bookmarks' iconComponent={BookmarksIcon} text={intl.formatMessage(messages.bookmarks)} />
|
<ColumnLink transparent to='/bookmark_categories' icon='bookmarks' iconComponent={BookmarksIcon} text={intl.formatMessage(messages.bookmarks)} />
|
||||||
<ColumnLink transparent to='/favourites' icon='star' iconComponent={StarIcon} text={intl.formatMessage(messages.favourites)} />
|
{ !isHideItem('favourite_menu') && <ColumnLink transparent to='/favourites' icon='star' iconComponent={StarIcon} text={intl.formatMessage(messages.favourites)} /> }
|
||||||
<hr />
|
<hr />
|
||||||
|
|
||||||
<ColumnLink transparent href='/settings/preferences' icon='cog' iconComponent={SettingsIcon} text={intl.formatMessage(messages.preferences)} />
|
<ColumnLink transparent href='/settings/preferences' icon='cog' iconComponent={SettingsIcon} text={intl.formatMessage(messages.preferences)} />
|
||||||
|
|
|
@ -1,6 +1,17 @@
|
||||||
// @ts-check
|
// @ts-check
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @typedef { 'blocking_quote'
|
||||||
|
* | 'emoji_reaction_on_timeline'
|
||||||
|
* | 'emoji_reaction_unavailable_server'
|
||||||
|
* | 'favourite_menu'
|
||||||
|
* | 'quote_in_home'
|
||||||
|
* | 'quote_in_public'
|
||||||
|
* | 'recent_emojis'
|
||||||
|
* } HideItemsDefinition
|
||||||
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {[code: string, name: string, localName: string]} InitialStateLanguage
|
* @typedef {[code: string, name: string, localName: string]} InitialStateLanguage
|
||||||
*/
|
*/
|
||||||
|
@ -27,9 +38,7 @@
|
||||||
* @property {boolean} enable_local_timeline
|
* @property {boolean} enable_local_timeline
|
||||||
* @property {boolean} enable_dtl_menu
|
* @property {boolean} enable_dtl_menu
|
||||||
* @property {boolean=} expand_spoilers
|
* @property {boolean=} expand_spoilers
|
||||||
* @property {boolean} hide_blocking_quote
|
* @property {HideItemsDefinition[]} hide_items
|
||||||
* @property {boolean} hide_emoji_reaction_unavailable_server
|
|
||||||
* @property {boolean} hide_recent_emojis
|
|
||||||
* @property {boolean} limited_federation_mode
|
* @property {boolean} limited_federation_mode
|
||||||
* @property {string} locale
|
* @property {string} locale
|
||||||
* @property {string | null} mascot
|
* @property {string | null} mascot
|
||||||
|
@ -42,9 +51,6 @@
|
||||||
* @property {string} repository
|
* @property {string} repository
|
||||||
* @property {boolean} search_enabled
|
* @property {boolean} search_enabled
|
||||||
* @property {boolean} trends_enabled
|
* @property {boolean} trends_enabled
|
||||||
* @property {boolean} show_emoji_reaction_on_timeline
|
|
||||||
* @property {boolean} show_quote_in_home
|
|
||||||
* @property {boolean} show_quote_in_public
|
|
||||||
* @property {string} simple_timeline_menu
|
* @property {string} simple_timeline_menu
|
||||||
* @property {boolean} single_user_mode
|
* @property {boolean} single_user_mode
|
||||||
* @property {string} source_url
|
* @property {string} source_url
|
||||||
|
@ -87,6 +93,20 @@ export const hasMultiColumnPath = initialPath === '/'
|
||||||
*/
|
*/
|
||||||
const getMeta = (prop) => initialState?.meta && initialState.meta[prop];
|
const getMeta = (prop) => initialState?.meta && initialState.meta[prop];
|
||||||
|
|
||||||
|
const hideItems = getMeta('hide_items');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param {HideItemsDefinition} key
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
export const isHideItem = (key) => (hideItems && hideItems.includes(key)) || false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param {HideItemsDefinition} key
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
export const isShowItem = (key) => !isHideItem(key);
|
||||||
|
|
||||||
export const activityApiEnabled = getMeta('activity_api_enabled');
|
export const activityApiEnabled = getMeta('activity_api_enabled');
|
||||||
export const autoPlayGif = getMeta('auto_play_gif');
|
export const autoPlayGif = getMeta('auto_play_gif');
|
||||||
export const bookmarkCategoryNeeded = getMeta('bookmark_category_needed');
|
export const bookmarkCategoryNeeded = getMeta('bookmark_category_needed');
|
||||||
|
@ -105,9 +125,6 @@ export const enableLoginPrivacy = getMeta('enable_login_privacy');
|
||||||
export const enableDtlMenu = getMeta('enable_dtl_menu');
|
export const enableDtlMenu = getMeta('enable_dtl_menu');
|
||||||
export const expandSpoilers = getMeta('expand_spoilers');
|
export const expandSpoilers = getMeta('expand_spoilers');
|
||||||
export const forceSingleColumn = !getMeta('advanced_layout');
|
export const forceSingleColumn = !getMeta('advanced_layout');
|
||||||
export const hideBlockingQuote = getMeta('hide_blocking_quote');
|
|
||||||
export const hideEmojiReactionUnavailableServer = getMeta('hide_emoji_reaction_unavailable_server');
|
|
||||||
export const hideRecentEmojis = getMeta('hide_recent_emojis');
|
|
||||||
export const limitedFederationMode = getMeta('limited_federation_mode');
|
export const limitedFederationMode = getMeta('limited_federation_mode');
|
||||||
export const mascot = getMeta('mascot');
|
export const mascot = getMeta('mascot');
|
||||||
export const me = getMeta('me');
|
export const me = getMeta('me');
|
||||||
|
@ -119,9 +136,6 @@ export const registrationsOpen = getMeta('registrations_open');
|
||||||
export const repository = getMeta('repository');
|
export const repository = getMeta('repository');
|
||||||
export const searchEnabled = getMeta('search_enabled');
|
export const searchEnabled = getMeta('search_enabled');
|
||||||
export const trendsEnabled = getMeta('trends_enabled');
|
export const trendsEnabled = getMeta('trends_enabled');
|
||||||
export const showEmojiReactionOnTimeline = getMeta('show_emoji_reaction_on_timeline');
|
|
||||||
export const showQuoteInHome = getMeta('show_quote_in_home');
|
|
||||||
export const showQuoteInPublic = getMeta('show_quote_in_public');
|
|
||||||
export const showTrends = getMeta('show_trends');
|
export const showTrends = getMeta('show_trends');
|
||||||
export const simpleTimelineMenu = getMeta('simple_timeline_menu');
|
export const simpleTimelineMenu = getMeta('simple_timeline_menu');
|
||||||
export const singleUserMode = getMeta('single_user_mode');
|
export const singleUserMode = getMeta('single_user_mode');
|
||||||
|
|
|
@ -3,7 +3,7 @@ import { createSelector } from 'reselect';
|
||||||
|
|
||||||
import { toServerSideType } from 'mastodon/utils/filters';
|
import { toServerSideType } from 'mastodon/utils/filters';
|
||||||
|
|
||||||
import { me, hideBlockingQuote } from '../initial_state';
|
import { me, isHideItem } from '../initial_state';
|
||||||
|
|
||||||
export { makeGetAccount } from "./accounts";
|
export { makeGetAccount } from "./accounts";
|
||||||
|
|
||||||
|
@ -40,7 +40,7 @@ export const makeGetStatus = () => {
|
||||||
statusReblog = null;
|
statusReblog = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (hideBlockingQuote && (statusReblog || statusBase).getIn(['quote', 'quote_muted'])) {
|
if (isHideItem('blocking_quote') && (statusReblog || statusBase).getIn(['quote', 'quote_muted'])) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -263,6 +263,10 @@ module HasUserSettings
|
||||||
settings['web.hide_emoji_reaction_unavailable_server']
|
settings['web.hide_emoji_reaction_unavailable_server']
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def setting_hide_favourite_menu
|
||||||
|
settings['web.hide_favourite_menu']
|
||||||
|
end
|
||||||
|
|
||||||
def allows_report_emails?
|
def allows_report_emails?
|
||||||
settings['notification_emails.report']
|
settings['notification_emails.report']
|
||||||
end
|
end
|
||||||
|
|
|
@ -72,6 +72,7 @@ class UserSettings
|
||||||
setting :show_quote_in_public, default: false
|
setting :show_quote_in_public, default: false
|
||||||
setting :hide_blocking_quote, default: true
|
setting :hide_blocking_quote, default: true
|
||||||
setting :hide_emoji_reaction_unavailable_server, default: false
|
setting :hide_emoji_reaction_unavailable_server, default: false
|
||||||
|
setting :hide_favourite_menu, default: false
|
||||||
end
|
end
|
||||||
|
|
||||||
namespace :notification_emails do
|
namespace :notification_emails do
|
||||||
|
|
|
@ -51,10 +51,8 @@ class InitialStateSerializer < ActiveModel::Serializer
|
||||||
store[:display_media_expand] = object.current_account.user.setting_display_media_expand
|
store[:display_media_expand] = object.current_account.user.setting_display_media_expand
|
||||||
store[:expand_spoilers] = object.current_account.user.setting_expand_spoilers
|
store[:expand_spoilers] = object.current_account.user.setting_expand_spoilers
|
||||||
store[:enable_emoji_reaction] = object.current_account.user.setting_enable_emoji_reaction && Setting.enable_emoji_reaction
|
store[:enable_emoji_reaction] = object.current_account.user.setting_enable_emoji_reaction && Setting.enable_emoji_reaction
|
||||||
store[:show_emoji_reaction_on_timeline] = object.current_account.user.setting_show_emoji_reaction_on_timeline
|
|
||||||
store[:enable_login_privacy] = object.current_account.user.setting_enable_login_privacy
|
store[:enable_login_privacy] = object.current_account.user.setting_enable_login_privacy
|
||||||
store[:enable_dtl_menu] = object.current_account.user.setting_enable_dtl_menu
|
store[:enable_dtl_menu] = object.current_account.user.setting_enable_dtl_menu
|
||||||
store[:hide_recent_emojis] = object.current_account.user.setting_hide_recent_emojis
|
|
||||||
store[:reduce_motion] = object.current_account.user.setting_reduce_motion
|
store[:reduce_motion] = object.current_account.user.setting_reduce_motion
|
||||||
store[:disable_swiping] = object.current_account.user.setting_disable_swiping
|
store[:disable_swiping] = object.current_account.user.setting_disable_swiping
|
||||||
store[:advanced_layout] = object.current_account.user.setting_advanced_layout
|
store[:advanced_layout] = object.current_account.user.setting_advanced_layout
|
||||||
|
@ -63,19 +61,24 @@ class InitialStateSerializer < ActiveModel::Serializer
|
||||||
store[:show_trends] = Setting.trends && object.current_account.user.setting_trends
|
store[:show_trends] = Setting.trends && object.current_account.user.setting_trends
|
||||||
store[:bookmark_category_needed] = object.current_account.user.setting_bookmark_category_needed
|
store[:bookmark_category_needed] = object.current_account.user.setting_bookmark_category_needed
|
||||||
store[:simple_timeline_menu] = object.current_account.user.setting_simple_timeline_menu
|
store[:simple_timeline_menu] = object.current_account.user.setting_simple_timeline_menu
|
||||||
store[:show_quote_in_home] = object.current_account.user.setting_show_quote_in_home
|
store[:hide_items] = [
|
||||||
store[:show_quote_in_public] = object.current_account.user.setting_show_quote_in_public
|
object.current_account.user.setting_hide_favourite_menu ? 'favourite_menu' : nil,
|
||||||
store[:hide_blocking_quote] = object.current_account.user.setting_hide_blocking_quote
|
object.current_account.user.setting_hide_recent_emojis ? 'recent_emojis' : nil,
|
||||||
store[:hide_emoji_reaction_unavailable_server] = object.current_account.user.setting_hide_emoji_reaction_unavailable_server
|
object.current_account.user.setting_hide_blocking_quote ? 'blocking_quote' : nil,
|
||||||
|
object.current_account.user.setting_hide_emoji_reaction_unavailable_server ? 'emoji_reaction_unavailable_server' : nil,
|
||||||
|
object.current_account.user.setting_show_emoji_reaction_on_timeline ? nil : 'emoji_reaction_on_timeline',
|
||||||
|
object.current_account.user.setting_show_quote_in_home ? nil : 'quote_in_home',
|
||||||
|
object.current_account.user.setting_show_quote_in_public ? nil : 'quote_in_public',
|
||||||
|
].compact
|
||||||
else
|
else
|
||||||
store[:auto_play_gif] = Setting.auto_play_gif
|
store[:auto_play_gif] = Setting.auto_play_gif
|
||||||
store[:display_media] = Setting.display_media
|
store[:display_media] = Setting.display_media
|
||||||
store[:reduce_motion] = Setting.reduce_motion
|
store[:reduce_motion] = Setting.reduce_motion
|
||||||
store[:use_blurhash] = Setting.use_blurhash
|
store[:use_blurhash] = Setting.use_blurhash
|
||||||
store[:enable_emoji_reaction] = Setting.enable_emoji_reaction
|
store[:enable_emoji_reaction] = Setting.enable_emoji_reaction
|
||||||
store[:show_emoji_reaction_on_timeline] = Setting.enable_emoji_reaction
|
store[:hide_items] = [
|
||||||
store[:show_quote_in_home] = true
|
Setting.enable_emoji_reaction ? nil : 'emoji_reaction_on_timeline',
|
||||||
store[:show_quote_in_public] = true
|
].compact
|
||||||
end
|
end
|
||||||
|
|
||||||
store[:disabled_account_id] = object.disabled_account.id.to_s if object.disabled_account
|
store[:disabled_account_id] = object.disabled_account.id.to_s if object.disabled_account
|
||||||
|
|
|
@ -46,6 +46,7 @@
|
||||||
|
|
||||||
.fields-group
|
.fields-group
|
||||||
= ff.input :'web.bookmark_category_needed', wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_bookmark_category_needed'), hint: I18n.t('simple_form.hints.defaults.setting_bookmark_category_needed')
|
= ff.input :'web.bookmark_category_needed', wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_bookmark_category_needed'), hint: I18n.t('simple_form.hints.defaults.setting_bookmark_category_needed')
|
||||||
|
= ff.input :'web.hide_favourite_menu', wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_hide_favourite_menu')
|
||||||
|
|
||||||
.fields-group
|
.fields-group
|
||||||
= ff.input :'web.show_quote_in_home', wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_show_quote_in_home'), hint: false
|
= ff.input :'web.show_quote_in_home', wrapper: :with_label, kmyblue: true, label: I18n.t('simple_form.labels.defaults.setting_show_quote_in_home'), hint: false
|
||||||
|
|
|
@ -269,6 +269,7 @@ en:
|
||||||
setting_expand_spoilers: Always expand posts marked with content warnings
|
setting_expand_spoilers: Always expand posts marked with content warnings
|
||||||
setting_hide_blocking_quote: Hide posts which have a quote written by the user you are blocking
|
setting_hide_blocking_quote: Hide posts which have a quote written by the user you are blocking
|
||||||
setting_hide_emoji_reaction_unavailable_server: Hide stamp button from unavailable server
|
setting_hide_emoji_reaction_unavailable_server: Hide stamp button from unavailable server
|
||||||
|
setting_hide_favourite_menu: Hide favourite menu
|
||||||
setting_hide_followers_count: Hide followers count
|
setting_hide_followers_count: Hide followers count
|
||||||
setting_hide_following_count: Hide following count
|
setting_hide_following_count: Hide following count
|
||||||
setting_hide_network: Hide your social graph
|
setting_hide_network: Hide your social graph
|
||||||
|
|
|
@ -280,6 +280,7 @@ ja:
|
||||||
setting_expand_spoilers: 閲覧注意としてマークされた投稿を常に展開する
|
setting_expand_spoilers: 閲覧注意としてマークされた投稿を常に展開する
|
||||||
setting_hide_blocking_quote: ブロックしたユーザーの投稿を引用した投稿を隠す
|
setting_hide_blocking_quote: ブロックしたユーザーの投稿を引用した投稿を隠す
|
||||||
setting_hide_emoji_reaction_unavailable_server: スタンプに対応していないと思われるサーバーの投稿からスタンプボタンを隠す
|
setting_hide_emoji_reaction_unavailable_server: スタンプに対応していないと思われるサーバーの投稿からスタンプボタンを隠す
|
||||||
|
setting_hide_favourite_menu: 右サイドメニューから「お気に入り」を隠す
|
||||||
setting_hide_followers_count: フォロワー数を隠す
|
setting_hide_followers_count: フォロワー数を隠す
|
||||||
setting_hide_following_count: フォロー数を隠す
|
setting_hide_following_count: フォロー数を隠す
|
||||||
setting_hide_network: 繋がりを隠す
|
setting_hide_network: 繋がりを隠す
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue