Skip to content
This repository was archived by the owner on Mar 19, 2021. It is now read-only.

Commit a18270e

Browse files
rayankanschromium-wpt-export-bot
authored andcommitted
[Contacts] Update implementation to match spec changes.
- Expose the `address` property and place it behind a flag. - Add & implement the getProperties method. Change-Id: If9bbebde6b8d076fd48b0b8a3584181e40adc1d4 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1835621 Reviewed-by: Stephen White <[email protected]> Reviewed-by: Peter Beverloo <[email protected]> Commit-Queue: Rayan Kanso <[email protected]> Cr-Commit-Position: refs/heads/master@{#702810}
1 parent 04c6f30 commit a18270e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

contacts/contacts-select.https.window.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,17 @@ contactsTestWithUserActivation(async (test, setSelectedContacts) => {
4747

4848
}, 'The Contact API can fail when the selector cannot be opened');
4949

50+
contactsTestWithUserActivation(async (test, setSelectedContacts) => {
51+
setSelectedContacts([]);
52+
53+
const properties = await navigator.contacts.getProperties();
54+
assert_true(properties.length > 0);
55+
56+
// Requesting the available properties should not fail.
57+
await navigator.contacts.select(properties);
58+
59+
}, 'Supported contact properties are exposed.');
60+
5061
contactsTestWithUserActivation(async (test, setSelectedContacts) => {
5162
// Returns two contacts with all information available.
5263
setSelectedContacts([

0 commit comments

Comments
 (0)