mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-29 07:09:48 +03:00
Content link resets filter if already viewing content screen (#521)
no issue - the content filter will be remembered if you navigate away from then back to the content screen - this PR changes the behaviour slightly so that clicking the sidebar "Content" link whilst viewing the content screen will act as a shortcut to reset the filter
This commit is contained in:
parent
bb007ec84f
commit
a8a7e98150
@ -20,6 +20,7 @@ export default Component.extend({
|
||||
session: injectService(),
|
||||
ghostPaths: injectService(),
|
||||
feature: injectService(),
|
||||
routing: injectService('-routing'),
|
||||
|
||||
mouseEnter() {
|
||||
this.sendAction('onMouseEnter');
|
||||
|
@ -21,8 +21,15 @@
|
||||
<ul class="gh-nav-list gh-nav-main">
|
||||
{{!<li><i class="icon-dash"></i>Dashboard</li>}}
|
||||
<li>{{#link-to "editor.new" classNames="gh-nav-main-editor"}}<i class="icon-pen"></i>New Post{{/link-to}}</li>
|
||||
<li>{{#link-to "posts" classNames="gh-nav-main-content"}}<i class="icon-content"></i>Content{{/link-to}}</li>
|
||||
{{!<li><a href="#"><i class="icon-user"></i>My Posts</a></li>}}
|
||||
<li>
|
||||
{{!-- clicking the Content link whilst on the content screen should reset the filter --}}
|
||||
{{#if (eq routing.currentRouteName "posts.index")}}
|
||||
{{#link-to "posts" (query-params type=null) classNames="gh-nav-main-content active"}}<i class="icon-content"></i>Content{{/link-to}}
|
||||
{{else}}
|
||||
{{#link-to "posts" classNames="gh-nav-main-content"}}<i class="icon-content"></i>Content{{/link-to}}
|
||||
{{/if}}
|
||||
</li>
|
||||
<li>{{#link-to "team" classNames="gh-nav-main-users"}}<i class="icon-team"></i>Team{{/link-to}}</li>
|
||||
{{!<li><a href="#"><i class="icon-idea"></i>Ideas</a></li>}}
|
||||
{{#if feature.subscribers}}
|
||||
|
Loading…
Reference in New Issue
Block a user