summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRenaud Chaput <renchap@gmail.com>2023-10-19 19:36:08 +0200
committerClaire <claire.github-309c@sitedethib.com>2023-12-04 15:28:15 +0100
commit4fc252354624d5b0fbafd86251204cc19edc525d (patch)
treec9012361faa123717ae0884695886def52b2a647
parentd5bc10b711dede8c84087de9240eea85c14ab7b0 (diff)
Do not display the navigation banner in the logo container (#27476)
-rw-r--r--app/javascript/mastodon/features/ui/components/navigation_panel.jsx30
-rw-r--r--app/javascript/styles/mastodon/components.scss1
2 files changed, 19 insertions, 12 deletions
diff --git a/app/javascript/mastodon/features/ui/components/navigation_panel.jsx b/app/javascript/mastodon/features/ui/components/navigation_panel.jsx
index 22eee79c0ac..b16eb5e1795 100644
--- a/app/javascript/mastodon/features/ui/components/navigation_panel.jsx
+++ b/app/javascript/mastodon/features/ui/components/navigation_panel.jsx
@@ -53,24 +53,30 @@ class NavigationPanel extends Component {
const { intl } = this.props;
const { signedIn, disabledAccountId } = this.context.identity;
+ let banner = undefined;
+
+ if(transientSingleColumn)
+ banner = (<div className='switch-to-advanced'>
+ {intl.formatMessage(messages.openedInClassicInterface)}
+ {" "}
+ <a href={`/deck${location.pathname}`} className='switch-to-advanced__toggle'>
+ {intl.formatMessage(messages.advancedInterface)}
+ </a>
+ </div>);
+
return (
<div className='navigation-panel'>
<div className='navigation-panel__logo'>
<Link to='/' className='column-link column-link--logo'><WordmarkLogo /></Link>
-
- {transientSingleColumn ? (
- <div className='switch-to-advanced'>
- {intl.formatMessage(messages.openedInClassicInterface)}
- {" "}
- <a href={`/deck${location.pathname}`} className='switch-to-advanced__toggle'>
- {intl.formatMessage(messages.advancedInterface)}
- </a>
- </div>
- ) : (
- <hr />
- )}
+ {!banner && <hr />}
</div>
+ {banner &&
+ <div class='navigation-panel__banner'>
+ {banner}
+ </div>
+ }
+
{signedIn && (
<>
<ColumnLink transparent to='/home' icon='home' text={intl.formatMessage(messages.home)} />
diff --git a/app/javascript/styles/mastodon/components.scss b/app/javascript/styles/mastodon/components.scss
index 567397a07b6..8c88b7dd6cc 100644
--- a/app/javascript/styles/mastodon/components.scss
+++ b/app/javascript/styles/mastodon/components.scss
@@ -2466,6 +2466,7 @@ $ui-header-height: 55px;
.navigation-panel__sign-in-banner,
.navigation-panel__logo,
+ .navigation-panel__banner,
.getting-started__trends {
display: none;
}