clickgo 3.2.7 → 3.2.9
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/LICENSE +1 -1
- package/README.md +1 -1
- package/dist/app/demo/form/control/text/text.js +4 -1
- package/dist/app/demo/form/method/form/form.js +12 -0
- package/dist/app/demo/form/method/form/form.xml +1 -0
- package/dist/clickgo.js +1 -1
- package/dist/clickgo.ts +1 -1
- package/dist/control/common.cgc +0 -0
- package/dist/lib/form.js +3 -1
- package/dist/lib/form.ts +3 -1
- package/package.json +2 -2
- package/types/index.d.ts +5 -0
package/LICENSE
CHANGED
|
@@ -186,7 +186,7 @@
|
|
|
186
186
|
same "printed page" as the copyright notice for easier
|
|
187
187
|
identification within third-party archives.
|
|
188
188
|
|
|
189
|
-
Copyright
|
|
189
|
+
Copyright 2023 MAIYUN.NET
|
|
190
190
|
|
|
191
191
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
192
|
you may not use this file except in compliance with the License.
|
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.4.
|
|
31
|
+
<script src="https://cdn.jsdelivr.net/npm/@litert/loader@3.4.10/dist/loader.min.js?path=index&npm={'clickgo':'3.2.9'}"></script>
|
|
32
32
|
```
|
|
33
33
|
|
|
34
34
|
**index.js**
|
|
@@ -72,7 +72,10 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
72
72
|
return undefined;
|
|
73
73
|
}
|
|
74
74
|
longClick() {
|
|
75
|
-
this.value = this.long ? 'short\nshort\nshort\nshort\nshort\nshort\nshort\nshort\nshort' : 'long\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong'
|
|
75
|
+
this.value = this.long ? 'short\nshort\nshort\nshort\nshort\nshort\nshort\nshort\nshort' : 'long\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\nlong\n\n\nlong\nlong\n' + `long
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
long`;
|
|
76
79
|
this.long = !this.long;
|
|
77
80
|
this.scrollTop = 0;
|
|
78
81
|
}
|
|
@@ -199,6 +199,18 @@ class default_1 extends clickgo.form.AbstractForm {
|
|
|
199
199
|
});
|
|
200
200
|
});
|
|
201
201
|
}
|
|
202
|
+
dialogData() {
|
|
203
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
204
|
+
this.dr = yield clickgo.form.dialog({
|
|
205
|
+
'direction': 'v',
|
|
206
|
+
'gutter': 10,
|
|
207
|
+
'content': '<block>Hello text!</block><text :modelValue="data.txt">',
|
|
208
|
+
'data': {
|
|
209
|
+
'txt': 'Text\nLine 2.'
|
|
210
|
+
}
|
|
211
|
+
});
|
|
212
|
+
});
|
|
213
|
+
}
|
|
202
214
|
confirm(cancel) {
|
|
203
215
|
return __awaiter(this, void 0, void 0, function* () {
|
|
204
216
|
this.dr = yield clickgo.form.confirm({
|
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
<button @click="dialogTitle" style="height: 30px;">dialog({'title':'Title','content':'Hello world!'})</button>
|
|
43
43
|
<button @click="dialogButtons" style="height: 30px;">dialog({'content':'Hello world!','buttons':['A','B','C']})</button>
|
|
44
44
|
<button @click="dialogCannot" style="height: 30px;">Dialog can not be close</button>
|
|
45
|
+
<button @click="dialogData" style="height: 30px;">Dialog data</button>
|
|
45
46
|
<button @click="confirm(false)" style="height: 30px;">confirm('confirm')</button>
|
|
46
47
|
<button @click="confirm(true)" style="height: 30px;">confirm({'content':'confirm','cancel':true})</button>
|
|
47
48
|
<button @click="flash" style="height: 30px;">flash({{formId}})</button>
|
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.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.2.
|
|
27
|
+
const version = '3.2.9';
|
|
28
28
|
function getVersion() {
|
|
29
29
|
return version;
|
|
30
30
|
}
|
package/dist/clickgo.ts
CHANGED
package/dist/control/common.cgc
CHANGED
|
Binary file
|
package/dist/lib/form.js
CHANGED
|
@@ -2177,8 +2177,10 @@ function dialog(opt) {
|
|
|
2177
2177
|
}
|
|
2178
2178
|
const cls = class extends AbstractForm {
|
|
2179
2179
|
constructor() {
|
|
2180
|
+
var _a;
|
|
2180
2181
|
super(...arguments);
|
|
2181
2182
|
this.buttons = nopt.buttons;
|
|
2183
|
+
this.data = (_a = nopt.data) !== null && _a !== void 0 ? _a : {};
|
|
2182
2184
|
}
|
|
2183
2185
|
get filename() {
|
|
2184
2186
|
return filename;
|
|
@@ -2202,7 +2204,7 @@ function dialog(opt) {
|
|
|
2202
2204
|
}
|
|
2203
2205
|
};
|
|
2204
2206
|
create(cls, undefined, {
|
|
2205
|
-
'layout': `<form title="${(_d = nopt.title) !== null && _d !== void 0 ? _d : '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>`,
|
|
2207
|
+
'layout': `<form title="${(_d = nopt.title) !== null && _d !== void 0 ? _d : '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.gutter ? ` gutter="${nopt.gutter}"` : ''}>${nopt.content}</dialog></form>`,
|
|
2206
2208
|
'style': nopt.style
|
|
2207
2209
|
}, t.id).then((frm) => {
|
|
2208
2210
|
if (typeof frm === 'number') {
|
package/dist/lib/form.ts
CHANGED
|
@@ -2759,6 +2759,8 @@ export function dialog(opt: string | types.IFormDialogOptions): Promise<string>
|
|
|
2759
2759
|
const cls = class extends AbstractForm {
|
|
2760
2760
|
public buttons = nopt.buttons;
|
|
2761
2761
|
|
|
2762
|
+
public data = nopt.data ?? {};
|
|
2763
|
+
|
|
2762
2764
|
public get filename(): string {
|
|
2763
2765
|
return filename;
|
|
2764
2766
|
}
|
|
@@ -2782,7 +2784,7 @@ export function dialog(opt: string | types.IFormDialogOptions): Promise<string>
|
|
|
2782
2784
|
}
|
|
2783
2785
|
};
|
|
2784
2786
|
create(cls, undefined, {
|
|
2785
|
-
'layout': `<form title="${nopt.title ?? '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>`,
|
|
2787
|
+
'layout': `<form title="${nopt.title ?? '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.gutter ? ` gutter="${nopt.gutter}"` : ''}>${nopt.content}</dialog></form>`,
|
|
2786
2788
|
'style': nopt.style
|
|
2787
2789
|
}, t.id).then((frm) => {
|
|
2788
2790
|
if (typeof frm === 'number') {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "clickgo",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.9",
|
|
4
4
|
"description": "Background interface, software interface, mobile phone APP interface operation library.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"deskrt",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"@litert/eslint-plugin-rules": "^0.1.2",
|
|
22
|
-
"@litert/loader": "^3.4.
|
|
22
|
+
"@litert/loader": "^3.4.10",
|
|
23
23
|
"@types/node": "^18.11.14",
|
|
24
24
|
"electron": "^22.2.0",
|
|
25
25
|
"jszip": "^3.10.1",
|
package/types/index.d.ts
CHANGED
|
@@ -558,8 +558,13 @@ export interface IFormDialogOptions {
|
|
|
558
558
|
'title'?: string;
|
|
559
559
|
'content': string;
|
|
560
560
|
'buttons'?: string[];
|
|
561
|
+
|
|
561
562
|
'direction'?: 'h' | 'v';
|
|
563
|
+
'gutter'?: number | string;
|
|
562
564
|
|
|
565
|
+
/** --- 传值,需要用 data.x 读取 --- */
|
|
566
|
+
'data'?: Record<string, any>;
|
|
567
|
+
/** --- 样式表 --- */
|
|
563
568
|
'style'?: string;
|
|
564
569
|
/** --- 路径基,以 / 结束或文件路径则以文件的基路径为准,可留空 --- */
|
|
565
570
|
'path'?: string;
|