Reference Source
import IndexPage from 'flarum/forum/components/IndexPage'
public class | source

IndexPage

Extends:

src/common/components/Page.js~Page → IndexPage

The IndexPage component displays the index page, including the welcome hero, the sidebar, and the discussion list.

Static Member Summary

Static Public Members
public static

Member Summary

Public Members
public
public
public

Method Summary

Public Methods
public

Build an item list for the part of the toolbar which is about taking action on the results.

public

hero(): MithrilComponent

Get the component to display as the hero.

public

Mark all discussions as read.

public

Build an item list for the navigation in the sidebar of the index page.

public

Open the composer for a new discussion or prompt the user to login.

public

onbeforeremove(vnode: *)

public

oncreate(vnode: *)

public

oninit(vnode: *)

public

onremove(vnode: *)

public
public

Build an item list for the sidebar of the index page.

public

view(): *

public

Build an item list for the part of the toolbar which is concerned with how the results are displayed.

Static Public Members

public static providesInitialSearch: * source

Public Members

public bodyClass: string source

public lastDiscussion: * source

public scrollTopOnCreate: boolean source

Public Methods

public actionItems(): ItemList source

Build an item list for the part of the toolbar which is about taking action on the results. By default this is just a "mark all as read" button.

Return:

ItemList

public hero(): MithrilComponent source

Get the component to display as the hero.

Return:

MithrilComponent

public markAllAsRead(): * source

Mark all discussions as read.

Return:

*

void

public navItems(): ItemList source

Build an item list for the navigation in the sidebar of the index page. By default this is just the 'All Discussions' link.

Return:

ItemList

public newDiscussionAction(): Promise source

Open the composer for a new discussion or prompt the user to login.

Return:

Promise

public onbeforeremove(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public oncreate(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public oninit(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public onremove(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public setTitle() source

public sidebarItems(): ItemList source

Build an item list for the sidebar of the index page. By default this is a "New Discussion" button, and then a DropdownSelect component containing a list of navigation items.

Return:

ItemList

public view(): * source

Return:

*

public viewItems(): ItemList source

Build an item list for the part of the toolbar which is concerned with how the results are displayed. By default this is just a select box to change the way discussions are sorted.

Return:

ItemList