blob: b67283c99a26f1d6636993e5ae3cd0a0893d8e5b (
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
|
---
title: transform-box
slug: Web/CSS/transform-box
translation_of: Web/CSS/transform-box
---
<div>{{CSSRef}}{{SeeCompatTable}}</div>
<h2 id="概述">概述</h2>
<p><strong><code>transform-box</code></strong>属性定义了与 {{cssxref("transform")}}、{{cssxref("transform-origin")}} 这两个属性有关联的布局框。</p>
<p>{{cssinfo}}</p>
<h2 id="语法">语法</h2>
<pre class="brush: css">/* Keyword values */
transform-box: border-box;
transform-box: fill-box;
transform-box: view-box;
/* Global values */
transform-box: inherit;
transform-box: initial;
transform-box: unset;
</pre>
<p><code>transform-box</code>属性被指定为以下所列出的关键字值之一。</p>
<h3 id="值">值</h3>
<dl>
<dt><code>border-box</code></dt>
<dd>border box是用作引用框,一个表格(table)的border-box是table包装盒的边框,而不是表的边框。</dd>
<dt><code>fill-box</code></dt>
<dd>Uses the object bounding box as reference box.</dd>
<dt><code>view-box</code></dt>
<dd>Uses the nearest {{Glossary("SVG")}} viewport as reference box. If a {{SVGAttr("viewBox")}} attribute is specified for the SVG viewport creating element, the reference box is positioned at the origin of the coordinate system established by the <code>viewBox</code> attribute and the dimension of the reference box is set to the width and height values of the <code>viewBox</code> attribute.</dd>
</dl>
<h3 id="Formal_syntax">Formal syntax</h3>
{{csssyntax}}
<h2 id="Specifications">Specifications</h2>
<table class="standard-table">
<thead>
<tr>
<th scope="col">Specification</th>
<th scope="col">Status</th>
<th scope="col">Comment</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{SpecName('CSS3 Transforms', '#transform-box', 'transform-box')}}</td>
<td>{{Spec2('CSS3 Transforms')}}</td>
<td>Initial definition</td>
</tr>
</tbody>
</table>
<h2 id="Browser_compatibility">Browser compatibility</h2>
{{Compat("css.properties.transform-box")}}
<h2 id="See_also">See also</h2>
<ul>
<li><a href="/en-US/docs/CSS/Using_CSS_transforms" title="/en-US/docs/CSS/Using_CSS_transforms">Using CSS Transforms</a></li>
</ul>
|