aboutsummaryrefslogtreecommitdiff
path: root/files/es/web/css/vertical-align/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'files/es/web/css/vertical-align/index.html')
-rw-r--r--files/es/web/css/vertical-align/index.html161
1 files changed, 161 insertions, 0 deletions
diff --git a/files/es/web/css/vertical-align/index.html b/files/es/web/css/vertical-align/index.html
new file mode 100644
index 0000000000..f8f35405c7
--- /dev/null
+++ b/files/es/web/css/vertical-align/index.html
@@ -0,0 +1,161 @@
+---
+title: vertical-align
+slug: Web/CSS/vertical-align
+translation_of: Web/CSS/vertical-align
+---
+<div>{{ CSSRef() }}</div>
+
+<h2 id="Summary" name="Summary">Resumen</h2>
+
+<p>La propiedad <code>vertical-align</code> de <a href="/en-US/docs/CSS" title="CSS">CSS</a> especifica el alineado vertical de un elemento en línea o una celda de una tabla.</p>
+
+<p>{{cssinfo}}</p>
+
+<h2 id="Syntax" name="Syntax">Sintaxis</h2>
+
+<pre class="syntaxbox"><code>vertical-align:</code> <code>baseline</code> | <code>sub</code> | <code>super</code> | <code>text-top</code> | <code>text-bottom</code> | <code>middle</code> | <code>top</code> | <code>bottom</code> | &lt;percentage&gt; | <a href="/en-US/docs/CSS/length" title="CSS/length">&lt;length&gt;</a></pre>
+
+<h3 id="Valores_(para_elementos_en_línea)">Valores (para elementos en línea)</h3>
+
+<p>La mayoría de los valores de alinean verticalmente el elemento de forma relativa al elemento padre:</p>
+
+<dl>
+ <dt><code>baseline</code></dt>
+ <dd>Alinea la línea base del elemento con la línea base del padre. La línea base de algunos <a href="/es/docs/CSS/Replaced_element" title="/es/docs/CSS/Replaced_element">elementos reemplazados</a>, como  {{HTMLElement("textarea")}} no está especificado en la especificación HTML, que significa que su comportamiento puede cambiar en un navegador u otro.</dd>
+ <dt><code>sub</code></dt>
+ <dd>Alinea la línea base del elemento con la línea subscript del elemento padre.</dd>
+ <dt><code>super</code></dt>
+ <dd> Alinea la línea base del elemento con la línea superscript del elemento padre.</dd>
+ <dt><code>text-top</code></dt>
+ <dd>Aligns the top of the element with the top of the parent element's font.</dd>
+ <dt><code>text-bottom</code></dt>
+ <dd>Aligns the bottom of the element with the bottom of the parent element's font.</dd>
+ <dt><code>middle</code></dt>
+ <dd>Aligns the middle of the element with the middle of lowercase letters in the parent.</dd>
+ <dt><code><a href="/en-US/docs/CSS/length" title="CSS/length">&lt;length&gt;</a></code></dt>
+ <dd>Aligns the baseline of the element at the given length above the baseline of its parent.</dd>
+ <dt><code>&lt;percentage&gt;</code></dt>
+ <dd>Like &lt;length&gt; values, with the percentage being a percent of the {{ Cssxref("line-height") }} property.
+ <p>For elements that do not have a baseline, the bottom margin edge is used instead.</p>
+
+ <p>However, two values vertically align the element relative to the entire line rather than relative to its parent:</p>
+ </dd>
+ <dt><code>top</code></dt>
+ <dd>Align the top of the element and its descendants with the top of the entire line.</dd>
+ <dt><code>bottom</code></dt>
+ <dd>Align the bottom of the element and its descendants with the bottom of the entire line.</dd>
+</dl>
+
+<p>Negative values are allowed.</p>
+
+<h3 id="Valores_(para_celdas_de_tablas)">Valores (para celdas de tablas)</h3>
+
+<dl>
+ <dt><code>baseline</code> (and <code>sub</code>, <code>super</code>, <code>text-top</code>, <code>text-bottom</code>, <code>&lt;length&gt;</code>, and <code>&lt;percentage&gt;</code>)</dt>
+ <dd>Align the baseline of the cell with the baseline of all other cells in the row that are baseline-aligned.</dd>
+ <dt><code>top</code></dt>
+ <dd>Align the top padding edge of the cell with the top of the row.</dd>
+ <dt><code>middle</code></dt>
+ <dd>Center the padding box of the cell within the row.</dd>
+ <dt><code>bottom</code></dt>
+ <dd>Align the bottom padding edge of the cell with the bottom of the row.</dd>
+</dl>
+
+<p>Negative values are allowed.</p>
+
+<h2 id="Examples" name="Examples">Ejemplos</h2>
+
+<pre class="brush: css">img {
+ vertical-align: bottom;
+}
+</pre>
+
+<h2 id="Especificaciones">Especificaciones</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 Transitions', '#animatable-css', 'vertical-align') }}</td>
+ <td>{{ Spec2('CSS3 Transitions') }}</td>
+ <td>Defines <code>visibility</code> as animatable.</td>
+ </tr>
+ <tr>
+ <td>{{ SpecName('CSS2.1', 'visudet.html#propdef-vertical-align', 'vertical-align') }}</td>
+ <td>{{ Spec2('CSS2.1') }}</td>
+ <td>Add the {{cssxref("&lt;length&gt;")}} value and allows it to be applied to element with a {{ cssxref("display") }} type of <code>table-cell</code>.</td>
+ </tr>
+ <tr>
+ <td>{{ SpecName('CSS1', '#vertical-align', 'vertical-align') }}</td>
+ <td>{{ Spec2('CSS1') }}</td>
+ <td>Initial definition.</td>
+ </tr>
+ </tbody>
+</table>
+
+<h2 id="Browser_compatibility" name="Browser_compatibility">Compatibilidad de los navegadores</h2>
+
+<p>{{ CompatibilityTable() }}</p>
+
+<div id="compat-desktop">
+<table class="compat-table">
+ <tbody>
+ <tr>
+ <th>Feature</th>
+ <th>Chrome</th>
+ <th>Firefox (Gecko)</th>
+ <th>Internet Explorer</th>
+ <th>Opera</th>
+ <th>Safari</th>
+ </tr>
+ <tr>
+ <td>Basic support</td>
+ <td>1.0</td>
+ <td>{{ CompatGeckoDesktop("1.0") }}</td>
+ <td>4.0</td>
+ <td>4.0</td>
+ <td>1.0 (85)</td>
+ </tr>
+ </tbody>
+</table>
+</div>
+
+<div id="compat-mobile">
+<table class="compat-table">
+ <tbody>
+ <tr>
+ <th>Feature</th>
+ <th>Android</th>
+ <th>Chrome for Android</th>
+ <th>Firefox Mobile (Gecko)</th>
+ <th>IE Mobile</th>
+ <th>Opera Mobile</th>
+ <th>Safari Mobile</th>
+ </tr>
+ <tr>
+ <td>Basic support</td>
+ <td>1.0</td>
+ <td>1.0</td>
+ <td>{{ CompatGeckoMobile("1.0") }}</td>
+ <td>{{ CompatVersionUnknown() }}</td>
+ <td>{{ CompatVersionUnknown() }}</td>
+ <td>1.0</td>
+ </tr>
+ </tbody>
+</table>
+</div>
+
+<h2 id="See_also" name="See_also">Ver también</h2>
+
+<ul>
+ <li>{{ Cssxref("line-height") }}, {{ Cssxref("text-align") }}, {{ Cssxref("margin") }}</li>
+ <li>
+ <p><a href="http://phrogz.net/css/vertical-align/index.html" title="http://phrogz.net/css/vertical-align/index.html">Understanding <code>vertical-align</code>, or "How (Not) To Vertically Center Content"</a></p>
+ </li>
+</ul>