jsbox-cview 1.3.5 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/alert/input-alert.ts +12 -6
- package/components/alert/login-alert.ts +11 -7
- package/components/alert/plain-alert.ts +9 -6
- package/components/alert/uialert.ts +3 -4
- package/components/base.ts +3 -4
- package/components/custom-navigation-bar.ts +52 -53
- package/components/dialogs/dialog-sheet.ts +10 -15
- package/components/dialogs/form-dialog.ts +5 -7
- package/components/dialogs/list-dialog.ts +9 -6
- package/components/dialogs/text-dialog.ts +7 -6
- package/components/dynamic-itemsize-matrix.ts +25 -26
- package/components/dynamic-preference-listview.ts +29 -31
- package/components/dynamic-rowheight-list.ts +10 -11
- package/components/enhanced-imageview.ts +4 -4
- package/components/flowlayout.ts +233 -0
- package/components/image-pager.ts +16 -10
- package/components/page-control.ts +16 -13
- package/components/pageviewer-titlebar.ts +15 -16
- package/components/pageviewer.ts +16 -15
- package/components/rotating-view.ts +27 -22
- package/components/searchbar.ts +30 -25
- package/components/sheet.ts +16 -17
- package/components/single-views.ts +107 -105
- package/components/spinners/loading-dual-ring.ts +15 -8
- package/components/spinners/loading-wedges.ts +8 -4
- package/components/spinners/spinner-androidstyle.ts +15 -16
- package/components/static-preference-listview.ts +94 -95
- package/components/symbol-button.ts +16 -30
- package/components/tabbar.ts +24 -25
- package/controller/base-controller.ts +57 -58
- package/controller/controller-router.ts +2 -3
- package/controller/pageviewer-controller.ts +16 -15
- package/controller/presented-page-controller.ts +14 -13
- package/controller/splitview-controller.ts +22 -13
- package/controller/tabbar-controller.ts +15 -15
- package/dist/components/alert/input-alert.js +12 -5
- package/dist/components/alert/login-alert.js +10 -5
- package/dist/components/alert/plain-alert.js +9 -5
- package/dist/components/alert/uialert.js +3 -3
- package/dist/components/base.js +4 -4
- package/dist/components/custom-navigation-bar.js +30 -30
- package/dist/components/dialogs/dialog-sheet.js +9 -12
- package/dist/components/dialogs/form-dialog.js +5 -5
- package/dist/components/dialogs/list-dialog.js +9 -5
- package/dist/components/dialogs/text-dialog.js +7 -5
- package/dist/components/dynamic-itemsize-matrix.js +15 -15
- package/dist/components/dynamic-preference-listview.js +4 -4
- package/dist/components/dynamic-rowheight-list.js +3 -3
- package/dist/components/enhanced-imageview.js +3 -3
- package/dist/components/flowlayout.js +184 -0
- package/dist/components/image-pager.js +14 -9
- package/dist/components/page-control.js +21 -18
- package/dist/components/pageviewer-titlebar.js +15 -15
- package/dist/components/pageviewer.js +16 -14
- package/dist/components/rotating-view.js +24 -19
- package/dist/components/searchbar.js +29 -24
- package/dist/components/sheet.js +13 -14
- package/dist/components/single-views.js +5 -5
- package/dist/components/spinners/loading-dual-ring.js +12 -5
- package/dist/components/spinners/loading-wedges.js +7 -3
- package/dist/components/spinners/spinner-androidstyle.js +13 -15
- package/dist/components/static-preference-listview.js +94 -94
- package/dist/components/symbol-button.js +0 -14
- package/dist/components/tabbar.js +24 -24
- package/dist/controller/base-controller.js +36 -36
- package/dist/controller/controller-router.js +2 -2
- package/dist/controller/pageviewer-controller.js +10 -8
- package/dist/controller/presented-page-controller.js +8 -6
- package/dist/controller/splitview-controller.js +19 -12
- package/dist/controller/tabbar-controller.js +3 -3
- package/dist/index.js +1 -2
- package/dist/test/flowlayout.js +74 -0
- package/index.ts +1 -2
- package/package.json +1 -1
- package/test/flowlayout.ts +77 -0
- package/components/artificial-flowlayout.ts +0 -321
- package/components/spinners/loading-double-rings.ts +0 -121
- package/dist/components/artificial-flowlayout.js +0 -258
- package/dist/components/spinners/loading-double-rings.js +0 -104
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* # cview LoadingDoubleRings
|
|
4
|
-
*/
|
|
5
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
6
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
7
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
8
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
9
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
10
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
11
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
12
|
-
});
|
|
13
|
-
};
|
|
14
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.DoubleRings = void 0;
|
|
16
|
-
const base_1 = require("../base");
|
|
17
|
-
class CanvasComponet extends base_1.Base {
|
|
18
|
-
constructor({ tintColor, startAngle, radiusReduction }) {
|
|
19
|
-
super();
|
|
20
|
-
this._tintColor = tintColor;
|
|
21
|
-
this.startAngle = startAngle;
|
|
22
|
-
this._radiusReduction = radiusReduction;
|
|
23
|
-
this._defineView = () => {
|
|
24
|
-
return {
|
|
25
|
-
type: "canvas",
|
|
26
|
-
props: {
|
|
27
|
-
id: this.id
|
|
28
|
-
},
|
|
29
|
-
layout: $layout.fill,
|
|
30
|
-
events: {
|
|
31
|
-
draw: (view, ctx) => {
|
|
32
|
-
ctx.strokeColor = this._tintColor;
|
|
33
|
-
const radius = Math.min(view.frame.width, view.frame.height);
|
|
34
|
-
ctx.setLineWidth(20);
|
|
35
|
-
ctx.setLineCap(1);
|
|
36
|
-
ctx.setLineJoin(1);
|
|
37
|
-
ctx.addArc(radius / 2, radius / 2, radius / 2 - 20 - this._radiusReduction, this.startAngle, this.startAngle + (Math.PI * 2 * 1) / 4, true);
|
|
38
|
-
ctx.strokePath();
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
};
|
|
42
|
-
};
|
|
43
|
-
}
|
|
44
|
-
redraw() {
|
|
45
|
-
this.view.ocValue().invoke("setNeedsDisplay");
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
class DoubleRings extends base_1.Base {
|
|
49
|
-
constructor({ colors = [$color("#f5542e"), $color("#f2c327")], layout }) {
|
|
50
|
-
super();
|
|
51
|
-
const interval = 1 / 60;
|
|
52
|
-
this._defineView = () => {
|
|
53
|
-
const canvas1 = new CanvasComponet({
|
|
54
|
-
tintColor: colors[0],
|
|
55
|
-
radiusReduction: 0,
|
|
56
|
-
startAngle: (-Math.PI * 3) / 4
|
|
57
|
-
});
|
|
58
|
-
const canvas2 = new CanvasComponet({
|
|
59
|
-
tintColor: colors[0],
|
|
60
|
-
radiusReduction: 0,
|
|
61
|
-
startAngle: Math.PI / 4
|
|
62
|
-
});
|
|
63
|
-
const canvas3 = new CanvasComponet({
|
|
64
|
-
tintColor: colors[1],
|
|
65
|
-
radiusReduction: 25,
|
|
66
|
-
startAngle: -Math.PI / 4
|
|
67
|
-
});
|
|
68
|
-
const canvas4 = new CanvasComponet({
|
|
69
|
-
tintColor: colors[1],
|
|
70
|
-
radiusReduction: 25,
|
|
71
|
-
startAngle: (Math.PI * 3) / 4
|
|
72
|
-
});
|
|
73
|
-
return {
|
|
74
|
-
type: "view",
|
|
75
|
-
props: {
|
|
76
|
-
id: this.id
|
|
77
|
-
},
|
|
78
|
-
views: [
|
|
79
|
-
canvas1.definition,
|
|
80
|
-
canvas2.definition,
|
|
81
|
-
canvas3.definition,
|
|
82
|
-
canvas4.definition
|
|
83
|
-
],
|
|
84
|
-
layout,
|
|
85
|
-
events: {
|
|
86
|
-
ready: (sender) => __awaiter(this, void 0, void 0, function* () {
|
|
87
|
-
while (sender.super) {
|
|
88
|
-
canvas1.startAngle += Math.PI * interval * -2;
|
|
89
|
-
canvas1.redraw();
|
|
90
|
-
canvas2.startAngle += Math.PI * interval * -2;
|
|
91
|
-
canvas2.redraw();
|
|
92
|
-
canvas3.startAngle += Math.PI * interval * 2;
|
|
93
|
-
canvas3.redraw();
|
|
94
|
-
canvas4.startAngle += Math.PI * interval * 2;
|
|
95
|
-
canvas4.redraw();
|
|
96
|
-
yield $wait(interval);
|
|
97
|
-
}
|
|
98
|
-
})
|
|
99
|
-
}
|
|
100
|
-
};
|
|
101
|
-
};
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
exports.DoubleRings = DoubleRings;
|