1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7 # [wasm_bindgen (extends = UiEvent , extends = Event , extends = :: js_sys :: Object , js_name = CompositionEvent , typescript_type = "CompositionEvent")]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `CompositionEvent` class."]
10 #[doc = ""]
11 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent)"]
12 #[doc = ""]
13 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
14 pub type CompositionEvent;
15 # [wasm_bindgen (structural , method , getter , js_class = "CompositionEvent" , js_name = data)]
16 #[doc = "Getter for the `data` field of this object."]
17 #[doc = ""]
18 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/data)"]
19 #[doc = ""]
20 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
21 pub fn data(this: &CompositionEvent) -> Option<String>;
22 # [wasm_bindgen (structural , method , getter , js_class = "CompositionEvent" , js_name = locale)]
23 #[doc = "Getter for the `locale` field of this object."]
24 #[doc = ""]
25 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/locale)"]
26 #[doc = ""]
27 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
28 pub fn locale(this: &CompositionEvent) -> String;
29 #[wasm_bindgen(catch, constructor, js_class = "CompositionEvent")]
30 #[doc = "The `new CompositionEvent(..)` constructor, creating a new instance of `CompositionEvent`."]
31 #[doc = ""]
32 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/CompositionEvent)"]
33 #[doc = ""]
34 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
35 pub fn new(type_: &str) -> Result<CompositionEvent, JsValue>;
36 #[cfg(feature = "CompositionEventInit")]
37 #[wasm_bindgen(catch, constructor, js_class = "CompositionEvent")]
38 #[doc = "The `new CompositionEvent(..)` constructor, creating a new instance of `CompositionEvent`."]
39 #[doc = ""]
40 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/CompositionEvent)"]
41 #[doc = ""]
42 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`, `CompositionEventInit`*"]
43 pub fn new_with_event_init_dict(
44 type_: &str,
45 event_init_dict: &CompositionEventInit,
46 ) -> Result<CompositionEvent, JsValue>;
47 # [wasm_bindgen (method , structural , js_class = "CompositionEvent" , js_name = initCompositionEvent)]
48 #[doc = "The `initCompositionEvent()` method."]
49 #[doc = ""]
50 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/initCompositionEvent)"]
51 #[doc = ""]
52 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
53 pub fn init_composition_event(this: &CompositionEvent, type_arg: &str);
54 # [wasm_bindgen (method , structural , js_class = "CompositionEvent" , js_name = initCompositionEvent)]
55 #[doc = "The `initCompositionEvent()` method."]
56 #[doc = ""]
57 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/initCompositionEvent)"]
58 #[doc = ""]
59 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
60 pub fn init_composition_event_with_can_bubble_arg(
61 this: &CompositionEvent,
62 type_arg: &str,
63 can_bubble_arg: bool,
64 );
65 # [wasm_bindgen (method , structural , js_class = "CompositionEvent" , js_name = initCompositionEvent)]
66 #[doc = "The `initCompositionEvent()` method."]
67 #[doc = ""]
68 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/initCompositionEvent)"]
69 #[doc = ""]
70 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`*"]
71 pub fn init_composition_event_with_can_bubble_arg_and_cancelable_arg(
72 this: &CompositionEvent,
73 type_arg: &str,
74 can_bubble_arg: bool,
75 cancelable_arg: bool,
76 );
77 #[cfg(feature = "Window")]
78 # [wasm_bindgen (method , structural , js_class = "CompositionEvent" , js_name = initCompositionEvent)]
79 #[doc = "The `initCompositionEvent()` method."]
80 #[doc = ""]
81 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/initCompositionEvent)"]
82 #[doc = ""]
83 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`, `Window`*"]
84 pub fn init_composition_event_with_can_bubble_arg_and_cancelable_arg_and_view_arg(
85 this: &CompositionEvent,
86 type_arg: &str,
87 can_bubble_arg: bool,
88 cancelable_arg: bool,
89 view_arg: Option<&Window>,
90 );
91 #[cfg(feature = "Window")]
92 # [wasm_bindgen (method , structural , js_class = "CompositionEvent" , js_name = initCompositionEvent)]
93 #[doc = "The `initCompositionEvent()` method."]
94 #[doc = ""]
95 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/initCompositionEvent)"]
96 #[doc = ""]
97 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`, `Window`*"]
98 pub fn init_composition_event_with_can_bubble_arg_and_cancelable_arg_and_view_arg_and_data_arg(
99 this: &CompositionEvent,
100 type_arg: &str,
101 can_bubble_arg: bool,
102 cancelable_arg: bool,
103 view_arg: Option<&Window>,
104 data_arg: Option<&str>,
105 );
106 #[cfg(feature = "Window")]
107 # [wasm_bindgen (method , structural , js_class = "CompositionEvent" , js_name = initCompositionEvent)]
108 #[doc = "The `initCompositionEvent()` method."]
109 #[doc = ""]
110 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/CompositionEvent/initCompositionEvent)"]
111 #[doc = ""]
112 #[doc = "*This API requires the following crate features to be activated: `CompositionEvent`, `Window`*"]
113 pub fn init_composition_event_with_can_bubble_arg_and_cancelable_arg_and_view_arg_and_data_arg_and_locale_arg(
114 this: &CompositionEvent,
115 type_arg: &str,
116 can_bubble_arg: bool,
117 cancelable_arg: bool,
118 view_arg: Option<&Window>,
119 data_arg: Option<&str>,
120 locale_arg: &str,
121 );
122}
123