1 | #![allow (unused_imports)] |
2 | #![allow (clippy::all)] |
3 | use super::*; |
4 | use wasm_bindgen::prelude::*; |
5 | #[wasm_bindgen ] |
6 | unsafeextern "C" { |
7 | # [wasm_bindgen (extends = :: js_sys :: Object , js_name = CSSStyleDeclaration , typescript_type = "CSSStyleDeclaration" )] |
8 | #[derive (Debug, Clone, PartialEq, Eq)] |
9 | #[doc = "The `CssStyleDeclaration` class." ] |
10 | #[doc = "" ] |
11 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration)" ] |
12 | #[doc = "" ] |
13 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
14 | pub type CssStyleDeclaration; |
15 | # [wasm_bindgen (structural , method , getter , js_class = "CSSStyleDeclaration" , js_name = cssText)] |
16 | #[doc = "Getter for the `cssText` field of this object." ] |
17 | #[doc = "" ] |
18 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/cssText)" ] |
19 | #[doc = "" ] |
20 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
21 | pub unsafefn css_text(this: &CssStyleDeclaration) -> ::alloc::string::String; |
22 | # [wasm_bindgen (structural , method , setter , js_class = "CSSStyleDeclaration" , js_name = cssText)] |
23 | #[doc = "Setter for the `cssText` field of this object." ] |
24 | #[doc = "" ] |
25 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/cssText)" ] |
26 | #[doc = "" ] |
27 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
28 | pub unsafefn set_css_text(this: &CssStyleDeclaration, value: &str); |
29 | # [wasm_bindgen (structural , method , getter , js_class = "CSSStyleDeclaration" , js_name = length)] |
30 | #[doc = "Getter for the `length` field of this object." ] |
31 | #[doc = "" ] |
32 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/length)" ] |
33 | #[doc = "" ] |
34 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
35 | pub unsafefn length(this: &CssStyleDeclaration) -> u32; |
36 | #[cfg (feature = "CssRule" )] |
37 | # [wasm_bindgen (structural , method , getter , js_class = "CSSStyleDeclaration" , js_name = parentRule)] |
38 | #[doc = "Getter for the `parentRule` field of this object." ] |
39 | #[doc = "" ] |
40 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/parentRule)" ] |
41 | #[doc = "" ] |
42 | #[doc = "*This API requires the following crate features to be activated: `CssRule`, `CssStyleDeclaration`*" ] |
43 | pub fn parent_rule(this: &CssStyleDeclaration) -> Option<CssRule>; |
44 | # [wasm_bindgen (method , structural , js_class = "CSSStyleDeclaration" , js_name = getPropertyPriority)] |
45 | #[doc = "The `getPropertyPriority()` method." ] |
46 | #[doc = "" ] |
47 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/getPropertyPriority)" ] |
48 | #[doc = "" ] |
49 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
50 | pub unsafefn get_property_priority( |
51 | this: &CssStyleDeclaration, |
52 | property: &str, |
53 | ) -> ::alloc::string::String; |
54 | # [wasm_bindgen (catch , method , structural , js_class = "CSSStyleDeclaration" , js_name = getPropertyValue)] |
55 | #[doc = "The `getPropertyValue()` method." ] |
56 | #[doc = "" ] |
57 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/getPropertyValue)" ] |
58 | #[doc = "" ] |
59 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
60 | pub unsafefn get_property_value( |
61 | this: &CssStyleDeclaration, |
62 | property: &str, |
63 | ) -> Result<::alloc::string::String, JsValue>; |
64 | # [wasm_bindgen (method , structural , js_class = "CSSStyleDeclaration" , js_name = item)] |
65 | #[doc = "The `item()` method." ] |
66 | #[doc = "" ] |
67 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/item)" ] |
68 | #[doc = "" ] |
69 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
70 | pub unsafefn item(this: &CssStyleDeclaration, index: u32) -> ::alloc::string::String; |
71 | # [wasm_bindgen (catch , method , structural , js_class = "CSSStyleDeclaration" , js_name = removeProperty)] |
72 | #[doc = "The `removeProperty()` method." ] |
73 | #[doc = "" ] |
74 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/removeProperty)" ] |
75 | #[doc = "" ] |
76 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
77 | pub unsafefn remove_property( |
78 | this: &CssStyleDeclaration, |
79 | property: &str, |
80 | ) -> Result<::alloc::string::String, JsValue>; |
81 | # [wasm_bindgen (catch , method , structural , js_class = "CSSStyleDeclaration" , js_name = setProperty)] |
82 | #[doc = "The `setProperty()` method." ] |
83 | #[doc = "" ] |
84 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/setProperty)" ] |
85 | #[doc = "" ] |
86 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
87 | pub unsafefn set_property( |
88 | this: &CssStyleDeclaration, |
89 | property: &str, |
90 | value: &str, |
91 | ) -> Result<(), JsValue>; |
92 | # [wasm_bindgen (catch , method , structural , js_class = "CSSStyleDeclaration" , js_name = setProperty)] |
93 | #[doc = "The `setProperty()` method." ] |
94 | #[doc = "" ] |
95 | #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CSSStyleDeclaration/setProperty)" ] |
96 | #[doc = "" ] |
97 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
98 | pub unsafefn set_property_with_priority( |
99 | this: &CssStyleDeclaration, |
100 | property: &str, |
101 | value: &str, |
102 | priority: &str, |
103 | ) -> Result<(), JsValue>; |
104 | #[wasm_bindgen (method, structural, js_class = "CSSStyleDeclaration" , indexing_getter)] |
105 | #[doc = "Indexing getter. As in the literal Javascript `this[key]`." ] |
106 | #[doc = "" ] |
107 | #[doc = "" ] |
108 | #[doc = "" ] |
109 | #[doc = "*This API requires the following crate features to be activated: `CssStyleDeclaration`*" ] |
110 | pub unsafefn get(this: &CssStyleDeclaration, index: u32) -> Option<::alloc::string::String>; |
111 | } |
112 | |