parent
912072d2e5
commit
997d744cea
9 changed files with 59 additions and 4 deletions
|
@ -171,6 +171,7 @@ module ApplicationHelper
|
||||||
output << 'system-font' if current_account&.user&.setting_system_font_ui
|
output << 'system-font' if current_account&.user&.setting_system_font_ui
|
||||||
output << (current_account&.user&.setting_reduce_motion ? 'reduce-motion' : 'no-reduce-motion')
|
output << (current_account&.user&.setting_reduce_motion ? 'reduce-motion' : 'no-reduce-motion')
|
||||||
output << 'rtl' if locale_direction == 'rtl'
|
output << 'rtl' if locale_direction == 'rtl'
|
||||||
|
output << "content-font-size__#{current_account&.user&.setting_content_font_size}"
|
||||||
output.compact_blank.join(' ')
|
output.compact_blank.join(' ')
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -46,6 +46,29 @@ body {
|
||||||
sans-serif;
|
sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&.content-font-size {
|
||||||
|
&__large {
|
||||||
|
--content-font-size: 18px;
|
||||||
|
--content-line-height: 27px;
|
||||||
|
--detail-content-font-size: 25px;
|
||||||
|
--detail-content-line-height: 32px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&__x_large {
|
||||||
|
--content-font-size: 22px;
|
||||||
|
--content-line-height: 30px;
|
||||||
|
--detail-content-font-size: 30px;
|
||||||
|
--detail-content-line-height: 39px;
|
||||||
|
}
|
||||||
|
|
||||||
|
&__xx_large {
|
||||||
|
--content-font-size: 30px;
|
||||||
|
--content-line-height: 44px;
|
||||||
|
--detail-content-font-size: 40px;
|
||||||
|
--detail-content-line-height: 52px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
&.app-body {
|
&.app-body {
|
||||||
padding: 0;
|
padding: 0;
|
||||||
|
|
||||||
|
|
|
@ -1003,8 +1003,8 @@ body > [data-popper-placement] {
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
font-size: 15px;
|
font-size: var(--content-font-size);
|
||||||
line-height: 22px;
|
line-height: var(--content-line-height);
|
||||||
padding-top: 2px;
|
padding-top: 2px;
|
||||||
color: $primary-text-color;
|
color: $primary-text-color;
|
||||||
|
|
||||||
|
@ -1738,8 +1738,8 @@ body > [data-popper-placement] {
|
||||||
}
|
}
|
||||||
|
|
||||||
.status__content {
|
.status__content {
|
||||||
font-size: 19px;
|
font-size: var(--detail-content-font-size);
|
||||||
line-height: 24px;
|
line-height: var(--detail-content-line-height);
|
||||||
|
|
||||||
.emojione {
|
.emojione {
|
||||||
min-width: 24px;
|
min-width: 24px;
|
||||||
|
|
|
@ -115,4 +115,8 @@ $font-monospace: 'mastodon-font-monospace' !default;
|
||||||
--surface-variant-background-color: #{$ui-base-color};
|
--surface-variant-background-color: #{$ui-base-color};
|
||||||
--surface-variant-active-background-color: #{lighten($ui-base-color, 4%)};
|
--surface-variant-active-background-color: #{lighten($ui-base-color, 4%)};
|
||||||
--avatar-border-radius: 8px;
|
--avatar-border-radius: 8px;
|
||||||
|
--content-font-size: 15px;
|
||||||
|
--content-line-height: 22px;
|
||||||
|
--detail-content-font-size: 19px;
|
||||||
|
--detail-content-line-height: 24px;
|
||||||
}
|
}
|
||||||
|
|
|
@ -103,6 +103,10 @@ module User::HasSettings
|
||||||
settings['web.use_system_font']
|
settings['web.use_system_font']
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def setting_content_font_size
|
||||||
|
settings['web.content_font_size']
|
||||||
|
end
|
||||||
|
|
||||||
def setting_show_quote_in_home
|
def setting_show_quote_in_home
|
||||||
settings['web.show_quote_in_home']
|
settings['web.show_quote_in_home']
|
||||||
end
|
end
|
||||||
|
|
|
@ -55,6 +55,7 @@ class UserSettings
|
||||||
setting :use_blurhash, default: true
|
setting :use_blurhash, default: true
|
||||||
setting :use_pending_items, default: false
|
setting :use_pending_items, default: false
|
||||||
setting :use_system_font, default: false
|
setting :use_system_font, default: false
|
||||||
|
setting :content_font_size, default: 'medium', in: %w(medium large x_large xx_large)
|
||||||
setting :bookmark_category_needed, default: false
|
setting :bookmark_category_needed, default: false
|
||||||
setting :disable_swiping, default: false
|
setting :disable_swiping, default: false
|
||||||
setting :disable_hover_cards, default: false
|
setting :disable_hover_cards, default: false
|
||||||
|
|
|
@ -60,6 +60,16 @@
|
||||||
= ff.input :'web.disable_hover_cards', wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_disable_hover_cards')
|
= 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_font', wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_system_font_ui')
|
||||||
|
|
||||||
|
.fields-group
|
||||||
|
= ff.input :'web.content_font_size',
|
||||||
|
collection: %w(medium large x_large xx_large),
|
||||||
|
hint: false,
|
||||||
|
include_blank: false,
|
||||||
|
kmyblue: true,
|
||||||
|
label_method: ->(size) { I18n.t("simple_form.labels.defaults.setting_content_font_size_items.#{size}") },
|
||||||
|
label: I18n.t('simple_form.labels.defaults.setting_content_font_size'),
|
||||||
|
wrapper: :with_label
|
||||||
|
|
||||||
%h4= t 'appearance.custom_emoji_and_emoji_reactions'
|
%h4= t 'appearance.custom_emoji_and_emoji_reactions'
|
||||||
|
|
||||||
.fields-group
|
.fields-group
|
||||||
|
|
|
@ -257,6 +257,12 @@ en:
|
||||||
setting_bookmark_category_needed: Category selection needed when registering bookmark on web
|
setting_bookmark_category_needed: Category selection needed when registering bookmark on web
|
||||||
setting_boost_menu: Show popup when click boost button
|
setting_boost_menu: Show popup when click boost button
|
||||||
setting_boost_modal: Show confirmation dialog before boosting
|
setting_boost_modal: Show confirmation dialog before boosting
|
||||||
|
setting_content_font_size: Font size of posts
|
||||||
|
setting_content_font_size_items:
|
||||||
|
large: Large
|
||||||
|
medium: Default
|
||||||
|
x_large: Large large
|
||||||
|
xx_large: Large large large
|
||||||
setting_default_language: Posting language
|
setting_default_language: Posting language
|
||||||
setting_default_privacy: Posting privacy
|
setting_default_privacy: Posting privacy
|
||||||
setting_default_reblog_privacy: Reblogging privacy
|
setting_default_reblog_privacy: Reblogging privacy
|
||||||
|
|
|
@ -257,6 +257,12 @@ ja:
|
||||||
setting_bookmark_category_needed: Webでブックマーク時にカテゴリの選択を必須にする
|
setting_bookmark_category_needed: Webでブックマーク時にカテゴリの選択を必須にする
|
||||||
setting_boost_menu: ブーストボタンを押したときにポップアップメニューを表示する
|
setting_boost_menu: ブーストボタンを押したときにポップアップメニューを表示する
|
||||||
setting_boost_modal: ブーストする前に確認ダイアログを表示する
|
setting_boost_modal: ブーストする前に確認ダイアログを表示する
|
||||||
|
setting_content_font_size: 投稿本文のフォントサイズ
|
||||||
|
setting_content_font_size_items:
|
||||||
|
large: 大きい
|
||||||
|
medium: デフォルト
|
||||||
|
x_large: 大きい大きい
|
||||||
|
xx_large: 大きい大きい大きい
|
||||||
setting_default_language: 投稿する言語
|
setting_default_language: 投稿する言語
|
||||||
setting_default_privacy: 投稿の公開範囲
|
setting_default_privacy: 投稿の公開範囲
|
||||||
setting_default_reblog_privacy: BTの公開範囲
|
setting_default_reblog_privacy: BTの公開範囲
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue