@onereach/ui-components 10.3.2 → 10.3.3-beta.4314.0

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.
Files changed (26) hide show
  1. package/dist/bundled/v2/components/OrRichTextEditorV3/OrRichTextEditor.js +4 -69
  2. package/dist/bundled/v2/components/OrRichTextEditorV3/utils/markdown.js +1 -1
  3. package/dist/bundled/v2/{markdown-4af315b8.js → markdown-62ee11bf.js} +70 -4
  4. package/dist/bundled/v3/components/OrRichTextEditorV3/OrRichTextEditor.js +1 -1
  5. package/dist/bundled/v3/components/OrRichTextEditorV3/index.js +1 -1
  6. package/dist/bundled/v3/components/OrRichTextEditorV3/props.js +1 -1
  7. package/dist/bundled/v3/components/OrRichTextEditorV3/styles.js +1 -1
  8. package/dist/bundled/v3/components/OrRichTextEditorV3/utils/codemirror/codemirrorNode.js +1 -1
  9. package/dist/bundled/v3/components/OrRichTextEditorV3/utils/codemirror/codemirrorView.js +1 -1
  10. package/dist/bundled/v3/components/OrRichTextEditorV3/utils/codemirror/index.js +1 -1
  11. package/dist/bundled/v3/components/OrRichTextEditorV3/utils/codemirror/theme.js +1 -1
  12. package/dist/bundled/v3/components/OrRichTextEditorV3/utils/markdown.js +1 -1
  13. package/dist/bundled/v3/components/{OrRichTextEditorV3-f20322fb.js → OrRichTextEditorV3-343c5a89.js} +69 -68
  14. package/dist/bundled/v3/components/index.js +1 -1
  15. package/dist/bundled/v3/index.js +1 -1
  16. package/dist/esm/v2/{OrRichTextEditor-2decab60.js → OrRichTextEditor-c03de64c.js} +5 -3
  17. package/dist/esm/v2/components/index.js +2 -1
  18. package/dist/esm/v2/components/or-rich-text-editor-v3/index.js +2 -1
  19. package/dist/esm/v2/index.js +2 -1
  20. package/dist/esm/v3/{OrRichTextEditor-ab25c57e.js → OrRichTextEditor-9781c771.js} +5 -3
  21. package/dist/esm/v3/components/index.js +2 -1
  22. package/dist/esm/v3/components/or-rich-text-editor-v3/index.js +2 -1
  23. package/dist/esm/v3/index.js +2 -1
  24. package/package.json +3 -3
  25. package/src/components/or-rich-text-editor-v3/OrRichTextEditor.vue +3 -2
  26. package/src/components/or-rich-text-editor-v3/utils/markdown.ts +2 -0
@@ -1,10 +1,10 @@
1
1
  import { g as useResizeObserver, o as onClickOutside } from '../../index-13c63b4c.js';
2
2
  import { u as useFocusTrap } from '../../useFocusTrap-c1b303f8.js';
3
3
  import { defineComponent, ref, onMounted, onBeforeUnmount, computed, watch, nextTick } from 'vue-demi';
4
- import { B as Blockquote, a as Bold, b as BulletList, C as CodeBlock, H as HardBreak, I as Italic, L as ListItem, O as OrderedList, P as Paragraph, S as Strike, s as serialize, d as deserialize, U as Underline, c as Link, e as Highlight } from '../../markdown-4af315b8.js';
4
+ import { B as Blockquote, a as Bold, b as BulletList, C as CodeBlock, H as HardBreak, c as HorizontalRule, I as Italic, L as ListItem, O as OrderedList, P as Paragraph, S as Strike, s as serialize, d as deserialize, U as Underline, e as Link, f as Highlight } from '../../markdown-62ee11bf.js';
5
5
  import { OrRichTextEditor, EditorContainer, ToolbarContainer, Toolbar, ToolbarButtonFocused, ToolbarButton, EditorInput } from './styles.js';
6
6
  import { Formats } from './props.js';
7
- import { N as Node, m as mergeAttributes, t as textblockTypeInputRule, E as Extension, D as Decoration, a as DecorationSet, M as Mark, b as markInputRule, c as markPasteRule, k as keydownHandler, d as callOrReturn, g as getExtensionField, n as nodeInputRule, e as Editor } from '../../index-7516cf60.js';
7
+ import { N as Node, m as mergeAttributes, t as textblockTypeInputRule, E as Extension, D as Decoration, a as DecorationSet, M as Mark, b as markInputRule, c as markPasteRule, k as keydownHandler, d as callOrReturn, g as getExtensionField, e as Editor } from '../../index-7516cf60.js';
8
8
  import { P as Plugin, a as PluginKey, d as dropPoint, S as Selection, N as NodeSelection, F as Fragment, b as Slice, T as TextSelection, M as Mapping } from '../../index-02a897ac.js';
9
9
  import codemirrorNode from './utils/codemirror/codemirrorNode.js';
10
10
  import __vue_component__$1 from '../OrIconButtonV3/OrIconButton.js';
@@ -1291,71 +1291,6 @@ const History = Extension.create({
1291
1291
  }
1292
1292
  });
1293
1293
 
1294
- const HorizontalRule = Node.create({
1295
- name: 'horizontalRule',
1296
- addOptions() {
1297
- return {
1298
- HTMLAttributes: {}
1299
- };
1300
- },
1301
- group: 'block',
1302
- parseHTML() {
1303
- return [{
1304
- tag: 'hr'
1305
- }];
1306
- },
1307
- renderHTML(_ref) {
1308
- let {
1309
- HTMLAttributes
1310
- } = _ref;
1311
- return ['hr', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes)];
1312
- },
1313
- addCommands() {
1314
- return {
1315
- setHorizontalRule: () => _ref2 => {
1316
- let {
1317
- chain
1318
- } = _ref2;
1319
- return chain().insertContent({
1320
- type: this.name
1321
- })
1322
- // set cursor after horizontal rule
1323
- .command(_ref3 => {
1324
- let {
1325
- tr,
1326
- dispatch
1327
- } = _ref3;
1328
- var _a;
1329
- if (dispatch) {
1330
- const {
1331
- $to
1332
- } = tr.selection;
1333
- const posAfter = $to.end();
1334
- if ($to.nodeAfter) {
1335
- tr.setSelection(TextSelection.create(tr.doc, $to.pos));
1336
- } else {
1337
- // add node after horizontal rule if it’s the end of the document
1338
- const node = (_a = $to.parent.type.contentMatch.defaultType) === null || _a === void 0 ? void 0 : _a.create();
1339
- if (node) {
1340
- tr.insert(posAfter, node);
1341
- tr.setSelection(TextSelection.create(tr.doc, posAfter));
1342
- }
1343
- }
1344
- tr.scrollIntoView();
1345
- }
1346
- return true;
1347
- }).run();
1348
- }
1349
- };
1350
- },
1351
- addInputRules() {
1352
- return [nodeInputRule({
1353
- find: /^(?:---|—-|___\s|\*\*\*\s)$/,
1354
- type: this.type
1355
- })];
1356
- }
1357
- });
1358
-
1359
1294
  const Text = Node.create({
1360
1295
  name: 'text',
1361
1296
  group: 'inline'
@@ -1861,8 +1796,8 @@ var script = defineComponent({
1861
1796
  editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
1862
1797
  }
1863
1798
  if (props.format === 'markdown' && value !== markdownOutput.value) {
1864
- //TODO: const deserialized = deserialize(editor?.schema, value);
1865
- editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
1799
+ const deserialized = deserialize(editor === null || editor === void 0 ? void 0 : editor.schema, value);
1800
+ editor === null || editor === void 0 ? void 0 : editor.commands.setContent(deserialized);
1866
1801
  }
1867
1802
  });
1868
1803
  return {
@@ -1,2 +1,2 @@
1
- export { d as deserialize, s as serialize } from '../../../markdown-4af315b8.js';
1
+ export { d as deserialize, s as serialize } from '../../../markdown-62ee11bf.js';
2
2
  import '../../../index-02a897ac.js';
@@ -1,6 +1,6 @@
1
- import { c as Schema, e as Mark, P as Plugin, a as PluginKey, T as TextSelection, D as DOMParser$1 } from './index-02a897ac.js';
1
+ import { c as Schema, e as Mark, T as TextSelection, P as Plugin, a as PluginKey, D as DOMParser$1 } from './index-02a897ac.js';
2
2
  import { c as commonjsGlobal, g as getDefaultExportFromCjs } from './_commonjsHelpers-1789f0cf.js';
3
- import { N as Node, m as mergeAttributes, M as Mark$1, f as getMarkAttributes, w as wrappingInputRule, b as markInputRule, c as markPasteRule, t as textblockTypeInputRule, h as combineTransactionSteps, i as getChangedRanges, j as getMarksBetween, l as findChildrenInRange, o as getAttributes } from './index-7516cf60.js';
3
+ import { N as Node, m as mergeAttributes, M as Mark$1, f as getMarkAttributes, w as wrappingInputRule, b as markInputRule, c as markPasteRule, n as nodeInputRule, t as textblockTypeInputRule, h as combineTransactionSteps, i as getChangedRanges, j as getMarksBetween, l as findChildrenInRange, o as getAttributes } from './index-7516cf60.js';
4
4
 
5
5
  var markdownIt_minExports = {};
6
6
  var markdownIt_min = {
@@ -7959,6 +7959,71 @@ const HardBreak = Node.create({
7959
7959
  }
7960
7960
  });
7961
7961
 
7962
+ const HorizontalRule = Node.create({
7963
+ name: 'horizontalRule',
7964
+ addOptions() {
7965
+ return {
7966
+ HTMLAttributes: {}
7967
+ };
7968
+ },
7969
+ group: 'block',
7970
+ parseHTML() {
7971
+ return [{
7972
+ tag: 'hr'
7973
+ }];
7974
+ },
7975
+ renderHTML(_ref) {
7976
+ let {
7977
+ HTMLAttributes
7978
+ } = _ref;
7979
+ return ['hr', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes)];
7980
+ },
7981
+ addCommands() {
7982
+ return {
7983
+ setHorizontalRule: () => _ref2 => {
7984
+ let {
7985
+ chain
7986
+ } = _ref2;
7987
+ return chain().insertContent({
7988
+ type: this.name
7989
+ })
7990
+ // set cursor after horizontal rule
7991
+ .command(_ref3 => {
7992
+ let {
7993
+ tr,
7994
+ dispatch
7995
+ } = _ref3;
7996
+ var _a;
7997
+ if (dispatch) {
7998
+ const {
7999
+ $to
8000
+ } = tr.selection;
8001
+ const posAfter = $to.end();
8002
+ if ($to.nodeAfter) {
8003
+ tr.setSelection(TextSelection.create(tr.doc, $to.pos));
8004
+ } else {
8005
+ // add node after horizontal rule if it’s the end of the document
8006
+ const node = (_a = $to.parent.type.contentMatch.defaultType) === null || _a === void 0 ? void 0 : _a.create();
8007
+ if (node) {
8008
+ tr.insert(posAfter, node);
8009
+ tr.setSelection(TextSelection.create(tr.doc, posAfter));
8010
+ }
8011
+ }
8012
+ tr.scrollIntoView();
8013
+ }
8014
+ return true;
8015
+ }).run();
8016
+ }
8017
+ };
8018
+ },
8019
+ addInputRules() {
8020
+ return [nodeInputRule({
8021
+ find: /^(?:---|—-|___\s|\*\*\*\s)$/,
8022
+ type: this.type
8023
+ })];
8024
+ }
8025
+ });
8026
+
7962
8027
  const starInputRegex = /(?:^|\s)((?:\*\*)((?:[^*]+))(?:\*\*))$/;
7963
8028
  const starPasteRegex = /(?:^|\s)((?:\*\*)((?:[^*]+))(?:\*\*))/g;
7964
8029
  const underscoreInputRegex = /(?:^|\s)((?:__)((?:[^__]+))(?:__))$/;
@@ -10489,7 +10554,8 @@ const mdSerializerNodes = {
10489
10554
  [OrderedList.name]: defaultMarkdownSerializer.nodes.ordered_list,
10490
10555
  [HardBreak.name]: defaultMarkdownSerializer.nodes.hard_break,
10491
10556
  [CodeBlock.name]: defaultMarkdownSerializer.nodes.code_block,
10492
- [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote
10557
+ [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote,
10558
+ [HorizontalRule.name]: defaultMarkdownSerializer.nodes.horizontal_rule
10493
10559
  };
10494
10560
  const mdSerializerMarks = {
10495
10561
  ...defaultMarkdownSerializer.marks,
@@ -10557,4 +10623,4 @@ function deserialize(schema, content) {
10557
10623
  return state.toJSON();
10558
10624
  }
10559
10625
 
10560
- export { Blockquote as B, CodeBlock as C, HardBreak as H, Italic as I, ListItem$1 as L, OrderedList as O, Paragraph as P, Strike as S, Underline as U, Bold as a, BulletList as b, Link as c, deserialize as d, Highlight as e, serialize as s };
10626
+ export { Blockquote as B, CodeBlock as C, HardBreak as H, Italic as I, ListItem$1 as L, OrderedList as O, Paragraph as P, Strike as S, Underline as U, Bold as a, BulletList as b, HorizontalRule as c, deserialize as d, Link as e, Highlight as f, serialize as s };
@@ -1 +1 @@
1
- export { s as default } from '../OrRichTextEditorV3-f20322fb.js';
1
+ export { s as default } from '../OrRichTextEditorV3-343c5a89.js';
@@ -1 +1 @@
1
- export { F as Formats, s as OrRichTextEditorV3 } from '../OrRichTextEditorV3-f20322fb.js';
1
+ export { F as Formats, s as OrRichTextEditorV3 } from '../OrRichTextEditorV3-343c5a89.js';
@@ -1 +1 @@
1
- export { F as Formats } from '../OrRichTextEditorV3-f20322fb.js';
1
+ export { F as Formats } from '../OrRichTextEditorV3-343c5a89.js';
@@ -1 +1 @@
1
- export { E as EditorContainer, f as EditorInput, O as OrRichTextEditor, b as Toolbar, c as ToolbarButton, e as ToolbarButtonFocused, T as ToolbarContainer } from '../OrRichTextEditorV3-f20322fb.js';
1
+ export { E as EditorContainer, f as EditorInput, O as OrRichTextEditor, b as Toolbar, c as ToolbarButton, e as ToolbarButtonFocused, T as ToolbarContainer } from '../OrRichTextEditorV3-343c5a89.js';
@@ -1,2 +1,2 @@
1
- export { i as default } from '../../../OrRichTextEditorV3-f20322fb.js';
1
+ export { i as default } from '../../../OrRichTextEditorV3-343c5a89.js';
2
2
  import '../../../OrCode-76048d47.js';
@@ -1,2 +1,2 @@
1
- export { C as default } from '../../../OrRichTextEditorV3-f20322fb.js';
1
+ export { C as default } from '../../../OrRichTextEditorV3-343c5a89.js';
2
2
  import '../../../OrCode-76048d47.js';
@@ -1 +1 @@
1
- export { C as CodeMirrorView } from '../../../OrRichTextEditorV3-f20322fb.js';
1
+ export { C as CodeMirrorView } from '../../../OrRichTextEditorV3-343c5a89.js';
@@ -1,3 +1,3 @@
1
1
  import '../../../OrCode-76048d47.js';
2
2
  import '../../../../hooks/useTheme.js';
3
- export { g as color, t as default, h as orCodeHighlightStyle, o as orCodeTheme } from '../../../OrRichTextEditorV3-f20322fb.js';
3
+ export { g as color, t as default, h as orCodeHighlightStyle, o as orCodeTheme } from '../../../OrRichTextEditorV3-343c5a89.js';
@@ -1 +1 @@
1
- export { d as deserialize, a as serialize } from '../../OrRichTextEditorV3-f20322fb.js';
1
+ export { d as deserialize, a as serialize } from '../../OrRichTextEditorV3-343c5a89.js';
@@ -24811,6 +24811,71 @@ const HardBreak = Node.create({
24811
24811
  }
24812
24812
  });
24813
24813
 
24814
+ const HorizontalRule = Node.create({
24815
+ name: 'horizontalRule',
24816
+ addOptions() {
24817
+ return {
24818
+ HTMLAttributes: {}
24819
+ };
24820
+ },
24821
+ group: 'block',
24822
+ parseHTML() {
24823
+ return [{
24824
+ tag: 'hr'
24825
+ }];
24826
+ },
24827
+ renderHTML(_ref) {
24828
+ let {
24829
+ HTMLAttributes
24830
+ } = _ref;
24831
+ return ['hr', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes)];
24832
+ },
24833
+ addCommands() {
24834
+ return {
24835
+ setHorizontalRule: () => _ref2 => {
24836
+ let {
24837
+ chain
24838
+ } = _ref2;
24839
+ return chain().insertContent({
24840
+ type: this.name
24841
+ })
24842
+ // set cursor after horizontal rule
24843
+ .command(_ref3 => {
24844
+ let {
24845
+ tr,
24846
+ dispatch
24847
+ } = _ref3;
24848
+ var _a;
24849
+ if (dispatch) {
24850
+ const {
24851
+ $to
24852
+ } = tr.selection;
24853
+ const posAfter = $to.end();
24854
+ if ($to.nodeAfter) {
24855
+ tr.setSelection(TextSelection.create(tr.doc, $to.pos));
24856
+ } else {
24857
+ // add node after horizontal rule if it’s the end of the document
24858
+ const node = (_a = $to.parent.type.contentMatch.defaultType) === null || _a === void 0 ? void 0 : _a.create();
24859
+ if (node) {
24860
+ tr.insert(posAfter, node);
24861
+ tr.setSelection(TextSelection.create(tr.doc, posAfter));
24862
+ }
24863
+ }
24864
+ tr.scrollIntoView();
24865
+ }
24866
+ return true;
24867
+ }).run();
24868
+ }
24869
+ };
24870
+ },
24871
+ addInputRules() {
24872
+ return [nodeInputRule({
24873
+ find: /^(?:---|—-|___\s|\*\*\*\s)$/,
24874
+ type: this.type
24875
+ })];
24876
+ }
24877
+ });
24878
+
24814
24879
  const starInputRegex = /(?:^|\s)((?:\*\*)((?:[^*]+))(?:\*\*))$/;
24815
24880
  const starPasteRegex = /(?:^|\s)((?:\*\*)((?:[^*]+))(?:\*\*))/g;
24816
24881
  const underscoreInputRegex = /(?:^|\s)((?:__)((?:[^__]+))(?:__))$/;
@@ -27341,7 +27406,8 @@ const mdSerializerNodes = {
27341
27406
  [OrderedList.name]: defaultMarkdownSerializer.nodes.ordered_list,
27342
27407
  [HardBreak.name]: defaultMarkdownSerializer.nodes.hard_break,
27343
27408
  [CodeBlock.name]: defaultMarkdownSerializer.nodes.code_block,
27344
- [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote
27409
+ [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote,
27410
+ [HorizontalRule.name]: defaultMarkdownSerializer.nodes.horizontal_rule
27345
27411
  };
27346
27412
  const mdSerializerMarks = {
27347
27413
  ...defaultMarkdownSerializer.marks,
@@ -28731,71 +28797,6 @@ const History = Extension.create({
28731
28797
  }
28732
28798
  });
28733
28799
 
28734
- const HorizontalRule = Node.create({
28735
- name: 'horizontalRule',
28736
- addOptions() {
28737
- return {
28738
- HTMLAttributes: {}
28739
- };
28740
- },
28741
- group: 'block',
28742
- parseHTML() {
28743
- return [{
28744
- tag: 'hr'
28745
- }];
28746
- },
28747
- renderHTML(_ref) {
28748
- let {
28749
- HTMLAttributes
28750
- } = _ref;
28751
- return ['hr', mergeAttributes(this.options.HTMLAttributes, HTMLAttributes)];
28752
- },
28753
- addCommands() {
28754
- return {
28755
- setHorizontalRule: () => _ref2 => {
28756
- let {
28757
- chain
28758
- } = _ref2;
28759
- return chain().insertContent({
28760
- type: this.name
28761
- })
28762
- // set cursor after horizontal rule
28763
- .command(_ref3 => {
28764
- let {
28765
- tr,
28766
- dispatch
28767
- } = _ref3;
28768
- var _a;
28769
- if (dispatch) {
28770
- const {
28771
- $to
28772
- } = tr.selection;
28773
- const posAfter = $to.end();
28774
- if ($to.nodeAfter) {
28775
- tr.setSelection(TextSelection.create(tr.doc, $to.pos));
28776
- } else {
28777
- // add node after horizontal rule if it’s the end of the document
28778
- const node = (_a = $to.parent.type.contentMatch.defaultType) === null || _a === void 0 ? void 0 : _a.create();
28779
- if (node) {
28780
- tr.insert(posAfter, node);
28781
- tr.setSelection(TextSelection.create(tr.doc, posAfter));
28782
- }
28783
- }
28784
- tr.scrollIntoView();
28785
- }
28786
- return true;
28787
- }).run();
28788
- }
28789
- };
28790
- },
28791
- addInputRules() {
28792
- return [nodeInputRule({
28793
- find: /^(?:---|—-|___\s|\*\*\*\s)$/,
28794
- type: this.type
28795
- })];
28796
- }
28797
- });
28798
-
28799
28800
  const Text = Node.create({
28800
28801
  name: 'text',
28801
28802
  group: 'inline'
@@ -29710,8 +29711,8 @@ var script = defineComponent({
29710
29711
  editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
29711
29712
  }
29712
29713
  if (props.format === 'markdown' && value !== markdownOutput.value) {
29713
- //TODO: const deserialized = deserialize(editor?.schema, value);
29714
- editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
29714
+ const deserialized = deserialize(editor === null || editor === void 0 ? void 0 : editor.schema, value);
29715
+ editor === null || editor === void 0 ? void 0 : editor.commands.setContent(deserialized);
29715
29716
  }
29716
29717
  });
29717
29718
  return {
@@ -81,7 +81,7 @@ export { s as OrRadioV3 } from './OrRadioV3-ab52b7d4.js';
81
81
  export { s as OrRangeSliderV3 } from './OrRangeSliderV3-1302c0d5.js';
82
82
  export { s as OrRatingV3 } from './OrRatingV3-82a538ca.js';
83
83
  export { s as OrResizeablePanelV3, R as ResizeablePanelPadding, a as ResizeablePanelPlacement } from './OrResizeablePanelV3-9aae7208.js';
84
- export { F as Formats, s as OrRichTextEditorV3 } from './OrRichTextEditorV3-f20322fb.js';
84
+ export { F as Formats, s as OrRichTextEditorV3 } from './OrRichTextEditorV3-343c5a89.js';
85
85
  export { default as OrSearch } from './OrSearch/OrSearch.js';
86
86
  export { default as OrSearchV3 } from './OrSearchV3/OrSearch.js';
87
87
  export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControlV3-de9f3667.js';
@@ -44,7 +44,7 @@ export { default as OrRadioGroup } from './components/OrRadioGroup/OrRadioGroup.
44
44
  export { default as OrRadioGroupV3 } from './components/OrRadioGroupV3/OrRadioGroup.js';
45
45
  export { s as OrRangeSliderV3 } from './components/OrRangeSliderV3-1302c0d5.js';
46
46
  export { s as OrRatingV3 } from './components/OrRatingV3-82a538ca.js';
47
- export { F as Formats, s as OrRichTextEditorV3 } from './components/OrRichTextEditorV3-f20322fb.js';
47
+ export { F as Formats, s as OrRichTextEditorV3 } from './components/OrRichTextEditorV3-343c5a89.js';
48
48
  export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './components/OrSegmentedControlV3-de9f3667.js';
49
49
  export { s as OrSelect } from './components/OrSelect-362ba223.js';
50
50
  export { s as OrSelectV3 } from './components/OrSelectV3-b1418e70.js';
@@ -11,6 +11,7 @@ import OrderedList from '@tiptap/extension-ordered-list';
11
11
  import Strike from '@tiptap/extension-strike';
12
12
  import Italic from '@tiptap/extension-italic';
13
13
  import HardBreak from '@tiptap/extension-hard-break';
14
+ import HorizontalRule from '@tiptap/extension-horizontal-rule';
14
15
  import Bold from '@tiptap/extension-bold';
15
16
  import CodeBlock from '@tiptap/extension-code-block';
16
17
  import Blockquote from '@tiptap/extension-blockquote';
@@ -47,7 +48,8 @@ const mdSerializerNodes = {
47
48
  [OrderedList.name]: defaultMarkdownSerializer.nodes.ordered_list,
48
49
  [HardBreak.name]: defaultMarkdownSerializer.nodes.hard_break,
49
50
  [CodeBlock.name]: defaultMarkdownSerializer.nodes.code_block,
50
- [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote
51
+ [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote,
52
+ [HorizontalRule.name]: defaultMarkdownSerializer.nodes.horizontal_rule
51
53
  };
52
54
  const mdSerializerMarks = {
53
55
  ...defaultMarkdownSerializer.marks,
@@ -640,8 +642,8 @@ var script = defineComponent({
640
642
  editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
641
643
  }
642
644
  if (props.format === 'markdown' && value !== markdownOutput.value) {
643
- //TODO: const deserialized = deserialize(editor?.schema, value);
644
- editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
645
+ const deserialized = deserialize(editor === null || editor === void 0 ? void 0 : editor.schema, value);
646
+ editor === null || editor === void 0 ? void 0 : editor.commands.setContent(deserialized);
645
647
  }
646
648
  });
647
649
  return {
@@ -99,7 +99,7 @@ export { _ as OrRadioV3 } from '../OrRadio-3629ad83.js';
99
99
  export { _ as OrRangeSliderV3 } from '../OrRangeSlider-0f59285f.js';
100
100
  export { _ as OrRatingV3 } from '../OrRating-aa2365e9.js';
101
101
  export { _ as OrResizeablePanelV3, R as ResizeablePanelPadding, a as ResizeablePanelPlacement } from '../OrResizeablePanel-2f741cc2.js';
102
- export { F as Formats, _ as OrRichTextEditorV3 } from '../OrRichTextEditor-2decab60.js';
102
+ export { F as Formats, _ as OrRichTextEditorV3 } from '../OrRichTextEditor-c03de64c.js';
103
103
  export { _ as OrSearch } from '../OrSearch-a340d5ff.js';
104
104
  export { _ as OrSearchV3 } from '../OrSearch-9eef2fa5.js';
105
105
  export { _ as OrSegmentedControlV3, S as SegmentedControlSize } from '../OrSegmentedControl-cd16856e.js';
@@ -206,6 +206,7 @@ import '@tiptap/extension-ordered-list';
206
206
  import '@tiptap/extension-strike';
207
207
  import '@tiptap/extension-italic';
208
208
  import '@tiptap/extension-hard-break';
209
+ import '@tiptap/extension-horizontal-rule';
209
210
  import '@tiptap/extension-bold';
210
211
  import '@tiptap/extension-code-block';
211
212
  import '@tiptap/extension-blockquote';
@@ -1,4 +1,4 @@
1
- export { F as Formats, _ as OrRichTextEditorV3 } from '../../OrRichTextEditor-2decab60.js';
1
+ export { F as Formats, _ as OrRichTextEditorV3 } from '../../OrRichTextEditor-c03de64c.js';
2
2
  import '@vueuse/core';
3
3
  import '@vueuse/integrations/useFocusTrap';
4
4
  import 'vue-demi';
@@ -12,6 +12,7 @@ import '@tiptap/extension-ordered-list';
12
12
  import '@tiptap/extension-strike';
13
13
  import '@tiptap/extension-italic';
14
14
  import '@tiptap/extension-hard-break';
15
+ import '@tiptap/extension-horizontal-rule';
15
16
  import '@tiptap/extension-bold';
16
17
  import '@tiptap/extension-code-block';
17
18
  import '@tiptap/extension-blockquote';
@@ -99,7 +99,7 @@ export { _ as OrRadioV3 } from './OrRadio-3629ad83.js';
99
99
  export { _ as OrRangeSliderV3 } from './OrRangeSlider-0f59285f.js';
100
100
  export { _ as OrRatingV3 } from './OrRating-aa2365e9.js';
101
101
  export { _ as OrResizeablePanelV3, R as ResizeablePanelPadding, a as ResizeablePanelPlacement } from './OrResizeablePanel-2f741cc2.js';
102
- export { F as Formats, _ as OrRichTextEditorV3 } from './OrRichTextEditor-2decab60.js';
102
+ export { F as Formats, _ as OrRichTextEditorV3 } from './OrRichTextEditor-c03de64c.js';
103
103
  export { _ as OrSearch } from './OrSearch-a340d5ff.js';
104
104
  export { _ as OrSearchV3 } from './OrSearch-9eef2fa5.js';
105
105
  export { _ as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-cd16856e.js';
@@ -208,6 +208,7 @@ import '@tiptap/extension-ordered-list';
208
208
  import '@tiptap/extension-strike';
209
209
  import '@tiptap/extension-italic';
210
210
  import '@tiptap/extension-hard-break';
211
+ import '@tiptap/extension-horizontal-rule';
211
212
  import '@tiptap/extension-bold';
212
213
  import '@tiptap/extension-code-block';
213
214
  import '@tiptap/extension-blockquote';
@@ -11,6 +11,7 @@ import OrderedList from '@tiptap/extension-ordered-list';
11
11
  import Strike from '@tiptap/extension-strike';
12
12
  import Italic from '@tiptap/extension-italic';
13
13
  import HardBreak from '@tiptap/extension-hard-break';
14
+ import HorizontalRule from '@tiptap/extension-horizontal-rule';
14
15
  import Bold from '@tiptap/extension-bold';
15
16
  import CodeBlock from '@tiptap/extension-code-block';
16
17
  import Blockquote from '@tiptap/extension-blockquote';
@@ -46,7 +47,8 @@ const mdSerializerNodes = {
46
47
  [OrderedList.name]: defaultMarkdownSerializer.nodes.ordered_list,
47
48
  [HardBreak.name]: defaultMarkdownSerializer.nodes.hard_break,
48
49
  [CodeBlock.name]: defaultMarkdownSerializer.nodes.code_block,
49
- [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote
50
+ [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote,
51
+ [HorizontalRule.name]: defaultMarkdownSerializer.nodes.horizontal_rule
50
52
  };
51
53
  const mdSerializerMarks = {
52
54
  ...defaultMarkdownSerializer.marks,
@@ -639,8 +641,8 @@ var script = defineComponent({
639
641
  editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
640
642
  }
641
643
  if (props.format === 'markdown' && value !== markdownOutput.value) {
642
- //TODO: const deserialized = deserialize(editor?.schema, value);
643
- editor === null || editor === void 0 ? void 0 : editor.commands.setContent(value);
644
+ const deserialized = deserialize(editor === null || editor === void 0 ? void 0 : editor.schema, value);
645
+ editor === null || editor === void 0 ? void 0 : editor.commands.setContent(deserialized);
644
646
  }
645
647
  });
646
648
  return {
@@ -96,7 +96,7 @@ export { s as OrRadioV3 } from '../OrRadio-370438a9.js';
96
96
  export { s as OrRangeSliderV3 } from '../OrRangeSlider-820d0c22.js';
97
97
  export { s as OrRatingV3 } from '../OrRating-2abf71bd.js';
98
98
  export { s as OrResizeablePanelV3, R as ResizeablePanelPadding, a as ResizeablePanelPlacement } from '../OrResizeablePanel-6e37ca25.js';
99
- export { F as Formats, s as OrRichTextEditorV3 } from '../OrRichTextEditor-ab25c57e.js';
99
+ export { F as Formats, s as OrRichTextEditorV3 } from '../OrRichTextEditor-9781c771.js';
100
100
  export { s as OrSearch } from '../OrSearch-948c7f78.js';
101
101
  export { s as OrSearchV3 } from '../OrSearch-a10f294f.js';
102
102
  export { s as OrSegmentedControlV3, S as SegmentedControlSize } from '../OrSegmentedControl-1370c626.js';
@@ -197,6 +197,7 @@ import '@tiptap/extension-ordered-list';
197
197
  import '@tiptap/extension-strike';
198
198
  import '@tiptap/extension-italic';
199
199
  import '@tiptap/extension-hard-break';
200
+ import '@tiptap/extension-horizontal-rule';
200
201
  import '@tiptap/extension-bold';
201
202
  import '@tiptap/extension-code-block';
202
203
  import '@tiptap/extension-blockquote';
@@ -1,4 +1,4 @@
1
- export { F as Formats, s as OrRichTextEditorV3 } from '../../OrRichTextEditor-ab25c57e.js';
1
+ export { F as Formats, s as OrRichTextEditorV3 } from '../../OrRichTextEditor-9781c771.js';
2
2
  import '@vueuse/core';
3
3
  import '@vueuse/integrations/useFocusTrap';
4
4
  import 'vue-demi';
@@ -12,6 +12,7 @@ import '@tiptap/extension-ordered-list';
12
12
  import '@tiptap/extension-strike';
13
13
  import '@tiptap/extension-italic';
14
14
  import '@tiptap/extension-hard-break';
15
+ import '@tiptap/extension-horizontal-rule';
15
16
  import '@tiptap/extension-bold';
16
17
  import '@tiptap/extension-code-block';
17
18
  import '@tiptap/extension-blockquote';
@@ -96,7 +96,7 @@ export { s as OrRadioV3 } from './OrRadio-370438a9.js';
96
96
  export { s as OrRangeSliderV3 } from './OrRangeSlider-820d0c22.js';
97
97
  export { s as OrRatingV3 } from './OrRating-2abf71bd.js';
98
98
  export { s as OrResizeablePanelV3, R as ResizeablePanelPadding, a as ResizeablePanelPlacement } from './OrResizeablePanel-6e37ca25.js';
99
- export { F as Formats, s as OrRichTextEditorV3 } from './OrRichTextEditor-ab25c57e.js';
99
+ export { F as Formats, s as OrRichTextEditorV3 } from './OrRichTextEditor-9781c771.js';
100
100
  export { s as OrSearch } from './OrSearch-948c7f78.js';
101
101
  export { s as OrSearchV3 } from './OrSearch-a10f294f.js';
102
102
  export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-1370c626.js';
@@ -199,6 +199,7 @@ import '@tiptap/extension-ordered-list';
199
199
  import '@tiptap/extension-strike';
200
200
  import '@tiptap/extension-italic';
201
201
  import '@tiptap/extension-hard-break';
202
+ import '@tiptap/extension-horizontal-rule';
202
203
  import '@tiptap/extension-bold';
203
204
  import '@tiptap/extension-code-block';
204
205
  import '@tiptap/extension-blockquote';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@onereach/ui-components",
3
- "version": "10.3.2",
3
+ "version": "10.3.3-beta.4314.0",
4
4
  "npmUnpacked": "4.15.2",
5
5
  "description": "Vue components library for v2/3",
6
6
  "sideEffects": false,
@@ -50,6 +50,7 @@
50
50
  "@tiptap/extension-hard-break": "2.0.3",
51
51
  "@tiptap/extension-heading": "2.0.3",
52
52
  "@tiptap/extension-highlight": "2.0.3",
53
+ "@tiptap/extension-horizontal-rule": "2.0.3",
53
54
  "@tiptap/extension-italic": "2.0.3",
54
55
  "@tiptap/extension-link": "2.0.3",
55
56
  "@tiptap/extension-list-item": "2.0.3",
@@ -178,6 +179,5 @@
178
179
  "default": "./dist/bundled/v3/components/*/index.js"
179
180
  },
180
181
  "./package.json": "./package.json"
181
- },
182
- "gitHead": "caab855a84c26e0a28b86b8eabca2a65ba75a838"
182
+ }
183
183
  }
@@ -723,9 +723,10 @@ export default defineComponent({
723
723
  if (value !== editor?.getHTML() && props.format !== 'markdown') {
724
724
  editor?.commands.setContent(value as string);
725
725
  }
726
+
726
727
  if (props.format === 'markdown' && value !== markdownOutput.value) {
727
- //TODO: const deserialized = deserialize(editor?.schema, value);
728
- editor?.commands.setContent(value as string);
728
+ const deserialized = deserialize(editor?.schema, value);
729
+ editor?.commands.setContent(deserialized as string);
729
730
  }
730
731
  });
731
732
 
@@ -11,6 +11,7 @@ import OrderedList from '@tiptap/extension-ordered-list';
11
11
  import Strike from '@tiptap/extension-strike';
12
12
  import Italic from '@tiptap/extension-italic';
13
13
  import HardBreak from '@tiptap/extension-hard-break';
14
+ import HorizontalRule from '@tiptap/extension-horizontal-rule';
14
15
  import Bold from '@tiptap/extension-bold';
15
16
  import CodeBlock from '@tiptap/extension-code-block';
16
17
  import Blockquote from '@tiptap/extension-blockquote';
@@ -27,6 +28,7 @@ const mdSerializerNodes = {
27
28
  [HardBreak.name]: defaultMarkdownSerializer.nodes.hard_break,
28
29
  [CodeBlock.name]: defaultMarkdownSerializer.nodes.code_block,
29
30
  [Blockquote.name]: defaultMarkdownSerializer.nodes.blockquote,
31
+ [HorizontalRule.name]: defaultMarkdownSerializer.nodes.horizontal_rule,
30
32
  };
31
33
 
32
34
  const mdSerializerMarks = {