Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ViewerDocumentChooser<SS>

This component provides the user with a way to start a preview player by selecting a document from a list of active documents in either default, TV or standalone mode.

Type parameters

  • SS

Hierarchy

Index

Constructors

constructor

  • Parameters

    • props: __type

    Returns ViewerDocumentChooser

Properties

context

context: any

Private documentInterval

documentInterval: number

Private idInput

idInput: Nullable<HTMLSelectElement>

Private modeInput

modeInput: Nullable<HTMLSelectElement>

props

props: Readonly<object> & Readonly<__type>

refs

refs: object

Type declaration

  • [key: string]: ReactInstance

state

Methods

Optional UNSAFE_componentWillMount

  • UNSAFE_componentWillMount(): void

Optional UNSAFE_componentWillReceiveProps

  • UNSAFE_componentWillReceiveProps(nextProps: Readonly<__type>, nextContext: any): void

Optional UNSAFE_componentWillUpdate

  • UNSAFE_componentWillUpdate(nextProps: Readonly<__type>, nextState: Readonly<ViewerDocumentChooserState>, nextContext: any): void

Optional componentDidCatch

  • componentDidCatch(error: Error, errorInfo: ErrorInfo): void
  • Catches exceptions generated in descendant components. Unhandled exceptions will cause the entire component tree to unmount.

    Parameters

    • error: Error
    • errorInfo: ErrorInfo

    Returns void

componentDidMount

  • componentDidMount(): void
  • Invoked after the first time the component is mounted. Fetches a list of existing documents from the server once every 1000ms and updates the state accordingly.

    Returns void

Optional componentDidUpdate

  • Called immediately after updating occurs. Not called for the initial render.

    The snapshot is only present if getSnapshotBeforeUpdate is present and returns non-null.

    Parameters

    Returns void

Optional componentWillMount

  • componentWillMount(): void

Optional componentWillReceiveProps

  • componentWillReceiveProps(nextProps: Readonly<__type>, nextContext: any): void

componentWillUnmount

  • componentWillUnmount(): void
  • Invoked before the component is unmounted.

    Returns void

Optional componentWillUpdate

Private continueClicked

  • continueClicked(): void
  • Callback invoked when the Continue button is clicked by the user. Makes sure that all input fields are valid and there are existing documents present. If all conditions are met, the user is redirected to the preview player.

    Returns void

forceUpdate

  • forceUpdate(callBack?: undefined | function): void
  • Parameters

    • Optional callBack: undefined | function

    Returns void

Optional getSnapshotBeforeUpdate

  • Runs before React applies the result of render to the document, and returns an object to be given to componentDidUpdate. Useful for saving things such as scroll position before render causes changes to it.

    Note: the presence of getSnapshotBeforeUpdate prevents any of the deprecated lifecycle events from running.

    Parameters

    Returns SS | null

render

  • render(): Element
  • Renders the component

    Returns Element

setState

  • setState<K>(state: function | null | S | object, callback?: undefined | function): void
  • Type parameters

    • K: keyof ViewerDocumentChooserState

    Parameters

    • state: function | null | S | object
    • Optional callback: undefined | function

    Returns void

Optional shouldComponentUpdate

  • Called to determine whether the change in props and state should trigger a re-render.

    Component always returns true. PureComponent implements a shallow comparison on props and state and returns true if any props or states have changed.

    If false is returned, Component#render, componentWillUpdate and componentDidUpdate will not be called.

    Parameters

    Returns boolean

Generated using TypeDoc