Skip to content

Add onClose callback (or equiv) to showReportDialog #9433

Closed
@phayes

Description

@phayes

Problem Statement

I want to be able to take an action after a user has closed the report-dialog (opened via showReportDialog).

Specifically, after my javascript application has crashed (gotten into a unknown and likely corrupted state) I pop the report dialog via the showReportDialog. After the user either submits their report or otherwise closes the dialog I want to reload the page.

This is re-opening #758

The solution suggested in the previous issue does not work for three reasons:

  1. There's a race condition on when, exactly, the DOM elements are loaded.
  2. The classes attached to the specified elements are not part of the official API and therefore brittle and prone to change.
  3. This does not solve the issue of the user closing the dialog by simply clicking outside of it.

Solution Brainstorm

An an 'onClose' callback.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions