@fileverse-dev/ddoc 7.2.0 → 7.2.2
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/headless-editor-utils.es.js +1 -1
- package/dist/{index-CgwDupjU.mjs → index-B1mVtyXJ.mjs} +1 -1
- package/dist/index.es.js +3372 -3366
- package/dist/package/stores/link-dialog-store.d.ts +12 -0
- package/dist/package/utils/apply-link-with-text.d.ts +7 -0
- package/dist/package/utils/responsive.d.ts +1 -0
- package/dist/{use-headless-editor-DfHwB1_9.mjs → use-headless-editor-BODPh_74.mjs} +2790 -2769
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
type Store = {
|
|
2
|
+
openDialog: (() => void) | null;
|
|
3
|
+
setOpenDialog: (open: (() => void) | null) => void;
|
|
4
|
+
};
|
|
5
|
+
/**
|
|
6
|
+
* Lets `insert.link` (a host app's menu, outside the editor tree) open the
|
|
7
|
+
* link dialog that MobileToolbar owns and ⌘K toggles. The toolbar registers
|
|
8
|
+
* the opener while mounted, so a request with no toolbar does nothing.
|
|
9
|
+
*/
|
|
10
|
+
export declare const useLinkDialogStore: import('zustand').UseBoundStore<import('zustand').StoreApi<Store>>;
|
|
11
|
+
export declare const openLinkDialog: () => void | undefined;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Editor } from '@tiptap/react';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Applies a link's text and URL to the selection. The text keeps the
|
|
5
|
+
* formatting it replaces (or the caret's), except the colour setLink drops.
|
|
6
|
+
*/
|
|
7
|
+
export declare const applyLinkWithText: (editor: Editor, text: string, href: string) => void;
|