A hook which allows displaying and interacting with a document preview.

  • Parameters

    • Optionaloptions: IParams

      An optional object containing the following parameters:

      • onLoadStart

        The callback function to be executed when the document starts loading.

      • onLoadEnd

        The callback function to be executed when the document finishes loading.

      • fallback

        The fallback content to be displayed while the document is loading.

      • onMount

        The callback function to be executed when the component is mounted.

      • onUnmount

        The callback function to be executed when the component is unmounted.

      • onSubmit

        The callback function to be executed when the submit button is clicked.

      • onClose

        The callback function to be executed when the component is closed.

      • title

        The title of the component.

      • submitLabel

        The label of the submit button.

    Returns { pickData: (request: IRequest) => void; render: () => Element }

    • An object containing the following properties: