@intuitionrobotics/thunderstorm 0.45.1 → 0.46.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/app-backend/api/v1/utils/version/_assert.js +0 -20
- package/app-backend/api/v1/utils/version/_assert.js.map +1 -1
- package/app-backend/api/v1/utils/version/assert.js +0 -20
- package/app-backend/api/v1/utils/version/assert.js.map +1 -1
- package/app-backend/core/BaseStorm.d.ts +1 -1
- package/app-backend/core/BaseStorm.js +2 -22
- package/app-backend/core/BaseStorm.js.map +1 -1
- package/app-backend/core/Storm.js +9 -27
- package/app-backend/core/Storm.js.map +1 -1
- package/app-backend/exceptions.d.ts +2 -2
- package/app-backend/exceptions.js +2 -22
- package/app-backend/exceptions.js.map +1 -1
- package/app-backend/modules/CleanupScheduler.js +5 -4
- package/app-backend/modules/CleanupScheduler.js.map +1 -1
- package/app-backend/modules/FirestoreBackupScheduler.d.ts +1 -1
- package/app-backend/modules/FirestoreBackupScheduler.js +23 -9
- package/app-backend/modules/FirestoreBackupScheduler.js.map +1 -1
- package/app-backend/modules/ForceUpgrade.d.ts +1 -1
- package/app-backend/modules/ForceUpgrade.js +8 -26
- package/app-backend/modules/ForceUpgrade.js.map +1 -1
- package/app-backend/modules/SlackModule.d.ts +2 -4
- package/app-backend/modules/SlackModule.js +9 -30
- package/app-backend/modules/SlackModule.js.map +1 -1
- package/app-backend/modules/http/AxiosHttpModule.js +3 -23
- package/app-backend/modules/http/AxiosHttpModule.js.map +1 -1
- package/app-backend/modules/proxy/RemoteProxy.d.ts +2 -1
- package/app-backend/modules/proxy/RemoteProxy.js +11 -30
- package/app-backend/modules/proxy/RemoteProxy.js.map +1 -1
- package/app-backend/modules/proxy/RemoteProxyCaller.d.ts +1 -1
- package/app-backend/modules/proxy/RemoteProxyCaller.js +11 -29
- package/app-backend/modules/proxy/RemoteProxyCaller.js.map +1 -1
- package/app-backend/modules/server/HttpServer.d.ts +2 -1
- package/app-backend/modules/server/HttpServer.js +9 -31
- package/app-backend/modules/server/HttpServer.js.map +1 -1
- package/app-backend/modules/server/server-api.d.ts +3 -1
- package/app-backend/modules/server/server-api.js +27 -25
- package/app-backend/modules/server/server-api.js.map +1 -1
- package/app-backend/modules/server/server-errors.d.ts +1 -1
- package/app-backend/modules/server/server-errors.js +7 -26
- package/app-backend/modules/server/server-errors.js.map +1 -1
- package/app-backend/utils/LogClient_File.d.ts +2 -2
- package/app-backend/utils/LogClient_File.js +12 -30
- package/app-backend/utils/LogClient_File.js.map +1 -1
- package/app-backend/utils/file.js +0 -20
- package/app-backend/utils/file.js.map +1 -1
- package/app-backend/utils/promisify-request.js +2 -22
- package/app-backend/utils/promisify-request.js.map +1 -1
- package/app-backend/utils/to-be-removed.js +0 -20
- package/app-backend/utils/to-be-removed.js.map +1 -1
- package/app-backend/utils/types.d.ts +1 -1
- package/app-backend/utils/types.js +2 -22
- package/app-backend/utils/types.js.map +1 -1
- package/app-frontend/components/ActionButton.js +0 -20
- package/app-frontend/components/ActionButton.js.map +1 -1
- package/app-frontend/components/DropDown.js +5 -24
- package/app-frontend/components/DropDown.js.map +1 -1
- package/app-frontend/components/FilterInput.js +4 -23
- package/app-frontend/components/FilterInput.js.map +1 -1
- package/app-frontend/components/GenericSelect.js +0 -20
- package/app-frontend/components/GenericSelect.js.map +1 -1
- package/app-frontend/components/Overlay.js +0 -20
- package/app-frontend/components/Overlay.js.map +1 -1
- package/app-frontend/components/TS_Input.js +3 -23
- package/app-frontend/components/TS_Input.js.map +1 -1
- package/app-frontend/components/TS_Table.d.ts +1 -1
- package/app-frontend/components/TS_Table.js +0 -20
- package/app-frontend/components/TS_Table.js.map +1 -1
- package/app-frontend/components/TS_TextArea.js +0 -20
- package/app-frontend/components/TS_TextArea.js.map +1 -1
- package/app-frontend/components/adapter/Adapter.js +6 -26
- package/app-frontend/components/adapter/Adapter.js.map +1 -1
- package/app-frontend/components/adapter/BaseRenderer.js +0 -20
- package/app-frontend/components/adapter/BaseRenderer.js.map +1 -1
- package/app-frontend/components/checkbox/TS_Checkbox.d.ts +2 -2
- package/app-frontend/components/checkbox/TS_Checkbox.js +2 -1
- package/app-frontend/components/checkbox/TS_Checkbox.js.map +1 -1
- package/app-frontend/components/checkbox/TS_CheckboxField.js +0 -18
- package/app-frontend/components/checkbox/TS_CheckboxField.js.map +1 -1
- package/app-frontend/components/form/Form.d.ts +2 -1
- package/app-frontend/components/form/Form.js +2 -22
- package/app-frontend/components/form/Form.js.map +1 -1
- package/app-frontend/components/form/types.d.ts +2 -1
- package/app-frontend/components/form/types.js +0 -20
- package/app-frontend/components/form/types.js.map +1 -1
- package/app-frontend/components/playground/Example_NewProps.js +0 -20
- package/app-frontend/components/playground/Example_NewProps.js.map +1 -1
- package/app-frontend/components/playground/Playground.js +1 -21
- package/app-frontend/components/playground/Playground.js.map +1 -1
- package/app-frontend/components/tree/MenuComponent.js +2 -22
- package/app-frontend/components/tree/MenuComponent.js.map +1 -1
- package/app-frontend/components/tree/MultiTypeAdaptor.js +2 -22
- package/app-frontend/components/tree/MultiTypeAdaptor.js.map +1 -1
- package/app-frontend/components/tree/SimpleTreeNodeRenderer.js +0 -20
- package/app-frontend/components/tree/SimpleTreeNodeRenderer.js.map +1 -1
- package/app-frontend/components/tree/Tree.js +3 -23
- package/app-frontend/components/tree/Tree.js.map +1 -1
- package/app-frontend/components/tree/types.js +0 -20
- package/app-frontend/components/tree/types.js.map +1 -1
- package/app-frontend/components/treeicons.js.map +1 -1
- package/app-frontend/components/types.js +0 -20
- package/app-frontend/components/types.js.map +1 -1
- package/app-frontend/core/AbstractThunder.d.ts +0 -3
- package/app-frontend/core/AbstractThunder.js +0 -32
- package/app-frontend/core/AbstractThunder.js.map +1 -1
- package/app-frontend/core/AppPage.js +0 -20
- package/app-frontend/core/AppPage.js.map +1 -1
- package/app-frontend/core/AppWrapper.js +2 -23
- package/app-frontend/core/AppWrapper.js.map +1 -1
- package/app-frontend/core/BaseComponent.d.ts +2 -4
- package/app-frontend/core/BaseComponent.js +18 -41
- package/app-frontend/core/BaseComponent.js.map +1 -1
- package/app-frontend/core/SimpleScriptInjector.js +2 -22
- package/app-frontend/core/SimpleScriptInjector.js.map +1 -1
- package/app-frontend/core/Thunder.js +3 -22
- package/app-frontend/core/Thunder.js.map +1 -1
- package/app-frontend/core/thunder-dispatcher.d.ts +2 -1
- package/app-frontend/core/thunder-dispatcher.js +13 -23
- package/app-frontend/core/thunder-dispatcher.js.map +1 -1
- package/app-frontend/modules/ConnectivityModule.d.ts +1 -1
- package/app-frontend/modules/ConnectivityModule.js +2 -2
- package/app-frontend/modules/ConnectivityModule.js.map +1 -1
- package/app-frontend/modules/ForceUpgrade.d.ts +1 -1
- package/app-frontend/modules/ForceUpgrade.js +4 -23
- package/app-frontend/modules/ForceUpgrade.js.map +1 -1
- package/app-frontend/modules/HistoryModule.d.ts +3 -5
- package/app-frontend/modules/HistoryModule.js +9 -28
- package/app-frontend/modules/HistoryModule.js.map +1 -1
- package/app-frontend/modules/ResourcesModule.d.ts +1 -4
- package/app-frontend/modules/ResourcesModule.js +2 -25
- package/app-frontend/modules/ResourcesModule.js.map +1 -1
- package/app-frontend/modules/StorageModule.d.ts +1 -4
- package/app-frontend/modules/StorageModule.js +4 -26
- package/app-frontend/modules/StorageModule.js.map +1 -1
- package/app-frontend/modules/ThunderstormModule.d.ts +1 -1
- package/app-frontend/modules/ThunderstormModule.js +3 -3
- package/app-frontend/modules/ThunderstormModule.js.map +1 -1
- package/app-frontend/modules/component-loader/ReactEntryComponentInjector.js +0 -20
- package/app-frontend/modules/component-loader/ReactEntryComponentInjector.js.map +1 -1
- package/app-frontend/modules/component-loader/entry-component-loading-module.d.ts +1 -1
- package/app-frontend/modules/component-loader/entry-component-loading-module.js +4 -25
- package/app-frontend/modules/component-loader/entry-component-loading-module.js.map +1 -1
- package/app-frontend/modules/dialog/Dialog.js +0 -22
- package/app-frontend/modules/dialog/Dialog.js.map +1 -1
- package/app-frontend/modules/dialog/DialogModule.d.ts +1 -1
- package/app-frontend/modules/dialog/DialogModule.js +2 -22
- package/app-frontend/modules/dialog/DialogModule.js.map +1 -1
- package/app-frontend/modules/http/HttpClient.js +0 -20
- package/app-frontend/modules/http/HttpClient.js.map +1 -1
- package/app-frontend/modules/http/XhrHttpModule.js +9 -10
- package/app-frontend/modules/http/XhrHttpModule.js.map +1 -1
- package/app-frontend/modules/locale/LocaleModule.d.ts +1 -4
- package/app-frontend/modules/locale/LocaleModule.js +5 -24
- package/app-frontend/modules/locale/LocaleModule.js.map +1 -1
- package/app-frontend/modules/locale/types.d.ts +0 -3
- package/app-frontend/modules/locale/types.js +0 -20
- package/app-frontend/modules/locale/types.js.map +1 -1
- package/app-frontend/modules/menu/MenuAndButton.js +2 -2
- package/app-frontend/modules/menu/MenuAndButton.js.map +1 -1
- package/app-frontend/modules/menu/MenuModule.d.ts +1 -1
- package/app-frontend/modules/menu/MenuModule.js +4 -3
- package/app-frontend/modules/menu/MenuModule.js.map +1 -1
- package/app-frontend/modules/menu/PopupMenu.js +2 -2
- package/app-frontend/modules/menu/PopupMenu.js.map +1 -1
- package/app-frontend/modules/routing/RoutingModule.d.ts +1 -1
- package/app-frontend/modules/routing/RoutingModule.js +6 -25
- package/app-frontend/modules/routing/RoutingModule.js.map +1 -1
- package/app-frontend/modules/routing/route.js +0 -20
- package/app-frontend/modules/routing/route.js.map +1 -1
- package/app-frontend/modules/toaster/BaseToaster.js +0 -22
- package/app-frontend/modules/toaster/BaseToaster.js.map +1 -1
- package/app-frontend/modules/toaster/Toaster.js +0 -20
- package/app-frontend/modules/toaster/Toaster.js.map +1 -1
- package/app-frontend/modules/toaster/ToasterModule.d.ts +1 -1
- package/app-frontend/modules/toaster/ToasterModule.js +5 -25
- package/app-frontend/modules/toaster/ToasterModule.js.map +1 -1
- package/app-frontend/modules/tooltip/Tooltip.js +2 -22
- package/app-frontend/modules/tooltip/Tooltip.js.map +1 -1
- package/app-frontend/modules/tooltip/TooltipModule.d.ts +1 -1
- package/app-frontend/modules/tooltip/TooltipModule.js +4 -23
- package/app-frontend/modules/tooltip/TooltipModule.js.map +1 -1
- package/app-frontend/tools/KeyboardListener.js +0 -17
- package/app-frontend/tools/KeyboardListener.js.map +1 -1
- package/app-frontend/tools/Stylable.js +0 -20
- package/app-frontend/tools/Stylable.js.map +1 -1
- package/app-frontend/types/renderer-map.js +0 -20
- package/app-frontend/types/renderer-map.js.map +1 -1
- package/app-frontend/utils/tools.js +3 -23
- package/app-frontend/utils/tools.js.map +1 -1
- package/index.d.ts +0 -6
- package/index.js +0 -37
- package/index.js.map +1 -1
- package/package.json +4 -4
- package/shared/BaseHttpModule.d.ts +1 -1
- package/shared/BaseHttpModule.js +6 -5
- package/shared/BaseHttpModule.js.map +1 -1
- package/shared/BaseHttpRequest.js +9 -27
- package/shared/BaseHttpRequest.js.map +1 -1
- package/shared/consts.js +0 -20
- package/shared/consts.js.map +1 -1
- package/shared/force-upgrade.js +0 -20
- package/shared/force-upgrade.js.map +1 -1
- package/shared/request-types.js +0 -20
- package/shared/request-types.js.map +1 -1
- package/shared/types.js +0 -20
- package/shared/types.js.map +1 -1
- package/test-backend/StormTester.js +6 -26
- package/test-backend/StormTester.js.map +1 -1
- package/test-frontend/ThunderTester.js +0 -20
- package/test-frontend/ThunderTester.js.map +1 -1
- package/app-backend/modules/_imports.d.ts +0 -10
- package/app-backend/modules/_imports.js +0 -43
- package/app-backend/modules/_imports.js.map +0 -1
- package/app-frontend/components/GenericTabs.d.ts +0 -4
- package/app-frontend/components/GenericTabs.js +0 -11
- package/app-frontend/components/GenericTabs.js.map +0 -1
- package/backend-test.d.ts +0 -1
- package/backend-test.js +0 -34
- package/backend-test.js.map +0 -1
- package/backend.d.ts +0 -17
- package/backend.js +0 -50
- package/backend.js.map +0 -1
- package/frontend.d.ts +0 -55
- package/frontend.js +0 -88
- package/frontend.js.map +0 -1
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
23
3
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
24
4
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -30,7 +10,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
30
10
|
};
|
|
31
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
32
12
|
exports.DefaultApiErrorMessageComposer = void 0;
|
|
33
|
-
const
|
|
13
|
+
const object_tools_1 = require("@intuitionrobotics/ts-common/utils/object-tools");
|
|
14
|
+
const tools_1 = require("@intuitionrobotics/ts-common/utils/tools");
|
|
34
15
|
const _propsResolver = () => __awaiter(void 0, void 0, void 0, function* () {
|
|
35
16
|
return {};
|
|
36
17
|
});
|
|
@@ -40,7 +21,7 @@ function DefaultApiErrorMessageComposer(headersToAttach = [], propsResolver = _p
|
|
|
40
21
|
const props = yield propsResolver(requestData);
|
|
41
22
|
let slackMessage = "";
|
|
42
23
|
slackMessage += `${error ? error.responseCode : "000"} - ${url} \n\n`;
|
|
43
|
-
const propsAsString =
|
|
24
|
+
const propsAsString = object_tools_1._keys(props).reduce((toRet, key) => {
|
|
44
25
|
return `${toRet} ${key}: ${props[key]}\n`;
|
|
45
26
|
}, "");
|
|
46
27
|
if (props && Object.keys(props).length > 0)
|
|
@@ -58,24 +39,24 @@ function DefaultApiErrorMessageComposer(headersToAttach = [], propsResolver = _p
|
|
|
58
39
|
slackMessage += "--------------------------------------------------------------------------------------\n";
|
|
59
40
|
}
|
|
60
41
|
}
|
|
61
|
-
const _headers =
|
|
42
|
+
const _headers = object_tools_1._keys(headers).reduce((toRet, key) => {
|
|
62
43
|
if (headersToAttach.includes(key))
|
|
63
44
|
toRet[key] = headers[key];
|
|
64
45
|
return toRet;
|
|
65
46
|
}, {});
|
|
66
47
|
if (_headers && Object.keys(_headers).length > 0)
|
|
67
|
-
slackMessage += `Headers: ${
|
|
48
|
+
slackMessage += `Headers: ${tools_1.__stringify(_headers)}\n`;
|
|
68
49
|
else
|
|
69
50
|
slackMessage += "Headers: -- No Included Headers --\n";
|
|
70
51
|
if (query) {
|
|
71
52
|
if (query && Object.keys(query).length > 0)
|
|
72
|
-
slackMessage += `Query: ${
|
|
53
|
+
slackMessage += `Query: ${tools_1.__stringify(query, true)}\n`;
|
|
73
54
|
else
|
|
74
55
|
slackMessage += "Query: -- No Query --\n";
|
|
75
56
|
}
|
|
76
57
|
if (body) {
|
|
77
58
|
if (body && Object.keys(body).length > 0)
|
|
78
|
-
slackMessage += `Body: ${
|
|
59
|
+
slackMessage += `Body: ${tools_1.__stringify(body)}\n`;
|
|
79
60
|
else
|
|
80
61
|
slackMessage += "Body: -- No Body --\n";
|
|
81
62
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server-errors.js","sourceRoot":"","sources":["../../../../src/main/app-backend/modules/server/server-errors.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"server-errors.js","sourceRoot":"","sources":["../../../../src/main/app-backend/modules/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intuitionrobotics/ts-common";
|
|
1
|
+
import { LogClient_BaseRotate } from "@intuitionrobotics/ts-common/core/logger/LogClient_BaseRotate";
|
|
2
2
|
export declare class LogClient_File extends LogClient_BaseRotate {
|
|
3
|
-
private pathToFolder;
|
|
3
|
+
private readonly pathToFolder;
|
|
4
4
|
private buffer;
|
|
5
5
|
constructor(name: string, pathToFolder: string, maxEntries?: number, maxSize?: number);
|
|
6
6
|
private getFileName;
|
|
@@ -1,35 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Permissions management system, define access level for each of
|
|
4
|
-
* your server apis, and restrict users by giving them access levels
|
|
5
|
-
*
|
|
6
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
7
|
-
*
|
|
8
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
-
* you may not use this file except in compliance with the License.
|
|
10
|
-
* You may obtain a copy of the License at
|
|
11
|
-
*
|
|
12
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
-
*
|
|
14
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
-
* See the License for the specific language governing permissions and
|
|
18
|
-
* limitations under the License.
|
|
19
|
-
*/
|
|
20
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
3
|
exports.LogClient_File = void 0;
|
|
22
|
-
const
|
|
23
|
-
const
|
|
24
|
-
class LogClient_File extends
|
|
4
|
+
const LogClient_BaseRotate_1 = require("@intuitionrobotics/ts-common/core/logger/LogClient_BaseRotate");
|
|
5
|
+
const fs_1 = require("fs");
|
|
6
|
+
class LogClient_File extends LogClient_BaseRotate_1.LogClient_BaseRotate {
|
|
25
7
|
constructor(name, pathToFolder, maxEntries = 10, maxSize = 1024 * 1024) {
|
|
26
8
|
super(name, maxEntries, maxSize);
|
|
27
9
|
this.pathToFolder = pathToFolder;
|
|
28
|
-
if (!
|
|
29
|
-
|
|
10
|
+
if (!fs_1.existsSync(pathToFolder))
|
|
11
|
+
fs_1.mkdirSync(pathToFolder, { recursive: true });
|
|
30
12
|
const defaultLogfile = this.getFileName();
|
|
31
|
-
if (
|
|
32
|
-
this.bufferSize =
|
|
13
|
+
if (fs_1.existsSync(defaultLogfile))
|
|
14
|
+
this.bufferSize = fs_1.statSync(`${defaultLogfile}`).size;
|
|
33
15
|
this.prepare();
|
|
34
16
|
}
|
|
35
17
|
getFileName(index = 0) {
|
|
@@ -39,19 +21,19 @@ class LogClient_File extends ts_common_1.LogClient_BaseRotate {
|
|
|
39
21
|
this.buffer.write(log);
|
|
40
22
|
}
|
|
41
23
|
rotateBuffer(fromIndex, toIndex) {
|
|
42
|
-
if (
|
|
24
|
+
if (fs_1.existsSync(this.getFileName(fromIndex))) {
|
|
43
25
|
console.log(`rotating ${fromIndex} => ${toIndex}`);
|
|
44
|
-
|
|
26
|
+
fs_1.renameSync(this.getFileName(fromIndex), this.getFileName(toIndex));
|
|
45
27
|
}
|
|
46
28
|
}
|
|
47
29
|
cleanup() {
|
|
48
30
|
const fileName = this.getFileName(this.maxEntries - 1);
|
|
49
|
-
if (
|
|
50
|
-
|
|
31
|
+
if (fs_1.existsSync(fileName))
|
|
32
|
+
fs_1.unlinkSync(fileName);
|
|
51
33
|
this.buffer.end();
|
|
52
34
|
}
|
|
53
35
|
prepare() {
|
|
54
|
-
this.buffer =
|
|
36
|
+
this.buffer = fs_1.createWriteStream(this.getFileName(), { flags: 'a' });
|
|
55
37
|
}
|
|
56
38
|
}
|
|
57
39
|
exports.LogClient_File = LogClient_File;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LogClient_File.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/LogClient_File.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"LogClient_File.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/LogClient_File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U,GAAG,CAAC,CAAC,CAAC;QACvD,IAAI,eAAU,CAAC,QAAQ,CAAC;YACpB,eAAU,CAAC,QAAQ,CAAC,CAAC;QACzB,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,CAAC;IACtB,CAAC;IAES,OAAO;QACb,IAAI,CAAC,MAAM,GAAG,sBAAiB,CAAC,IAAI,CAAC,WAAW,EAAE,EAAE,EAAC,KAAK,EAAE,GAAG,EAAC,CAAC,CAAC;IACtE,CAAC;CACJ;AA7CD,wCA6CC"}
|
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
23
3
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
24
4
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/file.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"file.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/file.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,yBAAyB;AAGzB,SAAsB,YAAY,CAAC,IAAY;;QAC9C,MAAM,MAAM,GAAG,MAAM,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,CAAC;QAC3C,OAAO,MAAM,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;IAClC,CAAC;CAAA;AAHD,oCAGC;AAED,SAAsB,YAAY,CAAC,eAAuB,EAAE,IAAY;;QACvE,MAAM,MAAM,GAAG,MAAM,CAAC,IAAI,CAAC,eAAe,EAAE,QAAQ,CAAC,CAAC;QACtD,MAAM,EAAE,CAAC,aAAa,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;IACtC,CAAC;CAAA;AAHD,oCAGC"}
|
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
23
3
|
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
24
4
|
return new (P || (P = Promise))(function (resolve, reject) {
|
|
@@ -31,7 +11,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
31
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
32
12
|
exports.promisifyRequest = void 0;
|
|
33
13
|
const exceptions_1 = require("../exceptions");
|
|
34
|
-
const
|
|
14
|
+
const tools_1 = require("@intuitionrobotics/ts-common/utils/tools");
|
|
35
15
|
const axios_1 = require("axios");
|
|
36
16
|
function promisifyRequest(_request) {
|
|
37
17
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -49,7 +29,7 @@ function promisifyRequest(_request) {
|
|
|
49
29
|
// The request was made but no response was received
|
|
50
30
|
// `error.request` is an instance of XMLHttpRequest in the browser and an instance of
|
|
51
31
|
// http.ClientRequest in node.js
|
|
52
|
-
throw new exceptions_1.ApiException(503, `Error: ${
|
|
32
|
+
throw new exceptions_1.ApiException(503, `Error: ${tools_1.__stringify(error)}\n Request: ${tools_1.__stringify(_request, true)}`);
|
|
53
33
|
// Something happened in setting up the request that triggered an Error
|
|
54
34
|
// console.log('Error', error.message);
|
|
55
35
|
//
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"promisify-request.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/promisify-request.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"promisify-request.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/promisify-request.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,8CAA2C;AAC3C,oEAAqE;AACrE,iCAGe;AAEf,SAAsB,gBAAgB,CAAC,QAA4B;;QAClE,IAAI;YACH,OAAO,MAAM,eAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;SACrC;QAAC,OAAO,KAAK,EAAE;YACf,MAAM,IAAI,GAAG,KAAK,CAAC,QAAQ,CAAC;YAC5B,IAAI,IAAI,EAAE;gBACT,mEAAmE;gBACnE,qCAAqC;gBACrC,OAAO,IAAI,CAAC;aACZ;YAED,qBAAqB;YACrB,oDAAoD;YACpD,qFAAqF;YACrF,gCAAgC;YAEhC,MAAM,IAAI,yBAAY,CAAC,GAAG,EAAE,UAAU,mBAAW,CAAC,KAAK,CAAC,eAAe,mBAAW,CAAC,QAAQ,EAAE,IAAI,CAAC,EAAE,CAAC,CAAA;YAErG,uEAAuE;YACvE,uCAAuC;YACvC,EAAE;YACF,6BAA6B;SAC7B;IACF,CAAC;CAAA;AAvBD,4CAuBC"}
|
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.assertProperty = void 0;
|
|
24
4
|
const exceptions_1 = require("../exceptions");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"to-be-removed.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/to-be-removed.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"to-be-removed.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/to-be-removed.ts"],"names":[],"mappings":";;;AACA,8CAA2C;AAEpC,MAAM,cAAc,GAAG,CAAgD,QAAW,EAAE,GAAY,EAAE,aAAqB,GAAG,EAAE,KAA4C,EAAQ,EAAE;IACxL,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC;QACrB,OAAO,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,sBAAc,CAAC,QAAQ,EAAE,CAAC,EAAE,UAAU,EAAE,KAAK,CAAC,CAAC,CAAC;IAEzE,MAAM,IAAI,GAAM,GAAG,CAAC;IACpB,MAAM,KAAK,GAAG,QAAQ,CAAC,IAAI,CAAC,CAAC;IAC7B,IAAI,CAAC,KAAK;QACT,MAAM,IAAI,yBAAY,CAAC,UAAU,EAAE,mBAAmB,GAAG,WAAW,CAAC,CAAC;IAEvE,IAAI,CAAC,KAAK;QACT,OAAO;IAER,IAAI,OAAO,KAAK,KAAK,QAAQ;QAC5B,OAAO;IAER,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC9B,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC9B,IAAI,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC;gBACrB,OAAO;YAER,MAAM,IAAI,yBAAY,CAAC,UAAU,EAAE,iBAAiB,KAAK,uCAAuC,KAAK,EAAE,CAAC,CAAA;SACxG;QAED,OAAO,KAAK,CAAC,KAAK,CAAC,CAAC;KACpB;IAED,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,UAAU;QAC3D,KAAK,CAAC,KAAK,CAAC,CAAA;AACd,CAAC,CAAC;AA5BW,QAAA,cAAc,kBA4BzB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { Dispatcher } from "@intuitionrobotics/ts-common/core/dispatcher";
|
|
1
2
|
import * as express from "express";
|
|
2
|
-
import { Dispatcher } from "@intuitionrobotics/ts-common";
|
|
3
3
|
export declare type Express = express.Express;
|
|
4
4
|
export declare type ExpressRouter = express.Router;
|
|
5
5
|
export declare type ExpressRequest = express.Request<any>;
|
|
@@ -1,26 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.dispatch_queryRequestInfo = void 0;
|
|
24
|
-
const
|
|
25
|
-
exports.dispatch_queryRequestInfo = new
|
|
4
|
+
const dispatcher_1 = require("@intuitionrobotics/ts-common/core/dispatcher");
|
|
5
|
+
exports.dispatch_queryRequestInfo = new dispatcher_1.Dispatcher('__queryRequestInfo');
|
|
26
6
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/main/app-backend/utils/types.ts"],"names":[],"mappings":";;;AAAA,6EAA0E;AAc7D,QAAA,yBAAyB,GAAG,IAAI,uBAAU,CAAyC,oBAAoB,CAAC,CAAC"}
|
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.ActionButton = void 0;
|
|
24
4
|
const React = require("react");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionButton.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/ActionButton.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ActionButton.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/ActionButton.tsx"],"names":[],"mappings":";;;AAAA,+BAA+B;AAExB,MAAM,YAAY,GAAG,CAAC,KAA4F,EAAE,EAAE;IAC5H,IAAI,OAAkB,CAAC;IACvB,IAAI,OAAO,KAAK,CAAC,MAAM,KAAK,QAAQ;QACnC,OAAO,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAgB,EAAE,QAAQ,CAAC,CAAC;;QAE9D,OAAO,GAAG,KAAK,CAAC,MAAM,CAAC;IACxB,OAAO,6BAAK,KAAK,EAAE,EAAC,OAAO,EAAE,CAAC,EAAC;QAC9B,6BACC,SAAS,EAAE,aAAa,OAAO,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAA,CAAC,CAAC,KAAK,CAAC,QAAQ,CAAA,CAAC,CAAA,EAAE,EAAE,EAC/E,KAAK,EAAE,OAAO,KAAK,CAAC,QAAQ,KAAK,QAAQ,CAAA,CAAC,CAAA,KAAK,CAAC,QAAQ,CAAA,CAAC,CAAA,EAAE,EAC3D,GAAG,EAAE,KAAK,CAAC,IAAI,EACf,OAAO,EAAE,OAAO,GAAG,CACf,CAAA;AACP,CAAC,CAAC;AAbW,QAAA,YAAY,gBAavB"}
|
|
@@ -1,34 +1,15 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.DropDown = exports.listStyle = exports.inputStyle = exports.headerStyle = void 0;
|
|
24
4
|
const React = require("react");
|
|
25
5
|
const FilterInput_1 = require("./FilterInput");
|
|
26
|
-
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
27
6
|
const KeyboardListener_1 = require("../tools/KeyboardListener");
|
|
28
7
|
const tools_1 = require("../utils/tools");
|
|
29
8
|
const Adapter_1 = require("./adapter/Adapter");
|
|
30
9
|
const Tree_1 = require("./tree/Tree");
|
|
31
10
|
const Overlay_1 = require("./Overlay");
|
|
11
|
+
const random_tools_1 = require("@intuitionrobotics/ts-common/utils/random-tools");
|
|
12
|
+
const tools_2 = require("@intuitionrobotics/ts-common/utils/tools");
|
|
32
13
|
const defaultWidth = "222px";
|
|
33
14
|
const defaultTitleHeight = "28px";
|
|
34
15
|
const defaultListHeight = "150px";
|
|
@@ -130,8 +111,8 @@ class DropDown extends React.Component {
|
|
|
130
111
|
return React.createElement(FilterInput_1.FilterInput, Object.assign({ key: this.state.id, id: `${this.props.id}-input`, filter: this.props.filter, list: this.props.adapter.data, onChange: (filteredOptions, filterBy) => {
|
|
131
112
|
this.setState(state => {
|
|
132
113
|
state.adapter.data = this.props.autocomplete && this.props.filter && !filterBy.length ? [] : filteredOptions;
|
|
133
|
-
console.log(`filter: ${this.props.id} (${filterBy}) -> ${
|
|
134
|
-
console.log(`state.adapter.data: ${
|
|
114
|
+
console.log(`filter: ${this.props.id} (${filterBy}) -> ${tools_2.__stringify(filteredOptions)}`);
|
|
115
|
+
console.log(`state.adapter.data: ${tools_2.__stringify(state.adapter.data)}`);
|
|
135
116
|
return {
|
|
136
117
|
adapter: state.adapter,
|
|
137
118
|
filterTextLength: filterBy.length
|
|
@@ -201,7 +182,7 @@ class DropDown extends React.Component {
|
|
|
201
182
|
}
|
|
202
183
|
exports.DropDown = DropDown;
|
|
203
184
|
DropDown.defaultProps = {
|
|
204
|
-
id:
|
|
185
|
+
id: random_tools_1.generateHex(8),
|
|
205
186
|
headerStylable: { style: exports.headerStyle },
|
|
206
187
|
listStylable: { style: exports.listStyle },
|
|
207
188
|
inputStylable: { style: exports.inputStyle }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DropDown.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/DropDown.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"DropDown.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/DropDown.tsx"],"names":[],"mappings":";;;AAAA,+BAA+B;AAC/B,+CAA0C;AAC1C,gEAA2D;AAC3D,0CAA+C;AAC/C,+CAA2C;AAC3C,sCAAiC;AAEjC,uCAAkC;AAClC,kFAA8E;AAC9E,oEAAuE;AAEvE,MAAM,YAAY,GAAG,OAAO,CAAC;AAC7B,MAAM,kBAAkB,GAAG,MAAM,CAAC;AAClC,MAAM,iBAAiB,GAAG,OAAO,CAAC;AAElC,+BAA+B;AAC/B,8BAA8B;AAC9B,IAAI;AAEJ,MAAM,YAAY,GAAwB;IACzC,OAAO,EAAE,cAAc;IACvB,QAAQ,EAAE,UAAU;CACpB,CAAC;AAEW,QAAA,WAAW,GAAwB;IAC/C,OAAO,EAAE,MAAM;IACf,UAAU,EAAE,QAAQ;IACpB,SAAS,EAAE,YAAY;IACvB,QAAQ,EAAE,UAAU;IACpB,MAAM,EAAE,WAAW;IACnB,YAAY,EAAE,CAAC;IACf,KAAK,EAAE,OAAO;IACd,eAAe,EAAE,OAAO;IACxB,KAAK,EAAE,YAAY;IACnB,MAAM,EAAE,kBAAkB;CAC1B,CAAC;AAEW,QAAA,UAAU,GAAwB;IAC9C,MAAM,EAAE,OAAO;IACf,SAAS,EAAE,YAAY;IACvB,OAAO,EAAE,MAAM;IACf,oBAAoB;IACpB,KAAK,EAAE,MAAM;CACb,CAAC;AAEF,MAAM,kBAAkB,GAAwB;IAC/C,OAAO,EAAE,cAAc;IACvB,QAAQ,EAAE,UAAU;IACpB,MAAM,EAAE,EAAE;CACV,CAAC;AAEW,QAAA,SAAS,GAAwB;IAC7C,SAAS,EAAE,YAAY;IACvB,eAAe,EAAE,YAAY;I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AAW,EAAC;IACpC,YAAY,EAAE,EAAC,KAAK,EAAE,iBAAS,EAAC;IAChC,aAAa,EAAE,EAAC,KAAK,EAAE,kBAAU,EAAC;CAClC,CAAC;AAsBa,qBAAY,GAAG,CAAC,SAA8B,EAAE,EAAE;IAChE,OAAO,SAAS,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,iBAAO,CAAC,SAAS,CAAC,YAAY,IAAI,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;AACvH,CAAC,CAAC;AAsKH,MAAM,2BAA2B,GAAG,CAAC,EAAU,EAAE,EAAE;IAClD,OAAO,CAAC,IAAoB,EAAE,CAAgB,EAAE,EAAE;;QACjD,IAAI,CAAC,CAAC,QAAQ,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC;YAC3F,MAAA,QAAQ,CAAC,cAAc,CAAC,GAAG,EAAE,QAAQ,CAAC,0CAAE,KAAK,GAAG;IAClD,CAAC,CAAC;AACH,CAAC,CAAC"}
|
|
@@ -1,30 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.FilterInput = void 0;
|
|
24
4
|
const React = require("react");
|
|
25
5
|
const filter_tools_1 = require("@intuitionrobotics/ts-common/utils/filter-tools");
|
|
26
6
|
const TS_Input_1 = require("./TS_Input");
|
|
27
|
-
const
|
|
7
|
+
const random_tools_1 = require("@intuitionrobotics/ts-common/utils/random-tools");
|
|
8
|
+
const object_tools_1 = require("@intuitionrobotics/ts-common/utils/object-tools");
|
|
28
9
|
class FilterInput extends React.Component {
|
|
29
10
|
constructor(props) {
|
|
30
11
|
super(props);
|
|
@@ -46,7 +27,7 @@ class FilterInput extends React.Component {
|
|
|
46
27
|
this.callOnChange(this.props.list, "");
|
|
47
28
|
}
|
|
48
29
|
shouldComponentUpdate(nextProps, nextState, nextContext) {
|
|
49
|
-
const b = this.notifyChanges = !
|
|
30
|
+
const b = this.notifyChanges = !object_tools_1.compare(this.props.list, nextProps.list);
|
|
50
31
|
if (b)
|
|
51
32
|
this.callOnChange(nextProps.list, "");
|
|
52
33
|
return b;
|
|
@@ -58,6 +39,6 @@ class FilterInput extends React.Component {
|
|
|
58
39
|
}
|
|
59
40
|
exports.FilterInput = FilterInput;
|
|
60
41
|
FilterInput.defaultProps = {
|
|
61
|
-
id:
|
|
42
|
+
id: random_tools_1.generateHex(16)
|
|
62
43
|
};
|
|
63
44
|
//# sourceMappingURL=FilterInput.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FilterInput.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/FilterInput.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"FilterInput.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/FilterInput.tsx"],"names":[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IAAI,EAAE,SAAS,CAAC,IAAI,CAAC,CAAC;QACzE,IAAI,CAAC;YACJ,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;QAEvC,OAAO,CAAC,CAAC;IACV,CAAC;IAeD,MAAM;QAEL,MAAM,EAAC,EAAE,EAAE,WAAW,EAAE,KAAK,EAAC,GAAG,IAAI,CAAC,KAAK,CAAC;QAC5C,OAAO,CACN,oBAAC,mBAAQ,IACR,IAAI,EAAC,MAAM,EACX,EAAE,EAAE,EAAE,EACN,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,iBAAiB,EACnC,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,EACrC,KAAK,EAAE,KAAK,EACZ,WAAW,EAAE,WAAW,EACxB,SAAS,EAAE,IAAI,CAAC,KAAK,CAAC,SAAS,EAC/B,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,EACvB,cAAc,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,GACxC,CACF,CAAC;IACH,CAAC;;AA1DF,kCA4DC;AAvDO,wBAAY,GAAoC;IACtD,EAAE,EAAE,0BAAW,CAAC,EAAE,CAAC;CACnB,CAAC"}
|
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.GenericSelect = void 0;
|
|
24
4
|
const React = require("react");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GenericSelect.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/GenericSelect.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"GenericSelect.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/GenericSelect.tsx"],"names":[],"mappings":";;;AAAA,+BAA+B;AAC/B,+CAAgD;AAoBhD,MAAa,aACZ,SAAQ,KAAK,CAAC,SAA0B;IAExC,YAAY,KAAe;QAC1B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,KAAK,GAAG;YACZ,UAAU,EAAE,KAAK;SACjB,CAAC;QACF,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACxD,CAAC;IAED,MAAM;QACL,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC;QACzB,MAAM,KAAK,GAAiB,EAAE,CAAC;QAC/B,MAAM,OAAO,GAAG,KAAK,CAAC,OAAO,CAAC;QAC9B,IAAI,KAAK,GAAsB,IAAI,CAAC;QACpC,IAAI,OAAO,EAAE;YACZ,MAAM,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC;YAC5C,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,GAAG,EAAE,EAAE;gBAC/B,MAAM,kBAAkB,GAAG,KAAK,CAAC,YAAY,CAAC,MAAM,CAAC,CAAA;gBACrD,MAAM,IAAI,GAAe,EAAC,KAAK,EAA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QACR,MAAM,GAAG,GAAG,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAC/B,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QACvC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC7B,CAAC;CAED;AA1DD,sCA0DC;AAED,MAAM,UAAU;IAIf,YAAY,CAAS;QACpB,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC;QACf,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC;IAChB,CAAC;CACD"}
|
|
@@ -1,24 +1,4 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
/*
|
|
3
|
-
* Thunderstorm is a full web app framework!
|
|
4
|
-
*
|
|
5
|
-
* Typescript & Express backend infrastructure that natively runs on firebase function
|
|
6
|
-
* Typescript & React frontend infrastructure
|
|
7
|
-
*
|
|
8
|
-
* Copyright (C) 2020 Intuition Robotics
|
|
9
|
-
*
|
|
10
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
11
|
-
* you may not use this file except in compliance with the License.
|
|
12
|
-
* You may obtain a copy of the License at
|
|
13
|
-
*
|
|
14
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
15
|
-
*
|
|
16
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
17
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
18
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
19
|
-
* See the License for the specific language governing permissions and
|
|
20
|
-
* limitations under the License.
|
|
21
|
-
*/
|
|
22
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
3
|
exports.Overlay = void 0;
|
|
24
4
|
const React = require("react");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Overlay.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/Overlay.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Overlay.js","sourceRoot":"","sources":["../../../src/main/app-frontend/components/Overlay.tsx"],"names":[],"mappings":";;;AAAA,+BAA+B;AAS/B,MAAM,YAAY,GAAG,CAAC,MAAc,EAAiB,EAAE,CAAC,CAAC;IACxD,MAAM;IACN,QAAQ,EAAE,OAAO;IACjB,GAAG,EAAE,CAAC;IACN,IAAI,EAAE,CAAC;IACP,KAAK,EAAE,CAAC;IACR,MAAM,EAAE,CAAC;CACT,CAAC,CAAC;AACH,MAAM,aAAa,GAAG,CAAC,MAAc,EAAE,EAAE,CAAC,CAAC;IAC1C,MAAM;IACN,OAAO,EAAE,cAAc;CACvB,CAAC,CAAC;AAEH,MAAa,OACZ,SAAQ,KAAK,CAAC,SAAgB;IAM9B,MAAM;QACL,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,WAAW;YAC1B,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC;QAE5B,OAAO;YACN,6BAAK,KAAK,EAAE,aAAa,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,IAC9C,IAAI,CAAC,KAAK,CAAC,QAAQ,CACf;YACN,6BACC,OAAO,EAAE,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,EAClD,KAAK,EAAE,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,GACrC,CACA,CAAA;IACJ,CAAC;;AApBF,0BAqBC;AAlBO,oBAAY,GAAmB;IACrC,MAAM,EAAE,CAAC;CACT,CAAC"}
|