From ece5132abaadfede4fb13839b317fac30a326a31 Mon Sep 17 00:00:00 2001 From: Yoav Weiss Date: Fri, 23 Feb 2024 11:38:15 +0100 Subject: [PATCH] Add autofill endpoints and processing model --- index.html | 102 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) diff --git a/index.html b/index.html index 502eb9ef..d6da01ec 100644 --- a/index.html +++ b/index.html @@ -1039,6 +1039,18 @@

Endpoints

/session/{session id}/print Print Page + + + POST + /session/{session id}/autofill/save + Save autofill values + + + + POST + /session/{session id}/autofill/trigger + Trigger autofill + @@ -10782,6 +10794,96 @@

Print Page

+
+

Autofill

+ +

This chapter describes testing methods for the browser's autofill +functionality to enable web developers to automatically test their HTML +content for expected autofill behavior, against multiple browser +implementations.

+ +

These methods would allow saving of test autofill data and then +triggering the autofill functionality on particular form field.

+ +Autofill configuration is a record containing a "fields" property, +an ordered map whose [=map/keys=] are autofill field names +and values are the field values. + +A browsing context has a autofill store for testing, an +ordered map. + +
+

Save autofill values

+ + + + + + +
HTTP Method + URI Template +
POST + /session/{session id}/autofill/save +
+ +

The remote end steps are: + +

    +
  1. If the current top-level browsing context is no longer open, + return error with error code no such window. +

  2. Let store be the current top-level browsing context's + autofill store for testing. +

  3. Let configuration be the result of trying to + JSON deserialize the request’s body as an autofill configuration. +

  4. Let fields be the "fields" property of configuration. +

  5. [=map/For each=] key=>value of fields, set + store[key] to value. + +

    +
+ +

Trigger autofill

+ + + + + +
HTTP Method + URI Template +
POST + /session/{session id}/autofill/trigger +
+ +

The remote end steps are: + +

    +
  1. If the current top-level browsing context is no longer open, + return error with error code no such window. +

  2. Let element be the result of trying to + deserialize a web element given request body. +

  3. The user agent should autofill + element and element's form owner, + while taking into account the contents of the current top-level browsing context's + autofill store for testing. + +

+ +

Privacy