aboutsummaryrefslogtreecommitdiff
path: root/files/fa/web/css/_doublecolon_cue/index.html
blob: f1e723f7e7c31ea376053b22a7d763dcf0898ecf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
---
title: '::cue (:cue)'
slug: 'Web/CSS/::cue'
translation_of: 'Web/CSS/::cue'
---
<p> </p>

<div>{{CSSRef}}</div>

<p> </p>

<p dir="rtl"><a href="/en-US/docs/Web/CSS/Pseudo-elements">شبه عنصر</a> {{ Cssxref("cue::") }} یک عنصر انتخاب شده با نشانه‌های WebVTT را تطابق می‌دهد. این <a href="/en-US/docs/Web/CSS/Pseudo-elements">شبه عنصر</a> می‌تواند برای<a href="/docs/Web/API/WebVTT_API#Styling_WebTT_cues"> آرایش زیرنویس و دیگر موارد</a> محتوای تصویری با VTT tracks مورد استفاده قرار گیرد.</p>

<pre class="brush: css no-line-numbers">::cue {
  color: yellow;
  font-weight: bold;
}</pre>

<h2 id="Allowable_properties">Allowable properties</h2>

<p>Only a small subset of CSS properties can be used in a rule with <code>::cue</code> in its selector:</p>

<ul>
 <li>{{cssxref("color")}}</li>
 <li>{{cssxref("opacity")}}</li>
 <li>{{cssxref("visibility")}}</li>
 <li>{{cssxref("text-decoration")}} and its longhand properties</li>
 <li>{{cssxref("text-shadow")}}</li>
 <li>{{cssxref("background")}} and its longhand properties</li>
 <li>{{cssxref("outline")}} and its longhand properties</li>
 <li>{{Cssxref("font")}} and its longhand properties, including {{cssxref("line-height")}}</li>
 <li>{{cssxref("white-space")}}</li>
 <li>{{cssxref("text-combine-upright")}}</li>
 <li>{{cssxref("ruby-position")}}</li>
</ul>

<p>The properties are applied to the entire set of cues as if they were a single unit. The only exception is that <code>background</code> and its shorthand properties apply to each cue individually, to avoid creating boxes and obscuring unexpectedly large areas of the media.</p>

<h2 id="Syntax">Syntax</h2>

<pre class="syntaxbox">{{csssyntax}}</pre>

<h2 id="Example">Example</h2>

<p>The following CSS sets the cue style so that the text is white and the background is a translucent black box.</p>

<pre class="brush: css">::cue {
  color: #fff;
  background-color: rgba(0, 0, 0, 0.6);
}</pre>

<h2 id="Specifications">Specifications</h2>

<table class="standard-table">
 <tbody>
  <tr>
   <th>Specification</th>
   <th>Status</th>
   <th>Comment</th>
  </tr>
  <tr>
   <td>{{SpecName("WebVTT", "#the-cue-pseudo-element", "::cue")}}</td>
   <td>{{Spec2("WebVTT")}}</td>
   <td>Initial definition.</td>
  </tr>
 </tbody>
</table>

<h2 id="Browser_compatibility">Browser compatibility</h2>

<p class="hidden">The compatibility table in this page is generated from structured data. If you'd like to contribute to the data, please check out <a href="https://github.com/mdn/browser-compat-data">https://github.com/mdn/browser-compat-data</a> and send us a pull request.</p>

<p>{{Compat("css.selectors.cue")}}</p>

<h2 id="See_also">See also</h2>

<ul>
 <li><a href="/en-US/docs/Web/API/WebVTT_API">Web Video Tracks Format (WebVTT)</a></li>
</ul>