ninegrid2 6.896.0 → 6.898.0
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/dist/bundle.cjs.js +25 -22
- package/dist/bundle.esm.js +25 -22
- package/dist/etc/nxDialog.js +25 -22
- package/package.json +1 -1
- package/src/etc/nxDialog.js +25 -22
package/dist/bundle.cjs.js
CHANGED
|
@@ -119317,18 +119317,18 @@ class nxDialog extends HTMLElement
|
|
|
119317
119317
|
{
|
|
119318
119318
|
//#owner;
|
|
119319
119319
|
#shift;
|
|
119320
|
-
|
|
119320
|
+
|
|
119321
119321
|
constructor () {
|
|
119322
119322
|
super();
|
|
119323
119323
|
}
|
|
119324
|
-
|
|
119324
|
+
|
|
119325
119325
|
connectedCallback() {
|
|
119326
119326
|
|
|
119327
119327
|
const v = this.innerHTML;
|
|
119328
119328
|
const cssFile = this.getAttribute("css-file");
|
|
119329
119329
|
const customFile1 = cssFile ? `@import "https://cdn.jsdelivr.net/npm/ninegrid@${ninegrid.version}/dist/css/${cssFile}";`: "";
|
|
119330
119330
|
const customFile2 = cssFile ? ninegrid.getCustomPath(this, cssFile) : "";
|
|
119331
|
-
|
|
119331
|
+
|
|
119332
119332
|
//console.log(ninegrid.getCustomPath(this,"nxDialog.css"));
|
|
119333
119333
|
|
|
119334
119334
|
this.innerHTML = `
|
|
@@ -119368,18 +119368,18 @@ class nxDialog extends HTMLElement
|
|
|
119368
119368
|
</div>
|
|
119369
119369
|
</dialog>
|
|
119370
119370
|
`;
|
|
119371
|
-
|
|
119371
|
+
|
|
119372
119372
|
//this.#owner = this.getRootNode().host.closest("nine-grid");
|
|
119373
|
-
|
|
119373
|
+
|
|
119374
119374
|
$(".title", this).html("Details");
|
|
119375
|
-
|
|
119375
|
+
|
|
119376
119376
|
this.#init();
|
|
119377
119377
|
};
|
|
119378
|
-
|
|
119378
|
+
|
|
119379
119379
|
showModal = () => {
|
|
119380
119380
|
this.querySelector('dialog').showModal();
|
|
119381
119381
|
};
|
|
119382
|
-
|
|
119382
|
+
|
|
119383
119383
|
close = () => {
|
|
119384
119384
|
$(".head", this) .off('mousedown', this.#onMouseDown);
|
|
119385
119385
|
$(".head", this) .off('touchstart', this.#onTouchStart);
|
|
@@ -119387,29 +119387,32 @@ class nxDialog extends HTMLElement
|
|
|
119387
119387
|
$(document) .off('touchend', this.#onTouchEnd);
|
|
119388
119388
|
$(document) .off('mousemove', this.#onMouseMove);
|
|
119389
119389
|
$(document) .off("touchmove", this.#onTouchMove);
|
|
119390
|
-
|
|
119390
|
+
|
|
119391
119391
|
this.querySelector('dialog').close();
|
|
119392
119392
|
};
|
|
119393
|
-
|
|
119393
|
+
|
|
119394
119394
|
#init = () => {
|
|
119395
119395
|
$(".close,.close2", this).on("click", e => {
|
|
119396
|
+
this.close();
|
|
119397
|
+
/**
|
|
119396
119398
|
ninegrid.j.querySelectorAll('dialog', this).addClass("out");
|
|
119397
119399
|
setTimeout(() => { this.close(); }, 300);
|
|
119400
|
+
*/
|
|
119398
119401
|
});
|
|
119399
|
-
|
|
119402
|
+
|
|
119400
119403
|
$(".head", this) .on('mousedown', this.#onMouseDown);
|
|
119401
119404
|
$(".head", this) .on('touchstart', this.#onTouchStart);
|
|
119402
119405
|
$(document) .on('mouseup', this.#onMouseUp);
|
|
119403
119406
|
$(document) .on('touchend', this.#onTouchEnd);
|
|
119404
119407
|
};
|
|
119405
|
-
|
|
119408
|
+
|
|
119406
119409
|
|
|
119407
119410
|
#onMouseDown = e => {
|
|
119408
119411
|
if (e.target.closest("buttons")) return;
|
|
119409
119412
|
if (e.buttons != 1 || e.altKey || e.ctrlKey || e.shiftkey) return;
|
|
119410
119413
|
|
|
119411
119414
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
119412
|
-
|
|
119415
|
+
|
|
119413
119416
|
this.#shift = {
|
|
119414
119417
|
x : e.clientX - rect.x,
|
|
119415
119418
|
y : e.clientY - rect.y,
|
|
@@ -119417,33 +119420,33 @@ class nxDialog extends HTMLElement
|
|
|
119417
119420
|
|
|
119418
119421
|
$(document).on('mousemove', this.#onMouseMove);
|
|
119419
119422
|
};
|
|
119420
|
-
|
|
119421
|
-
|
|
119423
|
+
|
|
119424
|
+
|
|
119422
119425
|
#onMouseMove = e => {
|
|
119423
119426
|
$(this.querySelector('dialog')).offset( { left : e.pageX - this.#shift.x, top : e.pageY - this.#shift.y });
|
|
119424
119427
|
};
|
|
119425
|
-
|
|
119428
|
+
|
|
119426
119429
|
#onMouseUp = e => {
|
|
119427
119430
|
$(document).off('mousemove', this.#onMouseMove);
|
|
119428
119431
|
};
|
|
119429
|
-
|
|
119432
|
+
|
|
119430
119433
|
#onTouchStart = e => {
|
|
119431
119434
|
if (e.target.closest("buttons")) return;
|
|
119432
|
-
|
|
119435
|
+
|
|
119433
119436
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
119434
|
-
|
|
119437
|
+
|
|
119435
119438
|
this.#shift = {
|
|
119436
119439
|
x : e.changedTouches[0].pageX - rect.x,
|
|
119437
119440
|
y : e.changedTouches[0].pageY - rect.y,
|
|
119438
119441
|
};
|
|
119439
|
-
|
|
119442
|
+
|
|
119440
119443
|
$(document).on("touchmove", this.#onTouchMove);
|
|
119441
119444
|
};
|
|
119442
|
-
|
|
119445
|
+
|
|
119443
119446
|
#onTouchMove = e => {
|
|
119444
119447
|
$(this.querySelector('dialog')).offset( { left : e.changedTouches[0].pageX - this.#shift.x, top : e.changedTouches[0].pageY - this.#shift.y });
|
|
119445
119448
|
};
|
|
119446
|
-
|
|
119449
|
+
|
|
119447
119450
|
#onTouchEnd = e => {
|
|
119448
119451
|
$(document).off('touchmove', this.#onTouchMove);
|
|
119449
119452
|
};
|
package/dist/bundle.esm.js
CHANGED
|
@@ -119313,18 +119313,18 @@ class nxDialog extends HTMLElement
|
|
|
119313
119313
|
{
|
|
119314
119314
|
//#owner;
|
|
119315
119315
|
#shift;
|
|
119316
|
-
|
|
119316
|
+
|
|
119317
119317
|
constructor () {
|
|
119318
119318
|
super();
|
|
119319
119319
|
}
|
|
119320
|
-
|
|
119320
|
+
|
|
119321
119321
|
connectedCallback() {
|
|
119322
119322
|
|
|
119323
119323
|
const v = this.innerHTML;
|
|
119324
119324
|
const cssFile = this.getAttribute("css-file");
|
|
119325
119325
|
const customFile1 = cssFile ? `@import "https://cdn.jsdelivr.net/npm/ninegrid@${ninegrid.version}/dist/css/${cssFile}";`: "";
|
|
119326
119326
|
const customFile2 = cssFile ? ninegrid.getCustomPath(this, cssFile) : "";
|
|
119327
|
-
|
|
119327
|
+
|
|
119328
119328
|
//console.log(ninegrid.getCustomPath(this,"nxDialog.css"));
|
|
119329
119329
|
|
|
119330
119330
|
this.innerHTML = `
|
|
@@ -119364,18 +119364,18 @@ class nxDialog extends HTMLElement
|
|
|
119364
119364
|
</div>
|
|
119365
119365
|
</dialog>
|
|
119366
119366
|
`;
|
|
119367
|
-
|
|
119367
|
+
|
|
119368
119368
|
//this.#owner = this.getRootNode().host.closest("nine-grid");
|
|
119369
|
-
|
|
119369
|
+
|
|
119370
119370
|
$(".title", this).html("Details");
|
|
119371
|
-
|
|
119371
|
+
|
|
119372
119372
|
this.#init();
|
|
119373
119373
|
};
|
|
119374
|
-
|
|
119374
|
+
|
|
119375
119375
|
showModal = () => {
|
|
119376
119376
|
this.querySelector('dialog').showModal();
|
|
119377
119377
|
};
|
|
119378
|
-
|
|
119378
|
+
|
|
119379
119379
|
close = () => {
|
|
119380
119380
|
$(".head", this) .off('mousedown', this.#onMouseDown);
|
|
119381
119381
|
$(".head", this) .off('touchstart', this.#onTouchStart);
|
|
@@ -119383,29 +119383,32 @@ class nxDialog extends HTMLElement
|
|
|
119383
119383
|
$(document) .off('touchend', this.#onTouchEnd);
|
|
119384
119384
|
$(document) .off('mousemove', this.#onMouseMove);
|
|
119385
119385
|
$(document) .off("touchmove", this.#onTouchMove);
|
|
119386
|
-
|
|
119386
|
+
|
|
119387
119387
|
this.querySelector('dialog').close();
|
|
119388
119388
|
};
|
|
119389
|
-
|
|
119389
|
+
|
|
119390
119390
|
#init = () => {
|
|
119391
119391
|
$(".close,.close2", this).on("click", e => {
|
|
119392
|
+
this.close();
|
|
119393
|
+
/**
|
|
119392
119394
|
ninegrid.j.querySelectorAll('dialog', this).addClass("out");
|
|
119393
119395
|
setTimeout(() => { this.close(); }, 300);
|
|
119396
|
+
*/
|
|
119394
119397
|
});
|
|
119395
|
-
|
|
119398
|
+
|
|
119396
119399
|
$(".head", this) .on('mousedown', this.#onMouseDown);
|
|
119397
119400
|
$(".head", this) .on('touchstart', this.#onTouchStart);
|
|
119398
119401
|
$(document) .on('mouseup', this.#onMouseUp);
|
|
119399
119402
|
$(document) .on('touchend', this.#onTouchEnd);
|
|
119400
119403
|
};
|
|
119401
|
-
|
|
119404
|
+
|
|
119402
119405
|
|
|
119403
119406
|
#onMouseDown = e => {
|
|
119404
119407
|
if (e.target.closest("buttons")) return;
|
|
119405
119408
|
if (e.buttons != 1 || e.altKey || e.ctrlKey || e.shiftkey) return;
|
|
119406
119409
|
|
|
119407
119410
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
119408
|
-
|
|
119411
|
+
|
|
119409
119412
|
this.#shift = {
|
|
119410
119413
|
x : e.clientX - rect.x,
|
|
119411
119414
|
y : e.clientY - rect.y,
|
|
@@ -119413,33 +119416,33 @@ class nxDialog extends HTMLElement
|
|
|
119413
119416
|
|
|
119414
119417
|
$(document).on('mousemove', this.#onMouseMove);
|
|
119415
119418
|
};
|
|
119416
|
-
|
|
119417
|
-
|
|
119419
|
+
|
|
119420
|
+
|
|
119418
119421
|
#onMouseMove = e => {
|
|
119419
119422
|
$(this.querySelector('dialog')).offset( { left : e.pageX - this.#shift.x, top : e.pageY - this.#shift.y });
|
|
119420
119423
|
};
|
|
119421
|
-
|
|
119424
|
+
|
|
119422
119425
|
#onMouseUp = e => {
|
|
119423
119426
|
$(document).off('mousemove', this.#onMouseMove);
|
|
119424
119427
|
};
|
|
119425
|
-
|
|
119428
|
+
|
|
119426
119429
|
#onTouchStart = e => {
|
|
119427
119430
|
if (e.target.closest("buttons")) return;
|
|
119428
|
-
|
|
119431
|
+
|
|
119429
119432
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
119430
|
-
|
|
119433
|
+
|
|
119431
119434
|
this.#shift = {
|
|
119432
119435
|
x : e.changedTouches[0].pageX - rect.x,
|
|
119433
119436
|
y : e.changedTouches[0].pageY - rect.y,
|
|
119434
119437
|
};
|
|
119435
|
-
|
|
119438
|
+
|
|
119436
119439
|
$(document).on("touchmove", this.#onTouchMove);
|
|
119437
119440
|
};
|
|
119438
|
-
|
|
119441
|
+
|
|
119439
119442
|
#onTouchMove = e => {
|
|
119440
119443
|
$(this.querySelector('dialog')).offset( { left : e.changedTouches[0].pageX - this.#shift.x, top : e.changedTouches[0].pageY - this.#shift.y });
|
|
119441
119444
|
};
|
|
119442
|
-
|
|
119445
|
+
|
|
119443
119446
|
#onTouchEnd = e => {
|
|
119444
119447
|
$(document).off('touchmove', this.#onTouchMove);
|
|
119445
119448
|
};
|
package/dist/etc/nxDialog.js
CHANGED
|
@@ -4,18 +4,18 @@ class nxDialog extends HTMLElement
|
|
|
4
4
|
{
|
|
5
5
|
//#owner;
|
|
6
6
|
#shift;
|
|
7
|
-
|
|
7
|
+
|
|
8
8
|
constructor () {
|
|
9
9
|
super();
|
|
10
10
|
}
|
|
11
|
-
|
|
11
|
+
|
|
12
12
|
connectedCallback() {
|
|
13
13
|
|
|
14
14
|
const v = this.innerHTML;
|
|
15
15
|
const cssFile = this.getAttribute("css-file");
|
|
16
16
|
const customFile1 = cssFile ? `@import "https://cdn.jsdelivr.net/npm/ninegrid@${ninegrid.version}/dist/css/${cssFile}";`: "";
|
|
17
17
|
const customFile2 = cssFile ? ninegrid.getCustomPath(this, cssFile) : "";
|
|
18
|
-
|
|
18
|
+
|
|
19
19
|
//console.log(ninegrid.getCustomPath(this,"nxDialog.css"));
|
|
20
20
|
|
|
21
21
|
this.innerHTML = `
|
|
@@ -55,18 +55,18 @@ class nxDialog extends HTMLElement
|
|
|
55
55
|
</div>
|
|
56
56
|
</dialog>
|
|
57
57
|
`;
|
|
58
|
-
|
|
58
|
+
|
|
59
59
|
//this.#owner = this.getRootNode().host.closest("nine-grid");
|
|
60
|
-
|
|
60
|
+
|
|
61
61
|
$(".title", this).html("Details");
|
|
62
|
-
|
|
62
|
+
|
|
63
63
|
this.#init();
|
|
64
64
|
};
|
|
65
|
-
|
|
65
|
+
|
|
66
66
|
showModal = () => {
|
|
67
67
|
this.querySelector('dialog').showModal();
|
|
68
68
|
};
|
|
69
|
-
|
|
69
|
+
|
|
70
70
|
close = () => {
|
|
71
71
|
$(".head", this) .off('mousedown', this.#onMouseDown);
|
|
72
72
|
$(".head", this) .off('touchstart', this.#onTouchStart);
|
|
@@ -74,29 +74,32 @@ class nxDialog extends HTMLElement
|
|
|
74
74
|
$(document) .off('touchend', this.#onTouchEnd);
|
|
75
75
|
$(document) .off('mousemove', this.#onMouseMove);
|
|
76
76
|
$(document) .off("touchmove", this.#onTouchMove);
|
|
77
|
-
|
|
77
|
+
|
|
78
78
|
this.querySelector('dialog').close();
|
|
79
79
|
};
|
|
80
|
-
|
|
80
|
+
|
|
81
81
|
#init = () => {
|
|
82
82
|
$(".close,.close2", this).on("click", e => {
|
|
83
|
+
this.close();
|
|
84
|
+
/**
|
|
83
85
|
ninegrid.j.querySelectorAll('dialog', this).addClass("out");
|
|
84
86
|
setTimeout(() => { this.close(); }, 300);
|
|
87
|
+
*/
|
|
85
88
|
});
|
|
86
|
-
|
|
89
|
+
|
|
87
90
|
$(".head", this) .on('mousedown', this.#onMouseDown);
|
|
88
91
|
$(".head", this) .on('touchstart', this.#onTouchStart);
|
|
89
92
|
$(document) .on('mouseup', this.#onMouseUp);
|
|
90
93
|
$(document) .on('touchend', this.#onTouchEnd);
|
|
91
94
|
};
|
|
92
|
-
|
|
95
|
+
|
|
93
96
|
|
|
94
97
|
#onMouseDown = e => {
|
|
95
98
|
if (e.target.closest("buttons")) return;
|
|
96
99
|
if (e.buttons != 1 || e.altKey || e.ctrlKey || e.shiftkey) return;
|
|
97
100
|
|
|
98
101
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
99
|
-
|
|
102
|
+
|
|
100
103
|
this.#shift = {
|
|
101
104
|
x : e.clientX - rect.x,
|
|
102
105
|
y : e.clientY - rect.y,
|
|
@@ -104,33 +107,33 @@ class nxDialog extends HTMLElement
|
|
|
104
107
|
|
|
105
108
|
$(document).on('mousemove', this.#onMouseMove);
|
|
106
109
|
};
|
|
107
|
-
|
|
108
|
-
|
|
110
|
+
|
|
111
|
+
|
|
109
112
|
#onMouseMove = e => {
|
|
110
113
|
$(this.querySelector('dialog')).offset( { left : e.pageX - this.#shift.x, top : e.pageY - this.#shift.y });
|
|
111
114
|
};
|
|
112
|
-
|
|
115
|
+
|
|
113
116
|
#onMouseUp = e => {
|
|
114
117
|
$(document).off('mousemove', this.#onMouseMove);
|
|
115
118
|
};
|
|
116
|
-
|
|
119
|
+
|
|
117
120
|
#onTouchStart = e => {
|
|
118
121
|
if (e.target.closest("buttons")) return;
|
|
119
|
-
|
|
122
|
+
|
|
120
123
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
121
|
-
|
|
124
|
+
|
|
122
125
|
this.#shift = {
|
|
123
126
|
x : e.changedTouches[0].pageX - rect.x,
|
|
124
127
|
y : e.changedTouches[0].pageY - rect.y,
|
|
125
128
|
}
|
|
126
|
-
|
|
129
|
+
|
|
127
130
|
$(document).on("touchmove", this.#onTouchMove);
|
|
128
131
|
};
|
|
129
|
-
|
|
132
|
+
|
|
130
133
|
#onTouchMove = e => {
|
|
131
134
|
$(this.querySelector('dialog')).offset( { left : e.changedTouches[0].pageX - this.#shift.x, top : e.changedTouches[0].pageY - this.#shift.y });
|
|
132
135
|
};
|
|
133
|
-
|
|
136
|
+
|
|
134
137
|
#onTouchEnd = e => {
|
|
135
138
|
$(document).off('touchmove', this.#onTouchMove);
|
|
136
139
|
};
|
package/package.json
CHANGED
package/src/etc/nxDialog.js
CHANGED
|
@@ -4,18 +4,18 @@ class nxDialog extends HTMLElement
|
|
|
4
4
|
{
|
|
5
5
|
//#owner;
|
|
6
6
|
#shift;
|
|
7
|
-
|
|
7
|
+
|
|
8
8
|
constructor () {
|
|
9
9
|
super();
|
|
10
10
|
}
|
|
11
|
-
|
|
11
|
+
|
|
12
12
|
connectedCallback() {
|
|
13
13
|
|
|
14
14
|
const v = this.innerHTML;
|
|
15
15
|
const cssFile = this.getAttribute("css-file");
|
|
16
16
|
const customFile1 = cssFile ? `@import "https://cdn.jsdelivr.net/npm/ninegrid@${ninegrid.version}/dist/css/${cssFile}";`: "";
|
|
17
17
|
const customFile2 = cssFile ? ninegrid.getCustomPath(this, cssFile) : "";
|
|
18
|
-
|
|
18
|
+
|
|
19
19
|
//console.log(ninegrid.getCustomPath(this,"nxDialog.css"));
|
|
20
20
|
|
|
21
21
|
this.innerHTML = `
|
|
@@ -55,18 +55,18 @@ class nxDialog extends HTMLElement
|
|
|
55
55
|
</div>
|
|
56
56
|
</dialog>
|
|
57
57
|
`;
|
|
58
|
-
|
|
58
|
+
|
|
59
59
|
//this.#owner = this.getRootNode().host.closest("nine-grid");
|
|
60
|
-
|
|
60
|
+
|
|
61
61
|
$(".title", this).html("Details");
|
|
62
|
-
|
|
62
|
+
|
|
63
63
|
this.#init();
|
|
64
64
|
};
|
|
65
|
-
|
|
65
|
+
|
|
66
66
|
showModal = () => {
|
|
67
67
|
this.querySelector('dialog').showModal();
|
|
68
68
|
};
|
|
69
|
-
|
|
69
|
+
|
|
70
70
|
close = () => {
|
|
71
71
|
$(".head", this) .off('mousedown', this.#onMouseDown);
|
|
72
72
|
$(".head", this) .off('touchstart', this.#onTouchStart);
|
|
@@ -74,29 +74,32 @@ class nxDialog extends HTMLElement
|
|
|
74
74
|
$(document) .off('touchend', this.#onTouchEnd);
|
|
75
75
|
$(document) .off('mousemove', this.#onMouseMove);
|
|
76
76
|
$(document) .off("touchmove", this.#onTouchMove);
|
|
77
|
-
|
|
77
|
+
|
|
78
78
|
this.querySelector('dialog').close();
|
|
79
79
|
};
|
|
80
|
-
|
|
80
|
+
|
|
81
81
|
#init = () => {
|
|
82
82
|
$(".close,.close2", this).on("click", e => {
|
|
83
|
+
this.close();
|
|
84
|
+
/**
|
|
83
85
|
ninegrid.j.querySelectorAll('dialog', this).addClass("out");
|
|
84
86
|
setTimeout(() => { this.close(); }, 300);
|
|
87
|
+
*/
|
|
85
88
|
});
|
|
86
|
-
|
|
89
|
+
|
|
87
90
|
$(".head", this) .on('mousedown', this.#onMouseDown);
|
|
88
91
|
$(".head", this) .on('touchstart', this.#onTouchStart);
|
|
89
92
|
$(document) .on('mouseup', this.#onMouseUp);
|
|
90
93
|
$(document) .on('touchend', this.#onTouchEnd);
|
|
91
94
|
};
|
|
92
|
-
|
|
95
|
+
|
|
93
96
|
|
|
94
97
|
#onMouseDown = e => {
|
|
95
98
|
if (e.target.closest("buttons")) return;
|
|
96
99
|
if (e.buttons != 1 || e.altKey || e.ctrlKey || e.shiftkey) return;
|
|
97
100
|
|
|
98
101
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
99
|
-
|
|
102
|
+
|
|
100
103
|
this.#shift = {
|
|
101
104
|
x : e.clientX - rect.x,
|
|
102
105
|
y : e.clientY - rect.y,
|
|
@@ -104,33 +107,33 @@ class nxDialog extends HTMLElement
|
|
|
104
107
|
|
|
105
108
|
$(document).on('mousemove', this.#onMouseMove);
|
|
106
109
|
};
|
|
107
|
-
|
|
108
|
-
|
|
110
|
+
|
|
111
|
+
|
|
109
112
|
#onMouseMove = e => {
|
|
110
113
|
$(this.querySelector('dialog')).offset( { left : e.pageX - this.#shift.x, top : e.pageY - this.#shift.y });
|
|
111
114
|
};
|
|
112
|
-
|
|
115
|
+
|
|
113
116
|
#onMouseUp = e => {
|
|
114
117
|
$(document).off('mousemove', this.#onMouseMove);
|
|
115
118
|
};
|
|
116
|
-
|
|
119
|
+
|
|
117
120
|
#onTouchStart = e => {
|
|
118
121
|
if (e.target.closest("buttons")) return;
|
|
119
|
-
|
|
122
|
+
|
|
120
123
|
var rect = this.querySelector('dialog').getBoundingClientRect();
|
|
121
|
-
|
|
124
|
+
|
|
122
125
|
this.#shift = {
|
|
123
126
|
x : e.changedTouches[0].pageX - rect.x,
|
|
124
127
|
y : e.changedTouches[0].pageY - rect.y,
|
|
125
128
|
}
|
|
126
|
-
|
|
129
|
+
|
|
127
130
|
$(document).on("touchmove", this.#onTouchMove);
|
|
128
131
|
};
|
|
129
|
-
|
|
132
|
+
|
|
130
133
|
#onTouchMove = e => {
|
|
131
134
|
$(this.querySelector('dialog')).offset( { left : e.changedTouches[0].pageX - this.#shift.x, top : e.changedTouches[0].pageY - this.#shift.y });
|
|
132
135
|
};
|
|
133
|
-
|
|
136
|
+
|
|
134
137
|
#onTouchEnd = e => {
|
|
135
138
|
$(document).off('touchmove', this.#onTouchMove);
|
|
136
139
|
};
|