@licium/editor 3.2.7 → 3.2.9

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 (91) hide show
  1. package/dist/esm/i18n/ar.js +1 -1
  2. package/dist/esm/i18n/cs-cz.js +1 -1
  3. package/dist/esm/i18n/de-de.js +1 -1
  4. package/dist/esm/i18n/en-us.js +1 -1
  5. package/dist/esm/i18n/es-es.js +1 -1
  6. package/dist/esm/i18n/fi-fi.js +1 -1
  7. package/dist/esm/i18n/fr-fr.js +1 -1
  8. package/dist/esm/i18n/gl-es.js +1 -1
  9. package/dist/esm/i18n/hr-hr.js +1 -1
  10. package/dist/esm/i18n/i18n.js +1 -1
  11. package/dist/esm/i18n/it-it.js +1 -1
  12. package/dist/esm/i18n/ja-jp.js +1 -1
  13. package/dist/esm/i18n/ko-kr.js +1 -1
  14. package/dist/esm/i18n/nb-no.js +1 -1
  15. package/dist/esm/i18n/nl-nl.js +1 -1
  16. package/dist/esm/i18n/pl-pl.js +1 -1
  17. package/dist/esm/i18n/pt-br.js +1 -1
  18. package/dist/esm/i18n/ru-ru.js +1 -1
  19. package/dist/esm/i18n/sv-se.js +1 -1
  20. package/dist/esm/i18n/tr-tr.js +1 -1
  21. package/dist/esm/i18n/uk-ua.js +1 -1
  22. package/dist/esm/i18n/wysiwyg/nodes/details.d.ts +29 -0
  23. package/dist/esm/i18n/wysiwyg/nodes/summary.d.ts +23 -0
  24. package/dist/esm/i18n/zh-cn.js +1 -1
  25. package/dist/esm/i18n/zh-tw.js +1 -1
  26. package/dist/esm/index.js +120 -7
  27. package/dist/esm/indexViewer.js +2 -1
  28. package/dist/i18n/ar.js +1 -1
  29. package/dist/i18n/cs-cz.js +1 -1
  30. package/dist/i18n/de-de.js +1 -1
  31. package/dist/i18n/es-es.js +1 -1
  32. package/dist/i18n/fi-fi.js +1 -1
  33. package/dist/i18n/fr-fr.js +1 -1
  34. package/dist/i18n/gl-es.js +1 -1
  35. package/dist/i18n/hr-hr.js +1 -1
  36. package/dist/i18n/it-it.js +1 -1
  37. package/dist/i18n/ja-jp.js +1 -1
  38. package/dist/i18n/ko-kr.js +1 -1
  39. package/dist/i18n/nb-no.js +1 -1
  40. package/dist/i18n/nl-nl.js +1 -1
  41. package/dist/i18n/pl-pl.js +1 -1
  42. package/dist/i18n/pt-br.js +1 -1
  43. package/dist/i18n/ru-ru.js +1 -1
  44. package/dist/i18n/sv-se.js +1 -1
  45. package/dist/i18n/tr-tr.js +1 -1
  46. package/dist/i18n/uk-ua.js +1 -1
  47. package/dist/i18n/zh-cn.js +1 -1
  48. package/dist/i18n/zh-tw.js +1 -1
  49. package/dist/theme/toastui-editor-dark.css +33 -8
  50. package/dist/toastui-editor-only.css +45 -15
  51. package/dist/toastui-editor-viewer.css +1 -1
  52. package/dist/toastui-editor-viewer.js +15 -3
  53. package/dist/toastui-editor.css +45 -15
  54. package/dist/toastui-editor.js +128 -7
  55. package/package.json +2 -2
  56. package/types/index.d.ts +1 -1
  57. package/types/wysiwyg.d.ts +3 -1
  58. package/LICENSE +0 -21
  59. package/dist/esm/i18n/__test__/integration/ui/layout.spec.d.ts +0 -1
  60. package/dist/esm/i18n/__test__/integration/ui/toolbar.spec.d.ts +0 -1
  61. package/dist/esm/i18n/__test__/integration/vdom/render.spec.d.ts +0 -1
  62. package/dist/esm/i18n/__test__/integration/widget/widgetNode.spec.d.ts +0 -1
  63. package/dist/esm/i18n/__test__/unit/convertor.spec.d.ts +0 -1
  64. package/dist/esm/i18n/__test__/unit/dom.spec.d.ts +0 -1
  65. package/dist/esm/i18n/__test__/unit/editor.spec.d.ts +0 -1
  66. package/dist/esm/i18n/__test__/unit/eventEmitter.spec.d.ts +0 -1
  67. package/dist/esm/i18n/__test__/unit/helper/common.spec.d.ts +0 -1
  68. package/dist/esm/i18n/__test__/unit/helper/image.spec.d.ts +0 -1
  69. package/dist/esm/i18n/__test__/unit/linkXss.spec.d.ts +0 -1
  70. package/dist/esm/i18n/__test__/unit/markdown/keymap.spec.d.ts +0 -1
  71. package/dist/esm/i18n/__test__/unit/markdown/mdCommand.spec.d.ts +0 -1
  72. package/dist/esm/i18n/__test__/unit/markdown/mdEditor.spec.d.ts +0 -1
  73. package/dist/esm/i18n/__test__/unit/markdown/mdPreview.spec.d.ts +0 -1
  74. package/dist/esm/i18n/__test__/unit/markdown/smartTask.spec.d.ts +0 -1
  75. package/dist/esm/i18n/__test__/unit/markdown/syntaxHighlight.spec.d.ts +0 -1
  76. package/dist/esm/i18n/__test__/unit/markdown/util.d.ts +0 -7
  77. package/dist/esm/i18n/__test__/unit/repro_3296.spec.d.ts +0 -1
  78. package/dist/esm/i18n/__test__/unit/sanitizer.spec.d.ts +0 -1
  79. package/dist/esm/i18n/__test__/unit/utils/escape.spec.d.ts +0 -1
  80. package/dist/esm/i18n/__test__/unit/utils/pollution.spec.d.ts +0 -1
  81. package/dist/esm/i18n/__test__/unit/vdom/template.spec.d.ts +0 -1
  82. package/dist/esm/i18n/__test__/unit/viewer.spec.d.ts +0 -1
  83. package/dist/esm/i18n/__test__/unit/wysiwyg/customBlock.spec.d.ts +0 -1
  84. package/dist/esm/i18n/__test__/unit/wysiwyg/helper/pasteMsoList.spec.d.ts +0 -1
  85. package/dist/esm/i18n/__test__/unit/wysiwyg/imageInsertion.spec.d.ts +0 -1
  86. package/dist/esm/i18n/__test__/unit/wysiwyg/keymap.spec.d.ts +0 -1
  87. package/dist/esm/i18n/__test__/unit/wysiwyg/wwCommand.spec.d.ts +0 -1
  88. package/dist/esm/i18n/__test__/unit/wysiwyg/wwEditor.spec.d.ts +0 -1
  89. package/dist/esm/i18n/__test__/unit/wysiwyg/wwTableCommand.spec.d.ts +0 -1
  90. package/dist/esm/i18n/__test__/unit/wysiwyg/wwToDOMAdaptor.spec.d.ts +0 -1
  91. package/dist/esm/i18n/__test__/unit/xssSanitizer.spec.d.ts +0 -1
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -0,0 +1,29 @@
1
+ import { DOMOutputSpec, ProsemirrorNode } from 'prosemirror-model';
2
+ import NodeSchema from '@/spec/node';
3
+ export declare class Details extends NodeSchema {
4
+ get name(): string;
5
+ get schema(): {
6
+ content: string;
7
+ group: string;
8
+ defining: boolean;
9
+ isolating: boolean;
10
+ attrs: {
11
+ open: {
12
+ default: boolean;
13
+ };
14
+ htmlAttrs: {
15
+ default: any;
16
+ };
17
+ classNames: {
18
+ default: string[] | null;
19
+ };
20
+ };
21
+ parseDOM: {
22
+ tag: string;
23
+ getAttrs(dom: Node | string): {
24
+ open: boolean;
25
+ };
26
+ }[];
27
+ toDOM({ attrs }: ProsemirrorNode): DOMOutputSpec;
28
+ };
29
+ }
@@ -0,0 +1,23 @@
1
+ import { DOMOutputSpec, ProsemirrorNode } from 'prosemirror-model';
2
+ import NodeSchema from '@/spec/node';
3
+ export declare class Summary extends NodeSchema {
4
+ get name(): string;
5
+ get schema(): {
6
+ content: string;
7
+ group: string;
8
+ defining: boolean;
9
+ isolating: boolean;
10
+ attrs: {
11
+ htmlAttrs: {
12
+ default: any;
13
+ };
14
+ classNames: {
15
+ default: string[] | null;
16
+ };
17
+ };
18
+ parseDOM: {
19
+ tag: string;
20
+ }[];
21
+ toDOM({ attrs }: ProsemirrorNode): DOMOutputSpec;
22
+ };
23
+ }
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : i18n
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
package/dist/esm/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -14733,6 +14733,7 @@ function getChildrenHTML(node, typeName) {
14733
14733
  function getHTMLAttrsByHTMLString(html) {
14734
14734
  html = html.match(reHTMLTag)[0];
14735
14735
  const attrs = html.match(new RegExp(ATTRIBUTE$1, 'g'));
14736
+ // prettier-ignore
14736
14737
  return attrs
14737
14738
  ? attrs.reduce((acc, attr) => {
14738
14739
  const [name, ...values] = attr.trim().split('=');
@@ -14760,10 +14761,13 @@ function sanitizeDOM(node, typeName, sanitizer, wwToDOMAdaptor) {
14760
14761
  }
14761
14762
  const schemaFactory = {
14762
14763
  htmlBlock(typeName, sanitizeHTML, wwToDOMAdaptor) {
14764
+ const isContainer = ['details', 'summary'].includes(typeName);
14763
14765
  return {
14764
- atom: true,
14765
- content: 'block+',
14766
+ atom: !isContainer,
14767
+ content: typeName === 'summary' ? 'inline*' : 'block+',
14766
14768
  group: 'block',
14769
+ defining: isContainer,
14770
+ isolating: typeName === 'details',
14767
14771
  attrs: {
14768
14772
  htmlAttrs: { default: {} },
14769
14773
  childrenHTML: { default: '' },
@@ -14773,6 +14777,11 @@ const schemaFactory = {
14773
14777
  {
14774
14778
  tag: typeName,
14775
14779
  getAttrs(dom) {
14780
+ if (isContainer) {
14781
+ return {
14782
+ htmlAttrs: getHTMLAttrs(dom),
14783
+ };
14784
+ }
14776
14785
  return {
14777
14786
  htmlAttrs: getHTMLAttrs(dom),
14778
14787
  childrenHTML: dom.innerHTML,
@@ -14783,6 +14792,9 @@ const schemaFactory = {
14783
14792
  toDOM(node) {
14784
14793
  const { dom, htmlAttrs } = sanitizeDOM(node, typeName, sanitizeHTML, wwToDOMAdaptor);
14785
14794
  htmlAttrs.class = htmlAttrs.class ? `${htmlAttrs.class} html-block` : 'html-block';
14795
+ if (isContainer) {
14796
+ return [typeName, htmlAttrs, 0];
14797
+ }
14786
14798
  return [typeName, htmlAttrs, ...toArray_1(dom.childNodes)];
14787
14799
  },
14788
14800
  };
@@ -18646,6 +18658,57 @@ class HTMLComment extends Node$2 {
18646
18658
  }
18647
18659
  }
18648
18660
 
18661
+ class Details extends Node$2 {
18662
+ get name() {
18663
+ return 'details';
18664
+ }
18665
+ get schema() {
18666
+ return {
18667
+ content: 'summary block+',
18668
+ group: 'block',
18669
+ defining: true,
18670
+ isolating: true,
18671
+ attrs: Object.assign(Object.assign({}, getDefaultCustomAttrs()), { open: { default: true } }),
18672
+ parseDOM: [
18673
+ {
18674
+ tag: 'details',
18675
+ getAttrs(dom) {
18676
+ return {
18677
+ open: false, // Always collapse on load/switch to prevent unresponsive state
18678
+ };
18679
+ },
18680
+ },
18681
+ ],
18682
+ toDOM({ attrs }) {
18683
+ const domAttrs = getCustomAttrs(attrs);
18684
+ if (attrs.open) {
18685
+ domAttrs.open = '';
18686
+ }
18687
+ return ['details', domAttrs, 0];
18688
+ },
18689
+ };
18690
+ }
18691
+ }
18692
+
18693
+ class Summary extends Node$2 {
18694
+ get name() {
18695
+ return 'summary';
18696
+ }
18697
+ get schema() {
18698
+ return {
18699
+ content: 'inline*',
18700
+ group: 'block',
18701
+ defining: true,
18702
+ isolating: true,
18703
+ attrs: Object.assign({}, getDefaultCustomAttrs()),
18704
+ parseDOM: [{ tag: 'summary' }],
18705
+ toDOM({ attrs }) {
18706
+ return ['summary', getCustomAttrs(attrs), 0];
18707
+ },
18708
+ };
18709
+ }
18710
+ }
18711
+
18649
18712
  function createSpecs(linkAttributes) {
18650
18713
  return new SpecManager([
18651
18714
  new Doc(),
@@ -18675,6 +18738,8 @@ function createSpecs(linkAttributes) {
18675
18738
  new FrontMatter(),
18676
18739
  new Widget(),
18677
18740
  new HTMLComment(),
18741
+ new Details(),
18742
+ new Summary(),
18678
18743
  ]);
18679
18744
  }
18680
18745
 
@@ -19750,7 +19815,7 @@ const toWwConvertors = {
19750
19815
  const nodeType = state.schema.nodes[typeName];
19751
19816
  const sanitizedHTML = sanitizeHTML(html);
19752
19817
  // for user defined html schema
19753
- if (nodeType === null || nodeType === void 0 ? void 0 : nodeType.spec.attrs.htmlBlock) {
19818
+ if ((nodeType === null || nodeType === void 0 ? void 0 : nodeType.spec.attrs.htmlBlock) && nodeType.spec.atom) {
19754
19819
  const htmlAttrs = getHTMLAttrsByHTMLString(sanitizedHTML);
19755
19820
  const childrenHTML = getChildrenHTML(node, typeName);
19756
19821
  state.addNode(nodeType, { htmlAttrs, childrenHTML });
@@ -19994,6 +20059,12 @@ const nodeTypeWriters = {
19994
20059
  state.write(' \n');
19995
20060
  },
19996
20061
  paragraph(state, { node, parent, index = 0 }) {
20062
+ if (parent && parent.type.name === 'details') {
20063
+ state.write('<p>');
20064
+ state.convertInline(node);
20065
+ state.write('</p>');
20066
+ return;
20067
+ }
19997
20068
  if (state.stopNewline) {
19998
20069
  state.convertInline(node);
19999
20070
  }
@@ -20152,6 +20223,24 @@ const nodeTypeWriters = {
20152
20223
  state.write(text);
20153
20224
  state.closeBlock(node);
20154
20225
  },
20226
+ details(state, { node }) {
20227
+ const attrs = node.attrs.htmlAttrs || {};
20228
+ const openTag = attrs.open !== null && typeof attrs.open !== 'undefined'
20229
+ ? '<details open="">'
20230
+ : '<details>';
20231
+ state.write(`${openTag}\n`);
20232
+ state.stopNewline = true;
20233
+ state.convertNode(node);
20234
+ state.write('</details>');
20235
+ state.stopNewline = false;
20236
+ state.closeBlock(node);
20237
+ },
20238
+ summary(state, { node }) {
20239
+ state.write('<summary>');
20240
+ state.convertInline(node);
20241
+ state.write('</summary>');
20242
+ state.closeBlock(node);
20243
+ },
20155
20244
  };
20156
20245
  function write(type, { state, nodeInfo, params, }) {
20157
20246
  const { rawHTML } = params;
@@ -20495,6 +20584,7 @@ function createMarkTypeConvertors(convertors) {
20495
20584
  function createMdConvertors(customConvertors) {
20496
20585
  const customConvertorTypes = Object.keys(customConvertors);
20497
20586
  customConvertorTypes.forEach((type) => {
20587
+ console.log('[DEBUG] custom convertor for:', type);
20498
20588
  const baseConvertor = toMdConvertors[type];
20499
20589
  const customConvertor = customConvertors[type];
20500
20590
  if (baseConvertor) {
@@ -20629,7 +20719,9 @@ class ToMdConvertorState {
20629
20719
  // I must modify `convertNode` to pass it, or store it.
20630
20720
  // Storing it in the instance is cleanest given the recursion.
20631
20721
  // I need to add `infoForPosSync` to the class.
20632
- if (node.attrs.htmlBlock) {
20722
+ // Skip htmlBlock fallback for details/summary to use their custom writers
20723
+ const skipHtmlBlockTypes = ['details', 'summary'];
20724
+ if (node.attrs.htmlBlock && !skipHtmlBlockTypes.includes(type)) {
20633
20725
  this.nodeTypeConvertors.html(this, nodeInfo);
20634
20726
  }
20635
20727
  else if (convertor) {
@@ -21168,11 +21260,32 @@ const tokenToDOMNode = {
21168
21260
  }
21169
21261
  },
21170
21262
  html(token, stack) {
21171
- last$1(stack).insertAdjacentHTML('beforeend', token.content);
21263
+ const parent = last$1(stack);
21264
+ if (parent) {
21265
+ parent.insertAdjacentHTML('beforeend', token.content);
21266
+ }
21267
+ else {
21268
+ const html = token.content;
21269
+ const container = document.createElement('div');
21270
+ container.innerHTML = html;
21271
+ let child = container.firstChild;
21272
+ if (!child) {
21273
+ child = document.createElement('span');
21274
+ }
21275
+ else if (child.nodeType === Node.TEXT_NODE) {
21276
+ const wrapper = document.createElement('span');
21277
+ wrapper.appendChild(child);
21278
+ child = wrapper;
21279
+ }
21280
+ stack.push(child);
21281
+ }
21172
21282
  },
21173
21283
  text(token, stack) {
21174
21284
  const textNode = document.createTextNode(token.content);
21175
- last$1(stack).appendChild(textNode);
21285
+ const parent = last$1(stack);
21286
+ if (parent) {
21287
+ parent.appendChild(textNode);
21288
+ }
21176
21289
  },
21177
21290
  };
21178
21291
  class WwToDOMAdaptor {
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * @licium/editor : viewer
3
- * @version 3.2.6 | Sat Jan 03 2026
3
+ * @version 3.2.8 | Tue Jan 06 2026
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -11582,6 +11582,7 @@ function getChildrenHTML(node, typeName) {
11582
11582
  function getHTMLAttrsByHTMLString(html) {
11583
11583
  html = html.match(reHTMLTag)[0];
11584
11584
  const attrs = html.match(new RegExp(ATTRIBUTE, 'g'));
11585
+ // prettier-ignore
11585
11586
  return attrs
11586
11587
  ? attrs.reduce((acc, attr) => {
11587
11588
  const [name, ...values] = attr.trim().split('=');
package/dist/i18n/ar.js CHANGED
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * TOAST UI Editor : i18n
3
- * @version 3.2.6
3
+ * @version 3.2.8
4
4
  * @author NHN Cloud FE Development Lab <dl_javascript@nhn.com>
5
5
  * @license MIT
6
6
  */