From 8b845be6228f2520051e97a13a3c9b8a84596cd9 Mon Sep 17 00:00:00 2001
From: Jinho Bang
readonly attribute DOMString instrumentKey;
readonly attribute boolean requestBillingAddress;
Promise<WindowClient?> openWindow(USVString url);
+ Promise<PaymentHandlerResponse?> showPaymentUI(USVString url, optional object? data = null);
Promise<PaymentMethodChangeResponse?> changePaymentMethod(DOMString methodName, optional object? methodDetails = null);
void respondWith(Promise<PaymentHandlerResponse>handlerResponsePromise);
};
@@ -1301,6 +1302,16 @@
user. When called, it runs the open window algorithm.
+ This method is used by the payment handler to show a custom UI to + the user. When called, it runs the show payment UI + algorithm. +
+
+ [SecureContxt, Exposed=Window]
+ interface PaymentHandlerContainer {
+ readonly attribute object? data;
+ void respondWith(PaymentHandlerResponse response);
+ };
+
+ partial interface Navigator {
+ [SecureContext, SameObject] readonly attribute PaymentHandlerContainer paymentHandler;
+ };
+
+ + The data attribute returns + [[\paymentHandlerRequestData]]. +
++ This method is used by the associated payment handler window to + provide a PaymentHandlerResponse to the associated payment + handler. When called, this method sets the user agent's + payment handler response data to the response + argument. +
+about:blank, return a
+ Promise rejected with a TypeError.
+ undefined.
+