chromium/third_party/blink/renderer/core/html/closewatcher/close_watcher.idl

// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// https://github.com/WICG/close-watcher
[
  Exposed=Window
] interface CloseWatcher : EventTarget {
  [CallWith=ScriptState, RaisesException] constructor(optional CloseWatcherOptions options = {});

  void requestClose();
  void close();
  void destroy();

  attribute EventHandler oncancel;
  attribute EventHandler onclose;
};