superdesk-ui-framework 4.0.13 → 4.0.16
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/.github/workflows/publish-to-npm.yml +1 -0
- package/app/styles/app.scss +1 -0
- package/app-typescript/components/CreateButton.tsx +1 -1
- package/app-typescript/components/DateTimePicker.tsx +33 -29
- package/app-typescript/components/Editor/EditorButton.tsx +1 -1
- package/app-typescript/components/IconButton.tsx +1 -3
- package/app-typescript/components/Lists/TableList.tsx +4 -4
- package/app-typescript/components/Switch.tsx +0 -1
- package/app-typescript/components/Tooltip.tsx +76 -48
- package/app-typescript/components/TreeSelect/TreeSelect.tsx +14 -1
- package/dist/components/Tooltips.tsx +1 -44
- package/dist/components/TreeSelect.tsx +10 -15
- package/dist/examples.bundle.js +3588 -1104
- package/dist/playgrounds/react-playgrounds/RundownEditor.tsx +1 -1
- package/dist/playgrounds/react-playgrounds/TestGround.tsx +26 -26
- package/dist/superdesk-ui.bundle.css +1 -1
- package/dist/superdesk-ui.bundle.js +3545 -1041
- package/examples/pages/components/Tooltips.tsx +1 -44
- package/examples/pages/components/TreeSelect.tsx +10 -15
- package/examples/pages/playgrounds/react-playgrounds/RundownEditor.tsx +1 -1
- package/examples/pages/playgrounds/react-playgrounds/TestGround.tsx +26 -26
- package/package.json +3 -2
- package/react/components/CreateButton.js +1 -1
- package/react/components/DateTimePicker.js +9 -7
- package/react/components/IconButton.js +1 -1
- package/react/components/Lists/TableList.js +4 -4
- package/react/components/Switch.js +1 -1
- package/react/components/Tooltip.d.ts +10 -4
- package/react/components/Tooltip.js +64 -64
- package/react/components/TreeSelect/TreeSelect.d.ts +1 -0
- package/react/components/TreeSelect/TreeSelect.js +8 -1
@@ -63,6 +63,7 @@ export declare class TreeSelect<T> extends React.Component<IProps<T>, IState<T>>
|
|
63
63
|
private htmlId;
|
64
64
|
private popperInstance;
|
65
65
|
private zIndex;
|
66
|
+
private changesFromOutside;
|
66
67
|
constructor(props: IProps<T>);
|
67
68
|
inputFocus: () => void;
|
68
69
|
listNavigation: () => void;
|
@@ -179,6 +179,7 @@ var TreeSelect = /** @class */ (function (_super) {
|
|
179
179
|
_this.treeSelectRef = React.createRef();
|
180
180
|
_this.popperInstance = null;
|
181
181
|
_this.onDragEnd = _this.onDragEnd.bind(_this);
|
182
|
+
_this.changesFromOutside = false;
|
182
183
|
return _this;
|
183
184
|
}
|
184
185
|
TreeSelect.prototype.componentWillUnmount = function () {
|
@@ -189,9 +190,15 @@ var TreeSelect = /** @class */ (function (_super) {
|
|
189
190
|
TreeSelect.prototype.componentDidUpdate = function (prevProps, prevState) {
|
190
191
|
var _a, _b;
|
191
192
|
if (!(0, lodash_1.isEqual)(prevState.value, this.state.value)) {
|
192
|
-
|
193
|
+
if (this.changesFromOutside) {
|
194
|
+
this.changesFromOutside = false;
|
195
|
+
}
|
196
|
+
else {
|
197
|
+
this.props.onChange(this.state.value);
|
198
|
+
}
|
193
199
|
}
|
194
200
|
else if (!(0, lodash_1.isEqual)(prevProps.value, this.props.value)) {
|
201
|
+
this.changesFromOutside = true;
|
195
202
|
this.setState({
|
196
203
|
value: (_a = this.props.value) !== null && _a !== void 0 ? _a : [],
|
197
204
|
});
|