clickgo 3.10.1 → 3.10.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/app/demo/form/control/iconview/iconview.js +6 -6
- package/dist/app/demo/form/control/list/list.js +3 -0
- package/dist/app/demo/form/control/select/select.js +12 -6
- package/dist/app/demo/form/control/select/select.xml +8 -6
- package/dist/app/demo/form/control/table/table.xml +43 -41
- package/dist/app/demo/form/main.js +2 -2
- package/dist/app/demo/form/main.xml +1 -0
- package/dist/app/demo/form/solution/backpanel/backpanel.js +6 -0
- package/dist/clickgo.js +1 -1
- package/dist/clickgo.ts +2 -2
- package/dist/control/common.cgc +0 -0
- package/dist/control/iconview.cgc +0 -0
- package/dist/control/table.cgc +0 -0
- package/package.json +7 -7
- package/types/index.d.ts +48 -1
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.
|
|
31
|
+
<script src="https://cdn.jsdelivr.net/npm/@litert/loader@3.5.1/dist/loader.min.js?path=index&npm={'clickgo':'3.10.3'}"></script>
|
|
32
32
|
```
|
|
33
33
|
|
|
34
34
|
**index.js**
|
|
@@ -135,17 +135,17 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
135
135
|
this.list.splice(-1, 1);
|
|
136
136
|
});
|
|
137
137
|
}
|
|
138
|
-
drop(
|
|
138
|
+
drop(e) {
|
|
139
139
|
return __awaiter(this, void 0, void 0, function* () {
|
|
140
|
-
yield clickgo.form.dialog(JSON.stringify(
|
|
140
|
+
yield clickgo.form.dialog(JSON.stringify(e.detail));
|
|
141
141
|
});
|
|
142
142
|
}
|
|
143
|
-
onSelect(
|
|
144
|
-
this.selectionArea = area;
|
|
143
|
+
onSelect(e) {
|
|
144
|
+
this.selectionArea = e.detail.area;
|
|
145
145
|
}
|
|
146
|
-
onOpen(
|
|
146
|
+
onOpen(e) {
|
|
147
147
|
return __awaiter(this, void 0, void 0, function* () {
|
|
148
|
-
yield clickgo.form.dialog('onOpen: ' +
|
|
148
|
+
yield clickgo.form.dialog('onOpen: ' + e.detail.value.toString());
|
|
149
149
|
});
|
|
150
150
|
}
|
|
151
151
|
scrollChange() {
|
|
@@ -68,7 +68,10 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
68
68
|
];
|
|
69
69
|
this.select = [];
|
|
70
70
|
this.slist2 = [
|
|
71
|
-
'haha1', 'haha2', 'haha3',
|
|
71
|
+
'haha1', 'haha2', 'haha3', {
|
|
72
|
+
'label': 'tip',
|
|
73
|
+
'color': 'tip'
|
|
74
|
+
}, 'haha4', {
|
|
72
75
|
'value': 'ha5',
|
|
73
76
|
'label': 'The value is ha5'
|
|
74
77
|
}, {
|
|
@@ -93,13 +96,14 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
93
96
|
}
|
|
94
97
|
];
|
|
95
98
|
this.addRemoveList = [];
|
|
96
|
-
this.select2 = ['
|
|
99
|
+
this.select2 = ['haha21111'];
|
|
97
100
|
this.aemodel = [];
|
|
98
101
|
this.label2 = [];
|
|
99
102
|
this.asyncModel = ['1'];
|
|
100
103
|
this.asyncData = [];
|
|
101
|
-
this.select3 =
|
|
102
|
-
this.label3 =
|
|
104
|
+
this.select3 = '';
|
|
105
|
+
this.label3 = '';
|
|
106
|
+
this.level3 = [];
|
|
103
107
|
this.s3other = false;
|
|
104
108
|
this.slist3r = ['a', 'b', 'c', 'haha3'];
|
|
105
109
|
this.padding = false;
|
|
@@ -146,8 +150,10 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
146
150
|
});
|
|
147
151
|
}
|
|
148
152
|
onLoaded() {
|
|
149
|
-
|
|
150
|
-
|
|
153
|
+
clickgo.form.notify({
|
|
154
|
+
'type': 'info',
|
|
155
|
+
'title': 'Levelselect @loaded',
|
|
156
|
+
'content': 'Done'
|
|
151
157
|
});
|
|
152
158
|
}
|
|
153
159
|
onRemote(value, resolve) {
|
|
@@ -80,11 +80,13 @@
|
|
|
80
80
|
<layout gutter="10" direction="v" style="padding: 10px;">
|
|
81
81
|
<label>Now select value is {{select3}}</label>
|
|
82
82
|
<label>Label: {{label3}}</label>
|
|
83
|
-
<
|
|
83
|
+
<label>Level: {{level3}}</label>
|
|
84
|
+
<levelselect ref="lese" v-model="select3" @label="label3 = $event" @level="level3 = $event" :data="s3other ? slist3r : slist2" :disabled="disabled" :editable="editable" :multi="multi" :async="async" placeholder="Please enter" @load="onLoad" @loaded="onLoaded" :style="{'font-size': fontSize ? '16px' : undefined, 'padding': padding ? '15px' : undefined, 'background': background ? 'red' : undefined, 'color': background ? '#FFF' : undefined}"></levelselect>
|
|
84
85
|
<button @click="async = !async">{{async ? '' : '!'}}async</button>
|
|
85
|
-
<button @click="select3 =
|
|
86
|
-
<button @click="select3 =
|
|
87
|
-
<button @click="
|
|
86
|
+
<button @click="select3 = 'title'">Set: 'title'</button>
|
|
87
|
+
<button @click="select3 = 'haha2'">Set: 'haha2'</button>
|
|
88
|
+
<button @click="refs.lese.selectLevelValue(['title', 'sub2'])">selectLevelValue(['title', 'sub2'])</button>
|
|
89
|
+
<button @click="select3 = ''">Clear</button>
|
|
88
90
|
<button @click="s3other = !s3other">Set {{s3other ? 'this' : 'other'}} data</button>
|
|
89
91
|
</layout>
|
|
90
92
|
</flow>
|
|
@@ -92,7 +94,7 @@
|
|
|
92
94
|
<layout gutter="10">
|
|
93
95
|
<button @click="disabled = !disabled" style="flex: 1;">{{disabled ? '' : '!'}}disabled</button>
|
|
94
96
|
<button v-if="ntab === 'greatselect'" @click="changeArea" style="flex: 1;">Area: {{area}}</button>
|
|
95
|
-
<button v-else @click="editable = !editable" style="flex: 1;">{{editable ? '' : '!'}}editable</button>
|
|
97
|
+
<button v-else-if="ntab === 'select'" @click="editable = !editable" style="flex: 1;">{{editable ? '' : '!'}}editable</button>
|
|
96
98
|
</layout>
|
|
97
99
|
<layout gutter="10">
|
|
98
100
|
<button @click="fontSize = !fontSize" style="flex: 1;">Change font size</button>
|
|
@@ -100,7 +102,7 @@
|
|
|
100
102
|
</layout>
|
|
101
103
|
<layout gutter="10">
|
|
102
104
|
<button @click="background = !background" style="flex: 1;">Change bg & color</button>
|
|
103
|
-
<button @click="multi = !multi" style="flex: 1;">{{multi ? '' : '!'}}multi</button>
|
|
105
|
+
<button v-if="ntab !== 'levelselect'" @click="multi = !multi" style="flex: 1;">{{multi ? '' : '!'}}multi</button>
|
|
104
106
|
</layout>
|
|
105
107
|
</layout>
|
|
106
108
|
</form>
|
|
@@ -1,43 +1,45 @@
|
|
|
1
|
-
<form width="400" height="500" title="Table">
|
|
2
|
-
<
|
|
3
|
-
<
|
|
4
|
-
|
|
5
|
-
<
|
|
6
|
-
<
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
<label>
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
<form width="400" height="500" title="Table" padding="10">
|
|
2
|
+
<flow direction="v" style="flex: 1; width: 0;">
|
|
3
|
+
<layout direction="v" gutter="10" style="flex: 1;">
|
|
4
|
+
<label>Value: {{val}}</label>
|
|
5
|
+
<table :data="data" :style="{'flex': adaptation ? undefined : '1'}" v-model="val" :disabled="disabled" :must="must" :multi="multi" :ctrl="ctrl" :selection="selection" :gesture="gesture ? ['top', 'bottom'] : []" :split="split" @gesture="onGesture" :scroll="scroll" :sizes="sizes" :sort="sort" @select="onSelect" @sort="onSort">
|
|
6
|
+
<template v-slot="d">
|
|
7
|
+
<table-item v-if="index" label="index" width="80" sort="false">{{d.index}}</table-item>
|
|
8
|
+
<table-item label="name">{{d.row.name ?? 'name'}}</table-item>
|
|
9
|
+
<table-item label="size" width="50" align-v="center" align-h="center">{{d.row.type ?? '0'}}</table-item>
|
|
10
|
+
<table-item label="col" width="100" direction="v" gutter="5">
|
|
11
|
+
<label>line1</label>
|
|
12
|
+
<button>line2</button>
|
|
13
|
+
</table-item>
|
|
14
|
+
</template>
|
|
15
|
+
<template v-slot:pop>
|
|
16
|
+
<menulist>
|
|
17
|
+
<menulist-item alt="S" @click="showIndex">Show select</menulist-item>
|
|
18
|
+
</menulist>
|
|
19
|
+
</template>
|
|
20
|
+
</table>
|
|
21
|
+
<template v-if="loadFirst">
|
|
22
|
+
<layout gutter="10">
|
|
23
|
+
<button style="flex: 1;" @click="data.splice(-2, 0, {'type': 0, 'name': 'Card' + data.length, 'disabled': false});refreshSort()">Add</button>
|
|
24
|
+
<button style="flex: 1;" @click="data.splice(-3, 1);refreshSort()">Remove</button>
|
|
25
|
+
<button style="flex: 1;" @click="scrollChange">Scroll {{scroll}}</button>
|
|
26
|
+
<button style="flex: 1;" @click="adaptation = !adaptation">{{adaptation ? '' : '!'}}adaptation</button>
|
|
27
|
+
</layout>
|
|
28
|
+
<layout gutter="10">
|
|
29
|
+
<button style="flex: 1;" @click="disabled = !disabled">{{disabled ? '' : '!'}}disabled</button>
|
|
30
|
+
<button style="flex: 1;" @click="multi = !multi">{{multi ? '' : '!'}}multi</button>
|
|
31
|
+
<button style="flex: 1;" @click="ctrl = !ctrl">{{ctrl ? '' : '!'}}ctrl</button>
|
|
32
|
+
<button style="flex: 1;" @click="must = !must">{{must ? '' : '!'}}must</button>
|
|
33
|
+
<button style="flex: 1;" @click="index = !index">{{index ? '' : '!'}}index</button>
|
|
34
|
+
</layout>
|
|
35
|
+
<layout gutter="10">
|
|
36
|
+
<button style="flex: 1;" @click="sortChange">sort {{sort ? 'true' : (sort === false ? 'false' : 'undefined')}}</button>
|
|
37
|
+
<button style="flex: 1;" @click="selection = !selection">{{selection ? '' : '!'}}selection</button>
|
|
38
|
+
<button style="flex: 1;" @click="gesture = !gesture">{{gesture ? '' : '!'}}gesture</button>
|
|
39
|
+
<button style="flex: 1;" @click="split = !split">{{split ? '' : '!'}}split</button>
|
|
40
|
+
</layout>
|
|
13
41
|
</template>
|
|
14
|
-
<
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
</menulist>
|
|
18
|
-
</template>
|
|
19
|
-
</table>
|
|
20
|
-
<template v-if="loadFirst">
|
|
21
|
-
<layout gutter="10">
|
|
22
|
-
<button style="flex: 1;" @click="data.splice(-2, 0, {'type': 0, 'name': 'Card' + data.length, 'disabled': false});refreshSort()">Add</button>
|
|
23
|
-
<button style="flex: 1;" @click="data.splice(-3, 1);refreshSort()">Remove</button>
|
|
24
|
-
<button style="flex: 1;" @click="scrollChange">Scroll {{scroll}}</button>
|
|
25
|
-
<button style="flex: 1;" @click="adaptation = !adaptation">{{adaptation ? '' : '!'}}adaptation</button>
|
|
26
|
-
</layout>
|
|
27
|
-
<layout gutter="10">
|
|
28
|
-
<button style="flex: 1;" @click="disabled = !disabled">{{disabled ? '' : '!'}}disabled</button>
|
|
29
|
-
<button style="flex: 1;" @click="multi = !multi">{{multi ? '' : '!'}}multi</button>
|
|
30
|
-
<button style="flex: 1;" @click="ctrl = !ctrl">{{ctrl ? '' : '!'}}ctrl</button>
|
|
31
|
-
<button style="flex: 1;" @click="must = !must">{{must ? '' : '!'}}must</button>
|
|
32
|
-
<button style="flex: 1;" @click="index = !index">{{index ? '' : '!'}}index</button>
|
|
33
|
-
</layout>
|
|
34
|
-
<layout gutter="10">
|
|
35
|
-
<button style="flex: 1;" @click="sortChange">sort {{sort ? 'true' : (sort === false ? 'false' : 'undefined')}}</button>
|
|
36
|
-
<button style="flex: 1;" @click="selection = !selection">{{selection ? '' : '!'}}selection</button>
|
|
37
|
-
<button style="flex: 1;" @click="gesture = !gesture">{{gesture ? '' : '!'}}gesture</button>
|
|
38
|
-
<button style="flex: 1;" @click="split = !split">{{split ? '' : '!'}}split</button>
|
|
39
|
-
</layout>
|
|
40
|
-
</template>
|
|
41
|
-
<button v-else @click="load">Load</button>
|
|
42
|
-
</layout>
|
|
42
|
+
<button v-else @click="load">Load</button>
|
|
43
|
+
</layout>
|
|
44
|
+
</flow>
|
|
43
45
|
</form>
|
|
@@ -97,7 +97,7 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
97
97
|
this.ntab = '';
|
|
98
98
|
this.adata = {};
|
|
99
99
|
}
|
|
100
|
-
openForm(name) {
|
|
100
|
+
openForm(name, data) {
|
|
101
101
|
return __awaiter(this, void 0, void 0, function* () {
|
|
102
102
|
let frm;
|
|
103
103
|
switch (name) {
|
|
@@ -336,7 +336,7 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
336
336
|
break;
|
|
337
337
|
}
|
|
338
338
|
default: {
|
|
339
|
-
frm = yield clickgo.form.create(backpanel_1.default);
|
|
339
|
+
frm = yield clickgo.form.create(backpanel_1.default, data);
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
342
|
frm.show();
|
|
@@ -115,6 +115,7 @@
|
|
|
115
115
|
<flow v-else class="inner" direction="v">
|
|
116
116
|
<layout gutter="10" direction="v">
|
|
117
117
|
<button @click="openForm('sbackpanel')">Backend panel</button>
|
|
118
|
+
<button @click="openForm('sbackpanel', {'hash': 'test2?p=6'})">Backend panel with hash</button>
|
|
118
119
|
</layout>
|
|
119
120
|
</flow>
|
|
120
121
|
</tab>
|
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.10.
|
|
27
|
+
const version = '3.10.3';
|
|
28
28
|
function getVersion() {
|
|
29
29
|
return version;
|
|
30
30
|
}
|
package/dist/clickgo.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright
|
|
2
|
+
* Copyright 2024 Han Guoshuai <zohegs@gmail.com>
|
|
3
3
|
*
|
|
4
4
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
5
|
* you may not use this file except in compliance with the License.
|
|
@@ -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.10.
|
|
16
|
+
const version = '3.10.3';
|
|
17
17
|
export function getVersion(): string {
|
|
18
18
|
return version;
|
|
19
19
|
}
|
package/dist/control/common.cgc
CHANGED
|
Binary file
|
|
Binary file
|
package/dist/control/table.cgc
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clickgo",
|
|
3
|
-
"version": "3.10.
|
|
3
|
+
"version": "3.10.3",
|
|
4
4
|
"description": "Background interface, software interface, mobile phone APP interface operation library.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"deskrt",
|
|
@@ -18,12 +18,12 @@
|
|
|
18
18
|
"native4": "electron ./dist/test/native/index4"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
|
-
"@litert/eslint-plugin-rules": "^0.1.
|
|
22
|
-
"@litert/loader": "^3.5.
|
|
23
|
-
"@types/node": "^
|
|
24
|
-
"electron": "^
|
|
21
|
+
"@litert/eslint-plugin-rules": "^0.1.6",
|
|
22
|
+
"@litert/loader": "^3.5.1",
|
|
23
|
+
"@types/node": "^20.11.6",
|
|
24
|
+
"electron": "^28.1.4",
|
|
25
25
|
"jszip": "^3.10.1",
|
|
26
|
-
"terser": "^5.
|
|
27
|
-
"typescript": "^
|
|
26
|
+
"terser": "^5.27.0",
|
|
27
|
+
"typescript": "^5.3.3"
|
|
28
28
|
}
|
|
29
29
|
}
|
package/types/index.d.ts
CHANGED
|
@@ -661,6 +661,53 @@ export interface IGreatselectAddEvent extends ICustomEvent {
|
|
|
661
661
|
};
|
|
662
662
|
}
|
|
663
663
|
|
|
664
|
+
// --- Iconview Control ---
|
|
665
|
+
|
|
666
|
+
export interface IIconviewItemclickedEvent {
|
|
667
|
+
'detail': {
|
|
668
|
+
'event': MouseEvent | TouchEvent;
|
|
669
|
+
'value': number;
|
|
670
|
+
};
|
|
671
|
+
}
|
|
672
|
+
|
|
673
|
+
export interface IIconviewOpenEvent {
|
|
674
|
+
'detail': {
|
|
675
|
+
'value': number[];
|
|
676
|
+
};
|
|
677
|
+
}
|
|
678
|
+
|
|
679
|
+
export interface IIconviewDropEvent {
|
|
680
|
+
'detail': {
|
|
681
|
+
'self': boolean;
|
|
682
|
+
'from': Array<{
|
|
683
|
+
'index': number;
|
|
684
|
+
'type': 0 | 1 | -1 | undefined;
|
|
685
|
+
'path': string;
|
|
686
|
+
}>;
|
|
687
|
+
'to': {
|
|
688
|
+
'index': number;
|
|
689
|
+
'type': 0 | 1 | -1 | undefined;
|
|
690
|
+
'path': string;
|
|
691
|
+
};
|
|
692
|
+
};
|
|
693
|
+
}
|
|
694
|
+
|
|
695
|
+
export interface IIconviewSelectEvent {
|
|
696
|
+
'detail': {
|
|
697
|
+
'area': {
|
|
698
|
+
'x': number;
|
|
699
|
+
'y': number;
|
|
700
|
+
'width': number;
|
|
701
|
+
'height': number;
|
|
702
|
+
'shift': boolean;
|
|
703
|
+
'ctrl': boolean;
|
|
704
|
+
'start': number;
|
|
705
|
+
'end': number;
|
|
706
|
+
'empty': boolean;
|
|
707
|
+
};
|
|
708
|
+
};
|
|
709
|
+
}
|
|
710
|
+
|
|
664
711
|
// --- List Control ---
|
|
665
712
|
|
|
666
713
|
export interface IListRemoveEvent extends ICustomEvent {
|
|
@@ -680,7 +727,7 @@ export interface IListAddEvent extends ICustomEvent {
|
|
|
680
727
|
export interface IListItemclickedEvent {
|
|
681
728
|
'detail': {
|
|
682
729
|
'event': MouseEvent | TouchEvent;
|
|
683
|
-
'value':
|
|
730
|
+
'value': string;
|
|
684
731
|
'arrow': boolean;
|
|
685
732
|
};
|
|
686
733
|
}
|