Home Reference Source
public class | source

Post

Extends:

react~Component → Post

Constructor Summary

Public Constructor
public

Component constructor

Member Summary

Public Members
public

Set open comment group function on state which passed by CommentGroup component

public

Close post write

public

Close share post

public

Show copy link

public

Delete a post

public

handleOpenComments(evt: event): *

Toggle on show/hide comment

public

Open post write

public

Open share post

public

Handle vote on a post

public

state: {"text": *, "readMoreState": *, "openComments": *, "shareOpen": *, "disableComments": *, "disableSharing": *, "shareTitle": string, "openCopyLink": *, "openPostWrite": *}

Method Summary

Public Methods
public

handleReadMore(evt: event)

Handle read more event

public

render(): react element

Reneder component DOM

Public Constructors

public constructor(props: object) source

Component constructor

Params:

NameTypeAttributeDescription
props object

is an object properties of component

Public Members

public getOpenCommentGroup(open: function): * source

Set open comment group function on state which passed by CommentGroup component

public handleClosePostWrite: * source

Close post write

public handleCloseShare: * source

Close share post

Show copy link

public handleDelete: * source

Delete a post

public handleOpenComments(evt: event): * source

Toggle on show/hide comment

public handleOpenPostWrite: * source

Open post write

public handleOpenShare: * source

Open share post

public handleVote: * source

Handle vote on a post

public state: {"text": *, "readMoreState": *, "openComments": *, "shareOpen": *, "disableComments": *, "disableSharing": *, "shareTitle": string, "openCopyLink": *, "openPostWrite": *} source

Public Methods

public handleReadMore(evt: event) source

Handle read more event

Params:

NameTypeAttributeDescription
evt event

is the event passed by click on read more

public render(): react element source

Reneder component DOM

Return:

react element

return the DOM which rendered by component