DEV: Remove `redesigned_user_page_nav_enabled` property (#20409)
This commit removes all references to the `redesigned_user_page_nav_enabled` which was used as a feature flag for developing the new user profile navigation menu previously.
This commit is contained in:
parent
ab46a05d77
commit
576745637e
|
@ -1,84 +0,0 @@
|
|||
<DNavigationItem
|
||||
@route="userActivity.index"
|
||||
@class="user-nav__activity-all"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "stream"}}
|
||||
<span>{{i18n "user.filters.all"}}</span>
|
||||
</DNavigationItem>
|
||||
<DNavigationItem
|
||||
@route="userActivity.topics"
|
||||
@class="user-nav__activity-topics"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "list-ul"}}
|
||||
<span>{{i18n "user_action_groups.4"}}</span>
|
||||
</DNavigationItem>
|
||||
<DNavigationItem
|
||||
@route="userActivity.replies"
|
||||
@class="user-nav__activity-replies"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "reply"}}
|
||||
<span>{{i18n "user_action_groups.5"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
{{#if @user.showRead}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.read"
|
||||
@class="user-nav__activity-read"
|
||||
@title={{i18n "user.read_help"}}
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "history"}}
|
||||
<span>{{i18n "user.read"}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
{{#if @user.showDrafts}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.drafts"
|
||||
@class="user-nav__activity-drafts"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "pencil-alt"}}
|
||||
<span>{{@draftLabel}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
{{#if (gt @model.pending_posts_count 0)}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.pending"
|
||||
@class="user-nav__activity-pending"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "clock"}}
|
||||
<span>{{@pendingLabel}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
<DNavigationItem
|
||||
@route="userActivity.likesGiven"
|
||||
@class="user-nav__activity-likes"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "heart"}}
|
||||
<span>{{i18n "user_action_groups.1"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
{{#if @user.showBookmarks}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.bookmarks"
|
||||
@class="user-nav__activity-bookmarks"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "bookmark"}}
|
||||
<span>{{i18n "user_action_groups.3"}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
<PluginOutlet
|
||||
@name="user-activity-bottom"
|
||||
@connectorTagName="li"
|
||||
@outletArgs={{hash model=@model}}
|
||||
/>
|
|
@ -1,52 +0,0 @@
|
|||
<DNavigationItem
|
||||
@route="userNotifications.index"
|
||||
@class="user-nav__notifications-all"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "bell"}}
|
||||
<span>{{i18n "user.filters.all"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<DNavigationItem
|
||||
@route="userNotifications.responses"
|
||||
@class="user-nav__notifications-responses"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "reply"}}
|
||||
<span>{{i18n "user_action_groups.6"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<DNavigationItem
|
||||
@route="userNotifications.likesReceived"
|
||||
@class="user-nav__notifications-likes"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "heart"}}
|
||||
<span>{{i18n "user_action_groups.2"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
{{#if @siteSettings.enable_mentions}}
|
||||
<DNavigationItem
|
||||
@route="userNotifications.mentions"
|
||||
@class="user-nav__notifications-mentions"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "at"}}
|
||||
<span>{{i18n "user_action_groups.7"}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
<DNavigationItem
|
||||
@route="userNotifications.edits"
|
||||
@class="user-nav__notifications-edits"
|
||||
@ariaCurrentContext={{@ariaCurrentContext}}
|
||||
>
|
||||
{{d-icon "pencil-alt"}}
|
||||
<span>{{i18n "user_action_groups.11"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<PluginOutlet
|
||||
@name="user-notifications-bottom"
|
||||
@connectorTagName="li"
|
||||
@outletArgs={{hash model=@model}}
|
||||
/>
|
|
@ -1,47 +1,25 @@
|
|||
{{#if this.can_see_invite_details}}
|
||||
{{#if this.currentUser.redesigned_user_page_nav_enabled}}
|
||||
<DSection @pageClass="user-invites" />
|
||||
<DSection @pageClass="user-invites" />
|
||||
|
||||
<div class="user-navigation user-navigation-secondary">
|
||||
<HorizontalOverflowNav @ariaLabel="User secondary - invites">
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="pending"
|
||||
@i18nLabel={{this.pendingLabel}}
|
||||
/>
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="expired"
|
||||
@i18nLabel={{this.expiredLabel}}
|
||||
/>
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="redeemed"
|
||||
@i18nLabel={{this.redeemedLabel}}
|
||||
/>
|
||||
</HorizontalOverflowNav>
|
||||
</div>
|
||||
{{else}}
|
||||
<DSection @class="user-secondary-navigation" @pageClass="user-invites">
|
||||
<MobileNav @class="invites-nav" @desktopClass="nav-stacked action-list">
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="pending"
|
||||
@i18nLabel={{this.pendingLabel}}
|
||||
/>
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="expired"
|
||||
@i18nLabel={{this.expiredLabel}}
|
||||
/>
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="redeemed"
|
||||
@i18nLabel={{this.redeemedLabel}}
|
||||
/>
|
||||
</MobileNav>
|
||||
</DSection>
|
||||
{{/if}}
|
||||
<div class="user-navigation user-navigation-secondary">
|
||||
<HorizontalOverflowNav @ariaLabel="User secondary - invites">
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="pending"
|
||||
@i18nLabel={{this.pendingLabel}}
|
||||
/>
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="expired"
|
||||
@i18nLabel={{this.expiredLabel}}
|
||||
/>
|
||||
<NavItem
|
||||
@route="userInvited.show"
|
||||
@routeParam="redeemed"
|
||||
@i18nLabel={{this.redeemedLabel}}
|
||||
/>
|
||||
</HorizontalOverflowNav>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{outlet}}
|
|
@ -1,94 +1,94 @@
|
|||
{{#if this.currentUser.redesigned_user_page_nav_enabled}}
|
||||
<DSection @pageClass="user-activity" />
|
||||
<DSection @pageClass="user-activity" />
|
||||
|
||||
<div class="user-navigation user-navigation-secondary">
|
||||
<HorizontalOverflowNav @ariaLabel="User secondary - activity">
|
||||
<UserNav::ActivityNav
|
||||
@user={{this.user}}
|
||||
@viewingSelf={{this.viewingSelf}}
|
||||
@model={{this.model}}
|
||||
@siteSettings={{this.siteSettings}}
|
||||
@draftLabel={{this.draftLabel}}
|
||||
@pendingLabel={{this.pendingLabel}}
|
||||
<div class="user-navigation user-navigation-secondary">
|
||||
<HorizontalOverflowNav @ariaLabel="User secondary - activity">
|
||||
<DNavigationItem
|
||||
@route="userActivity.index"
|
||||
@class="user-nav__activity-all"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "stream"}}
|
||||
<span>{{i18n "user.filters.all"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<DNavigationItem
|
||||
@route="userActivity.topics"
|
||||
@class="user-nav__activity-topics"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "list-ul"}}
|
||||
<span>{{i18n "user_action_groups.4"}}</span>
|
||||
</DNavigationItem>
|
||||
<DNavigationItem
|
||||
@route="userActivity.replies"
|
||||
@class="user-nav__activity-replies"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "reply"}}
|
||||
<span>{{i18n "user_action_groups.5"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
{{#if this.user.showRead}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.read"
|
||||
@class="user-nav__activity-read"
|
||||
@title={{i18n "user.read_help"}}
|
||||
@ariaCurrentContext="subNav"
|
||||
/>
|
||||
</HorizontalOverflowNav>
|
||||
</div>
|
||||
|
||||
{{else}}
|
||||
<DSection
|
||||
@pageClass="user-activity"
|
||||
@class="user-secondary-navigation"
|
||||
@scrollTop={{false}}
|
||||
>
|
||||
<nav role="navigation">
|
||||
<MobileNav
|
||||
@class="activity-nav"
|
||||
@desktopClass="action-list activity-list nav-stacked"
|
||||
>
|
||||
<DNavigationItem @route="userActivity.index">{{i18n
|
||||
"user.filters.all"
|
||||
}}</DNavigationItem>
|
||||
<DNavigationItem @route="userActivity.topics">{{i18n
|
||||
"user_action_groups.4"
|
||||
}}</DNavigationItem>
|
||||
<DNavigationItem @route="userActivity.replies">{{i18n
|
||||
"user_action_groups.5"
|
||||
}}</DNavigationItem>
|
||||
{{d-icon "history"}}
|
||||
<span>{{i18n "user.read"}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
{{#if this.user.showRead}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.read"
|
||||
@title={{i18n "user.read_help"}}
|
||||
>
|
||||
{{i18n "user.read"}}
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
{{#if this.user.showDrafts}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.drafts"
|
||||
@class="user-nav__activity-drafts"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "pencil-alt"}}
|
||||
<span>{{this.draftLabel}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
{{#if this.user.showDrafts}}
|
||||
<DNavigationItem @route="userActivity.drafts">
|
||||
{{this.draftLabel}}
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
{{#if (gt this.model.pending_posts_count 0)}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.pending"
|
||||
@class="user-nav__activity-pending"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "clock"}}
|
||||
<span>{{this.pendingLabel}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
{{#if (gt this.model.pending_posts_count 0)}}
|
||||
<DNavigationItem @route="userActivity.pending">
|
||||
{{this.pendingLabel}}
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.likesGiven"
|
||||
@class="user-nav__activity-likes"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "heart"}}
|
||||
<span>{{i18n "user_action_groups.1"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<DNavigationItem @route="userActivity.likesGiven">{{i18n
|
||||
"user_action_groups.1"
|
||||
}}</DNavigationItem>
|
||||
{{#if this.user.showBookmarks}}
|
||||
<DNavigationItem
|
||||
@route="userActivity.bookmarks"
|
||||
@class="user-nav__activity-bookmarks"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "bookmark"}}
|
||||
<span>{{i18n "user_action_groups.3"}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
{{#if this.user.showBookmarks}}
|
||||
<DNavigationItem @route="userActivity.bookmarks">{{i18n
|
||||
"user_action_groups.3"
|
||||
}}</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
<span>
|
||||
<PluginOutlet
|
||||
@name="user-activity-bottom"
|
||||
@connectorTagName="li"
|
||||
@outletArgs={{hash model=this.model}}
|
||||
/>
|
||||
</span>
|
||||
</MobileNav>
|
||||
</nav>
|
||||
</DSection>
|
||||
|
||||
{{#if this.canDownloadPosts}}
|
||||
<section class="user-additional-controls">
|
||||
<DButton
|
||||
@action={{action "exportUserArchive"}}
|
||||
@class="btn-default"
|
||||
@label="user.download_archive.button_text"
|
||||
@icon="download"
|
||||
/>
|
||||
</section>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
<PluginOutlet
|
||||
@name="user-activity-bottom"
|
||||
@connectorTagName="li"
|
||||
@outletArgs={{hash model=this.model}}
|
||||
/>
|
||||
</HorizontalOverflowNav>
|
||||
</div>
|
||||
|
||||
<section class="user-content" id="user-content">
|
||||
{{outlet}}
|
||||
|
|
|
@ -1,74 +1,64 @@
|
|||
{{#if this.currentUser.redesigned_user_page_nav_enabled}}
|
||||
<DSection @pageClass="user-notifications" />
|
||||
<DSection @pageClass="user-notifications" />
|
||||
|
||||
<div class="user-navigation user-navigation-secondary">
|
||||
<HorizontalOverflowNav @ariaLabel="User secondary - notifications">
|
||||
<UserNav::NotificationsNav
|
||||
@model={{this.model}}
|
||||
@siteSettings={{this.siteSettings}}
|
||||
@ariaCurrentContext="subNav"
|
||||
/>
|
||||
</HorizontalOverflowNav>
|
||||
|
||||
{{#if this.model}}
|
||||
<div class="navigation-controls">
|
||||
<DButton
|
||||
@title="user.dismiss_notifications_tooltip"
|
||||
@class="btn btn-default dismiss-notifications"
|
||||
@action={{action "resetNew"}}
|
||||
@label="user.dismiss_notifications"
|
||||
@icon="check"
|
||||
@disabled={{this.allNotificationsRead}}
|
||||
/>
|
||||
</div>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{else}}
|
||||
<DSection @pageClass="user-notifications" @class="user-secondary-navigation">
|
||||
<MobileNav
|
||||
@class="notifications-nav"
|
||||
@desktopClass="notification-list action-list nav-stacked"
|
||||
<div class="user-navigation user-navigation-secondary">
|
||||
<HorizontalOverflowNav @ariaLabel="User secondary - notifications">
|
||||
<DNavigationItem
|
||||
@route="userNotifications.index"
|
||||
@class="user-nav__notifications-all"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
<li>
|
||||
<LinkTo @route="userNotifications.index">
|
||||
{{i18n "user.filters.all"}}
|
||||
</LinkTo>
|
||||
</li>
|
||||
<li>
|
||||
<LinkTo @route="userNotifications.responses">
|
||||
{{i18n "user_action_groups.6"}}
|
||||
</LinkTo>
|
||||
</li>
|
||||
<li>
|
||||
<LinkTo @route="userNotifications.likesReceived">
|
||||
{{i18n "user_action_groups.2"}}
|
||||
</LinkTo>
|
||||
</li>
|
||||
{{#if this.siteSettings.enable_mentions}}
|
||||
<li>
|
||||
<LinkTo @route="userNotifications.mentions">
|
||||
{{i18n "user_action_groups.7"}}
|
||||
</LinkTo>
|
||||
</li>
|
||||
{{/if}}
|
||||
<li>
|
||||
<LinkTo @route="userNotifications.edits">
|
||||
{{i18n "user_action_groups.11"}}
|
||||
</LinkTo>
|
||||
</li>
|
||||
<span>
|
||||
<PluginOutlet
|
||||
@name="user-notifications-bottom"
|
||||
@connectorTagName="li"
|
||||
@outletArgs={{hash model=this.model}}
|
||||
/>
|
||||
</span>
|
||||
</MobileNav>
|
||||
{{d-icon "bell"}}
|
||||
<span>{{i18n "user.filters.all"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
</DSection>
|
||||
<DNavigationItem
|
||||
@route="userNotifications.responses"
|
||||
@class="user-nav__notifications-responses"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "reply"}}
|
||||
<span>{{i18n "user_action_groups.6"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<DNavigationItem
|
||||
@route="userNotifications.likesReceived"
|
||||
@class="user-nav__notifications-likes"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "heart"}}
|
||||
<span>{{i18n "user_action_groups.2"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
{{#if this.siteSettings.enable_mentions}}
|
||||
<DNavigationItem
|
||||
@route="userNotifications.mentions"
|
||||
@class="user-nav__notifications-mentions"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "at"}}
|
||||
<span>{{i18n "user_action_groups.7"}}</span>
|
||||
</DNavigationItem>
|
||||
{{/if}}
|
||||
|
||||
<DNavigationItem
|
||||
@route="userNotifications.edits"
|
||||
@class="user-nav__notifications-edits"
|
||||
@ariaCurrentContext="subNav"
|
||||
>
|
||||
{{d-icon "pencil-alt"}}
|
||||
<span>{{i18n "user_action_groups.11"}}</span>
|
||||
</DNavigationItem>
|
||||
|
||||
<PluginOutlet
|
||||
@name="user-notifications-bottom"
|
||||
@connectorTagName="li"
|
||||
@outletArgs={{hash model=this.model}}
|
||||
/>
|
||||
|
||||
</HorizontalOverflowNav>
|
||||
|
||||
{{#if this.model}}
|
||||
<section class="user-additional-controls">
|
||||
<div class="navigation-controls">
|
||||
<DButton
|
||||
@title="user.dismiss_notifications_tooltip"
|
||||
@class="btn btn-default dismiss-notifications"
|
||||
|
@ -77,9 +67,9 @@
|
|||
@icon="check"
|
||||
@disabled={{this.allNotificationsRead}}
|
||||
/>
|
||||
</section>
|
||||
</div>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
</div>
|
||||
|
||||
<section class="user-content" id="user-content">
|
||||
<LoadMore
|
||||
|
|
|
@ -64,7 +64,6 @@ class CurrentUserSerializer < BasicUserSerializer
|
|||
:status,
|
||||
:grouped_unread_notifications,
|
||||
:redesigned_user_menu_enabled,
|
||||
:redesigned_user_page_nav_enabled,
|
||||
:display_sidebar_tags,
|
||||
:sidebar_tags,
|
||||
:sidebar_category_ids,
|
||||
|
@ -300,11 +299,6 @@ class CurrentUserSerializer < BasicUserSerializer
|
|||
redesigned_user_menu_enabled
|
||||
end
|
||||
|
||||
# TODO(tgxworld): Return true for now until reliance on this attribute has been removed on the client side
|
||||
def redesigned_user_page_nav_enabled
|
||||
true
|
||||
end
|
||||
|
||||
def custom_sidebar_sections_enabled
|
||||
if SiteSetting.enable_custom_sidebar_sections.present?
|
||||
object.in_any_groups?(SiteSetting.enable_custom_sidebar_sections_map)
|
||||
|
|
Loading…
Reference in New Issue