@onehat/ui 0.2.44 → 0.2.46
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/package.json
CHANGED
|
@@ -227,7 +227,7 @@ export default function withDraggable(WrappedComponent) {
|
|
|
227
227
|
position={{ x: 0, y: 0, /* reset to dropped position */ }}
|
|
228
228
|
// bounds={bounds}
|
|
229
229
|
>
|
|
230
|
-
<div className="nsResize"
|
|
230
|
+
<div className="nsResize">
|
|
231
231
|
<WrappedComponent {...propsToPass} />
|
|
232
232
|
</div>
|
|
233
233
|
</Draggable>;
|
|
@@ -57,6 +57,13 @@ export default function withEditor(WrappedComponent) {
|
|
|
57
57
|
addValues[selectorId] = selectorSelected.id;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
+
// Set repository to sort by id DESC and switch to page 1, so this new entity is guaranteed to show up on the current page, even after saving
|
|
61
|
+
Repository.pauseEvents();
|
|
62
|
+
Repository.sort(Repository.schema.model.idProperty, 'DESC');
|
|
63
|
+
Repository.setPage(1);
|
|
64
|
+
Repository.resumeEvents();
|
|
65
|
+
await Repository.reload();
|
|
66
|
+
|
|
60
67
|
const entity = await Repository.add(addValues, false, true, true);
|
|
61
68
|
setSelection([entity]);
|
|
62
69
|
setIsEditorViewOnly(false);
|