From 074785cea106179cb3305637055ab0a009ca74f2 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:42:52 -0500 Subject: initial commit --- files/ru/web/css/isolation/index.html | 114 ++++++++++++++++++++++++++++++++++ 1 file changed, 114 insertions(+) create mode 100644 files/ru/web/css/isolation/index.html (limited to 'files/ru/web/css/isolation') diff --git a/files/ru/web/css/isolation/index.html b/files/ru/web/css/isolation/index.html new file mode 100644 index 0000000000..94f536220c --- /dev/null +++ b/files/ru/web/css/isolation/index.html @@ -0,0 +1,114 @@ +--- +title: isolation +slug: Web/CSS/isolation +tags: + - Контекст наложения + - Очередность + - Порядок отрисовки +translation_of: Web/CSS/isolation +--- +
{{CSSRef}}
+ +

CSS-свойство isolation определяет должен ли элемент создавать новый контекст наложения {{glossary("stacking context")}}.

+ +
{{EmbedInteractiveExample("pages/css/isolation.html")}}
+ + + +

Это свойство особенно полезно при использовании совместно с {{cssxref("background-blend-mode")}}.

+ +

Синтаксис

+ +
/* Значения ключевого слова */
+isolation: auto;
+isolation: isolate;
+
+/* Глобальные значения */
+isolation: inherit;
+isolation: initial;
+isolation: unset;
+
+ +

Свойство isolation указывается в качестве значения одного из нижеследующих ключевых слов.

+ +

Значения

+ +
+
auto
+
Новый контекст наложения создается только в том случае, если это требуется для одного из свойств, применяемых к элементу.
+
isolate
+
Новый контекст наложения должен быть создан.
+
+ +

Формальный синтаксис

+ +
{{csssyntax}}
+ +

Примеры

+ +
<div id="b" class="a">
+  <div id="d">
+    <div class="a c">auto</div>
+  </div>
+  <div id="e">
+    <div class="a c">isolate</div>
+  </div>
+</div>
+
+ +
.a {
+  background-color: rgb(0,255,0);
+}
+#b {
+  width: 200px;
+  height: 210px;
+}
+.c {
+  width: 100px;
+  height: 100px;
+  border: 1px solid black;
+  padding: 2px;
+  mix-blend-mode: difference;
+}
+#d {
+  isolation: auto;
+}
+#e {
+  isolation: isolate;
+}
+ +

{{ EmbedLiveSample('Examples', 230, 230) }}

+ +

Спецификации

+ + + + + + + + + + + + + + + + +
СпецификацияСтатусКомментарий
{{ SpecName('Compositing', '#isolation', 'Isolation') }}{{ Spec2('Compositing') }}Первое определение
+ +

{{cssinfo}}

+ +

Поддержка браузерами

+ + + +

{{Compat("css.properties.isolation")}}

+ +

Смотрите также

+ + -- cgit v1.2.3-54-g00ecf