1
0
Fork 0
mirror of https://github.com/anyproto/anytype-ts.git synced 2025-06-07 21:47:02 +09:00

make default empty values sorted on bottom

This commit is contained in:
Andrew Simachev 2025-06-06 15:48:29 +02:00
parent 26a6f95540
commit b2a7ec7baf
No known key found for this signature in database
GPG key ID: 1DFE44B21443F0EF
2 changed files with 7 additions and 4 deletions

View file

@ -368,7 +368,10 @@ const Controls = observer(class Controls extends React.Component<Props> {
};
if (component == 'dataviewSort') {
newItem.type = I.SortType.Asc;
newItem = Object.assign(newItem, {
type: I.SortType.Asc,
empty: I.EmptyType.End,
});
onSortAdd(newItem, callBack);
} else

View file

@ -305,7 +305,7 @@ const MenuSort = observer(class MenuSort extends React.Component<I.Menu> {
rootId,
blockId,
getView,
onSelect: (v) => {
onSelect: v => {
this.onChange(item.id, 'relationKey', v.relationKey ? v.relationKey : v.id);
}
});
@ -326,11 +326,11 @@ const MenuSort = observer(class MenuSort extends React.Component<I.Menu> {
return;
};
const obj = $(`#${getId()}`);
const content = obj.find('.content');
const content = $(`#${getId()} .content`);
const newItem = {
relationKey: relationOptions[0].id,
type: I.SortType.Asc,
empty: I.EmptyType.End,
};
onSortAdd(newItem, () => {