From: Claire Date: Thu, 14 Oct 2021 18:55:16 +0000 (+0200) Subject: Merge branch 'main' into glitch-soc/merge-upstream X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=694c073d1f94a54a0ccf19299e06f1de849c6edb;p=mastodon.git Merge branch 'main' into glitch-soc/merge-upstream Conflicts: - `app/controllers/admin/dashboard_controller.rb`: Upstream completely redesigned the admin dashboard. glitch-soc tracked extra features, but that list is gone. Followed upstram. - `app/views/admin/dashboard/index.html.haml` Upstream completely redesigned the admin dashboard. glitch-soc tracked extra features, but that list is gone. Followed upstram. --- 694c073d1f94a54a0ccf19299e06f1de849c6edb diff --cc app/helpers/application_helper.rb index cc622478d,34fc46615..3fbc418cb --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@@ -137,10 -137,13 +137,14 @@@ module ApplicationHelpe end end + def react_admin_component(name, props = {}) + content_tag(:div, nil, data: { 'admin-component': name.to_s.camelcase, props: Oj.dump({ locale: I18n.locale }.merge(props)) }) + end + def body_classes output = (@body_classes || '').split(' ') - output << "theme-#{current_theme.parameterize}" + output << "flavour-#{current_flavour.parameterize}" + output << "skin-#{current_skin.parameterize}" output << 'system-font' if current_account&.user&.setting_system_font_ui output << (current_account&.user&.setting_reduce_motion ? 'reduce-motion' : 'no-reduce-motion') output << 'rtl' if locale_direction == 'rtl'