2024-11-30 20:23:38 -08:00
|
|
|
typedef Promise<(DOMString or Blob)> ClipboardItemData;
|
|
|
|
|
|
|
|
|
|
// https://w3c.github.io/clipboard-apis/#clipboard-item-interface
|
|
|
|
|
[SecureContext, Exposed=Window]
|
|
|
|
|
interface ClipboardItem {
|
|
|
|
|
constructor(record<DOMString, ClipboardItemData> items,
|
|
|
|
|
optional ClipboardItemOptions options = {});
|
|
|
|
|
|
|
|
|
|
readonly attribute PresentationStyle presentationStyle;
|
2025-04-25 10:07:43 -04:00
|
|
|
readonly attribute FrozenArray<DOMString> types;
|
2024-11-30 20:23:38 -08:00
|
|
|
|
|
|
|
|
Promise<Blob> getType(DOMString type);
|
|
|
|
|
|
|
|
|
|
static boolean supports(DOMString type);
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
enum PresentationStyle { "unspecified", "inline", "attachment" };
|
|
|
|
|
|
|
|
|
|
dictionary ClipboardItemOptions {
|
|
|
|
|
PresentationStyle presentationStyle = "unspecified";
|
|
|
|
|
};
|