@complat/react-spectra-editor 1.5.1 → 1.5.2
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.
|
@@ -66,7 +66,10 @@ class MultiJcampsViewer extends _react.default.Component {
|
|
|
66
66
|
molSvg,
|
|
67
67
|
exactMass,
|
|
68
68
|
layoutSt,
|
|
69
|
-
integrationSt
|
|
69
|
+
integrationSt,
|
|
70
|
+
descriptions,
|
|
71
|
+
canChangeDescription,
|
|
72
|
+
onDescriptionChanged
|
|
70
73
|
} = this.props;
|
|
71
74
|
if (!entities || entities.length === 0) return /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {});
|
|
72
75
|
const separateCondition = _format.default.isGCLayout(layoutSt) ? 'yUnit' : 'xUnit';
|
|
@@ -117,9 +120,9 @@ class MultiJcampsViewer extends _react.default.Component {
|
|
|
117
120
|
exactMass: exactMass,
|
|
118
121
|
subLayoutsInfo: seperatedSubLayouts,
|
|
119
122
|
integration: currentIntegration,
|
|
120
|
-
descriptions:
|
|
121
|
-
canChangeDescription:
|
|
122
|
-
onDescriptionChanged:
|
|
123
|
+
descriptions: descriptions,
|
|
124
|
+
canChangeDescription: canChangeDescription,
|
|
125
|
+
onDescriptionChanged: onDescriptionChanged
|
|
123
126
|
})
|
|
124
127
|
})]
|
|
125
128
|
})
|
|
@@ -159,7 +162,10 @@ MultiJcampsViewer.propTypes = {
|
|
|
159
162
|
entities: _propTypes.default.array,
|
|
160
163
|
layoutSt: _propTypes.default.string.isRequired,
|
|
161
164
|
exactMass: _propTypes.default.string,
|
|
162
|
-
integrationSt: _propTypes.default.object.isRequired
|
|
165
|
+
integrationSt: _propTypes.default.object.isRequired,
|
|
166
|
+
descriptions: _propTypes.default.array.isRequired,
|
|
167
|
+
canChangeDescription: _propTypes.default.bool.isRequired,
|
|
168
|
+
onDescriptionChanged: _propTypes.default.func
|
|
163
169
|
};
|
|
164
170
|
MultiJcampsViewer.defaultProps = {
|
|
165
171
|
multiEntities: [],
|
|
@@ -168,6 +174,8 @@ MultiJcampsViewer.defaultProps = {
|
|
|
168
174
|
cLabel: '',
|
|
169
175
|
xLabel: '',
|
|
170
176
|
yLabel: '',
|
|
171
|
-
entities: []
|
|
177
|
+
entities: [],
|
|
178
|
+
descriptions: [],
|
|
179
|
+
canChangeDescription: false
|
|
172
180
|
};
|
|
173
181
|
var _default = exports.default = (0, _redux.compose)((0, _reactRedux.connect)(mapStateToProps, mapDispatchToProps), (0, _styles.withStyles)(styles))(MultiJcampsViewer);
|
|
@@ -442,7 +442,7 @@ const InfoPanel = ({
|
|
|
442
442
|
className: (0, _classnames.default)(classes.quill, 'card-sv-quill'),
|
|
443
443
|
value: normalizeQuillValue(descriptions),
|
|
444
444
|
placeholder: canChangeDescription ? 'Peaks will be written here...' : undefined,
|
|
445
|
-
readOnly:
|
|
445
|
+
readOnly: true,
|
|
446
446
|
modules: {
|
|
447
447
|
toolbar: false
|
|
448
448
|
},
|
package/dist/index.js
CHANGED
|
@@ -800,6 +800,7 @@ class DemoWriteIr extends _react.default.Component {
|
|
|
800
800
|
multiEntities: multiEntities,
|
|
801
801
|
others: others,
|
|
802
802
|
editorOnly: false,
|
|
803
|
+
descriptions: desc,
|
|
803
804
|
canChangeDescription: true,
|
|
804
805
|
onDescriptionChanged: this.onDescriptionChanged,
|
|
805
806
|
molSvg: molSvg,
|
package/dist/layer_init.js
CHANGED
|
@@ -155,7 +155,10 @@ class LayerInit extends _react.default.Component {
|
|
|
155
155
|
userManualLink: userManualLink,
|
|
156
156
|
molSvg: molSvg,
|
|
157
157
|
exactMass: exactMass,
|
|
158
|
-
operations: operations
|
|
158
|
+
operations: operations,
|
|
159
|
+
descriptions: descriptions,
|
|
160
|
+
canChangeDescription: canChangeDescription,
|
|
161
|
+
onDescriptionChanged: onDescriptionChanged
|
|
159
162
|
});
|
|
160
163
|
} else if (_format.default.isCyclicVoltaLayout(layout)) {
|
|
161
164
|
// eslint-disable-line
|
|
@@ -165,7 +168,10 @@ class LayerInit extends _react.default.Component {
|
|
|
165
168
|
userManualLink: userManualLink,
|
|
166
169
|
molSvg: molSvg,
|
|
167
170
|
exactMass: exactMass,
|
|
168
|
-
operations: operations
|
|
171
|
+
operations: operations,
|
|
172
|
+
descriptions: descriptions,
|
|
173
|
+
canChangeDescription: canChangeDescription,
|
|
174
|
+
onDescriptionChanged: onDescriptionChanged
|
|
169
175
|
});
|
|
170
176
|
}
|
|
171
177
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_layer_prism.default, {
|