feat: ship v1.1.0 writer toolkit with templates, import, export, and inspiration capture
Implement chapter templates, txt/md/docx import, submission export presets, and global inspiration shortcut. Split import handlers into a separate main bundle and fix EditorLayout setTarget loop that broke E2E. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Vendored
+23
-1
@@ -52,7 +52,10 @@ import type {
|
||||
PomodoroDuration,
|
||||
CharacterGraphData,
|
||||
CharacterRelationship,
|
||||
WritingAnalyticsSummary
|
||||
WritingAnalyticsSummary,
|
||||
ImportPreviewResult,
|
||||
ImportExecuteParams,
|
||||
ImportSplitMode
|
||||
} from './types'
|
||||
|
||||
export interface ElectronAPI {
|
||||
@@ -410,6 +413,24 @@ export interface ElectronAPI {
|
||||
analytics: {
|
||||
getSummary: (bookId: string) => Promise<IpcResult<WritingAnalyticsSummary>>
|
||||
}
|
||||
import: {
|
||||
pickFile: () => Promise<IpcResult<{ canceled: boolean; filePath?: string }>>
|
||||
preview: (
|
||||
filePath: string,
|
||||
splitMode: ImportSplitMode,
|
||||
customRegex?: string
|
||||
) => Promise<IpcResult<ImportPreviewResult>>
|
||||
execute: (params: ImportExecuteParams) => Promise<IpcResult<string>>
|
||||
}
|
||||
export: {
|
||||
formatChapter: (
|
||||
bookId: string,
|
||||
chapterId: string,
|
||||
presetId: string
|
||||
) => Promise<IpcResult<string>>
|
||||
copyClipboard: (text: string) => Promise<IpcResult<void>>
|
||||
saveTxt: (text: string, defaultName: string) => Promise<IpcResult<string | null>>
|
||||
}
|
||||
bridge: {
|
||||
get: (
|
||||
bookId: string,
|
||||
@@ -435,6 +456,7 @@ export interface ElectronAPI {
|
||||
onInteractiveStreamChunk: (callback: (payload: InteractiveStreamChunkEvent) => void) => () => void
|
||||
onPomodoroTick: (callback: (state: PomodoroState) => void) => () => void
|
||||
onGoalNotification: (callback: (payload: GoalNotificationPayload) => void) => () => void
|
||||
onImportProgress: (callback: (payload: { current: number; total: number }) => void) => () => void
|
||||
}
|
||||
|
||||
declare global {
|
||||
|
||||
Reference in New Issue
Block a user