Skip to content

Commit

Permalink
✨ feat: add foldBlock api
Browse files Browse the repository at this point in the history
  • Loading branch information
frostime committed Dec 28, 2023
1 parent a2a615a commit 74d62ac
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,24 @@ export async function moveBlock(id: BlockId, previousID?: PreviousID, parentID?:
}


export async function foldBlock(id: BlockId) {
let data = {
id: id
}
let url = '/api/block/foldBlock';
return request(url, data);
}


export async function unfoldBlock(id: BlockId) {
let data = {
id: id
}
let url = '/api/block/unfoldBlock';
return request(url, data);
}


export async function getBlockKramdown(id: BlockId): Promise<IResGetBlockKramdown> {
let data = {
id: id
Expand Down

0 comments on commit 74d62ac

Please sign in to comment.