Sanity Library Reference Docs
    Preparing search index...

    Function useDialogStack

    • Beta

      Hook to register a dialog in the stack and check if it's the top-most one.

      Parameters

      • __namedParameters: { path?: Path } = {}

      Returns { close: any; dialogId: string; isTop: boolean; stack: any; topEntry: any }

      • close: any

        Close dialogs

      • dialogId: string

        Unique ID for this dialog instance

      • isTop: boolean

        Check if this dialog is on top

      • stack: any

        The full stack of dialog entries (each has id and path)

      • topEntry: any

        The current top dialog entry