blob: 4edb54326c1a4c67780cf6e4f12d553b557616e0 [file] [log] [blame]
// Copyright 2018 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// https://wicg.github.io/portals/#the-portal-element
[Exposed=Window, HTMLConstructor, RuntimeEnabled=Portals]
interface HTMLPortalElement : HTMLElement {
[CEReactions, Reflect, URL] attribute USVString src;
[CEReactions, Reflect, ReflectOnly=("","no-referrer","origin","no-referrer-when-downgrade","origin-when-cross-origin","unsafe-url"), ReflectMissing="", ReflectInvalid=""] attribute DOMString referrerPolicy;
[CallWith=ScriptState, RaisesException, Measure] Promise<void> activate(optional PortalActivateOptions options);
[CallWith=ScriptState, RaisesException, Measure] void postMessage(any message, DOMString targetOrigin,
optional sequence<object> transfer = []);
[CallWith=ScriptState, RaisesException, Measure] void postMessage(any message, optional WindowPostMessageOptions options);
attribute EventHandler onmessage;
attribute EventHandler onmessageerror;
};