Примеры
Read a responsive two-column card layout
Ввод
.cards{display:grid;grid-template-columns:repeat(2,1fr);gap:1rem}@media(max-width:40rem){.cards{grid-template-columns:1fr}}Expected answer
.cards{
display:grid;
grid-template-columns:repeat(2,1fr);
gap:1rem
}
@media(max-width:40rem){
.cards{
grid-template-columns:1fr
}
}
- Отступ строки
Inspect focus styles without losing the attribute selector
Ввод
button[data-state="open"]:focus-visible{outline:2px solid #005fcc;outline-offset:3px}Expected answer
button[data-state="open"]:focus-visible{
outline:2px solid #005fcc;
outline-offset:3px
}
- Отступ строки
Trace a custom property through a dark-mode override
Ввод
:root{--surface:#fff;--ink:#111}.dark{--surface:#111;--ink:#fff}.panel{background:var(--surface);color:var(--ink)}Expected answer
:root{
--surface:#fff;
--ink:#111
}
.dark{
--surface:#111;
--ink:#fff
}
.panel{
background:var(--surface);
color:var(--ink)
}
- Отступ строки
Separate the steps of an opacity animation
Ввод
@keyframes fade{0%{opacity:0}50%{opacity:.5}100%{opacity:1}}Expected answer
@keyframes fade{
0%{
opacity:0
}
50%{
opacity:.5
}
100%{
opacity:1
}
}
- Отступ строки
Read a print rule that hides navigation
Ввод
/* Paper copy */@media print{nav,.toolbar{display:none}a{color:#000;text-decoration:underline}}Expected answer
/* Paper copy */
@media print{
nav,.toolbar{
display:none
}
a{
color:#000;
text-decoration:underline
}
}
- Отступ строки
Параметры
| Параметр | Значение по умолчанию | Ввод и варианты |
|---|---|---|
| Отступ строки | "\\t" | Поддерживаются escape-последовательности \n, \r и \t |