@haklex/rich-editor 0.0.66 → 0.0.68
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/{LinkFavicon-B9SOaYCR.js → PresentDialogContext-DmwCjSHw.js} +9 -2
- package/dist/{SubmitShortcutPlugin-WQpet-vq.js → SubmitShortcutPlugin-BRK63XHl.js} +17 -18
- package/dist/context/PresentDialogContext.d.ts +18 -0
- package/dist/context/PresentDialogContext.d.ts.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +10 -8
- package/dist/plugins/BlockIdPlugin.d.ts.map +1 -1
- package/dist/plugins-entry.mjs +1 -1
- package/dist/static-entry.d.ts +5 -3
- package/dist/static-entry.d.ts.map +1 -1
- package/dist/static-entry.mjs +9 -7
- package/dist/styles/article.css.d.ts.map +1 -1
- package/dist/transformers/footnote.d.ts.map +1 -1
- package/dist/transformers/grid-container.d.ts.map +1 -1
- package/package.json +4 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx } from "react/jsx-runtime";
|
|
2
2
|
import { Globe } from "lucide-react";
|
|
3
|
-
import { useState, useEffect } from "react";
|
|
3
|
+
import { useState, useEffect, createContext, use } from "react";
|
|
4
4
|
import { g as getHostname, p as probeFavicon } from "./favicon-BQgbXF_a.js";
|
|
5
5
|
function LinkFavicon({
|
|
6
6
|
href,
|
|
@@ -39,6 +39,13 @@ function LinkFavicon({
|
|
|
39
39
|
}
|
|
40
40
|
return /* @__PURE__ */ jsx("span", { className: `rich-link-favicon ${className ?? ""}`.trim(), children: /* @__PURE__ */ jsx(Globe, { "aria-hidden": true, size: 14 }) });
|
|
41
41
|
}
|
|
42
|
+
const PresentDialogContext = createContext(null);
|
|
43
|
+
const PresentDialogProvider = PresentDialogContext.Provider;
|
|
44
|
+
function usePresentDialog() {
|
|
45
|
+
return use(PresentDialogContext);
|
|
46
|
+
}
|
|
42
47
|
export {
|
|
43
|
-
LinkFavicon as L
|
|
48
|
+
LinkFavicon as L,
|
|
49
|
+
PresentDialogProvider as P,
|
|
50
|
+
usePresentDialog as u
|
|
44
51
|
};
|
|
@@ -479,7 +479,7 @@ const FOOTNOTE_TRANSFORMER = {
|
|
|
479
479
|
const FOOTNOTE_SECTION_TRANSFORMER = {
|
|
480
480
|
...FOOTNOTE_SECTION_TRANSFORMER$1,
|
|
481
481
|
dependencies: [FootnoteSectionNode],
|
|
482
|
-
regExp: /^\[\^(\w+)\]
|
|
482
|
+
regExp: /^\[\^(\w+)\]:[\t ]+(\S.*)$/,
|
|
483
483
|
replace: (parentNode, _children, match) => {
|
|
484
484
|
const identifier = match[1];
|
|
485
485
|
const content = match[2];
|
|
@@ -571,7 +571,7 @@ ${content}
|
|
|
571
571
|
${body}
|
|
572
572
|
:::`;
|
|
573
573
|
},
|
|
574
|
-
regExp:
|
|
574
|
+
regExp: /\b\B/,
|
|
575
575
|
replace: () => {
|
|
576
576
|
},
|
|
577
577
|
type: "element"
|
|
@@ -649,8 +649,8 @@ function detectMarkdown(text) {
|
|
|
649
649
|
let score = 0;
|
|
650
650
|
if (/^#{1,6}\s+\S/m.test(text)) score += 5;
|
|
651
651
|
if (/^```[\w-]*$/m.test(text)) score += 5;
|
|
652
|
-
if (/\[
|
|
653
|
-
if (/!\[
|
|
652
|
+
if (/\[[^\]]+\]\([^)]+\)/.test(text)) score += 4;
|
|
653
|
+
if (/!\[[^\]]*\]\([^)]+\)/.test(text)) score += 5;
|
|
654
654
|
if (/^\|.+\|$/m.test(text) && /^\|[\s:|-]+\|$/m.test(text)) score += 5;
|
|
655
655
|
if (/^>\s*\[!(?:note|tip|warning|caution|important)\]/im.test(text)) score += 5;
|
|
656
656
|
if (/^[*-]\s+\[[ x]\]/m.test(text)) score += 4;
|
|
@@ -785,11 +785,12 @@ function hasDuplicateOrMissingId(children) {
|
|
|
785
785
|
return false;
|
|
786
786
|
}
|
|
787
787
|
function generateBlockId(used) {
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
788
|
+
while (true) {
|
|
789
|
+
const id = nanoid(8);
|
|
790
|
+
if (!used.has(id)) {
|
|
791
|
+
return id;
|
|
792
|
+
}
|
|
793
|
+
}
|
|
793
794
|
}
|
|
794
795
|
function pickKeeperKey(nodes, previousKeys) {
|
|
795
796
|
if (!nodes.length) return null;
|
|
@@ -845,15 +846,13 @@ function BlockIdPlugin() {
|
|
|
845
846
|
if (hasDuplicateOrMissingId(initialChildren)) {
|
|
846
847
|
normalizeRootBlockIds(editor, /* @__PURE__ */ new Map());
|
|
847
848
|
}
|
|
848
|
-
return editor.registerUpdateListener(
|
|
849
|
-
(
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
}
|
|
856
|
-
);
|
|
849
|
+
return editor.registerUpdateListener(({ tags, editorState, prevEditorState }) => {
|
|
850
|
+
if (tags.has(NORMALIZATION_TAG)) return;
|
|
851
|
+
const children = collectRootChildren(editorState);
|
|
852
|
+
if (!hasDuplicateOrMissingId(children)) return;
|
|
853
|
+
const previousIdIndex = buildPreviousIdIndex(prevEditorState);
|
|
854
|
+
normalizeRootBlockIds(editor, previousIdIndex);
|
|
855
|
+
});
|
|
857
856
|
}, [editor]);
|
|
858
857
|
return null;
|
|
859
858
|
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { FC, ReactNode } from 'react';
|
|
2
|
+
export interface PresentDialogProps {
|
|
3
|
+
className?: string;
|
|
4
|
+
clickOutsideToDismiss?: boolean;
|
|
5
|
+
content: FC<{
|
|
6
|
+
dismiss: () => void;
|
|
7
|
+
}>;
|
|
8
|
+
description?: ReactNode;
|
|
9
|
+
portalClassName?: string;
|
|
10
|
+
sheet?: boolean | 'auto';
|
|
11
|
+
showCloseButton?: boolean;
|
|
12
|
+
theme?: 'light' | 'dark';
|
|
13
|
+
title?: ReactNode;
|
|
14
|
+
}
|
|
15
|
+
export type PresentDialogFn = (props: PresentDialogProps) => (() => void) | void;
|
|
16
|
+
export declare const PresentDialogProvider: import('react').Provider<PresentDialogFn | null>;
|
|
17
|
+
export declare function usePresentDialog(): PresentDialogFn | null;
|
|
18
|
+
//# sourceMappingURL=PresentDialogContext.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PresentDialogContext.d.ts","sourceRoot":"","sources":["../../src/context/PresentDialogContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAG3C,MAAM,WAAW,kBAAkB;IACjC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,OAAO,EAAE,EAAE,CAAC;QAAE,OAAO,EAAE,MAAM,IAAI,CAAA;KAAE,CAAC,CAAC;IACrC,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IACzB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,KAAK,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IACzB,KAAK,CAAC,EAAE,SAAS,CAAC;CACnB;AAED,MAAM,MAAM,eAAe,GAAG,CAAC,KAAK,EAAE,kBAAkB,KAAK,CAAC,MAAM,IAAI,CAAC,GAAG,IAAI,CAAC;AAIjF,eAAO,MAAM,qBAAqB,kDAAgC,CAAC;AAEnE,wBAAgB,gBAAgB,IAAI,eAAe,GAAG,IAAI,CAEzD"}
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,8 @@ export type { FootnoteDefinitionsContextValue } from './context/FootnoteDefiniti
|
|
|
11
11
|
export { FootnoteDefinitionsProvider, useFootnoteContent, useFootnoteDefinitions, useFootnoteDisplayNumber, } from './context/FootnoteDefinitionsContext';
|
|
12
12
|
export type { RenderEditorStateFn } from './context/NestedContentRendererContext';
|
|
13
13
|
export { NestedContentRendererProvider, useNestedContentRenderer, useOptionalNestedContentRenderer, } from './context/NestedContentRendererContext';
|
|
14
|
+
export type { PresentDialogFn, PresentDialogProps } from './context/PresentDialogContext';
|
|
15
|
+
export { PresentDialogProvider, usePresentDialog } from './context/PresentDialogContext';
|
|
14
16
|
export type { RendererMode } from './context/RendererConfigContext';
|
|
15
17
|
export { RendererConfigProvider, useRendererConfig, useRendererMode, useVariant, } from './context/RendererConfigContext';
|
|
16
18
|
export * from './styles';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,YAAY,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AACjE,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AACrD,YAAY,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACzE,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,YAAY,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAChE,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AACnF,YAAY,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC;AAC5F,OAAO,EACL,2BAA2B,EAC3B,kBAAkB,EAClB,sBAAsB,EACtB,wBAAwB,GACzB,MAAM,sCAAsC,CAAC;AAC9C,YAAY,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAC;AAClF,OAAO,EACL,6BAA6B,EAC7B,wBAAwB,EACxB,gCAAgC,GACjC,MAAM,wCAAwC,CAAC;AAChD,YAAY,EAAE,YAAY,EAAE,M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AwC,CAAC;AAChD,YAAY,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAC;AAC1F,OAAO,EAAE,qBAAqB,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AACzF,YAAY,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AACpE,OAAO,EACL,sBAAsB,EACtB,iBAAiB,EACjB,eAAe,EACf,UAAU,GACX,MAAM,iCAAiC,CAAC;AACzC,cAAc,UAAU,CAAC;AACzB,YAAY,EAAE,eAAe,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAClE,YAAY,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9D,YAAY,EACV,WAAW,EACX,YAAY,EACZ,WAAW,EACX,aAAa,EACb,WAAW,GACZ,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC"}
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { F as FootnotePlugin, O as OnChangePlugin, S as SubmitShortcutPlugin, E as EditorRefPlugin, a as AutoFocusPlugin, d as ImageUploadProvider, g as defaultImageUpload, C as CorePlugins, I as ImageUploadPlugin, L as LinkFaviconPlugin, c as BlockIdPlugin, f as blockIdState } from "./SubmitShortcutPlugin-
|
|
2
|
-
import { L } from "./
|
|
1
|
+
import { F as FootnotePlugin, O as OnChangePlugin, S as SubmitShortcutPlugin, E as EditorRefPlugin, a as AutoFocusPlugin, d as ImageUploadProvider, g as defaultImageUpload, C as CorePlugins, I as ImageUploadPlugin, L as LinkFaviconPlugin, c as BlockIdPlugin, f as blockIdState } from "./SubmitShortcutPlugin-BRK63XHl.js";
|
|
2
|
+
import { L, P, u } from "./PresentDialogContext-DmwCjSHw.js";
|
|
3
3
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
4
4
|
import { s as setResolvedEditNodes, a as allEditNodes } from "./node-registry-CSRSWJ0q.js";
|
|
5
5
|
import { I as ImagePlugin, K as KaTeXPlugin, A as AlertPlugin, M as MermaidPlugin } from "./MermaidPlugin-CIQbyjXF.js";
|
|
@@ -9,11 +9,11 @@ import { LexicalErrorBoundary } from "@lexical/react/LexicalErrorBoundary";
|
|
|
9
9
|
import { HistoryPlugin } from "@lexical/react/LexicalHistoryPlugin";
|
|
10
10
|
import { RichTextPlugin } from "@lexical/react/LexicalRichTextPlugin";
|
|
11
11
|
import { C as ColorSchemeProvider } from "./config-QGdXDSW9.js";
|
|
12
|
-
import { u } from "./config-QGdXDSW9.js";
|
|
12
|
+
import { u as u2 } from "./config-QGdXDSW9.js";
|
|
13
13
|
import { R as RendererConfigProvider } from "./KaTeXRenderer-C8jv_5xr.js";
|
|
14
|
-
import { F, u as
|
|
14
|
+
import { F, u as u3, b, d, e, f, g } from "./KaTeXRenderer-C8jv_5xr.js";
|
|
15
15
|
import { e as editorTheme } from "./theme-CRza9nbF.js";
|
|
16
|
-
import { N, u as
|
|
16
|
+
import { N, u as u4, b as b2 } from "./theme-CRza9nbF.js";
|
|
17
17
|
import { ContentEditable as ContentEditable$1 } from "@lexical/react/LexicalContentEditable";
|
|
18
18
|
/* empty css */
|
|
19
19
|
import { b as clsx, g as getVariantClass } from "./shared.css-DNuMYx6Q.js";
|
|
@@ -281,6 +281,7 @@ export {
|
|
|
281
281
|
F as FootnoteDefinitionsProvider,
|
|
282
282
|
L as LinkFavicon,
|
|
283
283
|
N as NestedContentRendererProvider,
|
|
284
|
+
P as PresentDialogProvider,
|
|
284
285
|
RendererConfigProvider,
|
|
285
286
|
RichEditor,
|
|
286
287
|
RichEditorShell,
|
|
@@ -295,12 +296,13 @@ export {
|
|
|
295
296
|
noteTheme,
|
|
296
297
|
n as noteVariant,
|
|
297
298
|
r as richContent,
|
|
298
|
-
|
|
299
|
-
|
|
299
|
+
u2 as useColorScheme,
|
|
300
|
+
u3 as useFootnoteContent,
|
|
300
301
|
b as useFootnoteDefinitions,
|
|
301
302
|
d as useFootnoteDisplayNumber,
|
|
302
|
-
|
|
303
|
+
u4 as useNestedContentRenderer,
|
|
303
304
|
b2 as useOptionalNestedContentRenderer,
|
|
305
|
+
u as usePresentDialog,
|
|
304
306
|
e as useRendererConfig,
|
|
305
307
|
f as useRendererMode,
|
|
306
308
|
g as useVariant,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BlockIdPlugin.d.ts","sourceRoot":"","sources":["../../src/plugins/BlockIdPlugin.tsx"],"names":[],"mappings":"AAaA,eAAO,MAAM,YAAY,kDAEvB,
|
|
1
|
+
{"version":3,"file":"BlockIdPlugin.d.ts","sourceRoot":"","sources":["../../src/plugins/BlockIdPlugin.tsx"],"names":[],"mappings":"AAaA,eAAO,MAAM,YAAY,kDAEvB,CAAC;AAwGH,wBAAgB,aAAa,SAsB5B"}
|
package/dist/plugins-entry.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A, a, b, B, c, C, E, F, H, I, d, L, M, e, O, S, f, g, u } from "./SubmitShortcutPlugin-
|
|
1
|
+
import { A, a, b, B, c, C, E, F, H, I, d, L, M, e, O, S, f, g, u } from "./SubmitShortcutPlugin-BRK63XHl.js";
|
|
2
2
|
import { A as A2, I as I2, K, M as M2 } from "./MermaidPlugin-CIQbyjXF.js";
|
|
3
3
|
export {
|
|
4
4
|
A as ALL_TRANSFORMERS,
|
package/dist/static-entry.d.ts
CHANGED
|
@@ -2,15 +2,17 @@ export { LinkFavicon } from './components/LinkFavicon';
|
|
|
2
2
|
export type { RubyRendererProps } from './components/renderers/RubyRenderer';
|
|
3
3
|
export { RubyRenderer } from './components/renderers/RubyRenderer';
|
|
4
4
|
export type { RendererKey } from './components/RendererWrapper';
|
|
5
|
-
export { createRendererDecoration, RendererWrapper
|
|
5
|
+
export { createRendererDecoration, RendererWrapper } from './components/RendererWrapper';
|
|
6
6
|
export { getVariantClass } from './components/utils';
|
|
7
7
|
export { allNodes, builtinNodes, customNodes } from './config';
|
|
8
8
|
export type { ColorScheme } from './context/ColorSchemeContext';
|
|
9
|
-
export { ColorSchemeProvider, useColorScheme
|
|
9
|
+
export { ColorSchemeProvider, useColorScheme } from './context/ColorSchemeContext';
|
|
10
10
|
export type { FootnoteDefinitionsContextValue } from './context/FootnoteDefinitionsContext';
|
|
11
11
|
export { FootnoteDefinitionsProvider, useFootnoteContent, useFootnoteDefinitions, useFootnoteDisplayNumber, } from './context/FootnoteDefinitionsContext';
|
|
12
12
|
export type { RenderEditorStateFn } from './context/NestedContentRendererContext';
|
|
13
13
|
export { NestedContentRendererProvider, useNestedContentRenderer, useOptionalNestedContentRenderer, } from './context/NestedContentRendererContext';
|
|
14
|
+
export type { PresentDialogFn, PresentDialogProps } from './context/PresentDialogContext';
|
|
15
|
+
export { PresentDialogProvider, usePresentDialog } from './context/PresentDialogContext';
|
|
14
16
|
export type { RendererMode } from './context/RendererConfigContext';
|
|
15
17
|
export { RendererConfigProvider, useRendererConfig, useRendererMode, useVariant, } from './context/RendererConfigContext';
|
|
16
18
|
export { articleVariant } from './styles/article.css';
|
|
@@ -21,5 +23,5 @@ export { editorTheme } from './styles/theme';
|
|
|
21
23
|
export type { RichEditorVariant } from './types';
|
|
22
24
|
export type { RendererConfig } from './types/renderer-config';
|
|
23
25
|
export { extractTextContent } from './utils/extractTextContent';
|
|
24
|
-
export { articleTheme, commentTheme, noteTheme, vars
|
|
26
|
+
export { articleTheme, commentTheme, noteTheme, vars } from '@haklex/rich-style-token/styles';
|
|
25
27
|
//# sourceMappingURL=static-entry.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"static-entry.d.ts","sourceRoot":"","sources":["../src/static-entry.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,
|
|
1
|
+
{"version":3,"file":"static-entry.d.ts","sourceRoot":"","sources":["../src/static-entry.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACv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AE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,YAAY,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AACjD,YAAY,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAChE,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,iCAAiC,CAAC"}
|
package/dist/static-entry.mjs
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
|
-
import { L } from "./
|
|
1
|
+
import { L, P, u } from "./PresentDialogContext-DmwCjSHw.js";
|
|
2
2
|
import { R } from "./RubyRenderer-DbeobSoH.js";
|
|
3
|
-
import { F, R as R2, a, c, u, b, d, e, f, g } from "./KaTeXRenderer-C8jv_5xr.js";
|
|
3
|
+
import { F, R as R2, a, c, u as u2, b, d, e, f, g } from "./KaTeXRenderer-C8jv_5xr.js";
|
|
4
4
|
import { a as a2, c as c2, g as g2, n, r } from "./shared.css-DNuMYx6Q.js";
|
|
5
|
-
import { C, a as a3, b as b2, c as c3, u as
|
|
6
|
-
import { N, e as e2, a as a4, u as
|
|
5
|
+
import { C, a as a3, b as b2, c as c3, u as u3 } from "./config-QGdXDSW9.js";
|
|
6
|
+
import { N, e as e2, a as a4, u as u4, b as b3 } from "./theme-CRza9nbF.js";
|
|
7
7
|
import { articleTheme, commentTheme, noteTheme, vars } from "@haklex/rich-style-token/styles";
|
|
8
8
|
export {
|
|
9
9
|
C as ColorSchemeProvider,
|
|
10
10
|
F as FootnoteDefinitionsProvider,
|
|
11
11
|
L as LinkFavicon,
|
|
12
12
|
N as NestedContentRendererProvider,
|
|
13
|
+
P as PresentDialogProvider,
|
|
13
14
|
R2 as RendererConfigProvider,
|
|
14
15
|
a as RendererWrapper,
|
|
15
16
|
R as RubyRenderer,
|
|
@@ -27,12 +28,13 @@ export {
|
|
|
27
28
|
noteTheme,
|
|
28
29
|
n as noteVariant,
|
|
29
30
|
r as richContent,
|
|
30
|
-
|
|
31
|
-
|
|
31
|
+
u3 as useColorScheme,
|
|
32
|
+
u2 as useFootnoteContent,
|
|
32
33
|
b as useFootnoteDefinitions,
|
|
33
34
|
d as useFootnoteDisplayNumber,
|
|
34
|
-
|
|
35
|
+
u4 as useNestedContentRenderer,
|
|
35
36
|
b3 as useOptionalNestedContentRenderer,
|
|
37
|
+
u as usePresentDialog,
|
|
36
38
|
e as useRendererConfig,
|
|
37
39
|
f as useRendererMode,
|
|
38
40
|
g as useVariant,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"article.css.d.ts","sourceRoot":"","sources":["../../src/styles/article.css.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"article.css.d.ts","sourceRoot":"","sources":["../../src/styles/article.css.ts"],"names":[],"mappings":"AAsBA,eAAO,MAAM,cAAc,QAAkD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"footnote.d.ts","sourceRoot":"","sources":["../../src/transformers/footnote.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"footnote.d.ts","sourceRoot":"","sources":["../../src/transformers/footnote.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,kBAAkB,EAAE,oBAAoB,EAAE,MAAM,mBAAmB,CAAC;AASlF,eAAO,MAAM,oBAAoB,EAAE,oBAOlC,CAAC;AAEF,eAAO,MAAM,4BAA4B,EAAE,kBAuB1C,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-container.d.ts","sourceRoot":"","sources":["../../src/transformers/grid-container.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"grid-container.d.ts","sourceRoot":"","sources":["../../src/transformers/grid-container.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAU5D,eAAO,MAAM,gCAAgC,EAAE,kBAW9C,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@haklex/rich-editor",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.68",
|
|
4
4
|
"description": "Core rich text editor based on Lexical",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -48,9 +48,9 @@
|
|
|
48
48
|
"@base-ui/react": "^1.1.0",
|
|
49
49
|
"nanoid": "^5.1.6",
|
|
50
50
|
"thumbhash": "^0.1.1",
|
|
51
|
-
"@haklex/rich-
|
|
52
|
-
"@haklex/rich-
|
|
53
|
-
"@haklex/rich-
|
|
51
|
+
"@haklex/rich-style-token": "0.0.68",
|
|
52
|
+
"@haklex/rich-editor-ui": "0.0.68",
|
|
53
|
+
"@haklex/rich-headless": "0.0.68"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"@lexical/code": "^0.41.0",
|