config-editor-base 3.0.9 → 3.1.3
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/dist/index.js +90 -74
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +90 -74
- package/dist/index.modern.js.map +1 -1
- package/package.json +68 -68
package/dist/index.js
CHANGED
|
@@ -18966,15 +18966,23 @@ var PartialConfigLoader = /*#__PURE__*/function (_React$Component) {
|
|
|
18966
18966
|
className: "browse-file-name"
|
|
18967
18967
|
}, jsonFileName))), Object.keys(jsonFile).length ? /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("pre", {
|
|
18968
18968
|
className: "browse-file-preview"
|
|
18969
|
-
}, JSON.stringify(jsonFile, null, 2)), formData ? /*#__PURE__*/React.createElement("div", null, mergedConfigValid ? /*#__PURE__*/React.createElement("
|
|
18970
|
-
className: "btn-highlight"
|
|
18969
|
+
}, JSON.stringify(jsonFile, null, 2)), formData ? /*#__PURE__*/React.createElement("div", null, mergedConfigValid ? /*#__PURE__*/React.createElement("div", {
|
|
18970
|
+
className: "btn-highlight",
|
|
18971
|
+
style: {
|
|
18972
|
+
fontSize: "12px",
|
|
18973
|
+
marginBottom: "8px"
|
|
18974
|
+
}
|
|
18971
18975
|
}, /*#__PURE__*/React.createElement("i", {
|
|
18972
18976
|
className: "fa fa-check"
|
|
18973
|
-
}), "
|
|
18974
|
-
className: "red-text"
|
|
18977
|
+
}), " Merged Configuration File validated") : null, !mergedConfigValid ? /*#__PURE__*/React.createElement("div", {
|
|
18978
|
+
className: "red-text",
|
|
18979
|
+
style: {
|
|
18980
|
+
fontSize: "12px",
|
|
18981
|
+
marginBottom: "8px"
|
|
18982
|
+
}
|
|
18975
18983
|
}, /*#__PURE__*/React.createElement("i", {
|
|
18976
18984
|
className: "fa fa-times"
|
|
18977
|
-
}), "
|
|
18985
|
+
}), " Merged Configuration File is invalid") : null, /*#__PURE__*/React.createElement("button", {
|
|
18978
18986
|
className: "btn btn-primary",
|
|
18979
18987
|
onClick: this.onReview
|
|
18980
18988
|
}, "Merge files")) : null) : null) : /*#__PURE__*/React.createElement("div", {
|
|
@@ -19300,7 +19308,6 @@ var EditorChangesComparison$1 = reactRedux.connect(mapStateToProps$1)(EditorChan
|
|
|
19300
19308
|
var regexRevision = new RegExp('\\d{2}\\.\\d{2}\\.json', 'g');
|
|
19301
19309
|
var isDownloadConfig = false;
|
|
19302
19310
|
var activatedTab;
|
|
19303
|
-
var FormWithNavStable = applyNav__default(Form, EditorNavs);
|
|
19304
19311
|
var EditorSection = /*#__PURE__*/function (_React$Component) {
|
|
19305
19312
|
function EditorSection(props) {
|
|
19306
19313
|
var _this;
|
|
@@ -19835,6 +19842,64 @@ var SimpleDropdown = /*#__PURE__*/function (_React$Component) {
|
|
|
19835
19842
|
return SimpleDropdown;
|
|
19836
19843
|
}(React.Component);
|
|
19837
19844
|
|
|
19845
|
+
var CollapsiblePreview = /*#__PURE__*/function (_React$Component) {
|
|
19846
|
+
function CollapsiblePreview() {
|
|
19847
|
+
return _React$Component.apply(this, arguments) || this;
|
|
19848
|
+
}
|
|
19849
|
+
_inheritsLoose(CollapsiblePreview, _React$Component);
|
|
19850
|
+
var _proto = CollapsiblePreview.prototype;
|
|
19851
|
+
_proto.render = function render() {
|
|
19852
|
+
var _this$props = this.props,
|
|
19853
|
+
open = _this$props.open,
|
|
19854
|
+
onToggle = _this$props.onToggle,
|
|
19855
|
+
data = _this$props.data,
|
|
19856
|
+
onDownload = _this$props.onDownload,
|
|
19857
|
+
label = _this$props.label;
|
|
19858
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
19859
|
+
style: {
|
|
19860
|
+
marginTop: "10px"
|
|
19861
|
+
}
|
|
19862
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
19863
|
+
onClick: onToggle,
|
|
19864
|
+
style: {
|
|
19865
|
+
display: "inline-flex",
|
|
19866
|
+
alignItems: "center",
|
|
19867
|
+
cursor: "pointer",
|
|
19868
|
+
fontSize: "12px",
|
|
19869
|
+
color: "#999999",
|
|
19870
|
+
userSelect: "none"
|
|
19871
|
+
}
|
|
19872
|
+
}, /*#__PURE__*/React.createElement("i", {
|
|
19873
|
+
className: open ? "fa fa-angle-down" : "fa fa-angle-right",
|
|
19874
|
+
style: {
|
|
19875
|
+
marginRight: "6px",
|
|
19876
|
+
width: "8px"
|
|
19877
|
+
}
|
|
19878
|
+
}), label || "Show partial config preview"), open ? /*#__PURE__*/React.createElement("div", {
|
|
19879
|
+
style: {
|
|
19880
|
+
marginTop: "10px"
|
|
19881
|
+
}
|
|
19882
|
+
}, /*#__PURE__*/React.createElement("pre", {
|
|
19883
|
+
className: "browse-file-preview",
|
|
19884
|
+
style: {
|
|
19885
|
+
maxHeight: "300px",
|
|
19886
|
+
overflow: "auto",
|
|
19887
|
+
fontSize: "11px"
|
|
19888
|
+
}
|
|
19889
|
+
}, JSON.stringify(data, null, 2)), onDownload ? /*#__PURE__*/React.createElement("button", {
|
|
19890
|
+
className: "btn",
|
|
19891
|
+
onClick: onDownload,
|
|
19892
|
+
style: {
|
|
19893
|
+
backgroundColor: "#fff",
|
|
19894
|
+
border: "1px solid #ccc",
|
|
19895
|
+
color: "#333",
|
|
19896
|
+
marginTop: "8px"
|
|
19897
|
+
}
|
|
19898
|
+
}, "Download JSON") : null) : null);
|
|
19899
|
+
};
|
|
19900
|
+
return CollapsiblePreview;
|
|
19901
|
+
}(React.Component);
|
|
19902
|
+
|
|
19838
19903
|
var obdPids = [
|
|
19839
19904
|
{
|
|
19840
19905
|
service: "01",
|
|
@@ -22746,48 +22811,28 @@ var OBDTool = /*#__PURE__*/function (_React$Component) {
|
|
|
22746
22811
|
marginBottom: "15px",
|
|
22747
22812
|
marginTop: "10px"
|
|
22748
22813
|
}
|
|
22749
|
-
}, "When testing supported PIDs, make sure the ignition is on for 2 minutes before you connect the device. Let the device be connected for 5 minutes to perform the test."), mergedConfigValid === false && /*#__PURE__*/React.createElement("
|
|
22750
|
-
className: "red-text"
|
|
22814
|
+
}, "When testing supported PIDs, make sure the ignition is on for 2 minutes before you connect the device. Let the device be connected for 5 minutes to perform the test."), mergedConfigValid === false && /*#__PURE__*/React.createElement("div", {
|
|
22815
|
+
className: "red-text",
|
|
22816
|
+
style: {
|
|
22817
|
+
fontSize: "12px",
|
|
22818
|
+
marginBottom: "8px"
|
|
22819
|
+
}
|
|
22751
22820
|
}, /*#__PURE__*/React.createElement("i", {
|
|
22752
22821
|
className: "fa fa-times"
|
|
22753
22822
|
}), " Merged Configuration File is invalid"), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("button", {
|
|
22754
22823
|
className: "btn btn-primary",
|
|
22755
22824
|
onClick: this.onMerge,
|
|
22756
22825
|
disabled: !formData || Object.keys(formData).length === 0 || mergedConfigValid !== true
|
|
22757
|
-
}, "Merge files"), /*#__PURE__*/React.createElement(
|
|
22758
|
-
|
|
22759
|
-
|
|
22760
|
-
disabled: Object.keys(generatedConfig).length === 0,
|
|
22761
|
-
style: {
|
|
22762
|
-
marginLeft: "10px"
|
|
22763
|
-
}
|
|
22764
|
-
}, "Download JSON"))), Object.keys(generatedConfig).length > 0 && /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("label", {
|
|
22765
|
-
style: {
|
|
22766
|
-
display: "flex",
|
|
22767
|
-
alignItems: "center",
|
|
22768
|
-
cursor: "pointer",
|
|
22769
|
-
fontSize: "12px",
|
|
22770
|
-
marginTop: "8px"
|
|
22771
|
-
}
|
|
22772
|
-
}, /*#__PURE__*/React.createElement("input", {
|
|
22773
|
-
type: "checkbox",
|
|
22774
|
-
checked: showPreview,
|
|
22775
|
-
onChange: function onChange() {
|
|
22826
|
+
}, "Merge files"))), Object.keys(generatedConfig).length > 0 && /*#__PURE__*/React.createElement(CollapsiblePreview, {
|
|
22827
|
+
open: showPreview,
|
|
22828
|
+
onToggle: function onToggle() {
|
|
22776
22829
|
return _this9.setState({
|
|
22777
22830
|
showPreview: !showPreview
|
|
22778
22831
|
});
|
|
22779
22832
|
},
|
|
22780
|
-
|
|
22781
|
-
|
|
22782
|
-
|
|
22783
|
-
}
|
|
22784
|
-
}), "Show partial config preview"), showPreview && /*#__PURE__*/React.createElement("div", {
|
|
22785
|
-
style: {
|
|
22786
|
-
marginTop: "10px"
|
|
22787
|
-
}
|
|
22788
|
-
}, /*#__PURE__*/React.createElement("pre", {
|
|
22789
|
-
className: "browse-file-preview"
|
|
22790
|
-
}, JSON.stringify(combinedConfig, null, 2))))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null)));
|
|
22833
|
+
data: combinedConfig,
|
|
22834
|
+
onDownload: this.onDownload
|
|
22835
|
+
})), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null)));
|
|
22791
22836
|
};
|
|
22792
22837
|
return OBDTool;
|
|
22793
22838
|
}(React.Component);
|
|
@@ -25646,11 +25691,7 @@ var FilterBuilderTool = /*#__PURE__*/function (_React$Component) {
|
|
|
25646
25691
|
className: "btn btn-primary",
|
|
25647
25692
|
onClick: _this10.onMerge,
|
|
25648
25693
|
disabled: !_this10.props.formData || Object.keys(_this10.props.formData).length === 0 || _this10.state.mergedConfigValid !== true || !isFirmwareSupported || !isDeviceSupported
|
|
25649
|
-
}, "Merge files"),
|
|
25650
|
-
className: "btn btn-default",
|
|
25651
|
-
onClick: _this10.onDownload,
|
|
25652
|
-
disabled: Object.keys(_this10.state.generatedFilterConfig).length === 0
|
|
25653
|
-
}, "Download JSON")), function () {
|
|
25694
|
+
}, "Merge files")), function () {
|
|
25654
25695
|
var mergeDisabled = !_this10.props.formData || Object.keys(_this10.props.formData).length === 0 || _this10.state.mergedConfigValid !== true || !isFirmwareSupported || !isDeviceSupported;
|
|
25655
25696
|
if (!mergeDisabled) return null;
|
|
25656
25697
|
var reason = "";
|
|
@@ -25673,41 +25714,16 @@ var FilterBuilderTool = /*#__PURE__*/function (_React$Component) {
|
|
|
25673
25714
|
}
|
|
25674
25715
|
}, reason) : null;
|
|
25675
25716
|
}());
|
|
25676
|
-
}(), Object.keys(_this10.state.generatedFilterConfig).length > 0 && /*#__PURE__*/React.createElement(
|
|
25677
|
-
|
|
25678
|
-
|
|
25679
|
-
}
|
|
25680
|
-
}, /*#__PURE__*/React.createElement("label", {
|
|
25681
|
-
style: {
|
|
25682
|
-
display: "flex",
|
|
25683
|
-
alignItems: "center",
|
|
25684
|
-
cursor: "pointer",
|
|
25685
|
-
fontSize: "12px"
|
|
25686
|
-
}
|
|
25687
|
-
}, /*#__PURE__*/React.createElement("input", {
|
|
25688
|
-
type: "checkbox",
|
|
25689
|
-
checked: _this10.state.showFilterPreview,
|
|
25690
|
-
onChange: function onChange() {
|
|
25717
|
+
}(), Object.keys(_this10.state.generatedFilterConfig).length > 0 && /*#__PURE__*/React.createElement(CollapsiblePreview, {
|
|
25718
|
+
open: _this10.state.showFilterPreview,
|
|
25719
|
+
onToggle: function onToggle() {
|
|
25691
25720
|
return _this10.setState({
|
|
25692
25721
|
showFilterPreview: !_this10.state.showFilterPreview
|
|
25693
25722
|
});
|
|
25694
25723
|
},
|
|
25695
|
-
|
|
25696
|
-
|
|
25697
|
-
|
|
25698
|
-
}
|
|
25699
|
-
}), "Show partial config preview"), _this10.state.showFilterPreview && /*#__PURE__*/React.createElement("div", {
|
|
25700
|
-
style: {
|
|
25701
|
-
marginTop: "10px"
|
|
25702
|
-
}
|
|
25703
|
-
}, /*#__PURE__*/React.createElement("pre", {
|
|
25704
|
-
className: "browse-file-preview",
|
|
25705
|
-
style: {
|
|
25706
|
-
maxHeight: "300px",
|
|
25707
|
-
overflow: "auto",
|
|
25708
|
-
fontSize: "11px"
|
|
25709
|
-
}
|
|
25710
|
-
}, JSON.stringify(_this10.state.generatedFilterConfig, null, 2)))));
|
|
25724
|
+
data: _this10.state.generatedFilterConfig,
|
|
25725
|
+
onDownload: _this10.onDownload
|
|
25726
|
+
}));
|
|
25711
25727
|
}()), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null), /*#__PURE__*/React.createElement("br", null)));
|
|
25712
25728
|
};
|
|
25713
25729
|
return FilterBuilderTool;
|