blob: 7284af26aab6f840a869c9b4b540a272bddb8724 (
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
|
---
title: background_color
slug: Web/Manifest/background_color
translation_of: Web/Manifest/background_color
---
<div>{{QuickLinksWithSubpages("/en-US/docs/Web/Manifest")}}</div>
<table class="properties">
<tbody>
<tr>
<th scope="row">
<div class="blockIndicator warning">
<p>wobuhuisuanmin</p>
</div>
<h5 id="Type">Type</h5>
</th>
<td><code>String</code></td>
</tr>
<tr>
<th scope="row">Mandatory</th>
<td>No</td>
</tr>
</tbody>
</table>
<p>被装载其样式表之前的 <code>background_color</code> 构件限定了用于应用页的占位符的背景颜色来显示。此值用于由用户代理来绘制一个快捷方式的背景颜色,当样式表加载之前清单是可用的。</p>
<p>(原文:The background_color member defines a placeholder background color for the application page to display before its stylesheet is loaded. This value is used by the user agent to draw the background color of a shortcut when the manifest is available before the stylesheet has loaded.)</p>
<p>因此,<code>background_color</code> 应于 {{cssxref("background-color")}}<font>网站样式表</font><font>中的</font><font>CSS属性</font><font>匹配</font><font>,以在启动Web应用程序和加载网站内容之间进行平滑过渡。</font></p>
<p>(原文:Therefore <code>background_color</code> should match the {{cssxref("background-color")}} CSS property in the site’s stylesheet for a smooth transition between launching the web application and loading the site's content.)</p>
<div class="blockIndicator note">
<p><strong><font><font>注意</font></font></strong><font><font>:该</font></font> <code>background_color</code> 构件仅用于在从网络或存储介质加载主样式表时改善用户体验。{{cssxref("background-color")}} <font>当渐进式Web应用程序样式表可用时</font><font>,用户代理不会将其用作</font><font>CSS属性。</font></p>
</div>
<h2 id="实例">实例</h2>
<pre class="brush: json notranslate">"background_color": "red"</pre>
<h2 id="规范">规范</h2>
<table class="standard-table">
<thead>
<tr>
<th scope="col">规范</th>
<th scope="col">状态</th>
<th scope="col">注释</th>
<th scope="col">反馈</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<p>{{SpecName('Manifest', '#background_color-member', 'background_color')}}</p>
</td>
<td>
<p>{{Spec2('Manifest')}}</p>
</td>
<td>
<p>初始定义</p>
</td>
<td>
<p><a href="https://github.com/w3c/manifest/issues/">Web App Manifest Working Group drafts</a></p>
</td>
</tr>
</tbody>
</table>
<h2 id="浏览器兼容性">浏览器兼容性</h2>
<p>{{Compat("html.manifest.background_color")}}</p>
|