Шаблон:Border radius/doc: различия между версиями
Материал из Dwarf Fortress Wiki
Перейти к навигацииПерейти к поиску
GeloMor (обсуждение | вклад) (Новая страница: «This is intended to be used in a CSS context as a shorter way of expressing border radii. It uses several vendor-specific prefixes, as well as the standard CSS3 <…») |
GeloMor (обсуждение | вклад) Нет описания правки |
||
Строка 15: | Строка 15: | ||
A semicolon after the template (<code><nowiki>{{border radius|4px}};</nowiki></code>) '''is not necessary'''. This template ends with a semicolon. Extra semicolons could cause problems in a few browsers. | A semicolon after the template (<code><nowiki>{{border radius|4px}};</nowiki></code>) '''is not necessary'''. This template ends with a semicolon. Extra semicolons could cause problems in a few browsers. | ||
This doesn't yet support specific corners, since CSS3 and the Webkit-specific version use <code>top-right-border-radius</code> and <code>-webkit-top-right-border-radius</code> (respectively), while Mozilla uses <code>-moz-border-radius-topright</code>. Feel free to implement this (it shouldn't be too hard), but '''''please''''' test it on your user page | This doesn't yet support specific corners, since CSS3 and the Webkit-specific version use <code>top-right-border-radius</code> and <code>-webkit-top-right-border-radius</code> (respectively), while Mozilla uses <code>-moz-border-radius-topright</code>. Feel free to implement this (it shouldn't be too hard), but '''''please''''' test it on your user page '''''before''''' changing this template. | ||
<includeonly>[[Категория:Шаблоны форматирования]]</includeonly> | <includeonly>[[Категория:Шаблоны форматирования]]</includeonly> | ||
<noinclude>[[Category:Документация шаблонов]][[en:Template:Border radius/doc]]</noinclude> | <noinclude>[[Category:Документация шаблонов]][[en:Template:Border radius/doc]]</noinclude> |
Текущая версия от 22:21, 6 марта 2022
This is intended to be used in a CSS context as a shorter way of expressing border radii. It uses several vendor-specific prefixes, as well as the standard CSS3 border-radius
.
Examples
<div style="border: 1px solid black; {{border radius|5px}}">Test</div>
Produces:
Test
Source:
<div style="border: 1px solid black; border-radius: 5px; -webkit-border-radius: 5px; -moz-border-radius: 5px; -o-border-radius: 5px; -ms-border-radius: 5px;">Test</div>
Technical
A semicolon after the template ({{border radius|4px}};
) is not necessary. This template ends with a semicolon. Extra semicolons could cause problems in a few browsers.
This doesn't yet support specific corners, since CSS3 and the Webkit-specific version use top-right-border-radius
and -webkit-top-right-border-radius
(respectively), while Mozilla uses -moz-border-radius-topright
. Feel free to implement this (it shouldn't be too hard), but please test it on your user page before changing this template.