clickgo 3.1.2-dev11 → 3.1.4-dev13

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.
Files changed (110) hide show
  1. package/README.md +1 -1
  2. package/dist/app/demo/app.js +0 -73
  3. package/dist/app/demo/config.json +113 -0
  4. package/dist/app/demo/form/control/button/button.js +12 -11
  5. package/dist/app/demo/form/control/button/button.xml +6 -6
  6. package/dist/app/demo/form/control/check/check.js +14 -10
  7. package/dist/app/demo/form/control/file/file.js +15 -13
  8. package/dist/app/demo/form/control/{overflow/overflow.css → flow/flow.css} +0 -0
  9. package/dist/app/demo/form/control/flow/flow.js +64 -0
  10. package/dist/app/demo/form/control/{overflow/overflow.scss → flow/flow.scss} +0 -0
  11. package/dist/app/demo/form/control/flow/flow.xml +101 -0
  12. package/dist/app/demo/form/control/form/form.js +1 -1
  13. package/dist/app/demo/form/control/form/form.xml +3 -3
  14. package/dist/app/demo/form/control/img/img.xml +2 -2
  15. package/dist/app/demo/form/control/list/list.js +95 -75
  16. package/dist/app/demo/form/control/list/list.xml +15 -11
  17. package/dist/app/demo/form/control/marquee/marquee.js +12 -10
  18. package/dist/app/demo/form/control/menu/menu.js +10 -6
  19. package/dist/app/demo/form/control/monaco/monaco.js +50 -60
  20. package/dist/app/demo/form/control/monaco/monaco.xml +6 -5
  21. package/dist/app/demo/form/control/property/property.js +131 -127
  22. package/dist/app/demo/form/control/radio/radio.js +9 -5
  23. package/dist/app/demo/form/control/scroll/scroll.js +16 -12
  24. package/dist/app/demo/form/control/scroll/scroll.xml +10 -10
  25. package/dist/app/demo/form/control/select/select.js +132 -71
  26. package/dist/app/demo/form/control/select/select.xml +69 -67
  27. package/dist/app/demo/form/control/tab/tab.js +21 -20
  28. package/dist/app/demo/form/control/tab/tab.xml +2 -2
  29. package/dist/app/demo/form/control/text/text.js +53 -45
  30. package/dist/app/demo/form/control/text/text.xml +3 -3
  31. package/dist/app/demo/form/control/{greatview/greatview.css → vflow/vflow.css} +0 -0
  32. package/dist/app/demo/form/control/vflow/vflow.js +79 -0
  33. package/dist/app/demo/form/control/{greatview/greatview.scss → vflow/vflow.scss} +0 -0
  34. package/dist/app/demo/form/control/{greatview/greatview.xml → vflow/vflow.xml} +25 -25
  35. package/dist/app/demo/form/event/form/form.js +58 -56
  36. package/dist/app/demo/form/event/form/form.xml +3 -3
  37. package/dist/app/demo/form/event/other/other.js +29 -0
  38. package/dist/app/demo/form/event/other/other.xml +5 -0
  39. package/dist/app/demo/form/event/screen/screen.js +30 -28
  40. package/dist/app/demo/form/event/screen/screen.xml +2 -2
  41. package/dist/app/demo/form/event/task/task.js +31 -31
  42. package/dist/app/demo/form/event/task/task.xml +3 -3
  43. package/dist/app/demo/form/main.js +166 -5
  44. package/dist/app/demo/form/main.xml +37 -35
  45. package/dist/app/demo/form/method/aform/aform.js +2 -1
  46. package/dist/app/demo/form/method/aform/aform.xml +3 -2
  47. package/dist/app/demo/form/method/aform/sd.js +28 -0
  48. package/dist/app/demo/form/method/aform/sd.xml +7 -0
  49. package/dist/app/demo/form/method/aform/test.xml +4 -5
  50. package/dist/app/demo/form/method/core/core.js +23 -8
  51. package/dist/app/demo/form/method/core/core.xml +6 -1
  52. package/dist/app/demo/form/method/dom/dom.js +91 -99
  53. package/dist/app/demo/form/method/dom/dom.xml +6 -7
  54. package/dist/app/demo/form/method/form/form.js +8 -8
  55. package/dist/app/demo/form/method/form/form.xml +4 -4
  56. package/dist/app/demo/form/method/fs/fs.js +34 -33
  57. package/dist/app/demo/form/method/fs/fs.xml +1 -1
  58. package/dist/app/demo/form/method/fs/text.js +12 -12
  59. package/dist/app/demo/form/method/native/native.js +50 -0
  60. package/dist/app/demo/form/method/native/native.xml +12 -0
  61. package/dist/app/demo/form/method/system/system.js +50 -0
  62. package/dist/app/demo/form/method/system/system.xml +11 -0
  63. package/dist/app/demo/form/method/task/task.js +68 -62
  64. package/dist/app/demo/form/method/task/task.xml +5 -6
  65. package/dist/app/demo/form/method/theme/theme.js +14 -14
  66. package/dist/app/demo/form/method/tool/tool.js +29 -28
  67. package/dist/app/demo/form/method/tool/tool.xml +3 -3
  68. package/dist/app/demo/form/method/zip/zip.js +46 -41
  69. package/dist/app/demo/form/method/zip/zip.xml +1 -1
  70. package/dist/app/task/app.js +0 -25
  71. package/dist/app/task/config.json +29 -0
  72. package/dist/app/task/form/bar/bar.js +1 -1
  73. package/dist/app/task/form/bar/bar.xml +1 -1
  74. package/dist/clickgo.js +1 -1
  75. package/dist/clickgo.ts +1 -1
  76. package/dist/control/common.cgc +0 -0
  77. package/dist/control/form.cgc +0 -0
  78. package/dist/control/monaco.cgc +0 -0
  79. package/dist/control/property.cgc +0 -0
  80. package/dist/control/task.cgc +0 -0
  81. package/dist/global.css +1 -1
  82. package/dist/index.js +6 -3
  83. package/dist/index.ts +9 -3
  84. package/dist/lib/control.js +70 -104
  85. package/dist/lib/control.ts +97 -123
  86. package/dist/lib/core.js +163 -253
  87. package/dist/lib/core.ts +185 -268
  88. package/dist/lib/dom.js +565 -484
  89. package/dist/lib/dom.ts +704 -547
  90. package/dist/lib/form.js +211 -159
  91. package/dist/lib/form.ts +196 -121
  92. package/dist/lib/fs.js +107 -12
  93. package/dist/lib/fs.ts +111 -20
  94. package/dist/lib/native.js +142 -8
  95. package/dist/lib/native.ts +181 -11
  96. package/dist/lib/task.js +526 -164
  97. package/dist/lib/task.ts +598 -179
  98. package/dist/lib/tool.js +48 -1
  99. package/dist/lib/tool.ts +61 -0
  100. package/dist/lib/zip.ts +2 -0
  101. package/dist/theme/familiar.cgt +0 -0
  102. package/package.json +2 -2
  103. package/types/index.d.ts +83 -39
  104. package/dist/app/demo/form/control/greatview/greatview.js +0 -92
  105. package/dist/app/demo/form/control/overflow/overflow.js +0 -70
  106. package/dist/app/demo/form/control/overflow/overflow.xml +0 -98
  107. package/dist/app/demo/form/control/view/view.css +0 -1
  108. package/dist/app/demo/form/control/view/view.js +0 -73
  109. package/dist/app/demo/form/control/view/view.scss +0 -18
  110. package/dist/app/demo/form/control/view/view.xml +0 -94
package/dist/lib/form.js CHANGED
@@ -9,7 +9,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
9
9
  });
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.hideLauncher = exports.showLauncher = exports.flash = exports.confirm = exports.dialog = exports.create = exports.remove = exports.doFocusAndPopEvent = exports.hidePop = exports.showPop = exports.removeFromPop = exports.appendToPop = exports.hideNotify = exports.notifyProgress = exports.notify = exports.hideDrag = exports.moveDrag = exports.showDrag = exports.hideRectangle = exports.showRectangle = exports.moveRectangle = exports.showCircular = exports.getRectByBorder = exports.getMaxZIndexID = exports.changeFocus = exports.getList = exports.send = exports.get = exports.getTaskId = exports.refreshMaxPosition = exports.bindDrag = exports.bindResize = exports.close = exports.max = exports.min = exports.launcherRoot = exports.simpleSystemTaskRoot = exports.AbstractForm = void 0;
12
+ exports.hideLauncher = exports.showLauncher = exports.flash = exports.confirm = exports.dialog = exports.create = exports.remove = exports.doFocusAndPopEvent = exports.hidePop = exports.showPop = exports.removeFromPop = exports.appendToPop = exports.hideNotify = exports.notifyProgress = exports.notify = exports.hideDrag = exports.moveDrag = exports.showDrag = exports.hideRectangle = exports.showRectangle = exports.moveRectangle = exports.showCircular = exports.getRectByBorder = exports.getMaxZIndexID = exports.changeFocus = exports.getFocus = exports.getList = exports.send = exports.get = exports.getTaskId = exports.refreshMaxPosition = exports.bindDrag = exports.bindResize = exports.close = exports.max = exports.min = exports.superConfirm = exports.elements = exports.launcherRoot = exports.simpleSystemTaskRoot = exports.AbstractForm = void 0;
13
13
  const clickgo = require("../clickgo");
14
14
  const core = require("./core");
15
15
  const task = require("./task");
@@ -18,6 +18,7 @@ const dom = require("./dom");
18
18
  const control = require("./control");
19
19
  const fs = require("./fs");
20
20
  const native = require("./native");
21
+ let focusId = null;
21
22
  const info = {
22
23
  'lastId': 0,
23
24
  'lastZIndex': 999,
@@ -55,6 +56,7 @@ const info = {
55
56
  };
56
57
  class AbstractForm {
57
58
  constructor() {
59
+ this.isNativeSync = false;
58
60
  this._firstShow = true;
59
61
  this.dialogResult = '';
60
62
  }
@@ -96,6 +98,9 @@ class AbstractForm {
96
98
  };
97
99
  const cdata = Object.entries(frm);
98
100
  for (const item of cdata) {
101
+ if (item[0] === 'access') {
102
+ continue;
103
+ }
99
104
  code.data[item[0]] = item[1];
100
105
  }
101
106
  if (!layout) {
@@ -174,7 +179,7 @@ class AbstractForm {
174
179
  return (_d = (_b = (_a = task.list[this.taskId].locale.data[this.locale]) === null || _a === void 0 ? void 0 : _a[key]) !== null && _b !== void 0 ? _b : (_c = task.list[this.taskId].locale.data['en']) === null || _c === void 0 ? void 0 : _c[key]) !== null && _d !== void 0 ? _d : 'LocaleError';
175
180
  };
176
181
  }
177
- classPrepend() {
182
+ get classPrepend() {
178
183
  return (cla) => {
179
184
  if (typeof cla !== 'string') {
180
185
  return cla;
@@ -250,9 +255,9 @@ class AbstractForm {
250
255
  }
251
256
  showDialog() {
252
257
  return __awaiter(this, void 0, void 0, function* () {
253
- this.topMost = true;
254
- this.show();
255
258
  task.list[this.taskId].runtime.dialogFormIds.push(this.formId);
259
+ this.show();
260
+ this.topMost = true;
256
261
  return new Promise((resolve) => {
257
262
  this.cgDialogCallback = () => {
258
263
  resolve(this.dialogResult);
@@ -264,6 +269,9 @@ class AbstractForm {
264
269
  const v = this;
265
270
  v.$refs.form.$data.isShow = false;
266
271
  }
272
+ close() {
273
+ close(this.formId);
274
+ }
267
275
  onBeforeCreate() {
268
276
  return;
269
277
  }
@@ -336,6 +344,9 @@ class AbstractForm {
336
344
  onLauncherFolderNameChanged() {
337
345
  return;
338
346
  }
347
+ onHashChanged() {
348
+ return;
349
+ }
339
350
  }
340
351
  exports.AbstractForm = AbstractForm;
341
352
  const popInfo = {
@@ -343,7 +354,8 @@ const popInfo = {
343
354
  'elList': [],
344
355
  'lastZIndex': 0
345
356
  };
346
- const elements = {
357
+ let superConfirmHandler = undefined;
358
+ exports.elements = {
347
359
  'wrap': document.createElement('div'),
348
360
  'list': document.createElement('div'),
349
361
  'popList': document.createElement('div'),
@@ -351,48 +363,40 @@ const elements = {
351
363
  'rectangle': document.createElement('div'),
352
364
  'gesture': document.createElement('div'),
353
365
  'drag': document.createElement('div'),
354
- 'dragIcon': undefined,
355
- 'system': document.createElement('div'),
356
- 'simpleSystemtask': document.createElement('div'),
366
+ 'notify': document.createElement('div'),
367
+ 'simpletask': document.createElement('div'),
357
368
  'launcher': document.createElement('div'),
369
+ 'confirm': document.createElement('div'),
358
370
  'init': function () {
359
371
  this.wrap.id = 'cg-wrap';
360
372
  document.getElementsByTagName('body')[0].appendChild(this.wrap);
361
- if (clickgo.isImmersion()) {
362
- this.wrap.addEventListener('mouseenter', function () {
363
- native.invoke('cg-mouse-ignore', native.getToken(), false);
364
- });
365
- this.wrap.addEventListener('mouseleave', function () {
366
- native.invoke('cg-mouse-ignore', native.getToken(), true);
367
- });
368
- }
369
- this.list.id = 'cg-form-list';
370
- this.wrap.appendChild(this.list);
371
- this.list.addEventListener('touchmove', function (e) {
373
+ this.wrap.addEventListener('touchmove', function (e) {
372
374
  if (e.cancelable) {
373
375
  e.preventDefault();
374
376
  }
375
377
  }, {
376
378
  'passive': false
377
379
  });
378
- this.list.addEventListener('wheel', function (e) {
380
+ this.wrap.addEventListener('wheel', function (e) {
379
381
  e.preventDefault();
380
382
  }, {
381
383
  'passive': false
382
384
  });
383
- this.list.addEventListener('contextmenu', function (e) {
385
+ this.wrap.addEventListener('contextmenu', function (e) {
384
386
  e.preventDefault();
385
387
  });
388
+ if (clickgo.isImmersion()) {
389
+ this.wrap.addEventListener('mouseenter', function () {
390
+ native.invoke('cg-mouse-ignore', native.getToken(), false);
391
+ });
392
+ this.wrap.addEventListener('mouseleave', function () {
393
+ native.invoke('cg-mouse-ignore', native.getToken(), true);
394
+ });
395
+ }
396
+ this.list.id = 'cg-form-list';
397
+ this.wrap.appendChild(this.list);
386
398
  this.popList.id = 'cg-pop-list';
387
- this.popList.addEventListener('contextmenu', function (e) {
388
- e.preventDefault();
389
- });
390
399
  this.wrap.appendChild(this.popList);
391
- this.popList.addEventListener('touchmove', function (e) {
392
- e.preventDefault();
393
- }, {
394
- 'passive': false
395
- });
396
400
  this.circular.id = 'cg-circular';
397
401
  this.wrap.appendChild(this.circular);
398
402
  this.rectangle.setAttribute('data-pos', '');
@@ -402,28 +406,11 @@ const elements = {
402
406
  this.wrap.appendChild(this.gesture);
403
407
  this.drag.id = 'cg-drag';
404
408
  this.drag.innerHTML = '<svg width="16" height="16" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M8 8L40 40" stroke="#FFF" stroke-width="4" stroke-linecap="butt" stroke-linejoin="miter"/><path d="M8 40L40 8" stroke="#FFF" stroke-width="4" stroke-linecap="butt" stroke-linejoin="miter"/></svg>';
405
- this.dragIcon = this.drag.childNodes[0];
406
409
  this.wrap.appendChild(this.drag);
407
- this.system.id = 'cg-system';
408
- this.system.addEventListener('contextmenu', function (e) {
409
- e.preventDefault();
410
- });
411
- this.wrap.appendChild(this.system);
412
- this.system.addEventListener('touchmove', function (e) {
413
- e.preventDefault();
414
- }, {
415
- 'passive': false
416
- });
417
- this.simpleSystemtask.id = 'cg-simpletask';
418
- this.simpleSystemtask.addEventListener('contextmenu', function (e) {
419
- e.preventDefault();
420
- });
421
- this.wrap.appendChild(this.simpleSystemtask);
422
- this.simpleSystemtask.addEventListener('touchmove', function (e) {
423
- e.preventDefault();
424
- }, {
425
- 'passive': false
426
- });
410
+ this.notify.id = 'cg-notify';
411
+ this.wrap.appendChild(this.notify);
412
+ this.simpletask.id = 'cg-simpletask';
413
+ this.wrap.appendChild(this.simpletask);
427
414
  const simpletaskApp = clickgo.vue.createApp({
428
415
  'template': '<div v-for="(item, formId) of forms" class="cg-simpletask-item" @click="click(parseInt(formId))"><div v-if="item.icon" class="cg-simpletask-icon" :style="{\'background-image\': \'url(\' + item.icon + \')\'}"></div><div>{{item.title}}</div></div>',
429
416
  'data': function () {
@@ -436,14 +423,14 @@ const elements = {
436
423
  handler: function () {
437
424
  const length = Object.keys(this.forms).length;
438
425
  if (length > 0) {
439
- if (elements.simpleSystemtask.style.bottom !== '0px') {
440
- elements.simpleSystemtask.style.bottom = '0px';
426
+ if (exports.elements.simpletask.style.bottom !== '0px') {
427
+ exports.elements.simpletask.style.bottom = '0px';
441
428
  core.trigger('screenResize');
442
429
  }
443
430
  }
444
431
  else {
445
- if (elements.simpleSystemtask.style.bottom === '0px') {
446
- elements.simpleSystemtask.style.bottom = '-46px';
432
+ if (exports.elements.simpletask.style.bottom === '0px') {
433
+ exports.elements.simpletask.style.bottom = '-46px';
447
434
  core.trigger('screenResize');
448
435
  }
449
436
  }
@@ -462,20 +449,12 @@ const elements = {
462
449
  });
463
450
  simpletaskApp.mount('#cg-simpletask');
464
451
  this.launcher.id = 'cg-launcher';
465
- this.launcher.addEventListener('contextmenu', function (e) {
466
- e.preventDefault();
467
- });
468
452
  this.wrap.appendChild(this.launcher);
469
- this.launcher.addEventListener('touchmove', function (e) {
470
- e.preventDefault();
471
- }, {
472
- 'passive': false
473
- });
474
453
  const waiting = function () {
475
454
  if (!core.config) {
476
455
  setTimeout(function () {
477
456
  waiting();
478
- }, 2000);
457
+ }, 150);
479
458
  return;
480
459
  }
481
460
  const launcherApp = clickgo.vue.createApp({
@@ -506,7 +485,8 @@ const elements = {
506
485
  'data': function () {
507
486
  return {
508
487
  'name': '',
509
- 'folderName': ''
488
+ 'folderName': '',
489
+ 'folderItem': {}
510
490
  };
511
491
  },
512
492
  'computed': {
@@ -638,9 +618,53 @@ const elements = {
638
618
  launcherApp.mount('#cg-launcher');
639
619
  };
640
620
  waiting();
621
+ this.confirm.id = 'cg-confirm';
622
+ this.wrap.appendChild(this.confirm);
623
+ this.confirm.innerHTML = `<div class="cg-confirm-box">` +
624
+ `<div id="cg-confirm-content"></div>` +
625
+ `<div class="cg-confirm-controls">` +
626
+ `<div id="cg-confirm-cancel"></div>` +
627
+ `<div id="cg-confirm-ok"></div>` +
628
+ `</div>` +
629
+ `</div>`;
630
+ this.confirm.style.display = 'none';
631
+ document.getElementById('cg-confirm-cancel').addEventListener('click', () => {
632
+ superConfirmHandler === null || superConfirmHandler === void 0 ? void 0 : superConfirmHandler(false);
633
+ this.confirm.style.display = 'none';
634
+ const fid = getMaxZIndexID();
635
+ if (fid) {
636
+ changeFocus(fid);
637
+ }
638
+ });
639
+ document.getElementById('cg-confirm-ok').addEventListener('click', () => {
640
+ superConfirmHandler === null || superConfirmHandler === void 0 ? void 0 : superConfirmHandler(true);
641
+ this.confirm.style.display = 'none';
642
+ const fid = getMaxZIndexID();
643
+ if (fid) {
644
+ changeFocus(fid);
645
+ }
646
+ });
641
647
  }
642
648
  };
643
- elements.init();
649
+ exports.elements.init();
650
+ function superConfirm(html) {
651
+ return new Promise((resolve) => {
652
+ var _a, _b, _c, _d;
653
+ if (superConfirmHandler !== undefined) {
654
+ resolve(false);
655
+ return;
656
+ }
657
+ exports.elements.confirm.style.display = 'flex';
658
+ document.getElementById('cg-confirm-content').innerHTML = html;
659
+ document.getElementById('cg-confirm-cancel').innerHTML = (_b = (_a = info.locale[core.config.locale]) === null || _a === void 0 ? void 0 : _a.cancel) !== null && _b !== void 0 ? _b : info.locale['en'].cancel;
660
+ document.getElementById('cg-confirm-ok').innerHTML = (_d = (_c = info.locale[core.config.locale]) === null || _c === void 0 ? void 0 : _c.ok) !== null && _d !== void 0 ? _d : info.locale['en'].ok;
661
+ superConfirmHandler = (result) => {
662
+ superConfirmHandler = undefined;
663
+ resolve(result);
664
+ };
665
+ });
666
+ }
667
+ exports.superConfirm = superConfirm;
644
668
  function changeState(state, formId) {
645
669
  const tid = getTaskId(formId);
646
670
  const t = task.list[tid];
@@ -712,8 +736,8 @@ function bindDrag(e) {
712
736
  exports.bindDrag = bindDrag;
713
737
  function refreshMaxPosition() {
714
738
  const area = core.getAvailArea();
715
- for (let i = 0; i < elements.list.children.length; ++i) {
716
- const el = elements.list.children.item(i);
739
+ for (let i = 0; i < exports.elements.list.children.length; ++i) {
740
+ const el = exports.elements.list.children.item(i);
717
741
  const ef = el.children.item(0);
718
742
  if (ef.dataset.cgMax === undefined) {
719
743
  continue;
@@ -732,7 +756,7 @@ function refreshMaxPosition() {
732
756
  }
733
757
  exports.refreshMaxPosition = refreshMaxPosition;
734
758
  function getTaskId(formId) {
735
- const formElement = elements.list.querySelector(`[data-form-id='${formId}']`);
759
+ const formElement = exports.elements.list.querySelector(`[data-form-id='${formId}']`);
736
760
  if (!formElement) {
737
761
  return 0;
738
762
  }
@@ -789,8 +813,12 @@ function getList(taskId) {
789
813
  return list;
790
814
  }
791
815
  exports.getList = getList;
816
+ function getFocus() {
817
+ return focusId;
818
+ }
819
+ exports.getFocus = getFocus;
792
820
  function changeFocus(formId = 0) {
793
- var _a, _b;
821
+ var _a;
794
822
  if (typeof formId !== 'number') {
795
823
  notify({
796
824
  'title': 'Warning',
@@ -799,37 +827,31 @@ function changeFocus(formId = 0) {
799
827
  });
800
828
  return;
801
829
  }
802
- const focusElement = document.querySelector('#cg-form-list > [data-form-focus]');
803
- if (focusElement) {
804
- const dataFormId = focusElement.getAttribute('data-form-id');
805
- if (dataFormId) {
806
- const dataFormIdNumber = parseInt(dataFormId);
807
- if (dataFormIdNumber === formId) {
808
- return;
809
- }
810
- else {
811
- const taskId = parseInt((_a = focusElement.getAttribute('data-task-id')) !== null && _a !== void 0 ? _a : '0');
812
- const t = task.list[taskId];
813
- t.forms[dataFormIdNumber].vapp._container.removeAttribute('data-form-focus');
814
- t.forms[dataFormIdNumber].vroot._formFocus = false;
815
- core.trigger('formBlurred', taskId, dataFormIdNumber);
816
- }
830
+ const dataFormId = getFocus();
831
+ if (dataFormId) {
832
+ if (dataFormId === formId) {
833
+ return;
817
834
  }
818
835
  else {
819
- return;
836
+ const t = task.list[task.getFocus()];
837
+ t.forms[dataFormId].vapp._container.removeAttribute('data-form-focus');
838
+ t.forms[dataFormId].vroot._formFocus = false;
839
+ core.trigger('formBlurred', t.id, dataFormId);
820
840
  }
821
841
  }
842
+ focusId = null;
843
+ task.setFocus();
822
844
  if (formId === 0) {
823
845
  return;
824
846
  }
825
- const el = document.querySelector(`#cg-form-list > [data-form-id='${formId}']`);
847
+ const el = exports.elements.list.querySelector(`.cg-form-wrap[data-form-id='${formId}']`);
826
848
  if (!el) {
827
849
  return;
828
850
  }
829
851
  if (el.children.item(0).dataset.cgMin !== undefined) {
830
852
  min(formId);
831
853
  }
832
- const taskId = parseInt((_b = el.getAttribute('data-task-id')) !== null && _b !== void 0 ? _b : '0');
854
+ const taskId = parseInt((_a = el.getAttribute('data-task-id')) !== null && _a !== void 0 ? _a : '0');
833
855
  const t = task.list[taskId];
834
856
  if (t.runtime.dialogFormIds.length) {
835
857
  const dialogFormId = t.runtime.dialogFormIds[t.runtime.dialogFormIds.length - 1];
@@ -844,6 +866,8 @@ function changeFocus(formId = 0) {
844
866
  }
845
867
  t.forms[dialogFormId].vapp._container.dataset.formFocus = '';
846
868
  t.forms[dialogFormId].vroot._formFocus = true;
869
+ focusId = dialogFormId;
870
+ task.setFocus(t.id);
847
871
  core.trigger('formFocused', taskId, dialogFormId);
848
872
  if (dialogFormId !== formId) {
849
873
  clickgo.form.flash(dialogFormId, taskId);
@@ -858,6 +882,8 @@ function changeFocus(formId = 0) {
858
882
  }
859
883
  t.forms[formId].vapp._container.dataset.formFocus = '';
860
884
  t.forms[formId].vroot._formFocus = true;
885
+ focusId = formId;
886
+ task.setFocus(t.id);
861
887
  core.trigger('formFocused', taskId, formId);
862
888
  }
863
889
  }
@@ -866,8 +892,8 @@ function getMaxZIndexID(out = {}) {
866
892
  var _a, _b;
867
893
  let zIndex = 0;
868
894
  let formId = null;
869
- for (let i = 0; i < elements.list.children.length; ++i) {
870
- const formWrap = elements.list.children.item(i);
895
+ for (let i = 0; i < exports.elements.list.children.length; ++i) {
896
+ const formWrap = exports.elements.list.children.item(i);
871
897
  const formInner = formWrap.children.item(0);
872
898
  if (!formInner) {
873
899
  continue;
@@ -977,21 +1003,21 @@ function getRectByBorder(border) {
977
1003
  }
978
1004
  exports.getRectByBorder = getRectByBorder;
979
1005
  function showCircular(x, y) {
980
- elements.circular.style.transition = 'none';
1006
+ exports.elements.circular.style.transition = 'none';
981
1007
  requestAnimationFrame(function () {
982
- elements.circular.style.width = '6px';
983
- elements.circular.style.height = '6px';
984
- elements.circular.style.left = (x - 3).toString() + 'px';
985
- elements.circular.style.top = (y - 3).toString() + 'px';
986
- elements.circular.style.opacity = '1';
1008
+ exports.elements.circular.style.width = '6px';
1009
+ exports.elements.circular.style.height = '6px';
1010
+ exports.elements.circular.style.left = (x - 3).toString() + 'px';
1011
+ exports.elements.circular.style.top = (y - 3).toString() + 'px';
1012
+ exports.elements.circular.style.opacity = '1';
987
1013
  requestAnimationFrame(function () {
988
- elements.circular.style.transition = 'all .3s ease-out';
1014
+ exports.elements.circular.style.transition = 'all .3s ease-out';
989
1015
  requestAnimationFrame(function () {
990
- elements.circular.style.width = '60px';
991
- elements.circular.style.height = '60px';
992
- elements.circular.style.left = (x - 30).toString() + 'px';
993
- elements.circular.style.top = (y - 30).toString() + 'px';
994
- elements.circular.style.opacity = '0';
1016
+ exports.elements.circular.style.width = '60px';
1017
+ exports.elements.circular.style.height = '60px';
1018
+ exports.elements.circular.style.left = (x - 30).toString() + 'px';
1019
+ exports.elements.circular.style.top = (y - 30).toString() + 'px';
1020
+ exports.elements.circular.style.opacity = '0';
995
1021
  });
996
1022
  });
997
1023
  });
@@ -999,43 +1025,43 @@ function showCircular(x, y) {
999
1025
  exports.showCircular = showCircular;
1000
1026
  function moveRectangle(border) {
1001
1027
  var _a, _b, _c, _d;
1002
- const dataReady = (_a = elements.rectangle.getAttribute('data-ready')) !== null && _a !== void 0 ? _a : '0';
1028
+ const dataReady = (_a = exports.elements.rectangle.getAttribute('data-ready')) !== null && _a !== void 0 ? _a : '0';
1003
1029
  if (dataReady === '0') {
1004
1030
  return;
1005
1031
  }
1006
- const dataBorder = (_b = elements.rectangle.getAttribute('data-border')) !== null && _b !== void 0 ? _b : '';
1032
+ const dataBorder = (_b = exports.elements.rectangle.getAttribute('data-border')) !== null && _b !== void 0 ? _b : '';
1007
1033
  const setDataBorder = typeof border === 'string' ? border : `o-${border.left}-${(_c = border.top) !== null && _c !== void 0 ? _c : 'n'}-${border.width}-${(_d = border.height) !== null && _d !== void 0 ? _d : 'n'}`;
1008
1034
  if (dataBorder === setDataBorder) {
1009
1035
  return;
1010
1036
  }
1011
- elements.rectangle.setAttribute('data-dir', setDataBorder);
1037
+ exports.elements.rectangle.setAttribute('data-dir', setDataBorder);
1012
1038
  const pos = getRectByBorder(border);
1013
1039
  const width = pos.width - 20;
1014
1040
  const height = pos.height - 20;
1015
1041
  const left = pos.left + 10;
1016
1042
  const top = pos.top + 10;
1017
1043
  if (width !== undefined && height !== undefined && left !== undefined && top !== undefined) {
1018
- elements.rectangle.style.width = width.toString() + 'px';
1019
- elements.rectangle.style.height = height.toString() + 'px';
1020
- elements.rectangle.style.left = left.toString() + 'px';
1021
- elements.rectangle.style.top = top.toString() + 'px';
1044
+ exports.elements.rectangle.style.width = width.toString() + 'px';
1045
+ exports.elements.rectangle.style.height = height.toString() + 'px';
1046
+ exports.elements.rectangle.style.left = left.toString() + 'px';
1047
+ exports.elements.rectangle.style.top = top.toString() + 'px';
1022
1048
  }
1023
1049
  }
1024
1050
  exports.moveRectangle = moveRectangle;
1025
1051
  function showRectangle(x, y, border) {
1026
- elements.rectangle.style.transition = 'none';
1052
+ exports.elements.rectangle.style.transition = 'none';
1027
1053
  requestAnimationFrame(function () {
1028
- elements.rectangle.style.width = '5px';
1029
- elements.rectangle.style.height = '5px';
1030
- elements.rectangle.style.left = (x - 10).toString() + 'px';
1031
- elements.rectangle.style.top = (y - 10).toString() + 'px';
1032
- elements.rectangle.style.opacity = '1';
1033
- elements.rectangle.setAttribute('data-ready', '0');
1034
- elements.rectangle.setAttribute('data-dir', '');
1054
+ exports.elements.rectangle.style.width = '5px';
1055
+ exports.elements.rectangle.style.height = '5px';
1056
+ exports.elements.rectangle.style.left = (x - 10).toString() + 'px';
1057
+ exports.elements.rectangle.style.top = (y - 10).toString() + 'px';
1058
+ exports.elements.rectangle.style.opacity = '1';
1059
+ exports.elements.rectangle.setAttribute('data-ready', '0');
1060
+ exports.elements.rectangle.setAttribute('data-dir', '');
1035
1061
  requestAnimationFrame(function () {
1036
- elements.rectangle.style.transition = 'all .2s ease-out';
1062
+ exports.elements.rectangle.style.transition = 'all .2s ease-out';
1037
1063
  requestAnimationFrame(function () {
1038
- elements.rectangle.setAttribute('data-ready', '1');
1064
+ exports.elements.rectangle.setAttribute('data-ready', '1');
1039
1065
  moveRectangle(border);
1040
1066
  });
1041
1067
  });
@@ -1043,40 +1069,36 @@ function showRectangle(x, y, border) {
1043
1069
  }
1044
1070
  exports.showRectangle = showRectangle;
1045
1071
  function hideRectangle() {
1046
- elements.rectangle.style.opacity = '0';
1072
+ exports.elements.rectangle.style.opacity = '0';
1047
1073
  }
1048
1074
  exports.hideRectangle = hideRectangle;
1049
1075
  function showDrag() {
1050
- elements.drag.style.opacity = '1';
1076
+ exports.elements.drag.style.opacity = '1';
1051
1077
  }
1052
1078
  exports.showDrag = showDrag;
1053
1079
  function moveDrag(opt) {
1054
1080
  if (opt.top) {
1055
- elements.drag.style.top = opt.top.toString() + 'px';
1081
+ exports.elements.drag.style.top = opt.top.toString() + 'px';
1056
1082
  }
1057
1083
  if (opt.left) {
1058
- elements.drag.style.left = opt.left.toString() + 'px';
1084
+ exports.elements.drag.style.left = opt.left.toString() + 'px';
1059
1085
  }
1060
1086
  if (opt.width) {
1061
- elements.drag.style.width = opt.width.toString() + 'px';
1087
+ exports.elements.drag.style.width = opt.width.toString() + 'px';
1062
1088
  }
1063
1089
  if (opt.height) {
1064
- elements.drag.style.height = opt.height.toString() + 'px';
1090
+ exports.elements.drag.style.height = opt.height.toString() + 'px';
1065
1091
  }
1066
1092
  if (opt.icon) {
1067
- if (elements.dragIcon) {
1068
- elements.dragIcon.style.display = 'block';
1069
- }
1093
+ exports.elements.drag.childNodes[0].style.display = 'block';
1070
1094
  }
1071
1095
  else {
1072
- if (elements.dragIcon) {
1073
- elements.dragIcon.style.display = 'none';
1074
- }
1096
+ exports.elements.drag.childNodes[0].style.display = 'none';
1075
1097
  }
1076
1098
  }
1077
1099
  exports.moveDrag = moveDrag;
1078
1100
  function hideDrag() {
1079
- elements.drag.style.opacity = '0';
1101
+ exports.elements.drag.style.opacity = '0';
1080
1102
  }
1081
1103
  exports.hideDrag = hideDrag;
1082
1104
  let notifyTop = 10;
@@ -1098,21 +1120,21 @@ function notify(opt) {
1098
1120
  }
1099
1121
  const el = document.createElement('div');
1100
1122
  const y = notifyTop;
1101
- el.classList.add('cg-system-notify');
1123
+ el.classList.add('cg-notify-wrap');
1102
1124
  el.setAttribute('data-notifyid', nid.toString());
1103
1125
  el.style.transform = `translateY(${y}px) translateX(280px)`;
1104
1126
  el.style.opacity = '1';
1105
- el.innerHTML = `<div class="cg-system-icon cg-${tool.escapeHTML((_a = opt.type) !== null && _a !== void 0 ? _a : 'primary')}"></div>
1127
+ el.innerHTML = `<div class="cg-notify-icon cg-${tool.escapeHTML((_a = opt.type) !== null && _a !== void 0 ? _a : 'primary')}"></div>
1106
1128
  <div style="flex: 1;">
1107
- <div class="cg-system-notify-title">${tool.escapeHTML(opt.title)}</div>
1108
- <div class="cg-system-notify-content">${tool.escapeHTML(opt.content).replace(/\r\n/g, '\n').replace(/\r/g, '\n').replace(/\n/g, '<br>')}</div>
1109
- ${opt.progress ? '<div class="cg-system-notify-progress"></div>' : ''}
1129
+ <div class="cg-notify-title">${tool.escapeHTML(opt.title)}</div>
1130
+ <div class="cg-notify-content">${tool.escapeHTML(opt.content).replace(/\r\n/g, '\n').replace(/\r/g, '\n').replace(/\n/g, '<br>')}</div>
1131
+ ${opt.progress ? '<div class="cg-notify-progress"></div>' : ''}
1110
1132
  </div>`;
1111
1133
  if (opt.icon) {
1112
1134
  el.childNodes.item(0).style.background = 'url(' + opt.icon + ')';
1113
1135
  el.childNodes.item(0).style.backgroundSize = '16px';
1114
1136
  }
1115
- elements.system.appendChild(el);
1137
+ exports.elements.notify.appendChild(el);
1116
1138
  notifyTop += el.offsetHeight + 10;
1117
1139
  requestAnimationFrame(function () {
1118
1140
  el.style.transform = `translateY(${y}px) translateX(-10px)`;
@@ -1125,11 +1147,11 @@ function notify(opt) {
1125
1147
  }
1126
1148
  exports.notify = notify;
1127
1149
  function notifyProgress(notifyId, per) {
1128
- const el = elements.system.querySelector(`[data-notifyid="${notifyId}"]`);
1150
+ const el = exports.elements.notify.querySelector(`[data-notifyid="${notifyId}"]`);
1129
1151
  if (!el) {
1130
1152
  return;
1131
1153
  }
1132
- const progress = el.querySelector('.cg-system-notify-progress');
1154
+ const progress = el.querySelector('.cg-notify-progress');
1133
1155
  if (!progress) {
1134
1156
  return;
1135
1157
  }
@@ -1149,7 +1171,7 @@ function notifyProgress(notifyId, per) {
1149
1171
  }
1150
1172
  exports.notifyProgress = notifyProgress;
1151
1173
  function hideNotify(notifyId) {
1152
- const el = elements.system.querySelector(`[data-notifyid="${notifyId}"]`);
1174
+ const el = exports.elements.notify.querySelector(`[data-notifyid="${notifyId}"]`);
1153
1175
  if (!el) {
1154
1176
  return;
1155
1177
  }
@@ -1158,7 +1180,7 @@ function hideNotify(notifyId) {
1158
1180
  el.style.opacity = '0';
1159
1181
  setTimeout(function () {
1160
1182
  notifyTop -= notifyHeight + 10;
1161
- const notifyElementList = document.getElementsByClassName('cg-system-notify');
1183
+ const notifyElementList = document.getElementsByClassName('cg-notify-wrap');
1162
1184
  let needSub = false;
1163
1185
  for (const notifyElement of notifyElementList) {
1164
1186
  if (notifyElement === el) {
@@ -1176,11 +1198,11 @@ function hideNotify(notifyId) {
1176
1198
  }
1177
1199
  exports.hideNotify = hideNotify;
1178
1200
  function appendToPop(el) {
1179
- elements.popList.appendChild(el);
1201
+ exports.elements.popList.appendChild(el);
1180
1202
  }
1181
1203
  exports.appendToPop = appendToPop;
1182
1204
  function removeFromPop(el) {
1183
- elements.popList.removeChild(el);
1205
+ exports.elements.popList.removeChild(el);
1184
1206
  }
1185
1207
  exports.removeFromPop = removeFromPop;
1186
1208
  let lastShowPopTime = 0;
@@ -1407,6 +1429,7 @@ function remove(formId) {
1407
1429
  }
1408
1430
  task.list[taskId].forms[formId].vroot.$refs.form.$data.isShow = false;
1409
1431
  setTimeout(function () {
1432
+ var _a;
1410
1433
  const fid = getMaxZIndexID({
1411
1434
  'formIds': [formId]
1412
1435
  });
@@ -1421,12 +1444,16 @@ function remove(formId) {
1421
1444
  }
1422
1445
  task.list[taskId].forms[formId].vapp.unmount();
1423
1446
  task.list[taskId].forms[formId].vapp._container.remove();
1447
+ (_a = exports.elements.popList.querySelector('[data-form-id="' + formId.toString() + '"]')) === null || _a === void 0 ? void 0 : _a.remove();
1424
1448
  if (io > -1) {
1425
1449
  task.list[taskId].forms[formId].vroot.cgDialogCallback();
1426
1450
  }
1427
1451
  delete task.list[taskId].forms[formId];
1428
1452
  dom.removeStyle(taskId, 'form', formId);
1429
1453
  core.trigger('formRemoved', taskId, formId, title, icon);
1454
+ dom.clearWatchStyle(formId);
1455
+ dom.clearWatchProperty(formId);
1456
+ native.clear(formId, taskId);
1430
1457
  if (Object.keys(task.list[taskId].forms).length === 0) {
1431
1458
  task.end(taskId);
1432
1459
  }
@@ -1450,7 +1477,7 @@ function getForm(taskId, formId) {
1450
1477
  return form;
1451
1478
  }
1452
1479
  function create(opt) {
1453
- var _a, _b, _c, _d;
1480
+ var _a, _b, _c, _d, _e, _f;
1454
1481
  return __awaiter(this, void 0, void 0, function* () {
1455
1482
  if (!opt.taskId) {
1456
1483
  return -1;
@@ -1465,6 +1492,7 @@ function create(opt) {
1465
1492
  return -3;
1466
1493
  }
1467
1494
  let data = {};
1495
+ let access = {};
1468
1496
  let methods = undefined;
1469
1497
  let computed = {};
1470
1498
  let beforeCreate = undefined;
@@ -1477,8 +1505,9 @@ function create(opt) {
1477
1505
  let unmounted = undefined;
1478
1506
  if (opt.code) {
1479
1507
  data = (_b = opt.code.data) !== null && _b !== void 0 ? _b : {};
1508
+ access = (_c = opt.code.access) !== null && _c !== void 0 ? _c : {};
1480
1509
  methods = opt.code.methods;
1481
- computed = (_c = opt.code.computed) !== null && _c !== void 0 ? _c : {};
1510
+ computed = (_d = opt.code.computed) !== null && _d !== void 0 ? _d : {};
1482
1511
  beforeCreate = opt.code.beforeCreate;
1483
1512
  created = opt.code.created;
1484
1513
  beforeMount = opt.code.beforeMount;
@@ -1493,7 +1522,7 @@ function create(opt) {
1493
1522
  if (opt.style) {
1494
1523
  const r = tool.stylePrepend(opt.style);
1495
1524
  prep = r.prep;
1496
- style = yield tool.styleUrl2DataUrl((_d = opt.path) !== null && _d !== void 0 ? _d : '/', r.style, t.app.files);
1525
+ style = yield tool.styleUrl2DataUrl((_e = opt.path) !== null && _e !== void 0 ? _e : '/', r.style, t.app.files);
1497
1526
  }
1498
1527
  let layout = tool.purify(opt.layout);
1499
1528
  layout = tool.layoutAddTagClassAndReTagName(layout, true);
@@ -1506,8 +1535,12 @@ function create(opt) {
1506
1535
  }
1507
1536
  layout = tool.layoutClassPrepend(layout, prepList);
1508
1537
  layout = tool.eventsAttrWrap(layout);
1509
- elements.list.insertAdjacentHTML('beforeend', `<div class="cg-form-wrap" data-form-id="${formId.toString()}" data-task-id="${opt.taskId.toString()}"></div>`);
1510
- const el = elements.list.children.item(elements.list.children.length - 1);
1538
+ if (layout.includes('<teleport')) {
1539
+ layout = tool.teleportGlue(layout, formId);
1540
+ }
1541
+ exports.elements.list.insertAdjacentHTML('beforeend', `<div class="cg-form-wrap" data-form-id="${formId.toString()}" data-task-id="${opt.taskId.toString()}"></div>`);
1542
+ exports.elements.popList.insertAdjacentHTML('beforeend', `<div data-form-id="${formId.toString()}" data-task-id="${opt.taskId.toString()}"></div>`);
1543
+ const el = exports.elements.list.children.item(exports.elements.list.children.length - 1);
1511
1544
  computed.formId = {
1512
1545
  get: function () {
1513
1546
  return formId;
@@ -1575,6 +1608,9 @@ function create(opt) {
1575
1608
  return;
1576
1609
  }
1577
1610
  };
1611
+ if (clickgo.isNative() && (formId === 1) && !clickgo.isImmersion() && !clickgo.hasFrame()) {
1612
+ data.isNativeSync = true;
1613
+ }
1578
1614
  if (style) {
1579
1615
  dom.pushStyle(opt.taskId, style, 'form', formId);
1580
1616
  }
@@ -1587,7 +1623,10 @@ function create(opt) {
1587
1623
  'methods': methods,
1588
1624
  'computed': computed,
1589
1625
  'beforeCreate': beforeCreate,
1590
- 'created': created,
1626
+ 'created': function () {
1627
+ this.access = tool.clone(access);
1628
+ created === null || created === void 0 ? void 0 : created.call(this);
1629
+ },
1591
1630
  'beforeMount': beforeMount,
1592
1631
  'mounted': function () {
1593
1632
  return __awaiter(this, void 0, void 0, function* () {
@@ -1646,18 +1685,31 @@ function create(opt) {
1646
1685
  }
1647
1686
  catch (err) {
1648
1687
  core.trigger('error', rtn.vroot.taskId, rtn.vroot.formId, err, 'Create form mounted error.');
1649
- t.forms[formId] = undefined;
1650
1688
  delete t.forms[formId];
1651
- rtn.vapp.unmount();
1689
+ try {
1690
+ rtn.vapp.unmount();
1691
+ }
1692
+ catch (err) {
1693
+ const msg = `Message: ${err.message}\nTask id: ${opt.taskId}\nForm id: ${formId}\nFunction: form.create, unmount.`;
1694
+ notify({
1695
+ 'title': 'Form Unmount Error',
1696
+ 'content': msg,
1697
+ 'type': 'danger'
1698
+ });
1699
+ console.log('Form Unmount Error', msg, err);
1700
+ }
1652
1701
  rtn.vapp._container.remove();
1702
+ (_f = exports.elements.popList.querySelector('[data-form-id="' + rtn.vroot.formId + '"]')) === null || _f === void 0 ? void 0 : _f.remove();
1703
+ dom.clearWatchStyle(rtn.vroot.formId);
1704
+ dom.clearWatchProperty(rtn.vroot.formId);
1705
+ native.clear(formId, t.id);
1653
1706
  dom.removeStyle(rtn.vroot.taskId, 'form', rtn.vroot.formId);
1654
1707
  return -8;
1655
1708
  }
1656
1709
  }
1657
1710
  core.trigger('formCreated', opt.taskId, formId, rtn.vroot.$refs.form.title, rtn.vroot.$refs.form.iconDataUrl);
1658
- if (clickgo.isNative() && (formId === 1) && !clickgo.isImmersion() && !clickgo.hasFrame()) {
1659
- rtn.vroot.$refs.form.isNativeSync = true;
1660
- native.invoke('cg-set-size', native.getToken(), rtn.vroot.$refs.form.$el.offsetWidth, rtn.vroot.$refs.form.$el.offsetHeight);
1711
+ if (rtn.vroot.isNativeSync) {
1712
+ yield native.invoke('cg-set-size', native.getToken(), rtn.vroot.$refs.form.$el.offsetWidth, rtn.vroot.$refs.form.$el.offsetHeight);
1661
1713
  window.addEventListener('resize', function () {
1662
1714
  rtn.vroot.$refs.form.setPropData('width', window.innerWidth);
1663
1715
  rtn.vroot.$refs.form.setPropData('height', window.innerHeight);
@@ -1713,7 +1765,7 @@ function dialog(opt) {
1713
1765
  }
1714
1766
  }
1715
1767
  };
1716
- cls.create(undefined, `<form title="${(_c = nopt.title) !== null && _c !== void 0 ? _c : 'dialog'}" min="false" max="false" resize="false" height="0" border="${nopt.title ? 'normal' : 'plain'}" direction="v"><dialog :buttons="buttons" @select="select"${nopt.direction ? ` direction="${nopt.direction}"` : ''}>${nopt.content}</dialog></form>`).then((frm) => {
1768
+ cls.create(undefined, `<form title="${(_c = nopt.title) !== null && _c !== void 0 ? _c : 'dialog'}" min="false" max="false" resize="false" height="0" width="0" border="${nopt.title ? 'normal' : 'plain'}" direction="v"><dialog :buttons="buttons" @select="select"${nopt.direction ? ` direction="${nopt.direction}"` : ''}>${nopt.content}</dialog></form>`).then((frm) => {
1717
1769
  if (typeof frm === 'number') {
1718
1770
  resolve('');
1719
1771
  return;
@@ -1789,20 +1841,20 @@ function flash(formId, taskId) {
1789
1841
  }
1790
1842
  exports.flash = flash;
1791
1843
  function showLauncher() {
1792
- elements.launcher.style.display = 'flex';
1844
+ exports.elements.launcher.style.display = 'flex';
1793
1845
  requestAnimationFrame(function () {
1794
- elements.launcher.classList.add('cg-show');
1846
+ exports.elements.launcher.classList.add('cg-show');
1795
1847
  });
1796
1848
  }
1797
1849
  exports.showLauncher = showLauncher;
1798
1850
  function hideLauncher() {
1799
- elements.launcher.classList.remove('cg-show');
1851
+ exports.elements.launcher.classList.remove('cg-show');
1800
1852
  setTimeout(function () {
1801
1853
  if (exports.launcherRoot.folderName !== '') {
1802
1854
  exports.launcherRoot.closeFolder();
1803
1855
  }
1804
1856
  exports.launcherRoot.name = '';
1805
- elements.launcher.style.display = 'none';
1857
+ exports.elements.launcher.style.display = 'none';
1806
1858
  }, 300);
1807
1859
  }
1808
1860
  exports.hideLauncher = hideLauncher;