clickgo 3.7.0 → 3.8.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.
Files changed (55) hide show
  1. package/README.md +13 -2
  2. package/dist/app/demo/config.json +9 -1
  3. package/dist/app/demo/form/control/arteditor/arteditor.js +65 -0
  4. package/dist/app/demo/form/control/arteditor/arteditor.xml +12 -0
  5. package/dist/app/demo/form/control/arteditor/img.js +51 -0
  6. package/dist/app/demo/form/control/arteditor/img.xml +6 -0
  7. package/dist/app/demo/form/control/iconview/iconview.js +5 -0
  8. package/dist/app/demo/form/control/iconview/iconview.xml +14 -13
  9. package/dist/app/demo/form/control/text/text.js +2 -0
  10. package/dist/app/demo/form/control/text/text.xml +8 -4
  11. package/dist/app/demo/form/control/tuieditor/tuieditor.js +39 -0
  12. package/dist/app/demo/form/control/tuieditor/tuieditor.xml +13 -0
  13. package/dist/app/demo/form/main.js +10 -0
  14. package/dist/app/demo/form/main.xml +2 -0
  15. package/dist/app/demo/form/method/core/core.js +5 -0
  16. package/dist/app/demo/form/method/core/core.xml +2 -1
  17. package/dist/app/demo/res/marker.svg +0 -1
  18. package/dist/clickgo.js +1 -1
  19. package/dist/clickgo.ts +1 -1
  20. package/dist/control/arteditor.cgc +0 -0
  21. package/dist/control/box.cgc +0 -0
  22. package/dist/control/common.cgc +0 -0
  23. package/dist/control/desc.cgc +0 -0
  24. package/dist/control/echarts.cgc +0 -0
  25. package/dist/control/form.cgc +0 -0
  26. package/dist/control/html.cgc +0 -0
  27. package/dist/control/iconview.cgc +0 -0
  28. package/dist/control/map.cgc +0 -0
  29. package/dist/control/monaco.cgc +0 -0
  30. package/dist/control/nav.cgc +0 -0
  31. package/dist/control/page.cgc +0 -0
  32. package/dist/control/property.cgc +0 -0
  33. package/dist/control/table.cgc +0 -0
  34. package/dist/control/task.cgc +0 -0
  35. package/dist/control/tuieditor.cgc +0 -0
  36. package/dist/control/xterm.cgc +0 -0
  37. package/dist/ext/toastui-editor-all.min.js +24 -0
  38. package/dist/global.css +1 -1
  39. package/dist/lib/control.js +5 -14
  40. package/dist/lib/control.ts +7 -10
  41. package/dist/lib/core.js +48 -8
  42. package/dist/lib/core.ts +48 -7
  43. package/dist/lib/dom.js +20 -2
  44. package/dist/lib/dom.ts +34 -11
  45. package/dist/lib/form.js +1 -7
  46. package/dist/lib/form.ts +5 -1
  47. package/dist/lib/fs.js +1 -1
  48. package/dist/lib/fs.ts +1 -1
  49. package/dist/lib/task.js +6 -0
  50. package/dist/lib/task.ts +9 -3
  51. package/dist/theme/byterun.cgt +0 -0
  52. package/dist/theme/familiar.cgt +0 -0
  53. package/dist/theme/light.cgt +0 -0
  54. package/package.json +1 -1
  55. package/types/index.d.ts +1 -0
package/README.md CHANGED
@@ -28,7 +28,7 @@ Load the module loader first, and then load it using the module loader.
28
28
  **index.html**
29
29
 
30
30
  ```html
31
- <script src="https://cdn.jsdelivr.net/npm/@litert/loader@3.5.0/dist/loader.min.js?path=index&npm={'clickgo':'3.7.0'}"></script>
31
+ <script src="https://cdn.jsdelivr.net/npm/@litert/loader@3.5.0/dist/loader.min.js?path=index&npm={'clickgo':'3.8.0'}"></script>
32
32
  ```
33
33
 
34
34
  **index.js**
@@ -106,6 +106,10 @@ This library is published under [Apache-2.0](./LICENSE) license.
106
106
 
107
107
  [More Horizontal SVG Vector](https://www.svgrepo.com/svg/447028/more-horizontal)
108
108
 
109
+ #### Arteditor
110
+
111
+ [Plus SVG Vector](https://www.svgrepo.com/svg/447037/plus)
112
+
109
113
  ### **LICENSE:** MIT License **AUTHOR:** developmentseed
110
114
 
111
115
  #### Map
@@ -126,4 +130,11 @@ This library is published under [Apache-2.0](./LICENSE) license.
126
130
  #### Iconview
127
131
 
128
132
  [Folder SVG Vector](https://www.svgrepo.com/svg/474852/folder)
129
- [File SVG Vector](https://www.svgrepo.com/svg/474842/file)
133
+ [File SVG Vector](https://www.svgrepo.com/svg/474842/file)
134
+
135
+ ### **LICENSE:** MIT License **AUTHOR:** instructure-ui
136
+
137
+ #### Arteditor
138
+
139
+ [Bold SVG Vector](https://www.svgrepo.com/svg/501109/bold)
140
+ [Italic SVG Vector](https://www.svgrepo.com/svg/501238/italic)
@@ -18,7 +18,9 @@
18
18
  "/clickgo/control/iconview",
19
19
  "/clickgo/control/xterm",
20
20
  "/clickgo/control/echarts",
21
- "/clickgo/control/map"
21
+ "/clickgo/control/map",
22
+ "/clickgo/control/tuieditor",
23
+ "/clickgo/control/arteditor"
22
24
  ],
23
25
  "style": "/package/global",
24
26
 
@@ -26,6 +28,10 @@
26
28
  "/form/control/alayout/alayout.js",
27
29
  "/form/control/alayout/alayout.css",
28
30
  "/form/control/alayout/alayout.xml",
31
+ "/form/control/arteditor/arteditor.js",
32
+ "/form/control/arteditor/arteditor.xml",
33
+ "/form/control/arteditor/img.js",
34
+ "/form/control/arteditor/img.xml",
29
35
  "/form/control/block/block.css",
30
36
  "/form/control/block/block.xml",
31
37
  "/form/control/box/box.js",
@@ -99,6 +105,8 @@
99
105
  "/form/control/table/table.xml",
100
106
  "/form/control/text/text.js",
101
107
  "/form/control/text/text.xml",
108
+ "/form/control/tuieditor/tuieditor.js",
109
+ "/form/control/tuieditor/tuieditor.xml",
102
110
  "/form/control/vflow/vflow.css",
103
111
  "/form/control/vflow/vflow.js",
104
112
  "/form/control/vflow/vflow.xml",
@@ -0,0 +1,65 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
26
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
27
+ return new (P || (P = Promise))(function (resolve, reject) {
28
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
29
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
30
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
31
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
32
+ });
33
+ };
34
+ var __importDefault = (this && this.__importDefault) || function (mod) {
35
+ return (mod && mod.__esModule) ? mod : { "default": mod };
36
+ };
37
+ Object.defineProperty(exports, "__esModule", { value: true });
38
+ const clickgo = __importStar(require("clickgo"));
39
+ const img_1 = __importDefault(require("./img"));
40
+ class default_1 extends clickgo.form.AbstractForm {
41
+ constructor() {
42
+ super(...arguments);
43
+ this.readonly = false;
44
+ this.disabled = false;
45
+ this.size = ['12px'];
46
+ this.family = false;
47
+ this.value = [
48
+ {
49
+ 'type': 'p',
50
+ 'value': 'This is a paragraph. You can say whatever you want to say, I won\'t stop you. Just like a bird can fly in the sky as long as it likes.'
51
+ }
52
+ ];
53
+ }
54
+ imgselect(cb) {
55
+ return __awaiter(this, void 0, void 0, function* () {
56
+ const frm = yield clickgo.form.create(img_1.default);
57
+ const path = yield frm.showDialog();
58
+ if (!path) {
59
+ return;
60
+ }
61
+ cb(path);
62
+ });
63
+ }
64
+ }
65
+ exports.default = default_1;
@@ -0,0 +1,12 @@
1
+ <form title="Arteditor" width="500" height="450" padding="10">
2
+ <layout gutter="10" direction="v" style="flex: 1; width: 0;">
3
+ <label>Line: {{value.length}}</label>
4
+ <arteditor v-model="value" :readonly="readonly" :disabled="disabled" pre="https://cdn.jsdelivr.net/npm/clickgo@3.8.0/dist/app/demo/" style="flex: 1; height: 0;" @imgselect="imgselect" :style="{'font-size': size[0], 'font-family': family ? 'Consolas, \'Courier New\', monospace' : undefined}"></arteditor>
5
+ <layout gutter="10">
6
+ <button @click="disabled = !disabled" style="flex: 1; width: 0;">{{disabled ? '' : '!'}}disabled</button>
7
+ <button @click="readonly = !readonly" style="flex: 1; width: 0;">{{readonly ? '' : '!'}}readonly</button>
8
+ <button @click="family = !family" style="flex: 1; width: 0;">{{family ? '' : '!'}}Family CCM</button>
9
+ <select v-model="size" :data="['12px', '13px', '14px', '15px', '16px']" style="flex: 1; width: 0;"></select>
10
+ </layout>
11
+ </layout>
12
+ </form>
@@ -0,0 +1,51 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ Object.defineProperty(exports, "__esModule", { value: true });
26
+ const clickgo = __importStar(require("clickgo"));
27
+ class default_1 extends clickgo.form.AbstractForm {
28
+ constructor() {
29
+ super(...arguments);
30
+ this.select = [];
31
+ this.list = [
32
+ {
33
+ 'icon': 'https://cdn.jsdelivr.net/npm/clickgo@3.7.0/dist/app/demo/res/sql.svg'
34
+ },
35
+ {
36
+ 'icon': 'https://cdn.jsdelivr.net/npm/clickgo@3.7.0/dist/app/demo/res/txt.svg'
37
+ },
38
+ {
39
+ 'icon': 'https://cdn.jsdelivr.net/npm/clickgo@3.7.0/dist/app/demo/res/zip.svg'
40
+ },
41
+ {
42
+ 'icon': 'https://cdn.jsdelivr.net/npm/clickgo@3.7.0/dist/app/demo/res/img.jpg'
43
+ }
44
+ ];
45
+ }
46
+ selectClick() {
47
+ this.dialogResult = this.list[this.select[0]].icon.slice(-11);
48
+ this.close();
49
+ }
50
+ }
51
+ exports.default = default_1;
@@ -0,0 +1,6 @@
1
+ <form title="Select image" width="400" height="400" padding="10" min="false" max="false">
2
+ <layout gutter="10" direction="v" style="flex: 1; width: 0;">
3
+ <iconview :data="list" v-model="select" name="false" multi="false" selection="false" must size="64" style="flex: 1;"></iconview>
4
+ <button @click="selectClick">Select</button>
5
+ </layout>
6
+ </form>
@@ -75,6 +75,10 @@ class default_1 extends clickgo.form.AbstractForm {
75
75
  'name': 'pack.zip',
76
76
  'time': 1676600099,
77
77
  'icon': '/package/res/zip.svg'
78
+ },
79
+ {
80
+ 'id': 7,
81
+ 'icon': 'https://cdn.jsdelivr.net/npm/clickgo@3.7.0/dist/app/demo/res/img.jpg'
78
82
  }
79
83
  ];
80
84
  this.select = [];
@@ -84,6 +88,7 @@ class default_1 extends clickgo.form.AbstractForm {
84
88
  this.ctrl = true;
85
89
  this.selection = true;
86
90
  this.gesture = false;
91
+ this.name = true;
87
92
  this.selectionArea = {};
88
93
  this.scroll = 'auto';
89
94
  this.size = [100];
@@ -1,7 +1,7 @@
1
- <form title="Iconview" width="400" height="500" padding="10">
1
+ <form title="Iconview" width="500" height="500" padding="10">
2
2
  <layout gutter="10" direction="v" style="flex: 1; width: 0;">
3
3
  <label>select: {{select}}</label>
4
- <iconview :data="list" v-model="select" :disabled="disabled" :must="must" :multi="multi" :ctrl="ctrl" :selection="selection" :gesture="gesture ? ['top', 'bottom'] : []" @gesture="onGesture" :scroll="scroll" :size="size[0] ? size[0] : undefined" style="flex: 1;" @drop="drop" @select="onSelect" @open="onOpen">
4
+ <iconview :data="list" v-model="select" :disabled="disabled" :must="must" :multi="multi" :ctrl="ctrl" :selection="selection" :gesture="gesture ? ['top', 'bottom'] : []" @gesture="onGesture" :scroll="scroll" :size="size[0] ? size[0] : undefined" :name="name" style="flex: 1;" @drop="drop" @select="onSelect" @open="onOpen">
5
5
  <template v-slot:pop>
6
6
  <menulist>
7
7
  <menulist-item alt="S">Some options</menulist-item>
@@ -16,24 +16,25 @@
16
16
  </iconview>
17
17
  <label>Area: {{selectionArea}}</label>
18
18
  <layout gutter="10">
19
- <button @click="add" style="padding: 10px; flex: 1;">Add</button>
20
- <button @click="remove" style="padding: 10px; flex: 1;">Remove</button>
21
- <button @click="scrollChange" style="padding: 10px; flex: 1;">Scroll {{scroll}}</button>
19
+ <button @click="add" style="flex: 1;">Add</button>
20
+ <button @click="remove" style="flex: 1;">Remove</button>
21
+ <button @click="scrollChange" style="flex: 1;">Scroll {{scroll}}</button>
22
22
  </layout>
23
23
  <layout class="ctr" gutter="10">
24
24
  <select v-model="size" :data="[32, 64, 100, 128, 256]" style="flex: 1;"></select>
25
- <button @click="select=[1]" style="padding: 10px; flex: 1;">Select 2th</button>
26
- <button v-if="multi" @click="select=[1,2]" style="padding: 10px; flex: 1;">Select two</button>
25
+ <button @click="select=[1]" style="flex: 1;">Select 2th</button>
26
+ <button v-if="multi" @click="select=[1,2]" style="flex: 1;">Select two</button>
27
27
  </layout>
28
28
  <layout class="ctr" gutter="10">
29
- <button @click="disabled = !disabled" style="padding: 10px; flex: 1;">{{disabled ? '' : '!'}}disabled</button>
30
- <button @click="multi = !multi" style="padding: 10px; flex: 1;">{{multi ? '' : '!'}}multi</button>
31
- <button @click="ctrl = !ctrl" style="padding: 10px; flex: 1;">{{ctrl ? '' : '!'}}ctrl</button>
29
+ <button @click="disabled = !disabled" style="flex: 1;">{{disabled ? '' : '!'}}disabled</button>
30
+ <button @click="multi = !multi" style="flex: 1;">{{multi ? '' : '!'}}multi</button>
31
+ <button @click="ctrl = !ctrl" style="flex: 1;">{{ctrl ? '' : '!'}}ctrl</button>
32
32
  </layout>
33
33
  <layout class="ctr" gutter="10">
34
- <button @click="must = !must" style="padding: 10px; flex: 1;">{{must ? '' : '!'}}must</button>
35
- <button @click="selection = !selection" style="padding: 10px; flex: 1;">{{selection ? '' : '!'}}selection</button>
36
- <button @click="gesture = !gesture" style="padding: 10px; flex: 1;">{{gesture ? '' : '!'}}gesture</button>
34
+ <button @click="must = !must" style="flex: 1;">{{must ? '' : '!'}}must</button>
35
+ <button @click="selection = !selection" style="flex: 1;">{{selection ? '' : '!'}}selection</button>
36
+ <button @click="gesture = !gesture" style="flex: 1;">{{gesture ? '' : '!'}}gesture</button>
37
+ <button @click="name = !name" style="flex: 1;">{{name ? '' : '!'}}name</button>
37
38
  </layout>
38
39
  </layout>
39
40
  </form>
@@ -49,6 +49,8 @@ class default_1 extends clickgo.form.AbstractForm {
49
49
  this.multi = false;
50
50
  this.disabled = false;
51
51
  this.readonly = false;
52
+ this.adaption = false;
53
+ this.scroll = true;
52
54
  this.password = false;
53
55
  this.wrap = true;
54
56
  this.menu = false;
@@ -1,8 +1,8 @@
1
- <form width="350" height="350" title="Textbox">
1
+ <form width="350" height="550" title="Textbox">
2
2
  <layout direction="v" gutter="10" style="padding: 10px; flex: 1; width: 0;">
3
3
  <label>Text Length: {{value.length}}, Selection Start: {{selectionStart}}, Selection End: {{selectionEnd}}, Focus: {{isFocus}}</label>
4
4
  <label>Scroll Left: {{scrollLeft}}, Scroll Top: {{scrollTop}}, Scroll Height: {{scrollHeight}}, Scroll Width: {{scrollWidth}}, Client Height: {{clientHeight}}, Client Width: {{clientWidth}}</label>
5
- <text v-model="value" placeholder="placeholder" :multi="multi" :gesture="gesture ? ['top', 'bottom'] : []" @gesture="onGesture" :disabled="disabled" :readonly="readonly" :password="password" :wrap="wrap" v-model:scroll-left="scrollLeft" v-model:scroll-top="scrollTop" v-model:selection-start="selectionStart" v-model:selection-end="selectionEnd" @clientheight="clientHeight = $event" @clientwidth="clientWidth = $event" @scrollheight="scrollHeight = $event" @scrollwidth="scrollWidth = $event" @focus="isFocus = true" @blur="isFocus = false" :style="{'flex': multi ? '1' : undefined, 'line-height': lineHeight, 'font-size': fontSize + 'px', 'background': background, 'color': background ? '#FFF' : undefined, 'height': multi ? undefined : '30px', 'border-width': textBorder}" :class="[phcolor && ('ph-' + phcolor)]">
5
+ <text v-model="value" placeholder="placeholder" :multi="multi" :gesture="gesture ? ['top', 'bottom'] : []" @gesture="onGesture" :disabled="disabled" :readonly="readonly" :adaption="adaption" :scroll="scroll" :password="password" :wrap="wrap" v-model:scroll-left="scrollLeft" v-model:scroll-top="scrollTop" v-model:selection-start="selectionStart" v-model:selection-end="selectionEnd" @clientheight="clientHeight = $event" @clientwidth="clientWidth = $event" @scrollheight="scrollHeight = $event" @scrollwidth="scrollWidth = $event" @focus="isFocus = true" @blur="isFocus = false" :style="{'flex': multi && (!adaption || scroll || !wrap) ? '1' : undefined, 'line-height': lineHeight, 'font-size': fontSize + 'px', 'background': background, 'color': background ? '#FFF' : undefined, 'height': multi && (!adaption || scroll || !wrap) ? '0' : undefined, 'border-width': textBorder}" :class="[phcolor && ('ph-' + phcolor)]">
6
6
  <menulist v-if="menu">
7
7
  <menulist-item>Custom</menulist-item>
8
8
  </menulist>
@@ -12,7 +12,7 @@
12
12
  <button @click="multi = !multi" style="flex: 1;">{{multi ? '' : '!'}}multi</button>
13
13
  <button @click="disabled = !disabled" style="flex: 1;">{{disabled ? '' : '!'}}disabled</button>
14
14
  <button @click="readonly = !readonly" style="flex: 1;">{{readonly ? '' : '!'}}readonly</button>
15
- <button @click="longClick" style="flex: 1;">{{long ? '' : '!'}}long</button>
15
+ <button @click="scroll = !scroll" style="flex: 1;">{{scroll ? '' : '!'}}scroll</button>
16
16
  </layout>
17
17
  <layout gutter="10">
18
18
  <button @click="password = !password" style="flex: 1;">{{password ? '' : '!'}}password</button>
@@ -20,10 +20,14 @@
20
20
  <button @click="menu = !menu" style="flex: 1;">{{menu ? '' : '!'}}menu</button>
21
21
  <button @click="gesture = !gesture" style="flex: 1;">{{gesture ? '' : '!'}}gesture</button>
22
22
  </layout>
23
+ <layout gutter="10">
24
+ <button @click="append = !append" style="flex: 1;">{{append ? '' : '!'}}append</button>
25
+ <button @click="adaption = !adaption" style="flex: 1;">{{adaption ? '' : '!'}}adaption</button>
26
+ <button @click="longClick" style="flex: 1;">{{long ? '' : '!'}}long</button>
27
+ </layout>
23
28
  <layout gutter="10">
24
29
  <button @click="lineHeight = lineHeight === 1 ? 1.5 : 1" style="flex: 1;">Set line {{lineHeight === 1 ? 1.5 : 1}}</button>
25
30
  <button @click="fontSize = fontSize === 12 ? 16 : 12" style="flex: 1;">Set size {{fontSize === 12 ? 16 : 12}}</button>
26
- <button @click="append = !append" style="flex: 1;">{{append ? '' : '!'}}append</button>
27
31
  </layout>
28
32
  <layout gutter="10">
29
33
  <button @click="border = 'solid'" style="flex: 2;">Set border solid</button>
@@ -0,0 +1,39 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ Object.defineProperty(exports, "__esModule", { value: true });
26
+ const clickgo = __importStar(require("clickgo"));
27
+ class default_1 extends clickgo.form.AbstractForm {
28
+ constructor() {
29
+ super(...arguments);
30
+ this.theme = ['light'];
31
+ this.themes = ['light', 'dark'];
32
+ this.disabled = false;
33
+ this.size = ['12px'];
34
+ this.family = false;
35
+ this.visual = false;
36
+ this.text = 'a**b**c';
37
+ }
38
+ }
39
+ exports.default = default_1;
@@ -0,0 +1,13 @@
1
+ <form title="Tuieditor" width="500" height="450" padding="10">
2
+ <layout gutter="10" direction="v" style="flex: 1; width: 0;">
3
+ <label>Length: {{text.length}}</label>
4
+ <tuieditor v-model="text" :disabled="disabled" :theme="theme[0]" :visual="visual" style="flex: 1; height: 0;" :style="{'font-size': size[0], 'font-family': family ? 'Consolas, \'Courier New\', monospace' : undefined}"></tuieditor>
5
+ <layout gutter="10">
6
+ <button @click="disabled = !disabled" style="flex: 1; width: 0;">{{disabled ? '' : '!'}}disabled</button>
7
+ <button @click="family = !family" style="flex: 1; width: 0;">{{family ? '' : '!'}}Family CCM</button>
8
+ <select v-model="size" :data="['12px', '13px', '14px', '15px', '16px']" style="flex: 1; width: 0;"></select>
9
+ <select v-model="theme" :data="themes" style="flex: 1; width: 0;"></select>
10
+ <button @click="visual = !visual" style="flex: 1; width: 0;">{{visual ? '' : '!'}}visual</button>
11
+ </layout>
12
+ </layout>
13
+ </form>
@@ -70,6 +70,8 @@ const text_1 = __importDefault(require("./control/text/text"));
70
70
  const vflow_1 = __importDefault(require("./control/vflow/vflow"));
71
71
  const xterm_1 = __importDefault(require("./control/xterm/xterm"));
72
72
  const echarts_1 = __importDefault(require("./control/echarts/echarts"));
73
+ const tuieditor_1 = __importDefault(require("./control/tuieditor/tuieditor"));
74
+ const arteditor_1 = __importDefault(require("./control/arteditor/arteditor"));
73
75
  const form_2 = __importDefault(require("./event/form/form"));
74
76
  const other_1 = __importDefault(require("./event/other/other"));
75
77
  const screen_1 = __importDefault(require("./event/screen/screen"));
@@ -250,6 +252,14 @@ class default_1 extends clickgo.form.AbstractForm {
250
252
  frm = yield clickgo.form.create(text_1.default);
251
253
  break;
252
254
  }
255
+ case 'ctuieditor': {
256
+ frm = yield clickgo.form.create(tuieditor_1.default);
257
+ break;
258
+ }
259
+ case 'carteditor': {
260
+ frm = yield clickgo.form.create(arteditor_1.default);
261
+ break;
262
+ }
253
263
  case 'eform': {
254
264
  frm = yield clickgo.form.create(form_2.default);
255
265
  break;
@@ -36,10 +36,12 @@
36
36
  <button @click="openForm('cdesc')">Desc</button>
37
37
  <button @click="openForm('chtml')">Html</button>
38
38
  <button @click="openForm('ciconview')">Iconview</button>
39
+ <button @click="openForm('carteditor')">Arteditor</button>
39
40
  <button @click="openForm('cmonaco')">Monaco</button>
40
41
  <button @click="openForm('cxterm')">Xterm</button>
41
42
  <button @click="openForm('cecharts')">Echarts</button>
42
43
  <button @click="openForm('cmap')">Map</button>
44
+ <button @click="openForm('ctuieditor')">Tuieditor</button>
43
45
  </layout>
44
46
  </flow>
45
47
  <flow v-else-if="ntab === 'method'" class="inner" direction="v">
@@ -65,6 +65,11 @@ class default_1 extends clickgo.form.AbstractForm {
65
65
  yield clickgo.form.dialog('Hash is: ' + clickgo.core.getHash());
66
66
  });
67
67
  }
68
+ getHost() {
69
+ return __awaiter(this, void 0, void 0, function* () {
70
+ yield clickgo.form.dialog('Host is: ' + clickgo.core.getHost());
71
+ });
72
+ }
68
73
  locatione() {
69
74
  return __awaiter(this, void 0, void 0, function* () {
70
75
  if (clickgo.core.location(this.location)) {
@@ -1,4 +1,4 @@
1
- <form width="350" height="430" title="Library task" padding="10">
1
+ <form width="350" height="450" title="Library task" padding="10">
2
2
  <layout direction="v" gutter="10" style="flex: 1;">
3
3
  <label>config:</label>
4
4
  <text v-model="config" readonly multi style="flex: 1;"></text>
@@ -9,6 +9,7 @@
9
9
  <button @click="hashe">hash('{{hash}}')</button>
10
10
  </layout>
11
11
  <button @click="getHash">getHash()</button>
12
+ <button @click="getHost">getHost()</button>
12
13
  <layout gutter="10">
13
14
  <text v-model="location" style="flex: 1;" />
14
15
  <button @click="locatione">location('...{{location.slice(-5)}}')</button>
@@ -1,4 +1,3 @@
1
-
2
1
  <?xml version="1.0" encoding="utf-8"?>
3
2
  <svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
4
3
  <path d="M12.5 7.04148C12.3374 7.0142 12.1704 7 12 7C10.3431 7 9 8.34315 9 10C9 11.6569 10.3431 13 12 13C13.6569 13 15 11.6569 15 10C15 9.82964 14.9858 9.6626 14.9585 9.5" stroke-width="1.5" stroke-linecap="round"/>
package/dist/clickgo.js CHANGED
@@ -24,7 +24,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
24
24
  };
25
25
  Object.defineProperty(exports, "__esModule", { value: true });
26
26
  exports.zip = exports.tool = exports.theme = exports.task = exports.storage = exports.native = exports.fs = exports.form = exports.dom = exports.core = exports.control = exports.vue = exports.hasFrame = exports.isImmersion = exports.getPlatform = exports.isNative = exports.getVersion = void 0;
27
- const version = '3.7.0';
27
+ const version = '3.8.0';
28
28
  function getVersion() {
29
29
  return version;
30
30
  }
package/dist/clickgo.ts CHANGED
@@ -13,7 +13,7 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- const version = '3.7.0';
16
+ const version = '3.8.0';
17
17
  export function getVersion(): string {
18
18
  return version;
19
19
  }
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file