@cocreate/events 1.10.1 → 1.10.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/demo/click.html +89 -68
- package/demo/hover.html +69 -53
- package/demo/index.html +1 -1
- package/demo/selected.html +85 -51
- package/demo/set-value.html +26 -20
- package/docs/index.html +353 -91
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
## [1.10.3](https://github.com/CoCreate-app/CoCreate-events/compare/v1.10.2...v1.10.3) (2023-06-02)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* format demo html ([7a646c2](https://github.com/CoCreate-app/CoCreate-events/commit/7a646c2531d8e3833be2e5d5ff5945219720ee49))
|
|
7
|
+
* Update dependencies versions for [@cocreate](https://github.com/cocreate) libraries ([f5f8bb5](https://github.com/CoCreate-app/CoCreate-events/commit/f5f8bb5c7be2167b76ca3ab0c99ea9fdeee9c7d0))
|
|
8
|
+
|
|
9
|
+
## [1.10.2](https://github.com/CoCreate-app/CoCreate-events/compare/v1.10.1...v1.10.2) (2023-05-21)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
* Update dependencies versions for [@cocreate](https://github.com/cocreate) libraries ([89dcb00](https://github.com/CoCreate-app/CoCreate-events/commit/89dcb00e3c7b9e805694672d9cc79924f81f207f))
|
|
15
|
+
|
|
1
16
|
## [1.10.1](https://github.com/CoCreate-app/CoCreate-events/compare/v1.10.0...v1.10.1) (2023-05-19)
|
|
2
17
|
|
|
3
18
|
|
package/demo/click.html
CHANGED
|
@@ -1,70 +1,91 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
|
-
<html>
|
|
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
|
-
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<title>Events | CoCreateJS</title>
|
|
5
|
+
|
|
6
|
+
<!-- CoCreate Favicon -->
|
|
7
|
+
<link
|
|
8
|
+
rel="icon"
|
|
9
|
+
href="https://cdn.cocreate.app/favicon.ico"
|
|
10
|
+
type="image/ico"
|
|
11
|
+
sizes="16x16" />
|
|
12
|
+
|
|
13
|
+
<!-- Custom CSS -->
|
|
14
|
+
<style type="text/css">
|
|
15
|
+
.test {
|
|
16
|
+
background: red;
|
|
17
|
+
}
|
|
18
|
+
.new {
|
|
19
|
+
background: yellow;
|
|
20
|
+
}
|
|
21
|
+
.active {
|
|
22
|
+
background-color: blue;
|
|
23
|
+
}
|
|
24
|
+
.hidden {
|
|
25
|
+
display: none;
|
|
26
|
+
}
|
|
27
|
+
</style>
|
|
28
|
+
<link rel="manifest" href="/manifest.webmanifest" />
|
|
29
|
+
</head>
|
|
30
|
+
<body>
|
|
31
|
+
<div click="active" class="test">
|
|
32
|
+
hhh
|
|
33
|
+
<!--<div class="test">click me</div><br/>-->
|
|
34
|
+
</div>
|
|
35
|
+
|
|
36
|
+
<i
|
|
37
|
+
class="fas fa-plus-circle"
|
|
38
|
+
click="fa-minus-circle, fa-plus-circle"></i>
|
|
39
|
+
|
|
40
|
+
<article>
|
|
41
|
+
<div id="div-01" class="vdom-item">
|
|
42
|
+
<p>Here is div-01 i should get class hidden</p>
|
|
43
|
+
<div>
|
|
44
|
+
<div class="vdom-item">some content1</div>
|
|
45
|
+
<span click="test" click-closest=".vdom-item"
|
|
46
|
+
><i
|
|
47
|
+
class="height:16px fill:#505050"
|
|
48
|
+
src="/assets/svg/caret-down.svg"></i
|
|
49
|
+
></span>
|
|
50
|
+
</div>
|
|
51
|
+
<div class="vdom-item">some content2</div>
|
|
52
|
+
</div>
|
|
53
|
+
<div class="vdom-item">some content3</div>
|
|
54
|
+
<div id="div-03">Here is div-03</div>
|
|
55
|
+
</article>
|
|
56
|
+
<br />
|
|
57
|
+
<hr />
|
|
58
|
+
<div class="vdom-item" click="active" click-target="article > div">
|
|
59
|
+
some content
|
|
60
|
+
</div>
|
|
61
|
+
<br />
|
|
62
|
+
<hr />
|
|
63
|
+
<div
|
|
64
|
+
class="vdom-item"
|
|
65
|
+
click-attribute="class"
|
|
66
|
+
click="active"
|
|
67
|
+
click-target=".vdom-item">
|
|
68
|
+
click for active
|
|
69
|
+
</div>
|
|
70
|
+
<br />
|
|
71
|
+
<hr />
|
|
72
|
+
TEST HERE
|
|
73
|
+
<div
|
|
74
|
+
class="vdom-item"
|
|
75
|
+
id="hey"
|
|
76
|
+
data-test=""
|
|
77
|
+
click-attribute="value"
|
|
78
|
+
click-target="#tester"
|
|
79
|
+
click-value="active, other, hi, jean">
|
|
80
|
+
some content
|
|
81
|
+
</div>
|
|
82
|
+
<form>
|
|
83
|
+
<input id="tester" />
|
|
84
|
+
<a actions="reset">reset</a>
|
|
85
|
+
</form>
|
|
86
|
+
|
|
66
87
|
<!-- <script src="../dist/CoCreate-events.js"></script> -->
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
</html>
|
|
88
|
+
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
89
|
+
<!-- <script src="https://cdn.cocreate.app/1.50.6/CoCreate.min.js" ></script> -->
|
|
90
|
+
</body>
|
|
91
|
+
</html>
|
package/demo/hover.html
CHANGED
|
@@ -1,56 +1,72 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
|
-
<html>
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<title>Hover | CoCreateJS</title>
|
|
5
|
+
|
|
6
|
+
<!-- Custom CSS -->
|
|
7
|
+
<style type="text/css">
|
|
8
|
+
.test {
|
|
9
|
+
background: red;
|
|
10
|
+
}
|
|
11
|
+
.new {
|
|
12
|
+
background: yellow;
|
|
13
|
+
}
|
|
14
|
+
.active {
|
|
15
|
+
background-color: blue;
|
|
16
|
+
}
|
|
17
|
+
.hidden {
|
|
18
|
+
display: none;
|
|
19
|
+
}
|
|
20
|
+
</style>
|
|
21
|
+
<link rel="manifest" href="/manifest.webmanifest" />
|
|
22
|
+
</head>
|
|
23
|
+
<body>
|
|
24
|
+
<div hover="active" class="test">
|
|
25
|
+
hhh
|
|
26
|
+
<!--<div class="test">click me</div><br/>-->
|
|
27
|
+
</div>
|
|
28
|
+
|
|
29
|
+
<article>
|
|
30
|
+
<div id="div-01" class="vdom-item">
|
|
31
|
+
<p>Here is div-01 i should get class hidden</p>
|
|
32
|
+
<div>
|
|
33
|
+
<div class="vdom-item">some content1</div>
|
|
34
|
+
<span hover="test" hover-closest=".vdom-item"
|
|
35
|
+
><i
|
|
36
|
+
class="height:16px fill:#505050"
|
|
37
|
+
src="/assets/svg/caret-down.svg"></i
|
|
38
|
+
></span>
|
|
39
|
+
</div>
|
|
40
|
+
<div class="vdom-item">some content2</div>
|
|
41
|
+
</div>
|
|
42
|
+
<div class="vdom-item">some content3</div>
|
|
43
|
+
<div id="div-03">Here is div-03</div>
|
|
44
|
+
</article>
|
|
45
|
+
<br />
|
|
46
|
+
<hr />
|
|
47
|
+
<div class="vdom-item" hover="active" hover-target="article > div">
|
|
48
|
+
some content
|
|
49
|
+
</div>
|
|
50
|
+
<br />
|
|
51
|
+
<hr />
|
|
52
|
+
<div
|
|
53
|
+
class="vdom-item"
|
|
54
|
+
hover-attribute="class"
|
|
55
|
+
hover="active"
|
|
56
|
+
hover-target=".vdom-item">
|
|
57
|
+
click for active
|
|
58
|
+
</div>
|
|
59
|
+
|
|
60
|
+
<div
|
|
61
|
+
class="vdom-item"
|
|
62
|
+
id="hey"
|
|
63
|
+
data-test=""
|
|
64
|
+
hover-attribute="data-test"
|
|
65
|
+
hover="active, other, hi, jean">
|
|
66
|
+
some content
|
|
67
|
+
</div>
|
|
26
68
|
|
|
27
|
-
|
|
28
|
-
<article>
|
|
29
|
-
<div id="div-01" class="vdom-item">
|
|
30
|
-
<p>Here is div-01 i should get class hidden</p>
|
|
31
|
-
<div>
|
|
32
|
-
<div class="vdom-item" >some content1</div>
|
|
33
|
-
<span hover="test" hover-closest=".vdom-item"><i class="height:16px fill:#505050" src="/assets/svg/caret-down".svg"></i></span>
|
|
34
|
-
</div>
|
|
35
|
-
<div class="vdom-item" >some content2</div>
|
|
36
|
-
</div>
|
|
37
|
-
<div class="vdom-item" >some content3</div>
|
|
38
|
-
<div id="div-03">Here is div-03</div>
|
|
39
|
-
</article>
|
|
40
|
-
<br>
|
|
41
|
-
<hr>
|
|
42
|
-
<div class="vdom-item" hover="active" hover-target="article > div">some content</div>
|
|
43
|
-
<br>
|
|
44
|
-
<hr>
|
|
45
|
-
<div class="vdom-item" hover-attribute='class' hover="active" hover-target=".vdom-item">
|
|
46
|
-
click for active
|
|
47
|
-
</div>
|
|
48
|
-
|
|
49
|
-
<div class="vdom-item" id="hey" data-test="" hover-attribute='data-test' hover="active, other, hi, jean">
|
|
50
|
-
some content
|
|
51
|
-
</div>
|
|
52
|
-
|
|
53
69
|
<!--<script src="../dist/CoCreate-events.js"></script>-->
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
</html>
|
|
70
|
+
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
71
|
+
</body>
|
|
72
|
+
</html>
|
package/demo/index.html
CHANGED
package/demo/selected.html
CHANGED
|
@@ -1,55 +1,89 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
|
-
<html>
|
|
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
|
-
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<title>Selected | CoCreateJS</title>
|
|
5
|
+
|
|
6
|
+
<!-- CoCreate Favicon -->
|
|
7
|
+
<link
|
|
8
|
+
rel="icon"
|
|
9
|
+
href="https://cdn.cocreate.app/favicon.ico"
|
|
10
|
+
type="image/ico"
|
|
11
|
+
sizes="16x16" />
|
|
12
|
+
<!-- Custom CSS -->
|
|
13
|
+
<style type="text/css">
|
|
14
|
+
.test {
|
|
15
|
+
background: red;
|
|
16
|
+
}
|
|
17
|
+
.green {
|
|
18
|
+
background: green;
|
|
19
|
+
}
|
|
20
|
+
.yellow {
|
|
21
|
+
background: yellow;
|
|
22
|
+
}
|
|
23
|
+
.blue {
|
|
24
|
+
background: blue;
|
|
25
|
+
}
|
|
26
|
+
.red {
|
|
27
|
+
background: red;
|
|
28
|
+
}
|
|
29
|
+
.active {
|
|
30
|
+
background-color: blue;
|
|
31
|
+
}
|
|
32
|
+
.hfhfh[selected] {
|
|
33
|
+
}
|
|
34
|
+
</style>
|
|
35
|
+
<link rel="manifest" href="/manifest.webmanifest" />
|
|
36
|
+
</head>
|
|
37
|
+
<body>
|
|
38
|
+
<!--<article>-->
|
|
39
|
+
|
|
40
|
+
<div
|
|
41
|
+
id="yyy"
|
|
42
|
+
selected-target=".tester"
|
|
43
|
+
selected-value="active,"
|
|
44
|
+
selected-attribute="data-test"
|
|
45
|
+
selected-group="uno"
|
|
46
|
+
data-test=""
|
|
47
|
+
class="test">
|
|
48
|
+
1 tab
|
|
49
|
+
</div>
|
|
50
|
+
<div selected-value="active" selected-group="uno" class="test">
|
|
51
|
+
2 tab
|
|
52
|
+
</div>
|
|
53
|
+
<div selected-value="active" selected-group="uno" class="test">
|
|
54
|
+
3 tab
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<hr />
|
|
58
|
+
|
|
59
|
+
<div selected-value="yellow" selected-group="2" class="green">
|
|
60
|
+
1 tab
|
|
61
|
+
</div>
|
|
62
|
+
<div selected-value="blue" selected-group="2" class="green">2 tab</div>
|
|
63
|
+
<div selected-value="red" selected-group="2" class="green">3 tab</div>
|
|
64
|
+
|
|
65
|
+
<hr />
|
|
66
|
+
<div class="tester">
|
|
67
|
+
<div
|
|
68
|
+
selected-value="active"
|
|
69
|
+
selected-closest="div.tester"
|
|
70
|
+
class="test">
|
|
71
|
+
4 tab
|
|
72
|
+
</div>
|
|
73
|
+
<div selected-value="active" class="test">4 tab</div>
|
|
74
|
+
|
|
75
|
+
<div
|
|
76
|
+
selected-value="color:black; background:grey"
|
|
77
|
+
selected-attribute="style"
|
|
78
|
+
style="">
|
|
79
|
+
color tab
|
|
80
|
+
</div>
|
|
81
|
+
|
|
82
|
+
<div id="yyyy" data-test="" class="test">1 tab</div>
|
|
83
|
+
</div>
|
|
50
84
|
|
|
51
85
|
<!-- <script src="../dist/CoCreate-selected.js"></script> -->
|
|
52
86
|
<script src="https://cdn.cocreate.app/1.50.6/CoCreate.min.js"></script>
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
</html>
|
|
87
|
+
<!-- <script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script> -->
|
|
88
|
+
</body>
|
|
89
|
+
</html>
|
package/demo/set-value.html
CHANGED
|
@@ -1,25 +1,31 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
|
-
<html>
|
|
3
|
-
<head>
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
<!-- CoCreate Favicon -->
|
|
7
|
-
<link rel="icon" href="https://cdn.cocreate.app/favicon.ico" type="image/ico" sizes="16x16">
|
|
8
|
-
<link rel="manifest" href="/manifest.webmanifest">
|
|
9
|
-
</head>
|
|
10
|
-
<body>
|
|
11
|
-
<div click-target="#testing" click-value="hello, bye" click-key="ty">
|
|
12
|
-
<span id="testing" class="{{ty}}">other content</span>
|
|
13
|
-
</div>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<title>Value | CoCreateJS</title>
|
|
14
5
|
|
|
15
|
-
|
|
16
|
-
|
|
6
|
+
<!-- CoCreate Favicon -->
|
|
7
|
+
<link
|
|
8
|
+
rel="icon"
|
|
9
|
+
href="https://cdn.cocreate.app/favicon.ico"
|
|
10
|
+
type="image/ico"
|
|
11
|
+
sizes="16x16" />
|
|
12
|
+
<link rel="manifest" href="/manifest.webmanifest" />
|
|
13
|
+
</head>
|
|
14
|
+
<body>
|
|
15
|
+
<div click-target="#testing" click-value="hello, bye" click-key="ty">
|
|
16
|
+
<span id="testing" class="{{ty}}">other content</span>
|
|
17
|
+
</div>
|
|
17
18
|
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
<form realtime="false">
|
|
20
|
+
<input
|
|
21
|
+
input-target="#testing2"
|
|
22
|
+
input-attribute="value"
|
|
23
|
+
value-type="array" />
|
|
20
24
|
|
|
21
|
-
|
|
22
|
-
|
|
25
|
+
<input id="testing2" class="{{ty}}" />
|
|
26
|
+
</form>
|
|
23
27
|
|
|
24
|
-
|
|
25
|
-
|
|
28
|
+
<!-- <script src="../../../CoCreateJS/dist/CoCreate.js"></script> -->
|
|
29
|
+
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
30
|
+
</body>
|
|
31
|
+
</html>
|
package/docs/index.html
CHANGED
|
@@ -1,68 +1,190 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
-
<meta charset="utf-8"
|
|
5
|
-
<meta http-equiv="X-UA-Compatible" content="IE=edge"
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1"
|
|
7
|
-
<title>CoCreate-events Documentation | CoCreateJS
|
|
8
|
-
<link
|
|
9
|
-
|
|
10
|
-
|
|
4
|
+
<meta charset="utf-8" />
|
|
5
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
7
|
+
<title>CoCreate-events Documentation | CoCreateJS</title>
|
|
8
|
+
<link
|
|
9
|
+
rel="icon"
|
|
10
|
+
type="image/png"
|
|
11
|
+
sizes="32x32"
|
|
12
|
+
href="https://cocreate.app/images/favicon.ico" />
|
|
13
|
+
<meta
|
|
14
|
+
name="description"
|
|
15
|
+
content="A simple HTML5 and pure javascript component. Easy configuration using HTML5 attributes or Javscript api and highly styleable." />
|
|
16
|
+
<meta
|
|
17
|
+
name="keywords"
|
|
18
|
+
content="helper classes, utility classes, css framework, css library, inline style classes" />
|
|
11
19
|
<meta name="robots" content="index,follow" />
|
|
12
|
-
|
|
13
|
-
|
|
20
|
+
<meta
|
|
21
|
+
property="og:image"
|
|
22
|
+
content="https://cdn.cocreate.app/docs/events.png" />
|
|
23
|
+
|
|
14
24
|
<!-- CoCreate CSS -->
|
|
15
|
-
<link
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
25
|
+
<link
|
|
26
|
+
rel="stylesheet"
|
|
27
|
+
href="https://cdn.cocreate.app/latest/CoCreate.min.css"
|
|
28
|
+
type="text/css" />
|
|
29
|
+
<link
|
|
30
|
+
rel="stylesheet"
|
|
31
|
+
href="/docs/index.css"
|
|
32
|
+
collection="files"
|
|
33
|
+
document_id="60888216117c640e7596303f"
|
|
34
|
+
name="src"
|
|
35
|
+
type="text/css"
|
|
36
|
+
save="true" />
|
|
37
|
+
<link rel="manifest" href="/manifest.webmanifest" />
|
|
38
|
+
</head>
|
|
19
39
|
|
|
20
40
|
<body>
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
41
|
+
<nav
|
|
42
|
+
class="nav display:flex align-items:center left:0px background:whitesmoke padding-top:10px padding-bottom:10px"
|
|
43
|
+
content_id="content"
|
|
44
|
+
scroll="sticky-nav,hide-nav"
|
|
45
|
+
scroll-up="10"
|
|
46
|
+
scroll-down="10"
|
|
47
|
+
collection="files"
|
|
48
|
+
document_id="60395ef42b3ac232657040fd"
|
|
49
|
+
name="src"></nav>
|
|
50
|
+
<sidenav
|
|
51
|
+
id="menuL"
|
|
52
|
+
class="position:fixed top:0px left:0px overflow:hidden background:whitesmoke height:100vh width:0px width:300px@xl"
|
|
53
|
+
resizable
|
|
54
|
+
resize-target="[content_id='content']"
|
|
55
|
+
resize-property="margin-left"
|
|
56
|
+
resize-value="width">
|
|
57
|
+
<menu
|
|
58
|
+
collection="files"
|
|
59
|
+
document_id="603717b07de7fb350ae9fec8"
|
|
60
|
+
name="src"></menu>
|
|
61
|
+
<div resize="right"></div>
|
|
62
|
+
</sidenav>
|
|
63
|
+
<main
|
|
64
|
+
class="padding-top:15px padding:15px@lg@xl"
|
|
65
|
+
content_id="content"
|
|
66
|
+
id="cocreate-events">
|
|
67
|
+
<div
|
|
68
|
+
class="display:flex flex-wrap:wrap justify-content:space-between position:relative margin:10px">
|
|
29
69
|
<div class="display:flex align-items:center">
|
|
30
70
|
<h2>CoCreate-events</h2>
|
|
31
71
|
</div>
|
|
32
|
-
<div
|
|
33
|
-
|
|
72
|
+
<div
|
|
73
|
+
class="display:flex align-items:center font-size:20px position:absolute right:0 padding:5px background:white">
|
|
74
|
+
<div
|
|
75
|
+
class="display:flex align-items:center transition:0.3s padding-left:10px"
|
|
76
|
+
share-network="true"
|
|
77
|
+
share-text="Enter decription here"
|
|
78
|
+
share-title="testing im a title"
|
|
79
|
+
share-height="600"
|
|
80
|
+
share-width="700"
|
|
81
|
+
share-media="https://cdn.cocreate.app/docs/events.png"
|
|
82
|
+
hover="display:block!important"
|
|
83
|
+
hover-target=".social-networks">
|
|
34
84
|
<div class="display:none social-networks">
|
|
35
|
-
<a
|
|
36
|
-
|
|
37
|
-
|
|
85
|
+
<a
|
|
86
|
+
class="margin-right:15px"
|
|
87
|
+
share-network="twitter"
|
|
88
|
+
title="Share on twitter"
|
|
89
|
+
><i
|
|
90
|
+
class="height:20px fill:#505050"
|
|
91
|
+
src="/assets/svg/twitter.svg"></i
|
|
92
|
+
></a>
|
|
93
|
+
<a
|
|
94
|
+
class="margin-right:15px"
|
|
95
|
+
share-network="facebook"
|
|
96
|
+
title="Share on Facebook"
|
|
97
|
+
><i
|
|
98
|
+
class="height:20px fill:#505050"
|
|
99
|
+
src="/assets/svg/facebook.svg"></i
|
|
100
|
+
></a>
|
|
101
|
+
<a
|
|
102
|
+
class="margin-right:15px"
|
|
103
|
+
share-network="instagram"
|
|
104
|
+
title="Share on instagram"
|
|
105
|
+
><i
|
|
106
|
+
class="height:20px fill:#505050"
|
|
107
|
+
src="/assets/svg/instagram.svg"></i
|
|
108
|
+
></a>
|
|
38
109
|
</div>
|
|
39
|
-
<a
|
|
110
|
+
<a
|
|
111
|
+
class="margin-right:15px"
|
|
112
|
+
share-network="share"
|
|
113
|
+
title="Share on share"
|
|
114
|
+
><i
|
|
115
|
+
class="height:20px fill:#505050"
|
|
116
|
+
src="/assets/svg/share-alt.svg"></i
|
|
117
|
+
></a>
|
|
40
118
|
</div>
|
|
41
|
-
<a
|
|
119
|
+
<a
|
|
120
|
+
href="https://github.com/CoCreate-app/CoCreate-events"
|
|
121
|
+
target="_blank"
|
|
122
|
+
class="margin-right:15px"
|
|
123
|
+
><i
|
|
124
|
+
class="height:20px fill:#505050"
|
|
125
|
+
src="/assets/svg/github.svg"></i
|
|
126
|
+
></a>
|
|
42
127
|
</div>
|
|
43
128
|
</div>
|
|
44
|
-
<h1
|
|
129
|
+
<h1
|
|
130
|
+
class="max-width:500px margin:20px_10px line-height:1.5 font-size:16px font-weight:100">
|
|
131
|
+
It is used to change values in classes or specific attributes,
|
|
132
|
+
its name describes its functionality events.
|
|
133
|
+
</h1>
|
|
45
134
|
<div id="events-section" class="display:flex flex-wrap:wrap">
|
|
46
|
-
<div
|
|
47
|
-
|
|
48
|
-
|
|
135
|
+
<div
|
|
136
|
+
class="flex-grow:1 width:400px width:300px@xs padding:0px_10px margin-top:60px">
|
|
137
|
+
<div
|
|
138
|
+
id="events-install"
|
|
139
|
+
class="border-bottom:1px_solid_lightgrey"
|
|
140
|
+
scroll
|
|
141
|
+
scroll-intersect="color:dodgerblue"
|
|
142
|
+
scroll-target="#events-install-section">
|
|
143
|
+
<span
|
|
144
|
+
class="display:flex align-items:center width:fit-content"
|
|
145
|
+
hover="display:block!important"
|
|
146
|
+
hover-target="[href='#events-install']">
|
|
49
147
|
<h2 class="padding:5px_0px">Install</h2>
|
|
50
|
-
<a
|
|
148
|
+
<a
|
|
149
|
+
class="margin-left:10px display:none"
|
|
150
|
+
href="#events-install"
|
|
151
|
+
><i
|
|
152
|
+
class="height:20px fill:#505050"
|
|
153
|
+
src="/assets/svg/link.svg"></i
|
|
154
|
+
></a>
|
|
51
155
|
</span>
|
|
52
156
|
</div>
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
157
|
+
<pre><code class="language-bash">npm i @cocreate/events</code></pre>
|
|
158
|
+
<p class="padding:10px_0px line-height:1.5">
|
|
159
|
+
Or you can use cdn link:
|
|
160
|
+
</p>
|
|
161
|
+
<pre><code class="language-html"><script>https://cdn.cocreate.app/events/latest/CoCreate-events.min.js</script></code></pre>
|
|
56
162
|
|
|
57
|
-
|
|
58
|
-
|
|
163
|
+
<div
|
|
164
|
+
id="events-usage"
|
|
165
|
+
class="margin-top:80px border-bottom:1px_solid_lightgrey"
|
|
166
|
+
scroll
|
|
167
|
+
scroll-intersect="color:dodgerblue"
|
|
168
|
+
scroll-target="#events-usage-section">
|
|
169
|
+
<span
|
|
170
|
+
class="display:flex align-items:center width:fit-content"
|
|
171
|
+
hover="display:block!important"
|
|
172
|
+
hover-target="[href='#events-usage']">
|
|
59
173
|
<h2 class="padding:5px_0px">Usage</h2>
|
|
60
|
-
<a
|
|
174
|
+
<a
|
|
175
|
+
class="margin-left:10px display:none"
|
|
176
|
+
href="#events-usage"
|
|
177
|
+
><i
|
|
178
|
+
class="height:20px fill:#505050"
|
|
179
|
+
src="/assets/svg/link.svg"></i
|
|
180
|
+
></a>
|
|
61
181
|
</span>
|
|
62
182
|
</div>
|
|
63
183
|
<div class="">
|
|
64
|
-
<p class="padding:10px_0px line-height:1.5">
|
|
65
|
-
|
|
184
|
+
<p class="padding:10px_0px line-height:1.5">
|
|
185
|
+
This is events usage
|
|
186
|
+
</p>
|
|
187
|
+
|
|
66
188
|
<div class="flex-grow:1 min-width:300px width:100%">
|
|
67
189
|
<pre>
|
|
68
190
|
<code class="language-js">
|
|
@@ -89,76 +211,216 @@
|
|
|
89
211
|
</code>
|
|
90
212
|
</pre>
|
|
91
213
|
</div>
|
|
92
|
-
<p class="padding:10px_0px line-height:1.5">
|
|
214
|
+
<p class="padding:10px_0px line-height:1.5">
|
|
215
|
+
This is events usage
|
|
216
|
+
</p>
|
|
93
217
|
</div>
|
|
94
|
-
<div
|
|
95
|
-
|
|
218
|
+
<div
|
|
219
|
+
id="events-attributes"
|
|
220
|
+
class="margin-top:80px border-bottom:1px_solid_lightgrey"
|
|
221
|
+
scroll
|
|
222
|
+
scroll-intersect="color:dodgerblue"
|
|
223
|
+
scroll-target="#events-attributes-section">
|
|
224
|
+
<span
|
|
225
|
+
class="display:flex align-items:center width:fit-content"
|
|
226
|
+
hover="display:block!important"
|
|
227
|
+
hover-target="[href='#events-attributes']">
|
|
96
228
|
<h2 class="padding:5px_0px">Attributes</h2>
|
|
97
|
-
<a
|
|
229
|
+
<a
|
|
230
|
+
class="margin-left:10px display:none"
|
|
231
|
+
href="#events-attributes"
|
|
232
|
+
><i
|
|
233
|
+
class="height:20px fill:#505050"
|
|
234
|
+
src="/assets/svg/link.svg"></i
|
|
235
|
+
></a>
|
|
98
236
|
</span>
|
|
99
237
|
</div>
|
|
100
|
-
<ul class="list-style-type:none
|
|
101
|
-
<li
|
|
102
|
-
|
|
103
|
-
<
|
|
238
|
+
<ul class="list-style-type:none">
|
|
239
|
+
<li
|
|
240
|
+
class="padding:15px_0px border-bottom:1px_solid_lightgrey">
|
|
241
|
+
<h4>
|
|
242
|
+
<span>events</span>
|
|
243
|
+
<span class="cocreate-badge success"
|
|
244
|
+
>string</span
|
|
245
|
+
>
|
|
246
|
+
<span class="cocreate-badge danger"
|
|
247
|
+
>required</span
|
|
248
|
+
>
|
|
249
|
+
</h4>
|
|
250
|
+
<p>
|
|
251
|
+
It is used to initialize the element, and this
|
|
252
|
+
attribute is added to the specific attribute if
|
|
253
|
+
it is defined, by default the class attribute is
|
|
254
|
+
used
|
|
255
|
+
</p>
|
|
104
256
|
</li>
|
|
105
|
-
<li
|
|
106
|
-
|
|
107
|
-
<
|
|
257
|
+
<li
|
|
258
|
+
class="padding:15px_0px border-bottom:1px_solid_lightgrey">
|
|
259
|
+
<h4>
|
|
260
|
+
<span>events-attribute</span>
|
|
261
|
+
<span class="cocreate-badge success"
|
|
262
|
+
>string</span
|
|
263
|
+
>
|
|
264
|
+
<span class="cocreate-badge warning"
|
|
265
|
+
>optional</span
|
|
266
|
+
>
|
|
267
|
+
</h4>
|
|
268
|
+
<p>
|
|
269
|
+
Add or remove values, by default the class
|
|
270
|
+
attribute is used
|
|
271
|
+
</p>
|
|
108
272
|
</li>
|
|
109
|
-
<li
|
|
110
|
-
|
|
111
|
-
<
|
|
273
|
+
<li
|
|
274
|
+
class="padding:15px_0px border-bottom:1px_solid_lightgrey">
|
|
275
|
+
<h4>
|
|
276
|
+
<span>events-target</span>
|
|
277
|
+
<span class="cocreate-badge success"
|
|
278
|
+
>string</span
|
|
279
|
+
>
|
|
280
|
+
<span class="cocreate-badge warning"
|
|
281
|
+
>optional</span
|
|
282
|
+
>
|
|
283
|
+
</h4>
|
|
284
|
+
<p>
|
|
285
|
+
Apply events functionality to a specific element
|
|
286
|
+
</p>
|
|
112
287
|
</li>
|
|
113
|
-
<li
|
|
114
|
-
|
|
115
|
-
<
|
|
288
|
+
<li
|
|
289
|
+
class="padding:15px_0px border-bottom:1px_solid_lightgrey">
|
|
290
|
+
<h4>
|
|
291
|
+
<span>events-closest</span>
|
|
292
|
+
<span class="cocreate-badge success"
|
|
293
|
+
>string</span
|
|
294
|
+
>
|
|
295
|
+
<span class="cocreate-badge warning"
|
|
296
|
+
>optional</span
|
|
297
|
+
>
|
|
298
|
+
</h4>
|
|
299
|
+
<p>
|
|
300
|
+
Apply events functionality to a closset element
|
|
301
|
+
</p>
|
|
116
302
|
</li>
|
|
117
303
|
</ul>
|
|
118
304
|
</div>
|
|
119
|
-
|
|
120
|
-
<div
|
|
305
|
+
|
|
306
|
+
<div
|
|
307
|
+
class="flex-grow:1 width:300px padding:0px_10px margin-top:60px border-bottom:1px_solid_lightgrey">
|
|
121
308
|
<!-- SandBox -->
|
|
122
|
-
<div
|
|
123
|
-
|
|
309
|
+
<div
|
|
310
|
+
id="events-demo"
|
|
311
|
+
class="border-bottom:1px_solid_lightgrey"
|
|
312
|
+
scroll
|
|
313
|
+
scroll-intersect="color:dodgerblue"
|
|
314
|
+
scroll-target="#events-demo-section">
|
|
315
|
+
<span
|
|
316
|
+
class="display:flex align-items:center width:fit-content"
|
|
317
|
+
hover="display:block!important"
|
|
318
|
+
hover-target="[href='#events-demo']">
|
|
124
319
|
<h2 class="padding:5px_0px">Demo</h2>
|
|
125
|
-
<a
|
|
320
|
+
<a
|
|
321
|
+
class="margin-left:10px display:none"
|
|
322
|
+
href="#events-demo"
|
|
323
|
+
><i
|
|
324
|
+
class="height:20px fill:#505050"
|
|
325
|
+
src="/assets/svg/link.svg"></i
|
|
326
|
+
></a>
|
|
126
327
|
</span>
|
|
127
328
|
</div>
|
|
128
|
-
<div
|
|
329
|
+
<div
|
|
330
|
+
class="position:sticky top:0 padding:15px_0px height:100vh">
|
|
129
331
|
<!-- SandBox -->
|
|
130
|
-
<div
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
332
|
+
<div
|
|
333
|
+
class="display:flex flex-direction:column position:relative overflow:hidden card border-radius:2px width:auto height:600px margin-top:20px"
|
|
334
|
+
id="playground">
|
|
335
|
+
<div
|
|
336
|
+
id="demo-code"
|
|
337
|
+
resizable
|
|
338
|
+
class="position:relative height:50%">
|
|
339
|
+
<textarea
|
|
340
|
+
type="code"
|
|
341
|
+
lang="html"
|
|
342
|
+
collection="demos"
|
|
343
|
+
document_id=""
|
|
344
|
+
name="demo"
|
|
345
|
+
save="false"
|
|
346
|
+
id="demo"
|
|
347
|
+
class="height:100% width:100% outline:none border:none resize:none padding:5px"></textarea>
|
|
348
|
+
<div
|
|
349
|
+
resize="bottom"
|
|
350
|
+
class="background:lightgrey"></div>
|
|
135
351
|
</div>
|
|
136
|
-
|
|
137
|
-
<div
|
|
138
|
-
|
|
352
|
+
|
|
353
|
+
<div
|
|
354
|
+
id="demo-preview"
|
|
355
|
+
class="position:relative overflow:auto background-color:white">
|
|
356
|
+
<div class="demopreview padding:20px"></div>
|
|
139
357
|
</div>
|
|
140
|
-
|
|
141
|
-
<div
|
|
142
|
-
|
|
143
|
-
<a
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
358
|
+
|
|
359
|
+
<div
|
|
360
|
+
class="font-size:20px position:absolute top:10px right:10px opacity:0.6">
|
|
361
|
+
<a
|
|
362
|
+
class="margin-right:10px"
|
|
363
|
+
id="eye"
|
|
364
|
+
show="#eye-slash"
|
|
365
|
+
hide="#eye, #demo-preview"
|
|
366
|
+
events="code-height"
|
|
367
|
+
events-target="#demo-code"
|
|
368
|
+
><i
|
|
369
|
+
class="height:18px fill:#505050"
|
|
370
|
+
src="/assets/svg/eye.svg"></i
|
|
371
|
+
></a>
|
|
372
|
+
<a
|
|
373
|
+
class="margin-right:10px"
|
|
374
|
+
hidden
|
|
375
|
+
id="eye-slash"
|
|
376
|
+
show="#eye, #demo-preview"
|
|
377
|
+
hide="#eye-slash"
|
|
378
|
+
events="code-height"
|
|
379
|
+
events-target="#demo-code"
|
|
380
|
+
><i
|
|
381
|
+
class="height:20px fill:#505050"
|
|
382
|
+
src="/assets/svg/eye-slash.svg"></i
|
|
383
|
+
></a>
|
|
384
|
+
<a
|
|
385
|
+
class="margin-right:10px"
|
|
386
|
+
id="code"
|
|
387
|
+
show="#code-slash"
|
|
388
|
+
hide="#code, #demo-code"
|
|
389
|
+
><i
|
|
390
|
+
class="height:20px fill:#505050"
|
|
391
|
+
src="/assets/svg/code.svg"></i
|
|
392
|
+
></a>
|
|
393
|
+
<a
|
|
394
|
+
class="margin-right:10px"
|
|
395
|
+
hidden
|
|
396
|
+
id="code-slash"
|
|
397
|
+
show="#code, #demo-code"
|
|
398
|
+
hide="#code-slash"
|
|
399
|
+
><i
|
|
400
|
+
class="display:flex height:18px fill:#505050"
|
|
401
|
+
src="/assets/svg/code.svg"></i
|
|
402
|
+
></a>
|
|
403
|
+
<a
|
|
404
|
+
class="margin-right:5px"
|
|
405
|
+
fullscreen
|
|
406
|
+
fullscreen-target="#playground"></a>
|
|
147
407
|
</div>
|
|
148
|
-
|
|
149
408
|
</div>
|
|
150
409
|
<!-- End SandBox -->
|
|
151
|
-
|
|
410
|
+
</div>
|
|
152
411
|
</div>
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
412
|
+
</div>
|
|
413
|
+
<button
|
|
414
|
+
href="https://github.com/CoCreate-app/CoCreate-events/tree/master/docs/index.html?message=docs%3A%20describe%20your%20change..."
|
|
415
|
+
target="_blank"
|
|
416
|
+
class="position:fixed bottom:15px right:15px padding:15px background:dodgerblue color:#fff font-size:1.5rem grow-hover border-radius:50% border-width:0 box-shadow:0px_2px_10px_0px_rgba(0,_0,_0,_0.4)">
|
|
417
|
+
<i
|
|
418
|
+
class="height:20px fill:#505050"
|
|
419
|
+
src="/assets/svg/pencil-alt.svg"></i>
|
|
420
|
+
</button>
|
|
421
|
+
</main>
|
|
422
|
+
|
|
423
|
+
<script src="./apikey.js"></script>
|
|
161
424
|
<script src="https://cdn.cocreate.app/latest/CoCreate.min.js"></script>
|
|
162
|
-
|
|
163
425
|
</body>
|
|
164
|
-
</html>
|
|
426
|
+
</html>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/events",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.3",
|
|
4
4
|
"description": "A simple events component in vanilla javascript. Easily configured using HTML5 attributes and/or JavaScript API.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"events",
|
|
@@ -59,10 +59,10 @@
|
|
|
59
59
|
"webpack-log": "^3.0.1"
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@cocreate/actions": "^1.8.
|
|
63
|
-
"@cocreate/docs": "^1.7.
|
|
64
|
-
"@cocreate/element-prototype": "^1.8.
|
|
65
|
-
"@cocreate/observer": "^1.
|
|
66
|
-
"@cocreate/utils": "^1.20.
|
|
62
|
+
"@cocreate/actions": "^1.8.12",
|
|
63
|
+
"@cocreate/docs": "^1.7.13",
|
|
64
|
+
"@cocreate/element-prototype": "^1.8.12",
|
|
65
|
+
"@cocreate/observer": "^1.8.0",
|
|
66
|
+
"@cocreate/utils": "^1.20.10"
|
|
67
67
|
}
|
|
68
68
|
}
|