https://github.com/web-platform-tests/wpt
Raw File
Tip revision: 933c42829a0b57ae83016a14eaafb152d37d343b authored by Yoav Weiss on 21 December 2018, 21:00:08 UTC
Fix resource-timing.html document.domain test
Tip revision: 933c428
web-nfc.idl
// GENERATED CONTENT - DO NOT EDIT
// Content was automatically extracted by Reffy into reffy-reports
// (https://github.com/tidoust/reffy-reports)
// Source: Web NFC API (https://w3c.github.io/web-nfc/)

dictionary NFCMessage {
  sequence<NFCRecord> records;
  USVString url;
};

typedef (DOMString or unrestricted double or ArrayBuffer or Dictionary) NFCRecordData;

dictionary NFCRecord {
  NFCRecordType recordType;
  USVString mediaType;
  NFCRecordData data;
};

enum NFCRecordType {
  "empty",
  "text",
  "url",
  "json",
  "opaque"
};

partial interface Navigator {
  [SecureContext, SameObject] readonly attribute NFC nfc;
};

typedef (DOMString or ArrayBuffer or NFCMessage) NFCMessageSource;

[Constructor(), SecureContext, Exposed=Window]
interface NFCWriter {
  Promise<void> push(NFCMessageSource message, optional NFCPushOptions options);
};

[SecureContext]
interface NFC {
  Promise<void> watch(MessageCallback callback, optional NFCWatchOptions options);
};

callback MessageCallback = void (NFCMessage message);

dictionary NFCPushOptions {
  NFCPushTarget target = "any";
  unrestricted double timeout = Infinity;
  boolean ignoreRead = true;
  AbortSignal? signal;
};

enum NFCPushTarget {
  "tag",
  "peer",
  "any"
};

dictionary NFCWatchOptions {
  USVString url = "";
  NFCRecordType recordType;
  USVString mediaType = "";
  NFCWatchMode mode = "web-nfc-only";
  AbortSignal? signal;
};

enum NFCWatchMode {
  "web-nfc-only",
  "any"
};
back to top