@ckeditor/ckeditor5-restricted-editing 0.0.0-internal-20241017.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 (313) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/LICENSE.md +17 -0
  3. package/README.md +26 -0
  4. package/build/restricted-editing.js +5 -0
  5. package/build/translations/ar.js +1 -0
  6. package/build/translations/az.js +1 -0
  7. package/build/translations/bg.js +1 -0
  8. package/build/translations/bn.js +1 -0
  9. package/build/translations/ca.js +1 -0
  10. package/build/translations/cs.js +1 -0
  11. package/build/translations/da.js +1 -0
  12. package/build/translations/de-ch.js +1 -0
  13. package/build/translations/de.js +1 -0
  14. package/build/translations/el.js +1 -0
  15. package/build/translations/en-au.js +1 -0
  16. package/build/translations/en-gb.js +1 -0
  17. package/build/translations/es.js +1 -0
  18. package/build/translations/et.js +1 -0
  19. package/build/translations/fa.js +1 -0
  20. package/build/translations/fi.js +1 -0
  21. package/build/translations/fr.js +1 -0
  22. package/build/translations/gl.js +1 -0
  23. package/build/translations/he.js +1 -0
  24. package/build/translations/hi.js +1 -0
  25. package/build/translations/hr.js +1 -0
  26. package/build/translations/hu.js +1 -0
  27. package/build/translations/id.js +1 -0
  28. package/build/translations/it.js +1 -0
  29. package/build/translations/ja.js +1 -0
  30. package/build/translations/ko.js +1 -0
  31. package/build/translations/ku.js +1 -0
  32. package/build/translations/lt.js +1 -0
  33. package/build/translations/lv.js +1 -0
  34. package/build/translations/ms.js +1 -0
  35. package/build/translations/nl.js +1 -0
  36. package/build/translations/no.js +1 -0
  37. package/build/translations/pl.js +1 -0
  38. package/build/translations/pt-br.js +1 -0
  39. package/build/translations/pt.js +1 -0
  40. package/build/translations/ro.js +1 -0
  41. package/build/translations/ru.js +1 -0
  42. package/build/translations/sk.js +1 -0
  43. package/build/translations/sq.js +1 -0
  44. package/build/translations/sr-latn.js +1 -0
  45. package/build/translations/sr.js +1 -0
  46. package/build/translations/sv.js +1 -0
  47. package/build/translations/th.js +1 -0
  48. package/build/translations/tk.js +1 -0
  49. package/build/translations/tr.js +1 -0
  50. package/build/translations/uk.js +1 -0
  51. package/build/translations/ur.js +1 -0
  52. package/build/translations/uz.js +1 -0
  53. package/build/translations/vi.js +1 -0
  54. package/build/translations/zh-cn.js +1 -0
  55. package/build/translations/zh.js +1 -0
  56. package/ckeditor5-metadata.json +44 -0
  57. package/dist/augmentation.d.ts +33 -0
  58. package/dist/index-content.css +4 -0
  59. package/dist/index-editor.css +4 -0
  60. package/dist/index.css +4 -0
  61. package/dist/index.d.ts +21 -0
  62. package/dist/index.js +1058 -0
  63. package/dist/index.js.map +1 -0
  64. package/dist/restrictededitingconfig.d.ts +64 -0
  65. package/dist/restrictededitingexceptioncommand.d.ts +34 -0
  66. package/dist/restrictededitingmode/converters.d.ts +43 -0
  67. package/dist/restrictededitingmode/utils.d.ts +34 -0
  68. package/dist/restrictededitingmode.d.ts +37 -0
  69. package/dist/restrictededitingmodeediting.d.ts +91 -0
  70. package/dist/restrictededitingmodenavigationcommand.d.ts +46 -0
  71. package/dist/restrictededitingmodeui.d.ts +50 -0
  72. package/dist/standardeditingmode.d.ts +34 -0
  73. package/dist/standardeditingmodeediting.d.ts +33 -0
  74. package/dist/standardeditingmodeui.d.ts +35 -0
  75. package/dist/translations/ar.d.ts +8 -0
  76. package/dist/translations/ar.js +5 -0
  77. package/dist/translations/ar.umd.js +11 -0
  78. package/dist/translations/az.d.ts +8 -0
  79. package/dist/translations/az.js +5 -0
  80. package/dist/translations/az.umd.js +11 -0
  81. package/dist/translations/bg.d.ts +8 -0
  82. package/dist/translations/bg.js +5 -0
  83. package/dist/translations/bg.umd.js +11 -0
  84. package/dist/translations/bn.d.ts +8 -0
  85. package/dist/translations/bn.js +5 -0
  86. package/dist/translations/bn.umd.js +11 -0
  87. package/dist/translations/ca.d.ts +8 -0
  88. package/dist/translations/ca.js +5 -0
  89. package/dist/translations/ca.umd.js +11 -0
  90. package/dist/translations/cs.d.ts +8 -0
  91. package/dist/translations/cs.js +5 -0
  92. package/dist/translations/cs.umd.js +11 -0
  93. package/dist/translations/da.d.ts +8 -0
  94. package/dist/translations/da.js +5 -0
  95. package/dist/translations/da.umd.js +11 -0
  96. package/dist/translations/de-ch.d.ts +8 -0
  97. package/dist/translations/de-ch.js +5 -0
  98. package/dist/translations/de-ch.umd.js +11 -0
  99. package/dist/translations/de.d.ts +8 -0
  100. package/dist/translations/de.js +5 -0
  101. package/dist/translations/de.umd.js +11 -0
  102. package/dist/translations/el.d.ts +8 -0
  103. package/dist/translations/el.js +5 -0
  104. package/dist/translations/el.umd.js +11 -0
  105. package/dist/translations/en-au.d.ts +8 -0
  106. package/dist/translations/en-au.js +5 -0
  107. package/dist/translations/en-au.umd.js +11 -0
  108. package/dist/translations/en-gb.d.ts +8 -0
  109. package/dist/translations/en-gb.js +5 -0
  110. package/dist/translations/en-gb.umd.js +11 -0
  111. package/dist/translations/en.d.ts +8 -0
  112. package/dist/translations/en.js +5 -0
  113. package/dist/translations/en.umd.js +11 -0
  114. package/dist/translations/es.d.ts +8 -0
  115. package/dist/translations/es.js +5 -0
  116. package/dist/translations/es.umd.js +11 -0
  117. package/dist/translations/et.d.ts +8 -0
  118. package/dist/translations/et.js +5 -0
  119. package/dist/translations/et.umd.js +11 -0
  120. package/dist/translations/fa.d.ts +8 -0
  121. package/dist/translations/fa.js +5 -0
  122. package/dist/translations/fa.umd.js +11 -0
  123. package/dist/translations/fi.d.ts +8 -0
  124. package/dist/translations/fi.js +5 -0
  125. package/dist/translations/fi.umd.js +11 -0
  126. package/dist/translations/fr.d.ts +8 -0
  127. package/dist/translations/fr.js +5 -0
  128. package/dist/translations/fr.umd.js +11 -0
  129. package/dist/translations/gl.d.ts +8 -0
  130. package/dist/translations/gl.js +5 -0
  131. package/dist/translations/gl.umd.js +11 -0
  132. package/dist/translations/he.d.ts +8 -0
  133. package/dist/translations/he.js +5 -0
  134. package/dist/translations/he.umd.js +11 -0
  135. package/dist/translations/hi.d.ts +8 -0
  136. package/dist/translations/hi.js +5 -0
  137. package/dist/translations/hi.umd.js +11 -0
  138. package/dist/translations/hr.d.ts +8 -0
  139. package/dist/translations/hr.js +5 -0
  140. package/dist/translations/hr.umd.js +11 -0
  141. package/dist/translations/hu.d.ts +8 -0
  142. package/dist/translations/hu.js +5 -0
  143. package/dist/translations/hu.umd.js +11 -0
  144. package/dist/translations/id.d.ts +8 -0
  145. package/dist/translations/id.js +5 -0
  146. package/dist/translations/id.umd.js +11 -0
  147. package/dist/translations/it.d.ts +8 -0
  148. package/dist/translations/it.js +5 -0
  149. package/dist/translations/it.umd.js +11 -0
  150. package/dist/translations/ja.d.ts +8 -0
  151. package/dist/translations/ja.js +5 -0
  152. package/dist/translations/ja.umd.js +11 -0
  153. package/dist/translations/ko.d.ts +8 -0
  154. package/dist/translations/ko.js +5 -0
  155. package/dist/translations/ko.umd.js +11 -0
  156. package/dist/translations/ku.d.ts +8 -0
  157. package/dist/translations/ku.js +5 -0
  158. package/dist/translations/ku.umd.js +11 -0
  159. package/dist/translations/lt.d.ts +8 -0
  160. package/dist/translations/lt.js +5 -0
  161. package/dist/translations/lt.umd.js +11 -0
  162. package/dist/translations/lv.d.ts +8 -0
  163. package/dist/translations/lv.js +5 -0
  164. package/dist/translations/lv.umd.js +11 -0
  165. package/dist/translations/ms.d.ts +8 -0
  166. package/dist/translations/ms.js +5 -0
  167. package/dist/translations/ms.umd.js +11 -0
  168. package/dist/translations/nl.d.ts +8 -0
  169. package/dist/translations/nl.js +5 -0
  170. package/dist/translations/nl.umd.js +11 -0
  171. package/dist/translations/no.d.ts +8 -0
  172. package/dist/translations/no.js +5 -0
  173. package/dist/translations/no.umd.js +11 -0
  174. package/dist/translations/pl.d.ts +8 -0
  175. package/dist/translations/pl.js +5 -0
  176. package/dist/translations/pl.umd.js +11 -0
  177. package/dist/translations/pt-br.d.ts +8 -0
  178. package/dist/translations/pt-br.js +5 -0
  179. package/dist/translations/pt-br.umd.js +11 -0
  180. package/dist/translations/pt.d.ts +8 -0
  181. package/dist/translations/pt.js +5 -0
  182. package/dist/translations/pt.umd.js +11 -0
  183. package/dist/translations/ro.d.ts +8 -0
  184. package/dist/translations/ro.js +5 -0
  185. package/dist/translations/ro.umd.js +11 -0
  186. package/dist/translations/ru.d.ts +8 -0
  187. package/dist/translations/ru.js +5 -0
  188. package/dist/translations/ru.umd.js +11 -0
  189. package/dist/translations/sk.d.ts +8 -0
  190. package/dist/translations/sk.js +5 -0
  191. package/dist/translations/sk.umd.js +11 -0
  192. package/dist/translations/sq.d.ts +8 -0
  193. package/dist/translations/sq.js +5 -0
  194. package/dist/translations/sq.umd.js +11 -0
  195. package/dist/translations/sr-latn.d.ts +8 -0
  196. package/dist/translations/sr-latn.js +5 -0
  197. package/dist/translations/sr-latn.umd.js +11 -0
  198. package/dist/translations/sr.d.ts +8 -0
  199. package/dist/translations/sr.js +5 -0
  200. package/dist/translations/sr.umd.js +11 -0
  201. package/dist/translations/sv.d.ts +8 -0
  202. package/dist/translations/sv.js +5 -0
  203. package/dist/translations/sv.umd.js +11 -0
  204. package/dist/translations/th.d.ts +8 -0
  205. package/dist/translations/th.js +5 -0
  206. package/dist/translations/th.umd.js +11 -0
  207. package/dist/translations/tk.d.ts +8 -0
  208. package/dist/translations/tk.js +5 -0
  209. package/dist/translations/tk.umd.js +11 -0
  210. package/dist/translations/tr.d.ts +8 -0
  211. package/dist/translations/tr.js +5 -0
  212. package/dist/translations/tr.umd.js +11 -0
  213. package/dist/translations/uk.d.ts +8 -0
  214. package/dist/translations/uk.js +5 -0
  215. package/dist/translations/uk.umd.js +11 -0
  216. package/dist/translations/ur.d.ts +8 -0
  217. package/dist/translations/ur.js +5 -0
  218. package/dist/translations/ur.umd.js +11 -0
  219. package/dist/translations/uz.d.ts +8 -0
  220. package/dist/translations/uz.js +5 -0
  221. package/dist/translations/uz.umd.js +11 -0
  222. package/dist/translations/vi.d.ts +8 -0
  223. package/dist/translations/vi.js +5 -0
  224. package/dist/translations/vi.umd.js +11 -0
  225. package/dist/translations/zh-cn.d.ts +8 -0
  226. package/dist/translations/zh-cn.js +5 -0
  227. package/dist/translations/zh-cn.umd.js +11 -0
  228. package/dist/translations/zh.d.ts +8 -0
  229. package/dist/translations/zh.js +5 -0
  230. package/dist/translations/zh.umd.js +11 -0
  231. package/lang/contexts.json +7 -0
  232. package/lang/translations/ar.po +38 -0
  233. package/lang/translations/az.po +38 -0
  234. package/lang/translations/bg.po +38 -0
  235. package/lang/translations/bn.po +38 -0
  236. package/lang/translations/ca.po +38 -0
  237. package/lang/translations/cs.po +38 -0
  238. package/lang/translations/da.po +38 -0
  239. package/lang/translations/de-ch.po +38 -0
  240. package/lang/translations/de.po +38 -0
  241. package/lang/translations/el.po +38 -0
  242. package/lang/translations/en-au.po +38 -0
  243. package/lang/translations/en-gb.po +38 -0
  244. package/lang/translations/en.po +38 -0
  245. package/lang/translations/es.po +38 -0
  246. package/lang/translations/et.po +38 -0
  247. package/lang/translations/fa.po +38 -0
  248. package/lang/translations/fi.po +38 -0
  249. package/lang/translations/fr.po +38 -0
  250. package/lang/translations/gl.po +38 -0
  251. package/lang/translations/he.po +38 -0
  252. package/lang/translations/hi.po +38 -0
  253. package/lang/translations/hr.po +38 -0
  254. package/lang/translations/hu.po +38 -0
  255. package/lang/translations/id.po +38 -0
  256. package/lang/translations/it.po +38 -0
  257. package/lang/translations/ja.po +38 -0
  258. package/lang/translations/ko.po +38 -0
  259. package/lang/translations/ku.po +38 -0
  260. package/lang/translations/lt.po +38 -0
  261. package/lang/translations/lv.po +38 -0
  262. package/lang/translations/ms.po +38 -0
  263. package/lang/translations/nl.po +38 -0
  264. package/lang/translations/no.po +38 -0
  265. package/lang/translations/pl.po +38 -0
  266. package/lang/translations/pt-br.po +38 -0
  267. package/lang/translations/pt.po +38 -0
  268. package/lang/translations/ro.po +38 -0
  269. package/lang/translations/ru.po +38 -0
  270. package/lang/translations/sk.po +38 -0
  271. package/lang/translations/sq.po +38 -0
  272. package/lang/translations/sr-latn.po +38 -0
  273. package/lang/translations/sr.po +38 -0
  274. package/lang/translations/sv.po +38 -0
  275. package/lang/translations/th.po +38 -0
  276. package/lang/translations/tk.po +38 -0
  277. package/lang/translations/tr.po +38 -0
  278. package/lang/translations/uk.po +38 -0
  279. package/lang/translations/ur.po +38 -0
  280. package/lang/translations/uz.po +38 -0
  281. package/lang/translations/vi.po +38 -0
  282. package/lang/translations/zh-cn.po +38 -0
  283. package/lang/translations/zh.po +38 -0
  284. package/package.json +41 -0
  285. package/src/augmentation.d.ts +29 -0
  286. package/src/augmentation.js +5 -0
  287. package/src/index.d.ts +17 -0
  288. package/src/index.js +14 -0
  289. package/src/restrictededitingconfig.d.ts +60 -0
  290. package/src/restrictededitingconfig.js +5 -0
  291. package/src/restrictededitingexceptioncommand.d.ts +30 -0
  292. package/src/restrictededitingexceptioncommand.js +61 -0
  293. package/src/restrictededitingmode/converters.d.ts +39 -0
  294. package/src/restrictededitingmode/converters.js +143 -0
  295. package/src/restrictededitingmode/utils.d.ts +30 -0
  296. package/src/restrictededitingmode/utils.js +50 -0
  297. package/src/restrictededitingmode.d.ts +33 -0
  298. package/src/restrictededitingmode.js +39 -0
  299. package/src/restrictededitingmodeediting.d.ts +87 -0
  300. package/src/restrictededitingmodeediting.js +430 -0
  301. package/src/restrictededitingmodenavigationcommand.d.ts +42 -0
  302. package/src/restrictededitingmodenavigationcommand.js +94 -0
  303. package/src/restrictededitingmodeui.d.ts +46 -0
  304. package/src/restrictededitingmodeui.js +139 -0
  305. package/src/standardeditingmode.d.ts +30 -0
  306. package/src/standardeditingmode.js +36 -0
  307. package/src/standardeditingmodeediting.d.ts +29 -0
  308. package/src/standardeditingmodeediting.js +59 -0
  309. package/src/standardeditingmodeui.d.ts +31 -0
  310. package/src/standardeditingmodeui.js +67 -0
  311. package/theme/icons/contentlock.svg +1 -0
  312. package/theme/icons/contentunlock.svg +1 -0
  313. package/theme/restrictedediting.css +10 -0
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Thai (https://app.transifex.com/ckeditor/teams/11143/th/)\n"
16
+ "Language: th\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "ปิดใช้งานการแก้ไข"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "เปิดใช้งานการแก้ไข"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "พื้นที่ซึ่งสามารถแก้ไขได้ก่อนหน้านี้"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "พื้นที่ซึ่งสามารถแก้ไขได้ถัดไป"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "นำทางไปยังพื้นที่ซึ่งสามารถแก้ไขได้"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Turkmen (https://app.transifex.com/ckeditor/teams/11143/tk/)\n"
16
+ "Language: tk\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "Redaktirlemegi öçüriň"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "Redaktirlemegi işjeňleşdiriň"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "Öňki redaktirläp bolýan sebit"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "Indiki redaktirläp bolýan sebit"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "Düzedip bolýan sebitlere geçiň"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Turkish (https://app.transifex.com/ckeditor/teams/11143/tr/)\n"
16
+ "Language: tr\n"
17
+ "Plural-Forms: nplurals=2; plural=(n > 1);\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "Düzenlemeyi devre dışı bırak"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "Düzenlemeyi etkinleştir"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "Önceki düzenlenebilir alan"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "Sonraki düzenlenebilir alan"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "Düzenlenebilir alanlara git"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Ukrainian (https://app.transifex.com/ckeditor/teams/11143/uk/)\n"
16
+ "Language: uk\n"
17
+ "Plural-Forms: nplurals=4; plural=(n % 1 == 0 && n % 10 == 1 && n % 100 != 11 ? 0 : n % 1 == 0 && n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 12 || n % 100 > 14) ? 1 : n % 1 == 0 && (n % 10 ==0 || (n % 10 >=5 && n % 10 <=9) || (n % 100 >=11 && n % 100 <=14 )) ? 2: 3);\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "Вимкнути редагування"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "Увімкнути редагування"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "Попередня область редагування"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "Наступна область редагування"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "Навігація по областях редагування"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Urdu (https://app.transifex.com/ckeditor/teams/11143/ur/)\n"
16
+ "Language: ur\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "تدویں غیر فعال کریں"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "تدوین فعال کریں"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr ""
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr ""
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr ""
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Uzbek (https://app.transifex.com/ckeditor/teams/11143/uz/)\n"
16
+ "Language: uz\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "Tahrirlashni o‘chirib qo‘yish"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "Tahrirlashga ruxsat berish"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "Avvalgi tahrirlanadigan hudud"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "Keyingi tahrirlanadigan hudud"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "Tahrirlanadigan hududlar boʻylab navigatsiya"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Vietnamese (https://app.transifex.com/ckeditor/teams/11143/vi/)\n"
16
+ "Language: vi\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "Tắt tính năng chỉnh sửa"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "Bật tính năng chỉnh sửa"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "Vùng có thể chỉnh sửa trước đó"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "Vùng có thể chỉnh sửa tiếp theo"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "Di chuyển giữa các vùng có thể chỉnh sửa"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Chinese (China) (https://app.transifex.com/ckeditor/teams/11143/zh_CN/)\n"
16
+ "Language: zh_CN\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "禁用编辑"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "允许编辑"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "上一个可编辑区域"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "下一个可编辑区域"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "导航至可编辑区域"
@@ -0,0 +1,38 @@
1
+ # Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
2
+ #
3
+ # !!! IMPORTANT !!!
4
+ #
5
+ # Before you edit this file, please keep in mind that contributing to the project
6
+ # translations is possible ONLY via the Transifex online service.
7
+ #
8
+ # To submit your translations, visit https://www.transifex.com/ckeditor/ckeditor5.
9
+ #
10
+ # To learn more, check out the official contributor's guide:
11
+ # https://ckeditor.com/docs/ckeditor5/latest/framework/guides/contributing/contributing.html
12
+ #
13
+ msgid ""
14
+ msgstr ""
15
+ "Language-Team: Chinese (Taiwan) (https://app.transifex.com/ckeditor/teams/11143/zh_TW/)\n"
16
+ "Language: zh_TW\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "Content-Type: text/plain; charset=UTF-8\n"
19
+
20
+ msgctxt "A label of the button indicating that using this button will make a selected text non–editable."
21
+ msgid "Disable editing"
22
+ msgstr "停用編輯"
23
+
24
+ msgctxt "A label of the button indicating that using this button will make a selected text editable."
25
+ msgid "Enable editing"
26
+ msgstr "啟用編輯"
27
+
28
+ msgctxt "A label of the button that moves selection to the previous editable region in the content."
29
+ msgid "Previous editable region"
30
+ msgstr "上一個可編輯區域"
31
+
32
+ msgctxt "A label of the button that moves selection to the next editable region in the content."
33
+ msgid "Next editable region"
34
+ msgstr "下一個可編輯區域"
35
+
36
+ msgctxt "A label of the dropdown that provides controls to navigate editable regions in the content."
37
+ msgid "Navigate editable regions"
38
+ msgstr "編輯區域導航"
package/package.json ADDED
@@ -0,0 +1,41 @@
1
+ {
2
+ "name": "@ckeditor/ckeditor5-restricted-editing",
3
+ "version": "0.0.0-internal-20241017.0",
4
+ "description": "Restricted editing feature for CKEditor 5 editors.",
5
+ "keywords": [
6
+ "ckeditor",
7
+ "ckeditor5",
8
+ "ckeditor 5",
9
+ "ckeditor5-lib",
10
+ "ckeditor5-dll"
11
+ ],
12
+ "type": "module",
13
+ "main": "src/index.js",
14
+ "dependencies": {
15
+ "@ckeditor/ckeditor5-core": "0.0.0-internal-20241017.0",
16
+ "@ckeditor/ckeditor5-engine": "0.0.0-internal-20241017.0",
17
+ "@ckeditor/ckeditor5-ui": "0.0.0-internal-20241017.0",
18
+ "@ckeditor/ckeditor5-utils": "0.0.0-internal-20241017.0",
19
+ "ckeditor5": "0.0.0-internal-20241017.0"
20
+ },
21
+ "author": "CKSource (http://cksource.com/)",
22
+ "license": "GPL-2.0-or-later",
23
+ "homepage": "https://ckeditor.com/ckeditor-5",
24
+ "bugs": "https://github.com/ckeditor/ckeditor5/issues",
25
+ "repository": {
26
+ "type": "git",
27
+ "url": "https://github.com/ckeditor/ckeditor5.git",
28
+ "directory": "packages/ckeditor5-restricted-editing"
29
+ },
30
+ "files": [
31
+ "dist",
32
+ "lang",
33
+ "src/**/*.js",
34
+ "src/**/*.d.ts",
35
+ "theme",
36
+ "build",
37
+ "ckeditor5-metadata.json",
38
+ "CHANGELOG.md"
39
+ ],
40
+ "types": "src/index.d.ts"
41
+ }
@@ -0,0 +1,29 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ import type { RestrictedEditingMode, RestrictedEditingModeEditing, RestrictedEditingModeUI, StandardEditingMode, StandardEditingModeEditing, StandardEditingModeUI, RestrictedEditingConfig, RestrictedEditingExceptionCommand, RestrictedEditingModeNavigationCommand } from './index.js';
6
+ declare module '@ckeditor/ckeditor5-core' {
7
+ interface PluginsMap {
8
+ [RestrictedEditingMode.pluginName]: RestrictedEditingMode;
9
+ [RestrictedEditingModeEditing.pluginName]: RestrictedEditingModeEditing;
10
+ [RestrictedEditingModeUI.pluginName]: RestrictedEditingModeUI;
11
+ [StandardEditingMode.pluginName]: StandardEditingMode;
12
+ [StandardEditingModeEditing.pluginName]: StandardEditingModeEditing;
13
+ [StandardEditingModeUI.pluginName]: StandardEditingModeUI;
14
+ }
15
+ interface CommandsMap {
16
+ restrictedEditingException: RestrictedEditingExceptionCommand;
17
+ goToPreviousRestrictedEditingException: RestrictedEditingModeNavigationCommand;
18
+ goToNextRestrictedEditingException: RestrictedEditingModeNavigationCommand;
19
+ }
20
+ interface EditorConfig {
21
+ /**
22
+ * The configuration of the restricted editing mode feature. Introduced by the
23
+ * {@link module:restricted-editing/restrictededitingmode~RestrictedEditingMode} feature.
24
+ *
25
+ * Read more in {@link module:restricted-editing/restrictededitingconfig~RestrictedEditingConfig}.
26
+ */
27
+ restrictedEditing?: RestrictedEditingConfig;
28
+ }
29
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ export {};
package/src/index.d.ts ADDED
@@ -0,0 +1,17 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module restricted-editing
7
+ */
8
+ export { default as RestrictedEditingMode } from './restrictededitingmode.js';
9
+ export { default as RestrictedEditingModeEditing } from './restrictededitingmodeediting.js';
10
+ export { default as RestrictedEditingModeUI } from './restrictededitingmodeui.js';
11
+ export { default as StandardEditingMode } from './standardeditingmode.js';
12
+ export { default as StandardEditingModeEditing } from './standardeditingmodeediting.js';
13
+ export { default as StandardEditingModeUI } from './standardeditingmodeui.js';
14
+ export type { RestrictedEditingConfig } from './restrictededitingconfig.js';
15
+ export type { default as RestrictedEditingExceptionCommand } from './restrictededitingexceptioncommand.js';
16
+ export type { default as RestrictedEditingModeNavigationCommand } from './restrictededitingmodenavigationcommand.js';
17
+ import './augmentation.js';
package/src/index.js ADDED
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module restricted-editing
7
+ */
8
+ export { default as RestrictedEditingMode } from './restrictededitingmode.js';
9
+ export { default as RestrictedEditingModeEditing } from './restrictededitingmodeediting.js';
10
+ export { default as RestrictedEditingModeUI } from './restrictededitingmodeui.js';
11
+ export { default as StandardEditingMode } from './standardeditingmode.js';
12
+ export { default as StandardEditingModeEditing } from './standardeditingmodeediting.js';
13
+ export { default as StandardEditingModeUI } from './standardeditingmodeui.js';
14
+ import './augmentation.js';
@@ -0,0 +1,60 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module restricted-editing/restrictededitingconfig
7
+ */
8
+ /**
9
+ * The configuration of the restricted editing mode feature.
10
+ * The option is used by the {@link module:restricted-editing/restrictededitingmode~RestrictedEditingMode} feature.
11
+ *
12
+ * ```ts
13
+ * ClassicEditor
14
+ * .create( {
15
+ * restrictedEditing: {
16
+ * allowedCommands: [ 'bold', 'link', 'unlink' ],
17
+ * allowedAttributes: [ 'bold', 'linkHref' ]
18
+ * }
19
+ * } )
20
+ * .then( ... )
21
+ * .catch( ... );
22
+ * ```
23
+ *
24
+ * See {@link module:core/editor/editorconfig~EditorConfig all editor options}.
25
+ */
26
+ export interface RestrictedEditingConfig {
27
+ /**
28
+ * The command names allowed in non-restricted areas of the content.
29
+ *
30
+ * Defines which feature commands should be enabled in the restricted editing mode. The commands used for typing and deleting text
31
+ * (`'input'`, `'delete'` and `'deleteForward'`) are allowed by the feature inside non-restricted regions and do not need to be defined.
32
+ *
33
+ * **Note**: The restricted editing mode always allows to use the restricted mode navigation commands as well as `'undo'` and `'redo'`
34
+ * commands.
35
+ *
36
+ * The default value is:
37
+ *
38
+ * ```ts
39
+ * const restrictedEditingConfig = {
40
+ * allowedCommands: [ 'bold', 'italic', 'link', 'unlink' ]
41
+ * };
42
+ * ```
43
+ *
44
+ * To make a command always enabled (also outside non-restricted areas) use
45
+ * {@link module:restricted-editing/restrictededitingmodeediting~RestrictedEditingModeEditing#enableCommand} method.
46
+ */
47
+ allowedCommands: Array<string>;
48
+ /**
49
+ * The text attribute names allowed when pasting content ot non-restricted areas.
50
+ *
51
+ * The default value is:
52
+ *
53
+ * ```ts
54
+ * const restrictedEditingConfig = {
55
+ * allowedAttributes: [ 'bold', 'italic', 'linkHref' ]
56
+ * };
57
+ * ```
58
+ */
59
+ allowedAttributes: Array<string>;
60
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ export {};
@@ -0,0 +1,30 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module restricted-editing/restrictededitingexceptioncommand
7
+ */
8
+ import { Command } from 'ckeditor5/src/core.js';
9
+ /**
10
+ * The command that toggles exceptions from the restricted editing on text.
11
+ */
12
+ export default class RestrictedEditingExceptionCommand extends Command {
13
+ /**
14
+ * A flag indicating whether the command is active
15
+ *
16
+ * @readonly
17
+ */
18
+ value: boolean;
19
+ /**
20
+ * @inheritDoc
21
+ */
22
+ refresh(): void;
23
+ /**
24
+ * @inheritDoc
25
+ */
26
+ execute(options?: RestrictedEditingExceptionCommandParams): void;
27
+ }
28
+ export interface RestrictedEditingExceptionCommandParams {
29
+ forceValue?: unknown;
30
+ }
@@ -0,0 +1,61 @@
1
+ /**
2
+ * @license Copyright (c) 2003-2024, CKSource Holding sp. z o.o. All rights reserved.
3
+ * For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
4
+ */
5
+ /**
6
+ * @module restricted-editing/restrictededitingexceptioncommand
7
+ */
8
+ import { Command } from 'ckeditor5/src/core.js';
9
+ /**
10
+ * The command that toggles exceptions from the restricted editing on text.
11
+ */
12
+ export default class RestrictedEditingExceptionCommand extends Command {
13
+ /**
14
+ * @inheritDoc
15
+ */
16
+ refresh() {
17
+ const model = this.editor.model;
18
+ const doc = model.document;
19
+ this.value = !!doc.selection.getAttribute('restrictedEditingException');
20
+ this.isEnabled = model.schema.checkAttributeInSelection(doc.selection, 'restrictedEditingException');
21
+ }
22
+ /**
23
+ * @inheritDoc
24
+ */
25
+ execute(options = {}) {
26
+ const model = this.editor.model;
27
+ const document = model.document;
28
+ const selection = document.selection;
29
+ const valueToSet = (options.forceValue === undefined) ? !this.value : options.forceValue;
30
+ model.change(writer => {
31
+ const ranges = model.schema.getValidRanges(selection.getRanges(), 'restrictedEditingException');
32
+ if (selection.isCollapsed) {
33
+ if (valueToSet) {
34
+ writer.setSelectionAttribute('restrictedEditingException', valueToSet);
35
+ }
36
+ else {
37
+ const isSameException = (value) => {
38
+ return value.item.getAttribute('restrictedEditingException') === this.value;
39
+ };
40
+ const focus = selection.focus;
41
+ const exceptionStart = focus.getLastMatchingPosition(isSameException, { direction: 'backward' });
42
+ const exceptionEnd = focus.getLastMatchingPosition(isSameException);
43
+ writer.removeSelectionAttribute('restrictedEditingException');
44
+ if (!(focus.isEqual(exceptionStart) || focus.isEqual(exceptionEnd))) {
45
+ writer.removeAttribute('restrictedEditingException', writer.createRange(exceptionStart, exceptionEnd));
46
+ }
47
+ }
48
+ }
49
+ else {
50
+ for (const range of ranges) {
51
+ if (valueToSet) {
52
+ writer.setAttribute('restrictedEditingException', valueToSet, range);
53
+ }
54
+ else {
55
+ writer.removeAttribute('restrictedEditingException', range);
56
+ }
57
+ }
58
+ }
59
+ });
60
+ }
61
+ }