Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

patchkit/patchkit-post-composer

Open more actions menu

Repository files navigation

Post Composer

Composer component for public and private text posts

screenshot.png

import Composer from 'patchkit-post-composer'

<Composer 
  thread={thread}
  recps={[userid1,userid2]}
  channel="initial-channel-value"
  channels={app.channels}
  suggestOptions={app.suggestOptions}
  placeholder="Write your message here"

  onSend={onSend}
  onCancel={onCancel}

  isPublic
  cancelBtn />

Options:

  • channels: Channel suggestions (array of strings).
  • suggestOptions: Suggest-box suggestions (see suggest-box).
  • thread: Thread/message object, if this is a reply.
  • channel: Default channel value.
  • recps: Default recipients value (array of IDs).
  • placeholder: Placeholder string when there's no value.
  • onSend: Function called on publish.
  • onCancel: Function called on cancel.
  • isPublic: Default to public or private?
  • verticalFilled: Have the composer fill the vertical space?
  • cancelBtn: Should there be a cancel button?

Styles

Use the .less file:

@import "node_modules/patchkit-post-composer/styles.less"

About

Composer component for public and private text posts

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  
Morty Proxy This is a proxified and sanitized view of the page, visit original site.