You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The <cite>HTML Media Capture</cite> specification extends the
1044
-
<adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#htmlinputelement"><code>HTMLInputElement</code></a> interface with a <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute. The
1044
+
<adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#htmlinputelement-htmlinputelement"><code>HTMLInputElement</code></a> interface with a <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute. The
1045
1045
<ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute allows authors to declaratively request use of a <ahref="#dfn-media-capture-mechanism" class="internalDFN" data-link-type="dfn">media capture mechanism</a>,
1046
1046
such as a camera or microphone, from within a file upload control, for capturing media on the spot.
The <dfndata-dfn-type="dfn" id="dfn-input"><ahref="https://html.spec.whatwg.org/multipage/#the-input-element"><code>input</code></a></dfn> element, its <dfndata-dfn-type="dfn" id="dfn-type"><ahref="https://html.spec.whatwg.org/multipage/#attr-input-type"><code>type</code></a></dfn> attribute,
value default</a></dfn>, and <dfndata-dfn-type="dfn" id="dfn-reflect"><ahref="https://html.spec.whatwg.org/multipage/#reflect">reflect</a></dfn> are defined in [<cite><aclass="bibref" href="#bib-HTML51">HTML51</a></cite>].
1076
+
The <dfndata-dfn-type="dfn" id="dfn-input"><ahref="https://www.w3.org/TR/html51/sec-forms.html#the-input-element"><code>input</code></a></dfn> element, its <dfndata-dfn-type="dfn" id="dfn-type"><ahref="https://www.w3.org/TR/html51/sec-forms.html#element-attrdef-input-type"><code>type</code></a></dfn> attribute,
value default</a></dfn>, and <dfndata-dfn-type="dfn" id="dfn-reflect"><ahref="https://www.w3.org/TR/html51/infrastructure.html#reflection">reflect</a></dfn> are defined in [<cite><aclass="bibref" href="#bib-HTML51">HTML51</a></cite>].
1083
1083
</p>
1084
+
<p>The <dfncite="!custom-elements#cereactions" data-dfn-type="dfn" id="dfn-x[cereactions]"><code>[CEReactions]</code></dfn> WebIDL extended attribute is defined in [<cite><aclass="bibref" href="#bib-custom-elements">custom-elements</a></cite>].</p>
1084
1085
<p>
1085
1086
The <dfndata-dfn-type="dfn" id="dfn-videofacingmodeenum"><ahref="https://www.w3.org/TR/mediacapture-streams/#def-constraint-facingMode"><code>VideoFacingModeEnum</code></a></dfn> enumeration is defined in [<cite><aclass="bibref" href="#bib-MEDIACAPTURE-STREAMS">MEDIACAPTURE-STREAMS</a></cite>].
In this specification, the term <dfndata-dfn-type="dfn" id="dfn-capture-control-type">capture control type</dfn> refers to a specialized type of a file picker control that is optimized, for the user, for directly capturing media of a MIME
1092
1093
type specified by the
1093
-
<adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#attr-input-accept"><code>accept</code></a> attribute, using a <ahref="#dfn-media-capture-mechanism" class="internalDFN" data-link-type="dfn">media capture mechanism</a> in its
1094
+
<adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#element-attrdef-input-accept"><code>accept</code></a> attribute, using a <ahref="#dfn-media-capture-mechanism" class="internalDFN" data-link-type="dfn">media capture mechanism</a> in its
This specification builds upon the security and privacy protections provided by the <code><input type="file"></code> [<cite><aclass="bibref" href="#bib-HTML51">HTML51</a></cite>] and the [<cite><aclass="bibref" href="#bib-FILE-API">FILE-API</a></cite>]
1121
-
specifications; in particular, it is expected that any offer to start capturing content from the user’s device would require a specific user interaction on an HTML element that is entirely controlled by the user agent.
1121
+
This specification builds upon the security and privacy protections provided by the <code><input type="file"></code> [<cite><aclass="bibref" href="#bib-HTML51">HTML51</a></cite>] and the [
1122
+
<cite><aclass="bibref" href="#bib-FILE-API">FILE-API</a></cite>] specifications; in particular, it is expected that any offer to start capturing content from the user’s device would require a specific user interaction on an HTML element that
1123
+
is entirely controlled by the user agent.
1122
1124
</p>
1123
1125
<p>
1124
1126
Implementors should take care to prevent additional age of privacy-sensitive data from captured media. For instance, embedding the user’s location in the metadata of captured media (e.g. EXIF) might transmit more private data than the user is expecting.
<h2id="x5.-the-capture-attribute"><spanclass="secno">5. </span> The <dfndata-dfn-for="htmlinputelement" data-dfn-type="dfn" id="dom-htmlinputelement-capture" data-idl="" data-title="capture"><code>capture</code></dfn> attribute
1130
1132
</h2>
1131
1133
<p>
1132
-
When an <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#the-input-element"><code>input</code></a> element's <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#attr-input-type"><code>type</code></a> attribute is in the <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#file-upload-state-(type=file)">File
1133
-
Upload</a> state, and its <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#attr-input-accept"><code>accept</code></a> attribute is specified, the rules in this section apply.
1134
+
When an <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#the-input-element"><code>input</code></a> element's <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#element-attrdef-input-type"><code>type</code></a> attribute is in the <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#element-statedef-input-file-upload">File
1135
+
Upload</a> state, and its <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#element-attrdef-input-accept"><code>accept</code></a> attribute is specified, the rules in this section apply.
The <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute is an <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#enumerated-attribute">enumerated attribute</a> whose state specifies the <ahref="#dfn-preferred-facing-mode" class="internalDFN" data-link-type="dfn">preferred facing mode</a> for the <ahref="#dfn-media-capture-mechanism" class="internalDFN" data-link-type="dfn">media
1145
+
The <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute is an <adata-link-type="dfn" href="https://www.w3.org/TR/html51/infrastructure.html#enumerated-attributes">enumerated attribute</a> whose state specifies the <ahref="#dfn-preferred-facing-mode" class="internalDFN" data-link-type="dfn">preferred facing mode</a> for the <ahref="#dfn-media-capture-mechanism" class="internalDFN" data-link-type="dfn">media
The <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#missing-value-default">missing value default</a> is the
1158
-
<var>implementation-specific</var> state. The <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#invalid-value-default">invalid value
1159
+
The <adata-link-type="dfn" href="https://www.w3.org/TR/html51/infrastructure.html#missing-value-default">missing value default</a> is the
1160
+
<var>implementation-specific</var> state. The <adata-link-type="dfn" href="https://www.w3.org/TR/html51/infrastructure.html#invalid-value-default">invalid value
1159
1161
default</a> is also the <var>implementation-specific</var> state.
The <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> IDL attribute <emclass="rfc2119" title="MUST">MUST</em><adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#reflect">reflect</a> the respective content attribute of the same name.
1171
+
The <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> IDL attribute <emclass="rfc2119" title="MUST">MUST</em><adata-link-type="dfn" href="https://www.w3.org/TR/html51/infrastructure.html#reflection">reflect</a> the respective content attribute of the same name.
1170
1172
</p>
1171
1173
<p>
1172
1174
When the <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute is specified, the <ahref="#dfn-user-agent" class="internalDFN" data-link-type="dfn">user agent</a>
If the <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#attr-input-accept"><code>accept</code></a> attribute's value is set to a MIME type that has no associated <ahref="#dfn-capture-control-type" class="internalDFN"
1190
+
If the <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#element-attrdef-input-accept"><code>accept</code></a> attribute's value is set to a MIME type that has no associated <ahref="#dfn-capture-control-type" class="internalDFN"
1189
1191
data-link-type="dfn">capture control type</a>, the <ahref="#dfn-user-agent" class="internalDFN" data-link-type="dfn">user agent</a><emclass="rfc2119" title="MUST">MUST</em> act as if there was no <ahref="#dom-htmlinputelement-capture"
When an <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#the-input-element"><code>input</code></a> element's <adata-link-type="dfn" href="https://html.spec.whatwg.org/multipage/#attr-input-accept"><code>accept</code></a> attribute is set to
1304
+
When an <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#the-input-element"><code>input</code></a> element's <adata-link-type="dfn" href="https://www.w3.org/TR/html51/sec-forms.html#element-attrdef-input-accept"><code>accept</code></a> attribute is set to
1303
1305
<code>image/*</code> and the <ahref="#dom-htmlinputelement-capture" class="internalDFN" data-link-type="dfn"><code>capture</code></a> attribute is specified as in the <ahref="#example-1">Example 1</a> or <ahref="#example-4">Example 4</a>,
1304
1306
the file picker may render as presented on the right side. When the attribute is not specified, the file picker may render as represented on the left side.
<dd><ahref="https://www.w3.org/TR/FileAPI/"><cite>File API</cite></a>. Arun Ranganathan; Jonas Sicking. W3C. 21 April 2015. W3C Working Draft. URL: <ahref="https://www.w3.org/TR/FileAPI/">https://www.w3.org/TR/FileAPI/</a>
1319
-
</dd><dtid="bib-HTML">[HTML]</dt>
1320
-
<dd><ahref="https://html.spec.whatwg.org/multipage/"><cite>HTML Standard</cite></a>. Anne van Kesteren; Domenic Denicola; Ian Hickson; Philip Jägenstedt; Simon Pieters. WHATWG. Living Standard. URL: <ahref="https://html.spec.whatwg.org/multipage/">https://html.spec.whatwg.org/multipage/</a>
1321
1321
</dd><dtid="bib-HTML51">[HTML51]</dt>
1322
1322
<dd><ahref="https://www.w3.org/TR/html51/"><cite>HTML 5.1 2nd Edition</cite></a>. Steve Faulkner; Arron Eicholz; Travis Leithead; Alex Danilo. W3C. 3 August 2017. W3C Proposed Recommendation. URL: <ahref="https://www.w3.org/TR/html51/">https://www.w3.org/TR/html51/</a>
<dd><ahref="https://tools.ietf.org/html/rfc2119"><cite>Key words for use in RFCs to Indicate Requirement Levels</cite></a>. S. Bradner. IETF. March 1997. Best Current Practice. URL: <ahref="https://tools.ietf.org/html/rfc2119">https://tools.ietf.org/html/rfc2119</a>
<dd><ahref="https://html.spec.whatwg.org/multipage/"><cite>HTML Standard</cite></a>. Anne van Kesteren; Domenic Denicola; Ian Hickson; Philip Jägenstedt; Simon Pieters. WHATWG. Living Standard. URL: <ahref="https://html.spec.whatwg.org/multipage/">https://html.spec.whatwg.org/multipage/</a>
1340
+
</dd><dtid="bib-WEBIDL">[WEBIDL]</dt>
1337
1341
<dd><ahref="https://heycam..io/webidl/"><cite>Web IDL</cite></a>. Cameron McCormack; Boris Zbarsky; Tobie Langel. W3C. 15 December 2016. W3C Editor's Draft. URL: <ahref="https://heycam..io/webidl/">https://heycam..io/webidl/</a>
0 commit comments