Co-thaobhadh dìreach
Atharraich gu furasta co-thaobhadh dìreach nan eileamaidean in-loidhne, bloc in-loidhne, clàr in-loidhne, agus cealla bùird.
Atharraich co-thaobhadh nan eileamaidean leis na vertical-alignment
goireasan. Thoir an aire nach toir co-thaobhadh dìreach buaidh ach air eileamaidean in-loidhne, bloc in-loidhne, clàr in-loidhne agus cealla-clàir.
Tagh bho .align-baseline
, .align-top
, .align-middle
, , .align-bottom
, .align-text-bottom
, agus .align-text-top
mar a tha feum air.
Gus susbaint neo-loidhne a mheadhanachadh gu dìreach (mar <div>
s agus barrachd), cleachd na goireasan bogsa sùbailte againn .
Le eileamaidean in-loidhne:
<span class="align-baseline">baseline</span>
<span class="align-top">top</span>
<span class="align-middle">middle</span>
<span class="align-bottom">bottom</span>
<span class="align-text-top">text-top</span>
<span class="align-text-bottom">text-bottom</span>
Le ceallan bùird:
bun-loidhne | mhullaich | meadhan | bun | teacs-uachdair | teacsa-bun |
<table style="height: 100px;">
<tbody>
<tr>
<td class="align-baseline">baseline</td>
<td class="align-top">top</td>
<td class="align-middle">middle</td>
<td class="align-bottom">bottom</td>
<td class="align-text-top">text-top</td>
<td class="align-text-bottom">text-bottom</td>
</tr>
</tbody>
</table>
Sass
Utilities API
Tha goireasan co-thaobhadh dìreach air an ainmeachadh anns na goireasan API againn ann an scss/_utilities.scss
. Ionnsaich mar a chleachdas tu an API Utilities.
"align": (
property: vertical-align,
class: align,
values: baseline top middle bottom text-bottom text-top
),