quoin-editor 2.0.4 → 2.1.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 (215) hide show
  1. package/CHANGELOG.md +110 -0
  2. package/MIGRATION.md +1 -1
  3. package/README.md +14 -13
  4. package/dist/ai.cjs +124 -94
  5. package/dist/ai.d.cts +7 -0
  6. package/dist/ai.d.ts +7 -0
  7. package/dist/ai.js +50 -20
  8. package/dist/ai.js.map +1 -1
  9. package/dist/catalogue.cjs +28 -26
  10. package/dist/catalogue.js +19 -17
  11. package/dist/catalogue.js.map +1 -1
  12. package/dist/{chunk-JGEDJYIV.cjs → chunk-2FUWXPPC.cjs} +92 -98
  13. package/dist/{chunk-NHNW5DK3.js → chunk-3F76QQ65.js} +6 -6
  14. package/dist/{chunk-NHNW5DK3.js.map → chunk-3F76QQ65.js.map} +1 -1
  15. package/dist/{chunk-DBOZFNWU.js → chunk-3QYFAAQR.js} +3 -3
  16. package/dist/{chunk-DBOZFNWU.js.map → chunk-3QYFAAQR.js.map} +1 -1
  17. package/dist/{chunk-I7X7B3WD.cjs → chunk-4JDRDPLC.cjs} +17 -8
  18. package/dist/{chunk-EBSDPHPS.cjs → chunk-4UFWFV43.cjs} +1060 -719
  19. package/dist/{chunk-LM3DHROX.cjs → chunk-5AUIA4B3.cjs} +2 -2
  20. package/dist/{chunk-3INFNIGN.cjs → chunk-5H3BB5VJ.cjs} +131 -78
  21. package/dist/{chunk-DJU25PFC.cjs → chunk-5L2NSIHZ.cjs} +11 -11
  22. package/dist/{chunk-W376L2GM.js → chunk-6Y7JAWYY.js} +8 -8
  23. package/dist/chunk-6Y7JAWYY.js.map +1 -0
  24. package/dist/{chunk-UDBLZILE.js → chunk-ATKDXQEY.js} +12 -7
  25. package/dist/{chunk-UDBLZILE.js.map → chunk-ATKDXQEY.js.map} +1 -1
  26. package/dist/{chunk-A2IQHMIH.js → chunk-BE2SYPK5.js} +49 -54
  27. package/dist/chunk-BE2SYPK5.js.map +1 -0
  28. package/dist/{chunk-PURYVDC3.cjs → chunk-CFICD2JP.cjs} +21 -16
  29. package/dist/{chunk-3HW3WRYC.cjs → chunk-CSIUXYRU.cjs} +2 -2
  30. package/dist/{chunk-N7BSFDDM.cjs → chunk-DBKL524I.cjs} +23 -23
  31. package/dist/{chunk-XE3IYW5B.js → chunk-DEFYFIWW.js} +90 -37
  32. package/dist/chunk-DEFYFIWW.js.map +1 -0
  33. package/dist/{chunk-7E43TURF.cjs → chunk-ECI3PSMS.cjs} +7 -7
  34. package/dist/{chunk-4G645EYO.js → chunk-F73QEF7E.js} +5 -5
  35. package/dist/{chunk-4G645EYO.js.map → chunk-F73QEF7E.js.map} +1 -1
  36. package/dist/{chunk-KHRVCTQQ.cjs → chunk-FUT7XLMP.cjs} +61 -74
  37. package/dist/{chunk-7J63427U.cjs → chunk-GQSBOBOM.cjs} +375 -320
  38. package/dist/{chunk-LU3T3JB4.js → chunk-HPNSQWRD.js} +15 -28
  39. package/dist/chunk-HPNSQWRD.js.map +1 -0
  40. package/dist/{chunk-7Y4B7NHO.js → chunk-I34BFOLL.js} +18 -11
  41. package/dist/chunk-I34BFOLL.js.map +1 -0
  42. package/dist/{chunk-AJT54OMZ.js → chunk-IFRXEFQH.js} +9 -15
  43. package/dist/chunk-IFRXEFQH.js.map +1 -0
  44. package/dist/{chunk-YYW33WUL.cjs → chunk-K3XWVRL4.cjs} +8 -8
  45. package/dist/{chunk-LSI4RMTY.js → chunk-L5L6YNLT.js} +3 -3
  46. package/dist/{chunk-LSI4RMTY.js.map → chunk-L5L6YNLT.js.map} +1 -1
  47. package/dist/{chunk-2BPXVQBP.js → chunk-MO4UMXMT.js} +238 -86
  48. package/dist/chunk-MO4UMXMT.js.map +1 -0
  49. package/dist/{chunk-2QKFRKOP.cjs → chunk-N25EH2GZ.cjs} +351 -205
  50. package/dist/{chunk-CSPCDVCT.js → chunk-NCV2ML25.js} +3 -3
  51. package/dist/{chunk-CSPCDVCT.js.map → chunk-NCV2ML25.js.map} +1 -1
  52. package/dist/{chunk-NUQ64S5B.cjs → chunk-OJSKSQTL.cjs} +26 -26
  53. package/dist/chunk-PIWMU4BV.js +9 -0
  54. package/dist/chunk-PIWMU4BV.js.map +1 -0
  55. package/dist/chunk-QFGWSFOI.cjs +10 -0
  56. package/dist/{chunk-GPTJYWGS.js → chunk-RNBLVGWY.js} +3 -3
  57. package/dist/{chunk-GPTJYWGS.js.map → chunk-RNBLVGWY.js.map} +1 -1
  58. package/dist/{chunk-5RBMZGKV.js → chunk-TL2MJOWM.js} +325 -57
  59. package/dist/chunk-TL2MJOWM.js.map +1 -0
  60. package/dist/{chunk-YEDPBYO5.cjs → chunk-UDQ52EEC.cjs} +4 -4
  61. package/dist/{chunk-EIWPJWY3.js → chunk-UE2NQPNG.js} +5 -5
  62. package/dist/{chunk-EIWPJWY3.js.map → chunk-UE2NQPNG.js.map} +1 -1
  63. package/dist/{chunk-BE2YHZXA.cjs → chunk-ULV3SCYP.cjs} +26 -15
  64. package/dist/{chunk-WDBFGX3U.cjs → chunk-VTTMJGWP.cjs} +72 -77
  65. package/dist/{chunk-556PFYES.js → chunk-WK4UGDZN.js} +290 -235
  66. package/dist/chunk-WK4UGDZN.js.map +1 -0
  67. package/dist/{chunk-JZF6UQH5.cjs → chunk-WMKA37NJ.cjs} +12 -12
  68. package/dist/{chunk-F2ZK6Z52.js → chunk-Y26F2X4E.js} +3 -3
  69. package/dist/{chunk-F2ZK6Z52.js.map → chunk-Y26F2X4E.js.map} +1 -1
  70. package/dist/{chunk-FK7EBZPX.cjs → chunk-Z5EEDCRI.cjs} +549 -276
  71. package/dist/{chunk-G6NBQYMM.js → chunk-ZGFZRVQA.js} +817 -478
  72. package/dist/chunk-ZGFZRVQA.js.map +1 -0
  73. package/dist/{chunk-QLVX7MPS.js → chunk-ZQF45LA4.js} +19 -8
  74. package/dist/chunk-ZQF45LA4.js.map +1 -0
  75. package/dist/comments.cjs +127 -65
  76. package/dist/comments.d.cts +35 -2
  77. package/dist/comments.d.ts +35 -2
  78. package/dist/comments.js +73 -12
  79. package/dist/comments.js.map +1 -1
  80. package/dist/{diagram-extension-22x_njXB.d.ts → diagram-extension-BMlh8GCw.d.ts} +1 -1
  81. package/dist/{diagram-extension-C_FSkoj9.d.cts → diagram-extension-gmndUpti.d.cts} +1 -1
  82. package/dist/diagram.cjs +10 -9
  83. package/dist/diagram.d.cts +2 -2
  84. package/dist/diagram.d.ts +2 -2
  85. package/dist/diagram.js +7 -6
  86. package/dist/diff.cjs +25 -25
  87. package/dist/diff.js +3 -3
  88. package/dist/docx.cjs +31 -30
  89. package/dist/docx.js +5 -4
  90. package/dist/docx.js.map +1 -1
  91. package/dist/embed.cjs +10 -9
  92. package/dist/embed.js +8 -7
  93. package/dist/{emoji-extension-Dk5IQLZf.d.cts → emoji-extension-DD9CQTQj.d.cts} +1 -1
  94. package/dist/{emoji-extension-C832oGeT.d.ts → emoji-extension-U_PWZ2fX.d.ts} +1 -1
  95. package/dist/emoji.cjs +10 -9
  96. package/dist/emoji.d.cts +2 -2
  97. package/dist/emoji.d.ts +2 -2
  98. package/dist/emoji.js +7 -6
  99. package/dist/engine.cjs +58 -58
  100. package/dist/engine.d.cts +3 -3
  101. package/dist/engine.d.ts +3 -3
  102. package/dist/engine.js +3 -3
  103. package/dist/{find-extension-DmK9_N81.d.ts → find-extension-BGlqooZi.d.ts} +1 -1
  104. package/dist/{find-extension-BfruAPLi.d.cts → find-extension-BPnAJ8bY.d.cts} +1 -1
  105. package/dist/find.cjs +11 -10
  106. package/dist/find.d.cts +1 -1
  107. package/dist/find.d.ts +1 -1
  108. package/dist/find.js +7 -6
  109. package/dist/headless.cjs +70 -69
  110. package/dist/headless.d.cts +33 -10
  111. package/dist/headless.d.ts +33 -10
  112. package/dist/headless.js +5 -4
  113. package/dist/highlight.cjs +7 -6
  114. package/dist/highlight.js +6 -5
  115. package/dist/highlight.js.map +1 -1
  116. package/dist/{index-3fYvwqUZ.d.cts → index-DN7vRKFw.d.cts} +1 -1
  117. package/dist/{index-CgxnzCO5.d.ts → index-DyIYI3PM.d.ts} +1 -1
  118. package/dist/index.cjs +82 -81
  119. package/dist/index.d.cts +19 -12
  120. package/dist/index.d.ts +19 -12
  121. package/dist/index.js +6 -5
  122. package/dist/{labels-CiCxj2jP.d.cts → labels-BJORhN93.d.ts} +10 -5
  123. package/dist/{labels-BhRJYo46.d.ts → labels-CVYJ2-1X.d.cts} +10 -5
  124. package/dist/locale-ar.cjs +10 -0
  125. package/dist/locale-ar.d.cts +1 -1
  126. package/dist/locale-ar.d.ts +1 -1
  127. package/dist/locale-ar.js +10 -0
  128. package/dist/locale-ar.js.map +1 -1
  129. package/dist/locale-de.cjs +4 -0
  130. package/dist/locale-de.d.cts +1 -1
  131. package/dist/locale-de.d.ts +1 -1
  132. package/dist/locale-de.js +4 -0
  133. package/dist/locale-de.js.map +1 -1
  134. package/dist/locale-es.cjs +4 -0
  135. package/dist/locale-es.d.cts +1 -1
  136. package/dist/locale-es.d.ts +1 -1
  137. package/dist/locale-es.js +4 -0
  138. package/dist/locale-es.js.map +1 -1
  139. package/dist/locale-fr.cjs +4 -0
  140. package/dist/locale-fr.d.cts +1 -1
  141. package/dist/locale-fr.d.ts +1 -1
  142. package/dist/locale-fr.js +4 -0
  143. package/dist/locale-fr.js.map +1 -1
  144. package/dist/locale-ja.cjs +4 -0
  145. package/dist/locale-ja.d.cts +1 -1
  146. package/dist/locale-ja.d.ts +1 -1
  147. package/dist/locale-ja.js +4 -0
  148. package/dist/locale-ja.js.map +1 -1
  149. package/dist/locale-pt.cjs +4 -0
  150. package/dist/locale-pt.d.cts +1 -1
  151. package/dist/locale-pt.d.ts +1 -1
  152. package/dist/locale-pt.js +4 -0
  153. package/dist/locale-pt.js.map +1 -1
  154. package/dist/locale-zh.cjs +4 -0
  155. package/dist/locale-zh.d.cts +1 -1
  156. package/dist/locale-zh.d.ts +1 -1
  157. package/dist/locale-zh.js +4 -0
  158. package/dist/locale-zh.js.map +1 -1
  159. package/dist/math.cjs +11 -10
  160. package/dist/math.js +9 -8
  161. package/dist/mention.cjs +11 -10
  162. package/dist/mention.js +9 -8
  163. package/dist/{node-reveal-DY6bimv3.d.cts → node-reveal-Be7Xa0BL.d.cts} +1 -1
  164. package/dist/{node-reveal-BnFcnHhz.d.ts → node-reveal-CftIEqF_.d.ts} +1 -1
  165. package/dist/palette-DuIFHYHc.d.cts +10 -0
  166. package/dist/palette-DuIFHYHc.d.ts +10 -0
  167. package/dist/presence.cjs +39 -38
  168. package/dist/presence.js +8 -7
  169. package/dist/presence.js.map +1 -1
  170. package/dist/source.cjs +10 -9
  171. package/dist/source.d.cts +1 -1
  172. package/dist/source.d.ts +1 -1
  173. package/dist/source.js +6 -5
  174. package/dist/source.js.map +1 -1
  175. package/dist/{stats-extension-Dmw0Ujxe.d.ts → stats-extension-Bbpr593p.d.ts} +1 -1
  176. package/dist/{stats-extension-D5HySF0a.d.cts → stats-extension-D7FaeydW.d.cts} +1 -1
  177. package/dist/stats.cjs +12 -10
  178. package/dist/stats.d.cts +2 -2
  179. package/dist/stats.d.ts +2 -2
  180. package/dist/stats.js +9 -7
  181. package/dist/styles.css +1 -1
  182. package/dist/{table-extension-7LkLNK6Q.d.cts → table-extension-DNijjmxV.d.cts} +1 -1
  183. package/dist/{table-extension-DEpV0DnP.d.ts → table-extension-Dp6FYGPh.d.ts} +1 -1
  184. package/dist/table.cjs +26 -25
  185. package/dist/table.d.cts +4 -3
  186. package/dist/table.d.ts +4 -3
  187. package/dist/table.js +7 -6
  188. package/dist/{toc-extension-Dvh37bWQ.d.cts → toc-extension-BGEVAmSY.d.cts} +1 -1
  189. package/dist/{toc-extension-SVckrFmb.d.ts → toc-extension-DZIe40eV.d.ts} +1 -1
  190. package/dist/toc.cjs +10 -9
  191. package/dist/toc.d.cts +2 -2
  192. package/dist/toc.d.ts +2 -2
  193. package/dist/toc.js +7 -6
  194. package/dist/{types-DMuuDBVh.d.ts → types-Byu2a9qk.d.ts} +6 -1
  195. package/dist/{types-Bzhq5AXj.d.cts → types-DdDlCyyZ.d.cts} +6 -1
  196. package/dist/view.cjs +4 -4
  197. package/dist/view.js +2 -2
  198. package/dist/yjs.cjs +121 -121
  199. package/dist/yjs.d.cts +2 -2
  200. package/dist/yjs.d.ts +2 -2
  201. package/dist/yjs.js +5 -5
  202. package/package.json +4 -3
  203. package/dist/chunk-2BPXVQBP.js.map +0 -1
  204. package/dist/chunk-556PFYES.js.map +0 -1
  205. package/dist/chunk-5RBMZGKV.js.map +0 -1
  206. package/dist/chunk-7Y4B7NHO.js.map +0 -1
  207. package/dist/chunk-A2IQHMIH.js.map +0 -1
  208. package/dist/chunk-AJT54OMZ.js.map +0 -1
  209. package/dist/chunk-G6NBQYMM.js.map +0 -1
  210. package/dist/chunk-LU3T3JB4.js.map +0 -1
  211. package/dist/chunk-QLVX7MPS.js.map +0 -1
  212. package/dist/chunk-W376L2GM.js.map +0 -1
  213. package/dist/chunk-XE3IYW5B.js.map +0 -1
  214. package/dist/palette-BrX-hEd-.d.cts +0 -4
  215. package/dist/palette-BrX-hEd-.d.ts +0 -4
package/dist/index.cjs CHANGED
@@ -1,99 +1,100 @@
1
1
  'use client';
2
2
  'use strict';
3
3
 
4
- var chunkEBSDPHPS_cjs = require('./chunk-EBSDPHPS.cjs');
5
- var chunk2QKFRKOP_cjs = require('./chunk-2QKFRKOP.cjs');
4
+ var chunk4UFWFV43_cjs = require('./chunk-4UFWFV43.cjs');
5
+ var chunkN25EH2GZ_cjs = require('./chunk-N25EH2GZ.cjs');
6
6
  require('./chunk-ZWTIRGY5.cjs');
7
7
  var chunkA6PGQVTR_cjs = require('./chunk-A6PGQVTR.cjs');
8
- var chunkFK7EBZPX_cjs = require('./chunk-FK7EBZPX.cjs');
9
- var chunkDJU25PFC_cjs = require('./chunk-DJU25PFC.cjs');
10
- var chunkI7X7B3WD_cjs = require('./chunk-I7X7B3WD.cjs');
8
+ require('./chunk-QFGWSFOI.cjs');
9
+ var chunkZ5EEDCRI_cjs = require('./chunk-Z5EEDCRI.cjs');
10
+ var chunk5L2NSIHZ_cjs = require('./chunk-5L2NSIHZ.cjs');
11
+ var chunk4JDRDPLC_cjs = require('./chunk-4JDRDPLC.cjs');
11
12
 
12
13
 
13
14
 
14
15
  Object.defineProperty(exports, "BlockCanvas", {
15
16
  enumerable: true,
16
- get: function () { return chunkEBSDPHPS_cjs.BlockCanvas; }
17
+ get: function () { return chunk4UFWFV43_cjs.BlockCanvas; }
17
18
  });
18
19
  Object.defineProperty(exports, "FilePickerButton", {
19
20
  enumerable: true,
20
- get: function () { return chunkEBSDPHPS_cjs.FilePickerButton; }
21
+ get: function () { return chunk4UFWFV43_cjs.FilePickerButton; }
21
22
  });
22
23
  Object.defineProperty(exports, "QuoinProvider", {
23
24
  enumerable: true,
24
- get: function () { return chunkEBSDPHPS_cjs.QuoinProvider; }
25
+ get: function () { return chunk4UFWFV43_cjs.QuoinProvider; }
25
26
  });
26
27
  Object.defineProperty(exports, "UploadField", {
27
28
  enumerable: true,
28
- get: function () { return chunkEBSDPHPS_cjs.UploadField; }
29
+ get: function () { return chunk4UFWFV43_cjs.UploadField; }
29
30
  });
30
31
  Object.defineProperty(exports, "coreBlocks", {
31
32
  enumerable: true,
32
- get: function () { return chunkEBSDPHPS_cjs.coreBlocks; }
33
+ get: function () { return chunk4UFWFV43_cjs.coreBlocks; }
33
34
  });
34
35
  Object.defineProperty(exports, "englishLabels", {
35
36
  enumerable: true,
36
- get: function () { return chunkEBSDPHPS_cjs.englishLabels; }
37
+ get: function () { return chunk4UFWFV43_cjs.englishLabels; }
37
38
  });
38
39
  Object.defineProperty(exports, "formatShortcut", {
39
40
  enumerable: true,
40
- get: function () { return chunkEBSDPHPS_cjs.formatShortcut; }
41
+ get: function () { return chunk4UFWFV43_cjs.formatShortcut; }
41
42
  });
42
43
  Object.defineProperty(exports, "resolveLabels", {
43
44
  enumerable: true,
44
- get: function () { return chunkEBSDPHPS_cjs.resolveLabels; }
45
+ get: function () { return chunk4UFWFV43_cjs.resolveLabels; }
45
46
  });
46
47
  Object.defineProperty(exports, "useAutosave", {
47
48
  enumerable: true,
48
- get: function () { return chunkEBSDPHPS_cjs.useAutosave; }
49
+ get: function () { return chunk4UFWFV43_cjs.useAutosave; }
49
50
  });
50
51
  Object.defineProperty(exports, "useLabels", {
51
52
  enumerable: true,
52
- get: function () { return chunkEBSDPHPS_cjs.useLabels; }
53
+ get: function () { return chunk4UFWFV43_cjs.useLabels; }
53
54
  });
54
55
  Object.defineProperty(exports, "useQuoin", {
55
56
  enumerable: true,
56
- get: function () { return chunkEBSDPHPS_cjs.useQuoin; }
57
+ get: function () { return chunk4UFWFV43_cjs.useQuoin; }
57
58
  });
58
59
  Object.defineProperty(exports, "EditableRegion", {
59
60
  enumerable: true,
60
- get: function () { return chunk2QKFRKOP_cjs.EditableRegion; }
61
+ get: function () { return chunkN25EH2GZ_cjs.EditableRegion; }
61
62
  });
62
63
  Object.defineProperty(exports, "EditorView", {
63
64
  enumerable: true,
64
- get: function () { return chunk2QKFRKOP_cjs.EditorView; }
65
+ get: function () { return chunkN25EH2GZ_cjs.EditorView; }
65
66
  });
66
67
  Object.defineProperty(exports, "ViewController", {
67
68
  enumerable: true,
68
- get: function () { return chunk2QKFRKOP_cjs.ViewController; }
69
+ get: function () { return chunkN25EH2GZ_cjs.ViewController; }
69
70
  });
70
71
  Object.defineProperty(exports, "caretFromPoint", {
71
72
  enumerable: true,
72
- get: function () { return chunk2QKFRKOP_cjs.caretFromPoint; }
73
+ get: function () { return chunkN25EH2GZ_cjs.caretFromPoint; }
73
74
  });
74
75
  Object.defineProperty(exports, "domMapOf", {
75
76
  enumerable: true,
76
- get: function () { return chunk2QKFRKOP_cjs.domMapOf; }
77
+ get: function () { return chunkN25EH2GZ_cjs.domMapOf; }
77
78
  });
78
79
  Object.defineProperty(exports, "hostKey", {
79
80
  enumerable: true,
80
- get: function () { return chunk2QKFRKOP_cjs.hostKey; }
81
+ get: function () { return chunkN25EH2GZ_cjs.hostKey; }
81
82
  });
82
83
  Object.defineProperty(exports, "renderInline", {
83
84
  enumerable: true,
84
- get: function () { return chunk2QKFRKOP_cjs.renderInline; }
85
+ get: function () { return chunkN25EH2GZ_cjs.renderInline; }
85
86
  });
86
87
  Object.defineProperty(exports, "useEditorState", {
87
88
  enumerable: true,
88
- get: function () { return chunk2QKFRKOP_cjs.useEditorState; }
89
+ get: function () { return chunkN25EH2GZ_cjs.useEditorState; }
89
90
  });
90
91
  Object.defineProperty(exports, "useQuoinEditor", {
91
92
  enumerable: true,
92
- get: function () { return chunk2QKFRKOP_cjs.useQuoinEditor; }
93
+ get: function () { return chunkN25EH2GZ_cjs.useQuoinEditor; }
93
94
  });
94
95
  Object.defineProperty(exports, "useViewController", {
95
96
  enumerable: true,
96
- get: function () { return chunk2QKFRKOP_cjs.useViewController; }
97
+ get: function () { return chunkN25EH2GZ_cjs.useViewController; }
97
98
  });
98
99
  Object.defineProperty(exports, "blockByType", {
99
100
  enumerable: true,
@@ -109,221 +110,221 @@ Object.defineProperty(exports, "paletteBlocks", {
109
110
  });
110
111
  Object.defineProperty(exports, "Transaction", {
111
112
  enumerable: true,
112
- get: function () { return chunkFK7EBZPX_cjs.Transaction; }
113
+ get: function () { return chunkZ5EEDCRI_cjs.Transaction; }
113
114
  });
114
115
  Object.defineProperty(exports, "addMarkStep", {
115
116
  enumerable: true,
116
- get: function () { return chunkFK7EBZPX_cjs.addMarkStep; }
117
+ get: function () { return chunkZ5EEDCRI_cjs.addMarkStep; }
117
118
  });
118
119
  Object.defineProperty(exports, "applyTransaction", {
119
120
  enumerable: true,
120
- get: function () { return chunkFK7EBZPX_cjs.applyTransaction; }
121
+ get: function () { return chunkZ5EEDCRI_cjs.applyTransaction; }
121
122
  });
122
123
  Object.defineProperty(exports, "blockInputRules", {
123
124
  enumerable: true,
124
- get: function () { return chunkFK7EBZPX_cjs.blockInputRules; }
125
+ get: function () { return chunkZ5EEDCRI_cjs.blockInputRules; }
125
126
  });
126
127
  Object.defineProperty(exports, "blockRangeSelection", {
127
128
  enumerable: true,
128
- get: function () { return chunkFK7EBZPX_cjs.blockRangeSelection; }
129
+ get: function () { return chunkZ5EEDCRI_cjs.blockRangeSelection; }
129
130
  });
130
131
  Object.defineProperty(exports, "coreExtensions", {
131
132
  enumerable: true,
132
- get: function () { return chunkFK7EBZPX_cjs.coreExtensions; }
133
+ get: function () { return chunkZ5EEDCRI_cjs.coreExtensions; }
133
134
  });
134
135
  Object.defineProperty(exports, "countDoc", {
135
136
  enumerable: true,
136
- get: function () { return chunkFK7EBZPX_cjs.countDoc; }
137
+ get: function () { return chunkZ5EEDCRI_cjs.countDoc; }
137
138
  });
138
139
  Object.defineProperty(exports, "countText", {
139
140
  enumerable: true,
140
- get: function () { return chunkFK7EBZPX_cjs.countText; }
141
+ get: function () { return chunkZ5EEDCRI_cjs.countText; }
141
142
  });
142
143
  Object.defineProperty(exports, "createEditor", {
143
144
  enumerable: true,
144
- get: function () { return chunkFK7EBZPX_cjs.createEditor; }
145
+ get: function () { return chunkZ5EEDCRI_cjs.createEditor; }
145
146
  });
146
147
  Object.defineProperty(exports, "createPluginKey", {
147
148
  enumerable: true,
148
- get: function () { return chunkFK7EBZPX_cjs.createPluginKey; }
149
+ get: function () { return chunkZ5EEDCRI_cjs.createPluginKey; }
149
150
  });
150
151
  Object.defineProperty(exports, "createState", {
151
152
  enumerable: true,
152
- get: function () { return chunkFK7EBZPX_cjs.createState; }
153
+ get: function () { return chunkZ5EEDCRI_cjs.createState; }
153
154
  });
154
155
  Object.defineProperty(exports, "defineExtension", {
155
156
  enumerable: true,
156
- get: function () { return chunkFK7EBZPX_cjs.defineExtension; }
157
+ get: function () { return chunkZ5EEDCRI_cjs.defineExtension; }
157
158
  });
158
159
  Object.defineProperty(exports, "fromHTML", {
159
160
  enumerable: true,
160
- get: function () { return chunkFK7EBZPX_cjs.fromHTML; }
161
+ get: function () { return chunkZ5EEDCRI_cjs.fromHTML; }
161
162
  });
162
163
  Object.defineProperty(exports, "getPluginState", {
163
164
  enumerable: true,
164
- get: function () { return chunkFK7EBZPX_cjs.getPluginState; }
165
+ get: function () { return chunkZ5EEDCRI_cjs.getPluginState; }
165
166
  });
166
167
  Object.defineProperty(exports, "insertBlockAfter", {
167
168
  enumerable: true,
168
- get: function () { return chunkFK7EBZPX_cjs.insertBlockAfter; }
169
+ get: function () { return chunkZ5EEDCRI_cjs.insertBlockAfter; }
169
170
  });
170
171
  Object.defineProperty(exports, "insertBlocksStep", {
171
172
  enumerable: true,
172
- get: function () { return chunkFK7EBZPX_cjs.insertBlocksStep; }
173
+ get: function () { return chunkZ5EEDCRI_cjs.insertBlocksStep; }
173
174
  });
174
175
  Object.defineProperty(exports, "insertText", {
175
176
  enumerable: true,
176
- get: function () { return chunkFK7EBZPX_cjs.insertText; }
177
+ get: function () { return chunkZ5EEDCRI_cjs.insertText; }
177
178
  });
178
179
  Object.defineProperty(exports, "insertTextWithRules", {
179
180
  enumerable: true,
180
- get: function () { return chunkFK7EBZPX_cjs.insertTextWithRules; }
181
+ get: function () { return chunkZ5EEDCRI_cjs.insertTextWithRules; }
181
182
  });
182
183
  Object.defineProperty(exports, "joinBlocksStep", {
183
184
  enumerable: true,
184
- get: function () { return chunkFK7EBZPX_cjs.joinBlocksStep; }
185
+ get: function () { return chunkZ5EEDCRI_cjs.joinBlocksStep; }
185
186
  });
186
187
  Object.defineProperty(exports, "keyName", {
187
188
  enumerable: true,
188
- get: function () { return chunkFK7EBZPX_cjs.keyName; }
189
+ get: function () { return chunkZ5EEDCRI_cjs.keyName; }
189
190
  });
190
191
  Object.defineProperty(exports, "markInputRules", {
191
192
  enumerable: true,
192
- get: function () { return chunkFK7EBZPX_cjs.markInputRules; }
193
+ get: function () { return chunkZ5EEDCRI_cjs.markInputRules; }
193
194
  });
194
195
  Object.defineProperty(exports, "moveBlocksStep", {
195
196
  enumerable: true,
196
- get: function () { return chunkFK7EBZPX_cjs.moveBlocksStep; }
197
+ get: function () { return chunkZ5EEDCRI_cjs.moveBlocksStep; }
197
198
  });
198
199
  Object.defineProperty(exports, "nodeSelection", {
199
200
  enumerable: true,
200
- get: function () { return chunkFK7EBZPX_cjs.nodeSelection; }
201
+ get: function () { return chunkZ5EEDCRI_cjs.nodeSelection; }
201
202
  });
202
203
  Object.defineProperty(exports, "normalizeKey", {
203
204
  enumerable: true,
204
- get: function () { return chunkFK7EBZPX_cjs.normalizeKey; }
205
+ get: function () { return chunkZ5EEDCRI_cjs.normalizeKey; }
205
206
  });
206
207
  Object.defineProperty(exports, "redo", {
207
208
  enumerable: true,
208
- get: function () { return chunkFK7EBZPX_cjs.redo; }
209
+ get: function () { return chunkZ5EEDCRI_cjs.redo; }
209
210
  });
210
211
  Object.defineProperty(exports, "removeBlocksStep", {
211
212
  enumerable: true,
212
- get: function () { return chunkFK7EBZPX_cjs.removeBlocksStep; }
213
+ get: function () { return chunkZ5EEDCRI_cjs.removeBlocksStep; }
213
214
  });
214
215
  Object.defineProperty(exports, "removeMarkStep", {
215
216
  enumerable: true,
216
- get: function () { return chunkFK7EBZPX_cjs.removeMarkStep; }
217
+ get: function () { return chunkZ5EEDCRI_cjs.removeMarkStep; }
217
218
  });
218
219
  Object.defineProperty(exports, "replaceBlockStep", {
219
220
  enumerable: true,
220
- get: function () { return chunkFK7EBZPX_cjs.replaceBlockStep; }
221
+ get: function () { return chunkZ5EEDCRI_cjs.replaceBlockStep; }
221
222
  });
222
223
  Object.defineProperty(exports, "replaceDocStep", {
223
224
  enumerable: true,
224
- get: function () { return chunkFK7EBZPX_cjs.replaceDocStep; }
225
+ get: function () { return chunkZ5EEDCRI_cjs.replaceDocStep; }
225
226
  });
226
227
  Object.defineProperty(exports, "replaceInlineStep", {
227
228
  enumerable: true,
228
- get: function () { return chunkFK7EBZPX_cjs.replaceInlineStep; }
229
+ get: function () { return chunkZ5EEDCRI_cjs.replaceInlineStep; }
229
230
  });
230
231
  Object.defineProperty(exports, "setAttrsStep", {
231
232
  enumerable: true,
232
- get: function () { return chunkFK7EBZPX_cjs.setAttrsStep; }
233
+ get: function () { return chunkZ5EEDCRI_cjs.setAttrsStep; }
233
234
  });
234
235
  Object.defineProperty(exports, "setBlockType", {
235
236
  enumerable: true,
236
- get: function () { return chunkFK7EBZPX_cjs.setBlockType; }
237
+ get: function () { return chunkZ5EEDCRI_cjs.setBlockType; }
237
238
  });
238
239
  Object.defineProperty(exports, "setIndentStep", {
239
240
  enumerable: true,
240
- get: function () { return chunkFK7EBZPX_cjs.setIndentStep; }
241
+ get: function () { return chunkZ5EEDCRI_cjs.setIndentStep; }
241
242
  });
242
243
  Object.defineProperty(exports, "splitBlockStep", {
243
244
  enumerable: true,
244
- get: function () { return chunkFK7EBZPX_cjs.splitBlockStep; }
245
+ get: function () { return chunkZ5EEDCRI_cjs.splitBlockStep; }
245
246
  });
246
247
  Object.defineProperty(exports, "stepFromJSON", {
247
248
  enumerable: true,
248
- get: function () { return chunkFK7EBZPX_cjs.stepFromJSON; }
249
+ get: function () { return chunkZ5EEDCRI_cjs.stepFromJSON; }
249
250
  });
250
251
  Object.defineProperty(exports, "textSelection", {
251
252
  enumerable: true,
252
- get: function () { return chunkFK7EBZPX_cjs.textSelection; }
253
+ get: function () { return chunkZ5EEDCRI_cjs.textSelection; }
253
254
  });
254
255
  Object.defineProperty(exports, "toHTML", {
255
256
  enumerable: true,
256
- get: function () { return chunkFK7EBZPX_cjs.toHTML; }
257
+ get: function () { return chunkZ5EEDCRI_cjs.toHTML; }
257
258
  });
258
259
  Object.defineProperty(exports, "toMarkdown", {
259
260
  enumerable: true,
260
- get: function () { return chunkFK7EBZPX_cjs.toMarkdown; }
261
+ get: function () { return chunkZ5EEDCRI_cjs.toMarkdown; }
261
262
  });
262
263
  Object.defineProperty(exports, "toPlainText", {
263
264
  enumerable: true,
264
- get: function () { return chunkFK7EBZPX_cjs.toPlainText; }
265
+ get: function () { return chunkZ5EEDCRI_cjs.toPlainText; }
265
266
  });
266
267
  Object.defineProperty(exports, "toggleMark", {
267
268
  enumerable: true,
268
- get: function () { return chunkFK7EBZPX_cjs.toggleMark; }
269
+ get: function () { return chunkZ5EEDCRI_cjs.toggleMark; }
269
270
  });
270
271
  Object.defineProperty(exports, "typographyRules", {
271
272
  enumerable: true,
272
- get: function () { return chunkFK7EBZPX_cjs.typographyRules; }
273
+ get: function () { return chunkZ5EEDCRI_cjs.typographyRules; }
273
274
  });
274
275
  Object.defineProperty(exports, "undo", {
275
276
  enumerable: true,
276
- get: function () { return chunkFK7EBZPX_cjs.undo; }
277
+ get: function () { return chunkZ5EEDCRI_cjs.undo; }
277
278
  });
278
279
  Object.defineProperty(exports, "diffBlocks", {
279
280
  enumerable: true,
280
- get: function () { return chunkDJU25PFC_cjs.diffBlocks; }
281
+ get: function () { return chunk5L2NSIHZ_cjs.diffBlocks; }
281
282
  });
282
283
  Object.defineProperty(exports, "diffInline", {
283
284
  enumerable: true,
284
- get: function () { return chunkDJU25PFC_cjs.diffInline; }
285
+ get: function () { return chunk5L2NSIHZ_cjs.diffInline; }
285
286
  });
286
287
  Object.defineProperty(exports, "PALETTE", {
287
288
  enumerable: true,
288
- get: function () { return chunkI7X7B3WD_cjs.PALETTE; }
289
+ get: function () { return chunk4JDRDPLC_cjs.PALETTE; }
289
290
  });
290
291
  Object.defineProperty(exports, "atom", {
291
292
  enumerable: true,
292
- get: function () { return chunkI7X7B3WD_cjs.atom; }
293
+ get: function () { return chunk4JDRDPLC_cjs.atom; }
293
294
  });
294
295
  Object.defineProperty(exports, "coreBlockSpecs", {
295
296
  enumerable: true,
296
- get: function () { return chunkI7X7B3WD_cjs.coreBlockSpecs; }
297
+ get: function () { return chunk4JDRDPLC_cjs.coreBlockSpecs; }
297
298
  });
298
299
  Object.defineProperty(exports, "createBlockCodec", {
299
300
  enumerable: true,
300
- get: function () { return chunkI7X7B3WD_cjs.createBlockCodec; }
301
+ get: function () { return chunk4JDRDPLC_cjs.createBlockCodec; }
301
302
  });
302
303
  Object.defineProperty(exports, "createSchema", {
303
304
  enumerable: true,
304
- get: function () { return chunkI7X7B3WD_cjs.createSchema; }
305
+ get: function () { return chunk4JDRDPLC_cjs.createSchema; }
305
306
  });
306
307
  Object.defineProperty(exports, "fromMarkdown", {
307
308
  enumerable: true,
308
- get: function () { return chunkI7X7B3WD_cjs.fromMarkdown; }
309
+ get: function () { return chunk4JDRDPLC_cjs.fromMarkdown; }
309
310
  });
310
311
  Object.defineProperty(exports, "normalizeInline", {
311
312
  enumerable: true,
312
- get: function () { return chunkI7X7B3WD_cjs.normalizeInline; }
313
+ get: function () { return chunk4JDRDPLC_cjs.normalizeInline; }
313
314
  });
314
315
  Object.defineProperty(exports, "parseInline", {
315
316
  enumerable: true,
316
- get: function () { return chunkI7X7B3WD_cjs.parseInline; }
317
+ get: function () { return chunk4JDRDPLC_cjs.parseInline; }
317
318
  });
318
319
  Object.defineProperty(exports, "sanitizeHref", {
319
320
  enumerable: true,
320
- get: function () { return chunkI7X7B3WD_cjs.sanitizeHref; }
321
+ get: function () { return chunk4JDRDPLC_cjs.sanitizeHref; }
321
322
  });
322
323
  Object.defineProperty(exports, "serializeInline", {
323
324
  enumerable: true,
324
- get: function () { return chunkI7X7B3WD_cjs.serializeInline; }
325
+ get: function () { return chunk4JDRDPLC_cjs.serializeInline; }
325
326
  });
326
327
  Object.defineProperty(exports, "text", {
327
328
  enumerable: true,
328
- get: function () { return chunkI7X7B3WD_cjs.text; }
329
+ get: function () { return chunk4JDRDPLC_cjs.text; }
329
330
  });
package/dist/index.d.cts CHANGED
@@ -4,18 +4,18 @@ import { C as CodeHighlighter } from './code-highlighter-BQDxhRrv.cjs';
4
4
  export { a as CodeToken } from './code-highlighter-BQDxhRrv.cjs';
5
5
  import { Q as QuoinBlock, P as Pos } from './types-CQ8Vw_7N.cjs';
6
6
  export { d as Assoc, c as AtomNode, e as AtomSpec, A as Attrs, B as BlockAttrs, f as BlockContent, g as BlockFlow, h as BlockRangeSelection, i as BlockSpec, C as CodecContext, j as CreatedBlock, k as EngineBlock, E as EngineDoc, I as Inline, l as InlineCodec, m as InlineNode, M as Mark, n as MarkSpec, o as MarkdownExportContext, N as NodeSelection, p as ParseInlineOptions, q as PosMap, S as Schema, b as Selection, r as SerializeInlineOptions, a as Step, s as StepJSON, t as StepResult, T as TextNode, u as TextSelection } from './types-CQ8Vw_7N.cjs';
7
- import { E as Extension, a as Editor, c as EditorState, b as Command } from './types-Bzhq5AXj.cjs';
8
- export { A as Align, B as BlockStructureOptions, e as BoundCommands, f as Chain, C as CommandFactories, g as CoreCommands, h as CoreExtensionOptions, i as DOMParserLike, D as Decoration, j as EditorOptions, F as FromHTMLOptions, I as InputRule, k as InputRuleContext, l as InputRuleRange, m as InsertTextOptions, K as KeyLike, M as MarkdownOptions, n as PasteRule, P as PluginKey, d as PluginSpec, S as Slice, o as TextStats, T as Transaction, p as TransactionOrigin, q as applyTransaction, r as coreExtensions, s as createEditor, t as createPluginKey, u as createState, v as fromHTML, w as getPluginState, x as insertBlockAfter, y as insertText, z as insertTextWithRules, G as keyName, H as normalizeKey, J as setBlockType, L as toggleMark } from './types-Bzhq5AXj.cjs';
9
- import { Q as QuoinLabels, S as SlashGroup } from './labels-CiCxj2jP.cjs';
7
+ import { E as Extension, a as Editor, c as EditorState, b as Command } from './types-DdDlCyyZ.cjs';
8
+ export { A as Align, B as BlockStructureOptions, e as BoundCommands, f as Chain, C as CommandFactories, g as CoreCommands, h as CoreExtensionOptions, i as DOMParserLike, D as Decoration, j as EditorOptions, F as FromHTMLOptions, I as InputRule, k as InputRuleContext, l as InputRuleRange, m as InsertTextOptions, K as KeyLike, M as MarkdownOptions, n as PasteRule, P as PluginKey, d as PluginSpec, S as Slice, o as TextStats, T as Transaction, p as TransactionOrigin, q as applyTransaction, r as coreExtensions, s as createEditor, t as createPluginKey, u as createState, v as fromHTML, w as getPluginState, x as insertBlockAfter, y as insertText, z as insertTextWithRules, G as keyName, H as normalizeKey, J as setBlockType, L as toggleMark } from './types-DdDlCyyZ.cjs';
9
+ import { Q as QuoinLabels, S as SlashGroup } from './labels-CVYJ2-1X.cjs';
10
10
  import { A as AnyBlockDefinition, U as UploadFn, a as UploadResult } from './registry-DZ8LIGt5.cjs';
11
11
  export { B as BlockDefinition, b as BlockEditorProps, c as BlockPreviewProps, e as blockByType, d as defineBlock, p as paletteBlocks } from './registry-DZ8LIGt5.cjs';
12
- import { V as ViewController, R as RenderOptions } from './node-reveal-DY6bimv3.cjs';
13
- export { A as Announcer, a as AtomRenderer, E as Engagement, F as FocusTarget, H as HostEntry, b as HostRegistry, K as KeyInterceptor, N as NodeReveal, S as Spoken, c as ViewControllerOptions, W as WidgetRenderer, h as hostKey } from './node-reveal-DY6bimv3.cjs';
12
+ import { V as ViewController, R as RenderOptions } from './node-reveal-Be7Xa0BL.cjs';
13
+ export { A as Announcer, a as AtomRenderer, E as Engagement, F as FocusTarget, H as HostEntry, b as HostRegistry, K as KeyInterceptor, N as NodeReveal, S as Spoken, c as ViewControllerOptions, W as WidgetRenderer, h as hostKey } from './node-reveal-Be7Xa0BL.cjs';
14
14
  import { BlockRenderer } from './headless.cjs';
15
- export { BlockLabel, BlockPlaceholder, BlockRenderProps, CaretPoint, DomMap, DomPoint, EditableRegion, EditableRegionProps, EditorView, EditorViewProps, UseQuoinEditorOptions, caretFromPoint, domMapOf, renderInline, useEditorState, useQuoinEditor, useViewController } from './headless.cjs';
15
+ export { BlockLabel, BlockPlaceholder, BlockRenderProps, CaretPoint, DomMap, DomPoint, EditableRegion, EditableRegionProps, EditorView, EditorViewProps, RendererLabels, UseQuoinEditorOptions, caretFromPoint, domMapOf, renderInline, useEditorState, useQuoinEditor, useViewController } from './headless.cjs';
16
16
  export { AttrsPatch, BlockChange, BlockCodec, BlockDiff, FromMarkdownOptions, InlineChange, SchemaInput, addMarkStep, atom, blockInputRules, blockRangeSelection, coreBlockSpecs, countDoc, countText, createBlockCodec, createSchema, defineExtension, diffBlocks, diffInline, fromMarkdown, insertBlocksStep, joinBlocksStep, markInputRules, moveBlocksStep, nodeSelection, normalizeInline, parseInline, redo, removeBlocksStep, removeMarkStep, replaceBlockStep, replaceDocStep, replaceInlineStep, sanitizeHref, serializeInline, setAttrsStep, setIndentStep, splitBlockStep, stepFromJSON, text, textSelection, toPlainText, typographyRules, undo } from './engine.cjs';
17
+ export { C as CalloutTone, a as PALETTE, P as PaletteName } from './palette-DuIFHYHc.cjs';
17
18
  export { T as ToMarkdownOptions, t as toMarkdown } from './to-markdown-C2w7Dzg8.cjs';
18
- export { P as PALETTE } from './palette-BrX-hEd-.cjs';
19
19
  export { E as EmbedProvider, a as EmbedUrl } from './embed-provider-jXwlRmnp.cjs';
20
20
  export { H as HTMLOptions, t as toHTML } from './to-html-C19PbIzh.cjs';
21
21
 
@@ -56,13 +56,16 @@ type BlockCanvasProps = {
56
56
  /** The text of an empty paragraph holding the caret, or alone in the document, in place of `labels.placeholderEmpty`. */
57
57
  placeholder?: string;
58
58
  /**
59
- * Every string the canvas shows or speaks, English by default. A key left out stays English. Keep the object stable,
60
- * hoisted or memoised: a new one each render re-renders everything that reads the canvas configuration.
59
+ * Every string the canvas shows or speaks, English by default. A key left out stays English. An object written inline
60
+ * that holds the same strings and functions as the last one, maps of names included, is taken as unchanged; a label
61
+ * function written inline is new on each render and re-renders everything that reads the canvas configuration, so
62
+ * hoist or memoise those.
61
63
  */
62
64
  labels?: Partial<QuoinLabels>;
63
65
  /**
64
66
  * The address the block menu's "Copy link to block" copies. By default the current page with `#block-<id>`, a fragment
65
- * the canvas follows on load and on hash changes to select the block and scroll it into view.
67
+ * the canvas follows on load and on hash changes to select the block and scroll it into view. Keep the function
68
+ * stable: a new one each render builds the block menu's actions again.
66
69
  */
67
70
  blockLink?: (blockId: string) => string;
68
71
  className?: string;
@@ -160,7 +163,10 @@ type UploadFieldProps = {
160
163
  /** Called once the upload resolves. The field stays busy until a returned promise settles, and throwing or rejecting is reported through the canvas `onError`. */
161
164
  onUploaded: (result: UploadResult) => void | Promise<void>;
162
165
  };
163
- /** A file picker wired to the canvas `upload` function, with its own busy state, success message and inline error. */
166
+ /**
167
+ * A file picker wired to the canvas `upload` function, with its own busy state, success message and inline error. The
168
+ * progress is announced through the live region of the canvas it is drawn in, or a live region of its own outside one.
169
+ */
164
170
  declare function UploadField({ category, label, accept, onUploaded }: UploadFieldProps): react.JSX.Element;
165
171
 
166
172
  /** Props for `FilePickerButton`. */
@@ -169,7 +175,7 @@ type FilePickerButtonProps = {
169
175
  label: string;
170
176
  /** An `accept` attribute for the file input, such as `'image/*'` or `'.pdf'`. */
171
177
  accept?: string;
172
- /** Greys the button out and disables the input behind it. After a pick, focus the browser dropped while it was disabled comes back once it is enabled again. */
178
+ /** Greys the button out and disables the input behind it. After a pick, focus the browser dropped while it was disabled comes back once it is enabled again, unless the user pressed elsewhere meanwhile. */
173
179
  disabled?: boolean;
174
180
  /** Greys the button out and refuses picks, as `disabled` does, but leaves the input focusable, so focus stays on it while an upload runs. */
175
181
  busy?: boolean;
@@ -230,6 +236,7 @@ type SuggestionRange = {
230
236
  from: number;
231
237
  to: number;
232
238
  };
239
+ /** A command of the slash menu, which needs a `command`, a `run` or both: the menu leaves out one with neither. */
233
240
  type SlashItem = {
234
241
  id: string;
235
242
  title: string;
package/dist/index.d.ts CHANGED
@@ -4,18 +4,18 @@ import { C as CodeHighlighter } from './code-highlighter-BQDxhRrv.js';
4
4
  export { a as CodeToken } from './code-highlighter-BQDxhRrv.js';
5
5
  import { Q as QuoinBlock, P as Pos } from './types-CQ8Vw_7N.js';
6
6
  export { d as Assoc, c as AtomNode, e as AtomSpec, A as Attrs, B as BlockAttrs, f as BlockContent, g as BlockFlow, h as BlockRangeSelection, i as BlockSpec, C as CodecContext, j as CreatedBlock, k as EngineBlock, E as EngineDoc, I as Inline, l as InlineCodec, m as InlineNode, M as Mark, n as MarkSpec, o as MarkdownExportContext, N as NodeSelection, p as ParseInlineOptions, q as PosMap, S as Schema, b as Selection, r as SerializeInlineOptions, a as Step, s as StepJSON, t as StepResult, T as TextNode, u as TextSelection } from './types-CQ8Vw_7N.js';
7
- import { E as Extension, a as Editor, c as EditorState, b as Command } from './types-DMuuDBVh.js';
8
- export { A as Align, B as BlockStructureOptions, e as BoundCommands, f as Chain, C as CommandFactories, g as CoreCommands, h as CoreExtensionOptions, i as DOMParserLike, D as Decoration, j as EditorOptions, F as FromHTMLOptions, I as InputRule, k as InputRuleContext, l as InputRuleRange, m as InsertTextOptions, K as KeyLike, M as MarkdownOptions, n as PasteRule, P as PluginKey, d as PluginSpec, S as Slice, o as TextStats, T as Transaction, p as TransactionOrigin, q as applyTransaction, r as coreExtensions, s as createEditor, t as createPluginKey, u as createState, v as fromHTML, w as getPluginState, x as insertBlockAfter, y as insertText, z as insertTextWithRules, G as keyName, H as normalizeKey, J as setBlockType, L as toggleMark } from './types-DMuuDBVh.js';
9
- import { Q as QuoinLabels, S as SlashGroup } from './labels-BhRJYo46.js';
7
+ import { E as Extension, a as Editor, c as EditorState, b as Command } from './types-Byu2a9qk.js';
8
+ export { A as Align, B as BlockStructureOptions, e as BoundCommands, f as Chain, C as CommandFactories, g as CoreCommands, h as CoreExtensionOptions, i as DOMParserLike, D as Decoration, j as EditorOptions, F as FromHTMLOptions, I as InputRule, k as InputRuleContext, l as InputRuleRange, m as InsertTextOptions, K as KeyLike, M as MarkdownOptions, n as PasteRule, P as PluginKey, d as PluginSpec, S as Slice, o as TextStats, T as Transaction, p as TransactionOrigin, q as applyTransaction, r as coreExtensions, s as createEditor, t as createPluginKey, u as createState, v as fromHTML, w as getPluginState, x as insertBlockAfter, y as insertText, z as insertTextWithRules, G as keyName, H as normalizeKey, J as setBlockType, L as toggleMark } from './types-Byu2a9qk.js';
9
+ import { Q as QuoinLabels, S as SlashGroup } from './labels-BJORhN93.js';
10
10
  import { A as AnyBlockDefinition, U as UploadFn, a as UploadResult } from './registry-DZ8LIGt5.js';
11
11
  export { B as BlockDefinition, b as BlockEditorProps, c as BlockPreviewProps, e as blockByType, d as defineBlock, p as paletteBlocks } from './registry-DZ8LIGt5.js';
12
- import { V as ViewController, R as RenderOptions } from './node-reveal-BnFcnHhz.js';
13
- export { A as Announcer, a as AtomRenderer, E as Engagement, F as FocusTarget, H as HostEntry, b as HostRegistry, K as KeyInterceptor, N as NodeReveal, S as Spoken, c as ViewControllerOptions, W as WidgetRenderer, h as hostKey } from './node-reveal-BnFcnHhz.js';
12
+ import { V as ViewController, R as RenderOptions } from './node-reveal-CftIEqF_.js';
13
+ export { A as Announcer, a as AtomRenderer, E as Engagement, F as FocusTarget, H as HostEntry, b as HostRegistry, K as KeyInterceptor, N as NodeReveal, S as Spoken, c as ViewControllerOptions, W as WidgetRenderer, h as hostKey } from './node-reveal-CftIEqF_.js';
14
14
  import { BlockRenderer } from './headless.js';
15
- export { BlockLabel, BlockPlaceholder, BlockRenderProps, CaretPoint, DomMap, DomPoint, EditableRegion, EditableRegionProps, EditorView, EditorViewProps, UseQuoinEditorOptions, caretFromPoint, domMapOf, renderInline, useEditorState, useQuoinEditor, useViewController } from './headless.js';
15
+ export { BlockLabel, BlockPlaceholder, BlockRenderProps, CaretPoint, DomMap, DomPoint, EditableRegion, EditableRegionProps, EditorView, EditorViewProps, RendererLabels, UseQuoinEditorOptions, caretFromPoint, domMapOf, renderInline, useEditorState, useQuoinEditor, useViewController } from './headless.js';
16
16
  export { AttrsPatch, BlockChange, BlockCodec, BlockDiff, FromMarkdownOptions, InlineChange, SchemaInput, addMarkStep, atom, blockInputRules, blockRangeSelection, coreBlockSpecs, countDoc, countText, createBlockCodec, createSchema, defineExtension, diffBlocks, diffInline, fromMarkdown, insertBlocksStep, joinBlocksStep, markInputRules, moveBlocksStep, nodeSelection, normalizeInline, parseInline, redo, removeBlocksStep, removeMarkStep, replaceBlockStep, replaceDocStep, replaceInlineStep, sanitizeHref, serializeInline, setAttrsStep, setIndentStep, splitBlockStep, stepFromJSON, text, textSelection, toPlainText, typographyRules, undo } from './engine.js';
17
+ export { C as CalloutTone, a as PALETTE, P as PaletteName } from './palette-DuIFHYHc.js';
17
18
  export { T as ToMarkdownOptions, t as toMarkdown } from './to-markdown-DC1EUye5.js';
18
- export { P as PALETTE } from './palette-BrX-hEd-.js';
19
19
  export { E as EmbedProvider, a as EmbedUrl } from './embed-provider-jXwlRmnp.js';
20
20
  export { H as HTMLOptions, t as toHTML } from './to-html-CogwrQer.js';
21
21
 
@@ -56,13 +56,16 @@ type BlockCanvasProps = {
56
56
  /** The text of an empty paragraph holding the caret, or alone in the document, in place of `labels.placeholderEmpty`. */
57
57
  placeholder?: string;
58
58
  /**
59
- * Every string the canvas shows or speaks, English by default. A key left out stays English. Keep the object stable,
60
- * hoisted or memoised: a new one each render re-renders everything that reads the canvas configuration.
59
+ * Every string the canvas shows or speaks, English by default. A key left out stays English. An object written inline
60
+ * that holds the same strings and functions as the last one, maps of names included, is taken as unchanged; a label
61
+ * function written inline is new on each render and re-renders everything that reads the canvas configuration, so
62
+ * hoist or memoise those.
61
63
  */
62
64
  labels?: Partial<QuoinLabels>;
63
65
  /**
64
66
  * The address the block menu's "Copy link to block" copies. By default the current page with `#block-<id>`, a fragment
65
- * the canvas follows on load and on hash changes to select the block and scroll it into view.
67
+ * the canvas follows on load and on hash changes to select the block and scroll it into view. Keep the function
68
+ * stable: a new one each render builds the block menu's actions again.
66
69
  */
67
70
  blockLink?: (blockId: string) => string;
68
71
  className?: string;
@@ -160,7 +163,10 @@ type UploadFieldProps = {
160
163
  /** Called once the upload resolves. The field stays busy until a returned promise settles, and throwing or rejecting is reported through the canvas `onError`. */
161
164
  onUploaded: (result: UploadResult) => void | Promise<void>;
162
165
  };
163
- /** A file picker wired to the canvas `upload` function, with its own busy state, success message and inline error. */
166
+ /**
167
+ * A file picker wired to the canvas `upload` function, with its own busy state, success message and inline error. The
168
+ * progress is announced through the live region of the canvas it is drawn in, or a live region of its own outside one.
169
+ */
164
170
  declare function UploadField({ category, label, accept, onUploaded }: UploadFieldProps): react.JSX.Element;
165
171
 
166
172
  /** Props for `FilePickerButton`. */
@@ -169,7 +175,7 @@ type FilePickerButtonProps = {
169
175
  label: string;
170
176
  /** An `accept` attribute for the file input, such as `'image/*'` or `'.pdf'`. */
171
177
  accept?: string;
172
- /** Greys the button out and disables the input behind it. After a pick, focus the browser dropped while it was disabled comes back once it is enabled again. */
178
+ /** Greys the button out and disables the input behind it. After a pick, focus the browser dropped while it was disabled comes back once it is enabled again, unless the user pressed elsewhere meanwhile. */
173
179
  disabled?: boolean;
174
180
  /** Greys the button out and refuses picks, as `disabled` does, but leaves the input focusable, so focus stays on it while an upload runs. */
175
181
  busy?: boolean;
@@ -230,6 +236,7 @@ type SuggestionRange = {
230
236
  from: number;
231
237
  to: number;
232
238
  };
239
+ /** A command of the slash menu, which needs a `command`, a `run` or both: the menu leaves out one with neither. */
233
240
  type SlashItem = {
234
241
  id: string;
235
242
  title: string;
package/dist/index.js CHANGED
@@ -1,10 +1,11 @@
1
1
  'use client';
2
- export { BlockCanvas, FilePickerButton, QuoinProvider, UploadField, coreBlocks, englishLabels, formatShortcut, resolveLabels, useAutosave, useLabels, useQuoin } from './chunk-G6NBQYMM.js';
3
- export { EditableRegion, EditorView, ViewController, caretFromPoint, domMapOf, hostKey, renderInline, useEditorState, useQuoinEditor, useViewController } from './chunk-2BPXVQBP.js';
2
+ export { BlockCanvas, FilePickerButton, QuoinProvider, UploadField, coreBlocks, englishLabels, formatShortcut, resolveLabels, useAutosave, useLabels, useQuoin } from './chunk-ZGFZRVQA.js';
3
+ export { EditableRegion, EditorView, ViewController, caretFromPoint, domMapOf, hostKey, renderInline, useEditorState, useQuoinEditor, useViewController } from './chunk-MO4UMXMT.js';
4
4
  import './chunk-DLQCTGC3.js';
5
5
  export { blockByType, defineBlock, paletteBlocks } from './chunk-HDJ653LM.js';
6
- export { Transaction, addMarkStep, applyTransaction, blockInputRules, blockRangeSelection, coreExtensions, countDoc, countText, createEditor, createPluginKey, createState, defineExtension, fromHTML, getPluginState, insertBlockAfter, insertBlocksStep, insertText, insertTextWithRules, joinBlocksStep, keyName, markInputRules, moveBlocksStep, nodeSelection, normalizeKey, redo, removeBlocksStep, removeMarkStep, replaceBlockStep, replaceDocStep, replaceInlineStep, setAttrsStep, setBlockType, setIndentStep, splitBlockStep, stepFromJSON, textSelection, toHTML, toMarkdown, toPlainText, toggleMark, typographyRules, undo } from './chunk-5RBMZGKV.js';
7
- export { diffBlocks, diffInline } from './chunk-CSPCDVCT.js';
8
- export { PALETTE, atom, coreBlockSpecs, createBlockCodec, createSchema, fromMarkdown, normalizeInline, parseInline, sanitizeHref, serializeInline, text } from './chunk-7Y4B7NHO.js';
6
+ import './chunk-PIWMU4BV.js';
7
+ export { Transaction, addMarkStep, applyTransaction, blockInputRules, blockRangeSelection, coreExtensions, countDoc, countText, createEditor, createPluginKey, createState, defineExtension, fromHTML, getPluginState, insertBlockAfter, insertBlocksStep, insertText, insertTextWithRules, joinBlocksStep, keyName, markInputRules, moveBlocksStep, nodeSelection, normalizeKey, redo, removeBlocksStep, removeMarkStep, replaceBlockStep, replaceDocStep, replaceInlineStep, setAttrsStep, setBlockType, setIndentStep, splitBlockStep, stepFromJSON, textSelection, toHTML, toMarkdown, toPlainText, toggleMark, typographyRules, undo } from './chunk-TL2MJOWM.js';
8
+ export { diffBlocks, diffInline } from './chunk-NCV2ML25.js';
9
+ export { PALETTE, atom, coreBlockSpecs, createBlockCodec, createSchema, fromMarkdown, normalizeInline, parseInline, sanitizeHref, serializeInline, text } from './chunk-I34BFOLL.js';
9
10
  //# sourceMappingURL=index.js.map
10
11
  //# sourceMappingURL=index.js.map
@@ -1,9 +1,7 @@
1
- import { P as PALETTE } from './palette-BrX-hEd-.cjs';
2
-
3
- type PaletteName = (typeof PALETTE)[number];
1
+ import { C as CalloutTone, P as PaletteName } from './palette-DuIFHYHc.js';
4
2
 
5
3
  type SlashGroup = 'basic' | 'lists' | 'media' | 'advanced' | 'embeds' | 'ai' | 'custom';
6
- type CalloutTone = 'info' | 'tip' | 'success' | 'warning' | 'danger';
4
+
7
5
  /** The block types the menus name. Headings are named by `heading`. */
8
6
  type BlockName = 'text' | 'bulletedList' | 'numberedList' | 'todoList' | 'quote' | 'callout' | 'toggle' | 'code' | 'divider' | 'image' | 'file';
9
7
  /** The slash commands that insert a block, which the menu explains under their names. */
@@ -32,7 +30,7 @@ type QuoinLabels = {
32
30
  /** The name of the button that shows a callout's tone and opens the menu of tones, given the tone's name. */
33
31
  calloutToneMenu: (tone: string) => string;
34
32
  toggle: string;
35
- /** The name of a toggle's chevron, given how many blocks the closed toggle hides, 0 while it is open. */
33
+ /** The name of a closed toggle's chevron, given how many blocks it hides. A chevron hiding none is named by `toggle`. */
36
34
  toggleButton: (hidden: number) => string;
37
35
  placeholderEmpty: string;
38
36
  placeholderHeading: (level: number) => string;
@@ -44,6 +42,8 @@ type QuoinLabels = {
44
42
  color: string;
45
43
  textColor: string;
46
44
  backgroundColor: string;
45
+ /** The letter the colour menus draw in each text colour beside its name. Optional like `blockError`. */
46
+ textColorSample?: string;
47
47
  /** The submenus of a callout's block menu that set its tone and its icon. */
48
48
  tone: string;
49
49
  icon: string;
@@ -51,12 +51,15 @@ type QuoinLabels = {
51
51
  copy: string;
52
52
  copyLink: string;
53
53
  copied: string;
54
+ copyFailed?: string;
54
55
  moveUp: string;
55
56
  moveDown: string;
56
57
  delete: string;
57
58
  askAi: string;
58
59
  addBelow: string;
59
60
  dragHandle: string;
61
+ /** The drag handle's name on a touch screen, where a tap opens the block menu and a touch does not drag. */
62
+ blockOptions?: string;
60
63
  slashMenu: string;
61
64
  noResults: string;
62
65
  /** What the open slash menu says once its list settles, given how many commands match. */
@@ -87,6 +90,8 @@ type QuoinLabels = {
87
90
  colors: Record<PaletteName, string>;
88
91
  blockMoved: (position: number, total: number) => string;
89
92
  blockInserted: (position: number, total: number) => string;
93
+ /** Several blocks inserted at once, at the place of the first of them. */
94
+ blocksInserted?: (n: number, position: number, total: number) => string;
90
95
  blockDeleted: (n: number) => string;
91
96
  blocksSelected: (n: number) => string;
92
97
  /** How to bring deleted blocks back, given the platform's undo shortcut. */