CSS border-image-source Свойство
Пример
Укажите изображение в качестве границы вокруг элемента:
#borderimg
{
border-image-source: url(border.png);
}
Определение и использование
Свойство border-image-source
указывает путь к изображению, используемому в качестве границы (вместо обычной границы вокруг элемента).
Совет: Если значение равно "None" или если изображение не может быть отображено, будут использоваться стили границ.
Совет: Также посмотрите на свойство border-Image (Сокращенное свойство для установки всех свойств Border-Image-*).
Значение по умолчанию: | none |
---|---|
Inherited: | no |
Animatable: | no. Читайте о animatable |
Version: | CSS3 |
Синтаксис JavaScript: | object.style.borderImageSource="url(border.png)" |
Поддержка браузера
Номера в таблице указывают первую версию браузера, которая полностью поддерживает свойство.
Свойство | |||||
---|---|---|---|---|---|
border-image-source | 15.0 | 11.0 | 15.0 | 6.0 | 15.0 |
Синтаксис CSS
border-image-source: none|image|initial|inherit;
Значения свойств
Значение | Описание |
---|---|
none | Изображение не будет использовано |
image | Путь к изображению, используемому в качестве границы |
initial | Присваивает этому свойству значение по умолчанию. (Читайте о initial) |
inherit | Наследует это свойство из родительского элемента. (Читайте о inherit) |
Похожие страницы
CSS Справочник: CSS Border Images
CSS Справка: border-image Свойство
CSS Справка: border-image-outset Свойство
CSS Справка: border-image-repeat Свойство
CSS Справка: border-image-slice Свойство
CSS Справка: border-image-width Свойство
HTML DOM Справочник: borderImageSource Свойство