@ckeditor/ckeditor5-list 47.5.0 → 47.6.0-alpha.1

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 (310) hide show
  1. package/LICENSE.md +4 -0
  2. package/build/list.js +2 -2
  3. package/build/translations/af.js +1 -1
  4. package/build/translations/ar.js +1 -1
  5. package/build/translations/ast.js +1 -1
  6. package/build/translations/az.js +1 -1
  7. package/build/translations/be.js +1 -1
  8. package/build/translations/bg.js +1 -1
  9. package/build/translations/bn.js +1 -1
  10. package/build/translations/bs.js +1 -1
  11. package/build/translations/ca.js +1 -1
  12. package/build/translations/cs.js +1 -1
  13. package/build/translations/da.js +1 -1
  14. package/build/translations/de-ch.js +1 -1
  15. package/build/translations/de.js +1 -1
  16. package/build/translations/el.js +1 -1
  17. package/build/translations/en-au.js +1 -1
  18. package/build/translations/en-gb.js +1 -1
  19. package/build/translations/eo.js +1 -1
  20. package/build/translations/es-co.js +1 -1
  21. package/build/translations/es.js +1 -1
  22. package/build/translations/et.js +1 -1
  23. package/build/translations/eu.js +1 -1
  24. package/build/translations/fa.js +1 -1
  25. package/build/translations/fi.js +1 -1
  26. package/build/translations/fr.js +1 -1
  27. package/build/translations/gl.js +1 -1
  28. package/build/translations/gu.js +1 -1
  29. package/build/translations/he.js +1 -1
  30. package/build/translations/hi.js +1 -1
  31. package/build/translations/hr.js +1 -1
  32. package/build/translations/hu.js +1 -1
  33. package/build/translations/hy.js +1 -1
  34. package/build/translations/id.js +1 -1
  35. package/build/translations/it.js +1 -1
  36. package/build/translations/ja.js +1 -1
  37. package/build/translations/jv.js +1 -1
  38. package/build/translations/kk.js +1 -1
  39. package/build/translations/km.js +1 -1
  40. package/build/translations/kn.js +1 -1
  41. package/build/translations/ko.js +1 -1
  42. package/build/translations/ku.js +1 -1
  43. package/build/translations/lt.js +1 -1
  44. package/build/translations/lv.js +1 -1
  45. package/build/translations/ms.js +1 -1
  46. package/build/translations/nb.js +1 -1
  47. package/build/translations/ne.js +1 -1
  48. package/build/translations/nl.js +1 -1
  49. package/build/translations/no.js +1 -1
  50. package/build/translations/oc.js +1 -1
  51. package/build/translations/pl.js +1 -1
  52. package/build/translations/pt-br.js +1 -1
  53. package/build/translations/pt.js +1 -1
  54. package/build/translations/ro.js +1 -1
  55. package/build/translations/ru.js +1 -1
  56. package/build/translations/si.js +1 -1
  57. package/build/translations/sk.js +1 -1
  58. package/build/translations/sl.js +1 -1
  59. package/build/translations/sq.js +1 -1
  60. package/build/translations/sr-latn.js +1 -1
  61. package/build/translations/sr.js +1 -1
  62. package/build/translations/sv.js +1 -1
  63. package/build/translations/th.js +1 -1
  64. package/build/translations/ti.js +1 -1
  65. package/build/translations/tk.js +1 -1
  66. package/build/translations/tr.js +1 -1
  67. package/build/translations/tt.js +1 -1
  68. package/build/translations/ug.js +1 -1
  69. package/build/translations/uk.js +1 -1
  70. package/build/translations/ur.js +1 -1
  71. package/build/translations/uz.js +1 -1
  72. package/build/translations/vi.js +1 -1
  73. package/build/translations/zh-cn.js +1 -1
  74. package/build/translations/zh.js +1 -1
  75. package/dist/index.js +82 -16
  76. package/dist/index.js.map +1 -1
  77. package/dist/translations/af.js +1 -1
  78. package/dist/translations/af.umd.js +1 -1
  79. package/dist/translations/ar.js +1 -1
  80. package/dist/translations/ar.umd.js +1 -1
  81. package/dist/translations/ast.js +1 -1
  82. package/dist/translations/ast.umd.js +1 -1
  83. package/dist/translations/az.js +1 -1
  84. package/dist/translations/az.umd.js +1 -1
  85. package/dist/translations/be.js +1 -1
  86. package/dist/translations/be.umd.js +1 -1
  87. package/dist/translations/bg.js +1 -1
  88. package/dist/translations/bg.umd.js +1 -1
  89. package/dist/translations/bn.js +1 -1
  90. package/dist/translations/bn.umd.js +1 -1
  91. package/dist/translations/bs.js +1 -1
  92. package/dist/translations/bs.umd.js +1 -1
  93. package/dist/translations/ca.js +1 -1
  94. package/dist/translations/ca.umd.js +1 -1
  95. package/dist/translations/cs.js +1 -1
  96. package/dist/translations/cs.umd.js +1 -1
  97. package/dist/translations/da.js +1 -1
  98. package/dist/translations/da.umd.js +1 -1
  99. package/dist/translations/de-ch.js +1 -1
  100. package/dist/translations/de-ch.umd.js +1 -1
  101. package/dist/translations/de.js +1 -1
  102. package/dist/translations/de.umd.js +1 -1
  103. package/dist/translations/el.js +1 -1
  104. package/dist/translations/el.umd.js +1 -1
  105. package/dist/translations/en-au.js +1 -1
  106. package/dist/translations/en-au.umd.js +1 -1
  107. package/dist/translations/en-gb.js +1 -1
  108. package/dist/translations/en-gb.umd.js +1 -1
  109. package/dist/translations/en.js +1 -1
  110. package/dist/translations/en.umd.js +1 -1
  111. package/dist/translations/eo.js +1 -1
  112. package/dist/translations/eo.umd.js +1 -1
  113. package/dist/translations/es-co.js +1 -1
  114. package/dist/translations/es-co.umd.js +1 -1
  115. package/dist/translations/es.js +1 -1
  116. package/dist/translations/es.umd.js +1 -1
  117. package/dist/translations/et.js +1 -1
  118. package/dist/translations/et.umd.js +1 -1
  119. package/dist/translations/eu.js +1 -1
  120. package/dist/translations/eu.umd.js +1 -1
  121. package/dist/translations/fa.js +1 -1
  122. package/dist/translations/fa.umd.js +1 -1
  123. package/dist/translations/fi.js +1 -1
  124. package/dist/translations/fi.umd.js +1 -1
  125. package/dist/translations/fr.js +1 -1
  126. package/dist/translations/fr.umd.js +1 -1
  127. package/dist/translations/gl.js +1 -1
  128. package/dist/translations/gl.umd.js +1 -1
  129. package/dist/translations/gu.js +1 -1
  130. package/dist/translations/gu.umd.js +1 -1
  131. package/dist/translations/he.js +1 -1
  132. package/dist/translations/he.umd.js +1 -1
  133. package/dist/translations/hi.js +1 -1
  134. package/dist/translations/hi.umd.js +1 -1
  135. package/dist/translations/hr.js +1 -1
  136. package/dist/translations/hr.umd.js +1 -1
  137. package/dist/translations/hu.js +1 -1
  138. package/dist/translations/hu.umd.js +1 -1
  139. package/dist/translations/hy.js +1 -1
  140. package/dist/translations/hy.umd.js +1 -1
  141. package/dist/translations/id.js +1 -1
  142. package/dist/translations/id.umd.js +1 -1
  143. package/dist/translations/it.js +1 -1
  144. package/dist/translations/it.umd.js +1 -1
  145. package/dist/translations/ja.js +1 -1
  146. package/dist/translations/ja.umd.js +1 -1
  147. package/dist/translations/jv.js +1 -1
  148. package/dist/translations/jv.umd.js +1 -1
  149. package/dist/translations/kk.js +1 -1
  150. package/dist/translations/kk.umd.js +1 -1
  151. package/dist/translations/km.js +1 -1
  152. package/dist/translations/km.umd.js +1 -1
  153. package/dist/translations/kn.js +1 -1
  154. package/dist/translations/kn.umd.js +1 -1
  155. package/dist/translations/ko.js +1 -1
  156. package/dist/translations/ko.umd.js +1 -1
  157. package/dist/translations/ku.js +1 -1
  158. package/dist/translations/ku.umd.js +1 -1
  159. package/dist/translations/lt.js +1 -1
  160. package/dist/translations/lt.umd.js +1 -1
  161. package/dist/translations/lv.js +1 -1
  162. package/dist/translations/lv.umd.js +1 -1
  163. package/dist/translations/ms.js +1 -1
  164. package/dist/translations/ms.umd.js +1 -1
  165. package/dist/translations/nb.js +1 -1
  166. package/dist/translations/nb.umd.js +1 -1
  167. package/dist/translations/ne.js +1 -1
  168. package/dist/translations/ne.umd.js +1 -1
  169. package/dist/translations/nl.js +1 -1
  170. package/dist/translations/nl.umd.js +1 -1
  171. package/dist/translations/no.js +1 -1
  172. package/dist/translations/no.umd.js +1 -1
  173. package/dist/translations/oc.js +1 -1
  174. package/dist/translations/oc.umd.js +1 -1
  175. package/dist/translations/pl.js +1 -1
  176. package/dist/translations/pl.umd.js +1 -1
  177. package/dist/translations/pt-br.js +1 -1
  178. package/dist/translations/pt-br.umd.js +1 -1
  179. package/dist/translations/pt.js +1 -1
  180. package/dist/translations/pt.umd.js +1 -1
  181. package/dist/translations/ro.js +1 -1
  182. package/dist/translations/ro.umd.js +1 -1
  183. package/dist/translations/ru.js +1 -1
  184. package/dist/translations/ru.umd.js +1 -1
  185. package/dist/translations/si.js +1 -1
  186. package/dist/translations/si.umd.js +1 -1
  187. package/dist/translations/sk.js +1 -1
  188. package/dist/translations/sk.umd.js +1 -1
  189. package/dist/translations/sl.js +1 -1
  190. package/dist/translations/sl.umd.js +1 -1
  191. package/dist/translations/sq.js +1 -1
  192. package/dist/translations/sq.umd.js +1 -1
  193. package/dist/translations/sr-latn.js +1 -1
  194. package/dist/translations/sr-latn.umd.js +1 -1
  195. package/dist/translations/sr.js +1 -1
  196. package/dist/translations/sr.umd.js +1 -1
  197. package/dist/translations/sv.js +1 -1
  198. package/dist/translations/sv.umd.js +1 -1
  199. package/dist/translations/th.js +1 -1
  200. package/dist/translations/th.umd.js +1 -1
  201. package/dist/translations/ti.js +1 -1
  202. package/dist/translations/ti.umd.js +1 -1
  203. package/dist/translations/tk.js +1 -1
  204. package/dist/translations/tk.umd.js +1 -1
  205. package/dist/translations/tr.js +1 -1
  206. package/dist/translations/tr.umd.js +1 -1
  207. package/dist/translations/tt.js +1 -1
  208. package/dist/translations/tt.umd.js +1 -1
  209. package/dist/translations/ug.js +1 -1
  210. package/dist/translations/ug.umd.js +1 -1
  211. package/dist/translations/uk.js +1 -1
  212. package/dist/translations/uk.umd.js +1 -1
  213. package/dist/translations/ur.js +1 -1
  214. package/dist/translations/ur.umd.js +1 -1
  215. package/dist/translations/uz.js +1 -1
  216. package/dist/translations/uz.umd.js +1 -1
  217. package/dist/translations/vi.js +1 -1
  218. package/dist/translations/vi.umd.js +1 -1
  219. package/dist/translations/zh-cn.js +1 -1
  220. package/dist/translations/zh-cn.umd.js +1 -1
  221. package/dist/translations/zh.js +1 -1
  222. package/dist/translations/zh.umd.js +1 -1
  223. package/lang/contexts.json +2 -0
  224. package/lang/translations/af.po +8 -0
  225. package/lang/translations/ar.po +8 -0
  226. package/lang/translations/ast.po +8 -0
  227. package/lang/translations/az.po +8 -0
  228. package/lang/translations/be.po +8 -0
  229. package/lang/translations/bg.po +8 -0
  230. package/lang/translations/bn.po +8 -0
  231. package/lang/translations/bs.po +8 -0
  232. package/lang/translations/ca.po +8 -0
  233. package/lang/translations/cs.po +8 -0
  234. package/lang/translations/da.po +8 -0
  235. package/lang/translations/de-ch.po +8 -0
  236. package/lang/translations/de.po +8 -0
  237. package/lang/translations/el.po +8 -0
  238. package/lang/translations/en-au.po +8 -0
  239. package/lang/translations/en-gb.po +8 -0
  240. package/lang/translations/en.po +8 -0
  241. package/lang/translations/eo.po +8 -0
  242. package/lang/translations/es-co.po +8 -0
  243. package/lang/translations/es.po +8 -0
  244. package/lang/translations/et.po +8 -0
  245. package/lang/translations/eu.po +8 -0
  246. package/lang/translations/fa.po +8 -0
  247. package/lang/translations/fi.po +8 -0
  248. package/lang/translations/fr.po +8 -0
  249. package/lang/translations/gl.po +8 -0
  250. package/lang/translations/gu.po +8 -0
  251. package/lang/translations/he.po +8 -0
  252. package/lang/translations/hi.po +8 -0
  253. package/lang/translations/hr.po +8 -0
  254. package/lang/translations/hu.po +8 -0
  255. package/lang/translations/hy.po +8 -0
  256. package/lang/translations/id.po +8 -0
  257. package/lang/translations/it.po +8 -0
  258. package/lang/translations/ja.po +8 -0
  259. package/lang/translations/jv.po +8 -0
  260. package/lang/translations/kk.po +8 -0
  261. package/lang/translations/km.po +8 -0
  262. package/lang/translations/kn.po +8 -0
  263. package/lang/translations/ko.po +8 -0
  264. package/lang/translations/ku.po +8 -0
  265. package/lang/translations/lt.po +8 -0
  266. package/lang/translations/lv.po +8 -0
  267. package/lang/translations/ms.po +8 -0
  268. package/lang/translations/nb.po +8 -0
  269. package/lang/translations/ne.po +8 -0
  270. package/lang/translations/nl.po +8 -0
  271. package/lang/translations/no.po +8 -0
  272. package/lang/translations/oc.po +8 -0
  273. package/lang/translations/pl.po +8 -0
  274. package/lang/translations/pt-br.po +8 -0
  275. package/lang/translations/pt.po +8 -0
  276. package/lang/translations/ro.po +8 -0
  277. package/lang/translations/ru.po +8 -0
  278. package/lang/translations/si.po +8 -0
  279. package/lang/translations/sk.po +8 -0
  280. package/lang/translations/sl.po +8 -0
  281. package/lang/translations/sq.po +8 -0
  282. package/lang/translations/sr-latn.po +8 -0
  283. package/lang/translations/sr.po +8 -0
  284. package/lang/translations/sv.po +8 -0
  285. package/lang/translations/th.po +8 -0
  286. package/lang/translations/ti.po +8 -0
  287. package/lang/translations/tk.po +8 -0
  288. package/lang/translations/tr.po +8 -0
  289. package/lang/translations/tt.po +8 -0
  290. package/lang/translations/ug.po +8 -0
  291. package/lang/translations/uk.po +8 -0
  292. package/lang/translations/ur.po +8 -0
  293. package/lang/translations/uz.po +8 -0
  294. package/lang/translations/vi.po +8 -0
  295. package/lang/translations/zh-cn.po +8 -0
  296. package/lang/translations/zh.po +8 -0
  297. package/package.json +12 -11
  298. package/src/list/listcommand.d.ts +1 -1
  299. package/src/list/listcommand.js +3 -1
  300. package/src/list/listediting.js +1 -1
  301. package/src/list/listindentcommand.js +7 -4
  302. package/src/list/listmergecommand.js +6 -2
  303. package/src/list/listutils.d.ts +4 -0
  304. package/src/list/listutils.js +7 -1
  305. package/src/list/utils/model.d.ts +17 -3
  306. package/src/list/utils/model.js +23 -6
  307. package/src/listconfig.d.ts +1 -1
  308. package/src/listproperties/listpropertiesui.js +7 -1
  309. package/src/listproperties/utils/config.js +11 -1
  310. package/src/listproperties/utils/style.js +2 -1
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "Unošenje liste obaveza"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "Ostavljanje liste obaveza"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "Unošenje liste obaveza"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "Ostavljanje liste obaveza"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "Fyller i en att-göra-lista"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "Lämnar en att-göra-lista"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "เข้าสู่รายการสิ่งที่ต้อง
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "ออกจากรายการสิ่งที่ต้องทำ"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "Yapılacaklar listesi girmek"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "Yapılacaklar listesinden ayrılma"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "ئىش تىزىمىنى كىرگۈزۈۋاتىدۇ"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "ئىش تىزىمىدىن ئايرىلىۋاتىدۇ"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "Входимо у список справ"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "Виходимо зі списку справ"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr ""
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr ""
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "Đang nhập danh sách việc cần làm"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "Đang rời khỏi danh sách việc cần làm"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "正在输入待办事项清单"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "正在退出待办事项清单"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
@@ -142,3 +142,11 @@ msgstr "進入待辦事項清單"
142
142
  msgctxt "Assistive technologies label for leaving the to-do list."
143
143
  msgid "Leaving a to-do list"
144
144
  msgstr "離開待辦事項清單"
145
+
146
+ msgctxt "The ARIA label of the button that toggles the \"arabic-indic\" list style."
147
+ msgid "Toggle the arabic-indic list style"
148
+ msgstr ""
149
+
150
+ msgctxt "The tooltip text of the button that toggles the \"arabic-indic\" list style."
151
+ msgid "Arabic-indic"
152
+ msgstr ""
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ckeditor/ckeditor5-list",
3
- "version": "47.5.0",
3
+ "version": "47.6.0-alpha.1",
4
4
  "description": "Ordered and unordered lists feature to CKEditor 5.",
5
5
  "keywords": [
6
6
  "ckeditor",
@@ -13,16 +13,17 @@
13
13
  "type": "module",
14
14
  "main": "src/index.js",
15
15
  "dependencies": {
16
- "@ckeditor/ckeditor5-clipboard": "47.5.0",
17
- "@ckeditor/ckeditor5-core": "47.5.0",
18
- "@ckeditor/ckeditor5-engine": "47.5.0",
19
- "@ckeditor/ckeditor5-enter": "47.5.0",
20
- "@ckeditor/ckeditor5-font": "47.5.0",
21
- "@ckeditor/ckeditor5-icons": "47.5.0",
22
- "@ckeditor/ckeditor5-typing": "47.5.0",
23
- "@ckeditor/ckeditor5-ui": "47.5.0",
24
- "@ckeditor/ckeditor5-utils": "47.5.0",
25
- "ckeditor5": "47.5.0"
16
+ "@ckeditor/ckeditor5-clipboard": "47.6.0-alpha.1",
17
+ "@ckeditor/ckeditor5-core": "47.6.0-alpha.1",
18
+ "@ckeditor/ckeditor5-engine": "47.6.0-alpha.1",
19
+ "@ckeditor/ckeditor5-enter": "47.6.0-alpha.1",
20
+ "@ckeditor/ckeditor5-font": "47.6.0-alpha.1",
21
+ "@ckeditor/ckeditor5-icons": "47.6.0-alpha.1",
22
+ "@ckeditor/ckeditor5-typing": "47.6.0-alpha.1",
23
+ "@ckeditor/ckeditor5-ui": "47.6.0-alpha.1",
24
+ "@ckeditor/ckeditor5-utils": "47.6.0-alpha.1",
25
+ "ckeditor5": "47.6.0-alpha.1",
26
+ "es-toolkit": "1.39.5"
26
27
  },
27
28
  "author": "CKSource (http://cksource.com/)",
28
29
  "license": "SEE LICENSE IN LICENSE.md",
@@ -7,7 +7,7 @@
7
7
  */
8
8
  import type { ModelElement } from 'ckeditor5/src/engine.js';
9
9
  import { Command, type Editor } from 'ckeditor5/src/core.js';
10
- import { type ListType } from './listediting.js';
10
+ import type { ListType } from './listediting.js';
11
11
  /**
12
12
  * The list command. It is used by the {@link module:list/list~List list feature}.
13
13
  */
@@ -63,6 +63,8 @@ export class ListCommand extends Command {
63
63
  model.change(writer => {
64
64
  if (turnOff) {
65
65
  const lastBlock = blocks[blocks.length - 1];
66
+ const listEditing = this.editor.plugins.get('ListEditing');
67
+ const attributeNames = listEditing.getListAttributeNames();
66
68
  // Split the first block from the list item.
67
69
  const itemBlocks = getListItemBlocks(lastBlock, { direction: 'forward' });
68
70
  const changedBlocks = [];
@@ -70,7 +72,7 @@ export class ListCommand extends Command {
70
72
  changedBlocks.push(...splitListItemBefore(itemBlocks[1], writer));
71
73
  }
72
74
  // Strip list attributes.
73
- changedBlocks.push(...removeListAttributes(blocks, writer));
75
+ changedBlocks.push(...removeListAttributes(blocks, writer, attributeNames));
74
76
  // Outdent items following the selected list item.
75
77
  changedBlocks.push(...outdentFollowingItems(lastBlock, writer));
76
78
  this._fireAfterExecute(changedBlocks);
@@ -457,7 +457,7 @@ export class ListEditing extends Plugin {
457
457
  const allChildren = Array.from(data.content.getChildren());
458
458
  const isSingleListItemSelected = isSingleListItem(allChildren);
459
459
  if (isSingleListItemSelected) {
460
- removeListAttributes(allChildren, writer);
460
+ removeListAttributes(allChildren, writer, this.getListAttributeNames());
461
461
  }
462
462
  }
463
463
  });
@@ -40,15 +40,18 @@ export class ListIndentCommand extends Command {
40
40
  * @fires afterExecute
41
41
  */
42
42
  execute() {
43
- const model = this.editor.model;
43
+ const editor = this.editor;
44
+ const model = editor.model;
44
45
  const blocks = getSelectedListBlocks(model.document.selection);
46
+ const listEditing = editor.plugins.get('ListEditing');
47
+ const attributeNames = listEditing.getListAttributeNames();
45
48
  model.change(writer => {
46
49
  const changedBlocks = [];
47
50
  // Handle selection contained in the single list item and starting in the following blocks.
48
51
  if (isSingleListItem(blocks) && !isFirstBlockOfListItem(blocks[0])) {
49
52
  // Allow increasing indent of following list item blocks.
50
53
  if (this._direction == 'forward') {
51
- changedBlocks.push(...indentBlocks(blocks, writer));
54
+ changedBlocks.push(...indentBlocks(blocks, writer, { attributeNames }));
52
55
  }
53
56
  // For indent make sure that indented blocks have a new ID.
54
57
  // For outdent just split blocks from the list item (give them a new IDs).
@@ -58,10 +61,10 @@ export class ListIndentCommand extends Command {
58
61
  else {
59
62
  // Now just update the attributes of blocks.
60
63
  if (this._direction == 'forward') {
61
- changedBlocks.push(...indentBlocks(blocks, writer, { expand: true }));
64
+ changedBlocks.push(...indentBlocks(blocks, writer, { expand: true, attributeNames }));
62
65
  }
63
66
  else {
64
- changedBlocks.push(...outdentBlocksWithMerge(blocks, writer));
67
+ changedBlocks.push(...outdentBlocksWithMerge(blocks, writer, { attributeNames }));
65
68
  }
66
69
  }
67
70
  // Align the list item type to match the previous list item (from the same list).
@@ -43,9 +43,12 @@ export class ListMergeCommand extends Command {
43
43
  * of the heuristics in `deleteContent()` that helps convert lists into paragraphs in certain cases.
44
44
  */
45
45
  execute({ shouldMergeOnBlocksContentLevel = false } = {}) {
46
- const model = this.editor.model;
46
+ const editor = this.editor;
47
+ const model = editor.model;
47
48
  const selection = model.document.selection;
48
49
  const changedBlocks = [];
50
+ const listEditing = editor.plugins.get('ListEditing');
51
+ const attributeNames = listEditing.getListAttributeNames();
49
52
  model.change(writer => {
50
53
  const { firstElement, lastElement } = this._getMergeSubjectElements(selection, shouldMergeOnBlocksContentLevel);
51
54
  const firstIndent = firstElement.getAttribute('listIndent') || 0;
@@ -56,7 +59,8 @@ export class ListMergeCommand extends Command {
56
59
  changedBlocks.push(...indentBlocks([lastElement, ...nestedLastElementBlocks], writer, {
57
60
  indentBy: firstIndent - lastIndent,
58
61
  // If outdenting, the entire sub-tree that follows must be included.
59
- expand: firstIndent < lastIndent
62
+ expand: firstIndent < lastIndent,
63
+ attributeNames
60
64
  }));
61
65
  }
62
66
  if (shouldMergeOnBlocksContentLevel) {
@@ -53,4 +53,8 @@ export declare class ListUtils extends Plugin {
53
53
  * Returns true if listType is of type `numbered` or `customNumbered`.
54
54
  */
55
55
  isNumberedListType(listType: ListType): boolean;
56
+ /**
57
+ * Returns true if the given list item is the first item in the list.
58
+ */
59
+ isFirstListItemInList(listItem: ModelElement): boolean;
56
60
  }
@@ -3,7 +3,7 @@
3
3
  * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
4
4
  */
5
5
  import { Plugin } from 'ckeditor5/src/core.js';
6
- import { expandListBlocksToCompleteItems, expandListBlocksToCompleteList, isFirstBlockOfListItem, isListItemBlock, isNumberedListType } from './utils/model.js';
6
+ import { expandListBlocksToCompleteItems, expandListBlocksToCompleteList, isFirstBlockOfListItem, isFirstListItemInList, isListItemBlock, isNumberedListType } from './utils/model.js';
7
7
  /**
8
8
  * A set of helpers related to document lists.
9
9
  */
@@ -59,4 +59,10 @@ export class ListUtils extends Plugin {
59
59
  isNumberedListType(listType) {
60
60
  return isNumberedListType(listType);
61
61
  }
62
+ /**
63
+ * Returns true if the given list item is the first item in the list.
64
+ */
65
+ isFirstListItemInList(listItem) {
66
+ return isFirstListItemInList(listItem);
67
+ }
62
68
  }
@@ -140,10 +140,12 @@ export declare function mergeListItemBefore(listBlock: ModelNode, parentBlock: M
140
140
  * @param options Additional options.
141
141
  * @param options.expand Whether should expand the list of blocks to include complete list items.
142
142
  * @param options.indentBy The number of levels the indentation should change (could be negative).
143
+ * @param options.attributeNames List of attribute names to remove when a block leaves the list (when blockIndent < 0).
143
144
  */
144
- export declare function indentBlocks(blocks: ArrayOrItem<ListElement>, writer: ModelWriter, { expand, indentBy }?: {
145
+ export declare function indentBlocks(blocks: ArrayOrItem<ListElement>, writer: ModelWriter, { expand, indentBy, attributeNames }: {
145
146
  expand?: boolean;
146
147
  indentBy?: number;
148
+ attributeNames: Array<string>;
147
149
  }): Array<ListElement>;
148
150
  /**
149
151
  * Decreases indentation of given list of blocks. If the indentation of some blocks matches the indentation
@@ -152,17 +154,22 @@ export declare function indentBlocks(blocks: ArrayOrItem<ListElement>, writer: M
152
154
  * @internal
153
155
  * @param blocks The block or iterable of blocks.
154
156
  * @param writer The model writer.
157
+ * @param options Additional options.
158
+ * @param options.attributeNames List of attribute names to remove when a block leaves the list (when blockIndent < 0).
155
159
  */
156
- export declare function outdentBlocksWithMerge(blocks: ArrayOrItem<ListElement>, writer: ModelWriter): Array<ListElement>;
160
+ export declare function outdentBlocksWithMerge(blocks: ArrayOrItem<ListElement>, writer: ModelWriter, { attributeNames }: {
161
+ attributeNames: Array<string>;
162
+ }): Array<ListElement>;
157
163
  /**
158
164
  * Removes all list attributes from the given blocks.
159
165
  *
160
166
  * @internal
161
167
  * @param blocks The block or iterable of blocks.
162
168
  * @param writer The model writer.
169
+ * @param attributeNames List of attribute names to remove.
163
170
  * @returns Array of altered blocks.
164
171
  */
165
- export declare function removeListAttributes(blocks: ArrayOrItem<ModelElement>, writer: ModelWriter): Array<ModelElement>;
172
+ export declare function removeListAttributes(blocks: ArrayOrItem<ModelElement>, writer: ModelWriter, attributeNames: Array<string>): Array<ModelElement>;
166
173
  /**
167
174
  * Checks whether the given blocks are related to a single list item.
168
175
  *
@@ -211,3 +218,10 @@ export declare function canBecomeSimpleListItem(block: ModelElement, schema: Mod
211
218
  * @internal
212
219
  */
213
220
  export declare function isNumberedListType(listType: ListType): boolean;
221
+ /**
222
+ * Checks if the given list item is the first item in the list.
223
+ *
224
+ * This function checks if there's any other list item before the given list item
225
+ * at the same indent level with the same list type.
226
+ */
227
+ export declare function isFirstListItemInList(listItem: ModelElement): boolean;
@@ -215,15 +215,16 @@ export function mergeListItemBefore(listBlock, parentBlock, writer) {
215
215
  * @param options Additional options.
216
216
  * @param options.expand Whether should expand the list of blocks to include complete list items.
217
217
  * @param options.indentBy The number of levels the indentation should change (could be negative).
218
+ * @param options.attributeNames List of attribute names to remove when a block leaves the list (when blockIndent < 0).
218
219
  */
219
- export function indentBlocks(blocks, writer, { expand, indentBy = 1 } = {}) {
220
+ export function indentBlocks(blocks, writer, { expand, indentBy = 1, attributeNames }) {
220
221
  blocks = toArray(blocks);
221
222
  // Expand the selected blocks to contain the whole list items.
222
223
  const allBlocks = expand ? expandListBlocksToCompleteItems(blocks) : blocks;
223
224
  for (const block of allBlocks) {
224
225
  const blockIndent = block.getAttribute('listIndent') + indentBy;
225
226
  if (blockIndent < 0) {
226
- removeListAttributes(block, writer);
227
+ removeListAttributes(block, writer, attributeNames);
227
228
  }
228
229
  else {
229
230
  writer.setAttribute('listIndent', blockIndent, block);
@@ -238,8 +239,10 @@ export function indentBlocks(blocks, writer, { expand, indentBy = 1 } = {}) {
238
239
  * @internal
239
240
  * @param blocks The block or iterable of blocks.
240
241
  * @param writer The model writer.
242
+ * @param options Additional options.
243
+ * @param options.attributeNames List of attribute names to remove when a block leaves the list (when blockIndent < 0).
241
244
  */
242
- export function outdentBlocksWithMerge(blocks, writer) {
245
+ export function outdentBlocksWithMerge(blocks, writer, { attributeNames }) {
243
246
  blocks = toArray(blocks);
244
247
  // Expand the selected blocks to contain the whole list items.
245
248
  const allBlocks = expandListBlocksToCompleteItems(blocks);
@@ -257,7 +260,7 @@ export function outdentBlocksWithMerge(blocks, writer) {
257
260
  visited.add(block);
258
261
  const blockIndent = block.getAttribute('listIndent') - 1;
259
262
  if (blockIndent < 0) {
260
- removeListAttributes(block, writer);
263
+ removeListAttributes(block, writer, attributeNames);
261
264
  continue;
262
265
  }
263
266
  // Merge with parent list item while outdenting and indent matches reference indent.
@@ -282,9 +285,10 @@ export function outdentBlocksWithMerge(blocks, writer) {
282
285
  * @internal
283
286
  * @param blocks The block or iterable of blocks.
284
287
  * @param writer The model writer.
288
+ * @param attributeNames List of attribute names to remove.
285
289
  * @returns Array of altered blocks.
286
290
  */
287
- export function removeListAttributes(blocks, writer) {
291
+ export function removeListAttributes(blocks, writer, attributeNames) {
288
292
  blocks = toArray(blocks);
289
293
  // Convert simple list items to plain paragraphs.
290
294
  for (const block of blocks) {
@@ -295,7 +299,7 @@ export function removeListAttributes(blocks, writer) {
295
299
  // Remove list attributes.
296
300
  for (const block of blocks) {
297
301
  for (const attributeKey of block.getAttributeKeys()) {
298
- if (attributeKey.startsWith('list')) {
302
+ if (attributeNames.includes(attributeKey)) {
299
303
  writer.removeAttribute(attributeKey, block);
300
304
  }
301
305
  }
@@ -449,6 +453,19 @@ export function canBecomeSimpleListItem(block, schema) {
449
453
  export function isNumberedListType(listType) {
450
454
  return listType == 'numbered' || listType == 'customNumbered';
451
455
  }
456
+ /**
457
+ * Checks if the given list item is the first item in the list.
458
+ *
459
+ * This function checks if there's any other list item before the given list item
460
+ * at the same indent level with the same list type.
461
+ */
462
+ export function isFirstListItemInList(listItem) {
463
+ const previousItem = ListWalker.first(listItem, {
464
+ sameIndent: true,
465
+ sameAttributes: 'listType'
466
+ });
467
+ return !previousItem;
468
+ }
452
469
  /**
453
470
  * Merges a given block to the given parent block if parent is a list item and there is no more blocks in the same item.
454
471
  */
@@ -224,5 +224,5 @@ export interface ListStyleTypesConfig {
224
224
  bulleted?: Array<BulletedListStyleType>;
225
225
  }
226
226
  export type ListPropertiesStyleListType = 'numbered' | 'bulleted';
227
- export type NumberedListStyleType = 'decimal' | 'decimal-leading-zero' | 'lower-roman' | 'upper-roman' | 'lower-latin' | 'upper-latin';
227
+ export type NumberedListStyleType = 'decimal' | 'decimal-leading-zero' | 'lower-roman' | 'upper-roman' | 'lower-latin' | 'upper-latin' | 'arabic-indic';
228
228
  export type BulletedListStyleType = 'disc' | 'circle' | 'square';
@@ -6,7 +6,7 @@
6
6
  * @module list/listproperties/listpropertiesui
7
7
  */
8
8
  import { Plugin } from 'ckeditor5/src/core.js';
9
- import { IconBulletedList, IconNumberedList, IconListStyleCircle, IconListStyleDecimal, IconListStyleDecimalLeadingZero, IconListStyleDisc, IconListStyleLowerLatin, IconListStyleLowerRoman, IconListStyleSquare, IconListStyleUpperLatin, IconListStyleUpperRoman } from 'ckeditor5/src/icons.js';
9
+ import { IconBulletedList, IconNumberedList, IconListStyleCircle, IconListStyleDecimal, IconListStyleDecimalLeadingZero, IconListStyleDisc, IconListStyleLowerLatin, IconListStyleLowerRoman, IconListStyleSquare, IconListStyleUpperLatin, IconListStyleUpperRoman, IconListStyleArabicIndic } from 'ckeditor5/src/icons.js';
10
10
  import { ButtonView, SplitButtonView, createDropdown, focusChildOnDropdownOpen, MenuBarMenuView } from 'ckeditor5/src/ui.js';
11
11
  import { ListPropertiesView } from './ui/listpropertiesview.js';
12
12
  import { getNormalizedConfig } from './utils/config.js';
@@ -123,6 +123,12 @@ export class ListPropertiesUI extends Plugin {
123
123
  tooltip: t('Upper-latin'),
124
124
  type: 'upper-latin',
125
125
  icon: IconListStyleUpperLatin
126
+ },
127
+ {
128
+ label: t('Toggle the arabic-indic list style'),
129
+ tooltip: t('Arabic-indic'),
130
+ type: 'arabic-indic',
131
+ icon: IconListStyleArabicIndic
126
132
  }
127
133
  ];
128
134
  const buttonLabel = t('Numbered List');
@@ -5,6 +5,7 @@
5
5
  /**
6
6
  * @module list/listproperties/utils/config
7
7
  */
8
+ import { pick } from 'es-toolkit/compat';
8
9
  import { toArray } from 'ckeditor5/src/utils.js';
9
10
  /**
10
11
  * Normalizes {@link module:list/listconfig~ListPropertiesConfig} in the configuration of the list properties feature.
@@ -50,16 +51,22 @@ export function getNormalizedConfig(config) {
50
51
  function getNormalizedStylesConfig(styles) {
51
52
  const normalizedConfig = {
52
53
  listTypes: ['bulleted', 'numbered'],
53
- useAttribute: false
54
+ useAttribute: false,
55
+ listStyleTypes: {
56
+ numbered: ['decimal', 'decimal-leading-zero', 'lower-roman', 'upper-roman', 'lower-latin', 'upper-latin'],
57
+ bulleted: ['disc', 'circle', 'square']
58
+ }
54
59
  };
55
60
  if (styles === true) {
56
61
  return normalizedConfig;
57
62
  }
58
63
  if (!styles) {
59
64
  normalizedConfig.listTypes = [];
65
+ normalizedConfig.listStyleTypes = {};
60
66
  }
61
67
  else if (Array.isArray(styles) || typeof styles == 'string') {
62
68
  normalizedConfig.listTypes = toArray(styles);
69
+ normalizedConfig.listStyleTypes = pick(normalizedConfig.listStyleTypes, normalizedConfig.listTypes);
63
70
  }
64
71
  else {
65
72
  normalizedConfig.listTypes = styles.listTypes ?
@@ -69,6 +76,9 @@ function getNormalizedStylesConfig(styles) {
69
76
  if (styles.listStyleTypes) {
70
77
  normalizedConfig.listStyleTypes = styles.listStyleTypes;
71
78
  }
79
+ else {
80
+ normalizedConfig.listStyleTypes = pick(normalizedConfig.listStyleTypes, normalizedConfig.listTypes);
81
+ }
72
82
  }
73
83
  return normalizedConfig;
74
84
  }
@@ -19,7 +19,8 @@ const LIST_STYLE_TYPES = [
19
19
  { listStyle: 'lower-alpha', typeAttribute: 'a', listType: 'numbered' },
20
20
  { listStyle: 'upper-alpha', typeAttribute: 'A', listType: 'numbered' },
21
21
  { listStyle: 'lower-latin', typeAttribute: 'a', listType: 'numbered' },
22
- { listStyle: 'upper-latin', typeAttribute: 'A', listType: 'numbered' }
22
+ { listStyle: 'upper-latin', typeAttribute: 'A', listType: 'numbered' },
23
+ { listStyle: 'arabic-indic', typeAttribute: null, listType: 'numbered' }
23
24
  ];
24
25
  for (const { listStyle, typeAttribute, listType } of LIST_STYLE_TYPES) {
25
26
  LIST_STYLE_TO_LIST_TYPE[listStyle] = listType;