- From: mbrodesser <notifications@github.com>
- Date: Wed, 08 Dec 2021 05:23:26 -0800
- To: w3c/clipboard-apis <clipboard-apis@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <w3c/clipboard-apis/pull/158/review/826429419@github.com>
@mbrodesser commented on this pull request.
> + Creates a new {{ClipboardItem}} object. <var>items</var> are used to fill its MIME types and [=Promise=]s to [=Blob=]s or {{DOMString}}s corresponding to the MIME types, <var>options</var> can be used to fill its {{ClipboardItemOptions}},
+ as per the example below.
- readonly attribute PresentationStyle presentationStyle;
- readonly attribute long long lastModified;
- readonly attribute boolean delayed;
+ <pre class="example javascript" highlight=js>
+ const format1 = 'text/plain';
+ const promise_text_blob = Promise.resolve(new Blob(['hello'], {type: format1}));
+ const clipboardItemInput = new ClipboardItem(
+ {[format1]: promise_text_blob},
+ {presentationStyle: "unspecified"});
+ </pre>
> It might be a style sheet issue. I'm not sure if all style sheets include the domintro styles.
That might indeed be the problem. The `domintro` style used in the fetch standard is defined in https://resources.whatwg.org/standard.css. The Clipboard API spec includes https://www.w3.org/StyleSheets/TR/2021/W3C-ED which imports https://www.w3.org/StyleSheets/TR/2021/W3C-ED/base.css. I didn't know that. I assumed both specs would use the same style sheets, nowadays.
Could it just be a remnant of ancient times? Is it correct that nowadays this w3c spec should use the exact same styles like the whatwg specs?
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/clipboard-apis/pull/158#discussion_r764860157
Received on Wednesday, 8 December 2021 13:23:38 UTC