Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • ComposerState

Index

Constructors

constructor

Properties

body

body: Object

The dynamic component being shown inside the composer.

editor

editor: null | EditorDriverInterface

A reference to the text editor that allows text manipulation.

fields

fields: undefined | { content: Stream<string> }

height

height: number

The composer's intended height, which can be modified by the user (by dragging the composer handle).

onExit

onExit: undefined | null | { callback: () => boolean; message: string }

position

position: { FULLSCREEN: string; HIDDEN: string; MINIMIZED: string; NORMAL: string }

The composer's current position.

Type declaration

  • FULLSCREEN: string
  • HIDDEN: string
  • MINIMIZED: string
  • NORMAL: string

Static Position

Position: { FULLSCREEN: string; HIDDEN: string; MINIMIZED: string; NORMAL: string }

Type declaration

  • FULLSCREEN: string
  • HIDDEN: string
  • MINIMIZED: string
  • NORMAL: string

Methods

bodyMatches

  • bodyMatches(type: object, data?: object): boolean
  • Determine whether the body matches the given component class and data.

    Parameters

    • type: object

      The component class to check against. Subclasses are accepted as well.

    • data: object = {}

    Returns boolean

clear

  • clear(): void

close

  • close(): void

composingReplyTo

computedHeight

  • computedHeight(): string | number
  • Computed the composer's current height, based on the intended height, and the composer's current state. This will be applied to the composer content's DOM element.

    Returns string | number

exitFullScreen

  • exitFullScreen(): void

fullScreen

  • fullScreen(): void

hide

  • hide(): void

isFullScreen

  • isFullScreen(): boolean
  • Determine whether or not the Composer is covering the screen.

    This will be true if the Composer is in full-screen mode on desktop, or if we are on a mobile device, where we always consider the composer as full-screen..

    Returns boolean

isVisible

  • isVisible(): boolean
  • Determine whether or not the Composer is visible.

    True when the composer is displayed on the screen and has a body component. It could be open in "normal" or full-screen mode, or even minimized.

    Returns boolean

load

maximumHeight

  • maximumHeight(): number

minimize

  • minimize(): void

minimumHeight

  • minimumHeight(): number

preventClosingWhen

  • preventClosingWhen(callback: () => boolean, message: string): void
  • Configure when / what to ask the user before closing the composer.

    The provided callback will be used to determine whether asking for confirmation is necessary. If the callback returns true at the time of closing, the provided text will be shown in a standard confirmation dialog.

    Parameters

    • callback: () => boolean
        • (): boolean
        • Returns boolean

    • message: string

    Returns void

preventExit

  • preventExit(): boolean
  • Confirm with the user that they want to close the composer and lose their content.

    Returns boolean

    Whether or not the exit was cancelled.

show

  • show(): void

Generated using TypeDoc version 0.22.10