feat(export): add metadata file to preserve page icons and ordering on import (#1877)

* feat(export): add metadata file to preserve page icons and ordering on import
- Export includes `docmost-metadata.json`
- Import reads metadata to restore icons and sort siblings by original position

* cleanup

* bonus fixes

* handle unknown prosemirror nodes

* add docmost app  version
This commit is contained in:
Philip Okugbe
2026-01-27 16:39:39 +00:00
committed by GitHub
parent 0245a183e1
commit 6ccb2bb872
8 changed files with 178 additions and 9 deletions
@@ -0,0 +1,14 @@
export type ExportPageMetadata = {
pageId: string;
slugId: string;
icon: string | null;
position: string;
parentPath: string | null;
};
export type ExportMetadata = {
exportedAt: string;
source: 'docmost';
version: string;
pages: Record<string, ExportPageMetadata>;
};