@intuitionrobotics/thunderstorm 0.41.68 → 0.41.71
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/app-backend/api/v1/utils/version/_assert.js +1 -1
- package/app-backend/api/v1/utils/version/_assert.js.map +1 -1
- package/app-backend/api/v1/utils/version/assert.js +13 -58
- package/app-backend/api/v1/utils/version/assert.js.map +1 -1
- package/app-backend/core/BaseStorm.js +34 -87
- package/app-backend/core/BaseStorm.js.map +1 -1
- package/app-backend/core/Storm.js +42 -112
- package/app-backend/core/Storm.js.map +1 -1
- package/app-backend/exceptions.js +11 -27
- package/app-backend/exceptions.js.map +1 -1
- package/app-backend/modules/CleanupScheduler.js +24 -92
- package/app-backend/modules/CleanupScheduler.js.map +1 -1
- package/app-backend/modules/FirestoreBackupScheduler.js +47 -138
- package/app-backend/modules/FirestoreBackupScheduler.js.map +1 -1
- package/app-backend/modules/ForceUpgrade.js +31 -82
- package/app-backend/modules/ForceUpgrade.js.map +1 -1
- package/app-backend/modules/http/AxiosHttpModule.js +116 -184
- package/app-backend/modules/http/AxiosHttpModule.js.map +1 -1
- package/app-backend/modules/proxy/RemoteProxy.js +40 -90
- package/app-backend/modules/proxy/RemoteProxy.js.map +1 -1
- package/app-backend/modules/proxy/RemoteProxyCaller.js +49 -122
- package/app-backend/modules/proxy/RemoteProxyCaller.js.map +1 -1
- package/app-backend/modules/server/HttpServer.js +153 -216
- package/app-backend/modules/server/HttpServer.js.map +1 -1
- package/app-backend/modules/server/server-api.js +236 -361
- package/app-backend/modules/server/server-api.js.map +1 -1
- package/app-backend/modules/server/server-errors.js +51 -91
- package/app-backend/modules/server/server-errors.js.map +1 -1
- package/app-backend/utils/LogClient_File.js +23 -42
- package/app-backend/utils/LogClient_File.js.map +1 -1
- package/app-backend/utils/file.js +7 -50
- package/app-backend/utils/file.js.map +1 -1
- package/app-backend/utils/promisify-request.js +13 -43
- package/app-backend/utils/promisify-request.js.map +1 -1
- package/app-backend/utils/to-be-removed.js +7 -8
- package/app-backend/utils/to-be-removed.js.map +1 -1
- package/app-backend/utils/types.js +1 -1
- package/app-backend/utils/types.js.map +1 -1
- package/app-frontend/components/ActionButton.js +5 -5
- package/app-frontend/components/ActionButton.js.map +1 -1
- package/app-frontend/components/DropDown.js +91 -119
- package/app-frontend/components/DropDown.js.map +1 -1
- package/app-frontend/components/FilterInput.js +31 -48
- package/app-frontend/components/FilterInput.js.map +1 -1
- package/app-frontend/components/GenericSelect.js +30 -59
- package/app-frontend/components/GenericSelect.js.map +1 -1
- package/app-frontend/components/GenericTabs.js +5 -23
- package/app-frontend/components/GenericTabs.js.map +1 -1
- package/app-frontend/components/Overlay.js +15 -34
- package/app-frontend/components/Overlay.js.map +1 -1
- package/app-frontend/components/TS_Input.js +43 -60
- package/app-frontend/components/TS_Input.js.map +1 -1
- package/app-frontend/components/TS_Table.js +31 -48
- package/app-frontend/components/TS_Table.js.map +1 -1
- package/app-frontend/components/TS_TextArea.js +21 -48
- package/app-frontend/components/TS_TextArea.js.map +1 -1
- package/app-frontend/components/Tabs.js +16 -33
- package/app-frontend/components/Tabs.js.map +1 -1
- package/app-frontend/components/adapter/Adapter.js +103 -154
- package/app-frontend/components/adapter/Adapter.js.map +1 -1
- package/app-frontend/components/adapter/BaseRenderer.js +9 -32
- package/app-frontend/components/adapter/BaseRenderer.js.map +1 -1
- package/app-frontend/components/checkbox/TS_Checkbox.js +12 -29
- package/app-frontend/components/checkbox/TS_Checkbox.js.map +1 -1
- package/app-frontend/components/checkbox/TS_CheckboxField.js +16 -34
- package/app-frontend/components/checkbox/TS_CheckboxField.js.map +1 -1
- package/app-frontend/components/form/Form.js +21 -39
- package/app-frontend/components/form/Form.js.map +1 -1
- package/app-frontend/components/playground/Example_NewProps.js +25 -53
- package/app-frontend/components/playground/Example_NewProps.js.map +1 -1
- package/app-frontend/components/playground/Playground.js +21 -49
- package/app-frontend/components/playground/Playground.js.map +1 -1
- package/app-frontend/components/tree/MenuComponent.js +11 -27
- package/app-frontend/components/tree/MenuComponent.js.map +1 -1
- package/app-frontend/components/tree/MultiTypeAdaptor.js +16 -32
- package/app-frontend/components/tree/MultiTypeAdaptor.js.map +1 -1
- package/app-frontend/components/tree/SimpleTreeNodeRenderer.js +18 -52
- package/app-frontend/components/tree/SimpleTreeNodeRenderer.js.map +1 -1
- package/app-frontend/components/tree/Tree.js +142 -178
- package/app-frontend/components/tree/Tree.js.map +1 -1
- package/app-frontend/components/treeicons.js +5 -5
- package/app-frontend/components/treeicons.js.map +1 -1
- package/app-frontend/core/AbstractThunder.js +27 -43
- package/app-frontend/core/AbstractThunder.js.map +1 -1
- package/app-frontend/core/AppPage.js +16 -32
- package/app-frontend/core/AppPage.js.map +1 -1
- package/app-frontend/core/AppWrapper.js +9 -10
- package/app-frontend/core/AppWrapper.js.map +1 -1
- package/app-frontend/core/BaseComponent.js +62 -106
- package/app-frontend/core/BaseComponent.js.map +1 -1
- package/app-frontend/core/SimpleScriptInjector.js +12 -31
- package/app-frontend/core/SimpleScriptInjector.js.map +1 -1
- package/app-frontend/core/Thunder.js +32 -48
- package/app-frontend/core/Thunder.js.map +1 -1
- package/app-frontend/core/thunder-dispatcher.js +18 -67
- package/app-frontend/core/thunder-dispatcher.js.map +1 -1
- package/app-frontend/modules/ConnectivityModule.js +16 -32
- package/app-frontend/modules/ConnectivityModule.js.map +1 -1
- package/app-frontend/modules/ForceUpgrade.js +17 -33
- package/app-frontend/modules/ForceUpgrade.js.map +1 -1
- package/app-frontend/modules/HistoryModule.js +51 -79
- package/app-frontend/modules/HistoryModule.js.map +1 -1
- package/app-frontend/modules/ResourcesModule.js +12 -28
- package/app-frontend/modules/ResourcesModule.js.map +1 -1
- package/app-frontend/modules/StorageModule.js +47 -68
- package/app-frontend/modules/StorageModule.js.map +1 -1
- package/app-frontend/modules/ThunderstormModule.js +15 -31
- package/app-frontend/modules/ThunderstormModule.js.map +1 -1
- package/app-frontend/modules/component-loader/ReactEntryComponentInjector.js +24 -41
- package/app-frontend/modules/component-loader/ReactEntryComponentInjector.js.map +1 -1
- package/app-frontend/modules/component-loader/entry-component-loading-module.js +19 -36
- package/app-frontend/modules/component-loader/entry-component-loading-module.js.map +1 -1
- package/app-frontend/modules/dialog/Dialog.js +55 -96
- package/app-frontend/modules/dialog/Dialog.js.map +1 -1
- package/app-frontend/modules/dialog/DialogModule.js +48 -84
- package/app-frontend/modules/dialog/DialogModule.js.map +1 -1
- package/app-frontend/modules/http/HttpClient.js +46 -93
- package/app-frontend/modules/http/HttpClient.js.map +1 -1
- package/app-frontend/modules/http/XhrHttpModule.js +66 -88
- package/app-frontend/modules/http/XhrHttpModule.js.map +1 -1
- package/app-frontend/modules/locale/LocaleModule.js +23 -50
- package/app-frontend/modules/locale/LocaleModule.js.map +1 -1
- package/app-frontend/modules/menu/MenuAndButton.js +23 -40
- package/app-frontend/modules/menu/MenuAndButton.js.map +1 -1
- package/app-frontend/modules/menu/MenuModule.js +25 -42
- package/app-frontend/modules/menu/MenuModule.js.map +1 -1
- package/app-frontend/modules/menu/PopupMenu.js +37 -64
- package/app-frontend/modules/menu/PopupMenu.js.map +1 -1
- package/app-frontend/modules/routing/RoutingModule.js +47 -66
- package/app-frontend/modules/routing/RoutingModule.js.map +1 -1
- package/app-frontend/modules/routing/route.js +31 -33
- package/app-frontend/modules/routing/route.js.map +1 -1
- package/app-frontend/modules/toaster/BaseToaster.js +18 -36
- package/app-frontend/modules/toaster/BaseToaster.js.map +1 -1
- package/app-frontend/modules/toaster/Toaster.js +12 -38
- package/app-frontend/modules/toaster/Toaster.js.map +1 -1
- package/app-frontend/modules/toaster/ToasterModule.js +61 -88
- package/app-frontend/modules/toaster/ToasterModule.js.map +1 -1
- package/app-frontend/modules/tooltip/Tooltip.js +25 -52
- package/app-frontend/modules/tooltip/Tooltip.js.map +1 -1
- package/app-frontend/modules/tooltip/TooltipModule.js +32 -51
- package/app-frontend/modules/tooltip/TooltipModule.js.map +1 -1
- package/app-frontend/tools/KeyboardListener.js +24 -41
- package/app-frontend/tools/KeyboardListener.js.map +1 -1
- package/app-frontend/tools/Stylable.js +14 -28
- package/app-frontend/tools/Stylable.js.map +1 -1
- package/app-frontend/utils/tools.js +8 -8
- package/app-frontend/utils/tools.js.map +1 -1
- package/app-frontend/widgets/FieldEditor.js +16 -32
- package/app-frontend/widgets/FieldEditor.js.map +1 -1
- package/app-frontend/widgets/FieldEditorClick.js +32 -49
- package/app-frontend/widgets/FieldEditorClick.js.map +1 -1
- package/app-frontend/widgets/FieldEditorWithButtons.js +33 -49
- package/app-frontend/widgets/FieldEditorWithButtons.js.map +1 -1
- package/app-frontend/widgets/click-to-drag/ClickToDrag.js +25 -41
- package/app-frontend/widgets/click-to-drag/ClickToDrag.js.map +1 -1
- package/app-frontend/widgets/click-to-drag/OverlayWithDocumentListener.js +22 -38
- package/app-frontend/widgets/click-to-drag/OverlayWithDocumentListener.js.map +1 -1
- package/package.json +4 -4
- package/shared/BaseHttpModule.js +44 -64
- package/shared/BaseHttpModule.js.map +1 -1
- package/shared/BaseHttpRequest.js +122 -176
- package/shared/BaseHttpRequest.js.map +1 -1
- package/shared/request-types.js +4 -19
- package/shared/request-types.js.map +1 -1
- package/test-backend/StormTester.js +37 -90
- package/test-backend/StormTester.js.map +1 -1
|
@@ -19,19 +19,6 @@
|
|
|
19
19
|
* See the License for the specific language governing permissions and
|
|
20
20
|
* limitations under the License.
|
|
21
21
|
*/
|
|
22
|
-
var __extends = (this && this.__extends) || (function () {
|
|
23
|
-
var extendStatics = function (d, b) {
|
|
24
|
-
extendStatics = Object.setPrototypeOf ||
|
|
25
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
26
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
27
|
-
return extendStatics(d, b);
|
|
28
|
-
};
|
|
29
|
-
return function (d, b) {
|
|
30
|
-
extendStatics(d, b);
|
|
31
|
-
function __() { this.constructor = d; }
|
|
32
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
22
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
36
23
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
37
24
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -41,63 +28,27 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
41
28
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
42
29
|
});
|
|
43
30
|
};
|
|
44
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
45
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
46
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
47
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
48
|
-
function step(op) {
|
|
49
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
50
|
-
while (_) try {
|
|
51
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
52
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
53
|
-
switch (op[0]) {
|
|
54
|
-
case 0: case 1: t = op; break;
|
|
55
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
56
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
57
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
58
|
-
default:
|
|
59
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
60
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
61
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
62
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
63
|
-
if (t[2]) _.ops.pop();
|
|
64
|
-
_.trys.pop(); continue;
|
|
65
|
-
}
|
|
66
|
-
op = body.call(thisArg, _);
|
|
67
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
68
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
69
|
-
}
|
|
70
|
-
};
|
|
71
31
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
72
32
|
exports.ThunderDispatcher = void 0;
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
return _super.call(this, method) || this;
|
|
33
|
+
const dispatcher_1 = require("@intuitionrobotics/ts-common/core/dispatcher");
|
|
34
|
+
class ThunderDispatcher extends dispatcher_1.Dispatcher {
|
|
35
|
+
constructor(method) {
|
|
36
|
+
super(method);
|
|
78
37
|
}
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
return listeners.filter(this.filter).map(
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
return __awaiter(this, void 0, void 0, function () {
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
var params;
|
|
92
|
-
return __generator(this, function (_a) {
|
|
93
|
-
params = p;
|
|
94
|
-
return [2 /*return*/, listener[this.method].apply(listener, params)];
|
|
95
|
-
});
|
|
96
|
-
}); }))];
|
|
97
|
-
});
|
|
38
|
+
dispatchUI(p) {
|
|
39
|
+
const listeners = ThunderDispatcher.listenersResolver();
|
|
40
|
+
// @ts-ignore
|
|
41
|
+
return listeners.filter(this.filter).map((listener) => listener[this.method](...p));
|
|
42
|
+
}
|
|
43
|
+
dispatchUIAsync(p) {
|
|
44
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
45
|
+
const listeners = ThunderDispatcher.listenersResolver();
|
|
46
|
+
return Promise.all(listeners.filter(this.filter).map((listener) => __awaiter(this, void 0, void 0, function* () {
|
|
47
|
+
const params = p;
|
|
48
|
+
return listener[this.method](...params);
|
|
49
|
+
})));
|
|
98
50
|
});
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
}(dispatcher_1.Dispatcher));
|
|
51
|
+
}
|
|
52
|
+
}
|
|
102
53
|
exports.ThunderDispatcher = ThunderDispatcher;
|
|
103
54
|
//# sourceMappingURL=thunder-dispatcher.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"thunder-dispatcher.js","sourceRoot":"","sources":["../../../src/main/app-frontend/core/thunder-dispatcher.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"thunder-dispatcher.js","sourceRoot":"","sources":["../../../src/main/app-frontend/core/thunder-dispatcher.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;;;;;;;;;;AAEH,6EAAwE;AAMxE,MAAa,iBACZ,SAAQ,uBAAgB;IAIxB,YAAY,MAAS;QACpB,KAAK,CAAC,MAAM,CAAC,CAAC;IACf,CAAC;IAEM,UAAU,CAAC,CAAmB;QACpC,MAAM,SAAS,GAAG,iBAAiB,CAAC,iBAAiB,EAAE,CAAC;QACxD,aAAa;QACb,OAAO,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,QAAW,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;IACxF,CAAC;IAEY,eAAe,CAAC,CAAmB;;YAC/C,MAAM,SAAS,GAAG,iBAAiB,CAAC,iBAAiB,EAAE,CAAC;YACxD,OAAO,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,GAAG,CAAC,CAAO,QAAW,EAAE,EAAE;gBAC1E,MAAM,MAAM,GAAQ,CAAC,CAAC;gBACtB,OAAO,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,GAAG,MAAM,CAAC,CAAC;YACzC,CAAC,CAAA,CAAC,CAAC,CAAC;QACL,CAAC;KAAA;CACD;AAtBD,8CAsBC"}
|
|
@@ -1,41 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __extends = (this && this.__extends) || (function () {
|
|
3
|
-
var extendStatics = function (d, b) {
|
|
4
|
-
extendStatics = Object.setPrototypeOf ||
|
|
5
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
6
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
7
|
-
return extendStatics(d, b);
|
|
8
|
-
};
|
|
9
|
-
return function (d, b) {
|
|
10
|
-
extendStatics(d, b);
|
|
11
|
-
function __() { this.constructor = d; }
|
|
12
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
13
|
-
};
|
|
14
|
-
})();
|
|
15
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
3
|
exports.ConnectivityModule = void 0;
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
_this.dispatch_onConnectivityChange.dispatchUI([]);
|
|
4
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
5
|
+
const thunder_dispatcher_1 = require("../core/thunder-dispatcher");
|
|
6
|
+
class ConnectivityModule_Class extends ts_common_1.Module {
|
|
7
|
+
constructor() {
|
|
8
|
+
super();
|
|
9
|
+
this.dispatch_onConnectivityChange = new thunder_dispatcher_1.ThunderDispatcher('__onConnectivityChange');
|
|
10
|
+
this.isConnected = () => this.connected;
|
|
11
|
+
this.handleConnectionChange = () => {
|
|
12
|
+
this.connected = this.getConnectivityStatus();
|
|
13
|
+
this.dispatch_onConnectivityChange.dispatchModule([]);
|
|
14
|
+
this.dispatch_onConnectivityChange.dispatchUI([]);
|
|
29
15
|
};
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
return _this;
|
|
16
|
+
this.getConnectivityStatus = () => navigator.onLine;
|
|
17
|
+
this.connected = this.getConnectivityStatus();
|
|
33
18
|
}
|
|
34
|
-
|
|
19
|
+
init() {
|
|
35
20
|
window.addEventListener('online', this.handleConnectionChange);
|
|
36
21
|
window.addEventListener('offline', this.handleConnectionChange);
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
}(ts_common_1.Module));
|
|
22
|
+
}
|
|
23
|
+
}
|
|
40
24
|
exports.ConnectivityModule = new ConnectivityModule_Class();
|
|
41
25
|
//# sourceMappingURL=ConnectivityModule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConnectivityModule.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/ConnectivityModule.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ConnectivityModule.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/ConnectivityModule.ts"],"names":[],"mappings":";;;AAAA,4DAAoD;AACpD,mEAA6D;AAM7D,MAAM,wBACL,SAAQ,kBAAM;IAKd;QACC,KAAK,EAAE,CAAC;QAHD,kCAA6B,GAAG,IAAI,sCAAiB,CAAiD,wBAAwB,CAAC,CAAC;QAYxI,gBAAW,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,SAAS,CAAC;QAEnC,2BAAsB,GAAG,GAAG,EAAE;YAC7B,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,qBAAqB,EAAE,CAAC;YAC9C,IAAI,CAAC,6BAA6B,CAAC,cAAc,CAAC,EAAE,CAAC,CAAC;YACtD,IAAI,CAAC,6BAA6B,CAAC,UAAU,CAAC,EAAE,CAAC,CAAA;QAClD,CAAC,CAAC;QAEM,0BAAqB,GAAG,GAAG,EAAE,CAAC,SAAS,CAAC,MAAM,CAAC;QAhBtD,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,qBAAqB,EAAE,CAAC;IAC/C,CAAC;IAES,IAAI;QACb,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,IAAI,CAAC,sBAAsB,CAAC,CAAC;QAC/D,MAAM,CAAC,gBAAgB,CAAC,SAAS,EAAE,IAAI,CAAC,sBAAsB,CAAC,CAAC;IACjE,CAAC;CAWD;AAEY,QAAA,kBAAkB,GAAG,IAAI,wBAAwB,EAAE,CAAC"}
|
|
@@ -19,47 +19,31 @@
|
|
|
19
19
|
* See the License for the specific language governing permissions and
|
|
20
20
|
* limitations under the License.
|
|
21
21
|
*/
|
|
22
|
-
var __extends = (this && this.__extends) || (function () {
|
|
23
|
-
var extendStatics = function (d, b) {
|
|
24
|
-
extendStatics = Object.setPrototypeOf ||
|
|
25
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
26
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
27
|
-
return extendStatics(d, b);
|
|
28
|
-
};
|
|
29
|
-
return function (d, b) {
|
|
30
|
-
extendStatics(d, b);
|
|
31
|
-
function __() { this.constructor = d; }
|
|
32
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
22
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
23
|
exports.ForceUpgrade = exports.RequestKey_AssertAppVersion = void 0;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
24
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
25
|
+
const XhrHttpModule_1 = require("./http/XhrHttpModule");
|
|
26
|
+
const force_upgrade_1 = require("../../shared/force-upgrade");
|
|
27
|
+
const types_1 = require("../../shared/types");
|
|
28
|
+
const tools_1 = require("../utils/tools");
|
|
42
29
|
exports.RequestKey_AssertAppVersion = "assert-app-version";
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
_this.compareVersion = function () {
|
|
30
|
+
const dispatch_onUpgradeRequired = new ts_common_1.Dispatcher("__onUpgradeRequired");
|
|
31
|
+
class ForceUpgrade_Class extends ts_common_1.Module {
|
|
32
|
+
constructor() {
|
|
33
|
+
super(...arguments);
|
|
34
|
+
this.compareVersion = () => {
|
|
49
35
|
XhrHttpModule_1.XhrHttpModule
|
|
50
36
|
.createRequest(types_1.HttpMethod.GET, exports.RequestKey_AssertAppVersion)
|
|
51
|
-
.setRelativeUrl(
|
|
52
|
-
.execute(
|
|
37
|
+
.setRelativeUrl(this.config.assertVersionUrl)
|
|
38
|
+
.execute((response) => {
|
|
53
39
|
dispatch_onUpgradeRequired.dispatchModule([response]);
|
|
54
40
|
});
|
|
55
41
|
};
|
|
56
|
-
return _this;
|
|
57
42
|
}
|
|
58
|
-
|
|
59
|
-
XhrHttpModule_1.XhrHttpModule.addDefaultHeader(force_upgrade_1.HeaderKey_AppVersion,
|
|
60
|
-
XhrHttpModule_1.XhrHttpModule.addDefaultHeader(force_upgrade_1.HeaderKey_BrowserType,
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
}(ts_common_1.Module));
|
|
43
|
+
init() {
|
|
44
|
+
XhrHttpModule_1.XhrHttpModule.addDefaultHeader(force_upgrade_1.HeaderKey_AppVersion, `${process.env.appVersion}`);
|
|
45
|
+
XhrHttpModule_1.XhrHttpModule.addDefaultHeader(force_upgrade_1.HeaderKey_BrowserType, `${tools_1.browserType()}`);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
64
48
|
exports.ForceUpgrade = new ForceUpgrade_Class();
|
|
65
49
|
//# sourceMappingURL=ForceUpgrade.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ForceUpgrade.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/ForceUpgrade.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"ForceUpgrade.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/ForceUpgrade.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH,4DAGsC;AACtC,wDAAmD;AACnD,8DAKoC;AACpC,8CAA8C;AAC9C,0CAA2C;AAE9B,QAAA,2BAA2B,GAAG,oBAAoB,CAAC;AAShE,MAAM,0BAA0B,GAAG,IAAI,sBAAU,CAA2C,qBAAqB,CAAC,CAAC;AAEnH,MAAM,kBACL,SAAQ,kBAAc;IADvB;;QAQC,mBAAc,GAAG,GAAG,EAAE;YACrB,6BAAa;iBACX,aAAa,CAA6B,kBAAU,CAAC,GAAG,EAAE,mCAA2B,CAAC;iBACtF,cAAc,CAAC,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC;iBAC5C,OAAO,CAAC,CAAC,QAAyB,EAAE,EAAE;gBACtC,0BAA0B,CAAC,cAAc,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC;YACvD,CAAC,CAAC,CAAC;QACL,CAAC,CAAC;IACH,CAAC;IAbU,IAAI;QACb,6BAAa,CAAC,gBAAgB,CAAC,oCAAoB,EAAE,GAAG,OAAO,CAAC,GAAG,CAAC,UAAU,EAAE,CAAC,CAAC;QAClF,6BAAa,CAAC,gBAAgB,CAAC,qCAAqB,EAAE,GAAG,mBAAW,EAAE,EAAE,CAAC,CAAC;IAC3E,CAAC;CAUD;AAEY,QAAA,YAAY,GAAG,IAAI,kBAAkB,EAAE,CAAC"}
|
|
@@ -19,44 +19,19 @@
|
|
|
19
19
|
* See the License for the specific language governing permissions and
|
|
20
20
|
* limitations under the License.
|
|
21
21
|
*/
|
|
22
|
-
var __extends = (this && this.__extends) || (function () {
|
|
23
|
-
var extendStatics = function (d, b) {
|
|
24
|
-
extendStatics = Object.setPrototypeOf ||
|
|
25
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
26
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
27
|
-
return extendStatics(d, b);
|
|
28
|
-
};
|
|
29
|
-
return function (d, b) {
|
|
30
|
-
extendStatics(d, b);
|
|
31
|
-
function __() { this.constructor = d; }
|
|
32
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __assign = (this && this.__assign) || function () {
|
|
36
|
-
__assign = Object.assign || function(t) {
|
|
37
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
38
|
-
s = arguments[i];
|
|
39
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
40
|
-
t[p] = s[p];
|
|
41
|
-
}
|
|
42
|
-
return t;
|
|
43
|
-
};
|
|
44
|
-
return __assign.apply(this, arguments);
|
|
45
|
-
};
|
|
46
22
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
47
23
|
exports.BrowserHistoryModule = exports.BrowserHistoryModule_Class = void 0;
|
|
48
24
|
/**
|
|
49
25
|
* Created by tacb0ss on 27/07/2018.
|
|
50
26
|
*/
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
var queryAsString = window.location.search;
|
|
27
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
28
|
+
const history_1 = require("history");
|
|
29
|
+
class BrowserHistoryModule_Class extends ts_common_1.Module {
|
|
30
|
+
constructor() {
|
|
31
|
+
super();
|
|
32
|
+
this.getEncodedQueryParams = () => {
|
|
33
|
+
const queryParams = {};
|
|
34
|
+
let queryAsString = window.location.search;
|
|
60
35
|
if (!queryAsString || queryAsString.length === 0)
|
|
61
36
|
return {};
|
|
62
37
|
while (true) {
|
|
@@ -67,35 +42,34 @@ var BrowserHistoryModule_Class = /** @class */ (function (_super) {
|
|
|
67
42
|
else
|
|
68
43
|
break;
|
|
69
44
|
}
|
|
70
|
-
|
|
71
|
-
return query.map(
|
|
72
|
-
|
|
45
|
+
const query = queryAsString.split("&");
|
|
46
|
+
return query.map(param => {
|
|
47
|
+
const parts = param.split("=");
|
|
73
48
|
return { key: parts[0], value: parts[1] };
|
|
74
|
-
}).reduce(
|
|
49
|
+
}).reduce((toRet, param) => {
|
|
75
50
|
if (param.key && param.value)
|
|
76
51
|
toRet[param.key] = param.value;
|
|
77
52
|
return toRet;
|
|
78
53
|
}, queryParams);
|
|
79
54
|
};
|
|
80
|
-
|
|
81
|
-
return _this;
|
|
55
|
+
this.history = history_1.createBrowserHistory();
|
|
82
56
|
}
|
|
83
|
-
|
|
57
|
+
push(push) {
|
|
84
58
|
this.history.push(push);
|
|
85
|
-
}
|
|
86
|
-
|
|
59
|
+
}
|
|
60
|
+
replace(push) {
|
|
87
61
|
this.history.replace(push);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
|
|
62
|
+
}
|
|
63
|
+
composeQuery(queryParams) {
|
|
64
|
+
const queryAsString = ts_common_1._keys(queryParams).map((key) => `${key}=${queryParams[key]}`).join("&");
|
|
91
65
|
if (queryAsString.length === 0)
|
|
92
66
|
return undefined;
|
|
93
67
|
return queryAsString;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
ts_common_1._keys(params).forEach(
|
|
98
|
-
|
|
68
|
+
}
|
|
69
|
+
getQueryParams() {
|
|
70
|
+
const params = this.getEncodedQueryParams();
|
|
71
|
+
ts_common_1._keys(params).forEach(key => {
|
|
72
|
+
const value = params[key];
|
|
99
73
|
if (!value) {
|
|
100
74
|
delete params[key];
|
|
101
75
|
return;
|
|
@@ -103,11 +77,11 @@ var BrowserHistoryModule_Class = /** @class */ (function (_super) {
|
|
|
103
77
|
params[key] = decodeURIComponent(value);
|
|
104
78
|
});
|
|
105
79
|
return params;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
ts_common_1._keys(encodedQueryParams).forEach(
|
|
110
|
-
|
|
80
|
+
}
|
|
81
|
+
setQuery(queryParams) {
|
|
82
|
+
const encodedQueryParams = Object.assign({}, queryParams);
|
|
83
|
+
ts_common_1._keys(encodedQueryParams).forEach(key => {
|
|
84
|
+
const value = encodedQueryParams[key];
|
|
111
85
|
if (!value) {
|
|
112
86
|
delete encodedQueryParams[key];
|
|
113
87
|
return;
|
|
@@ -115,43 +89,41 @@ var BrowserHistoryModule_Class = /** @class */ (function (_super) {
|
|
|
115
89
|
encodedQueryParams[key] = encodeURIComponent(value);
|
|
116
90
|
});
|
|
117
91
|
this.updateQueryParams(encodedQueryParams);
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
|
|
92
|
+
}
|
|
93
|
+
addQueryParam(key, value) {
|
|
94
|
+
const encodedQueryParams = this.getEncodedQueryParams();
|
|
121
95
|
encodedQueryParams[key] = encodeURIComponent(value);
|
|
122
96
|
this.updateQueryParams(encodedQueryParams);
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
|
|
97
|
+
}
|
|
98
|
+
removeQueryParam(key) {
|
|
99
|
+
const encodedQueryParams = this.getEncodedQueryParams();
|
|
126
100
|
delete encodedQueryParams[key];
|
|
127
|
-
|
|
101
|
+
const data = this.createHistoryDataFromQueryParams(encodedQueryParams);
|
|
128
102
|
this.replace(data);
|
|
129
|
-
}
|
|
130
|
-
|
|
103
|
+
}
|
|
104
|
+
setUrl(url, queryParams) {
|
|
131
105
|
this.push(this.createHistoryDataFromQueryParams(queryParams, url));
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
if (pathname === void 0) { pathname = window.location.pathname; }
|
|
106
|
+
}
|
|
107
|
+
createHistoryDataFromQueryParams(encodedQueryParams, pathname = window.location.pathname) {
|
|
135
108
|
return {
|
|
136
109
|
pathname: !pathname.endsWith("/") ? pathname : pathname.substring(0, pathname.length - 1),
|
|
137
110
|
search: !encodedQueryParams ? "" : this.composeQuery(encodedQueryParams)
|
|
138
111
|
};
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
|
|
112
|
+
}
|
|
113
|
+
updateQueryParams(encodedQueryParams) {
|
|
114
|
+
const data = this.createHistoryDataFromQueryParams(encodedQueryParams);
|
|
142
115
|
this.push(data);
|
|
143
|
-
}
|
|
144
|
-
|
|
116
|
+
}
|
|
117
|
+
getOrigin() {
|
|
145
118
|
return window.location.origin;
|
|
146
|
-
}
|
|
147
|
-
|
|
119
|
+
}
|
|
120
|
+
getCurrent() {
|
|
148
121
|
return this.history.location;
|
|
149
|
-
}
|
|
150
|
-
|
|
122
|
+
}
|
|
123
|
+
getHistory() {
|
|
151
124
|
return this.history;
|
|
152
|
-
}
|
|
153
|
-
|
|
154
|
-
}(ts_common_1.Module));
|
|
125
|
+
}
|
|
126
|
+
}
|
|
155
127
|
exports.BrowserHistoryModule_Class = BrowserHistoryModule_Class;
|
|
156
128
|
exports.BrowserHistoryModule = new BrowserHistoryModule_Class();
|
|
157
129
|
//# sourceMappingURL=HistoryModule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HistoryModule.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/HistoryModule.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"HistoryModule.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/HistoryModule.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH;;GAEG;AACH,4DAGsC;AACtC,qCAIiB;AAGjB,MAAa,0BACZ,SAAQ,kBAAM;IAGd;QACC,KAAK,EAAE,CAAC;QAoBD,0BAAqB,GAAG,GAAgB,EAAE;YACjD,MAAM,WAAW,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AAC,MAAM,CAAC;IAC/B,CAAC;IAED,UAAU;QACT,OAAO,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC;IAC9B,CAAC;IAED,UAAU;QACT,OAAO,IAAI,CAAC,OAAO,CAAC;IACrB,CAAC;CACD;AA7HD,gEA6HC;AAEY,QAAA,oBAAoB,GAAG,IAAI,0BAA0B,EAAE,CAAC"}
|
|
@@ -19,40 +19,24 @@
|
|
|
19
19
|
* See the License for the specific language governing permissions and
|
|
20
20
|
* limitations under the License.
|
|
21
21
|
*/
|
|
22
|
-
var __extends = (this && this.__extends) || (function () {
|
|
23
|
-
var extendStatics = function (d, b) {
|
|
24
|
-
extendStatics = Object.setPrototypeOf ||
|
|
25
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
26
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
27
|
-
return extendStatics(d, b);
|
|
28
|
-
};
|
|
29
|
-
return function (d, b) {
|
|
30
|
-
extendStatics(d, b);
|
|
31
|
-
function __() { this.constructor = d; }
|
|
32
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
22
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
23
|
exports.ResourcesModule = exports.ResourcesModule_Class = void 0;
|
|
37
24
|
/**
|
|
38
25
|
* Created by tacb0ss on 27/07/2018.
|
|
39
26
|
*/
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
_this.relativePathImages = _this.relativePath + "images/";
|
|
47
|
-
return _this;
|
|
27
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
28
|
+
class ResourcesModule_Class extends ts_common_1.Module {
|
|
29
|
+
constructor() {
|
|
30
|
+
super();
|
|
31
|
+
this.relativePath = "../../res/";
|
|
32
|
+
this.relativePathImages = `${this.relativePath}images/`;
|
|
48
33
|
}
|
|
49
|
-
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
return
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
}(ts_common_1.Module));
|
|
34
|
+
init() {
|
|
35
|
+
}
|
|
36
|
+
getImageUrl(relativePath) {
|
|
37
|
+
return `${this.relativePathImages}${relativePath}`;
|
|
38
|
+
}
|
|
39
|
+
}
|
|
56
40
|
exports.ResourcesModule_Class = ResourcesModule_Class;
|
|
57
41
|
exports.ResourcesModule = new ResourcesModule_Class();
|
|
58
42
|
//# sourceMappingURL=ResourcesModule.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ResourcesModule.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/ResourcesModule.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"ResourcesModule.js","sourceRoot":"","sources":["../../../src/main/app-frontend/modules/ResourcesModule.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH;;GAEG;AACH,4DAAoD;AAIpD,MAAa,qBACZ,SAAQ,kBAAM;IAKd;QACC,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,kBAAkB,GAAG,GAAG,IAAI,CAAC,YAAY,SAAS,CAAC;IACzD,CAAC;IAED,IAAI;IACJ,CAAC;IAEM,WAAW,CAAC,YAAwB;QAC1C,OAAO,GAAG,IAAI,CAAC,kBAAkB,GAAG,YAAY,EAAE,CAAA;IACnD,CAAC;CACD;AAlBD,sDAkBC;AAEY,QAAA,eAAe,GAAG,IAAI,qBAAqB,EAAE,CAAC"}
|