1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
use crate::{
    BufferRange, FunctionIdentifier, Link, LinkDecorations, LinkMatcherOptions, LinkProvider,
    Terminal, TerminalOptions, Theme, UnicodeVersionProvider, WindowOptions,
};
use wasm_bindgen::JsCast;

impl Terminal {
    pub fn new(options: &TerminalOptions) -> Self {
        Terminal::construct(Some(&options))
    }
}

impl Default for Terminal {
    fn default() -> Self {
        Terminal::construct(None)
    }
}

impl TerminalOptions {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl Theme {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl LinkMatcherOptions {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl WindowOptions {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl LinkProvider {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl Link {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl LinkDecorations {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl BufferRange {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl FunctionIdentifier {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}

impl UnicodeVersionProvider {
    pub fn new() -> Self {
        js_sys::Object::new().unchecked_into()
    }
}