@cocreate/fullscreen 1.1.80 → 1.1.82
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 +14 -0
- package/package.json +2 -2
- package/src/index.js +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [1.1.82](https://github.com/CoCreate-app/CoCreate-fullscreen/compare/v1.1.81...v1.1.82) (2022-11-23)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* bumped [@cocreate](https://github.com/cocreate) dependencies ([4f3e22f](https://github.com/CoCreate-app/CoCreate-fullscreen/commit/4f3e22f264d37fdfacb573723e6dff7645039e60))
|
|
7
|
+
|
|
8
|
+
## [1.1.81](https://github.com/CoCreate-app/CoCreate-fullscreen/compare/v1.1.80...v1.1.81) (2022-11-22)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* workflow docs ([d465609](https://github.com/CoCreate-app/CoCreate-fullscreen/commit/d465609507ab8688ed9eaf2c54d0465f0618b69e))
|
|
14
|
+
|
|
1
15
|
## [1.1.80](https://github.com/CoCreate-app/CoCreate-fullscreen/compare/v1.1.79...v1.1.80) (2022-11-22)
|
|
2
16
|
|
|
3
17
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/fullscreen",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.82",
|
|
4
4
|
"description": "Toggle any html element to view in fullscreen mode. Easy configuration and targeting using the fullscreen and target attribute.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"fullscreen",
|
|
@@ -61,6 +61,6 @@
|
|
|
61
61
|
"webpack-log": "^3.0.1"
|
|
62
62
|
},
|
|
63
63
|
"dependencies": {
|
|
64
|
-
"@cocreate/docs": "^1.
|
|
64
|
+
"@cocreate/docs": "^1.4.2"
|
|
65
65
|
}
|
|
66
66
|
}
|
package/src/index.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
var requestFullscreen = function (ele) {
|
|
9
|
-
if(!document.fullscreenElement){
|
|
9
|
+
if (!document.fullscreenElement){
|
|
10
10
|
if (ele.requestFullscreen) {
|
|
11
11
|
ele.requestFullscreen();
|
|
12
12
|
} else if (ele.webkitRequestFullscreen) {
|
|
@@ -22,7 +22,7 @@ var requestFullscreen = function (ele) {
|
|
|
22
22
|
};
|
|
23
23
|
|
|
24
24
|
var exitFullscreen = function (item) {
|
|
25
|
-
if(document.fullscreenElement){
|
|
25
|
+
if (document.fullscreenElement){
|
|
26
26
|
if (document.exitFullscreen) {
|
|
27
27
|
document.exitFullscreen();
|
|
28
28
|
} else if (document.webkitExitFullscreen) {
|
|
@@ -65,7 +65,7 @@ document.addEventListener('fullscreenchange', (event) => {
|
|
|
65
65
|
list_fs_target_button_true.forEach(elem =>{
|
|
66
66
|
//elem.dataset['fullscreen'] = document.fullscreenElement!=null
|
|
67
67
|
console.log("evetn ",document.fullscreenElement)
|
|
68
|
-
if(document.fullscreenElement==null){
|
|
68
|
+
if (document.fullscreenElement==null){
|
|
69
69
|
console.log("LOG fullscreen")
|
|
70
70
|
elem.setAttribute('fullscreen', false)
|
|
71
71
|
}
|
|
@@ -75,7 +75,7 @@ document.addEventListener('fullscreenchange', (event) => {
|
|
|
75
75
|
for (let item of list_fs_target_button) {
|
|
76
76
|
item.addEventListener("click", function(event) {
|
|
77
77
|
console.log("primero ",item.dataset['fullscreen'])
|
|
78
|
-
if(document.fullscreenElement==null)
|
|
78
|
+
if (document.fullscreenElement==null)
|
|
79
79
|
item.setAttribute('fullscreen', false)
|
|
80
80
|
var action = typeof item.dataset['fullscreen'] != 'undefined' ? Boolean.parse(item.dataset['fullscreen']) : false
|
|
81
81
|
console.log("action ",action)
|
|
@@ -84,7 +84,7 @@ for (let item of list_fs_target_button) {
|
|
|
84
84
|
})*/
|
|
85
85
|
item.dataset['fullscreen'] = !action
|
|
86
86
|
console.log("primero ",item.dataset['fullscreen'])
|
|
87
|
-
if(!action){
|
|
87
|
+
if (!action){
|
|
88
88
|
FullscreenItem(item)
|
|
89
89
|
}
|
|
90
90
|
else{
|