Skip to content

Commit

Permalink
Fix tsc errors
Browse files Browse the repository at this point in the history
  • Loading branch information
inokawa committed Dec 7, 2023
1 parent a6ce0fa commit f6c40e0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/models/mdast.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import type { Literal } from "mdast";

export * from "mdast";
export * from "mdast-util-math/complex-types";
export * from "mdast-util-math";

export interface TOML extends Literal {
type: "toml";
Expand Down
5 changes: 4 additions & 1 deletion src/transformers/slate-to-mdast/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,10 @@ const convertTexts = (
const buildMdastNode = (
node: Exclude<slateInternal.SlateNode, slateInternal.Text>,
overrides: OverridedSlateBuilders
): Exclude<mdast.Content, TextOrDecoration> | null => {
): Exclude<
mdast.Content | mdast.Math | mdast.InlineMath,
TextOrDecoration
> | null => {
const customNode = overrides[node.type]?.(node as any, (children) =>
convertNodes(children, overrides)
);
Expand Down

0 comments on commit f6c40e0

Please sign in to comment.