@select-org/select-post-builder 1.1.35 → 1.1.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -44,7 +44,14 @@ declare type BaseProps = {
44
44
  json: JSONContent;
45
45
  text: string;
46
46
  }) => void;
47
+ onVoiceComment?: (params: {
48
+ voiceUrl: string;
49
+ voiceTime: number;
50
+ }) => void;
47
51
  onGroupSelect?: (groupId: string) => void;
52
+ onDirtyStateChange?: (isDirty: boolean) => void;
53
+ onReady?: (controls: PostBuilderControls) => void;
54
+ disableNavigationWarning?: boolean;
48
55
  };
49
56
 
50
57
  export declare enum EditorPlacement {
@@ -126,6 +133,12 @@ export declare interface PostBuilderConfig {
126
133
  logEvent: (name: string, properties: Record<string, unknown>) => void;
127
134
  }
128
135
 
136
+ export declare interface PostBuilderControls {
137
+ saveDraft: () => void;
138
+ discardDraft: () => void;
139
+ keepEditing: () => void;
140
+ }
141
+
129
142
  export declare const PostBuilderEditor: FC<PostBuilderEditorProps>;
130
143
 
131
144
  export declare type PostBuilderEditorProps = WithModalProps | WithoutModalProps;
@@ -372,6 +385,11 @@ declare module '@tiptap/core' {
372
385
  * Delete link preview node by uid
373
386
  */
374
387
  deleteLinkPreviewByUid: (uid: string) => ReturnType;
388
+ /**
389
+ * Insert a link preview node directly after the top-level block containing
390
+ * the link mark with the given uid. Skips nested content (depth > 1).
391
+ */
392
+ insertLinkPreviewAfterLink: (uid: string, attrs: LinkPreviewAttributes) => ReturnType;
375
393
  };
376
394
  }
377
395
  }