1
0
Fork 0
mirror of https://github.com/anyproto/anytype-ts.git synced 2025-06-08 05:57:02 +09:00

fix layout broken

This commit is contained in:
Andrew Simachev 2025-04-09 12:30:57 +02:00
parent 8d7cb39b12
commit 4b555faea4
No known key found for this signature in database
GPG key ID: 1DFE44B21443F0EF
4 changed files with 10 additions and 6 deletions

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 45 KiB

After

Width:  |  Height:  |  Size: 45 KiB

Before After
Before After

View file

@ -39,6 +39,8 @@ const ControlButtons = observer(class ControlButtons extends React.Component<Pro
return null;
};
console.log('ROOT', root);
const check = U.Data.checkDetails(rootId);
const object = S.Detail.get(rootId, rootId, [ 'featuredRelations', 'targetObjectType', 'layoutAlign' ]);
const checkType = S.Block.checkBlockTypeExists(rootId);

View file

@ -257,12 +257,14 @@ const SidebarPageType = observer(class SidebarPageType extends React.Component<I
onCancel () {
const { isPopup, previous } = this.props;
console.log(JSON.stringify(this.backup, null, 3));
const rootId = keyboard.getRootId();
if (U.Common.objectLength(this.update)) {
S.Detail.update(J.Constant.subId.type, { id: this.backup.id, details: this.backup }, false);
this.updateLayout(this.backup.recommendedLayout);
if ((rootId != this.backup.id) && !U.Object.isTypeLayout(this.backup.layout)) {
this.updateLayout(this.backup.recommendedLayout);
};
};
if (previous && previous.page) {

View file

@ -486,7 +486,7 @@ export const TemplateCreateFromObject = (response: Rpc.Template.CreateFromObject
export const WorkspaceCreate = (response: Rpc.Workspace.Create.Response) => {
return {
objectId: response.getSpaceid(),
startingId: response.getStartingobjectid(),
//startingId: response.getStartingobjectid(),
};
};