diff --git a/packages/web/src/javascripts/Components/SuperEditor/Lexical/Utils/PDFExport/PDFExport.tsx b/packages/web/src/javascripts/Components/SuperEditor/Lexical/Utils/PDFExport/PDFExport.tsx index 27a20824b..388d8a299 100644 --- a/packages/web/src/javascripts/Components/SuperEditor/Lexical/Utils/PDFExport/PDFExport.tsx +++ b/packages/web/src/javascripts/Components/SuperEditor/Lexical/Utils/PDFExport/PDFExport.tsx @@ -12,6 +12,7 @@ import { import { $isLinkNode } from '@lexical/link' import { $isHeadingNode, type HeadingNode, $isQuoteNode } from '@lexical/rich-text' import { $isListNode, $isListItemNode, ListType } from '@lexical/list' +import { $isHorizontalRuleNode } from '@lexical/react/LexicalHorizontalRuleNode' import { $isTableNode, $isTableRowNode, $isTableCellNode } from '@lexical/table' import { $isCodeNode } from '@lexical/code' import { $isInlineFileNode } from '../../../Plugins/InlineFilePlugin/InlineFileNode' @@ -394,6 +395,18 @@ const getPDFDataNodeFromLexicalNode = (node: LexicalNode, fontFamilies: FontFami } } + if ($isHorizontalRuleNode(node)) { + return { + type: 'View', + style: { + borderBottomWidth: 1, + borderBottomColor: '#cccccc', + marginVertical: 10, + width: '100%', + }, + } + } + if ($isElementNode(node)) { return { type: 'View',