From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- files/ja/web/api/cssstylerule/style/index.html | 41 ++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 files/ja/web/api/cssstylerule/style/index.html (limited to 'files/ja/web/api/cssstylerule/style/index.html') diff --git a/files/ja/web/api/cssstylerule/style/index.html b/files/ja/web/api/cssstylerule/style/index.html new file mode 100644 index 0000000000..7d3f91c398 --- /dev/null +++ b/files/ja/web/api/cssstylerule/style/index.html @@ -0,0 +1,41 @@ +--- +title: CSSStyleRule.style +slug: Web/API/CSSStyleRule/style +tags: + - API + - CSSOM + - Property + - Reference +translation_of: Web/API/CSSStyleRule/style +--- +

{{ APIRef("CSSOM") }}

+ +

概要

+ +

CSSRule.style プロパティは、{{DOMXref("CSSRule")}} の 宣言ブロック のための {{domxref("CSSStyleDeclaration")}} インターフェイスです。

+ +

構文

+ +
styleObj = cssRule.style
+ +

+ +
function stilo() {
+  alert(document.styleSheets[0].cssRules[0].style.cssText);
+}
+// displays "background-color: gray;"
+
+ +

補記

+ +

宣言ブロックは、波括弧内に現れるスタイル規則の部分であり、(波括弧の前に書かれるセレクターのための) 実際のスタイル定義を提供します 。

+ +

仕様書

+ +

DOM Level 2 CSS: styleCSSR

+ +

関連情報

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