@mdedit/sdk
Advanced tools
+5
-2
@@ -1,2 +0,2 @@ | ||
| import { ArticleContentSaveOptions } from '@mdedit/mdedit-api-client/articleContent'; | ||
| import { ArticleContentSaveOptions, ArticleContentCommitResponse } from '@mdedit/mdedit-api-client/articleContent'; | ||
@@ -8,2 +8,3 @@ type AuthHeaders = Record<string, string>; | ||
| getAuthHeaders: () => Promise<AuthHeaders>; | ||
| signal?: AbortSignal; | ||
| } | ||
@@ -85,2 +86,4 @@ declare class FetchError extends Error { | ||
| content?: string; | ||
| contentRevision?: number; | ||
| contentHash?: string; | ||
| folderId?: string | null; | ||
@@ -199,3 +202,3 @@ isArchived?: boolean; | ||
| delete: (workspaceId: string, articleId: string) => Promise<void>; | ||
| saveContent: (workspaceId: string, articleId: string, content: string, options?: ArticleContentSaveOptions) => Promise<void>; | ||
| saveContent: (workspaceId: string, articleId: string, content: string, options?: ArticleContentSaveOptions) => Promise<ArticleContentCommitResponse | void>; | ||
| exportZip: (workspaceId: string, articleId: string) => Promise<Blob>; | ||
@@ -202,0 +205,0 @@ }; |
+5
-2
@@ -11,2 +11,3 @@ // ../mdedit-api-client/src/shared.ts | ||
| ...init, | ||
| signal: init?.signal ?? config.signal, | ||
| headers: { | ||
@@ -25,2 +26,3 @@ ...init?.headers, | ||
| ...init, | ||
| signal: init?.signal ?? config.signal, | ||
| headers: { | ||
@@ -35,3 +37,3 @@ ...init?.headers, | ||
| }; | ||
| return { customFetch, customFetchV2: customFetchV22 }; | ||
| return { customFetch, customFetchV2: customFetchV22, signal: config.signal }; | ||
| } | ||
@@ -246,3 +248,4 @@ function getDefaultFetchers() { | ||
| headers: { "Content-Type": "text/markdown" }, | ||
| body: content | ||
| body: content, | ||
| signal: maybeFetchers?.signal | ||
| }); | ||
@@ -249,0 +252,0 @@ if (!uploadResponse.ok) { |
+1
-1
| { | ||
| "name": "@mdedit/sdk", | ||
| "version": "0.3.0", | ||
| "version": "0.3.1", | ||
| "private": false, | ||
@@ -5,0 +5,0 @@ "type": "module", |
Sorry, the diff of this file is too big to display
139524
0.56%902
0.67%