-
Notifications
You must be signed in to change notification settings - Fork 0
/
custom-elements.json
59 lines (59 loc) · 1.87 KB
/
custom-elements.json
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
{
"version": "experimental",
"tags": [
{
"name": "wc-accordion",
"path": "./wc-accordion.js",
"attributes": [
{
"name": "mode"
}
],
"properties": [
{
"name": "template",
"type": "string",
"default": "\"<slot></slot>\""
},
{
"name": "openAll",
"type": "() => void",
"default": "\"() => {\\n this.elements.forEach((el) => {\\n el.open();\\n });\\n }\""
},
{
"name": "closeAll",
"type": "() => void",
"default": "\"() => {\\n this.elements.forEach((el) => {\\n el.shrink();\\n });\\n }\""
},
{
"name": "open",
"type": "(index: any) => void",
"default": "\"(index) => {\\n try {\\n this.elements[index].open();\\n } catch (error) {\\n console.log(error);\\n }\\n }\""
},
{
"name": "close",
"type": "(index: any) => void",
"default": "\"(index) => {\\n try {\\n this.elements[index].shrink();\\n } catch (error) {\\n console.log(error);\\n }\\n }\""
},
{
"name": "handleOnChange",
"type": "(event: any) => void",
"default": "\"(event) => {\\n if (event.target.checked) {\\n this.openAll();\\n } else {\\n this.closeAll();\\n }\\n }\""
},
{
"name": "handleExclusiveOpen",
"type": "(event: any) => void",
"default": "\"(event) => {\\n this.elements.forEach((detail) => {\\n if (detail.el !== event.target) {\\n detail.shrink();\\n }\\n });\\n }\""
},
{
"name": "defaultSlot"
},
{
"name": "elements",
"type": "never[]",
"default": "[]"
}
]
}
]
}