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

PostStreamScrubber

Extends:

src/common/Component.js~Component → PostStreamScrubber

The PostStreamScrubber component displays a scrubber which can be used to navigate/scrub through a post stream.

Attrs

  • stream
  • className

Member Summary

Public Members
public
public
public

handlers: {}

public
public
public
public

stream: *

Method Summary

Public Methods
public

Go to the first post in the discussion.

public

Go to the last post in the discussion.

public

onclick(e: *)

public

oncreate(vnode: *)

public

oninit(vnode: *)

public

onmousedown(e: *)

public

onmousemove(e: *)

public
public

onremove(vnode: *)

public
public

onupdate(vnode: *)

public

Get the percentage of the height of the scrubber that should be allocated to each post.

public

Update the scrollbar's position to reflect the current values of the index/visible properties.

public

view(): *

Public Members

public adjustingHeight: boolean source

public dragging: boolean source

public handlers: {} source

public indexStart: number source

public mouseStart: number source

public scrollListener: * source

public stream: * source

Public Methods

public goToFirst() source

Go to the first post in the discussion.

public goToLast() source

Go to the last post in the discussion.

public onclick(e: *) source

Params:

NameTypeAttributeDescription
e *

public oncreate(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public oninit(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public onmousedown(e: *) source

Params:

NameTypeAttributeDescription
e *

public onmousemove(e: *) source

Params:

NameTypeAttributeDescription
e *

public onmouseup() source

public onremove(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public onresize() source

public onupdate(vnode: *) source

Params:

NameTypeAttributeDescription
vnode *

public percentPerPost(): Object source

Get the percentage of the height of the scrubber that should be allocated to each post.

Return:

Object

Return Properties:

NameTypeAttributeDescription
index Number

The percent per post for posts on either side of the visible part of the scrubber.

visible Number

The percent per post for the visible part of the scrubber.

public updateScrubberValues(animate: Boolean) source

Update the scrollbar's position to reflect the current values of the index/visible properties.

Params:

NameTypeAttributeDescription
animate Boolean

public view(): * source

Return:

*