mirror of
https://github.com/flarum/framework.git
synced 2025-02-27 23:00:54 +08:00
Use Page component for Tags page
This commit is contained in:
parent
69057183e0
commit
a7ebbf1035
@ -1,4 +1,4 @@
|
||||
import Component from 'flarum/Component';
|
||||
import Page from 'flarum/components/Page';
|
||||
import IndexPage from 'flarum/components/IndexPage';
|
||||
import listItems from 'flarum/helpers/listItems';
|
||||
import humanTime from 'flarum/helpers/humanTime';
|
||||
@ -7,14 +7,13 @@ import icon from 'flarum/helpers/icon';
|
||||
import tagLabel from 'flarum/tags/helpers/tagLabel';
|
||||
import sortTags from 'flarum/tags/utils/sortTags';
|
||||
|
||||
export default class TagsPage extends Component {
|
||||
export default class TagsPage extends Page {
|
||||
init() {
|
||||
super.init();
|
||||
|
||||
this.tags = sortTags(app.store.all('tags').filter(tag => !tag.parent()));
|
||||
|
||||
app.current = this;
|
||||
app.history.push('tags', icon('fas fa-th-large'));
|
||||
app.drawer.hide();
|
||||
app.modal.close();
|
||||
}
|
||||
|
||||
view() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user