@intuitionrobotics/thunderstorm 0.41.69 → 0.41.70
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,59 +19,41 @@
|
|
|
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.Component_Form = void 0;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
_this.setState(function (state) {
|
|
24
|
+
const React = require("react");
|
|
25
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
26
|
+
class Component_Form extends React.Component {
|
|
27
|
+
constructor(p) {
|
|
28
|
+
super(p);
|
|
29
|
+
this.onValueChanged = (value, id) => {
|
|
30
|
+
this.setState(state => {
|
|
45
31
|
state.value[id] = value;
|
|
46
32
|
return state;
|
|
47
33
|
});
|
|
48
34
|
};
|
|
49
|
-
|
|
50
|
-
return _this;
|
|
35
|
+
this.state = { value: p.value };
|
|
51
36
|
}
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
Component_Form.prototype.renderField = function (data, key) {
|
|
58
|
-
var _this = this;
|
|
37
|
+
render() {
|
|
38
|
+
const data = this.state.value;
|
|
39
|
+
return (React.createElement("div", { className: `ll_v_c ${this.props.className}`, style: { justifyContent: 'space-evenly' } }, ts_common_1._keys(this.props.form).map(key => this.renderField(data, key))));
|
|
40
|
+
}
|
|
41
|
+
renderField(data, key) {
|
|
59
42
|
var _a;
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
key
|
|
63
|
-
field
|
|
43
|
+
const field = this.props.form[key];
|
|
44
|
+
const fieldProps = {
|
|
45
|
+
key,
|
|
46
|
+
field,
|
|
64
47
|
value: data[key],
|
|
65
48
|
onChange: this.onValueChanged,
|
|
66
49
|
showErrors: this.props.showErrors,
|
|
67
50
|
validator: (_a = this.props.validator) === null || _a === void 0 ? void 0 : _a[key],
|
|
68
|
-
onAccept:
|
|
69
|
-
|
|
51
|
+
onAccept: () => {
|
|
52
|
+
this.props.onAccept(this.state.value);
|
|
70
53
|
}
|
|
71
54
|
};
|
|
72
55
|
return this.props.renderer[key](fieldProps);
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
}(React.Component));
|
|
56
|
+
}
|
|
57
|
+
}
|
|
76
58
|
exports.Component_Form = Component_Form;
|
|
77
59
|
//# sourceMappingURL=Form.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Form.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/form/Form.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"Form.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/form/Form.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAOH,+BAA+B;AAC/B,4DAIsC;AAiBtC,MAAa,cACZ,SAAQ,KAAK,CAAC,SAA6B;IAE3C,YAAY,CAAW;QACtB,KAAK,CAAC,CAAC,CAAC,CAAC;QA6BF,mBAAc,GAAG,CAAC,KAAU,EAAE,EAAW,EAAE,EAAE;YACpD,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE;gBACrB,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC;gBACxB,OAAO,KAAK,CAAA;YACb,CAAC,CAAC,CAAC;QACJ,CAAC,CAAC;QAjCD,IAAI,CAAC,KAAK,GAAG,EAAC,KAAK,EAAE,CAAC,CAAC,KAAK,EAAC,CAAA;IAC9B,CAAC;IAED,MAAM;QACL,MAAM,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC;QAC9B,OAAO,CACN,6BAAK,SAAS,EAAE,UAAU,IAAI,CAAC,KAAK,CAAC,SAAS,EAAE,EAAE,KAAK,EAAE,EAAC,cAAc,EAAE,cAAc,EAAC,IACvF,iBAAK,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,WAAW,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC,CAC1D,CACN,CAAA;IACF,CAAC;IAEO,WAAW,CAAC,IAAgB,EAAE,GAAY;;QACjD,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACnC,MAAM,UAAU,GAAuB;YACtC,GAAG;YACH,KAAK;YACL,KAAK,EAAE,IAAI,CAAC,GAAG,CAAC;YAChB,QAAQ,EAAE,IAAI,CAAC,cAAc;YAC7B,UAAU,EAAE,IAAI,CAAC,KAAK,CAAC,UAAU;YACjC,SAAS,QAAE,IAAI,CAAC,KAAK,CAAC,SAAS,0CAAG,GAAG,CAAC;YACtC,QAAQ,EAAE,GAAG,EAAE;gBACd,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,KAAU,CAAC,CAAC;YAC5C,CAAC;SACD,CAAC;QACF,OAAO,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,UAAU,CAAC,CAAC;IAC7C,CAAC;CAQD;AAvCD,wCAuCC"}
|
|
@@ -19,73 +19,45 @@
|
|
|
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.Example_NewProps = void 0;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
_this.state = { index: 0 };
|
|
54
|
-
return _this;
|
|
24
|
+
const React = require("react");
|
|
25
|
+
class Example_NewProps extends React.Component {
|
|
26
|
+
constructor(props) {
|
|
27
|
+
super(props);
|
|
28
|
+
this.state = { index: 0 };
|
|
55
29
|
}
|
|
56
|
-
|
|
57
|
-
|
|
30
|
+
render() {
|
|
31
|
+
const Renderer = this.props.renderer;
|
|
58
32
|
return React.createElement("div", null,
|
|
59
33
|
React.createElement("div", { style: { marginBottom: "10px" } }, this.props.name),
|
|
60
34
|
this.renderList(Renderer),
|
|
61
35
|
this.renderToggle(Renderer));
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
var _this = this;
|
|
36
|
+
}
|
|
37
|
+
renderToggle(Renderer) {
|
|
65
38
|
if (!this.props.showToggle)
|
|
66
39
|
return;
|
|
67
40
|
return React.createElement("div", null,
|
|
68
|
-
React.createElement("div", { onClick:
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
if (index >=
|
|
41
|
+
React.createElement("div", { onClick: () => {
|
|
42
|
+
this.setState(state => {
|
|
43
|
+
let index = state.index + 1;
|
|
44
|
+
if (index >= this.props.data.length)
|
|
72
45
|
index = 0;
|
|
73
|
-
return { index
|
|
46
|
+
return { index };
|
|
74
47
|
});
|
|
75
48
|
}, style: { width: "fit-content" } }, "click to switch"),
|
|
76
|
-
React.createElement(Renderer,
|
|
77
|
-
}
|
|
78
|
-
|
|
49
|
+
React.createElement(Renderer, Object.assign({}, this.props.data[this.state.index])));
|
|
50
|
+
}
|
|
51
|
+
renderList(Renderer) {
|
|
79
52
|
if (!this.props.showList)
|
|
80
53
|
return;
|
|
81
|
-
return React.createElement("div", { className: "ll_v_l", style: { marginBottom: "20px" } }, this.props.data.map(
|
|
82
|
-
React.createElement(Renderer,
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
showList: true,
|
|
86
|
-
showToggle: true
|
|
87
|
-
};
|
|
88
|
-
return Example_NewProps;
|
|
89
|
-
}(React.Component));
|
|
54
|
+
return React.createElement("div", { className: "ll_v_l", style: { marginBottom: "20px" } }, this.props.data.map((_data, index) => React.createElement("div", { key: index, style: { marginBottom: "5px" } },
|
|
55
|
+
React.createElement(Renderer, Object.assign({}, _data)))));
|
|
56
|
+
}
|
|
57
|
+
}
|
|
90
58
|
exports.Example_NewProps = Example_NewProps;
|
|
59
|
+
Example_NewProps.defaultProps = {
|
|
60
|
+
showList: true,
|
|
61
|
+
showToggle: true
|
|
62
|
+
};
|
|
91
63
|
//# sourceMappingURL=Example_NewProps.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Example_NewProps.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/playground/Example_NewProps.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"Example_NewProps.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/playground/Example_NewProps.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH,+BAA+B;AAa/B,MAAa,gBACZ,SAAQ,KAAK,CAAC,SAA0B;IAOxC,YAAY,KAAe;QAC1B,KAAK,CAAC,K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,KAAK,EAAE,EAAE,CAAC,6BAAK,GAAG,EAAE,KAAK,EAAE,KAAK,EAAE,EAAC,YAAY,EAAE,KAAK,EAAC;YAAE,oBAAC,QAAQ,oBAAK,KAAK,EAAG,CAAM,CAAC,CAC9G,CAAC;IACR,CAAC;;AAjDF,4CAkDC;AA/CO,6BAAY,GAAG;IACrB,QAAQ,EAAE,IAAI;IACd,UAAU,EAAE,IAAI;CAChB,CAAC"}
|
|
@@ -19,67 +19,39 @@
|
|
|
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.Playground = void 0;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
_this.state = { selectedScreen: screen };
|
|
60
|
-
return _this;
|
|
24
|
+
const React = require("react");
|
|
25
|
+
const GenericSelect_1 = require("../GenericSelect");
|
|
26
|
+
const HistoryModule_1 = require("../../modules/HistoryModule");
|
|
27
|
+
const Example_NewProps_1 = require("./Example_NewProps");
|
|
28
|
+
const PLAYGROUND = "playground";
|
|
29
|
+
class Playground extends React.Component {
|
|
30
|
+
constructor(props) {
|
|
31
|
+
super(props);
|
|
32
|
+
const queryParam = HistoryModule_1.BrowserHistoryModule.getQueryParams()[PLAYGROUND];
|
|
33
|
+
const screen = this.props.screens.find(s => s.name === queryParam);
|
|
34
|
+
this.state = { selectedScreen: screen };
|
|
61
35
|
}
|
|
62
|
-
|
|
63
|
-
var _this = this;
|
|
36
|
+
render() {
|
|
64
37
|
return React.createElement("div", { className: 'match_height match_width' },
|
|
65
38
|
React.createElement("div", { className: 'match_height match_width', style: { alignSelf: "start", padding: "20px" } },
|
|
66
|
-
React.createElement(GenericSelect_1.GenericSelect, { iconClose: this.props.iconClose, iconOpen: this.props.iconOpen, selectedOption: this.state.selectedScreen, options: this.props.screens, onChange:
|
|
67
|
-
|
|
39
|
+
React.createElement(GenericSelect_1.GenericSelect, { iconClose: this.props.iconClose, iconOpen: this.props.iconOpen, selectedOption: this.state.selectedScreen, options: this.props.screens, onChange: (screen) => {
|
|
40
|
+
this.setState({ selectedScreen: screen });
|
|
68
41
|
HistoryModule_1.BrowserHistoryModule.addQueryParam(PLAYGROUND, screen.name);
|
|
69
|
-
}, styles: this.props.selectStyle, presentation:
|
|
42
|
+
}, styles: this.props.selectStyle, presentation: (screen) => screen.name })),
|
|
70
43
|
React.createElement("div", { style: { borderStyle: "double", display: "inline-block", padding: "12px", margin: "12px" } }, this.renderPlayground()));
|
|
71
|
-
}
|
|
72
|
-
|
|
44
|
+
}
|
|
45
|
+
renderPlayground() {
|
|
73
46
|
if (!this.state.selectedScreen)
|
|
74
47
|
return React.createElement("div", null, "Select a playground");
|
|
75
|
-
|
|
48
|
+
const data = this.state.selectedScreen.data;
|
|
76
49
|
if (!data || data.length === 0)
|
|
77
50
|
return React.createElement(this.state.selectedScreen.renderer, null);
|
|
78
51
|
if (data.length === 1)
|
|
79
|
-
return React.createElement(this.state.selectedScreen.renderer,
|
|
52
|
+
return React.createElement(this.state.selectedScreen.renderer, Object.assign({}, data[0]));
|
|
80
53
|
return React.createElement(Example_NewProps_1.Example_NewProps, { name: this.state.selectedScreen.name, data: data, renderer: this.state.selectedScreen.renderer });
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
}(React.Component));
|
|
54
|
+
}
|
|
55
|
+
}
|
|
84
56
|
exports.Playground = Playground;
|
|
85
57
|
//# sourceMappingURL=Playground.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Playground.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/playground/Playground.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"Playground.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/playground/Playground.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH,+BAA+B;AAC/B,oDAA+C;AAC/C,+DAAiE;AACjE,yDAAoD;AAEpD,MAAM,UAAU,GAAG,YAAY,CAAA;AAmB/B,MAAa,UACZ,SAAQ,KAAK,CAAC,SAAiC;IAE/C,YAAY,KAAsB;QACjC,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,MAAM,UAAU,GAAG,oCAAoB,CAAC,cAAc,EAAE,CAAC,UAAU,CAAC,CAAC;QACrE,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,UAAU,CAAC,CAAC;QAC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AAK,CAAC,cAAc,CAAC,QAAQ,OAAE,CAAA;QAE7C,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;YACpB,OAAO,oBAAC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,QAAQ,oBAAK,IAAI,CAAC,CAAC,CAAC,EAAG,CAAA;QAE1D,OAAO,oBAAC,mCAAgB,IAAC,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,QAAQ,GAAG,CAAA;IAC3H,CAAC;CACD;AA3CD,gCA2CC"}
|
|
@@ -19,36 +19,20 @@
|
|
|
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.MenuComponent = void 0;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
_this.id = _this.props.id || ts_common_1.generateHex(8);
|
|
46
|
-
return _this;
|
|
24
|
+
const React = require("react");
|
|
25
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
26
|
+
const BaseComponent_1 = require("../../core/BaseComponent");
|
|
27
|
+
const Tree_1 = require("./Tree");
|
|
28
|
+
class MenuComponent extends BaseComponent_1.BaseComponent {
|
|
29
|
+
constructor(props) {
|
|
30
|
+
super(props);
|
|
31
|
+
this.id = this.props.id || ts_common_1.generateHex(8);
|
|
47
32
|
}
|
|
48
|
-
|
|
33
|
+
render() {
|
|
49
34
|
return React.createElement(Tree_1.Tree, { id: this.id, adapter: this.props.adapter, onNodeClicked: this.props.onNodeClicked });
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
}(BaseComponent_1.BaseComponent));
|
|
35
|
+
}
|
|
36
|
+
}
|
|
53
37
|
exports.MenuComponent = MenuComponent;
|
|
54
38
|
//# sourceMappingURL=MenuComponent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MenuComponent.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/tree/MenuComponent.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"MenuComponent.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/tree/MenuComponent.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAGH,+BAA+B;AAC/B,4DAAyD;AACzD,4DAAuD;AAEvD,iCAA4B;AAU5B,MAAa,aACZ,SAAQ,6BAAiC;IAGzC,YAAY,KAAyB;QACpC,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,EAAE,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,IAAI,uBAAW,CAAC,CAAC,CAAC,CAAC;IAC3C,CAAC;IAED,MAAM;QACL,OAAO,oBAAC,WAAI,IACX,EAAE,EAAE,IAAI,CAAC,EAAE,EACX,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,OAAO,EAC3B,aAAa,EAAE,IAAI,CAAC,KAAK,CAAC,aAAa,GACtC,CAAA;IACH,CAAC;CACD;AAhBD,sCAgBC"}
|
|
@@ -19,51 +19,35 @@
|
|
|
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.MultiTypeAdapter = void 0;
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
_this.rendererMap = rendererMap;
|
|
45
|
-
return _this;
|
|
24
|
+
const ts_common_1 = require("@intuitionrobotics/ts-common");
|
|
25
|
+
const Adapter_1 = require("../adapter/Adapter");
|
|
26
|
+
class MultiTypeAdapter extends Adapter_1.Adapter {
|
|
27
|
+
constructor(data, rendererMap) {
|
|
28
|
+
super(data);
|
|
29
|
+
this.hideRoot = true;
|
|
30
|
+
this.rendererMap = rendererMap;
|
|
46
31
|
}
|
|
47
|
-
|
|
32
|
+
filter(obj, key) {
|
|
48
33
|
return key !== "item" && key !== 'rendererType';
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
if (!ts_common_1._keys(obj).find(
|
|
34
|
+
}
|
|
35
|
+
adjust(obj) {
|
|
36
|
+
if (!ts_common_1._keys(obj).find(key => key === "_children"))
|
|
52
37
|
return { data: obj, deltaPath: "" };
|
|
53
38
|
// @ts-ignore
|
|
54
|
-
|
|
39
|
+
const objElement = obj['_children'];
|
|
55
40
|
// @ts-ignore
|
|
56
41
|
objElement.type = obj.type;
|
|
57
42
|
// @ts-ignore
|
|
58
43
|
objElement.item = obj.item;
|
|
59
44
|
// @ts-ignore
|
|
60
45
|
return { data: objElement, deltaPath: '_children' };
|
|
61
|
-
}
|
|
62
|
-
|
|
46
|
+
}
|
|
47
|
+
resolveRenderer(propKey) {
|
|
63
48
|
return this.rendererMap[propKey];
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
}(Adapter_1.Adapter));
|
|
49
|
+
}
|
|
50
|
+
}
|
|
67
51
|
exports.MultiTypeAdapter = MultiTypeAdapter;
|
|
68
52
|
//
|
|
69
53
|
// export const GenericRenderer_Default = (rendererMap: RendererMap) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MultiTypeAdaptor.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/tree/MultiTypeAdaptor.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"MultiTypeAdaptor.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/tree/MultiTypeAdaptor.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH,4DAAmD;AACnD,gDAA4C;AAG5C,MAAa,gBACZ,SAAQ,iBAAU;IAIlB,YAAY,IAAS,EAAE,WAAe;QACrC,KAAK,CAAC,IAAI,CAAC,CAAC;QACZ,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC;QACrB,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;IAChC,CAAC;IAGD,MAAM,CAAC,GAAQ,EAAE,GAAc;QAC9B,OAAO,GAAG,KAAK,MAAM,IAAI,GAAG,KAAK,cAAc,CAAC;IACjD,CAAC;IAED,MAAM,CAAC,GAAQ;QACd,IAAI,CAAC,iBAAK,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,WAAW,CAAC;YAC/C,OAAO,EAAC,IAAI,EAAE,GAAG,EAAE,SAAS,EAAE,EAAE,EAAC,CAAC;QAEnC,aAAa;QACb,MAAM,UAAU,GAAG,GAAG,CAAC,WAAW,CAAC,CAAC;QACpC,aAAa;QACb,UAAU,CAAC,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;QAC3B,aAAa;QACb,UAAU,CAAC,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;QAE3B,aAAa;QACb,OAAO,EAAC,IAAI,EAAE,UAAU,EAAE,SAAS,EAAE,WAAW,EAAC,CAAC;IAEnD,CAAC;IAED,eAAe,CAAC,OAAe;QAC9B,OAAO,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC;IAClC,CAAC;CACD;AAnCD,4CAmCC;AAED,EAAE;AACF,yEAAyE;AACzE,EAAE;AACF,mDAAmD;AACnD,kDAAkD;AAClD,2EAA2E;AAC3E,MAAM;AACN,EAAE;AACF,iCAAiC;AACjC,iEAAiE;AACjE,mCAAmC;AACnC,mCAAmC;AACnC,wBAAwB;AACxB,oDAAoD;AACpD,kBAAkB;AAClB,4CAA4C;AAC5C,EAAE;AACF,aAAa;AACb,qFAAqF;AACrF,gCAAgC;AAChC,2BAA2B;AAC3B,uBAAuB;AACvB,qCAAqC;AACrC,kEAAkE;AAClE,oDAAoD;AACpD,+CAA+C;AAC/C,YAAY;AACZ,MAAM;AACN,MAAM;AACN,KAAK"}
|
|
@@ -19,41 +19,13 @@
|
|
|
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.SimpleNodeRenderer = exports.SimpleTreeNodeRenderer = void 0;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
return _super !== null && _super.apply(this, arguments) || this;
|
|
54
|
-
}
|
|
55
|
-
SimpleTreeNodeRenderer.prototype.renderCollapse = function () {
|
|
56
|
-
var toDisplay;
|
|
24
|
+
const React = require("react");
|
|
25
|
+
const BaseRenderer_1 = require("../adapter/BaseRenderer");
|
|
26
|
+
class SimpleTreeNodeRenderer extends BaseRenderer_1.BaseNodeRenderer {
|
|
27
|
+
renderCollapse() {
|
|
28
|
+
let toDisplay;
|
|
57
29
|
if (typeof this.props.item !== "object")
|
|
58
30
|
toDisplay = "";
|
|
59
31
|
else if (Object.keys(this.props.item).length === 0)
|
|
@@ -62,35 +34,29 @@ var SimpleTreeNodeRenderer = /** @class */ (function (_super) {
|
|
|
62
34
|
toDisplay = "-";
|
|
63
35
|
else
|
|
64
36
|
toDisplay = "+";
|
|
65
|
-
return React.createElement("div", { className:
|
|
66
|
-
}
|
|
67
|
-
|
|
37
|
+
return React.createElement("div", { className: `clickable`, id: this.props.node.path, onClick: this.props.node.expandToggler, style: { width: "15px" } }, toDisplay);
|
|
38
|
+
}
|
|
39
|
+
renderItem(item) {
|
|
68
40
|
return (React.createElement("div", { className: "ll_h_c" },
|
|
69
41
|
this.renderCollapse(),
|
|
70
42
|
React.createElement("div", { id: this.props.node.path, className: 'clickable', onClick: this.props.node.onClick, style: { backgroundColor: this.props.node.focused ? "red" : "salmon", userSelect: "none" } },
|
|
71
|
-
React.createElement(SimpleNodeRenderer,
|
|
72
|
-
}
|
|
43
|
+
React.createElement(SimpleNodeRenderer, Object.assign({}, this.props)))));
|
|
44
|
+
}
|
|
73
45
|
;
|
|
74
|
-
|
|
75
|
-
}(BaseRenderer_1.BaseNodeRenderer));
|
|
46
|
+
}
|
|
76
47
|
exports.SimpleTreeNodeRenderer = SimpleTreeNodeRenderer;
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
}
|
|
82
|
-
SimpleNodeRenderer.prototype.render = function () {
|
|
83
|
-
var label;
|
|
84
|
-
var item = this.props.item;
|
|
48
|
+
class SimpleNodeRenderer extends React.Component {
|
|
49
|
+
render() {
|
|
50
|
+
let label;
|
|
51
|
+
const item = this.props.item;
|
|
85
52
|
if (typeof item !== "object")
|
|
86
|
-
label =
|
|
53
|
+
label = ` : ${item}`;
|
|
87
54
|
else if (Object.keys(item).length === 0)
|
|
88
55
|
label = " : {}";
|
|
89
56
|
else
|
|
90
57
|
label = "";
|
|
91
58
|
return (this.props.node.propKey || "root") + label;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
}(React.Component));
|
|
59
|
+
}
|
|
60
|
+
}
|
|
95
61
|
exports.SimpleNodeRenderer = SimpleNodeRenderer;
|
|
96
62
|
//# sourceMappingURL=SimpleTreeNodeRenderer.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SimpleTreeNodeRenderer.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/tree/SimpleTreeNodeRenderer.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG
|
|
1
|
+
{"version":3,"file":"SimpleTreeNodeRenderer.js","sourceRoot":"","sources":["../../../../src/main/app-frontend/components/tree/SimpleTreeNodeRenderer.tsx"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;GAmBG;;;AAEH,+BAA+B;AAC/B,0DAGiC;AAEjC,MAAa,sBACZ,SAAQ,+BAAqB;IAE7B,cAAc;QACb,IAAI,SAAS,CAAC;QACd,IAAI,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,KAAK,QAAQ;YACtC,SAAS,GAAG,EAAE,CAAC;aACX,IAAI,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,MAAM,KAAK,CAAC;YACjD,SAAS,GAAG,EAAE,CAAC;aACX,IAAI,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ;YAChC,SAAS,GAAG,GAAG,CAAC;;YAEhB,SAAS,GAAG,GAAG,CAAC;QAEjB,OAAO,6BACN,SAAS,EAAE,WAAW,EACtB,EAAE,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,EACxB,OAAO,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,aAAa,EACtC,KAAK,EAAE,EAAC,KAAK,EAAE,MAAM,EAAC,IACrB,SAAS,CACL,CAAA;IACP,CAAC;IAES,UAAU,CAAC,IAAS;QAC7B,OAAO,CAAC,6BAAK,SAAS,EAAC,QAAQ;YAC7B,IAAI,CAAC,cAAc,EAAE;YACtB,6BACC,EAAE,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,EACxB,SAAS,EAAC,WAAW,EACrB,OAAO,EAAE,IAAI,CAAC,KAAK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