Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

Commit

Permalink
🐛 fix content filters jumping when loading screen is shown
Browse files Browse the repository at this point in the history
no issue
- ensure content filters in the loading screen have the same styles
- add session injection to `posts-loading` controller so that the authors dropdown doesn't appear when changing filters when logged in as an author
  • Loading branch information
kevinansfield committed Apr 13, 2017
1 parent 14bbb0d commit ff1717d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/controllers/posts-loading.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import Controller from 'ember-controller';
import {readOnly} from 'ember-computed';
import injectController from 'ember-controller/inject';
import injectService from 'ember-service/inject';

export default Controller.extend({

postsController: injectController('posts'),
session: injectService(),

availableTypes: readOnly('postsController.availableTypes'),
selectedType: readOnly('postsController.selectedType'),
Expand Down
6 changes: 6 additions & 0 deletions app/templates/posts-loading.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
classNames="gh-contentfilter-menu gh-contentfilter-type"
triggerClass="gh-contentfilter-menu-trigger"
dropdownClass="gh-contentfilter-menu-dropdown"
matchTriggerWidth=false
data-test-type-select=true
as |type|
}}
Expand All @@ -35,6 +36,7 @@
classNames="gh-contentfilter-menu gh-contentfilter-author"
triggerClass="gh-contentfilter-menu-trigger"
dropdownClass="gh-contentfilter-menu-dropdown"
matchTriggerWidth=false
data-test-author-select=true
as |author|
}}
Expand All @@ -52,6 +54,8 @@
classNames="gh-contentfilter-menu gh-contentfilter-tag"
triggerClass="gh-contentfilter-menu-trigger"
dropdownClass="gh-contentfilter-menu-dropdown"
searchPlaceholder="Search tags"
matchTriggerWidth=false
data-test-tag-select=true
as |tag|
}}
Expand All @@ -69,6 +73,8 @@
classNames="gh-contentfilter-menu gh-contentfilter-sort"
triggerClass="gh-contentfilter-menu-trigger"
dropdownClass="gh-contentfilter-menu-dropdown"
horizontalPosition="right"
matchTriggerWidth=false
data-test-order-select=true
as |order|
}}
Expand Down

0 comments on commit ff1717d

Please sign in to comment.