alinea
Version:
[](https://npmjs.org/package/alinea) [](https://packagephobia.com/result?p=alinea)
36 lines (35 loc) • 876 B
TypeScript
import { Mark } from '@tiptap/core';
interface LinkAttributes {
'data-id'?: string;
'data-entry'?: string;
'data-type'?: string;
href?: string;
target?: string;
title?: string;
}
export interface LinkOptions {
/**
* A list of HTML attributes to be rendered.
*/
HTMLAttributes: Record<string, any>;
}
declare module '@tiptap/core' {
interface Commands<ReturnType> {
link: {
/**
* Set a link mark
*/
setLink: (attributes: LinkAttributes) => ReturnType;
/**
* Toggle a link mark
*/
toggleLink: (attributes: LinkAttributes) => ReturnType;
/**
* Unset a link mark
*/
unsetLink: () => ReturnType;
};
}
}
export declare const Link: Mark<LinkOptions, any>;
export {};