phcthemes_admin_panel_pack 4.1.0 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (852) hide show
  1. checksums.yaml +4 -4
  2. data/MIT-LICENSE +20 -20
  3. data/README.md +1 -1
  4. data/Rakefile +8 -8
  5. data/app/assets/config/phcthemes_admin_panel_pack_manifest.js +7 -6
  6. data/app/assets/javascripts/coloradmin/app.min.js +1 -0
  7. data/app/assets/javascripts/coloradmin/phcthemes_admin_panel_pack_coloradmin.js +4 -0
  8. data/app/assets/javascripts/coloradmin/vendor.min.js +12 -0
  9. data/app/assets/javascripts/{phcthemes_admin_panel_pack_metronic.js → metronic/phcthemes_admin_panel_pack_metronic.js} +0 -0
  10. data/app/assets/stylesheets/coloradmin/apple/phcthemes_admin_panel_pack_coloradmin.scss +8 -0
  11. data/app/assets/stylesheets/coloradmin/default/phcthemes_admin_panel_pack_coloradmin.scss +8 -0
  12. data/app/assets/stylesheets/coloradmin/facebook/phcthemes_admin_panel_pack_coloradmin.scss +8 -0
  13. data/app/assets/stylesheets/coloradmin/google/phcthemes_admin_panel_pack_coloradmin.scss +8 -0
  14. data/app/assets/stylesheets/coloradmin/material/phcthemes_admin_panel_pack_coloradmin.scss +8 -0
  15. data/app/assets/stylesheets/coloradmin/theme/css/apple/app-rtl.min.css +9 -0
  16. data/app/assets/stylesheets/coloradmin/theme/css/apple/app.min.css +9 -0
  17. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/bg-login-dark-mode.png +0 -0
  18. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/bg-login.png +0 -0
  19. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/coming-soon.jpg +0 -0
  20. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/cover-pattern.png +0 -0
  21. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/cover-sidebar-user.jpg +0 -0
  22. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/cover-sidebar.jpg +0 -0
  23. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/error-page-pattern.png +0 -0
  24. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/profile-cover.jpg +0 -0
  25. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.1.png +0 -0
  26. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.2.png +0 -0
  27. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.3.png +0 -0
  28. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.4.png +0 -0
  29. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.5.png +0 -0
  30. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.6.png +0 -0
  31. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.7.png +0 -0
  32. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.8.png +0 -0
  33. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/black-0.9.png +0 -0
  34. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.1.png +0 -0
  35. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.2.png +0 -0
  36. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.3.png +0 -0
  37. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.4.png +0 -0
  38. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.5.png +0 -0
  39. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.6.png +0 -0
  40. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.7.png +0 -0
  41. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.8.png +0 -0
  42. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.9.png +0 -0
  43. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/transparent/white-0.98.png +0 -0
  44. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/ui-icons_444444_256x240.png +0 -0
  45. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/ui-icons_555555_256x240.png +0 -0
  46. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/ui-icons_777620_256x240.png +0 -0
  47. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/ui-icons_777777_256x240.png +0 -0
  48. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/ui-icons_cc0000_256x240.png +0 -0
  49. data/app/assets/stylesheets/coloradmin/theme/css/apple/images/ui-icons_ffffff_256x240.png +0 -0
  50. data/app/assets/stylesheets/coloradmin/theme/css/color_admin_vendor.min.css +15 -0
  51. data/app/assets/stylesheets/coloradmin/theme/css/default/app-rtl.min.css +9 -0
  52. data/app/assets/stylesheets/coloradmin/theme/css/default/app.min.css +9 -0
  53. data/app/assets/stylesheets/coloradmin/theme/css/default/images/bg-login-dark-mode.png +0 -0
  54. data/app/assets/stylesheets/coloradmin/theme/css/default/images/bg-login.png +0 -0
  55. data/app/assets/stylesheets/coloradmin/theme/css/default/images/coming-soon.jpg +0 -0
  56. data/app/assets/stylesheets/coloradmin/theme/css/default/images/cover-pattern.png +0 -0
  57. data/app/assets/stylesheets/coloradmin/theme/css/default/images/cover-sidebar-user.jpg +0 -0
  58. data/app/assets/stylesheets/coloradmin/theme/css/default/images/cover-sidebar.jpg +0 -0
  59. data/app/assets/stylesheets/coloradmin/theme/css/default/images/error-page-pattern.png +0 -0
  60. data/app/assets/stylesheets/coloradmin/theme/css/default/images/profile-cover.jpg +0 -0
  61. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.1.png +0 -0
  62. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.2.png +0 -0
  63. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.3.png +0 -0
  64. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.4.png +0 -0
  65. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.5.png +0 -0
  66. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.6.png +0 -0
  67. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.7.png +0 -0
  68. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.8.png +0 -0
  69. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/black-0.9.png +0 -0
  70. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.1.png +0 -0
  71. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.2.png +0 -0
  72. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.3.png +0 -0
  73. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.4.png +0 -0
  74. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.5.png +0 -0
  75. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.6.png +0 -0
  76. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.7.png +0 -0
  77. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.8.png +0 -0
  78. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.9.png +0 -0
  79. data/app/assets/stylesheets/coloradmin/theme/css/default/images/transparent/white-0.98.png +0 -0
  80. data/app/assets/stylesheets/coloradmin/theme/css/default/images/ui-icons_444444_256x240.png +0 -0
  81. data/app/assets/stylesheets/coloradmin/theme/css/default/images/ui-icons_555555_256x240.png +0 -0
  82. data/app/assets/stylesheets/coloradmin/theme/css/default/images/ui-icons_777620_256x240.png +0 -0
  83. data/app/assets/stylesheets/coloradmin/theme/css/default/images/ui-icons_777777_256x240.png +0 -0
  84. data/app/assets/stylesheets/coloradmin/theme/css/default/images/ui-icons_cc0000_256x240.png +0 -0
  85. data/app/assets/stylesheets/coloradmin/theme/css/default/images/ui-icons_ffffff_256x240.png +0 -0
  86. data/app/assets/stylesheets/coloradmin/theme/css/facebook/app-rtl.min.css +9 -0
  87. data/app/assets/stylesheets/coloradmin/theme/css/facebook/app.min.css +9 -0
  88. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/bg-login-dark-mode.png +0 -0
  89. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/bg-login.png +0 -0
  90. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/coming-soon.jpg +0 -0
  91. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/cover-pattern.png +0 -0
  92. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/cover-sidebar-user.jpg +0 -0
  93. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/cover-sidebar.jpg +0 -0
  94. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/error-page-pattern.png +0 -0
  95. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/profile-cover.jpg +0 -0
  96. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.1.png +0 -0
  97. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.2.png +0 -0
  98. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.3.png +0 -0
  99. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.4.png +0 -0
  100. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.5.png +0 -0
  101. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.6.png +0 -0
  102. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.7.png +0 -0
  103. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.8.png +0 -0
  104. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/black-0.9.png +0 -0
  105. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.1.png +0 -0
  106. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.2.png +0 -0
  107. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.3.png +0 -0
  108. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.4.png +0 -0
  109. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.5.png +0 -0
  110. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.6.png +0 -0
  111. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.7.png +0 -0
  112. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.8.png +0 -0
  113. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.9.png +0 -0
  114. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/transparent/white-0.98.png +0 -0
  115. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/ui-icons_444444_256x240.png +0 -0
  116. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/ui-icons_555555_256x240.png +0 -0
  117. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/ui-icons_777620_256x240.png +0 -0
  118. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/ui-icons_777777_256x240.png +0 -0
  119. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/ui-icons_cc0000_256x240.png +0 -0
  120. data/app/assets/stylesheets/coloradmin/theme/css/facebook/images/ui-icons_ffffff_256x240.png +0 -0
  121. data/app/assets/stylesheets/coloradmin/theme/css/fonts/bootstrap-icons.woff +0 -0
  122. data/app/assets/stylesheets/coloradmin/theme/css/fonts/bootstrap-icons.woff2 +0 -0
  123. data/app/assets/stylesheets/coloradmin/theme/css/google/app-rtl.min.css +9 -0
  124. data/app/assets/stylesheets/coloradmin/theme/css/google/app.min.css +9 -0
  125. data/app/assets/stylesheets/coloradmin/theme/css/google/images/bg-login-dark-mode.png +0 -0
  126. data/app/assets/stylesheets/coloradmin/theme/css/google/images/bg-login.png +0 -0
  127. data/app/assets/stylesheets/coloradmin/theme/css/google/images/coming-soon.jpg +0 -0
  128. data/app/assets/stylesheets/coloradmin/theme/css/google/images/cover-pattern.png +0 -0
  129. data/app/assets/stylesheets/coloradmin/theme/css/google/images/cover-sidebar-user.jpg +0 -0
  130. data/app/assets/stylesheets/coloradmin/theme/css/google/images/cover-sidebar.jpg +0 -0
  131. data/app/assets/stylesheets/coloradmin/theme/css/google/images/error-page-pattern.png +0 -0
  132. data/app/assets/stylesheets/coloradmin/theme/css/google/images/profile-cover.jpg +0 -0
  133. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.1.png +0 -0
  134. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.2.png +0 -0
  135. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.3.png +0 -0
  136. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.4.png +0 -0
  137. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.5.png +0 -0
  138. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.6.png +0 -0
  139. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.7.png +0 -0
  140. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.8.png +0 -0
  141. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/black-0.9.png +0 -0
  142. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.1.png +0 -0
  143. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.2.png +0 -0
  144. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.3.png +0 -0
  145. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.4.png +0 -0
  146. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.5.png +0 -0
  147. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.6.png +0 -0
  148. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.7.png +0 -0
  149. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.8.png +0 -0
  150. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.9.png +0 -0
  151. data/app/assets/stylesheets/coloradmin/theme/css/google/images/transparent/white-0.98.png +0 -0
  152. data/app/assets/stylesheets/coloradmin/theme/css/google/images/ui-icons_444444_256x240.png +0 -0
  153. data/app/assets/stylesheets/coloradmin/theme/css/google/images/ui-icons_555555_256x240.png +0 -0
  154. data/app/assets/stylesheets/coloradmin/theme/css/google/images/ui-icons_777620_256x240.png +0 -0
  155. data/app/assets/stylesheets/coloradmin/theme/css/google/images/ui-icons_777777_256x240.png +0 -0
  156. data/app/assets/stylesheets/coloradmin/theme/css/google/images/ui-icons_cc0000_256x240.png +0 -0
  157. data/app/assets/stylesheets/coloradmin/theme/css/google/images/ui-icons_ffffff_256x240.png +0 -0
  158. data/app/assets/stylesheets/coloradmin/theme/css/material/app-rtl.min.css +9 -0
  159. data/app/assets/stylesheets/coloradmin/theme/css/material/app.min.css +9 -0
  160. data/app/assets/stylesheets/coloradmin/theme/css/material/images/bg-login-dark-mode.png +0 -0
  161. data/app/assets/stylesheets/coloradmin/theme/css/material/images/bg-login.png +0 -0
  162. data/app/assets/stylesheets/coloradmin/theme/css/material/images/coming-soon.jpg +0 -0
  163. data/app/assets/stylesheets/coloradmin/theme/css/material/images/cover-pattern.png +0 -0
  164. data/app/assets/stylesheets/coloradmin/theme/css/material/images/cover-sidebar-user.jpg +0 -0
  165. data/app/assets/stylesheets/coloradmin/theme/css/material/images/cover-sidebar.jpg +0 -0
  166. data/app/assets/stylesheets/coloradmin/theme/css/material/images/error-page-pattern.png +0 -0
  167. data/app/assets/stylesheets/coloradmin/theme/css/material/images/profile-cover.jpg +0 -0
  168. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.1.png +0 -0
  169. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.2.png +0 -0
  170. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.3.png +0 -0
  171. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.4.png +0 -0
  172. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.5.png +0 -0
  173. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.6.png +0 -0
  174. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.7.png +0 -0
  175. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.8.png +0 -0
  176. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/black-0.9.png +0 -0
  177. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.1.png +0 -0
  178. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.2.png +0 -0
  179. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.3.png +0 -0
  180. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.4.png +0 -0
  181. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.5.png +0 -0
  182. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.6.png +0 -0
  183. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.7.png +0 -0
  184. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.8.png +0 -0
  185. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.9.png +0 -0
  186. data/app/assets/stylesheets/coloradmin/theme/css/material/images/transparent/white-0.98.png +0 -0
  187. data/app/assets/stylesheets/coloradmin/theme/css/material/images/ui-icons_444444_256x240.png +0 -0
  188. data/app/assets/stylesheets/coloradmin/theme/css/material/images/ui-icons_555555_256x240.png +0 -0
  189. data/app/assets/stylesheets/coloradmin/theme/css/material/images/ui-icons_777620_256x240.png +0 -0
  190. data/app/assets/stylesheets/coloradmin/theme/css/material/images/ui-icons_777777_256x240.png +0 -0
  191. data/app/assets/stylesheets/coloradmin/theme/css/material/images/ui-icons_cc0000_256x240.png +0 -0
  192. data/app/assets/stylesheets/coloradmin/theme/css/material/images/ui-icons_ffffff_256x240.png +0 -0
  193. data/app/assets/stylesheets/coloradmin/theme/css/transparent/app-rtl.min.css +9 -0
  194. data/app/assets/stylesheets/coloradmin/theme/css/transparent/app.min.css +9 -0
  195. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/bg-login-dark-mode.png +0 -0
  196. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/bg-login.png +0 -0
  197. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/coming-soon.jpg +0 -0
  198. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/cover-pattern.png +0 -0
  199. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/cover-sidebar-user.jpg +0 -0
  200. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/cover-sidebar.jpg +0 -0
  201. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/error-page-pattern.png +0 -0
  202. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/page-cover-v2.jpg +0 -0
  203. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/page-cover.jpg +0 -0
  204. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/profile-cover.jpg +0 -0
  205. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.1.png +0 -0
  206. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.2.png +0 -0
  207. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.3.png +0 -0
  208. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.4.png +0 -0
  209. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.5.png +0 -0
  210. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.6.png +0 -0
  211. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.7.png +0 -0
  212. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.8.png +0 -0
  213. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/black-0.9.png +0 -0
  214. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.1.png +0 -0
  215. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.2.png +0 -0
  216. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.3.png +0 -0
  217. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.4.png +0 -0
  218. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.5.png +0 -0
  219. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.6.png +0 -0
  220. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.7.png +0 -0
  221. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.8.png +0 -0
  222. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.9.png +0 -0
  223. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/transparent/white-0.98.png +0 -0
  224. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/ui-icons_444444_256x240.png +0 -0
  225. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/ui-icons_555555_256x240.png +0 -0
  226. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/ui-icons_777620_256x240.png +0 -0
  227. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/ui-icons_777777_256x240.png +0 -0
  228. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/ui-icons_cc0000_256x240.png +0 -0
  229. data/app/assets/stylesheets/coloradmin/theme/css/transparent/images/ui-icons_ffffff_256x240.png +0 -0
  230. data/app/assets/stylesheets/coloradmin/theme/img/coming-soon/coming-soon-1.jpg +0 -0
  231. data/app/assets/stylesheets/coloradmin/theme/img/cover/cover-profile.jpg +0 -0
  232. data/app/assets/stylesheets/coloradmin/theme/img/cover/cover-scrum-board.png +0 -0
  233. data/app/assets/stylesheets/coloradmin/theme/img/flag/cn.jpg +0 -0
  234. data/app/assets/stylesheets/coloradmin/theme/img/flag/de.jpg +0 -0
  235. data/app/assets/stylesheets/coloradmin/theme/img/flag/fr.jpg +0 -0
  236. data/app/assets/stylesheets/coloradmin/theme/img/flag/jp.jpg +0 -0
  237. data/app/assets/stylesheets/coloradmin/theme/img/flag/us.jpg +0 -0
  238. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-1-thumb.jpg +0 -0
  239. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-1.jpg +0 -0
  240. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-10-thumb.jpg +0 -0
  241. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-10.jpg +0 -0
  242. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-11-thumb.jpg +0 -0
  243. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-11.jpg +0 -0
  244. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-12-thumb.jpg +0 -0
  245. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-12.jpg +0 -0
  246. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-13-thumb.jpg +0 -0
  247. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-13.jpg +0 -0
  248. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-14-thumb.jpg +0 -0
  249. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-14.jpg +0 -0
  250. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-15-thumb.jpg +0 -0
  251. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-15.jpg +0 -0
  252. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-16-thumb.jpg +0 -0
  253. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-16.jpg +0 -0
  254. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-17-thumb.jpg +0 -0
  255. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-17.jpg +0 -0
  256. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-18-thumb.jpg +0 -0
  257. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-18.jpg +0 -0
  258. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-19-thumb.jpg +0 -0
  259. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-19.jpg +0 -0
  260. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-2-thumb.jpg +0 -0
  261. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-2.jpg +0 -0
  262. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-20-thumb.jpg +0 -0
  263. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-20.jpg +0 -0
  264. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-21-thumb.jpg +0 -0
  265. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-21.jpg +0 -0
  266. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-22-thumb.jpg +0 -0
  267. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-22.jpg +0 -0
  268. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-23-thumb.jpg +0 -0
  269. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-23.jpg +0 -0
  270. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-24-thumb.jpg +0 -0
  271. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-24.jpg +0 -0
  272. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-25-thumb.jpg +0 -0
  273. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-25.jpg +0 -0
  274. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-26-thumb.jpg +0 -0
  275. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-26.jpg +0 -0
  276. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-27-thumb.jpg +0 -0
  277. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-27.jpg +0 -0
  278. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-28-thumb.jpg +0 -0
  279. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-28.jpg +0 -0
  280. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-29-thumb.jpg +0 -0
  281. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-29.jpg +0 -0
  282. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-3-thumb.jpg +0 -0
  283. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-3.jpg +0 -0
  284. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-30-thumb.jpg +0 -0
  285. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-30.jpg +0 -0
  286. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-31-thumb.jpg +0 -0
  287. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-31.jpg +0 -0
  288. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-32-thumb.jpg +0 -0
  289. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-32.jpg +0 -0
  290. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-33-thumb.jpg +0 -0
  291. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-33.jpg +0 -0
  292. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-34-thumb.jpg +0 -0
  293. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-34.jpg +0 -0
  294. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-35-thumb.jpg +0 -0
  295. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-35.jpg +0 -0
  296. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-36-thumb.jpg +0 -0
  297. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-36.jpg +0 -0
  298. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-37-thumb.jpg +0 -0
  299. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-37.jpg +0 -0
  300. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-38-thumb.jpg +0 -0
  301. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-38.jpg +0 -0
  302. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-39-thumb.jpg +0 -0
  303. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-39.jpg +0 -0
  304. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-4-thumb.jpg +0 -0
  305. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-4.jpg +0 -0
  306. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-40-thumb.jpg +0 -0
  307. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-40.jpg +0 -0
  308. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-41-thumb.jpg +0 -0
  309. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-41.jpg +0 -0
  310. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-42-thumb.jpg +0 -0
  311. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-42.jpg +0 -0
  312. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-43-thumb.jpg +0 -0
  313. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-43.jpg +0 -0
  314. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-44-thumb.jpg +0 -0
  315. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-44.jpg +0 -0
  316. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-45-thumb.jpg +0 -0
  317. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-45.jpg +0 -0
  318. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-46-thumb.jpg +0 -0
  319. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-46.jpg +0 -0
  320. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-47-thumb.jpg +0 -0
  321. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-47.jpg +0 -0
  322. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-48-thumb.jpg +0 -0
  323. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-48.jpg +0 -0
  324. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-49-thumb.jpg +0 -0
  325. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-49.jpg +0 -0
  326. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-5-thumb.jpg +0 -0
  327. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-5.jpg +0 -0
  328. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-50-thumb.jpg +0 -0
  329. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-50.jpg +0 -0
  330. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-51-thumb.jpg +0 -0
  331. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-51.jpg +0 -0
  332. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-52-thumb.jpg +0 -0
  333. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-52.jpg +0 -0
  334. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-53-thumb.jpg +0 -0
  335. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-53.jpg +0 -0
  336. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-54-thumb.jpg +0 -0
  337. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-54.jpg +0 -0
  338. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-55-thumb.jpg +0 -0
  339. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-55.jpg +0 -0
  340. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-56-thumb.jpg +0 -0
  341. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-56.jpg +0 -0
  342. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-57-thumb.jpg +0 -0
  343. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-57.jpg +0 -0
  344. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-58-thumb.jpg +0 -0
  345. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-58.jpg +0 -0
  346. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-59-thumb.jpg +0 -0
  347. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-59.jpg +0 -0
  348. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-6-thumb.jpg +0 -0
  349. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-6.jpg +0 -0
  350. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-60-thumb.jpg +0 -0
  351. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-60.jpg +0 -0
  352. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-61-thumb.jpg +0 -0
  353. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-61.jpg +0 -0
  354. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-62-thumb.jpg +0 -0
  355. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-62.jpg +0 -0
  356. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-63-thumb.jpg +0 -0
  357. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-63.jpg +0 -0
  358. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-64-thumb.jpg +0 -0
  359. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-64.jpg +0 -0
  360. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-65-thumb.jpg +0 -0
  361. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-65.jpg +0 -0
  362. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-66-thumb.jpg +0 -0
  363. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-66.jpg +0 -0
  364. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-67-thumb.jpg +0 -0
  365. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-67.jpg +0 -0
  366. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-68-thumb.jpg +0 -0
  367. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-68.jpg +0 -0
  368. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-69-thumb.jpg +0 -0
  369. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-69.jpg +0 -0
  370. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-7-thumb.jpg +0 -0
  371. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-7.jpg +0 -0
  372. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-70-thumb.jpg +0 -0
  373. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-70.jpg +0 -0
  374. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-8-thumb.jpg +0 -0
  375. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-8.jpg +0 -0
  376. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-9-thumb.jpg +0 -0
  377. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-9.jpg +0 -0
  378. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-1.jpg +0 -0
  379. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-10.jpg +0 -0
  380. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-11-thumb.jpg +0 -0
  381. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-11.jpg +0 -0
  382. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-2.jpg +0 -0
  383. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-3.jpg +0 -0
  384. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-4.jpg +0 -0
  385. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-5.jpg +0 -0
  386. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-6.jpg +0 -0
  387. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-7.jpg +0 -0
  388. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-8.jpg +0 -0
  389. data/app/assets/stylesheets/coloradmin/theme/img/gallery/gallery-portrait-9.jpg +0 -0
  390. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-1-thumb.jpg +0 -0
  391. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-1.jpg +0 -0
  392. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-10-thumb.jpg +0 -0
  393. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-10.jpg +0 -0
  394. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-11-thumb.jpg +0 -0
  395. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-11.jpg +0 -0
  396. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-12-thumb.jpg +0 -0
  397. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-12.jpg +0 -0
  398. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-13-thumb.jpg +0 -0
  399. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-13.jpg +0 -0
  400. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-14-thumb.jpg +0 -0
  401. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-14.jpg +0 -0
  402. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-15.jpg +0 -0
  403. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-16-thumb.jpg +0 -0
  404. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-16.jpg +0 -0
  405. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-17-thumb.jpg +0 -0
  406. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-17.jpg +0 -0
  407. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-18-thumb.jpg +0 -0
  408. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-18.jpg +0 -0
  409. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-2-thumb.jpg +0 -0
  410. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-2.jpg +0 -0
  411. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-3-thumb.jpg +0 -0
  412. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-3.jpg +0 -0
  413. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-4-thumb.jpg +0 -0
  414. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-4.jpg +0 -0
  415. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-5-thumb.jpg +0 -0
  416. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-5.jpg +0 -0
  417. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-6-thumb.jpg +0 -0
  418. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-6.jpg +0 -0
  419. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-7-thumb.jpg +0 -0
  420. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-7.jpg +0 -0
  421. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-8-thumb.jpg +0 -0
  422. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-8.jpg +0 -0
  423. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-9-thumb.jpg +0 -0
  424. data/app/assets/stylesheets/coloradmin/theme/img/login-bg/login-bg-9.jpg +0 -0
  425. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-admin-apple.png +0 -0
  426. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-admin-facebook.png +0 -0
  427. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-admin-google.png +0 -0
  428. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-admin-transparent.png +0 -0
  429. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-admin.png +0 -0
  430. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-bs4.png +0 -0
  431. data/app/assets/stylesheets/coloradmin/theme/img/logo/logo-bs5.png +0 -0
  432. data/app/assets/stylesheets/coloradmin/theme/img/pos/icon-table-black.svg +31 -0
  433. data/app/assets/stylesheets/coloradmin/theme/img/pos/icon-table.svg +37 -0
  434. data/app/assets/stylesheets/coloradmin/theme/img/pos/logo-white.svg +44 -0
  435. data/app/assets/stylesheets/coloradmin/theme/img/pos/logo.svg +80 -0
  436. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-1.jpg +0 -0
  437. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-10.jpg +0 -0
  438. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-11.jpg +0 -0
  439. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-12.jpg +0 -0
  440. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-13.jpg +0 -0
  441. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-14.jpg +0 -0
  442. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-15.jpg +0 -0
  443. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-16.jpg +0 -0
  444. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-17.jpg +0 -0
  445. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-2.jpg +0 -0
  446. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-3.jpg +0 -0
  447. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-4.jpg +0 -0
  448. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-5.jpg +0 -0
  449. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-6.jpg +0 -0
  450. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-7.jpg +0 -0
  451. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-8.jpg +0 -0
  452. data/app/assets/stylesheets/coloradmin/theme/img/pos/product-9.jpg +0 -0
  453. data/app/assets/stylesheets/coloradmin/theme/img/product/product-1.jpg +0 -0
  454. data/app/assets/stylesheets/coloradmin/theme/img/product/product-1.png +0 -0
  455. data/app/assets/stylesheets/coloradmin/theme/img/product/product-10.jpg +0 -0
  456. data/app/assets/stylesheets/coloradmin/theme/img/product/product-11.jpg +0 -0
  457. data/app/assets/stylesheets/coloradmin/theme/img/product/product-12.jpg +0 -0
  458. data/app/assets/stylesheets/coloradmin/theme/img/product/product-13.jpg +0 -0
  459. data/app/assets/stylesheets/coloradmin/theme/img/product/product-14.jpg +0 -0
  460. data/app/assets/stylesheets/coloradmin/theme/img/product/product-15.jpg +0 -0
  461. data/app/assets/stylesheets/coloradmin/theme/img/product/product-2.jpg +0 -0
  462. data/app/assets/stylesheets/coloradmin/theme/img/product/product-2.png +0 -0
  463. data/app/assets/stylesheets/coloradmin/theme/img/product/product-3.jpg +0 -0
  464. data/app/assets/stylesheets/coloradmin/theme/img/product/product-3.png +0 -0
  465. data/app/assets/stylesheets/coloradmin/theme/img/product/product-4.jpg +0 -0
  466. data/app/assets/stylesheets/coloradmin/theme/img/product/product-4.png +0 -0
  467. data/app/assets/stylesheets/coloradmin/theme/img/product/product-5.jpg +0 -0
  468. data/app/assets/stylesheets/coloradmin/theme/img/product/product-5.png +0 -0
  469. data/app/assets/stylesheets/coloradmin/theme/img/product/product-6.jpg +0 -0
  470. data/app/assets/stylesheets/coloradmin/theme/img/product/product-6.png +0 -0
  471. data/app/assets/stylesheets/coloradmin/theme/img/product/product-7.jpg +0 -0
  472. data/app/assets/stylesheets/coloradmin/theme/img/product/product-7.png +0 -0
  473. data/app/assets/stylesheets/coloradmin/theme/img/product/product-8.jpg +0 -0
  474. data/app/assets/stylesheets/coloradmin/theme/img/product/product-9.jpg +0 -0
  475. data/app/assets/stylesheets/coloradmin/theme/img/product/product-preview-ipad.png +0 -0
  476. data/app/assets/stylesheets/coloradmin/theme/img/product/product-preview-iphone.png +0 -0
  477. data/app/assets/stylesheets/coloradmin/theme/img/product/product-preview-macbook.png +0 -0
  478. data/app/assets/stylesheets/coloradmin/theme/img/product/product-preview-sm.jpg +0 -0
  479. data/app/assets/stylesheets/coloradmin/theme/img/product/product-preview.jpg +0 -0
  480. data/app/assets/stylesheets/coloradmin/theme/img/svg/img-1.svg +1 -0
  481. data/app/assets/stylesheets/coloradmin/theme/img/svg/img-2.svg +1 -0
  482. data/app/assets/stylesheets/coloradmin/theme/img/svg/img-3.svg +1 -0
  483. data/app/assets/stylesheets/coloradmin/theme/img/svg/img-4.svg +1 -0
  484. data/app/assets/stylesheets/coloradmin/theme/img/theme/apple.jpg +0 -0
  485. data/app/assets/stylesheets/coloradmin/theme/img/theme/blog.jpg +0 -0
  486. data/app/assets/stylesheets/coloradmin/theme/img/theme/corporate.jpg +0 -0
  487. data/app/assets/stylesheets/coloradmin/theme/img/theme/default.jpg +0 -0
  488. data/app/assets/stylesheets/coloradmin/theme/img/theme/e-commerce.jpg +0 -0
  489. data/app/assets/stylesheets/coloradmin/theme/img/theme/facebook.jpg +0 -0
  490. data/app/assets/stylesheets/coloradmin/theme/img/theme/forum.jpg +0 -0
  491. data/app/assets/stylesheets/coloradmin/theme/img/theme/google.jpg +0 -0
  492. data/app/assets/stylesheets/coloradmin/theme/img/theme/material.jpg +0 -0
  493. data/app/assets/stylesheets/coloradmin/theme/img/theme/one-page-parallax.jpg +0 -0
  494. data/app/assets/stylesheets/coloradmin/theme/img/theme/transparent.jpg +0 -0
  495. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.1.png +0 -0
  496. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.2.png +0 -0
  497. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.3.png +0 -0
  498. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.4.png +0 -0
  499. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.5.png +0 -0
  500. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.6.png +0 -0
  501. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.7.png +0 -0
  502. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.8.png +0 -0
  503. data/app/assets/stylesheets/coloradmin/theme/img/transparent/black-0.9.png +0 -0
  504. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.1.png +0 -0
  505. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.2.png +0 -0
  506. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.3.png +0 -0
  507. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.4.png +0 -0
  508. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.5.png +0 -0
  509. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.6.png +0 -0
  510. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.7.png +0 -0
  511. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.8.png +0 -0
  512. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.9.png +0 -0
  513. data/app/assets/stylesheets/coloradmin/theme/img/transparent/white-0.98.png +0 -0
  514. data/app/assets/stylesheets/coloradmin/theme/img/user/user-1.jpg +0 -0
  515. data/app/assets/stylesheets/coloradmin/theme/img/user/user-10.jpg +0 -0
  516. data/app/assets/stylesheets/coloradmin/theme/img/user/user-11.jpg +0 -0
  517. data/app/assets/stylesheets/coloradmin/theme/img/user/user-12.jpg +0 -0
  518. data/app/assets/stylesheets/coloradmin/theme/img/user/user-13.jpg +0 -0
  519. data/app/assets/stylesheets/coloradmin/theme/img/user/user-14.jpg +0 -0
  520. data/app/assets/stylesheets/coloradmin/theme/img/user/user-2.jpg +0 -0
  521. data/app/assets/stylesheets/coloradmin/theme/img/user/user-3.jpg +0 -0
  522. data/app/assets/stylesheets/coloradmin/theme/img/user/user-4.jpg +0 -0
  523. data/app/assets/stylesheets/coloradmin/theme/img/user/user-5.jpg +0 -0
  524. data/app/assets/stylesheets/coloradmin/theme/img/user/user-6.jpg +0 -0
  525. data/app/assets/stylesheets/coloradmin/theme/img/user/user-7.jpg +0 -0
  526. data/app/assets/stylesheets/coloradmin/theme/img/user/user-8.jpg +0 -0
  527. data/app/assets/stylesheets/coloradmin/theme/img/user/user-9.jpg +0 -0
  528. data/app/assets/stylesheets/coloradmin/theme/img/version/ajax.jpg +0 -0
  529. data/app/assets/stylesheets/coloradmin/theme/img/version/angular10x.jpg +0 -0
  530. data/app/assets/stylesheets/coloradmin/theme/img/version/angular1x.jpg +0 -0
  531. data/app/assets/stylesheets/coloradmin/theme/img/version/angular8x.jpg +0 -0
  532. data/app/assets/stylesheets/coloradmin/theme/img/version/dotnet.jpg +0 -0
  533. data/app/assets/stylesheets/coloradmin/theme/img/version/html.jpg +0 -0
  534. data/app/assets/stylesheets/coloradmin/theme/img/version/laravel.jpg +0 -0
  535. data/app/assets/stylesheets/coloradmin/theme/img/version/reactjs.jpg +0 -0
  536. data/app/assets/stylesheets/coloradmin/theme/img/version/vuejs.jpg +0 -0
  537. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-brands-400.ttf +0 -0
  538. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-brands-400.woff2 +0 -0
  539. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-regular-400.ttf +0 -0
  540. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-regular-400.woff2 +0 -0
  541. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-solid-900.ttf +0 -0
  542. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-solid-900.woff2 +0 -0
  543. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-v4compatibility.ttf +0 -0
  544. data/app/assets/stylesheets/coloradmin/theme/webfonts/fa-v4compatibility.woff2 +0 -0
  545. data/app/assets/stylesheets/coloradmin/transparent/phcthemes_admin_panel_pack_coloradmin.scss +8 -0
  546. data/lib/phcthemes_admin_panel_pack/engine.rb +10 -20
  547. data/lib/phcthemes_admin_panel_pack/version.rb +3 -3
  548. data/lib/phcthemes_admin_panel_pack.rb +6 -6
  549. data/lib/tasks/phcthemes_admin_panel_pack_tasks.rake +4 -4
  550. metadata +552 -414
  551. data/app/assets/javascripts/common/backstretch/jquery.backstretch.js +0 -1602
  552. data/app/assets/javascripts/common/bootstrap/bootstrap.bundle.js +0 -7023
  553. data/app/assets/javascripts/common/bootstrap/bootstrap.three.js +0 -2377
  554. data/app/assets/javascripts/common/bootstrap-datepicker/bootstrap-datepicker.js +0 -2039
  555. data/app/assets/javascripts/common/bootstrap-markdown/bootstrap-markdown.js +0 -1390
  556. data/app/assets/javascripts/common/bootstrap-select/bootstrap-select.js +0 -3139
  557. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.js +0 -46
  558. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.js.map +0 -1
  559. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-am_ET.min.js +0 -8
  560. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.js +0 -51
  561. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.js.map +0 -1
  562. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ar_AR.min.js +0 -8
  563. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.js +0 -46
  564. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.js.map +0 -1
  565. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-bg_BG.min.js +0 -8
  566. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.js +0 -39
  567. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.js.map +0 -1
  568. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-cs_CZ.min.js +0 -8
  569. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.js +0 -46
  570. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.js.map +0 -1
  571. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-da_DK.min.js +0 -8
  572. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.js +0 -46
  573. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.js.map +0 -1
  574. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-de_DE.min.js +0 -8
  575. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.js +0 -46
  576. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.js.map +0 -1
  577. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-en_US.min.js +0 -8
  578. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.js +0 -39
  579. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.js.map +0 -1
  580. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_CL.min.js +0 -8
  581. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.js +0 -39
  582. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.js.map +0 -1
  583. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-es_ES.min.js +0 -8
  584. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.js +0 -46
  585. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.js.map +0 -1
  586. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-et_EE.min.js +0 -8
  587. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.js +0 -39
  588. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.js.map +0 -1
  589. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-eu.min.js +0 -8
  590. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.js +0 -39
  591. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.js.map +0 -1
  592. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fa_IR.min.js +0 -8
  593. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.js +0 -46
  594. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.js.map +0 -1
  595. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fi_FI.min.js +0 -8
  596. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.js +0 -46
  597. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.js.map +0 -1
  598. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-fr_FR.min.js +0 -8
  599. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.js +0 -46
  600. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.js.map +0 -1
  601. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hr_HR.min.js +0 -8
  602. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.js +0 -46
  603. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.js.map +0 -1
  604. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-hu_HU.min.js +0 -8
  605. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.js +0 -39
  606. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.js.map +0 -1
  607. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-id_ID.min.js +0 -8
  608. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.js +0 -41
  609. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.js.map +0 -1
  610. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-it_IT.min.js +0 -8
  611. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.js +0 -39
  612. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.js.map +0 -1
  613. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ja_JP.min.js +0 -8
  614. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.js +0 -46
  615. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.js.map +0 -1
  616. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-kh_KM.min.js +0 -8
  617. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.js +0 -46
  618. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.js.map +0 -1
  619. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ko_KR.min.js +0 -8
  620. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.js +0 -46
  621. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.js.map +0 -1
  622. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lt_LT.min.js +0 -8
  623. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.js +0 -46
  624. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.js.map +0 -1
  625. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-lv_LV.min.js +0 -8
  626. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.js +0 -46
  627. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.js.map +0 -1
  628. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nb_NO.min.js +0 -8
  629. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.js +0 -39
  630. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.js.map +0 -1
  631. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-nl_NL.min.js +0 -8
  632. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.js +0 -39
  633. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.js.map +0 -1
  634. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pl_PL.min.js +0 -8
  635. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.js +0 -39
  636. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.js.map +0 -1
  637. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_BR.min.js +0 -8
  638. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.js +0 -39
  639. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.js.map +0 -1
  640. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-pt_PT.min.js +0 -8
  641. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.js +0 -40
  642. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.js.map +0 -1
  643. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ro_RO.min.js +0 -8
  644. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.js +0 -40
  645. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.js.map +0 -1
  646. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ru_RU.min.js +0 -8
  647. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.js +0 -39
  648. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.js.map +0 -1
  649. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sk_SK.min.js +0 -8
  650. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.js +0 -44
  651. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.js.map +0 -1
  652. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sl_SI.min.js +0 -8
  653. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.js +0 -46
  654. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.js.map +0 -1
  655. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-sv_SE.min.js +0 -8
  656. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.js +0 -46
  657. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.js.map +0 -1
  658. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-tr_TR.min.js +0 -8
  659. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.js +0 -39
  660. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.js.map +0 -1
  661. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-ua_UA.min.js +0 -8
  662. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.js +0 -46
  663. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.js.map +0 -1
  664. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-vi_VN.min.js +0 -8
  665. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.js +0 -39
  666. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.js.map +0 -1
  667. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_CN.min.js +0 -8
  668. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.js +0 -39
  669. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.js.map +0 -1
  670. data/app/assets/javascripts/common/bootstrap-select/i18n/defaults-zh_TW.min.js +0 -8
  671. data/app/assets/javascripts/common/chartjs/chart.js +0 -14680
  672. data/app/assets/javascripts/common/ckeditor/ckeditor.js +0 -7
  673. data/app/assets/javascripts/common/ckeditor/ckeditor.js.map +0 -1
  674. data/app/assets/javascripts/common/ckeditor/translations/af.js +0 -1
  675. data/app/assets/javascripts/common/ckeditor/translations/ar.js +0 -1
  676. data/app/assets/javascripts/common/ckeditor/translations/ast.js +0 -1
  677. data/app/assets/javascripts/common/ckeditor/translations/az.js +0 -1
  678. data/app/assets/javascripts/common/ckeditor/translations/bg.js +0 -1
  679. data/app/assets/javascripts/common/ckeditor/translations/ca.js +0 -1
  680. data/app/assets/javascripts/common/ckeditor/translations/cs.js +0 -1
  681. data/app/assets/javascripts/common/ckeditor/translations/da.js +0 -1
  682. data/app/assets/javascripts/common/ckeditor/translations/de-ch.js +0 -1
  683. data/app/assets/javascripts/common/ckeditor/translations/de.js +0 -1
  684. data/app/assets/javascripts/common/ckeditor/translations/el.js +0 -1
  685. data/app/assets/javascripts/common/ckeditor/translations/en-au.js +0 -1
  686. data/app/assets/javascripts/common/ckeditor/translations/en-gb.js +0 -1
  687. data/app/assets/javascripts/common/ckeditor/translations/eo.js +0 -1
  688. data/app/assets/javascripts/common/ckeditor/translations/es.js +0 -1
  689. data/app/assets/javascripts/common/ckeditor/translations/et.js +0 -1
  690. data/app/assets/javascripts/common/ckeditor/translations/eu.js +0 -1
  691. data/app/assets/javascripts/common/ckeditor/translations/fa.js +0 -1
  692. data/app/assets/javascripts/common/ckeditor/translations/fi.js +0 -1
  693. data/app/assets/javascripts/common/ckeditor/translations/fr.js +0 -1
  694. data/app/assets/javascripts/common/ckeditor/translations/gl.js +0 -1
  695. data/app/assets/javascripts/common/ckeditor/translations/gu.js +0 -1
  696. data/app/assets/javascripts/common/ckeditor/translations/he.js +0 -1
  697. data/app/assets/javascripts/common/ckeditor/translations/hr.js +0 -1
  698. data/app/assets/javascripts/common/ckeditor/translations/hu.js +0 -1
  699. data/app/assets/javascripts/common/ckeditor/translations/id.js +0 -1
  700. data/app/assets/javascripts/common/ckeditor/translations/it.js +0 -1
  701. data/app/assets/javascripts/common/ckeditor/translations/ja.js +0 -1
  702. data/app/assets/javascripts/common/ckeditor/translations/km.js +0 -1
  703. data/app/assets/javascripts/common/ckeditor/translations/kn.js +0 -1
  704. data/app/assets/javascripts/common/ckeditor/translations/ko.js +0 -1
  705. data/app/assets/javascripts/common/ckeditor/translations/ku.js +0 -1
  706. data/app/assets/javascripts/common/ckeditor/translations/lt.js +0 -1
  707. data/app/assets/javascripts/common/ckeditor/translations/lv.js +0 -1
  708. data/app/assets/javascripts/common/ckeditor/translations/nb.js +0 -1
  709. data/app/assets/javascripts/common/ckeditor/translations/ne.js +0 -1
  710. data/app/assets/javascripts/common/ckeditor/translations/nl.js +0 -1
  711. data/app/assets/javascripts/common/ckeditor/translations/no.js +0 -1
  712. data/app/assets/javascripts/common/ckeditor/translations/oc.js +0 -1
  713. data/app/assets/javascripts/common/ckeditor/translations/pl.js +0 -1
  714. data/app/assets/javascripts/common/ckeditor/translations/pt-br.js +0 -1
  715. data/app/assets/javascripts/common/ckeditor/translations/pt.js +0 -1
  716. data/app/assets/javascripts/common/ckeditor/translations/ro.js +0 -1
  717. data/app/assets/javascripts/common/ckeditor/translations/ru.js +0 -1
  718. data/app/assets/javascripts/common/ckeditor/translations/si.js +0 -1
  719. data/app/assets/javascripts/common/ckeditor/translations/sk.js +0 -1
  720. data/app/assets/javascripts/common/ckeditor/translations/sl.js +0 -1
  721. data/app/assets/javascripts/common/ckeditor/translations/sq.js +0 -1
  722. data/app/assets/javascripts/common/ckeditor/translations/sr-latn.js +0 -1
  723. data/app/assets/javascripts/common/ckeditor/translations/sr.js +0 -1
  724. data/app/assets/javascripts/common/ckeditor/translations/sv.js +0 -1
  725. data/app/assets/javascripts/common/ckeditor/translations/th.js +0 -1
  726. data/app/assets/javascripts/common/ckeditor/translations/tr.js +0 -1
  727. data/app/assets/javascripts/common/ckeditor/translations/tt.js +0 -1
  728. data/app/assets/javascripts/common/ckeditor/translations/ug.js +0 -1
  729. data/app/assets/javascripts/common/ckeditor/translations/uk.js +0 -1
  730. data/app/assets/javascripts/common/ckeditor/translations/vi.js +0 -1
  731. data/app/assets/javascripts/common/ckeditor/translations/zh-cn.js +0 -1
  732. data/app/assets/javascripts/common/ckeditor/translations/zh.js +0 -1
  733. data/app/assets/javascripts/common/clipboardjs/clipboard.js +0 -978
  734. data/app/assets/javascripts/common/covervid/covervid.js +0 -94
  735. data/app/assets/javascripts/common/custom/custom.js +0 -0
  736. data/app/assets/javascripts/common/datatables/datatables.js +0 -15310
  737. data/app/assets/javascripts/common/daterangepicker/daterangepicker.js +0 -1565
  738. data/app/assets/javascripts/common/fastclick/fastclick.js +0 -841
  739. data/app/assets/javascripts/common/flexslider/jquery.flexslider.js +0 -1252
  740. data/app/assets/javascripts/common/greenstock/greensock.js +0 -36
  741. data/app/assets/javascripts/common/html5sortable/jquery.sortable.js +0 -98
  742. data/app/assets/javascripts/common/icheck/icheck.js +0 -509
  743. data/app/assets/javascripts/common/imagesloaded/imagesloaded.pkgd.js +0 -497
  744. data/app/assets/javascripts/common/isotope/isotope.pkgd.js +0 -3563
  745. data/app/assets/javascripts/common/jquery/jquery-3.4.1.js +0 -10598
  746. data/app/assets/javascripts/common/jquery-countdown/jquery.countdown.js +0 -246
  747. data/app/assets/javascripts/common/jquery-filterizer/jquery.filterizr.min.js +0 -1
  748. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.autogrow.js +0 -37
  749. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.charcounter.js +0 -53
  750. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.checkbox.js +0 -54
  751. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.datepicker.js +0 -59
  752. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.js +0 -823
  753. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.masked.js +0 -46
  754. data/app/assets/javascripts/common/jquery-jeditable/jquery.jeditable.time.js +0 -71
  755. data/app/assets/javascripts/common/jquery-jvectormap/jquery-jvectormap.js +0 -44
  756. data/app/assets/javascripts/common/jquery-placeholder/jquery.placeholder.js +0 -281
  757. data/app/assets/javascripts/common/jquery-slimscroll/jquery.slimscroll.js +0 -474
  758. data/app/assets/javascripts/common/jquery-sparkline/jquery.sparkline.js +0 -3054
  759. data/app/assets/javascripts/common/jquery-ui/jquery-ui.js +0 -18706
  760. data/app/assets/javascripts/common/jquery-validation/jquery.validate.js +0 -1650
  761. data/app/assets/javascripts/common/jqvmap/jquery.vmap.js +0 -1281
  762. data/app/assets/javascripts/common/jqvmap/jquery.vmap.min.js +0 -10
  763. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.africa.js +0 -2
  764. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.asia.js +0 -2
  765. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.australia.js +0 -2
  766. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.europe.js +0 -2
  767. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.north-america.js +0 -2
  768. data/app/assets/javascripts/common/jqvmap/maps/continents/jquery.vmap.south-america.js +0 -2
  769. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.algeria.js +0 -2
  770. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.argentina.js +0 -1
  771. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.brazil.js +0 -2
  772. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.canada.js +0 -2
  773. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.europe.js +0 -2
  774. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.france.js +0 -1
  775. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.germany.js +0 -2
  776. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.greece.js +0 -1
  777. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.iran.js +0 -6
  778. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.iraq.js +0 -1
  779. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.russia.js +0 -2
  780. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.tunisia.js +0 -2
  781. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.turkey.js +0 -11
  782. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.usa.js +0 -2
  783. data/app/assets/javascripts/common/jqvmap/maps/jquery.vmap.world.js +0 -2
  784. data/app/assets/javascripts/common/js-cookie/js.cookie.js +0 -165
  785. data/app/assets/javascripts/common/layerslider/layerslider.kreaturamedia.jquery.js +0 -13
  786. data/app/assets/javascripts/common/layerslider/layerslider.origami.js +0 -13
  787. data/app/assets/javascripts/common/layerslider/layerslider.timeline.js +0 -13
  788. data/app/assets/javascripts/common/layerslider/layerslider.transitions.js +0 -13
  789. data/app/assets/javascripts/common/lazysizes/lazysizes.js +0 -754
  790. data/app/assets/javascripts/common/leaflet/leaflet.js +0 -5
  791. data/app/assets/javascripts/common/magnific-popup/jquery.magnific-popup.js +0 -1860
  792. data/app/assets/javascripts/common/mapbox/mapbox.js +0 -51
  793. data/app/assets/javascripts/common/metismenu/metisMenu.js +0 -340
  794. data/app/assets/javascripts/common/moderizer/modernizr.js +0 -11
  795. data/app/assets/javascripts/common/nouislider/nouislider.js +0 -2637
  796. data/app/assets/javascripts/common/owl-carousel/owl.carousel.js +0 -3448
  797. data/app/assets/javascripts/common/pace/pace.js +0 -935
  798. data/app/assets/javascripts/common/paroller/jquery.paroller.js +0 -228
  799. data/app/assets/javascripts/common/particlejs/particles.js +0 -1541
  800. data/app/assets/javascripts/common/perfect-scrollbar/perfect-scrollbar.common.js +0 -1318
  801. data/app/assets/javascripts/common/perfect-scrollbar/perfect-scrollbar.esm.js +0 -1316
  802. data/app/assets/javascripts/common/perfect-scrollbar/perfect-scrollbar.js +0 -1324
  803. data/app/assets/javascripts/common/plyr/plyr.js +0 -9137
  804. data/app/assets/javascripts/common/rangeslider/rangeslider.js +0 -498
  805. data/app/assets/javascripts/common/retina/retina.js +0 -100
  806. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.actions.js +0 -386
  807. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.carousel.js +0 -365
  808. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.kenburn.js +0 -199
  809. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.layeranimation.js +0 -2524
  810. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.migration.js +0 -260
  811. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.navigation.js +0 -1156
  812. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.parallax.js +0 -465
  813. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.slideanims.js +0 -1447
  814. data/app/assets/javascripts/common/rev-slider/extensions/revolution.extension.video.js +0 -1464
  815. data/app/assets/javascripts/common/rev-slider/jquery.themepunch.revolution.js +0 -3286
  816. data/app/assets/javascripts/common/rev-slider/jquery.themepunch.tools.min.js +0 -8710
  817. data/app/assets/javascripts/common/scrollme/jquery.scrollme.js +0 -455
  818. data/app/assets/javascripts/common/scrollup/jquery.scrollUp.js +0 -168
  819. data/app/assets/javascripts/common/select2/select2.full.js +0 -6597
  820. data/app/assets/javascripts/common/selectbox/jquery.selectBox.js +0 -1092
  821. data/app/assets/javascripts/common/slick/slick.js +0 -3004
  822. data/app/assets/javascripts/common/smooth-scroll/SmoothScroll.js +0 -788
  823. data/app/assets/javascripts/common/spectrum/spectrum.js +0 -2323
  824. data/app/assets/javascripts/common/stepper/jquery.fs.stepper.js +0 -339
  825. data/app/assets/javascripts/common/swiper/swiper.js +0 -8124
  826. data/app/assets/javascripts/common/toaster/toastr.js +0 -476
  827. data/app/assets/javascripts/common/typed/typed.js +0 -1045
  828. data/app/assets/javascripts/common/visable/jquery.visible.js +0 -68
  829. data/app/assets/javascripts/common/waypoints/jquery.waypoints.js +0 -662
  830. data/app/assets/javascripts/common/wow/wow.js +0 -508
  831. data/app/assets/javascripts/phcthemes_admin_panel_pack_adminlte.js +0 -12
  832. data/app/assets/javascripts/phcthemes_admin_panel_pack_boomerang.js +0 -0
  833. data/app/assets/javascripts/phcthemes_admin_panel_pack_coloradmin.js +0 -5
  834. data/app/assets/javascripts/phcthemes_admin_panel_pack_inspinia.js +0 -10
  835. data/app/assets/javascripts/phcthemes_admin_panel_pack_quilpro.js +0 -5
  836. data/app/assets/javascripts/phcthemes_admin_panel_pack_starlight.js +0 -5
  837. data/app/assets/javascripts/themes/adminlte/theme/adminlte.js +0 -1141
  838. data/app/assets/javascripts/themes/coloradmin/theme/color_admin_app.min.js +0 -1
  839. data/app/assets/javascripts/themes/coloradmin/theme/color_admin_default.js +0 -231
  840. data/app/assets/javascripts/themes/inspinia/theme/inspinia.js +0 -279
  841. data/app/assets/javascripts/themes/metronic/theme/plugins.bundle.js +0 -83988
  842. data/app/assets/javascripts/themes/metronic/theme/prismjs.bundle.js +0 -1922
  843. data/app/assets/javascripts/themes/metronic/theme/scripts.bundle.js +0 -11035
  844. data/app/assets/javascripts/themes/metronic/theme/widgets.js +0 -4706
  845. data/app/assets/stylesheets/common/hanna_hearts/hanna_hearts.scss +0 -11
  846. data/app/assets/stylesheets/phcthemes_admin_panel_pack_adminlte.scss +0 -16
  847. data/app/assets/stylesheets/phcthemes_admin_panel_pack_boomerang.scss +0 -27
  848. data/app/assets/stylesheets/phcthemes_admin_panel_pack_coloradmin.scss +0 -11
  849. data/app/assets/stylesheets/phcthemes_admin_panel_pack_inspinia.scss +0 -18
  850. data/app/assets/stylesheets/phcthemes_admin_panel_pack_metronic.scss +0 -15
  851. data/app/assets/stylesheets/phcthemes_admin_panel_pack_quilpro.scss +0 -19
  852. data/app/assets/stylesheets/phcthemes_admin_panel_pack_starlight.scss +0 -15
@@ -1 +0,0 @@
1
- {"version":3,"file":"ckeditor.js","sources":["webpack://ClassicEditor/ckeditor.js"],"sourcesContent":["/*!\n * @license Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md.\n */\n(function(t){const e=t[\"en\"]=t[\"en\"]||{};e.dictionary=Object.assign(e.dictionary||{},{\"%0 of %1\":\"%0 of %1\",\"Align cell text to the bottom\":\"Align cell text to the bottom\",\"Align cell text to the center\":\"Align cell text to the center\",\"Align cell text to the left\":\"Align cell text to the left\",\"Align cell text to the middle\":\"Align cell text to the middle\",\"Align cell text to the right\":\"Align cell text to the right\",\"Align cell text to the top\":\"Align cell text to the top\",\"Align center\":\"Align center\",\"Align left\":\"Align left\",\"Align right\":\"Align right\",\"Align table to the left\":\"Align table to the left\",\"Align table to the right\":\"Align table to the right\",Alignment:\"Alignment\",\"Almost equal to\":\"Almost equal to\",Angle:\"Angle\",\"Approximately equal to\":\"Approximately equal to\",Aquamarine:\"Aquamarine\",\"Asterisk operator\":\"Asterisk operator\",\"Austral sign\":\"Austral sign\",\"back with leftwards arrow above\":\"back with leftwards arrow above\",Background:\"Background\",Big:\"Big\",\"Bitcoin sign\":\"Bitcoin sign\",Black:\"Black\",\"Block quote\":\"Block quote\",Blue:\"Blue\",\"Blue marker\":\"Blue marker\",Bold:\"Bold\",Border:\"Border\",Cancel:\"Cancel\",\"Cedi sign\":\"Cedi sign\",\"Cell properties\":\"Cell properties\",\"Cent sign\":\"Cent sign\",\"Center table\":\"Center table\",\"Character categories\":\"Character categories\",\"Characters: %0\":\"Characters: %0\",\"Choose heading\":\"Choose heading\",Code:\"Code\",\"Colon sign\":\"Colon sign\",Color:\"Color\",\"Color picker\":\"Color picker\",Column:\"Column\",\"Contains as member\":\"Contains as member\",\"Copyright sign\":\"Copyright sign\",\"Cruzeiro sign\":\"Cruzeiro sign\",\"Currency sign\":\"Currency sign\",Dashed:\"Dashed\",\"Decrease indent\":\"Decrease indent\",Default:\"Default\",\"Degree sign\":\"Degree sign\",\"Delete column\":\"Delete column\",\"Delete row\":\"Delete row\",\"Dim grey\":\"Dim grey\",Dimensions:\"Dimensions\",\"Division sign\":\"Division sign\",\"Document colors\":\"Document colors\",\"Dollar sign\":\"Dollar sign\",\"Dong sign\":\"Dong sign\",Dotted:\"Dotted\",Double:\"Double\",\"Double dagger\":\"Double dagger\",\"Double exclamation mark\":\"Double exclamation mark\",\"Double low-9 quotation mark\":\"Double low-9 quotation mark\",\"Double question mark\":\"Double question mark\",Downloadable:\"Downloadable\",\"downwards arrow to bar\":\"downwards arrow to bar\",\"downwards dashed arrow\":\"downwards dashed arrow\",\"downwards double arrow\":\"downwards double arrow\",\"Drachma sign\":\"Drachma sign\",\"Dropdown toolbar\":\"Dropdown toolbar\",\"Edit link\":\"Edit link\",\"Editor toolbar\":\"Editor toolbar\",\"Element of\":\"Element of\",\"Em dash\":\"Em dash\",\"Empty set\":\"Empty set\",\"En dash\":\"En dash\",\"end with leftwards arrow above\":\"end with leftwards arrow above\",\"Euro sign\":\"Euro sign\",\"Euro-currency sign\":\"Euro-currency sign\",\"Exclamation question mark\":\"Exclamation question mark\",\"Font Background Color\":\"Font Background Color\",\"Font Color\":\"Font Color\",\"Font Family\":\"Font Family\",\"Font Size\":\"Font Size\",\"For all\":\"For all\",\"Fraction slash\":\"Fraction slash\",\"French franc sign\":\"French franc sign\",\"German penny sign\":\"German penny sign\",\"Greater-than or equal to\":\"Greater-than or equal to\",\"Greater-than sign\":\"Greater-than sign\",Green:\"Green\",\"Green marker\":\"Green marker\",\"Green pen\":\"Green pen\",Grey:\"Grey\",Groove:\"Groove\",\"Guarani sign\":\"Guarani sign\",\"Header column\":\"Header column\",\"Header row\":\"Header row\",Heading:\"Heading\",\"Heading 1\":\"Heading 1\",\"Heading 2\":\"Heading 2\",\"Heading 3\":\"Heading 3\",\"Heading 4\":\"Heading 4\",\"Heading 5\":\"Heading 5\",\"Heading 6\":\"Heading 6\",Height:\"Height\",Highlight:\"Highlight\",\"Horizontal ellipsis\":\"Horizontal ellipsis\",\"Horizontal line\":\"Horizontal line\",\"Horizontal text alignment toolbar\":\"Horizontal text alignment toolbar\",\"Hryvnia sign\":\"Hryvnia sign\",Huge:\"Huge\",\"Identical to\":\"Identical to\",\"Increase indent\":\"Increase indent\",\"Indian rupee sign\":\"Indian rupee sign\",Infinity:\"Infinity\",\"Insert code block\":\"Insert code block\",\"Insert column left\":\"Insert column left\",\"Insert column right\":\"Insert column right\",\"Insert paragraph after block\":\"Insert paragraph after block\",\"Insert paragraph before block\":\"Insert paragraph before block\",\"Insert row above\":\"Insert row above\",\"Insert row below\":\"Insert row below\",\"Insert table\":\"Insert table\",Inset:\"Inset\",Integral:\"Integral\",Intersection:\"Intersection\",\"Inverted exclamation mark\":\"Inverted exclamation mark\",\"Inverted question mark\":\"Inverted question mark\",Italic:\"Italic\",Justify:\"Justify\",\"Justify cell text\":\"Justify cell text\",\"Kip sign\":\"Kip sign\",\"Latin capital letter a with breve\":\"Latin capital letter a with breve\",\"Latin capital letter a with macron\":\"Latin capital letter a with macron\",\"Latin capital letter a with ogonek\":\"Latin capital letter a with ogonek\",\"Latin capital letter c with acute\":\"Latin capital letter c with acute\",\"Latin capital letter c with caron\":\"Latin capital letter c with caron\",\"Latin capital letter c with circumflex\":\"Latin capital letter c with circumflex\",\"Latin capital letter c with dot above\":\"Latin capital letter c with dot above\",\"Latin capital letter d with caron\":\"Latin capital letter d with caron\",\"Latin capital letter d with stroke\":\"Latin capital letter d with stroke\",\"Latin capital letter e with breve\":\"Latin capital letter e with breve\",\"Latin capital letter e with caron\":\"Latin capital letter e with caron\",\"Latin capital letter e with dot above\":\"Latin capital letter e with dot above\",\"Latin capital letter e with macron\":\"Latin capital letter e with macron\",\"Latin capital letter e with ogonek\":\"Latin capital letter e with ogonek\",\"Latin capital letter eng\":\"Latin capital letter eng\",\"Latin capital letter g with breve\":\"Latin capital letter g with breve\",\"Latin capital letter g with cedilla\":\"Latin capital letter g with cedilla\",\"Latin capital letter g with circumflex\":\"Latin capital letter g with circumflex\",\"Latin capital letter g with dot above\":\"Latin capital letter g with dot above\",\"Latin capital letter h with circumflex\":\"Latin capital letter h with circumflex\",\"Latin capital letter h with stroke\":\"Latin capital letter h with stroke\",\"Latin capital letter i with breve\":\"Latin capital letter i with breve\",\"Latin capital letter i with dot above\":\"Latin capital letter i with dot above\",\"Latin capital letter i with macron\":\"Latin capital letter i with macron\",\"Latin capital letter i with ogonek\":\"Latin capital letter i with ogonek\",\"Latin capital letter i with tilde\":\"Latin capital letter i with tilde\",\"Latin capital letter j with circumflex\":\"Latin capital letter j with circumflex\",\"Latin capital letter k with cedilla\":\"Latin capital letter k with cedilla\",\"Latin capital letter l with acute\":\"Latin capital letter l with acute\",\"Latin capital letter l with caron\":\"Latin capital letter l with caron\",\"Latin capital letter l with cedilla\":\"Latin capital letter l with cedilla\",\"Latin capital letter l with middle dot\":\"Latin capital letter l with middle dot\",\"Latin capital letter l with stroke\":\"Latin capital letter l with stroke\",\"Latin capital letter n with acute\":\"Latin capital letter n with acute\",\"Latin capital letter n with caron\":\"Latin capital letter n with caron\",\"Latin capital letter n with cedilla\":\"Latin capital letter n with cedilla\",\"Latin capital letter o with breve\":\"Latin capital letter o with breve\",\"Latin capital letter o with double acute\":\"Latin capital letter o with double acute\",\"Latin capital letter o with macron\":\"Latin capital letter o with macron\",\"Latin capital letter r with acute\":\"Latin capital letter r with acute\",\"Latin capital letter r with caron\":\"Latin capital letter r with caron\",\"Latin capital letter r with cedilla\":\"Latin capital letter r with cedilla\",\"Latin capital letter s with acute\":\"Latin capital letter s with acute\",\"Latin capital letter s with caron\":\"Latin capital letter s with caron\",\"Latin capital letter s with cedilla\":\"Latin capital letter s with cedilla\",\"Latin capital letter s with circumflex\":\"Latin capital letter s with circumflex\",\"Latin capital letter t with caron\":\"Latin capital letter t with caron\",\"Latin capital letter t with cedilla\":\"Latin capital letter t with cedilla\",\"Latin capital letter t with stroke\":\"Latin capital letter t with stroke\",\"Latin capital letter u with breve\":\"Latin capital letter u with breve\",\"Latin capital letter u with double acute\":\"Latin capital letter u with double acute\",\"Latin capital letter u with macron\":\"Latin capital letter u with macron\",\"Latin capital letter u with ogonek\":\"Latin capital letter u with ogonek\",\"Latin capital letter u with ring above\":\"Latin capital letter u with ring above\",\"Latin capital letter u with tilde\":\"Latin capital letter u with tilde\",\"Latin capital letter w with circumflex\":\"Latin capital letter w with circumflex\",\"Latin capital letter y with circumflex\":\"Latin capital letter y with circumflex\",\"Latin capital letter y with diaeresis\":\"Latin capital letter y with diaeresis\",\"Latin capital letter z with acute\":\"Latin capital letter z with acute\",\"Latin capital letter z with caron\":\"Latin capital letter z with caron\",\"Latin capital letter z with dot above\":\"Latin capital letter z with dot above\",\"Latin capital ligature ij\":\"Latin capital ligature ij\",\"Latin capital ligature oe\":\"Latin capital ligature oe\",\"Latin small letter a with breve\":\"Latin small letter a with breve\",\"Latin small letter a with macron\":\"Latin small letter a with macron\",\"Latin small letter a with ogonek\":\"Latin small letter a with ogonek\",\"Latin small letter c with acute\":\"Latin small letter c with acute\",\"Latin small letter c with caron\":\"Latin small letter c with caron\",\"Latin small letter c with circumflex\":\"Latin small letter c with circumflex\",\"Latin small letter c with dot above\":\"Latin small letter c with dot above\",\"Latin small letter d with caron\":\"Latin small letter d with caron\",\"Latin small letter d with stroke\":\"Latin small letter d with stroke\",\"Latin small letter dotless i\":\"Latin small letter dotless i\",\"Latin small letter e with breve\":\"Latin small letter e with breve\",\"Latin small letter e with caron\":\"Latin small letter e with caron\",\"Latin small letter e with dot above\":\"Latin small letter e with dot above\",\"Latin small letter e with macron\":\"Latin small letter e with macron\",\"Latin small letter e with ogonek\":\"Latin small letter e with ogonek\",\"Latin small letter eng\":\"Latin small letter eng\",\"Latin small letter f with hook\":\"Latin small letter f with hook\",\"Latin small letter g with breve\":\"Latin small letter g with breve\",\"Latin small letter g with cedilla\":\"Latin small letter g with cedilla\",\"Latin small letter g with circumflex\":\"Latin small letter g with circumflex\",\"Latin small letter g with dot above\":\"Latin small letter g with dot above\",\"Latin small letter h with circumflex\":\"Latin small letter h with circumflex\",\"Latin small letter h with stroke\":\"Latin small letter h with stroke\",\"Latin small letter i with breve\":\"Latin small letter i with breve\",\"Latin small letter i with macron\":\"Latin small letter i with macron\",\"Latin small letter i with ogonek\":\"Latin small letter i with ogonek\",\"Latin small letter i with tilde\":\"Latin small letter i with tilde\",\"Latin small letter j with circumflex\":\"Latin small letter j with circumflex\",\"Latin small letter k with cedilla\":\"Latin small letter k with cedilla\",\"Latin small letter kra\":\"Latin small letter kra\",\"Latin small letter l with acute\":\"Latin small letter l with acute\",\"Latin small letter l with caron\":\"Latin small letter l with caron\",\"Latin small letter l with cedilla\":\"Latin small letter l with cedilla\",\"Latin small letter l with middle dot\":\"Latin small letter l with middle dot\",\"Latin small letter l with stroke\":\"Latin small letter l with stroke\",\"Latin small letter long s\":\"Latin small letter long s\",\"Latin small letter n preceded by apostrophe\":\"Latin small letter n preceded by apostrophe\",\"Latin small letter n with acute\":\"Latin small letter n with acute\",\"Latin small letter n with caron\":\"Latin small letter n with caron\",\"Latin small letter n with cedilla\":\"Latin small letter n with cedilla\",\"Latin small letter o with breve\":\"Latin small letter o with breve\",\"Latin small letter o with double acute\":\"Latin small letter o with double acute\",\"Latin small letter o with macron\":\"Latin small letter o with macron\",\"Latin small letter r with acute\":\"Latin small letter r with acute\",\"Latin small letter r with caron\":\"Latin small letter r with caron\",\"Latin small letter r with cedilla\":\"Latin small letter r with cedilla\",\"Latin small letter s with acute\":\"Latin small letter s with acute\",\"Latin small letter s with caron\":\"Latin small letter s with caron\",\"Latin small letter s with cedilla\":\"Latin small letter s with cedilla\",\"Latin small letter s with circumflex\":\"Latin small letter s with circumflex\",\"Latin small letter t with caron\":\"Latin small letter t with caron\",\"Latin small letter t with cedilla\":\"Latin small letter t with cedilla\",\"Latin small letter t with stroke\":\"Latin small letter t with stroke\",\"Latin small letter u with breve\":\"Latin small letter u with breve\",\"Latin small letter u with double acute\":\"Latin small letter u with double acute\",\"Latin small letter u with macron\":\"Latin small letter u with macron\",\"Latin small letter u with ogonek\":\"Latin small letter u with ogonek\",\"Latin small letter u with ring above\":\"Latin small letter u with ring above\",\"Latin small letter u with tilde\":\"Latin small letter u with tilde\",\"Latin small letter w with circumflex\":\"Latin small letter w with circumflex\",\"Latin small letter y with circumflex\":\"Latin small letter y with circumflex\",\"Latin small letter z with acute\":\"Latin small letter z with acute\",\"Latin small letter z with caron\":\"Latin small letter z with caron\",\"Latin small letter z with dot above\":\"Latin small letter z with dot above\",\"Latin small ligature ij\":\"Latin small ligature ij\",\"Latin small ligature oe\":\"Latin small ligature oe\",\"Left double quotation mark\":\"Left double quotation mark\",\"Left single quotation mark\":\"Left single quotation mark\",\"Left-pointing double angle quotation mark\":\"Left-pointing double angle quotation mark\",\"leftwards arrow to bar\":\"leftwards arrow to bar\",\"leftwards dashed arrow\":\"leftwards dashed arrow\",\"leftwards double arrow\":\"leftwards double arrow\",\"Less-than or equal to\":\"Less-than or equal to\",\"Less-than sign\":\"Less-than sign\",\"Light blue\":\"Light blue\",\"Light green\":\"Light green\",\"Light grey\":\"Light grey\",Link:\"Link\",\"Link URL\":\"Link URL\",\"Lira sign\":\"Lira sign\",\"Livre tournois sign\":\"Livre tournois sign\",\"Logical and\":\"Logical and\",\"Logical or\":\"Logical or\",Macron:\"Macron\",\"Manat sign\":\"Manat sign\",\"Merge cell down\":\"Merge cell down\",\"Merge cell left\":\"Merge cell left\",\"Merge cell right\":\"Merge cell right\",\"Merge cell up\":\"Merge cell up\",\"Merge cells\":\"Merge cells\",\"Mill sign\":\"Mill sign\",\"Minus sign\":\"Minus sign\",\"Multiplication sign\":\"Multiplication sign\",\"N-ary product\":\"N-ary product\",\"N-ary summation\":\"N-ary summation\",Nabla:\"Nabla\",\"Naira sign\":\"Naira sign\",\"New sheqel sign\":\"New sheqel sign\",Next:\"Next\",None:\"None\",\"Nordic mark sign\":\"Nordic mark sign\",\"Not an element of\":\"Not an element of\",\"Not equal to\":\"Not equal to\",\"Not sign\":\"Not sign\",\"on with exclamation mark with left right arrow above\":\"on with exclamation mark with left right arrow above\",\"Open in a new tab\":\"Open in a new tab\",\"Open link in new tab\":\"Open link in new tab\",Orange:\"Orange\",Outset:\"Outset\",Overline:\"Overline\",Padding:\"Padding\",Paragraph:\"Paragraph\",\"Paragraph sign\":\"Paragraph sign\",\"Partial differential\":\"Partial differential\",\"Per mille sign\":\"Per mille sign\",\"Per ten thousand sign\":\"Per ten thousand sign\",\"Peseta sign\":\"Peseta sign\",\"Peso sign\":\"Peso sign\",\"Pink marker\":\"Pink marker\",\"Plain text\":\"Plain text\",\"Plus-minus sign\":\"Plus-minus sign\",\"Pound sign\":\"Pound sign\",Previous:\"Previous\",\"Proportional to\":\"Proportional to\",Purple:\"Purple\",\"Question exclamation mark\":\"Question exclamation mark\",Red:\"Red\",\"Red pen\":\"Red pen\",Redo:\"Redo\",\"Registered sign\":\"Registered sign\",\"Remove color\":\"Remove color\",\"Remove Format\":\"Remove Format\",\"Remove highlight\":\"Remove highlight\",\"Reversed paragraph sign\":\"Reversed paragraph sign\",\"Rich Text Editor\":\"Rich Text Editor\",\"Rich Text Editor, %0\":\"Rich Text Editor, %0\",Ridge:\"Ridge\",\"Right double quotation mark\":\"Right double quotation mark\",\"Right single quotation mark\":\"Right single quotation mark\",\"Right-pointing double angle quotation mark\":\"Right-pointing double angle quotation mark\",\"rightwards arrow to bar\":\"rightwards arrow to bar\",\"rightwards dashed arrow\":\"rightwards dashed arrow\",\"rightwards double arrow\":\"rightwards double arrow\",Row:\"Row\",\"Ruble sign\":\"Ruble sign\",\"Rupee sign\":\"Rupee sign\",Save:\"Save\",\"Section sign\":\"Section sign\",\"Select all\":\"Select all\",\"Select column\":\"Select column\",\"Select row\":\"Select row\",\"Show more items\":\"Show more items\",\"Single left-pointing angle quotation mark\":\"Single left-pointing angle quotation mark\",\"Single low-9 quotation mark\":\"Single low-9 quotation mark\",\"Single right-pointing angle quotation mark\":\"Single right-pointing angle quotation mark\",Small:\"Small\",Solid:\"Solid\",\"soon with rightwards arrow above\":\"soon with rightwards arrow above\",\"Special characters\":\"Special characters\",\"Spesmilo sign\":\"Spesmilo sign\",\"Split cell horizontally\":\"Split cell horizontally\",\"Split cell vertically\":\"Split cell vertically\",\"Square root\":\"Square root\",Strikethrough:\"Strikethrough\",Style:\"Style\",Subscript:\"Subscript\",Superscript:\"Superscript\",\"Table alignment toolbar\":\"Table alignment toolbar\",\"Table cell text alignment\":\"Table cell text alignment\",\"Table properties\":\"Table properties\",\"Table toolbar\":\"Table toolbar\",\"Tenge sign\":\"Tenge sign\",\"Text alignment\":\"Text alignment\",\"Text alignment toolbar\":\"Text alignment toolbar\",\"Text highlight toolbar\":\"Text highlight toolbar\",'The color is invalid. Try \"#FF0000\" or \"rgb(255,0,0)\" or \"red\".':'The color is invalid. Try \"#FF0000\" or \"rgb(255,0,0)\" or \"red\".','The value is invalid. Try \"10px\" or \"2em\" or simply \"2\".':'The value is invalid. Try \"10px\" or \"2em\" or simply \"2\".',\"There exists\":\"There exists\",\"This link has no URL\":\"This link has no URL\",\"Tilde operator\":\"Tilde operator\",Tiny:\"Tiny\",\"top with upwards arrow above\":\"top with upwards arrow above\",\"Trade mark sign\":\"Trade mark sign\",\"Tugrik sign\":\"Tugrik sign\",\"Turkish lira sign\":\"Turkish lira sign\",Turquoise:\"Turquoise\",\"Two dot leader\":\"Two dot leader\",Underline:\"Underline\",Undo:\"Undo\",Union:\"Union\",Unlink:\"Unlink\",\"up down arrow with base\":\"up down arrow with base\",\"upwards arrow to bar\":\"upwards arrow to bar\",\"upwards dashed arrow\":\"upwards dashed arrow\",\"upwards double arrow\":\"upwards double arrow\",\"Vertical text alignment toolbar\":\"Vertical text alignment toolbar\",\"Vulgar fraction one half\":\"Vulgar fraction one half\",\"Vulgar fraction one quarter\":\"Vulgar fraction one quarter\",\"Vulgar fraction three quarters\":\"Vulgar fraction three quarters\",White:\"White\",\"Widget toolbar\":\"Widget toolbar\",Width:\"Width\",\"Won sign\":\"Won sign\",\"Words: %0\":\"Words: %0\",Yellow:\"Yellow\",\"Yellow marker\":\"Yellow marker\",\"Yen sign\":\"Yen sign\"})})(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={}));(function t(e,i){if(typeof exports===\"object\"&&typeof module===\"object\")module.exports=i();else if(typeof define===\"function\"&&define.amd)define([],i);else if(typeof exports===\"object\")exports[\"ClassicEditor\"]=i();else e[\"ClassicEditor\"]=i()})(window,(function(){return function(t){var e={};function i(n){if(e[n]){return e[n].exports}var o=e[n]={i:n,l:false,exports:{}};t[n].call(o.exports,o,o.exports,i);o.l=true;return o.exports}i.m=t;i.c=e;i.d=function(t,e,n){if(!i.o(t,e)){Object.defineProperty(t,e,{enumerable:true,get:n})}};i.r=function(t){if(typeof Symbol!==\"undefined\"&&Symbol.toStringTag){Object.defineProperty(t,Symbol.toStringTag,{value:\"Module\"})}Object.defineProperty(t,\"__esModule\",{value:true})};i.t=function(t,e){if(e&1)t=i(t);if(e&8)return t;if(e&4&&typeof t===\"object\"&&t&&t.__esModule)return t;var n=Object.create(null);i.r(n);Object.defineProperty(n,\"default\",{enumerable:true,value:t});if(e&2&&typeof t!=\"string\")for(var o in t)i.d(n,o,function(e){return t[e]}.bind(null,o));return n};i.n=function(t){var e=t&&t.__esModule?function e(){return t[\"default\"]}:function e(){return t};i.d(e,\"a\",e);return e};i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};i.p=\"\";return i(i.s=114)}([function(t,e,i){\"use strict\";i.d(e,\"b\",(function(){return o}));i.d(e,\"a\",(function(){return r}));const n=\"https://ckeditor.com/docs/ckeditor5/latest/framework/guides/support/error-codes.html\";class o extends Error{constructor(t,e,i){t=r(t);if(i){t+=\" \"+JSON.stringify(i)}super(t);this.name=\"CKEditorError\";this.context=e;this.data=i}is(t){return t===\"CKEditorError\"}static rethrowUnexpectedError(t,e){if(t.is&&t.is(\"CKEditorError\")){throw t}const i=new o(t.message,e);i.stack=t.stack;throw i}}function r(t){const e=t.match(/^([^:]+):/);if(!e){return t}return t+` Read more: ${n}#error-${e[1]}\\n`}},function(t,e,i){\"use strict\";var n=function t(){var e;return function t(){if(typeof e===\"undefined\"){e=Boolean(window&&document&&document.all&&!window.atob)}return e}}();var o=function t(){var e={};return function t(i){if(typeof e[i]===\"undefined\"){var n=document.querySelector(i);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement){try{n=n.contentDocument.head}catch(t){n=null}}e[i]=n}return e[i]}}();var r=[];function s(t){var e=-1;for(var i=0;i<r.length;i++){if(r[i].identifier===t){e=i;break}}return e}function a(t,e){var i={};var n=[];for(var o=0;o<t.length;o++){var a=t[o];var l=e.base?a[0]+e.base:a[0];var c=i[l]||0;var d=\"\".concat(l,\" \").concat(c);i[l]=c+1;var u=s(d);var h={css:a[1],media:a[2],sourceMap:a[3]};if(u!==-1){r[u].references++;r[u].updater(h)}else{r.push({identifier:d,updater:g(h,e),references:1})}n.push(d)}return n}function l(t){var e=document.createElement(\"style\");var n=t.attributes||{};if(typeof n.nonce===\"undefined\"){var r=true?i.nc:undefined;if(r){n.nonce=r}}Object.keys(n).forEach((function(t){e.setAttribute(t,n[t])}));if(typeof t.insert===\"function\"){t.insert(e)}else{var s=o(t.insert||\"head\");if(!s){throw new Error(\"Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.\")}s.appendChild(e)}return e}function c(t){if(t.parentNode===null){return false}t.parentNode.removeChild(t)}var d=function t(){var e=[];return function t(i,n){e[i]=n;return e.filter(Boolean).join(\"\\n\")}}();function u(t,e,i,n){var o=i?\"\":n.media?\"@media \".concat(n.media,\" {\").concat(n.css,\"}\"):n.css;if(t.styleSheet){t.styleSheet.cssText=d(e,o)}else{var r=document.createTextNode(o);var s=t.childNodes;if(s[e]){t.removeChild(s[e])}if(s.length){t.insertBefore(r,s[e])}else{t.appendChild(r)}}}function h(t,e,i){var n=i.css;var o=i.media;var r=i.sourceMap;if(o){t.setAttribute(\"media\",o)}else{t.removeAttribute(\"media\")}if(r&&btoa){n+=\"\\n/*# sourceMappingURL=data:application/json;base64,\".concat(btoa(unescape(encodeURIComponent(JSON.stringify(r)))),\" */\")}if(t.styleSheet){t.styleSheet.cssText=n}else{while(t.firstChild){t.removeChild(t.firstChild)}t.appendChild(document.createTextNode(n))}}var f=null;var m=0;function g(t,e){var i;var n;var o;if(e.singleton){var r=m++;i=f||(f=l(e));n=u.bind(null,i,r,false);o=u.bind(null,i,r,true)}else{i=l(e);n=h.bind(null,i,e);o=function t(){c(i)}}n(t);return function e(i){if(i){if(i.css===t.css&&i.media===t.media&&i.sourceMap===t.sourceMap){return}n(t=i)}else{o()}}}t.exports=function(t,e){e=e||{};if(!e.singleton&&typeof e.singleton!==\"boolean\"){e.singleton=n()}t=t||[];var i=a(t,e);return function t(n){n=n||[];if(Object.prototype.toString.call(n)!==\"[object Array]\"){return}for(var o=0;o<i.length;o++){var l=i[o];var c=s(l);r[c].references--}var d=a(n,e);for(var u=0;u<i.length;u++){var h=i[u];var f=s(h);if(r[f].references===0){r[f].updater();r.splice(f,1)}}i=d}}},,function(t,e,i){\"use strict\";var n=i(7);var o=typeof self==\"object\"&&self&&self.Object===Object&&self;var r=n[\"a\"]||o||Function(\"return this\")();e[\"a\"]=r},function(t,e,i){\"use strict\";(function(t){var n=i(3);var o=i(15);var r=typeof exports==\"object\"&&exports&&!exports.nodeType&&exports;var s=r&&typeof t==\"object\"&&t&&!t.nodeType&&t;var a=s&&s.exports===r;var l=a?n[\"a\"].Buffer:undefined;var c=l?l.isBuffer:undefined;var d=c||o[\"a\"];e[\"a\"]=d}).call(this,i(9)(t))},function(t,e,i){\"use strict\";(function(t){var n=i(7);var o=typeof exports==\"object\"&&exports&&!exports.nodeType&&exports;var r=o&&typeof t==\"object\"&&t&&!t.nodeType&&t;var s=r&&r.exports===o;var a=s&&n[\"a\"].process;var l=function(){try{var t=r&&r.require&&r.require(\"util\").types;if(t){return t}return a&&a.binding&&a.binding(\"util\")}catch(t){}}();e[\"a\"]=l}).call(this,i(9)(t))},function(t,e,i){\"use strict\";(function(t){var e=i(0);const n=\"19.1.1\";const o=typeof window===\"object\"?window:t;if(o.CKEDITOR_VERSION){throw new e[\"b\"](\"ckeditor-duplicated-modules: Some CKEditor 5 modules are duplicated.\",null)}else{o.CKEDITOR_VERSION=n}}).call(this,i(10))},function(t,e,i){\"use strict\";(function(t){var i=typeof t==\"object\"&&t&&t.Object===Object&&t;e[\"a\"]=i}).call(this,i(10))},function(t,e,i){\"use strict\";(function(t){var n=i(3);var o=typeof exports==\"object\"&&exports&&!exports.nodeType&&exports;var r=o&&typeof t==\"object\"&&t&&!t.nodeType&&t;var s=r&&r.exports===o;var a=s?n[\"a\"].Buffer:undefined,l=a?a.allocUnsafe:undefined;function c(t,e){if(e){return t.slice()}var i=t.length,n=l?l(i):new t.constructor(i);t.copy(n);return n}e[\"a\"]=c}).call(this,i(9)(t))},function(t,e){t.exports=function(t){if(!t.webpackPolyfill){var e=Object.create(t);if(!e.children)e.children=[];Object.defineProperty(e,\"loaded\",{enumerable:true,get:function(){return e.l}});Object.defineProperty(e,\"id\",{enumerable:true,get:function(){return e.i}});Object.defineProperty(e,\"exports\",{enumerable:true});e.webpackPolyfill=1}return e}},function(t,e){var i;i=function(){return this}();try{i=i||new Function(\"return this\")()}catch(t){if(typeof window===\"object\")i=window}t.exports=i},function(t,e,i){var n=i(1);var o=i(49);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e,i){var n=i(1);var o=i(60);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e,i){var n=i(1);var o=i(108);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e,i){var n=i(1);var o=i(109);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e,i){\"use strict\";function n(){return false}e[\"a\"]=n},function(t){t.exports=JSON.parse('{\"ar\":{\"latex\":\"LaTeX\",\"cancel\":\"إلغاء\",\"accept\":\"موا�?ق\",\"manual\":\"الدليل\",\"insert_math\":\"إدراج صيغة رياضية - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"ca\":{\"latex\":\"LaTeX\",\"cancel\":\"Cancel·lar\",\"accept\":\"Acceptar\",\"manual\":\"Manual\",\"insert_math\":\"Inserir fórmula matemàtica - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"cs\":{\"latex\":\"LaTeX\",\"cancel\":\"Storno\",\"accept\":\"OK\",\"manual\":\"Příru�?ka\",\"insert_math\":\"Vložit matematický vzorec - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"da\":{\"latex\":\"LaTeX\",\"cancel\":\"Annuller\",\"accept\":\"OK\",\"manual\":\"Brugervejledning\",\"insert_math\":\"Indsæt matematisk formel - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"de\":{\"latex\":\"LaTeX\",\"cancel\":\"Abbrechen\",\"accept\":\"OK\",\"manual\":\"Handbuch\",\"insert_math\":\"Mathematische Formel einfügen - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"en\":{\"latex\":\"LaTeX\",\"cancel\":\"Cancel\",\"accept\":\"OK\",\"manual\":\"Manual\",\"insert_math\":\"Insert a math equation - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"es\":{\"latex\":\"LaTeX\",\"cancel\":\"Cancelar\",\"accept\":\"Aceptar\",\"manual\":\"Manual\",\"insert_math\":\"Insertar fórmula matemática - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"et\":{\"latex\":\"LaTeX\",\"cancel\":\"Loobu\",\"accept\":\"OK\",\"manual\":\"Käsiraamat\",\"insert_math\":\"Lisa matemaatiline valem – WIRIS\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"eu\":{\"latex\":\"LaTeX\",\"cancel\":\"Ezeztatu\",\"accept\":\"Onartu\",\"manual\":\"Gida\",\"insert_math\":\"Txertatu matematikako formula - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"fi\":{\"latex\":\"LaTeX\",\"cancel\":\"Peruuta\",\"accept\":\"OK\",\"manual\":\"Manual\",\"insert_math\":\"Liitä matemaattinen kaava - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"fr\":{\"latex\":\"LaTeX\",\"cancel\":\"Annuler\",\"accept\":\"OK\",\"manual\":\"Manuel\",\"insert_math\":\"Insérer une formule mathématique - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"gl\":{\"latex\":\"LaTeX\",\"cancel\":\"Cancelar\",\"accept\":\"Aceptar\",\"manual\":\"Manual\",\"insert_math\":\"Inserir fórmula matemática - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"he\":{\"latex\":\"LaTeX\",\"cancel\":\"ביטול\",\"accept\":\"�?ישור\",\"manual\":\"מדריך\",\"insert_math\":\"הוסף נוסחה מתמטית - MathType\",\"insert_chem\":\"הוספת כתיבה כימית - ChemType\",\"minimize\":\"מזערי\",\"maximize\":\"מרבי\",\"fullscreen\":\"מסך מל�?\",\"exit_fullscreen\":\"יצי�?ה ממצב מסך מל�?\",\"close\":\"סגירה\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"ה�?�? לצ�?ת? שינויי�? �?שר בוצעו ימחקו.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" �?יננה פונקציה\",\"exception_invalid_date_format\":\"תסדיר ת�?ריך �?ינו תקין : \",\"exception_casting\":\"ל�? ניתן להמיר \",\"exception_casting_to\":\" ל \"},\"hr\":{\"latex\":\"LaTeX\",\"cancel\":\"Poništi\",\"accept\":\"U redu\",\"manual\":\"Priru�?nik\",\"insert_math\":\"Umetnite matemati�?ku formulu - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"hu\":{\"latex\":\"LaTeX\",\"cancel\":\"Mégsem\",\"accept\":\"OK\",\"manual\":\"Kézikönyv\",\"insert_math\":\"Matematikai képlet beszúrása - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"it\":{\"latex\":\"LaTeX\",\"cancel\":\"Annulla\",\"accept\":\"Accetta\",\"manual\":\"Manuale\",\"insert_math\":\"Inserisci una formula matematica - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"ja\":{\"latex\":\"LaTeX\",\"cancel\":\"キャンセル\",\"accept\":\"OK\",\"manual\":\"マニュアル\",\"insert_math\":\"数�?を挿入 - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"ko\":{\"latex\":\"LaTeX\",\"cancel\":\"취소\",\"accept\":\"승�?�\",\"manual\":\"설명서\",\"insert_math\":\"수학 공�? 삽입 - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"nl\":{\"latex\":\"LaTeX\",\"cancel\":\"Annuleren\",\"accept\":\"OK\",\"manual\":\"Handleiding\",\"insert_math\":\"Wiskundige formule invoegen - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"no\":{\"latex\":\"LaTeX\",\"cancel\":\"Avbryt\",\"accept\":\"OK\",\"manual\":\"Håndbok\",\"insert_math\":\"Sett inn matematikkformel - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"pl\":{\"latex\":\"LaTeX\",\"cancel\":\"Anuluj\",\"accept\":\"OK\",\"manual\":\"Instrukcja\",\"insert_math\":\"Wstaw formułę matematyczną - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"pt\":{\"latex\":\"LaTeX\",\"cancel\":\"Cancelar\",\"accept\":\"OK\",\"manual\":\"Manual\",\"insert_math\":\"Inserir fórmula matemática - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"pt_br\":{\"latex\":\"LaTeX\",\"cancel\":\"Cancelar\",\"accept\":\"OK\",\"manual\":\"Manual\",\"insert_math\":\"Inserir fórmula matemática - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"ru\":{\"latex\":\"LaTeX\",\"cancel\":\"отмена\",\"accept\":\"OK\",\"manual\":\"вручную\",\"insert_math\":\"В�?тавить математиче�?кую формулу: WIRIS\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"sv\":{\"latex\":\"LaTeX\",\"cancel\":\"Avbryt\",\"accept\":\"OK\",\"manual\":\"Bruksanvisning\",\"insert_math\":\"Infoga matematisk formel - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"tr\":{\"latex\":\"LaTeX\",\"cancel\":\"Vazgeç\",\"accept\":\"Tamam\",\"manual\":\"Kılavuz\",\"insert_math\":\"Matematik formülü ekle - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"zh\":{\"latex\":\"LaTeX\",\"cancel\":\"�?�消\",\"accept\":\"确定\",\"manual\":\"手册\",\"insert_math\":\"�?�入数学公�? - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"el\":{\"latex\":\"LaTeX\",\"cancel\":\"Άκυ�?ο\",\"accept\":\"ΟΚ\",\"manual\":\"Χει�?οκίνητα\",\"insert_math\":\"Εισαγωγή μαθηματικο�? τ�?που - MathType\",\"insert_chem\":\"Insert a chemistry formula - ChemType\",\"minimize\":\"Minimize\",\"maximize\":\"Maximize\",\"fullscreen\":\"Full-screen\",\"exit_fullscreen\":\"Exit full-screen\",\"close\":\"Close\",\"mathtype\":\"MathType\",\"title_modalwindow\":\"MathType modal window\",\"close_modal_warning\":\"Are you sure you want to leave? The changes you made will be lost.\",\"latex_name_label\":\"Latex Formula\",\"browser_no_compatible\":\"Your browser is not compatible with AJAX technology. Please, use the latest version of Mozilla Firefox.\",\"error_convert_accessibility\":\"Error converting from MathML to accessible text.\",\"exception_cross_site\":\"Cross site scripting is only allowed for HTTP.\",\"exception_high_surrogate\":\"High surrogate not followed by low surrogate in fixedCharCodeAt()\",\"exception_string_length\":\"Invalid string. Length must be a multiple of 4\",\"exception_key_nonobject\":\"Object.keys called on non-object\",\"exception_null_or_undefined\":\" this is null or not defined\",\"exception_not_function\":\" is not a function\",\"exception_invalid_date_format\":\"Invalid date format : \",\"exception_casting\":\"Cannot cast \",\"exception_casting_to\":\" to \"},\"\":{}}')},function(t,e,i){var n=i(1);var o=i(18);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-placeholder:before,.ck .ck-placeholder:before{content:attr(data-placeholder);pointer-events:none}.ck.ck-read-only .ck-placeholder:before{display:none}.ck.ck-placeholder:before,.ck .ck-placeholder:before{cursor:text;color:var(--ck-color-engine-placeholder-text)}\"},function(t,e,i){var n=i(1);var o=i(20);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck-hidden{display:none!important}.ck.ck-reset,.ck.ck-reset_all,.ck.ck-reset_all *{box-sizing:border-box;width:auto;height:auto;position:static}:root{--ck-z-default:1;--ck-z-modal:calc(var(--ck-z-default) + 999);--ck-color-base-foreground:#fafafa;--ck-color-base-background:#fff;--ck-color-base-border:#c4c4c4;--ck-color-base-action:#61b045;--ck-color-base-focus:#6cb5f9;--ck-color-base-text:#333;--ck-color-base-active:#198cf0;--ck-color-base-active-focus:#0e7fe1;--ck-color-base-error:#db3700;--ck-color-focus-border-coordinates:208,79%,51%;--ck-color-focus-border:hsl(var(--ck-color-focus-border-coordinates));--ck-color-focus-outer-shadow:#bcdefb;--ck-color-focus-disabled-shadow:rgba(119,186,248,0.3);--ck-color-focus-error-shadow:rgba(255,64,31,0.3);--ck-color-text:var(--ck-color-base-text);--ck-color-shadow-drop:rgba(0,0,0,0.15);--ck-color-shadow-drop-active:rgba(0,0,0,0.2);--ck-color-shadow-inner:rgba(0,0,0,0.1);--ck-color-button-default-background:transparent;--ck-color-button-default-hover-background:#e6e6e6;--ck-color-button-default-active-background:#d9d9d9;--ck-color-button-default-active-shadow:#bfbfbf;--ck-color-button-default-disabled-background:transparent;--ck-color-button-on-background:#dedede;--ck-color-button-on-hover-background:#c4c4c4;--ck-color-button-on-active-background:#bababa;--ck-color-button-on-active-shadow:#a1a1a1;--ck-color-button-on-disabled-background:#dedede;--ck-color-button-action-background:var(--ck-color-base-action);--ck-color-button-action-hover-background:#579e3d;--ck-color-button-action-active-background:#53973b;--ck-color-button-action-active-shadow:#498433;--ck-color-button-action-disabled-background:#7ec365;--ck-color-button-action-text:var(--ck-color-base-background);--ck-color-button-save:#008a00;--ck-color-button-cancel:#db3700;--ck-color-switch-button-off-background:#b0b0b0;--ck-color-switch-button-off-hover-background:#a3a3a3;--ck-color-switch-button-on-background:var(--ck-color-button-action-background);--ck-color-switch-button-on-hover-background:#579e3d;--ck-color-switch-button-inner-background:var(--ck-color-base-background);--ck-color-switch-button-inner-shadow:rgba(0,0,0,0.1);--ck-color-dropdown-panel-background:var(--ck-color-base-background);--ck-color-dropdown-panel-border:var(--ck-color-base-border);--ck-color-input-background:var(--ck-color-base-background);--ck-color-input-border:#c7c7c7;--ck-color-input-error-border:var(--ck-color-base-error);--ck-color-input-text:var(--ck-color-base-text);--ck-color-input-disabled-background:#f2f2f2;--ck-color-input-disabled-border:#c7c7c7;--ck-color-input-disabled-text:#5c5c5c;--ck-color-list-background:var(--ck-color-base-background);--ck-color-list-button-hover-background:var(--ck-color-button-default-hover-background);--ck-color-list-button-on-background:var(--ck-color-base-active);--ck-color-list-button-on-background-focus:var(--ck-color-base-active-focus);--ck-color-list-button-on-text:var(--ck-color-base-background);--ck-color-panel-background:var(--ck-color-base-background);--ck-color-panel-border:var(--ck-color-base-border);--ck-color-toolbar-background:var(--ck-color-base-foreground);--ck-color-toolbar-border:var(--ck-color-base-border);--ck-color-tooltip-background:var(--ck-color-base-text);--ck-color-tooltip-text:var(--ck-color-base-background);--ck-color-engine-placeholder-text:#707070;--ck-color-upload-bar-background:#6cb5f9;--ck-color-link-default:#0000f0;--ck-color-link-selected-background:rgba(31,177,255,0.1);--ck-disabled-opacity:.5;--ck-focus-outer-shadow-geometry:0 0 0 3px;--ck-focus-outer-shadow:var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-outer-shadow);--ck-focus-disabled-outer-shadow:var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-disabled-shadow);--ck-focus-error-outer-shadow:var(--ck-focus-outer-shadow-geometry) var(--ck-color-focus-error-shadow);--ck-focus-ring:1px solid var(--ck-color-focus-border);--ck-font-size-base:13px;--ck-line-height-base:1.84615;--ck-font-face:Helvetica,Arial,Tahoma,Verdana,Sans-Serif;--ck-font-size-tiny:0.7em;--ck-font-size-small:0.75em;--ck-font-size-normal:1em;--ck-font-size-big:1.4em;--ck-font-size-large:1.8em;--ck-ui-component-min-height:2.3em}.ck.ck-reset,.ck.ck-reset_all,.ck.ck-reset_all *{margin:0;padding:0;border:0;background:transparent;text-decoration:none;vertical-align:middle;transition:none;word-wrap:break-word}.ck.ck-reset_all,.ck.ck-reset_all *{border-collapse:collapse;font:normal normal normal var(--ck-font-size-base)/var(--ck-line-height-base) var(--ck-font-face);color:var(--ck-color-text);text-align:left;white-space:nowrap;cursor:auto;float:none}.ck.ck-reset_all .ck-rtl *{text-align:right}.ck.ck-reset_all iframe{vertical-align:inherit}.ck.ck-reset_all textarea{white-space:pre-wrap}.ck.ck-reset_all input[type=password],.ck.ck-reset_all input[type=text],.ck.ck-reset_all textarea{cursor:text}.ck.ck-reset_all input[type=password][disabled],.ck.ck-reset_all input[type=text][disabled],.ck.ck-reset_all textarea[disabled]{cursor:default}.ck.ck-reset_all fieldset{padding:10px;border:2px groove #dfdee3}.ck.ck-reset_all button::-moz-focus-inner{padding:0;border:0}.ck[dir=rtl],.ck[dir=rtl] .ck{text-align:right}:root{--ck-border-radius:2px;--ck-inner-shadow:2px 2px 3px var(--ck-color-shadow-inner) inset;--ck-drop-shadow:0 1px 2px 1px var(--ck-color-shadow-drop);--ck-drop-shadow-active:0 3px 6px 1px var(--ck-color-shadow-drop-active);--ck-spacing-unit:0.6em;--ck-spacing-large:calc(var(--ck-spacing-unit)*1.5);--ck-spacing-standard:var(--ck-spacing-unit);--ck-spacing-medium:calc(var(--ck-spacing-unit)*0.8);--ck-spacing-small:calc(var(--ck-spacing-unit)*0.5);--ck-spacing-tiny:calc(var(--ck-spacing-unit)*0.3);--ck-spacing-extra-tiny:calc(var(--ck-spacing-unit)*0.16)}\"},function(t,e,i){var n=i(1);var o=i(22);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\":root{--ck-color-editable-blur-selection:#d9d9d9}.ck.ck-editor__editable:not(.ck-editor__nested-editable){border-radius:0}.ck-rounded-corners .ck.ck-editor__editable:not(.ck-editor__nested-editable),.ck.ck-editor__editable:not(.ck-editor__nested-editable).ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-editor__editable:not(.ck-editor__nested-editable).ck-focused{outline:none;border:var(--ck-focus-ring);box-shadow:var(--ck-inner-shadow),0 0}.ck.ck-editor__editable_inline{overflow:auto;padding:0 var(--ck-spacing-standard);border:1px solid transparent}.ck.ck-editor__editable_inline[dir=ltr]{text-align:left}.ck.ck-editor__editable_inline[dir=rtl]{text-align:right}.ck.ck-editor__editable_inline>:first-child{margin-top:var(--ck-spacing-large)}.ck.ck-editor__editable_inline>:last-child{margin-bottom:var(--ck-spacing-large)}.ck.ck-editor__editable_inline.ck-blurred ::selection{background:var(--ck-color-editable-blur-selection)}.ck.ck-balloon-panel.ck-toolbar-container[class*=arrow_n]:after{border-bottom-color:var(--ck-color-base-foreground)}.ck.ck-balloon-panel.ck-toolbar-container[class*=arrow_s]:after{border-top-color:var(--ck-color-base-foreground)}\"},function(t,e,i){var n=i(1);var o=i(24);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-label{display:block}.ck.ck-voice-label{display:none}.ck.ck-label{font-weight:700}\"},function(t,e,i){var n=i(1);var o=i(26);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-sticky-panel .ck-sticky-panel__content_sticky{z-index:var(--ck-z-modal);position:fixed;top:0}.ck.ck-sticky-panel .ck-sticky-panel__content_sticky_bottom-limit{top:auto;position:absolute}.ck.ck-sticky-panel .ck-sticky-panel__content_sticky{box-shadow:var(--ck-drop-shadow),0 0;border-width:0 1px 1px;border-top-left-radius:0;border-top-right-radius:0}\"},function(t,e,i){var n=i(1);var o=i(28);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-dropdown{display:inline-block;position:relative}.ck.ck-dropdown .ck-dropdown__arrow{pointer-events:none;z-index:var(--ck-z-default)}.ck.ck-dropdown .ck-button.ck-dropdown__button{width:100%}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-on .ck-tooltip{display:none}.ck.ck-dropdown .ck-dropdown__panel{-webkit-backface-visibility:hidden;display:none;z-index:var(--ck-z-modal);position:absolute}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel-visible{display:inline-block}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_ne,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nw{bottom:100%}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_se,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_sw{top:100%;bottom:auto}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_ne,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_se{left:0}.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_nw,.ck.ck-dropdown .ck-dropdown__panel.ck-dropdown__panel_sw{right:0}:root{--ck-dropdown-arrow-size:calc(0.5*var(--ck-icon-size))}.ck.ck-dropdown{font-size:inherit}.ck.ck-dropdown .ck-dropdown__arrow{width:var(--ck-dropdown-arrow-size)}[dir=ltr] .ck.ck-dropdown .ck-dropdown__arrow{right:var(--ck-spacing-standard);margin-left:var(--ck-spacing-standard)}[dir=rtl] .ck.ck-dropdown .ck-dropdown__arrow{left:var(--ck-spacing-standard);margin-right:var(--ck-spacing-small)}.ck.ck-dropdown.ck-disabled .ck-dropdown__arrow{opacity:var(--ck-disabled-opacity)}[dir=ltr] .ck.ck-dropdown .ck-button.ck-dropdown__button:not(.ck-button_with-text){padding-left:var(--ck-spacing-small)}[dir=rtl] .ck.ck-dropdown .ck-button.ck-dropdown__button:not(.ck-button_with-text){padding-right:var(--ck-spacing-small)}.ck.ck-dropdown .ck-button.ck-dropdown__button .ck-button__label{width:7em;overflow:hidden;text-overflow:ellipsis}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-disabled .ck-button__label{opacity:var(--ck-disabled-opacity)}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-on{border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-dropdown .ck-button.ck-dropdown__button.ck-dropdown__button_label-width_auto .ck-button__label{width:auto}.ck.ck-dropdown__panel{border-radius:0}.ck-rounded-corners .ck.ck-dropdown__panel,.ck.ck-dropdown__panel.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-dropdown__panel{box-shadow:var(--ck-drop-shadow),0 0;background:var(--ck-color-dropdown-panel-background);border:1px solid var(--ck-color-dropdown-panel-border);bottom:0;min-width:100%}.ck.ck-dropdown__panel.ck-dropdown__panel_se{border-top-left-radius:0}.ck.ck-dropdown__panel.ck-dropdown__panel_sw{border-top-right-radius:0}.ck.ck-dropdown__panel.ck-dropdown__panel_ne{border-bottom-left-radius:0}.ck.ck-dropdown__panel.ck-dropdown__panel_nw{border-bottom-right-radius:0}\"},function(t,e,i){var n=i(1);var o=i(30);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-icon{vertical-align:middle}:root{--ck-icon-size:calc(var(--ck-line-height-base)*var(--ck-font-size-normal))}.ck.ck-icon{width:var(--ck-icon-size);height:var(--ck-icon-size);font-size:.8333350694em;will-change:transform}.ck.ck-icon,.ck.ck-icon *{color:inherit;cursor:inherit}.ck.ck-icon :not([fill]){fill:currentColor}\"},function(t,e,i){var n=i(1);var o=i(32);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports='.ck.ck-tooltip,.ck.ck-tooltip .ck-tooltip__text:after{position:absolute;pointer-events:none;-webkit-backface-visibility:hidden}.ck.ck-tooltip{visibility:hidden;opacity:0;display:none;z-index:var(--ck-z-modal)}.ck.ck-tooltip .ck-tooltip__text{display:inline-block}.ck.ck-tooltip .ck-tooltip__text:after{content:\"\";width:0;height:0}:root{--ck-tooltip-arrow-size:5px}.ck.ck-tooltip{left:50%;top:0;transition:opacity .2s ease-in-out .2s}.ck.ck-tooltip .ck-tooltip__text{border-radius:0}.ck-rounded-corners .ck.ck-tooltip .ck-tooltip__text,.ck.ck-tooltip .ck-tooltip__text.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-tooltip .ck-tooltip__text{font-size:.9em;line-height:1.5;color:var(--ck-color-tooltip-text);padding:var(--ck-spacing-small) var(--ck-spacing-medium);background:var(--ck-color-tooltip-background);position:relative;left:-50%}.ck.ck-tooltip .ck-tooltip__text:after{transition:opacity .2s ease-in-out .2s;border-style:solid;left:50%}.ck.ck-tooltip.ck-tooltip_s{bottom:calc(-1*var(--ck-tooltip-arrow-size));transform:translateY(100%)}.ck.ck-tooltip.ck-tooltip_s .ck-tooltip__text:after{top:calc(-1*var(--ck-tooltip-arrow-size));transform:translateX(-50%);border-left-color:transparent;border-bottom-color:var(--ck-color-tooltip-background);border-right-color:transparent;border-top-color:transparent;border-left-width:var(--ck-tooltip-arrow-size);border-bottom-width:var(--ck-tooltip-arrow-size);border-right-width:var(--ck-tooltip-arrow-size);border-top-width:0}.ck.ck-tooltip.ck-tooltip_n{top:calc(-1*var(--ck-tooltip-arrow-size));transform:translateY(-100%)}.ck.ck-tooltip.ck-tooltip_n .ck-tooltip__text:after{bottom:calc(-1*var(--ck-tooltip-arrow-size));transform:translateX(-50%);border-left-color:transparent;border-bottom-color:transparent;border-right-color:transparent;border-top-color:var(--ck-color-tooltip-background);border-left-width:var(--ck-tooltip-arrow-size);border-bottom-width:0;border-right-width:var(--ck-tooltip-arrow-size);border-top-width:var(--ck-tooltip-arrow-size)}'},function(t,e,i){var n=i(1);var o=i(34);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-button,a.ck.ck-button{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.ck.ck-button .ck-tooltip,a.ck.ck-button .ck-tooltip{display:block}@media (hover:none){.ck.ck-button .ck-tooltip,a.ck.ck-button .ck-tooltip{display:none}}.ck.ck-button,a.ck.ck-button{position:relative;display:inline-flex;align-items:center;justify-content:left}.ck.ck-button .ck-button__label,a.ck.ck-button .ck-button__label{display:none}.ck.ck-button.ck-button_with-text .ck-button__label,a.ck.ck-button.ck-button_with-text .ck-button__label{display:inline-block}.ck.ck-button:not(.ck-button_with-text),a.ck.ck-button:not(.ck-button_with-text){justify-content:center}.ck.ck-button:hover .ck-tooltip,a.ck.ck-button:hover .ck-tooltip{visibility:visible;opacity:1}.ck.ck-button:focus:not(:hover) .ck-tooltip,a.ck.ck-button:focus:not(:hover) .ck-tooltip{display:none}.ck.ck-button,a.ck.ck-button{background:var(--ck-color-button-default-background)}.ck.ck-button:not(.ck-disabled):hover,a.ck.ck-button:not(.ck-disabled):hover{background:var(--ck-color-button-default-hover-background)}.ck.ck-button:not(.ck-disabled):active,a.ck.ck-button:not(.ck-disabled):active{background:var(--ck-color-button-default-active-background);box-shadow:inset 0 2px 2px var(--ck-color-button-default-active-shadow)}.ck.ck-button.ck-disabled,a.ck.ck-button.ck-disabled{background:var(--ck-color-button-default-disabled-background)}.ck.ck-button,a.ck.ck-button{border-radius:0}.ck-rounded-corners .ck.ck-button,.ck-rounded-corners a.ck.ck-button,.ck.ck-button.ck-rounded-corners,a.ck.ck-button.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-button,a.ck.ck-button{white-space:nowrap;cursor:default;vertical-align:middle;padding:var(--ck-spacing-tiny);text-align:center;min-width:var(--ck-ui-component-min-height);min-height:var(--ck-ui-component-min-height);line-height:1;font-size:inherit;border:1px solid transparent;transition:box-shadow .2s ease-in-out,border .2s ease-in-out;-webkit-appearance:none}.ck.ck-button:active,.ck.ck-button:focus,a.ck.ck-button:active,a.ck.ck-button:focus{outline:none;border:var(--ck-focus-ring);box-shadow:var(--ck-focus-outer-shadow),0 0}.ck.ck-button .ck-button__icon use,.ck.ck-button .ck-button__icon use *,a.ck.ck-button .ck-button__icon use,a.ck.ck-button .ck-button__icon use *{color:inherit}.ck.ck-button .ck-button__label,a.ck.ck-button .ck-button__label{font-size:inherit;font-weight:inherit;color:inherit;cursor:inherit;vertical-align:middle}[dir=ltr] .ck.ck-button .ck-button__label,[dir=ltr] a.ck.ck-button .ck-button__label{text-align:left}[dir=rtl] .ck.ck-button .ck-button__label,[dir=rtl] a.ck.ck-button .ck-button__label{text-align:right}.ck.ck-button .ck-button__keystroke,a.ck.ck-button .ck-button__keystroke{color:inherit}[dir=ltr] .ck.ck-button .ck-button__keystroke,[dir=ltr] a.ck.ck-button .ck-button__keystroke{margin-left:var(--ck-spacing-large)}[dir=rtl] .ck.ck-button .ck-button__keystroke,[dir=rtl] a.ck.ck-button .ck-button__keystroke{margin-right:var(--ck-spacing-large)}.ck.ck-button .ck-button__keystroke,a.ck.ck-button .ck-button__keystroke{font-weight:700;opacity:.7}.ck.ck-button.ck-disabled:active,.ck.ck-button.ck-disabled:focus,a.ck.ck-button.ck-disabled:active,a.ck.ck-button.ck-disabled:focus{box-shadow:var(--ck-focus-disabled-outer-shadow),0 0}.ck.ck-button.ck-disabled .ck-button__icon,a.ck.ck-button.ck-disabled .ck-button__icon{opacity:var(--ck-disabled-opacity)}.ck.ck-button.ck-disabled .ck-button__label,a.ck.ck-button.ck-disabled .ck-button__label{opacity:var(--ck-disabled-opacity)}.ck.ck-button.ck-disabled .ck-button__keystroke,a.ck.ck-button.ck-disabled .ck-button__keystroke{opacity:.3}.ck.ck-button.ck-button_with-text,a.ck.ck-button.ck-button_with-text{padding:var(--ck-spacing-tiny) var(--ck-spacing-standard)}[dir=ltr] .ck.ck-button.ck-button_with-text .ck-button__icon,[dir=ltr] a.ck.ck-button.ck-button_with-text .ck-button__icon{margin-left:calc(-1*var(--ck-spacing-small));margin-right:var(--ck-spacing-small)}[dir=rtl] .ck.ck-button.ck-button_with-text .ck-button__icon,[dir=rtl] a.ck.ck-button.ck-button_with-text .ck-button__icon{margin-right:calc(-1*var(--ck-spacing-small));margin-left:var(--ck-spacing-small)}.ck.ck-button.ck-button_with-keystroke .ck-button__label,a.ck.ck-button.ck-button_with-keystroke .ck-button__label{flex-grow:1}.ck.ck-button.ck-on,a.ck.ck-button.ck-on{background:var(--ck-color-button-on-background)}.ck.ck-button.ck-on:not(.ck-disabled):hover,a.ck.ck-button.ck-on:not(.ck-disabled):hover{background:var(--ck-color-button-on-hover-background)}.ck.ck-button.ck-on:not(.ck-disabled):active,a.ck.ck-button.ck-on:not(.ck-disabled):active{background:var(--ck-color-button-on-active-background);box-shadow:inset 0 2px 2px var(--ck-color-button-on-active-shadow)}.ck.ck-button.ck-on.ck-disabled,a.ck.ck-button.ck-on.ck-disabled{background:var(--ck-color-button-on-disabled-background)}.ck.ck-button.ck-button-save,a.ck.ck-button.ck-button-save{color:var(--ck-color-button-save)}.ck.ck-button.ck-button-cancel,a.ck.ck-button.ck-button-cancel{color:var(--ck-color-button-cancel)}.ck.ck-button-action,a.ck.ck-button-action{background:var(--ck-color-button-action-background)}.ck.ck-button-action:not(.ck-disabled):hover,a.ck.ck-button-action:not(.ck-disabled):hover{background:var(--ck-color-button-action-hover-background)}.ck.ck-button-action:not(.ck-disabled):active,a.ck.ck-button-action:not(.ck-disabled):active{background:var(--ck-color-button-action-active-background);box-shadow:inset 0 2px 2px var(--ck-color-button-action-active-shadow)}.ck.ck-button-action.ck-disabled,a.ck.ck-button-action.ck-disabled{background:var(--ck-color-button-action-disabled-background)}.ck.ck-button-action,a.ck.ck-button-action{color:var(--ck-color-button-action-text)}.ck.ck-button-bold,a.ck.ck-button-bold{font-weight:700}\"},function(t,e,i){var n=i(1);var o=i(36);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-list{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none;display:flex;flex-direction:column}.ck.ck-list .ck-list__item,.ck.ck-list .ck-list__separator{display:block}.ck.ck-list .ck-list__item>:focus{position:relative;z-index:var(--ck-z-default)}.ck.ck-list{border-radius:0}.ck-rounded-corners .ck.ck-list,.ck.ck-list.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-list{list-style-type:none;background:var(--ck-color-list-background)}.ck.ck-list__item{cursor:default;min-width:12em}.ck.ck-list__item .ck-button{min-height:unset;width:100%;text-align:left;border-radius:0;padding:calc(0.2*var(--ck-line-height-base)*var(--ck-font-size-base)) calc(0.4*var(--ck-line-height-base)*var(--ck-font-size-base))}.ck.ck-list__item .ck-button .ck-button__label{line-height:calc(1.2*var(--ck-line-height-base)*var(--ck-font-size-base))}.ck.ck-list__item .ck-button:active{box-shadow:none}.ck.ck-list__item .ck-button.ck-on{background:var(--ck-color-list-button-on-background);color:var(--ck-color-list-button-on-text)}.ck.ck-list__item .ck-button.ck-on:active{box-shadow:none}.ck.ck-list__item .ck-button.ck-on:hover:not(.ck-disabled){background:var(--ck-color-list-button-on-background-focus)}.ck.ck-list__item .ck-button.ck-on:focus:not(.ck-disabled){border-color:var(--ck-color-base-background)}.ck.ck-list__item .ck-button:hover:not(.ck-disabled){background:var(--ck-color-list-button-hover-background)}.ck.ck-list__item .ck-switchbutton.ck-on{background:var(--ck-color-list-background);color:inherit}.ck.ck-list__item .ck-switchbutton.ck-on:hover:not(.ck-disabled){background:var(--ck-color-list-button-hover-background);color:inherit}.ck.ck-list__separator{height:1px;width:100%;background:var(--ck-color-base-border)}\"},function(t,e,i){var n=i(1);var o=i(38);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-button.ck-switchbutton .ck-button__toggle,.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{display:block}:root{--ck-switch-button-toggle-width:2.6153846154em;--ck-switch-button-toggle-inner-size:1.0769230769em;--ck-switch-button-toggle-spacing:1px;--ck-switch-button-translation:calc(var(--ck-switch-button-toggle-width) - var(--ck-switch-button-toggle-inner-size) - 2*var(--ck-switch-button-toggle-spacing))}[dir=ltr] .ck.ck-button.ck-switchbutton .ck-button__label{margin-right:calc(2*var(--ck-spacing-large))}[dir=rtl] .ck.ck-button.ck-switchbutton .ck-button__label{margin-left:calc(2*var(--ck-spacing-large))}.ck.ck-button.ck-switchbutton .ck-button__toggle{border-radius:0}.ck-rounded-corners .ck.ck-button.ck-switchbutton .ck-button__toggle,.ck.ck-button.ck-switchbutton .ck-button__toggle.ck-rounded-corners{border-radius:var(--ck-border-radius)}[dir=ltr] .ck.ck-button.ck-switchbutton .ck-button__toggle{margin-left:auto}[dir=rtl] .ck.ck-button.ck-switchbutton .ck-button__toggle{margin-right:auto}.ck.ck-button.ck-switchbutton .ck-button__toggle{transition:background .4s ease;width:var(--ck-switch-button-toggle-width);background:var(--ck-color-switch-button-off-background)}.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{border-radius:0}.ck-rounded-corners .ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner,.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner.ck-rounded-corners{border-radius:var(--ck-border-radius);border-radius:calc(0.5*var(--ck-border-radius))}.ck.ck-button.ck-switchbutton .ck-button__toggle .ck-button__toggle__inner{margin:var(--ck-switch-button-toggle-spacing);width:var(--ck-switch-button-toggle-inner-size);height:var(--ck-switch-button-toggle-inner-size);background:var(--ck-color-switch-button-inner-background);transition:all .3s ease}.ck.ck-button.ck-switchbutton .ck-button__toggle:hover{background:var(--ck-color-switch-button-off-hover-background)}.ck.ck-button.ck-switchbutton .ck-button__toggle:hover .ck-button__toggle__inner{box-shadow:0 0 0 5px var(--ck-color-switch-button-inner-shadow)}.ck.ck-button.ck-switchbutton.ck-disabled .ck-button__toggle{opacity:var(--ck-disabled-opacity)}.ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle{background:var(--ck-color-switch-button-on-background)}.ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle:hover{background:var(--ck-color-switch-button-on-hover-background)}[dir=ltr] .ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle .ck-button__toggle__inner{transform:translateX(var(--ck-switch-button-translation))}[dir=rtl] .ck.ck-button.ck-switchbutton.ck-on .ck-button__toggle .ck-button__toggle__inner{transform:translateX(calc(-1*var(--ck-switch-button-translation)))}\"},function(t,e,i){var n=i(1);var o=i(40);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-toolbar-dropdown .ck.ck-toolbar .ck.ck-toolbar__items{flex-wrap:nowrap}.ck.ck-toolbar-dropdown .ck-dropdown__panel .ck-button:focus{z-index:calc(var(--ck-z-default) + 1)}.ck.ck-toolbar-dropdown .ck-toolbar{border:0}\"},function(t,e,i){var n=i(1);var o=i(42);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-dropdown .ck-dropdown__panel .ck-list{border-radius:0}.ck-rounded-corners .ck.ck-dropdown .ck-dropdown__panel .ck-list,.ck.ck-dropdown .ck-dropdown__panel .ck-list.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0}.ck.ck-dropdown .ck-dropdown__panel .ck-list .ck-list__item:first-child .ck-button{border-radius:0}.ck-rounded-corners .ck.ck-dropdown .ck-dropdown__panel .ck-list .ck-list__item:first-child .ck-button,.ck.ck-dropdown .ck-dropdown__panel .ck-list .ck-list__item:first-child .ck-button.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0;border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-dropdown .ck-dropdown__panel .ck-list .ck-list__item:last-child .ck-button{border-radius:0}.ck-rounded-corners .ck.ck-dropdown .ck-dropdown__panel .ck-list .ck-list__item:last-child .ck-button,.ck.ck-dropdown .ck-dropdown__panel .ck-list .ck-list__item:last-child .ck-button.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0;border-top-right-radius:0}\"},function(t,e,i){var n=i(1);var o=i(44);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-toolbar{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none;display:flex;flex-flow:row nowrap;align-items:center}.ck.ck-toolbar>.ck-toolbar__items{display:flex;flex-flow:row wrap;align-items:center;flex-grow:1}.ck.ck-toolbar .ck.ck-toolbar__separator{display:inline-block}.ck.ck-toolbar .ck.ck-toolbar__separator:first-child,.ck.ck-toolbar .ck.ck-toolbar__separator:last-child{display:none}.ck.ck-toolbar.ck-toolbar_grouping>.ck-toolbar__items{flex-wrap:nowrap}.ck.ck-toolbar.ck-toolbar_vertical>.ck-toolbar__items{flex-direction:column}.ck.ck-toolbar.ck-toolbar_floating>.ck-toolbar__items{flex-wrap:nowrap}.ck.ck-toolbar>.ck.ck-toolbar__grouped-dropdown>.ck-dropdown__button .ck-dropdown__arrow{display:none}.ck.ck-toolbar{border-radius:0}.ck-rounded-corners .ck.ck-toolbar,.ck.ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-toolbar{background:var(--ck-color-toolbar-background);padding:0 var(--ck-spacing-small);border:1px solid var(--ck-color-toolbar-border)}.ck.ck-toolbar .ck.ck-toolbar__separator{align-self:stretch;width:1px;min-width:1px;margin-top:0;margin-bottom:0;background:var(--ck-color-toolbar-border)}.ck.ck-toolbar>.ck-toolbar__items>*{margin-top:var(--ck-spacing-small);margin-bottom:var(--ck-spacing-small);margin-right:var(--ck-spacing-small)}.ck.ck-toolbar>.ck-toolbar__items:empty+.ck.ck-toolbar__separator{display:none}.ck.ck-toolbar>.ck-toolbar__items>*,.ck.ck-toolbar>.ck.ck-toolbar__grouped-dropdown{margin-top:var(--ck-spacing-small);margin-bottom:var(--ck-spacing-small)}.ck.ck-toolbar.ck-toolbar_vertical{padding:0}.ck.ck-toolbar.ck-toolbar_vertical>.ck-toolbar__items>.ck{width:100%;margin:0;border-radius:0;border:0}.ck.ck-toolbar.ck-toolbar_compact{padding:0}.ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>*{margin:0}.ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>:not(:first-child):not(:last-child){border-radius:0}.ck.ck-toolbar>.ck.ck-toolbar__grouped-dropdown>.ck.ck-button.ck-dropdown__button{padding-left:var(--ck-spacing-tiny)}.ck-toolbar-container .ck.ck-toolbar{border:0}.ck.ck-toolbar[dir=rtl]>.ck-toolbar__items>.ck,[dir=rtl] .ck.ck-toolbar>.ck-toolbar__items>.ck{margin-right:0}.ck.ck-toolbar[dir=rtl]:not(.ck-toolbar_compact)>.ck-toolbar__items>.ck,[dir=rtl] .ck.ck-toolbar:not(.ck-toolbar_compact)>.ck-toolbar__items>.ck{margin-left:var(--ck-spacing-small)}.ck.ck-toolbar[dir=rtl]>.ck-toolbar__items>.ck:last-child,[dir=rtl] .ck.ck-toolbar>.ck-toolbar__items>.ck:last-child{margin-left:0}.ck.ck-toolbar[dir=rtl].ck-toolbar_compact>.ck-toolbar__items>.ck:first-child,[dir=rtl] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.ck.ck-toolbar[dir=rtl].ck-toolbar_compact>.ck-toolbar__items>.ck:last-child,[dir=rtl] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:last-child{border-top-right-radius:0;border-bottom-right-radius:0}.ck.ck-toolbar[dir=rtl]>.ck.ck-toolbar__separator,[dir=rtl] .ck.ck-toolbar>.ck.ck-toolbar__separator{margin-left:var(--ck-spacing-small)}.ck.ck-toolbar[dir=rtl].ck-toolbar_grouping>.ck-toolbar__items:not(:empty):not(:only-child),[dir=rtl] .ck.ck-toolbar.ck-toolbar_grouping>.ck-toolbar__items:not(:empty):not(:only-child){margin-left:var(--ck-spacing-small)}.ck.ck-toolbar[dir=ltr]>.ck-toolbar__items>.ck:last-child,[dir=ltr] .ck.ck-toolbar>.ck-toolbar__items>.ck:last-child{margin-right:0}.ck.ck-toolbar[dir=ltr].ck-toolbar_compact>.ck-toolbar__items>.ck:first-child,[dir=ltr] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:first-child{border-top-right-radius:0;border-bottom-right-radius:0}.ck.ck-toolbar[dir=ltr].ck-toolbar_compact>.ck-toolbar__items>.ck:last-child,[dir=ltr] .ck.ck-toolbar.ck-toolbar_compact>.ck-toolbar__items>.ck:last-child{border-top-left-radius:0;border-bottom-left-radius:0}.ck.ck-toolbar[dir=ltr]>.ck.ck-toolbar__separator,[dir=ltr] .ck.ck-toolbar>.ck.ck-toolbar__separator{margin-right:var(--ck-spacing-small)}.ck.ck-toolbar[dir=ltr].ck-toolbar_grouping>.ck-toolbar__items:not(:empty):not(:only-child),[dir=ltr] .ck.ck-toolbar.ck-toolbar_grouping>.ck-toolbar__items:not(:empty):not(:only-child){margin-right:var(--ck-spacing-small)}\"},function(t,e,i){var n=i(1);var o=i(46);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-editor{position:relative}.ck.ck-editor .ck-editor__top .ck-sticky-panel .ck-toolbar{z-index:var(--ck-z-modal)}.ck.ck-editor__top .ck-sticky-panel .ck-toolbar{border-radius:0}.ck-rounded-corners .ck.ck-editor__top .ck-sticky-panel .ck-toolbar,.ck.ck-editor__top .ck-sticky-panel .ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius);border-bottom-left-radius:0;border-bottom-right-radius:0}.ck.ck-editor__top .ck-sticky-panel .ck-toolbar{border-bottom-width:0}.ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar{border-bottom-width:1px;border-radius:0}.ck-rounded-corners .ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar,.ck.ck-editor__top .ck-sticky-panel .ck-sticky-panel__content_sticky .ck-toolbar.ck-rounded-corners{border-radius:var(--ck-border-radius);border-radius:0}.ck.ck-editor__main>.ck-editor__editable{background:var(--ck-color-base-background);border-radius:0}.ck-rounded-corners .ck.ck-editor__main>.ck-editor__editable,.ck.ck-editor__main>.ck-editor__editable.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:0;border-top-right-radius:0}.ck.ck-editor__main>.ck-editor__editable:not(.ck-focused){border-color:var(--ck-color-base-border)}\"},function(t,e,i){var n=i(1);var o=i(48);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck-content blockquote{overflow:hidden;padding-right:1.5em;padding-left:1.5em;margin-left:0;margin-right:0;font-style:italic;border-left:5px solid #ccc}.ck-content[dir=rtl] blockquote{border-left:0;border-right:5px solid #ccc}\"},function(t,e){t.exports=\".ck-content code{background-color:hsla(0,0%,78%,.3);padding:.15em;border-radius:2px}\"},function(t,e,i){var n=i(1);var o=i(51);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-splitbutton{font-size:inherit}.ck.ck-splitbutton .ck-splitbutton__action:focus{z-index:calc(var(--ck-z-default) + 1)}.ck.ck-splitbutton.ck-splitbutton_open>.ck-button .ck-tooltip{display:none}:root{--ck-color-split-button-hover-background:#ebebeb;--ck-color-split-button-hover-border:#b3b3b3}[dir=ltr] .ck.ck-splitbutton>.ck-splitbutton__action{border-top-right-radius:unset;border-bottom-right-radius:unset}[dir=rtl] .ck.ck-splitbutton>.ck-splitbutton__action{border-top-left-radius:unset;border-bottom-left-radius:unset}.ck.ck-splitbutton>.ck-splitbutton__arrow{min-width:unset}[dir=ltr] .ck.ck-splitbutton>.ck-splitbutton__arrow{border-radius:0}.ck-rounded-corners [dir=ltr] .ck.ck-splitbutton>.ck-splitbutton__arrow,[dir=ltr] .ck.ck-splitbutton>.ck-splitbutton__arrow.ck-rounded-corners{border-radius:var(--ck-border-radius);border-top-left-radius:unset;border-bottom-left-radius:unset}[dir=rtl] .ck.ck-splitbutton>.ck-splitbutton__arrow{border-top-right-radius:unset;border-bottom-right-radius:unset}.ck.ck-splitbutton>.ck-splitbutton__arrow svg{width:var(--ck-dropdown-arrow-size)}.ck.ck-splitbutton.ck-splitbutton_open>.ck-button:not(.ck-on):not(.ck-disabled):not(:hover),.ck.ck-splitbutton:hover>.ck-button:not(.ck-on):not(.ck-disabled):not(:hover){background:var(--ck-color-split-button-hover-background)}[dir=ltr] .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled),[dir=ltr] .ck.ck-splitbutton:hover>.ck-splitbutton__arrow:not(.ck-disabled){border-left-color:var(--ck-color-split-button-hover-border)}[dir=rtl] .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow:not(.ck-disabled),[dir=rtl] .ck.ck-splitbutton:hover>.ck-splitbutton__arrow:not(.ck-disabled){border-right-color:var(--ck-color-split-button-hover-border)}.ck.ck-splitbutton.ck-splitbutton_open{border-radius:0}.ck-rounded-corners .ck.ck-splitbutton.ck-splitbutton_open,.ck.ck-splitbutton.ck-splitbutton_open.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck-rounded-corners .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__action,.ck.ck-splitbutton.ck-splitbutton_open.ck-rounded-corners>.ck-splitbutton__action{border-bottom-left-radius:0}.ck-rounded-corners .ck.ck-splitbutton.ck-splitbutton_open>.ck-splitbutton__arrow,.ck.ck-splitbutton.ck-splitbutton_open.ck-rounded-corners>.ck-splitbutton__arrow{border-bottom-right-radius:0}\"},function(t,e,i){var n=i(1);var o=i(53);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck-content pre{padding:1em;color:#353535;background:hsla(0,0%,78%,.3);border:1px solid #c4c4c4;border-radius:2px;text-align:left;direction:ltr;tab-size:4;white-space:pre-wrap;font-style:normal;min-width:200px}.ck-content pre code{background:unset;padding:0;border-radius:0}.ck.ck-editor__editable pre{position:relative}.ck.ck-editor__editable pre[data-language]:after{content:attr(data-language);position:absolute}:root{--ck-color-code-block-label-background:#757575}.ck.ck-editor__editable pre[data-language]:after{top:-1px;right:10px;background:var(--ck-color-code-block-label-background);font-size:10px;font-family:var(--ck-font-face);line-height:16px;padding:var(--ck-spacing-tiny) var(--ck-spacing-medium);color:#fff;white-space:nowrap}.ck.ck-code-block-dropdown .ck-dropdown__panel{max-height:250px;overflow-y:auto;overflow-x:hidden}\"},function(t,e,i){var n=i(1);var o=i(55);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-color-grid{display:grid}:root{--ck-color-grid-tile-size:24px;--ck-color-color-grid-check-icon:#000}.ck.ck-color-grid{grid-gap:5px;padding:8px}.ck.ck-color-grid__tile{width:var(--ck-color-grid-tile-size);height:var(--ck-color-grid-tile-size);min-width:var(--ck-color-grid-tile-size);min-height:var(--ck-color-grid-tile-size);padding:0;transition:box-shadow .2s ease;border:0}.ck.ck-color-grid__tile.ck-disabled{cursor:unset;transition:unset}.ck.ck-color-grid__tile.ck-color-table__color-tile_bordered{box-shadow:0 0 0 1px var(--ck-color-base-border)}.ck.ck-color-grid__tile .ck.ck-icon{display:none;color:var(--ck-color-color-grid-check-icon)}.ck.ck-color-grid__tile.ck-on{box-shadow:inset 0 0 0 1px var(--ck-color-base-background),0 0 0 2px var(--ck-color-base-text)}.ck.ck-color-grid__tile.ck-on .ck.ck-icon{display:block}.ck.ck-color-grid__tile.ck-on,.ck.ck-color-grid__tile:focus:not(.ck-disabled),.ck.ck-color-grid__tile:hover:not(.ck-disabled){border:0}.ck.ck-color-grid__tile:focus:not(.ck-disabled),.ck.ck-color-grid__tile:hover:not(.ck-disabled){box-shadow:inset 0 0 0 1px var(--ck-color-base-background),0 0 0 2px var(--ck-color-focus-border)}.ck.ck-color-grid__label{padding:0 var(--ck-spacing-standard)}\"},function(t,e,i){var n=i(1);var o=i(57);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck .ck-button.ck-color-table__remove-color{display:flex;align-items:center;width:100%}label.ck.ck-color-grid__label{font-weight:unset}.ck .ck-button.ck-color-table__remove-color{padding:calc(var(--ck-spacing-standard)/2) var(--ck-spacing-standard);border-bottom-left-radius:0;border-bottom-right-radius:0}.ck .ck-button.ck-color-table__remove-color:not(:focus){border-bottom:1px solid var(--ck-color-base-border)}[dir=ltr] .ck .ck-button.ck-color-table__remove-color .ck.ck-icon{margin-right:var(--ck-spacing-standard)}[dir=rtl] .ck .ck-button.ck-color-table__remove-color .ck.ck-icon{margin-left:var(--ck-spacing-standard)}\"},function(t,e,i){var n=i(1);var o=i(59);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck-content .text-tiny{font-size:.7em}.ck-content .text-small{font-size:.85em}.ck-content .text-big{font-size:1.4em}.ck-content .text-huge{font-size:1.8em}\"},function(t,e){t.exports=\".ck.ck-heading_heading1{font-size:20px}.ck.ck-heading_heading2{font-size:17px}.ck.ck-heading_heading3{font-size:14px}.ck[class*=ck-heading_heading]{font-weight:700}.ck.ck-dropdown.ck-heading-dropdown .ck-dropdown__button .ck-button__label{width:8em}.ck.ck-dropdown.ck-heading-dropdown .ck-dropdown__panel .ck-list__item{min-width:18em}\"},function(t,e,i){var n=i(1);var o=i(62);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\":root{--ck-highlight-marker-yellow:#fdfd77;--ck-highlight-marker-green:#62f962;--ck-highlight-marker-pink:#fc7899;--ck-highlight-marker-blue:#72ccfd;--ck-highlight-pen-red:#e71313;--ck-highlight-pen-green:#128a00}.ck-content .marker-yellow{background-color:var(--ck-highlight-marker-yellow)}.ck-content .marker-green{background-color:var(--ck-highlight-marker-green)}.ck-content .marker-pink{background-color:var(--ck-highlight-marker-pink)}.ck-content .marker-blue{background-color:var(--ck-highlight-marker-blue)}.ck-content .pen-red{color:var(--ck-highlight-pen-red);background-color:transparent}.ck-content .pen-green{color:var(--ck-highlight-pen-green);background-color:transparent}\"},function(t,e,i){var n=i(1);var o=i(64);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=':root{--ck-balloon-panel-arrow-z-index:calc(var(--ck-z-default) - 3)}.ck.ck-balloon-panel{display:none;position:absolute;z-index:var(--ck-z-modal)}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:after,.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:before{content:\"\";position:absolute}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:before{z-index:var(--ck-balloon-panel-arrow-z-index)}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:after{z-index:calc(var(--ck-balloon-panel-arrow-z-index) + 1)}.ck.ck-balloon-panel[class*=arrow_n]:before{z-index:var(--ck-balloon-panel-arrow-z-index)}.ck.ck-balloon-panel[class*=arrow_n]:after{z-index:calc(var(--ck-balloon-panel-arrow-z-index) + 1)}.ck.ck-balloon-panel[class*=arrow_s]:before{z-index:var(--ck-balloon-panel-arrow-z-index)}.ck.ck-balloon-panel[class*=arrow_s]:after{z-index:calc(var(--ck-balloon-panel-arrow-z-index) + 1)}.ck.ck-balloon-panel.ck-balloon-panel_visible{display:block}:root{--ck-balloon-arrow-offset:2px;--ck-balloon-arrow-height:10px;--ck-balloon-arrow-half-width:8px}.ck.ck-balloon-panel{border-radius:0}.ck-rounded-corners .ck.ck-balloon-panel,.ck.ck-balloon-panel.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-balloon-panel{box-shadow:var(--ck-drop-shadow),0 0;min-height:15px;background:var(--ck-color-panel-background);border:1px solid var(--ck-color-panel-border)}.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:after,.ck.ck-balloon-panel.ck-balloon-panel_with-arrow:before{width:0;height:0;border-style:solid}.ck.ck-balloon-panel[class*=arrow_n]:after,.ck.ck-balloon-panel[class*=arrow_n]:before{border-left-width:var(--ck-balloon-arrow-half-width);border-bottom-width:var(--ck-balloon-arrow-height);border-right-width:var(--ck-balloon-arrow-half-width);border-top-width:0}.ck.ck-balloon-panel[class*=arrow_n]:before{border-bottom-color:var(--ck-color-panel-border)}.ck.ck-balloon-panel[class*=arrow_n]:after,.ck.ck-balloon-panel[class*=arrow_n]:before{border-left-color:transparent;border-right-color:transparent;border-top-color:transparent}.ck.ck-balloon-panel[class*=arrow_n]:after{border-bottom-color:var(--ck-color-panel-background);margin-top:var(--ck-balloon-arrow-offset)}.ck.ck-balloon-panel[class*=arrow_s]:after,.ck.ck-balloon-panel[class*=arrow_s]:before{border-left-width:var(--ck-balloon-arrow-half-width);border-bottom-width:0;border-right-width:var(--ck-balloon-arrow-half-width);border-top-width:var(--ck-balloon-arrow-height)}.ck.ck-balloon-panel[class*=arrow_s]:before{border-top-color:var(--ck-color-panel-border)}.ck.ck-balloon-panel[class*=arrow_s]:after,.ck.ck-balloon-panel[class*=arrow_s]:before{border-left-color:transparent;border-bottom-color:transparent;border-right-color:transparent}.ck.ck-balloon-panel[class*=arrow_s]:after{border-top-color:var(--ck-color-panel-background);margin-bottom:var(--ck-balloon-arrow-offset)}.ck.ck-balloon-panel.ck-balloon-panel_arrow_n:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_n:before{left:50%;margin-left:calc(-1*var(--ck-balloon-arrow-half-width));top:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_nw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_nw:before{left:calc(2*var(--ck-balloon-arrow-half-width));top:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_ne:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_ne:before{right:calc(2*var(--ck-balloon-arrow-half-width));top:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_s:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_s:before{left:50%;margin-left:calc(-1*var(--ck-balloon-arrow-half-width));bottom:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_sw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_sw:before{left:calc(2*var(--ck-balloon-arrow-half-width));bottom:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_se:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_se:before{right:calc(2*var(--ck-balloon-arrow-half-width));bottom:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_sme:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_sme:before{right:25%;margin-right:calc(2*var(--ck-balloon-arrow-half-width));bottom:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_smw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_smw:before{left:25%;margin-left:calc(2*var(--ck-balloon-arrow-half-width));bottom:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_nme:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_nme:before{right:25%;margin-right:calc(2*var(--ck-balloon-arrow-half-width));top:calc(-1*var(--ck-balloon-arrow-height))}.ck.ck-balloon-panel.ck-balloon-panel_arrow_nmw:after,.ck.ck-balloon-panel.ck-balloon-panel_arrow_nmw:before{left:25%;margin-left:calc(2*var(--ck-balloon-arrow-half-width));top:calc(-1*var(--ck-balloon-arrow-height))}'},function(t,e,i){var n=i(1);var o=i(66);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck-editor__editable .ck-horizontal-line{display:flow-root}.ck-content hr{border:solid #5e5e5e;border-width:1px 0 0;margin:0}.ck-editor__editable .ck-horizontal-line{padding:5px 0}\"},function(t,e,i){var n=i(1);var o=i(68);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck .ck-link_selected{background:var(--ck-color-link-selected-background)}\"},function(t,e,i){var n=i(1);var o=i(70);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck .ck-balloon-rotator__navigation{display:flex;align-items:center;justify-content:center}.ck .ck-balloon-rotator__content .ck-toolbar{justify-content:center}.ck .ck-balloon-rotator__navigation{background:var(--ck-color-toolbar-background);border-bottom:1px solid var(--ck-color-toolbar-border);padding:0 var(--ck-spacing-small)}.ck .ck-balloon-rotator__navigation>*{margin-right:var(--ck-spacing-small);margin-top:var(--ck-spacing-small);margin-bottom:var(--ck-spacing-small)}.ck .ck-balloon-rotator__navigation .ck-balloon-rotator__counter{margin-right:var(--ck-spacing-standard);margin-left:var(--ck-spacing-small)}.ck .ck-balloon-rotator__content .ck.ck-annotation-wrapper{box-shadow:none}\"},function(t,e,i){var n=i(1);var o=i(72);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck .ck-fake-panel{position:absolute;z-index:calc(var(--ck-z-modal) - 1)}.ck .ck-fake-panel div{position:absolute}.ck .ck-fake-panel div:first-child{z-index:2}.ck .ck-fake-panel div:nth-child(2){z-index:1}:root{--ck-balloon-fake-panel-offset-horizontal:6px;--ck-balloon-fake-panel-offset-vertical:6px}.ck .ck-fake-panel div{box-shadow:var(--ck-drop-shadow),0 0;min-height:15px;background:var(--ck-color-panel-background);border:1px solid var(--ck-color-panel-border);border-radius:var(--ck-border-radius);width:100%;height:100%}.ck .ck-fake-panel div:first-child{margin-left:var(--ck-balloon-fake-panel-offset-horizontal);margin-top:var(--ck-balloon-fake-panel-offset-vertical)}.ck .ck-fake-panel div:nth-child(2){margin-left:calc(var(--ck-balloon-fake-panel-offset-horizontal)*2);margin-top:calc(var(--ck-balloon-fake-panel-offset-vertical)*2)}.ck .ck-fake-panel div:nth-child(3){margin-left:calc(var(--ck-balloon-fake-panel-offset-horizontal)*3);margin-top:calc(var(--ck-balloon-fake-panel-offset-vertical)*3)}.ck .ck-balloon-panel_arrow_s+.ck-fake-panel,.ck .ck-balloon-panel_arrow_se+.ck-fake-panel,.ck .ck-balloon-panel_arrow_sw+.ck-fake-panel{--ck-balloon-fake-panel-offset-vertical:-6px}\"},function(t,e,i){var n=i(1);var o=i(74);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-labeled-field-view .ck-labeled-field-view__status{font-size:var(--ck-font-size-small);margin-top:var(--ck-spacing-small);white-space:normal}.ck.ck-labeled-field-view .ck-labeled-field-view__status_error{color:var(--ck-color-base-error)}.ck.ck-labeled-field-view>.ck.ck-label{width:100%;text-overflow:ellipsis;overflow:hidden}\"},function(t,e,i){var n=i(1);var o=i(76);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\":root{--ck-input-text-width:18em}.ck.ck-input-text{border-radius:0}.ck-rounded-corners .ck.ck-input-text,.ck.ck-input-text.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-input-text{box-shadow:var(--ck-inner-shadow),0 0;background:var(--ck-color-input-background);border:1px solid var(--ck-color-input-border);padding:var(--ck-spacing-extra-tiny) var(--ck-spacing-medium);min-width:var(--ck-input-text-width);min-height:var(--ck-ui-component-min-height);transition:box-shadow .2s ease-in-out,border .2s ease-in-out}.ck.ck-input-text:focus{outline:none;border:var(--ck-focus-ring);box-shadow:var(--ck-focus-outer-shadow),var(--ck-inner-shadow)}.ck.ck-input-text[readonly]{border:1px solid var(--ck-color-input-disabled-border);background:var(--ck-color-input-disabled-background);color:var(--ck-color-input-disabled-text)}.ck.ck-input-text[readonly]:focus{box-shadow:var(--ck-focus-disabled-outer-shadow),var(--ck-inner-shadow)}.ck.ck-input-text.ck-error{border-color:var(--ck-color-input-error-border);animation:ck-text-input-shake .3s ease both}.ck.ck-input-text.ck-error:focus{box-shadow:var(--ck-focus-error-outer-shadow),var(--ck-inner-shadow)}@keyframes ck-text-input-shake{20%{transform:translateX(-2px)}40%{transform:translateX(2px)}60%{transform:translateX(-1px)}80%{transform:translateX(1px)}}\"},function(t,e,i){var n=i(1);var o=i(78);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-link-form{display:flex}.ck.ck-link-form .ck-label{display:none}@media screen and (max-width:600px){.ck.ck-link-form{flex-wrap:wrap}.ck.ck-link-form .ck-labeled-field-view{flex-basis:100%}.ck.ck-link-form .ck-button{flex-basis:50%}}.ck.ck-link-form_layout-vertical{display:block}.ck.ck-link-form{padding:var(--ck-spacing-standard)}.ck.ck-link-form:focus{outline:none}[dir=ltr] .ck.ck-link-form>:not(:first-child),[dir=rtl] .ck.ck-link-form>:not(:last-child){margin-left:var(--ck-spacing-standard)}@media screen and (max-width:600px){.ck.ck-link-form{padding:0;width:calc(0.8*var(--ck-input-text-width))}.ck.ck-link-form .ck-labeled-field-view{margin:var(--ck-spacing-standard) var(--ck-spacing-standard) 0}.ck.ck-link-form .ck-labeled-field-view .ck-input-text{min-width:0;width:100%}.ck.ck-link-form .ck-button{padding:var(--ck-spacing-standard);margin-top:var(--ck-spacing-standard);border-radius:0;border:0;border-top:1px solid var(--ck-color-base-border)}[dir=ltr] .ck.ck-link-form .ck-button{margin-left:0}[dir=ltr] .ck.ck-link-form .ck-button:first-of-type{border-right:1px solid var(--ck-color-base-border)}[dir=rtl] .ck.ck-link-form .ck-button{margin-left:0}[dir=rtl] .ck.ck-link-form .ck-button:last-of-type{border-right:1px solid var(--ck-color-base-border)}}.ck.ck-link-form_layout-vertical{padding:0;min-width:var(--ck-input-text-width)}.ck.ck-link-form_layout-vertical .ck-labeled-field-view{margin:var(--ck-spacing-standard) var(--ck-spacing-standard) var(--ck-spacing-small)}.ck.ck-link-form_layout-vertical .ck-labeled-field-view .ck-input-text{min-width:0;width:100%}.ck.ck-link-form_layout-vertical .ck-button{padding:var(--ck-spacing-standard);margin:0;border-radius:0;border:0;border-top:1px solid var(--ck-color-base-border);width:50%}[dir=ltr] .ck.ck-link-form_layout-vertical .ck-button{margin-left:0}[dir=ltr] .ck.ck-link-form_layout-vertical .ck-button:first-of-type{border-right:1px solid var(--ck-color-base-border)}[dir=rtl] .ck.ck-link-form_layout-vertical .ck-button{margin-left:0}[dir=rtl] .ck.ck-link-form_layout-vertical .ck-button:last-of-type{border-right:1px solid var(--ck-color-base-border)}.ck.ck-link-form_layout-vertical .ck.ck-list{margin-left:0}.ck.ck-link-form_layout-vertical .ck.ck-list .ck-button.ck-switchbutton{border:0;width:100%}.ck.ck-link-form_layout-vertical .ck.ck-list .ck-button.ck-switchbutton:hover{background:none}\"},function(t,e,i){var n=i(1);var o=i(80);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-link-actions{display:flex;flex-direction:row;flex-wrap:nowrap}.ck.ck-link-actions .ck-link-actions__preview{display:inline-block}.ck.ck-link-actions .ck-link-actions__preview .ck-button__label{overflow:hidden}@media screen and (max-width:600px){.ck.ck-link-actions{flex-wrap:wrap}.ck.ck-link-actions .ck-link-actions__preview{flex-basis:100%}.ck.ck-link-actions .ck-button:not(.ck-link-actions__preview){flex-basis:50%}}.ck.ck-link-actions{padding:var(--ck-spacing-standard)}.ck.ck-link-actions .ck-button.ck-link-actions__preview{padding-left:0;padding-right:0}.ck.ck-link-actions .ck-button.ck-link-actions__preview .ck-button__label{padding:0 var(--ck-spacing-medium);color:var(--ck-color-link-default);text-overflow:ellipsis;cursor:pointer;max-width:var(--ck-input-text-width);min-width:3em;text-align:center}.ck.ck-link-actions .ck-button.ck-link-actions__preview .ck-button__label:hover{text-decoration:underline}.ck.ck-link-actions .ck-button.ck-link-actions__preview,.ck.ck-link-actions .ck-button.ck-link-actions__preview:active,.ck.ck-link-actions .ck-button.ck-link-actions__preview:focus,.ck.ck-link-actions .ck-button.ck-link-actions__preview:hover{background:none}.ck.ck-link-actions .ck-button.ck-link-actions__preview:active{box-shadow:none}.ck.ck-link-actions .ck-button.ck-link-actions__preview:focus .ck-button__label{text-decoration:underline}.ck.ck-link-actions:focus{outline:none}[dir=ltr] .ck.ck-link-actions .ck-button:not(:first-child),[dir=rtl] .ck.ck-link-actions .ck-button:not(:last-child){margin-left:var(--ck-spacing-standard)}@media screen and (max-width:600px){.ck.ck-link-actions{padding:0;width:calc(0.8*var(--ck-input-text-width))}.ck.ck-link-actions .ck-button.ck-link-actions__preview{margin:var(--ck-spacing-standard) var(--ck-spacing-standard) 0}.ck.ck-link-actions .ck-button.ck-link-actions__preview .ck-button__label{min-width:0;max-width:100%}.ck.ck-link-actions .ck-button:not(.ck-link-actions__preview){padding:var(--ck-spacing-standard);margin-top:var(--ck-spacing-standard);border-radius:0;border:0;border-top:1px solid var(--ck-color-base-border)}[dir=ltr] .ck.ck-link-actions .ck-button:not(.ck-link-actions__preview){margin-left:0}[dir=ltr] .ck.ck-link-actions .ck-button:not(.ck-link-actions__preview):first-of-type{border-right:1px solid var(--ck-color-base-border)}[dir=rtl] .ck.ck-link-actions .ck-button:not(.ck-link-actions__preview){margin-left:0}[dir=rtl] .ck.ck-link-actions .ck-button:not(.ck-link-actions__preview):last-of-type{border-right:1px solid var(--ck-color-base-border)}}\"},function(t,e,i){var n=i(1);var o=i(82);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports='.ck .ck-widget .ck-widget__type-around__button{display:block;position:absolute;overflow:hidden;z-index:var(--ck-z-default)}.ck .ck-widget .ck-widget__type-around__button svg{position:absolute;top:50%;left:50%;z-index:calc(var(--ck-z-default) + 2)}.ck .ck-widget .ck-widget__type-around__button.ck-widget__type-around__button_before{top:calc(-0.5*var(--ck-widget-outline-thickness));left:min(10%,30px);transform:translateY(-50%)}.ck .ck-widget .ck-widget__type-around__button.ck-widget__type-around__button_after{bottom:calc(-0.5*var(--ck-widget-outline-thickness));right:min(10%,30px);transform:translateY(50%)}.ck .ck-widget:not(.ck-widget_can-type-around_after)>.ck-widget__type-around>.ck-widget__type-around__button_after,.ck .ck-widget:not(.ck-widget_can-type-around_before)>.ck-widget__type-around>.ck-widget__type-around__button_before{display:none}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:after,.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__button:hover:after{content:\"\";display:block;position:absolute;top:1px;left:1px;z-index:calc(var(--ck-z-default) + 1)}.ck.ck-editor__editable.ck-read-only .ck-widget__type-around,.ck.ck-editor__editable.ck-restricted-editing_mode_restricted .ck-widget__type-around{display:none}:root{--ck-widget-type-around-button-size:20px;--ck-color-widget-type-around-button-active:var(--ck-color-focus-border);--ck-color-widget-type-around-button-hover:var(--ck-color-widget-hover-border);--ck-color-widget-type-around-button-blurred-editable:var(--ck-color-widget-blurred-border);--ck-color-widget-type-around-button-radar-start-alpha:0;--ck-color-widget-type-around-button-radar-end-alpha:.3;--ck-color-widget-type-around-button-icon:var(--ck-color-base-background)}.ck .ck-widget .ck-widget__type-around__button{width:var(--ck-widget-type-around-button-size);height:var(--ck-widget-type-around-button-size);background:var(--ck-color-widget-type-around-button);border-radius:100px;pointer-events:none;opacity:0;transition:opacity var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve)}.ck .ck-widget .ck-widget__type-around__button svg{width:10px;height:8px;transform:translate(-50%,-50%);transition:transform .5s ease;margin-top:1px}.ck .ck-widget .ck-widget__type-around__button svg *{stroke-dasharray:10;stroke-dashoffset:0;fill:none;stroke:var(--ck-color-widget-type-around-button-icon);stroke-width:1.5px;stroke-linecap:round;stroke-linejoin:round}.ck .ck-widget .ck-widget__type-around__button svg line{stroke-dasharray:7}.ck .ck-widget .ck-widget__type-around__button:hover{animation:ck-widget-type-around-button-sonar 1s ease infinite}.ck .ck-widget .ck-widget__type-around__button:hover svg polyline{animation:ck-widget-type-around-arrow-dash 2s linear}.ck .ck-widget .ck-widget__type-around__button:hover svg line{animation:ck-widget-type-around-arrow-tip-dash 2s linear}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button,.ck .ck-widget:hover>.ck-widget__type-around>.ck-widget__type-around__button{pointer-events:auto;opacity:1}.ck .ck-widget:not(.ck-widget_selected)>.ck-widget__type-around>.ck-widget__type-around__button{background:var(--ck-color-widget-type-around-button-hover)}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button,.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__button:hover{background:var(--ck-color-widget-type-around-button-active)}.ck .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:after,.ck .ck-widget>.ck-widget__type-around>.ck-widget__type-around__button:hover:after{width:calc(var(--ck-widget-type-around-button-size) - 2px);height:calc(var(--ck-widget-type-around-button-size) - 2px);border-radius:100px;background:linear-gradient(135deg,hsla(0,0%,100%,0),hsla(0,0%,100%,.3))}.ck .ck-widget.ck-widget_with-selection-handle>.ck-widget__type-around>.ck-widget__type-around__button_before{margin-left:20px}.ck-editor__nested-editable.ck-editor__editable_selected .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button,.ck-editor__nested-editable.ck-editor__editable_selected .ck-widget:hover>.ck-widget__type-around>.ck-widget__type-around__button{pointer-events:none;opacity:0}.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:not(:hover){background:var(--ck-color-widget-type-around-button-blurred-editable)}.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected>.ck-widget__type-around>.ck-widget__type-around__button:not(:hover) svg *{stroke:#999}@keyframes ck-widget-type-around-arrow-dash{0%{stroke-dashoffset:10}20%,to{stroke-dashoffset:0}}@keyframes ck-widget-type-around-arrow-tip-dash{0%,20%{stroke-dashoffset:7}40%,to{stroke-dashoffset:0}}@keyframes ck-widget-type-around-button-sonar{0%{box-shadow:0 0 0 0 hsla(var(--ck-color-focus-border-coordinates),var(--ck-color-widget-type-around-button-radar-start-alpha))}50%{box-shadow:0 0 0 5px hsla(var(--ck-color-focus-border-coordinates),var(--ck-color-widget-type-around-button-radar-end-alpha))}to{box-shadow:0 0 0 5px hsla(var(--ck-color-focus-border-coordinates),var(--ck-color-widget-type-around-button-radar-start-alpha))}}'},function(t,e,i){var n=i(1);var o=i(84);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\":root{--ck-color-resizer:var(--ck-color-focus-border);--ck-resizer-size:10px;--ck-resizer-border-width:1px;--ck-resizer-border-radius:2px;--ck-resizer-offset:calc(var(--ck-resizer-size)/-2 - 2px);--ck-resizer-tooltip-offset:10px;--ck-color-resizer-tooltip-background:#262626;--ck-color-resizer-tooltip-text:#f2f2f2}.ck .ck-widget,.ck .ck-widget.ck-widget_with-selection-handle{position:relative}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{position:absolute}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon{display:block}.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected .ck-widget__selection-handle,.ck .ck-widget.ck-widget_with-selection-handle:hover .ck-widget__selection-handle{visibility:visible}.ck .ck-size-view{background:var(--ck-color-resizer-tooltip-background);color:var(--ck-color-resizer-tooltip-text);border:1px solid var(--ck-color-resizer-tooltip-text);border-radius:var(--ck-resizer-border-radius);font-size:var(--ck-font-size-tiny);display:block;padding:var(--ck-spacing-small)}.ck .ck-size-view.ck-orientation-bottom-left,.ck .ck-size-view.ck-orientation-bottom-right,.ck .ck-size-view.ck-orientation-top-left,.ck .ck-size-view.ck-orientation-top-right{position:absolute}.ck .ck-size-view.ck-orientation-top-left{top:var(--ck-resizer-tooltip-offset);left:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-top-right{top:var(--ck-resizer-tooltip-offset);right:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-bottom-right{bottom:var(--ck-resizer-tooltip-offset);right:var(--ck-resizer-tooltip-offset)}.ck .ck-size-view.ck-orientation-bottom-left{bottom:var(--ck-resizer-tooltip-offset);left:var(--ck-resizer-tooltip-offset)}:root{--ck-widget-outline-thickness:3px;--ck-widget-handler-icon-size:16px;--ck-widget-handler-animation-duration:200ms;--ck-widget-handler-animation-curve:ease;--ck-color-widget-blurred-border:#dedede;--ck-color-widget-hover-border:#ffc83d;--ck-color-widget-editable-focus-background:var(--ck-color-base-background);--ck-color-widget-drag-handler-icon-color:var(--ck-color-base-background)}.ck .ck-widget{outline-width:var(--ck-widget-outline-thickness);outline-style:solid;outline-color:transparent;transition:outline-color var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve)}.ck .ck-widget.ck-widget_selected,.ck .ck-widget.ck-widget_selected:hover{outline:var(--ck-widget-outline-thickness) solid var(--ck-color-focus-border)}.ck .ck-widget:hover{outline-color:var(--ck-color-widget-hover-border)}.ck .ck-editor__nested-editable{border:1px solid transparent}.ck .ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck .ck-editor__nested-editable:focus{outline:none;border:var(--ck-focus-ring);box-shadow:var(--ck-inner-shadow),0 0;background-color:var(--ck-color-widget-editable-focus-background)}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{padding:4px;box-sizing:border-box;background-color:transparent;opacity:0;transition:background-color var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),visibility var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve),opacity var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);border-radius:var(--ck-border-radius) var(--ck-border-radius) 0 0;transform:translateY(-100%);left:calc(0px - var(--ck-widget-outline-thickness))}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon{width:var(--ck-widget-handler-icon-size);height:var(--ck-widget-handler-icon-size);color:var(--ck-color-widget-drag-handler-icon-color)}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator{opacity:0;transition:opacity .3s var(--ck-widget-handler-animation-curve)}.ck .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle:hover .ck-icon .ck-icon__selected-indicator{opacity:1}.ck .ck-widget.ck-widget_with-selection-handle:hover .ck-widget__selection-handle{opacity:1;background-color:var(--ck-color-widget-hover-border)}.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected .ck-widget__selection-handle,.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected:hover .ck-widget__selection-handle{opacity:1;background-color:var(--ck-color-focus-border)}.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected .ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator,.ck .ck-widget.ck-widget_with-selection-handle.ck-widget_selected:hover .ck-widget__selection-handle .ck-icon .ck-icon__selected-indicator{opacity:1}.ck[dir=rtl] .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle{left:auto;right:calc(0px - var(--ck-widget-outline-thickness))}.ck.ck-editor__editable.ck-read-only .ck-widget{transition:none}.ck.ck-editor__editable.ck-read-only .ck-widget:not(.ck-widget_selected){--ck-widget-outline-thickness:0px}.ck.ck-editor__editable.ck-read-only .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle,.ck.ck-editor__editable.ck-read-only .ck-widget.ck-widget_with-selection-handle .ck-widget__selection-handle:hover{background:var(--ck-color-widget-blurred-border)}.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected:hover{outline-color:var(--ck-color-widget-blurred-border)}.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected.ck-widget_with-selection-handle .ck-widget__selection-handle,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected.ck-widget_with-selection-handle .ck-widget__selection-handle:hover,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected:hover.ck-widget_with-selection-handle .ck-widget__selection-handle,.ck.ck-editor__editable.ck-blurred .ck-widget.ck-widget_selected:hover.ck-widget_with-selection-handle .ck-widget__selection-handle:hover{background:var(--ck-color-widget-blurred-border)}.ck.ck-editor__editable>.ck-widget.ck-widget_with-selection-handle:first-child,.ck.ck-editor__editable blockquote>.ck-widget.ck-widget_with-selection-handle:first-child{margin-top:calc(1em + var(--ck-widget-handler-icon-size))}\"},function(module,__webpack_exports__,__webpack_require__){\"use strict\";var md5;var _unused_webpack_default_export=md5;(function(){var HxOverrides=function(){};HxOverrides.__name__=true;HxOverrides.dateStr=function(t){var e=t.getMonth()+1;var i=t.getDate();var n=t.getHours();var o=t.getMinutes();var r=t.getSeconds();return t.getFullYear()+\"-\"+(e<10?\"0\"+e:\"\"+e)+\"-\"+(i<10?\"0\"+i:\"\"+i)+\" \"+(n<10?\"0\"+n:\"\"+n)+\":\"+(o<10?\"0\"+o:\"\"+o)+\":\"+(r<10?\"0\"+r:\"\"+r)};HxOverrides.strDate=function(t){switch(t.length){case 8:var e=t.split(\":\");var i=new Date;i.setTime(0);i.setUTCHours(e[0]);i.setUTCMinutes(e[1]);i.setUTCSeconds(e[2]);return i;case 10:var e=t.split(\"-\");return new Date(e[0],e[1]-1,e[2],0,0,0);case 19:var e=t.split(\" \");var n=e[0].split(\"-\");var o=e[1].split(\":\");return new Date(n[0],n[1]-1,n[2],o[0],o[1],o[2]);default:throw\"Invalid date format : \"+t}};HxOverrides.cca=function(t,e){var i=t.charCodeAt(e);if(i!=i)return undefined;return i};HxOverrides.substr=function(t,e,i){if(e!=null&&e!=0&&i!=null&&i<0)return\"\";if(i==null)i=t.length;if(e<0){e=t.length+e;if(e<0)e=0}else if(i<0)i=t.length+i-e;return t.substr(e,i)};HxOverrides.remove=function(t,e){var i=0;var n=t.length;while(i<n){if(t[i]==e){t.splice(i,1);return true}i++}return false};HxOverrides.iter=function(t){return{cur:0,arr:t,hasNext:function(){return this.cur<this.arr.length},next:function(){return this.arr[this.cur++]}}};var IntIter=function(t,e){this.min=t;this.max=e};IntIter.__name__=true;IntIter.prototype={next:function(){return this.min++},hasNext:function(){return this.min<this.max},__class__:IntIter};var Std=function(){};Std.__name__=true;Std[\"is\"]=function(t,e){return js.Boot.__instanceof(t,e)};Std.string=function(t){return js.Boot.__string_rec(t,\"\")};Std[\"int\"]=function(t){return t|0};Std.parseInt=function(t){var e=parseInt(t,10);if(e==0&&(HxOverrides.cca(t,1)==120||HxOverrides.cca(t,1)==88))e=parseInt(t);if(isNaN(e))return null;return e};Std.parseFloat=function(t){return parseFloat(t)};Std.random=function(t){return Math.floor(Math.random()*t)};var com=com||{};if(!com.wiris)com.wiris={};if(!com.wiris.js)com.wiris.js={};com.wiris.js.JsPluginTools=function(){this.tryReady()};com.wiris.js.JsPluginTools.__name__=true;com.wiris.js.JsPluginTools.main=function(){var t;t=com.wiris.js.JsPluginTools.getInstance();haxe.Timer.delay($bind(t,t.tryReady),100)};com.wiris.js.JsPluginTools.getInstance=function(){if(com.wiris.js.JsPluginTools.instance==null)com.wiris.js.JsPluginTools.instance=new com.wiris.js.JsPluginTools;return com.wiris.js.JsPluginTools.instance};com.wiris.js.JsPluginTools.bypassEncapsulation=function(){if(window.com==null)window.com={};if(window.com.wiris==null)window.com.wiris={};if(window.com.wiris.js==null)window.com.wiris.js={};if(window.com.wiris.js.JsPluginTools==null)window.com.wiris.js.JsPluginTools=com.wiris.js.JsPluginTools.getInstance()};com.wiris.js.JsPluginTools.prototype={md5encode:function(t){return haxe.Md5.encode(t)},doLoad:function(){this.ready=true;com.wiris.js.JsPluginTools.instance=this;com.wiris.js.JsPluginTools.bypassEncapsulation()},tryReady:function(){this.ready=false;if(js.Lib.document.readyState){this.doLoad();this.ready=true}if(!this.ready)haxe.Timer.delay($bind(this,this.tryReady),100)},__class__:com.wiris.js.JsPluginTools};var haxe=haxe||{};haxe.Log=function(){};haxe.Log.__name__=true;haxe.Log.trace=function(t,e){js.Boot.__trace(t,e)};haxe.Log.clear=function(){js.Boot.__clear_trace()};haxe.Md5=function(){};haxe.Md5.__name__=true;haxe.Md5.encode=function(t){return(new haxe.Md5).doEncode(t)};haxe.Md5.prototype={doEncode:function(t){var e=this.str2blks(t);var i=1732584193;var n=-271733879;var o=-1732584194;var r=271733878;var s;var a=0;while(a<e.length){var l=i;var c=n;var d=o;var u=r;s=0;i=this.ff(i,n,o,r,e[a],7,-680876936);r=this.ff(r,i,n,o,e[a+1],12,-389564586);o=this.ff(o,r,i,n,e[a+2],17,606105819);n=this.ff(n,o,r,i,e[a+3],22,-1044525330);i=this.ff(i,n,o,r,e[a+4],7,-176418897);r=this.ff(r,i,n,o,e[a+5],12,1200080426);o=this.ff(o,r,i,n,e[a+6],17,-1473231341);n=this.ff(n,o,r,i,e[a+7],22,-45705983);i=this.ff(i,n,o,r,e[a+8],7,1770035416);r=this.ff(r,i,n,o,e[a+9],12,-1958414417);o=this.ff(o,r,i,n,e[a+10],17,-42063);n=this.ff(n,o,r,i,e[a+11],22,-1990404162);i=this.ff(i,n,o,r,e[a+12],7,1804603682);r=this.ff(r,i,n,o,e[a+13],12,-40341101);o=this.ff(o,r,i,n,e[a+14],17,-1502002290);n=this.ff(n,o,r,i,e[a+15],22,1236535329);i=this.gg(i,n,o,r,e[a+1],5,-165796510);r=this.gg(r,i,n,o,e[a+6],9,-1069501632);o=this.gg(o,r,i,n,e[a+11],14,643717713);n=this.gg(n,o,r,i,e[a],20,-373897302);i=this.gg(i,n,o,r,e[a+5],5,-701558691);r=this.gg(r,i,n,o,e[a+10],9,38016083);o=this.gg(o,r,i,n,e[a+15],14,-660478335);n=this.gg(n,o,r,i,e[a+4],20,-405537848);i=this.gg(i,n,o,r,e[a+9],5,568446438);r=this.gg(r,i,n,o,e[a+14],9,-1019803690);o=this.gg(o,r,i,n,e[a+3],14,-187363961);n=this.gg(n,o,r,i,e[a+8],20,1163531501);i=this.gg(i,n,o,r,e[a+13],5,-1444681467);r=this.gg(r,i,n,o,e[a+2],9,-51403784);o=this.gg(o,r,i,n,e[a+7],14,1735328473);n=this.gg(n,o,r,i,e[a+12],20,-1926607734);i=this.hh(i,n,o,r,e[a+5],4,-378558);r=this.hh(r,i,n,o,e[a+8],11,-2022574463);o=this.hh(o,r,i,n,e[a+11],16,1839030562);n=this.hh(n,o,r,i,e[a+14],23,-35309556);i=this.hh(i,n,o,r,e[a+1],4,-1530992060);r=this.hh(r,i,n,o,e[a+4],11,1272893353);o=this.hh(o,r,i,n,e[a+7],16,-155497632);n=this.hh(n,o,r,i,e[a+10],23,-1094730640);i=this.hh(i,n,o,r,e[a+13],4,681279174);r=this.hh(r,i,n,o,e[a],11,-358537222);o=this.hh(o,r,i,n,e[a+3],16,-722521979);n=this.hh(n,o,r,i,e[a+6],23,76029189);i=this.hh(i,n,o,r,e[a+9],4,-640364487);r=this.hh(r,i,n,o,e[a+12],11,-421815835);o=this.hh(o,r,i,n,e[a+15],16,530742520);n=this.hh(n,o,r,i,e[a+2],23,-995338651);i=this.ii(i,n,o,r,e[a],6,-198630844);r=this.ii(r,i,n,o,e[a+7],10,1126891415);o=this.ii(o,r,i,n,e[a+14],15,-1416354905);n=this.ii(n,o,r,i,e[a+5],21,-57434055);i=this.ii(i,n,o,r,e[a+12],6,1700485571);r=this.ii(r,i,n,o,e[a+3],10,-1894986606);o=this.ii(o,r,i,n,e[a+10],15,-1051523);n=this.ii(n,o,r,i,e[a+1],21,-2054922799);i=this.ii(i,n,o,r,e[a+8],6,1873313359);r=this.ii(r,i,n,o,e[a+15],10,-30611744);o=this.ii(o,r,i,n,e[a+6],15,-1560198380);n=this.ii(n,o,r,i,e[a+13],21,1309151649);i=this.ii(i,n,o,r,e[a+4],6,-145523070);r=this.ii(r,i,n,o,e[a+11],10,-1120210379);o=this.ii(o,r,i,n,e[a+2],15,718787259);n=this.ii(n,o,r,i,e[a+9],21,-343485551);i=this.addme(i,l);n=this.addme(n,c);o=this.addme(o,d);r=this.addme(r,u);a+=16}return this.rhex(i)+this.rhex(n)+this.rhex(o)+this.rhex(r)},ii:function(t,e,i,n,o,r,s){return this.cmn(this.bitXOR(i,this.bitOR(e,~n)),t,e,o,r,s)},hh:function(t,e,i,n,o,r,s){return this.cmn(this.bitXOR(this.bitXOR(e,i),n),t,e,o,r,s)},gg:function(t,e,i,n,o,r,s){return this.cmn(this.bitOR(this.bitAND(e,n),this.bitAND(i,~n)),t,e,o,r,s)},ff:function(t,e,i,n,o,r,s){return this.cmn(this.bitOR(this.bitAND(e,i),this.bitAND(~e,n)),t,e,o,r,s)},cmn:function(t,e,i,n,o,r){return this.addme(this.rol(this.addme(this.addme(e,t),this.addme(n,r)),o),i)},rol:function(t,e){return t<<e|t>>>32-e},str2blks:function(t){var e=(t.length+8>>6)+1;var i=new Array;var n=0,o=e*16;while(n<o){var r=n++;i[r]=0}var r=0;while(r<t.length){i[r>>2]|=HxOverrides.cca(t,r)<<(t.length*8+r)%4*8;r++}i[r>>2]|=128<<(t.length*8+r)%4*8;var s=t.length*8;var a=e*16-2;i[a]=s&255;i[a]|=(s>>>8&255)<<8;i[a]|=(s>>>16&255)<<16;i[a]|=(s>>>24&255)<<24;return i},rhex:function(t){var e=\"\";var i=\"0123456789abcdef\";var n=0;while(n<4){var o=n++;e+=i.charAt(t>>o*8+4&15)+i.charAt(t>>o*8&15)}return e},addme:function(t,e){var i=(t&65535)+(e&65535);var n=(t>>16)+(e>>16)+(i>>16);return n<<16|i&65535},bitAND:function(t,e){var i=t&1&(e&1);var n=t>>>1&e>>>1;return n<<1|i},bitXOR:function(t,e){var i=t&1^e&1;var n=t>>>1^e>>>1;return n<<1|i},bitOR:function(t,e){var i=t&1|e&1;var n=t>>>1|e>>>1;return n<<1|i},__class__:haxe.Md5};haxe.Timer=function(t){var e=this;this.id=window.setInterval((function(){e.run()}),t)};haxe.Timer.__name__=true;haxe.Timer.delay=function(t,e){var i=new haxe.Timer(e);i.run=function(){i.stop();t()};return i};haxe.Timer.measure=function(t,e){var i=haxe.Timer.stamp();var n=t();haxe.Log.trace(haxe.Timer.stamp()-i+\"s\",e);return n};haxe.Timer.stamp=function(){return(new Date).getTime()/1e3};haxe.Timer.prototype={run:function(){},stop:function(){if(this.id==null)return;window.clearInterval(this.id);this.id=null},__class__:haxe.Timer};var js=js||{};js.Boot=function(){};js.Boot.__name__=true;js.Boot.__unhtml=function(t){return t.split(\"&\").join(\"&amp;\").split(\"<\").join(\"&lt;\").split(\">\").join(\"&gt;\")};js.Boot.__trace=function(t,e){var i=e!=null?e.fileName+\":\"+e.lineNumber+\": \":\"\";i+=js.Boot.__string_rec(t,\"\");var n;if(typeof document!=\"undefined\"&&(n=document.getElementById(\"haxe:trace\"))!=null)n.innerHTML+=js.Boot.__unhtml(i)+\"<br/>\";else if(typeof console!=\"undefined\"&&console.log!=null)console.log(i)};js.Boot.__clear_trace=function(){var t=document.getElementById(\"haxe:trace\");if(t!=null)t.innerHTML=\"\"};js.Boot.isClass=function(t){return t.__name__};js.Boot.isEnum=function(t){return t.__ename__};js.Boot.getClass=function(t){return t.__class__};js.Boot.__string_rec=function(t,e){if(t==null)return\"null\";if(e.length>=5)return\"<...>\";var i=typeof t;if(i==\"function\"&&(t.__name__||t.__ename__))i=\"object\";switch(i){case\"object\":if(t instanceof Array){if(t.__enum__){if(t.length==2)return t[0];var n=t[0]+\"(\";e+=\"\\t\";var o=2,r=t.length;while(o<r){var s=o++;if(s!=2)n+=\",\"+js.Boot.__string_rec(t[s],e);else n+=js.Boot.__string_rec(t[s],e)}return n+\")\"}var a=t.length;var s;var n=\"[\";e+=\"\\t\";var r=0;while(r<a){var l=r++;n+=(l>0?\",\":\"\")+js.Boot.__string_rec(t[l],e)}n+=\"]\";return n}var c;try{c=t.toString}catch(t){return\"???\"}if(c!=null&&c!=Object.toString){var d=t.toString();if(d!=\"[object Object]\")return d}var u=null;var n=\"{\\n\";e+=\"\\t\";var h=t.hasOwnProperty!=null;for(var u in t){if(h&&!t.hasOwnProperty(u)){continue}if(u==\"prototype\"||u==\"__class__\"||u==\"__super__\"||u==\"__interfaces__\"||u==\"__properties__\"){continue}if(n.length!=2)n+=\", \\n\";n+=e+u+\" : \"+js.Boot.__string_rec(t[u],e)}e=e.substring(1);n+=\"\\n\"+e+\"}\";return n;case\"function\":return\"<function>\";case\"string\":return t;default:return String(t)}};js.Boot.__interfLoop=function(t,e){if(t==null)return false;if(t==e)return true;var i=t.__interfaces__;if(i!=null){var n=0,o=i.length;while(n<o){var r=n++;var s=i[r];if(s==e||js.Boot.__interfLoop(s,e))return true}}return js.Boot.__interfLoop(t.__super__,e)};js.Boot.__instanceof=function(t,e){try{if(t instanceof e){if(e==Array)return t.__enum__==null;return true}if(js.Boot.__interfLoop(t.__class__,e))return true}catch(t){if(e==null)return false}switch(e){case Int:return Math.ceil(t%2147483648)===t;case Float:return typeof t==\"number\";case Bool:return t===true||t===false;case String:return typeof t==\"string\";case Dynamic:return true;default:if(t==null)return false;if(e==Class&&t.__name__!=null)return true;else null;if(e==Enum&&t.__ename__!=null)return true;else null;return t.__enum__==e}};js.Boot.__cast=function(t,e){if(js.Boot.__instanceof(t,e))return t;else throw\"Cannot cast \"+Std.string(t)+\" to \"+Std.string(e)};js.Lib=function(){};js.Lib.__name__=true;js.Lib.debug=function(){debugger};js.Lib.alert=function(t){alert(js.Boot.__string_rec(t,\"\"))};js.Lib.eval=function(code){return eval(code)};js.Lib.setErrorHandler=function(t){js.Lib.onerror=t};var $_;function $bind(t,e){var i=function(){return i.method.apply(i.scope,arguments)};i.scope=t;i.method=e;return i}if(Array.prototype.indexOf)HxOverrides.remove=function(t,e){var i=t.indexOf(e);if(i==-1)return false;t.splice(i,1);return true};else null;Math.__name__=[\"Math\"];Math.NaN=Number.NaN;Math.NEGATIVE_INFINITY=Number.NEGATIVE_INFINITY;Math.POSITIVE_INFINITY=Number.POSITIVE_INFINITY;Math.isFinite=function(t){return isFinite(t)};Math.isNaN=function(t){return isNaN(t)};String.prototype.__class__=String;String.__name__=true;Array.prototype.__class__=Array;Array.__name__=true;Date.prototype.__class__=Date;Date.__name__=[\"Date\"];var Int={__name__:[\"Int\"]};var Dynamic={__name__:[\"Dynamic\"]};var Float=Number;Float.__name__=[\"Float\"];var Bool=Boolean;Bool.__ename__=[\"Bool\"];var Class={__name__:[\"Class\"]};var Enum={};var Void={__ename__:[\"Void\"]};if(typeof document!=\"undefined\")js.Lib.document=document;if(typeof window!=\"undefined\"){js.Lib.window=window;js.Lib.window.onerror=function(t,e,i){var n=js.Lib.onerror;if(n==null)return false;return n(t,[e+\":\"+i])}}com.wiris.js.JsPluginTools.main();delete Array.prototype.__class__})();(function(){var HxOverrides=function(){};HxOverrides.__name__=true;HxOverrides.dateStr=function(t){var e=t.getMonth()+1;var i=t.getDate();var n=t.getHours();var o=t.getMinutes();var r=t.getSeconds();return t.getFullYear()+\"-\"+(e<10?\"0\"+e:\"\"+e)+\"-\"+(i<10?\"0\"+i:\"\"+i)+\" \"+(n<10?\"0\"+n:\"\"+n)+\":\"+(o<10?\"0\"+o:\"\"+o)+\":\"+(r<10?\"0\"+r:\"\"+r)};HxOverrides.strDate=function(t){switch(t.length){case 8:var e=t.split(\":\");var i=new Date;i.setTime(0);i.setUTCHours(e[0]);i.setUTCMinutes(e[1]);i.setUTCSeconds(e[2]);return i;case 10:var e=t.split(\"-\");return new Date(e[0],e[1]-1,e[2],0,0,0);case 19:var e=t.split(\" \");var n=e[0].split(\"-\");var o=e[1].split(\":\");return new Date(n[0],n[1]-1,n[2],o[0],o[1],o[2]);default:throw\"Invalid date format : \"+t}};HxOverrides.cca=function(t,e){var i=t.charCodeAt(e);if(i!=i)return undefined;return i};HxOverrides.substr=function(t,e,i){if(e!=null&&e!=0&&i!=null&&i<0)return\"\";if(i==null)i=t.length;if(e<0){e=t.length+e;if(e<0)e=0}else if(i<0)i=t.length+i-e;return t.substr(e,i)};HxOverrides.remove=function(t,e){var i=0;var n=t.length;while(i<n){if(t[i]==e){t.splice(i,1);return true}i++}return false};HxOverrides.iter=function(t){return{cur:0,arr:t,hasNext:function(){return this.cur<this.arr.length},next:function(){return this.arr[this.cur++]}}};var IntIter=function(t,e){this.min=t;this.max=e};IntIter.__name__=true;IntIter.prototype={next:function(){return this.min++},hasNext:function(){return this.min<this.max},__class__:IntIter};var Std=function(){};Std.__name__=true;Std[\"is\"]=function(t,e){return js.Boot.__instanceof(t,e)};Std.string=function(t){return js.Boot.__string_rec(t,\"\")};Std[\"int\"]=function(t){return t|0};Std.parseInt=function(t){var e=parseInt(t,10);if(e==0&&(HxOverrides.cca(t,1)==120||HxOverrides.cca(t,1)==88))e=parseInt(t);if(isNaN(e))return null;return e};Std.parseFloat=function(t){return parseFloat(t)};Std.random=function(t){return Math.floor(Math.random()*t)};var com=com||{};if(!com.wiris)com.wiris={};if(!com.wiris.js)com.wiris.js={};com.wiris.js.JsPluginTools=function(){this.tryReady()};com.wiris.js.JsPluginTools.__name__=true;com.wiris.js.JsPluginTools.main=function(){var t;t=com.wiris.js.JsPluginTools.getInstance();haxe.Timer.delay($bind(t,t.tryReady),100)};com.wiris.js.JsPluginTools.getInstance=function(){if(com.wiris.js.JsPluginTools.instance==null)com.wiris.js.JsPluginTools.instance=new com.wiris.js.JsPluginTools;return com.wiris.js.JsPluginTools.instance};com.wiris.js.JsPluginTools.bypassEncapsulation=function(){if(window.com==null)window.com={};if(window.com.wiris==null)window.com.wiris={};if(window.com.wiris.js==null)window.com.wiris.js={};if(window.com.wiris.js.JsPluginTools==null)window.com.wiris.js.JsPluginTools=com.wiris.js.JsPluginTools.getInstance()};com.wiris.js.JsPluginTools.prototype={md5encode:function(t){return haxe.Md5.encode(t)},doLoad:function(){this.ready=true;com.wiris.js.JsPluginTools.instance=this;com.wiris.js.JsPluginTools.bypassEncapsulation()},tryReady:function(){this.ready=false;if(js.Lib.document.readyState){this.doLoad();this.ready=true}if(!this.ready)haxe.Timer.delay($bind(this,this.tryReady),100)},__class__:com.wiris.js.JsPluginTools};var haxe=haxe||{};haxe.Log=function(){};haxe.Log.__name__=true;haxe.Log.trace=function(t,e){js.Boot.__trace(t,e)};haxe.Log.clear=function(){js.Boot.__clear_trace()};haxe.Md5=function(){};haxe.Md5.__name__=true;haxe.Md5.encode=function(t){return(new haxe.Md5).doEncode(t)};haxe.Md5.prototype={doEncode:function(t){var e=this.str2blks(t);var i=1732584193;var n=-271733879;var o=-1732584194;var r=271733878;var s;var a=0;while(a<e.length){var l=i;var c=n;var d=o;var u=r;s=0;i=this.ff(i,n,o,r,e[a],7,-680876936);r=this.ff(r,i,n,o,e[a+1],12,-389564586);o=this.ff(o,r,i,n,e[a+2],17,606105819);n=this.ff(n,o,r,i,e[a+3],22,-1044525330);i=this.ff(i,n,o,r,e[a+4],7,-176418897);r=this.ff(r,i,n,o,e[a+5],12,1200080426);o=this.ff(o,r,i,n,e[a+6],17,-1473231341);n=this.ff(n,o,r,i,e[a+7],22,-45705983);i=this.ff(i,n,o,r,e[a+8],7,1770035416);r=this.ff(r,i,n,o,e[a+9],12,-1958414417);o=this.ff(o,r,i,n,e[a+10],17,-42063);n=this.ff(n,o,r,i,e[a+11],22,-1990404162);i=this.ff(i,n,o,r,e[a+12],7,1804603682);r=this.ff(r,i,n,o,e[a+13],12,-40341101);o=this.ff(o,r,i,n,e[a+14],17,-1502002290);n=this.ff(n,o,r,i,e[a+15],22,1236535329);i=this.gg(i,n,o,r,e[a+1],5,-165796510);r=this.gg(r,i,n,o,e[a+6],9,-1069501632);o=this.gg(o,r,i,n,e[a+11],14,643717713);n=this.gg(n,o,r,i,e[a],20,-373897302);i=this.gg(i,n,o,r,e[a+5],5,-701558691);r=this.gg(r,i,n,o,e[a+10],9,38016083);o=this.gg(o,r,i,n,e[a+15],14,-660478335);n=this.gg(n,o,r,i,e[a+4],20,-405537848);i=this.gg(i,n,o,r,e[a+9],5,568446438);r=this.gg(r,i,n,o,e[a+14],9,-1019803690);o=this.gg(o,r,i,n,e[a+3],14,-187363961);n=this.gg(n,o,r,i,e[a+8],20,1163531501);i=this.gg(i,n,o,r,e[a+13],5,-1444681467);r=this.gg(r,i,n,o,e[a+2],9,-51403784);o=this.gg(o,r,i,n,e[a+7],14,1735328473);n=this.gg(n,o,r,i,e[a+12],20,-1926607734);i=this.hh(i,n,o,r,e[a+5],4,-378558);r=this.hh(r,i,n,o,e[a+8],11,-2022574463);o=this.hh(o,r,i,n,e[a+11],16,1839030562);n=this.hh(n,o,r,i,e[a+14],23,-35309556);i=this.hh(i,n,o,r,e[a+1],4,-1530992060);r=this.hh(r,i,n,o,e[a+4],11,1272893353);o=this.hh(o,r,i,n,e[a+7],16,-155497632);n=this.hh(n,o,r,i,e[a+10],23,-1094730640);i=this.hh(i,n,o,r,e[a+13],4,681279174);r=this.hh(r,i,n,o,e[a],11,-358537222);o=this.hh(o,r,i,n,e[a+3],16,-722521979);n=this.hh(n,o,r,i,e[a+6],23,76029189);i=this.hh(i,n,o,r,e[a+9],4,-640364487);r=this.hh(r,i,n,o,e[a+12],11,-421815835);o=this.hh(o,r,i,n,e[a+15],16,530742520);n=this.hh(n,o,r,i,e[a+2],23,-995338651);i=this.ii(i,n,o,r,e[a],6,-198630844);r=this.ii(r,i,n,o,e[a+7],10,1126891415);o=this.ii(o,r,i,n,e[a+14],15,-1416354905);n=this.ii(n,o,r,i,e[a+5],21,-57434055);i=this.ii(i,n,o,r,e[a+12],6,1700485571);r=this.ii(r,i,n,o,e[a+3],10,-1894986606);o=this.ii(o,r,i,n,e[a+10],15,-1051523);n=this.ii(n,o,r,i,e[a+1],21,-2054922799);i=this.ii(i,n,o,r,e[a+8],6,1873313359);r=this.ii(r,i,n,o,e[a+15],10,-30611744);o=this.ii(o,r,i,n,e[a+6],15,-1560198380);n=this.ii(n,o,r,i,e[a+13],21,1309151649);i=this.ii(i,n,o,r,e[a+4],6,-145523070);r=this.ii(r,i,n,o,e[a+11],10,-1120210379);o=this.ii(o,r,i,n,e[a+2],15,718787259);n=this.ii(n,o,r,i,e[a+9],21,-343485551);i=this.addme(i,l);n=this.addme(n,c);o=this.addme(o,d);r=this.addme(r,u);a+=16}return this.rhex(i)+this.rhex(n)+this.rhex(o)+this.rhex(r)},ii:function(t,e,i,n,o,r,s){return this.cmn(this.bitXOR(i,this.bitOR(e,~n)),t,e,o,r,s)},hh:function(t,e,i,n,o,r,s){return this.cmn(this.bitXOR(this.bitXOR(e,i),n),t,e,o,r,s)},gg:function(t,e,i,n,o,r,s){return this.cmn(this.bitOR(this.bitAND(e,n),this.bitAND(i,~n)),t,e,o,r,s)},ff:function(t,e,i,n,o,r,s){return this.cmn(this.bitOR(this.bitAND(e,i),this.bitAND(~e,n)),t,e,o,r,s)},cmn:function(t,e,i,n,o,r){return this.addme(this.rol(this.addme(this.addme(e,t),this.addme(n,r)),o),i)},rol:function(t,e){return t<<e|t>>>32-e},str2blks:function(t){var e=(t.length+8>>6)+1;var i=new Array;var n=0,o=e*16;while(n<o){var r=n++;i[r]=0}var r=0;while(r<t.length){i[r>>2]|=HxOverrides.cca(t,r)<<(t.length*8+r)%4*8;r++}i[r>>2]|=128<<(t.length*8+r)%4*8;var s=t.length*8;var a=e*16-2;i[a]=s&255;i[a]|=(s>>>8&255)<<8;i[a]|=(s>>>16&255)<<16;i[a]|=(s>>>24&255)<<24;return i},rhex:function(t){var e=\"\";var i=\"0123456789abcdef\";var n=0;while(n<4){var o=n++;e+=i.charAt(t>>o*8+4&15)+i.charAt(t>>o*8&15)}return e},addme:function(t,e){var i=(t&65535)+(e&65535);var n=(t>>16)+(e>>16)+(i>>16);return n<<16|i&65535},bitAND:function(t,e){var i=t&1&(e&1);var n=t>>>1&e>>>1;return n<<1|i},bitXOR:function(t,e){var i=t&1^e&1;var n=t>>>1^e>>>1;return n<<1|i},bitOR:function(t,e){var i=t&1|e&1;var n=t>>>1|e>>>1;return n<<1|i},__class__:haxe.Md5};haxe.Timer=function(t){var e=this;this.id=window.setInterval((function(){e.run()}),t)};haxe.Timer.__name__=true;haxe.Timer.delay=function(t,e){var i=new haxe.Timer(e);i.run=function(){i.stop();t()};return i};haxe.Timer.measure=function(t,e){var i=haxe.Timer.stamp();var n=t();haxe.Log.trace(haxe.Timer.stamp()-i+\"s\",e);return n};haxe.Timer.stamp=function(){return(new Date).getTime()/1e3};haxe.Timer.prototype={run:function(){},stop:function(){if(this.id==null)return;window.clearInterval(this.id);this.id=null},__class__:haxe.Timer};var js=js||{};js.Boot=function(){};js.Boot.__name__=true;js.Boot.__unhtml=function(t){return t.split(\"&\").join(\"&amp;\").split(\"<\").join(\"&lt;\").split(\">\").join(\"&gt;\")};js.Boot.__trace=function(t,e){var i=e!=null?e.fileName+\":\"+e.lineNumber+\": \":\"\";i+=js.Boot.__string_rec(t,\"\");var n;if(typeof document!=\"undefined\"&&(n=document.getElementById(\"haxe:trace\"))!=null)n.innerHTML+=js.Boot.__unhtml(i)+\"<br/>\";else if(typeof console!=\"undefined\"&&console.log!=null)console.log(i)};js.Boot.__clear_trace=function(){var t=document.getElementById(\"haxe:trace\");if(t!=null)t.innerHTML=\"\"};js.Boot.isClass=function(t){return t.__name__};js.Boot.isEnum=function(t){return t.__ename__};js.Boot.getClass=function(t){return t.__class__};js.Boot.__string_rec=function(t,e){if(t==null)return\"null\";if(e.length>=5)return\"<...>\";var i=typeof t;if(i==\"function\"&&(t.__name__||t.__ename__))i=\"object\";switch(i){case\"object\":if(t instanceof Array){if(t.__enum__){if(t.length==2)return t[0];var n=t[0]+\"(\";e+=\"\\t\";var o=2,r=t.length;while(o<r){var s=o++;if(s!=2)n+=\",\"+js.Boot.__string_rec(t[s],e);else n+=js.Boot.__string_rec(t[s],e)}return n+\")\"}var a=t.length;var s;var n=\"[\";e+=\"\\t\";var r=0;while(r<a){var l=r++;n+=(l>0?\",\":\"\")+js.Boot.__string_rec(t[l],e)}n+=\"]\";return n}var c;try{c=t.toString}catch(t){return\"???\"}if(c!=null&&c!=Object.toString){var d=t.toString();if(d!=\"[object Object]\")return d}var u=null;var n=\"{\\n\";e+=\"\\t\";var h=t.hasOwnProperty!=null;for(var u in t){if(h&&!t.hasOwnProperty(u)){continue}if(u==\"prototype\"||u==\"__class__\"||u==\"__super__\"||u==\"__interfaces__\"||u==\"__properties__\"){continue}if(n.length!=2)n+=\", \\n\";n+=e+u+\" : \"+js.Boot.__string_rec(t[u],e)}e=e.substring(1);n+=\"\\n\"+e+\"}\";return n;case\"function\":return\"<function>\";case\"string\":return t;default:return String(t)}};js.Boot.__interfLoop=function(t,e){if(t==null)return false;if(t==e)return true;var i=t.__interfaces__;if(i!=null){var n=0,o=i.length;while(n<o){var r=n++;var s=i[r];if(s==e||js.Boot.__interfLoop(s,e))return true}}return js.Boot.__interfLoop(t.__super__,e)};js.Boot.__instanceof=function(t,e){try{if(t instanceof e){if(e==Array)return t.__enum__==null;return true}if(js.Boot.__interfLoop(t.__class__,e))return true}catch(t){if(e==null)return false}switch(e){case Int:return Math.ceil(t%2147483648)===t;case Float:return typeof t==\"number\";case Bool:return t===true||t===false;case String:return typeof t==\"string\";case Dynamic:return true;default:if(t==null)return false;if(e==Class&&t.__name__!=null)return true;else null;if(e==Enum&&t.__ename__!=null)return true;else null;return t.__enum__==e}};js.Boot.__cast=function(t,e){if(js.Boot.__instanceof(t,e))return t;else throw\"Cannot cast \"+Std.string(t)+\" to \"+Std.string(e)};js.Lib=function(){};js.Lib.__name__=true;js.Lib.debug=function(){debugger};js.Lib.alert=function(t){alert(js.Boot.__string_rec(t,\"\"))};js.Lib.eval=function(code){return eval(code)};js.Lib.setErrorHandler=function(t){js.Lib.onerror=t};var $_;function $bind(t,e){var i=function(){return i.method.apply(i.scope,arguments)};i.scope=t;i.method=e;return i}if(Array.prototype.indexOf)HxOverrides.remove=function(t,e){var i=t.indexOf(e);if(i==-1)return false;t.splice(i,1);return true};else null;Math.__name__=[\"Math\"];Math.NaN=Number.NaN;Math.NEGATIVE_INFINITY=Number.NEGATIVE_INFINITY;Math.POSITIVE_INFINITY=Number.POSITIVE_INFINITY;Math.isFinite=function(t){return isFinite(t)};Math.isNaN=function(t){return isNaN(t)};String.prototype.__class__=String;String.__name__=true;Array.prototype.__class__=Array;Array.__name__=true;Date.prototype.__class__=Date;Date.__name__=[\"Date\"];var Int={__name__:[\"Int\"]};var Dynamic={__name__:[\"Dynamic\"]};var Float=Number;Float.__name__=[\"Float\"];var Bool=Boolean;Bool.__ename__=[\"Bool\"];var Class={__name__:[\"Class\"]};var Enum={};var Void={__ename__:[\"Void\"]};if(typeof document!=\"undefined\")js.Lib.document=document;if(typeof window!=\"undefined\"){js.Lib.window=window;js.Lib.window.onerror=function(t,e,i){var n=js.Lib.onerror;if(n==null)return false;return n(t,[e+\":\"+i])}}com.wiris.js.JsPluginTools.main()})();delete Array.prototype.__class__},function(t,e,i){var n=i(1);var o=i(87);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".wrs_modal_overlay{position:fixed;font-family:arial,sans-serif;top:0;right:0;left:0;bottom:0;background:rgba(0,0,0,.8);z-index:999998;opacity:.65;pointer-events:auto}.wrs_modal_overlay.wrs_modal_android,.wrs_modal_overlay.wrs_modal_ios{visibility:hidden;display:none}.wrs_modal_overlay.wrs_modal_ios.moodle{position:fixed}.wrs_modal_overlay.wrs_modal_desktop.wrs_stack{background:transparent;display:none}.wrs_modal_overlay.wrs_modal_desktop.wrs_maximized{background:rgba(0,0,0,.8)}.wrs_modal_overlay.wrs_modal_desktop.wrs_closed,.wrs_modal_overlay.wrs_modal_desktop.wrs_minimized{background:transparent;display:none}.wrs_modal_title{color:#fff;padding:5px 0 5px 10px;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none;text-align:left}.wrs_modal_close_button{background-repeat:no-repeat}.wrs_modal_close_button,.wrs_modal_minimize_button{float:right;cursor:pointer;color:#fff;padding:5px 10px 5px 0;margin:10px 7px 0 0}.wrs_modal_minimize_button{top:inherit}.wrs_modal_stack_button{float:right;cursor:pointer;color:#fff;margin:10px 7px 0 0;padding:5px 10px 5px 0;top:inherit}.wrs_modal_stack_button.wrs_minimized,.wrs_modal_stack_button.wrs_stack{visibility:hidden;margin:0;padding:0}.wrs_modal_maximize_button{float:right;cursor:pointer;color:#fff;margin:10px 7px 0 0;padding:5px 10px 5px 0;top:inherit}.wrs_modal_maximize_button.wrs_maximized{visibility:hidden;margin:0;padding:0}.wrs_modal_wrapper{display:block}.wrs_modal_title_bar{display:block;background-color:#778e9a}.wrs_modal_dialogContainer{border:none;background:#fafafa;z-index:999999}.wrs_modal_dialogContainer.wrs_modal_desktop{font-size:14px}.wrs_modal_dialogContainer.wrs_modal_desktop.wrs_maximized{position:fixed}.wrs_modal_dialogContainer.wrs_modal_desktop.wrs_minimized{position:fixed;top:inherit;margin:0 10px 0 0}.wrs_modal_dialogContainer.wrs_closed{visibility:hidden;display:none;opacity:0}.wrs_modal_dialogContainer.wrs_modal_desktop.wrs_stack{position:fixed;bottom:0;right:0;box-shadow:0 2px 8px rgba(0,0,0,.5)}.wrs_modal_dialogContainer.wrs_drag,.wrs_modal_dialogContainer.wrs_modal_desktop.wrs_drag{box-shadow:0 2px 8px rgba(0,0,0,.5)}.wrs_modal_dialogContainer.wrs_modal_android{width:99%;height:99%}.wrs_modal_dialogContainer.wrs_modal_android,.wrs_modal_dialogContainer.wrs_modal_ios{margin:auto;overflow:hidden;transform:translate(50%,-50%);top:50%;right:50%!important;position:fixed}.wrs_modal_dialogContainer.wrs_modal_ios{width:100%;height:100%}.wrs_content_container.wrs_minimized{display:none}.wrs_content_container.wrs_modal_android{width:100%;flex-grow:1;display:flex;flex-direction:column}.wrs_content_container.wrs_modal_android>div:first-child,.wrs_content_container.wrs_modal_desktop>div:first-child,.wrs_content_container.wrs_modal_ios>div:first-child{flex-grow:1}.wrs_modal_wrapper.wrs_modal_android{margin:auto;display:flex;flex-direction:column;height:100%;width:100%}.wrs_content_container.wrs_modal_desktop,.wrs_content_container.wrs_modal_ios{width:100%;flex-grow:1;display:flex;flex-direction:column}.wrs_modal_wrapper.wrs_modal_ios{margin:auto;display:flex;flex-direction:column;height:100%;width:100%}.wrs_virtual_keyboard{height:100%;width:100%;top:0;left:50%;transform:translate(-50%)}@media (orientation:portrait){.wrs_modal_dialogContainer.wrs_modal_mobile{width:100vmin;height:100vmin;margin:auto;border-width:0}.wrs_modal_wrapper.wrs_modal_mobile{width:100vmin;height:100vmin;margin:auto}}@media (orientation:landscape){.wrs_modal_dialogContainer.wrs_modal_mobile{width:100vmin;height:100vmin;margin:auto;border-width:0}.wrs_modal_wrapper.wrs_modal_mobile{width:100vmin;height:100vmin;margin:auto}}.wrs_modal_dialogContainer.wrs_modal_badStock,.wrs_modal_wrapper.wrs_modal_badStock{width:100%;height:280px;margin:0 auto;border-width:0}.wrs_noselect{-khtml-user-select:none}.wrs_bottom_right_resizer,.wrs_noselect{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none;user-select:none}.wrs_bottom_right_resizer{width:10px;height:10px;color:#778e9a;position:absolute;right:4px;bottom:8px;cursor:se-resize}.wrs_bottom_left_resizer{width:15px;height:15px;color:#778e9a;position:absolute;left:0;top:0;cursor:se-resize}.wrs_modal_controls{height:42px;margin:3px 0;overflow:hidden;line-height:normal}.wrs_modal_links{margin:10px auto 0;font-family:arial,sans-serif;padding:6px;display:inline;float:right;text-align:right}.wrs_modal_links>a{text-decoration:none;color:#778e9a;font-size:16px}.wrs_modal_button_cancel,.wrs_modal_button_cancel:active,.wrs_modal_button_cancel:focus,.wrs_modal_button_cancel:hover,.wrs_modal_button_cancel:visited{min-width:80px;font-size:14px;border-radius:3px;border:1px solid #778e9a;padding:6px 8px;margin:10px auto 0 5px;cursor:pointer;font-family:arial,sans-serif;background-color:#ddd;height:32px}.wrs_modal_button_accept,.wrs_modal_button_accept:active,.wrs_modal_button_accept:focus,.wrs_modal_button_accept:hover,.wrs_modal_button_accept:visited{min-width:80px;font-size:14px;border-radius:3px;border:1px solid #778e9a;padding:6px 8px;margin:10px 5px 0 auto;color:#fff;background:#778e9a;cursor:pointer;font-family:arial,sans-serif;height:32px}.wrs_editor_vertical_bar{height:20px;float:right;background:none;width:20px;cursor:pointer}.wrs_modal_buttons_container{display:inline;float:left}.wrs_modal_buttons_container.wrs_modalAndroid{padding-left:6px}.wrs_modal_buttons_container.wrs_modalDesktop{padding-left:0}.wrs_modal_buttons_container>button{line-height:normal;background-image:none}.wrs_modal_wrapper{margin:6px;display:flex;flex-direction:column}.wrs_modal_wrapper.wrs_modal_desktop.wrs_minimized{display:none}@media only screen and (max-device-width:480px) and (orientation:portrait){#wrs_modal_wrapper{width:140%}}.wrs_popupmessage_overlay_envolture{display:none;width:100%}.wrs_popupmessage_overlay{position:absolute;width:100%;height:100%;top:0;left:0;right:0;bottom:0;background-color:rgba(0,0,0,.5);z-index:4;cursor:pointer}.wrs_popupmessage_panel{top:50%;left:50%;transform:translate(-50%,-50%);position:absolute;background:#fff;max-width:500px;width:75%;border-radius:2px;padding:20px;font-family:sans-serif;font-size:15px;text-align:left;color:#2e2e2e;z-index:5;max-height:75%;overflow:auto}.wrs_popupmessage_button_area{margin:10px 0 0}.wrs_panelContainer *{border:0}.wrs_button_cancel,.wrs_button_cancel:active,.wrs_button_cancel:focus,.wrs_button_cancel:hover,.wrs_button_cancel:visited{min-width:80px;font-size:14px;border-radius:3px;border:1px solid #778e9a;padding:6px 8px;margin:10px auto 0 5px;cursor:pointer;font-family:arial,sans-serif;background-color:#ddd;background-image:none;height:32px}.wrs_button_accept,.wrs_button_accept:active,.wrs_button_accept:focus,.wrs_button_accept:hover,.wrs_button_accept:visited{min-width:80px;font-size:14px;border-radius:3px;border:1px solid #778e9a;padding:6px 8px;margin:10px 5px 0 auto;color:#fff;background:#778e9a;cursor:pointer;font-family:arial,sans-serif;height:32px}.wrs_editor button{box-shadow:none}.wrs_editor .wrs_header button{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0}.wrs_modal_overlay.wrs_modal_desktop.wrs_stack.wrs_overlay_active{display:block}.wrs_toolbar tr:focus,.wrs_toolbar tr:hover{background:none}.wrs_modal_rtl .wrs_modal_button_cancel{margin-right:5px;margin-left:0}.wrs_modal_rtl .wrs_modal_button_accept{margin-right:0;margin-left:5px}.wrs_modal_rtl .wrs_button_cancel{margin-right:5px;margin-left:0}.wrs_modal_rtl .wrs_button_accept{margin-right:0;margin-left:5px}\"},function(t,e,i){var n=i(1);var o=i(89);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-form__header{display:flex;flex-direction:row;flex-wrap:nowrap;align-items:center;justify-content:space-between}:root{--ck-form-header-height:38px}.ck.ck-form__header{padding:var(--ck-spacing-small) var(--ck-spacing-large);height:var(--ck-form-header-height);line-height:var(--ck-form-header-height);border-bottom:1px solid var(--ck-color-base-border)}.ck.ck-form__header .ck-form__header__label{font-weight:700}\"},function(t,e,i){var n=i(1);var o=i(91);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-character-grid .ck-character-grid__tiles{display:grid;grid-template-columns:repeat(10,1fr)}:root{--ck-character-grid-tile-size:24px}.ck.ck-character-grid{overflow-y:auto;overflow-x:hidden;width:350px;max-height:200px}.ck.ck-character-grid .ck-character-grid__tiles{margin:var(--ck-spacing-standard) var(--ck-spacing-large);grid-gap:var(--ck-spacing-standard)}.ck.ck-character-grid .ck-character-grid__tile{width:var(--ck-character-grid-tile-size);height:var(--ck-character-grid-tile-size);min-width:var(--ck-character-grid-tile-size);min-height:var(--ck-character-grid-tile-size);font-size:1.2em;padding:0;transition:box-shadow .2s ease;border:0}.ck.ck-character-grid .ck-character-grid__tile:focus:not(.ck-disabled),.ck.ck-character-grid .ck-character-grid__tile:hover:not(.ck-disabled){border:0;box-shadow:inset 0 0 0 1px var(--ck-color-base-background),0 0 0 2px var(--ck-color-focus-border)}.ck.ck-character-grid .ck-character-grid__tile .ck-button__label{line-height:var(--ck-character-grid-tile-size);width:100%;text-align:center}\"},function(t,e,i){var n=i(1);var o=i(93);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-character-info{display:flex;justify-content:space-between;padding:var(--ck-spacing-small) var(--ck-spacing-large);border-top:1px solid var(--ck-color-base-border)}.ck.ck-character-info>*{text-transform:uppercase;font-size:var(--ck-font-size-small)}.ck.ck-character-info .ck-character-info__name{max-width:280px;text-overflow:ellipsis;overflow:hidden}.ck.ck-character-info .ck-character-info__code{opacity:.6}\"},function(t,e,i){var n=i(1);var o=i(95);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-special-characters-navigation>.ck-label{max-width:160px;text-overflow:ellipsis;overflow:hidden}.ck.ck-special-characters-navigation>.ck-dropdown .ck-dropdown__panel{max-height:250px;overflow-y:auto;overflow-x:hidden}\"},function(t,e,i){var n=i(1);var o=i(97);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\":root{--ck-color-table-focused-cell-background:rgba(158,207,250,0.3)}.ck-widget.table td.ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck-widget.table td.ck-editor__nested-editable:focus,.ck-widget.table th.ck-editor__nested-editable.ck-editor__nested-editable_focused,.ck-widget.table th.ck-editor__nested-editable:focus{background:var(--ck-color-table-focused-cell-background);border-style:none;outline:1px solid var(--ck-color-focus-border);outline-offset:-1px}\"},function(t,e,i){var n=i(1);var o=i(99);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck .ck-insert-table-dropdown__grid{display:flex;flex-direction:row;flex-wrap:wrap}:root{--ck-insert-table-dropdown-padding:10px;--ck-insert-table-dropdown-box-height:11px;--ck-insert-table-dropdown-box-width:12px;--ck-insert-table-dropdown-box-margin:1px}.ck .ck-insert-table-dropdown__grid{width:calc(var(--ck-insert-table-dropdown-box-width)*10 + var(--ck-insert-table-dropdown-box-margin)*20 + var(--ck-insert-table-dropdown-padding)*2);padding:var(--ck-insert-table-dropdown-padding) var(--ck-insert-table-dropdown-padding) 0}.ck .ck-insert-table-dropdown__label{text-align:center}.ck .ck-insert-table-dropdown-grid-box{width:var(--ck-insert-table-dropdown-box-width);height:var(--ck-insert-table-dropdown-box-height);margin:var(--ck-insert-table-dropdown-box-margin);border:1px solid var(--ck-color-base-border);border-radius:1px}.ck .ck-insert-table-dropdown-grid-box.ck-on{border-color:var(--ck-color-focus-border);background:var(--ck-color-focus-outer-shadow)}\"},function(t,e,i){var n=i(1);var o=i(101);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=':root{--ck-table-selected-cell-background:rgba(158,207,250,0.3)}.ck.ck-editor__editable .table table td.ck-editor__editable_selected,.ck.ck-editor__editable .table table th.ck-editor__editable_selected{position:relative;caret-color:transparent;outline:unset;box-shadow:unset}.ck.ck-editor__editable .table table td.ck-editor__editable_selected:after,.ck.ck-editor__editable .table table th.ck-editor__editable_selected:after{content:\"\";pointer-events:none;background-color:var(--ck-table-selected-cell-background);position:absolute;top:0;left:0;right:0;bottom:0}.ck.ck-editor__editable .table table td.ck-editor__editable_selected ::selection,.ck.ck-editor__editable .table table td.ck-editor__editable_selected:focus,.ck.ck-editor__editable .table table th.ck-editor__editable_selected ::selection,.ck.ck-editor__editable .table table th.ck-editor__editable_selected:focus{background-color:transparent}.ck.ck-editor__editable .table table td.ck-editor__editable_selected .ck-widget_selected,.ck.ck-editor__editable .table table th.ck-editor__editable_selected .ck-widget_selected{outline:unset}'},function(t,e,i){var n=i(1);var o=i(103);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck-content .table{margin:1em auto;display:table}.ck-content .table table{border-collapse:collapse;border-spacing:0;width:100%;height:100%;border:1px double #b3b3b3}.ck-content .table table td,.ck-content .table table th{min-width:2em;padding:.4em;border:1px solid #bfbfbf}.ck-content .table table th{font-weight:700;background:hsla(0,0%,0%,5%)}.ck-content[dir=rtl] .table th{text-align:right}.ck-content[dir=ltr] .table th{text-align:left}\"},function(t,e,i){var n=i(1);var o=i(105);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-input-color{width:100%;display:flex}.ck.ck-input-color>input.ck.ck-input-text{min-width:auto;flex-grow:1}.ck.ck-input-color>input.ck.ck-input-text:active,.ck.ck-input-color>input.ck.ck-input-text:focus{z-index:var(--ck-z-default)}.ck.ck-input-color>div.ck.ck-dropdown{min-width:auto}.ck.ck-input-color>div.ck.ck-dropdown>.ck-input-color__button .ck-dropdown__arrow{display:none}.ck.ck-input-color .ck.ck-input-color__button .ck.ck-input-color__button__preview{position:relative;overflow:hidden}.ck.ck-input-color .ck.ck-input-color__button .ck.ck-input-color__button__preview>.ck.ck-input-color__button__preview__no-color-indicator{position:absolute;display:block}[dir=ltr] .ck.ck-input-color>.ck.ck-input-text{border-top-right-radius:0;border-bottom-right-radius:0}[dir=rtl] .ck.ck-input-color>.ck.ck-input-text{border-top-left-radius:0;border-bottom-left-radius:0}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button{padding:0}[dir=ltr] .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button{border-top-left-radius:0;border-bottom-left-radius:0;margin-left:-1px}[dir=rtl] .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button{border-top-right-radius:0;border-bottom-right-radius:0;margin-right:-1px}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button.ck-disabled{background:var(--ck-color-input-disabled-background)}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button>.ck.ck-input-color__button__preview{border-radius:0}.ck-rounded-corners .ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button>.ck.ck-input-color__button__preview,.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button>.ck.ck-input-color__button__preview.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button>.ck.ck-input-color__button__preview{width:20px;height:20px;border:1px solid var(--ck-color-input-border)}.ck.ck-input-color>.ck.ck-dropdown>.ck.ck-input-color__button>.ck.ck-input-color__button__preview>.ck.ck-input-color__button__preview__no-color-indicator{top:-30%;left:50%;height:150%;width:8%;background:red;border-radius:2px;transform:rotate(45deg);transform-origin:50%}.ck.ck-input-color .ck.ck-input-color__remove-color{width:100%;border-bottom:1px solid var(--ck-color-input-border);padding:calc(var(--ck-spacing-standard)/2) var(--ck-spacing-standard);border-bottom-left-radius:0;border-bottom-right-radius:0}[dir=ltr] .ck.ck-input-color .ck.ck-input-color__remove-color{border-top-right-radius:0}[dir=rtl] .ck.ck-input-color .ck.ck-input-color__remove-color{border-top-left-radius:0}.ck.ck-input-color .ck.ck-input-color__remove-color .ck.ck-icon{margin-right:var(--ck-spacing-standard)}[dir=rtl] .ck.ck-input-color .ck.ck-input-color__remove-color .ck.ck-icon{margin-right:0;margin-left:var(--ck-spacing-standard)}\"},function(t,e,i){var n=i(1);var o=i(107);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-form__row{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:space-between}.ck.ck-form__row>:not(.ck-label){flex-grow:1}.ck.ck-form__row.ck-table-form__action-row .ck-button-cancel,.ck.ck-form__row.ck-table-form__action-row .ck-button-save{justify-content:center}.ck.ck-form__row{padding:var(--ck-spacing-standard) var(--ck-spacing-large) 0}[dir=ltr] .ck.ck-form__row>:not(.ck-label)+*{margin-left:var(--ck-spacing-large)}[dir=rtl] .ck.ck-form__row>:not(.ck-label)+*{margin-right:var(--ck-spacing-large)}.ck.ck-form__row>.ck-label{width:100%;min-width:100%}.ck.ck-form__row.ck-table-form__action-row{margin-top:var(--ck-spacing-large)}.ck.ck-form__row.ck-table-form__action-row .ck-button .ck-button__label{color:var(--ck-color-text)}\"},function(t,e){t.exports=\".ck.ck-form{padding:0 0 var(--ck-spacing-large)}.ck.ck-form:focus{outline:none}.ck.ck-form .ck.ck-input-text{min-width:100%;width:0}.ck.ck-form .ck.ck-dropdown{min-width:100%}.ck.ck-form .ck.ck-dropdown .ck-dropdown__button:not(:focus){border:1px solid var(--ck-color-base-border)}.ck.ck-form .ck.ck-dropdown .ck-dropdown__button .ck-button__label{width:100%}\"},function(t,e){t.exports='.ck.ck-table-form .ck-form__row.ck-table-form__border-row{flex-wrap:wrap}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-labeled-field-view{display:flex;flex-direction:column-reverse}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-labeled-field-view .ck.ck-dropdown,.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-table-form__border-style,.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-table-form__border-width{flex-grow:0}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row{flex-wrap:wrap;align-items:center}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-labeled-field-view{display:flex;flex-direction:column-reverse;align-items:center}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-labeled-field-view .ck.ck-dropdown,.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimension-operator{flex-grow:0}.ck.ck-table-form .ck.ck-labeled-field-view{position:relative}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{position:absolute;left:50%;bottom:calc(-1*var(--ck-table-properties-error-arrow-size));transform:translate(-50%,100%);z-index:1}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status:after{content:\"\";position:absolute;top:calc(-1*var(--ck-table-properties-error-arrow-size));left:50%;transform:translateX(-50%)}:root{--ck-table-properties-error-arrow-size:6px;--ck-table-properties-min-error-width:150px}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-labeled-field-view>.ck-label{font-size:var(--ck-font-size-tiny);text-align:center}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-table-form__border-style{width:80px;min-width:80px}.ck.ck-table-form .ck-form__row.ck-table-form__border-row .ck-table-form__border-width{width:50px;min-width:50px}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row{padding:0}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-labeled-field-view>.ck-label{font-size:10px;text-align:center}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimensions-row__height,.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimensions-row__width{margin:0}.ck.ck-table-form .ck-form__row.ck-table-form__dimensions-row .ck-table-form__dimension-operator{align-self:start;display:inline-block;height:var(--ck-ui-component-min-height);line-height:var(--ck-ui-component-min-height);margin:0 var(--ck-spacing-small)}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{border-radius:0}.ck-rounded-corners .ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status,.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status.ck-rounded-corners{border-radius:var(--ck-border-radius)}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{background:var(--ck-color-base-error);color:var(--ck-color-base-background);padding:var(--ck-spacing-small) var(--ck-spacing-medium);min-width:var(--ck-table-properties-min-error-width);text-align:center}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status:after{border-left:var(--ck-table-properties-error-arrow-size) solid transparent;border-bottom:var(--ck-table-properties-error-arrow-size) solid var(--ck-color-base-error);border-right:var(--ck-table-properties-error-arrow-size) solid transparent;border-top:0 solid transparent}.ck.ck-table-form .ck.ck-labeled-field-view .ck.ck-labeled-field-view__status{animation:ck-table-form-labeled-view-status-appear .15s ease both}.ck.ck-table-form .ck.ck-labeled-field-view .ck-input.ck-error:not(:focus)+.ck.ck-labeled-field-view__status{display:none}@keyframes ck-table-form-labeled-view-status-appear{0%{opacity:0}to{opacity:1}}'},function(t,e,i){var n=i(1);var o=i(111);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row{flex-wrap:wrap}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row .ck.ck-toolbar{flex-grow:0}.ck.ck-table-cell-properties-form{width:320px}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__padding-row{padding:0;width:35%}.ck.ck-table-cell-properties-form .ck-form__row.ck-table-cell-properties-form__alignment-row .ck.ck-toolbar{background:none}\"},function(t,e,i){var n=i(1);var o=i(113);o=o.__esModule?o.default:o;if(typeof o===\"string\"){o=[[t.i,o,\"\"]]}var r={injectType:\"singletonStyleTag\",attributes:{\"data-cke\":true}};r.insert=\"head\";r.singleton=true;var s=n(o,r);t.exports=o.locals||{}},function(t,e){t.exports=\".ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row{flex-wrap:wrap;flex-basis:0;align-content:baseline}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row .ck.ck-toolbar .ck-toolbar__items{flex-wrap:nowrap}.ck.ck-table-properties-form{width:320px}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row{padding:0}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row .ck.ck-toolbar{background:none}.ck.ck-table-properties-form .ck-form__row.ck-table-properties-form__alignment-row .ck.ck-toolbar .ck-toolbar__items>*{width:40px}\"},function(t,e,i){\"use strict\";i.r(e);var n=i(3);var o=n[\"a\"].Symbol;var r=o;var s=Object.prototype;var a=s.hasOwnProperty;var l=s.toString;var c=r?r.toStringTag:undefined;function d(t){var e=a.call(t,c),i=t[c];try{t[c]=undefined;var n=true}catch(t){}var o=l.call(t);if(n){if(e){t[c]=i}else{delete t[c]}}return o}var u=d;var h=Object.prototype;var f=h.toString;function m(t){return f.call(t)}var g=m;var p=\"[object Null]\",b=\"[object Undefined]\";var w=r?r.toStringTag:undefined;function _(t){if(t==null){return t===undefined?b:p}return w&&w in Object(t)?u(t):g(t)}var k=_;function v(t,e){return function(i){return t(e(i))}}var y=v;var x=y(Object.getPrototypeOf,Object);var C=x;function A(t){return t!=null&&typeof t==\"object\"}var T=A;var P=\"[object Object]\";var E=Function.prototype,S=Object.prototype;var M=E.toString;var O=S.hasOwnProperty;var I=M.call(Object);function R(t){if(!T(t)||k(t)!=P){return false}var e=C(t);if(e===null){return true}var i=O.call(e,\"constructor\")&&e.constructor;return typeof i==\"function\"&&i instanceof i&&M.call(i)==I}var L=R;function N(){this.__data__=[];this.size=0}var B=N;function V(t,e){return t===e||t!==t&&e!==e}var D=V;function z(t,e){var i=t.length;while(i--){if(D(t[i][0],e)){return i}}return-1}var F=z;var j=Array.prototype;var H=j.splice;function W(t){var e=this.__data__,i=F(e,t);if(i<0){return false}var n=e.length-1;if(i==n){e.pop()}else{H.call(e,i,1)}--this.size;return true}var q=W;function $(t){var e=this.__data__,i=F(e,t);return i<0?undefined:e[i][1]}var U=$;function G(t){return F(this.__data__,t)>-1}var J=G;function K(t,e){var i=this.__data__,n=F(i,t);if(n<0){++this.size;i.push([t,e])}else{i[n][1]=e}return this}var X=K;function Y(t){var e=-1,i=t==null?0:t.length;this.clear();while(++e<i){var n=t[e];this.set(n[0],n[1])}}Y.prototype.clear=B;Y.prototype[\"delete\"]=q;Y.prototype.get=U;Y.prototype.has=J;Y.prototype.set=X;var Q=Y;function Z(){this.__data__=new Q;this.size=0}var tt=Z;function et(t){var e=this.__data__,i=e[\"delete\"](t);this.size=e.size;return i}var it=et;function nt(t){return this.__data__.get(t)}var ot=nt;function rt(t){return this.__data__.has(t)}var st=rt;function at(t){var e=typeof t;return t!=null&&(e==\"object\"||e==\"function\")}var lt=at;var ct=\"[object AsyncFunction]\",dt=\"[object Function]\",ut=\"[object GeneratorFunction]\",ht=\"[object Proxy]\";function ft(t){if(!lt(t)){return false}var e=k(t);return e==dt||e==ut||e==ct||e==ht}var mt=ft;var gt=n[\"a\"][\"__core-js_shared__\"];var pt=gt;var bt=function(){var t=/[^.]+$/.exec(pt&&pt.keys&&pt.keys.IE_PROTO||\"\");return t?\"Symbol(src)_1.\"+t:\"\"}();function wt(t){return!!bt&&bt in t}var _t=wt;var kt=Function.prototype;var vt=kt.toString;function yt(t){if(t!=null){try{return vt.call(t)}catch(t){}try{return t+\"\"}catch(t){}}return\"\"}var xt=yt;var Ct=/[\\\\^$.*+?()[\\]{}|]/g;var At=/^\\[object .+?Constructor\\]$/;var Tt=Function.prototype,Pt=Object.prototype;var Et=Tt.toString;var St=Pt.hasOwnProperty;var Mt=RegExp(\"^\"+Et.call(St).replace(Ct,\"\\\\$&\").replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g,\"$1.*?\")+\"$\");function Ot(t){if(!lt(t)||_t(t)){return false}var e=mt(t)?Mt:At;return e.test(xt(t))}var It=Ot;function Rt(t,e){return t==null?undefined:t[e]}var Lt=Rt;function Nt(t,e){var i=Lt(t,e);return It(i)?i:undefined}var Bt=Nt;var Vt=Bt(n[\"a\"],\"Map\");var Dt=Vt;var zt=Bt(Object,\"create\");var Ft=zt;function jt(){this.__data__=Ft?Ft(null):{};this.size=0}var Ht=jt;function Wt(t){var e=this.has(t)&&delete this.__data__[t];this.size-=e?1:0;return e}var qt=Wt;var $t=\"__lodash_hash_undefined__\";var Ut=Object.prototype;var Gt=Ut.hasOwnProperty;function Jt(t){var e=this.__data__;if(Ft){var i=e[t];return i===$t?undefined:i}return Gt.call(e,t)?e[t]:undefined}var Kt=Jt;var Xt=Object.prototype;var Yt=Xt.hasOwnProperty;function Qt(t){var e=this.__data__;return Ft?e[t]!==undefined:Yt.call(e,t)}var Zt=Qt;var te=\"__lodash_hash_undefined__\";function ee(t,e){var i=this.__data__;this.size+=this.has(t)?0:1;i[t]=Ft&&e===undefined?te:e;return this}var ie=ee;function ne(t){var e=-1,i=t==null?0:t.length;this.clear();while(++e<i){var n=t[e];this.set(n[0],n[1])}}ne.prototype.clear=Ht;ne.prototype[\"delete\"]=qt;ne.prototype.get=Kt;ne.prototype.has=Zt;ne.prototype.set=ie;var oe=ne;function re(){this.size=0;this.__data__={hash:new oe,map:new(Dt||Q),string:new oe}}var se=re;function ae(t){var e=typeof t;return e==\"string\"||e==\"number\"||e==\"symbol\"||e==\"boolean\"?t!==\"__proto__\":t===null}var le=ae;function ce(t,e){var i=t.__data__;return le(e)?i[typeof e==\"string\"?\"string\":\"hash\"]:i.map}var de=ce;function ue(t){var e=de(this,t)[\"delete\"](t);this.size-=e?1:0;return e}var he=ue;function fe(t){return de(this,t).get(t)}var me=fe;function ge(t){return de(this,t).has(t)}var pe=ge;function be(t,e){var i=de(this,t),n=i.size;i.set(t,e);this.size+=i.size==n?0:1;return this}var we=be;function _e(t){var e=-1,i=t==null?0:t.length;this.clear();while(++e<i){var n=t[e];this.set(n[0],n[1])}}_e.prototype.clear=se;_e.prototype[\"delete\"]=he;_e.prototype.get=me;_e.prototype.has=pe;_e.prototype.set=we;var ke=_e;var ve=200;function ye(t,e){var i=this.__data__;if(i instanceof Q){var n=i.__data__;if(!Dt||n.length<ve-1){n.push([t,e]);this.size=++i.size;return this}i=this.__data__=new ke(n)}i.set(t,e);this.size=i.size;return this}var xe=ye;function Ce(t){var e=this.__data__=new Q(t);this.size=e.size}Ce.prototype.clear=tt;Ce.prototype[\"delete\"]=it;Ce.prototype.get=ot;Ce.prototype.has=st;Ce.prototype.set=xe;var Ae=Ce;function Te(t,e){var i=-1,n=t==null?0:t.length;while(++i<n){if(e(t[i],i,t)===false){break}}return t}var Pe=Te;var Ee=function(){try{var t=Bt(Object,\"defineProperty\");t({},\"\",{});return t}catch(t){}}();var Se=Ee;function Me(t,e,i){if(e==\"__proto__\"&&Se){Se(t,e,{configurable:true,enumerable:true,value:i,writable:true})}else{t[e]=i}}var Oe=Me;var Ie=Object.prototype;var Re=Ie.hasOwnProperty;function Le(t,e,i){var n=t[e];if(!(Re.call(t,e)&&D(n,i))||i===undefined&&!(e in t)){Oe(t,e,i)}}var Ne=Le;function Be(t,e,i,n){var o=!i;i||(i={});var r=-1,s=e.length;while(++r<s){var a=e[r];var l=n?n(i[a],t[a],a,i,t):undefined;if(l===undefined){l=t[a]}if(o){Oe(i,a,l)}else{Ne(i,a,l)}}return i}var Ve=Be;function De(t,e){var i=-1,n=Array(t);while(++i<t){n[i]=e(i)}return n}var ze=De;var Fe=\"[object Arguments]\";function je(t){return T(t)&&k(t)==Fe}var He=je;var We=Object.prototype;var qe=We.hasOwnProperty;var $e=We.propertyIsEnumerable;var Ue=He(function(){return arguments}())?He:function(t){return T(t)&&qe.call(t,\"callee\")&&!$e.call(t,\"callee\")};var Ge=Ue;var Je=Array.isArray;var Ke=Je;var Xe=i(4);var Ye=9007199254740991;var Qe=/^(?:0|[1-9]\\d*)$/;function Ze(t,e){var i=typeof t;e=e==null?Ye:e;return!!e&&(i==\"number\"||i!=\"symbol\"&&Qe.test(t))&&(t>-1&&t%1==0&&t<e)}var ti=Ze;var ei=9007199254740991;function ii(t){return typeof t==\"number\"&&t>-1&&t%1==0&&t<=ei}var ni=ii;var oi=\"[object Arguments]\",ri=\"[object Array]\",si=\"[object Boolean]\",ai=\"[object Date]\",li=\"[object Error]\",ci=\"[object Function]\",di=\"[object Map]\",ui=\"[object Number]\",hi=\"[object Object]\",fi=\"[object RegExp]\",mi=\"[object Set]\",gi=\"[object String]\",pi=\"[object WeakMap]\";var bi=\"[object ArrayBuffer]\",wi=\"[object DataView]\",_i=\"[object Float32Array]\",ki=\"[object Float64Array]\",vi=\"[object Int8Array]\",yi=\"[object Int16Array]\",xi=\"[object Int32Array]\",Ci=\"[object Uint8Array]\",Ai=\"[object Uint8ClampedArray]\",Ti=\"[object Uint16Array]\",Pi=\"[object Uint32Array]\";var Ei={};Ei[_i]=Ei[ki]=Ei[vi]=Ei[yi]=Ei[xi]=Ei[Ci]=Ei[Ai]=Ei[Ti]=Ei[Pi]=true;Ei[oi]=Ei[ri]=Ei[bi]=Ei[si]=Ei[wi]=Ei[ai]=Ei[li]=Ei[ci]=Ei[di]=Ei[ui]=Ei[hi]=Ei[fi]=Ei[mi]=Ei[gi]=Ei[pi]=false;function Si(t){return T(t)&&ni(t.length)&&!!Ei[k(t)]}var Mi=Si;function Oi(t){return function(e){return t(e)}}var Ii=Oi;var Ri=i(5);var Li=Ri[\"a\"]&&Ri[\"a\"].isTypedArray;var Ni=Li?Ii(Li):Mi;var Bi=Ni;var Vi=Object.prototype;var Di=Vi.hasOwnProperty;function zi(t,e){var i=Ke(t),n=!i&&Ge(t),o=!i&&!n&&Object(Xe[\"a\"])(t),r=!i&&!n&&!o&&Bi(t),s=i||n||o||r,a=s?ze(t.length,String):[],l=a.length;for(var c in t){if((e||Di.call(t,c))&&!(s&&(c==\"length\"||o&&(c==\"offset\"||c==\"parent\")||r&&(c==\"buffer\"||c==\"byteLength\"||c==\"byteOffset\")||ti(c,l)))){a.push(c)}}return a}var Fi=zi;var ji=Object.prototype;function Hi(t){var e=t&&t.constructor,i=typeof e==\"function\"&&e.prototype||ji;return t===i}var Wi=Hi;var qi=y(Object.keys,Object);var $i=qi;var Ui=Object.prototype;var Gi=Ui.hasOwnProperty;function Ji(t){if(!Wi(t)){return $i(t)}var e=[];for(var i in Object(t)){if(Gi.call(t,i)&&i!=\"constructor\"){e.push(i)}}return e}var Ki=Ji;function Xi(t){return t!=null&&ni(t.length)&&!mt(t)}var Yi=Xi;function Qi(t){return Yi(t)?Fi(t):Ki(t)}var Zi=Qi;function tn(t,e){return t&&Ve(e,Zi(e),t)}var en=tn;function nn(t){var e=[];if(t!=null){for(var i in Object(t)){e.push(i)}}return e}var on=nn;var rn=Object.prototype;var sn=rn.hasOwnProperty;function an(t){if(!lt(t)){return on(t)}var e=Wi(t),i=[];for(var n in t){if(!(n==\"constructor\"&&(e||!sn.call(t,n)))){i.push(n)}}return i}var ln=an;function cn(t){return Yi(t)?Fi(t,true):ln(t)}var dn=cn;function un(t,e){return t&&Ve(e,dn(e),t)}var hn=un;var fn=i(8);function mn(t,e){var i=-1,n=t.length;e||(e=Array(n));while(++i<n){e[i]=t[i]}return e}var gn=mn;function pn(t,e){var i=-1,n=t==null?0:t.length,o=0,r=[];while(++i<n){var s=t[i];if(e(s,i,t)){r[o++]=s}}return r}var bn=pn;function wn(){return[]}var _n=wn;var kn=Object.prototype;var vn=kn.propertyIsEnumerable;var yn=Object.getOwnPropertySymbols;var xn=!yn?_n:function(t){if(t==null){return[]}t=Object(t);return bn(yn(t),(function(e){return vn.call(t,e)}))};var Cn=xn;function An(t,e){return Ve(t,Cn(t),e)}var Tn=An;function Pn(t,e){var i=-1,n=e.length,o=t.length;while(++i<n){t[o+i]=e[i]}return t}var En=Pn;var Sn=Object.getOwnPropertySymbols;var Mn=!Sn?_n:function(t){var e=[];while(t){En(e,Cn(t));t=C(t)}return e};var On=Mn;function In(t,e){return Ve(t,On(t),e)}var Rn=In;function Ln(t,e,i){var n=e(t);return Ke(t)?n:En(n,i(t))}var Nn=Ln;function Bn(t){return Nn(t,Zi,Cn)}var Vn=Bn;function Dn(t){return Nn(t,dn,On)}var zn=Dn;var Fn=Bt(n[\"a\"],\"DataView\");var jn=Fn;var Hn=Bt(n[\"a\"],\"Promise\");var Wn=Hn;var qn=Bt(n[\"a\"],\"Set\");var $n=qn;var Un=Bt(n[\"a\"],\"WeakMap\");var Gn=Un;var Jn=\"[object Map]\",Kn=\"[object Object]\",Xn=\"[object Promise]\",Yn=\"[object Set]\",Qn=\"[object WeakMap]\";var Zn=\"[object DataView]\";var to=xt(jn),eo=xt(Dt),io=xt(Wn),no=xt($n),oo=xt(Gn);var ro=k;if(jn&&ro(new jn(new ArrayBuffer(1)))!=Zn||Dt&&ro(new Dt)!=Jn||Wn&&ro(Wn.resolve())!=Xn||$n&&ro(new $n)!=Yn||Gn&&ro(new Gn)!=Qn){ro=function(t){var e=k(t),i=e==Kn?t.constructor:undefined,n=i?xt(i):\"\";if(n){switch(n){case to:return Zn;case eo:return Jn;case io:return Xn;case no:return Yn;case oo:return Qn}}return e}}var so=ro;var ao=Object.prototype;var lo=ao.hasOwnProperty;function co(t){var e=t.length,i=new t.constructor(e);if(e&&typeof t[0]==\"string\"&&lo.call(t,\"index\")){i.index=t.index;i.input=t.input}return i}var uo=co;var ho=n[\"a\"].Uint8Array;var fo=ho;function mo(t){var e=new t.constructor(t.byteLength);new fo(e).set(new fo(t));return e}var go=mo;function po(t,e){var i=e?go(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.byteLength)}var bo=po;var wo=/\\w*$/;function _o(t){var e=new t.constructor(t.source,wo.exec(t));e.lastIndex=t.lastIndex;return e}var ko=_o;var vo=r?r.prototype:undefined,yo=vo?vo.valueOf:undefined;function xo(t){return yo?Object(yo.call(t)):{}}var Co=xo;function Ao(t,e){var i=e?go(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.length)}var To=Ao;var Po=\"[object Boolean]\",Eo=\"[object Date]\",So=\"[object Map]\",Mo=\"[object Number]\",Oo=\"[object RegExp]\",Io=\"[object Set]\",Ro=\"[object String]\",Lo=\"[object Symbol]\";var No=\"[object ArrayBuffer]\",Bo=\"[object DataView]\",Vo=\"[object Float32Array]\",Do=\"[object Float64Array]\",zo=\"[object Int8Array]\",Fo=\"[object Int16Array]\",jo=\"[object Int32Array]\",Ho=\"[object Uint8Array]\",Wo=\"[object Uint8ClampedArray]\",qo=\"[object Uint16Array]\",$o=\"[object Uint32Array]\";function Uo(t,e,i){var n=t.constructor;switch(e){case No:return go(t);case Po:case Eo:return new n(+t);case Bo:return bo(t,i);case Vo:case Do:case zo:case Fo:case jo:case Ho:case Wo:case qo:case $o:return To(t,i);case So:return new n;case Mo:case Ro:return new n(t);case Oo:return ko(t);case Io:return new n;case Lo:return Co(t)}}var Go=Uo;var Jo=Object.create;var Ko=function(){function t(){}return function(e){if(!lt(e)){return{}}if(Jo){return Jo(e)}t.prototype=e;var i=new t;t.prototype=undefined;return i}}();var Xo=Ko;function Yo(t){return typeof t.constructor==\"function\"&&!Wi(t)?Xo(C(t)):{}}var Qo=Yo;var Zo=\"[object Map]\";function tr(t){return T(t)&&so(t)==Zo}var er=tr;var ir=Ri[\"a\"]&&Ri[\"a\"].isMap;var nr=ir?Ii(ir):er;var or=nr;var rr=\"[object Set]\";function sr(t){return T(t)&&so(t)==rr}var ar=sr;var lr=Ri[\"a\"]&&Ri[\"a\"].isSet;var cr=lr?Ii(lr):ar;var dr=cr;var ur=1,hr=2,fr=4;var mr=\"[object Arguments]\",gr=\"[object Array]\",pr=\"[object Boolean]\",br=\"[object Date]\",wr=\"[object Error]\",_r=\"[object Function]\",kr=\"[object GeneratorFunction]\",vr=\"[object Map]\",yr=\"[object Number]\",xr=\"[object Object]\",Cr=\"[object RegExp]\",Ar=\"[object Set]\",Tr=\"[object String]\",Pr=\"[object Symbol]\",Er=\"[object WeakMap]\";var Sr=\"[object ArrayBuffer]\",Mr=\"[object DataView]\",Or=\"[object Float32Array]\",Ir=\"[object Float64Array]\",Rr=\"[object Int8Array]\",Lr=\"[object Int16Array]\",Nr=\"[object Int32Array]\",Br=\"[object Uint8Array]\",Vr=\"[object Uint8ClampedArray]\",Dr=\"[object Uint16Array]\",zr=\"[object Uint32Array]\";var Fr={};Fr[mr]=Fr[gr]=Fr[Sr]=Fr[Mr]=Fr[pr]=Fr[br]=Fr[Or]=Fr[Ir]=Fr[Rr]=Fr[Lr]=Fr[Nr]=Fr[vr]=Fr[yr]=Fr[xr]=Fr[Cr]=Fr[Ar]=Fr[Tr]=Fr[Pr]=Fr[Br]=Fr[Vr]=Fr[Dr]=Fr[zr]=true;Fr[wr]=Fr[_r]=Fr[Er]=false;function jr(t,e,i,n,o,r){var s,a=e&ur,l=e&hr,c=e&fr;if(i){s=o?i(t,n,o,r):i(t)}if(s!==undefined){return s}if(!lt(t)){return t}var d=Ke(t);if(d){s=uo(t);if(!a){return gn(t,s)}}else{var u=so(t),h=u==_r||u==kr;if(Object(Xe[\"a\"])(t)){return Object(fn[\"a\"])(t,a)}if(u==xr||u==mr||h&&!o){s=l||h?{}:Qo(t);if(!a){return l?Rn(t,hn(s,t)):Tn(t,en(s,t))}}else{if(!Fr[u]){return o?t:{}}s=Go(t,u,a)}}r||(r=new Ae);var f=r.get(t);if(f){return f}r.set(t,s);if(dr(t)){t.forEach((function(n){s.add(jr(n,e,i,n,t,r))}))}else if(or(t)){t.forEach((function(n,o){s.set(o,jr(n,e,i,o,t,r))}))}var m=c?l?zn:Vn:l?keysIn:Zi;var g=d?undefined:m(t);Pe(g||t,(function(n,o){if(g){o=n;n=t[o]}Ne(s,o,jr(n,e,i,o,t,r))}));return s}var Hr=jr;var Wr=1,qr=4;function $r(t,e){e=typeof e==\"function\"?e:undefined;return Hr(t,Wr|qr,e)}var Ur=$r;function Gr(t){return T(t)&&t.nodeType===1&&!L(t)}var Jr=Gr;class Kr{constructor(t,e){this._config={};if(e){this.define(Xr(e))}if(t){this._setObjectToTarget(this._config,t)}}set(t,e){this._setToTarget(this._config,t,e)}define(t,e){const i=true;this._setToTarget(this._config,t,e,i)}get(t){return this._getFromSource(this._config,t)}*names(){for(const t of Object.keys(this._config)){yield t}}_setToTarget(t,e,i,n=false){if(L(e)){this._setObjectToTarget(t,e,n);return}const o=e.split(\".\");e=o.pop();for(const e of o){if(!L(t[e])){t[e]={}}t=t[e]}if(L(i)){if(!L(t[e])){t[e]={}}t=t[e];this._setObjectToTarget(t,i,n);return}if(n&&typeof t[e]!=\"undefined\"){return}t[e]=i}_getFromSource(t,e){const i=e.split(\".\");e=i.pop();for(const e of i){if(!L(t[e])){t=null;break}t=t[e]}return t?Xr(t[e]):undefined}_setObjectToTarget(t,e,i){Object.keys(e).forEach(n=>{this._setToTarget(t,n,e[n],i)})}}function Xr(t){return Ur(t,Yr)}function Yr(t){return Jr(t)?t:undefined}function Qr(){return function t(){t.called=true}}var Zr=Qr;class ts{constructor(t,e){this.source=t;this.name=e;this.path=[];this.stop=Zr();this.off=Zr()}}const es=new Array(256).fill().map((t,e)=>(\"0\"+e.toString(16)).slice(-2));function is(){const t=Math.random()*4294967296>>>0;const e=Math.random()*4294967296>>>0;const i=Math.random()*4294967296>>>0;const n=Math.random()*4294967296>>>0;return\"e\"+es[t>>0&255]+es[t>>8&255]+es[t>>16&255]+es[t>>24&255]+es[e>>0&255]+es[e>>8&255]+es[e>>16&255]+es[e>>24&255]+es[i>>0&255]+es[i>>8&255]+es[i>>16&255]+es[i>>24&255]+es[n>>0&255]+es[n>>8&255]+es[n>>16&255]+es[n>>24&255]}const ns={get(t){if(typeof t!=\"number\"){return this[t]||this.normal}else{return t}},highest:1e5,high:1e3,normal:0,low:-1e3,lowest:-1e5};var os=ns;var rs=i(6);var ss=i(0);const as=Symbol(\"listeningTo\");const ls=Symbol(\"emitterId\");const cs={on(t,e,i={}){this.listenTo(this,t,e,i)},once(t,e,i){let n=false;const o=function(t,...i){if(!n){n=true;t.off();e.call(this,t,...i)}};this.listenTo(this,t,o,i)},off(t,e){this.stopListening(this,t,e)},listenTo(t,e,i,n={}){let o,r;if(!this[as]){this[as]={}}const s=this[as];if(!fs(t)){hs(t)}const a=fs(t);if(!(o=s[a])){o=s[a]={emitter:t,callbacks:{}}}if(!(r=o.callbacks[e])){r=o.callbacks[e]=[]}r.push(i);ps(t,e);const l=bs(t,e);const c=os.get(n.priority);const d={callback:i,priority:c};for(const t of l){let e=false;for(let i=0;i<t.length;i++){if(t[i].priority<c){t.splice(i,0,d);e=true;break}}if(!e){t.push(d)}}},stopListening(t,e,i){const n=this[as];let o=t&&fs(t);const r=n&&o&&n[o];const s=r&&e&&r.callbacks[e];if(!n||t&&!r||e&&!s){return}if(i){ks(t,e,i)}else if(s){while(i=s.pop()){ks(t,e,i)}delete r.callbacks[e]}else if(r){for(e in r.callbacks){this.stopListening(t,e)}delete n[o]}else{for(o in n){this.stopListening(n[o].emitter)}delete this[as]}},fire(t,...e){try{const i=t instanceof ts?t:new ts(this,t);const n=i.name;let o=ws(this,n);i.path.push(this);if(o){const t=[i,...e];o=Array.from(o);for(let e=0;e<o.length;e++){o[e].callback.apply(this,t);if(i.off.called){delete i.off.called;ks(this,n,o[e].callback)}if(i.stop.called){break}}}if(this._delegations){const t=this._delegations.get(n);const o=this._delegations.get(\"*\");if(t){_s(t,i,e)}if(o){_s(o,i,e)}}return i.return}catch(t){ss[\"b\"].rethrowUnexpectedError(t,this)}},delegate(...t){return{to:(e,i)=>{if(!this._delegations){this._delegations=new Map}t.forEach(t=>{const n=this._delegations.get(t);if(!n){this._delegations.set(t,new Map([[e,i]]))}else{n.set(e,i)}})}}},stopDelegating(t,e){if(!this._delegations){return}if(!t){this._delegations.clear()}else if(!e){this._delegations.delete(t)}else{const i=this._delegations.get(t);if(i){i.delete(e)}}}};var ds=cs;function us(t,e){if(t[as]&&t[as][e]){return t[as][e].emitter}return null}function hs(t,e){if(!t[ls]){t[ls]=e||is()}}function fs(t){return t[ls]}function ms(t){if(!t._events){Object.defineProperty(t,\"_events\",{value:{}})}return t._events}function gs(){return{callbacks:[],childEvents:[]}}function ps(t,e){const i=ms(t);if(i[e]){return}let n=e;let o=null;const r=[];while(n!==\"\"){if(i[n]){break}i[n]=gs();r.push(i[n]);if(o){i[n].childEvents.push(o)}o=n;n=n.substr(0,n.lastIndexOf(\":\"))}if(n!==\"\"){for(const t of r){t.callbacks=i[n].callbacks.slice()}i[n].childEvents.push(o)}}function bs(t,e){const i=ms(t)[e];if(!i){return[]}let n=[i.callbacks];for(let e=0;e<i.childEvents.length;e++){const o=bs(t,i.childEvents[e]);n=n.concat(o)}return n}function ws(t,e){let i;if(!t._events||!(i=t._events[e])||!i.callbacks.length){if(e.indexOf(\":\")>-1){return ws(t,e.substr(0,e.lastIndexOf(\":\")))}else{return null}}return i.callbacks}function _s(t,e,i){for(let[n,o]of t){if(!o){o=e.name}else if(typeof o==\"function\"){o=o(e.name)}const t=new ts(e.source,o);t.path=[...e.path];n.fire(t,...i)}}function ks(t,e,i){const n=bs(t,e);for(const t of n){for(let e=0;e<t.length;e++){if(t[e].callback==i){t.splice(e,1);e--}}}}function vs(t){return!!(t&&t[Symbol.iterator])}function ys(t,...e){e.forEach(e=>{Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e)).forEach(i=>{if(i in t.prototype){return}const n=Object.getOwnPropertyDescriptor(e,i);n.enumerable=false;Object.defineProperty(t.prototype,i,n)})})}class xs{constructor(t={},e={}){const i=vs(t);if(!i){e=t}this._items=[];this._itemMap=new Map;this._idProperty=e.idProperty||\"id\";this._bindToExternalToInternalMap=new WeakMap;this._bindToInternalToExternalMap=new WeakMap;this._skippedIndexesFromExternal=[];if(i){for(const e of t){this._items.push(e);this._itemMap.set(this._getItemIdBeforeAdding(e),e)}}}get length(){return this._items.length}get first(){return this._items[0]||null}get last(){return this._items[this.length-1]||null}add(t,e){const i=this._getItemIdBeforeAdding(t);if(e===undefined){e=this._items.length}else if(e>this._items.length||e<0){throw new ss[\"b\"](\"collection-add-item-invalid-index\",this)}this._items.splice(e,0,t);this._itemMap.set(i,t);this.fire(\"add\",t,e);return this}get(t){let e;if(typeof t==\"string\"){e=this._itemMap.get(t)}else if(typeof t==\"number\"){e=this._items[t]}else{throw new ss[\"b\"](\"collection-get-invalid-arg: Index or id must be given.\",this)}return e||null}has(t){if(typeof t==\"string\"){return this._itemMap.has(t)}else{const e=this._idProperty;const i=t[e];return this._itemMap.has(i)}}getIndex(t){let e;if(typeof t==\"string\"){e=this._itemMap.get(t)}else{e=t}return this._items.indexOf(e)}remove(t){let e,i,n;let o=false;const r=this._idProperty;if(typeof t==\"string\"){i=t;n=this._itemMap.get(i);o=!n;if(n){e=this._items.indexOf(n)}}else if(typeof t==\"number\"){e=t;n=this._items[e];o=!n;if(n){i=n[r]}}else{n=t;i=n[r];e=this._items.indexOf(n);o=e==-1||!this._itemMap.get(i)}if(o){throw new ss[\"b\"](\"collection-remove-404: Item not found.\",this)}this._items.splice(e,1);this._itemMap.delete(i);const s=this._bindToInternalToExternalMap.get(n);this._bindToInternalToExternalMap.delete(n);this._bindToExternalToInternalMap.delete(s);this.fire(\"remove\",n,e);return n}map(t,e){return this._items.map(t,e)}find(t,e){return this._items.find(t,e)}filter(t,e){return this._items.filter(t,e)}clear(){if(this._bindToCollection){this.stopListening(this._bindToCollection);this._bindToCollection=null}while(this.length){this.remove(0)}}bindTo(t){if(this._bindToCollection){throw new ss[\"b\"](\"collection-bind-to-rebind: The collection cannot be bound more than once.\",this)}this._bindToCollection=t;return{as:t=>{this._setUpBindToBinding(e=>new t(e))},using:t=>{if(typeof t==\"function\"){this._setUpBindToBinding(e=>t(e))}else{this._setUpBindToBinding(e=>e[t])}}}}_setUpBindToBinding(t){const e=this._bindToCollection;const i=(i,n,o)=>{const r=e._bindToCollection==this;const s=e._bindToInternalToExternalMap.get(n);if(r&&s){this._bindToExternalToInternalMap.set(n,s);this._bindToInternalToExternalMap.set(s,n)}else{const i=t(n);if(!i){this._skippedIndexesFromExternal.push(o);return}let r=o;for(const t of this._skippedIndexesFromExternal){if(o>t){r--}}for(const t of e._skippedIndexesFromExternal){if(r>=t){r++}}this._bindToExternalToInternalMap.set(n,i);this._bindToInternalToExternalMap.set(i,n);this.add(i,r);for(let t=0;t<e._skippedIndexesFromExternal.length;t++){if(r<=e._skippedIndexesFromExternal[t]){e._skippedIndexesFromExternal[t]++}}}};for(const t of e){i(null,t,e.getIndex(t))}this.listenTo(e,\"add\",i);this.listenTo(e,\"remove\",(t,e,i)=>{const n=this._bindToExternalToInternalMap.get(e);if(n){this.remove(n)}this._skippedIndexesFromExternal=this._skippedIndexesFromExternal.reduce((t,e)=>{if(i<e){t.push(e-1)}if(i>e){t.push(e)}return t},[])})}_getItemIdBeforeAdding(t){const e=this._idProperty;let i;if(e in t){i=t[e];if(typeof i!=\"string\"){throw new ss[\"b\"](\"collection-add-invalid-id\",this)}if(this.get(i)){throw new ss[\"b\"](\"collection-add-item-already-exists\",this)}}else{t[e]=i=is()}return i}[Symbol.iterator](){return this._items[Symbol.iterator]()}}ys(xs,ds);class Cs{constructor(t,e=[],i=[]){this._context=t;this._plugins=new Map;this._availablePlugins=new Map;for(const t of e){if(t.pluginName){this._availablePlugins.set(t.pluginName,t)}}this._contextPlugins=new Map;for(const[t,e]of i){this._contextPlugins.set(t,e);this._contextPlugins.set(e,t);if(t.pluginName){this._availablePlugins.set(t.pluginName,t)}}}*[Symbol.iterator](){for(const t of this._plugins){if(typeof t[0]==\"function\"){yield t}}}get(t){const e=this._plugins.get(t);if(!e){const e=\"plugincollection-plugin-not-loaded: The requested plugin is not loaded.\";let i=t;if(typeof t==\"function\"){i=t.pluginName||t.name}throw new ss[\"b\"](e,this._context,{plugin:i})}return e}has(t){return this._plugins.has(t)}init(t,e=[]){const i=this;const n=this._context;const o=new Set;const r=[];const s=m(t);const a=m(e);const l=f(t);if(l){const t=\"plugincollection-plugin-not-found: Some plugins are not available and could not be loaded.\";console.error(Object(ss[\"a\"])(t),{plugins:l});return Promise.reject(new ss[\"b\"](t,n,{plugins:l}))}return Promise.all(s.map(c)).then(()=>d(r,\"init\")).then(()=>d(r,\"afterInit\")).then(()=>r);function c(t){if(a.includes(t)){return}if(i._plugins.has(t)||o.has(t)){return}return u(t).catch(e=>{console.error(Object(ss[\"a\"])(\"plugincollection-load: It was not possible to load the plugin.\"),{plugin:t});throw e})}function d(t,e){return t.reduce((t,n)=>{if(!n[e]){return t}if(i._contextPlugins.has(n)){return t}return t.then(n[e].bind(n))},Promise.resolve())}function u(t){return new Promise(s=>{o.add(t);if(t.requires){t.requires.forEach(i=>{const o=h(i);if(t.isContextPlugin&&!o.isContextPlugin){throw new ss[\"b\"](\"plugincollection-context-required: Context plugin can not require plugin which is not a context plugin\",null,{plugin:o.name,requiredBy:t.name})}if(e.includes(o)){throw new ss[\"b\"](\"plugincollection-required: Cannot load a plugin because one of its dependencies is listed in\"+\"the `removePlugins` option.\",n,{plugin:o.name,requiredBy:t.name})}c(o)})}const a=i._contextPlugins.get(t)||new t(n);i._add(t,a);r.push(a);s()})}function h(t){if(typeof t==\"function\"){return t}return i._availablePlugins.get(t)}function f(t){const e=[];for(const i of t){if(!h(i)){e.push(i)}}return e.length?e:null}function m(t){return t.map(t=>h(t)).filter(t=>!!t)}}destroy(){const t=[];for(const[,e]of this){if(typeof e.destroy==\"function\"&&!this._contextPlugins.has(e)){t.push(e.destroy())}}return Promise.all(t)}_add(t,e){this._plugins.set(t,e);const i=t.pluginName;if(!i){return}if(this._plugins.has(i)){throw new ss[\"b\"](\"plugincollection-plugin-name-conflict: Two plugins with the same name were loaded.\",null,{pluginName:i,plugin1:this._plugins.get(i).constructor,plugin2:t})}this._plugins.set(i,e)}}ys(Cs,ds);if(!window.CKEDITOR_TRANSLATIONS){window.CKEDITOR_TRANSLATIONS={}}function As(t,e,i){if(!window.CKEDITOR_TRANSLATIONS[t]){window.CKEDITOR_TRANSLATIONS[t]={}}const n=window.CKEDITOR_TRANSLATIONS[t];n.dictionary=n.dictionary||{};n.getPluralForm=i||n.getPluralForm;Object.assign(n.dictionary,e)}function Ts(t,e,i=1){if(typeof i!==\"number\"){throw new ss[\"b\"](\"translation-service-quantity-not-a-number: Expecting `quantity` to be a number.\",null,{quantity:i})}const n=Ss();if(n===1){t=Object.keys(window.CKEDITOR_TRANSLATIONS)[0]}const o=e.id||e.string;if(n===0||!Es(t,o)){if(i!==1){return e.plural}return e.string}const r=window.CKEDITOR_TRANSLATIONS[t].dictionary;const s=window.CKEDITOR_TRANSLATIONS[t].getPluralForm||(t=>t===1?0:1);if(typeof r[o]===\"string\"){return r[o]}const a=Number(s(i));return r[o][a]}function Ps(){window.CKEDITOR_TRANSLATIONS={}}function Es(t,e){return!!window.CKEDITOR_TRANSLATIONS[t]&&!!window.CKEDITOR_TRANSLATIONS[t].dictionary[e]}function Ss(){return Object.keys(window.CKEDITOR_TRANSLATIONS).length}const Ms=[\"ar\",\"fa\",\"he\",\"ku\",\"ug\"];class Os{constructor(t={}){this.uiLanguage=t.uiLanguage||\"en\";this.contentLanguage=t.contentLanguage||this.uiLanguage;this.uiLanguageDirection=Rs(this.uiLanguage);this.contentLanguageDirection=Rs(this.contentLanguage);this.t=(t,e)=>this._t(t,e)}get language(){console.warn(\"locale-deprecated-language-property: \"+\"The Locale#language property has been deprecated and will be removed in the near future. \"+\"Please use #uiLanguage and #contentLanguage properties instead.\");return this.uiLanguage}_t(t,e=[]){if(!Array.isArray(e)){e=[e]}if(typeof t===\"string\"){t={string:t}}const i=!!t.plural;const n=i?e[0]:1;const o=Ts(this.uiLanguage,t,n);return Is(o,e)}}function Is(t,e){return t.replace(/%(\\d+)/g,(t,i)=>i<e.length?e[i]:t)}function Rs(t){return Ms.includes(t)?\"rtl\":\"ltr\"}class Ls{constructor(t){this.config=new Kr(t,this.constructor.defaultConfig);const e=this.constructor.builtinPlugins;this.config.define(\"plugins\",e);this.plugins=new Cs(this,e);const i=this.config.get(\"language\")||{};this.locale=new Os({uiLanguage:typeof i===\"string\"?i:i.ui,contentLanguage:this.config.get(\"language.content\")});this.t=this.locale.t;this.editors=new xs;this._contextOwner=null}initPlugins(){const t=this.config.get(\"plugins\")||[];for(const e of t){if(typeof e!=\"function\"){throw new ss[\"b\"](\"context-initplugins-constructor-only: Only a constructor function is allowed as a context plugin.\",null,{Plugin:e})}if(e.isContextPlugin!==true){throw new ss[\"b\"](\"context-initplugins-invalid-plugin: Only a plugin marked as a context plugin is allowed to be used with a context.\",null,{Plugin:e})}}return this.plugins.init(t)}destroy(){return Promise.all(Array.from(this.editors,t=>t.destroy())).then(()=>this.plugins.destroy())}_addEditor(t,e){if(this._contextOwner){throw new ss[\"b\"](\"context-addEditor-private-context: Cannot add multiple editors to the context which is created by the editor.\")}this.editors.add(t);if(e){this._contextOwner=t}}_removeEditor(t){if(this.editors.has(t)){this.editors.remove(t)}if(this._contextOwner===t){return this.destroy()}return Promise.resolve()}_getEditorConfig(){const t={};for(const e of this.config.names()){if(![\"plugins\",\"removePlugins\",\"extraPlugins\"].includes(e)){t[e]=this.config.get(e)}}return t}static create(t){return new Promise(e=>{const i=new this(t);e(i.initPlugins().then(()=>i))})}}function Ns(t,e){const i=Math.min(t.length,e.length);for(let n=0;n<i;n++){if(t[n]!=e[n]){return n}}if(t.length==e.length){return\"same\"}else if(t.length<e.length){return\"prefix\"}else{return\"extension\"}}var Bs=4;function Vs(t){return Hr(t,Bs)}var Ds=Vs;class zs{constructor(t){this.document=t;this.parent=null}get index(){let t;if(!this.parent){return null}if((t=this.parent.getChildIndex(this))==-1){throw new ss[\"b\"](\"view-node-not-found-in-parent: The node's parent does not contain this node.\",this)}return t}get nextSibling(){const t=this.index;return t!==null&&this.parent.getChild(t+1)||null}get previousSibling(){const t=this.index;return t!==null&&this.parent.getChild(t-1)||null}get root(){let t=this;while(t.parent){t=t.parent}return t}isAttached(){return this.root.is(\"rootElement\")}getPath(){const t=[];let e=this;while(e.parent){t.unshift(e.index);e=e.parent}return t}getAncestors(t={includeSelf:false,parentFirst:false}){const e=[];let i=t.includeSelf?this:this.parent;while(i){e[t.parentFirst?\"push\":\"unshift\"](i);i=i.parent}return e}getCommonAncestor(t,e={}){const i=this.getAncestors(e);const n=t.getAncestors(e);let o=0;while(i[o]==n[o]&&i[o]){o++}return o===0?null:i[o-1]}isBefore(t){if(this==t){return false}if(this.root!==t.root){return false}const e=this.getPath();const i=t.getPath();const n=Ns(e,i);switch(n){case\"prefix\":return true;case\"extension\":return false;default:return e[n]<i[n]}}isAfter(t){if(this==t){return false}if(this.root!==t.root){return false}return!this.isBefore(t)}_remove(){this.parent._removeChildren(this.index)}_fireChange(t,e){this.fire(\"change:\"+t,e);if(this.parent){this.parent._fireChange(t,e)}}toJSON(){const t=Ds(this);delete t.parent;return t}is(t){return t===\"node\"||t===\"view:node\"}}ys(zs,ds);class Fs extends zs{constructor(t,e){super(t);this._textData=e}is(t){return t===\"text\"||t===\"view:text\"||t===\"node\"||t===\"view:node\"}get data(){return this._textData}get _data(){return this.data}set _data(t){this._fireChange(\"text\",this);this._textData=t}isSimilar(t){if(!(t instanceof Fs)){return false}return this===t||this.data===t.data}_clone(){return new Fs(this.document,this.data)}}class js{constructor(t,e,i){this.textNode=t;if(e<0||e>t.data.length){throw new ss[\"b\"](\"view-textproxy-wrong-offsetintext: Given offsetInText value is incorrect.\",this)}if(i<0||e+i>t.data.length){throw new ss[\"b\"](\"view-textproxy-wrong-length: Given length value is incorrect.\",this)}this.data=t.data.substring(e,e+i);this.offsetInText=e}get offsetSize(){return this.data.length}get isPartial(){return this.data.length!==this.textNode.data.length}get parent(){return this.textNode.parent}get root(){return this.textNode.root}get document(){return this.textNode.document}is(t){return t===\"textProxy\"||t===\"view:textProxy\"}getAncestors(t={includeSelf:false,parentFirst:false}){const e=[];let i=t.includeSelf?this.textNode:this.parent;while(i!==null){e[t.parentFirst?\"push\":\"unshift\"](i);i=i.parent}return e}}function Hs(t){const e=new Map;for(const i in t){e.set(i,t[i])}return e}function Ws(t){if(vs(t)){return new Map(t)}else{return Hs(t)}}class qs{constructor(...t){this._patterns=[];this.add(...t)}add(...t){for(let e of t){if(typeof e==\"string\"||e instanceof RegExp){e={name:e}}if(e.classes&&(typeof e.classes==\"string\"||e.classes instanceof RegExp)){e.classes=[e.classes]}this._patterns.push(e)}}match(...t){for(const e of t){for(const t of this._patterns){const i=$s(e,t);if(i){return{element:e,pattern:t,match:i}}}}return null}matchAll(...t){const e=[];for(const i of t){for(const t of this._patterns){const n=$s(i,t);if(n){e.push({element:i,pattern:t,match:n})}}}return e.length>0?e:null}getElementName(){if(this._patterns.length!==1){return null}const t=this._patterns[0];const e=t.name;return typeof t!=\"function\"&&e&&!(e instanceof RegExp)?e:null}}function $s(t,e){if(typeof e==\"function\"){return e(t)}const i={};if(e.name){i.name=Us(e.name,t.name);if(!i.name){return null}}if(e.attributes){i.attributes=Gs(e.attributes,t);if(!i.attributes){return null}}if(e.classes){i.classes=Js(e.classes,t);if(!i.classes){return false}}if(e.styles){i.styles=Ks(e.styles,t);if(!i.styles){return false}}return i}function Us(t,e){if(t instanceof RegExp){return t.test(e)}return t===e}function Gs(t,e){const i=[];for(const n in t){const o=t[n];if(e.hasAttribute(n)){const t=e.getAttribute(n);if(o===true){i.push(n)}else if(o instanceof RegExp){if(o.test(t)){i.push(n)}else{return null}}else if(t===o){i.push(n)}else{return null}}else{return null}}return i}function Js(t,e){const i=[];for(const n of t){if(n instanceof RegExp){const t=e.getClassNames();for(const e of t){if(n.test(e)){i.push(e)}}if(i.length===0){return null}}else if(e.hasClass(n)){i.push(n)}else{return null}}return i}function Ks(t,e){const i=[];for(const n in t){const o=t[n];if(e.hasStyle(n)){const t=e.getStyle(n);if(o instanceof RegExp){if(o.test(t)){i.push(n)}else{return null}}else if(t===o){i.push(n)}else{return null}}else{return null}}return i}var Xs=\"[object Symbol]\";function Ys(t){return typeof t==\"symbol\"||T(t)&&k(t)==Xs}var Qs=Ys;var Zs=/\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,ta=/^\\w*$/;function ea(t,e){if(Ke(t)){return false}var i=typeof t;if(i==\"number\"||i==\"symbol\"||i==\"boolean\"||t==null||Qs(t)){return true}return ta.test(t)||!Zs.test(t)||e!=null&&t in Object(e)}var ia=ea;var na=\"Expected a function\";function oa(t,e){if(typeof t!=\"function\"||e!=null&&typeof e!=\"function\"){throw new TypeError(na)}var i=function(){var n=arguments,o=e?e.apply(this,n):n[0],r=i.cache;if(r.has(o)){return r.get(o)}var s=t.apply(this,n);i.cache=r.set(o,s)||r;return s};i.cache=new(oa.Cache||ke);return i}oa.Cache=ke;var ra=oa;var sa=500;function aa(t){var e=ra(t,(function(t){if(i.size===sa){i.clear()}return t}));var i=e.cache;return e}var la=aa;var ca=/[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;var da=/\\\\(\\\\)?/g;var ua=la((function(t){var e=[];if(t.charCodeAt(0)===46){e.push(\"\")}t.replace(ca,(function(t,i,n,o){e.push(n?o.replace(da,\"$1\"):i||t)}));return e}));var ha=ua;function fa(t,e){var i=-1,n=t==null?0:t.length,o=Array(n);while(++i<n){o[i]=e(t[i],i,t)}return o}var ma=fa;var ga=1/0;var pa=r?r.prototype:undefined,ba=pa?pa.toString:undefined;function wa(t){if(typeof t==\"string\"){return t}if(Ke(t)){return ma(t,wa)+\"\"}if(Qs(t)){return ba?ba.call(t):\"\"}var e=t+\"\";return e==\"0\"&&1/t==-ga?\"-0\":e}var _a=wa;function ka(t){return t==null?\"\":_a(t)}var va=ka;function ya(t,e){if(Ke(t)){return t}return ia(t,e)?[t]:ha(va(t))}var xa=ya;function Ca(t){var e=t==null?0:t.length;return e?t[e-1]:undefined}var Aa=Ca;var Ta=1/0;function Pa(t){if(typeof t==\"string\"||Qs(t)){return t}var e=t+\"\";return e==\"0\"&&1/t==-Ta?\"-0\":e}var Ea=Pa;function Sa(t,e){e=xa(e,t);var i=0,n=e.length;while(t!=null&&i<n){t=t[Ea(e[i++])]}return i&&i==n?t:undefined}var Ma=Sa;function Oa(t,e,i){var n=-1,o=t.length;if(e<0){e=-e>o?0:o+e}i=i>o?o:i;if(i<0){i+=o}o=e>i?0:i-e>>>0;e>>>=0;var r=Array(o);while(++n<o){r[n]=t[n+e]}return r}var Ia=Oa;function Ra(t,e){return e.length<2?t:Ma(t,Ia(e,0,-1))}var La=Ra;function Na(t,e){e=xa(e,t);t=La(t,e);return t==null||delete t[Ea(Aa(e))]}var Ba=Na;function Va(t,e){return t==null?true:Ba(t,e)}var Da=Va;function za(t,e,i){var n=t==null?undefined:Ma(t,e);return n===undefined?i:n}var Fa=za;function ja(t,e,i){if(i!==undefined&&!D(t[e],i)||i===undefined&&!(e in t)){Oe(t,e,i)}}var Ha=ja;function Wa(t){return function(e,i,n){var o=-1,r=Object(e),s=n(e),a=s.length;while(a--){var l=s[t?a:++o];if(i(r[l],l,r)===false){break}}return e}}var qa=Wa;var $a=qa();var Ua=$a;function Ga(t){return T(t)&&Yi(t)}var Ja=Ga;function Ka(t,e){if(e===\"constructor\"&&typeof t[e]===\"function\"){return}if(e==\"__proto__\"){return}return t[e]}var Xa=Ka;function Ya(t){return Ve(t,dn(t))}var Qa=Ya;function Za(t,e,i,n,o,r,s){var a=Xa(t,i),l=Xa(e,i),c=s.get(l);if(c){Ha(t,i,c);return}var d=r?r(a,l,i+\"\",t,e,s):undefined;var u=d===undefined;if(u){var h=Ke(l),f=!h&&Object(Xe[\"a\"])(l),m=!h&&!f&&Bi(l);d=l;if(h||f||m){if(Ke(a)){d=a}else if(Ja(a)){d=gn(a)}else if(f){u=false;d=Object(fn[\"a\"])(l,true)}else if(m){u=false;d=To(l,true)}else{d=[]}}else if(L(l)||Ge(l)){d=a;if(Ge(a)){d=Qa(a)}else if(!lt(a)||mt(a)){d=Qo(l)}}else{u=false}}if(u){s.set(l,d);o(d,l,n,r,s);s[\"delete\"](l)}Ha(t,i,d)}var tl=Za;function el(t,e,i,n,o){if(t===e){return}Ua(e,(function(r,s){o||(o=new Ae);if(lt(r)){tl(t,e,s,i,el,n,o)}else{var a=n?n(Xa(t,s),r,s+\"\",t,e,o):undefined;if(a===undefined){a=r}Ha(t,s,a)}}),dn)}var il=el;function nl(t){return t}var ol=nl;function rl(t,e,i){switch(i.length){case 0:return t.call(e);case 1:return t.call(e,i[0]);case 2:return t.call(e,i[0],i[1]);case 3:return t.call(e,i[0],i[1],i[2])}return t.apply(e,i)}var sl=rl;var al=Math.max;function ll(t,e,i){e=al(e===undefined?t.length-1:e,0);return function(){var n=arguments,o=-1,r=al(n.length-e,0),s=Array(r);while(++o<r){s[o]=n[e+o]}o=-1;var a=Array(e+1);while(++o<e){a[o]=n[o]}a[e]=i(s);return sl(t,this,a)}}var cl=ll;function dl(t){return function(){return t}}var ul=dl;var hl=!Se?ol:function(t,e){return Se(t,\"toString\",{configurable:true,enumerable:false,value:ul(e),writable:true})};var fl=hl;var ml=800,gl=16;var pl=Date.now;function bl(t){var e=0,i=0;return function(){var n=pl(),o=gl-(n-i);i=n;if(o>0){if(++e>=ml){return arguments[0]}}else{e=0}return t.apply(undefined,arguments)}}var wl=bl;var _l=wl(fl);var kl=_l;function vl(t,e){return kl(cl(t,e,ol),t+\"\")}var yl=vl;function xl(t,e,i){if(!lt(i)){return false}var n=typeof e;if(n==\"number\"?Yi(i)&&ti(e,i.length):n==\"string\"&&e in i){return D(i[e],t)}return false}var Cl=xl;function Al(t){return yl((function(e,i){var n=-1,o=i.length,r=o>1?i[o-1]:undefined,s=o>2?i[2]:undefined;r=t.length>3&&typeof r==\"function\"?(o--,r):undefined;if(s&&Cl(i[0],i[1],s)){r=o<3?undefined:r;o=1}e=Object(e);while(++n<o){var a=i[n];if(a){t(e,a,n,r)}}return e}))}var Tl=Al;var Pl=Tl((function(t,e,i){il(t,e,i)}));var El=Pl;function Sl(t,e,i,n){if(!lt(t)){return t}e=xa(e,t);var o=-1,r=e.length,s=r-1,a=t;while(a!=null&&++o<r){var l=Ea(e[o]),c=i;if(o!=s){var d=a[l];c=n?n(d,l,a):undefined;if(c===undefined){c=lt(d)?d:ti(e[o+1])?[]:{}}}Ne(a,l,c);a=a[l]}return t}var Ml=Sl;function Ol(t,e,i){return t==null?t:Ml(t,e,i)}var Il=Ol;class Rl{constructor(t){this._styles={};this._styleProcessor=t}get isEmpty(){const t=Object.entries(this._styles);const e=Array.from(t);return!e.length}get size(){if(this.isEmpty){return 0}return this.getStyleNames().length}setTo(t){this.clear();const e=Array.from(Nl(t).entries());for(const[t,i]of e){this._styleProcessor.toNormalizedForm(t,i,this._styles)}}has(t){if(this.isEmpty){return false}const e=this._styleProcessor.getReducedForm(t,this._styles);const i=e.find(([e])=>e===t);return Array.isArray(i)}set(t,e){if(lt(t)){for(const[e,i]of Object.entries(t)){this._styleProcessor.toNormalizedForm(e,i,this._styles)}}else{this._styleProcessor.toNormalizedForm(t,e,this._styles)}}remove(t){const e=Bl(t);Da(this._styles,e);delete this._styles[t];this._cleanEmptyObjectsOnPath(e)}getNormalized(t){return this._styleProcessor.getNormalized(t,this._styles)}toString(){if(this.isEmpty){return\"\"}return this._getStylesEntries().map(t=>t.join(\":\")).sort().join(\";\")+\";\"}getAsString(t){if(this.isEmpty){return}if(this._styles[t]&&!lt(this._styles[t])){return this._styles[t]}const e=this._styleProcessor.getReducedForm(t,this._styles);const i=e.find(([e])=>e===t);if(Array.isArray(i)){return i[1]}}getStyleNames(){if(this.isEmpty){return[]}const t=this._getStylesEntries();return t.map(([t])=>t)}clear(){this._styles={}}_getStylesEntries(){const t=[];const e=Object.keys(this._styles);for(const i of e){t.push(...this._styleProcessor.getReducedForm(i,this._styles))}return t}_cleanEmptyObjectsOnPath(t){const e=t.split(\".\");const i=e.length>1;if(!i){return}const n=e.splice(0,e.length-1).join(\".\");const o=Fa(this._styles,n);if(!o){return}const r=!Array.from(Object.keys(o)).length;if(r){this.remove(n)}}}class Ll{constructor(){this._normalizers=new Map;this._extractors=new Map;this._reducers=new Map;this._consumables=new Map}toNormalizedForm(t,e,i){if(lt(e)){Vl(i,Bl(t),e);return}if(this._normalizers.has(t)){const n=this._normalizers.get(t);const{path:o,value:r}=n(e);Vl(i,o,r)}else{Vl(i,t,e)}}getNormalized(t,e){if(!t){return El({},e)}if(e[t]!==undefined){return e[t]}if(this._extractors.has(t)){const i=this._extractors.get(t);if(typeof i===\"string\"){return Fa(e,i)}const n=i(t,e);if(n){return n}}return Fa(e,Bl(t))}getReducedForm(t,e){const i=this.getNormalized(t,e);if(i===undefined){return[]}if(this._reducers.has(t)){const e=this._reducers.get(t);return e(i)}return[[t,i]]}getRelatedStyles(t){return this._consumables.get(t)||[]}setNormalizer(t,e){this._normalizers.set(t,e)}setExtractor(t,e){this._extractors.set(t,e)}setReducer(t,e){this._reducers.set(t,e)}setStyleRelation(t,e){this._mapStyleNames(t,e);for(const i of e){this._mapStyleNames(i,[t])}}_mapStyleNames(t,e){if(!this._consumables.has(t)){this._consumables.set(t,[])}this._consumables.get(t).push(...e)}}function Nl(t){let e=null;let i=0;let n=0;let o=null;const r=new Map;if(t===\"\"){return r}if(t.charAt(t.length-1)!=\";\"){t=t+\";\"}for(let s=0;s<t.length;s++){const a=t.charAt(s);if(e===null){switch(a){case\":\":if(!o){o=t.substr(i,s-i);n=s+1}break;case'\"':case\"'\":e=a;break;case\";\":{const e=t.substr(n,s-n);if(o){r.set(o.trim(),e.trim())}o=null;i=s+1;break}}}else if(a===e){e=null}}return r}function Bl(t){return t.replace(\"-\",\".\")}function Vl(t,e,i){let n=i;if(lt(i)){n=El({},Fa(t,e),i)}Il(t,e,n)}class Dl extends zs{constructor(t,e,i,n){super(t);this.name=e;this._attrs=zl(i);this._children=[];if(n){this._insertChild(0,n)}this._classes=new Set;if(this._attrs.has(\"class\")){const t=this._attrs.get(\"class\");Fl(this._classes,t);this._attrs.delete(\"class\")}this._styles=new Rl(this.document.stylesProcessor);if(this._attrs.has(\"style\")){this._styles.setTo(this._attrs.get(\"style\"));this._attrs.delete(\"style\")}this._customProperties=new Map}get childCount(){return this._children.length}get isEmpty(){return this._children.length===0}is(t,e=null){if(!e){return t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"element\"||t===\"view:element\")}}getChild(t){return this._children[t]}getChildIndex(t){return this._children.indexOf(t)}getChildren(){return this._children[Symbol.iterator]()}*getAttributeKeys(){if(this._classes.size>0){yield\"class\"}if(!this._styles.isEmpty){yield\"style\"}yield*this._attrs.keys()}*getAttributes(){yield*this._attrs.entries();if(this._classes.size>0){yield[\"class\",this.getAttribute(\"class\")]}if(!this._styles.isEmpty){yield[\"style\",this.getAttribute(\"style\")]}}getAttribute(t){if(t==\"class\"){if(this._classes.size>0){return[...this._classes].join(\" \")}return undefined}if(t==\"style\"){const t=this._styles.toString();return t==\"\"?undefined:t}return this._attrs.get(t)}hasAttribute(t){if(t==\"class\"){return this._classes.size>0}if(t==\"style\"){return!this._styles.isEmpty}return this._attrs.has(t)}isSimilar(t){if(!(t instanceof Dl)){return false}if(this===t){return true}if(this.name!=t.name){return false}if(this._attrs.size!==t._attrs.size||this._classes.size!==t._classes.size||this._styles.size!==t._styles.size){return false}for(const[e,i]of this._attrs){if(!t._attrs.has(e)||t._attrs.get(e)!==i){return false}}for(const e of this._classes){if(!t._classes.has(e)){return false}}for(const e of this._styles.getStyleNames()){if(!t._styles.has(e)||t._styles.getAsString(e)!==this._styles.getAsString(e)){return false}}return true}hasClass(...t){for(const e of t){if(!this._classes.has(e)){return false}}return true}getClassNames(){return this._classes.keys()}getStyle(t){return this._styles.getAsString(t)}getNormalizedStyle(t){return this._styles.getNormalized(t)}getStyleNames(){return this._styles.getStyleNames()}hasStyle(...t){for(const e of t){if(!this._styles.has(e)){return false}}return true}findAncestor(...t){const e=new qs(...t);let i=this.parent;while(i){if(e.match(i)){return i}i=i.parent}return null}getCustomProperty(t){return this._customProperties.get(t)}*getCustomProperties(){yield*this._customProperties.entries()}getIdentity(){const t=Array.from(this._classes).sort().join(\",\");const e=this._styles.toString();const i=Array.from(this._attrs).map(t=>`${t[0]}=\"${t[1]}\"`).sort().join(\" \");return this.name+(t==\"\"?\"\":` class=\"${t}\"`)+(!e?\"\":` style=\"${e}\"`)+(i==\"\"?\"\":` ${i}`)}_clone(t=false){const e=[];if(t){for(const i of this.getChildren()){e.push(i._clone(t))}}const i=new this.constructor(this.document,this.name,this._attrs,e);i._classes=new Set(this._classes);i._styles.set(this._styles.getNormalized());i._customProperties=new Map(this._customProperties);i.getFillerOffset=this.getFillerOffset;return i}_appendChild(t){return this._insertChild(this.childCount,t)}_insertChild(t,e){this._fireChange(\"children\",this);let i=0;const n=jl(this.document,e);for(const e of n){if(e.parent!==null){e._remove()}e.parent=this;e.document=this.document;this._children.splice(t,0,e);t++;i++}return i}_removeChildren(t,e=1){this._fireChange(\"children\",this);for(let i=t;i<t+e;i++){this._children[i].parent=null}return this._children.splice(t,e)}_setAttribute(t,e){e=String(e);this._fireChange(\"attributes\",this);if(t==\"class\"){Fl(this._classes,e)}else if(t==\"style\"){this._styles.setTo(e)}else{this._attrs.set(t,e)}}_removeAttribute(t){this._fireChange(\"attributes\",this);if(t==\"class\"){if(this._classes.size>0){this._classes.clear();return true}return false}if(t==\"style\"){if(!this._styles.isEmpty){this._styles.clear();return true}return false}return this._attrs.delete(t)}_addClass(t){this._fireChange(\"attributes\",this);t=Array.isArray(t)?t:[t];t.forEach(t=>this._classes.add(t))}_removeClass(t){this._fireChange(\"attributes\",this);t=Array.isArray(t)?t:[t];t.forEach(t=>this._classes.delete(t))}_setStyle(t,e){this._fireChange(\"attributes\",this);this._styles.set(t,e)}_removeStyle(t){this._fireChange(\"attributes\",this);t=Array.isArray(t)?t:[t];t.forEach(t=>this._styles.remove(t))}_setCustomProperty(t,e){this._customProperties.set(t,e)}_removeCustomProperty(t){return this._customProperties.delete(t)}}function zl(t){t=Ws(t);for(const[e,i]of t){if(i===null){t.delete(e)}else if(typeof i!=\"string\"){t.set(e,String(i))}}return t}function Fl(t,e){const i=e.split(/\\s+/);t.clear();i.forEach(e=>t.add(e))}function jl(t,e){if(typeof e==\"string\"){return[new Fs(t,e)]}if(!vs(e)){e=[e]}return Array.from(e).map(e=>{if(typeof e==\"string\"){return new Fs(t,e)}if(e instanceof js){return new Fs(t,e.data)}return e})}class Hl extends Dl{constructor(t,e,i,n){super(t,e,i,n);this.getFillerOffset=Wl}is(t,e=null){if(!e){return t===\"containerElement\"||t===\"view:containerElement\"||t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"containerElement\"||t===\"view:containerElement\"||t===\"element\"||t===\"view:element\")}}}function Wl(){const t=[...this.getChildren()];const e=t[this.childCount-1];if(e&&e.is(\"element\",\"br\")){return this.childCount}for(const e of t){if(!e.is(\"uiElement\")){return null}}return this.childCount}var ql=Tl((function(t,e){Ve(e,dn(e),t)}));var $l=ql;const Ul=Symbol(\"observableProperties\");const Gl=Symbol(\"boundObservables\");const Jl=Symbol(\"boundProperties\");const Kl={set(t,e){if(lt(t)){Object.keys(t).forEach(e=>{this.set(e,t[e])},this);return}Yl(this);const i=this[Ul];if(t in this&&!i.has(t)){throw new ss[\"b\"](\"observable-set-cannot-override: Cannot override an existing property.\",this)}Object.defineProperty(this,t,{enumerable:true,configurable:true,get(){return i.get(t)},set(e){const n=i.get(t);let o=this.fire(\"set:\"+t,t,e,n);if(o===undefined){o=e}if(n!==o||!i.has(t)){i.set(t,o);this.fire(\"change:\"+t,t,o,n)}}});this[t]=e},bind(...t){if(!t.length||!ec(t)){throw new ss[\"b\"](\"observable-bind-wrong-properties: All properties must be strings.\",this)}if(new Set(t).size!==t.length){throw new ss[\"b\"](\"observable-bind-duplicate-properties: Properties must be unique.\",this)}Yl(this);const e=this[Jl];t.forEach(t=>{if(e.has(t)){throw new ss[\"b\"](\"observable-bind-rebind: Cannot bind the same property more than once.\",this)}});const i=new Map;t.forEach(t=>{const n={property:t,to:[]};e.set(t,n);i.set(t,n)});return{to:Ql,toMany:Zl,_observable:this,_bindProperties:t,_to:[],_bindings:i}},unbind(...t){if(!this[Ul]){return}const e=this[Jl];const i=this[Gl];if(t.length){if(!ec(t)){throw new ss[\"b\"](\"observable-unbind-wrong-properties: Properties must be strings.\",this)}t.forEach(t=>{const n=e.get(t);if(!n){return}let o,r,s,a;n.to.forEach(t=>{o=t[0];r=t[1];s=i.get(o);a=s[r];a.delete(n);if(!a.size){delete s[r]}if(!Object.keys(s).length){i.delete(o);this.stopListening(o,\"change\")}});e.delete(t)})}else{i.forEach((t,e)=>{this.stopListening(e,\"change\")});i.clear();e.clear()}},decorate(t){const e=this[t];if(!e){throw new ss[\"b\"](\"observablemixin-cannot-decorate-undefined: Cannot decorate an undefined method.\",this,{object:this,methodName:t})}this.on(t,(t,i)=>{t.return=e.apply(this,i)});this[t]=function(...e){return this.fire(t,e)}}};$l(Kl,ds);var Xl=Kl;function Yl(t){if(t[Ul]){return}Object.defineProperty(t,Ul,{value:new Map});Object.defineProperty(t,Gl,{value:new Map});Object.defineProperty(t,Jl,{value:new Map})}function Ql(...t){const e=ic(...t);const i=Array.from(this._bindings.keys());const n=i.length;if(!e.callback&&e.to.length>1){throw new ss[\"b\"](\"observable-bind-to-no-callback: Binding multiple observables only possible with callback.\",this)}if(n>1&&e.callback){throw new ss[\"b\"](\"observable-bind-to-extra-callback: Cannot bind multiple properties and use a callback in one binding.\",this)}e.to.forEach(t=>{if(t.properties.length&&t.properties.length!==n){throw new ss[\"b\"](\"observable-bind-to-properties-length: The number of properties must match.\",this)}if(!t.properties.length){t.properties=this._bindProperties}});this._to=e.to;if(e.callback){this._bindings.get(i[0]).callback=e.callback}sc(this._observable,this._to);oc(this);this._bindProperties.forEach(t=>{rc(this._observable,t)})}function Zl(t,e,i){if(this._bindings.size>1){throw new ss[\"b\"](\"observable-bind-to-many-not-one-binding: Cannot bind multiple properties with toMany().\",this)}this.to(...tc(t,e),i)}function tc(t,e){const i=t.map(t=>[t,e]);return Array.prototype.concat.apply([],i)}function ec(t){return t.every(t=>typeof t==\"string\")}function ic(...t){if(!t.length){throw new ss[\"b\"](\"observable-bind-to-parse-error: Invalid argument syntax in `to()`.\",null)}const e={to:[]};let i;if(typeof t[t.length-1]==\"function\"){e.callback=t.pop()}t.forEach(t=>{if(typeof t==\"string\"){i.properties.push(t)}else if(typeof t==\"object\"){i={observable:t,properties:[]};e.to.push(i)}else{throw new ss[\"b\"](\"observable-bind-to-parse-error: Invalid argument syntax in `to()`.\",null)}});return e}function nc(t,e,i,n){const o=t[Gl];const r=o.get(i);const s=r||{};if(!s[n]){s[n]=new Set}s[n].add(e);if(!r){o.set(i,s)}}function oc(t){let e;t._bindings.forEach((i,n)=>{t._to.forEach(o=>{e=o.properties[i.callback?0:t._bindProperties.indexOf(n)];i.to.push([o.observable,e]);nc(t._observable,i,o.observable,e)})})}function rc(t,e){const i=t[Jl];const n=i.get(e);let o;if(n.callback){o=n.callback.apply(t,n.to.map(t=>t[0][t[1]]))}else{o=n.to[0];o=o[0][o[1]]}if(t.hasOwnProperty(e)){t[e]=o}else{t.set(e,o)}}function sc(t,e){e.forEach(e=>{const i=t[Gl];let n;if(!i.get(e.observable)){t.listenTo(e.observable,\"change\",(o,r)=>{n=i.get(e.observable)[r];if(n){n.forEach(e=>{rc(t,e.property)})}})}})}class ac extends Hl{constructor(t,e,i,n){super(t,e,i,n);this.set(\"isReadOnly\",false);this.set(\"isFocused\",false);this.bind(\"isReadOnly\").to(t);this.bind(\"isFocused\").to(t,\"isFocused\",e=>e&&t.selection.editableElement==this);this.listenTo(t.selection,\"change\",()=>{this.isFocused=t.isFocused&&t.selection.editableElement==this})}is(t,e=null){if(!e){return t===\"editableElement\"||t===\"view:editableElement\"||t===\"containerElement\"||t===\"view:containerElement\"||t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"editableElement\"||t===\"view:editableElement\"||t===\"containerElement\"||t===\"view:containerElement\"||t===\"element\"||t===\"view:element\")}}destroy(){this.stopListening()}}ys(ac,Xl);const lc=Symbol(\"rootName\");class cc extends ac{constructor(t,e){super(t,e);this.rootName=\"main\"}is(t,e=null){if(!e){return t===\"rootElement\"||t===\"view:rootElement\"||t===\"editableElement\"||t===\"view:editableElement\"||t===\"containerElement\"||t===\"view:containerElement\"||t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"rootElement\"||t===\"view:rootElement\"||t===\"editableElement\"||t===\"view:editableElement\"||t===\"containerElement\"||t===\"view:containerElement\"||t===\"element\"||t===\"view:element\")}}get rootName(){return this.getCustomProperty(lc)}set rootName(t){this._setCustomProperty(lc,t)}set _name(t){this.name=t}}class dc{constructor(t={}){if(!t.boundaries&&!t.startPosition){throw new ss[\"b\"](\"view-tree-walker-no-start-position: Neither boundaries nor starting position have been defined.\",null)}if(t.direction&&t.direction!=\"forward\"&&t.direction!=\"backward\"){throw new ss[\"b\"](\"view-tree-walker-unknown-direction: Only `backward` and `forward` direction allowed.\",t.startPosition,{direction:t.direction})}this.boundaries=t.boundaries||null;if(t.startPosition){this.position=uc._createAt(t.startPosition)}else{this.position=uc._createAt(t.boundaries[t.direction==\"backward\"?\"end\":\"start\"])}this.direction=t.direction||\"forward\";this.singleCharacters=!!t.singleCharacters;this.shallow=!!t.shallow;this.ignoreElementEnd=!!t.ignoreElementEnd;this._boundaryStartParent=this.boundaries?this.boundaries.start.parent:null;this._boundaryEndParent=this.boundaries?this.boundaries.end.parent:null}[Symbol.iterator](){return this}skip(t){let e,i,n;do{n=this.position;({done:e,value:i}=this.next())}while(!e&&t(i));if(!e){this.position=n}}next(){if(this.direction==\"forward\"){return this._next()}else{return this._previous()}}_next(){let t=this.position.clone();const e=this.position;const i=t.parent;if(i.parent===null&&t.offset===i.childCount){return{done:true}}if(i===this._boundaryEndParent&&t.offset==this.boundaries.end.offset){return{done:true}}let n;if(i instanceof Fs){if(t.isAtEnd){this.position=uc._createAfter(i);return this._next()}n=i.data[t.offset]}else{n=i.getChild(t.offset)}if(n instanceof Dl){if(!this.shallow){t=new uc(n,0)}else{t.offset++}this.position=t;return this._formatReturnValue(\"elementStart\",n,e,t,1)}else if(n instanceof Fs){if(this.singleCharacters){t=new uc(n,0);this.position=t;return this._next()}else{let i=n.data.length;let o;if(n==this._boundaryEndParent){i=this.boundaries.end.offset;o=new js(n,0,i);t=uc._createAfter(o)}else{o=new js(n,0,n.data.length);t.offset++}this.position=t;return this._formatReturnValue(\"text\",o,e,t,i)}}else if(typeof n==\"string\"){let n;if(this.singleCharacters){n=1}else{const e=i===this._boundaryEndParent?this.boundaries.end.offset:i.data.length;n=e-t.offset}const o=new js(i,t.offset,n);t.offset+=n;this.position=t;return this._formatReturnValue(\"text\",o,e,t,n)}else{t=uc._createAfter(i);this.position=t;if(this.ignoreElementEnd){return this._next()}else{return this._formatReturnValue(\"elementEnd\",i,e,t)}}}_previous(){let t=this.position.clone();const e=this.position;const i=t.parent;if(i.parent===null&&t.offset===0){return{done:true}}if(i==this._boundaryStartParent&&t.offset==this.boundaries.start.offset){return{done:true}}let n;if(i instanceof Fs){if(t.isAtStart){this.position=uc._createBefore(i);return this._previous()}n=i.data[t.offset-1]}else{n=i.getChild(t.offset-1)}if(n instanceof Dl){if(!this.shallow){t=new uc(n,n.childCount);this.position=t;if(this.ignoreElementEnd){return this._previous()}else{return this._formatReturnValue(\"elementEnd\",n,e,t)}}else{t.offset--;this.position=t;return this._formatReturnValue(\"elementStart\",n,e,t,1)}}else if(n instanceof Fs){if(this.singleCharacters){t=new uc(n,n.data.length);this.position=t;return this._previous()}else{let i=n.data.length;let o;if(n==this._boundaryStartParent){const e=this.boundaries.start.offset;o=new js(n,e,n.data.length-e);i=o.data.length;t=uc._createBefore(o)}else{o=new js(n,0,n.data.length);t.offset--}this.position=t;return this._formatReturnValue(\"text\",o,e,t,i)}}else if(typeof n==\"string\"){let n;if(!this.singleCharacters){const e=i===this._boundaryStartParent?this.boundaries.start.offset:0;n=t.offset-e}else{n=1}t.offset-=n;const o=new js(i,t.offset,n);this.position=t;return this._formatReturnValue(\"text\",o,e,t,n)}else{t=uc._createBefore(i);this.position=t;return this._formatReturnValue(\"elementStart\",i,e,t,1)}}_formatReturnValue(t,e,i,n,o){if(e instanceof js){if(e.offsetInText+e.data.length==e.textNode.data.length){if(this.direction==\"forward\"&&!(this.boundaries&&this.boundaries.end.isEqual(this.position))){n=uc._createAfter(e.textNode);this.position=n}else{i=uc._createAfter(e.textNode)}}if(e.offsetInText===0){if(this.direction==\"backward\"&&!(this.boundaries&&this.boundaries.start.isEqual(this.position))){n=uc._createBefore(e.textNode);this.position=n}else{i=uc._createBefore(e.textNode)}}}return{done:false,value:{type:t,item:e,previousPosition:i,nextPosition:n,length:o}}}}class uc{constructor(t,e){this.parent=t;this.offset=e}get nodeAfter(){if(this.parent.is(\"text\")){return null}return this.parent.getChild(this.offset)||null}get nodeBefore(){if(this.parent.is(\"text\")){return null}return this.parent.getChild(this.offset-1)||null}get isAtStart(){return this.offset===0}get isAtEnd(){const t=this.parent.is(\"text\")?this.parent.data.length:this.parent.childCount;return this.offset===t}get root(){return this.parent.root}get editableElement(){let t=this.parent;while(!(t instanceof ac)){if(t.parent){t=t.parent}else{return null}}return t}getShiftedBy(t){const e=uc._createAt(this);const i=e.offset+t;e.offset=i<0?0:i;return e}getLastMatchingPosition(t,e={}){e.startPosition=this;const i=new dc(e);i.skip(t);return i.position}getAncestors(){if(this.parent.is(\"documentFragment\")){return[this.parent]}else{return this.parent.getAncestors({includeSelf:true})}}getCommonAncestor(t){const e=this.getAncestors();const i=t.getAncestors();let n=0;while(e[n]==i[n]&&e[n]){n++}return n===0?null:e[n-1]}is(t){return t===\"position\"||t===\"view:position\"}isEqual(t){return this.parent==t.parent&&this.offset==t.offset}isBefore(t){return this.compareWith(t)==\"before\"}isAfter(t){return this.compareWith(t)==\"after\"}compareWith(t){if(this.root!==t.root){return\"different\"}if(this.isEqual(t)){return\"same\"}const e=this.parent.is(\"node\")?this.parent.getPath():[];const i=t.parent.is(\"node\")?t.parent.getPath():[];e.push(this.offset);i.push(t.offset);const n=Ns(e,i);switch(n){case\"prefix\":return\"before\";case\"extension\":return\"after\";default:return e[n]<i[n]?\"before\":\"after\"}}getWalker(t={}){t.startPosition=this;return new dc(t)}clone(){return new uc(this.parent,this.offset)}static _createAt(t,e){if(t instanceof uc){return new this(t.parent,t.offset)}else{const i=t;if(e==\"end\"){e=i.is(\"text\")?i.data.length:i.childCount}else if(e==\"before\"){return this._createBefore(i)}else if(e==\"after\"){return this._createAfter(i)}else if(e!==0&&!e){throw new ss[\"b\"](\"view-createPositionAt-offset-required: \"+\"View#createPositionAt() requires the offset when the first parameter is a view item.\",i)}return new uc(i,e)}}static _createAfter(t){if(t.is(\"textProxy\")){return new uc(t.textNode,t.offsetInText+t.data.length)}if(!t.parent){throw new ss[\"b\"](\"view-position-after-root: You can not make position after root.\",t,{root:t})}return new uc(t.parent,t.index+1)}static _createBefore(t){if(t.is(\"textProxy\")){return new uc(t.textNode,t.offsetInText)}if(!t.parent){throw new ss[\"b\"](\"view-position-before-root: You can not make position before root.\",t,{root:t})}return new uc(t.parent,t.index)}}class hc{constructor(t,e=null){this.start=t.clone();this.end=e?e.clone():t.clone()}*[Symbol.iterator](){yield*new dc({boundaries:this,ignoreElementEnd:true})}get isCollapsed(){return this.start.isEqual(this.end)}get isFlat(){return this.start.parent===this.end.parent}get root(){return this.start.root}getEnlarged(){let t=this.start.getLastMatchingPosition(fc,{direction:\"backward\"});let e=this.end.getLastMatchingPosition(fc);if(t.parent.is(\"text\")&&t.isAtStart){t=uc._createBefore(t.parent)}if(e.parent.is(\"text\")&&e.isAtEnd){e=uc._createAfter(e.parent)}return new hc(t,e)}getTrimmed(){let t=this.start.getLastMatchingPosition(fc);if(t.isAfter(this.end)||t.isEqual(this.end)){return new hc(t,t)}let e=this.end.getLastMatchingPosition(fc,{direction:\"backward\"});const i=t.nodeAfter;const n=e.nodeBefore;if(i&&i.is(\"text\")){t=new uc(i,0)}if(n&&n.is(\"text\")){e=new uc(n,n.data.length)}return new hc(t,e)}isEqual(t){return this==t||this.start.isEqual(t.start)&&this.end.isEqual(t.end)}containsPosition(t){return t.isAfter(this.start)&&t.isBefore(this.end)}containsRange(t,e=false){if(t.isCollapsed){e=false}const i=this.containsPosition(t.start)||e&&this.start.isEqual(t.start);const n=this.containsPosition(t.end)||e&&this.end.isEqual(t.end);return i&&n}getDifference(t){const e=[];if(this.isIntersecting(t)){if(this.containsPosition(t.start)){e.push(new hc(this.start,t.start))}if(this.containsPosition(t.end)){e.push(new hc(t.end,this.end))}}else{e.push(this.clone())}return e}getIntersection(t){if(this.isIntersecting(t)){let e=this.start;let i=this.end;if(this.containsPosition(t.start)){e=t.start}if(this.containsPosition(t.end)){i=t.end}return new hc(e,i)}return null}getWalker(t={}){t.boundaries=this;return new dc(t)}getCommonAncestor(){return this.start.getCommonAncestor(this.end)}getContainedElement(){if(this.isCollapsed){return null}let t=this.start.nodeAfter;let e=this.end.nodeBefore;if(this.start.parent.is(\"text\")&&this.start.isAtEnd&&this.start.parent.nextSibling){t=this.start.parent.nextSibling}if(this.end.parent.is(\"text\")&&this.end.isAtStart&&this.end.parent.previousSibling){e=this.end.parent.previousSibling}if(t&&t.is(\"element\")&&t===e){return t}return null}clone(){return new hc(this.start,this.end)}*getItems(t={}){t.boundaries=this;t.ignoreElementEnd=true;const e=new dc(t);for(const t of e){yield t.item}}*getPositions(t={}){t.boundaries=this;const e=new dc(t);yield e.position;for(const t of e){yield t.nextPosition}}is(t){return t===\"range\"||t===\"view:range\"}isIntersecting(t){return this.start.isBefore(t.end)&&this.end.isAfter(t.start)}static _createFromParentsAndOffsets(t,e,i,n){return new this(new uc(t,e),new uc(i,n))}static _createFromPositionAndShift(t,e){const i=t;const n=t.getShiftedBy(e);return e>0?new this(i,n):new this(n,i)}static _createIn(t){return this._createFromParentsAndOffsets(t,0,t,t.childCount)}static _createOn(t){const e=t.is(\"textProxy\")?t.offsetSize:1;return this._createFromPositionAndShift(uc._createBefore(t),e)}}function fc(t){if(t.item.is(\"attributeElement\")||t.item.is(\"uiElement\")){return true}return false}function mc(t){let e=0;for(const i of t){e++}return e}class gc{constructor(t=null,e,i){this._ranges=[];this._lastRangeBackward=false;this._isFake=false;this._fakeSelectionLabel=\"\";this.setTo(t,e,i)}get isFake(){return this._isFake}get fakeSelectionLabel(){return this._fakeSelectionLabel}get anchor(){if(!this._ranges.length){return null}const t=this._ranges[this._ranges.length-1];const e=this._lastRangeBackward?t.end:t.start;return e.clone()}get focus(){if(!this._ranges.length){return null}const t=this._ranges[this._ranges.length-1];const e=this._lastRangeBackward?t.start:t.end;return e.clone()}get isCollapsed(){return this.rangeCount===1&&this._ranges[0].isCollapsed}get rangeCount(){return this._ranges.length}get isBackward(){return!this.isCollapsed&&this._lastRangeBackward}get editableElement(){if(this.anchor){return this.anchor.editableElement}return null}*getRanges(){for(const t of this._ranges){yield t.clone()}}getFirstRange(){let t=null;for(const e of this._ranges){if(!t||e.start.isBefore(t.start)){t=e}}return t?t.clone():null}getLastRange(){let t=null;for(const e of this._ranges){if(!t||e.end.isAfter(t.end)){t=e}}return t?t.clone():null}getFirstPosition(){const t=this.getFirstRange();return t?t.start.clone():null}getLastPosition(){const t=this.getLastRange();return t?t.end.clone():null}isEqual(t){if(this.isFake!=t.isFake){return false}if(this.isFake&&this.fakeSelectionLabel!=t.fakeSelectionLabel){return false}if(this.rangeCount!=t.rangeCount){return false}else if(this.rangeCount===0){return true}if(!this.anchor.isEqual(t.anchor)||!this.focus.isEqual(t.focus)){return false}for(const e of this._ranges){let i=false;for(const n of t._ranges){if(e.isEqual(n)){i=true;break}}if(!i){return false}}return true}isSimilar(t){if(this.isBackward!=t.isBackward){return false}const e=mc(this.getRanges());const i=mc(t.getRanges());if(e!=i){return false}if(e==0){return true}for(let e of this.getRanges()){e=e.getTrimmed();let i=false;for(let n of t.getRanges()){n=n.getTrimmed();if(e.start.isEqual(n.start)&&e.end.isEqual(n.end)){i=true;break}}if(!i){return false}}return true}getSelectedElement(){if(this.rangeCount!==1){return null}return this.getFirstRange().getContainedElement()}setTo(t,e,i){if(t===null){this._setRanges([]);this._setFakeOptions(e)}else if(t instanceof gc||t instanceof pc){this._setRanges(t.getRanges(),t.isBackward);this._setFakeOptions({fake:t.isFake,label:t.fakeSelectionLabel})}else if(t instanceof hc){this._setRanges([t],e&&e.backward);this._setFakeOptions(e)}else if(t instanceof uc){this._setRanges([new hc(t)]);this._setFakeOptions(e)}else if(t instanceof zs){const n=!!i&&!!i.backward;let o;if(e===undefined){throw new ss[\"b\"](\"view-selection-setTo-required-second-parameter: \"+\"selection.setTo requires the second parameter when the first parameter is a node.\",this)}else if(e==\"in\"){o=hc._createIn(t)}else if(e==\"on\"){o=hc._createOn(t)}else{o=new hc(uc._createAt(t,e))}this._setRanges([o],n);this._setFakeOptions(i)}else if(vs(t)){this._setRanges(t,e&&e.backward);this._setFakeOptions(e)}else{throw new ss[\"b\"](\"view-selection-setTo-not-selectable: Cannot set selection to given place.\",this)}this.fire(\"change\")}setFocus(t,e){if(this.anchor===null){throw new ss[\"b\"](\"view-selection-setFocus-no-ranges: Cannot set selection focus if there are no ranges in selection.\",this)}const i=uc._createAt(t,e);if(i.compareWith(this.focus)==\"same\"){return}const n=this.anchor;this._ranges.pop();if(i.compareWith(n)==\"before\"){this._addRange(new hc(i,n),true)}else{this._addRange(new hc(n,i))}this.fire(\"change\")}is(t){return t===\"selection\"||t===\"view:selection\"}_setRanges(t,e=false){t=Array.from(t);this._ranges=[];for(const e of t){this._addRange(e)}this._lastRangeBackward=!!e}_setFakeOptions(t={}){this._isFake=!!t.fake;this._fakeSelectionLabel=t.fake?t.label||\"\":\"\"}_addRange(t,e=false){if(!(t instanceof hc)){throw new ss[\"b\"](\"view-selection-add-range-not-range: \"+\"Selection range set to an object that is not an instance of view.Range\",this)}this._pushRange(t);this._lastRangeBackward=!!e}_pushRange(t){for(const e of this._ranges){if(t.isIntersecting(e)){throw new ss[\"b\"](\"view-selection-range-intersects: Trying to add a range that intersects with another range from selection.\",this,{addedRange:t,intersectingRange:e})}}this._ranges.push(new hc(t.start,t.end))}}ys(gc,ds);class pc{constructor(t=null,e,i){this._selection=new gc;this._selection.delegate(\"change\").to(this);this._selection.setTo(t,e,i)}get isFake(){return this._selection.isFake}get fakeSelectionLabel(){return this._selection.fakeSelectionLabel}get anchor(){return this._selection.anchor}get focus(){return this._selection.focus}get isCollapsed(){return this._selection.isCollapsed}get rangeCount(){return this._selection.rangeCount}get isBackward(){return this._selection.isBackward}get editableElement(){return this._selection.editableElement}get _ranges(){return this._selection._ranges}*getRanges(){yield*this._selection.getRanges()}getFirstRange(){return this._selection.getFirstRange()}getLastRange(){return this._selection.getLastRange()}getFirstPosition(){return this._selection.getFirstPosition()}getLastPosition(){return this._selection.getLastPosition()}getSelectedElement(){return this._selection.getSelectedElement()}isEqual(t){return this._selection.isEqual(t)}isSimilar(t){return this._selection.isSimilar(t)}is(t){return t===\"selection\"||t==\"documentSelection\"||t==\"view:selection\"||t==\"view:documentSelection\"}_setTo(t,e,i){this._selection.setTo(t,e,i)}_setFocus(t,e){this._selection.setFocus(t,e)}}ys(pc,ds);class bc{constructor(t){this.selection=new pc;this.roots=new xs({idProperty:\"rootName\"});this.stylesProcessor=t;this.set(\"isReadOnly\",false);this.set(\"isFocused\",false);this.set(\"isComposing\",false);this._postFixers=new Set}getRoot(t=\"main\"){return this.roots.get(t)}registerPostFixer(t){this._postFixers.add(t)}destroy(){this.roots.map(t=>t.destroy());this.stopListening()}_callPostFixers(t){let e=false;do{for(const i of this._postFixers){e=i(t);if(e){break}}}while(e)}}ys(bc,Xl);const wc=10;class _c extends Dl{constructor(t,e,i,n){super(t,e,i,n);this.getFillerOffset=kc;this._priority=wc;this._id=null;this._clonesGroup=null}get priority(){return this._priority}get id(){return this._id}getElementsWithSameId(){if(this.id===null){throw new ss[\"b\"](\"attribute-element-get-elements-with-same-id-no-id: \"+\"Cannot get elements with the same id for an attribute element without id.\",this)}return new Set(this._clonesGroup)}is(t,e=null){if(!e){return t===\"attributeElement\"||t===\"view:attributeElement\"||t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"attributeElement\"||t===\"view:attributeElement\"||t===\"element\"||t===\"view:element\")}}isSimilar(t){if(this.id!==null||t.id!==null){return this.id===t.id}return super.isSimilar(t)&&this.priority==t.priority}_clone(t){const e=super._clone(t);e._priority=this._priority;e._id=this._id;return e}}_c.DEFAULT_PRIORITY=wc;function kc(){if(vc(this)){return null}let t=this.parent;while(t&&t.is(\"attributeElement\")){if(vc(t)>1){return null}t=t.parent}if(!t||vc(t)>1){return null}return this.childCount}function vc(t){return Array.from(t.getChildren()).filter(t=>!t.is(\"uiElement\")).length}class yc extends Dl{constructor(t,e,i,n){super(t,e,i,n);this.getFillerOffset=xc}is(t,e=null){if(!e){return t===\"emptyElement\"||t===\"view:emptyElement\"||t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"emptyElement\"||t===\"view:emptyElement\"||t===\"element\"||t===\"view:element\")}}_insertChild(t,e){if(e&&(e instanceof zs||Array.from(e).length>0)){throw new ss[\"b\"](\"view-emptyelement-cannot-add: Cannot add child nodes to EmptyElement instance.\",[this,e])}}}function xc(){return null}const Cc=navigator.userAgent.toLowerCase();const Ac={isMac:Pc(Cc),isGecko:Ec(Cc),isSafari:Sc(Cc),isAndroid:Mc(Cc),features:{isRegExpUnicodePropertySupported:Oc()}};var Tc=Ac;function Pc(t){return t.indexOf(\"macintosh\")>-1}function Ec(t){return!!t.match(/gecko\\/\\d+/)}function Sc(t){return t.indexOf(\" applewebkit/\")>-1&&t.indexOf(\"chrome\")===-1}function Mc(t){return t.indexOf(\"android\")>-1}function Oc(){let t=false;try{t=\"ć\".search(new RegExp(\"[\\\\p{L}]\",\"u\"))===0}catch(t){}return t}const Ic={\"⌘\":\"ctrl\",\"⇧\":\"shift\",\"⌥\":\"alt\"};const Rc={ctrl:\"⌘\",shift:\"⇧\",alt:\"⌥\"};const Lc=Dc();function Nc(t){let e;if(typeof t==\"string\"){e=Lc[t.toLowerCase()];if(!e){throw new ss[\"b\"](\"keyboard-unknown-key: Unknown key name.\",null,{key:t})}}else{e=t.keyCode+(t.altKey?Lc.alt:0)+(t.ctrlKey?Lc.ctrl:0)+(t.shiftKey?Lc.shift:0)}return e}function Bc(t){if(typeof t==\"string\"){t=zc(t)}return t.map(t=>typeof t==\"string\"?Nc(t):t).reduce((t,e)=>e+t,0)}function Vc(t){if(!Tc.isMac){return t}return zc(t).map(t=>Rc[t.toLowerCase()]||t).reduce((t,e)=>{if(t.slice(-1)in Ic){return t+e}else{return t+\"+\"+e}})}function Dc(){const t={arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,backspace:8,delete:46,enter:13,space:32,esc:27,tab:9,ctrl:1114112,cmd:1114112,shift:2228224,alt:4456448};for(let e=65;e<=90;e++){const i=String.fromCharCode(e);t[i.toLowerCase()]=e}for(let e=48;e<=57;e++){t[e-48]=e}for(let e=112;e<=123;e++){t[\"f\"+(e-111)]=e}return t}function zc(t){return t.split(/\\s*\\+\\s*/)}class Fc extends Dl{constructor(t,e,i,n){super(t,e,i,n);this.getFillerOffset=Hc}is(t,e=null){if(!e){return t===\"uiElement\"||t===\"view:uiElement\"||t===this.name||t===\"view:\"+this.name||t===\"element\"||t===\"view:element\"||t===\"node\"||t===\"view:node\"}else{return e===this.name&&(t===\"uiElement\"||t===\"view:uiElement\"||t===\"element\"||t===\"view:element\")}}_insertChild(t,e){if(e&&(e instanceof zs||Array.from(e).length>0)){throw new ss[\"b\"](\"view-uielement-cannot-add: Cannot add child nodes to UIElement instance.\",this)}}render(t){return this.toDomElement(t)}toDomElement(t){const e=t.createElement(this.name);for(const t of this.getAttributeKeys()){e.setAttribute(t,this.getAttribute(t))}return e}}function jc(t){t.document.on(\"keydown\",(e,i)=>Wc(e,i,t.domConverter))}function Hc(){return null}function Wc(t,e,i){if(e.keyCode==Lc.arrowright){const t=e.domTarget.ownerDocument.defaultView.getSelection();const n=t.rangeCount==1&&t.getRangeAt(0).collapsed;if(n||e.shiftKey){const e=t.focusNode;const o=t.focusOffset;const r=i.domPositionToView(e,o);if(r===null){return}let s=false;const a=r.getLastMatchingPosition(t=>{if(t.item.is(\"uiElement\")){s=true}if(t.item.is(\"uiElement\")||t.item.is(\"attributeElement\")){return true}return false});if(s){const e=i.viewPositionToDom(a);if(n){t.collapse(e.parent,e.offset)}else{t.extend(e.parent,e.offset)}}}}}class qc{constructor(t,e){this.document=t;this._children=[];if(e){this._insertChild(0,e)}}[Symbol.iterator](){return this._children[Symbol.iterator]()}get childCount(){return this._children.length}get isEmpty(){return this.childCount===0}get root(){return this}get parent(){return null}is(t){return t===\"documentFragment\"||t===\"view:documentFragment\"}_appendChild(t){return this._insertChild(this.childCount,t)}getChild(t){return this._children[t]}getChildIndex(t){return this._children.indexOf(t)}getChildren(){return this._children[Symbol.iterator]()}_insertChild(t,e){this._fireChange(\"children\",this);let i=0;const n=$c(this.document,e);for(const e of n){if(e.parent!==null){e._remove()}e.parent=this;this._children.splice(t,0,e);t++;i++}return i}_removeChildren(t,e=1){this._fireChange(\"children\",this);for(let i=t;i<t+e;i++){this._children[i].parent=null}return this._children.splice(t,e)}_fireChange(t,e){this.fire(\"change:\"+t,e)}}ys(qc,ds);function $c(t,e){if(typeof e==\"string\"){return[new Fs(t,e)]}if(!vs(e)){e=[e]}return Array.from(e).map(e=>{if(typeof e==\"string\"){return new Fs(t,e)}if(e instanceof js){return new Fs(t,e.data)}return e})}class Uc{constructor(t){this.document=t;this._cloneGroups=new Map}setSelection(t,e,i){this.document.selection._setTo(t,e,i)}setSelectionFocus(t,e){this.document.selection._setFocus(t,e)}createText(t){return new Fs(this.document,t)}createAttributeElement(t,e,i={}){const n=new _c(this.document,t,e);if(i.priority){n._priority=i.priority}if(i.id){n._id=i.id}return n}createContainerElement(t,e){return new Hl(this.document,t,e)}createEditableElement(t,e){const i=new ac(this.document,t,e);i._document=this.document;return i}createEmptyElement(t,e){return new yc(this.document,t,e)}createUIElement(t,e,i){const n=new Fc(this.document,t,e);if(i){n.render=i}return n}setAttribute(t,e,i){i._setAttribute(t,e)}removeAttribute(t,e){e._removeAttribute(t)}addClass(t,e){e._addClass(t)}removeClass(t,e){e._removeClass(t)}setStyle(t,e,i){if(L(t)&&i===undefined){i=e}i._setStyle(t,e)}removeStyle(t,e){e._removeStyle(t)}setCustomProperty(t,e,i){i._setCustomProperty(t,e)}removeCustomProperty(t,e){return e._removeCustomProperty(t)}breakAttributes(t){if(t instanceof uc){return this._breakAttributes(t)}else{return this._breakAttributesRange(t)}}breakContainer(t){const e=t.parent;if(!e.is(\"containerElement\")){throw new ss[\"b\"](\"view-writer-break-non-container-element: Trying to break an element which is not a container element.\",this.document)}if(!e.parent){throw new ss[\"b\"](\"view-writer-break-root: Trying to break root element.\",this.document)}if(t.isAtStart){return uc._createBefore(e)}else if(!t.isAtEnd){const i=e._clone(false);this.insert(uc._createAfter(e),i);const n=new hc(t,uc._createAt(e,\"end\"));const o=new uc(i,0);this.move(n,o)}return uc._createAfter(e)}mergeAttributes(t){const e=t.offset;const i=t.parent;if(i.is(\"text\")){return t}if(i.is(\"attributeElement\")&&i.childCount===0){const t=i.parent;const e=i.index;i._remove();this._removeFromClonedElementsGroup(i);return this.mergeAttributes(new uc(t,e))}const n=i.getChild(e-1);const o=i.getChild(e);if(!n||!o){return t}if(n.is(\"text\")&&o.is(\"text\")){return Qc(n,o)}else if(n.is(\"attributeElement\")&&o.is(\"attributeElement\")&&n.isSimilar(o)){const t=n.childCount;n._appendChild(o.getChildren());o._remove();this._removeFromClonedElementsGroup(o);return this.mergeAttributes(new uc(n,t))}return t}mergeContainers(t){const e=t.nodeBefore;const i=t.nodeAfter;if(!e||!i||!e.is(\"containerElement\")||!i.is(\"containerElement\")){throw new ss[\"b\"](\"view-writer-merge-containers-invalid-position: \"+\"Element before and after given position cannot be merged.\",this.document)}const n=e.getChild(e.childCount-1);const o=n instanceof Fs?uc._createAt(n,\"end\"):uc._createAt(e,\"end\");this.move(hc._createIn(i),uc._createAt(e,\"end\"));this.remove(hc._createOn(i));return o}insert(t,e){e=vs(e)?[...e]:[e];Zc(e,this.document);const i=Jc(t);if(!i){throw new ss[\"b\"](\"view-writer-invalid-position-container\",this.document)}const n=this._breakAttributes(t,true);const o=i._insertChild(n.offset,e);for(const t of e){this._addToClonedElementsGroup(t)}const r=n.getShiftedBy(o);const s=this.mergeAttributes(n);if(o===0){return new hc(s,s)}else{if(!s.isEqual(n)){r.offset--}const t=this.mergeAttributes(r);return new hc(s,t)}}remove(t){const e=t instanceof hc?t:hc._createOn(t);id(e,this.document);if(e.isCollapsed){return new qc(this.document)}const{start:i,end:n}=this._breakAttributesRange(e,true);const o=i.parent;const r=n.offset-i.offset;const s=o._removeChildren(i.offset,r);for(const t of s){this._removeFromClonedElementsGroup(t)}const a=this.mergeAttributes(i);e.start=a;e.end=a.clone();return new qc(this.document,s)}clear(t,e){id(t,this.document);const i=t.getWalker({direction:\"backward\",ignoreElementEnd:true});for(const n of i){const i=n.item;let o;if(i.is(\"element\")&&e.isSimilar(i)){o=hc._createOn(i)}else if(!n.nextPosition.isAfter(t.start)&&i.is(\"textProxy\")){const t=i.getAncestors().find(t=>t.is(\"element\")&&e.isSimilar(t));if(t){o=hc._createIn(t)}}if(o){if(o.end.isAfter(t.end)){o.end=t.end}if(o.start.isBefore(t.start)){o.start=t.start}this.remove(o)}}}move(t,e){let i;if(e.isAfter(t.end)){e=this._breakAttributes(e,true);const n=e.parent;const o=n.childCount;t=this._breakAttributesRange(t,true);i=this.remove(t);e.offset+=n.childCount-o}else{i=this.remove(t)}return this.insert(e,i)}wrap(t,e){if(!(e instanceof _c)){throw new ss[\"b\"](\"view-writer-wrap-invalid-attribute\",this.document)}id(t,this.document);if(!t.isCollapsed){return this._wrapRange(t,e)}else{let i=t.start;if(i.parent.is(\"element\")&&!Gc(i.parent)){i=i.getLastMatchingPosition(t=>t.item.is(\"uiElement\"))}i=this._wrapPosition(i,e);const n=this.document.selection;if(n.isCollapsed&&n.getFirstPosition().isEqual(t.start)){this.setSelection(i)}return new hc(i)}}unwrap(t,e){if(!(e instanceof _c)){throw new ss[\"b\"](\"view-writer-unwrap-invalid-attribute\",this.document)}id(t,this.document);if(t.isCollapsed){return t}const{start:i,end:n}=this._breakAttributesRange(t,true);const o=i.parent;const r=this._unwrapChildren(o,i.offset,n.offset,e);const s=this.mergeAttributes(r.start);if(!s.isEqual(r.start)){r.end.offset--}const a=this.mergeAttributes(r.end);return new hc(s,a)}rename(t,e){const i=new Hl(this.document,t,e.getAttributes());this.insert(uc._createAfter(e),i);this.move(hc._createIn(e),uc._createAt(i,0));this.remove(hc._createOn(e));return i}clearClonedElementsGroup(t){this._cloneGroups.delete(t)}createPositionAt(t,e){return uc._createAt(t,e)}createPositionAfter(t){return uc._createAfter(t)}createPositionBefore(t){return uc._createBefore(t)}createRange(t,e){return new hc(t,e)}createRangeOn(t){return hc._createOn(t)}createRangeIn(t){return hc._createIn(t)}createSelection(t,e,i){return new gc(t,e,i)}_wrapChildren(t,e,i,n){let o=e;const r=[];while(o<i){const e=t.getChild(o);const i=e.is(\"text\");const s=e.is(\"attributeElement\");const a=e.is(\"emptyElement\");const l=e.is(\"uiElement\");if(s&&this._wrapAttributeElement(n,e)){r.push(new uc(t,o))}else if(i||a||l||s&&Kc(n,e)){const i=n._clone();e._remove();i._appendChild(e);t._insertChild(o,i);this._addToClonedElementsGroup(i);r.push(new uc(t,o))}else if(s){this._wrapChildren(e,0,e.childCount,n)}o++}let s=0;for(const t of r){t.offset-=s;if(t.offset==e){continue}const n=this.mergeAttributes(t);if(!n.isEqual(t)){s++;i--}}return hc._createFromParentsAndOffsets(t,e,t,i)}_unwrapChildren(t,e,i,n){let o=e;const r=[];while(o<i){const e=t.getChild(o);if(!e.is(\"attributeElement\")){o++;continue}if(e.isSimilar(n)){const n=e.getChildren();const s=e.childCount;e._remove();t._insertChild(o,n);this._removeFromClonedElementsGroup(e);r.push(new uc(t,o),new uc(t,o+s));o+=s;i+=s-1;continue}if(this._unwrapAttributeElement(n,e)){r.push(new uc(t,o),new uc(t,o+1));o++;continue}this._unwrapChildren(e,0,e.childCount,n);o++}let s=0;for(const t of r){t.offset-=s;if(t.offset==e||t.offset==i){continue}const n=this.mergeAttributes(t);if(!n.isEqual(t)){s++;i--}}return hc._createFromParentsAndOffsets(t,e,t,i)}_wrapRange(t,e){const{start:i,end:n}=this._breakAttributesRange(t,true);const o=i.parent;const r=this._wrapChildren(o,i.offset,n.offset,e);const s=this.mergeAttributes(r.start);if(!s.isEqual(r.start)){r.end.offset--}const a=this.mergeAttributes(r.end);return new hc(s,a)}_wrapPosition(t,e){if(e.isSimilar(t.parent)){return Xc(t.clone())}if(t.parent.is(\"text\")){t=Yc(t)}const i=this.createAttributeElement();i._priority=Number.POSITIVE_INFINITY;i.isSimilar=()=>false;t.parent._insertChild(t.offset,i);const n=new hc(t,t.getShiftedBy(1));this.wrap(n,e);const o=new uc(i.parent,i.index);i._remove();const r=o.nodeBefore;const s=o.nodeAfter;if(r instanceof Fs&&s instanceof Fs){return Qc(r,s)}return Xc(o)}_wrapAttributeElement(t,e){if(!nd(t,e)){return false}if(t.name!==e.name||t.priority!==e.priority){return false}for(const i of t.getAttributeKeys()){if(i===\"class\"||i===\"style\"){continue}if(e.hasAttribute(i)&&e.getAttribute(i)!==t.getAttribute(i)){return false}}for(const i of t.getStyleNames()){if(e.hasStyle(i)&&e.getStyle(i)!==t.getStyle(i)){return false}}for(const i of t.getAttributeKeys()){if(i===\"class\"||i===\"style\"){continue}if(!e.hasAttribute(i)){this.setAttribute(i,t.getAttribute(i),e)}}for(const i of t.getStyleNames()){if(!e.hasStyle(i)){this.setStyle(i,t.getStyle(i),e)}}for(const i of t.getClassNames()){if(!e.hasClass(i)){this.addClass(i,e)}}return true}_unwrapAttributeElement(t,e){if(!nd(t,e)){return false}if(t.name!==e.name||t.priority!==e.priority){return false}for(const i of t.getAttributeKeys()){if(i===\"class\"||i===\"style\"){continue}if(!e.hasAttribute(i)||e.getAttribute(i)!==t.getAttribute(i)){return false}}if(!e.hasClass(...t.getClassNames())){return false}for(const i of t.getStyleNames()){if(!e.hasStyle(i)||e.getStyle(i)!==t.getStyle(i)){return false}}for(const i of t.getAttributeKeys()){if(i===\"class\"||i===\"style\"){continue}this.removeAttribute(i,e)}this.removeClass(Array.from(t.getClassNames()),e);this.removeStyle(Array.from(t.getStyleNames()),e);return true}_breakAttributesRange(t,e=false){const i=t.start;const n=t.end;id(t,this.document);if(t.isCollapsed){const i=this._breakAttributes(t.start,e);return new hc(i,i)}const o=this._breakAttributes(n,e);const r=o.parent.childCount;const s=this._breakAttributes(i,e);o.offset+=o.parent.childCount-r;return new hc(s,o)}_breakAttributes(t,e=false){const i=t.offset;const n=t.parent;if(t.parent.is(\"emptyElement\")){throw new ss[\"b\"](\"view-writer-cannot-break-empty-element\",this.document)}if(t.parent.is(\"uiElement\")){throw new ss[\"b\"](\"view-writer-cannot-break-ui-element\",this.document)}if(!e&&n.is(\"text\")&&ed(n.parent)){return t.clone()}if(ed(n)){return t.clone()}if(n.is(\"text\")){return this._breakAttributes(Yc(t),e)}const o=n.childCount;if(i==o){const t=new uc(n.parent,n.index+1);return this._breakAttributes(t,e)}else{if(i===0){const t=new uc(n.parent,n.index);return this._breakAttributes(t,e)}else{const t=n.index+1;const o=n._clone();n.parent._insertChild(t,o);this._addToClonedElementsGroup(o);const r=n.childCount-i;const s=n._removeChildren(i,r);o._appendChild(s);const a=new uc(n.parent,t);return this._breakAttributes(a,e)}}}_addToClonedElementsGroup(t){if(!t.root.is(\"rootElement\")){return}if(t.is(\"element\")){for(const e of t.getChildren()){this._addToClonedElementsGroup(e)}}const e=t.id;if(!e){return}let i=this._cloneGroups.get(e);if(!i){i=new Set;this._cloneGroups.set(e,i)}i.add(t);t._clonesGroup=i}_removeFromClonedElementsGroup(t){if(t.is(\"element\")){for(const e of t.getChildren()){this._removeFromClonedElementsGroup(e)}}const e=t.id;if(!e){return}const i=this._cloneGroups.get(e);if(!i){return}i.delete(t)}}function Gc(t){return Array.from(t.getChildren()).some(t=>!t.is(\"uiElement\"))}function Jc(t){let e=t.parent;while(!ed(e)){if(!e){return undefined}e=e.parent}return e}function Kc(t,e){if(t.priority<e.priority){return true}else if(t.priority>e.priority){return false}return t.getIdentity()<e.getIdentity()}function Xc(t){const e=t.nodeBefore;if(e&&e.is(\"text\")){return new uc(e,e.data.length)}const i=t.nodeAfter;if(i&&i.is(\"text\")){return new uc(i,0)}return t}function Yc(t){if(t.offset==t.parent.data.length){return new uc(t.parent.parent,t.parent.index+1)}if(t.offset===0){return new uc(t.parent.parent,t.parent.index)}const e=t.parent.data.slice(t.offset);t.parent._data=t.parent.data.slice(0,t.offset);t.parent.parent._insertChild(t.parent.index+1,new Fs(t.root.document,e));return new uc(t.parent.parent,t.parent.index+1)}function Qc(t,e){const i=t.data.length;t._data+=e.data;e._remove();return new uc(t,i)}function Zc(t,e){for(const i of t){if(!td.some(t=>i instanceof t)){throw new ss[\"b\"](\"view-writer-insert-invalid-node\",e)}if(!i.is(\"text\")){Zc(i.getChildren(),e)}}}const td=[Fs,_c,Hl,yc,Fc];function ed(t){return t&&(t.is(\"containerElement\")||t.is(\"documentFragment\"))}function id(t,e){const i=Jc(t.start);const n=Jc(t.end);if(!i||!n||i!==n){throw new ss[\"b\"](\"view-writer-invalid-range-container\",e)}}function nd(t,e){return t.id===null&&e.id===null}function od(t){return Object.prototype.toString.call(t)==\"[object Text]\"}const rd=t=>t.createTextNode(\" \");const sd=t=>{const e=t.createElement(\"br\");e.dataset.ckeFiller=true;return e};const ad=7;const ld=(()=>{let t=\"\";for(let e=0;e<ad;e++){t+=\"​\"}return t})();function cd(t){return od(t)&&t.data.substr(0,ad)===ld}function dd(t){return t.data.length==ad&&cd(t)}function ud(t){if(cd(t)){return t.data.slice(ad)}else{return t.data}}function hd(t){t.document.on(\"keydown\",fd)}function fd(t,e){if(e.keyCode==Lc.arrowleft){const t=e.domTarget.ownerDocument.defaultView.getSelection();if(t.rangeCount==1&&t.getRangeAt(0).collapsed){const e=t.getRangeAt(0).startContainer;const i=t.getRangeAt(0).startOffset;if(cd(e)&&i<=ad){t.collapse(e,0)}}}}function md(t,e,i,n=false){i=i||function(t,e){return t===e};if(!Array.isArray(t)){t=Array.prototype.slice.call(t)}if(!Array.isArray(e)){e=Array.prototype.slice.call(e)}const o=gd(t,e,i);return n?_d(o,e.length):wd(e,o)}function gd(t,e,i){const n=pd(t,e,i);if(n===-1){return{firstIndex:-1,lastIndexOld:-1,lastIndexNew:-1}}const o=bd(t,n);const r=bd(e,n);const s=pd(o,r,i);const a=t.length-s;const l=e.length-s;return{firstIndex:n,lastIndexOld:a,lastIndexNew:l}}function pd(t,e,i){for(let n=0;n<Math.max(t.length,e.length);n++){if(t[n]===undefined||e[n]===undefined||!i(t[n],e[n])){return n}}return-1}function bd(t,e){return t.slice(e).reverse()}function wd(t,e){const i=[];const{firstIndex:n,lastIndexOld:o,lastIndexNew:r}=e;if(r-n>0){i.push({index:n,type:\"insert\",values:t.slice(n,r)})}if(o-n>0){i.push({index:n+(r-n),type:\"delete\",howMany:o-n})}return i}function _d(t,e){const{firstIndex:i,lastIndexOld:n,lastIndexNew:o}=t;if(i===-1){return Array(e).fill(\"equal\")}let r=[];if(i>0){r=r.concat(Array(i).fill(\"equal\"))}if(o-i>0){r=r.concat(Array(o-i).fill(\"insert\"))}if(n-i>0){r=r.concat(Array(n-i).fill(\"delete\"))}if(o<e){r=r.concat(Array(e-o).fill(\"equal\"))}return r}function kd(t,e,i){i=i||function(t,e){return t===e};const n=t.length;const o=e.length;if(n>200||o>200||n+o>300){return kd.fastDiff(t,e,i,true)}let r,s;if(o<n){const i=t;t=e;e=i;r=\"delete\";s=\"insert\"}else{r=\"insert\";s=\"delete\"}const a=t.length;const l=e.length;const c=l-a;const d={};const u={};function h(n){const o=(u[n-1]!==undefined?u[n-1]:-1)+1;const c=u[n+1]!==undefined?u[n+1]:-1;const h=o>c?-1:1;if(d[n+h]){d[n]=d[n+h].slice(0)}if(!d[n]){d[n]=[]}d[n].push(o>c?r:s);let f=Math.max(o,c);let m=f-n;while(m<a&&f<l&&i(t[m],e[f])){m++;f++;d[n].push(\"equal\")}return f}let f=0;let m;do{for(m=-f;m<c;m++){u[m]=h(m)}for(m=c+f;m>c;m--){u[m]=h(m)}u[c]=h(c);f++}while(u[c]!==l);return d[c].slice(1)}kd.fastDiff=md;function vd(t,e,i){t.insertBefore(i,t.childNodes[e]||null)}function yd(t){const e=t.parentNode;if(e){e.removeChild(t)}}function xd(t){if(t){if(t.defaultView){return t instanceof t.defaultView.Document}else if(t.ownerDocument&&t.ownerDocument.defaultView){return t instanceof t.ownerDocument.defaultView.Node}}return false}class Cd{constructor(t,e){this.domDocuments=new Set;this.domConverter=t;this.markedAttributes=new Set;this.markedChildren=new Set;this.markedTexts=new Set;this.selection=e;this.isFocused=false;this._inlineFiller=null;this._fakeSelectionContainer=null}markToSync(t,e){if(t===\"text\"){if(this.domConverter.mapViewToDom(e.parent)){this.markedTexts.add(e)}}else{if(!this.domConverter.mapViewToDom(e)){return}if(t===\"attributes\"){this.markedAttributes.add(e)}else if(t===\"children\"){this.markedChildren.add(e)}else{throw new ss[\"b\"](\"view-renderer-unknown-type: Unknown type passed to Renderer.markToSync.\",this)}}}render(){let t;for(const t of this.markedChildren){this._updateChildrenMappings(t)}if(this._inlineFiller&&!this._isSelectionInInlineFiller()){this._removeInlineFiller()}if(this._inlineFiller){t=this._getInlineFillerPosition()}else if(this._needsInlineFillerAtSelection()){t=this.selection.getFirstPosition();this.markedChildren.add(t.parent)}for(const t of this.markedAttributes){this._updateAttrs(t)}for(const e of this.markedChildren){this._updateChildren(e,{inlineFillerPosition:t})}for(const e of this.markedTexts){if(!this.markedChildren.has(e.parent)&&this.domConverter.mapViewToDom(e.parent)){this._updateText(e,{inlineFillerPosition:t})}}if(t){const e=this.domConverter.viewPositionToDom(t);const i=e.parent.ownerDocument;if(!cd(e.parent)){this._inlineFiller=Td(i,e.parent,e.offset)}else{this._inlineFiller=e.parent}}else{this._inlineFiller=null}this._updateSelection();this._updateFocus();this.markedTexts.clear();this.markedAttributes.clear();this.markedChildren.clear()}_updateChildrenMappings(t){const e=this.domConverter.mapViewToDom(t);if(!e){return}const i=this.domConverter.mapViewToDom(t).childNodes;const n=Array.from(this.domConverter.viewChildrenToDom(t,e.ownerDocument,{withChildren:false}));const o=this._diffNodeLists(i,n);const r=this._findReplaceActions(o,i,n);if(r.indexOf(\"replace\")!==-1){const e={equal:0,insert:0,delete:0};for(const o of r){if(o===\"replace\"){const o=e.equal+e.insert;const r=e.equal+e.delete;const s=t.getChild(o);if(s&&!s.is(\"uiElement\")){this._updateElementMappings(s,i[r])}yd(n[o]);e.equal++}else{e[o]++}}}}_updateElementMappings(t,e){this.domConverter.unbindDomElement(e);this.domConverter.bindElements(e,t);this.markedChildren.add(t);this.markedAttributes.add(t)}_getInlineFillerPosition(){const t=this.selection.getFirstPosition();if(t.parent.is(\"text\")){return uc._createBefore(this.selection.getFirstPosition().parent)}else{return t}}_isSelectionInInlineFiller(){if(this.selection.rangeCount!=1||!this.selection.isCollapsed){return false}const t=this.selection.getFirstPosition();const e=this.domConverter.viewPositionToDom(t);if(e&&od(e.parent)&&cd(e.parent)){return true}return false}_removeInlineFiller(){const t=this._inlineFiller;if(!cd(t)){throw new ss[\"b\"](\"view-renderer-filler-was-lost: The inline filler node was lost.\",this)}if(dd(t)){t.parentNode.removeChild(t)}else{t.data=t.data.substr(ad)}this._inlineFiller=null}_needsInlineFillerAtSelection(){if(this.selection.rangeCount!=1||!this.selection.isCollapsed){return false}const t=this.selection.getFirstPosition();const e=t.parent;const i=t.offset;if(!this.domConverter.mapViewToDom(e.root)){return false}if(!e.is(\"element\")){return false}if(!Ad(e)){return false}if(i===e.getFillerOffset()){return false}const n=t.nodeBefore;const o=t.nodeAfter;if(n instanceof Fs||o instanceof Fs){return false}return true}_updateText(t,e){const i=this.domConverter.findCorrespondingDomText(t);const n=this.domConverter.viewToDom(t,i.ownerDocument);const o=i.data;let r=n.data;const s=e.inlineFillerPosition;if(s&&s.parent==t.parent&&s.offset==t.index){r=ld+r}if(o!=r){const t=md(o,r);for(const e of t){if(e.type===\"insert\"){i.insertData(e.index,e.values.join(\"\"))}else{i.deleteData(e.index,e.howMany)}}}}_updateAttrs(t){const e=this.domConverter.mapViewToDom(t);if(!e){return}const i=Array.from(e.attributes).map(t=>t.name);const n=t.getAttributeKeys();for(const i of n){e.setAttribute(i,t.getAttribute(i))}for(const n of i){if(!t.hasAttribute(n)){e.removeAttribute(n)}}}_updateChildren(t,e){const i=this.domConverter.mapViewToDom(t);if(!i){return}const n=e.inlineFillerPosition;const o=this.domConverter.mapViewToDom(t).childNodes;const r=Array.from(this.domConverter.viewChildrenToDom(t,i.ownerDocument,{bind:true,inlineFillerPosition:n}));if(n&&n.parent===t){Td(i.ownerDocument,r,n.offset)}const s=this._diffNodeLists(o,r);let a=0;const l=new Set;for(const t of s){if(t===\"delete\"){l.add(o[a]);yd(o[a])}else if(t===\"equal\"){a++}}a=0;for(const t of s){if(t===\"insert\"){vd(i,a,r[a]);a++}else if(t===\"equal\"){this._markDescendantTextToSync(this.domConverter.domToView(r[a]));a++}}for(const t of l){if(!t.parentNode){this.domConverter.unbindDomElement(t)}}}_diffNodeLists(t,e){t=Md(t,this._fakeSelectionContainer);return kd(t,e,Ed.bind(null,this.domConverter))}_findReplaceActions(t,e,i){if(t.indexOf(\"insert\")===-1||t.indexOf(\"delete\")===-1){return t}let n=[];let o=[];let r=[];const s={equal:0,insert:0,delete:0};for(const a of t){if(a===\"insert\"){r.push(i[s.equal+s.insert])}else if(a===\"delete\"){o.push(e[s.equal+s.delete])}else{n=n.concat(kd(o,r,Pd).map(t=>t===\"equal\"?\"replace\":t));n.push(\"equal\");o=[];r=[]}s[a]++}return n.concat(kd(o,r,Pd).map(t=>t===\"equal\"?\"replace\":t))}_markDescendantTextToSync(t){if(!t){return}if(t.is(\"text\")){this.markedTexts.add(t)}else if(t.is(\"element\")){for(const e of t.getChildren()){this._markDescendantTextToSync(e)}}}_updateSelection(){if(this.selection.rangeCount===0){this._removeDomSelection();this._removeFakeSelection();return}const t=this.domConverter.mapViewToDom(this.selection.editableElement);if(!this.isFocused||!t){return}if(this.selection.isFake){this._updateFakeSelection(t)}else{this._removeFakeSelection();this._updateDomSelection(t)}}_updateFakeSelection(t){const e=t.ownerDocument;if(!this._fakeSelectionContainer){this._fakeSelectionContainer=Od(e)}const i=this._fakeSelectionContainer;this.domConverter.bindFakeSelection(i,this.selection);if(!this._fakeSelectionNeedsUpdate(t)){return}if(!i.parentElement||i.parentElement!=t){t.appendChild(i)}i.textContent=this.selection.fakeSelectionLabel||\" \";const n=e.getSelection();const o=e.createRange();n.removeAllRanges();o.selectNodeContents(i);n.addRange(o)}_updateDomSelection(t){const e=t.ownerDocument.defaultView.getSelection();if(!this._domSelectionNeedsUpdate(e)){return}const i=this.domConverter.viewPositionToDom(this.selection.anchor);const n=this.domConverter.viewPositionToDom(this.selection.focus);t.focus();e.collapse(i.parent,i.offset);e.extend(n.parent,n.offset);if(Tc.isGecko){Sd(n,e)}}_domSelectionNeedsUpdate(t){if(!this.domConverter.isDomSelectionCorrect(t)){return true}const e=t&&this.domConverter.domSelectionToView(t);if(e&&this.selection.isEqual(e)){return false}if(!this.selection.isCollapsed&&this.selection.isSimilar(e)){return false}return true}_fakeSelectionNeedsUpdate(t){const e=this._fakeSelectionContainer;const i=t.ownerDocument.getSelection();if(!e||e.parentElement!==t){return true}if(i.anchorNode!==e&&!e.contains(i.anchorNode)){return true}return e.textContent!==this.selection.fakeSelectionLabel}_removeDomSelection(){for(const t of this.domDocuments){const e=t.getSelection();if(e.rangeCount){const e=t.activeElement;const i=this.domConverter.mapDomToView(e);if(e&&i){t.getSelection().removeAllRanges()}}}}_removeFakeSelection(){const t=this._fakeSelectionContainer;if(t){t.remove()}}_updateFocus(){if(this.isFocused){const t=this.selection.editableElement;if(t){this.domConverter.focus(t)}}}}ys(Cd,Xl);function Ad(t){if(t.getAttribute(\"contenteditable\")==\"false\"){return false}const e=t.findAncestor(t=>t.hasAttribute(\"contenteditable\"));return!e||e.getAttribute(\"contenteditable\")==\"true\"}function Td(t,e,i){const n=e instanceof Array?e:e.childNodes;const o=n[i];if(od(o)){o.data=ld+o.data;return o}else{const o=t.createTextNode(ld);if(Array.isArray(e)){n.splice(i,0,o)}else{vd(e,i,o)}return o}}function Pd(t,e){return xd(t)&&xd(e)&&!od(t)&&!od(e)&&t.tagName.toLowerCase()===e.tagName.toLowerCase()}function Ed(t,e,i){if(e===i){return true}else if(od(e)&&od(i)){return e.data===i.data}else if(t.isBlockFiller(e)&&t.isBlockFiller(i)){return true}return false}function Sd(t,e){const i=t.parent;if(i.nodeType!=Node.ELEMENT_NODE||t.offset!=i.childNodes.length-1){return}const n=i.childNodes[t.offset];if(n&&n.tagName==\"BR\"){e.addRange(e.getRangeAt(0))}}function Md(t,e){const i=Array.from(t);if(i.length==0||!e){return i}const n=i[i.length-1];if(n==e){i.pop()}return i}function Od(t){const e=t.createElement(\"div\");Object.assign(e.style,{position:\"fixed\",top:0,left:\"-9999px\",width:\"42px\"});e.textContent=\" \";return e}var Id={window:window,document:document};function Rd(t){let e=0;while(t.previousSibling){t=t.previousSibling;e++}return e}function Ld(t){const e=[];while(t&&t.nodeType!=Node.DOCUMENT_NODE){e.unshift(t);t=t.parentNode}return e}function Nd(t,e){const i=Ld(t);const n=Ld(e);let o=0;while(i[o]==n[o]&&i[o]){o++}return o===0?null:i[o-1]}const Bd=sd(document);class Vd{constructor(t,e={}){this.document=t;this.blockFillerMode=e.blockFillerMode||\"br\";this.preElements=[\"pre\"];this.blockElements=[\"p\",\"div\",\"h1\",\"h2\",\"h3\",\"h4\",\"h5\",\"h6\",\"li\",\"dd\",\"dt\",\"figcaption\"];this._blockFiller=this.blockFillerMode==\"br\"?sd:rd;this._domToViewMapping=new WeakMap;this._viewToDomMapping=new WeakMap;this._fakeSelectionMapping=new WeakMap}bindFakeSelection(t,e){this._fakeSelectionMapping.set(t,new gc(e))}fakeSelectionToView(t){return this._fakeSelectionMapping.get(t)}bindElements(t,e){this._domToViewMapping.set(t,e);this._viewToDomMapping.set(e,t)}unbindDomElement(t){const e=this._domToViewMapping.get(t);if(e){this._domToViewMapping.delete(t);this._viewToDomMapping.delete(e);for(const e of t.childNodes){this.unbindDomElement(e)}}}bindDocumentFragments(t,e){this._domToViewMapping.set(t,e);this._viewToDomMapping.set(e,t)}viewToDom(t,e,i={}){if(t.is(\"text\")){const i=this._processDataFromViewText(t);return e.createTextNode(i)}else{if(this.mapViewToDom(t)){return this.mapViewToDom(t)}let n;if(t.is(\"documentFragment\")){n=e.createDocumentFragment();if(i.bind){this.bindDocumentFragments(n,t)}}else if(t.is(\"uiElement\")){n=t.render(e);if(i.bind){this.bindElements(n,t)}return n}else{if(t.hasAttribute(\"xmlns\")){n=e.createElementNS(t.getAttribute(\"xmlns\"),t.name)}else{n=e.createElement(t.name)}if(i.bind){this.bindElements(n,t)}for(const e of t.getAttributeKeys()){n.setAttribute(e,t.getAttribute(e))}}if(i.withChildren||i.withChildren===undefined){for(const o of this.viewChildrenToDom(t,e,i)){n.appendChild(o)}}return n}}*viewChildrenToDom(t,e,i={}){const n=t.getFillerOffset&&t.getFillerOffset();let o=0;for(const r of t.getChildren()){if(n===o){yield this._blockFiller(e)}yield this.viewToDom(r,e,i);o++}if(n===o){yield this._blockFiller(e)}}viewRangeToDom(t){const e=this.viewPositionToDom(t.start);const i=this.viewPositionToDom(t.end);const n=document.createRange();n.setStart(e.parent,e.offset);n.setEnd(i.parent,i.offset);return n}viewPositionToDom(t){const e=t.parent;if(e.is(\"text\")){const i=this.findCorrespondingDomText(e);if(!i){return null}let n=t.offset;if(cd(i)){n+=ad}return{parent:i,offset:n}}else{let i,n,o;if(t.offset===0){i=this.mapViewToDom(e);if(!i){return null}o=i.childNodes[0]}else{const e=t.nodeBefore;n=e.is(\"text\")?this.findCorrespondingDomText(e):this.mapViewToDom(t.nodeBefore);if(!n){return null}i=n.parentNode;o=n.nextSibling}if(od(o)&&cd(o)){return{parent:o,offset:ad}}const r=n?Rd(n)+1:0;return{parent:i,offset:r}}}domToView(t,e={}){if(this.isBlockFiller(t,this.blockFillerMode)){return null}const i=this.getParentUIElement(t,this._domToViewMapping);if(i){return i}if(od(t)){if(dd(t)){return null}else{const e=this._processDataFromDomText(t);return e===\"\"?null:new Fs(this.document,e)}}else if(this.isComment(t)){return null}else{if(this.mapDomToView(t)){return this.mapDomToView(t)}let i;if(this.isDocumentFragment(t)){i=new qc(this.document);if(e.bind){this.bindDocumentFragments(t,i)}}else{const n=e.keepOriginalCase?t.tagName:t.tagName.toLowerCase();i=new Dl(this.document,n);if(e.bind){this.bindElements(t,i)}const o=t.attributes;for(let t=o.length-1;t>=0;t--){i._setAttribute(o[t].name,o[t].value)}}if(e.withChildren||e.withChildren===undefined){for(const n of this.domChildrenToView(t,e)){i._appendChild(n)}}return i}}*domChildrenToView(t,e={}){for(let i=0;i<t.childNodes.length;i++){const n=t.childNodes[i];const o=this.domToView(n,e);if(o!==null){yield o}}}domSelectionToView(t){if(t.rangeCount===1){let e=t.getRangeAt(0).startContainer;if(od(e)){e=e.parentNode}const i=this.fakeSelectionToView(e);if(i){return i}}const e=this.isDomSelectionBackward(t);const i=[];for(let e=0;e<t.rangeCount;e++){const n=t.getRangeAt(e);const o=this.domRangeToView(n);if(o){i.push(o)}}return new gc(i,{backward:e})}domRangeToView(t){const e=this.domPositionToView(t.startContainer,t.startOffset);const i=this.domPositionToView(t.endContainer,t.endOffset);if(e&&i){return new hc(e,i)}return null}domPositionToView(t,e){if(this.isBlockFiller(t,this.blockFillerMode)){return this.domPositionToView(t.parentNode,Rd(t))}const i=this.mapDomToView(t);if(i&&i.is(\"uiElement\")){return uc._createBefore(i)}if(od(t)){if(dd(t)){return this.domPositionToView(t.parentNode,Rd(t))}const i=this.findCorrespondingViewText(t);let n=e;if(!i){return null}if(cd(t)){n-=ad;n=n<0?0:n}return new uc(i,n)}else{if(e===0){const e=this.mapDomToView(t);if(e){return new uc(e,0)}}else{const i=t.childNodes[e-1];const n=od(i)?this.findCorrespondingViewText(i):this.mapDomToView(i);if(n&&n.parent){return new uc(n.parent,n.index+1)}}return null}}mapDomToView(t){return this.getParentUIElement(t)||this._domToViewMapping.get(t)}findCorrespondingViewText(t){if(dd(t)){return null}const e=this.getParentUIElement(t);if(e){return e}const i=t.previousSibling;if(i){if(!this.isElement(i)){return null}const t=this.mapDomToView(i);if(t){const e=t.nextSibling;if(e instanceof Fs){return t.nextSibling}else{return null}}}else{const e=this.mapDomToView(t.parentNode);if(e){const t=e.getChild(0);if(t instanceof Fs){return t}else{return null}}}return null}mapViewToDom(t){return this._viewToDomMapping.get(t)}findCorrespondingDomText(t){const e=t.previousSibling;if(e&&this.mapViewToDom(e)){return this.mapViewToDom(e).nextSibling}if(!e&&t.parent&&this.mapViewToDom(t.parent)){return this.mapViewToDom(t.parent).childNodes[0]}return null}focus(t){const e=this.mapViewToDom(t);if(e&&e.ownerDocument.activeElement!==e){const{scrollX:t,scrollY:i}=Id.window;const n=[];zd(e,t=>{const{scrollLeft:e,scrollTop:i}=t;n.push([e,i])});e.focus();zd(e,t=>{const[e,i]=n.shift();t.scrollLeft=e;t.scrollTop=i});Id.window.scrollTo(t,i)}}isElement(t){return t&&t.nodeType==Node.ELEMENT_NODE}isDocumentFragment(t){return t&&t.nodeType==Node.DOCUMENT_FRAGMENT_NODE}isComment(t){return t&&t.nodeType==Node.COMMENT_NODE}isBlockFiller(t){if(this.blockFillerMode==\"br\"){return t.isEqualNode(Bd)}if(t.tagName===\"BR\"&&jd(t,this.blockElements)&&t.parentNode.childNodes.length===1){return true}return Fd(t,this.blockElements)}isDomSelectionBackward(t){if(t.isCollapsed){return false}const e=document.createRange();e.setStart(t.anchorNode,t.anchorOffset);e.setEnd(t.focusNode,t.focusOffset);const i=e.collapsed;e.detach();return i}getParentUIElement(t){const e=Ld(t);e.pop();while(e.length){const t=e.pop();const i=this._domToViewMapping.get(t);if(i&&i.is(\"uiElement\")){return i}}return null}isDomSelectionCorrect(t){return this._isDomSelectionPositionCorrect(t.anchorNode,t.anchorOffset)&&this._isDomSelectionPositionCorrect(t.focusNode,t.focusOffset)}_isDomSelectionPositionCorrect(t,e){if(od(t)&&cd(t)&&e<ad){return false}if(this.isElement(t)&&cd(t.childNodes[e])){return false}const i=this.mapDomToView(t);if(i&&i.is(\"uiElement\")){return false}return true}_processDataFromViewText(t){let e=t.data;if(t.getAncestors().some(t=>this.preElements.includes(t.name))){return e}if(e.charAt(0)==\" \"){const i=this._getTouchingViewTextNode(t,false);const n=i&&this._nodeEndsWithSpace(i);if(n||!i){e=\" \"+e.substr(1)}}if(e.charAt(e.length-1)==\" \"){const i=this._getTouchingViewTextNode(t,true);if(e.charAt(e.length-2)==\" \"||!i||i.data.charAt(0)==\" \"){e=e.substr(0,e.length-1)+\" \"}}return e.replace(/ {2}/g,\"  \")}_nodeEndsWithSpace(t){if(t.getAncestors().some(t=>this.preElements.includes(t.name))){return false}const e=this._processDataFromViewText(t);return e.charAt(e.length-1)==\" \"}_processDataFromDomText(t){let e=t.data;if(Dd(t,this.preElements)){return ud(t)}e=e.replace(/[ \\n\\t\\r]{1,}/g,\" \");const i=this._getTouchingInlineDomNode(t,false);const n=this._getTouchingInlineDomNode(t,true);const o=this._checkShouldLeftTrimDomText(i);const r=this._checkShouldRightTrimDomText(t,n);if(o){e=e.replace(/^ /,\"\")}if(r){e=e.replace(/ $/,\"\")}e=ud(new Text(e));e=e.replace(/ \\u00A0/g,\" \");if(/( |\\u00A0)\\u00A0$/.test(e)||!n||n.data&&n.data.charAt(0)==\" \"){e=e.replace(/\\u00A0$/,\" \")}if(o){e=e.replace(/^\\u00A0/,\" \")}return e}_checkShouldLeftTrimDomText(t){if(!t){return true}if(Jr(t)){return true}return/[^\\S\\u00A0]/.test(t.data.charAt(t.data.length-1))}_checkShouldRightTrimDomText(t,e){if(e){return false}return!cd(t)}_getTouchingViewTextNode(t,e){const i=new dc({startPosition:e?uc._createAfter(t):uc._createBefore(t),direction:e?\"forward\":\"backward\"});for(const t of i){if(t.item.is(\"containerElement\")){return null}else if(t.item.is(\"br\")){return null}else if(t.item.is(\"textProxy\")){return t.item}}return null}_getTouchingInlineDomNode(t,e){if(!t.parentNode){return null}const i=e?\"nextNode\":\"previousNode\";const n=t.ownerDocument;const o=Ld(t)[0];const r=n.createTreeWalker(o,NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT,{acceptNode(t){if(od(t)){return NodeFilter.FILTER_ACCEPT}if(t.tagName==\"BR\"){return NodeFilter.FILTER_ACCEPT}return NodeFilter.FILTER_SKIP}});r.currentNode=t;const s=r[i]();if(s!==null){const e=Nd(t,s);if(e&&!Dd(t,this.blockElements,e)&&!Dd(s,this.blockElements,e)){return s}}return null}}function Dd(t,e,i){let n=Ld(t);if(i){n=n.slice(n.indexOf(i)+1)}return n.some(t=>t.tagName&&e.includes(t.tagName.toLowerCase()))}function zd(t,e){while(t&&t!=Id.document){e(t);t=t.parentNode}}function Fd(t,e){const i=od(t)&&t.data==\" \";return i&&jd(t,e)&&t.parentNode.childNodes.length===1}function jd(t,e){const i=t.parentNode;return i&&i.tagName&&e.includes(i.tagName.toLowerCase())}function Hd(t){const e=Object.prototype.toString.apply(t);if(e==\"[object Window]\"){return true}if(e==\"[object global]\"){return true}return false}const Wd=$l({},ds,{listenTo(t,...e){if(xd(t)||Hd(t)){const i=this._getProxyEmitter(t)||new $d(t);i.attach(...e);t=i}ds.listenTo.call(this,t,...e)},stopListening(t,e,i){if(xd(t)||Hd(t)){const e=this._getProxyEmitter(t);if(!e){return}t=e}ds.stopListening.call(this,t,e,i);if(t instanceof $d){t.detach(e)}},_getProxyEmitter(t){return us(this,Ud(t))}});var qd=Wd;class $d{constructor(t){hs(this,Ud(t));this._domNode=t}}$l($d.prototype,ds,{attach(t,e,i={}){if(this._domListeners&&this._domListeners[t]){return}const n=this._createDomListener(t,!!i.useCapture);this._domNode.addEventListener(t,n,!!i.useCapture);if(!this._domListeners){this._domListeners={}}this._domListeners[t]=n},detach(t){let e;if(this._domListeners[t]&&(!(e=this._events[t])||!e.callbacks.length)){this._domListeners[t].removeListener()}},_createDomListener(t,e){const i=e=>{this.fire(t,e)};i.removeListener=()=>{this._domNode.removeEventListener(t,i,e);delete this._domListeners[t]};return i}});function Ud(t){return t[\"data-ck-expando\"]||(t[\"data-ck-expando\"]=is())}class Gd{constructor(t){this.view=t;this.document=t.document;this.isEnabled=false}enable(){this.isEnabled=true}disable(){this.isEnabled=false}destroy(){this.disable();this.stopListening()}}ys(Gd,qd);var Jd=\"__lodash_hash_undefined__\";function Kd(t){this.__data__.set(t,Jd);return this}var Xd=Kd;function Yd(t){return this.__data__.has(t)}var Qd=Yd;function Zd(t){var e=-1,i=t==null?0:t.length;this.__data__=new ke;while(++e<i){this.add(t[e])}}Zd.prototype.add=Zd.prototype.push=Xd;Zd.prototype.has=Qd;var tu=Zd;function eu(t,e){var i=-1,n=t==null?0:t.length;while(++i<n){if(e(t[i],i,t)){return true}}return false}var iu=eu;function nu(t,e){return t.has(e)}var ou=nu;var ru=1,su=2;function au(t,e,i,n,o,r){var s=i&ru,a=t.length,l=e.length;if(a!=l&&!(s&&l>a)){return false}var c=r.get(t);if(c&&r.get(e)){return c==e}var d=-1,u=true,h=i&su?new tu:undefined;r.set(t,e);r.set(e,t);while(++d<a){var f=t[d],m=e[d];if(n){var g=s?n(m,f,d,e,t,r):n(f,m,d,t,e,r)}if(g!==undefined){if(g){continue}u=false;break}if(h){if(!iu(e,(function(t,e){if(!ou(h,e)&&(f===t||o(f,t,i,n,r))){return h.push(e)}}))){u=false;break}}else if(!(f===m||o(f,m,i,n,r))){u=false;break}}r[\"delete\"](t);r[\"delete\"](e);return u}var lu=au;function cu(t){var e=-1,i=Array(t.size);t.forEach((function(t,n){i[++e]=[n,t]}));return i}var du=cu;function uu(t){var e=-1,i=Array(t.size);t.forEach((function(t){i[++e]=t}));return i}var hu=uu;var fu=1,mu=2;var gu=\"[object Boolean]\",pu=\"[object Date]\",bu=\"[object Error]\",wu=\"[object Map]\",_u=\"[object Number]\",ku=\"[object RegExp]\",vu=\"[object Set]\",yu=\"[object String]\",xu=\"[object Symbol]\";var Cu=\"[object ArrayBuffer]\",Au=\"[object DataView]\";var Tu=r?r.prototype:undefined,Pu=Tu?Tu.valueOf:undefined;function Eu(t,e,i,n,o,r,s){switch(i){case Au:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset){return false}t=t.buffer;e=e.buffer;case Cu:if(t.byteLength!=e.byteLength||!r(new fo(t),new fo(e))){return false}return true;case gu:case pu:case _u:return D(+t,+e);case bu:return t.name==e.name&&t.message==e.message;case ku:case yu:return t==e+\"\";case wu:var a=du;case vu:var l=n&fu;a||(a=hu);if(t.size!=e.size&&!l){return false}var c=s.get(t);if(c){return c==e}n|=mu;s.set(t,e);var d=lu(a(t),a(e),n,o,r,s);s[\"delete\"](t);return d;case xu:if(Pu){return Pu.call(t)==Pu.call(e)}}return false}var Su=Eu;var Mu=1;var Ou=Object.prototype;var Iu=Ou.hasOwnProperty;function Ru(t,e,i,n,o,r){var s=i&Mu,a=Vn(t),l=a.length,c=Vn(e),d=c.length;if(l!=d&&!s){return false}var u=l;while(u--){var h=a[u];if(!(s?h in e:Iu.call(e,h))){return false}}var f=r.get(t);if(f&&r.get(e)){return f==e}var m=true;r.set(t,e);r.set(e,t);var g=s;while(++u<l){h=a[u];var p=t[h],b=e[h];if(n){var w=s?n(b,p,h,e,t,r):n(p,b,h,t,e,r)}if(!(w===undefined?p===b||o(p,b,i,n,r):w)){m=false;break}g||(g=h==\"constructor\")}if(m&&!g){var _=t.constructor,k=e.constructor;if(_!=k&&(\"constructor\"in t&&\"constructor\"in e)&&!(typeof _==\"function\"&&_ instanceof _&&typeof k==\"function\"&&k instanceof k)){m=false}}r[\"delete\"](t);r[\"delete\"](e);return m}var Lu=Ru;var Nu=1;var Bu=\"[object Arguments]\",Vu=\"[object Array]\",Du=\"[object Object]\";var zu=Object.prototype;var Fu=zu.hasOwnProperty;function ju(t,e,i,n,o,r){var s=Ke(t),a=Ke(e),l=s?Vu:so(t),c=a?Vu:so(e);l=l==Bu?Du:l;c=c==Bu?Du:c;var d=l==Du,u=c==Du,h=l==c;if(h&&Object(Xe[\"a\"])(t)){if(!Object(Xe[\"a\"])(e)){return false}s=true;d=false}if(h&&!d){r||(r=new Ae);return s||Bi(t)?lu(t,e,i,n,o,r):Su(t,e,l,i,n,o,r)}if(!(i&Nu)){var f=d&&Fu.call(t,\"__wrapped__\"),m=u&&Fu.call(e,\"__wrapped__\");if(f||m){var g=f?t.value():t,p=m?e.value():e;r||(r=new Ae);return o(g,p,i,n,r)}}if(!h){return false}r||(r=new Ae);return Lu(t,e,i,n,o,r)}var Hu=ju;function Wu(t,e,i,n,o){if(t===e){return true}if(t==null||e==null||!T(t)&&!T(e)){return t!==t&&e!==e}return Hu(t,e,i,n,Wu,o)}var qu=Wu;function $u(t,e,i){i=typeof i==\"function\"?i:undefined;var n=i?i(t,e):undefined;return n===undefined?qu(t,e,undefined,i):!!n}var Uu=$u;class Gu extends Gd{constructor(t){super(t);this._config={childList:true,characterData:true,characterDataOldValue:true,subtree:true};this.domConverter=t.domConverter;this.renderer=t._renderer;this._domElements=[];this._mutationObserver=new window.MutationObserver(this._onMutations.bind(this))}flush(){this._onMutations(this._mutationObserver.takeRecords())}observe(t){this._domElements.push(t);if(this.isEnabled){this._mutationObserver.observe(t,this._config)}}enable(){super.enable();for(const t of this._domElements){this._mutationObserver.observe(t,this._config)}}disable(){super.disable();this._mutationObserver.disconnect()}destroy(){super.destroy();this._mutationObserver.disconnect()}_onMutations(t){if(t.length===0){return}const e=this.domConverter;const i=new Map;const n=new Set;for(const i of t){if(i.type===\"childList\"){const t=e.mapDomToView(i.target);if(t&&t.is(\"uiElement\")){continue}if(t&&!this._isBogusBrMutation(i)){n.add(t)}}}for(const o of t){const t=e.mapDomToView(o.target);if(t&&t.is(\"uiElement\")){continue}if(o.type===\"characterData\"){const t=e.findCorrespondingViewText(o.target);if(t&&!n.has(t.parent)){i.set(t,{type:\"text\",oldText:t.data,newText:ud(o.target),node:t})}else if(!t&&cd(o.target)){n.add(e.mapDomToView(o.target.parentNode))}}}const o=[];for(const t of i.values()){this.renderer.markToSync(\"text\",t.node);o.push(t)}for(const t of n){const i=e.mapViewToDom(t);const n=Array.from(t.getChildren());const r=Array.from(e.domChildrenToView(i,{withChildren:false}));if(!Uu(n,r,a)){this.renderer.markToSync(\"children\",t);o.push({type:\"children\",oldChildren:n,newChildren:r,node:t})}}const r=t[0].target.ownerDocument.getSelection();let s=null;if(r&&r.anchorNode){const t=e.domPositionToView(r.anchorNode,r.anchorOffset);const i=e.domPositionToView(r.focusNode,r.focusOffset);if(t&&i){s=new gc(t);s.setFocus(i)}}if(o.length){this.document.fire(\"mutations\",o,s);this.view.forceRender()}function a(t,e){if(Array.isArray(t)){return}if(t===e){return true}else if(t.is(\"text\")&&e.is(\"text\")){return t.data===e.data}return false}}_isBogusBrMutation(t){let e=null;if(t.nextSibling===null&&t.removedNodes.length===0&&t.addedNodes.length==1){e=this.domConverter.domToView(t.addedNodes[0],{withChildren:false})}return e&&e.is(\"element\",\"br\")}}class Ju{constructor(t,e,i){this.view=t;this.document=t.document;this.domEvent=e;this.domTarget=e.target;$l(this,i)}get target(){return this.view.domConverter.mapDomToView(this.domTarget)}preventDefault(){this.domEvent.preventDefault()}stopPropagation(){this.domEvent.stopPropagation()}}class Ku extends Gd{constructor(t){super(t);this.useCapture=false}observe(t){const e=typeof this.domEventType==\"string\"?[this.domEventType]:this.domEventType;e.forEach(e=>{this.listenTo(t,e,(t,e)=>{if(this.isEnabled){this.onDomEvent(e)}},{useCapture:this.useCapture})})}fire(t,e,i){if(this.isEnabled){this.document.fire(t,new Ju(this.view,e,i))}}}class Xu extends Ku{constructor(t){super(t);this.domEventType=[\"keydown\",\"keyup\"]}onDomEvent(t){this.fire(t.type,t,{keyCode:t.keyCode,altKey:t.altKey,ctrlKey:t.ctrlKey||t.metaKey,shiftKey:t.shiftKey,get keystroke(){return Nc(this)}})}}var Yu=function(){return n[\"a\"].Date.now()};var Qu=Yu;var Zu=0/0;var th=/^\\s+|\\s+$/g;var eh=/^[-+]0x[0-9a-f]+$/i;var ih=/^0b[01]+$/i;var nh=/^0o[0-7]+$/i;var oh=parseInt;function rh(t){if(typeof t==\"number\"){return t}if(Qs(t)){return Zu}if(lt(t)){var e=typeof t.valueOf==\"function\"?t.valueOf():t;t=lt(e)?e+\"\":e}if(typeof t!=\"string\"){return t===0?t:+t}t=t.replace(th,\"\");var i=ih.test(t);return i||nh.test(t)?oh(t.slice(2),i?2:8):eh.test(t)?Zu:+t}var sh=rh;var ah=\"Expected a function\";var lh=Math.max,ch=Math.min;function dh(t,e,i){var n,o,r,s,a,l,c=0,d=false,u=false,h=true;if(typeof t!=\"function\"){throw new TypeError(ah)}e=sh(e)||0;if(lt(i)){d=!!i.leading;u=\"maxWait\"in i;r=u?lh(sh(i.maxWait)||0,e):r;h=\"trailing\"in i?!!i.trailing:h}function f(e){var i=n,r=o;n=o=undefined;c=e;s=t.apply(r,i);return s}function m(t){c=t;a=setTimeout(b,e);return d?f(t):s}function g(t){var i=t-l,n=t-c,o=e-i;return u?ch(o,r-n):o}function p(t){var i=t-l,n=t-c;return l===undefined||i>=e||i<0||u&&n>=r}function b(){var t=Qu();if(p(t)){return w(t)}a=setTimeout(b,g(t))}function w(t){a=undefined;if(h&&n){return f(t)}n=o=undefined;return s}function _(){if(a!==undefined){clearTimeout(a)}c=0;n=l=o=a=undefined}function k(){return a===undefined?s:w(Qu())}function v(){var t=Qu(),i=p(t);n=arguments;o=this;l=t;if(i){if(a===undefined){return m(l)}if(u){clearTimeout(a);a=setTimeout(b,e);return f(l)}}if(a===undefined){a=setTimeout(b,e)}return s}v.cancel=_;v.flush=k;return v}var uh=dh;class hh extends Gd{constructor(t){super(t);this._fireSelectionChangeDoneDebounced=uh(t=>this.document.fire(\"selectionChangeDone\",t),200)}observe(){const t=this.document;t.on(\"keydown\",(e,i)=>{const n=t.selection;if(n.isFake&&fh(i.keyCode)&&this.isEnabled){i.preventDefault();this._handleSelectionMove(i.keyCode)}},{priority:\"lowest\"})}destroy(){super.destroy();this._fireSelectionChangeDoneDebounced.cancel()}_handleSelectionMove(t){const e=this.document.selection;const i=new gc(e.getRanges(),{backward:e.isBackward,fake:false});if(t==Lc.arrowleft||t==Lc.arrowup){i.setTo(i.getFirstPosition())}if(t==Lc.arrowright||t==Lc.arrowdown){i.setTo(i.getLastPosition())}const n={oldSelection:e,newSelection:i,domSelection:null};this.document.fire(\"selectionChange\",n);this._fireSelectionChangeDoneDebounced(n)}}function fh(t){return t==Lc.arrowright||t==Lc.arrowleft||t==Lc.arrowup||t==Lc.arrowdown}class mh extends Gd{constructor(t){super(t);this.mutationObserver=t.getObserver(Gu);this.selection=this.document.selection;this.domConverter=t.domConverter;this._documents=new WeakSet;this._fireSelectionChangeDoneDebounced=uh(t=>this.document.fire(\"selectionChangeDone\",t),200);this._clearInfiniteLoopInterval=setInterval(()=>this._clearInfiniteLoop(),1e3);this._loopbackCounter=0}observe(t){const e=t.ownerDocument;if(this._documents.has(e)){return}this.listenTo(e,\"selectionchange\",()=>{this._handleSelectionChange(e)});this._documents.add(e)}destroy(){super.destroy();clearInterval(this._clearInfiniteLoopInterval);this._fireSelectionChangeDoneDebounced.cancel()}_handleSelectionChange(t){if(!this.isEnabled){return}this.mutationObserver.flush();const e=t.defaultView.getSelection();const i=this.domConverter.domSelectionToView(e);if(i.rangeCount==0){this.view.hasDomSelection=false;return}this.view.hasDomSelection=true;if(this.selection.isEqual(i)&&this.domConverter.isDomSelectionCorrect(e)){return}if(++this._loopbackCounter>60){return}if(this.selection.isSimilar(i)){this.view.forceRender()}else{const t={oldSelection:this.selection,newSelection:i,domSelection:e};this.document.fire(\"selectionChange\",t);this._fireSelectionChangeDoneDebounced(t)}}_clearInfiniteLoop(){this._loopbackCounter=0}}class gh extends Ku{constructor(t){super(t);this.domEventType=[\"focus\",\"blur\"];this.useCapture=true;const e=this.document;e.on(\"focus\",()=>{e.isFocused=true;this._renderTimeoutId=setTimeout(()=>t.forceRender(),50)});e.on(\"blur\",(i,n)=>{const o=e.selection.editableElement;if(o===null||o===n.target){e.isFocused=false;t.forceRender()}})}onDomEvent(t){this.fire(t.type,t)}destroy(){if(this._renderTimeoutId){clearTimeout(this._renderTimeoutId)}super.destroy()}}class ph extends Ku{constructor(t){super(t);this.domEventType=[\"compositionstart\",\"compositionupdate\",\"compositionend\"];const e=this.document;e.on(\"compositionstart\",()=>{e.isComposing=true});e.on(\"compositionend\",()=>{e.isComposing=false})}onDomEvent(t){this.fire(t.type,t)}}class bh extends Ku{constructor(t){super(t);this.domEventType=[\"beforeinput\"]}onDomEvent(t){this.fire(t.type,t)}}function wh(t){return Object.prototype.toString.apply(t)==\"[object Range]\"}function _h(t){const e=t.ownerDocument.defaultView.getComputedStyle(t);return{top:parseInt(e.borderTopWidth,10),right:parseInt(e.borderRightWidth,10),bottom:parseInt(e.borderBottomWidth,10),left:parseInt(e.borderLeftWidth,10)}}const kh=[\"top\",\"right\",\"bottom\",\"left\",\"width\",\"height\"];class vh{constructor(t){const e=wh(t);Object.defineProperty(this,\"_source\",{value:t._source||t,writable:true,enumerable:false});if(Jr(t)||e){if(e){yh(this,vh.getDomRangeRects(t)[0])}else{yh(this,t.getBoundingClientRect())}}else if(Hd(t)){const{innerWidth:e,innerHeight:i}=t;yh(this,{top:0,right:e,bottom:i,left:0,width:e,height:i})}else{yh(this,t)}}clone(){return new vh(this)}moveTo(t,e){this.top=e;this.right=t+this.width;this.bottom=e+this.height;this.left=t;return this}moveBy(t,e){this.top+=e;this.right+=t;this.left+=t;this.bottom+=e;return this}getIntersection(t){const e={top:Math.max(this.top,t.top),right:Math.min(this.right,t.right),bottom:Math.min(this.bottom,t.bottom),left:Math.max(this.left,t.left)};e.width=e.right-e.left;e.height=e.bottom-e.top;if(e.width<0||e.height<0){return null}else{return new vh(e)}}getIntersectionArea(t){const e=this.getIntersection(t);if(e){return e.getArea()}else{return 0}}getArea(){return this.width*this.height}getVisible(){const t=this._source;let e=this.clone();if(!xh(t)){let i=t.parentNode||t.commonAncestorContainer;while(i&&!xh(i)){const t=new vh(i);const n=e.getIntersection(t);if(n){if(n.getArea()<e.getArea()){e=n}}else{return null}i=i.parentNode}}return e}isEqual(t){for(const e of kh){if(this[e]!==t[e]){return false}}return true}contains(t){const e=this.getIntersection(t);return!!(e&&e.isEqual(t))}excludeScrollbarsAndBorders(){const t=this._source;let e,i,n;if(Hd(t)){e=t.innerWidth-t.document.documentElement.clientWidth;i=t.innerHeight-t.document.documentElement.clientHeight;n=t.getComputedStyle(t.document.documentElement).direction}else{const o=_h(this._source);e=t.offsetWidth-t.clientWidth-o.left-o.right;i=t.offsetHeight-t.clientHeight-o.top-o.bottom;n=t.ownerDocument.defaultView.getComputedStyle(t).direction;this.left+=o.left;this.top+=o.top;this.right-=o.right;this.bottom-=o.bottom;this.width=this.right-this.left;this.height=this.bottom-this.top}this.width-=e;if(n===\"ltr\"){this.right-=e}else{this.left+=e}this.height-=i;this.bottom-=i;return this}static getDomRangeRects(t){const e=[];const i=Array.from(t.getClientRects());if(i.length){for(const t of i){e.push(new vh(t))}}else{let i=t.startContainer;if(od(i)){i=i.parentNode}const n=new vh(i.getBoundingClientRect());n.right=n.left;n.width=0;e.push(n)}return e}}function yh(t,e){for(const i of kh){t[i]=e[i]}}function xh(t){if(!Jr(t)){return false}return t===t.ownerDocument.body}const Ch={};function Ah({target:t,viewportOffset:e=0}){const i=Rh(t);let n=i;let o=null;while(n){let r;if(n==i){r=Lh(t)}else{r=Lh(o)}Eh(r,()=>Nh(t,n));const s=Nh(t,n);Ph(n,s,e);if(n.parent!=n){o=n.frameElement;n=n.parent;if(!o){return}}else{n=null}}}function Th(t){const e=Lh(t);Eh(e,()=>new vh(t))}Object.assign(Ch,{scrollViewportToShowTarget:Ah,scrollAncestorsToShowTarget:Th});function Ph(t,e,i){const n=e.clone().moveBy(0,i);const o=e.clone().moveBy(0,-i);const r=new vh(t).excludeScrollbarsAndBorders();const s=[o,n];if(!s.every(t=>r.contains(t))){let{scrollX:s,scrollY:a}=t;if(Mh(o,r)){a-=r.top-e.top+i}else if(Sh(n,r)){a+=e.bottom-r.bottom+i}if(Oh(e,r)){s-=r.left-e.left+i}else if(Ih(e,r)){s+=e.right-r.right+i}t.scrollTo(s,a)}}function Eh(t,e){const i=Rh(t);let n,o;while(t!=i.document.body){o=e();n=new vh(t).excludeScrollbarsAndBorders();if(!n.contains(o)){if(Mh(o,n)){t.scrollTop-=n.top-o.top}else if(Sh(o,n)){t.scrollTop+=o.bottom-n.bottom}if(Oh(o,n)){t.scrollLeft-=n.left-o.left}else if(Ih(o,n)){t.scrollLeft+=o.right-n.right}}t=t.parentNode}}function Sh(t,e){return t.bottom>e.bottom}function Mh(t,e){return t.top<e.top}function Oh(t,e){return t.left<e.left}function Ih(t,e){return t.right>e.right}function Rh(t){if(wh(t)){return t.startContainer.ownerDocument.defaultView}else{return t.ownerDocument.defaultView}}function Lh(t){if(wh(t)){let e=t.commonAncestorContainer;if(od(e)){e=e.parentNode}return e}else{return t.parentNode}}function Nh(t,e){const i=Rh(t);const n=new vh(t);if(i===e){return n}else{let t=i;while(t!=e){const e=t.frameElement;const i=new vh(e).excludeScrollbarsAndBorders();n.moveBy(i.left,i.top);t=t.parent}}return n}class Bh{constructor(t){this.document=new bc(t);this.domConverter=new Vd(this.document);this.domRoots=new Map;this.set(\"isRenderingInProgress\",false);this.set(\"hasDomSelection\",false);this._renderer=new Cd(this.domConverter,this.document.selection);this._renderer.bind(\"isFocused\").to(this.document);this._initialDomRootAttributes=new WeakMap;this._observers=new Map;this._ongoingChange=false;this._postFixersInProgress=false;this._renderingDisabled=false;this._hasChangedSinceTheLastRendering=false;this._writer=new Uc(this.document);this.addObserver(Gu);this.addObserver(mh);this.addObserver(gh);this.addObserver(Xu);this.addObserver(hh);this.addObserver(ph);if(Tc.isAndroid){this.addObserver(bh)}hd(this);jc(this);this.on(\"render\",()=>{this._render();this.document.fire(\"layoutChanged\");this._hasChangedSinceTheLastRendering=false});this.listenTo(this.document.selection,\"change\",()=>{this._hasChangedSinceTheLastRendering=true})}attachDomRoot(t,e=\"main\"){const i=this.document.getRoot(e);i._name=t.tagName.toLowerCase();const n={};for(const{name:e,value:o}of Array.from(t.attributes)){n[e]=o;if(e===\"class\"){this._writer.addClass(o.split(\" \"),i)}else{this._writer.setAttribute(e,o,i)}}this._initialDomRootAttributes.set(t,n);const o=()=>{this._writer.setAttribute(\"contenteditable\",!i.isReadOnly,i);if(i.isReadOnly){this._writer.addClass(\"ck-read-only\",i)}else{this._writer.removeClass(\"ck-read-only\",i)}};o();this.domRoots.set(e,t);this.domConverter.bindElements(t,i);this._renderer.markToSync(\"children\",i);this._renderer.markToSync(\"attributes\",i);this._renderer.domDocuments.add(t.ownerDocument);i.on(\"change:children\",(t,e)=>this._renderer.markToSync(\"children\",e));i.on(\"change:attributes\",(t,e)=>this._renderer.markToSync(\"attributes\",e));i.on(\"change:text\",(t,e)=>this._renderer.markToSync(\"text\",e));i.on(\"change:isReadOnly\",()=>this.change(o));i.on(\"change\",()=>{this._hasChangedSinceTheLastRendering=true});for(const i of this._observers.values()){i.observe(t,e)}}detachDomRoot(t){const e=this.domRoots.get(t);Array.from(e.attributes).forEach(({name:t})=>e.removeAttribute(t));const i=this._initialDomRootAttributes.get(e);for(const t in i){e.setAttribute(t,i[t])}this.domRoots.delete(t);this.domConverter.unbindDomElement(e)}getDomRoot(t=\"main\"){return this.domRoots.get(t)}addObserver(t){let e=this._observers.get(t);if(e){return e}e=new t(this);this._observers.set(t,e);for(const[t,i]of this.domRoots){e.observe(i,t)}e.enable();return e}getObserver(t){return this._observers.get(t)}disableObservers(){for(const t of this._observers.values()){t.disable()}}enableObservers(){for(const t of this._observers.values()){t.enable()}}scrollToTheSelection(){const t=this.document.selection.getFirstRange();if(t){Ah({target:this.domConverter.viewRangeToDom(t),viewportOffset:20})}}focus(){if(!this.document.isFocused){const t=this.document.selection.editableElement;if(t){this.domConverter.focus(t);this.forceRender()}else{}}}change(t){if(this.isRenderingInProgress||this._postFixersInProgress){throw new ss[\"b\"](\"cannot-change-view-tree: \"+\"Attempting to make changes to the view when it is in an incorrect state: rendering or post-fixers are in progress. \"+\"This may cause some unexpected behavior and inconsistency between the DOM and the view.\",this)}try{if(this._ongoingChange){return t(this._writer)}this._ongoingChange=true;const e=t(this._writer);this._ongoingChange=false;if(!this._renderingDisabled&&this._hasChangedSinceTheLastRendering){this._postFixersInProgress=true;this.document._callPostFixers(this._writer);this._postFixersInProgress=false;this.fire(\"render\")}return e}catch(t){ss[\"b\"].rethrowUnexpectedError(t,this)}}forceRender(){this._hasChangedSinceTheLastRendering=true;this.change(()=>{})}destroy(){for(const t of this._observers.values()){t.destroy()}this.document.destroy();this.stopListening()}createPositionAt(t,e){return uc._createAt(t,e)}createPositionAfter(t){return uc._createAfter(t)}createPositionBefore(t){return uc._createBefore(t)}createRange(t,e){return new hc(t,e)}createRangeOn(t){return hc._createOn(t)}createRangeIn(t){return hc._createIn(t)}createSelection(t,e,i){return new gc(t,e,i)}_disableRendering(t){this._renderingDisabled=t;if(t==false){this.change(()=>{})}}_render(){this.isRenderingInProgress=true;this.disableObservers();this._renderer.render();this.enableObservers();this.isRenderingInProgress=false}}ys(Bh,Xl);class Vh{constructor(t){this.parent=null;this._attrs=Ws(t)}get index(){let t;if(!this.parent){return null}if((t=this.parent.getChildIndex(this))===null){throw new ss[\"b\"](\"model-node-not-found-in-parent: The node's parent does not contain this node.\",this)}return t}get startOffset(){let t;if(!this.parent){return null}if((t=this.parent.getChildStartOffset(this))===null){throw new ss[\"b\"](\"model-node-not-found-in-parent: The node's parent does not contain this node.\",this)}return t}get offsetSize(){return 1}get endOffset(){if(!this.parent){return null}return this.startOffset+this.offsetSize}get nextSibling(){const t=this.index;return t!==null&&this.parent.getChild(t+1)||null}get previousSibling(){const t=this.index;return t!==null&&this.parent.getChild(t-1)||null}get root(){let t=this;while(t.parent){t=t.parent}return t}isAttached(){return this.root.is(\"rootElement\")}getPath(){const t=[];let e=this;while(e.parent){t.unshift(e.startOffset);e=e.parent}return t}getAncestors(t={includeSelf:false,parentFirst:false}){const e=[];let i=t.includeSelf?this:this.parent;while(i){e[t.parentFirst?\"push\":\"unshift\"](i);i=i.parent}return e}getCommonAncestor(t,e={}){const i=this.getAncestors(e);const n=t.getAncestors(e);let o=0;while(i[o]==n[o]&&i[o]){o++}return o===0?null:i[o-1]}isBefore(t){if(this==t){return false}if(this.root!==t.root){return false}const e=this.getPath();const i=t.getPath();const n=Ns(e,i);switch(n){case\"prefix\":return true;case\"extension\":return false;default:return e[n]<i[n]}}isAfter(t){if(this==t){return false}if(this.root!==t.root){return false}return!this.isBefore(t)}hasAttribute(t){return this._attrs.has(t)}getAttribute(t){return this._attrs.get(t)}getAttributes(){return this._attrs.entries()}getAttributeKeys(){return this._attrs.keys()}toJSON(){const t={};if(this._attrs.size){t.attributes=Array.from(this._attrs).reduce((t,e)=>{t[e[0]]=e[1];return t},{})}return t}is(t){return t===\"node\"||t===\"model:node\"}_clone(){return new Vh(this._attrs)}_remove(){this.parent._removeChildren(this.index)}_setAttribute(t,e){this._attrs.set(t,e)}_setAttributesTo(t){this._attrs=Ws(t)}_removeAttribute(t){return this._attrs.delete(t)}_clearAttributes(){this._attrs.clear()}}class Dh extends Vh{constructor(t,e){super(e);this._data=t||\"\"}get offsetSize(){return this.data.length}get data(){return this._data}is(t){return t===\"text\"||t===\"model:text\"||t===\"node\"||t===\"model:node\"}toJSON(){const t=super.toJSON();t.data=this.data;return t}_clone(){return new Dh(this.data,this.getAttributes())}static fromJSON(t){return new Dh(t.data,t.attributes)}}class zh{constructor(t,e,i){this.textNode=t;if(e<0||e>t.offsetSize){throw new ss[\"b\"](\"model-textproxy-wrong-offsetintext: Given offsetInText value is incorrect.\",this)}if(i<0||e+i>t.offsetSize){throw new ss[\"b\"](\"model-textproxy-wrong-length: Given length value is incorrect.\",this)}this.data=t.data.substring(e,e+i);this.offsetInText=e}get startOffset(){return this.textNode.startOffset!==null?this.textNode.startOffset+this.offsetInText:null}get offsetSize(){return this.data.length}get endOffset(){return this.startOffset!==null?this.startOffset+this.offsetSize:null}get isPartial(){return this.offsetSize!==this.textNode.offsetSize}get parent(){return this.textNode.parent}get root(){return this.textNode.root}is(t){return t===\"textProxy\"||t===\"model:textProxy\"}getPath(){const t=this.textNode.getPath();if(t.length>0){t[t.length-1]+=this.offsetInText}return t}getAncestors(t={includeSelf:false,parentFirst:false}){const e=[];let i=t.includeSelf?this:this.parent;while(i){e[t.parentFirst?\"push\":\"unshift\"](i);i=i.parent}return e}hasAttribute(t){return this.textNode.hasAttribute(t)}getAttribute(t){return this.textNode.getAttribute(t)}getAttributes(){return this.textNode.getAttributes()}getAttributeKeys(){return this.textNode.getAttributeKeys()}}class Fh{constructor(t){this._nodes=[];if(t){this._insertNodes(0,t)}}[Symbol.iterator](){return this._nodes[Symbol.iterator]()}get length(){return this._nodes.length}get maxOffset(){return this._nodes.reduce((t,e)=>t+e.offsetSize,0)}getNode(t){return this._nodes[t]||null}getNodeIndex(t){const e=this._nodes.indexOf(t);return e==-1?null:e}getNodeStartOffset(t){const e=this.getNodeIndex(t);return e===null?null:this._nodes.slice(0,e).reduce((t,e)=>t+e.offsetSize,0)}indexToOffset(t){if(t==this._nodes.length){return this.maxOffset}const e=this._nodes[t];if(!e){throw new ss[\"b\"](\"model-nodelist-index-out-of-bounds: Given index cannot be found in the node list.\",this)}return this.getNodeStartOffset(e)}offsetToIndex(t){let e=0;for(const i of this._nodes){if(t>=e&&t<e+i.offsetSize){return this.getNodeIndex(i)}e+=i.offsetSize}if(e!=t){throw new ss[\"b\"](\"model-nodelist-offset-out-of-bounds: Given offset cannot be found in the node list.\",this,{offset:t,nodeList:this})}return this.length}_insertNodes(t,e){for(const t of e){if(!(t instanceof Vh)){throw new ss[\"b\"](\"model-nodelist-insertNodes-not-node: Trying to insert an object which is not a Node instance.\",this)}}this._nodes.splice(t,0,...e)}_removeNodes(t,e=1){return this._nodes.splice(t,e)}toJSON(){return this._nodes.map(t=>t.toJSON())}}class jh extends Vh{constructor(t,e,i){super(e);this.name=t;this._children=new Fh;if(i){this._insertChild(0,i)}}get childCount(){return this._children.length}get maxOffset(){return this._children.maxOffset}get isEmpty(){return this.childCount===0}is(t,e=null){if(!e){return t===\"element\"||t===\"model:element\"||t===this.name||t===\"model:\"+this.name||t===\"node\"||t===\"model:node\"}return e===this.name&&(t===\"element\"||t===\"model:element\")}getChild(t){return this._children.getNode(t)}getChildren(){return this._children[Symbol.iterator]()}getChildIndex(t){return this._children.getNodeIndex(t)}getChildStartOffset(t){return this._children.getNodeStartOffset(t)}offsetToIndex(t){return this._children.offsetToIndex(t)}getNodeByPath(t){let e=this;for(const i of t){e=e.getChild(e.offsetToIndex(i))}return e}toJSON(){const t=super.toJSON();t.name=this.name;if(this._children.length>0){t.children=[];for(const e of this._children){t.children.push(e.toJSON())}}return t}_clone(t=false){const e=t?Array.from(this._children).map(t=>t._clone(true)):null;return new jh(this.name,this.getAttributes(),e)}_appendChild(t){this._insertChild(this.childCount,t)}_insertChild(t,e){const i=Hh(e);for(const t of i){if(t.parent!==null){t._remove()}t.parent=this}this._children._insertNodes(t,i)}_removeChildren(t,e=1){const i=this._children._removeNodes(t,e);for(const t of i){t.parent=null}return i}static fromJSON(t){let e=null;if(t.children){e=[];for(const i of t.children){if(i.name){e.push(jh.fromJSON(i))}else{e.push(Dh.fromJSON(i))}}}return new jh(t.name,t.attributes,e)}}function Hh(t){if(typeof t==\"string\"){return[new Dh(t)]}if(!vs(t)){t=[t]}return Array.from(t).map(t=>{if(typeof t==\"string\"){return new Dh(t)}if(t instanceof zh){return new Dh(t.data,t.getAttributes())}return t})}class Wh{constructor(t={}){if(!t.boundaries&&!t.startPosition){throw new ss[\"b\"](\"model-tree-walker-no-start-position: Neither boundaries nor starting position have been defined.\",null)}const e=t.direction||\"forward\";if(e!=\"forward\"&&e!=\"backward\"){throw new ss[\"b\"](\"model-tree-walker-unknown-direction: Only `backward` and `forward` direction allowed.\",t,{direction:e})}this.direction=e;this.boundaries=t.boundaries||null;if(t.startPosition){this.position=t.startPosition.clone()}else{this.position=$h._createAt(this.boundaries[this.direction==\"backward\"?\"end\":\"start\"])}this.position.stickiness=\"toNone\";this.singleCharacters=!!t.singleCharacters;this.shallow=!!t.shallow;this.ignoreElementEnd=!!t.ignoreElementEnd;this._boundaryStartParent=this.boundaries?this.boundaries.start.parent:null;this._boundaryEndParent=this.boundaries?this.boundaries.end.parent:null;this._visitedParent=this.position.parent}[Symbol.iterator](){return this}skip(t){let e,i,n,o;do{n=this.position;o=this._visitedParent;({done:e,value:i}=this.next())}while(!e&&t(i));if(!e){this.position=n;this._visitedParent=o}}next(){if(this.direction==\"forward\"){return this._next()}else{return this._previous()}}_next(){const t=this.position;const e=this.position.clone();const i=this._visitedParent;if(i.parent===null&&e.offset===i.maxOffset){return{done:true}}if(i===this._boundaryEndParent&&e.offset==this.boundaries.end.offset){return{done:true}}const n=e.parent;const o=Uh(e,n);const r=o?o:Gh(e,n,o);if(r instanceof jh){if(!this.shallow){e.path.push(0);this._visitedParent=r}else{e.offset++}this.position=e;return qh(\"elementStart\",r,t,e,1)}else if(r instanceof Dh){let n;if(this.singleCharacters){n=1}else{let t=r.endOffset;if(this._boundaryEndParent==i&&this.boundaries.end.offset<t){t=this.boundaries.end.offset}n=t-e.offset}const o=e.offset-r.startOffset;const s=new zh(r,o,n);e.offset+=n;this.position=e;return qh(\"text\",s,t,e,n)}else{e.path.pop();e.offset++;this.position=e;this._visitedParent=i.parent;if(this.ignoreElementEnd){return this._next()}else{return qh(\"elementEnd\",i,t,e)}}}_previous(){const t=this.position;const e=this.position.clone();const i=this._visitedParent;if(i.parent===null&&e.offset===0){return{done:true}}if(i==this._boundaryStartParent&&e.offset==this.boundaries.start.offset){return{done:true}}const n=e.parent;const o=Uh(e,n);const r=o?o:Jh(e,n,o);if(r instanceof jh){e.offset--;if(!this.shallow){e.path.push(r.maxOffset);this.position=e;this._visitedParent=r;if(this.ignoreElementEnd){return this._previous()}else{return qh(\"elementEnd\",r,t,e)}}else{this.position=e;return qh(\"elementStart\",r,t,e,1)}}else if(r instanceof Dh){let n;if(this.singleCharacters){n=1}else{let t=r.startOffset;if(this._boundaryStartParent==i&&this.boundaries.start.offset>t){t=this.boundaries.start.offset}n=e.offset-t}const o=e.offset-r.startOffset;const s=new zh(r,o-n,n);e.offset-=n;this.position=e;return qh(\"text\",s,t,e,n)}else{e.path.pop();this.position=e;this._visitedParent=i.parent;return qh(\"elementStart\",i,t,e,1)}}}function qh(t,e,i,n,o){return{done:false,value:{type:t,item:e,previousPosition:i,nextPosition:n,length:o}}}class $h{constructor(t,e,i=\"toNone\"){if(!t.is(\"element\")&&!t.is(\"documentFragment\")){throw new ss[\"b\"](\"model-position-root-invalid: Position root invalid.\",t)}if(!(e instanceof Array)||e.length===0){throw new ss[\"b\"](\"model-position-path-incorrect-format: Position path must be an array with at least one item.\",t,{path:e})}if(t.is(\"rootElement\")){e=e.slice()}else{e=[...t.getPath(),...e];t=t.root}this.root=t;this.path=e;this.stickiness=i}get offset(){return this.path[this.path.length-1]}set offset(t){this.path[this.path.length-1]=t}get parent(){let t=this.root;for(let e=0;e<this.path.length-1;e++){t=t.getChild(t.offsetToIndex(this.path[e]));if(!t){throw new ss[\"b\"](\"model-position-path-incorrect: The position's path is incorrect.\",this,{position:this})}}if(t.is(\"text\")){throw new ss[\"b\"](\"model-position-path-incorrect: The position's path is incorrect.\",this,{position:this})}return t}get index(){return this.parent.offsetToIndex(this.offset)}get textNode(){return Uh(this,this.parent)}get nodeAfter(){const t=this.parent;return Gh(this,t,Uh(this,t))}get nodeBefore(){const t=this.parent;return Jh(this,t,Uh(this,t))}get isAtStart(){return this.offset===0}get isAtEnd(){return this.offset==this.parent.maxOffset}compareWith(t){if(this.root!=t.root){return\"different\"}const e=Ns(this.path,t.path);switch(e){case\"same\":return\"same\";case\"prefix\":return\"before\";case\"extension\":return\"after\";default:return this.path[e]<t.path[e]?\"before\":\"after\"}}getLastMatchingPosition(t,e={}){e.startPosition=this;const i=new Wh(e);i.skip(t);return i.position}getParentPath(){return this.path.slice(0,-1)}getAncestors(){const t=this.parent;if(t.is(\"documentFragment\")){return[t]}else{return t.getAncestors({includeSelf:true})}}getCommonPath(t){if(this.root!=t.root){return[]}const e=Ns(this.path,t.path);const i=typeof e==\"string\"?Math.min(this.path.length,t.path.length):e;return this.path.slice(0,i)}getCommonAncestor(t){const e=this.getAncestors();const i=t.getAncestors();let n=0;while(e[n]==i[n]&&e[n]){n++}return n===0?null:e[n-1]}getShiftedBy(t){const e=this.clone();const i=e.offset+t;e.offset=i<0?0:i;return e}isAfter(t){return this.compareWith(t)==\"after\"}isBefore(t){return this.compareWith(t)==\"before\"}isEqual(t){return this.compareWith(t)==\"same\"}isTouching(t){let e=null;let i=null;const n=this.compareWith(t);switch(n){case\"same\":return true;case\"before\":e=$h._createAt(this);i=$h._createAt(t);break;case\"after\":e=$h._createAt(t);i=$h._createAt(this);break;default:return false}let o=e.parent;while(e.path.length+i.path.length){if(e.isEqual(i)){return true}if(e.path.length>i.path.length){if(e.offset!==o.maxOffset){return false}e.path=e.path.slice(0,-1);o=o.parent;e.offset++}else{if(i.offset!==0){return false}i.path=i.path.slice(0,-1)}}}is(t){return t===\"position\"||t===\"model:position\"}hasSameParentAs(t){if(this.root!==t.root){return false}const e=this.getParentPath();const i=t.getParentPath();return Ns(e,i)==\"same\"}getTransformedByOperation(t){let e;switch(t.type){case\"insert\":e=this._getTransformedByInsertOperation(t);break;case\"move\":case\"remove\":case\"reinsert\":e=this._getTransformedByMoveOperation(t);break;case\"split\":e=this._getTransformedBySplitOperation(t);break;case\"merge\":e=this._getTransformedByMergeOperation(t);break;default:e=$h._createAt(this);break}return e}_getTransformedByInsertOperation(t){return this._getTransformedByInsertion(t.position,t.howMany)}_getTransformedByMoveOperation(t){return this._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany)}_getTransformedBySplitOperation(t){const e=t.movedRange;const i=e.containsPosition(this)||e.start.isEqual(this)&&this.stickiness==\"toNext\";if(i){return this._getCombined(t.splitPosition,t.moveTargetPosition)}else{if(t.graveyardPosition){return this._getTransformedByMove(t.graveyardPosition,t.insertionPosition,1)}else{return this._getTransformedByInsertion(t.insertionPosition,1)}}}_getTransformedByMergeOperation(t){const e=t.movedRange;const i=e.containsPosition(this)||e.start.isEqual(this);let n;if(i){n=this._getCombined(t.sourcePosition,t.targetPosition);if(t.sourcePosition.isBefore(t.targetPosition)){n=n._getTransformedByDeletion(t.deletionPosition,1)}}else if(this.isEqual(t.deletionPosition)){n=$h._createAt(t.deletionPosition)}else{n=this._getTransformedByMove(t.deletionPosition,t.graveyardPosition,1)}return n}_getTransformedByDeletion(t,e){const i=$h._createAt(this);if(this.root!=t.root){return i}if(Ns(t.getParentPath(),this.getParentPath())==\"same\"){if(t.offset<this.offset){if(t.offset+e>this.offset){return null}else{i.offset-=e}}}else if(Ns(t.getParentPath(),this.getParentPath())==\"prefix\"){const n=t.path.length-1;if(t.offset<=this.path[n]){if(t.offset+e>this.path[n]){return null}else{i.path[n]-=e}}}return i}_getTransformedByInsertion(t,e){const i=$h._createAt(this);if(this.root!=t.root){return i}if(Ns(t.getParentPath(),this.getParentPath())==\"same\"){if(t.offset<this.offset||t.offset==this.offset&&this.stickiness!=\"toPrevious\"){i.offset+=e}}else if(Ns(t.getParentPath(),this.getParentPath())==\"prefix\"){const n=t.path.length-1;if(t.offset<=this.path[n]){i.path[n]+=e}}return i}_getTransformedByMove(t,e,i){e=e._getTransformedByDeletion(t,i);if(t.isEqual(e)){return $h._createAt(this)}const n=this._getTransformedByDeletion(t,i);const o=n===null||t.isEqual(this)&&this.stickiness==\"toNext\"||t.getShiftedBy(i).isEqual(this)&&this.stickiness==\"toPrevious\";if(o){return this._getCombined(t,e)}else{return n._getTransformedByInsertion(e,i)}}_getCombined(t,e){const i=t.path.length-1;const n=$h._createAt(e);n.stickiness=this.stickiness;n.offset=n.offset+this.path[i]-t.offset;n.path=[...n.path,...this.path.slice(i+1)];return n}toJSON(){return{root:this.root.toJSON(),path:Array.from(this.path),stickiness:this.stickiness}}clone(){return new this.constructor(this.root,this.path,this.stickiness)}static _createAt(t,e,i=\"toNone\"){if(t instanceof $h){return new $h(t.root,t.path,t.stickiness)}else{const n=t;if(e==\"end\"){e=n.maxOffset}else if(e==\"before\"){return this._createBefore(n,i)}else if(e==\"after\"){return this._createAfter(n,i)}else if(e!==0&&!e){throw new ss[\"b\"](\"model-createPositionAt-offset-required: \"+\"Model#createPositionAt() requires the offset when the first parameter is a model item.\",[this,t])}if(!n.is(\"element\")&&!n.is(\"documentFragment\")){throw new ss[\"b\"](\"model-position-parent-incorrect: Position parent have to be a element or document fragment.\",[this,t])}const o=n.getPath();o.push(e);return new this(n.root,o,i)}}static _createAfter(t,e){if(!t.parent){throw new ss[\"b\"](\"model-position-after-root: You cannot make a position after root.\",[this,t],{root:t})}return this._createAt(t.parent,t.endOffset,e)}static _createBefore(t,e){if(!t.parent){throw new ss[\"b\"](\"model-position-before-root: You cannot make a position before root.\",t,{root:t})}return this._createAt(t.parent,t.startOffset,e)}static fromJSON(t,e){if(t.root===\"$graveyard\"){const i=new $h(e.graveyard,t.path);i.stickiness=t.stickiness;return i}if(!e.getRoot(t.root)){throw new ss[\"b\"](\"model-position-fromjson-no-root: Cannot create position for document. Root with specified name does not exist.\",e,{rootName:t.root})}return new $h(e.getRoot(t.root),t.path,t.stickiness)}}function Uh(t,e){const i=e.getChild(e.offsetToIndex(t.offset));if(i&&i.is(\"text\")&&i.startOffset<t.offset){return i}return null}function Gh(t,e,i){if(i!==null){return null}return e.getChild(e.offsetToIndex(t.offset))}function Jh(t,e,i){if(i!==null){return null}return e.getChild(e.offsetToIndex(t.offset)-1)}class Kh{constructor(t,e=null){this.start=$h._createAt(t);this.end=e?$h._createAt(e):$h._createAt(t);this.start.stickiness=this.isCollapsed?\"toNone\":\"toNext\";this.end.stickiness=this.isCollapsed?\"toNone\":\"toPrevious\"}*[Symbol.iterator](){yield*new Wh({boundaries:this,ignoreElementEnd:true})}get isCollapsed(){return this.start.isEqual(this.end)}get isFlat(){const t=this.start.getParentPath();const e=this.end.getParentPath();return Ns(t,e)==\"same\"}get root(){return this.start.root}containsPosition(t){return t.isAfter(this.start)&&t.isBefore(this.end)}containsRange(t,e=false){if(t.isCollapsed){e=false}const i=this.containsPosition(t.start)||e&&this.start.isEqual(t.start);const n=this.containsPosition(t.end)||e&&this.end.isEqual(t.end);return i&&n}containsItem(t){const e=$h._createBefore(t);return this.containsPosition(e)||this.start.isEqual(e)}is(t){return t===\"range\"||t===\"model:range\"}isEqual(t){return this.start.isEqual(t.start)&&this.end.isEqual(t.end)}isIntersecting(t){return this.start.isBefore(t.end)&&this.end.isAfter(t.start)}getDifference(t){const e=[];if(this.isIntersecting(t)){if(this.containsPosition(t.start)){e.push(new Kh(this.start,t.start))}if(this.containsPosition(t.end)){e.push(new Kh(t.end,this.end))}}else{e.push(new Kh(this.start,this.end))}return e}getIntersection(t){if(this.isIntersecting(t)){let e=this.start;let i=this.end;if(this.containsPosition(t.start)){e=t.start}if(this.containsPosition(t.end)){i=t.end}return new Kh(e,i)}return null}getMinimalFlatRanges(){const t=[];const e=this.start.getCommonPath(this.end).length;const i=$h._createAt(this.start);let n=i.parent;while(i.path.length>e+1){const e=n.maxOffset-i.offset;if(e!==0){t.push(new Kh(i,i.getShiftedBy(e)))}i.path=i.path.slice(0,-1);i.offset++;n=n.parent}while(i.path.length<=this.end.path.length){const e=this.end.path[i.path.length-1];const n=e-i.offset;if(n!==0){t.push(new Kh(i,i.getShiftedBy(n)))}i.offset=e;i.path.push(0)}return t}getWalker(t={}){t.boundaries=this;return new Wh(t)}*getItems(t={}){t.boundaries=this;t.ignoreElementEnd=true;const e=new Wh(t);for(const t of e){yield t.item}}*getPositions(t={}){t.boundaries=this;const e=new Wh(t);yield e.position;for(const t of e){yield t.nextPosition}}getTransformedByOperation(t){switch(t.type){case\"insert\":return this._getTransformedByInsertOperation(t);case\"move\":case\"remove\":case\"reinsert\":return this._getTransformedByMoveOperation(t);case\"split\":return[this._getTransformedBySplitOperation(t)];case\"merge\":return[this._getTransformedByMergeOperation(t)]}return[new Kh(this.start,this.end)]}getTransformedByOperations(t){const e=[new Kh(this.start,this.end)];for(const i of t){for(let t=0;t<e.length;t++){const n=e[t].getTransformedByOperation(i);e.splice(t,1,...n);t+=n.length-1}}for(let t=0;t<e.length;t++){const i=e[t];for(let n=t+1;n<e.length;n++){const t=e[n];if(i.containsRange(t)||t.containsRange(i)||i.isEqual(t)){e.splice(n,1)}}}return e}getCommonAncestor(){return this.start.getCommonAncestor(this.end)}getContainedElement(){if(this.isCollapsed){return null}const t=this.start.nodeAfter;const e=this.end.nodeBefore;if(t&&t.is(\"element\")&&t===e){return t}return null}toJSON(){return{start:this.start.toJSON(),end:this.end.toJSON()}}clone(){return new this.constructor(this.start,this.end)}_getTransformedByInsertOperation(t,e=false){return this._getTransformedByInsertion(t.position,t.howMany,e)}_getTransformedByMoveOperation(t,e=false){const i=t.sourcePosition;const n=t.howMany;const o=t.targetPosition;return this._getTransformedByMove(i,o,n,e)}_getTransformedBySplitOperation(t){const e=this.start._getTransformedBySplitOperation(t);let i=this.end._getTransformedBySplitOperation(t);if(this.end.isEqual(t.insertionPosition)){i=this.end.getShiftedBy(1)}if(e.root!=i.root){i=this.end.getShiftedBy(-1)}return new Kh(e,i)}_getTransformedByMergeOperation(t){if(this.start.isEqual(t.targetPosition)&&this.end.isEqual(t.deletionPosition)){return new Kh(this.start)}let e=this.start._getTransformedByMergeOperation(t);let i=this.end._getTransformedByMergeOperation(t);if(e.root!=i.root){i=this.end.getShiftedBy(-1)}if(e.isAfter(i)){if(t.sourcePosition.isBefore(t.targetPosition)){e=$h._createAt(i);e.offset=0}else{if(!t.deletionPosition.isEqual(e)){i=t.deletionPosition}e=t.targetPosition}return new Kh(e,i)}return new Kh(e,i)}_getTransformedByInsertion(t,e,i=false){if(i&&this.containsPosition(t)){return[new Kh(this.start,t),new Kh(t.getShiftedBy(e),this.end._getTransformedByInsertion(t,e))]}else{const i=new Kh(this.start,this.end);i.start=i.start._getTransformedByInsertion(t,e);i.end=i.end._getTransformedByInsertion(t,e);return[i]}}_getTransformedByMove(t,e,i,n=false){if(this.isCollapsed){const n=this.start._getTransformedByMove(t,e,i);return[new Kh(n)]}const o=Kh._createFromPositionAndShift(t,i);const r=e._getTransformedByDeletion(t,i);if(this.containsPosition(e)&&!n){if(o.containsPosition(this.start)||o.containsPosition(this.end)){const n=this.start._getTransformedByMove(t,e,i);const o=this.end._getTransformedByMove(t,e,i);return[new Kh(n,o)]}}let s;const a=this.getDifference(o);let l=null;const c=this.getIntersection(o);if(a.length==1){l=new Kh(a[0].start._getTransformedByDeletion(t,i),a[0].end._getTransformedByDeletion(t,i))}else if(a.length==2){l=new Kh(this.start,this.end._getTransformedByDeletion(t,i))}if(l){s=l._getTransformedByInsertion(r,i,c!==null||n)}else{s=[]}if(c){const t=new Kh(c.start._getCombined(o.start,r),c.end._getCombined(o.start,r));if(s.length==2){s.splice(1,0,t)}else{s.push(t)}}return s}_getTransformedByDeletion(t,e){let i=this.start._getTransformedByDeletion(t,e);let n=this.end._getTransformedByDeletion(t,e);if(i==null&&n==null){return null}if(i==null){i=t}if(n==null){n=t}return new Kh(i,n)}static _createFromPositionAndShift(t,e){const i=t;const n=t.getShiftedBy(e);return e>0?new this(i,n):new this(n,i)}static _createIn(t){return new this($h._createAt(t,0),$h._createAt(t,t.maxOffset))}static _createOn(t){return this._createFromPositionAndShift($h._createBefore(t),t.offsetSize)}static _createFromRanges(t){if(t.length===0){throw new ss[\"b\"](\"range-create-from-ranges-empty-array: At least one range has to be passed.\",null)}else if(t.length==1){return t[0].clone()}const e=t[0];t.sort((t,e)=>t.start.isAfter(e.start)?1:-1);const i=t.indexOf(e);const n=new this(e.start,e.end);if(i>0){for(let e=i-1;true;e++){if(t[e].end.isEqual(n.start)){n.start=$h._createAt(t[e].start)}else{break}}}for(let e=i+1;e<t.length;e++){if(t[e].start.isEqual(n.end)){n.end=$h._createAt(t[e].end)}else{break}}return n}static fromJSON(t,e){return new this($h.fromJSON(t.start,e),$h.fromJSON(t.end,e))}}class Xh{constructor(){this._modelToViewMapping=new WeakMap;this._viewToModelMapping=new WeakMap;this._viewToModelLengthCallbacks=new Map;this._markerNameToElements=new Map;this._elementToMarkerNames=new Map;this._unboundMarkerNames=new Set;this.on(\"modelToViewPosition\",(t,e)=>{if(e.viewPosition){return}const i=this._modelToViewMapping.get(e.modelPosition.parent);e.viewPosition=this._findPositionIn(i,e.modelPosition.offset)},{priority:\"low\"});this.on(\"viewToModelPosition\",(t,e)=>{if(e.modelPosition){return}const i=this.findMappedViewAncestor(e.viewPosition);const n=this._viewToModelMapping.get(i);const o=this._toModelOffset(e.viewPosition.parent,e.viewPosition.offset,i);e.modelPosition=$h._createAt(n,o)},{priority:\"low\"})}bindElements(t,e){this._modelToViewMapping.set(t,e);this._viewToModelMapping.set(e,t)}unbindViewElement(t){const e=this.toModelElement(t);this._viewToModelMapping.delete(t);if(this._elementToMarkerNames.has(t)){for(const e of this._elementToMarkerNames.get(t)){this._unboundMarkerNames.add(e)}}if(this._modelToViewMapping.get(e)==t){this._modelToViewMapping.delete(e)}}unbindModelElement(t){const e=this.toViewElement(t);this._modelToViewMapping.delete(t);if(this._viewToModelMapping.get(e)==t){this._viewToModelMapping.delete(e)}}bindElementToMarker(t,e){const i=this._markerNameToElements.get(e)||new Set;i.add(t);const n=this._elementToMarkerNames.get(t)||new Set;n.add(e);this._markerNameToElements.set(e,i);this._elementToMarkerNames.set(t,n)}unbindElementFromMarkerName(t,e){const i=this._markerNameToElements.get(e);if(i){i.delete(t);if(i.size==0){this._markerNameToElements.delete(e)}}const n=this._elementToMarkerNames.get(t);if(n){n.delete(e);if(n.size==0){this._elementToMarkerNames.delete(t)}}}flushUnboundMarkerNames(){const t=Array.from(this._unboundMarkerNames);this._unboundMarkerNames.clear();return t}clearBindings(){this._modelToViewMapping=new WeakMap;this._viewToModelMapping=new WeakMap;this._markerNameToElements=new Map;this._elementToMarkerNames=new Map;this._unboundMarkerNames=new Set}toModelElement(t){return this._viewToModelMapping.get(t)}toViewElement(t){return this._modelToViewMapping.get(t)}toModelRange(t){return new Kh(this.toModelPosition(t.start),this.toModelPosition(t.end))}toViewRange(t){return new hc(this.toViewPosition(t.start),this.toViewPosition(t.end))}toModelPosition(t){const e={viewPosition:t,mapper:this};this.fire(\"viewToModelPosition\",e);return e.modelPosition}toViewPosition(t,e={isPhantom:false}){const i={modelPosition:t,mapper:this,isPhantom:e.isPhantom};this.fire(\"modelToViewPosition\",i);return i.viewPosition}markerNameToElements(t){const e=this._markerNameToElements.get(t);if(!e){return null}const i=new Set;for(const t of e){if(t.is(\"attributeElement\")){for(const e of t.getElementsWithSameId()){i.add(e)}}else{i.add(t)}}return i}registerViewToModelLength(t,e){this._viewToModelLengthCallbacks.set(t,e)}findMappedViewAncestor(t){let e=t.parent;while(!this._viewToModelMapping.has(e)){e=e.parent}return e}_toModelOffset(t,e,i){if(i!=t){const n=this._toModelOffset(t.parent,t.index,i);const o=this._toModelOffset(t,e,t);return n+o}if(t.is(\"text\")){return e}let n=0;for(let i=0;i<e;i++){n+=this.getModelLength(t.getChild(i))}return n}getModelLength(t){if(this._viewToModelLengthCallbacks.get(t.name)){const e=this._viewToModelLengthCallbacks.get(t.name);return e(t)}else if(this._viewToModelMapping.has(t)){return 1}else if(t.is(\"text\")){return t.data.length}else if(t.is(\"uiElement\")){return 0}else{let e=0;for(const i of t.getChildren()){e+=this.getModelLength(i)}return e}}_findPositionIn(t,e){let i;let n=0;let o=0;let r=0;if(t.is(\"text\")){return new uc(t,e)}while(o<e){i=t.getChild(r);n=this.getModelLength(i);o+=n;r++}if(o==e){return this._moveViewPositionToTextNode(new uc(t,r))}else{return this._findPositionIn(i,e-(o-n))}}_moveViewPositionToTextNode(t){const e=t.nodeBefore;const i=t.nodeAfter;if(e instanceof Fs){return new uc(e,e.data.length)}else if(i instanceof Fs){return new uc(i,0)}return t}}ys(Xh,ds);class Yh{constructor(){this._consumable=new Map;this._textProxyRegistry=new Map}add(t,e){e=Qh(e);if(t instanceof zh){t=this._getSymbolForTextProxy(t)}if(!this._consumable.has(t)){this._consumable.set(t,new Map)}this._consumable.get(t).set(e,true)}consume(t,e){e=Qh(e);if(t instanceof zh){t=this._getSymbolForTextProxy(t)}if(this.test(t,e)){this._consumable.get(t).set(e,false);return true}else{return false}}test(t,e){e=Qh(e);if(t instanceof zh){t=this._getSymbolForTextProxy(t)}const i=this._consumable.get(t);if(i===undefined){return null}const n=i.get(e);if(n===undefined){return null}return n}revert(t,e){e=Qh(e);if(t instanceof zh){t=this._getSymbolForTextProxy(t)}const i=this.test(t,e);if(i===false){this._consumable.get(t).set(e,true);return true}else if(i===true){return false}return null}_getSymbolForTextProxy(t){let e=null;const i=this._textProxyRegistry.get(t.startOffset);if(i){const n=i.get(t.endOffset);if(n){e=n.get(t.parent)}}if(!e){e=this._addSymbolForTextProxy(t.startOffset,t.endOffset,t.parent)}return e}_addSymbolForTextProxy(t,e,i){const n=Symbol(\"textProxySymbol\");let o,r;o=this._textProxyRegistry.get(t);if(!o){o=new Map;this._textProxyRegistry.set(t,o)}r=o.get(e);if(!r){r=new Map;o.set(e,r)}r.set(i,n);return n}}function Qh(t){const e=t.split(\":\");return e.length>1?e[0]+\":\"+e[1]:e[0]}class Zh{constructor(t){this.conversionApi=$l({dispatcher:this},t)}convertChanges(t,e,i){for(const e of t.getMarkersToRemove()){this.convertMarkerRemove(e.name,e.range,i)}for(const e of t.getChanges()){if(e.type==\"insert\"){this.convertInsert(Kh._createFromPositionAndShift(e.position,e.length),i)}else if(e.type==\"remove\"){this.convertRemove(e.position,e.length,e.name,i)}else{this.convertAttribute(e.range,e.attributeKey,e.attributeOldValue,e.attributeNewValue,i)}}for(const t of this.conversionApi.mapper.flushUnboundMarkerNames()){const n=e.get(t).getRange();this.convertMarkerRemove(t,n,i);this.convertMarkerAdd(t,n,i)}for(const e of t.getMarkersToAdd()){this.convertMarkerAdd(e.name,e.range,i)}}convertInsert(t,e){this.conversionApi.writer=e;this.conversionApi.consumable=this._createInsertConsumable(t);for(const e of t){const t=e.item;const i=Kh._createFromPositionAndShift(e.previousPosition,e.length);const n={item:t,range:i};this._testAndFire(\"insert\",n);for(const e of t.getAttributeKeys()){n.attributeKey=e;n.attributeOldValue=null;n.attributeNewValue=t.getAttribute(e);this._testAndFire(`attribute:${e}`,n)}}this._clearConversionApi()}convertRemove(t,e,i,n){this.conversionApi.writer=n;this.fire(\"remove:\"+i,{position:t,length:e},this.conversionApi);this._clearConversionApi()}convertAttribute(t,e,i,n,o){this.conversionApi.writer=o;this.conversionApi.consumable=this._createConsumableForRange(t,`attribute:${e}`);for(const o of t){const t=o.item;const r=Kh._createFromPositionAndShift(o.previousPosition,o.length);const s={item:t,range:r,attributeKey:e,attributeOldValue:i,attributeNewValue:n};this._testAndFire(`attribute:${e}`,s)}this._clearConversionApi()}convertSelection(t,e,i){const n=Array.from(e.getMarkersAtPosition(t.getFirstPosition()));this.conversionApi.writer=i;this.conversionApi.consumable=this._createSelectionConsumable(t,n);this.fire(\"selection\",{selection:t},this.conversionApi);if(!t.isCollapsed){return}for(const e of n){const i=e.getRange();if(!tf(t.getFirstPosition(),e,this.conversionApi.mapper)){continue}const n={item:t,markerName:e.name,markerRange:i};if(this.conversionApi.consumable.test(t,\"addMarker:\"+e.name)){this.fire(\"addMarker:\"+e.name,n,this.conversionApi)}}for(const e of t.getAttributeKeys()){const i={item:t,range:t.getFirstRange(),attributeKey:e,attributeOldValue:null,attributeNewValue:t.getAttribute(e)};if(this.conversionApi.consumable.test(t,\"attribute:\"+i.attributeKey)){this.fire(\"attribute:\"+i.attributeKey+\":$text\",i,this.conversionApi)}}this._clearConversionApi()}convertMarkerAdd(t,e,i){if(!e.root.document||e.root.rootName==\"$graveyard\"){return}this.conversionApi.writer=i;const n=\"addMarker:\"+t;const o=new Yh;o.add(e,n);this.conversionApi.consumable=o;this.fire(n,{markerName:t,markerRange:e},this.conversionApi);if(!o.test(e,n)){return}this.conversionApi.consumable=this._createConsumableForRange(e,n);for(const i of e.getItems()){if(!this.conversionApi.consumable.test(i,n)){continue}const o={item:i,range:Kh._createOn(i),markerName:t,markerRange:e};this.fire(n,o,this.conversionApi)}this._clearConversionApi()}convertMarkerRemove(t,e,i){if(!e.root.document||e.root.rootName==\"$graveyard\"){return}this.conversionApi.writer=i;this.fire(\"removeMarker:\"+t,{markerName:t,markerRange:e},this.conversionApi);this._clearConversionApi()}_createInsertConsumable(t){const e=new Yh;for(const i of t){const t=i.item;e.add(t,\"insert\");for(const i of t.getAttributeKeys()){e.add(t,\"attribute:\"+i)}}return e}_createConsumableForRange(t,e){const i=new Yh;for(const n of t.getItems()){i.add(n,e)}return i}_createSelectionConsumable(t,e){const i=new Yh;i.add(t,\"selection\");for(const n of e){i.add(t,\"addMarker:\"+n.name)}for(const e of t.getAttributeKeys()){i.add(t,\"attribute:\"+e)}return i}_testAndFire(t,e){if(!this.conversionApi.consumable.test(e.item,t)){return}const i=e.item.name||\"$text\";this.fire(t+\":\"+i,e,this.conversionApi)}_clearConversionApi(){delete this.conversionApi.writer;delete this.conversionApi.consumable}}ys(Zh,ds);function tf(t,e,i){const n=e.getRange();const o=Array.from(t.getAncestors());o.shift();o.reverse();const r=o.some(t=>{if(n.containsItem(t)){const e=i.toViewElement(t);return!!e.getCustomProperty(\"addHighlight\")}});return!r}class ef{constructor(t,e,i){this._lastRangeBackward=false;this._ranges=[];this._attrs=new Map;if(t){this.setTo(t,e,i)}}get anchor(){if(this._ranges.length>0){const t=this._ranges[this._ranges.length-1];return this._lastRangeBackward?t.end:t.start}return null}get focus(){if(this._ranges.length>0){const t=this._ranges[this._ranges.length-1];return this._lastRangeBackward?t.start:t.end}return null}get isCollapsed(){const t=this._ranges.length;if(t===1){return this._ranges[0].isCollapsed}else{return false}}get rangeCount(){return this._ranges.length}get isBackward(){return!this.isCollapsed&&this._lastRangeBackward}isEqual(t){if(this.rangeCount!=t.rangeCount){return false}else if(this.rangeCount===0){return true}if(!this.anchor.isEqual(t.anchor)||!this.focus.isEqual(t.focus)){return false}for(const e of this._ranges){let i=false;for(const n of t._ranges){if(e.isEqual(n)){i=true;break}}if(!i){return false}}return true}*getRanges(){for(const t of this._ranges){yield new Kh(t.start,t.end)}}getFirstRange(){let t=null;for(const e of this._ranges){if(!t||e.start.isBefore(t.start)){t=e}}return t?new Kh(t.start,t.end):null}getLastRange(){let t=null;for(const e of this._ranges){if(!t||e.end.isAfter(t.end)){t=e}}return t?new Kh(t.start,t.end):null}getFirstPosition(){const t=this.getFirstRange();return t?t.start.clone():null}getLastPosition(){const t=this.getLastRange();return t?t.end.clone():null}setTo(t,e,i){if(t===null){this._setRanges([])}else if(t instanceof ef){this._setRanges(t.getRanges(),t.isBackward)}else if(t&&typeof t.getRanges==\"function\"){this._setRanges(t.getRanges(),t.isBackward)}else if(t instanceof Kh){this._setRanges([t],!!e&&!!e.backward)}else if(t instanceof $h){this._setRanges([new Kh(t)])}else if(t instanceof Vh){const n=!!i&&!!i.backward;let o;if(e==\"in\"){o=Kh._createIn(t)}else if(e==\"on\"){o=Kh._createOn(t)}else if(e!==undefined){o=new Kh($h._createAt(t,e))}else{throw new ss[\"b\"](\"model-selection-setTo-required-second-parameter: \"+\"selection.setTo requires the second parameter when the first parameter is a node.\",[this,t])}this._setRanges([o],n)}else if(vs(t)){this._setRanges(t,e&&!!e.backward)}else{throw new ss[\"b\"](\"model-selection-setTo-not-selectable: Cannot set the selection to the given place.\",[this,t])}}_setRanges(t,e=false){t=Array.from(t);const i=t.some(e=>{if(!(e instanceof Kh)){throw new ss[\"b\"](\"model-selection-set-ranges-not-range: \"+\"Selection range set to an object that is not an instance of model.Range.\",[this,t])}return this._ranges.every(t=>!t.isEqual(e))});if(t.length===this._ranges.length&&!i){return}this._removeAllRanges();for(const e of t){this._pushRange(e)}this._lastRangeBackward=!!e;this.fire(\"change:range\",{directChange:true})}setFocus(t,e){if(this.anchor===null){throw new ss[\"b\"](\"model-selection-setFocus-no-ranges: Cannot set selection focus if there are no ranges in selection.\",[this,t])}const i=$h._createAt(t,e);if(i.compareWith(this.focus)==\"same\"){return}const n=this.anchor;if(this._ranges.length){this._popRange()}if(i.compareWith(n)==\"before\"){this._pushRange(new Kh(i,n));this._lastRangeBackward=true}else{this._pushRange(new Kh(n,i));this._lastRangeBackward=false}this.fire(\"change:range\",{directChange:true})}getAttribute(t){return this._attrs.get(t)}getAttributes(){return this._attrs.entries()}getAttributeKeys(){return this._attrs.keys()}hasAttribute(t){return this._attrs.has(t)}removeAttribute(t){if(this.hasAttribute(t)){this._attrs.delete(t);this.fire(\"change:attribute\",{attributeKeys:[t],directChange:true})}}setAttribute(t,e){if(this.getAttribute(t)!==e){this._attrs.set(t,e);this.fire(\"change:attribute\",{attributeKeys:[t],directChange:true})}}getSelectedElement(){if(this.rangeCount!==1){return null}return this.getFirstRange().getContainedElement()}is(t){return t===\"selection\"||t===\"model:selection\"}*getSelectedBlocks(){const t=new WeakSet;for(const e of this.getRanges()){const i=rf(e.start,t);if(i&&sf(i,e)){yield i}for(const i of e.getWalker()){const n=i.item;if(i.type==\"elementEnd\"&&of(n,t,e)){yield n}}const n=rf(e.end,t);if(n&&!e.end.isTouching($h._createAt(n,0))&&sf(n,e)){yield n}}}containsEntireContent(t=this.anchor.root){const e=$h._createAt(t,0);const i=$h._createAt(t,\"end\");return e.isTouching(this.getFirstPosition())&&i.isTouching(this.getLastPosition())}_pushRange(t){this._checkRange(t);this._ranges.push(new Kh(t.start,t.end))}_checkRange(t){for(let e=0;e<this._ranges.length;e++){if(t.isIntersecting(this._ranges[e])){throw new ss[\"b\"](\"model-selection-range-intersects: Trying to add a range that intersects with another range in the selection.\",[this,t],{addedRange:t,intersectingRange:this._ranges[e]})}}}_removeAllRanges(){while(this._ranges.length>0){this._popRange()}}_popRange(){this._ranges.pop()}}ys(ef,ds);function nf(t,e){if(e.has(t)){return false}e.add(t);return t.root.document.model.schema.isBlock(t)&&t.parent}function of(t,e,i){return nf(t,e)&&sf(t,i)}function rf(t,e){const i=t.parent;const n=i.root.document.model.schema;const o=t.parent.getAncestors({parentFirst:true,includeSelf:true});let r=false;const s=o.find(t=>{if(r){return false}r=n.isLimit(t);return!r&&nf(t,e)});o.forEach(t=>e.add(t));return s}function sf(t,e){const i=af(t);if(!i){return true}const n=e.containsRange(Kh._createOn(i),true);return!n}function af(t){const e=t.root.document.model.schema;let i=t.parent;while(i){if(e.isBlock(i)){return i}i=i.parent}}class lf extends Kh{constructor(t,e){super(t,e);cf.call(this)}detach(){this.stopListening()}is(t){return t===\"liveRange\"||t===\"model:liveRange\"||t==\"range\"||t===\"model:range\"}toRange(){return new Kh(this.start,this.end)}static fromRange(t){return new lf(t.start,t.end)}}function cf(){this.listenTo(this.root.document.model,\"applyOperation\",(t,e)=>{const i=e[0];if(!i.isDocumentOperation){return}df.call(this,i)},{priority:\"low\"})}function df(t){const e=this.getTransformedByOperation(t);const i=Kh._createFromRanges(e);const n=!i.isEqual(this);const o=uf(this,t);let r=null;if(n){if(i.root.rootName==\"$graveyard\"){if(t.type==\"remove\"){r=t.sourcePosition}else{r=t.deletionPosition}}const e=this.toRange();this.start=i.start;this.end=i.end;this.fire(\"change:range\",e,{deletionPosition:r})}else if(o){this.fire(\"change:content\",this.toRange(),{deletionPosition:r})}}function uf(t,e){switch(e.type){case\"insert\":return t.containsPosition(e.position);case\"move\":case\"remove\":case\"reinsert\":case\"merge\":return t.containsPosition(e.sourcePosition)||t.start.isEqual(e.sourcePosition)||t.containsPosition(e.targetPosition);case\"split\":return t.containsPosition(e.splitPosition)||t.containsPosition(e.insertionPosition)}return false}ys(lf,ds);const hf=\"selection:\";class ff{constructor(t){this._selection=new mf(t);this._selection.delegate(\"change:range\").to(this);this._selection.delegate(\"change:attribute\").to(this);this._selection.delegate(\"change:marker\").to(this)}get isCollapsed(){return this._selection.isCollapsed}get anchor(){return this._selection.anchor}get focus(){return this._selection.focus}get rangeCount(){return this._selection.rangeCount}get hasOwnRange(){return this._selection.hasOwnRange}get isBackward(){return this._selection.isBackward}get isGravityOverridden(){return this._selection.isGravityOverridden}get markers(){return this._selection.markers}get _ranges(){return this._selection._ranges}getRanges(){return this._selection.getRanges()}getFirstPosition(){return this._selection.getFirstPosition()}getLastPosition(){return this._selection.getLastPosition()}getFirstRange(){return this._selection.getFirstRange()}getLastRange(){return this._selection.getLastRange()}getSelectedBlocks(){return this._selection.getSelectedBlocks()}getSelectedElement(){return this._selection.getSelectedElement()}containsEntireContent(t){return this._selection.containsEntireContent(t)}destroy(){this._selection.destroy()}getAttributeKeys(){return this._selection.getAttributeKeys()}getAttributes(){return this._selection.getAttributes()}getAttribute(t){return this._selection.getAttribute(t)}hasAttribute(t){return this._selection.hasAttribute(t)}refresh(){this._selection._updateMarkers();this._selection._updateAttributes(false)}is(t){return t===\"selection\"||t==\"model:selection\"||t==\"documentSelection\"||t==\"model:documentSelection\"}_setFocus(t,e){this._selection.setFocus(t,e)}_setTo(t,e,i){this._selection.setTo(t,e,i)}_setAttribute(t,e){this._selection.setAttribute(t,e)}_removeAttribute(t){this._selection.removeAttribute(t)}_getStoredAttributes(){return this._selection._getStoredAttributes()}_overrideGravity(){return this._selection.overrideGravity()}_restoreGravity(t){this._selection.restoreGravity(t)}static _getStoreAttributeKey(t){return hf+t}static _isStoreAttributeKey(t){return t.startsWith(hf)}}ys(ff,ds);class mf extends ef{constructor(t){super();this.markers=new xs({idProperty:\"name\"});this._model=t.model;this._document=t;this._attributePriority=new Map;this._fixGraveyardRangesData=[];this._hasChangedRange=false;this._overriddenGravityRegister=new Set;this.listenTo(this._model,\"applyOperation\",(t,e)=>{const i=e[0];if(!i.isDocumentOperation||i.type==\"marker\"||i.type==\"rename\"||i.type==\"noop\"){return}while(this._fixGraveyardRangesData.length){const{liveRange:t,sourcePosition:e}=this._fixGraveyardRangesData.shift();this._fixGraveyardSelection(t,e)}if(this._hasChangedRange){this._hasChangedRange=false;this.fire(\"change:range\",{directChange:false})}},{priority:\"lowest\"});this.on(\"change:range\",()=>{for(const t of this.getRanges()){if(!this._document._validateSelectionRange(t)){throw new ss[\"b\"](\"document-selection-wrong-position: Range from document selection starts or ends at incorrect position.\",this,{range:t})}}});this.listenTo(this._model.markers,\"update\",()=>this._updateMarkers());this.listenTo(this._document,\"change\",(t,e)=>{pf(this._model,e)})}get isCollapsed(){const t=this._ranges.length;return t===0?this._document._getDefaultRange().isCollapsed:super.isCollapsed}get anchor(){return super.anchor||this._document._getDefaultRange().start}get focus(){return super.focus||this._document._getDefaultRange().end}get rangeCount(){return this._ranges.length?this._ranges.length:1}get hasOwnRange(){return this._ranges.length>0}get isGravityOverridden(){return!!this._overriddenGravityRegister.size}destroy(){for(let t=0;t<this._ranges.length;t++){this._ranges[t].detach()}this.stopListening()}*getRanges(){if(this._ranges.length){yield*super.getRanges()}else{yield this._document._getDefaultRange()}}getFirstRange(){return super.getFirstRange()||this._document._getDefaultRange()}getLastRange(){return super.getLastRange()||this._document._getDefaultRange()}setTo(t,e,i){super.setTo(t,e,i);this._updateAttributes(true);this._updateMarkers()}setFocus(t,e){super.setFocus(t,e);this._updateAttributes(true);this._updateMarkers()}setAttribute(t,e){if(this._setAttribute(t,e)){const e=[t];this.fire(\"change:attribute\",{attributeKeys:e,directChange:true})}}removeAttribute(t){if(this._removeAttribute(t)){const e=[t];this.fire(\"change:attribute\",{attributeKeys:e,directChange:true})}}overrideGravity(){const t=is();this._overriddenGravityRegister.add(t);if(this._overriddenGravityRegister.size===1){this._updateAttributes(true)}return t}restoreGravity(t){if(!this._overriddenGravityRegister.has(t)){throw new ss[\"b\"](\"document-selection-gravity-wrong-restore: Attempting to restore the selection gravity for an unknown UID.\",this,{uid:t})}this._overriddenGravityRegister.delete(t);if(!this.isGravityOverridden){this._updateAttributes(true)}}_popRange(){this._ranges.pop().detach()}_pushRange(t){const e=this._prepareRange(t);if(e){this._ranges.push(e)}}_prepareRange(t){this._checkRange(t);if(t.root==this._document.graveyard){return}const e=lf.fromRange(t);e.on(\"change:range\",(t,i,n)=>{this._hasChangedRange=true;if(e.root==this._document.graveyard){this._fixGraveyardRangesData.push({liveRange:e,sourcePosition:n.deletionPosition})}});return e}_updateMarkers(){const t=[];let e=false;for(const e of this._model.markers){const i=e.getRange();for(const n of this.getRanges()){if(i.containsRange(n,!n.isCollapsed)){t.push(e)}}}const i=Array.from(this.markers);for(const i of t){if(!this.markers.has(i)){this.markers.add(i);e=true}}for(const i of Array.from(this.markers)){if(!t.includes(i)){this.markers.remove(i);e=true}}if(e){this.fire(\"change:marker\",{oldMarkers:i,directChange:false})}}_updateAttributes(t){const e=Ws(this._getSurroundingAttributes());const i=Ws(this.getAttributes());if(t){this._attributePriority=new Map;this._attrs=new Map}else{for(const[t,e]of this._attributePriority){if(e==\"low\"){this._attrs.delete(t);this._attributePriority.delete(t)}}}this._setAttributesTo(e);const n=[];for(const[t,e]of this.getAttributes()){if(!i.has(t)||i.get(t)!==e){n.push(t)}}for(const[t]of i){if(!this.hasAttribute(t)){n.push(t)}}if(n.length>0){this.fire(\"change:attribute\",{attributeKeys:n,directChange:false})}}_setAttribute(t,e,i=true){const n=i?\"normal\":\"low\";if(n==\"low\"&&this._attributePriority.get(t)==\"normal\"){return false}const o=super.getAttribute(t);if(o===e){return false}this._attrs.set(t,e);this._attributePriority.set(t,n);return true}_removeAttribute(t,e=true){const i=e?\"normal\":\"low\";if(i==\"low\"&&this._attributePriority.get(t)==\"normal\"){return false}this._attributePriority.set(t,i);if(!super.hasAttribute(t)){return false}this._attrs.delete(t);return true}_setAttributesTo(t){const e=new Set;for(const[e,i]of this.getAttributes()){if(t.get(e)===i){continue}this._removeAttribute(e,false)}for(const[i,n]of t){const t=this._setAttribute(i,n,false);if(t){e.add(i)}}return e}*_getStoredAttributes(){const t=this.getFirstPosition().parent;if(this.isCollapsed&&t.isEmpty){for(const e of t.getAttributeKeys()){if(e.startsWith(hf)){const i=e.substr(hf.length);yield[i,t.getAttribute(e)]}}}}_getSurroundingAttributes(){const t=this.getFirstPosition();const e=this._model.schema;let i=null;if(!this.isCollapsed){const t=this.getFirstRange();for(const n of t){if(n.item.is(\"element\")&&e.isObject(n.item)){break}if(n.type==\"text\"){i=n.item.getAttributes();break}}}else{const e=t.textNode?t.textNode:t.nodeBefore;const n=t.textNode?t.textNode:t.nodeAfter;if(!this.isGravityOverridden){i=gf(e)}if(!i){i=gf(n)}if(!this.isGravityOverridden&&!i){let t=e;while(t&&!i){t=t.previousSibling;i=gf(t)}}if(!i){let t=n;while(t&&!i){t=t.nextSibling;i=gf(t)}}if(!i){i=this._getStoredAttributes()}}return i}_fixGraveyardSelection(t,e){const i=e.clone();const n=this._model.schema.getNearestSelectionRange(i);const o=this._ranges.indexOf(t);this._ranges.splice(o,1);t.detach();if(n&&!bf(n,this)){const t=this._prepareRange(n);this._ranges.splice(o,0,t)}}}function gf(t){if(t instanceof zh||t instanceof Dh){return t.getAttributes()}return null}function pf(t,e){const i=t.document.differ;for(const n of i.getChanges()){if(n.type!=\"insert\"){continue}const i=n.position.parent;const o=n.length===i.maxOffset;if(o){t.enqueueChange(e,t=>{const e=Array.from(i.getAttributeKeys()).filter(t=>t.startsWith(hf));for(const n of e){t.removeAttribute(n,i)}})}}}function bf(t,e){return!e._ranges.every(e=>!t.isEqual(e))}class wf{constructor(t){this._dispatchers=t}add(t){for(const e of this._dispatchers){t(e)}return this}}var _f=1,kf=4;function vf(t){return Hr(t,_f|kf)}var yf=vf;class xf extends wf{elementToElement(t){return this.add(Df(t))}attributeToElement(t){return this.add(zf(t))}attributeToAttribute(t){return this.add(Ff(t))}markerToElement(t){return this.add(jf(t))}markerToHighlight(t){return this.add(Hf(t))}}function Cf(){return(t,e,i)=>{if(!i.consumable.consume(e.item,\"insert\")){return}const n=i.writer;const o=i.mapper.toViewPosition(e.range.start);const r=n.createText(e.item.data);n.insert(o,r)}}function Af(){return(t,e,i)=>{const n=i.mapper.toViewPosition(e.position);const o=e.position.getShiftedBy(e.length);const r=i.mapper.toViewPosition(o,{isPhantom:true});const s=i.writer.createRange(n,r);const a=i.writer.remove(s.getTrimmed());for(const t of i.writer.createRangeIn(a).getItems()){i.mapper.unbindViewElement(t)}}}function Tf(t,e){const i=t.createAttributeElement(\"span\",e.attributes);if(e.classes){i._addClass(e.classes)}if(e.priority){i._priority=e.priority}i._id=e.id;return i}function Pf(){return(t,e,i)=>{const n=e.selection;if(n.isCollapsed){return}if(!i.consumable.consume(n,\"selection\")){return}const o=[];for(const t of n.getRanges()){const e=i.mapper.toViewRange(t);o.push(e)}i.writer.setSelection(o,{backward:n.isBackward})}}function Ef(){return(t,e,i)=>{const n=e.selection;if(!n.isCollapsed){return}if(!i.consumable.consume(n,\"selection\")){return}const o=i.writer;const r=n.getFirstPosition();const s=i.mapper.toViewPosition(r);const a=o.breakAttributes(s);o.setSelection(a)}}function Sf(){return(t,e,i)=>{const n=i.writer;const o=n.document.selection;for(const t of o.getRanges()){if(t.isCollapsed){if(t.end.parent.isAttached()){i.writer.mergeAttributes(t.start)}}}n.setSelection(null)}}function Mf(t){return(e,i,n)=>{const o=t(i.attributeOldValue,n.writer);const r=t(i.attributeNewValue,n.writer);if(!o&&!r){return}if(!n.consumable.consume(i.item,e.name)){return}const s=n.writer;const a=s.document.selection;if(i.item instanceof ef||i.item instanceof ff){s.wrap(a.getFirstRange(),r)}else{let t=n.mapper.toViewRange(i.range);if(i.attributeOldValue!==null&&o){t=s.unwrap(t,o)}if(i.attributeNewValue!==null&&r){s.wrap(t,r)}}}}function Of(t){return(e,i,n)=>{const o=t(i.item,n.writer);if(!o){return}if(!n.consumable.consume(i.item,\"insert\")){return}const r=n.mapper.toViewPosition(i.range.start);n.mapper.bindElements(i.item,o);n.writer.insert(r,o)}}function If(t){return(e,i,n)=>{i.isOpening=true;const o=t(i,n.writer);i.isOpening=false;const r=t(i,n.writer);if(!o||!r){return}const s=i.markerRange;if(s.isCollapsed&&!n.consumable.consume(s,e.name)){return}for(const t of s){if(!n.consumable.consume(t.item,e.name)){return}}const a=n.mapper;const l=n.writer;l.insert(a.toViewPosition(s.start),o);n.mapper.bindElementToMarker(o,i.markerName);if(!s.isCollapsed){l.insert(a.toViewPosition(s.end),r);n.mapper.bindElementToMarker(r,i.markerName)}e.stop()}}function Rf(){return(t,e,i)=>{const n=i.mapper.markerNameToElements(e.markerName);if(!n){return}for(const t of n){i.mapper.unbindElementFromMarkerName(t,e.markerName);i.writer.clear(i.writer.createRangeOn(t),t)}i.writer.clearClonedElementsGroup(e.markerName);t.stop()}}function Lf(t){return(e,i,n)=>{const o=t(i.attributeOldValue,i);const r=t(i.attributeNewValue,i);if(!o&&!r){return}if(!n.consumable.consume(i.item,e.name)){return}const s=n.mapper.toViewElement(i.item);const a=n.writer;if(!s){throw new ss[\"b\"](\"conversion-attribute-to-attribute-on-text: \"+\"Trying to convert text node's attribute with attribute-to-attribute converter.\",[i,n])}if(i.attributeOldValue!==null&&o){if(o.key==\"class\"){const t=Array.isArray(o.value)?o.value:[o.value];for(const e of t){a.removeClass(e,s)}}else if(o.key==\"style\"){const t=Object.keys(o.value);for(const e of t){a.removeStyle(e,s)}}else{a.removeAttribute(o.key,s)}}if(i.attributeNewValue!==null&&r){if(r.key==\"class\"){const t=Array.isArray(r.value)?r.value:[r.value];for(const e of t){a.addClass(e,s)}}else if(r.key==\"style\"){const t=Object.keys(r.value);for(const e of t){a.setStyle(e,r.value[e],s)}}else{a.setAttribute(r.key,r.value,s)}}}}function Nf(t){return(e,i,n)=>{if(!i.item){return}if(!(i.item instanceof ef||i.item instanceof ff)&&!i.item.is(\"textProxy\")){return}const o=Gf(t,i,n);if(!o){return}if(!n.consumable.consume(i.item,e.name)){return}const r=n.writer;const s=Tf(r,o);const a=r.document.selection;if(i.item instanceof ef||i.item instanceof ff){r.wrap(a.getFirstRange(),s,a)}else{const t=n.mapper.toViewRange(i.range);const e=r.wrap(t,s);for(const t of e.getItems()){if(t.is(\"attributeElement\")&&t.isSimilar(s)){n.mapper.bindElementToMarker(t,i.markerName);break}}}}}function Bf(t){return(e,i,n)=>{if(!i.item){return}if(!(i.item instanceof jh)){return}const o=Gf(t,i,n);if(!o){return}if(!n.consumable.test(i.item,e.name)){return}const r=n.mapper.toViewElement(i.item);if(r&&r.getCustomProperty(\"addHighlight\")){n.consumable.consume(i.item,e.name);for(const t of Kh._createIn(i.item)){n.consumable.consume(t.item,e.name)}r.getCustomProperty(\"addHighlight\")(r,o,n.writer);n.mapper.bindElementToMarker(r,i.markerName)}}}function Vf(t){return(e,i,n)=>{if(i.markerRange.isCollapsed){return}const o=Gf(t,i,n);if(!o){return}const r=Tf(n.writer,o);const s=n.mapper.markerNameToElements(i.markerName);if(!s){return}for(const t of s){n.mapper.unbindElementFromMarkerName(t,i.markerName);if(t.is(\"attributeElement\")){n.writer.unwrap(n.writer.createRangeOn(t),r)}else{t.getCustomProperty(\"removeHighlight\")(t,o.id,n.writer)}}n.writer.clearClonedElementsGroup(i.markerName);e.stop()}}function Df(t){t=yf(t);t.view=Wf(t.view,\"container\");return e=>{e.on(\"insert:\"+t.model,Of(t.view),{priority:t.converterPriority||\"normal\"})}}function zf(t){t=yf(t);const e=t.model.key?t.model.key:t.model;let i=\"attribute:\"+e;if(t.model.name){i+=\":\"+t.model.name}if(t.model.values){for(const e of t.model.values){t.view[e]=Wf(t.view[e],\"attribute\")}}else{t.view=Wf(t.view,\"attribute\")}const n=$f(t);return e=>{e.on(i,Mf(n),{priority:t.converterPriority||\"normal\"})}}function Ff(t){t=yf(t);const e=t.model.key?t.model.key:t.model;let i=\"attribute:\"+e;if(t.model.name){i+=\":\"+t.model.name}if(t.model.values){for(const e of t.model.values){t.view[e]=Uf(t.view[e])}}else{t.view=Uf(t.view)}const n=$f(t);return e=>{e.on(i,Lf(n),{priority:t.converterPriority||\"normal\"})}}function jf(t){t=yf(t);t.view=Wf(t.view,\"ui\");return e=>{e.on(\"addMarker:\"+t.model,If(t.view),{priority:t.converterPriority||\"normal\"});e.on(\"removeMarker:\"+t.model,Rf(t.view),{priority:t.converterPriority||\"normal\"})}}function Hf(t){return e=>{e.on(\"addMarker:\"+t.model,Nf(t.view),{priority:t.converterPriority||\"normal\"});e.on(\"addMarker:\"+t.model,Bf(t.view),{priority:t.converterPriority||\"normal\"});e.on(\"removeMarker:\"+t.model,Vf(t.view),{priority:t.converterPriority||\"normal\"})}}function Wf(t,e){if(typeof t==\"function\"){return t}return(i,n)=>qf(t,n,e)}function qf(t,e,i){if(typeof t==\"string\"){t={name:t}}let n;const o=Object.assign({},t.attributes);if(i==\"container\"){n=e.createContainerElement(t.name,o)}else if(i==\"attribute\"){const i={priority:t.priority||_c.DEFAULT_PRIORITY};n=e.createAttributeElement(t.name,o,i)}else{n=e.createUIElement(t.name,o)}if(t.styles){const i=Object.keys(t.styles);for(const o of i){e.setStyle(o,t.styles[o],n)}}if(t.classes){const i=t.classes;if(typeof i==\"string\"){e.addClass(i,n)}else{for(const t of i){e.addClass(t,n)}}}return n}function $f(t){if(t.model.values){return(e,i)=>{const n=t.view[e];if(n){return n(e,i)}return null}}else{return t.view}}function Uf(t){if(typeof t==\"string\"){return e=>({key:t,value:e})}else if(typeof t==\"object\"){if(t.value){return()=>t}else{return e=>({key:t.key,value:e})}}else{return t}}function Gf(t,e,i){const n=typeof t==\"function\"?t(e,i):t;if(!n){return null}if(!n.priority){n.priority=10}if(!n.id){n.id=e.markerName}return n}class Jf extends wf{elementToElement(t){return this.add(Qf(t))}elementToAttribute(t){return this.add(Zf(t))}attributeToAttribute(t){return this.add(tm(t))}elementToMarker(t){return this.add(em(t))}}function Kf(){return(t,e,i)=>{if(!e.modelRange&&i.consumable.consume(e.viewItem,{name:true})){const{modelRange:t,modelCursor:n}=i.convertChildren(e.viewItem,e.modelCursor);e.modelRange=t;e.modelCursor=n}}}function Xf(){return(t,e,i)=>{if(i.schema.checkChild(e.modelCursor,\"$text\")){if(i.consumable.consume(e.viewItem)){const t=i.writer.createText(e.viewItem.data);i.writer.insert(t,e.modelCursor);e.modelRange=Kh._createFromPositionAndShift(e.modelCursor,t.offsetSize);e.modelCursor=e.modelRange.end}}}}function Yf(t,e){return(i,n)=>{const o=n.newSelection;const r=new ef;const s=[];for(const t of o.getRanges()){s.push(e.toModelRange(t))}r.setTo(s,{backward:o.isBackward});if(!r.isEqual(t.document.selection)){t.change(t=>{t.setSelection(r)})}}}function Qf(t){t=yf(t);const e=nm(t);const i=im(t.view);const n=i?\"element:\"+i:\"element\";return i=>{i.on(n,e,{priority:t.converterPriority||\"normal\"})}}function Zf(t){t=yf(t);sm(t);const e=am(t,false);const i=im(t.view);const n=i?\"element:\"+i:\"element\";return i=>{i.on(n,e,{priority:t.converterPriority||\"low\"})}}function tm(t){t=yf(t);let e=null;if(typeof t.view==\"string\"||t.view.key){e=rm(t)}sm(t,e);const i=am(t,true);return e=>{e.on(\"element\",i,{priority:t.converterPriority||\"low\"})}}function em(t){t=yf(t);dm(t);return Qf(t)}function im(t){if(typeof t==\"string\"){return t}if(typeof t==\"object\"&&typeof t.name==\"string\"){return t.name}return null}function nm(t){const e=t.view?new qs(t.view):null;return(i,n,o)=>{let r={};if(e){const t=e.match(n.viewItem);if(!t){return}r=t.match}r.name=true;const s=om(t.model,n.viewItem,o.writer);if(!s){return}if(!o.consumable.test(n.viewItem,r)){return}const a=o.splitToAllowedParent(s,n.modelCursor);if(!a){return}o.writer.insert(s,a.position);o.convertChildren(n.viewItem,o.writer.createPositionAt(s,0));o.consumable.consume(n.viewItem,r);const l=o.getSplitParts(s);n.modelRange=new Kh(o.writer.createPositionBefore(s),o.writer.createPositionAfter(l[l.length-1]));if(a.cursorParent){n.modelCursor=o.writer.createPositionAt(a.cursorParent,0)}else{n.modelCursor=n.modelRange.end}}}function om(t,e,i){if(t instanceof Function){return t(e,i)}else{return i.createElement(t)}}function rm(t){if(typeof t.view==\"string\"){t.view={key:t.view}}const e=t.view.key;let i;if(e==\"class\"||e==\"style\"){const n=e==\"class\"?\"classes\":\"styles\";i={[n]:t.view.value}}else{const n=typeof t.view.value==\"undefined\"?/[\\s\\S]*/:t.view.value;i={attributes:{[e]:n}}}if(t.view.name){i.name=t.view.name}t.view=i;return e}function sm(t,e=null){const i=e===null?true:t=>t.getAttribute(e);const n=typeof t.model!=\"object\"?t.model:t.model.key;const o=typeof t.model!=\"object\"||typeof t.model.value==\"undefined\"?i:t.model.value;t.model={key:n,value:o}}function am(t,e){const i=new qs(t.view);return(n,o,r)=>{const s=i.match(o.viewItem);if(!s){return}const a=t.model.key;const l=typeof t.model.value==\"function\"?t.model.value(o.viewItem):t.model.value;if(l===null){return}if(lm(t.view,o.viewItem)){s.match.name=true}else{delete s.match.name}if(!r.consumable.test(o.viewItem,s.match)){return}if(!o.modelRange){o=Object.assign(o,r.convertChildren(o.viewItem,o.modelCursor))}const c=cm(o.modelRange,{key:a,value:l},e,r);if(c){r.consumable.consume(o.viewItem,s.match)}}}function lm(t,e){const i=typeof t==\"function\"?t(e):t;if(typeof i==\"object\"&&!im(i)){return false}return!i.classes&&!i.attributes&&!i.styles}function cm(t,e,i,n){let o=false;for(const r of Array.from(t.getItems({shallow:i}))){if(n.schema.checkAttribute(r,e.key)){n.writer.setAttribute(e.key,e.value,r);o=true}}return o}function dm(t){const e=t.model;t.model=(t,i)=>{const n=typeof e==\"string\"?e:e(t);return i.createElement(\"$marker\",{\"data-name\":n})}}class um{constructor(t,e){this.model=t;this.view=new Bh(e);this.mapper=new Xh;this.downcastDispatcher=new Zh({mapper:this.mapper});const i=this.model.document;const n=i.selection;const o=this.model.markers;this.listenTo(this.model,\"_beforeChanges\",()=>{this.view._disableRendering(true)},{priority:\"highest\"});this.listenTo(this.model,\"_afterChanges\",()=>{this.view._disableRendering(false)},{priority:\"lowest\"});this.listenTo(i,\"change\",()=>{this.view.change(t=>{this.downcastDispatcher.convertChanges(i.differ,o,t);this.downcastDispatcher.convertSelection(n,o,t)})},{priority:\"low\"});this.listenTo(this.view.document,\"selectionChange\",Yf(this.model,this.mapper));this.downcastDispatcher.on(\"insert:$text\",Cf(),{priority:\"lowest\"});this.downcastDispatcher.on(\"remove\",Af(),{priority:\"low\"});this.downcastDispatcher.on(\"selection\",Sf(),{priority:\"low\"});this.downcastDispatcher.on(\"selection\",Pf(),{priority:\"low\"});this.downcastDispatcher.on(\"selection\",Ef(),{priority:\"low\"});this.view.document.roots.bindTo(this.model.document.roots).using(t=>{if(t.rootName==\"$graveyard\"){return null}const e=new cc(this.view.document,t.name);e.rootName=t.rootName;this.mapper.bindElements(t,e);return e})}destroy(){this.view.destroy();this.stopListening()}}ys(um,Xl);class hm{constructor(){this._commands=new Map}add(t,e){this._commands.set(t,e)}get(t){return this._commands.get(t)}execute(t,...e){const i=this.get(t);if(!i){throw new ss[\"b\"](\"commandcollection-command-not-found: Command does not exist.\",this,{commandName:t})}i.execute(...e)}*names(){yield*this._commands.keys()}*commands(){yield*this._commands.values()}[Symbol.iterator](){return this._commands[Symbol.iterator]()}destroy(){for(const t of this.commands()){t.destroy()}}}class fm{constructor(){this._consumables=new Map}add(t,e){let i;if(t.is(\"text\")||t.is(\"documentFragment\")){this._consumables.set(t,true);return}if(!this._consumables.has(t)){i=new mm(t);this._consumables.set(t,i)}else{i=this._consumables.get(t)}i.add(e)}test(t,e){const i=this._consumables.get(t);if(i===undefined){return null}if(t.is(\"text\")||t.is(\"documentFragment\")){return i}return i.test(e)}consume(t,e){if(this.test(t,e)){if(t.is(\"text\")||t.is(\"documentFragment\")){this._consumables.set(t,false)}else{this._consumables.get(t).consume(e)}return true}return false}revert(t,e){const i=this._consumables.get(t);if(i!==undefined){if(t.is(\"text\")||t.is(\"documentFragment\")){this._consumables.set(t,true)}else{i.revert(e)}}}static consumablesFromElement(t){const e={element:t,name:true,attributes:[],classes:[],styles:[]};const i=t.getAttributeKeys();for(const t of i){if(t==\"style\"||t==\"class\"){continue}e.attributes.push(t)}const n=t.getClassNames();for(const t of n){e.classes.push(t)}const o=t.getStyleNames();for(const t of o){e.styles.push(t)}return e}static createFrom(t,e){if(!e){e=new fm(t)}if(t.is(\"text\")){e.add(t);return e}if(t.is(\"element\")){e.add(t,fm.consumablesFromElement(t))}if(t.is(\"documentFragment\")){e.add(t)}for(const i of t.getChildren()){e=fm.createFrom(i,e)}return e}}class mm{constructor(t){this.element=t;this._canConsumeName=null;this._consumables={attributes:new Map,styles:new Map,classes:new Map}}add(t){if(t.name){this._canConsumeName=true}for(const e in this._consumables){if(e in t){this._add(e,t[e])}}}test(t){if(t.name&&!this._canConsumeName){return this._canConsumeName}for(const e in this._consumables){if(e in t){const i=this._test(e,t[e]);if(i!==true){return i}}}return true}consume(t){if(t.name){this._canConsumeName=false}for(const e in this._consumables){if(e in t){this._consume(e,t[e])}}}revert(t){if(t.name){this._canConsumeName=true}for(const e in this._consumables){if(e in t){this._revert(e,t[e])}}}_add(t,e){const i=Ke(e)?e:[e];const n=this._consumables[t];for(const e of i){if(t===\"attributes\"&&(e===\"class\"||e===\"style\")){throw new ss[\"b\"](\"viewconsumable-invalid-attribute: Classes and styles should be handled separately.\",this)}n.set(e,true);if(t===\"styles\"){for(const t of this.element.document.stylesProcessor.getRelatedStyles(e)){n.set(t,true)}}}}_test(t,e){const i=Ke(e)?e:[e];const n=this._consumables[t];for(const e of i){if(t===\"attributes\"&&(e===\"class\"||e===\"style\")){const t=e==\"class\"?\"classes\":\"styles\";const i=this._test(t,[...this._consumables[t].keys()]);if(i!==true){return i}}else{const t=n.get(e);if(t===undefined){return null}if(!t){return false}}}return true}_consume(t,e){const i=Ke(e)?e:[e];const n=this._consumables[t];for(const e of i){if(t===\"attributes\"&&(e===\"class\"||e===\"style\")){const t=e==\"class\"?\"classes\":\"styles\";this._consume(t,[...this._consumables[t].keys()])}else{n.set(e,false);if(t==\"styles\"){for(const t of this.element.document.stylesProcessor.getRelatedStyles(e)){n.set(t,false)}}}}}_revert(t,e){const i=Ke(e)?e:[e];const n=this._consumables[t];for(const e of i){if(t===\"attributes\"&&(e===\"class\"||e===\"style\")){const t=e==\"class\"?\"classes\":\"styles\";this._revert(t,[...this._consumables[t].keys()])}else{const t=n.get(e);if(t===false){n.set(e,true)}}}}}class gm{constructor(){this._sourceDefinitions={};this._attributeProperties={};this.decorate(\"checkChild\");this.decorate(\"checkAttribute\");this.on(\"checkAttribute\",(t,e)=>{e[0]=new pm(e[0])},{priority:\"highest\"});this.on(\"checkChild\",(t,e)=>{e[0]=new pm(e[0]);e[1]=this.getDefinition(e[1])},{priority:\"highest\"})}register(t,e){if(this._sourceDefinitions[t]){throw new ss[\"b\"](\"schema-cannot-register-item-twice: A single item cannot be registered twice in the schema.\",this,{itemName:t})}this._sourceDefinitions[t]=[Object.assign({},e)];this._clearCache()}extend(t,e){if(!this._sourceDefinitions[t]){throw new ss[\"b\"](\"schema-cannot-extend-missing-item: Cannot extend an item which was not registered yet.\",this,{itemName:t})}this._sourceDefinitions[t].push(Object.assign({},e));this._clearCache()}getDefinitions(){if(!this._compiledDefinitions){this._compile()}return this._compiledDefinitions}getDefinition(t){let e;if(typeof t==\"string\"){e=t}else if(t.is&&(t.is(\"text\")||t.is(\"textProxy\"))){e=\"$text\"}else{e=t.name}return this.getDefinitions()[e]}isRegistered(t){return!!this.getDefinition(t)}isBlock(t){const e=this.getDefinition(t);return!!(e&&e.isBlock)}isLimit(t){const e=this.getDefinition(t);if(!e){return false}return!!(e.isLimit||e.isObject)}isObject(t){const e=this.getDefinition(t);return!!(e&&e.isObject)}isInline(t){const e=this.getDefinition(t);return!!(e&&e.isInline)}checkChild(t,e){if(!e){return false}return this._checkContextMatch(e,t)}checkAttribute(t,e){const i=this.getDefinition(t.last);if(!i){return false}return i.allowAttributes.includes(e)}checkMerge(t,e=null){if(t instanceof $h){const e=t.nodeBefore;const i=t.nodeAfter;if(!(e instanceof jh)){throw new ss[\"b\"](\"schema-check-merge-no-element-before: The node before the merge position must be an element.\",this)}if(!(i instanceof jh)){throw new ss[\"b\"](\"schema-check-merge-no-element-after: The node after the merge position must be an element.\",this)}return this.checkMerge(e,i)}for(const i of e.getChildren()){if(!this.checkChild(t,i)){return false}}return true}addChildCheck(t){this.on(\"checkChild\",(e,[i,n])=>{if(!n){return}const o=t(i,n);if(typeof o==\"boolean\"){e.stop();e.return=o}},{priority:\"high\"})}addAttributeCheck(t){this.on(\"checkAttribute\",(e,[i,n])=>{const o=t(i,n);if(typeof o==\"boolean\"){e.stop();e.return=o}},{priority:\"high\"})}setAttributeProperties(t,e){this._attributeProperties[t]=Object.assign(this.getAttributeProperties(t),e)}getAttributeProperties(t){return this._attributeProperties[t]||{}}getLimitElement(t){let e;if(t instanceof $h){e=t.parent}else{const i=t instanceof Kh?[t]:Array.from(t.getRanges());e=i.reduce((t,e)=>{const i=e.getCommonAncestor();if(!t){return i}return t.getCommonAncestor(i,{includeSelf:true})},null)}while(!this.isLimit(e)){if(e.parent){e=e.parent}else{break}}return e}checkAttributeInSelection(t,e){if(t.isCollapsed){const i=t.getFirstPosition();const n=[...i.getAncestors(),new Dh(\"\",t.getAttributes())];return this.checkAttribute(n,e)}else{const i=t.getRanges();for(const t of i){for(const i of t){if(this.checkAttribute(i.item,e)){return true}}}}return false}*getValidRanges(t,e){t=Om(t);for(const i of t){yield*this._getValidRangesForRange(i,e)}}getNearestSelectionRange(t,e=\"both\"){if(this.checkChild(t,\"$text\")){return new Kh(t)}let i,n;const o=t.getAncestors().reverse().find(t=>this.isLimit(t))||t.root;if(e==\"both\"||e==\"backward\"){i=new Wh({boundaries:Kh._createIn(o),startPosition:t,direction:\"backward\"})}if(e==\"both\"||e==\"forward\"){n=new Wh({boundaries:Kh._createIn(o),startPosition:t})}for(const t of Mm(i,n)){const e=t.walker==i?\"elementEnd\":\"elementStart\";const n=t.value;if(n.type==e&&this.isObject(n.item)){return Kh._createOn(n.item)}if(this.checkChild(n.nextPosition,\"$text\")){return new Kh(n.nextPosition)}}return null}findAllowedParent(t,e){let i=t.parent;while(i){if(this.checkChild(i,e)){return i}if(this.isLimit(i)){return null}i=i.parent}return null}removeDisallowedAttributes(t,e){for(const i of t){if(i.is(\"text\")){Im(this,i,e)}else{const t=Kh._createIn(i);const n=t.getPositions();for(const t of n){const i=t.nodeBefore||t.parent;Im(this,i,e)}}}}createContext(t){return new pm(t)}_clearCache(){this._compiledDefinitions=null}_compile(){const t={};const e=this._sourceDefinitions;const i=Object.keys(e);for(const n of i){t[n]=bm(e[n],n)}for(const e of i){wm(t,e)}for(const e of i){_m(t,e)}for(const e of i){km(t,e);vm(t,e)}for(const e of i){ym(t,e);xm(t,e)}this._compiledDefinitions=t}_checkContextMatch(t,e,i=e.length-1){const n=e.getItem(i);if(t.allowIn.includes(n.name)){if(i==0){return true}else{const t=this.getDefinition(n);return this._checkContextMatch(t,e,i-1)}}else{return false}}*_getValidRangesForRange(t,e){let i=t.start;let n=t.start;for(const o of t.getItems({shallow:true})){if(o.is(\"element\")){yield*this._getValidRangesForRange(Kh._createIn(o),e)}if(!this.checkAttribute(o,e)){if(!i.isEqual(n)){yield new Kh(i,n)}i=$h._createAfter(o)}n=$h._createAfter(o)}if(!i.isEqual(n)){yield new Kh(i,n)}}}ys(gm,Xl);class pm{constructor(t){if(t instanceof pm){return t}if(typeof t==\"string\"){t=[t]}else if(!Array.isArray(t)){t=t.getAncestors({includeSelf:true})}if(t[0]&&typeof t[0]!=\"string\"&&t[0].is(\"documentFragment\")){t.shift()}this._items=t.map(Sm)}get length(){return this._items.length}get last(){return this._items[this._items.length-1]}[Symbol.iterator](){return this._items[Symbol.iterator]()}push(t){const e=new pm([t]);e._items=[...this._items,...e._items];return e}getItem(t){return this._items[t]}*getNames(){yield*this._items.map(t=>t.name)}endsWith(t){return Array.from(this.getNames()).join(\" \").endsWith(t)}startsWith(t){return Array.from(this.getNames()).join(\" \").startsWith(t)}}function bm(t,e){const i={name:e,allowIn:[],allowContentOf:[],allowWhere:[],allowAttributes:[],allowAttributesOf:[],inheritTypesFrom:[]};Cm(t,i);Am(t,i,\"allowIn\");Am(t,i,\"allowContentOf\");Am(t,i,\"allowWhere\");Am(t,i,\"allowAttributes\");Am(t,i,\"allowAttributesOf\");Am(t,i,\"inheritTypesFrom\");Tm(t,i);return i}function wm(t,e){for(const i of t[e].allowContentOf){if(t[i]){const n=Pm(t,i);n.forEach(t=>{t.allowIn.push(e)})}}delete t[e].allowContentOf}function _m(t,e){for(const i of t[e].allowWhere){const n=t[i];if(n){const i=n.allowIn;t[e].allowIn.push(...i)}}delete t[e].allowWhere}function km(t,e){for(const i of t[e].allowAttributesOf){const n=t[i];if(n){const i=n.allowAttributes;t[e].allowAttributes.push(...i)}}delete t[e].allowAttributesOf}function vm(t,e){const i=t[e];for(const e of i.inheritTypesFrom){const n=t[e];if(n){const t=Object.keys(n).filter(t=>t.startsWith(\"is\"));for(const e of t){if(!(e in i)){i[e]=n[e]}}}}delete i.inheritTypesFrom}function ym(t,e){const i=t[e];const n=i.allowIn.filter(e=>t[e]);i.allowIn=Array.from(new Set(n))}function xm(t,e){const i=t[e];i.allowAttributes=Array.from(new Set(i.allowAttributes))}function Cm(t,e){for(const i of t){const t=Object.keys(i).filter(t=>t.startsWith(\"is\"));for(const n of t){e[n]=i[n]}}}function Am(t,e,i){for(const n of t){if(typeof n[i]==\"string\"){e[i].push(n[i])}else if(Array.isArray(n[i])){e[i].push(...n[i])}}}function Tm(t,e){for(const i of t){const t=i.inheritAllFrom;if(t){e.allowContentOf.push(t);e.allowWhere.push(t);e.allowAttributesOf.push(t);e.inheritTypesFrom.push(t)}}}function Pm(t,e){const i=t[e];return Em(t).filter(t=>t.allowIn.includes(i.name))}function Em(t){return Object.keys(t).map(e=>t[e])}function Sm(t){if(typeof t==\"string\"){return{name:t,*getAttributeKeys(){},getAttribute(){}}}else{return{name:t.is(\"element\")?t.name:\"$text\",*getAttributeKeys(){yield*t.getAttributeKeys()},getAttribute(e){return t.getAttribute(e)}}}}function*Mm(t,e){let i=false;while(!i){i=true;if(t){const e=t.next();if(!e.done){i=false;yield{walker:t,value:e.value}}}if(e){const t=e.next();if(!t.done){i=false;yield{walker:e,value:t.value}}}}}function*Om(t){for(const e of t){yield*e.getMinimalFlatRanges()}}function Im(t,e,i){for(const n of e.getAttributeKeys()){if(!t.checkAttribute(e,n)){i.removeAttribute(n,e)}}}class Rm{constructor(t={}){this._splitParts=new Map;this._modelCursor=null;this.conversionApi=Object.assign({},t);this.conversionApi.convertItem=this._convertItem.bind(this);this.conversionApi.convertChildren=this._convertChildren.bind(this);this.conversionApi.splitToAllowedParent=this._splitToAllowedParent.bind(this);this.conversionApi.getSplitParts=this._getSplitParts.bind(this)}convert(t,e,i=[\"$root\"]){this.fire(\"viewCleanup\",t);this._modelCursor=Nm(i,e);this.conversionApi.writer=e;this.conversionApi.consumable=fm.createFrom(t);this.conversionApi.store={};const{modelRange:n}=this._convertItem(t,this._modelCursor);const o=e.createDocumentFragment();if(n){this._removeEmptyElements();for(const t of Array.from(this._modelCursor.parent.getChildren())){e.append(t,o)}o.markers=Lm(o,e)}this._modelCursor=null;this._splitParts.clear();this.conversionApi.writer=null;this.conversionApi.store=null;return o}_convertItem(t,e){const i=Object.assign({viewItem:t,modelCursor:e,modelRange:null});if(t.is(\"element\")){this.fire(\"element:\"+t.name,i,this.conversionApi)}else if(t.is(\"text\")){this.fire(\"text\",i,this.conversionApi)}else{this.fire(\"documentFragment\",i,this.conversionApi)}if(i.modelRange&&!(i.modelRange instanceof Kh)){throw new ss[\"b\"](\"view-conversion-dispatcher-incorrect-result: Incorrect conversion result was dropped.\",this)}return{modelRange:i.modelRange,modelCursor:i.modelCursor}}_convertChildren(t,e){const i=new Kh(e);let n=e;for(const e of Array.from(t.getChildren())){const t=this._convertItem(e,n);if(t.modelRange instanceof Kh){i.end=t.modelRange.end;n=t.modelCursor}}return{modelRange:i,modelCursor:n}}_splitToAllowedParent(t,e){const i=this.conversionApi.schema.findAllowedParent(e,t);if(!i){return null}if(i===e.parent){return{position:e}}if(this._modelCursor.parent.getAncestors().includes(i)){return null}const n=this.conversionApi.writer.split(e,i);const o=[];for(const t of n.range.getWalker()){if(t.type==\"elementEnd\"){o.push(t.item)}else{const e=o.pop();const i=t.item;this._registerSplitPair(e,i)}}return{position:n.position,cursorParent:n.range.end.parent}}_registerSplitPair(t,e){if(!this._splitParts.has(t)){this._splitParts.set(t,[t])}const i=this._splitParts.get(t);this._splitParts.set(e,i);i.push(e)}_getSplitParts(t){let e;if(!this._splitParts.has(t)){e=[t]}else{e=this._splitParts.get(t)}return e}_removeEmptyElements(){let t=false;for(const e of this._splitParts.keys()){if(e.isEmpty){this.conversionApi.writer.remove(e);this._splitParts.delete(e);t=true}}if(t){this._removeEmptyElements()}}}ys(Rm,ds);function Lm(t,e){const i=new Set;const n=new Map;const o=Kh._createIn(t).getItems();for(const t of o){if(t.name==\"$marker\"){i.add(t)}}for(const t of i){const i=t.getAttribute(\"data-name\");const o=e.createPositionBefore(t);if(!n.has(i)){n.set(i,new Kh(o.clone()))}else{n.get(i).end=o.clone()}e.remove(t)}return n}function Nm(t,e){let i;for(const n of new pm(t)){const t={};for(const e of n.getAttributeKeys()){t[e]=n.getAttribute(e)}const o=e.createElement(n.name,t);if(i){e.append(o,i)}i=$h._createAt(o,0)}return i}class Bm{constructor(t,e){this.model=t;this.stylesProcessor=e;this.processor;this.mapper=new Xh;this.downcastDispatcher=new Zh({mapper:this.mapper});this.downcastDispatcher.on(\"insert:$text\",Cf(),{priority:\"lowest\"});this.upcastDispatcher=new Rm({schema:t.schema});this.viewDocument=new bc(e);this._viewWriter=new Uc(this.viewDocument);this.upcastDispatcher.on(\"text\",Xf(),{priority:\"lowest\"});this.upcastDispatcher.on(\"element\",Kf(),{priority:\"lowest\"});this.upcastDispatcher.on(\"documentFragment\",Kf(),{priority:\"lowest\"});this.decorate(\"init\");this.on(\"init\",()=>{this.fire(\"ready\")},{priority:\"lowest\"})}get(t){const{rootName:e=\"main\",trim:i=\"empty\"}=t||{};if(!this._checkIfRootsExists([e])){throw new ss[\"b\"](\"datacontroller-get-non-existent-root: Attempting to get data from a non-existing root.\",this)}const n=this.model.document.getRoot(e);if(i===\"empty\"&&!this.model.hasContent(n,{ignoreWhitespaces:true})){return\"\"}return this.stringify(n)}stringify(t){const e=this.toView(t);return this.processor.toData(e)}toView(t){const e=this.viewDocument;const i=this._viewWriter;this.mapper.clearBindings();const n=Kh._createIn(t);const o=new qc(e);this.mapper.bindElements(t,o);this.downcastDispatcher.convertInsert(n,i);if(!t.is(\"documentFragment\")){const e=Vm(t);for(const[t,n]of e){this.downcastDispatcher.convertMarkerAdd(t,n,i)}}return o}init(t){if(this.model.document.version){throw new ss[\"b\"](\"datacontroller-init-document-not-empty: Trying to set initial data to not empty document.\",this)}let e={};if(typeof t===\"string\"){e.main=t}else{e=t}if(!this._checkIfRootsExists(Object.keys(e))){throw new ss[\"b\"](\"datacontroller-init-non-existent-root: Attempting to init data on a non-existing root.\",this)}this.model.enqueueChange(\"transparent\",t=>{for(const i of Object.keys(e)){const n=this.model.document.getRoot(i);t.insert(this.parse(e[i],n),n,0)}});return Promise.resolve()}set(t){let e={};if(typeof t===\"string\"){e.main=t}else{e=t}if(!this._checkIfRootsExists(Object.keys(e))){throw new ss[\"b\"](\"datacontroller-set-non-existent-root: Attempting to set data on a non-existing root.\",this)}this.model.enqueueChange(\"transparent\",t=>{t.setSelection(null);t.removeSelectionAttribute(this.model.document.selection.getAttributeKeys());for(const i of Object.keys(e)){const n=this.model.document.getRoot(i);t.remove(t.createRangeIn(n));t.insert(this.parse(e[i],n),n,0)}})}parse(t,e=\"$root\"){const i=this.processor.toView(t);return this.toModel(i,e)}toModel(t,e=\"$root\"){return this.model.change(i=>this.upcastDispatcher.convert(t,i,e))}addStyleProcessorRules(t){t(this.stylesProcessor)}destroy(){this.stopListening()}_checkIfRootsExists(t){for(const e of t){if(!this.model.document.getRootNames().includes(e)){return false}}return true}}ys(Bm,Xl);function Vm(t){const e=[];const i=t.root.document;if(!i){return[]}const n=Kh._createIn(t);for(const t of i.model.markers){const i=n.getIntersection(t.getRange());if(i){e.push([t.name,i])}}return e}class Dm{constructor(t,e){this._helpers=new Map;this._downcast=Array.isArray(t)?t:[t];this._createConversionHelpers({name:\"downcast\",dispatchers:this._downcast,isDowncast:true});this._upcast=Array.isArray(e)?e:[e];this._createConversionHelpers({name:\"upcast\",dispatchers:this._upcast,isDowncast:false})}addAlias(t,e){const i=this._downcast.includes(e);const n=this._upcast.includes(e);if(!n&&!i){throw new ss[\"b\"](\"conversion-add-alias-dispatcher-not-registered: \"+\"Trying to register and alias for a dispatcher that nas not been registered.\",this)}this._createConversionHelpers({name:t,dispatchers:[e],isDowncast:i})}for(t){if(!this._helpers.has(t)){throw new ss[\"b\"](\"conversion-for-unknown-group: Trying to add a converter to an unknown dispatchers group.\",this)}return this._helpers.get(t)}elementToElement(t){this.for(\"downcast\").elementToElement(t);for(const{model:e,view:i}of zm(t)){this.for(\"upcast\").elementToElement({model:e,view:i,converterPriority:t.converterPriority})}}attributeToElement(t){this.for(\"downcast\").attributeToElement(t);for(const{model:e,view:i}of zm(t)){this.for(\"upcast\").elementToAttribute({view:i,model:e,converterPriority:t.converterPriority})}}attributeToAttribute(t){this.for(\"downcast\").attributeToAttribute(t);for(const{model:e,view:i}of zm(t)){this.for(\"upcast\").attributeToAttribute({view:i,model:e})}}_createConversionHelpers({name:t,dispatchers:e,isDowncast:i}){if(this._helpers.has(t)){throw new ss[\"b\"](\"conversion-group-exists: Trying to register a group name that has already been registered.\",this)}const n=i?new xf(e):new Jf(e);this._helpers.set(t,n)}}function*zm(t){if(t.model.values){for(const e of t.model.values){const i={key:t.model.key,value:e};const n=t.view[e];const o=t.upcastAlso?t.upcastAlso[e]:undefined;yield*Fm(i,n,o)}}else{yield*Fm(t.model,t.view,t.upcastAlso)}}function*Fm(t,e,i){yield{model:t,view:e};if(i){i=Array.isArray(i)?i:[i];for(const e of i){yield{model:t,view:e}}}}class jm{constructor(t=\"default\"){this.operations=[];this.type=t}get baseVersion(){for(const t of this.operations){if(t.baseVersion!==null){return t.baseVersion}}return null}addOperation(t){t.batch=this;this.operations.push(t);return t}}class Hm{constructor(t){this.baseVersion=t;this.isDocumentOperation=this.baseVersion!==null;this.batch=null}_validate(){}toJSON(){const t=Object.assign({},this);t.__className=this.constructor.className;delete t.batch;delete t.isDocumentOperation;return t}static get className(){return\"Operation\"}static fromJSON(t){return new this(t.baseVersion)}}class Wm{constructor(t){this.markers=new Map;this._children=new Fh;if(t){this._insertChild(0,t)}}[Symbol.iterator](){return this.getChildren()}get childCount(){return this._children.length}get maxOffset(){return this._children.maxOffset}get isEmpty(){return this.childCount===0}get root(){return this}get parent(){return null}is(t){return t===\"documentFragment\"||t===\"model:documentFragment\"}getChild(t){return this._children.getNode(t)}getChildren(){return this._children[Symbol.iterator]()}getChildIndex(t){return this._children.getNodeIndex(t)}getChildStartOffset(t){return this._children.getNodeStartOffset(t)}getPath(){return[]}getNodeByPath(t){let e=this;for(const i of t){e=e.getChild(e.offsetToIndex(i))}return e}offsetToIndex(t){return this._children.offsetToIndex(t)}toJSON(){const t=[];for(const e of this._children){t.push(e.toJSON())}return t}static fromJSON(t){const e=[];for(const i of t){if(i.name){e.push(jh.fromJSON(i))}else{e.push(Dh.fromJSON(i))}}return new Wm(e)}_appendChild(t){this._insertChild(this.childCount,t)}_insertChild(t,e){const i=qm(e);for(const t of i){if(t.parent!==null){t._remove()}t.parent=this}this._children._insertNodes(t,i)}_removeChildren(t,e=1){const i=this._children._removeNodes(t,e);for(const t of i){t.parent=null}return i}}function qm(t){if(typeof t==\"string\"){return[new Dh(t)]}if(!vs(t)){t=[t]}return Array.from(t).map(t=>{if(typeof t==\"string\"){return new Dh(t)}if(t instanceof zh){return new Dh(t.data,t.getAttributes())}return t})}function $m(t,e){e=Km(e);const i=e.reduce((t,e)=>t+e.offsetSize,0);const n=t.parent;Ym(t);const o=t.index;n._insertChild(o,e);Xm(n,o+e.length);Xm(n,o);return new Kh(t,t.getShiftedBy(i))}function Um(t){if(!t.isFlat){throw new ss[\"b\"](\"operation-utils-remove-range-not-flat: \"+\"Trying to remove a range which starts and ends in different element.\",this)}const e=t.start.parent;Ym(t.start);Ym(t.end);const i=e._removeChildren(t.start.index,t.end.index-t.start.index);Xm(e,t.start.index);return i}function Gm(t,e){if(!t.isFlat){throw new ss[\"b\"](\"operation-utils-move-range-not-flat: \"+\"Trying to move a range which starts and ends in different element.\",this)}const i=Um(t);e=e._getTransformedByDeletion(t.start,t.end.offset-t.start.offset);return $m(e,i)}function Jm(t,e,i){Ym(t.start);Ym(t.end);for(const n of t.getItems({shallow:true})){const t=n.is(\"textProxy\")?n.textNode:n;if(i!==null){t._setAttribute(e,i)}else{t._removeAttribute(e)}Xm(t.parent,t.index)}Xm(t.end.parent,t.end.index)}function Km(t){const e=[];if(!(t instanceof Array)){t=[t]}for(let i=0;i<t.length;i++){if(typeof t[i]==\"string\"){e.push(new Dh(t[i]))}else if(t[i]instanceof zh){e.push(new Dh(t[i].data,t[i].getAttributes()))}else if(t[i]instanceof Wm||t[i]instanceof Fh){for(const n of t[i]){e.push(n)}}else if(t[i]instanceof Vh){e.push(t[i])}}for(let t=1;t<e.length;t++){const i=e[t];const n=e[t-1];if(i instanceof Dh&&n instanceof Dh&&Qm(i,n)){e.splice(t-1,2,new Dh(n.data+i.data,n.getAttributes()));t--}}return e}function Xm(t,e){const i=t.getChild(e-1);const n=t.getChild(e);if(i&&n&&i.is(\"text\")&&n.is(\"text\")&&Qm(i,n)){const o=new Dh(i.data+n.data,i.getAttributes());t._removeChildren(e-1,2);t._insertChild(e-1,o)}}function Ym(t){const e=t.textNode;const i=t.parent;if(e){const n=t.offset-e.startOffset;const o=e.index;i._removeChildren(o,1);const r=new Dh(e.data.substr(0,n),e.getAttributes());const s=new Dh(e.data.substr(n),e.getAttributes());i._insertChild(o,[r,s])}}function Qm(t,e){const i=t.getAttributes();const n=e.getAttributes();for(const t of i){if(t[1]!==e.getAttribute(t[0])){return false}n.next()}return n.next().done}function Zm(t,e){return qu(t,e)}var tg=Zm;class eg extends Hm{constructor(t,e,i,n,o){super(o);this.range=t.clone();this.key=e;this.oldValue=i===undefined?null:i;this.newValue=n===undefined?null:n}get type(){if(this.oldValue===null){return\"addAttribute\"}else if(this.newValue===null){return\"removeAttribute\"}else{return\"changeAttribute\"}}clone(){return new eg(this.range,this.key,this.oldValue,this.newValue,this.baseVersion)}getReversed(){return new eg(this.range,this.key,this.newValue,this.oldValue,this.baseVersion+1)}toJSON(){const t=super.toJSON();t.range=this.range.toJSON();return t}_validate(){if(!this.range.isFlat){throw new ss[\"b\"](\"attribute-operation-range-not-flat: The range to change is not flat.\",this)}for(const t of this.range.getItems({shallow:true})){if(this.oldValue!==null&&!tg(t.getAttribute(this.key),this.oldValue)){throw new ss[\"b\"](\"attribute-operation-wrong-old-value: Changed node has different attribute value than operation's \"+\"old attribute value.\",this,{item:t,key:this.key,value:this.oldValue})}if(this.oldValue===null&&this.newValue!==null&&t.hasAttribute(this.key)){throw new ss[\"b\"](\"attribute-operation-attribute-exists: The attribute with given key already exists.\",this,{node:t,key:this.key})}}}_execute(){if(!tg(this.oldValue,this.newValue)){Jm(this.range,this.key,this.newValue)}}static get className(){return\"AttributeOperation\"}static fromJSON(t,e){return new eg(Kh.fromJSON(t.range,e),t.key,t.oldValue,t.newValue,t.baseVersion)}}class ig extends Hm{constructor(t,e){super(null);this.sourcePosition=t.clone();this.howMany=e}get type(){return\"detach\"}toJSON(){const t=super.toJSON();t.sourcePosition=this.sourcePosition.toJSON();return t}_validate(){if(this.sourcePosition.root.document){throw new ss[\"b\"](\"detach-operation-on-document-node: Cannot detach document node.\",this)}}_execute(){Um(Kh._createFromPositionAndShift(this.sourcePosition,this.howMany))}static get className(){return\"DetachOperation\"}}class ng extends Hm{constructor(t,e,i,n){super(n);this.sourcePosition=t.clone();this.sourcePosition.stickiness=\"toNext\";this.howMany=e;this.targetPosition=i.clone();this.targetPosition.stickiness=\"toNone\"}get type(){if(this.targetPosition.root.rootName==\"$graveyard\"){return\"remove\"}else if(this.sourcePosition.root.rootName==\"$graveyard\"){return\"reinsert\"}return\"move\"}clone(){return new this.constructor(this.sourcePosition,this.howMany,this.targetPosition,this.baseVersion)}getMovedRangeStart(){return this.targetPosition._getTransformedByDeletion(this.sourcePosition,this.howMany)}getReversed(){const t=this.sourcePosition._getTransformedByInsertion(this.targetPosition,this.howMany);return new this.constructor(this.getMovedRangeStart(),this.howMany,t,this.baseVersion+1)}_validate(){const t=this.sourcePosition.parent;const e=this.targetPosition.parent;const i=this.sourcePosition.offset;const n=this.targetPosition.offset;if(i+this.howMany>t.maxOffset){throw new ss[\"b\"](\"move-operation-nodes-do-not-exist: The nodes which should be moved do not exist.\",this)}else if(t===e&&i<n&&n<i+this.howMany){throw new ss[\"b\"](\"move-operation-range-into-itself: Trying to move a range of nodes to the inside of that range.\",this)}else if(this.sourcePosition.root==this.targetPosition.root){if(Ns(this.sourcePosition.getParentPath(),this.targetPosition.getParentPath())==\"prefix\"){const t=this.sourcePosition.path.length-1;if(this.targetPosition.path[t]>=i&&this.targetPosition.path[t]<i+this.howMany){throw new ss[\"b\"](\"move-operation-node-into-itself: Trying to move a range of nodes into one of nodes from that range.\",this)}}}}_execute(){Gm(Kh._createFromPositionAndShift(this.sourcePosition,this.howMany),this.targetPosition)}toJSON(){const t=super.toJSON();t.sourcePosition=this.sourcePosition.toJSON();t.targetPosition=this.targetPosition.toJSON();return t}static get className(){return\"MoveOperation\"}static fromJSON(t,e){const i=$h.fromJSON(t.sourcePosition,e);const n=$h.fromJSON(t.targetPosition,e);return new this(i,t.howMany,n,t.baseVersion)}}class og extends Hm{constructor(t,e,i){super(i);this.position=t.clone();this.position.stickiness=\"toNone\";this.nodes=new Fh(Km(e));this.shouldReceiveAttributes=false}get type(){return\"insert\"}get howMany(){return this.nodes.maxOffset}clone(){const t=new Fh([...this.nodes].map(t=>t._clone(true)));const e=new og(this.position,t,this.baseVersion);e.shouldReceiveAttributes=this.shouldReceiveAttributes;return e}getReversed(){const t=this.position.root.document.graveyard;const e=new $h(t,[0]);return new ng(this.position,this.nodes.maxOffset,e,this.baseVersion+1)}_validate(){const t=this.position.parent;if(!t||t.maxOffset<this.position.offset){throw new ss[\"b\"](\"insert-operation-position-invalid: Insertion position is invalid.\",this)}}_execute(){const t=this.nodes;this.nodes=new Fh([...t].map(t=>t._clone(true)));$m(this.position,t)}toJSON(){const t=super.toJSON();t.position=this.position.toJSON();t.nodes=this.nodes.toJSON();return t}static get className(){return\"InsertOperation\"}static fromJSON(t,e){const i=[];for(const e of t.nodes){if(e.name){i.push(jh.fromJSON(e))}else{i.push(Dh.fromJSON(e))}}const n=new og($h.fromJSON(t.position,e),i,t.baseVersion);n.shouldReceiveAttributes=t.shouldReceiveAttributes;return n}}class rg extends Hm{constructor(t,e,i,n,o,r){super(r);this.name=t;this.oldRange=e?e.clone():null;this.newRange=i?i.clone():null;this.affectsData=o;this._markers=n}get type(){return\"marker\"}clone(){return new rg(this.name,this.oldRange,this.newRange,this._markers,this.affectsData,this.baseVersion)}getReversed(){return new rg(this.name,this.newRange,this.oldRange,this._markers,this.affectsData,this.baseVersion+1)}_execute(){const t=this.newRange?\"_set\":\"_remove\";this._markers[t](this.name,this.newRange,true,this.affectsData)}toJSON(){const t=super.toJSON();if(this.oldRange){t.oldRange=this.oldRange.toJSON()}if(this.newRange){t.newRange=this.newRange.toJSON()}delete t._markers;return t}static get className(){return\"MarkerOperation\"}static fromJSON(t,e){return new rg(t.name,t.oldRange?Kh.fromJSON(t.oldRange,e):null,t.newRange?Kh.fromJSON(t.newRange,e):null,e.model.markers,t.affectsData,t.baseVersion)}}class sg extends Hm{constructor(t,e,i,n){super(n);this.position=t;this.position.stickiness=\"toNext\";this.oldName=e;this.newName=i}get type(){return\"rename\"}clone(){return new sg(this.position.clone(),this.oldName,this.newName,this.baseVersion)}getReversed(){return new sg(this.position.clone(),this.newName,this.oldName,this.baseVersion+1)}_validate(){const t=this.position.nodeAfter;if(!(t instanceof jh)){throw new ss[\"b\"](\"rename-operation-wrong-position: Given position is invalid or node after it is not an instance of Element.\",this)}else if(t.name!==this.oldName){throw new ss[\"b\"](\"rename-operation-wrong-name: Element to change has different name than operation's old name.\",this)}}_execute(){const t=this.position.nodeAfter;t.name=this.newName}toJSON(){const t=super.toJSON();t.position=this.position.toJSON();return t}static get className(){return\"RenameOperation\"}static fromJSON(t,e){return new sg($h.fromJSON(t.position,e),t.oldName,t.newName,t.baseVersion)}}class ag extends Hm{constructor(t,e,i,n,o){super(o);this.root=t;this.key=e;this.oldValue=i;this.newValue=n}get type(){if(this.oldValue===null){return\"addRootAttribute\"}else if(this.newValue===null){return\"removeRootAttribute\"}else{return\"changeRootAttribute\"}}clone(){return new ag(this.root,this.key,this.oldValue,this.newValue,this.baseVersion)}getReversed(){return new ag(this.root,this.key,this.newValue,this.oldValue,this.baseVersion+1)}_validate(){if(this.root!=this.root.root||this.root.is(\"documentFragment\")){throw new ss[\"b\"](\"rootattribute-operation-not-a-root: The element to change is not a root element.\",this,{root:this.root,key:this.key})}if(this.oldValue!==null&&this.root.getAttribute(this.key)!==this.oldValue){throw new ss[\"b\"](\"rootattribute-operation-wrong-old-value: Changed node has different attribute value than operation's \"+\"old attribute value.\",this,{root:this.root,key:this.key})}if(this.oldValue===null&&this.newValue!==null&&this.root.hasAttribute(this.key)){throw new ss[\"b\"](\"rootattribute-operation-attribute-exists: The attribute with given key already exists.\",this,{root:this.root,key:this.key})}}_execute(){if(this.newValue!==null){this.root._setAttribute(this.key,this.newValue)}else{this.root._removeAttribute(this.key)}}toJSON(){const t=super.toJSON();t.root=this.root.toJSON();return t}static get className(){return\"RootAttributeOperation\"}static fromJSON(t,e){if(!e.getRoot(t.root)){throw new ss[\"b\"](\"rootattribute-operation-fromjson-no-root: Cannot create RootAttributeOperation. Root with specified name does not exist.\",this,{rootName:t.root})}return new ag(e.getRoot(t.root),t.key,t.oldValue,t.newValue,t.baseVersion)}}class lg extends Hm{constructor(t,e,i,n,o){super(o);this.sourcePosition=t.clone();this.sourcePosition.stickiness=\"toPrevious\";this.howMany=e;this.targetPosition=i.clone();this.targetPosition.stickiness=\"toNext\";this.graveyardPosition=n.clone()}get type(){return\"merge\"}get deletionPosition(){return new $h(this.sourcePosition.root,this.sourcePosition.path.slice(0,-1))}get movedRange(){const t=this.sourcePosition.getShiftedBy(Number.POSITIVE_INFINITY);return new Kh(this.sourcePosition,t)}clone(){return new this.constructor(this.sourcePosition,this.howMany,this.targetPosition,this.graveyardPosition,this.baseVersion)}getReversed(){const t=this.targetPosition._getTransformedByMergeOperation(this);const e=this.sourcePosition.path.slice(0,-1);const i=new $h(this.sourcePosition.root,e)._getTransformedByMergeOperation(this);const n=new cg(t,this.howMany,this.graveyardPosition,this.baseVersion+1);n.insertionPosition=i;return n}_validate(){const t=this.sourcePosition.parent;const e=this.targetPosition.parent;if(!t.parent){throw new ss[\"b\"](\"merge-operation-source-position-invalid: Merge source position is invalid.\",this)}else if(!e.parent){throw new ss[\"b\"](\"merge-operation-target-position-invalid: Merge target position is invalid.\",this)}else if(this.howMany!=t.maxOffset){throw new ss[\"b\"](\"merge-operation-how-many-invalid: Merge operation specifies wrong number of nodes to move.\",this)}}_execute(){const t=this.sourcePosition.parent;const e=Kh._createIn(t);Gm(e,this.targetPosition);Gm(Kh._createOn(t),this.graveyardPosition)}toJSON(){const t=super.toJSON();t.sourcePosition=t.sourcePosition.toJSON();t.targetPosition=t.targetPosition.toJSON();t.graveyardPosition=t.graveyardPosition.toJSON();return t}static get className(){return\"MergeOperation\"}static fromJSON(t,e){const i=$h.fromJSON(t.sourcePosition,e);const n=$h.fromJSON(t.targetPosition,e);const o=$h.fromJSON(t.graveyardPosition,e);return new this(i,t.howMany,n,o,t.baseVersion)}}class cg extends Hm{constructor(t,e,i,n){super(n);this.splitPosition=t.clone();this.splitPosition.stickiness=\"toNext\";this.howMany=e;this.insertionPosition=cg.getInsertionPosition(t);this.insertionPosition.stickiness=\"toNone\";this.graveyardPosition=i?i.clone():null;if(this.graveyardPosition){this.graveyardPosition.stickiness=\"toNext\"}}get type(){return\"split\"}get moveTargetPosition(){const t=this.insertionPosition.path.slice();t.push(0);return new $h(this.insertionPosition.root,t)}get movedRange(){const t=this.splitPosition.getShiftedBy(Number.POSITIVE_INFINITY);return new Kh(this.splitPosition,t)}clone(){const t=new this.constructor(this.splitPosition,this.howMany,this.graveyardPosition,this.baseVersion);t.insertionPosition=this.insertionPosition;return t}getReversed(){const t=this.splitPosition.root.document.graveyard;const e=new $h(t,[0]);return new lg(this.moveTargetPosition,this.howMany,this.splitPosition,e,this.baseVersion+1)}_validate(){const t=this.splitPosition.parent;const e=this.splitPosition.offset;if(!t||t.maxOffset<e){throw new ss[\"b\"](\"split-operation-position-invalid: Split position is invalid.\",this)}else if(!t.parent){throw new ss[\"b\"](\"split-operation-split-in-root: Cannot split root element.\",this)}else if(this.howMany!=t.maxOffset-this.splitPosition.offset){throw new ss[\"b\"](\"split-operation-how-many-invalid: Split operation specifies wrong number of nodes to move.\",this)}else if(this.graveyardPosition&&!this.graveyardPosition.nodeAfter){throw new ss[\"b\"](\"split-operation-graveyard-position-invalid: Graveyard position invalid.\",this)}}_execute(){const t=this.splitPosition.parent;if(this.graveyardPosition){Gm(Kh._createFromPositionAndShift(this.graveyardPosition,1),this.insertionPosition)}else{const e=t._clone();$m(this.insertionPosition,e)}const e=new Kh($h._createAt(t,this.splitPosition.offset),$h._createAt(t,t.maxOffset));Gm(e,this.moveTargetPosition)}toJSON(){const t=super.toJSON();t.splitPosition=this.splitPosition.toJSON();t.insertionPosition=this.insertionPosition.toJSON();if(this.graveyardPosition){t.graveyardPosition=this.graveyardPosition.toJSON()}return t}static get className(){return\"SplitOperation\"}static getInsertionPosition(t){const e=t.path.slice(0,-1);e[e.length-1]++;return new $h(t.root,e)}static fromJSON(t,e){const i=$h.fromJSON(t.splitPosition,e);const n=$h.fromJSON(t.insertionPosition,e);const o=t.graveyardPosition?$h.fromJSON(t.graveyardPosition,e):null;const r=new this(i,t.howMany,o,t.baseVersion);r.insertionPosition=n;return r}}class dg extends jh{constructor(t,e,i=\"main\"){super(e);this._document=t;this.rootName=i}get document(){return this._document}is(t,e){if(!e){return t===\"rootElement\"||t===\"model:rootElement\"||t===\"element\"||t===\"model:element\"||t===this.name||t===\"model:\"+this.name||t===\"node\"||t===\"model:node\"}return e===this.name&&(t===\"rootElement\"||t===\"model:rootElement\"||t===\"element\"||t===\"model:element\")}toJSON(){return this.rootName}}class ug{constructor(t,e){this.model=t;this.batch=e}createText(t,e){return new Dh(t,e)}createElement(t,e){return new jh(t,e)}createDocumentFragment(){return new Wm}insert(t,e,i=0){this._assertWriterUsedCorrectly();if(t instanceof Dh&&t.data==\"\"){return}const n=$h._createAt(e,i);if(t.parent){if(pg(t.root,n.root)){this.move(Kh._createOn(t),n);return}else{if(t.root.document){throw new ss[\"b\"](\"model-writer-insert-forbidden-move: \"+\"Cannot move a node from a document to a different tree. \"+\"It is forbidden to move a node that was already in a document outside of it.\",this)}else{this.remove(t)}}}const o=n.root.document?n.root.document.version:null;const r=new og(n,t,o);if(t instanceof Dh){r.shouldReceiveAttributes=true}this.batch.addOperation(r);this.model.applyOperation(r);if(t instanceof Wm){for(const[e,i]of t.markers){const t=$h._createAt(i.root,0);const o=new Kh(i.start._getCombined(t,n),i.end._getCombined(t,n));const r={range:o,usingOperation:true,affectsData:true};if(this.model.markers.has(e)){this.updateMarker(e,r)}else{this.addMarker(e,r)}}}}insertText(t,e,i,n){if(e instanceof Wm||e instanceof jh||e instanceof $h){this.insert(this.createText(t),e,i)}else{this.insert(this.createText(t,e),i,n)}}insertElement(t,e,i,n){if(e instanceof Wm||e instanceof jh||e instanceof $h){this.insert(this.createElement(t),e,i)}else{this.insert(this.createElement(t,e),i,n)}}append(t,e){this.insert(t,e,\"end\")}appendText(t,e,i){if(e instanceof Wm||e instanceof jh){this.insert(this.createText(t),e,\"end\")}else{this.insert(this.createText(t,e),i,\"end\")}}appendElement(t,e,i){if(e instanceof Wm||e instanceof jh){this.insert(this.createElement(t),e,\"end\")}else{this.insert(this.createElement(t,e),i,\"end\")}}setAttribute(t,e,i){this._assertWriterUsedCorrectly();if(i instanceof Kh){const n=i.getMinimalFlatRanges();for(const i of n){hg(this,t,e,i)}}else{fg(this,t,e,i)}}setAttributes(t,e){for(const[i,n]of Ws(t)){this.setAttribute(i,n,e)}}removeAttribute(t,e){this._assertWriterUsedCorrectly();if(e instanceof Kh){const i=e.getMinimalFlatRanges();for(const e of i){hg(this,t,null,e)}}else{fg(this,t,null,e)}}clearAttributes(t){this._assertWriterUsedCorrectly();const e=t=>{for(const e of t.getAttributeKeys()){this.removeAttribute(e,t)}};if(!(t instanceof Kh)){e(t)}else{for(const i of t.getItems()){e(i)}}}move(t,e,i){this._assertWriterUsedCorrectly();if(!(t instanceof Kh)){throw new ss[\"b\"](\"writer-move-invalid-range: Invalid range to move.\",this)}if(!t.isFlat){throw new ss[\"b\"](\"writer-move-range-not-flat: Range to move is not flat.\",this)}const n=$h._createAt(e,i);if(n.isEqual(t.start)){return}this._addOperationForAffectedMarkers(\"move\",t);if(!pg(t.root,n.root)){throw new ss[\"b\"](\"writer-move-different-document: Range is going to be moved between different documents.\",this)}const o=t.root.document?t.root.document.version:null;const r=new ng(t.start,t.end.offset-t.start.offset,n,o);this.batch.addOperation(r);this.model.applyOperation(r)}remove(t){this._assertWriterUsedCorrectly();const e=t instanceof Kh?t:Kh._createOn(t);const i=e.getMinimalFlatRanges().reverse();for(const t of i){this._addOperationForAffectedMarkers(\"move\",t);gg(t.start,t.end.offset-t.start.offset,this.batch,this.model)}}merge(t){this._assertWriterUsedCorrectly();const e=t.nodeBefore;const i=t.nodeAfter;this._addOperationForAffectedMarkers(\"merge\",t);if(!(e instanceof jh)){throw new ss[\"b\"](\"writer-merge-no-element-before: Node before merge position must be an element.\",this)}if(!(i instanceof jh)){throw new ss[\"b\"](\"writer-merge-no-element-after: Node after merge position must be an element.\",this)}if(!t.root.document){this._mergeDetached(t)}else{this._merge(t)}}createPositionFromPath(t,e,i){return this.model.createPositionFromPath(t,e,i)}createPositionAt(t,e){return this.model.createPositionAt(t,e)}createPositionAfter(t){return this.model.createPositionAfter(t)}createPositionBefore(t){return this.model.createPositionBefore(t)}createRange(t,e){return this.model.createRange(t,e)}createRangeIn(t){return this.model.createRangeIn(t)}createRangeOn(t){return this.model.createRangeOn(t)}createSelection(t,e,i){return this.model.createSelection(t,e,i)}_mergeDetached(t){const e=t.nodeBefore;const i=t.nodeAfter;this.move(Kh._createIn(i),$h._createAt(e,\"end\"));this.remove(i)}_merge(t){const e=$h._createAt(t.nodeBefore,\"end\");const i=$h._createAt(t.nodeAfter,0);const n=t.root.document.graveyard;const o=new $h(n,[0]);const r=t.root.document.version;const s=new lg(i,t.nodeAfter.maxOffset,e,o,r);this.batch.addOperation(s);this.model.applyOperation(s)}rename(t,e){this._assertWriterUsedCorrectly();if(!(t instanceof jh)){throw new ss[\"b\"](\"writer-rename-not-element-instance: Trying to rename an object which is not an instance of Element.\",this)}const i=t.root.document?t.root.document.version:null;const n=new sg($h._createBefore(t),t.name,e,i);this.batch.addOperation(n);this.model.applyOperation(n)}split(t,e){this._assertWriterUsedCorrectly();let i=t.parent;if(!i.parent){throw new ss[\"b\"](\"writer-split-element-no-parent: Element with no parent can not be split.\",this)}if(!e){e=i.parent}if(!t.parent.getAncestors({includeSelf:true}).includes(e)){throw new ss[\"b\"](\"writer-split-invalid-limit-element: Limit element is not a position ancestor.\",this)}let n,o;do{const e=i.root.document?i.root.document.version:null;const r=i.maxOffset-t.offset;const s=new cg(t,r,null,e);this.batch.addOperation(s);this.model.applyOperation(s);if(!n&&!o){n=i;o=t.parent.nextSibling}t=this.createPositionAfter(t.parent);i=t.parent}while(i!==e);return{position:t,range:new Kh($h._createAt(n,\"end\"),$h._createAt(o,0))}}wrap(t,e){this._assertWriterUsedCorrectly();if(!t.isFlat){throw new ss[\"b\"](\"writer-wrap-range-not-flat: Range to wrap is not flat.\",this)}const i=e instanceof jh?e:new jh(e);if(i.childCount>0){throw new ss[\"b\"](\"writer-wrap-element-not-empty: Element to wrap with is not empty.\",this)}if(i.parent!==null){throw new ss[\"b\"](\"writer-wrap-element-attached: Element to wrap with is already attached to tree model.\",this)}this.insert(i,t.start);const n=new Kh(t.start.getShiftedBy(1),t.end.getShiftedBy(1));this.move(n,$h._createAt(i,0))}unwrap(t){this._assertWriterUsedCorrectly();if(t.parent===null){throw new ss[\"b\"](\"writer-unwrap-element-no-parent: Trying to unwrap an element which has no parent.\",this)}this.move(Kh._createIn(t),this.createPositionAfter(t));this.remove(t)}addMarker(t,e){this._assertWriterUsedCorrectly();if(!e||typeof e.usingOperation!=\"boolean\"){throw new ss[\"b\"](\"writer-addMarker-no-usingOperation: The options.usingOperation parameter is required when adding a new marker.\",this)}const i=e.usingOperation;const n=e.range;const o=e.affectsData===undefined?false:e.affectsData;if(this.model.markers.has(t)){throw new ss[\"b\"](\"writer-addMarker-marker-exists: Marker with provided name already exists.\",this)}if(!n){throw new ss[\"b\"](\"writer-addMarker-no-range: Range parameter is required when adding a new marker.\",this)}if(!i){return this.model.markers._set(t,n,i,o)}mg(this,t,null,n,o);return this.model.markers.get(t)}updateMarker(t,e){this._assertWriterUsedCorrectly();const i=typeof t==\"string\"?t:t.name;const n=this.model.markers.get(i);if(!n){throw new ss[\"b\"](\"writer-updateMarker-marker-not-exists: Marker with provided name does not exists.\",this)}if(!e){this.model.markers._refresh(n);return}const o=typeof e.usingOperation==\"boolean\";const r=typeof e.affectsData==\"boolean\";const s=r?e.affectsData:n.affectsData;if(!o&&!e.range&&!r){throw new ss[\"b\"](\"writer-updateMarker-wrong-options: One of the options is required - provide range, usingOperations or affectsData.\",this)}const a=n.getRange();const l=e.range?e.range:a;if(o&&e.usingOperation!==n.managedUsingOperations){if(e.usingOperation){mg(this,i,null,l,s)}else{mg(this,i,a,null,s);this.model.markers._set(i,l,undefined,s)}return}if(n.managedUsingOperations){mg(this,i,a,l,s)}else{this.model.markers._set(i,l,undefined,s)}}removeMarker(t){this._assertWriterUsedCorrectly();const e=typeof t==\"string\"?t:t.name;if(!this.model.markers.has(e)){throw new ss[\"b\"](\"writer-removeMarker-no-marker: Trying to remove marker which does not exist.\",this)}const i=this.model.markers.get(e);if(!i.managedUsingOperations){this.model.markers._remove(e);return}const n=i.getRange();mg(this,e,n,null,i.affectsData)}setSelection(t,e,i){this._assertWriterUsedCorrectly();this.model.document.selection._setTo(t,e,i)}setSelectionFocus(t,e){this._assertWriterUsedCorrectly();this.model.document.selection._setFocus(t,e)}setSelectionAttribute(t,e){this._assertWriterUsedCorrectly();if(typeof t===\"string\"){this._setSelectionAttribute(t,e)}else{for(const[e,i]of Ws(t)){this._setSelectionAttribute(e,i)}}}removeSelectionAttribute(t){this._assertWriterUsedCorrectly();if(typeof t===\"string\"){this._removeSelectionAttribute(t)}else{for(const e of t){this._removeSelectionAttribute(e)}}}overrideSelectionGravity(){return this.model.document.selection._overrideGravity()}restoreSelectionGravity(t){this.model.document.selection._restoreGravity(t)}_setSelectionAttribute(t,e){const i=this.model.document.selection;if(i.isCollapsed&&i.anchor.parent.isEmpty){const n=ff._getStoreAttributeKey(t);this.setAttribute(n,e,i.anchor.parent)}i._setAttribute(t,e)}_removeSelectionAttribute(t){const e=this.model.document.selection;if(e.isCollapsed&&e.anchor.parent.isEmpty){const i=ff._getStoreAttributeKey(t);this.removeAttribute(i,e.anchor.parent)}e._removeAttribute(t)}_assertWriterUsedCorrectly(){if(this.model._currentWriter!==this){throw new ss[\"b\"](\"writer-incorrect-use: Trying to use a writer outside the change() block.\",this)}}_addOperationForAffectedMarkers(t,e){for(const i of this.model.markers){if(!i.managedUsingOperations){continue}const n=i.getRange();let o=false;if(t===\"move\"){o=e.containsPosition(n.start)||e.start.isEqual(n.start)||e.containsPosition(n.end)||e.end.isEqual(n.end)}else{const t=e.nodeBefore;const i=e.nodeAfter;const r=n.start.parent==t&&n.start.isAtEnd;const s=n.end.parent==i&&n.end.offset==0;const a=n.end.nodeAfter==i;const l=n.start.nodeAfter==i;o=r||s||a||l}if(o){this.updateMarker(i.name,{range:n})}}}}function hg(t,e,i,n){const o=t.model;const r=o.document;let s=n.start;let a;let l;let c;for(const t of n.getWalker({shallow:true})){c=t.item.getAttribute(e);if(a&&l!=c){if(l!=i){d()}s=a}a=t.nextPosition;l=c}if(a instanceof $h&&a!=s&&l!=i){d()}function d(){const n=new Kh(s,a);const c=n.root.document?r.version:null;const d=new eg(n,e,l,i,c);t.batch.addOperation(d);o.applyOperation(d)}}function fg(t,e,i,n){const o=t.model;const r=o.document;const s=n.getAttribute(e);let a,l;if(s!=i){const c=n.root===n;if(c){const t=n.document?r.version:null;l=new ag(n,e,s,i,t)}else{a=new Kh($h._createBefore(n),t.createPositionAfter(n));const o=a.root.document?r.version:null;l=new eg(a,e,s,i,o)}t.batch.addOperation(l);o.applyOperation(l)}}function mg(t,e,i,n,o){const r=t.model;const s=r.document;const a=new rg(e,i,n,r.markers,o,s.version);t.batch.addOperation(a);r.applyOperation(a)}function gg(t,e,i,n){let o;if(t.root.document){const i=n.document;const r=new $h(i.graveyard,[0]);o=new ng(t,e,r,i.version)}else{o=new ig(t,e)}i.addOperation(o);n.applyOperation(o)}function pg(t,e){if(t===e){return true}if(t instanceof dg&&e instanceof dg){return true}return false}class bg{constructor(t){this._markerCollection=t;this._changesInElement=new Map;this._elementSnapshots=new Map;this._changedMarkers=new Map;this._changeCount=0;this._cachedChanges=null;this._cachedChangesWithGraveyard=null}get isEmpty(){return this._changesInElement.size==0&&this._changedMarkers.size==0}refreshItem(t){if(this._isInInsertedElement(t.parent)){return}this._markRemove(t.parent,t.startOffset,t.offsetSize);this._markInsert(t.parent,t.startOffset,t.offsetSize);const e=Kh._createOn(t);for(const t of this._markerCollection.getMarkersIntersectingRange(e)){const e=t.getRange();this.bufferMarkerChange(t.name,e,e,t.affectsData)}this._cachedChanges=null}bufferOperation(t){switch(t.type){case\"insert\":{if(this._isInInsertedElement(t.position.parent)){return}this._markInsert(t.position.parent,t.position.offset,t.nodes.maxOffset);break}case\"addAttribute\":case\"removeAttribute\":case\"changeAttribute\":{for(const e of t.range.getItems({shallow:true})){if(this._isInInsertedElement(e.parent)){continue}this._markAttribute(e)}break}case\"remove\":case\"move\":case\"reinsert\":{if(t.sourcePosition.isEqual(t.targetPosition)||t.sourcePosition.getShiftedBy(t.howMany).isEqual(t.targetPosition)){return}const e=this._isInInsertedElement(t.sourcePosition.parent);const i=this._isInInsertedElement(t.targetPosition.parent);if(!e){this._markRemove(t.sourcePosition.parent,t.sourcePosition.offset,t.howMany)}if(!i){this._markInsert(t.targetPosition.parent,t.getMovedRangeStart().offset,t.howMany)}break}case\"rename\":{if(this._isInInsertedElement(t.position.parent)){return}this._markRemove(t.position.parent,t.position.offset,1);this._markInsert(t.position.parent,t.position.offset,1);const e=Kh._createFromPositionAndShift(t.position,1);for(const t of this._markerCollection.getMarkersIntersectingRange(e)){const e=t.getRange();this.bufferMarkerChange(t.name,e,e,t.affectsData)}break}case\"split\":{const e=t.splitPosition.parent;if(!this._isInInsertedElement(e)){this._markRemove(e,t.splitPosition.offset,t.howMany)}if(!this._isInInsertedElement(t.insertionPosition.parent)){this._markInsert(t.insertionPosition.parent,t.insertionPosition.offset,1)}if(t.graveyardPosition){this._markRemove(t.graveyardPosition.parent,t.graveyardPosition.offset,1)}break}case\"merge\":{const e=t.sourcePosition.parent;if(!this._isInInsertedElement(e.parent)){this._markRemove(e.parent,e.startOffset,1)}const i=t.graveyardPosition.parent;this._markInsert(i,t.graveyardPosition.offset,1);const n=t.targetPosition.parent;if(!this._isInInsertedElement(n)){this._markInsert(n,t.targetPosition.offset,e.maxOffset)}break}}this._cachedChanges=null}bufferMarkerChange(t,e,i,n){const o=this._changedMarkers.get(t);if(!o){this._changedMarkers.set(t,{oldRange:e,newRange:i,affectsData:n})}else{o.newRange=i;o.affectsData=n;if(o.oldRange==null&&o.newRange==null){this._changedMarkers.delete(t)}}}getMarkersToRemove(){const t=[];for(const[e,i]of this._changedMarkers){if(i.oldRange!=null){t.push({name:e,range:i.oldRange})}}return t}getMarkersToAdd(){const t=[];for(const[e,i]of this._changedMarkers){if(i.newRange!=null){t.push({name:e,range:i.newRange})}}return t}getChangedMarkers(){return Array.from(this._changedMarkers).map(t=>({name:t[0],data:{oldRange:t[1].oldRange,newRange:t[1].newRange}}))}hasDataChanges(){for(const[,t]of this._changedMarkers){if(t.affectsData){return true}}return this._changesInElement.size>0}getChanges(t={includeChangesInGraveyard:false}){if(this._cachedChanges){if(t.includeChangesInGraveyard){return this._cachedChangesWithGraveyard.slice()}else{return this._cachedChanges.slice()}}const e=[];for(const t of this._changesInElement.keys()){const i=this._changesInElement.get(t).sort((t,e)=>{if(t.offset===e.offset){if(t.type!=e.type){return t.type==\"remove\"?-1:1}return 0}return t.offset<e.offset?-1:1});const n=this._elementSnapshots.get(t);const o=wg(t.getChildren());const r=_g(n.length,i);let s=0;let a=0;for(const i of r){if(i===\"i\"){e.push(this._getInsertDiff(t,s,o[s].name));s++}else if(i===\"r\"){e.push(this._getRemoveDiff(t,s,n[a].name));a++}else if(i===\"a\"){const i=o[s].attributes;const r=n[a].attributes;let l;if(o[s].name==\"$text\"){l=new Kh($h._createAt(t,s),$h._createAt(t,s+1))}else{const e=t.offsetToIndex(s);l=new Kh($h._createAt(t,s),$h._createAt(t.getChild(e),0))}e.push(...this._getAttributesDiff(l,r,i));s++;a++}else{s++;a++}}}e.sort((t,e)=>{if(t.position.root!=e.position.root){return t.position.root.rootName<e.position.root.rootName?-1:1}if(t.position.isEqual(e.position)){return t.changeCount-e.changeCount}return t.position.isBefore(e.position)?-1:1});for(let t=1;t<e.length;t++){const i=e[t-1];const n=e[t];const o=i.type==\"remove\"&&n.type==\"remove\"&&i.name==\"$text\"&&n.name==\"$text\"&&i.position.isEqual(n.position);const r=i.type==\"insert\"&&n.type==\"insert\"&&i.name==\"$text\"&&n.name==\"$text\"&&i.position.parent==n.position.parent&&i.position.offset+i.length==n.position.offset;const s=i.type==\"attribute\"&&n.type==\"attribute\"&&i.position.parent==n.position.parent&&i.range.isFlat&&n.range.isFlat&&i.position.offset+i.length==n.position.offset&&i.attributeKey==n.attributeKey&&i.attributeOldValue==n.attributeOldValue&&i.attributeNewValue==n.attributeNewValue;if(o||r||s){e[t-1].length++;if(s){e[t-1].range.end=e[t-1].range.end.getShiftedBy(1)}e.splice(t,1);t--}}for(const t of e){delete t.changeCount;if(t.type==\"attribute\"){delete t.position;delete t.length}}this._changeCount=0;this._cachedChangesWithGraveyard=e.slice();this._cachedChanges=e.slice().filter(kg);if(t.includeChangesInGraveyard){return this._cachedChangesWithGraveyard}else{return this._cachedChanges}}reset(){this._changesInElement.clear();this._elementSnapshots.clear();this._changedMarkers.clear();this._cachedChanges=null}_markInsert(t,e,i){const n={type:\"insert\",offset:e,howMany:i,count:this._changeCount++};this._markChange(t,n)}_markRemove(t,e,i){const n={type:\"remove\",offset:e,howMany:i,count:this._changeCount++};this._markChange(t,n);this._removeAllNestedChanges(t,e,i)}_markAttribute(t){const e={type:\"attribute\",offset:t.startOffset,howMany:t.offsetSize,count:this._changeCount++};this._markChange(t.parent,e)}_markChange(t,e){this._makeSnapshot(t);const i=this._getChangesForElement(t);this._handleChange(e,i);i.push(e);for(let t=0;t<i.length;t++){if(i[t].howMany<1){i.splice(t,1);t--}}}_getChangesForElement(t){let e;if(this._changesInElement.has(t)){e=this._changesInElement.get(t)}else{e=[];this._changesInElement.set(t,e)}return e}_makeSnapshot(t){if(!this._elementSnapshots.has(t)){this._elementSnapshots.set(t,wg(t.getChildren()))}}_handleChange(t,e){t.nodesToHandle=t.howMany;for(const i of e){const n=t.offset+t.howMany;const o=i.offset+i.howMany;if(t.type==\"insert\"){if(i.type==\"insert\"){if(t.offset<=i.offset){i.offset+=t.howMany}else if(t.offset<o){i.howMany+=t.nodesToHandle;t.nodesToHandle=0}}if(i.type==\"remove\"){if(t.offset<i.offset){i.offset+=t.howMany}}if(i.type==\"attribute\"){if(t.offset<=i.offset){i.offset+=t.howMany}else if(t.offset<o){const o=i.howMany;i.howMany=t.offset-i.offset;e.unshift({type:\"attribute\",offset:n,howMany:o-i.howMany,count:this._changeCount++})}}}if(t.type==\"remove\"){if(i.type==\"insert\"){if(n<=i.offset){i.offset-=t.howMany}else if(n<=o){if(t.offset<i.offset){const e=n-i.offset;i.offset=t.offset;i.howMany-=e;t.nodesToHandle-=e}else{i.howMany-=t.nodesToHandle;t.nodesToHandle=0}}else{if(t.offset<=i.offset){t.nodesToHandle-=i.howMany;i.howMany=0}else if(t.offset<o){const e=o-t.offset;i.howMany-=e;t.nodesToHandle-=e}}}if(i.type==\"remove\"){if(n<=i.offset){i.offset-=t.howMany}else if(t.offset<i.offset){t.nodesToHandle+=i.howMany;i.howMany=0}}if(i.type==\"attribute\"){if(n<=i.offset){i.offset-=t.howMany}else if(t.offset<i.offset){const e=n-i.offset;i.offset=t.offset;i.howMany-=e}else if(t.offset<o){if(n<=o){const n=i.howMany;i.howMany=t.offset-i.offset;const o=n-i.howMany-t.nodesToHandle;e.unshift({type:\"attribute\",offset:t.offset,howMany:o,count:this._changeCount++})}else{i.howMany-=o-t.offset}}}}if(t.type==\"attribute\"){if(i.type==\"insert\"){if(t.offset<i.offset&&n>i.offset){if(n>o){const t={type:\"attribute\",offset:o,howMany:n-o,count:this._changeCount++};this._handleChange(t,e);e.push(t)}t.nodesToHandle=i.offset-t.offset;t.howMany=t.nodesToHandle}else if(t.offset>=i.offset&&t.offset<o){if(n>o){t.nodesToHandle=n-o;t.offset=o}else{t.nodesToHandle=0}}}if(i.type==\"remove\"){if(t.offset<i.offset&&n>i.offset){const o={type:\"attribute\",offset:i.offset,howMany:n-i.offset,count:this._changeCount++};this._handleChange(o,e);e.push(o);t.nodesToHandle=i.offset-t.offset;t.howMany=t.nodesToHandle}}if(i.type==\"attribute\"){if(t.offset>=i.offset&&n<=o){t.nodesToHandle=0;t.howMany=0;t.offset=0}else if(t.offset<=i.offset&&n>=o){i.howMany=0}}}}t.howMany=t.nodesToHandle;delete t.nodesToHandle}_getInsertDiff(t,e,i){return{type:\"insert\",position:$h._createAt(t,e),name:i,length:1,changeCount:this._changeCount++}}_getRemoveDiff(t,e,i){return{type:\"remove\",position:$h._createAt(t,e),name:i,length:1,changeCount:this._changeCount++}}_getAttributesDiff(t,e,i){const n=[];i=new Map(i);for(const[o,r]of e){const e=i.has(o)?i.get(o):null;if(e!==r){n.push({type:\"attribute\",position:t.start,range:t.clone(),length:1,attributeKey:o,attributeOldValue:r,attributeNewValue:e,changeCount:this._changeCount++})}i.delete(o)}for(const[e,o]of i){n.push({type:\"attribute\",position:t.start,range:t.clone(),length:1,attributeKey:e,attributeOldValue:null,attributeNewValue:o,changeCount:this._changeCount++})}return n}_isInInsertedElement(t){const e=t.parent;if(!e){return false}const i=this._changesInElement.get(e);const n=t.startOffset;if(i){for(const t of i){if(t.type==\"insert\"&&n>=t.offset&&n<t.offset+t.howMany){return true}}}return this._isInInsertedElement(e)}_removeAllNestedChanges(t,e,i){const n=new Kh($h._createAt(t,e),$h._createAt(t,e+i));for(const t of n.getItems({shallow:true})){if(t.is(\"element\")){this._elementSnapshots.delete(t);this._changesInElement.delete(t);this._removeAllNestedChanges(t,0,t.maxOffset)}}}}function wg(t){const e=[];for(const i of t){if(i.is(\"text\")){for(let t=0;t<i.data.length;t++){e.push({name:\"$text\",attributes:new Map(i.getAttributes())})}}else{e.push({name:i.name,attributes:new Map(i.getAttributes())})}}return e}function _g(t,e){const i=[];let n=0;let o=0;for(const t of e){if(t.offset>n){for(let e=0;e<t.offset-n;e++){i.push(\"e\")}o+=t.offset-n}if(t.type==\"insert\"){for(let e=0;e<t.howMany;e++){i.push(\"i\")}n=t.offset+t.howMany}else if(t.type==\"remove\"){for(let e=0;e<t.howMany;e++){i.push(\"r\")}n=t.offset;o+=t.howMany}else{i.push(...\"a\".repeat(t.howMany).split(\"\"));n=t.offset+t.howMany;o+=t.howMany}}if(o<t){for(let e=0;e<t-o-n;e++){i.push(\"e\")}}return i}function kg(t){const e=t.position&&t.position.root.rootName==\"$graveyard\";const i=t.range&&t.range.root.rootName==\"$graveyard\";return!e&&!i}class vg{constructor(){this._operations=[];this._undoPairs=new Map;this._undoneOperations=new Set}addOperation(t){if(this._operations.includes(t)){return}this._operations.push(t)}getOperations(t=0,e=Number.POSITIVE_INFINITY){if(t<0){return[]}return this._operations.slice(t,e)}getOperation(t){return this._operations[t]}setOperationAsUndone(t,e){this._undoPairs.set(e,t);this._undoneOperations.add(t)}isUndoingOperation(t){return this._undoPairs.has(t)}isUndoneOperation(t){return this._undoneOperations.has(t)}getUndoneOperation(t){return this._undoPairs.get(t)}}function yg(t){return!!t&&t.length==1&&/[\\u0300-\\u036f\\u1ab0-\\u1aff\\u1dc0-\\u1dff\\u20d0-\\u20ff\\ufe20-\\ufe2f]/.test(t)}function xg(t){return!!t&&t.length==1&&/[\\ud800-\\udbff]/.test(t)}function Cg(t){return!!t&&t.length==1&&/[\\udc00-\\udfff]/.test(t)}function Ag(t,e){return xg(t.charAt(e-1))&&Cg(t.charAt(e))}function Tg(t,e){return yg(t.charAt(e))}const Pg=\"$graveyard\";class Eg{constructor(t){this.model=t;this.version=0;this.history=new vg(this);this.selection=new ff(this);this.roots=new xs({idProperty:\"rootName\"});this.differ=new bg(t.markers);this._postFixers=new Set;this._hasSelectionChangedFromTheLastChangeBlock=false;this.createRoot(\"$root\",Pg);this.listenTo(t,\"applyOperation\",(t,e)=>{const i=e[0];if(i.isDocumentOperation&&i.baseVersion!==this.version){throw new ss[\"b\"](\"model-document-applyOperation-wrong-version: Only operations with matching versions can be applied.\",this,{operation:i})}},{priority:\"highest\"});this.listenTo(t,\"applyOperation\",(t,e)=>{const i=e[0];if(i.isDocumentOperation){this.differ.bufferOperation(i)}},{priority:\"high\"});this.listenTo(t,\"applyOperation\",(t,e)=>{const i=e[0];if(i.isDocumentOperation){this.version++;this.history.addOperation(i)}},{priority:\"low\"});this.listenTo(this.selection,\"change\",()=>{this._hasSelectionChangedFromTheLastChangeBlock=true});this.listenTo(t.markers,\"update\",(t,e,i,n)=>{this.differ.bufferMarkerChange(e.name,i,n,e.affectsData);if(i===null){e.on(\"change\",(t,i)=>{this.differ.bufferMarkerChange(e.name,i,e.getRange(),e.affectsData)})}})}get graveyard(){return this.getRoot(Pg)}createRoot(t=\"$root\",e=\"main\"){if(this.roots.get(e)){throw new ss[\"b\"](\"model-document-createRoot-name-exists: Root with specified name already exists.\",this,{name:e})}const i=new dg(this,t,e);this.roots.add(i);return i}destroy(){this.selection.destroy();this.stopListening()}getRoot(t=\"main\"){return this.roots.get(t)}getRootNames(){return Array.from(this.roots,t=>t.rootName).filter(t=>t!=Pg)}registerPostFixer(t){this._postFixers.add(t)}toJSON(){const t=Ds(this);t.selection=\"[engine.model.DocumentSelection]\";t.model=\"[engine.model.Model]\";return t}_handleChangeBlock(t){if(this._hasDocumentChangedFromTheLastChangeBlock()){this._callPostFixers(t);this.selection.refresh();if(this.differ.hasDataChanges()){this.fire(\"change:data\",t.batch)}else{this.fire(\"change\",t.batch)}this.selection.refresh();this.differ.reset()}this._hasSelectionChangedFromTheLastChangeBlock=false}_hasDocumentChangedFromTheLastChangeBlock(){return!this.differ.isEmpty||this._hasSelectionChangedFromTheLastChangeBlock}_getDefaultRoot(){for(const t of this.roots){if(t!==this.graveyard){return t}}return this.graveyard}_getDefaultRange(){const t=this._getDefaultRoot();const e=this.model;const i=e.schema;const n=e.createPositionFromPath(t,[0]);const o=i.getNearestSelectionRange(n);return o||e.createRange(n)}_validateSelectionRange(t){return Sg(t.start)&&Sg(t.end)}_callPostFixers(t){let e=false;do{for(const i of this._postFixers){this.selection.refresh();e=i(t);if(e){break}}}while(e)}}ys(Eg,ds);function Sg(t){const e=t.textNode;if(e){const i=e.data;const n=t.offset-e.startOffset;return!Ag(i,n)&&!Tg(i,n)}return true}class Mg{constructor(){this._markers=new Map}[Symbol.iterator](){return this._markers.values()}has(t){return this._markers.has(t)}get(t){return this._markers.get(t)||null}_set(t,e,i=false,n=false){const o=t instanceof Og?t.name:t;const r=this._markers.get(o);if(r){const t=r.getRange();let s=false;if(!t.isEqual(e)){r._attachLiveRange(lf.fromRange(e));s=true}if(i!=r.managedUsingOperations){r._managedUsingOperations=i;s=true}if(typeof n===\"boolean\"&&n!=r.affectsData){r._affectsData=n;s=true}if(s){this.fire(\"update:\"+o,r,t,e)}return r}const s=lf.fromRange(e);const a=new Og(o,s,i,n);this._markers.set(o,a);this.fire(\"update:\"+o,a,null,e);return a}_remove(t){const e=t instanceof Og?t.name:t;const i=this._markers.get(e);if(i){this._markers.delete(e);this.fire(\"update:\"+e,i,i.getRange(),null);this._destroyMarker(i);return true}return false}_refresh(t){const e=t instanceof Og?t.name:t;const i=this._markers.get(e);if(!i){throw new ss[\"b\"](\"markercollection-refresh-marker-not-exists: Marker with provided name does not exists.\",this)}const n=i.getRange();this.fire(\"update:\"+e,i,n,n,i.managedUsingOperations,i.affectsData)}*getMarkersAtPosition(t){for(const e of this){if(e.getRange().containsPosition(t)){yield e}}}*getMarkersIntersectingRange(t){for(const e of this){if(e.getRange().getIntersection(t)!==null){yield e}}}destroy(){for(const t of this._markers.values()){this._destroyMarker(t)}this._markers=null;this.stopListening()}*getMarkersGroup(t){for(const e of this._markers.values()){if(e.name.startsWith(t+\":\")){yield e}}}_destroyMarker(t){t.stopListening();t._detachLiveRange()}}ys(Mg,ds);class Og{constructor(t,e,i,n){this.name=t;this._liveRange=this._attachLiveRange(e);this._managedUsingOperations=i;this._affectsData=n}get managedUsingOperations(){if(!this._liveRange){throw new ss[\"b\"](\"marker-destroyed: Cannot use a destroyed marker instance.\",this)}return this._managedUsingOperations}get affectsData(){if(!this._liveRange){throw new ss[\"b\"](\"marker-destroyed: Cannot use a destroyed marker instance.\",this)}return this._affectsData}getStart(){if(!this._liveRange){throw new ss[\"b\"](\"marker-destroyed: Cannot use a destroyed marker instance.\",this)}return this._liveRange.start.clone()}getEnd(){if(!this._liveRange){throw new ss[\"b\"](\"marker-destroyed: Cannot use a destroyed marker instance.\",this)}return this._liveRange.end.clone()}getRange(){if(!this._liveRange){throw new ss[\"b\"](\"marker-destroyed: Cannot use a destroyed marker instance.\",this)}return this._liveRange.toRange()}is(t){return t===\"marker\"||t===\"model:marker\"}_attachLiveRange(t){if(this._liveRange){this._detachLiveRange()}t.delegate(\"change:range\").to(this);t.delegate(\"change:content\").to(this);this._liveRange=t;return t}_detachLiveRange(){this._liveRange.stopDelegating(\"change:range\",this);this._liveRange.stopDelegating(\"change:content\",this);this._liveRange.detach();this._liveRange=null}}ys(Og,ds);class Ig extends Hm{get type(){return\"noop\"}clone(){return new Ig(this.baseVersion)}getReversed(){return new Ig(this.baseVersion+1)}_execute(){}static get className(){return\"NoOperation\"}}const Rg={};Rg[eg.className]=eg;Rg[og.className]=og;Rg[rg.className]=rg;Rg[ng.className]=ng;Rg[Ig.className]=Ig;Rg[Hm.className]=Hm;Rg[sg.className]=sg;Rg[ag.className]=ag;Rg[cg.className]=cg;Rg[lg.className]=lg;class Lg{static fromJSON(t,e){return Rg[t.__className].fromJSON(t,e)}}class Ng extends $h{constructor(t,e,i=\"toNone\"){super(t,e,i);if(!this.root.is(\"rootElement\")){throw new ss[\"b\"](\"model-liveposition-root-not-rootelement: LivePosition's root has to be an instance of RootElement.\",t)}Bg.call(this)}detach(){this.stopListening()}is(t){return t===\"livePosition\"||t===\"model:livePosition\"||t==\"position\"||t===\"model:position\"}toPosition(){return new $h(this.root,this.path.slice(),this.stickiness)}static fromPosition(t,e){return new this(t.root,t.path.slice(),e?e:t.stickiness)}}function Bg(){this.listenTo(this.root.document.model,\"applyOperation\",(t,e)=>{const i=e[0];if(!i.isDocumentOperation){return}Vg.call(this,i)},{priority:\"low\"})}function Vg(t){const e=this.getTransformedByOperation(t);if(!this.isEqual(e)){const t=this.toPosition();this.path=e.path;this.root=e.root;this.fire(\"change\",t)}}ys(Ng,ds);function Dg(t,e,i,n){return t.change(o=>{let r;if(!i){r=t.document.selection}else if(i instanceof ef||i instanceof ff){r=i}else{r=o.createSelection(i,n)}if(!r.isCollapsed){t.deleteContent(r,{doNotAutoparagraph:true})}const s=new zg(t,o,r.anchor);let a;if(e.is(\"documentFragment\")){a=e.getChildren()}else{a=[e]}s.handleNodes(a,{isFirst:true,isLast:true});const l=s.getSelectionRange();if(l){if(r instanceof ff){o.setSelection(l)}else{r.setTo(l)}}else{}const c=s.getAffectedRange()||t.createRange(r.anchor);s.destroy();return c})}class zg{constructor(t,e,i){this.model=t;this.writer=e;this.position=i;this.canMergeWith=new Set([this.position.parent]);this.schema=t.schema;this._filterAttributesOf=[];this._affectedStart=null;this._affectedEnd=null}handleNodes(t,e){t=Array.from(t);for(let i=0;i<t.length;i++){const n=t[i];this._handleNode(n,{isFirst:i===0&&e.isFirst,isLast:i===t.length-1&&e.isLast})}this.schema.removeDisallowedAttributes(this._filterAttributesOf,this.writer);this._filterAttributesOf=[]}getSelectionRange(){if(this.nodeToSelect){return Kh._createOn(this.nodeToSelect)}return this.model.schema.getNearestSelectionRange(this.position)}getAffectedRange(){if(!this._affectedStart){return null}return new Kh(this._affectedStart,this._affectedEnd)}destroy(){if(this._affectedStart){this._affectedStart.detach()}if(this._affectedEnd){this._affectedEnd.detach()}}_handleNode(t,e){if(this.schema.isObject(t)){this._handleObject(t,e);return}const i=this._checkAndSplitToAllowedPosition(t,e);if(!i){this._handleDisallowedNode(t,e);return}this._insert(t);this._mergeSiblingsOf(t,e)}_handleObject(t,e){if(this._checkAndSplitToAllowedPosition(t)){this._insert(t)}else{this._tryAutoparagraphing(t,e)}}_handleDisallowedNode(t,e){if(t.is(\"element\")){this.handleNodes(t.getChildren(),e)}else{this._tryAutoparagraphing(t,e)}}_insert(t){if(!this.schema.checkChild(this.position,t)){throw new ss[\"b\"](\"insertcontent-wrong-position: Given node cannot be inserted on the given position.\",this,{node:t,position:this.position})}const e=Ng.fromPosition(this.position,\"toNext\");this._setAffectedBoundaries(this.position);this.writer.insert(t,this.position);this.position=e.toPosition();e.detach();if(this.schema.isObject(t)&&!this.schema.checkChild(this.position,\"$text\")){this.nodeToSelect=t}else{this.nodeToSelect=null}this._filterAttributesOf.push(t)}_setAffectedBoundaries(t){if(!this._affectedStart){this._affectedStart=Ng.fromPosition(t,\"toPrevious\")}if(!this._affectedEnd||this._affectedEnd.isBefore(t)){if(this._affectedEnd){this._affectedEnd.detach()}this._affectedEnd=Ng.fromPosition(t,\"toNext\")}}_mergeSiblingsOf(t,e){if(!(t instanceof jh)){return}const i=this._canMergeLeft(t,e);const n=this._canMergeRight(t,e);const o=Ng._createBefore(t);o.stickiness=\"toNext\";const r=Ng._createAfter(t);r.stickiness=\"toNext\";if(i){const t=Ng.fromPosition(this.position);t.stickiness=\"toNext\";if(this._affectedStart.isEqual(o)){this._affectedStart.detach();this._affectedStart=Ng._createAt(o.nodeBefore,\"end\",\"toPrevious\")}this.writer.merge(o);if(o.isEqual(this._affectedEnd)&&e.isLast){this._affectedEnd.detach();this._affectedEnd=Ng._createAt(o.nodeBefore,\"end\",\"toNext\")}this.position=t.toPosition();t.detach()}if(n){if(!this.position.isEqual(r)){throw new ss[\"b\"](\"insertcontent-invalid-insertion-position\",this)}this.position=$h._createAt(r.nodeBefore,\"end\");const t=Ng.fromPosition(this.position,\"toPrevious\");if(this._affectedEnd.isEqual(r)){this._affectedEnd.detach();this._affectedEnd=Ng._createAt(r.nodeBefore,\"end\",\"toNext\")}this.writer.merge(r);if(r.getShiftedBy(-1).isEqual(this._affectedStart)&&e.isFirst){this._affectedStart.detach();this._affectedStart=Ng._createAt(r.nodeBefore,0,\"toPrevious\")}this.position=t.toPosition();t.detach()}if(i||n){this._filterAttributesOf.push(this.position.parent)}o.detach();r.detach()}_canMergeLeft(t,e){const i=t.previousSibling;return e.isFirst&&i instanceof jh&&this.canMergeWith.has(i)&&this.model.schema.checkMerge(i,t)}_canMergeRight(t,e){const i=t.nextSibling;return e.isLast&&i instanceof jh&&this.canMergeWith.has(i)&&this.model.schema.checkMerge(t,i)}_tryAutoparagraphing(t,e){const i=this.writer.createElement(\"paragraph\");if(this._getAllowedIn(i,this.position.parent)&&this.schema.checkChild(i,t)){i._appendChild(t);this._handleNode(i,e)}}_checkAndSplitToAllowedPosition(t){const e=this._getAllowedIn(t,this.position.parent);if(!e){return false}while(e!=this.position.parent){if(this.schema.isLimit(this.position.parent)){return false}if(this.position.isAtStart){const t=this.position.parent;this.position=this.writer.createPositionBefore(t);if(t.isEmpty&&t.parent===e){this.writer.remove(t)}}else if(this.position.isAtEnd){this.position=this.writer.createPositionAfter(this.position.parent)}else{const t=this.writer.createPositionAfter(this.position.parent);this._setAffectedBoundaries(this.position);this.writer.split(this.position);this.position=t;this.canMergeWith.add(this.position.nodeAfter)}}return true}_getAllowedIn(t,e){if(this.schema.checkChild(e,t)){return e}if(e.parent){return this._getAllowedIn(t,e.parent)}return null}}function Fg(t,e,i={}){if(e.isCollapsed){return}const n=e.getFirstRange();if(n.root.rootName==\"$graveyard\"){return}const o=t.schema;t.change(t=>{if(!i.doNotResetEntireContent&&Ug(o,e)){$g(t,e,o);return}const r=n.start;const s=Ng.fromPosition(n.end,\"toNext\");if(!n.start.isTouching(n.end)){t.remove(n)}if(!i.leaveUnmerged){jg(t,r,s);o.removeDisallowedAttributes(r.parent.getChildren(),t)}Gg(t,e,r);if(!i.doNotAutoparagraph&&Hg(o,r)){qg(t,r,e)}s.detach()})}function jg(t,e,i){const n=e.parent;const o=i.parent;if(n==o){return}if(t.model.schema.isLimit(n)||t.model.schema.isLimit(o)){return}if(!Wg(e,i,t.model.schema)){return}e=t.createPositionAfter(n);i=t.createPositionBefore(o);if(!i.isEqual(e)){t.insert(o,e)}t.merge(e);while(i.parent.isEmpty){const e=i.parent;i=t.createPositionBefore(e);t.remove(e)}jg(t,e,i)}function Hg(t,e){const i=t.checkChild(e,\"$text\");const n=t.checkChild(e,\"paragraph\");return!i&&n}function Wg(t,e,i){const n=new Kh(t,e);for(const t of n.getWalker()){if(i.isLimit(t.item)){return false}}return true}function qg(t,e,i){const n=t.createElement(\"paragraph\");t.insert(n,e);Gg(t,i,t.createPositionAt(n,0))}function $g(t,e){const i=t.model.schema.getLimitElement(e);t.remove(t.createRangeIn(i));qg(t,t.createPositionAt(i,0),e)}function Ug(t,e){const i=t.getLimitElement(e);if(!e.containsEntireContent(i)){return false}const n=e.getFirstRange();if(n.start.parent==n.end.parent){return false}return t.checkChild(i,\"paragraph\")}function Gg(t,e,i){if(e instanceof ff){t.setSelection(i)}else{e.setTo(i)}}const Jg=' ,.?!:;\"-()';function Kg(t,e,i={}){const n=t.schema;const o=i.direction!=\"backward\";const r=i.unit?i.unit:\"character\";const s=e.focus;const a=new Wh({boundaries:Zg(s,o),singleCharacters:true,direction:o?\"forward\":\"backward\"});const l={walker:a,schema:n,isForward:o,unit:r};let c;while(c=a.next()){if(c.done){return}const i=Xg(l,c.value);if(i){if(e instanceof ff){t.change(t=>{t.setSelectionFocus(i)})}else{e.setFocus(i)}return}}}function Xg(t,e){if(e.type==\"text\"){if(t.unit===\"word\"){return Qg(t.walker,t.isForward)}return Yg(t.walker,t.unit,t.isForward)}if(e.type==(t.isForward?\"elementStart\":\"elementEnd\")){if(t.schema.isObject(e.item)){return $h._createAt(e.item,t.isForward?\"after\":\"before\")}if(t.schema.checkChild(e.nextPosition,\"$text\")){return e.nextPosition}}else{if(t.schema.isLimit(e.item)){t.walker.skip(()=>true);return}if(t.schema.checkChild(e.nextPosition,\"$text\")){return e.nextPosition}}}function Yg(t,e){const i=t.position.textNode;if(i){const n=i.data;let o=t.position.offset-i.startOffset;while(Ag(n,o)||e==\"character\"&&Tg(n,o)){t.next();o=t.position.offset-i.startOffset}}return t.position}function Qg(t,e){let i=t.position.textNode;if(i){let n=t.position.offset-i.startOffset;while(!tp(i.data,n,e)&&!ep(i,n,e)){t.next();const o=e?t.position.nodeAfter:t.position.nodeBefore;if(o&&o.is(\"text\")){const n=o.data.charAt(e?0:o.data.length-1);if(!Jg.includes(n)){t.next();i=t.position.textNode}}n=t.position.offset-i.startOffset}}return t.position}function Zg(t,e){const i=t.root;const n=$h._createAt(i,e?\"end\":0);if(e){return new Kh(t,n)}else{return new Kh(n,t)}}function tp(t,e,i){const n=e+(i?0:-1);return Jg.includes(t.charAt(n))}function ep(t,e,i){return e===(i?t.endOffset:0)}function ip(t,e){return t.change(t=>{const i=t.createDocumentFragment();const n=e.getFirstRange();if(!n||n.isCollapsed){return i}const o=n.start.root;const r=n.start.getCommonPath(n.end);const s=o.getNodeByPath(r);let a;if(n.start.parent==n.end.parent){a=n}else{a=t.createRange(t.createPositionAt(s,n.start.path[r.length]),t.createPositionAt(s,n.end.path[r.length]+1))}const l=a.end.offset-a.start.offset;for(const e of a.getItems({shallow:true})){if(e.is(\"textProxy\")){t.appendText(e.data,e.getAttributes(),i)}else{t.append(e._clone(true),i)}}if(a!=n){const e=n._getTransformedByMove(a.start,t.createPositionAt(i,0),l)[0];const o=t.createRange(t.createPositionAt(i,0),e.start);const r=t.createRange(e.end,t.createPositionAt(i,\"end\"));np(r,t);np(o,t)}return i})}function np(t,e){const i=[];Array.from(t.getItems({direction:\"backward\"})).map(t=>e.createRangeOn(t)).filter(e=>{const i=(e.start.isAfter(t.start)||e.start.isEqual(t.start))&&(e.end.isBefore(t.end)||e.end.isEqual(t.end));return i}).forEach(t=>{i.push(t.start.parent);e.remove(t)});i.forEach(t=>{let i=t;while(i.parent&&i.isEmpty){const t=e.createRangeOn(i);i=i.parent;e.remove(t)}})}function op(t){t.document.registerPostFixer(e=>rp(e,t))}function rp(t,e){const i=e.document.selection;const n=e.schema;const o=[];let r=false;for(const t of i.getRanges()){const e=sp(t,n);if(e){o.push(e);r=true}else{o.push(t)}}if(r){t.setSelection(up(o),{backward:i.isBackward})}}function sp(t,e){if(t.isCollapsed){return ap(t,e)}return lp(t,e)}function ap(t,e){const i=t.start;const n=e.getNearestSelectionRange(i);if(!n){return null}if(!n.isCollapsed){return n}const o=n.start;if(i.isEqual(o)){return null}return new Kh(o)}function lp(t,e){const i=t.start;const n=t.end;const o=e.checkChild(i,\"$text\");const r=e.checkChild(n,\"$text\");const s=e.getLimitElement(i);const a=e.getLimitElement(n);if(s===a){if(o&&r){return null}if(dp(i,n,e)){const t=i.nodeAfter&&e.isObject(i.nodeAfter);const o=t?null:e.getNearestSelectionRange(i,\"forward\");const r=n.nodeBefore&&e.isObject(n.nodeBefore);const s=r?null:e.getNearestSelectionRange(n,\"backward\");const a=o?o.start:i;const l=s?s.start:n;return new Kh(a,l)}}const l=s&&!s.is(\"rootElement\");const c=a&&!a.is(\"rootElement\");if(l||c){const t=i.nodeAfter&&n.nodeBefore&&i.nodeAfter.parent===n.nodeBefore.parent;const o=l&&(!t||!hp(i.nodeAfter,e));const r=c&&(!t||!hp(n.nodeBefore,e));let d=i;let u=n;if(o){d=$h._createBefore(cp(s,e))}if(r){u=$h._createAfter(cp(a,e))}return new Kh(d,u)}return null}function cp(t,e){let i=t;let n=i;while(e.isLimit(n)&&n.parent){i=n;n=n.parent}return i}function dp(t,e,i){const n=t.nodeAfter&&!i.isLimit(t.nodeAfter)||i.checkChild(t,\"$text\");const o=e.nodeBefore&&!i.isLimit(e.nodeBefore)||i.checkChild(e,\"$text\");return n||o}function up(t){const e=[];e.push(t.shift());for(const i of t){const t=e.pop();if(i.isIntersecting(t)){const n=t.start.isAfter(i.start)?i.start:t.start;const o=t.end.isAfter(i.end)?t.end:i.end;const r=new Kh(n,o);e.push(r)}else{e.push(t);e.push(i)}}return e}function hp(t,e){return t&&e.isObject(t)}class fp{constructor(){this.markers=new Mg;this.document=new Eg(this);this.schema=new gm;this._pendingChanges=[];this._currentWriter=null;[\"insertContent\",\"deleteContent\",\"modifySelection\",\"getSelectedContent\",\"applyOperation\"].forEach(t=>this.decorate(t));this.on(\"applyOperation\",(t,e)=>{const i=e[0];i._validate()},{priority:\"highest\"});this.schema.register(\"$root\",{isLimit:true});this.schema.register(\"$block\",{allowIn:\"$root\",isBlock:true});this.schema.register(\"$text\",{allowIn:\"$block\",isInline:true});this.schema.register(\"$clipboardHolder\",{allowContentOf:\"$root\",isLimit:true});this.schema.extend(\"$text\",{allowIn:\"$clipboardHolder\"});this.schema.register(\"$marker\");this.schema.addChildCheck((t,e)=>{if(e.name===\"$marker\"){return true}});op(this)}change(t){try{if(this._pendingChanges.length===0){this._pendingChanges.push({batch:new jm,callback:t});return this._runPendingChanges()[0]}else{return t(this._currentWriter)}}catch(t){ss[\"b\"].rethrowUnexpectedError(t,this)}}enqueueChange(t,e){try{if(typeof t===\"string\"){t=new jm(t)}else if(typeof t==\"function\"){e=t;t=new jm}this._pendingChanges.push({batch:t,callback:e});if(this._pendingChanges.length==1){this._runPendingChanges()}}catch(t){ss[\"b\"].rethrowUnexpectedError(t,this)}}applyOperation(t){t._execute()}insertContent(t,e,i){return Dg(this,t,e,i)}deleteContent(t,e){Fg(this,t,e)}modifySelection(t,e){Kg(this,t,e)}getSelectedContent(t){return ip(this,t)}hasContent(t,e){const i=t instanceof jh?Kh._createIn(t):t;if(i.isCollapsed){return false}for(const t of this.markers.getMarkersIntersectingRange(i)){if(t.affectsData){return true}}const{ignoreWhitespaces:n=false}=e||{};for(const t of i.getItems()){if(t.is(\"textProxy\")){if(!n){return true}else if(t.data.search(/\\S/)!==-1){return true}}else if(this.schema.isObject(t)){return true}}return false}createPositionFromPath(t,e,i){return new $h(t,e,i)}createPositionAt(t,e){return $h._createAt(t,e)}createPositionAfter(t){return $h._createAfter(t)}createPositionBefore(t){return $h._createBefore(t)}createRange(t,e){return new Kh(t,e)}createRangeIn(t){return Kh._createIn(t)}createRangeOn(t){return Kh._createOn(t)}createSelection(t,e,i){return new ef(t,e,i)}createBatch(t){return new jm(t)}createOperationFromJSON(t){return Lg.fromJSON(t,this.document)}destroy(){this.document.destroy();this.stopListening()}_runPendingChanges(){const t=[];this.fire(\"_beforeChanges\");while(this._pendingChanges.length){const e=this._pendingChanges[0].batch;this._currentWriter=new ug(this,e);const i=this._pendingChanges[0].callback(this._currentWriter);t.push(i);this.document._handleChangeBlock(this._currentWriter);this._pendingChanges.shift();this._currentWriter=null}this.fire(\"_afterChanges\");return t}}ys(fp,Xl);class mp{constructor(){this._listener=Object.create(qd)}listenTo(t){this._listener.listenTo(t,\"keydown\",(t,e)=>{this._listener.fire(\"_keydown:\"+Nc(e),e)})}set(t,e,i={}){const n=Bc(t);const o=i.priority;this._listener.listenTo(this._listener,\"_keydown:\"+n,(t,i)=>{e(i,()=>{i.preventDefault();i.stopPropagation();t.stop()});t.return=true},{priority:o})}press(t){return!!this._listener.fire(\"_keydown:\"+Nc(t),t)}destroy(){this._listener.stopListening()}}class gp extends mp{constructor(t){super();this.editor=t}set(t,e,i={}){if(typeof e==\"string\"){const t=e;e=(e,i)=>{this.editor.execute(t);i()}}super.set(t,e,i)}}class pp{constructor(t={}){this._context=t.context||new Ls({language:t.language});this._context._addEditor(this,!t.context);const e=Array.from(this.constructor.builtinPlugins||[]);this.config=new Kr(t,this.constructor.defaultConfig);this.config.define(\"plugins\",e);this.config.define(this._context._getEditorConfig());this.plugins=new Cs(this,e,this._context.plugins);this.locale=this._context.locale;this.t=this.locale.t;this.commands=new hm;this.set(\"state\",\"initializing\");this.once(\"ready\",()=>this.state=\"ready\",{priority:\"high\"});this.once(\"destroy\",()=>this.state=\"destroyed\",{priority:\"high\"});this.set(\"isReadOnly\",false);this.model=new fp;const i=new Ll;this.data=new Bm(this.model,i);this.editing=new um(this.model,i);this.editing.view.document.bind(\"isReadOnly\").to(this);this.conversion=new Dm([this.editing.downcastDispatcher,this.data.downcastDispatcher],this.data.upcastDispatcher);this.conversion.addAlias(\"dataDowncast\",this.data.downcastDispatcher);this.conversion.addAlias(\"editingDowncast\",this.editing.downcastDispatcher);this.keystrokes=new gp(this);this.keystrokes.listenTo(this.editing.view.document)}initPlugins(){const t=this.config;const e=t.get(\"plugins\");const i=t.get(\"removePlugins\")||[];const n=t.get(\"extraPlugins\")||[];return this.plugins.init(e.concat(n),i)}destroy(){let t=Promise.resolve();if(this.state==\"initializing\"){t=new Promise(t=>this.once(\"ready\",t))}return t.then(()=>{this.fire(\"destroy\");this.stopListening();this.commands.destroy()}).then(()=>this.plugins.destroy()).then(()=>{this.model.destroy();this.data.destroy();this.editing.destroy();this.keystrokes.destroy()}).then(()=>this._context._removeEditor(this))}execute(...t){try{this.commands.execute(...t)}catch(t){ss[\"b\"].rethrowUnexpectedError(t,this)}}}ys(pp,Xl);const bp={setData(t){this.data.set(t)},getData(t){return this.data.get(t)}};var wp=bp;function _p(t,e){if(t instanceof HTMLTextAreaElement){t.value=e}t.innerHTML=e}const kp={updateSourceElement(){if(!this.sourceElement){throw new ss[\"b\"](\"editor-missing-sourceelement: Cannot update the source element of a detached editor.\",this)}_p(this.sourceElement,this.data.get())}};var vp=kp;function yp(t){if(!mt(t.updateSourceElement)){throw new ss[\"b\"](\"attachtoform-missing-elementapi-interface: Editor passed to attachToForm() must implement ElementApi.\",t)}const e=t.sourceElement;if(e&&e.tagName.toLowerCase()===\"textarea\"&&e.form){let i;const n=e.form;const o=()=>t.updateSourceElement();if(mt(n.submit)){i=n.submit;n.submit=()=>{o();i.apply(n)}}n.addEventListener(\"submit\",o);t.on(\"destroy\",()=>{n.removeEventListener(\"submit\",o);if(i){n.submit=i}})}}class xp{getHtml(t){const e=document.implementation.createHTMLDocument(\"\");const i=e.createElement(\"div\");i.appendChild(t);return i.innerHTML}}class Cp{constructor(t){this._domParser=new DOMParser;this._domConverter=new Vd(t,{blockFillerMode:\"nbsp\"});this._htmlWriter=new xp}toData(t){const e=this._domConverter.viewToDom(t,document);return this._htmlWriter.getHtml(e)}toView(t){const e=this._toDom(t);return this._domConverter.domToView(e)}_toDom(t){const e=this._domParser.parseFromString(t,\"text/html\");const i=e.createDocumentFragment();const n=e.body.childNodes;while(n.length>0){i.appendChild(n[0])}return i}}class Ap{constructor(t){this.editor=t;this._components=new Map}*names(){for(const t of this._components.values()){yield t.originalName}}add(t,e){if(this.has(t)){throw new ss[\"b\"](\"componentfactory-item-exists: The item already exists in the component factory.\",this,{name:t})}this._components.set(Tp(t),{callback:e,originalName:t})}create(t){if(!this.has(t)){throw new ss[\"b\"](\"componentfactory-item-missing: The required component is not registered in the factory.\",this,{name:t})}return this._components.get(Tp(t)).callback(this.editor.locale)}has(t){return this._components.has(Tp(t))}}function Tp(t){return String(t).toLowerCase()}class Pp{constructor(){this.set(\"isFocused\",false);this.set(\"focusedElement\",null);this._elements=new Set;this._nextEventLoopTimeout=null}add(t){if(this._elements.has(t)){throw new ss[\"b\"](\"focusTracker-add-element-already-exist\",this)}this.listenTo(t,\"focus\",()=>this._focus(t),{useCapture:true});this.listenTo(t,\"blur\",()=>this._blur(),{useCapture:true});this._elements.add(t)}remove(t){if(t===this.focusedElement){this._blur(t)}if(this._elements.has(t)){this.stopListening(t);this._elements.delete(t)}}destroy(){this.stopListening()}_focus(t){clearTimeout(this._nextEventLoopTimeout);this.focusedElement=t;this.isFocused=true}_blur(){clearTimeout(this._nextEventLoopTimeout);this._nextEventLoopTimeout=setTimeout(()=>{this.focusedElement=null;this.isFocused=false},0)}}ys(Pp,qd);ys(Pp,Xl);class Ep{constructor(t){this.editor=t;this.componentFactory=new Ap(t);this.focusTracker=new Pp;this._editableElementsMap=new Map;this.listenTo(t.editing.view.document,\"layoutChanged\",()=>this.update())}get element(){return null}update(){this.fire(\"update\")}destroy(){this.stopListening();this.focusTracker.destroy();for(const t of this._editableElementsMap.values()){t.ckeditorInstance=null}this._editableElementsMap=new Map}setEditableElement(t,e){this._editableElementsMap.set(t,e);if(!e.ckeditorInstance){e.ckeditorInstance=this.editor}}getEditableElement(t=\"main\"){return this._editableElementsMap.get(t)}getEditableElementsNames(){return this._editableElementsMap.keys()}get _editableElements(){console.warn(\"editor-ui-deprecated-editable-elements: \"+\"The EditorUI#_editableElements property has been deprecated and will be removed in the near future.\",{editorUI:this});return this._editableElementsMap}}ys(Ep,ds);function Sp({origin:t,originKeystrokeHandler:e,originFocusTracker:i,toolbar:n,beforeFocus:o,afterBlur:r}){i.add(n.element);e.set(\"Alt+F10\",(t,e)=>{if(i.isFocused&&!n.focusTracker.isFocused){if(o){o()}n.focus();e()}});n.keystrokes.set(\"Esc\",(e,i)=>{if(n.focusTracker.isFocused){t.focus();if(r){r()}i()}})}function Mp(t){if(Array.isArray(t)){return{items:t}}if(!t){return{items:[]}}return Object.assign({items:[]},t)}var Op=i(17);const Ip=new WeakMap;function Rp(t){const{view:e,element:i,text:n,isDirectHost:o=true}=t;const r=e.document;if(!Ip.has(r)){Ip.set(r,new Map);r.registerPostFixer(t=>Dp(r,t))}Ip.get(r).set(i,{text:n,isDirectHost:o});e.change(t=>Dp(r,t))}function Lp(t,e){const i=e.document;t.change(t=>{if(!Ip.has(i)){return}const n=Ip.get(i);const o=n.get(e);t.removeAttribute(\"data-placeholder\",o.hostElement);Bp(t,o.hostElement);n.delete(e)})}function Np(t,e){if(!e.hasClass(\"ck-placeholder\")){t.addClass(\"ck-placeholder\",e);return true}return false}function Bp(t,e){if(e.hasClass(\"ck-placeholder\")){t.removeClass(\"ck-placeholder\",e);return true}return false}function Vp(t){if(!t.isAttached()){return false}const e=!Array.from(t.getChildren()).some(t=>!t.is(\"uiElement\"));const i=t.document;if(!i.isFocused&&e){return true}const n=i.selection;const o=n.anchor;if(e&&o&&o.parent!==t){return true}return false}function Dp(t,e){const i=Ip.get(t);let n=false;for(const[t,o]of i){if(zp(e,t,o)){n=true}}return n}function zp(t,e,i){const{text:n,isDirectHost:o}=i;const r=o?e:Fp(e);let s=false;if(!r){return false}i.hostElement=r;if(r.getAttribute(\"data-placeholder\")!==n){t.setAttribute(\"data-placeholder\",n,r);s=true}if(Vp(r)){if(Np(t,r)){s=true}}else if(Bp(t,r)){s=true}return s}function Fp(t){if(t.childCount===1){const e=t.getChild(0);if(e.is(\"element\")&&!e.is(\"uiElement\")){return e}}return null}class jp{constructor(){this._replacedElements=[]}replace(t,e){this._replacedElements.push({element:t,newElement:e});t.style.display=\"none\";if(e){t.parentNode.insertBefore(e,t.nextSibling)}}restore(){this._replacedElements.forEach(({element:t,newElement:e})=>{t.style.display=\"\";if(e){e.remove()}});this._replacedElements=[]}}class Hp extends Ep{constructor(t,e){super(t);this.view=e;this._toolbarConfig=Mp(t.config.get(\"toolbar\"));this._elementReplacer=new jp}get element(){return this.view.element}init(t){const e=this.editor;const i=this.view;const n=e.editing.view;const o=i.editable;const r=n.document.getRoot();o.name=r.rootName;i.render();const s=o.element;this.setEditableElement(o.name,s);this.focusTracker.add(s);i.editable.bind(\"isFocused\").to(this.focusTracker);n.attachDomRoot(s);if(t){this._elementReplacer.replace(t,this.element)}this._initPlaceholder();this._initToolbar();this.fire(\"ready\")}destroy(){const t=this.view;const e=this.editor.editing.view;this._elementReplacer.restore();e.detachDomRoot(t.editable.name);t.destroy();super.destroy()}_initToolbar(){const t=this.editor;const e=this.view;const i=t.editing.view;e.stickyPanel.bind(\"isActive\").to(this.focusTracker,\"isFocused\");e.stickyPanel.limiterElement=e.element;if(this._toolbarConfig.viewportTopOffset){e.stickyPanel.viewportTopOffset=this._toolbarConfig.viewportTopOffset}e.toolbar.fillFromConfig(this._toolbarConfig.items,this.componentFactory);Sp({origin:i,originFocusTracker:this.focusTracker,originKeystrokeHandler:t.keystrokes,toolbar:e.toolbar})}_initPlaceholder(){const t=this.editor;const e=t.editing.view;const i=e.document.getRoot();const n=t.sourceElement;const o=t.config.get(\"placeholder\")||n&&n.tagName.toLowerCase()===\"textarea\"&&n.getAttribute(\"placeholder\");if(o){Rp({view:e,element:i,text:o,isDirectHost:false})}}}class Wp extends xs{constructor(t=[]){super(t,{idProperty:\"viewUid\"});this.on(\"add\",(t,e,i)=>{this._renderViewIntoCollectionParent(e,i)});this.on(\"remove\",(t,e)=>{if(e.element&&this._parentElement){e.element.remove()}});this._parentElement=null}destroy(){this.map(t=>t.destroy())}setParent(t){this._parentElement=t;for(const t of this){this._renderViewIntoCollectionParent(t)}}delegate(...t){if(!t.length||!qp(t)){throw new ss[\"b\"](\"ui-viewcollection-delegate-wrong-events: All event names must be strings.\",this)}return{to:e=>{for(const i of this){for(const n of t){i.delegate(n).to(e)}}this.on(\"add\",(i,n)=>{for(const i of t){n.delegate(i).to(e)}});this.on(\"remove\",(i,n)=>{for(const i of t){n.stopDelegating(i,e)}})}}}_renderViewIntoCollectionParent(t,e){if(!t.isRendered){t.render()}if(t.element&&this._parentElement){this._parentElement.insertBefore(t.element,this._parentElement.children[e])}}}function qp(t){return t.every(t=>typeof t==\"string\")}const $p=\"http://www.w3.org/1999/xhtml\";class Up{constructor(t){Object.assign(this,nb(ib(t)));this._isRendered=false;this._revertData=null}render(){const t=this._renderNode({intoFragment:true});this._isRendered=true;return t}apply(t){this._revertData=pb();this._renderNode({node:t,isApplying:true,revertData:this._revertData});return t}revert(t){if(!this._revertData){throw new ss[\"b\"](\"ui-template-revert-not-applied: Attempting to revert a template which has not been applied yet.\",[this,t])}this._revertTemplateFromNode(t,this._revertData)}*getViews(){function*t(e){if(e.children){for(const i of e.children){if(fb(i)){yield i}else if(mb(i)){yield*t(i)}}}}yield*t(this)}static bind(t,e){return{to(i,n){return new Jp({eventNameOrFunction:i,attribute:i,observable:t,emitter:e,callback:n})},if(i,n,o){return new Kp({observable:t,emitter:e,attribute:i,valueIfTrue:n,callback:o})}}}static extend(t,e){if(t._isRendered){throw new ss[\"b\"](\"template-extend-render: Attempting to extend a template which has already been rendered.\",[this,t])}ub(t,nb(ib(e)))}_renderNode(t){let e;if(t.node){e=this.tag&&this.text}else{e=this.tag?this.text:!this.text}if(e){throw new ss[\"b\"]('ui-template-wrong-syntax: Node definition must have either \"tag\" or \"text\" when rendering a new Node.',this)}if(this.text){return this._renderText(t)}else{return this._renderElement(t)}}_renderElement(t){let e=t.node;if(!e){e=t.node=document.createElementNS(this.ns||$p,this.tag)}this._renderAttributes(t);this._renderElementChildren(t);this._setUpListeners(t);return e}_renderText(t){let e=t.node;if(e){t.revertData.text=e.textContent}else{e=t.node=document.createTextNode(\"\")}if(Xp(this.text)){this._bindToObservable({schema:this.text,updater:Zp(e),data:t})}else{e.textContent=this.text.join(\"\")}return e}_renderAttributes(t){let e,i,n,o;if(!this.attributes){return}const r=t.node;const s=t.revertData;for(e in this.attributes){n=r.getAttribute(e);i=this.attributes[e];if(s){s.attributes[e]=n}o=lt(i[0])&&i[0].ns?i[0].ns:null;if(Xp(i)){const a=o?i[0].value:i;if(s&&bb(e)){a.unshift(n)}this._bindToObservable({schema:a,updater:tb(r,e,o),data:t})}else if(e==\"style\"&&typeof i[0]!==\"string\"){this._renderStyleAttribute(i[0],t)}else{if(s&&n&&bb(e)){i.unshift(n)}i=i.map(t=>t?t.value||t:t).reduce((t,e)=>t.concat(e),[]).reduce(cb,\"\");if(!hb(i)){r.setAttributeNS(o,e,i)}}}}_renderStyleAttribute(t,e){const i=e.node;for(const n in t){const o=t[n];if(Xp(o)){this._bindToObservable({schema:[o],updater:eb(i,n),data:e})}else{i.style[n]=o}}}_renderElementChildren(t){const e=t.node;const i=t.intoFragment?document.createDocumentFragment():e;const n=t.isApplying;let o=0;for(const r of this.children){if(gb(r)){if(!n){r.setParent(e);for(const t of r){i.appendChild(t.element)}}}else if(fb(r)){if(!n){if(!r.isRendered){r.render()}i.appendChild(r.element)}}else if(xd(r)){i.appendChild(r)}else{if(n){const e=t.revertData;const n=pb();e.children.push(n);r._renderNode({node:i.childNodes[o++],isApplying:true,revertData:n})}else{i.appendChild(r.render())}}}if(t.intoFragment){e.appendChild(i)}}_setUpListeners(t){if(!this.eventListeners){return}for(const e in this.eventListeners){const i=this.eventListeners[e].map(i=>{const[n,o]=e.split(\"@\");return i.activateDomEventListener(n,o,t)});if(t.revertData){t.revertData.bindings.push(i)}}}_bindToObservable({schema:t,updater:e,data:i}){const n=i.revertData;Qp(t,e,i);const o=t.filter(t=>!hb(t)).filter(t=>t.observable).map(n=>n.activateAttributeListener(t,e,i));if(n){n.bindings.push(o)}}_revertTemplateFromNode(t,e){for(const t of e.bindings){for(const e of t){e()}}if(e.text){t.textContent=e.text;return}for(const i in e.attributes){const n=e.attributes[i];if(n===null){t.removeAttribute(i)}else{t.setAttribute(i,n)}}for(let i=0;i<e.children.length;++i){this._revertTemplateFromNode(t.childNodes[i],e.children[i])}}}ys(Up,ds);class Gp{constructor(t){Object.assign(this,t)}getValue(t){const e=this.observable[this.attribute];return this.callback?this.callback(e,t):e}activateAttributeListener(t,e,i){const n=()=>Qp(t,e,i);this.emitter.listenTo(this.observable,\"change:\"+this.attribute,n);return()=>{this.emitter.stopListening(this.observable,\"change:\"+this.attribute,n)}}}class Jp extends Gp{activateDomEventListener(t,e,i){const n=(t,i)=>{if(!e||i.target.matches(e)){if(typeof this.eventNameOrFunction==\"function\"){this.eventNameOrFunction(i)}else{this.observable.fire(this.eventNameOrFunction,i)}}};this.emitter.listenTo(i.node,t,n);return()=>{this.emitter.stopListening(i.node,t,n)}}}class Kp extends Gp{getValue(t){const e=super.getValue(t);return hb(e)?false:this.valueIfTrue||true}}function Xp(t){if(!t){return false}if(t.value){t=t.value}if(Array.isArray(t)){return t.some(Xp)}else if(t instanceof Gp){return true}return false}function Yp(t,e){return t.map(t=>{if(t instanceof Gp){return t.getValue(e)}return t})}function Qp(t,e,{node:i}){let n=Yp(t,i);if(t.length==1&&t[0]instanceof Kp){n=n[0]}else{n=n.reduce(cb,\"\")}if(hb(n)){e.remove()}else{e.set(n)}}function Zp(t){return{set(e){t.textContent=e},remove(){t.textContent=\"\"}}}function tb(t,e,i){return{set(n){t.setAttributeNS(i,e,n)},remove(){t.removeAttributeNS(i,e)}}}function eb(t,e){return{set(i){t.style[e]=i},remove(){t.style[e]=null}}}function ib(t){const e=Ur(t,t=>{if(t&&(t instanceof Gp||mb(t)||fb(t)||gb(t))){return t}});return e}function nb(t){if(typeof t==\"string\"){t=sb(t)}else if(t.text){ab(t)}if(t.on){t.eventListeners=rb(t.on);delete t.on}if(!t.text){if(t.attributes){ob(t.attributes)}const e=[];if(t.children){if(gb(t.children)){e.push(t.children)}else{for(const i of t.children){if(mb(i)||fb(i)||xd(i)){e.push(i)}else{e.push(new Up(i))}}}}t.children=e}return t}function ob(t){for(const e in t){if(t[e].value){t[e].value=[].concat(t[e].value)}lb(t,e)}}function rb(t){for(const e in t){lb(t,e)}return t}function sb(t){return{text:[t]}}function ab(t){if(!Array.isArray(t.text)){t.text=[t.text]}}function lb(t,e){if(!Array.isArray(t[e])){t[e]=[t[e]]}}function cb(t,e){if(hb(e)){return t}else if(hb(t)){return e}else{return`${t} ${e}`}}function db(t,e){for(const i in e){if(t[i]){t[i].push(...e[i])}else{t[i]=e[i]}}}function ub(t,e){if(e.attributes){if(!t.attributes){t.attributes={}}db(t.attributes,e.attributes)}if(e.eventListeners){if(!t.eventListeners){t.eventListeners={}}db(t.eventListeners,e.eventListeners)}if(e.text){t.text.push(...e.text)}if(e.children&&e.children.length){if(t.children.length!=e.children.length){throw new ss[\"b\"](\"ui-template-extend-children-mismatch: The number of children in extended definition does not match.\",t)}let i=0;for(const n of e.children){ub(t.children[i++],n)}}}function hb(t){return!t&&t!==0}function fb(t){return t instanceof _b}function mb(t){return t instanceof Up}function gb(t){return t instanceof Wp}function pb(){return{children:[],bindings:[],attributes:{}}}function bb(t){return t==\"class\"||t==\"style\"}var wb=i(19);class _b{constructor(t){this.element=null;this.isRendered=false;this.locale=t;this.t=t&&t.t;this._viewCollections=new xs;this._unboundChildren=this.createCollection();this._viewCollections.on(\"add\",(e,i)=>{i.locale=t});this.decorate(\"render\")}get bindTemplate(){if(this._bindTemplate){return this._bindTemplate}return this._bindTemplate=Up.bind(this,this)}createCollection(t){const e=new Wp(t);this._viewCollections.add(e);return e}registerChild(t){if(!vs(t)){t=[t]}for(const e of t){this._unboundChildren.add(e)}}deregisterChild(t){if(!vs(t)){t=[t]}for(const e of t){this._unboundChildren.remove(e)}}setTemplate(t){this.template=new Up(t)}extendTemplate(t){Up.extend(this.template,t)}render(){if(this.isRendered){throw new ss[\"b\"](\"ui-view-render-already-rendered: This View has already been rendered.\",this)}if(this.template){this.element=this.template.render();this.registerChild(this.template.getViews())}this.isRendered=true}destroy(){this.stopListening();this._viewCollections.map(t=>t.destroy());if(this.template&&this.template._revertData){this.template.revert(this.element)}}}ys(_b,qd);ys(_b,Xl);var kb=\"[object String]\";function vb(t){return typeof t==\"string\"||!Ke(t)&&T(t)&&k(t)==kb}var yb=vb;function xb(t,e,i={},n=[]){const o=i&&i.xmlns;const r=o?t.createElementNS(o,e):t.createElement(e);for(const t in i){r.setAttribute(t,i[t])}if(yb(n)||!vs(n)){n=[n]}for(let e of n){if(yb(e)){e=t.createTextNode(e)}r.appendChild(e)}return r}class Cb extends Wp{constructor(t,e=[]){super(e);this.locale=t}attachToDom(){this._bodyCollectionContainer=new Up({tag:\"div\",attributes:{class:[\"ck\",\"ck-reset_all\",\"ck-body\",\"ck-rounded-corners\"],dir:this.locale.uiLanguageDirection},children:this}).render();let t=document.querySelector(\".ck-body-wrapper\");if(!t){t=xb(document,\"div\",{class:\"ck-body-wrapper\"});document.body.appendChild(t)}t.appendChild(this._bodyCollectionContainer)}detachFromDom(){super.destroy();if(this._bodyCollectionContainer){this._bodyCollectionContainer.remove()}const t=document.querySelector(\".ck-body-wrapper\");if(t&&t.childElementCount==0){t.remove()}}}var Ab=i(21);class Tb extends _b{constructor(t){super(t);this.body=new Cb(t)}render(){super.render();this.body.attachToDom()}destroy(){this.body.detachFromDom();return super.destroy()}}var Pb=i(23);class Eb extends _b{constructor(t){super(t);this.set(\"text\");this.set(\"for\");this.id=`ck-editor__label_${is()}`;const e=this.bindTemplate;this.setTemplate({tag:\"label\",attributes:{class:[\"ck\",\"ck-label\"],id:this.id,for:e.to(\"for\")},children:[{text:e.to(\"text\")}]})}}class Sb extends Tb{constructor(t){super(t);this.top=this.createCollection();this.main=this.createCollection();this._voiceLabelView=this._createVoiceLabel();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-reset\",\"ck-editor\",\"ck-rounded-corners\"],role:\"application\",dir:t.uiLanguageDirection,lang:t.uiLanguage,\"aria-labelledby\":this._voiceLabelView.id},children:[this._voiceLabelView,{tag:\"div\",attributes:{class:[\"ck\",\"ck-editor__top\",\"ck-reset_all\"],role:\"presentation\"},children:this.top},{tag:\"div\",attributes:{class:[\"ck\",\"ck-editor__main\"],role:\"presentation\"},children:this.main}]})}_createVoiceLabel(){const t=this.t;const e=new Eb;e.text=t(\"Rich Text Editor\");e.extendTemplate({attributes:{class:\"ck-voice-label\"}});return e}}class Mb extends _b{constructor(t,e,i){super(t);this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-content\",\"ck-editor__editable\",\"ck-rounded-corners\"],lang:t.contentLanguage,dir:t.contentLanguageDirection}});this.name=null;this.set(\"isFocused\",false);this._editableElement=i;this._hasExternalElement=!!this._editableElement;this._editingView=e}render(){super.render();if(this._hasExternalElement){this.template.apply(this.element=this._editableElement)}else{this._editableElement=this.element}this.on(\"change:isFocused\",()=>this._updateIsFocusedClasses());this._updateIsFocusedClasses()}destroy(){if(this._hasExternalElement){this.template.revert(this._editableElement)}super.destroy()}_updateIsFocusedClasses(){const t=this._editingView;if(t.isRenderingInProgress){i(this)}else{e(this)}function e(e){t.change(i=>{const n=t.document.getRoot(e.name);i.addClass(e.isFocused?\"ck-focused\":\"ck-blurred\",n);i.removeClass(e.isFocused?\"ck-blurred\":\"ck-focused\",n)})}function i(n){t.once(\"change:isRenderingInProgress\",(t,o,r)=>{if(!r){e(n)}else{i(n)}})}}}class Ob extends Mb{constructor(t,e,i){super(t,e,i);this.extendTemplate({attributes:{role:\"textbox\",class:\"ck-editor__editable_inline\"}})}render(){super.render();const t=this._editingView;const e=this.t;t.change(i=>{const n=t.document.getRoot(this.name);i.setAttribute(\"aria-label\",e(\"Rich Text Editor, %0\",[this.name]),n)})}}function Ib(t){return e=>e+t}var Rb=i(25);const Lb=Ib(\"px\");class Nb extends _b{constructor(t){super(t);const e=this.bindTemplate;this.set(\"isActive\",false);this.set(\"isSticky\",false);this.set(\"limiterElement\",null);this.set(\"limiterBottomOffset\",50);this.set(\"viewportTopOffset\",0);this.set(\"_marginLeft\",null);this.set(\"_isStickyToTheLimiter\",false);this.set(\"_hasViewportTopOffset\",false);this.content=this.createCollection();this._contentPanelPlaceholder=new Up({tag:\"div\",attributes:{class:[\"ck\",\"ck-sticky-panel__placeholder\"],style:{display:e.to(\"isSticky\",t=>t?\"block\":\"none\"),height:e.to(\"isSticky\",t=>t?Lb(this._panelRect.height):null)}}}).render();this._contentPanel=new Up({tag:\"div\",attributes:{class:[\"ck\",\"ck-sticky-panel__content\",e.if(\"isSticky\",\"ck-sticky-panel__content_sticky\"),e.if(\"_isStickyToTheLimiter\",\"ck-sticky-panel__content_sticky_bottom-limit\")],style:{width:e.to(\"isSticky\",t=>t?Lb(this._contentPanelPlaceholder.getBoundingClientRect().width):null),top:e.to(\"_hasViewportTopOffset\",t=>t?Lb(this.viewportTopOffset):null),bottom:e.to(\"_isStickyToTheLimiter\",t=>t?Lb(this.limiterBottomOffset):null),marginLeft:e.to(\"_marginLeft\")}},children:this.content}).render();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-sticky-panel\"]},children:[this._contentPanelPlaceholder,this._contentPanel]})}render(){super.render();this._checkIfShouldBeSticky();this.listenTo(Id.window,\"scroll\",()=>{this._checkIfShouldBeSticky()});this.listenTo(this,\"change:isActive\",()=>{this._checkIfShouldBeSticky()})}_checkIfShouldBeSticky(){const t=this._panelRect=this._contentPanel.getBoundingClientRect();let e;if(!this.limiterElement){this.isSticky=false}else{e=this._limiterRect=this.limiterElement.getBoundingClientRect();this.isSticky=this.isActive&&e.top<this.viewportTopOffset&&this._panelRect.height+this.limiterBottomOffset<e.height}if(this.isSticky){this._isStickyToTheLimiter=e.bottom<t.height+this.limiterBottomOffset+this.viewportTopOffset;this._hasViewportTopOffset=!this._isStickyToTheLimiter&&!!this.viewportTopOffset;this._marginLeft=this._isStickyToTheLimiter?null:Lb(-Id.window.scrollX)}else{this._isStickyToTheLimiter=false;this._hasViewportTopOffset=false;this._marginLeft=null}}}class Bb{constructor(t){Object.assign(this,t);if(t.actions&&t.keystrokeHandler){for(const e in t.actions){let i=t.actions[e];if(typeof i==\"string\"){i=[i]}for(const n of i){t.keystrokeHandler.set(n,(t,i)=>{this[e]();i()})}}}}get first(){return this.focusables.find(Vb)||null}get last(){return this.focusables.filter(Vb).slice(-1)[0]||null}get next(){return this._getFocusableItem(1)}get previous(){return this._getFocusableItem(-1)}get current(){let t=null;if(this.focusTracker.focusedElement===null){return null}this.focusables.find((e,i)=>{const n=e.element===this.focusTracker.focusedElement;if(n){t=i}return n});return t}focusFirst(){this._focus(this.first)}focusLast(){this._focus(this.last)}focusNext(){this._focus(this.next)}focusPrevious(){this._focus(this.previous)}_focus(t){if(t){t.focus()}}_getFocusableItem(t){const e=this.current;const i=this.focusables.length;if(!i){return null}if(e===null){return this[t===1?\"first\":\"last\"]}let n=(e+i+t)%i;do{const e=this.focusables.get(n);if(Vb(e)){return e}n=(n+i+t)%i}while(n!==e);return null}}function Vb(t){return!!(t.focus&&Id.window.getComputedStyle(t.element).display!=\"none\")}class Db extends _b{constructor(t){super(t);this.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-toolbar__separator\"]}})}}const zb=100;class Fb{constructor(t,e){if(!Fb._observerInstance){Fb._createObserver()}this._element=t;this._callback=e;Fb._addElementCallback(t,e);Fb._observerInstance.observe(t)}destroy(){Fb._deleteElementCallback(this._element,this._callback)}static _addElementCallback(t,e){if(!Fb._elementCallbacks){Fb._elementCallbacks=new Map}let i=Fb._elementCallbacks.get(t);if(!i){i=new Set;Fb._elementCallbacks.set(t,i)}i.add(e)}static _deleteElementCallback(t,e){const i=Fb._getElementCallbacks(t);if(i){i.delete(e);if(!i.size){Fb._elementCallbacks.delete(t);Fb._observerInstance.unobserve(t)}}if(Fb._elementCallbacks&&!Fb._elementCallbacks.size){Fb._observerInstance=null;Fb._elementCallbacks=null}}static _getElementCallbacks(t){if(!Fb._elementCallbacks){return null}return Fb._elementCallbacks.get(t)}static _createObserver(){let t;if(typeof Id.window.ResizeObserver===\"function\"){t=Id.window.ResizeObserver}else{t=jb}Fb._observerInstance=new t(t=>{for(const e of t){if(!e.target.offsetParent){continue}const t=Fb._getElementCallbacks(e.target);if(t){for(const i of t){i(e)}}}})}}Fb._observerInstance=null;Fb._elementCallbacks=null;class jb{constructor(t){this._callback=t;this._elements=new Set;this._previousRects=new Map;this._periodicCheckTimeout=null}observe(t){this._elements.add(t);this._checkElementRectsAndExecuteCallback();if(this._elements.size===1){this._startPeriodicCheck()}}unobserve(t){this._elements.delete(t);this._previousRects.delete(t);if(!this._elements.size){this._stopPeriodicCheck()}}_startPeriodicCheck(){const t=()=>{this._checkElementRectsAndExecuteCallback();this._periodicCheckTimeout=setTimeout(t,zb)};this.listenTo(Id.window,\"resize\",()=>{this._checkElementRectsAndExecuteCallback()});this._periodicCheckTimeout=setTimeout(t,zb)}_stopPeriodicCheck(){clearTimeout(this._periodicCheckTimeout);this.stopListening();this._previousRects.clear()}_checkElementRectsAndExecuteCallback(){const t=[];for(const e of this._elements){if(this._hasRectChanged(e)){t.push({target:e,contentRect:this._previousRects.get(e)})}}if(t.length){this._callback(t)}}_hasRectChanged(t){if(!t.ownerDocument.body.contains(t)){return false}const e=new vh(t);const i=this._previousRects.get(t);const n=!i||!i.isEqual(e);this._previousRects.set(t,e);return n}}ys(jb,qd);function Hb(t){return t.bindTemplate.to(e=>{if(e.target===t.element){e.preventDefault()}})}class Wb extends _b{constructor(t){super(t);const e=this.bindTemplate;this.set(\"isVisible\",false);this.set(\"position\",\"se\");this.children=this.createCollection();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-reset\",\"ck-dropdown__panel\",e.to(\"position\",t=>`ck-dropdown__panel_${t}`),e.if(\"isVisible\",\"ck-dropdown__panel-visible\")]},children:this.children,on:{selectstart:e.to(t=>t.preventDefault())}})}focus(){if(this.children.length){this.children.first.focus()}}focusLast(){if(this.children.length){const t=this.children.last;if(typeof t.focusLast===\"function\"){t.focusLast()}else{t.focus()}}}}var qb=i(27);function $b(t){if(!t||!t.parentNode){return null}if(t.offsetParent===Id.document.body){return null}return t.offsetParent}function Ub({element:t,target:e,positions:i,limiter:n,fitInViewport:o}){if(mt(e)){e=e()}if(mt(n)){n=n()}const r=$b(t);const s=new vh(t);const a=new vh(e);let l;let c;if(!n&&!o){[c,l]=Gb(i[0],a,s)}else{const t=n&&new vh(n).getVisible();const e=o&&new vh(Id.window);const r=Jb(i,{targetRect:a,elementRect:s,limiterRect:t,viewportRect:e});[c,l]=r||Gb(i[0],a,s)}let d=Qb(l);if(r){d=Yb(d,r)}return{left:d.left,top:d.top,name:c}}function Gb(t,e,i){const n=t(e,i);if(!n){return null}const{left:o,top:r,name:s}=n;return[s,i.clone().moveTo(o,r)]}function Jb(t,e){const{elementRect:i,viewportRect:n}=e;const o=i.getArea();const r=Kb(t,e);if(n){const t=r.filter(({viewportIntersectArea:t})=>t===o);const e=Xb(t,o);if(e){return e}}return Xb(r,o)}function Kb(t,{targetRect:e,elementRect:i,limiterRect:n,viewportRect:o}){const r=[];const s=i.getArea();for(const a of t){const t=Gb(a,e,i);if(!t){continue}const[l,c]=t;let d=0;let u=0;if(n){if(o){const t=n.getIntersection(o);if(t){d=t.getIntersectionArea(c)}}else{d=n.getIntersectionArea(c)}}if(o){u=o.getIntersectionArea(c)}const h={positionName:l,positionRect:c,limiterIntersectArea:d,viewportIntersectArea:u};if(d===s){return[h]}r.push(h)}return r}function Xb(t,e){let i=0;let n;let o;for(const{positionName:r,positionRect:s,limiterIntersectArea:a,viewportIntersectArea:l}of t){if(a===e){return[r,s]}const t=l**2+a**2;if(t>i){i=t;n=s;o=r}}return n?[o,n]:null}function Yb({left:t,top:e},i){const n=Qb(new vh(i));const o=_h(i);t-=n.left;e-=n.top;t+=i.scrollLeft;e+=i.scrollTop;t-=o.left;e-=o.top;return{left:t,top:e}}function Qb({left:t,top:e}){const{scrollX:i,scrollY:n}=Id.window;return{left:t+i,top:e+n}}class Zb extends _b{constructor(t,e,i){super(t);const n=this.bindTemplate;this.buttonView=e;this.panelView=i;this.set(\"isOpen\",false);this.set(\"isEnabled\",true);this.set(\"class\");this.set(\"id\");this.set(\"panelPosition\",\"auto\");this.keystrokes=new mp;this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-dropdown\",n.to(\"class\"),n.if(\"isEnabled\",\"ck-disabled\",t=>!t)],id:n.to(\"id\"),\"aria-describedby\":n.to(\"ariaDescribedById\")},children:[e,i]});e.extendTemplate({attributes:{class:[\"ck-dropdown__button\"]}})}render(){super.render();this.listenTo(this.buttonView,\"open\",()=>{this.isOpen=!this.isOpen});this.panelView.bind(\"isVisible\").to(this,\"isOpen\");this.on(\"change:isOpen\",()=>{if(!this.isOpen){return}if(this.panelPosition===\"auto\"){this.panelView.position=Zb._getOptimalPosition({element:this.panelView.element,target:this.buttonView.element,fitInViewport:true,positions:this._panelPositions}).name}else{this.panelView.position=this.panelPosition}});this.keystrokes.listenTo(this.element);const t=(t,e)=>{if(this.isOpen){this.buttonView.focus();this.isOpen=false;e()}};this.keystrokes.set(\"arrowdown\",(t,e)=>{if(this.buttonView.isEnabled&&!this.isOpen){this.isOpen=true;e()}});this.keystrokes.set(\"arrowright\",(t,e)=>{if(this.isOpen){e()}});this.keystrokes.set(\"arrowleft\",t);this.keystrokes.set(\"esc\",t)}focus(){this.buttonView.focus()}get _panelPositions(){const{southEast:t,southWest:e,northEast:i,northWest:n}=Zb.defaultPanelPositions;if(this.locale.uiLanguageDirection===\"ltr\"){return[t,e,i,n]}else{return[e,t,n,i]}}}Zb.defaultPanelPositions={southEast:t=>({top:t.bottom,left:t.left,name:\"se\"}),southWest:(t,e)=>({top:t.bottom,left:t.left-e.width+t.width,name:\"sw\"}),northEast:(t,e)=>({top:t.top-e.height,left:t.left,name:\"ne\"}),northWest:(t,e)=>({top:t.bottom-e.height,left:t.left-e.width+t.width,name:\"nw\"})};Zb._getOptimalPosition=Ub;var tw=i(29);class ew extends _b{constructor(){super();const t=this.bindTemplate;this.set(\"content\",\"\");this.set(\"viewBox\",\"0 0 20 20\");this.set(\"fillColor\",\"\");this.setTemplate({tag:\"svg\",ns:\"http://www.w3.org/2000/svg\",attributes:{class:[\"ck\",\"ck-icon\"],viewBox:t.to(\"viewBox\")}})}render(){super.render();this._updateXMLContent();this._colorFillPaths();this.on(\"change:content\",()=>{this._updateXMLContent();this._colorFillPaths()});this.on(\"change:fillColor\",()=>{this._colorFillPaths()})}_updateXMLContent(){if(this.content){const t=(new DOMParser).parseFromString(this.content.trim(),\"image/svg+xml\");const e=t.querySelector(\"svg\");const i=e.getAttribute(\"viewBox\");if(i){this.viewBox=i}this.element.innerHTML=\"\";while(e.childNodes.length>0){this.element.appendChild(e.childNodes[0])}}}_colorFillPaths(){if(this.fillColor){this.element.querySelectorAll(\".ck-icon__fill\").forEach(t=>{t.style.fill=this.fillColor})}}}var iw=i(31);class nw extends _b{constructor(t){super(t);this.set(\"text\",\"\");this.set(\"position\",\"s\");const e=this.bindTemplate;this.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-tooltip\",e.to(\"position\",t=>\"ck-tooltip_\"+t),e.if(\"text\",\"ck-hidden\",t=>!t.trim())]},children:[{tag:\"span\",attributes:{class:[\"ck\",\"ck-tooltip__text\"]},children:[{text:e.to(\"text\")}]}]})}}var ow=i(33);class rw extends _b{constructor(t){super(t);const e=this.bindTemplate;const i=is();this.set(\"class\");this.set(\"labelStyle\");this.set(\"icon\");this.set(\"isEnabled\",true);this.set(\"isOn\",false);this.set(\"isVisible\",true);this.set(\"isToggleable\",false);this.set(\"keystroke\");this.set(\"label\");this.set(\"tabindex\",-1);this.set(\"tooltip\");this.set(\"tooltipPosition\",\"s\");this.set(\"type\",\"button\");this.set(\"withText\",false);this.set(\"withKeystroke\",false);this.children=this.createCollection();this.tooltipView=this._createTooltipView();this.labelView=this._createLabelView(i);this.iconView=new ew;this.iconView.extendTemplate({attributes:{class:\"ck-button__icon\"}});this.keystrokeView=this._createKeystrokeView();this.bind(\"_tooltipString\").to(this,\"tooltip\",this,\"label\",this,\"keystroke\",this._getTooltipString.bind(this));this.setTemplate({tag:\"button\",attributes:{class:[\"ck\",\"ck-button\",e.to(\"class\"),e.if(\"isEnabled\",\"ck-disabled\",t=>!t),e.if(\"isVisible\",\"ck-hidden\",t=>!t),e.to(\"isOn\",t=>t?\"ck-on\":\"ck-off\"),e.if(\"withText\",\"ck-button_with-text\"),e.if(\"withKeystroke\",\"ck-button_with-keystroke\")],type:e.to(\"type\",t=>t?t:\"button\"),tabindex:e.to(\"tabindex\"),\"aria-labelledby\":`ck-editor__aria-label_${i}`,\"aria-disabled\":e.if(\"isEnabled\",true,t=>!t),\"aria-pressed\":e.to(\"isOn\",t=>this.isToggleable?String(t):false)},children:this.children,on:{mousedown:e.to(t=>{t.preventDefault()}),click:e.to(t=>{if(this.isEnabled){this.fire(\"execute\")}else{t.preventDefault()}})}})}render(){super.render();if(this.icon){this.iconView.bind(\"content\").to(this,\"icon\");this.children.add(this.iconView)}this.children.add(this.tooltipView);this.children.add(this.labelView);if(this.withKeystroke){this.children.add(this.keystrokeView)}}focus(){this.element.focus()}_createTooltipView(){const t=new nw;t.bind(\"text\").to(this,\"_tooltipString\");t.bind(\"position\").to(this,\"tooltipPosition\");return t}_createLabelView(t){const e=new _b;const i=this.bindTemplate;e.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-button__label\"],style:i.to(\"labelStyle\"),id:`ck-editor__aria-label_${t}`},children:[{text:this.bindTemplate.to(\"label\")}]});return e}_createKeystrokeView(){const t=new _b;t.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-button__keystroke\"]},children:[{text:this.bindTemplate.to(\"keystroke\",t=>Vc(t))}]});return t}_getTooltipString(t,e,i){if(t){if(typeof t==\"string\"){return t}else{if(i){i=Vc(i)}if(t instanceof Function){return t(e,i)}else{return`${e}${i?` (${i})`:\"\"}`}}}return\"\"}}var sw='<svg viewBox=\"0 0 10 10\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M.941 4.523a.75.75 0 1 1 1.06-1.06l3.006 3.005 3.005-3.005a.75.75 0 1 1 1.06 1.06l-3.549 3.55a.75.75 0 0 1-1.168-.136L.941 4.523z\"/></svg>';class aw extends rw{constructor(t){super(t);this.arrowView=this._createArrowView();this.extendTemplate({attributes:{\"aria-haspopup\":true}});this.delegate(\"execute\").to(this,\"open\")}render(){super.render();this.children.add(this.arrowView)}_createArrowView(){const t=new ew;t.content=sw;t.extendTemplate({attributes:{class:\"ck-dropdown__arrow\"}});return t}}var lw=i(35);class cw extends _b{constructor(){super();this.items=this.createCollection();this.focusTracker=new Pp;this.keystrokes=new mp;this._focusCycler=new Bb({focusables:this.items,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"arrowup\",focusNext:\"arrowdown\"}});this.setTemplate({tag:\"ul\",attributes:{class:[\"ck\",\"ck-reset\",\"ck-list\"]},children:this.items})}render(){super.render();for(const t of this.items){this.focusTracker.add(t.element)}this.items.on(\"add\",(t,e)=>{this.focusTracker.add(e.element)});this.items.on(\"remove\",(t,e)=>{this.focusTracker.remove(e.element)});this.keystrokes.listenTo(this.element)}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}}class dw extends _b{constructor(t){super(t);this.children=this.createCollection();this.setTemplate({tag:\"li\",attributes:{class:[\"ck\",\"ck-list__item\"]},children:this.children})}focus(){this.children.first.focus()}}class uw extends _b{constructor(t){super(t);this.setTemplate({tag:\"li\",attributes:{class:[\"ck\",\"ck-list__separator\"]}})}}var hw=i(37);class fw extends rw{constructor(t){super(t);this.isToggleable=true;this.toggleSwitchView=this._createToggleView();this.extendTemplate({attributes:{class:\"ck-switchbutton\"}})}render(){super.render();this.children.add(this.toggleSwitchView)}_createToggleView(){const t=new _b;t.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-button__toggle\"]},children:[{tag:\"span\",attributes:{class:[\"ck\",\"ck-button__toggle__inner\"]}}]});return t}}function mw({emitter:t,activator:e,callback:i,contextElements:n}){t.listenTo(document,\"mousedown\",(t,{target:o})=>{if(!e()){return}for(const t of n){if(t.contains(o)){return}}i()})}var gw=i(39);var pw=i(41);function bw(t,e=aw){const i=new e(t);const n=new Wb(t);const o=new Zb(t,i,n);i.bind(\"isEnabled\").to(o);if(i instanceof aw){i.bind(\"isOn\").to(o,\"isOpen\")}else{i.arrowView.bind(\"isOn\").to(o,\"isOpen\")}kw(o);return o}function ww(t,e){const i=t.locale;const n=i.t;const o=t.toolbarView=new Tw(i);o.set(\"ariaLabel\",n(\"Dropdown toolbar\"));t.extendTemplate({attributes:{class:[\"ck-toolbar-dropdown\"]}});e.map(t=>o.items.add(t));t.panelView.children.add(o);o.items.delegate(\"execute\").to(t)}function _w(t,e){const i=t.locale;const n=t.listView=new cw(i);n.items.bindTo(e).using(({type:t,model:e})=>{if(t===\"separator\"){return new uw(i)}else if(t===\"button\"||t===\"switchbutton\"){const n=new dw(i);let o;if(t===\"button\"){o=new rw(i)}else{o=new fw(i)}o.bind(...Object.keys(e)).to(e);o.delegate(\"execute\").to(n);n.children.add(o);return n}});t.panelView.children.add(n);n.items.delegate(\"execute\").to(t)}function kw(t){vw(t);yw(t);xw(t)}function vw(t){t.on(\"render\",()=>{mw({emitter:t,activator:()=>t.isOpen,callback:()=>{t.isOpen=false},contextElements:[t.element]})})}function yw(t){t.on(\"execute\",e=>{if(e.source instanceof fw){return}t.isOpen=false})}function xw(t){t.keystrokes.set(\"arrowdown\",(e,i)=>{if(t.isOpen){t.panelView.focus();i()}});t.keystrokes.set(\"arrowup\",(e,i)=>{if(t.isOpen){t.panelView.focusLast();i()}})}var Cw='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><circle cx=\"9.5\" cy=\"4.5\" r=\"1.5\"/><circle cx=\"9.5\" cy=\"10.5\" r=\"1.5\"/><circle cx=\"9.5\" cy=\"16.5\" r=\"1.5\"/></svg>';var Aw=i(43);class Tw extends _b{constructor(t,e){super(t);const i=this.bindTemplate;const n=this.t;this.options=e||{};this.set(\"ariaLabel\",n(\"Editor toolbar\"));this.set(\"maxWidth\",\"auto\");this.items=this.createCollection();this.focusTracker=new Pp;this.keystrokes=new mp;this.set(\"class\");this.set(\"isCompact\",false);this.itemsView=new Pw(t);this.children=this.createCollection();this.children.add(this.itemsView);this.focusables=this.createCollection();this._focusCycler=new Bb({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:[\"arrowleft\",\"arrowup\"],focusNext:[\"arrowright\",\"arrowdown\"]}});this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-toolbar\",i.to(\"class\"),i.if(\"isCompact\",\"ck-toolbar_compact\")],role:\"toolbar\",\"aria-label\":i.to(\"ariaLabel\"),style:{maxWidth:i.to(\"maxWidth\")}},children:this.children,on:{mousedown:Hb(this)}});this._behavior=this.options.shouldGroupWhenFull?new Sw(this):new Ew(this)}render(){super.render();for(const t of this.items){this.focusTracker.add(t.element)}this.items.on(\"add\",(t,e)=>{this.focusTracker.add(e.element)});this.items.on(\"remove\",(t,e)=>{this.focusTracker.remove(e.element)});this.keystrokes.listenTo(this.element);this._behavior.render(this)}destroy(){this._behavior.destroy();return super.destroy()}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}fillFromConfig(t,e){t.map(t=>{if(t==\"|\"){this.items.add(new Db)}else if(e.has(t)){this.items.add(e.create(t))}else{console.warn(Object(ss[\"a\"])(\"toolbarview-item-unavailable: The requested toolbar item is unavailable.\"),{name:t})}})}}class Pw extends _b{constructor(t){super(t);this.children=this.createCollection();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-toolbar__items\"]},children:this.children})}}class Ew{constructor(t){const e=t.bindTemplate;t.set(\"isVertical\",false);t.itemsView.children.bindTo(t.items).using(t=>t);t.focusables.bindTo(t.items).using(t=>t);t.extendTemplate({attributes:{class:[e.if(\"isVertical\",\"ck-toolbar_vertical\")]}})}render(){}destroy(){}}class Sw{constructor(t){this.viewChildren=t.children;this.viewFocusables=t.focusables;this.viewItemsView=t.itemsView;this.viewFocusTracker=t.focusTracker;this.viewLocale=t.locale;this.ungroupedItems=t.createCollection();this.groupedItems=t.createCollection();this.groupedItemsDropdown=this._createGroupedItemsDropdown();this.resizeObserver=null;this.cachedPadding=null;this.shouldUpdateGroupingOnNextResize=false;t.itemsView.children.bindTo(this.ungroupedItems).using(t=>t);this.ungroupedItems.on(\"add\",this._updateFocusCycleableItems.bind(this));this.ungroupedItems.on(\"remove\",this._updateFocusCycleableItems.bind(this));t.children.on(\"add\",this._updateFocusCycleableItems.bind(this));t.children.on(\"remove\",this._updateFocusCycleableItems.bind(this));t.items.on(\"add\",(t,e,i)=>{if(i>this.ungroupedItems.length){this.groupedItems.add(e,i-this.ungroupedItems.length)}else{this.ungroupedItems.add(e,i)}this._updateGrouping()});t.items.on(\"remove\",(t,e,i)=>{if(i>this.ungroupedItems.length){this.groupedItems.remove(e)}else{this.ungroupedItems.remove(e)}this._updateGrouping()});t.extendTemplate({attributes:{class:[\"ck-toolbar_grouping\"]}})}render(t){this.viewElement=t.element;this._enableGroupingOnResize();this._enableGroupingOnMaxWidthChange(t)}destroy(){this.groupedItemsDropdown.destroy();this.resizeObserver.destroy()}_updateGrouping(){if(!this.viewElement.ownerDocument.body.contains(this.viewElement)){return}if(!this.viewElement.offsetParent){this.shouldUpdateGroupingOnNextResize=true;return}let t;while(this._areItemsOverflowing){this._groupLastItem();t=true}if(!t&&this.groupedItems.length){while(this.groupedItems.length&&!this._areItemsOverflowing){this._ungroupFirstItem()}if(this._areItemsOverflowing){this._groupLastItem()}}}get _areItemsOverflowing(){if(!this.ungroupedItems.length){return false}const t=this.viewElement;const e=this.viewLocale.uiLanguageDirection;const i=new vh(t.lastChild);const n=new vh(t);if(!this.cachedPadding){const i=Id.window.getComputedStyle(t);const n=e===\"ltr\"?\"paddingRight\":\"paddingLeft\";this.cachedPadding=Number.parseInt(i[n])}if(e===\"ltr\"){return i.right>n.right-this.cachedPadding}else{return i.left<n.left+this.cachedPadding}}_enableGroupingOnResize(){let t;this.resizeObserver=new Fb(this.viewElement,e=>{if(!t||t!==e.contentRect.width||this.shouldUpdateGroupingOnNextResize){this.shouldUpdateGroupingOnNextResize=false;this._updateGrouping();t=e.contentRect.width}});this._updateGrouping()}_enableGroupingOnMaxWidthChange(t){t.on(\"change:maxWidth\",()=>{this._updateGrouping()})}_groupLastItem(){if(!this.groupedItems.length){this.viewChildren.add(new Db);this.viewChildren.add(this.groupedItemsDropdown);this.viewFocusTracker.add(this.groupedItemsDropdown.element)}this.groupedItems.add(this.ungroupedItems.remove(this.ungroupedItems.last),0)}_ungroupFirstItem(){this.ungroupedItems.add(this.groupedItems.remove(this.groupedItems.first));if(!this.groupedItems.length){this.viewChildren.remove(this.groupedItemsDropdown);this.viewChildren.remove(this.viewChildren.last);this.viewFocusTracker.remove(this.groupedItemsDropdown.element)}}_createGroupedItemsDropdown(){const t=this.viewLocale;const e=t.t;const i=bw(t);i.class=\"ck-toolbar__grouped-dropdown\";i.panelPosition=t.uiLanguageDirection===\"ltr\"?\"sw\":\"se\";ww(i,[]);i.buttonView.set({label:e(\"Show more items\"),tooltip:true,icon:Cw});i.toolbarView.items.bindTo(this.groupedItems).using(t=>t);return i}_updateFocusCycleableItems(){this.viewFocusables.clear();this.ungroupedItems.map(t=>{this.viewFocusables.add(t)});if(this.groupedItems.length){this.viewFocusables.add(this.groupedItemsDropdown)}}}var Mw=i(45);class Ow extends Sb{constructor(t,e,i={}){super(t);this.stickyPanel=new Nb(t);this.toolbar=new Tw(t,{shouldGroupWhenFull:i.shouldToolbarGroupWhenFull});this.editable=new Ob(t,e)}render(){super.render();this.stickyPanel.content.add(this.toolbar);this.top.add(this.stickyPanel);this.main.add(this.editable)}}function Iw(t){if(t instanceof HTMLTextAreaElement){return t.value}return t.innerHTML}class Rw extends pp{constructor(t,e){super(e);if(Jr(t)){this.sourceElement=t}this.data.processor=new Cp(this.data.viewDocument);this.model.document.createRoot();const i=!this.config.get(\"toolbar.shouldNotGroupWhenFull\");const n=new Ow(this.locale,this.editing.view,{shouldToolbarGroupWhenFull:i});this.ui=new Hp(this,n);yp(this)}destroy(){if(this.sourceElement){this.updateSourceElement()}this.ui.destroy();return super.destroy()}static create(t,e={}){return new Promise(i=>{const n=new this(t,e);i(n.initPlugins().then(()=>n.ui.init(Jr(t)?t:null)).then(()=>{if(!Jr(t)&&e.initialData){throw new ss[\"b\"](\"editor-create-initial-data: \"+\"The config.initialData option cannot be used together with initial data passed in Editor.create().\",null)}const i=e.initialData||Lw(t);return n.data.init(i)}).then(()=>n.fire(\"ready\")).then(()=>n))})}}ys(Rw,wp);ys(Rw,vp);function Lw(t){return Jr(t)?Iw(t):t}class Nw{constructor(t){this.editor=t;this.set(\"isEnabled\",true);this._disableStack=new Set}forceDisabled(t){this._disableStack.add(t);if(this._disableStack.size==1){this.on(\"set:isEnabled\",Bw,{priority:\"highest\"});this.isEnabled=false}}clearForceDisabled(t){this._disableStack.delete(t);if(this._disableStack.size==0){this.off(\"set:isEnabled\",Bw);this.isEnabled=true}}destroy(){this.stopListening()}static get isContextPlugin(){return false}}ys(Nw,Xl);function Bw(t){t.return=false;t.stop()}class Vw{constructor(t){this.editor=t;this.set(\"value\",undefined);this.set(\"isEnabled\",false);this._disableStack=new Set;this.decorate(\"execute\");this.listenTo(this.editor.model.document,\"change\",()=>{this.refresh()});this.on(\"execute\",t=>{if(!this.isEnabled){t.stop()}},{priority:\"high\"});this.listenTo(t,\"change:isReadOnly\",(t,e,i)=>{if(i){this.forceDisabled(\"readOnlyMode\")}else{this.clearForceDisabled(\"readOnlyMode\")}})}refresh(){this.isEnabled=true}forceDisabled(t){this._disableStack.add(t);if(this._disableStack.size==1){this.on(\"set:isEnabled\",Dw,{priority:\"highest\"});this.isEnabled=false}}clearForceDisabled(t){this._disableStack.delete(t);if(this._disableStack.size==0){this.off(\"set:isEnabled\",Dw);this.refresh()}}execute(){}destroy(){this.stopListening()}}ys(Vw,Xl);function Dw(t){t.return=false;t.stop()}function zw(t){const e=t.next();if(e.done){return null}return e.value}const Fw=[\"left\",\"right\",\"center\",\"justify\"];function jw(t){return Fw.includes(t)}function Hw(t,e){if(e.contentLanguageDirection==\"rtl\"){return t===\"right\"}else{return t===\"left\"}}const Ww=\"alignment\";class qw extends Vw{refresh(){const t=this.editor;const e=t.locale;const i=zw(this.editor.model.document.selection.getSelectedBlocks());this.isEnabled=!!i&&this._canBeAligned(i);if(this.isEnabled&&i.hasAttribute(\"alignment\")){this.value=i.getAttribute(\"alignment\")}else{this.value=e.contentLanguageDirection===\"rtl\"?\"right\":\"left\"}}execute(t={}){const e=this.editor;const i=e.locale;const n=e.model;const o=n.document;const r=t.value;n.change(t=>{const e=Array.from(o.selection.getSelectedBlocks()).filter(t=>this._canBeAligned(t));const n=e[0].getAttribute(\"alignment\");const s=Hw(r,i)||n===r||!r;if(s){$w(e,t)}else{Uw(e,t,r)}})}_canBeAligned(t){return this.editor.model.schema.checkAttribute(t,Ww)}}function $w(t,e){for(const i of t){e.removeAttribute(Ww,i)}}function Uw(t,e,i){for(const n of t){e.setAttribute(Ww,i,n)}}class Gw extends Nw{static get pluginName(){return\"AlignmentEditing\"}constructor(t){super(t);t.config.define(\"alignment\",{options:[...Fw]})}init(){const t=this.editor;const e=t.locale;const i=t.model.schema;const n=t.config.get(\"alignment.options\").filter(jw);i.extend(\"$block\",{allowAttributes:\"alignment\"});t.model.schema.setAttributeProperties(\"alignment\",{isFormatting:true});const o=Jw(n.filter(t=>!Hw(t,e)));t.conversion.attributeToAttribute(o);t.commands.add(\"alignment\",new qw(t))}}function Jw(t){const e={model:{key:\"alignment\",values:t.slice()},view:{}};for(const i of t){e.view[i]={key:\"style\",value:{\"text-align\":i}}}return e}var Kw='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 3.75c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0 8c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0 4c0 .414.336.75.75.75h9.929a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0-8c0 .414.336.75.75.75h9.929a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75z\"/></svg>';var Xw='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M18 3.75a.75.75 0 0 1-.75.75H2.75a.75.75 0 1 1 0-1.5h14.5a.75.75 0 0 1 .75.75zm0 8a.75.75 0 0 1-.75.75H2.75a.75.75 0 1 1 0-1.5h14.5a.75.75 0 0 1 .75.75zm0 4a.75.75 0 0 1-.75.75H7.321a.75.75 0 1 1 0-1.5h9.929a.75.75 0 0 1 .75.75zm0-8a.75.75 0 0 1-.75.75H7.321a.75.75 0 1 1 0-1.5h9.929a.75.75 0 0 1 .75.75z\"/></svg>';var Yw='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 3.75c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0 8c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm2.286 4c0 .414.336.75.75.75h9.928a.75.75 0 1 0 0-1.5H5.036a.75.75 0 0 0-.75.75zm0-8c0 .414.336.75.75.75h9.928a.75.75 0 1 0 0-1.5H5.036a.75.75 0 0 0-.75.75z\"/></svg>';var Qw='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 3.75c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0 8c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0 4c0 .414.336.75.75.75h9.929a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm0-8c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75z\"/></svg>';const Zw=new Map([[\"left\",Kw],[\"right\",Xw],[\"center\",Yw],[\"justify\",Qw]]);class t_ extends Nw{get localizedOptionTitles(){const t=this.editor.t;return{left:t(\"Align left\"),right:t(\"Align right\"),center:t(\"Align center\"),justify:t(\"Justify\")}}static get pluginName(){return\"AlignmentUI\"}init(){const t=this.editor;const e=t.ui.componentFactory;const i=t.t;const n=t.config.get(\"alignment.options\");n.filter(jw).forEach(t=>this._addButton(t));e.add(\"alignment\",t=>{const o=bw(t);const r=n.map(t=>e.create(`alignment:${t}`));ww(o,r);o.buttonView.set({label:i(\"Text alignment\"),tooltip:true});o.toolbarView.isVertical=true;o.toolbarView.ariaLabel=i(\"Text alignment toolbar\");o.extendTemplate({attributes:{class:\"ck-alignment-dropdown\"}});const s=t.contentLanguageDirection===\"rtl\"?Xw:Kw;o.buttonView.bind(\"icon\").toMany(r,\"isOn\",(...t)=>{const e=t.findIndex(t=>t);if(e<0){return s}return r[e].icon});o.bind(\"isEnabled\").toMany(r,\"isEnabled\",(...t)=>t.some(t=>t));return o})}_addButton(t){const e=this.editor;e.ui.componentFactory.add(`alignment:${t}`,i=>{const n=e.commands.get(\"alignment\");const o=new rw(i);o.set({label:this.localizedOptionTitles[t],icon:Zw.get(t),tooltip:true,isToggleable:true});o.bind(\"isEnabled\").to(n);o.bind(\"isOn\").to(n,\"value\",e=>e===t);this.listenTo(o,\"execute\",()=>{e.execute(\"alignment\",{value:t});e.editing.view.focus()});return o})}}class e_ extends Nw{static get requires(){return[Gw,t_]}static get pluginName(){return\"Alignment\"}}class i_{static get pluginName(){return\"BlockAutoformatEditing\"}constructor(t,e,i){let n;let o=null;if(typeof i==\"function\"){n=i}else{o=t.commands.get(i);n=()=>{t.execute(i)}}t.model.document.on(\"change\",(i,r)=>{if(o&&!o.isEnabled){return}if(r.type==\"transparent\"){return}const s=Array.from(t.model.document.differ.getChanges());const a=s[0];if(s.length!=1||a.type!==\"insert\"||a.name!=\"$text\"||a.length!=1){return}const l=a.position.parent;if(!l.is(\"paragraph\")||l.childCount!==1){return}const c=e.exec(l.getChild(0).data);if(!c){return}t.model.enqueueChange(t=>{const e=t.createPositionAt(l,0);const i=t.createPositionAt(l,c[0].length);const o=new lf(e,i);const r=n({match:c});if(r!==false){t.remove(o)}o.detach()})})}}function n_(t,e){let i=t.start;const n=Array.from(t.getItems()).reduce((t,n)=>{if(!(n.is(\"text\")||n.is(\"textProxy\"))){i=e.createPositionAfter(n);return\"\"}return t+n.data},\"\");return{text:n,range:e.createRange(i,t.end)}}class o_{static get pluginName(){return\"InlineAutoformatEditing\"}constructor(t,e,i){let n;let o;let r;let s;if(e instanceof RegExp){n=e}else{r=e}if(typeof i==\"string\"){o=i}else{s=i}r=r||(t=>{let e;const i=[];const o=[];while((e=n.exec(t))!==null){if(e&&e.length<4){break}let{index:t,1:n,2:r,3:s}=e;const a=n+r+s;t+=e[0].length-a.length;const l=[t,t+n.length];const c=[t+n.length+r.length,t+n.length+r.length+s.length];i.push(l);i.push(c);o.push([t+n.length,t+n.length+r.length])}return{remove:i,format:o}});s=s||((e,i)=>{const n=t.model.schema.getValidRanges(i,o);for(const t of n){e.setAttribute(o,true,t)}e.removeSelectionAttribute(o)});t.model.document.on(\"change\",(e,i)=>{if(i.type==\"transparent\"){return}const n=t.model;const o=n.document.selection;if(!o.isCollapsed){return}const a=Array.from(n.document.differ.getChanges());const l=a[0];if(a.length!=1||l.type!==\"insert\"||l.name!=\"$text\"||l.length!=1){return}const c=o.focus;const d=c.parent;const{text:u,range:h}=n_(n.createRange(n.createPositionAt(d,0),c),n);const f=r(u);const m=r_(h.start,f.format,n);const g=r_(h.start,f.remove,n);if(!(m.length&&g.length)){return}n.enqueueChange(t=>{const e=s(t,m);if(e===false){return}for(const e of g.reverse()){t.remove(e)}})})}}function r_(t,e,i){return e.filter(t=>t[0]!==undefined&&t[1]!==undefined).map(e=>i.createRange(t.getShiftedBy(e[0]),t.getShiftedBy(e[1])))}class s_ extends Nw{static get pluginName(){return\"Autoformat\"}afterInit(){this._addListAutoformats();this._addBasicStylesAutoformats();this._addHeadingAutoformats();this._addBlockQuoteAutoformats();this._addCodeBlockAutoformats()}_addListAutoformats(){const t=this.editor.commands;if(t.get(\"bulletedList\")){new i_(this.editor,/^[*-]\\s$/,\"bulletedList\")}if(t.get(\"numberedList\")){new i_(this.editor,/^1[.|)]\\s$/,\"numberedList\")}}_addBasicStylesAutoformats(){const t=this.editor.commands;if(t.get(\"bold\")){const t=a_(this.editor,\"bold\");new o_(this.editor,/(\\*\\*)([^*]+)(\\*\\*)$/g,t);new o_(this.editor,/(__)([^_]+)(__)$/g,t)}if(t.get(\"italic\")){const t=a_(this.editor,\"italic\");new o_(this.editor,/(?:^|[^*])(\\*)([^*_]+)(\\*)$/g,t);new o_(this.editor,/(?:^|[^_])(_)([^_]+)(_)$/g,t)}if(t.get(\"code\")){const t=a_(this.editor,\"code\");new o_(this.editor,/(`)([^`]+)(`)$/g,t)}if(t.get(\"strikethrough\")){const t=a_(this.editor,\"strikethrough\");new o_(this.editor,/(~~)([^~]+)(~~)$/g,t)}}_addHeadingAutoformats(){const t=this.editor.commands.get(\"heading\");if(t){t.modelElements.filter(t=>t.match(/^heading[1-6]$/)).forEach(e=>{const i=e[7];const n=new RegExp(`^(#{${i}})\\\\s$`);new i_(this.editor,n,()=>{if(!t.isEnabled){return false}this.editor.execute(\"heading\",{value:e})})})}}_addBlockQuoteAutoformats(){if(this.editor.commands.get(\"blockQuote\")){new i_(this.editor,/^>\\s$/,\"blockQuote\")}}_addCodeBlockAutoformats(){if(this.editor.commands.get(\"codeBlock\")){new i_(this.editor,/^```$/,\"codeBlock\")}}}function a_(t,e){return(i,n)=>{const o=t.commands.get(e);if(!o.isEnabled){return false}const r=t.model.schema.getValidRanges(n,e);for(const t of r){i.setAttribute(e,true,t)}i.removeSelectionAttribute(e)}}class l_ extends Vw{refresh(){this.value=this._getValue();this.isEnabled=this._checkEnabled()}execute(t={}){const e=this.editor.model;const i=e.schema;const n=e.document.selection;const o=Array.from(n.getSelectedBlocks());const r=t.forceValue===undefined?!this.value:t.forceValue;e.change(t=>{if(!r){this._removeQuote(t,o.filter(c_))}else{const e=o.filter(t=>c_(t)||u_(i,t));this._applyQuote(t,e)}})}_getValue(){const t=this.editor.model.document.selection;const e=zw(t.getSelectedBlocks());return!!(e&&c_(e))}_checkEnabled(){if(this.value){return true}const t=this.editor.model.document.selection;const e=this.editor.model.schema;const i=zw(t.getSelectedBlocks());if(!i){return false}return u_(e,i)}_removeQuote(t,e){d_(t,e).reverse().forEach(e=>{if(e.start.isAtStart&&e.end.isAtEnd){t.unwrap(e.start.parent);return}if(e.start.isAtStart){const i=t.createPositionBefore(e.start.parent);t.move(e,i);return}if(!e.end.isAtEnd){t.split(e.end)}const i=t.createPositionAfter(e.end.parent);t.move(e,i)})}_applyQuote(t,e){const i=[];d_(t,e).reverse().forEach(e=>{let n=c_(e.start);if(!n){n=t.createElement(\"blockQuote\");t.wrap(e,n)}i.push(n)});i.reverse().reduce((e,i)=>{if(e.nextSibling==i){t.merge(t.createPositionAfter(e));return e}return i})}}function c_(t){return t.parent.name==\"blockQuote\"?t.parent:null}function d_(t,e){let i;let n=0;const o=[];while(n<e.length){const r=e[n];const s=e[n+1];if(!i){i=t.createPositionBefore(r)}if(!s||r.nextSibling!=s){o.push(t.createRange(i,t.createPositionAfter(r)));i=null}n++}return o}function u_(t,e){const i=t.checkChild(e.parent,\"blockQuote\");const n=t.checkChild([\"$root\",\"blockQuote\"],e);return i&&n}class h_ extends Nw{static get pluginName(){return\"BlockQuoteEditing\"}init(){const t=this.editor;const e=t.model.schema;t.commands.add(\"blockQuote\",new l_(t));e.register(\"blockQuote\",{allowWhere:\"$block\",allowContentOf:\"$root\"});e.addChildCheck((t,e)=>{if(t.endsWith(\"blockQuote\")&&e.name==\"blockQuote\"){return false}});t.conversion.elementToElement({model:\"blockQuote\",view:\"blockquote\"});t.model.document.registerPostFixer(i=>{const n=t.model.document.differ.getChanges();for(const t of n){if(t.type==\"insert\"){const n=t.position.nodeAfter;if(!n){continue}if(n.is(\"blockQuote\")&&n.isEmpty){i.remove(n);return true}else if(n.is(\"blockQuote\")&&!e.checkChild(t.position,n)){i.unwrap(n);return true}else if(n.is(\"element\")){const t=i.createRangeIn(n);for(const n of t.getItems()){if(n.is(\"blockQuote\")&&!e.checkChild(i.createPositionBefore(n),n)){i.unwrap(n);return true}}}}else if(t.type==\"remove\"){const e=t.position.parent;if(e.is(\"blockQuote\")&&e.isEmpty){i.remove(e);return true}}}return false})}afterInit(){const t=this.editor;const e=t.commands.get(\"blockQuote\");this.listenTo(this.editor.editing.view.document,\"enter\",(t,i)=>{const n=this.editor.model.document;const o=n.selection.getLastPosition().parent;if(n.selection.isCollapsed&&o.isEmpty&&e.value){this.editor.execute(\"blockQuote\");this.editor.editing.view.scrollToTheSelection();i.preventDefault();t.stop()}})}}var f_='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M3 10.423a6.5 6.5 0 0 1 6.056-6.408l.038.67C6.448 5.423 5.354 7.663 5.22 10H9c.552 0 .5.432.5.986v4.511c0 .554-.448.503-1 .503h-5c-.552 0-.5-.449-.5-1.003v-4.574zm8 0a6.5 6.5 0 0 1 6.056-6.408l.038.67c-2.646.739-3.74 2.979-3.873 5.315H17c.552 0 .5.432.5.986v4.511c0 .554-.448.503-1 .503h-5c-.552 0-.5-.449-.5-1.003v-4.574z\"/></svg>';var m_=i(47);class g_ extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(\"blockQuote\",i=>{const n=t.commands.get(\"blockQuote\");const o=new rw(i);o.set({label:e(\"Block quote\"),icon:f_,tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(\"blockQuote\");t.editing.view.focus()});return o})}}class p_ extends Nw{static get requires(){return[h_,g_]}static get pluginName(){return\"BlockQuote\"}}class b_ extends Vw{constructor(t,e){super(t);this.attributeKey=e}refresh(){const t=this.editor.model;const e=t.document;this.value=this._getValueFromFirstAllowedNode();this.isEnabled=t.schema.checkAttributeInSelection(e.selection,this.attributeKey)}execute(t={}){const e=this.editor.model;const i=e.document;const n=i.selection;const o=t.forceValue===undefined?!this.value:t.forceValue;e.change(t=>{if(n.isCollapsed){if(o){t.setSelectionAttribute(this.attributeKey,true)}else{t.removeSelectionAttribute(this.attributeKey)}}else{const i=e.schema.getValidRanges(n.getRanges(),this.attributeKey);for(const e of i){if(o){t.setAttribute(this.attributeKey,o,e)}else{t.removeAttribute(this.attributeKey,e)}}}})}_getValueFromFirstAllowedNode(){const t=this.editor.model;const e=t.schema;const i=t.document.selection;if(i.isCollapsed){return i.hasAttribute(this.attributeKey)}for(const t of i.getRanges()){for(const i of t.getItems()){if(e.checkAttribute(i,this.attributeKey)){return i.hasAttribute(this.attributeKey)}}}return false}}const w_=\"bold\";class __ extends Nw{static get pluginName(){return\"BoldEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:w_});t.model.schema.setAttributeProperties(w_,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:w_,view:\"strong\",upcastAlso:[\"b\",t=>{const e=t.getStyle(\"font-weight\");if(!e){return null}if(e==\"bold\"||Number(e)>=600){return{name:true,styles:[\"font-weight\"]}}}]});t.commands.add(w_,new b_(t,w_));t.keystrokes.set(\"CTRL+B\",w_)}}var k_='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M10.187 17H5.773c-.637 0-1.092-.138-1.364-.415-.273-.277-.409-.718-.409-1.323V4.738c0-.617.14-1.062.419-1.332.279-.27.73-.406 1.354-.406h4.68c.69 0 1.288.041 1.793.124.506.083.96.242 1.36.478.341.197.644.447.906.75a3.262 3.262 0 0 1 .808 2.162c0 1.401-.722 2.426-2.167 3.075C15.05 10.175 16 11.315 16 13.01a3.756 3.756 0 0 1-2.296 3.504 6.1 6.1 0 0 1-1.517.377c-.571.073-1.238.11-2 .11zm-.217-6.217H7v4.087h3.069c1.977 0 2.965-.69 2.965-2.072 0-.707-.256-1.22-.768-1.537-.512-.319-1.277-.478-2.296-.478zM7 5.13v3.619h2.606c.729 0 1.292-.067 1.69-.2a1.6 1.6 0 0 0 .91-.765c.165-.267.247-.566.247-.897 0-.707-.26-1.176-.778-1.409-.519-.232-1.31-.348-2.375-.348H7z\"/></svg>';const v_=\"bold\";class y_ extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(v_,i=>{const n=t.commands.get(v_);const o=new rw(i);o.set({label:e(\"Bold\"),icon:k_,keystroke:\"CTRL+B\",tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(v_);t.editing.view.focus()});return o})}}class x_ extends Nw{static get requires(){return[__,y_]}static get pluginName(){return\"Bold\"}}const C_=\"code\";class A_ extends Nw{static get pluginName(){return\"CodeEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:C_});t.model.schema.setAttributeProperties(C_,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:C_,view:\"code\",upcastAlso:{styles:{\"word-wrap\":\"break-word\"}}});t.commands.add(C_,new b_(t,C_))}}var T_='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12.5 5.7l5.2 3.9v1.3l-5.6 4c-.1.2-.3.2-.5.2-.3-.1-.6-.7-.6-1l.3-.4 4.7-3.5L11.5 7l-.2-.2c-.1-.3-.1-.6 0-.8.2-.2.5-.4.8-.4a.8.8 0 0 1 .4.1zm-5.2 0L2 9.6v1.3l5.6 4c.1.2.3.2.5.2.3-.1.7-.7.6-1 0-.1 0-.3-.2-.4l-5-3.5L8.2 7l.2-.2c.1-.3.1-.6 0-.8-.2-.2-.5-.4-.8-.4a.8.8 0 0 0-.3.1z\"/></svg>';var P_=i(11);const E_=\"code\";class S_ extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(E_,i=>{const n=t.commands.get(E_);const o=new rw(i);o.set({label:e(\"Code\"),icon:T_,tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(E_);t.editing.view.focus()});return o})}}class M_ extends Nw{static get requires(){return[A_,S_]}static get pluginName(){return\"Code\"}}function*O_(t,e){for(const i of e){if(i&&t.getAttributeProperties(i[0]).copyOnEnter){yield i}}}class I_ extends Vw{execute(){const t=this.editor.model;const e=t.document;t.change(i=>{L_(t,i,e.selection);this.fire(\"afterExecute\",{writer:i})})}refresh(){const t=this.editor.model;const e=t.document;this.isEnabled=R_(t.schema,e.selection)}}function R_(t,e){if(e.rangeCount>1){return false}const i=e.anchor;if(!i||!t.checkChild(i,\"softBreak\")){return false}const n=e.getFirstRange();const o=n.start.parent;const r=n.end.parent;if((B_(o,t)||B_(r,t))&&o!==r){return false}return true}function L_(t,e,i){const n=i.isCollapsed;const o=i.getFirstRange();const r=o.start.parent;const s=o.end.parent;const a=r==s;if(n){const n=O_(t.schema,i.getAttributes());N_(t,e,o.end);e.removeSelectionAttribute(i.getAttributeKeys());e.setSelectionAttribute(n)}else{const n=!(o.start.isAtStart&&o.end.isAtEnd);t.deleteContent(i,{leaveUnmerged:n});if(a){N_(t,e,i.focus)}else{if(n){e.setSelection(s,0)}}}}function N_(t,e,i){const n=e.createElement(\"softBreak\");t.insertContent(n,i);e.setSelection(n,\"after\")}function B_(t,e){if(t.is(\"rootElement\")){return false}return e.isLimit(t)||B_(t.parent,e)}class V_ extends Gd{constructor(t){super(t);const e=this.document;e.on(\"keydown\",(t,i)=>{if(this.isEnabled&&i.keyCode==Lc.enter){let n;e.once(\"enter\",t=>n=t,{priority:\"highest\"});e.fire(\"enter\",new Ju(e,i.domEvent,{isSoft:i.shiftKey}));if(n&&n.stop.called){t.stop()}}})}observe(){}}class D_ extends Nw{static get pluginName(){return\"ShiftEnter\"}init(){const t=this.editor;const e=t.model.schema;const i=t.conversion;const n=t.editing.view;const o=n.document;e.register(\"softBreak\",{allowWhere:\"$text\",isInline:true});i.for(\"upcast\").elementToElement({model:\"softBreak\",view:\"br\"});i.for(\"downcast\").elementToElement({model:\"softBreak\",view:(t,e)=>e.createEmptyElement(\"br\")});n.addObserver(V_);t.commands.add(\"shiftEnter\",new I_(t));this.listenTo(o,\"enter\",(e,i)=>{i.preventDefault();if(!i.isSoft){return}t.execute(\"shiftEnter\");n.scrollToTheSelection()},{priority:\"low\"})}}function z_(t){const e=t.t;const i=t.config.get(\"codeBlock.languages\");for(const t of i){if(t.label===\"Plain text\"){t.label=e(\"Plain text\")}if(t.class===undefined){t.class=`language-${t.language}`}}return i}function F_(t,e,i){const n={};for(const o of t){if(e===\"class\"){n[o[e].split(\" \").shift()]=o[i]}else{n[o[e]]=o[i]}}return n}function j_(t){return t.data.match(/^(\\s*)/)[0]}function H_(t,e){const i=t.createDocumentFragment();const n=e.split(\"\\n\").map(e=>t.createText(e));const o=n[n.length-1];for(const e of n){t.append(e,i);if(e!==o){t.appendElement(\"softBreak\",i)}}return i}function W_(t){const e=t.document.selection;const i=[];if(e.isCollapsed){i.push(e.anchor)}else{const n=e.getFirstRange().getWalker({ignoreElementEnd:true,direction:\"backward\"});for(const{item:e}of n){if(e.is(\"textProxy\")&&e.parent.is(\"codeBlock\")){const n=j_(e.textNode);const{parent:o,startOffset:r}=e.textNode;const s=t.createPositionAt(o,r+n.length);i.push(s)}}}return i}function q_(t){const e=zw(t.getSelectedBlocks());return e&&e.is(\"codeBlock\")}class $_ extends Vw{refresh(){this.value=this._getValue();this.isEnabled=this._checkEnabled()}execute(t={}){const e=this.editor;const i=e.model;const n=i.document.selection;const o=z_(e);const r=o[0];const s=Array.from(n.getSelectedBlocks());const a=t.forceValue===undefined?!this.value:t.forceValue;const l=t.language||r.language;i.change(t=>{if(a){this._applyCodeBlock(t,s,l)}else{this._removeCodeBlock(t,s)}})}_getValue(){const t=this.editor.model.document.selection;const e=zw(t.getSelectedBlocks());const i=!!(e&&e.is(\"codeBlock\"));return i?e.getAttribute(\"language\"):false}_checkEnabled(){if(this.value){return true}const t=this.editor.model.document.selection;const e=this.editor.model.schema;const i=zw(t.getSelectedBlocks());if(!i){return false}return U_(e,i)}_applyCodeBlock(t,e,i){const n=this.editor.model.schema;const o=e.filter(t=>U_(n,t));for(const e of o){t.rename(e,\"codeBlock\");t.setAttribute(\"language\",i,e);n.removeDisallowedAttributes([e],t)}o.reverse().forEach((e,i)=>{const n=o[i+1];if(e.previousSibling===n){t.appendElement(\"softBreak\",n);t.merge(t.createPositionBefore(e))}})}_removeCodeBlock(t,e){const i=e.filter(t=>t.is(\"codeBlock\"));for(const e of i){const i=t.createRangeOn(e);for(const e of Array.from(i.getItems()).reverse()){if(e.is(\"softBreak\")&&e.parent.is(\"codeBlock\")){const{position:i}=t.split(t.createPositionBefore(e));t.rename(i.nodeAfter,\"paragraph\");t.removeAttribute(\"language\",i.nodeAfter);t.remove(e)}}t.rename(e,\"paragraph\");t.removeAttribute(\"language\",e)}}}function U_(t,e){if(e.is(\"rootElement\")||t.isLimit(e)){return false}return t.checkChild(e.parent,\"codeBlock\")}class G_ extends Vw{constructor(t){super(t);this._indentSequence=t.config.get(\"codeBlock.indentSequence\")}refresh(){this.isEnabled=this._checkEnabled()}execute(){const t=this.editor;const e=t.model;e.change(t=>{const i=W_(e);for(const e of i){t.insertText(this._indentSequence,e)}})}_checkEnabled(){if(!this._indentSequence){return false}return q_(this.editor.model.document.selection)}}class J_ extends Vw{constructor(t){super(t);this._indentSequence=t.config.get(\"codeBlock.indentSequence\")}refresh(){this.isEnabled=this._checkEnabled()}execute(){const t=this.editor;const e=t.model;e.change(t=>{const i=W_(e);for(const e of i){const i=K_(this.editor.model,e,this._indentSequence);if(i){t.remove(i)}}})}_checkEnabled(){if(!this._indentSequence){return false}const t=this.editor.model;if(!q_(t.document.selection)){return false}return W_(t).some(e=>K_(t,e,this._indentSequence))}}function K_(t,e,i){const n=X_(e);if(!n){return null}const o=j_(n);const r=o.lastIndexOf(i);if(r+i.length!==o.length){return null}if(r===-1){return null}const{parent:s,startOffset:a}=n;return t.createRange(t.createPositionAt(s,a+r),t.createPositionAt(s,a+r+i.length))}function X_(t){let e=t.parent.getChild(t.index);if(!e||e.is(\"softBreak\")){e=t.nodeBefore}if(!e||e.is(\"softBreak\")){return null}return e}function Y_(t,e,i=false){const n=F_(e,\"language\",\"class\");const o=F_(e,\"language\",\"label\");return(e,r,s)=>{const{writer:a,mapper:l,consumable:c}=s;if(!c.consume(r.item,\"insert\")){return}const d=r.item.getAttribute(\"language\");const u=l.toViewPosition(t.createPositionBefore(r.item));const h={};if(i){h[\"data-language\"]=o[d];h.spellcheck=\"false\"}const f=a.createContainerElement(\"pre\",h);const m=a.createContainerElement(\"code\",{class:n[d]||null});a.insert(a.createPositionAt(f,0),m);a.insert(u,f);l.bindElements(r.item,m)}}function Q_(t){return(e,i,n)=>{if(i.item.parent.name!==\"codeBlock\"){return}const{writer:o,mapper:r,consumable:s}=n;if(!s.consume(i.item,\"insert\")){return}const a=r.toViewPosition(t.createPositionBefore(i.item));o.insert(a,o.createText(\"\\n\"))}}function Z_(t,e){const i=F_(e,\"class\",\"language\");const n=e[0].language;return(e,o,r)=>{const s=o.viewItem;const a=s.getChild(0);if(!a||!a.is(\"code\")){return}const{consumable:l,writer:c}=r;if(!l.test(s,{name:true})||!l.test(a,{name:true})){return}const d=c.createElement(\"codeBlock\");const u=[...a.getClassNames()];if(!u.length){u.push(\"\")}for(const t of u){const e=i[t];if(e){c.setAttribute(\"language\",e,d);break}}if(!d.hasAttribute(\"language\")){c.setAttribute(\"language\",n,d)}const h=[...t.createRangeIn(a)].filter(t=>t.type===\"text\").map(({item:t})=>t.data).join(\"\");const f=H_(c,h);c.append(f,d);const m=r.splitToAllowedParent(d,o.modelCursor);if(!m){return}c.insert(d,m.position);l.consume(s,{name:true});l.consume(a,{name:true});const g=r.getSplitParts(d);o.modelRange=c.createRange(r.writer.createPositionBefore(d),r.writer.createPositionAfter(g[g.length-1]));if(m.cursorParent){o.modelCursor=c.createPositionAt(m.cursorParent,0)}else{o.modelCursor=o.modelRange.end}}}const tk=\"paragraph\";class ek extends Nw{static get pluginName(){return\"CodeBlockEditing\"}static get requires(){return[D_]}constructor(t){super(t);t.config.define(\"codeBlock\",{languages:[{language:\"plaintext\",label:\"Plain text\"},{language:\"c\",label:\"C\"},{language:\"cs\",label:\"C#\"},{language:\"cpp\",label:\"C++\"},{language:\"css\",label:\"CSS\"},{language:\"diff\",label:\"Diff\"},{language:\"html\",label:\"HTML\"},{language:\"java\",label:\"Java\"},{language:\"javascript\",label:\"JavaScript\"},{language:\"php\",label:\"PHP\"},{language:\"python\",label:\"Python\"},{language:\"ruby\",label:\"Ruby\"},{language:\"typescript\",label:\"TypeScript\"},{language:\"xml\",label:\"XML\"}],indentSequence:\"\\t\"})}init(){const t=this.editor;const e=t.model.schema;const i=t.model;const n=z_(t);t.commands.add(\"codeBlock\",new $_(t));t.commands.add(\"indentCodeBlock\",new G_(t));t.commands.add(\"outdentCodeBlock\",new J_(t));const o=t=>(e,i)=>{const n=this.editor.commands.get(t);if(n.isEnabled){this.editor.execute(t);i()}};t.keystrokes.set(\"Tab\",o(\"indentCodeBlock\"));t.keystrokes.set(\"Shift+Tab\",o(\"outdentCodeBlock\"));e.register(\"codeBlock\",{allowWhere:\"$block\",isBlock:true,allowAttributes:[\"language\"]});e.extend(\"$text\",{allowIn:\"codeBlock\"});e.addAttributeCheck(t=>{if(t.endsWith(\"codeBlock $text\")){return false}});t.editing.downcastDispatcher.on(\"insert:codeBlock\",Y_(i,n,true));t.data.downcastDispatcher.on(\"insert:codeBlock\",Y_(i,n));t.data.downcastDispatcher.on(\"insert:softBreak\",Q_(i),{priority:\"high\"});t.data.upcastDispatcher.on(\"element:pre\",Z_(t.editing.view,n));this.listenTo(t.editing.view.document,\"clipboardInput\",(t,e)=>{const n=i.document.selection;if(!n.anchor.parent.is(\"codeBlock\")){return}const o=e.dataTransfer.getData(\"text/plain\");i.change(e=>{i.insertContent(H_(e,o),n);t.stop()})});this.listenTo(i,\"getSelectedContent\",(t,[n])=>{const o=n.anchor;if(n.isCollapsed||!o.parent.is(\"codeBlock\")||!o.hasSameParentAs(n.focus)){return}i.change(i=>{const r=t.return;if(r.childCount>1||n.containsEntireContent(o.parent)){const e=i.createElement(\"codeBlock\",o.parent.getAttributes());i.append(r,e);const n=i.createDocumentFragment();i.append(e,n);t.return=n}else{const t=r.getChild(0);if(e.checkAttribute(t,\"code\")){i.setAttribute(\"code\",true,t)}}})})}afterInit(){const t=this.editor;const e=t.commands;const i=e.get(\"indent\");const n=e.get(\"outdent\");if(i){i.registerChildCommand(e.get(\"indentCodeBlock\"))}if(n){n.registerChildCommand(e.get(\"outdentCodeBlock\"))}this.listenTo(t.editing.view.document,\"enter\",(e,i)=>{const n=t.model.document.selection.getLastPosition().parent;if(!n.is(\"codeBlock\")){return}nk(t,i.isSoft)||ok(t,i.isSoft)||ik(t);i.preventDefault();e.stop()})}}function ik(t){const e=t.model;const i=e.document;const n=i.selection.getLastPosition();const o=n.nodeBefore||n.textNode;let r;if(o&&o.is(\"text\")){r=j_(o)}t.model.change(e=>{t.execute(\"shiftEnter\");if(r){e.insertText(r,i.selection.anchor)}})}function nk(t,e){const i=t.model;const n=i.document;const o=t.editing.view;const r=n.selection.getLastPosition();const s=r.nodeAfter;if(e||!n.selection.isCollapsed||!r.isAtStart){return false}if(!s||!s.is(\"softBreak\")){return false}t.model.change(e=>{t.execute(\"enter\");const i=n.selection.anchor.parent.previousSibling;e.rename(i,tk);e.setSelection(i,\"in\");t.model.schema.removeDisallowedAttributes([i],e);e.remove(s)});o.scrollToTheSelection();return true}function ok(t,e){const i=t.model;const n=i.document;const o=t.editing.view;const r=n.selection.getLastPosition();const s=r.nodeBefore;let a;if(e||!n.selection.isCollapsed||!r.isAtEnd||!s){return false}if(s.is(\"softBreak\")){a=i.createRangeOn(s)}else if(s.is(\"text\")&&!s.data.match(/\\S/)&&s.previousSibling&&s.previousSibling.is(\"softBreak\")){a=i.createRange(i.createPositionBefore(s.previousSibling),i.createPositionAfter(s))}else{return false}t.model.change(e=>{e.remove(a);t.execute(\"enter\");const i=n.selection.anchor.parent;e.rename(i,tk);t.model.schema.removeDisallowedAttributes([i],e)});o.scrollToTheSelection();return true}class rk{constructor(t,e){if(e){$l(this,e)}if(t){this.set(t)}}}ys(rk,Xl);var sk=i(50);class ak extends _b{constructor(t){super(t);const e=this.bindTemplate;this.set(\"icon\");this.set(\"isEnabled\",true);this.set(\"isOn\",false);this.set(\"isToggleable\",false);this.set(\"isVisible\",true);this.set(\"keystroke\");this.set(\"label\");this.set(\"tabindex\",-1);this.set(\"tooltip\");this.set(\"tooltipPosition\",\"s\");this.set(\"type\",\"button\");this.set(\"withText\",false);this.children=this.createCollection();this.actionView=this._createActionView();this.arrowView=this._createArrowView();this.keystrokes=new mp;this.focusTracker=new Pp;this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-splitbutton\",e.if(\"isVisible\",\"ck-hidden\",t=>!t),this.arrowView.bindTemplate.if(\"isOn\",\"ck-splitbutton_open\")]},children:this.children})}render(){super.render();this.children.add(this.actionView);this.children.add(this.arrowView);this.focusTracker.add(this.actionView.element);this.focusTracker.add(this.arrowView.element);this.keystrokes.listenTo(this.element);this.keystrokes.set(\"arrowright\",(t,e)=>{if(this.focusTracker.focusedElement===this.actionView.element){this.arrowView.focus();e()}});this.keystrokes.set(\"arrowleft\",(t,e)=>{if(this.focusTracker.focusedElement===this.arrowView.element){this.actionView.focus();e()}})}focus(){this.actionView.focus()}_createActionView(){const t=new rw;t.bind(\"icon\",\"isEnabled\",\"isOn\",\"isToggleable\",\"keystroke\",\"label\",\"tabindex\",\"tooltip\",\"tooltipPosition\",\"type\",\"withText\").to(this);t.extendTemplate({attributes:{class:\"ck-splitbutton__action\"}});t.delegate(\"execute\").to(this);return t}_createArrowView(){const t=new rw;const e=t.bindTemplate;t.icon=sw;t.extendTemplate({attributes:{class:\"ck-splitbutton__arrow\",\"aria-haspopup\":true,\"aria-expanded\":e.to(\"isOn\",t=>String(t))}});t.bind(\"isEnabled\").to(this);t.delegate(\"execute\").to(this,\"open\");return t}}var lk='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12.87 12.61a.75.75 0 0 1-.089.976l-.085.07-3.154 2.254 3.412 2.414a.75.75 0 0 1 .237.95l-.057.095a.75.75 0 0 1-.95.237l-.096-.058-4.272-3.022-.003-1.223 4.01-2.867a.75.75 0 0 1 1.047.174zm2.795-.231l.095.057 4.011 2.867-.003 1.223-4.272 3.022-.095.058a.75.75 0 0 1-.88-.151l-.07-.086-.058-.095a.75.75 0 0 1 .15-.88l.087-.07 3.412-2.414-3.154-2.253-.085-.071a.75.75 0 0 1 .862-1.207zM16 0a2 2 0 0 1 2 2v9.354l-.663-.492-.837-.001V2a.5.5 0 0 0-.5-.5H2a.5.5 0 0 0-.5.5v15a.5.5 0 0 0 .5.5h3.118L7.156 19H2a2 2 0 0 1-2-2V2a2 2 0 0 1 2-2h14zM5.009 15l.003 1H3v-1h2.009zm2.188-2l-1.471 1H5v-1h2.197zM10 11v.095L8.668 12H7v-1h3zm4-2v1H7V9h7zm0-2v1H7V7h7zm-4-2v1H5V5h5zM6 3v1H3V3h3z\"/></svg>';var ck=i(52);class dk extends Nw{init(){const t=this.editor;const e=t.t;const i=t.ui.componentFactory;const n=z_(t);const o=n[0];i.add(\"codeBlock\",i=>{const r=t.commands.get(\"codeBlock\");const s=bw(i,ak);const a=s.buttonView;a.set({label:e(\"Insert code block\"),tooltip:true,icon:lk,isToggleable:true});a.bind(\"isOn\").to(r,\"value\",t=>!!t);a.on(\"execute\",()=>{t.execute(\"codeBlock\",{language:o.language});t.editing.view.focus()});s.on(\"execute\",e=>{t.execute(\"codeBlock\",{language:e.source._codeBlockLanguage,forceValue:true});t.editing.view.focus()});s.class=\"ck-code-block-dropdown\";s.bind(\"isEnabled\").to(r);_w(s,this._getLanguageListItemDefinitions(n));return s})}_getLanguageListItemDefinitions(t){const e=this.editor;const i=e.commands.get(\"codeBlock\");const n=new xs;for(const e of t){const t={type:\"button\",model:new rk({_codeBlockLanguage:e.language,label:e.label,withText:true})};t.model.bind(\"isOn\").to(i,\"value\",e=>e===t.model._codeBlockLanguage);n.add(t)}return n}}class uk extends Nw{static get requires(){return[ek,dk]}static get pluginName(){return\"CodeBlock\"}}class hk{constructor(t){this.files=fk(t);this._native=t}get types(){return this._native.types}getData(t){return this._native.getData(t)}setData(t,e){this._native.setData(t,e)}}function fk(t){const e=t.files?Array.from(t.files):[];const i=t.items?Array.from(t.items):[];if(e.length){return e}return i.filter(t=>t.kind===\"file\").map(t=>t.getAsFile())}class mk extends Ku{constructor(t){super(t);const e=this.document;this.domEventType=[\"paste\",\"copy\",\"cut\",\"drop\",\"dragover\"];this.listenTo(e,\"paste\",i,{priority:\"low\"});this.listenTo(e,\"drop\",i,{priority:\"low\"});function i(t,i){i.preventDefault();const n=i.dropRange?[i.dropRange]:Array.from(e.selection.getRanges());const o=new ts(e,\"clipboardInput\");e.fire(o,{dataTransfer:i.dataTransfer,targetRanges:n});if(o.stop.called){i.stopPropagation()}}}onDomEvent(t){const e={dataTransfer:new hk(t.clipboardData?t.clipboardData:t.dataTransfer)};if(t.type==\"drop\"){e.dropRange=gk(this.view,t)}this.fire(t.type,t,e)}}function gk(t,e){const i=e.target.ownerDocument;const n=e.clientX;const o=e.clientY;let r;if(i.caretRangeFromPoint&&i.caretRangeFromPoint(n,o)){r=i.caretRangeFromPoint(n,o)}else if(e.rangeParent){r=i.createRange();r.setStart(e.rangeParent,e.rangeOffset);r.collapse(true)}if(r){return t.domConverter.domRangeToView(r)}else{return t.document.selection.getFirstRange()}}function pk(t){t=t.replace(/</g,\"&lt;\").replace(/>/g,\"&gt;\").replace(/\\n/g,\"</p><p>\").replace(/^\\s/,\"&nbsp;\").replace(/\\s$/,\"&nbsp;\").replace(/\\s\\s/g,\" &nbsp;\");if(t.indexOf(\"</p><p>\")>-1){t=`<p>${t}</p>`}return t}function bk(t){return t.replace(/<span(?: class=\"Apple-converted-space\"|)>(\\s+)<\\/span>/g,(t,e)=>{if(e.length==1){return\" \"}return e})}const wk=[\"figcaption\",\"li\"];function _k(t){let e=\"\";if(t.is(\"text\")||t.is(\"textProxy\")){e=t.data}else if(t.is(\"img\")&&t.hasAttribute(\"alt\")){e=t.getAttribute(\"alt\")}else{let i=null;for(const n of t.getChildren()){const t=_k(n);if(i&&(i.is(\"containerElement\")||n.is(\"containerElement\"))){if(wk.includes(i.name)||wk.includes(n.name)){e+=\"\\n\"}else{e+=\"\\n\\n\"}}e+=t;i=n}}return e}class kk extends Nw{static get pluginName(){return\"Clipboard\"}init(){const t=this.editor;const e=t.model.document;const i=t.editing.view;const n=i.document;this._htmlDataProcessor=new Cp(n);i.addObserver(mk);this.listenTo(n,\"clipboardInput\",e=>{if(t.isReadOnly){e.stop()}},{priority:\"highest\"});this.listenTo(n,\"clipboardInput\",(t,e)=>{const n=e.dataTransfer;let o=\"\";if(n.getData(\"text/html\")){o=bk(n.getData(\"text/html\"))}else if(n.getData(\"text/plain\")){o=pk(n.getData(\"text/plain\"))}o=this._htmlDataProcessor.toView(o);const r=new ts(this,\"inputTransformation\");this.fire(r,{content:o,dataTransfer:n});if(r.stop.called){t.stop()}i.scrollToTheSelection()},{priority:\"low\"});this.listenTo(this,\"inputTransformation\",(t,e)=>{if(!e.content.isEmpty){const i=this.editor.data;const n=this.editor.model;const o=i.toModel(e.content,\"$clipboardHolder\");if(o.childCount==0){return}n.insertContent(o);t.stop()}},{priority:\"low\"});function o(i,o){const r=o.dataTransfer;o.preventDefault();const s=t.data.toView(t.model.getSelectedContent(e.selection));n.fire(\"clipboardOutput\",{dataTransfer:r,content:s,method:i.name})}this.listenTo(n,\"copy\",o,{priority:\"low\"});this.listenTo(n,\"cut\",(e,i)=>{if(t.isReadOnly){i.preventDefault()}else{o(e,i)}},{priority:\"low\"});this.listenTo(n,\"clipboardOutput\",(i,n)=>{if(!n.content.isEmpty){n.dataTransfer.setData(\"text/html\",this._htmlDataProcessor.toData(n.content));n.dataTransfer.setData(\"text/plain\",_k(n.content))}if(n.method==\"cut\"){t.model.deleteContent(e.selection)}},{priority:\"low\"})}}class vk extends Vw{execute(){const t=this.editor.model;const e=t.document;t.change(i=>{yk(this.editor.model,i,e.selection,t.schema);this.fire(\"afterExecute\",{writer:i})})}}function yk(t,e,i,n){const o=i.isCollapsed;const r=i.getFirstRange();const s=r.start.parent;const a=r.end.parent;if(n.isLimit(s)||n.isLimit(a)){if(!o&&s==a){t.deleteContent(i)}return}if(o){const t=O_(e.model.schema,i.getAttributes());xk(e,r.start);e.setSelectionAttribute(t)}else{const n=!(r.start.isAtStart&&r.end.isAtEnd);const o=s==a;t.deleteContent(i,{leaveUnmerged:n});if(n){if(o){xk(e,i.focus)}else{e.setSelection(a,0)}}}}function xk(t,e){t.split(e);t.setSelection(e.parent.nextSibling,0)}class Ck extends Nw{static get pluginName(){return\"Enter\"}init(){const t=this.editor;const e=t.editing.view;const i=e.document;e.addObserver(V_);t.commands.add(\"enter\",new vk(t));this.listenTo(i,\"enter\",(i,n)=>{n.preventDefault();if(n.isSoft){return}t.execute(\"enter\");e.scrollToTheSelection()},{priority:\"low\"})}}class Ak extends Vw{execute(){const t=this.editor.model;const e=t.schema.getLimitElement(t.document.selection);t.change(t=>{t.setSelection(e,\"in\")})}}const Tk=Bc(\"Ctrl+A\");class Pk extends Nw{static get pluginName(){return\"SelectAllEditing\"}init(){const t=this.editor;const e=t.editing.view;const i=e.document;t.commands.add(\"selectAll\",new Ak(t));this.listenTo(i,\"keydown\",(e,i)=>{if(Nc(i)===Tk){t.execute(\"selectAll\");i.preventDefault()}})}}var Ek='<svg width=\"20\" height=\"20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M.75 15.5a.75.75 0 0 1 .75.75V18l.008.09A.5.5 0 0 0 2 18.5h1.75a.75.75 0 1 1 0 1.5H1.5l-.144-.007a1.5 1.5 0 0 1-1.35-1.349L0 18.5v-2.25a.75.75 0 0 1 .75-.75zm18.5 0a.75.75 0 0 1 .75.75v2.25l-.007.144a1.5 1.5 0 0 1-1.349 1.35L18.5 20h-2.25a.75.75 0 1 1 0-1.5H18a.5.5 0 0 0 .492-.41L18.5 18v-1.75a.75.75 0 0 1 .75-.75zm-10.45 3c.11 0 .2.09.2.2v1.1a.2.2 0 0 1-.2.2H7.2a.2.2 0 0 1-.2-.2v-1.1c0-.11.09-.2.2-.2h1.6zm4 0c.11 0 .2.09.2.2v1.1a.2.2 0 0 1-.2.2h-1.6a.2.2 0 0 1-.2-.2v-1.1c0-.11.09-.2.2-.2h1.6zm.45-5.5a.75.75 0 1 1 0 1.5h-8.5a.75.75 0 1 1 0-1.5h8.5zM1.3 11c.11 0 .2.09.2.2v1.6a.2.2 0 0 1-.2.2H.2a.2.2 0 0 1-.2-.2v-1.6c0-.11.09-.2.2-.2h1.1zm18.5 0c.11 0 .2.09.2.2v1.6a.2.2 0 0 1-.2.2h-1.1a.2.2 0 0 1-.2-.2v-1.6c0-.11.09-.2.2-.2h1.1zm-4.55-2a.75.75 0 1 1 0 1.5H4.75a.75.75 0 1 1 0-1.5h10.5zM1.3 7c.11 0 .2.09.2.2v1.6a.2.2 0 0 1-.2.2H.2a.2.2 0 0 1-.2-.2V7.2c0-.11.09-.2.2-.2h1.1zm18.5 0c.11 0 .2.09.2.2v1.6a.2.2 0 0 1-.2.2h-1.1a.2.2 0 0 1-.2-.2V7.2c0-.11.09-.2.2-.2h1.1zm-4.55-2a.75.75 0 1 1 0 1.5h-2.5a.75.75 0 1 1 0-1.5h2.5zm-5 0a.75.75 0 1 1 0 1.5h-5.5a.75.75 0 0 1 0-1.5h5.5zm-6.5-5a.75.75 0 0 1 0 1.5H2a.5.5 0 0 0-.492.41L1.5 2v1.75a.75.75 0 0 1-1.5 0V1.5l.007-.144A1.5 1.5 0 0 1 1.356.006L1.5 0h2.25zM18.5 0l.144.007a1.5 1.5 0 0 1 1.35 1.349L20 1.5v2.25a.75.75 0 1 1-1.5 0V2l-.008-.09A.5.5 0 0 0 18 1.5h-1.75a.75.75 0 1 1 0-1.5h2.25zM8.8 0c.11 0 .2.09.2.2v1.1a.2.2 0 0 1-.2.2H7.2a.2.2 0 0 1-.2-.2V.2c0-.11.09-.2.2-.2h1.6zm4 0c.11 0 .2.09.2.2v1.1a.2.2 0 0 1-.2.2h-1.6a.2.2 0 0 1-.2-.2V.2c0-.11.09-.2.2-.2h1.6z\"/></svg>';class Sk extends Nw{static get pluginName(){return\"SelectAllUI\"}init(){const t=this.editor;t.ui.componentFactory.add(\"selectAll\",e=>{const i=t.commands.get(\"selectAll\");const n=new rw(e);const o=e.t;n.set({label:o(\"Select all\"),icon:Ek,keystroke:\"Ctrl+A\",tooltip:true});n.bind(\"isOn\",\"isEnabled\").to(i,\"value\",\"isEnabled\");this.listenTo(n,\"execute\",()=>{t.execute(\"selectAll\");t.editing.view.focus()});return n})}}class Mk extends Nw{static get requires(){return[Pk,Sk]}static get pluginName(){return\"SelectAll\"}}class Ok{constructor(t,e=20){this.model=t;this.size=0;this.limit=e;this.isLocked=false;this._changeCallback=(t,e)=>{if(e.type!=\"transparent\"&&e!==this._batch){this._reset(true)}};this._selectionChangeCallback=()=>{this._reset()};this.model.document.on(\"change\",this._changeCallback);this.model.document.selection.on(\"change:range\",this._selectionChangeCallback);this.model.document.selection.on(\"change:attribute\",this._selectionChangeCallback)}get batch(){if(!this._batch){this._batch=this.model.createBatch()}return this._batch}input(t){this.size+=t;if(this.size>=this.limit){this._reset(true)}}lock(){this.isLocked=true}unlock(){this.isLocked=false}destroy(){this.model.document.off(\"change\",this._changeCallback);this.model.document.selection.off(\"change:range\",this._selectionChangeCallback);this.model.document.selection.off(\"change:attribute\",this._selectionChangeCallback)}_reset(t){if(!this.isLocked||t){this._batch=null;this.size=0}}}class Ik extends Vw{constructor(t,e){super(t);this._buffer=new Ok(t.model,e);this._batches=new WeakSet}get buffer(){return this._buffer}destroy(){super.destroy();this._buffer.destroy()}execute(t={}){const e=this.editor.model;const i=e.document;const n=t.text||\"\";const o=n.length;const r=t.range?e.createSelection(t.range):i.selection;const s=t.resultRange;e.enqueueChange(this._buffer.batch,t=>{this._buffer.lock();e.deleteContent(r);if(n){e.insertContent(t.createText(n,i.selection.getAttributes()),r)}if(s){t.setSelection(s)}else if(!r.is(\"documentSelection\")){t.setSelection(r)}this._buffer.unlock();this._buffer.input(o);this._batches.add(this._buffer.batch)})}}function Rk(t){let e=null;const i=t.model;const n=t.editing.view;const o=t.commands.get(\"input\");if(Tc.isAndroid){n.document.on(\"beforeinput\",(t,e)=>r(e),{priority:\"lowest\"})}else{n.document.on(\"keydown\",(t,e)=>r(e),{priority:\"lowest\"})}n.document.on(\"compositionstart\",s,{priority:\"lowest\"});n.document.on(\"compositionend\",()=>{e=i.createSelection(i.document.selection)},{priority:\"lowest\"});function r(t){const r=i.document;const s=n.document.isComposing;const l=e&&e.isEqual(r.selection);e=null;if(!o.isEnabled){return}if(Nk(t)||r.selection.isCollapsed){return}if(s&&t.keyCode===229){return}if(!s&&t.keyCode===229&&l){return}a()}function s(){const t=i.document;const e=t.selection.rangeCount===1?t.selection.getFirstRange().isFlat:true;if(t.selection.isCollapsed||e){return}a()}function a(){const t=o.buffer;t.lock();i.enqueueChange(t.batch,()=>{i.deleteContent(i.document.selection)});t.unlock()}}const Lk=[Nc(\"arrowUp\"),Nc(\"arrowRight\"),Nc(\"arrowDown\"),Nc(\"arrowLeft\"),9,16,17,18,19,20,27,33,34,35,36,45,91,93,144,145,173,174,175,176,177,178,179,255];for(let t=112;t<=135;t++){Lk.push(t)}function Nk(t){if(t.ctrlKey){return true}return Lk.includes(t.keyCode)}function Bk(t,e){const i=[];let n=0;let o;t.forEach(t=>{if(t==\"equal\"){r();n++}else if(t==\"insert\"){if(s(\"insert\")){o.values.push(e[n])}else{r();o={type:\"insert\",index:n,values:[e[n]]}}n++}else{if(s(\"delete\")){o.howMany++}else{r();o={type:\"delete\",index:n,howMany:1}}}});r();return i;function r(){if(o){i.push(o);o=null}}function s(t){return o&&o.type==t}}function Vk(t){if(t.length==0){return false}for(const e of t){if(e.type===\"children\"&&!Dk(e)){return true}}return false}function Dk(t){if(t.newChildren.length-t.oldChildren.length!=1){return}const e=kd(t.oldChildren,t.newChildren,zk);const i=Bk(e,t.newChildren);if(i.length>1){return}const n=i[0];if(!(!!n.values[0]&&n.values[0].is(\"text\"))){return}return n}function zk(t,e){if(!!t&&t.is(\"text\")&&!!e&&e.is(\"text\")){return t.data===e.data}else{return t===e}}function Fk(t){t.editing.view.document.on(\"mutations\",(e,i,n)=>{new jk(t).handle(i,n)})}class jk{constructor(t){this.editor=t;this.editing=this.editor.editing}handle(t,e){if(Vk(t)){this._handleContainerChildrenMutations(t,e)}else{for(const i of t){this._handleTextMutation(i,e);this._handleTextNodeInsertion(i)}}}_handleContainerChildrenMutations(t,e){const i=Hk(t);if(!i){return}const n=this.editor.editing.view.domConverter;const o=n.mapViewToDom(i);const r=new Vd(this.editor.editing.view.document);const s=this.editor.data.toModel(r.domToView(o)).getChild(0);const a=this.editor.editing.mapper.toModelElement(i);if(!a){return}const l=Array.from(s.getChildren());const c=Array.from(a.getChildren());const d=l[l.length-1];const u=c[c.length-1];if(d&&d.is(\"softBreak\")&&u&&!u.is(\"softBreak\")){l.pop()}const h=this.editor.model.schema;if(!Wk(l,h)||!Wk(c,h)){return}const f=l.map(t=>t.is(\"text\")?t.data:\"@\").join(\"\").replace(/\\u00A0/g,\" \");const m=c.map(t=>t.is(\"text\")?t.data:\"@\").join(\"\").replace(/\\u00A0/g,\" \");if(m===f){return}const g=kd(m,f);const{firstChangeAt:p,insertions:b,deletions:w}=qk(g);let _=null;if(e){_=this.editing.mapper.toModelRange(e.getFirstRange())}const k=f.substr(p,b);const v=this.editor.model.createRange(this.editor.model.createPositionAt(a,p),this.editor.model.createPositionAt(a,p+w));this.editor.execute(\"input\",{text:k,range:v,resultRange:_})}_handleTextMutation(t,e){if(t.type!=\"text\"){return}const i=t.newText.replace(/\\u00A0/g,\" \");const n=t.oldText.replace(/\\u00A0/g,\" \");if(n===i){return}const o=kd(n,i);const{firstChangeAt:r,insertions:s,deletions:a}=qk(o);let l=null;if(e){l=this.editing.mapper.toModelRange(e.getFirstRange())}const c=this.editing.view.createPositionAt(t.node,r);const d=this.editing.mapper.toModelPosition(c);const u=this.editor.model.createRange(d,d.getShiftedBy(a));const h=i.substr(r,s);this.editor.execute(\"input\",{text:h,range:u,resultRange:l})}_handleTextNodeInsertion(t){if(t.type!=\"children\"){return}const e=Dk(t);const i=this.editing.view.createPositionAt(t.node,e.index);const n=this.editing.mapper.toModelPosition(i);const o=e.values[0].data;this.editor.execute(\"input\",{text:o.replace(/\\u00A0/g,\" \"),range:this.editor.model.createRange(n)})}}function Hk(t){const e=t.map(t=>t.node).reduce((t,e)=>t.getCommonAncestor(e,{includeSelf:true}));if(!e){return}return e.getAncestors({includeSelf:true,parentFirst:true}).find(t=>t.is(\"containerElement\")||t.is(\"rootElement\"))}function Wk(t,e){return t.every(t=>e.isInline(t))}function qk(t){let e=null;let i=null;for(let n=0;n<t.length;n++){const o=t[n];if(o!=\"equal\"){e=e===null?n:e;i=n}}let n=0;let o=0;for(let r=e;r<=i;r++){if(t[r]!=\"insert\"){n++}if(t[r]!=\"delete\"){o++}}return{insertions:o,deletions:n,firstChangeAt:e}}class $k extends Nw{static get pluginName(){return\"Input\"}init(){const t=this.editor;const e=new Ik(t,t.config.get(\"typing.undoStep\")||20);t.commands.add(\"input\",e);Rk(t);Fk(t)}isInput(t){const e=this.editor.commands.get(\"input\");return e._batches.has(t)}}class Uk extends Vw{constructor(t,e){super(t);this.direction=e;this._buffer=new Ok(t.model,t.config.get(\"typing.undoStep\"))}get buffer(){return this._buffer}execute(t={}){const e=this.editor.model;const i=e.document;e.enqueueChange(this._buffer.batch,n=>{this._buffer.lock();const o=n.createSelection(t.selection||i.selection);const r=o.isCollapsed;if(o.isCollapsed){e.modifySelection(o,{direction:this.direction,unit:t.unit})}if(this._shouldEntireContentBeReplacedWithParagraph(t.sequence||1)){this._replaceEntireContentWithParagraph(n);return}if(o.isCollapsed){return}let s=0;o.getFirstRange().getMinimalFlatRanges().forEach(t=>{s+=mc(t.getWalker({singleCharacters:true,ignoreElementEnd:true,shallow:true}))});e.deleteContent(o,{doNotResetEntireContent:r,direction:this.direction});this._buffer.input(s);n.setSelection(o);this._buffer.unlock()})}_shouldEntireContentBeReplacedWithParagraph(t){if(t>1){return false}const e=this.editor.model;const i=e.document;const n=i.selection;const o=e.schema.getLimitElement(n);const r=n.isCollapsed&&n.containsEntireContent(o);if(!r){return false}if(!e.schema.checkChild(o,\"paragraph\")){return false}const s=o.getChild(0);if(s&&s.name===\"paragraph\"){return false}return true}_replaceEntireContentWithParagraph(t){const e=this.editor.model;const i=e.document;const n=i.selection;const o=e.schema.getLimitElement(n);const r=t.createElement(\"paragraph\");t.remove(t.createRangeIn(o));t.insert(r,o);t.setSelection(r,0)}}class Gk extends Gd{constructor(t){super(t);const e=t.document;let i=0;e.on(\"keyup\",(t,e)=>{if(e.keyCode==Lc.delete||e.keyCode==Lc.backspace){i=0}});e.on(\"keydown\",(t,e)=>{const o={};if(e.keyCode==Lc.delete){o.direction=\"forward\";o.unit=\"character\"}else if(e.keyCode==Lc.backspace){o.direction=\"backward\";o.unit=\"codePoint\"}else{return}const r=Tc.isMac?e.altKey:e.ctrlKey;o.unit=r?\"word\":o.unit;o.sequence=++i;n(t,e.domEvent,o)});if(Tc.isAndroid){e.on(\"beforeinput\",(e,i)=>{if(i.domEvent.inputType!=\"deleteContentBackward\"){return}const o={unit:\"codepoint\",direction:\"backward\",sequence:1};const r=i.domTarget.ownerDocument.defaultView.getSelection();if(r.anchorNode==r.focusNode&&r.anchorOffset+1!=r.focusOffset){o.selectionToRemove=t.domConverter.domSelectionToView(r)}n(e,i.domEvent,o)})}function n(t,i,n){let o;e.once(\"delete\",t=>o=t,{priority:Number.POSITIVE_INFINITY});e.fire(\"delete\",new Ju(e,i,n));if(o&&o.stop.called){t.stop()}}}observe(){}}class Jk extends Nw{static get pluginName(){return\"Delete\"}init(){const t=this.editor;const e=t.editing.view;const i=e.document;e.addObserver(Gk);t.commands.add(\"forwardDelete\",new Uk(t,\"forward\"));t.commands.add(\"delete\",new Uk(t,\"backward\"));this.listenTo(i,\"delete\",(i,n)=>{const o={unit:n.unit,sequence:n.sequence};if(n.selectionToRemove){const e=t.model.createSelection();const i=[];for(const e of n.selectionToRemove.getRanges()){i.push(t.editing.mapper.toModelRange(e))}e.setTo(i);o.selection=e}t.execute(n.direction==\"forward\"?\"forwardDelete\":\"delete\",o);n.preventDefault();e.scrollToTheSelection()});if(Tc.isAndroid){let t=null;this.listenTo(i,\"delete\",(e,i)=>{const n=i.domTarget.ownerDocument.defaultView.getSelection();t={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}},{priority:\"lowest\"});this.listenTo(i,\"keyup\",(e,i)=>{if(t){const e=i.domTarget.ownerDocument.defaultView.getSelection();e.collapse(t.anchorNode,t.anchorOffset);e.extend(t.focusNode,t.focusOffset);t=null}})}}}class Kk extends Nw{static get requires(){return[$k,Jk]}static get pluginName(){return\"Typing\"}}const Xk=new Map;function Yk(t,e,i){let n=Xk.get(t);if(!n){n=new Map;Xk.set(t,n)}n.set(e,i)}function Qk(t,e){const i=Xk.get(t);if(i&&i.has(e)){return i.get(e)}return Zk}function Zk(t){return[t]}function tv(t,e,i={}){const n=Qk(t.constructor,e.constructor);try{t=t.clone();return n(t,e,i)}catch(t){throw t}}function ev(t,e,i){t=t.slice();e=e.slice();const n=new iv(i.document,i.useRelations,i.forceWeakRemove);n.setOriginalOperations(t);n.setOriginalOperations(e);const o=n.originalOperations;if(t.length==0||e.length==0){return{operationsA:t,operationsB:e,originalOperations:o}}const r=new WeakMap;for(const e of t){r.set(e,0)}const s={nextBaseVersionA:t[t.length-1].baseVersion+1,nextBaseVersionB:e[e.length-1].baseVersion+1,originalOperationsACount:t.length,originalOperationsBCount:e.length};let a=0;while(a<t.length){const i=t[a];const o=r.get(i);if(o==e.length){a++;continue}const s=e[o];const l=tv(i,s,n.getContext(i,s,true));const c=tv(s,i,n.getContext(s,i,false));n.updateRelation(i,s);n.setOriginalOperations(l,i);n.setOriginalOperations(c,s);for(const t of l){r.set(t,o+c.length)}t.splice(a,1,...l);e.splice(o,1,...c)}if(i.padWithNoOps){const i=t.length-s.originalOperationsACount;const n=e.length-s.originalOperationsBCount;ov(t,n-i);ov(e,i-n)}nv(t,s.nextBaseVersionB);nv(e,s.nextBaseVersionA);return{operationsA:t,operationsB:e,originalOperations:o}}class iv{constructor(t,e,i=false){this.originalOperations=new Map;this._history=t.history;this._useRelations=e;this._forceWeakRemove=!!i;this._relations=new Map}setOriginalOperations(t,e=null){const i=e?this.originalOperations.get(e):null;for(const e of t){this.originalOperations.set(e,i||e)}}updateRelation(t,e){switch(t.constructor){case ng:{switch(e.constructor){case lg:{if(t.targetPosition.isEqual(e.sourcePosition)||e.movedRange.containsPosition(t.targetPosition)){this._setRelation(t,e,\"insertAtSource\")}else if(t.targetPosition.isEqual(e.deletionPosition)){this._setRelation(t,e,\"insertBetween\")}else if(t.targetPosition.isAfter(e.sourcePosition)){this._setRelation(t,e,\"moveTargetAfter\")}break}case ng:{if(t.targetPosition.isEqual(e.sourcePosition)||t.targetPosition.isBefore(e.sourcePosition)){this._setRelation(t,e,\"insertBefore\")}else{this._setRelation(t,e,\"insertAfter\")}break}}break}case cg:{switch(e.constructor){case lg:{if(t.splitPosition.isBefore(e.sourcePosition)){this._setRelation(t,e,\"splitBefore\")}break}case ng:{if(t.splitPosition.isEqual(e.sourcePosition)||t.splitPosition.isBefore(e.sourcePosition)){this._setRelation(t,e,\"splitBefore\")}break}}break}case lg:{switch(e.constructor){case lg:{if(!t.targetPosition.isEqual(e.sourcePosition)){this._setRelation(t,e,\"mergeTargetNotMoved\")}if(t.sourcePosition.isEqual(e.targetPosition)){this._setRelation(t,e,\"mergeSourceNotMoved\")}if(t.sourcePosition.isEqual(e.sourcePosition)){this._setRelation(t,e,\"mergeSameElement\")}break}case cg:{if(t.sourcePosition.isEqual(e.splitPosition)){this._setRelation(t,e,\"splitAtSource\")}}}break}case rg:{const i=t.newRange;if(!i){return}switch(e.constructor){case ng:{const n=Kh._createFromPositionAndShift(e.sourcePosition,e.howMany);const o=n.containsPosition(i.start)||n.start.isEqual(i.start);const r=n.containsPosition(i.end)||n.end.isEqual(i.end);if((o||r)&&!n.containsRange(i)){this._setRelation(t,e,{side:o?\"left\":\"right\",path:o?i.start.path.slice():i.end.path.slice()})}break}case lg:{const n=i.start.isEqual(e.targetPosition);const o=i.start.isEqual(e.deletionPosition);const r=i.end.isEqual(e.deletionPosition);const s=i.end.isEqual(e.sourcePosition);if(n||o||r||s){this._setRelation(t,e,{wasInLeftElement:n,wasStartBeforeMergedElement:o,wasEndBeforeMergedElement:r,wasInRightElement:s})}break}}break}}}getContext(t,e,i){return{aIsStrong:i,aWasUndone:this._wasUndone(t),bWasUndone:this._wasUndone(e),abRelation:this._useRelations?this._getRelation(t,e):null,baRelation:this._useRelations?this._getRelation(e,t):null,forceWeakRemove:this._forceWeakRemove}}_wasUndone(t){const e=this.originalOperations.get(t);return e.wasUndone||this._history.isUndoneOperation(e)}_getRelation(t,e){const i=this.originalOperations.get(e);const n=this._history.getUndoneOperation(i);if(!n){return null}const o=this.originalOperations.get(t);const r=this._relations.get(o);if(r){return r.get(n)||null}return null}_setRelation(t,e,i){const n=this.originalOperations.get(t);const o=this.originalOperations.get(e);let r=this._relations.get(n);if(!r){r=new Map;this._relations.set(n,r)}r.set(o,i)}}function nv(t,e){for(const i of t){i.baseVersion=e++}}function ov(t,e){for(let i=0;i<e;i++){t.push(new Ig(0))}}Yk(eg,eg,(t,e,i)=>{if(t.key===e.key&&t.range.start.hasSameParentAs(e.range.start)){const n=t.range.getDifference(e.range).map(e=>new eg(e,t.key,t.oldValue,t.newValue,0));const o=t.range.getIntersection(e.range);if(o){if(i.aIsStrong){n.push(new eg(o,e.key,e.newValue,t.newValue,0))}}if(n.length==0){return[new Ig(0)]}return n}else{return[t]}});Yk(eg,og,(t,e)=>{if(t.range.start.hasSameParentAs(e.position)&&t.range.containsPosition(e.position)){const i=t.range._getTransformedByInsertion(e.position,e.howMany,!e.shouldReceiveAttributes);const n=i.map(e=>new eg(e,t.key,t.oldValue,t.newValue,t.baseVersion));if(e.shouldReceiveAttributes){const i=rv(e,t.key,t.oldValue);if(i){n.unshift(i)}}return n}t.range=t.range._getTransformedByInsertion(e.position,e.howMany,false)[0];return[t]});function rv(t,e,i){const n=t.nodes;const o=n.getNode(0).getAttribute(e);if(o==i){return null}const r=new Kh(t.position,t.position.getShiftedBy(t.howMany));return new eg(r,e,o,i,0)}Yk(eg,lg,(t,e)=>{const i=[];if(t.range.start.hasSameParentAs(e.deletionPosition)){if(t.range.containsPosition(e.deletionPosition)||t.range.start.isEqual(e.deletionPosition)){i.push(Kh._createFromPositionAndShift(e.graveyardPosition,1))}}const n=t.range._getTransformedByMergeOperation(e);if(!n.isCollapsed){i.push(n)}return i.map(e=>new eg(e,t.key,t.oldValue,t.newValue,t.baseVersion))});Yk(eg,ng,(t,e)=>{const i=sv(t.range,e);return i.map(e=>new eg(e,t.key,t.oldValue,t.newValue,t.baseVersion))});function sv(t,e){const i=Kh._createFromPositionAndShift(e.sourcePosition,e.howMany);let n=null;let o=[];if(i.containsRange(t,true)){n=t}else if(t.start.hasSameParentAs(i.start)){o=t.getDifference(i);n=t.getIntersection(i)}else{o=[t]}const r=[];for(let t of o){t=t._getTransformedByDeletion(e.sourcePosition,e.howMany);const i=e.getMovedRangeStart();const n=t.start.hasSameParentAs(i);t=t._getTransformedByInsertion(i,e.howMany,n);r.push(...t)}if(n){r.push(n._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany,false)[0])}return r}Yk(eg,cg,(t,e)=>{if(t.range.end.isEqual(e.insertionPosition)){if(!e.graveyardPosition){t.range.end.offset++}return[t]}if(t.range.start.hasSameParentAs(e.splitPosition)&&t.range.containsPosition(e.splitPosition)){const i=t.clone();i.range=new Kh(e.moveTargetPosition.clone(),t.range.end._getCombined(e.splitPosition,e.moveTargetPosition));t.range.end=e.splitPosition.clone();t.range.end.stickiness=\"toPrevious\";return[t,i]}t.range=t.range._getTransformedBySplitOperation(e);return[t]});Yk(og,eg,(t,e)=>{const i=[t];if(t.shouldReceiveAttributes&&t.position.hasSameParentAs(e.range.start)&&e.range.containsPosition(t.position)){const n=rv(t,e.key,e.newValue);if(n){i.push(n)}}return i});Yk(og,og,(t,e,i)=>{if(t.position.isEqual(e.position)&&i.aIsStrong){return[t]}t.position=t.position._getTransformedByInsertOperation(e);return[t]});Yk(og,ng,(t,e)=>{t.position=t.position._getTransformedByMoveOperation(e);return[t]});Yk(og,cg,(t,e)=>{t.position=t.position._getTransformedBySplitOperation(e);return[t]});Yk(og,lg,(t,e)=>{t.position=t.position._getTransformedByMergeOperation(e);return[t]});Yk(rg,og,(t,e)=>{if(t.oldRange){t.oldRange=t.oldRange._getTransformedByInsertOperation(e)[0]}if(t.newRange){t.newRange=t.newRange._getTransformedByInsertOperation(e)[0]}return[t]});Yk(rg,rg,(t,e,i)=>{if(t.name==e.name){if(i.aIsStrong){t.oldRange=e.newRange?e.newRange.clone():null}else{return[new Ig(0)]}}return[t]});Yk(rg,lg,(t,e)=>{if(t.oldRange){t.oldRange=t.oldRange._getTransformedByMergeOperation(e)}if(t.newRange){t.newRange=t.newRange._getTransformedByMergeOperation(e)}return[t]});Yk(rg,ng,(t,e,i)=>{if(t.oldRange){t.oldRange=Kh._createFromRanges(t.oldRange._getTransformedByMoveOperation(e))}if(t.newRange){if(i.abRelation){const n=Kh._createFromRanges(t.newRange._getTransformedByMoveOperation(e));if(i.abRelation.side==\"left\"&&e.targetPosition.isEqual(t.newRange.start)){t.newRange.start.path=i.abRelation.path;t.newRange.end=n.end;return[t]}else if(i.abRelation.side==\"right\"&&e.targetPosition.isEqual(t.newRange.end)){t.newRange.start=n.start;t.newRange.end.path=i.abRelation.path;return[t]}}t.newRange=Kh._createFromRanges(t.newRange._getTransformedByMoveOperation(e))}return[t]});Yk(rg,cg,(t,e,i)=>{if(t.oldRange){t.oldRange=t.oldRange._getTransformedBySplitOperation(e)}if(t.newRange){if(i.abRelation){const n=t.newRange._getTransformedBySplitOperation(e);if(t.newRange.start.isEqual(e.splitPosition)&&i.abRelation.wasStartBeforeMergedElement){t.newRange.start=$h._createAt(e.insertionPosition)}else if(t.newRange.start.isEqual(e.splitPosition)&&!i.abRelation.wasInLeftElement){t.newRange.start=$h._createAt(e.moveTargetPosition)}if(t.newRange.end.isEqual(e.splitPosition)&&i.abRelation.wasInRightElement){t.newRange.end=$h._createAt(e.moveTargetPosition)}else if(t.newRange.end.isEqual(e.splitPosition)&&i.abRelation.wasEndBeforeMergedElement){t.newRange.end=$h._createAt(e.insertionPosition)}else{t.newRange.end=n.end}return[t]}t.newRange=t.newRange._getTransformedBySplitOperation(e)}return[t]});Yk(lg,og,(t,e)=>{if(t.sourcePosition.hasSameParentAs(e.position)){t.howMany+=e.howMany}t.sourcePosition=t.sourcePosition._getTransformedByInsertOperation(e);t.targetPosition=t.targetPosition._getTransformedByInsertOperation(e);return[t]});Yk(lg,lg,(t,e,i)=>{if(t.sourcePosition.isEqual(e.sourcePosition)&&t.targetPosition.isEqual(e.targetPosition)){if(!i.bWasUndone){return[new Ig(0)]}else{const i=e.graveyardPosition.path.slice();i.push(0);t.sourcePosition=new $h(e.graveyardPosition.root,i);t.howMany=0;return[t]}}if(t.sourcePosition.isEqual(e.sourcePosition)&&!t.targetPosition.isEqual(e.targetPosition)&&!i.bWasUndone&&i.abRelation!=\"splitAtSource\"){const n=t.targetPosition.root.rootName==\"$graveyard\";const o=e.targetPosition.root.rootName==\"$graveyard\";const r=n&&!o;const s=o&&!n;const a=s||!r&&i.aIsStrong;if(a){const i=e.targetPosition._getTransformedByMergeOperation(e);const n=t.targetPosition._getTransformedByMergeOperation(e);return[new ng(i,t.howMany,n,0)]}else{return[new Ig(0)]}}if(t.sourcePosition.hasSameParentAs(e.targetPosition)){t.howMany+=e.howMany}t.sourcePosition=t.sourcePosition._getTransformedByMergeOperation(e);t.targetPosition=t.targetPosition._getTransformedByMergeOperation(e);if(!t.graveyardPosition.isEqual(e.graveyardPosition)||!i.aIsStrong){t.graveyardPosition=t.graveyardPosition._getTransformedByMergeOperation(e)}return[t]});Yk(lg,ng,(t,e,i)=>{const n=Kh._createFromPositionAndShift(e.sourcePosition,e.howMany);if(e.type==\"remove\"&&!i.bWasUndone&&!i.forceWeakRemove){if(t.deletionPosition.hasSameParentAs(e.sourcePosition)&&n.containsPosition(t.sourcePosition)){return[new Ig(0)]}}if(t.sourcePosition.hasSameParentAs(e.targetPosition)){t.howMany+=e.howMany}if(t.sourcePosition.hasSameParentAs(e.sourcePosition)){t.howMany-=e.howMany}t.sourcePosition=t.sourcePosition._getTransformedByMoveOperation(e);t.targetPosition=t.targetPosition._getTransformedByMoveOperation(e);if(!t.graveyardPosition.isEqual(e.targetPosition)){t.graveyardPosition=t.graveyardPosition._getTransformedByMoveOperation(e)}return[t]});Yk(lg,cg,(t,e,i)=>{if(e.graveyardPosition){t.graveyardPosition=t.graveyardPosition._getTransformedByDeletion(e.graveyardPosition,1);if(t.deletionPosition.isEqual(e.graveyardPosition)){t.howMany=e.howMany}}if(t.targetPosition.isEqual(e.splitPosition)){const n=e.howMany!=0;const o=e.graveyardPosition&&t.deletionPosition.isEqual(e.graveyardPosition);if(n||o||i.abRelation==\"mergeTargetNotMoved\"){t.sourcePosition=t.sourcePosition._getTransformedBySplitOperation(e);return[t]}}if(t.sourcePosition.isEqual(e.splitPosition)){if(i.abRelation==\"mergeSourceNotMoved\"){t.howMany=0;t.targetPosition=t.targetPosition._getTransformedBySplitOperation(e);return[t]}if(i.abRelation==\"mergeSameElement\"||t.sourcePosition.offset>0){t.sourcePosition=e.moveTargetPosition.clone();t.targetPosition=t.targetPosition._getTransformedBySplitOperation(e);return[t]}}if(t.sourcePosition.hasSameParentAs(e.splitPosition)){t.howMany=e.splitPosition.offset}t.sourcePosition=t.sourcePosition._getTransformedBySplitOperation(e);t.targetPosition=t.targetPosition._getTransformedBySplitOperation(e);return[t]});Yk(ng,og,(t,e)=>{const i=Kh._createFromPositionAndShift(t.sourcePosition,t.howMany);const n=i._getTransformedByInsertOperation(e,false)[0];t.sourcePosition=n.start;t.howMany=n.end.offset-n.start.offset;if(!t.targetPosition.isEqual(e.position)){t.targetPosition=t.targetPosition._getTransformedByInsertOperation(e)}return[t]});Yk(ng,ng,(t,e,i)=>{const n=Kh._createFromPositionAndShift(t.sourcePosition,t.howMany);const o=Kh._createFromPositionAndShift(e.sourcePosition,e.howMany);let r=i.aIsStrong;let s=!i.aIsStrong;if(i.abRelation==\"insertBefore\"||i.baRelation==\"insertAfter\"){s=true}else if(i.abRelation==\"insertAfter\"||i.baRelation==\"insertBefore\"){s=false}let a;if(t.targetPosition.isEqual(e.targetPosition)&&s){a=t.targetPosition._getTransformedByDeletion(e.sourcePosition,e.howMany)}else{a=t.targetPosition._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany)}if(av(t,e)&&av(e,t)){return[e.getReversed()]}const l=n.containsPosition(e.targetPosition);if(l&&n.containsRange(o,true)){n.start=n.start._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany);n.end=n.end._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany);return lv([n],a)}const c=o.containsPosition(t.targetPosition);if(c&&o.containsRange(n,true)){n.start=n.start._getCombined(e.sourcePosition,e.getMovedRangeStart());n.end=n.end._getCombined(e.sourcePosition,e.getMovedRangeStart());return lv([n],a)}const d=Ns(t.sourcePosition.getParentPath(),e.sourcePosition.getParentPath());if(d==\"prefix\"||d==\"extension\"){n.start=n.start._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany);n.end=n.end._getTransformedByMove(e.sourcePosition,e.targetPosition,e.howMany);return lv([n],a)}if(t.type==\"remove\"&&e.type!=\"remove\"&&!i.aWasUndone&&!i.forceWeakRemove){r=true}else if(t.type!=\"remove\"&&e.type==\"remove\"&&!i.bWasUndone&&!i.forceWeakRemove){r=false}const u=[];const h=n.getDifference(o);for(const t of h){t.start=t.start._getTransformedByDeletion(e.sourcePosition,e.howMany);t.end=t.end._getTransformedByDeletion(e.sourcePosition,e.howMany);const i=Ns(t.start.getParentPath(),e.getMovedRangeStart().getParentPath())==\"same\";const n=t._getTransformedByInsertion(e.getMovedRangeStart(),e.howMany,i);u.push(...n)}const f=n.getIntersection(o);if(f!==null&&r){f.start=f.start._getCombined(e.sourcePosition,e.getMovedRangeStart());f.end=f.end._getCombined(e.sourcePosition,e.getMovedRangeStart());if(u.length===0){u.push(f)}else if(u.length==1){if(o.start.isBefore(n.start)||o.start.isEqual(n.start)){u.unshift(f)}else{u.push(f)}}else{u.splice(1,0,f)}}if(u.length===0){return[new Ig(t.baseVersion)]}return lv(u,a)});Yk(ng,cg,(t,e,i)=>{let n=t.targetPosition.clone();if(!t.targetPosition.isEqual(e.insertionPosition)||!e.graveyardPosition||i.abRelation==\"moveTargetAfter\"){n=t.targetPosition._getTransformedBySplitOperation(e)}const o=Kh._createFromPositionAndShift(t.sourcePosition,t.howMany);if(o.end.isEqual(e.insertionPosition)){if(!e.graveyardPosition){t.howMany++}t.targetPosition=n;return[t]}if(o.start.hasSameParentAs(e.splitPosition)&&o.containsPosition(e.splitPosition)){let t=new Kh(e.splitPosition,o.end);t=t._getTransformedBySplitOperation(e);const i=[new Kh(o.start,e.splitPosition),t];return lv(i,n)}if(t.targetPosition.isEqual(e.splitPosition)&&i.abRelation==\"insertAtSource\"){n=e.moveTargetPosition}if(t.targetPosition.isEqual(e.insertionPosition)&&i.abRelation==\"insertBetween\"){n=t.targetPosition}const r=o._getTransformedBySplitOperation(e);const s=[r];if(e.graveyardPosition){const n=o.start.isEqual(e.graveyardPosition)||o.containsPosition(e.graveyardPosition);if(t.howMany>1&&n&&!i.aWasUndone){s.push(Kh._createFromPositionAndShift(e.insertionPosition,1))}}return lv(s,n)});Yk(ng,lg,(t,e,i)=>{const n=Kh._createFromPositionAndShift(t.sourcePosition,t.howMany);if(e.deletionPosition.hasSameParentAs(t.sourcePosition)&&n.containsPosition(e.sourcePosition)){if(t.type==\"remove\"&&!i.forceWeakRemove){if(!i.aWasUndone){const i=[];let n=e.graveyardPosition.clone();let o=e.targetPosition._getTransformedByMergeOperation(e);if(t.howMany>1){i.push(new ng(t.sourcePosition,t.howMany-1,t.targetPosition,0));n=n._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany-1);o=o._getTransformedByMove(t.sourcePosition,t.targetPosition,t.howMany-1)}const r=e.deletionPosition._getCombined(t.sourcePosition,t.targetPosition);const s=new ng(n,1,r,0);const a=s.getMovedRangeStart().path.slice();a.push(0);const l=new $h(s.targetPosition.root,a);o=o._getTransformedByMove(n,r,1);const c=new ng(o,e.howMany,l,0);i.push(s);i.push(c);return i}}else{if(t.howMany==1){if(!i.bWasUndone){return[new Ig(0)]}else{t.sourcePosition=e.graveyardPosition.clone();t.targetPosition=t.targetPosition._getTransformedByMergeOperation(e);return[t]}}}}const o=Kh._createFromPositionAndShift(t.sourcePosition,t.howMany);const r=o._getTransformedByMergeOperation(e);t.sourcePosition=r.start;t.howMany=r.end.offset-r.start.offset;t.targetPosition=t.targetPosition._getTransformedByMergeOperation(e);return[t]});Yk(sg,og,(t,e)=>{t.position=t.position._getTransformedByInsertOperation(e);return[t]});Yk(sg,lg,(t,e)=>{if(t.position.isEqual(e.deletionPosition)){t.position=e.graveyardPosition.clone();t.position.stickiness=\"toNext\";return[t]}t.position=t.position._getTransformedByMergeOperation(e);return[t]});Yk(sg,ng,(t,e)=>{t.position=t.position._getTransformedByMoveOperation(e);return[t]});Yk(sg,sg,(t,e,i)=>{if(t.position.isEqual(e.position)){if(i.aIsStrong){t.oldName=e.newName}else{return[new Ig(0)]}}return[t]});Yk(sg,cg,(t,e)=>{const i=t.position.path;const n=e.splitPosition.getParentPath();if(Ns(i,n)==\"same\"&&!e.graveyardPosition){const e=new sg(t.position.getShiftedBy(1),t.oldName,t.newName,0);return[t,e]}t.position=t.position._getTransformedBySplitOperation(e);return[t]});Yk(ag,ag,(t,e,i)=>{if(t.root===e.root&&t.key===e.key){if(!i.aIsStrong||t.newValue===e.newValue){return[new Ig(0)]}else{t.oldValue=e.newValue}}return[t]});Yk(cg,og,(t,e)=>{if(t.splitPosition.hasSameParentAs(e.position)&&t.splitPosition.offset<e.position.offset){t.howMany+=e.howMany}t.splitPosition=t.splitPosition._getTransformedByInsertOperation(e);t.insertionPosition=cg.getInsertionPosition(t.splitPosition);return[t]});Yk(cg,lg,(t,e,i)=>{if(!t.graveyardPosition&&!i.bWasUndone&&t.splitPosition.hasSameParentAs(e.sourcePosition)){const i=e.graveyardPosition.path.slice();i.push(0);const n=new $h(e.graveyardPosition.root,i);const o=cg.getInsertionPosition(new $h(e.graveyardPosition.root,i));const r=new cg(n,0,null,0);r.insertionPosition=o;t.splitPosition=t.splitPosition._getTransformedByMergeOperation(e);t.insertionPosition=cg.getInsertionPosition(t.splitPosition);t.graveyardPosition=r.insertionPosition.clone();t.graveyardPosition.stickiness=\"toNext\";return[r,t]}if(t.splitPosition.hasSameParentAs(e.deletionPosition)&&!t.splitPosition.isAfter(e.deletionPosition)){t.howMany--}if(t.splitPosition.hasSameParentAs(e.targetPosition)){t.howMany+=e.howMany}t.splitPosition=t.splitPosition._getTransformedByMergeOperation(e);t.insertionPosition=cg.getInsertionPosition(t.splitPosition);if(t.graveyardPosition){t.graveyardPosition=t.graveyardPosition._getTransformedByMergeOperation(e)}return[t]});Yk(cg,ng,(t,e,i)=>{const n=Kh._createFromPositionAndShift(e.sourcePosition,e.howMany);if(t.graveyardPosition){const o=n.start.isEqual(t.graveyardPosition)||n.containsPosition(t.graveyardPosition);if(!i.bWasUndone&&o){const i=t.splitPosition._getTransformedByMoveOperation(e);const n=t.graveyardPosition._getTransformedByMoveOperation(e);const o=n.path.slice();o.push(0);const r=new $h(n.root,o);const s=new ng(i,t.howMany,r,0);return[s]}t.graveyardPosition=t.graveyardPosition._getTransformedByMoveOperation(e)}if(t.splitPosition.hasSameParentAs(e.sourcePosition)&&n.containsPosition(t.splitPosition)){const i=e.howMany-(t.splitPosition.offset-e.sourcePosition.offset);t.howMany-=i;if(t.splitPosition.hasSameParentAs(e.targetPosition)&&t.splitPosition.offset<e.targetPosition.offset){t.howMany+=e.howMany}t.splitPosition=e.sourcePosition.clone();t.insertionPosition=cg.getInsertionPosition(t.splitPosition);return[t]}const o=t.splitPosition.isEqual(e.targetPosition);if(o&&(i.baRelation==\"insertAtSource\"||i.abRelation==\"splitBefore\")){t.howMany+=e.howMany;t.splitPosition=t.splitPosition._getTransformedByDeletion(e.sourcePosition,e.howMany);t.insertionPosition=cg.getInsertionPosition(t.splitPosition);return[t]}if(!e.sourcePosition.isEqual(e.targetPosition)){if(t.splitPosition.hasSameParentAs(e.sourcePosition)&&t.splitPosition.offset<=e.sourcePosition.offset){t.howMany-=e.howMany}if(t.splitPosition.hasSameParentAs(e.targetPosition)&&t.splitPosition.offset<e.targetPosition.offset){t.howMany+=e.howMany}}t.splitPosition.stickiness=\"toNone\";t.splitPosition=t.splitPosition._getTransformedByMoveOperation(e);t.splitPosition.stickiness=\"toNext\";if(t.graveyardPosition){t.insertionPosition=t.insertionPosition._getTransformedByMoveOperation(e)}else{t.insertionPosition=cg.getInsertionPosition(t.splitPosition)}return[t]});Yk(cg,cg,(t,e,i)=>{if(t.splitPosition.isEqual(e.splitPosition)){if(!t.graveyardPosition&&!e.graveyardPosition){return[new Ig(0)]}if(t.graveyardPosition&&e.graveyardPosition&&t.graveyardPosition.isEqual(e.graveyardPosition)){return[new Ig(0)]}if(i.abRelation==\"splitBefore\"){t.howMany=0;t.graveyardPosition=t.graveyardPosition._getTransformedBySplitOperation(e);return[t]}}if(t.graveyardPosition&&e.graveyardPosition&&t.graveyardPosition.isEqual(e.graveyardPosition)){const n=t.splitPosition.root.rootName==\"$graveyard\";const o=e.splitPosition.root.rootName==\"$graveyard\";const r=n&&!o;const s=o&&!n;const a=s||!r&&i.aIsStrong;if(a){const i=[];if(e.howMany){i.push(new ng(e.moveTargetPosition,e.howMany,e.splitPosition,0))}if(t.howMany){i.push(new ng(t.splitPosition,t.howMany,t.moveTargetPosition,0))}return i}else{return[new Ig(0)]}}if(t.graveyardPosition){t.graveyardPosition=t.graveyardPosition._getTransformedBySplitOperation(e)}if(t.splitPosition.isEqual(e.insertionPosition)&&i.abRelation==\"splitBefore\"){t.howMany++;return[t]}if(e.splitPosition.isEqual(t.insertionPosition)&&i.baRelation==\"splitBefore\"){const i=e.insertionPosition.path.slice();i.push(0);const n=new $h(e.insertionPosition.root,i);const o=new ng(t.insertionPosition,1,n,0);return[t,o]}if(t.splitPosition.hasSameParentAs(e.splitPosition)&&t.splitPosition.offset<e.splitPosition.offset){t.howMany-=e.howMany}t.splitPosition=t.splitPosition._getTransformedBySplitOperation(e);t.insertionPosition=cg.getInsertionPosition(t.splitPosition);return[t]});function av(t,e){return t.targetPosition._getTransformedByDeletion(e.sourcePosition,e.howMany)===null}function lv(t,e){const i=[];for(let n=0;n<t.length;n++){const o=t[n];const r=new ng(o.start,o.end.offset-o.start.offset,e,0);i.push(r);for(let e=n+1;e<t.length;e++){t[e]=t[e]._getTransformedByMove(r.sourcePosition,r.targetPosition,r.howMany)[0]}e=e._getTransformedByMove(r.sourcePosition,r.targetPosition,r.howMany)}return i}class cv extends Vw{constructor(t){super(t);this._stack=[];this._createdBatches=new WeakSet;this.refresh()}refresh(){this.isEnabled=this._stack.length>0}addBatch(t){const e=this.editor.model.document.selection;const i={ranges:e.hasOwnRange?Array.from(e.getRanges()):[],isBackward:e.isBackward};this._stack.push({batch:t,selection:i});this.refresh()}clearStack(){this._stack=[];this.refresh()}_restoreSelection(t,e,i){const n=this.editor.model;const o=n.document;const r=[];for(const e of t){const t=dv(e,i);const n=t.find(t=>t.start.root!=o.graveyard);if(n){r.push(n)}}if(r.length){n.change(t=>{t.setSelection(r,{backward:e})})}}_undo(t,e){const i=this.editor.model;const n=i.document;this._createdBatches.add(e);const o=t.operations.slice().filter(t=>t.isDocumentOperation);o.reverse();for(const t of o){const o=t.baseVersion+1;const r=Array.from(n.history.getOperations(o));const s=ev([t.getReversed()],r,{useRelations:true,document:this.editor.model.document,padWithNoOps:false,forceWeakRemove:true});const a=s.operationsA;for(const o of a){e.addOperation(o);i.applyOperation(o);n.history.setOperationAsUndone(t,o)}}}}function dv(t,e){const i=t.getTransformedByOperations(e);i.sort((t,e)=>t.start.isBefore(e.start)?-1:1);for(let t=1;t<i.length;t++){const e=i[t-1];const n=i[t];if(e.end.isTouching(n.start)){e.end=n.end;i.splice(t,1);t--}}return i}class uv extends cv{execute(t=null){const e=t?this._stack.findIndex(e=>e.batch==t):this._stack.length-1;const i=this._stack.splice(e,1)[0];const n=this.editor.model.createBatch(\"transparent\");this.editor.model.enqueueChange(n,()=>{this._undo(i.batch,n);const t=this.editor.model.document.history.getOperations(i.batch.baseVersion);this._restoreSelection(i.selection.ranges,i.selection.isBackward,t);this.fire(\"revert\",i.batch,n)});this.refresh()}}class hv extends cv{execute(){const t=this._stack.pop();const e=this.editor.model.createBatch(\"transparent\");this.editor.model.enqueueChange(e,()=>{const i=t.batch.operations[t.batch.operations.length-1];const n=i.baseVersion+1;const o=this.editor.model.document.history.getOperations(n);this._restoreSelection(t.selection.ranges,t.selection.isBackward,o);this._undo(t.batch,e)});this.refresh()}}class fv extends Nw{static get pluginName(){return\"UndoEditing\"}constructor(t){super(t);this._batchRegistry=new WeakSet}init(){const t=this.editor;this._undoCommand=new uv(t);this._redoCommand=new hv(t);t.commands.add(\"undo\",this._undoCommand);t.commands.add(\"redo\",this._redoCommand);this.listenTo(t.model,\"applyOperation\",(t,e)=>{const i=e[0];if(!i.isDocumentOperation){return}const n=i.batch;const o=this._redoCommand._createdBatches.has(n);const r=this._undoCommand._createdBatches.has(n);const s=this._batchRegistry.has(n);if(s||n.type==\"transparent\"&&!o&&!r){return}else{if(o){this._undoCommand.addBatch(n)}else if(!r){this._undoCommand.addBatch(n);this._redoCommand.clearStack()}}this._batchRegistry.add(n)},{priority:\"highest\"});this.listenTo(this._undoCommand,\"revert\",(t,e,i)=>{this._redoCommand.addBatch(i)});t.keystrokes.set(\"CTRL+Z\",\"undo\");t.keystrokes.set(\"CTRL+Y\",\"redo\");t.keystrokes.set(\"CTRL+SHIFT+Z\",\"redo\")}}var mv='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M5.042 9.367l2.189 1.837a.75.75 0 0 1-.965 1.149l-3.788-3.18a.747.747 0 0 1-.21-.284.75.75 0 0 1 .17-.945L6.23 4.762a.75.75 0 1 1 .964 1.15L4.863 7.866h8.917A.75.75 0 0 1 14 7.9a4 4 0 1 1-1.477 7.718l.344-1.489a2.5 2.5 0 1 0 1.094-4.73l.008-.032H5.042z\"/></svg>';var gv='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M14.958 9.367l-2.189 1.837a.75.75 0 0 0 .965 1.149l3.788-3.18a.747.747 0 0 0 .21-.284.75.75 0 0 0-.17-.945L13.77 4.762a.75.75 0 1 0-.964 1.15l2.331 1.955H6.22A.75.75 0 0 0 6 7.9a4 4 0 1 0 1.477 7.718l-.344-1.489A2.5 2.5 0 1 1 6.039 9.4l-.008-.032h8.927z\"/></svg>';class pv extends Nw{init(){const t=this.editor;const e=t.locale;const i=t.t;const n=e.uiLanguageDirection==\"ltr\"?mv:gv;const o=e.uiLanguageDirection==\"ltr\"?gv:mv;this._addButton(\"undo\",i(\"Undo\"),\"CTRL+Z\",n);this._addButton(\"redo\",i(\"Redo\"),\"CTRL+Y\",o)}_addButton(t,e,i,n){const o=this.editor;o.ui.componentFactory.add(t,r=>{const s=o.commands.get(t);const a=new rw(r);a.set({label:e,icon:n,keystroke:i,tooltip:true});a.bind(\"isEnabled\").to(s,\"isEnabled\");this.listenTo(a,\"execute\",()=>{o.execute(t);o.editing.view.focus()});return a})}}class bv extends Nw{static get requires(){return[fv,pv]}static get pluginName(){return\"Undo\"}}class wv extends Nw{static get requires(){return[kk,Ck,Mk,D_,Kk,bv]}static get pluginName(){return\"Essentials\"}}class _v extends Vw{constructor(t,e){super(t);this.attributeKey=e}refresh(){const t=this.editor.model;const e=t.document;this.value=e.selection.getAttribute(this.attributeKey);this.isEnabled=t.schema.checkAttributeInSelection(e.selection,this.attributeKey)}execute(t={}){const e=this.editor.model;const i=e.document;const n=i.selection;const o=t.value;e.change(t=>{if(n.isCollapsed){if(o){t.setSelectionAttribute(this.attributeKey,o)}else{t.removeSelectionAttribute(this.attributeKey)}}else{const i=e.schema.getValidRanges(n.getRanges(),this.attributeKey);for(const e of i){if(o){t.setAttribute(this.attributeKey,o,e)}else{t.removeAttribute(this.attributeKey,e)}}}})}}var kv='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path class=\"ck-icon__fill\" d=\"M16.935 5.328a2 2 0 0 1 0 2.829l-7.778 7.778a2 2 0 0 1-2.829 0L3.5 13.107a1.999 1.999 0 1 1 2.828-2.829l.707.707a1 1 0 0 0 1.414 0l5.658-5.657a2 2 0 0 1 2.828 0z\"/><path d=\"M14.814 6.035L8.448 12.4a1 1 0 0 1-1.414 0l-1.413-1.415A1 1 0 1 0 4.207 12.4l2.829 2.829a1 1 0 0 0 1.414 0l7.778-7.778a1 1 0 1 0-1.414-1.415z\"/></svg>';class vv extends rw{constructor(t){super(t);const e=this.bindTemplate;this.set(\"color\");this.set(\"hasBorder\");this.icon=kv;this.extendTemplate({attributes:{style:{backgroundColor:e.to(\"color\")},class:[\"ck\",\"ck-color-grid__tile\",e.if(\"hasBorder\",\"ck-color-table__color-tile_bordered\")]}})}render(){super.render();this.iconView.fillColor=\"hsl(0, 0%, 100%)\"}}var yv=i(54);class xv extends _b{constructor(t,e){super(t);const i=e&&e.colorDefinitions||[];const n={};if(e&&e.columns){n.gridTemplateColumns=`repeat( ${e.columns}, 1fr)`}this.set(\"selectedColor\");this.items=this.createCollection();this.focusTracker=new Pp;this.keystrokes=new mp;this._focusCycler=new Bb({focusables:this.items,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"arrowleft\",focusNext:\"arrowright\"}});this.items.on(\"add\",(t,e)=>{e.isOn=e.color===this.selectedColor});i.forEach(t=>{const e=new vv;e.set({color:t.color,label:t.label,tooltip:true,hasBorder:t.options.hasBorder});e.on(\"execute\",()=>{this.fire(\"execute\",{value:t.color,hasBorder:t.options.hasBorder,label:t.label})});this.items.add(e)});this.setTemplate({tag:\"div\",children:this.items,attributes:{class:[\"ck\",\"ck-color-grid\"],style:n}});this.on(\"change:selectedColor\",(t,e,i)=>{for(const t of this.items){t.isOn=t.color===i}})}focus(){if(this.items.length){this.items.first.focus()}}focusLast(){if(this.items.length){this.items.last.focus()}}render(){super.render();for(const t of this.items){this.focusTracker.add(t.element)}this.items.on(\"add\",(t,e)=>{this.focusTracker.add(e.element)});this.items.on(\"remove\",(t,e)=>{this.focusTracker.remove(e.element)});this.keystrokes.listenTo(this.element)}}class Cv extends xs{constructor(t){super(t);this.set(\"isEmpty\",true)}add(t,e){if(this.find(e=>e.color===t.color)){return}super.add(t,e);this.set(\"isEmpty\",false)}remove(t){const e=super.remove(t);if(this.length===0){this.set(\"isEmpty\",true)}return e}hasColor(t){return!!this.find(e=>e.color===t)}}ys(Cv,Xl);var Av='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M8.636 9.531l-2.758 3.94a.5.5 0 0 0 .122.696l3.224 2.284h1.314l2.636-3.736L8.636 9.53zm.288 8.451L5.14 15.396a2 2 0 0 1-.491-2.786l6.673-9.53a2 2 0 0 1 2.785-.49l3.742 2.62a2 2 0 0 1 .491 2.785l-7.269 10.053-2.147-.066z\"/><path d=\"M4 18h5.523v-1H4zm-2 0h1v-1H2z\"/></svg>';var Tv=i(56);class Pv extends _b{constructor(t,{colors:e,columns:i,removeButtonLabel:n,documentColorsLabel:o,documentColorsCount:r}){super(t);this.items=this.createCollection();this.colorDefinitions=e;this.focusTracker=new Pp;this.keystrokes=new mp;this.set(\"selectedColor\");this.removeButtonLabel=n;this.columns=i;this.documentColors=new Cv;this.documentColorsCount=r;this._focusCycler=new Bb({focusables:this.items,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"arrowup\",focusNext:\"arrowdown\"}});this._documentColorsLabel=o;this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-color-table\"]},children:this.items});this.items.add(this._removeColorButton())}updateDocumentColors(t,e){const i=t.document;const n=this.documentColorsCount;this.documentColors.clear();for(const o of i.getRootNames()){const r=i.getRoot(o);const s=t.createRangeIn(r);for(const t of s.getItems()){if(t.is(\"textProxy\")&&t.hasAttribute(e)){this._addColorToDocumentColors(t.getAttribute(e));if(this.documentColors.length>=n){return}}}}}updateSelectedColors(){const t=this.documentColorsGrid;const e=this.staticColorsGrid;const i=this.selectedColor;e.selectedColor=i;if(t){t.selectedColor=i}}render(){super.render();for(const t of this.items){this.focusTracker.add(t.element)}this.keystrokes.listenTo(this.element)}appendGrids(){if(this.staticColorsGrid){return}this.staticColorsGrid=this._createStaticColorsGrid();this.items.add(this.staticColorsGrid);if(this.documentColorsCount){const t=Up.bind(this.documentColors,this.documentColors);const e=new Eb(this.locale);e.text=this._documentColorsLabel;e.extendTemplate({attributes:{class:[\"ck\",\"ck-color-grid__label\",t.if(\"isEmpty\",\"ck-hidden\")]}});this.items.add(e);this.documentColorsGrid=this._createDocumentColorsGrid();this.items.add(this.documentColorsGrid)}}focus(){this._focusCycler.focusFirst()}focusLast(){this._focusCycler.focusLast()}_removeColorButton(){const t=new rw;t.set({withText:true,icon:Av,tooltip:true,label:this.removeButtonLabel});t.class=\"ck-color-table__remove-color\";t.on(\"execute\",()=>{this.fire(\"execute\",{value:null})});return t}_createStaticColorsGrid(){const t=new xv(this.locale,{colorDefinitions:this.colorDefinitions,columns:this.columns});t.delegate(\"execute\").to(this);return t}_createDocumentColorsGrid(){const t=Up.bind(this.documentColors,this.documentColors);const e=new xv(this.locale,{columns:this.columns});e.delegate(\"execute\").to(this);e.extendTemplate({attributes:{class:t.if(\"isEmpty\",\"ck-hidden\")}});e.items.bindTo(this.documentColors).using(t=>{const e=new vv;e.set({color:t.color,hasBorder:t.options&&t.options.hasBorder});if(t.label){e.set({label:t.label,tooltip:true})}e.on(\"execute\",()=>{this.fire(\"execute\",{value:t.color})});return e});this.documentColors.on(\"change:isEmpty\",(t,i,n)=>{if(n){e.selectedColor=null}});return e}_addColorToDocumentColors(t){const e=this.colorDefinitions.find(e=>e.color===t);if(!e){this.documentColors.add({color:t,label:t,options:{hasBorder:false}})}else{this.documentColors.add(Object.assign({},e))}}}const Ev=\"fontSize\";const Sv=\"fontFamily\";const Mv=\"fontColor\";const Ov=\"fontBackgroundColor\";function Iv(t,e){const i={model:{key:t,values:[]},view:{},upcastAlso:{}};for(const t of e){i.model.values.push(t.model);i.view[t.model]=t.view;if(t.upcastAlso){i.upcastAlso[t.model]=t.upcastAlso}}return i}function Rv(t){return e=>Bv(e.getStyle(t))}function Lv(t){return(e,i)=>i.createAttributeElement(\"span\",{style:`${t}:${e}`},{priority:7})}function Nv({dropdownView:t,colors:e,columns:i,removeButtonLabel:n,documentColorsLabel:o,documentColorsCount:r}){const s=t.locale;const a=new Pv(s,{colors:e,columns:i,removeButtonLabel:n,documentColorsLabel:o,documentColorsCount:r});t.colorTableView=a;t.panelView.children.add(a);a.delegate(\"execute\").to(t,\"execute\");return a}function Bv(t){return t.replace(/\\s/g,\"\")}class Vv extends _v{constructor(t){super(t,Ov)}}class Dv extends Nw{static get pluginName(){return\"FontBackgroundColorEditing\"}constructor(t){super(t);t.config.define(Ov,{colors:[{color:\"hsl(0, 0%, 0%)\",label:\"Black\"},{color:\"hsl(0, 0%, 30%)\",label:\"Dim grey\"},{color:\"hsl(0, 0%, 60%)\",label:\"Grey\"},{color:\"hsl(0, 0%, 90%)\",label:\"Light grey\"},{color:\"hsl(0, 0%, 100%)\",label:\"White\",hasBorder:true},{color:\"hsl(0, 75%, 60%)\",label:\"Red\"},{color:\"hsl(30, 75%, 60%)\",label:\"Orange\"},{color:\"hsl(60, 75%, 60%)\",label:\"Yellow\"},{color:\"hsl(90, 75%, 60%)\",label:\"Light green\"},{color:\"hsl(120, 75%, 60%)\",label:\"Green\"},{color:\"hsl(150, 75%, 60%)\",label:\"Aquamarine\"},{color:\"hsl(180, 75%, 60%)\",label:\"Turquoise\"},{color:\"hsl(210, 75%, 60%)\",label:\"Light blue\"},{color:\"hsl(240, 75%, 60%)\",label:\"Blue\"},{color:\"hsl(270, 75%, 60%)\",label:\"Purple\"}],columns:5});t.conversion.for(\"upcast\").elementToAttribute({view:{name:\"span\",styles:{\"background-color\":/[\\s\\S]+/}},model:{key:Ov,value:Rv(\"background-color\")}});t.conversion.for(\"downcast\").attributeToElement({model:Ov,view:Lv(\"background-color\")});t.commands.add(Ov,new Vv(t));t.model.schema.extend(\"$text\",{allowAttributes:Ov});t.model.schema.setAttributeProperties(Ov,{isFormatting:true,copyOnEnter:true})}}function zv(t,e){const i=t.t;const n={Black:i(\"Black\"),\"Dim grey\":i(\"Dim grey\"),Grey:i(\"Grey\"),\"Light grey\":i(\"Light grey\"),White:i(\"White\"),Red:i(\"Red\"),Orange:i(\"Orange\"),Yellow:i(\"Yellow\"),\"Light green\":i(\"Light green\"),Green:i(\"Green\"),Aquamarine:i(\"Aquamarine\"),Turquoise:i(\"Turquoise\"),\"Light blue\":i(\"Light blue\"),Blue:i(\"Blue\"),Purple:i(\"Purple\")};return e.map(t=>{const e=n[t.label];if(e&&e!=t.label){t.label=e}return t})}function Fv(t){return t.map(jv).filter(t=>!!t)}function jv(t){if(typeof t===\"string\"){return{model:t,label:t,hasBorder:false,view:{name:\"span\",styles:{color:t}}}}else{return{model:t.color,label:t.label||t.color,hasBorder:t.hasBorder===undefined?false:t.hasBorder,view:{name:\"span\",styles:{color:`${t.color}`}}}}}class Hv extends Nw{constructor(t,{commandName:e,icon:i,componentName:n,dropdownLabel:o}){super(t);this.commandName=e;this.componentName=n;this.icon=i;this.dropdownLabel=o;this.columns=t.config.get(`${this.componentName}.columns`);this.colorTableView}init(){const t=this.editor;const e=t.locale;const i=e.t;const n=t.commands.get(this.commandName);const o=Fv(t.config.get(this.componentName).colors);const r=zv(e,o);const s=t.config.get(`${this.componentName}.documentColors`);t.ui.componentFactory.add(this.componentName,e=>{const o=bw(e);this.colorTableView=Nv({dropdownView:o,colors:r.map(t=>({label:t.label,color:t.model,options:{hasBorder:t.hasBorder}})),columns:this.columns,removeButtonLabel:i(\"Remove color\"),documentColorsLabel:s!==0?i(\"Document colors\"):undefined,documentColorsCount:s===undefined?this.columns:s});this.colorTableView.bind(\"selectedColor\").to(n,\"value\");o.buttonView.set({label:this.dropdownLabel,icon:this.icon,tooltip:true});o.extendTemplate({attributes:{class:\"ck-color-ui-dropdown\"}});o.bind(\"isEnabled\").to(n);o.on(\"execute\",(e,i)=>{t.execute(this.commandName,i);t.editing.view.focus()});o.on(\"change:isOpen\",(e,i,n)=>{o.colorTableView.appendGrids();if(n){if(s!==0){this.colorTableView.updateDocumentColors(t.model,this.componentName)}this.colorTableView.updateSelectedColors()}});return o})}}var Wv='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M4 2h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2zm8.38 9.262H7.62L10 5.506l2.38 5.756zm.532 1.285L14.34 16h1.426L10.804 4H9.196L4.234 16H5.66l1.428-3.453h5.824z\"/></svg>';class qv extends Hv{constructor(t){const e=t.locale.t;super(t,{commandName:Ov,componentName:Ov,icon:Wv,dropdownLabel:e(\"Font Background Color\")})}static get pluginName(){return\"FontBackgroundColorUI\"}}class $v extends Nw{static get requires(){return[Dv,qv]}static get pluginName(){return\"FontBackgroundColor\"}}class Uv extends _v{constructor(t){super(t,Mv)}}class Gv extends Nw{static get pluginName(){return\"FontColorEditing\"}constructor(t){super(t);t.config.define(Mv,{colors:[{color:\"hsl(0, 0%, 0%)\",label:\"Black\"},{color:\"hsl(0, 0%, 30%)\",label:\"Dim grey\"},{color:\"hsl(0, 0%, 60%)\",label:\"Grey\"},{color:\"hsl(0, 0%, 90%)\",label:\"Light grey\"},{color:\"hsl(0, 0%, 100%)\",label:\"White\",hasBorder:true},{color:\"hsl(0, 75%, 60%)\",label:\"Red\"},{color:\"hsl(30, 75%, 60%)\",label:\"Orange\"},{color:\"hsl(60, 75%, 60%)\",label:\"Yellow\"},{color:\"hsl(90, 75%, 60%)\",label:\"Light green\"},{color:\"hsl(120, 75%, 60%)\",label:\"Green\"},{color:\"hsl(150, 75%, 60%)\",label:\"Aquamarine\"},{color:\"hsl(180, 75%, 60%)\",label:\"Turquoise\"},{color:\"hsl(210, 75%, 60%)\",label:\"Light blue\"},{color:\"hsl(240, 75%, 60%)\",label:\"Blue\"},{color:\"hsl(270, 75%, 60%)\",label:\"Purple\"}],columns:5});t.conversion.for(\"upcast\").elementToAttribute({view:{name:\"span\",styles:{color:/[\\s\\S]+/}},model:{key:Mv,value:Rv(\"color\")}});t.conversion.for(\"downcast\").attributeToElement({model:Mv,view:Lv(\"color\")});t.commands.add(Mv,new Uv(t));t.model.schema.extend(\"$text\",{allowAttributes:Mv});t.model.schema.setAttributeProperties(Mv,{isFormatting:true,copyOnEnter:true})}}var Jv='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12.4 10.3L10 4.5l-2.4 5.8h4.8zm.5 1.2H7.1L5.7 15H4.2l5-12h1.6l5 12h-1.5L13 11.5zm3.1 7H4a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2z\"/></svg>';class Kv extends Hv{constructor(t){const e=t.locale.t;super(t,{commandName:Mv,componentName:Mv,icon:Jv,dropdownLabel:e(\"Font Color\")})}static get pluginName(){return\"FontColorUI\"}}class Xv extends Nw{static get requires(){return[Gv,Kv]}static get pluginName(){return\"FontColor\"}}class Yv extends _v{constructor(t){super(t,Sv)}}function Qv(t){return t.map(Zv).filter(t=>!!t)}function Zv(t){if(typeof t===\"object\"){return t}if(t===\"default\"){return{title:\"Default\",model:undefined}}if(typeof t!==\"string\"){return}return ty(t)}function ty(t){const e=t.replace(/\"|'/g,\"\").split(\",\");const i=e[0];const n=e.map(ey).join(\", \");return{title:i,model:i,view:{name:\"span\",styles:{\"font-family\":n},priority:7}}}function ey(t){t=t.trim();if(t.indexOf(\" \")>0){t=`'${t}'`}return t}class iy extends Nw{static get pluginName(){return\"FontFamilyEditing\"}constructor(t){super(t);t.config.define(Sv,{options:[\"default\",\"Arial, Helvetica, sans-serif\",\"Courier New, Courier, monospace\",\"Georgia, serif\",\"Lucida Sans Unicode, Lucida Grande, sans-serif\",\"Tahoma, Geneva, sans-serif\",\"Times New Roman, Times, serif\",\"Trebuchet MS, Helvetica, sans-serif\",\"Verdana, Geneva, sans-serif\"],supportAllValues:false})}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:Sv});t.model.schema.setAttributeProperties(Sv,{isFormatting:true,copyOnEnter:true});const e=Qv(t.config.get(\"fontFamily.options\")).filter(t=>t.model);const i=Iv(Sv,e);if(t.config.get(\"fontFamily.supportAllValues\")){this._prepareAnyValueConverters()}else{t.conversion.attributeToElement(i)}t.commands.add(Sv,new Yv(t))}_prepareAnyValueConverters(){const t=this.editor;t.conversion.for(\"downcast\").attributeToElement({model:Sv,view:(t,e)=>e.createAttributeElement(\"span\",{style:\"font-family:\"+t},{priority:7})});t.conversion.for(\"upcast\").attributeToAttribute({model:{key:Sv,value:t=>t.getStyle(\"font-family\")},view:{name:\"span\",styles:{\"font-family\":/.*/}}})}}var ny='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.03 3h6.149a.75.75 0 1 1 0 1.5h-5.514L11.03 3zm1.27 3h4.879a.75.75 0 1 1 0 1.5h-4.244L12.3 6zm1.27 3h3.609a.75.75 0 1 1 0 1.5h-2.973L13.57 9zm-2.754 2.5L8.038 4.785 5.261 11.5h5.555zm.62 1.5H4.641l-1.666 4.028H1.312l5.789-14h1.875l5.789 14h-1.663L11.436 13z\"/></svg>';class oy extends Nw{init(){const t=this.editor;const e=t.t;const i=this._getLocalizedOptions();const n=t.commands.get(Sv);t.ui.componentFactory.add(Sv,o=>{const r=bw(o);_w(r,ry(i,n));r.buttonView.set({label:e(\"Font Family\"),icon:ny,tooltip:true});r.extendTemplate({attributes:{class:\"ck-font-family-dropdown\"}});r.bind(\"isEnabled\").to(n);this.listenTo(r,\"execute\",e=>{t.execute(e.source.commandName,{value:e.source.commandParam});t.editing.view.focus()});return r})}_getLocalizedOptions(){const t=this.editor;const e=t.t;const i=Qv(t.config.get(Sv).options);return i.map(t=>{if(t.title===\"Default\"){t.title=e(\"Default\")}return t})}}function ry(t,e){const i=new xs;for(const n of t){const t={type:\"button\",model:new rk({commandName:Sv,commandParam:n.model,label:n.title,withText:true})};t.model.bind(\"isOn\").to(e,\"value\",t=>{if(t===n.model){return true}if(!t||!n.model){return false}return t.split(\",\")[0].replace(/'/g,\"\").toLowerCase()===n.model.toLowerCase()});if(n.view&&n.view.styles){t.model.set(\"labelStyle\",`font-family: ${n.view.styles[\"font-family\"]}`)}i.add(t)}return i}class sy extends Nw{static get requires(){return[iy,oy]}static get pluginName(){return\"FontFamily\"}}class ay extends _v{constructor(t){super(t,Ev)}}function ly(t){return t.map(t=>dy(t)).filter(t=>!!t)}const cy={get tiny(){return{title:\"Tiny\",model:\"tiny\",view:{name:\"span\",classes:\"text-tiny\",priority:7}}},get small(){return{title:\"Small\",model:\"small\",view:{name:\"span\",classes:\"text-small\",priority:7}}},get big(){return{title:\"Big\",model:\"big\",view:{name:\"span\",classes:\"text-big\",priority:7}}},get huge(){return{title:\"Huge\",model:\"huge\",view:{name:\"span\",classes:\"text-huge\",priority:7}}}};function dy(t){if(my(t)){return hy(t)}const e=fy(t);if(e){return hy(e)}if(t===\"default\"){return{model:undefined,title:\"Default\"}}if(gy(t)){return}return uy(t)}function uy(t){if(typeof t===\"number\"||typeof t===\"string\"){t={title:String(t),model:`${parseFloat(t)}px`}}t.view={name:\"span\",styles:{\"font-size\":t.model}};return hy(t)}function hy(t){if(!t.view.priority){t.view.priority=7}return t}function fy(t){return cy[t]||cy[t.model]}function my(t){return typeof t===\"object\"&&t.title&&t.model&&t.view}function gy(t){let e;if(typeof t===\"object\"){if(!t.model){throw new ss[\"b\"](\"font-size-invalid-definition: Provided font size definition is invalid.\",null,t)}else{e=parseFloat(t.model)}}else{e=parseFloat(t)}return isNaN(e)}class py extends Nw{static get pluginName(){return\"FontSizeEditing\"}constructor(t){super(t);t.config.define(Ev,{options:[\"tiny\",\"small\",\"default\",\"big\",\"huge\"],supportAllValues:false})}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:Ev});t.model.schema.setAttributeProperties(Ev,{isFormatting:true,copyOnEnter:true});const e=t.config.get(\"fontSize.supportAllValues\");const i=ly(this.editor.config.get(\"fontSize.options\")).filter(t=>t.model);const n=Iv(Ev,i);if(e){this._prepareAnyValueConverters(n)}else{t.conversion.attributeToElement(n)}t.commands.add(Ev,new ay(t))}_prepareAnyValueConverters(t){const e=this.editor;const i=t.model.values.filter(t=>!String(t).match(/[\\d.]+[\\w%]+/));if(i.length){throw new ss[\"b\"](\"font-size-invalid-use-of-named-presets: \"+\"If config.fontSize.supportAllValues is set to true, you need to use numerical values as font size options.\",null,{presets:i})}e.conversion.for(\"downcast\").attributeToElement({model:Ev,view:(t,e)=>{if(!t){return}return e.createAttributeElement(\"span\",{style:\"font-size:\"+t},{priority:7})}});e.conversion.for(\"upcast\").attributeToAttribute({model:{key:Ev,value:t=>t.getStyle(\"font-size\")},view:{name:\"span\"}})}}var by='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M9.816 11.5L7.038 4.785 4.261 11.5h5.555zm.62 1.5H3.641l-1.666 4.028H.312l5.789-14h1.875l5.789 14h-1.663L10.436 13zm7.55 2.279l.779-.779.707.707-2.265 2.265-2.193-2.265.707-.707.765.765V4.825c0-.042 0-.083.002-.123l-.77.77-.707-.707L17.207 2.5l2.265 2.265-.707.707-.782-.782c.002.043.003.089.003.135v10.454z\"/></svg>';var wy=i(58);class _y extends Nw{init(){const t=this.editor;const e=t.t;const i=this._getLocalizedOptions();const n=t.commands.get(Ev);t.ui.componentFactory.add(Ev,o=>{const r=bw(o);_w(r,ky(i,n));r.buttonView.set({label:e(\"Font Size\"),icon:by,tooltip:true});r.extendTemplate({attributes:{class:[\"ck-font-size-dropdown\"]}});r.bind(\"isEnabled\").to(n);this.listenTo(r,\"execute\",e=>{t.execute(e.source.commandName,{value:e.source.commandParam});t.editing.view.focus()});return r})}_getLocalizedOptions(){const t=this.editor;const e=t.t;const i={Default:e(\"Default\"),Tiny:e(\"Tiny\"),Small:e(\"Small\"),Big:e(\"Big\"),Huge:e(\"Huge\")};const n=ly(t.config.get(Ev).options);return n.map(t=>{const e=i[t.title];if(e&&e!=t.title){t=Object.assign({},t,{title:e})}return t})}}function ky(t,e){const i=new xs;for(const n of t){const t={type:\"button\",model:new rk({commandName:Ev,commandParam:n.model,label:n.title,class:\"ck-fontsize-option\",withText:true})};if(n.view&&n.view.styles){t.model.set(\"labelStyle\",`font-size:${n.view.styles[\"font-size\"]}`)}if(n.view&&n.view.classes){t.model.set(\"class\",`${t.model.class} ${n.view.classes}`)}t.model.bind(\"isOn\").to(e,\"value\",t=>t===n.model);i.add(t)}return i}class vy extends Nw{static get requires(){return[py,_y]}static get pluginName(){return\"FontSize\"}}class yy extends Vw{refresh(){const t=this.editor.model;const e=t.document;const i=zw(e.selection.getSelectedBlocks());this.value=!!i&&i.is(\"paragraph\");this.isEnabled=!!i&&xy(i,t.schema)}execute(t={}){const e=this.editor.model;const i=e.document;e.change(n=>{const o=(t.selection||i.selection).getSelectedBlocks();for(const t of o){if(!t.is(\"paragraph\")&&xy(t,e.schema)){n.rename(t,\"paragraph\")}}})}}function xy(t,e){return e.checkChild(t.parent,\"paragraph\")&&!e.isObject(t)}class Cy extends Vw{execute(t){const e=this.editor.model;if(!e.schema.checkChild(t.position,\"paragraph\")){return}e.change(i=>{const n=i.createElement(\"paragraph\");e.insertContent(n,t.position);i.setSelection(n,\"in\")})}}class Ay extends Nw{static get pluginName(){return\"Paragraph\"}init(){const t=this.editor;const e=t.model;const i=t.data;t.commands.add(\"paragraph\",new yy(t));t.commands.add(\"insertParagraph\",new Cy(t));e.schema.register(\"paragraph\",{inheritAllFrom:\"$block\"});t.conversion.elementToElement({model:\"paragraph\",view:\"p\"});t.conversion.for(\"upcast\").elementToElement({model:(t,e)=>{if(!Ay.paragraphLikeElements.has(t.name)){return null}if(t.isEmpty){return null}return e.createElement(\"paragraph\")},converterPriority:\"low\"});i.upcastDispatcher.on(\"element\",(t,e,i)=>{if(!i.consumable.test(e.viewItem,{name:e.viewItem.name})){return}if(Py(e.viewItem,e.modelCursor,i.schema)){Object.assign(e,Ty(e.viewItem,e.modelCursor,i))}},{priority:\"low\"});i.upcastDispatcher.on(\"text\",(t,e,i)=>{if(e.modelRange){return}if(Py(e.viewItem,e.modelCursor,i.schema)){Object.assign(e,Ty(e.viewItem,e.modelCursor,i))}},{priority:\"lowest\"});e.document.registerPostFixer(t=>this._autoparagraphEmptyRoots(t));t.data.on(\"ready\",()=>{e.enqueueChange(\"transparent\",t=>this._autoparagraphEmptyRoots(t))},{priority:\"lowest\"})}_autoparagraphEmptyRoots(t){const e=this.editor.model;for(const i of e.document.getRootNames()){const n=e.document.getRoot(i);if(n.isEmpty&&n.rootName!=\"$graveyard\"){if(e.schema.checkChild(n,\"paragraph\")){t.insertElement(\"paragraph\",n);return true}}}}}Ay.paragraphLikeElements=new Set([\"blockquote\",\"dd\",\"div\",\"dt\",\"h1\",\"h2\",\"h3\",\"h4\",\"h5\",\"h6\",\"li\",\"p\",\"td\"]);function Ty(t,e,i){const n=i.writer.createElement(\"paragraph\");i.writer.insert(n,e);return i.convertItem(t,i.writer.createPositionAt(n,0))}function Py(t,e,i){const n=i.createContext(e);if(!i.checkChild(n,\"paragraph\")){return false}if(!i.checkChild(n.push(\"paragraph\"),t)){return false}return true}class Ey extends Vw{constructor(t,e){super(t);this.modelElements=e}refresh(){const t=zw(this.editor.model.document.selection.getSelectedBlocks());this.value=!!t&&this.modelElements.includes(t.name)&&t.name;this.isEnabled=!!t&&this.modelElements.some(e=>Sy(t,e,this.editor.model.schema))}execute(t){const e=this.editor.model;const i=e.document;const n=t.value;e.change(t=>{const o=Array.from(i.selection.getSelectedBlocks()).filter(t=>Sy(t,n,e.schema));for(const e of o){if(!e.is(n)){t.rename(e,n)}}})}}function Sy(t,e,i){return i.checkChild(t.parent,e)&&!i.isObject(t)}const My=\"paragraph\";class Oy extends Nw{static get pluginName(){return\"HeadingEditing\"}constructor(t){super(t);t.config.define(\"heading\",{options:[{model:\"paragraph\",title:\"Paragraph\",class:\"ck-heading_paragraph\"},{model:\"heading1\",view:\"h2\",title:\"Heading 1\",class:\"ck-heading_heading1\"},{model:\"heading2\",view:\"h3\",title:\"Heading 2\",class:\"ck-heading_heading2\"},{model:\"heading3\",view:\"h4\",title:\"Heading 3\",class:\"ck-heading_heading3\"}]})}static get requires(){return[Ay]}init(){const t=this.editor;const e=t.config.get(\"heading.options\");const i=[];for(const n of e){if(n.model!==My){t.model.schema.register(n.model,{inheritAllFrom:\"$block\"});t.conversion.elementToElement(n);i.push(n.model)}}this._addDefaultH1Conversion(t);t.commands.add(\"heading\",new Ey(t,i))}afterInit(){const t=this.editor;const e=t.commands.get(\"enter\");const i=t.config.get(\"heading.options\");if(e){this.listenTo(e,\"afterExecute\",(e,n)=>{const o=t.model.document.selection.getFirstPosition().parent;const r=i.some(t=>o.is(t.model));if(r&&!o.is(My)&&o.childCount===0){n.writer.rename(o,My)}})}}_addDefaultH1Conversion(t){t.conversion.for(\"upcast\").elementToElement({model:\"heading1\",view:\"h1\",converterPriority:os.get(\"low\")+1})}}function Iy(t){const e=t.t;const i={Paragraph:e(\"Paragraph\"),\"Heading 1\":e(\"Heading 1\"),\"Heading 2\":e(\"Heading 2\"),\"Heading 3\":e(\"Heading 3\"),\"Heading 4\":e(\"Heading 4\"),\"Heading 5\":e(\"Heading 5\"),\"Heading 6\":e(\"Heading 6\")};return t.config.get(\"heading.options\").map(t=>{const e=i[t.title];if(e&&e!=t.title){t.title=e}return t})}var Ry=i(12);class Ly extends Nw{init(){const t=this.editor;const e=t.t;const i=Iy(t);const n=e(\"Choose heading\");const o=e(\"Heading\");t.ui.componentFactory.add(\"heading\",e=>{const r={};const s=new xs;const a=t.commands.get(\"heading\");const l=t.commands.get(\"paragraph\");const c=[a];for(const t of i){const e={type:\"button\",model:new rk({label:t.title,class:t.class,withText:true})};if(t.model===\"paragraph\"){e.model.bind(\"isOn\").to(l,\"value\");e.model.set(\"commandName\",\"paragraph\");c.push(l)}else{e.model.bind(\"isOn\").to(a,\"value\",e=>e===t.model);e.model.set({commandName:\"heading\",commandValue:t.model})}s.add(e);r[t.model]=t.title}const d=bw(e);_w(d,s);d.buttonView.set({isOn:false,withText:true,tooltip:o});d.extendTemplate({attributes:{class:[\"ck-heading-dropdown\"]}});d.bind(\"isEnabled\").toMany(c,\"isEnabled\",(...t)=>t.some(t=>t));d.buttonView.bind(\"label\").to(a,\"value\",l,\"value\",(t,e)=>{const i=t||e&&\"paragraph\";return r[i]?r[i]:n});this.listenTo(d,\"execute\",e=>{t.execute(e.source.commandName,e.source.commandValue?{value:e.source.commandValue}:undefined);t.editing.view.focus()});return d})}}class Ny extends Nw{static get requires(){return[Oy,Ly]}static get pluginName(){return\"Heading\"}}class By extends Vw{refresh(){const t=this.editor.model;const e=t.document;this.value=e.selection.getAttribute(\"highlight\");this.isEnabled=t.schema.checkAttributeInSelection(e.selection,\"highlight\")}execute(t={}){const e=this.editor.model;const i=e.document;const n=i.selection;const o=t.value;e.change(t=>{const i=e.schema.getValidRanges(n.getRanges(),\"highlight\");if(n.isCollapsed){const e=n.getFirstPosition();if(n.hasAttribute(\"highlight\")){const i=t=>t.item.hasAttribute(\"highlight\")&&t.item.getAttribute(\"highlight\")===this.value;const n=e.getLastMatchingPosition(i,{direction:\"backward\"});const r=e.getLastMatchingPosition(i);const s=t.createRange(n,r);if(!o||this.value===o){t.removeAttribute(\"highlight\",s);t.removeSelectionAttribute(\"highlight\")}else{t.setAttribute(\"highlight\",o,s);t.setSelectionAttribute(\"highlight\",o)}}else if(o){t.setSelectionAttribute(\"highlight\",o)}}else{for(const e of i){if(o){t.setAttribute(\"highlight\",o,e)}else{t.removeAttribute(\"highlight\",e)}}}})}}class Vy extends Nw{static get pluginName(){return\"HighlightEditing\"}constructor(t){super(t);t.config.define(\"highlight\",{options:[{model:\"yellowMarker\",class:\"marker-yellow\",title:\"Yellow marker\",color:\"var(--ck-highlight-marker-yellow)\",type:\"marker\"},{model:\"greenMarker\",class:\"marker-green\",title:\"Green marker\",color:\"var(--ck-highlight-marker-green)\",type:\"marker\"},{model:\"pinkMarker\",class:\"marker-pink\",title:\"Pink marker\",color:\"var(--ck-highlight-marker-pink)\",type:\"marker\"},{model:\"blueMarker\",class:\"marker-blue\",title:\"Blue marker\",color:\"var(--ck-highlight-marker-blue)\",type:\"marker\"},{model:\"redPen\",class:\"pen-red\",title:\"Red pen\",color:\"var(--ck-highlight-pen-red)\",type:\"pen\"},{model:\"greenPen\",class:\"pen-green\",title:\"Green pen\",color:\"var(--ck-highlight-pen-green)\",type:\"pen\"}]})}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:\"highlight\"});const e=t.config.get(\"highlight.options\");t.conversion.attributeToElement(Dy(e));t.commands.add(\"highlight\",new By(t))}}function Dy(t){const e={model:{key:\"highlight\",values:[]},view:{}};for(const i of t){e.model.values.push(i.model);e.view[i.model]={name:\"mark\",classes:i.class}}return e}var zy='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path class=\"ck-icon__fill\" d=\"M10.798 1.59L3.002 12.875l1.895 1.852 2.521 1.402 6.997-12.194z\"/><path d=\"M2.556 16.727l.234-.348c-.297-.151-.462-.293-.498-.426-.036-.137.002-.416.115-.837.094-.25.15-.449.169-.595a4.495 4.495 0 0 0 0-.725c-.209-.621-.303-1.041-.284-1.26.02-.218.178-.506.475-.862l6.77-9.414c.539-.91 1.605-.85 3.199.18 1.594 1.032 2.188 1.928 1.784 2.686l-5.877 10.36c-.158.412-.333.673-.526.782-.193.108-.604.179-1.232.21-.362.131-.608.237-.738.318-.13.081-.305.238-.526.47-.293.265-.504.397-.632.397-.096 0-.27-.075-.524-.226l-.31.41-1.6-1.12zm-.279.415l1.575 1.103-.392.515H1.19l1.087-1.618zm8.1-13.656l-4.953 6.9L8.75 12.57l4.247-7.574c.175-.25-.188-.647-1.092-1.192-.903-.546-1.412-.652-1.528-.32zM8.244 18.5L9.59 17h9.406v1.5H8.245z\"/></svg>';var Fy='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path class=\"ck-icon__fill\" d=\"M10.126 2.268L2.002 13.874l1.895 1.852 2.521 1.402L14.47 5.481l-1.543-2.568-2.801-.645z\"/><path d=\"M4.5 18.088l-2.645-1.852-.04-2.95-.006-.005.006-.008v-.025l.011.008L8.73 2.97c.165-.233.356-.417.567-.557l-1.212.308L4.604 7.9l-.83-.558 3.694-5.495 2.708-.69 1.65 1.145.046.018.85-1.216 2.16 1.512-.856 1.222c.828.967 1.144 2.141.432 3.158L7.55 17.286l.006.005-3.055.797H4.5zm-.634.166l-1.976.516-.026-1.918 2.002 1.402zM9.968 3.817l-.006-.004-6.123 9.184 3.277 2.294 6.108-9.162.005.003c.317-.452-.16-1.332-1.064-1.966-.891-.624-1.865-.776-2.197-.349zM8.245 18.5L9.59 17h9.406v1.5H8.245z\"/></svg>';var jy=i(61);class Hy extends Nw{get localizedOptionTitles(){const t=this.editor.t;return{\"Yellow marker\":t(\"Yellow marker\"),\"Green marker\":t(\"Green marker\"),\"Pink marker\":t(\"Pink marker\"),\"Blue marker\":t(\"Blue marker\"),\"Red pen\":t(\"Red pen\"),\"Green pen\":t(\"Green pen\")}}static get pluginName(){return\"HighlightUI\"}init(){const t=this.editor.config.get(\"highlight.options\");for(const e of t){this._addHighlighterButton(e)}this._addRemoveHighlightButton();this._addDropdown(t)}_addRemoveHighlightButton(){const t=this.editor.t;this._addButton(\"removeHighlight\",t(\"Remove highlight\"),Av)}_addHighlighterButton(t){const e=this.editor.commands.get(\"highlight\");this._addButton(\"highlight:\"+t.model,t.title,qy(t.type),t.model,i);function i(i){i.bind(\"isEnabled\").to(e,\"isEnabled\");i.bind(\"isOn\").to(e,\"value\",e=>e===t.model);i.iconView.fillColor=t.color;i.isToggleable=true}}_addButton(t,e,i,n,o=(()=>{})){const r=this.editor;r.ui.componentFactory.add(t,t=>{const s=new rw(t);const a=this.localizedOptionTitles[e]?this.localizedOptionTitles[e]:e;s.set({label:a,icon:i,tooltip:true});s.on(\"execute\",()=>{r.execute(\"highlight\",{value:n});r.editing.view.focus()});o(s);return s})}_addDropdown(t){const e=this.editor;const i=e.t;const n=e.ui.componentFactory;const o=t[0];const r=t.reduce((t,e)=>{t[e.model]=e;return t},{});n.add(\"highlight\",s=>{const a=e.commands.get(\"highlight\");const l=bw(s,ak);const c=l.buttonView;c.set({tooltip:i(\"Highlight\"),lastExecuted:o.model,commandValue:o.model,isToggleable:true});c.bind(\"icon\").to(a,\"value\",t=>qy(u(t,\"type\")));c.bind(\"color\").to(a,\"value\",t=>u(t,\"color\"));c.bind(\"commandValue\").to(a,\"value\",t=>u(t,\"model\"));c.bind(\"isOn\").to(a,\"value\",t=>!!t);c.delegate(\"execute\").to(l);const d=t.map(t=>{const e=n.create(\"highlight:\"+t.model);this.listenTo(e,\"execute\",()=>l.buttonView.set({lastExecuted:t.model}));return e});l.bind(\"isEnabled\").toMany(d,\"isEnabled\",(...t)=>t.some(t=>t));d.push(new Db);d.push(n.create(\"removeHighlight\"));ww(l,d);Wy(l);l.toolbarView.ariaLabel=i(\"Text highlight toolbar\");c.on(\"execute\",()=>{e.execute(\"highlight\",{value:c.commandValue});e.editing.view.focus()});function u(t,e){const i=!t||t===c.lastExecuted?c.lastExecuted:t;return r[i][e]}return l})}}function Wy(t){const e=t.buttonView.actionView;e.iconView.bind(\"fillColor\").to(t.buttonView,\"color\")}function qy(t){return t===\"marker\"?zy:Fy}class $y extends Nw{static get requires(){return[Vy,Hy]}static get pluginName(){return\"Highlight\"}}class Uy{constructor(){this._stack=[]}add(t,e){const i=this._stack;const n=i[0];this._insertDescriptor(t);const o=i[0];if(n!==o&&!Gy(n,o)){this.fire(\"change:top\",{oldDescriptor:n,newDescriptor:o,writer:e})}}remove(t,e){const i=this._stack;const n=i[0];this._removeDescriptor(t);const o=i[0];if(n!==o&&!Gy(n,o)){this.fire(\"change:top\",{oldDescriptor:n,newDescriptor:o,writer:e})}}_insertDescriptor(t){const e=this._stack;const i=e.findIndex(e=>e.id===t.id);if(Gy(t,e[i])){return}if(i>-1){e.splice(i,1)}let n=0;while(e[n]&&Jy(e[n],t)){n++}e.splice(n,0,t)}_removeDescriptor(t){const e=this._stack;const i=e.findIndex(e=>e.id===t);if(i>-1){e.splice(i,1)}}}ys(Uy,ds);function Gy(t,e){return t&&e&&t.priority==e.priority&&Ky(t.classes)==Ky(e.classes)}function Jy(t,e){if(t.priority>e.priority){return true}else if(t.priority<e.priority){return false}return Ky(t.classes)>Ky(e.classes)}function Ky(t){return Array.isArray(t)?t.sort().join(\",\"):t}var Xy=i(63);const Yy=Ib(\"px\");const Qy=Id.document.body;class Zy extends _b{constructor(t){super(t);const e=this.bindTemplate;this.set(\"top\",0);this.set(\"left\",0);this.set(\"position\",\"arrow_nw\");this.set(\"isVisible\",false);this.set(\"withArrow\",true);this.set(\"class\");this.content=this.createCollection();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-balloon-panel\",e.to(\"position\",t=>`ck-balloon-panel_${t}`),e.if(\"isVisible\",\"ck-balloon-panel_visible\"),e.if(\"withArrow\",\"ck-balloon-panel_with-arrow\"),e.to(\"class\")],style:{top:e.to(\"top\",Yy),left:e.to(\"left\",Yy)}},children:this.content})}show(){this.isVisible=true}hide(){this.isVisible=false}attachTo(t){this.show();const e=Zy.defaultPositions;const i=Object.assign({},{element:this.element,positions:[e.southArrowNorth,e.southArrowNorthMiddleWest,e.southArrowNorthMiddleEast,e.southArrowNorthWest,e.southArrowNorthEast,e.northArrowSouth,e.northArrowSouthMiddleWest,e.northArrowSouthMiddleEast,e.northArrowSouthWest,e.northArrowSouthEast],limiter:Qy,fitInViewport:true},t);const n=Zy._getOptimalPosition(i);const o=parseInt(n.left);const r=parseInt(n.top);const s=n.name;Object.assign(this,{top:r,left:o,position:s})}pin(t){this.unpin();this._pinWhenIsVisibleCallback=()=>{if(this.isVisible){this._startPinning(t)}else{this._stopPinning()}};this._startPinning(t);this.listenTo(this,\"change:isVisible\",this._pinWhenIsVisibleCallback)}unpin(){if(this._pinWhenIsVisibleCallback){this._stopPinning();this.stopListening(this,\"change:isVisible\",this._pinWhenIsVisibleCallback);this._pinWhenIsVisibleCallback=null;this.hide()}}_startPinning(t){this.attachTo(t);const e=tx(t.target);const i=t.limiter?tx(t.limiter):Qy;this.listenTo(Id.document,\"scroll\",(n,o)=>{const r=o.target;const s=e&&r.contains(e);const a=i&&r.contains(i);if(s||a||!e||!i){this.attachTo(t)}},{useCapture:true});this.listenTo(Id.window,\"resize\",()=>{this.attachTo(t)})}_stopPinning(){this.stopListening(Id.document,\"scroll\");this.stopListening(Id.window,\"resize\")}}function tx(t){if(Jr(t)){return t}if(wh(t)){return t.commonAncestorContainer}if(typeof t==\"function\"){return tx(t())}return null}Zy.arrowHorizontalOffset=25;Zy.arrowVerticalOffset=10;Zy._getOptimalPosition=Ub;Zy.defaultPositions={northWestArrowSouthWest:(t,e)=>({top:ex(t,e),left:t.left-Zy.arrowHorizontalOffset,name:\"arrow_sw\"}),northWestArrowSouthMiddleWest:(t,e)=>({top:ex(t,e),left:t.left-e.width*.25-Zy.arrowHorizontalOffset,name:\"arrow_smw\"}),northWestArrowSouth:(t,e)=>({top:ex(t,e),left:t.left-e.width/2,name:\"arrow_s\"}),northWestArrowSouthMiddleEast:(t,e)=>({top:ex(t,e),left:t.left-e.width*.75+Zy.arrowHorizontalOffset,name:\"arrow_sme\"}),northWestArrowSouthEast:(t,e)=>({top:ex(t,e),left:t.left-e.width+Zy.arrowHorizontalOffset,name:\"arrow_se\"}),northArrowSouthWest:(t,e)=>({top:ex(t,e),left:t.left+t.width/2-Zy.arrowHorizontalOffset,name:\"arrow_sw\"}),northArrowSouthMiddleWest:(t,e)=>({top:ex(t,e),left:t.left+t.width/2-e.width*.25-Zy.arrowHorizontalOffset,name:\"arrow_smw\"}),northArrowSouth:(t,e)=>({top:ex(t,e),left:t.left+t.width/2-e.width/2,name:\"arrow_s\"}),northArrowSouthMiddleEast:(t,e)=>({top:ex(t,e),left:t.left+t.width/2-e.width*.75+Zy.arrowHorizontalOffset,name:\"arrow_sme\"}),northArrowSouthEast:(t,e)=>({top:ex(t,e),left:t.left+t.width/2-e.width+Zy.arrowHorizontalOffset,name:\"arrow_se\"}),northEastArrowSouthWest:(t,e)=>({top:ex(t,e),left:t.right-Zy.arrowHorizontalOffset,name:\"arrow_sw\"}),northEastArrowSouthMiddleWest:(t,e)=>({top:ex(t,e),left:t.right-e.width*.25-Zy.arrowHorizontalOffset,name:\"arrow_smw\"}),northEastArrowSouth:(t,e)=>({top:ex(t,e),left:t.right-e.width/2,name:\"arrow_s\"}),northEastArrowSouthMiddleEast:(t,e)=>({top:ex(t,e),left:t.right-e.width*.75+Zy.arrowHorizontalOffset,name:\"arrow_sme\"}),northEastArrowSouthEast:(t,e)=>({top:ex(t,e),left:t.right-e.width+Zy.arrowHorizontalOffset,name:\"arrow_se\"}),southWestArrowNorthWest:(t,e)=>({top:ix(t,e),left:t.left-Zy.arrowHorizontalOffset,name:\"arrow_nw\"}),southWestArrowNorthMiddleWest:(t,e)=>({top:ix(t,e),left:t.left-e.width*.25-Zy.arrowHorizontalOffset,name:\"arrow_nmw\"}),southWestArrowNorth:(t,e)=>({top:ix(t,e),left:t.left-e.width/2,name:\"arrow_n\"}),southWestArrowNorthMiddleEast:(t,e)=>({top:ix(t,e),left:t.left-e.width*.75+Zy.arrowHorizontalOffset,name:\"arrow_nme\"}),southWestArrowNorthEast:(t,e)=>({top:ix(t,e),left:t.left-e.width+Zy.arrowHorizontalOffset,name:\"arrow_ne\"}),southArrowNorthWest:(t,e)=>({top:ix(t,e),left:t.left+t.width/2-Zy.arrowHorizontalOffset,name:\"arrow_nw\"}),southArrowNorthMiddleWest:(t,e)=>({top:ix(t,e),left:t.left+t.width/2-e.width*.25-Zy.arrowHorizontalOffset,name:\"arrow_nmw\"}),southArrowNorth:(t,e)=>({top:ix(t,e),left:t.left+t.width/2-e.width/2,name:\"arrow_n\"}),southArrowNorthMiddleEast:(t,e)=>({top:ix(t,e),left:t.left+t.width/2-e.width*.75+Zy.arrowHorizontalOffset,name:\"arrow_nme\"}),southArrowNorthEast:(t,e)=>({top:ix(t,e),left:t.left+t.width/2-e.width+Zy.arrowHorizontalOffset,name:\"arrow_ne\"}),southEastArrowNorthWest:(t,e)=>({top:ix(t,e),left:t.right-Zy.arrowHorizontalOffset,name:\"arrow_nw\"}),southEastArrowNorthMiddleWest:(t,e)=>({top:ix(t,e),left:t.right-e.width*.25-Zy.arrowHorizontalOffset,name:\"arrow_nmw\"}),southEastArrowNorth:(t,e)=>({top:ix(t,e),left:t.right-e.width/2,name:\"arrow_n\"}),southEastArrowNorthMiddleEast:(t,e)=>({top:ix(t,e),left:t.right-e.width*.75+Zy.arrowHorizontalOffset,name:\"arrow_nme\"}),southEastArrowNorthEast:(t,e)=>({top:ix(t,e),left:t.right-e.width+Zy.arrowHorizontalOffset,name:\"arrow_ne\"})};function ex(t,e){return t.top-e.height-Zy.arrowVerticalOffset}function ix(t){return t.bottom+Zy.arrowVerticalOffset}var nx='<svg viewBox=\"0 0 16 16\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M4 0v1H1v3H0V.5A.5.5 0 0 1 .5 0H4zm8 0h3.5a.5.5 0 0 1 .5.5V4h-1V1h-3V0zM4 16H.5a.5.5 0 0 1-.5-.5V12h1v3h3v1zm8 0v-1h3v-3h1v3.5a.5.5 0 0 1-.5.5H12z\"/><path fill-opacity=\".256\" d=\"M1 1h14v14H1z\"/><g class=\"ck-icon__selected-indicator\"><path d=\"M7 0h2v1H7V0zM0 7h1v2H0V7zm15 0h1v2h-1V7zm-8 8h2v1H7v-1z\"/><path fill-opacity=\".254\" d=\"M1 1h14v14H1z\"/></g></svg>';const ox=\"ck-widget\";const rx=\"ck-widget_selected\";function sx(t){if(!t.is(\"element\")){return false}return!!t.getCustomProperty(\"widget\")}function ax(t,e,i={}){e.setAttribute(\"contenteditable\",\"false\",t);e.addClass(ox,t);e.setCustomProperty(\"widget\",true,t);t.getFillerOffset=gx;if(i.label){cx(t,i.label,e)}if(i.hasSelectionHandle){px(t,e)}lx(t,e,(t,e,i)=>i.addClass(n(e.classes),t),(t,e,i)=>i.removeClass(n(e.classes),t));return t;function n(t){return Array.isArray(t)?t:[t]}}function lx(t,e,i,n){const o=new Uy;o.on(\"change:top\",(e,o)=>{if(o.oldDescriptor){n(t,o.oldDescriptor,o.writer)}if(o.newDescriptor){i(t,o.newDescriptor,o.writer)}});e.setCustomProperty(\"addHighlight\",(t,e,i)=>o.add(e,i),t);e.setCustomProperty(\"removeHighlight\",(t,e,i)=>o.remove(e,i),t)}function cx(t,e,i){i.setCustomProperty(\"widgetLabel\",e,t)}function dx(t){const e=t.getCustomProperty(\"widgetLabel\");if(!e){return\"\"}return typeof e==\"function\"?e():e}function ux(t,e){e.addClass([\"ck-editor__editable\",\"ck-editor__nested-editable\"],t);e.setAttribute(\"contenteditable\",t.isReadOnly?\"false\":\"true\",t);t.on(\"change:isReadOnly\",(i,n,o)=>{e.setAttribute(\"contenteditable\",o?\"false\":\"true\",t)});t.on(\"change:isFocused\",(i,n,o)=>{if(o){e.addClass(\"ck-editor__nested-editable_focused\",t)}else{e.removeClass(\"ck-editor__nested-editable_focused\",t)}});return t}function hx(t,e){const i=t.getSelectedElement();if(i&&e.schema.isBlock(i)){return e.createPositionAfter(i)}const n=t.getSelectedBlocks().next().value;if(n){if(n.isEmpty){return e.createPositionAt(n,0)}const i=e.createPositionAfter(n);if(t.focus.isTouching(i)){return i}return e.createPositionBefore(n)}return t.focus}function fx(t,e){return(i,n)=>{const{mapper:o,viewPosition:r}=n;const s=o.findMappedViewAncestor(r);if(!e(s)){return}const a=o.toModelElement(s);n.modelPosition=t.createPositionAt(a,r.isAtStart?\"before\":\"after\")}}function mx(t,e){const i=new vh(Id.window);const n=i.getIntersection(t);const o=e.height+Zy.arrowVerticalOffset;if(t.top-o>i.top||t.bottom+o<i.bottom){return null}const r=n||t;const s=r.left+r.width/2-e.width/2;return{top:Math.max(t.top,0)+Zy.arrowVerticalOffset,left:s,name:\"arrow_n\"}}function gx(){return null}function px(t,e){const i=e.createUIElement(\"div\",{class:\"ck ck-widget__selection-handle\"},(function(t){const e=this.toDomElement(t);const i=new ew;i.set(\"content\",nx);i.render();e.appendChild(i.element);return e}));e.insert(e.createPositionAt(t,0),i);e.addClass([\"ck-widget_with-selection-handle\"],t)}class bx extends Vw{refresh(){this.isEnabled=wx(this.editor.model)}execute(){const t=this.editor.model;t.change(e=>{const i=e.createElement(\"horizontalLine\");t.insertContent(i);let n=i.nextSibling;const o=n&&t.schema.checkChild(n,\"$text\");if(!o&&t.schema.checkChild(i.parent,\"paragraph\")){n=e.createElement(\"paragraph\");t.insertContent(n,e.createPositionAfter(i))}if(n){e.setSelection(n,0)}})}}function wx(t){const e=t.schema;const i=t.document.selection;return _x(i,e,t)&&!kx(i,e)}function _x(t,e,i){const n=vx(t,i);return e.checkChild(n,\"horizontalLine\")}function kx(t,e){const i=t.getSelectedElement();return i&&e.isObject(i)}function vx(t,e){const i=hx(t,e);const n=i.parent;if(n.isEmpty&&!n.is(\"$root\")){return n.parent}return n}var yx=i(65);class xx extends Nw{static get pluginName(){return\"HorizontalLineEditing\"}init(){const t=this.editor;const e=t.model.schema;const i=t.t;const n=t.conversion;e.register(\"horizontalLine\",{isObject:true,allowWhere:\"$block\"});n.for(\"dataDowncast\").elementToElement({model:\"horizontalLine\",view:(t,e)=>e.createEmptyElement(\"hr\")});n.for(\"editingDowncast\").elementToElement({model:\"horizontalLine\",view:(t,e)=>{const n=i(\"Horizontal line\");const o=e.createContainerElement(\"div\");const r=e.createEmptyElement(\"hr\");e.addClass(\"ck-horizontal-line\",o);e.setCustomProperty(\"hr\",true,o);e.insert(e.createPositionAt(o,0),r);return Cx(o,e,n)}});n.for(\"upcast\").elementToElement({view:\"hr\",model:\"horizontalLine\"});t.commands.add(\"horizontalLine\",new bx(t))}}function Cx(t,e,i){e.setCustomProperty(\"horizontalLine\",true,t);return ax(t,e,{label:i})}var Ax='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 9h16v2H2z\"/></svg>';class Tx extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(\"horizontalLine\",i=>{const n=t.commands.get(\"horizontalLine\");const o=new rw(i);o.set({label:e(\"Horizontal line\"),icon:Ax,tooltip:true});o.bind(\"isEnabled\").to(n,\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(\"horizontalLine\");t.editing.view.focus()});return o})}}class Px extends Nw{static get requires(){return[xx,Tx]}static get pluginName(){return\"HorizontalLine\"}}class Ex extends Vw{constructor(t){super(t);this._childCommands=[]}refresh(){}execute(...t){const e=this._getFirstEnabledCommand();e.execute(t)}registerChildCommand(t){this._childCommands.push(t);t.on(\"change:isEnabled\",()=>this._checkEnabled());this._checkEnabled()}_checkEnabled(){this.isEnabled=!!this._getFirstEnabledCommand()}_getFirstEnabledCommand(){return this._childCommands.find(t=>t.isEnabled)}}class Sx extends Nw{static get pluginName(){return\"IndentEditing\"}init(){const t=this.editor;t.commands.add(\"indent\",new Ex(t));t.commands.add(\"outdent\",new Ex(t))}}var Mx='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 3.75c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm5 6c0 .414.336.75.75.75h9.5a.75.75 0 1 0 0-1.5h-9.5a.75.75 0 0 0-.75.75zM2.75 16.5h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 1 0 0 1.5zM1.632 6.95L5.02 9.358a.4.4 0 0 1-.013.661l-3.39 2.207A.4.4 0 0 1 1 11.892V7.275a.4.4 0 0 1 .632-.326z\"/></svg>';var Ox='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 3.75c0 .414.336.75.75.75h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 0 0-.75.75zm5 6c0 .414.336.75.75.75h9.5a.75.75 0 1 0 0-1.5h-9.5a.75.75 0 0 0-.75.75zM2.75 16.5h14.5a.75.75 0 1 0 0-1.5H2.75a.75.75 0 1 0 0 1.5zm1.618-9.55L.98 9.358a.4.4 0 0 0 .013.661l3.39 2.207A.4.4 0 0 0 5 11.892V7.275a.4.4 0 0 0-.632-.326z\"/></svg>';class Ix extends Nw{static get pluginName(){return\"IndentUI\"}init(){const t=this.editor;const e=t.locale;const i=t.t;const n=e.uiLanguageDirection==\"ltr\"?Mx:Ox;const o=e.uiLanguageDirection==\"ltr\"?Ox:Mx;this._defineButton(\"indent\",i(\"Increase indent\"),n);this._defineButton(\"outdent\",i(\"Decrease indent\"),o)}_defineButton(t,e,i){const n=this.editor;n.ui.componentFactory.add(t,o=>{const r=n.commands.get(t);const s=new rw(o);s.set({label:e,icon:i,tooltip:true});s.bind(\"isOn\",\"isEnabled\").to(r,\"value\",\"isEnabled\");this.listenTo(s,\"execute\",()=>{n.execute(t);n.editing.view.focus()});return s})}}class Rx extends Nw{static get pluginName(){return\"Indent\"}static get requires(){return[Sx,Ix]}}class Lx extends Vw{constructor(t,e){super(t);this._indentBehavior=e}refresh(){const t=this.editor;const e=t.model;const i=zw(e.document.selection.getSelectedBlocks());if(!i||!e.schema.checkAttribute(i,\"blockIndent\")){this.isEnabled=false;return}this.isEnabled=this._indentBehavior.checkEnabled(i.getAttribute(\"blockIndent\"))}execute(){const t=this.editor.model;const e=Nx(t);t.change(t=>{for(const i of e){const e=i.getAttribute(\"blockIndent\");const n=this._indentBehavior.getNextIndent(e);if(n){t.setAttribute(\"blockIndent\",n,i)}else{t.removeAttribute(\"blockIndent\",i)}}})}}function Nx(t){const e=t.document.selection;const i=t.schema;const n=Array.from(e.getSelectedBlocks());return n.filter(t=>i.checkAttribute(t,\"blockIndent\"))}class Bx{constructor(t){this.isForward=t.direction===\"forward\";this.offset=t.offset;this.unit=t.unit}checkEnabled(t){const e=parseFloat(t||0);return this.isForward||e>0}getNextIndent(t){const e=parseFloat(t||0);const i=!t||t.endsWith(this.unit);if(!i){return this.isForward?this.offset+this.unit:undefined}const n=this.isForward?this.offset:-this.offset;const o=e+n;return o>0?o+this.unit:undefined}}class Vx{constructor(t){this.isForward=t.direction===\"forward\";this.classes=t.classes}checkEnabled(t){const e=this.classes.indexOf(t);if(this.isForward){return e<this.classes.length-1}else{return e>=0}}getNextIndent(t){const e=this.classes.indexOf(t);const i=this.isForward?1:-1;return this.classes[e+i]}}const Dx=/^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i;const zx=/^rgb\\([ ]?([0-9]{1,3}[ %]?,[ ]?){2,3}[0-9]{1,3}[ %]?\\)$/i;const Fx=/^rgba\\([ ]?([0-9]{1,3}[ %]?,[ ]?){3}(1|[0-9]+%|[0]?\\.?[0-9]+)\\)$/i;const jx=/^hsl\\([ ]?([0-9]{1,3}[ %]?[,]?[ ]*){3}(1|[0-9]+%|[0]?\\.?[0-9]+)?\\)$/i;const Hx=/^hsla\\([ ]?([0-9]{1,3}[ %]?,[ ]?){2,3}(1|[0-9]+%|[0]?\\.?[0-9]+)\\)$/i;const Wx=new Set([\"black\",\"silver\",\"gray\",\"white\",\"maroon\",\"red\",\"purple\",\"fuchsia\",\"green\",\"lime\",\"olive\",\"yellow\",\"navy\",\"blue\",\"teal\",\"aqua\",\"orange\",\"aliceblue\",\"antiquewhite\",\"aquamarine\",\"azure\",\"beige\",\"bisque\",\"blanchedalmond\",\"blueviolet\",\"brown\",\"burlywood\",\"cadetblue\",\"chartreuse\",\"chocolate\",\"coral\",\"cornflowerblue\",\"cornsilk\",\"crimson\",\"cyan\",\"darkblue\",\"darkcyan\",\"darkgoldenrod\",\"darkgray\",\"darkgreen\",\"darkgrey\",\"darkkhaki\",\"darkmagenta\",\"darkolivegreen\",\"darkorange\",\"darkorchid\",\"darkred\",\"darksalmon\",\"darkseagreen\",\"darkslateblue\",\"darkslategray\",\"darkslategrey\",\"darkturquoise\",\"darkviolet\",\"deeppink\",\"deepskyblue\",\"dimgray\",\"dimgrey\",\"dodgerblue\",\"firebrick\",\"floralwhite\",\"forestgreen\",\"gainsboro\",\"ghostwhite\",\"gold\",\"goldenrod\",\"greenyellow\",\"grey\",\"honeydew\",\"hotpink\",\"indianred\",\"indigo\",\"ivory\",\"khaki\",\"lavender\",\"lavenderblush\",\"lawngreen\",\"lemonchiffon\",\"lightblue\",\"lightcoral\",\"lightcyan\",\"lightgoldenrodyellow\",\"lightgray\",\"lightgreen\",\"lightgrey\",\"lightpink\",\"lightsalmon\",\"lightseagreen\",\"lightskyblue\",\"lightslategray\",\"lightslategrey\",\"lightsteelblue\",\"lightyellow\",\"limegreen\",\"linen\",\"magenta\",\"mediumaquamarine\",\"mediumblue\",\"mediumorchid\",\"mediumpurple\",\"mediumseagreen\",\"mediumslateblue\",\"mediumspringgreen\",\"mediumturquoise\",\"mediumvioletred\",\"midnightblue\",\"mintcream\",\"mistyrose\",\"moccasin\",\"navajowhite\",\"oldlace\",\"olivedrab\",\"orangered\",\"orchid\",\"palegoldenrod\",\"palegreen\",\"paleturquoise\",\"palevioletred\",\"papayawhip\",\"peachpuff\",\"peru\",\"pink\",\"plum\",\"powderblue\",\"rosybrown\",\"royalblue\",\"saddlebrown\",\"salmon\",\"sandybrown\",\"seagreen\",\"seashell\",\"sienna\",\"skyblue\",\"slateblue\",\"slategray\",\"slategrey\",\"snow\",\"springgreen\",\"steelblue\",\"tan\",\"thistle\",\"tomato\",\"turquoise\",\"violet\",\"wheat\",\"whitesmoke\",\"yellowgreen\",\"rebeccapurple\",\"currentcolor\",\"transparent\"]);function qx(t){if(t.startsWith(\"#\")){return Dx.test(t)}if(t.startsWith(\"rgb\")){return zx.test(t)||Fx.test(t)}if(t.startsWith(\"hsl\")){return jx.test(t)||Hx.test(t)}return Wx.has(t.toLowerCase())}const $x=[\"none\",\"hidden\",\"dotted\",\"dashed\",\"solid\",\"double\",\"groove\",\"ridge\",\"inset\",\"outset\"];function Ux(t){return $x.includes(t)}const Gx=/^([+-]?[0-9]*[.]?[0-9]+(px|cm|mm|in|pc|pt|ch|em|ex|rem|vh|vw|vmin|vmax)|0)$/;function Jx(t){return Gx.test(t)}const Kx=/^[+-]?[0-9]*[.]?[0-9]+%$/;function Xx(t){return Kx.test(t)}const Yx=[\"repeat-x\",\"repeat-y\",\"repeat\",\"space\",\"round\",\"no-repeat\"];function Qx(t){return Yx.includes(t)}const Zx=[\"center\",\"top\",\"bottom\",\"left\",\"right\"];function tC(t){return Zx.includes(t)}const eC=[\"fixed\",\"scroll\",\"local\"];function iC(t){return eC.includes(t)}const nC=/^url\\(/;function oC(t){return nC.test(t)}function rC(t=\"\"){if(t===\"\"){return{top:undefined,right:undefined,bottom:undefined,left:undefined}}const e=cC(t);const i=e[0];const n=e[2]||i;const o=e[1]||i;const r=e[3]||o;return{top:i,bottom:n,right:o,left:r}}function sC(t){return e=>{const{top:i,right:n,bottom:o,left:r}=e;const s=[];if(![i,n,r,o].every(t=>!!t)){if(i){s.push([t+\"-top\",i])}if(n){s.push([t+\"-right\",n])}if(o){s.push([t+\"-bottom\",o])}if(r){s.push([t+\"-left\",r])}}else{s.push([t,aC(e)])}return s}}function aC({top:t,right:e,bottom:i,left:n}){const o=[];if(n!==e){o.push(t,e,i,n)}else if(i!==t){o.push(t,e,i)}else if(e!==t){o.push(t,e)}else{o.push(t)}return o.join(\" \")}function lC(t){return e=>({path:t,value:rC(e)})}function cC(t){return t.replace(/, /g,\",\").split(\" \").map(t=>t.replace(/,/g,\", \"))}function dC(t){t.setNormalizer(\"margin\",lC(\"margin\"));t.setNormalizer(\"margin-top\",t=>({path:\"margin.top\",value:t}));t.setNormalizer(\"margin-right\",t=>({path:\"margin.right\",value:t}));t.setNormalizer(\"margin-bottom\",t=>({path:\"margin.bottom\",value:t}));t.setNormalizer(\"margin-left\",t=>({path:\"margin.left\",value:t}));t.setReducer(\"margin\",sC(\"margin\"));t.setStyleRelation(\"margin\",[\"margin-top\",\"margin-right\",\"margin-bottom\",\"margin-left\"])}class uC extends Nw{constructor(t){super(t);t.config.define(\"indentBlock\",{offset:40,unit:\"px\"})}static get pluginName(){return\"IndentBlock\"}init(){const t=this.editor;const e=t.config.get(\"indentBlock\");const i=!e.classes||!e.classes.length;const n=Object.assign({direction:\"forward\"},e);const o=Object.assign({direction:\"backward\"},e);if(i){t.data.addStyleProcessorRules(dC);this._setupConversionUsingOffset(t.conversion);t.commands.add(\"indentBlock\",new Lx(t,new Bx(n)));t.commands.add(\"outdentBlock\",new Lx(t,new Bx(o)))}else{this._setupConversionUsingClasses(e.classes);t.commands.add(\"indentBlock\",new Lx(t,new Vx(n)));t.commands.add(\"outdentBlock\",new Lx(t,new Vx(o)))}}afterInit(){const t=this.editor;const e=t.model.schema;const i=t.commands.get(\"indent\");const n=t.commands.get(\"outdent\");const o=[\"paragraph\",\"heading1\",\"heading2\",\"heading3\",\"heading4\",\"heading5\",\"heading6\"];o.forEach(t=>{if(e.isRegistered(t)){e.extend(t,{allowAttributes:\"blockIndent\"})}});i.registerChildCommand(t.commands.get(\"indentBlock\"));n.registerChildCommand(t.commands.get(\"outdentBlock\"))}_setupConversionUsingOffset(){const t=this.editor.conversion;const e=this.editor.locale;const i=e.contentLanguageDirection===\"rtl\"?\"margin-right\":\"margin-left\";t.for(\"upcast\").attributeToAttribute({view:{styles:{[i]:/[\\s\\S]+/}},model:{key:\"blockIndent\",value:t=>t.getStyle(i)}});t.for(\"downcast\").attributeToAttribute({model:\"blockIndent\",view:t=>({key:\"style\",value:{[i]:t}})})}_setupConversionUsingClasses(t){const e={model:{key:\"blockIndent\",values:[]},view:{}};for(const i of t){e.model.values.push(i);e.view[i]={key:\"class\",value:[i]}}this.editor.conversion.attributeToAttribute(e)}}const hC=\"italic\";class fC extends Nw{static get pluginName(){return\"ItalicEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:hC});t.model.schema.setAttributeProperties(hC,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:hC,view:\"i\",upcastAlso:[\"em\",{styles:{\"font-style\":\"italic\"}}]});t.commands.add(hC,new b_(t,hC));t.keystrokes.set(\"CTRL+I\",hC)}}var mC='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M9.586 14.633l.021.004c-.036.335.095.655.393.962.082.083.173.15.274.201h1.474a.6.6 0 1 1 0 1.2H5.304a.6.6 0 0 1 0-1.2h1.15c.474-.07.809-.182 1.005-.334.157-.122.291-.32.404-.597l2.416-9.55a1.053 1.053 0 0 0-.281-.823 1.12 1.12 0 0 0-.442-.296H8.15a.6.6 0 0 1 0-1.2h6.443a.6.6 0 1 1 0 1.2h-1.195c-.376.056-.65.155-.823.296-.215.175-.423.439-.623.79l-2.366 9.347z\"/></svg>';const gC=\"italic\";class pC extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(gC,i=>{const n=t.commands.get(gC);const o=new rw(i);o.set({label:e(\"Italic\"),icon:mC,keystroke:\"CTRL+I\",tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(gC);t.editing.view.focus()});return o})}}class bC extends Nw{static get requires(){return[fC,pC]}static get pluginName(){return\"Italic\"}}function wC(t,e,i){return i.createRange(_C(t,e,true,i),_C(t,e,false,i))}function _C(t,e,i,n){let o=t.textNode||(i?t.nodeBefore:t.nodeAfter);let r=null;while(o&&o.getAttribute(\"linkHref\")==e){r=o;o=i?o.previousSibling:o.nextSibling}return r?n.createPositionAt(r,i?\"before\":\"after\"):t}class kC extends Vw{constructor(t){super(t);this.manualDecorators=new xs}restoreManualDecoratorStates(){for(const t of this.manualDecorators){t.value=this._getDecoratorStateFromModel(t.id)}}refresh(){const t=this.editor.model;const e=t.document;this.value=e.selection.getAttribute(\"linkHref\");for(const t of this.manualDecorators){t.value=this._getDecoratorStateFromModel(t.id)}this.isEnabled=t.schema.checkAttributeInSelection(e.selection,\"linkHref\")}execute(t,e={}){const i=this.editor.model;const n=i.document.selection;const o=[];const r=[];for(const t in e){if(e[t]){o.push(t)}else{r.push(t)}}i.change(e=>{if(n.isCollapsed){const s=n.getFirstPosition();if(n.hasAttribute(\"linkHref\")){const a=wC(s,n.getAttribute(\"linkHref\"),i);e.setAttribute(\"linkHref\",t,a);o.forEach(t=>{e.setAttribute(t,true,a)});r.forEach(t=>{e.removeAttribute(t,a)});e.setSelection(a)}else if(t!==\"\"){const r=Ws(n.getAttributes());r.set(\"linkHref\",t);o.forEach(t=>{r.set(t,true)});const a=e.createText(t,r);i.insertContent(a,s);e.setSelection(e.createRangeOn(a))}}else{const s=i.schema.getValidRanges(n.getRanges(),\"linkHref\");for(const i of s){e.setAttribute(\"linkHref\",t,i);o.forEach(t=>{e.setAttribute(t,true,i)});r.forEach(t=>{e.removeAttribute(t,i)})}}})}_getDecoratorStateFromModel(t){const e=this.editor.model.document;return e.selection.getAttribute(t)}}class vC extends Vw{refresh(){this.isEnabled=this.editor.model.document.selection.hasAttribute(\"linkHref\")}execute(){const t=this.editor;const e=this.editor.model;const i=e.document.selection;const n=t.commands.get(\"link\");e.change(t=>{const o=i.isCollapsed?[wC(i.getFirstPosition(),i.getAttribute(\"linkHref\"),e)]:i.getRanges();for(const e of o){t.removeAttribute(\"linkHref\",e);if(n){for(const i of n.manualDecorators){t.removeAttribute(i.id,e)}}}})}}function yC(t,e,i){var n=t.length;i=i===undefined?n:i;return!e&&i>=n?t:Ia(t,e,i)}var xC=yC;var CC=\"\\\\ud800-\\\\udfff\",AC=\"\\\\u0300-\\\\u036f\",TC=\"\\\\ufe20-\\\\ufe2f\",PC=\"\\\\u20d0-\\\\u20ff\",EC=AC+TC+PC,SC=\"\\\\ufe0e\\\\ufe0f\";var MC=\"\\\\u200d\";var OC=RegExp(\"[\"+MC+CC+EC+SC+\"]\");function IC(t){return OC.test(t)}var RC=IC;function LC(t){return t.split(\"\")}var NC=LC;var BC=\"\\\\ud800-\\\\udfff\",VC=\"\\\\u0300-\\\\u036f\",DC=\"\\\\ufe20-\\\\ufe2f\",zC=\"\\\\u20d0-\\\\u20ff\",FC=VC+DC+zC,jC=\"\\\\ufe0e\\\\ufe0f\";var HC=\"[\"+BC+\"]\",WC=\"[\"+FC+\"]\",qC=\"\\\\ud83c[\\\\udffb-\\\\udfff]\",$C=\"(?:\"+WC+\"|\"+qC+\")\",UC=\"[^\"+BC+\"]\",GC=\"(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}\",JC=\"[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]\",KC=\"\\\\u200d\";var XC=$C+\"?\",YC=\"[\"+jC+\"]?\",QC=\"(?:\"+KC+\"(?:\"+[UC,GC,JC].join(\"|\")+\")\"+YC+XC+\")*\",ZC=YC+XC+QC,tA=\"(?:\"+[UC+WC+\"?\",WC,GC,JC,HC].join(\"|\")+\")\";var eA=RegExp(qC+\"(?=\"+qC+\")|\"+tA+ZC,\"g\");function iA(t){return t.match(eA)||[]}var nA=iA;function oA(t){return RC(t)?nA(t):NC(t)}var rA=oA;function sA(t){return function(e){e=va(e);var i=RC(e)?rA(e):undefined;var n=i?i[0]:e.charAt(0);var o=i?xC(i,1).join(\"\"):e.slice(1);return n[t]()+o}}var aA=sA;var lA=aA(\"toUpperCase\");var cA=lA;const dA=/[\\u0000-\\u0020\\u00A0\\u1680\\u180E\\u2000-\\u2029\\u205f\\u3000]/g;const uA=/^(?:(?:https?|ftps?|mailto):|[^a-z]|[a-z+.-]+(?:[^a-z+.:-]|$))/i;function hA(t){return t.is(\"attributeElement\")&&!!t.getCustomProperty(\"link\")}function fA(t,e){const i=e.createAttributeElement(\"a\",{href:t},{priority:5});e.setCustomProperty(\"link\",true,i);return i}function mA(t){t=String(t);return gA(t)?t:\"#\"}function gA(t){const e=t.replace(dA,\"\");return e.match(uA)}function pA(t,e){const i={\"Open in a new tab\":t(\"Open in a new tab\"),Downloadable:t(\"Downloadable\")};e.forEach(t=>{if(t.label&&i[t.label]){t.label=i[t.label]}return t});return e}function bA(t){const e=[];if(t){for(const[i,n]of Object.entries(t)){const t=Object.assign({},n,{id:`link${cA(i)}`});e.push(t)}}return e}class wA{constructor(){this._definitions=new Set}get length(){return this._definitions.size}add(t){if(Array.isArray(t)){t.forEach(t=>this._definitions.add(t))}else{this._definitions.add(t)}}getDispatcher(){return t=>{t.on(\"attribute:linkHref\",(t,e,i)=>{if(!i.consumable.test(e.item,\"attribute:linkHref\")){return}const n=i.writer;const o=n.document.selection;for(const t of this._definitions){const r=n.createAttributeElement(\"a\",t.attributes,{priority:5});n.setCustomProperty(\"link\",true,r);if(t.callback(e.attributeNewValue)){if(e.item.is(\"selection\")){n.wrap(o.getFirstRange(),r)}else{n.wrap(i.mapper.toViewRange(e.range),r)}}else{n.unwrap(i.mapper.toViewRange(e.range),r)}}},{priority:\"high\"})}}}class _A{constructor({id:t,label:e,attributes:i,defaultValue:n}){this.id=t;this.set(\"value\");this.defaultValue=n;this.label=e;this.attributes=i}}ys(_A,Xl);function kA({view:t,model:e,emitter:i,attribute:n,locale:o}){const r=new vA(e,i,n);const s=e.document.selection;i.listenTo(t.document,\"keydown\",(t,e)=>{if(!s.isCollapsed){return}if(e.shiftKey||e.altKey||e.ctrlKey){return}const i=e.keyCode==Lc.arrowright;const n=e.keyCode==Lc.arrowleft;if(!i&&!n){return}const a=s.getFirstPosition();const l=o.contentLanguageDirection;let c;if(l===\"ltr\"&&i||l===\"rtl\"&&n){c=r.handleForwardMovement(a,e)}else{c=r.handleBackwardMovement(a,e)}if(c){t.stop()}},{priority:os.get(\"high\")+1})}class vA{constructor(t,e,i){this.model=t;this.attribute=i;this._modelSelection=t.document.selection;this._overrideUid=null;this._isNextGravityRestorationSkipped=false;e.listenTo(this._modelSelection,\"change:range\",(t,e)=>{if(this._isNextGravityRestorationSkipped){this._isNextGravityRestorationSkipped=false;return}if(!this._isGravityOverridden){return}if(!e.directChange&&yA(this._modelSelection.getFirstPosition(),i)){return}this._restoreGravity()})}handleForwardMovement(t,e){const i=this.attribute;if(this._isGravityOverridden){return}if(t.isAtStart&&this._hasSelectionAttribute){return}if(AA(t,i)&&this._hasSelectionAttribute){this._preventCaretMovement(e);this._removeSelectionAttribute();return true}if(xA(t,i)){this._preventCaretMovement(e);this._overrideGravity();return true}if(CA(t,i)&&this._hasSelectionAttribute){this._preventCaretMovement(e);this._overrideGravity();return true}}handleBackwardMovement(t,e){const i=this.attribute;if(this._isGravityOverridden){if(AA(t,i)&&this._hasSelectionAttribute){this._preventCaretMovement(e);this._restoreGravity();this._removeSelectionAttribute();return true}else{this._preventCaretMovement(e);this._restoreGravity();if(t.isAtStart){this._removeSelectionAttribute()}return true}}else{if(AA(t,i)&&!this._hasSelectionAttribute){this._preventCaretMovement(e);this._setSelectionAttributeFromTheNodeBefore(t);return true}if(t.isAtEnd&&CA(t,i)){if(this._hasSelectionAttribute){if(TA(t,i)){this._skipNextAutomaticGravityRestoration();this._overrideGravity()}return}else{this._preventCaretMovement(e);this._setSelectionAttributeFromTheNodeBefore(t);return true}}if(t.isAtStart){if(this._hasSelectionAttribute){this._removeSelectionAttribute();this._preventCaretMovement(e);return true}return}if(TA(t,i)){this._skipNextAutomaticGravityRestoration();this._overrideGravity()}}}get _isGravityOverridden(){return!!this._overrideUid}get _hasSelectionAttribute(){return this._modelSelection.hasAttribute(this.attribute)}_overrideGravity(){this._overrideUid=this.model.change(t=>t.overrideSelectionGravity())}_restoreGravity(){this.model.change(t=>{t.restoreSelectionGravity(this._overrideUid);this._overrideUid=null})}_preventCaretMovement(t){t.preventDefault()}_removeSelectionAttribute(){this.model.change(t=>{t.removeSelectionAttribute(this.attribute)})}_setSelectionAttributeFromTheNodeBefore(t){const e=this.attribute;this.model.change(i=>{i.setSelectionAttribute(this.attribute,t.nodeBefore.getAttribute(e))})}_skipNextAutomaticGravityRestoration(){this._isNextGravityRestorationSkipped=true}}function yA(t,e){return xA(t,e)||CA(t,e)}function xA(t,e){const{nodeBefore:i,nodeAfter:n}=t;const o=i?i.hasAttribute(e):false;const r=n?n.hasAttribute(e):false;return r&&(!o||i.getAttribute(e)!==n.getAttribute(e))}function CA(t,e){const{nodeBefore:i,nodeAfter:n}=t;const o=i?i.hasAttribute(e):false;const r=n?n.hasAttribute(e):false;return o&&(!r||i.getAttribute(e)!==n.getAttribute(e))}function AA(t,e){const{nodeBefore:i,nodeAfter:n}=t;const o=i?i.hasAttribute(e):false;const r=n?n.hasAttribute(e):false;if(!r||!o){return}return n.getAttribute(e)!==i.getAttribute(e)}function TA(t,e){return yA(t.getShiftedBy(-1),e)}var PA=i(67);const EA=\"ck-link_selected\";const SA=\"automatic\";const MA=\"manual\";const OA=/^(https?:)?\\/\\//;class IA extends Nw{static get pluginName(){return\"LinkEditing\"}constructor(t){super(t);t.config.define(\"link\",{addTargetToExternalLinks:false})}init(){const t=this.editor;const e=t.locale;t.model.schema.extend(\"$text\",{allowAttributes:\"linkHref\"});t.conversion.for(\"dataDowncast\").attributeToElement({model:\"linkHref\",view:fA});t.conversion.for(\"editingDowncast\").attributeToElement({model:\"linkHref\",view:(t,e)=>fA(mA(t),e)});t.conversion.for(\"upcast\").elementToAttribute({view:{name:\"a\",attributes:{href:true}},model:{key:\"linkHref\",value:t=>t.getAttribute(\"href\")}});t.commands.add(\"link\",new kC(t));t.commands.add(\"unlink\",new vC(t));const i=pA(t.t,bA(t.config.get(\"link.decorators\")));this._enableAutomaticDecorators(i.filter(t=>t.mode===SA));this._enableManualDecorators(i.filter(t=>t.mode===MA));kA({view:t.editing.view,model:t.model,emitter:this,attribute:\"linkHref\",locale:e});this._setupLinkHighlight();this._enableInsertContentSelectionAttributesFixer()}_enableAutomaticDecorators(t){const e=this.editor;const i=new wA;if(e.config.get(\"link.addTargetToExternalLinks\")){i.add({id:\"linkIsExternal\",mode:SA,callback:t=>OA.test(t),attributes:{target:\"_blank\",rel:\"noopener noreferrer\"}})}i.add(t);if(i.length){e.conversion.for(\"downcast\").add(i.getDispatcher())}}_enableManualDecorators(t){if(!t.length){return}const e=this.editor;const i=e.commands.get(\"link\");const n=i.manualDecorators;t.forEach(t=>{e.model.schema.extend(\"$text\",{allowAttributes:t.id});n.add(new _A(t));e.conversion.for(\"downcast\").attributeToElement({model:t.id,view:(e,i)=>{if(e){const e=n.get(t.id).attributes;const o=i.createAttributeElement(\"a\",e,{priority:5});i.setCustomProperty(\"link\",true,o);return o}}});e.conversion.for(\"upcast\").elementToAttribute({view:{name:\"a\",attributes:n.get(t.id).attributes},model:{key:t.id}})})}_setupLinkHighlight(){const t=this.editor;const e=t.editing.view;const i=new Set;e.document.registerPostFixer(e=>{const n=t.model.document.selection;let o=false;if(n.hasAttribute(\"linkHref\")){const r=wC(n.getFirstPosition(),n.getAttribute(\"linkHref\"),t.model);const s=t.editing.mapper.toViewRange(r);for(const t of s.getItems()){if(t.is(\"a\")&&!t.hasClass(EA)){e.addClass(EA,t);i.add(t);o=true}}}return o});t.conversion.for(\"editingDowncast\").add(t=>{t.on(\"insert\",n,{priority:\"highest\"});t.on(\"remove\",n,{priority:\"highest\"});t.on(\"attribute\",n,{priority:\"highest\"});t.on(\"selection\",n,{priority:\"highest\"});function n(){e.change(t=>{for(const e of i.values()){t.removeClass(EA,e);i.delete(e)}})}})}_enableInsertContentSelectionAttributesFixer(){const t=this.editor;const e=t.model;const i=e.document.selection;e.on(\"insertContent\",()=>{const t=i.anchor.nodeBefore;const n=i.anchor.nodeAfter;if(!i.hasAttribute(\"linkHref\")){return}if(!t){return}if(!t.hasAttribute(\"linkHref\")){return}if(n&&n.hasAttribute(\"linkHref\")){return}e.change(t=>{[...e.document.selection.getAttributeKeys()].filter(t=>t.startsWith(\"link\")).forEach(e=>t.removeSelectionAttribute(e))})},{priority:\"low\"})}}class RA extends Ku{constructor(t){super(t);this.domEventType=\"click\"}onDomEvent(t){this.fire(t.type,t)}}var LA='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.463 5.187a.888.888 0 1 1 1.254 1.255L9.16 10l3.557 3.557a.888.888 0 1 1-1.254 1.255L7.26 10.61a.888.888 0 0 1 .16-1.382l4.043-4.042z\"/></svg>';var NA='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M8.537 14.813a.888.888 0 1 1-1.254-1.255L10.84 10 7.283 6.442a.888.888 0 1 1 1.254-1.255L12.74 9.39a.888.888 0 0 1-.16 1.382l-4.043 4.042z\"/></svg>';var BA=i(69);var VA=i(71);const DA=Ib(\"px\");class zA extends Nw{static get pluginName(){return\"ContextualBalloon\"}constructor(t){super(t);this.positionLimiter=()=>{const t=this.editor.editing.view;const e=t.document;const i=e.selection.editableElement;if(i){return t.domConverter.mapViewToDom(i.root)}return null};this.set(\"visibleView\",null);this.view=new Zy(t.locale);t.ui.view.body.add(this.view);t.ui.focusTracker.add(this.view.element);this._viewToStack=new Map;this._idToStack=new Map;this.set(\"_numberOfStacks\",0);this.set(\"_singleViewMode\",false);this._rotatorView=this._createRotatorView();this._fakePanelsView=this._createFakePanelsView()}hasView(t){return Array.from(this._viewToStack.keys()).includes(t)}add(t){if(this.hasView(t.view)){throw new ss[\"b\"](\"contextualballoon-add-view-exist: Cannot add configuration of the same view twice.\",[this,t])}const e=t.stackId||\"main\";if(!this._idToStack.has(e)){this._idToStack.set(e,new Map([[t.view,t]]));this._viewToStack.set(t.view,this._idToStack.get(e));this._numberOfStacks=this._idToStack.size;if(!this._visibleStack||t.singleViewMode){this.showStack(e)}return}const i=this._idToStack.get(e);if(t.singleViewMode){this.showStack(e)}i.set(t.view,t);this._viewToStack.set(t.view,i);if(i===this._visibleStack){this._showView(t)}}remove(t){if(!this.hasView(t)){throw new ss[\"b\"](\"contextualballoon-remove-view-not-exist: Cannot remove the configuration of a non-existent view.\",[this,t])}const e=this._viewToStack.get(t);if(this._singleViewMode&&this.visibleView===t){this._singleViewMode=false}if(this.visibleView===t){if(e.size===1){if(this._idToStack.size>1){this._showNextStack()}else{this.view.hide();this.visibleView=null;this._rotatorView.hideView()}}else{this._showView(Array.from(e.values())[e.size-2])}}if(e.size===1){this._idToStack.delete(this._getStackId(e));this._numberOfStacks=this._idToStack.size}else{e.delete(t)}this._viewToStack.delete(t)}updatePosition(t){if(t){this._visibleStack.get(this.visibleView).position=t}this.view.pin(this._getBalloonPosition());this._fakePanelsView.updatePosition()}showStack(t){this.visibleStack=t;const e=this._idToStack.get(t);if(!e){throw new ss[\"b\"](\"contextualballoon-showstack-stack-not-exist: Cannot show a stack that does not exist.\",this)}if(this._visibleStack===e){return}this._showView(Array.from(e.values()).pop())}get _visibleStack(){return this._viewToStack.get(this.visibleView)}_getStackId(t){const e=Array.from(this._idToStack.entries()).find(e=>e[1]===t);return e[0]}_showNextStack(){const t=Array.from(this._idToStack.values());let e=t.indexOf(this._visibleStack)+1;if(!t[e]){e=0}this.showStack(this._getStackId(t[e]))}_showPrevStack(){const t=Array.from(this._idToStack.values());let e=t.indexOf(this._visibleStack)-1;if(!t[e]){e=t.length-1}this.showStack(this._getStackId(t[e]))}_createRotatorView(){const t=new FA(this.editor.locale);const e=this.editor.locale.t;this.view.content.add(t);t.bind(\"isNavigationVisible\").to(this,\"_numberOfStacks\",this,\"_singleViewMode\",(t,e)=>!e&&t>1);t.on(\"change:isNavigationVisible\",()=>this.updatePosition(),{priority:\"low\"});t.bind(\"counter\").to(this,\"visibleView\",this,\"_numberOfStacks\",(t,i)=>{if(i<2){return\"\"}const n=Array.from(this._idToStack.values()).indexOf(this._visibleStack)+1;return e(\"%0 of %1\",[n,i])});t.buttonNextView.on(\"execute\",()=>{if(t.focusTracker.isFocused){this.editor.editing.view.focus()}this._showNextStack()});t.buttonPrevView.on(\"execute\",()=>{if(t.focusTracker.isFocused){this.editor.editing.view.focus()}this._showPrevStack()});return t}_createFakePanelsView(){const t=new jA(this.editor.locale,this.view);t.bind(\"numberOfPanels\").to(this,\"_numberOfStacks\",this,\"_singleViewMode\",(t,e)=>{const i=!e&&t>=2;return i?Math.min(t-1,2):0});t.listenTo(this.view,\"change:top\",()=>t.updatePosition());t.listenTo(this.view,\"change:left\",()=>t.updatePosition());this.editor.ui.view.body.add(t);return t}_showView({view:t,balloonClassName:e=\"\",withArrow:i=true,singleViewMode:n=false}){this.view.class=e;this.view.withArrow=i;this._rotatorView.showView(t);this.visibleView=t;this.view.pin(this._getBalloonPosition());this._fakePanelsView.updatePosition();if(n){this._singleViewMode=true}}_getBalloonPosition(){let t=Array.from(this._visibleStack.values()).pop().position;if(t&&!t.limiter){t=Object.assign({},t,{limiter:this.positionLimiter})}return t}}class FA extends _b{constructor(t){super(t);const e=t.t;const i=this.bindTemplate;this.set(\"isNavigationVisible\",true);this.focusTracker=new Pp;this.buttonPrevView=this._createButtonView(e(\"Previous\"),LA);this.buttonNextView=this._createButtonView(e(\"Next\"),NA);this.content=this.createCollection();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-balloon-rotator\"],\"z-index\":\"-1\"},children:[{tag:\"div\",attributes:{class:[\"ck-balloon-rotator__navigation\",i.to(\"isNavigationVisible\",t=>t?\"\":\"ck-hidden\")]},children:[this.buttonPrevView,{tag:\"span\",attributes:{class:[\"ck-balloon-rotator__counter\"]},children:[{text:i.to(\"counter\")}]},this.buttonNextView]},{tag:\"div\",attributes:{class:\"ck-balloon-rotator__content\"},children:this.content}]})}render(){super.render();this.focusTracker.add(this.element)}showView(t){this.hideView();this.content.add(t)}hideView(){this.content.clear()}_createButtonView(t,e){const i=new rw(this.locale);i.set({label:t,icon:e,tooltip:true});return i}}class jA extends _b{constructor(t,e){super(t);const i=this.bindTemplate;this.set(\"top\",0);this.set(\"left\",0);this.set(\"height\",0);this.set(\"width\",0);this.set(\"numberOfPanels\",0);this.content=this.createCollection();this._balloonPanelView=e;this.setTemplate({tag:\"div\",attributes:{class:[\"ck-fake-panel\",i.to(\"numberOfPanels\",t=>t?\"\":\"ck-hidden\")],style:{top:i.to(\"top\",DA),left:i.to(\"left\",DA),width:i.to(\"width\",DA),height:i.to(\"height\",DA)}},children:this.content});this.on(\"change:numberOfPanels\",(t,e,i,n)=>{if(i>n){this._addPanels(i-n)}else{this._removePanels(n-i)}this.updatePosition()})}_addPanels(t){while(t--){const t=new _b;t.setTemplate({tag:\"div\"});this.content.add(t);this.registerChild(t)}}_removePanels(t){while(t--){const t=this.content.last;this.content.remove(t);this.deregisterChild(t);t.destroy()}}updatePosition(){if(this.numberOfPanels){const{top:t,left:e}=this._balloonPanelView;const{width:i,height:n}=new vh(this._balloonPanelView.element);Object.assign(this,{top:t,left:e,width:i,height:n})}}}var HA=i(73);class WA extends _b{constructor(t,e){super(t);const i=`ck-labeled-field-view-${is()}`;const n=`ck-labeled-field-view-status-${is()}`;this.fieldView=e(this,i,n);this.set(\"label\");this.set(\"isEnabled\",true);this.set(\"errorText\",null);this.set(\"infoText\",null);this.set(\"class\");this.labelView=this._createLabelView(i);this.statusView=this._createStatusView(n);this.bind(\"_statusText\").to(this,\"errorText\",this,\"infoText\",(t,e)=>t||e);const o=this.bindTemplate;this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-labeled-field-view\",o.to(\"class\"),o.if(\"isEnabled\",\"ck-disabled\",t=>!t)]},children:[this.labelView,this.fieldView,this.statusView]})}_createLabelView(t){const e=new Eb(this.locale);e.for=t;e.bind(\"text\").to(this,\"label\");return e}_createStatusView(t){const e=new _b(this.locale);const i=this.bindTemplate;e.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-labeled-field-view__status\",i.if(\"errorText\",\"ck-labeled-field-view__status_error\"),i.if(\"_statusText\",\"ck-hidden\",t=>!t)],id:t,role:i.if(\"errorText\",\"alert\")},children:[{text:i.to(\"_statusText\")}]});return e}focus(){this.fieldView.focus()}}var qA=i(75);class $A extends _b{constructor(t){super(t);this.set(\"value\");this.set(\"id\");this.set(\"placeholder\");this.set(\"isReadOnly\",false);this.set(\"hasError\",false);this.set(\"ariaDescribedById\");const e=this.bindTemplate;this.setTemplate({tag:\"input\",attributes:{type:\"text\",class:[\"ck\",\"ck-input\",\"ck-input-text\",e.if(\"hasError\",\"ck-error\")],id:e.to(\"id\"),placeholder:e.to(\"placeholder\"),readonly:e.to(\"isReadOnly\"),\"aria-invalid\":e.if(\"hasError\",true),\"aria-describedby\":e.to(\"ariaDescribedById\")},on:{input:e.to(\"input\")}})}render(){super.render();const t=t=>{this.element.value=!t&&t!==0?\"\":t};t(this.value);this.on(\"change:value\",(e,i,n)=>{t(n)})}select(){this.element.select()}focus(){this.element.focus()}}function UA(t,e,i){const n=new $A(t.locale);n.set({id:e,ariaDescribedById:i});n.bind(\"isReadOnly\").to(t,\"isEnabled\",t=>!t);n.bind(\"hasError\").to(t,\"errorText\",t=>!!t);n.on(\"input\",()=>{t.errorText=null});return n}function GA(t,e,i){const n=bw(t.locale);n.set({id:e,ariaDescribedById:i});n.bind(\"isEnabled\").to(t);return n}function JA({view:t}){t.listenTo(t.element,\"submit\",(e,i)=>{i.preventDefault();t.fire(\"submit\")},{useCapture:true})}var KA='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M6.972 16.615a.997.997 0 0 1-.744-.292l-4.596-4.596a1 1 0 1 1 1.414-1.414l3.926 3.926 9.937-9.937a1 1 0 0 1 1.414 1.415L7.717 16.323a.997.997 0 0 1-.745.292z\"/></svg>';var XA='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.591 10.177l4.243 4.242a1 1 0 0 1-1.415 1.415l-4.242-4.243-4.243 4.243a1 1 0 0 1-1.414-1.415l4.243-4.242L4.52 5.934A1 1 0 0 1 5.934 4.52l4.243 4.243 4.242-4.243a1 1 0 1 1 1.415 1.414l-4.243 4.243z\"/></svg>';var YA=i(77);class QA extends _b{constructor(t,e){super(t);const i=t.t;this.focusTracker=new Pp;this.keystrokes=new mp;this.urlInputView=this._createUrlInput();this.saveButtonView=this._createButton(i(\"Save\"),KA,\"ck-button-save\");this.saveButtonView.type=\"submit\";this.cancelButtonView=this._createButton(i(\"Cancel\"),XA,\"ck-button-cancel\",\"cancel\");this._manualDecoratorSwitches=this._createManualDecoratorSwitches(e);this.children=this._createFormChildren(e.manualDecorators);this._focusables=new Wp;this._focusCycler=new Bb({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"shift + tab\",focusNext:\"tab\"}});const n=[\"ck\",\"ck-link-form\"];if(e.manualDecorators.length){n.push(\"ck-link-form_layout-vertical\")}this.setTemplate({tag:\"form\",attributes:{class:n,tabindex:\"-1\"},children:this.children})}getDecoratorSwitchesState(){return Array.from(this._manualDecoratorSwitches).reduce((t,e)=>{t[e.name]=e.isOn;return t},{})}render(){super.render();JA({view:this});const t=[this.urlInputView,...this._manualDecoratorSwitches,this.saveButtonView,this.cancelButtonView];t.forEach(t=>{this._focusables.add(t);this.focusTracker.add(t.element)});this.keystrokes.listenTo(this.element)}focus(){this._focusCycler.focusFirst()}_createUrlInput(){const t=this.locale.t;const e=new WA(this.locale,UA);e.label=t(\"Link URL\");e.fieldView.placeholder=\"https://example.com\";return e}_createButton(t,e,i,n){const o=new rw(this.locale);o.set({label:t,icon:e,tooltip:true});o.extendTemplate({attributes:{class:i}});if(n){o.delegate(\"execute\").to(this,n)}return o}_createManualDecoratorSwitches(t){const e=this.createCollection();for(const i of t.manualDecorators){const n=new fw(this.locale);n.set({name:i.id,label:i.label,withText:true});n.bind(\"isOn\").toMany([i,t],\"value\",(t,e)=>e===undefined&&t===undefined?i.defaultValue:t);n.on(\"execute\",()=>{i.set(\"value\",!n.isOn)});e.add(n)}return e}_createFormChildren(t){const e=this.createCollection();e.add(this.urlInputView);if(t.length){const t=new _b;t.setTemplate({tag:\"ul\",children:this._manualDecoratorSwitches.map(t=>({tag:\"li\",children:[t],attributes:{class:[\"ck\",\"ck-list__item\"]}})),attributes:{class:[\"ck\",\"ck-reset\",\"ck-list\"]}});e.add(t)}e.add(this.saveButtonView);e.add(this.cancelButtonView);return e}}var ZA='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.077 15l.991-1.416a.75.75 0 1 1 1.229.86l-1.148 1.64a.748.748 0 0 1-.217.206 5.251 5.251 0 0 1-8.503-5.955.741.741 0 0 1 .12-.274l1.147-1.639a.75.75 0 1 1 1.228.86L4.933 10.7l.006.003a3.75 3.75 0 0 0 6.132 4.294l.006.004zm5.494-5.335a.748.748 0 0 1-.12.274l-1.147 1.639a.75.75 0 1 1-1.228-.86l.86-1.23a3.75 3.75 0 0 0-6.144-4.301l-.86 1.229a.75.75 0 0 1-1.229-.86l1.148-1.64a.748.748 0 0 1 .217-.206 5.251 5.251 0 0 1 8.503 5.955zm-4.563-2.532a.75.75 0 0 1 .184 1.045l-3.155 4.505a.75.75 0 1 1-1.229-.86l3.155-4.506a.75.75 0 0 1 1.045-.184zm4.919 10.562l-1.414 1.414a.75.75 0 1 1-1.06-1.06l1.414-1.415-1.415-1.414a.75.75 0 0 1 1.061-1.06l1.414 1.414 1.414-1.415a.75.75 0 0 1 1.061 1.061l-1.414 1.414 1.414 1.415a.75.75 0 0 1-1.06 1.06l-1.415-1.414z\"/></svg>';var tT='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M7.3 17.37l-.061.088a1.518 1.518 0 0 1-.934.535l-4.178.663-.806-4.153a1.495 1.495 0 0 1 .187-1.058l.056-.086L8.77 2.639c.958-1.351 2.803-1.076 4.296-.03 1.497 1.047 2.387 2.693 1.433 4.055L7.3 17.37zM9.14 4.728l-5.545 8.346 3.277 2.294 5.544-8.346L9.14 4.728zM6.07 16.512l-3.276-2.295.53 2.73 2.746-.435zM9.994 3.506L13.271 5.8c.316-.452-.16-1.333-1.065-1.966-.905-.634-1.895-.78-2.212-.328zM8 18.5L9.375 17H19v1.5H8z\"/></svg>';var eT=i(79);class iT extends _b{constructor(t){super(t);const e=t.t;this.focusTracker=new Pp;this.keystrokes=new mp;this.previewButtonView=this._createPreviewButton();this.unlinkButtonView=this._createButton(e(\"Unlink\"),ZA,\"unlink\");this.editButtonView=this._createButton(e(\"Edit link\"),tT,\"edit\");this.set(\"href\");this._focusables=new Wp;this._focusCycler=new Bb({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"shift + tab\",focusNext:\"tab\"}});this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-link-actions\"],tabindex:\"-1\"},children:[this.previewButtonView,this.editButtonView,this.unlinkButtonView]})}render(){super.render();const t=[this.previewButtonView,this.editButtonView,this.unlinkButtonView];t.forEach(t=>{this._focusables.add(t);this.focusTracker.add(t.element)});this.keystrokes.listenTo(this.element)}focus(){this._focusCycler.focusFirst()}_createButton(t,e,i){const n=new rw(this.locale);n.set({label:t,icon:e,tooltip:true});n.delegate(\"execute\").to(this,i);return n}_createPreviewButton(){const t=new rw(this.locale);const e=this.bindTemplate;const i=this.t;t.set({withText:true,tooltip:i(\"Open link in new tab\")});t.extendTemplate({attributes:{class:[\"ck\",\"ck-link-actions__preview\"],href:e.to(\"href\",t=>t&&mA(t)),target:\"_blank\",rel:\"noopener noreferrer\"}});t.bind(\"label\").to(this,\"href\",t=>t||i(\"This link has no URL\"));t.bind(\"isEnabled\").to(this,\"href\",t=>!!t);t.template.tag=\"a\";t.template.eventListeners={};return t}}var nT='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.077 15l.991-1.416a.75.75 0 1 1 1.229.86l-1.148 1.64a.748.748 0 0 1-.217.206 5.251 5.251 0 0 1-8.503-5.955.741.741 0 0 1 .12-.274l1.147-1.639a.75.75 0 1 1 1.228.86L4.933 10.7l.006.003a3.75 3.75 0 0 0 6.132 4.294l.006.004zm5.494-5.335a.748.748 0 0 1-.12.274l-1.147 1.639a.75.75 0 1 1-1.228-.86l.86-1.23a3.75 3.75 0 0 0-6.144-4.301l-.86 1.229a.75.75 0 0 1-1.229-.86l1.148-1.64a.748.748 0 0 1 .217-.206 5.251 5.251 0 0 1 8.503 5.955zm-4.563-2.532a.75.75 0 0 1 .184 1.045l-3.155 4.505a.75.75 0 1 1-1.229-.86l3.155-4.506a.75.75 0 0 1 1.045-.184z\"/></svg>';const oT=\"Ctrl+K\";class rT extends Nw{static get requires(){return[zA]}static get pluginName(){return\"LinkUI\"}init(){const t=this.editor;t.editing.view.addObserver(RA);this.actionsView=this._createActionsView();this.formView=this._createFormView();this._balloon=t.plugins.get(zA);this._createToolbarLinkButton();this._enableUserBalloonInteractions()}destroy(){super.destroy();this.formView.destroy()}_createActionsView(){const t=this.editor;const e=new iT(t.locale);const i=t.commands.get(\"link\");const n=t.commands.get(\"unlink\");e.bind(\"href\").to(i,\"value\");e.editButtonView.bind(\"isEnabled\").to(i);e.unlinkButtonView.bind(\"isEnabled\").to(n);this.listenTo(e,\"edit\",()=>{this._addFormView()});this.listenTo(e,\"unlink\",()=>{t.execute(\"unlink\");this._hideUI()});e.keystrokes.set(\"Esc\",(t,e)=>{this._hideUI();e()});e.keystrokes.set(oT,(t,e)=>{this._addFormView();e()});return e}_createFormView(){const t=this.editor;const e=t.commands.get(\"link\");const i=new QA(t.locale,e);i.urlInputView.fieldView.bind(\"value\").to(e,\"value\");i.urlInputView.bind(\"isReadOnly\").to(e,\"isEnabled\",t=>!t);i.saveButtonView.bind(\"isEnabled\").to(e);this.listenTo(i,\"submit\",()=>{t.execute(\"link\",i.urlInputView.fieldView.element.value,i.getDecoratorSwitchesState());this._closeFormView()});this.listenTo(i,\"cancel\",()=>{this._closeFormView()});i.keystrokes.set(\"Esc\",(t,e)=>{this._closeFormView();e()});return i}_createToolbarLinkButton(){const t=this.editor;const e=t.commands.get(\"link\");const i=t.t;t.keystrokes.set(oT,(t,e)=>{e();this._showUI(true)});t.ui.componentFactory.add(\"link\",t=>{const n=new rw(t);n.isEnabled=true;n.label=i(\"Link\");n.icon=nT;n.keystroke=oT;n.tooltip=true;n.isToggleable=true;n.bind(\"isEnabled\").to(e,\"isEnabled\");n.bind(\"isOn\").to(e,\"value\",t=>!!t);this.listenTo(n,\"execute\",()=>this._showUI(true));return n})}_enableUserBalloonInteractions(){const t=this.editor.editing.view.document;this.listenTo(t,\"click\",()=>{const t=this._getSelectedLinkElement();if(t){this._showUI()}});this.editor.keystrokes.set(\"Tab\",(t,e)=>{if(this._areActionsVisible&&!this.actionsView.focusTracker.isFocused){this.actionsView.focus();e()}},{priority:\"high\"});this.editor.keystrokes.set(\"Esc\",(t,e)=>{if(this._isUIVisible){this._hideUI();e()}});mw({emitter:this.formView,activator:()=>this._isUIInPanel,contextElements:[this._balloon.view.element],callback:()=>this._hideUI()})}_addActionsView(){if(this._areActionsInPanel){return}this._balloon.add({view:this.actionsView,position:this._getBalloonPositionData()})}_addFormView(){if(this._isFormInPanel){return}const t=this.editor;const e=t.commands.get(\"link\");this._balloon.add({view:this.formView,position:this._getBalloonPositionData()});if(this._balloon.visibleView===this.formView){this.formView.urlInputView.fieldView.select()}this.formView.urlInputView.fieldView.element.value=e.value||\"\"}_closeFormView(){const t=this.editor.commands.get(\"link\");t.restoreManualDecoratorStates();if(t.value!==undefined){this._removeFormView()}else{this._hideUI()}}_removeFormView(){if(this._isFormInPanel){this.formView.saveButtonView.focus();this._balloon.remove(this.formView);this.editor.editing.view.focus()}}_showUI(t=false){if(!this._getSelectedLinkElement()){this._addActionsView();if(t){this._balloon.showStack(\"main\")}this._addFormView()}else{if(this._areActionsVisible){this._addFormView()}else{this._addActionsView()}if(t){this._balloon.showStack(\"main\")}}this._startUpdatingUI()}_hideUI(){if(!this._isUIInPanel){return}const t=this.editor;this.stopListening(t.ui,\"update\");this.stopListening(this._balloon,\"change:visibleView\");t.editing.view.focus();this._removeFormView();this._balloon.remove(this.actionsView)}_startUpdatingUI(){const t=this.editor;const e=t.editing.view.document;let i=this._getSelectedLinkElement();let n=r();const o=()=>{const t=this._getSelectedLinkElement();const e=r();if(i&&!t||!i&&e!==n){this._hideUI()}else if(this._isUIVisible){this._balloon.updatePosition(this._getBalloonPositionData())}i=t;n=e};function r(){return e.selection.focus.getAncestors().reverse().find(t=>t.is(\"element\"))}this.listenTo(t.ui,\"update\",o);this.listenTo(this._balloon,\"change:visibleView\",o)}get _isFormInPanel(){return this._balloon.hasView(this.formView)}get _areActionsInPanel(){return this._balloon.hasView(this.actionsView)}get _areActionsVisible(){return this._balloon.visibleView===this.actionsView}get _isUIInPanel(){return this._isFormInPanel||this._areActionsInPanel}get _isUIVisible(){const t=this._balloon.visibleView;return t==this.formView||this._areActionsVisible}_getBalloonPositionData(){const t=this.editor.editing.view;const e=t.document;const i=this._getSelectedLinkElement();const n=i?t.domConverter.mapViewToDom(i):t.domConverter.viewRangeToDom(e.selection.getFirstRange());return{target:n}}_getSelectedLinkElement(){const t=this.editor.editing.view;const e=t.document.selection;if(e.isCollapsed){return sT(e.getFirstPosition())}else{const i=e.getFirstRange().getTrimmed();const n=sT(i.start);const o=sT(i.end);if(!n||n!=o){return null}if(t.createRangeIn(n).getTrimmed().isEqual(i)){return n}else{return null}}}}function sT(t){return t.getAncestors().find(t=>hA(t))}class aT extends Nw{static get requires(){return[IA,rT]}static get pluginName(){return\"Link\"}}class lT{constructor(t,e={}){this.namespaces=e.namespaces||[];this._domParser=new DOMParser;this._domConverter=new Vd(t,{blockFillerMode:\"nbsp\"});this._htmlWriter=new xp}toData(t){const e=this._domConverter.viewToDom(t,document);return this._htmlWriter.getHtml(e)}toView(t){const e=this._toDom(t);return this._domConverter.domToView(e,{keepOriginalCase:true})}_toDom(t){const e=this.namespaces.map(t=>`xmlns:${t}=\"nsp\"`).join(\" \");t=`<xml ${e}>${t}</xml>`;const i=this._domParser.parseFromString(t,\"text/xml\");const n=i.querySelector(\"parsererror\");if(n){throw new Error(\"Parse error - \"+n.textContent)}const o=i.createDocumentFragment();const r=i.documentElement.childNodes;while(r.length>0){o.appendChild(r[0])}return o}}class cT{constructor(t){this.document=t}createDocumentFragment(t){return new qc(this.document,t)}createElement(t,e,i){return new Dl(this.document,t,e,i)}createText(t){return new Fs(this.document,t)}clone(t,e=false){return t._clone(e)}appendChild(t,e){return e._appendChild(t)}insertChild(t,e,i){return i._insertChild(t,e)}removeChildren(t,e,i){return i._removeChildren(t,e)}remove(t){const e=t.parent;if(e){return this.removeChildren(e.getChildIndex(t),1,e)}return[]}replace(t,e){const i=t.parent;if(i){const n=i.getChildIndex(t);this.removeChildren(n,1,i);this.insertChild(n,e,i);return true}return false}unwrapElement(t){const e=t.parent;if(e){const i=e.getChildIndex(t);this.remove(t);this.insertChild(i,t.getChildren(),e)}}rename(t,e){const i=new Dl(this.document,t,e.getAttributes(),e.getChildren());return this.replace(e,i)?i:null}setAttribute(t,e,i){i._setAttribute(t,e)}removeAttribute(t,e){e._removeAttribute(t)}addClass(t,e){e._addClass(t)}removeClass(t,e){e._removeClass(t)}setStyle(t,e,i){if(L(t)&&i===undefined){i=e}i._setStyle(t,e)}removeStyle(t,e){e._removeStyle(t)}setCustomProperty(t,e,i){i._setCustomProperty(t,e)}removeCustomProperty(t,e){return e._removeCustomProperty(t)}createPositionAt(t,e){return uc._createAt(t,e)}createPositionAfter(t){return uc._createAfter(t)}createPositionBefore(t){return uc._createBefore(t)}createRange(t,e){return new hc(t,e)}createRangeOn(t){return hc._createOn(t)}createRangeIn(t){return hc._createIn(t)}createSelection(t,e,i){return new gc(t,e,i)}}class dT extends Ku{constructor(t){super(t);this.domEventType=\"mousedown\"}onDomEvent(t){this.fire(t.type,t)}}function uT(t,e,i){return t&&sx(t)&&!i.isInline(e)}function hT(t){return t.closest(\".ck-widget__type-around__button\")}function fT(t){return t.classList.contains(\"ck-widget__type-around__button_before\")?\"before\":\"after\"}function mT(t,e){const i=t.closest(\".ck-widget\");return e.mapDomToView(i)}function gT(t){const e=[];if(pT(t)||wT(t)){e.push(\"before\")}if(bT(t)||_T(t)){e.push(\"after\")}return e}function pT(t){return!t.previousSibling}function bT(t){return!t.nextSibling}function wT(t){return t.previousSibling&&sx(t.previousSibling)}function _T(t){return t.nextSibling&&sx(t.nextSibling)}var kT='<svg viewBox=\"0 0 10 8\" xmlns=\"http://www.w3.org/2000/svg\"><polyline points=\"8.05541992 0.263427734 8.05541992 4.23461914 1.28417969 4.23461914\" transform=\"translate(1,0)\"></polyline><line x1=\"0\" y1=\"4.21581031\" x2=\"2\" y2=\"2.17810059\" transform=\"translate(1, 0)\"></line><line x1=\"0\" y1=\"6.21581031\" x2=\"2\" y2=\"4.17810059\" transform=\"translate(2, 5.196955) scale(1, -1) translate(-1, -5.196955)\"></line></svg>\\n';var vT=i(81);const yT=[\"before\",\"after\"];const xT=(new DOMParser).parseFromString(kT,\"image/svg+xml\").firstChild;class CT extends Nw{static get requires(){return[Ay]}static get pluginName(){return\"WidgetTypeAround\"}constructor(t){super(t);this._widgetsWithTypeAroundUI=new Set}destroy(){this._widgetsWithTypeAroundUI.clear()}init(){this._enableTypeAroundUIInjection();this._enableDetectionOfTypeAroundWidgets();this._enableInsertingParagraphsOnButtonClick()}_insertParagraph(t,e){const i=this.editor;const n=i.editing.view;const o=i.editing.mapper.toModelElement(t);let r;if(e===\"before\"){r=i.model.createPositionBefore(o)}else{r=i.model.createPositionAfter(o)}i.execute(\"insertParagraph\",{position:r});n.focus();n.scrollToTheSelection()}_enableTypeAroundUIInjection(){const t=this.editor;const e=t.model.schema;const i=t.locale.t;const n={before:i(\"Insert paragraph before block\"),after:i(\"Insert paragraph after block\")};t.editing.downcastDispatcher.on(\"insert\",(t,i,o)=>{const r=o.mapper.toViewElement(i.item);if(uT(r,i.item,e)){AT(o.writer,n,r);this._widgetsWithTypeAroundUI.add(r)}},{priority:\"low\"})}_enableDetectionOfTypeAroundWidgets(){const t=this.editor;const e=t.editing.view;function i(t){return`ck-widget_can-type-around_${t}`}e.document.registerPostFixer(t=>{for(const e of this._widgetsWithTypeAroundUI){if(!e.isAttached()){this._widgetsWithTypeAroundUI.delete(e)}else{const n=gT(e);t.removeClass(yT.map(i),e);t.addClass(n.map(i),e)}}})}_enableInsertingParagraphsOnButtonClick(){const t=this.editor;const e=t.editing.view;e.document.on(\"mousedown\",(t,i)=>{const n=hT(i.domTarget);if(!n){return}const o=fT(n);const r=mT(n,e.domConverter);this._insertParagraph(r,o);i.preventDefault();t.stop()})}}function AT(t,e,i){const n=t.createUIElement(\"div\",{class:\"ck ck-reset_all ck-widget__type-around\"},(function(t){const i=this.toDomElement(t);TT(i,e);return i}));t.insert(t.createPositionAt(i,\"end\"),n)}function TT(t,e){for(const i of yT){const n=new Up({tag:\"div\",attributes:{class:[\"ck\",\"ck-widget__type-around__button\",`ck-widget__type-around__button_${i}`],title:e[i]},children:[t.ownerDocument.importNode(xT,true)]});t.appendChild(n.render())}}var PT=i(83);class ET extends Nw{static get pluginName(){return\"Widget\"}static get requires(){return[CT]}init(){const t=this.editor.editing.view;const e=t.document;this._previouslySelected=new Set;this.editor.editing.downcastDispatcher.on(\"selection\",(t,e,i)=>{this._clearPreviouslySelectedWidgets(i.writer);const n=i.writer;const o=n.document.selection;const r=o.getSelectedElement();let s=null;for(const t of o.getRanges()){for(const e of t){const t=e.item;if(sx(t)&&!OT(t,s)){n.addClass(rx,t);this._previouslySelected.add(t);s=t;if(t==r){n.setSelection(o.getRanges(),{fake:true,label:dx(r)})}}}}},{priority:\"low\"});t.addObserver(dT);this.listenTo(e,\"mousedown\",(...t)=>this._onMousedown(...t));this.listenTo(e,\"keydown\",(...t)=>this._onKeydown(...t),{priority:\"high\"});this.listenTo(e,\"delete\",(t,e)=>{if(this._handleDelete(e.direction==\"forward\")){e.preventDefault();t.stop()}},{priority:\"high\"})}_onMousedown(t,e){const i=this.editor;const n=i.editing.view;const o=n.document;let r=e.target;if(MT(r)){if(Tc.isSafari&&e.domEvent.detail>=3){const t=i.editing.mapper;const n=t.toModelElement(r);this.editor.model.change(t=>{e.preventDefault();t.setSelection(n,\"in\")})}return}if(!sx(r)){r=r.findAncestor(sx);if(!r){return}}e.preventDefault();if(!o.isFocused){n.focus()}const s=i.editing.mapper.toModelElement(r);this._setSelectionOverElement(s)}_onKeydown(t,e){const i=e.keyCode;const n=this.editor.locale.contentLanguageDirection===\"ltr\";const o=i==Lc.arrowdown||i==Lc[n?\"arrowright\":\"arrowleft\"];let r=false;if(ST(i)){r=this._handleArrowKeys(o)}else if(i===Lc.enter){r=this._handleEnterKey(e.shiftKey)}if(r){e.preventDefault();t.stop()}}_handleDelete(t){if(this.editor.isReadOnly){return}const e=this.editor.model.document;const i=e.selection;if(!i.isCollapsed){return}const n=this._getObjectElementNextToSelection(t);if(n){this.editor.model.change(t=>{let e=i.anchor.parent;while(e.isEmpty){const i=e;e=i.parent;t.remove(i)}this._setSelectionOverElement(n)});return true}}_handleArrowKeys(t){const e=this.editor.model;const i=e.schema;const n=e.document;const o=n.selection;const r=o.getSelectedElement();if(r&&i.isObject(r)){const n=t?o.getLastPosition():o.getFirstPosition();const r=i.getNearestSelectionRange(n,t?\"forward\":\"backward\");if(r){e.change(t=>{t.setSelection(r)})}return true}if(!o.isCollapsed){return}const s=this._getObjectElementNextToSelection(t);if(!!s&&i.isObject(s)){this._setSelectionOverElement(s);return true}}_handleEnterKey(t){const e=this.editor.model;const i=e.document.selection;const n=i.getSelectedElement();if(IT(n,e.schema)){e.change(i=>{let o=i.createPositionAt(n,t?\"before\":\"after\");const r=i.createElement(\"paragraph\");if(e.schema.isBlock(n.parent)){const t=e.schema.findAllowedParent(o,r);o=i.split(o,t).position}i.insert(r,o);i.setSelection(r,\"in\")});return true}}_setSelectionOverElement(t){this.editor.model.change(e=>{e.setSelection(e.createRangeOn(t))})}_getObjectElementNextToSelection(t){const e=this.editor.model;const i=e.schema;const n=e.document.selection;const o=e.createSelection(n);e.modifySelection(o,{direction:t?\"forward\":\"backward\"});const r=t?o.focus.nodeBefore:o.focus.nodeAfter;if(!!r&&i.isObject(r)){return r}return null}_clearPreviouslySelectedWidgets(t){for(const e of this._previouslySelected){t.removeClass(rx,e)}this._previouslySelected.clear()}}function ST(t){return t==Lc.arrowright||t==Lc.arrowleft||t==Lc.arrowup||t==Lc.arrowdown}function MT(t){while(t){if(t.is(\"editableElement\")&&!t.is(\"rootElement\")){return true}if(sx(t)){return false}t=t.parent}return false}function OT(t,e){if(!e){return false}return Array.from(t.getAncestors()).includes(e)}function IT(t,e){return t&&e.isObject(t)&&!e.isInline(t)}class RT{static get safeXmlCharactersEntities(){return{tagOpener:\"&laquo;\",tagCloser:\"&raquo;\",doubleQuote:\"&uml;\",realDoubleQuote:\"&quot;\"}}static get safeBadBlackboardCharacters(){return{ltElement:\"«mo»<«/mo»\",gtElement:\"«mo»>«/mo»\",ampElement:\"«mo»&«/mo»\"}}static get safeGoodBlackboardCharacters(){return{ltElement:\"«mo»§lt;«/mo»\",gtElement:\"«mo»§gt;«/mo»\",ampElement:\"«mo»§amp;«/mo»\"}}static get xmlCharacters(){return{id:\"xmlCharacters\",tagOpener:\"<\",tagCloser:\">\",doubleQuote:'\"',ampersand:\"&\",quote:\"'\"}}static get safeXmlCharacters(){return{id:\"safeXmlCharacters\",tagOpener:\"«\",tagCloser:\"»\",doubleQuote:\"¨\",ampersand:\"§\",quote:\"`\",realDoubleQuote:\"¨\"}}}class LT{static isMathmlInAttribute(t,e){const i=\"['\\\"][\\\\s]*=[\\\\s]*[\\\\w-]+\";const n=\"\\\"[^\\\"]*\\\"|'[^']*'\";const o=`[\\\\s]*(${n})[\\\\s]*=[\\\\s]*[\\\\w-]+[\\\\s]*`;const r=`('${o}')*`;const s=`^${i}${r}[\\\\s]+gmi<`;const a=new RegExp(s);const l=t.substring(0,e);const c=l.split(\"\").reverse().join(\"\");const d=a.test(c);return d}static safeXmlDecode(t){let{tagOpener:e}=RT.safeXmlCharactersEntities;let{tagCloser:i}=RT.safeXmlCharactersEntities;let{doubleQuote:n}=RT.safeXmlCharactersEntities;let{realDoubleQuote:o}=RT.safeXmlCharactersEntities;t=t.split(e).join(RT.safeXmlCharacters.tagOpener);t=t.split(i).join(RT.safeXmlCharacters.tagCloser);t=t.split(n).join(RT.safeXmlCharacters.doubleQuote);t=t.split(o).join(RT.safeXmlCharacters.realDoubleQuote);const{ltElement:r}=RT.safeBadBlackboardCharacters;const{gtElement:s}=RT.safeBadBlackboardCharacters;const{ampElement:a}=RT.safeBadBlackboardCharacters;if(\"_wrs_blackboard\"in window&&window._wrs_blackboard){t=t.split(r).join(RT.safeGoodBlackboardCharacters.ltElement);t=t.split(s).join(RT.safeGoodBlackboardCharacters.gtElement);t=t.split(a).join(RT.safeGoodBlackboardCharacters.ampElement)}({tagOpener:e}=RT.safeXmlCharacters);({tagCloser:i}=RT.safeXmlCharacters);({doubleQuote:n}=RT.safeXmlCharacters);({realDoubleQuote:o}=RT.safeXmlCharacters);const{ampersand:l}=RT.safeXmlCharacters;const{quote:c}=RT.safeXmlCharacters;t=t.split(e).join(RT.xmlCharacters.tagOpener);t=t.split(i).join(RT.xmlCharacters.tagCloser);t=t.split(n).join(RT.xmlCharacters.doubleQuote);t=t.split(l).join(RT.xmlCharacters.ampersand);t=t.split(c).join(RT.xmlCharacters.quote);let d=\"\";let u=null;for(let e=0;e<t.length;e+=1){const i=t.charAt(e);if(u==null){if(i===\"$\"){u=\"\"}else{d+=i}}else if(i===\";\"){d+=`&${u}`;u=null}else if(i.match(/([a-zA-Z0-9#._-] | '-')/)){u+=i}else{d+=`$${u}`;u=null;e-=1}}return d}static safeXmlEncode(t){const{tagOpener:e}=RT.xmlCharacters;const{tagCloser:i}=RT.xmlCharacters;const{doubleQuote:n}=RT.xmlCharacters;const{ampersand:o}=RT.xmlCharacters;const{quote:r}=RT.xmlCharacters;t=t.split(e).join(RT.safeXmlCharacters.tagOpener);t=t.split(i).join(RT.safeXmlCharacters.tagCloser);t=t.split(n).join(RT.safeXmlCharacters.doubleQuote);t=t.split(o).join(RT.safeXmlCharacters.ampersand);t=t.split(r).join(RT.safeXmlCharacters.quote);return t}static mathMLEntities(t){let e=\"\";for(let i=0;i<t.length;i+=1){const n=t.charAt(i);if(t.codePointAt(i)>128){e+=`&#${t.codePointAt(i)};`;if(t.codePointAt(i)>65535){i+=1}}else if(n===\"&\"){const o=t.indexOf(\";\",i+1);if(o>=0){const n=document.createElement(\"span\");n.innerHTML=t.substring(i,o+1);e+=`&#${HT.fixedCharCodeAt(n.textContent||n.innerText,0)};`;i=o}else{e+=n}}else{e+=n}}return e}static addCustomEditorClassAttribute(t,e){let i=\"\";const n=t.indexOf(\"<math\");if(n===0){const o=t.indexOf(\">\");if(t.indexOf(\"class\")===-1){i=`${t.substr(n,o)} class=\"wrs_${e}\">`;i+=t.substr(o+1,t.length);return i}}return t}static removeCustomEditorClassAttribute(t,e){if(t.indexOf(\"class\")===-1||t.indexOf(`wrs_${e}`)===-1){return t}if(t.indexOf(`class=\"wrs_${e}\"`)!==-1){return t.replace(`class=\"wrs_${e}\"`,\"\")}return t.replace(`wrs_${e}`,\"\")}static addAnnotation(t,e,i){const n=t.indexOf(\"<annotation\");let o=\"\";if(n!==-1){const n=t.indexOf(\"</semantics>\");o=`${t.substring(0,n)}<annotation encoding=\"${i}\">${e}</annotation>${t.substring(n)}`}else if(LT.isEmpty(t)){const n=t.indexOf(\"/>\");const r=t.indexOf(\">\");const s=r===n?n:r;o=`${t.substring(0,s)}><semantics><annotation encoding=\"${i}\">${e}</annotation></semantics></math>`}else{const n=t.indexOf(\">\")+1;const r=t.lastIndexOf(\"</math>\");const s=t.substring(n,r);o=`${t.substring(0,n)}<semantics>${s}<annotation encoding=\"${i}\">${e}</annotation></semantics></math>`}return o}static removeAnnotation(t,e){let i=t;const n=`<annotation encoding=\"${e}\">`;const o=\"</annotation>\";const r=t.indexOf(n);if(r!==-1){let e=false;let n=t.indexOf(\"<annotation\");while(n!==-1){if(n!==r){e=true}n=t.indexOf(\"<annotation\",n+1)}if(e){const e=t.indexOf(o,r);const n=e+o.length;const s=t.substring(0,r);i=s+t.substring(n)}else{i=LT.removeSemantics(t)}}return i}static removeSemantics(t){const e=\"</math>\";const i=\"<semantics>\";const n=\"<annotation\";let o=t;const r=t.indexOf(i);if(r!==-1){const s=t.indexOf(n,r+i.length);if(s!==-1){o=t.substring(0,r)+t.substring(r+i.length,s)+e}}return o}static removeSemanticsOcurrences(t,e=RT.xmlCharacters){const i=`${e.tagOpener}math`;const n=`${e.tagOpener}/math${e.tagCloser}`;const o=`/${e.tagCloser}`;const{tagCloser:r}=e;const s=`${e.tagOpener}semantics${e.tagCloser}`;const a=`${e.tagOpener}annotation encoding=`;let l=\"\";let c=t.indexOf(i);let d=0;while(c!==-1){l+=t.substring(d,c);const e=t.indexOf(n,c);const u=t.indexOf(o,c);const h=t.indexOf(r,c);if(e!==-1){d=e}else if(u===h-1){d=u}const f=t.indexOf(s,c);if(f!==-1){const e=t.substring(c,f);const o=t.indexOf(a,c);if(o!==-1){const r=f+s.length;const a=t.substring(r,o);l+=e+a+n;c=t.indexOf(i,c+i.length);d+=n.length}else{d=c;c=t.indexOf(i,c+i.length)}}else{d=c;c=t.indexOf(i,c+i.length)}}l+=t.substring(d,t.length);return l}static containClass(t,e){const i=t.indexOf(\"class\");if(i===-1){return false}const n=t.indexOf(\">\",i);const o=t.substring(i,n);if(o.indexOf(e)!==-1){return true}return false}static isEmpty(t){const e=\">\";const i=\"/>\";const n=t.indexOf(e);const o=t.indexOf(i);let r=false;if(o!==-1){if(o===n-1){r=true}}if(!r){const e=new RegExp(\"</(.+:)?math>\");const i=e.exec(t);if(i){r=n+1===i.index}}return r}static encodeProperties(t){const e=/\\w+=\".*?\"/g;const i=t=>{const e=t.indexOf('\"');const i=t.substring(e+1,t.length-1);const n=HT.htmlEntities(i);const o=`${t.substring(0,e+1)}${n}\"`;return o};const n=t.replace(e,i);return n}}class NT{static addConfiguration(t){Object.assign(NT.properties,t)}static get properties(){return NT._properties}static set properties(t){NT._properties=t}static get(t){if(!Object.prototype.hasOwnProperty.call(NT.properties,t)){if(Object.prototype.hasOwnProperty.call(NT.properties,\"_wrs_conf_\")){return NT.properties[`_wrs_conf_${t}`]}return false}return NT.properties[t]}static set(t,e){NT.properties[t]=e}static update(t,e){if(!NT.get(t)){NT.set(t,e)}else{const i=Object.assign(NT.get(t),e);NT.set(t,i)}}}NT._properties={};class BT{constructor(){this.cache=[]}populate(t,e){this.cache[t]=e}get(t){if(Object.prototype.hasOwnProperty.call(this.cache,t)){return this.cache[t]}return false}}class VT{constructor(){this.listeners=[]}add(t){this.listeners.push(t)}fire(t,e){for(let i=0;i<this.listeners.length&&!e.cancelled;i+=1){if(this.listeners[i].eventName===t){this.listeners[i].callback(e)}}return e.defaultPrevented}static newListener(t,e){const i={};i.eventName=t;i.callback=e;return i}}class DT{static get listeners(){return DT._listeners}static addListener(t){DT.listeners.add(t)}static fireEvent(t,e){DT.listeners.fire(t,e)}static get parameters(){return DT._parameters}static set parameters(t){DT._parameters=t}static get servicePaths(){return DT._servicePaths}static set servicePaths(t){DT._servicePaths=t}static setServicePath(t,e){DT.servicePaths[t]=e}static getServicePath(t){return DT.servicePaths[t]}static get integrationPath(){return DT._integrationPath}static set integrationPath(t){DT._integrationPath=t}static getServerURL(){const t=window.location.href;const e=t.split(\"/\");const i=`${e[0]}//${e[2]}`;return i}static init(t){DT.parameters=t;let e=DT.createServiceURI(\"configurationjs\");let i=DT.createServiceURI(\"createimage\");let n=DT.createServiceURI(\"showimage\");let o=DT.createServiceURI(\"getmathml\");let r=DT.createServiceURI(\"service\");if(DT.parameters.URI.indexOf(\"/\")===0){const t=DT.getServerURL();e=t+e;n=t+n;i=t+i;o=t+o;r=t+r}DT.setServicePath(\"configurationjs\",e);DT.setServicePath(\"showimage\",n);DT.setServicePath(\"createimage\",i);DT.setServicePath(\"service\",r);DT.setServicePath(\"getmathml\",o);DT.setServicePath(\"configurationjs\",e);DT.listeners.fire(\"onInit\",{})}static getUrl(t,e){const i=window.location.toString().substr(0,window.location.toString().lastIndexOf(\"/\")+1);const n=HT.createHttpRequest();if(n){if(typeof e===\"undefined\"||typeof e===\"undefined\"){n.open(\"GET\",t,false)}else if(t.substr(0,1)===\"/\"||t.substr(0,7)===\"http://\"||t.substr(0,8)===\"https://\"){n.open(\"POST\",t,false)}else{n.open(\"POST\",i+t,false)}if(typeof e!==\"undefined\"&&e){n.setRequestHeader(\"Content-type\",\"application/x-www-form-urlencoded; charset=UTF-8\");n.send(HT.httpBuildQuery(e))}else{n.send(null)}return n.responseText}return\"\"}static getService(t,e,i){let n;if(i===true){const i=`${DT.getServicePath(t)}?${e}`;n=DT.getUrl(i)}else{const i=DT.getServicePath(t);n=DT.getUrl(i,e)}return n}static getServerLanguageFromService(t){if(t.indexOf(\".php\")!==-1){return\"php\"}if(t.indexOf(\".aspx\")!==-1){return\"aspx\"}if(t.indexOf(\"wirispluginengine\")!==-1){return\"ruby\"}return\"java\"}static createServiceURI(t){const e=DT.serverExtension();return HT.concatenateUrl(DT.parameters.URI,t)+e}static serverExtension(){if(DT.parameters.server.indexOf(\"php\")!==-1){return\".php\"}if(DT.parameters.server.indexOf(\"aspx\")!==-1){return\".aspx\"}return\"\"}}DT._servicePaths={};DT._integrationPath=\"\";DT._listeners=new VT;DT._parameters={};class zT{static get cache(){return zT._cache}static set cache(t){zT._cache=t}static getLatexFromMathML(t){const e=LT.removeSemantics(t);const{cache:i}=zT;const n={service:\"mathml2latex\",mml:e};const o=JSON.parse(DT.getService(\"service\",n));let r=\"\";if(o.status===\"ok\"){r=o.result.text;const e=HT.htmlEntities(r);const n=LT.addAnnotation(t,e,\"LaTeX\");i.populate(r,n)}return r}static getMathMLFromLatex(t,e){const i=zT.cache;if(zT.cache.get(t)){return zT.cache.get(t)}const n={service:\"latex2mathml\",latex:t};if(e){n.saveLatex=\"\"}const o=JSON.parse(DT.getService(\"service\",n));let r;if(o.status===\"ok\"){let e=o.result.text;e=e.split(\"\\r\").join(\"\").split(\"\\n\").join(\" \");if(e.indexOf(\"semantics\")===-1&&e.indexOf(\"annotation\")===-1){e=LT.addAnnotation(e,t,\"LaTeX\");r=e}else{r=e}if(!i.get(t)){i.populate(t,e)}}else{r=`$$${t}$$`}return r}static parseMathmlToLatex(t,e){let i=\"\";const n=`${e.tagOpener}math`;const o=`${e.tagOpener}/math${e.tagCloser}`;const r=`${e.tagOpener}annotation encoding=${e.doubleQuote}LaTeX${e.doubleQuote}${e.tagCloser}`;const s=`${e.tagOpener}/annotation${e.tagCloser}`;let a=t.indexOf(n);let l=0;let c;let d;let u;while(a!==-1){i+=t.substring(l,a);l=t.indexOf(o,a);if(l===-1){l=t.length-1}else{l+=o.length}c=t.substring(a,l);d=c.indexOf(r);if(d!==-1){d+=r.length;u=c.indexOf(s);let t=c.substring(d,u);if(e===RT.safeXmlCharacters){t=LT.safeXmlDecode(t)}i+=`$$${t}$$`;zT.cache.populate(t,c)}else{i+=c}a=t.indexOf(n,l)}i+=t.substring(l,t.length);return i}static getLatexFromTextNode(t,e,i){const n={open:\"$$\",close:\"$$\"};if(typeof i===\"undefined\"||i==null){i=n}let o=t;while(o.previousSibling&&o.previousSibling.nodeType===3){o=o.previousSibling}function r(t,e,n){let o=t.nodeValue.indexOf(n,e);while(o===-1){t=t.nextSibling;if(!t){return null}o=t.nodeValue?t.nodeValue.indexOf(i.close):-1}return{node:t,position:o}}function s(t,e,i,n){if(t===i){return e<=n}while(t&&t!==i){t=t.nextSibling}return t===i}let a;let l={node:o,position:0};const c=i.open.length;do{a=r(l.node,l.position,i.open);if(a==null||s(t,e,a.node,a.position)){return null}l=r(a.node,a.position+c,i.close);if(l==null){return null}l.position+=c}while(s(l.node,l.position,t,e));let d;if(a.node===l.node){d=a.node.nodeValue.substring(a.position+c,l.position-c)}else{const t=a.position+c;d=a.node.nodeValue.substring(t,a.node.nodeValue.length);let e=a.node;do{e=e.nextSibling;if(e===l.node){d+=l.node.nodeValue.substring(0,l.position-c)}else{d+=e.nodeValue?e.nodeValue:\"\"}}while(e!==l.node)}return{latex:d,startNode:a.node,startPosition:a.position,endNode:l.node,endPosition:l.position}}}zT._cache=new BT;var FT=i(16);class jT{constructor(){throw new Error(\"Static class StringManager can not be instantiated.\")}static get(t){let{language:e}=this;if(!(e in this.strings)){console.warn(`Unknown language ${e} set in StringManager.`);e=\"en\"}if(!(t in this.strings[e])){console.warn(`Unknown key ${t} in StringManager.`);return t}return this.strings[e][t]}}jT.strings=FT;jT.language=\"en\";class HT{static fireEvent(t,e){if(document.createEvent){const i=document.createEvent(\"HTMLEvents\");i.initEvent(e,true,true);return!t.dispatchEvent(i)}const i=document.createEventObject();return t.fireEvent(`on${e}`,i)}static addEvent(t,e,i){if(t.addEventListener){t.addEventListener(e,i,true)}else if(t.attachEvent){t.attachEvent(`on${e}`,i)}}static removeEvent(t,e,i){if(t.removeEventListener){t.removeEventListener(e,i,true)}else if(t.detachEvent){t.detachEvent(`on${e}`,i)}}static addElementEvents(t,e,i,n){if(e){HT.addEvent(t,\"dblclick\",t=>{const i=t||window.event;const n=i.srcElement?i.srcElement:i.target;e(n,i)})}if(i){HT.addEvent(t,\"mousedown\",t=>{const e=t||window.event;const n=e.srcElement?e.srcElement:e.target;i(n,e)})}if(n){HT.addEvent(t,\"mouseup\",t=>{const e=t||window.event;const i=e.srcElement?e.srcElement:e.target;n(i,e)})}}static addClass(t,e){if(!HT.containsClass(t,e)){t.className+=` ${e}`}}static containsClass(t,e){if(t==null||!(\"className\"in t)){return false}const i=t.className.split(\" \");for(let t=i.length-1;t>=0;t-=1){if(i[t]===e){return true}}return false}static removeClass(t,e){let i=\"\";const n=t.className.split(\" \");for(let t=0;t<n.length;t+=1){if(n[t]!==e){i+=`${n[t]} `}}t.className=i.trim()}static convertOldXmlinitialtextAttribute(t){const e=\"value=\";const i=t.indexOf(\"xmlinitialtext\");const n=t.indexOf(e,i);const o=t.charAt(n+e.length);const r=n+e.length+1;const s=t.indexOf(o,r);const a=t.substring(r,s);let l=a.split(\"«\").join(\"§lt;\");l=l.split(\"»\").join(\"§gt;\");l=l.split(\"&\").join(\"§\");l=l.split(\"¨\").join(\"§quot;\");t=t.split(a).join(l);return t}static createElement(t,e,i){if(e===undefined){e={}}if(i===undefined){i=document}let n;try{let o=`<${t}`;Object.keys(e).forEach(t=>{o+=` ${t}=\"${HT.htmlEntities(e[t])}\"`});o+=\">\";n=i.createElement(o)}catch(o){n=i.createElement(t);Object.keys(e).forEach(t=>{n.setAttribute(t,e[t])})}return n}static createObject(t,e){if(e===undefined){e=document}t=t.split(\"<applet \").join('<span wirisObject=\"WirisApplet\" ').split(\"<APPLET \").join('<span wirisObject=\"WirisApplet\" ');t=t.split(\"</applet>\").join(\"</span>\").split(\"</APPLET>\").join(\"</span>\");t=t.split(\"<param \").join('<br wirisObject=\"WirisParam\" ').split(\"<PARAM \").join('<br wirisObject=\"WirisParam\" ');t=t.split(\"</param>\").join(\"</br>\").split(\"</PARAM>\").join(\"</br>\");const i=HT.createElement(\"div\",{},e);i.innerHTML=t;function n(t){if(t.getAttribute&&t.getAttribute(\"wirisObject\")===\"WirisParam\"){const i={};for(let e=0;e<t.attributes.length;e+=1){if(t.attributes[e].nodeValue!==null){i[t.attributes[e].nodeName]=t.attributes[e].nodeValue}}const n=HT.createElement(\"param\",i,e);if(n.NAME){n.name=n.NAME;n.value=n.VALUE}n.removeAttribute(\"wirisObject\");t.parentNode.replaceChild(n,t)}else if(t.getAttribute&&t.getAttribute(\"wirisObject\")===\"WirisApplet\"){const i={};for(let e=0;e<t.attributes.length;e+=1){if(t.attributes[e].nodeValue!==null){i[t.attributes[e].nodeName]=t.attributes[e].nodeValue}}const o=HT.createElement(\"applet\",i,e);o.removeAttribute(\"wirisObject\");for(let e=0;e<t.childNodes.length;e+=1){n(t.childNodes[e]);if(t.childNodes[e].nodeName.toLowerCase()===\"param\"){o.appendChild(t.childNodes[e]);e-=1}}t.parentNode.replaceChild(o,t)}else{for(let e=0;e<t.childNodes.length;e+=1){n(t.childNodes[e])}}}n(i);return i.firstChild}static createObjectCode(t){if(typeof t===\"undefined\"||t===null){return null}if(t.nodeType===1){let e=`<${t.tagName}`;for(let i=0;i<t.attributes.length;i+=1){if(t.attributes[i].specified){e+=` ${t.attributes[i].name}=\"${HT.htmlEntities(t.attributes[i].value)}\"`}}if(t.childNodes.length>0){e+=\">\";for(let i=0;i<t.childNodes.length;i+=1){e+=HT.createObject(t.childNodes[i])}e+=`</${t.tagName}>`}else if(t.nodeName===\"DIV\"||t.nodeName===\"SCRIPT\"){e+=`></${t.tagName}>`}else{e+=\"/>\"}return e}if(t.nodeType===3){return HT.htmlEntities(t.nodeValue)}return\"\"}static concatenateUrl(t,e){let i=\"\";if(t.indexOf(\"/\")!==t.length&&e.indexOf(\"/\")!==0){i=\"/\"}return(t+i+e).replace(/([^:]\\/)\\/+/g,\"$1\")}static htmlEntities(t){return t.split(\"&\").join(\"&amp;\").split(\"<\").join(\"&lt;\").split(\">\").join(\"&gt;\").split('\"').join(\"&quot;\")}static htmlEntitiesDecode(t){const e=document.createElement(\"textarea\");e.innerHTML=t;return e.value}static createHttpRequest(){const t=window.location.toString().substr(0,window.location.toString().lastIndexOf(\"/\")+1);if(t.substr(0,7)===\"file://\"){throw jT.get(\"exception_cross_site\")}if(typeof XMLHttpRequest!==\"undefined\"){return new XMLHttpRequest}try{return new ActiveXObject(\"Msxml2.XMLHTTP\")}catch(t){try{return new ActiveXObject(\"Microsoft.XMLHTTP\")}catch(t){return null}}}static httpBuildQuery(t){let e=\"\";Object.keys(t).forEach(i=>{if(t[i]!=null){e+=`${HT.urlEncode(i)}=${HT.urlEncode(t[i])}&`}});if(e.substring(e.length-1)===\"&\"){e=e.substring(0,e.length-1)}return e}static propertiesToString(t){const e=[];Object.keys(t).forEach(i=>{if(Object.prototype.hasOwnProperty.call(t,i)){e.push(i)}});const i=e.length;for(let t=0;t<i;t+=1){for(let n=t+1;n<i;n+=1){const i=e[t];const o=e[n];if(HT.compareStrings(i,o)>0){e[t]=o;e[n]=i}}}let n=\"\";for(let o=0;o<i;o+=1){const i=e[o];n+=i;n+=\"=\";let r=t[i];r=r.replace(\"\\\\\",\"\\\\\\\\\");r=r.replace(\"\\n\",\"\\\\n\");r=r.replace(\"\\r\",\"\\\\r\");r=r.replace(\"\\t\",\"\\\\t\");n+=r;n+=\"\\n\"}return n}static compareStrings(t,e){let i;const n=t.length;const o=e.length;const r=n>o?o:n;for(i=0;i<r;i+=1){const n=HT.fixedCharCodeAt(t,i)-HT.fixedCharCodeAt(e,i);if(n!==0){return n}}return t.length-e.length}static fixedCharCodeAt(t,e){e=e||0;const i=t.charCodeAt(e);let n;let o;if(i>=55296&&i<=56319){n=i;o=t.charCodeAt(e+1);if(Number.isNaN(o)){throw jT.get(\"exception_high_surrogate\")}return(n-55296)*1024+(o-56320)+65536}if(i>=56320&&i<=57343){return false}return i}static urlToAssArray(t){let e;e=t.indexOf(\"?\");if(e>0){const i=t.substring(e+1);const n=i.split(\"&\");const o={};for(e=0;e<n.length;e+=1){const t=n[e];const i=t.split(\"=\");if(i.length>1){o[i[0]]=decodeURIComponent(i[1].replace(/\\+/g,\" \"))}}return o}return{}}static urlEncode(t){let e=\"\";e=encodeURIComponent(t);return e}static getWIRISImageOutput(t,e,i){const n=HT.createObject(t);if(n){if(n.className===NT.get(\"imageClassName\")||n.getAttribute(NT.get(\"imageMathmlAttribute\"))){if(!e){return t}const o=n.getAttribute(NT.get(\"imageMathmlAttribute\"));let r=LT.safeXmlDecode(o);if(!NT.get(\"saveHandTraces\")){r=LT.removeAnnotation(r,\"application/json\")}if(r==null){r=n.getAttribute(\"alt\")}if(i){const t=LT.safeXmlEncode(r);return t}return r}}return t}static getNodeLength(t){const e={IMG:1,BR:1};if(t.nodeType===3){return t.nodeValue.length}if(t.nodeType===1){let i=e[t.nodeName.toUpperCase()];if(i===undefined){i=0}for(let e=0;e<t.childNodes.length;e+=1){i+=HT.getNodeLength(t.childNodes[e])}return i}return 0}static getSelectedItem(t,e,i){let n;if(e){n=t.contentWindow;n.focus()}else{n=window;t.focus()}if(document.selection&&!i){const i=n.document.selection.createRange();if(i.parentElement){if(i.htmlText.length>0){if(i.text.length===0){return HT.getSelectedItem(t,e,true)}return null}n.document.execCommand(\"InsertImage\",false,\"#\");let o=i.parentElement();if(o.nodeName.toUpperCase()!==\"IMG\"){i.pasteHTML('<span id=\"wrs_openEditorWindow_temporalObject\"></span>');o=n.document.getElementById(\"wrs_openEditorWindow_temporalObject\")}let r;let s;if(o.nextSibling&&o.nextSibling.nodeType===3){r=o.nextSibling;s=0}else if(o.previousSibling&&o.previousSibling.nodeType===3){r=o.previousSibling;s=r.nodeValue.length}else{r=n.document.createTextNode(\"\");o.parentNode.insertBefore(r,o);s=0}o.parentNode.removeChild(o);return{node:r,caretPosition:s}}if(i.length>1){return null}return{node:i.item(0)}}if(n.getSelection){let t;const e=n.getSelection();try{t=e.getRangeAt(0)}catch(e){t=n.document.createRange()}const i=t.startContainer;if(i.nodeType===3){return{node:i,caretPosition:t.startOffset}}if(i!==t.endContainer){return null}if(i.nodeType===1){const e=t.startOffset;if(i.childNodes[e]){return{node:i.childNodes[e]}}}}return null}static getSelectedItemOnTextarea(t){const e=document.createTextNode(t.value);const i=zT.getLatexFromTextNode(e,t.selectionStart);if(i===null){return null}return{node:e,caretPosition:t.selectionStart,startPosition:i.startPosition,endPosition:i.endPosition}}static getElementsByNameFromString(t,e,i){const n=[];t=t.toLowerCase();e=e.toLowerCase();let o=t.indexOf(`<${e} `);while(o!==-1){let r;if(i){r=\">\"}else{r=`</${e}>`}let s=t.indexOf(r,o);if(s!==-1){s+=r.length;n.push({start:o,end:s})}else{s=o+1}o=t.indexOf(`<${e} `,s)}return n}static decode64(t){const e=\"+\".charCodeAt(0);const i=\"/\".charCodeAt(0);const n=\"0\".charCodeAt(0);const o=\"a\".charCodeAt(0);const r=\"A\".charCodeAt(0);const s=\"-\".charCodeAt(0);const a=\"_\".charCodeAt(0);const l=t.charCodeAt(0);if(l===e||l===s){return 62}if(l===i||l===a){return 63}if(l<n){return-1}if(l<n+10){return l-n+26+26}if(l<r+26){return l-r}if(l<o+26){return l-o+26}return null}static b64ToByteArray(t,e){let i;if(t.length%4>0){throw new Error(\"Invalid string. Length must be a multiple of 4\")}const n=[];let o;let r;if(!e){if(t.charAt(t.length-2)===\"=\"){r=2}else if(t.charAt(t.length-1)===\"=\"){r=1}else{r=0}o=r>0?t.length-4:t.length}else{o=e}let s;for(s=0;s<o;s+=4){i=HT.decode64(t.charAt(s))<<18|HT.decode64(t.charAt(s+1))<<12|HT.decode64(t.charAt(s+2))<<6|HT.decode64(t.charAt(s+3));n.push(i>>16&255);n.push(i>>8&255);n.push(i&255)}if(r){if(r===2){i=HT.decode64(t.charAt(s))<<2|HT.decode64(t.charAt(s+1))>>4;n.push(i&255)}else if(r===1){i=HT.decode64(t.charAt(s))<<10|HT.decode64(t.charAt(s+1))<<4|HT.decode64(t.charAt(s+2))>>2;n.push(i>>8&255);n.push(i&255)}}return n}static readInt32(t){if(t.length<4){return false}const e=t.splice(0,4);return e[0]<<24|e[1]<<16|e[2]<<8|e[3]<<0}static readByte(t){return t.shift()<<0}static readBytes(t,e,i){return t.splice(e,i)}static updateTextArea(t,e){if(t&&e){t.focus();if(t.selectionStart!=null){const{selectionEnd:i}=t;const n=t.value.substring(0,t.selectionStart);const o=t.value.substring(i,t.value.length);t.value=n+e+o;t.selectionEnd=i+e.length}else{const t=document.selection.createRange();t.text=e}}}static updateExistingTextOnTextarea(t,e,i,n){t.focus();const o=t.value.substring(0,i);t.value=o+e+t.value.substring(n,t.value.length);t.selectionEnd=i+e.length}static addArgument(t,e,i){let n;if(t.indexOf(\"?\")>0){n=\"&\"}else{n=\"?\"}return`${t+n+e}=${i}`}}class WT{static removeImgDataAttributes(t){const e=[];const{attributes:i}=t;Object.keys(i).forEach(t=>{const n=i[t];if(n.name.indexOf(\"data-\")===0){e.push(n.name)}});e.forEach(e=>{t.removeAttribute(e)})}static clone(t,e){const i=NT.get(\"imageCustomEditorName\");if(!t.hasAttribute(i)){e.removeAttribute(i)}const n=NT.get(\"imageMathmlAttribute\");const o=[n,i,\"alt\",\"height\",\"width\",\"style\",\"src\",\"role\"];o.forEach(i=>{const n=t.getAttribute(i);if(n){e.setAttribute(i,n)}})}static setImgSize(t,e,i){let n;let o;let r;let s;if(i){if(NT.get(\"imageFormat\")===\"svg\"){if(NT.get(\"saveMode\")!==\"base64\"){n=WT.getMetricsFromSvgString(e)}else{o=t.src.substr(t.src.indexOf(\"base64,\")+7,t.src.length);s=\"\";r=HT.b64ToByteArray(o,o.length);for(let t=0;t<r.length;t+=1){s+=String.fromCharCode(r[t])}n=WT.getMetricsFromSvgString(s)}}else{o=t.src.substr(t.src.indexOf(\"base64,\")+7,t.src.length);r=HT.b64ToByteArray(o,88);n=WT.getMetricsFromBytes(r)}}else{n=HT.urlToAssArray(e)}let a=n.cw;if(!a){return}let l=n.ch;let c=n.cb;const{dpi:d}=n;if(d){a=a*96/d;l=l*96/d;c=c*96/d}t.width=a;t.height=l;t.style.verticalAlign=`-${l-c}px`}static fixAfterResize(t){t.removeAttribute(\"style\");t.removeAttribute(\"width\");t.removeAttribute(\"height\");t.style.maxWidth=\"none\";if(t.src.indexOf(\"data:image\")!==-1){if(NT.get(\"imageFormat\")===\"svg\"){const e=decodeURIComponent(t.src.substring(32,t.src.length));WT.setImgSize(t,e,true)}else{const e=t.src.substring(22,t.src.length);WT.setImgSize(t,e,true)}}else{WT.setImgSize(t,t.src)}}static getMetricsFromSvgString(t){let e=t.indexOf('height=\"');let i=t.indexOf('\"',e+8,t.length);const n=t.substring(e+8,i);e=t.indexOf('width=\"');i=t.indexOf('\"',e+7,t.length);const o=t.substring(e+7,i);e=t.indexOf('wrs:baseline=\"');i=t.indexOf('\"',e+14,t.length);const r=t.substring(e+14,i);if(typeof o!==\"undefined\"){const t=[];t.cw=o;t.ch=n;if(typeof r!==\"undefined\"){t.cb=r}return t}return[]}static getMetricsFromBytes(t){HT.readBytes(t,0,8);let e;let i;let n;let o;let r;while(t.length>=4){n=HT.readInt32(t);if(n===1229472850){e=HT.readInt32(t);i=HT.readInt32(t);HT.readInt32(t);HT.readByte(t)}else if(n===1650545477){o=HT.readInt32(t)}else if(n===1883789683){r=HT.readInt32(t);r=Math.round(r/39.37);HT.readInt32(t);HT.readByte(t)}HT.readInt32(t)}if(typeof e!==\"undefined\"){const t=[];t.cw=e;t.ch=i;t.dpi=r;if(o){t.cb=o}return t}return[]}}class qT{static get cache(){return qT._cache}static set cache(t){qT._cache=t}static mathMLToAccessible(t,e,i){if(typeof e===\"undefined\"){e=\"en\"}if(LT.containClass(t,\"wrs_chemistry\")){i.mode=\"chemistry\"}let n=\"\";if(qT.cache.get(t)){n=qT.cache.get(t)}else{i.service=\"mathml2accessible\";i.lang=e;const o=JSON.parse(DT.getService(\"service\",i));if(o.status!==\"error\"){n=o.result.text;qT.cache.populate(t,n)}else{n=jT.get(\"error_convert_accessibility\")}}return n}}qT._cache=new BT;var $T=i(85);class UT{static mathmlToImgObject(t,e,i,n){const o=t.createElement(\"img\");o.align=\"middle\";o.style.maxWidth=\"none\";const r=i||{};r.mml=e;r.lang=n;r.metrics=\"true\";r.centerbaseline=\"false\";if(NT.get(\"saveMode\")===\"base64\"&&NT.get(\"base64savemode\")===\"default\"){r.base64=true}o.className=NT.get(\"imageClassName\");if(e.indexOf('class=\"')!==-1){let t=e.substring(e.indexOf('class=\"')+'class=\"'.length,e.length);t=t.substring(0,t.indexOf('\"'));t=t.substring(4,t.length);o.setAttribute(NT.get(\"imageCustomEditorName\"),t)}if(NT.get(\"wirisPluginPerformance\")&&(NT.get(\"saveMode\")===\"xml\"||NT.get(\"saveMode\")===\"safeXml\")){let t=JSON.parse(UT.createShowImageSrc(r,n));if(t.status===\"warning\"){try{t=JSON.parse(DT.getService(\"showimage\",r))}catch(t){return null}}({result:t}=t);if(t.format===\"png\"){o.src=`data:image/png;base64,${t.content}`}else{o.src=`data:image/svg+xml;charset=utf8,${HT.urlEncode(t.content)}`}o.setAttribute(NT.get(\"imageMathmlAttribute\"),LT.safeXmlEncode(e));WT.setImgSize(o,t.content,true);if(NT.get(\"enableAccessibility\")){if(typeof t.alt===\"undefined\"){o.alt=qT.mathMLToAccessible(e,n,r)}else{o.alt=t.alt}}}else{const t=UT.createImageSrc(e,r);o.setAttribute(NT.get(\"imageMathmlAttribute\"),LT.safeXmlEncode(e));o.src=t;WT.setImgSize(o,t,NT.get(\"saveMode\")===\"base64\"&&NT.get(\"base64savemode\")===\"default\");if(NT.get(\"enableAccessibility\")){o.alt=qT.mathMLToAccessible(e,n,r)}}if(typeof UT.observer!==\"undefined\"){UT.observer.observe(o)}o.setAttribute(\"role\",\"math\");return o}static createImageSrc(t,e){if(NT.get(\"saveMode\")===\"base64\"&&NT.get(\"base64savemode\")===\"default\"){e.base64=true}let i=DT.getService(\"createimage\",e);if(i.indexOf(\"@BASE@\")!==-1){const t=DT.getServicePath(\"createimage\").split(\"/\");t.pop();i=i.split(\"@BASE@\").join(t.join(\"/\"))}return i}static initParse(t,e){t=UT.initParseSaveMode(t,e);return UT.initParseEditMode(t)}static initParseSaveMode(t,e){if(NT.get(\"saveMode\")){t=zT.parseMathmlToLatex(t,RT.safeXmlCharacters);t=zT.parseMathmlToLatex(t,RT.xmlCharacters);t=UT.parseMathmlToImg(t,RT.safeXmlCharacters,e);t=UT.parseMathmlToImg(t,RT.xmlCharacters,e);if(NT.get(\"saveMode\")===\"base64\"&&NT.get(\"base64savemode\")===\"image\"){t=UT.codeImgTransform(t,\"base642showimage\")}}return t}static initParseEditMode(t){if(NT.get(\"parseModes\").indexOf(\"latex\")!==-1){const e=HT.getElementsByNameFromString(t,\"img\",true);const i='encoding=\"LaTeX\">';let n=0;for(let o=0;o<e.length;o+=1){const r=t.substring(e[o].start+n,e[o].end+n);if(r.indexOf(` class=\"${NT.get(\"imageClassName\")}\"`)!==-1){let s=` ${NT.get(\"imageMathmlAttribute\")}=\"`;let a=r.indexOf(s);if(a===-1){s=' alt=\"';a=r.indexOf(s)}if(a!==-1){a+=s.length;const l=r.indexOf('\"',a);const c=LT.safeXmlDecode(r.substring(a,l));let d=c.indexOf(i);if(d!==-1){d+=i.length;const r=c.indexOf(\"</annotation>\",d);const s=c.substring(d,r);const a=`$$${HT.htmlEntitiesDecode(s)}$$`;const l=t.substring(0,e[o].start+n);const u=t.substring(e[o].end+n);t=l+a+u;n+=a.length-(e[o].end-e[o].start)}}}}}return t}static endParse(t){const e=UT.endParseEditMode(t);const i=UT.endParseSaveMode(e);return i}static endParseEditMode(t){if(NT.get(\"parseModes\").indexOf(\"latex\")!==-1){let e=\"\";let i=0;let n=t.indexOf(\"$$\");while(n!==-1){e+=t.substring(i,n);i=t.indexOf(\"$$\",n+2);if(i!==-1){const o=t.substring(n+2,i);const r=HT.htmlEntitiesDecode(o);let s=zT.getMathMLFromLatex(r,true);if(!NT.get(\"saveHandTraces\")){s=LT.removeAnnotation(s,\"application/json\")}e+=s;i+=2}else{e+=\"$$\";i=n+2}n=t.indexOf(\"$$\",i)}e+=t.substring(i,t.length);t=e}return t}static endParseSaveMode(t){if(NT.get(\"saveMode\")){if(NT.get(\"saveMode\")===\"safeXml\"){t=UT.codeImgTransform(t,\"img2mathml\")}else if(NT.get(\"saveMode\")===\"xml\"){t=UT.codeImgTransform(t,\"img2mathml\")}else if(NT.get(\"saveMode\")===\"base64\"&&NT.get(\"base64savemode\")===\"image\"){t=UT.codeImgTransform(t,\"img264\")}}return t}static createShowImageSrc(t,e){const i=[];const n=[\"mml\",\"color\",\"centerbaseline\",\"zoom\",\"dpi\",\"fontSize\",\"fontFamily\",\"defaultStretchy\",\"backgroundColor\",\"format\"];n.forEach(e=>{const o=n[e];if(typeof t[o]!==\"undefined\"){i[o]=t[o]}});const o={};Object.keys(t).forEach(e=>{if(e!==\"mml\"){o[e]=t[e]}});o.formula=com.wiris.js.JsPluginTools.md5encode(HT.propertiesToString(i));o.lang=typeof e===\"undefined\"?\"en\":e;o.version=NT.get(\"version\");const r=DT.getService(\"showimage\",HT.httpBuildQuery(o),true);return r}static codeImgTransform(t,e){let i=\"\";let n=0;const o=/<img/gi;const r=o.source.length;while(o.test(t)){const s=o.lastIndex-r;i+=t.substring(n,s);let a=s+1;while(a<t.length&&n<=s){const e=t.charAt(a);if(e==='\"'||e===\"'\"){const i=t.indexOf(e,a+1);if(i===-1){a=t.length}else{a=i}}else if(e===\">\"){n=a+1}a+=1}if(n<s){i+=t.substring(s,t.length);return i}let l=t.substring(s,n);const c=HT.createObject(l);let d=c.getAttribute(NT.get(\"imageMathmlAttribute\"));let u;let h;if(e===\"base642showimage\"){if(d==null){d=c.getAttribute(\"alt\")}d=LT.safeXmlDecode(d);l=UT.mathmlToImgObject(document,d,null,null);i+=HT.createObjectCode(l)}else if(e===\"img2mathml\"){if(NT.get(\"saveMode\")){if(NT.get(\"saveMode\")===\"safeXml\"){u=true;h=true}else if(NT.get(\"saveMode\")===\"xml\"){u=true;h=false}}i+=HT.getWIRISImageOutput(l,u,h)}else if(e===\"img264\"){if(d===null){d=c.getAttribute(\"alt\")}d=LT.safeXmlDecode(d);const t={};t.base64=\"true\";l=UT.mathmlToImgObject(document,d,t,null);WT.setImgSize(l,l.src,true);i+=HT.createObjectCode(l)}}i+=t.substring(n,t.length);return i}static parseMathmlToImg(t,e,i){let n=\"\";const o=`${e.tagOpener}math`;const r=`${e.tagOpener}/math${e.tagCloser}`;let s=t.indexOf(o);let a=0;while(s!==-1){n+=t.substring(a,s);const l=t.indexOf(NT.get(\"imageMathmlAttribute\"));a=t.indexOf(r,s);if(a===-1){a=t.length-1}else if(l!==-1){a+=t.indexOf(\"/>\",s)}else{a+=r.length}if(!LT.isMathmlInAttribute(t,s)&&l===-1){let o=t.substring(s,a);o=e.id===RT.safeXmlCharacters.id?LT.safeXmlDecode(o):LT.mathMLEntities(o);n+=HT.createObjectCode(UT.mathmlToImgObject(document,o,null,i))}else{n+=t.substring(s,a)}s=t.indexOf(o,a)}n+=t.substring(a,t.length);return n}}if(typeof MutationObserver!==\"undefined\"){const t=new MutationObserver(t=>{t.forEach(t=>{if(t.oldValue===NT.get(\"imageClassName\")&&t.attributeName===\"class\"&&t.target.className.indexOf(NT.get(\"imageClassName\"))===-1){t.target.className=NT.get(\"imageClassName\")}})});UT.observer=Object.create(t);UT.observer.Config={attributes:true,attributeOldValue:true};UT.observer.observe=function t(e){Object.getPrototypeOf(this).observe(e,this.Config)}}class GT{constructor(){this.isContentChanged=false;this.waitingForChanges=false}setIsContentChanged(t){this.isContentChanged=t}getIsContentChanged(){return this.isContentChanged}setWaitingForChanges(t){this.waitingForChanges=t}caretPositionChanged(t){}clipboardChanged(t){}contentChanged(t){if(this.waitingForChanges===true&&this.isContentChanged===false){this.isContentChanged=true}}styleChanged(t){}transformationReceived(t){}}class JT{constructor(t){this.editorAttributes={};if(\"editorAttributes\"in t){this.editorAttributes=t.editorAttributes}else{throw new Error(\"ContentManager constructor error: editorAttributes property missed.\")}this.customEditors=null;if(\"customEditors\"in t){this.customEditors=t.customEditors}this.environment={};if(\"environment\"in t){this.environment=t.environment}else{throw new Error(\"ContentManager constructor error: environment property missed\")}this.language=\"\";if(\"language\"in t){this.language=t.language}else{throw new Error(\"ContentManager constructor error: language property missed\")}this.editorListener=new GT;this.editor=null;this.ua=navigator.userAgent.toLowerCase();this.deviceProperties={};this.deviceProperties.isAndroid=this.ua.indexOf(\"android\")>-1;this.deviceProperties.isIOS=this.ua.indexOf(\"ipad\")>-1||this.ua.indexOf(\"iphone\")>-1;this.toolbar=null;this.modalDialogInstance=null;this.listeners=new VT;this.mathML=null;this.isNewElement=true;this.integrationModel=null}addListener(t){this.listeners.add(t)}setIntegrationModel(t){this.integrationModel=t}setModalDialogInstance(t){this.modalDialogInstance=t}insert(){this.updateTitle(this.modalDialogInstance);this.insertEditor(this.modalDialogInstance)}insertEditor(){if(JT.isEditorLoaded()){this.editor=window.com.wiris.jsEditor.JsEditor.newInstance(this.editorAttributes);this.editor.insertInto(this.modalDialogInstance.contentContainer);this.editor.focus();if(this.modalDialogInstance.rtl){this.editor.action(\"rtl\")}if(this.editor.getEditorModel().isRTL()){this.editor.element.style.direction=\"rtl\"}this.editor.getEditorModel().addEditorListener(this.editorListener);if(this.modalDialogInstance.deviceProperties.isIOS){setTimeout((function t(){this.modalDialogInstance.hideKeyboard()}),400);const t=document.getElementsByClassName(\"wrs_formulaDisplay\")[0];HT.addEvent(t,\"focus\",this.modalDialogInstance.handleOpenedIosSoftkeyboard);HT.addEvent(t,\"blur\",this.modalDialogInstance.handleClosedIosSoftkeyboard)}this.listeners.fire(\"onLoad\",{})}else{setTimeout(JT.prototype.insertEditor.bind(this),100)}}init(){if(!JT.isEditorLoaded()){this.addEditorAsExternalDependency()}}addEditorAsExternalDependency(){const t=document.createElement(\"script\");t.type=\"text/javascript\";let e=NT.get(\"editorUrl\");const i=document.createElement(\"a\");JT.setHrefToAnchorElement(i,e);JT.setProtocolToAnchorElement(i);e=JT.getURLFromAnchorElement(i);const n=this.getEditorStats();t.src=`${e}?lang=${this.language}&stats-editor=${n.editor}&stats-mode=${n.mode}&stats-version=${n.version}`;document.getElementsByTagName(\"head\")[0].appendChild(t)}static setHrefToAnchorElement(t,e){t.href=e}static setProtocolToAnchorElement(t){if(window.location.href.indexOf(\"https://\")===0){if(t.protocol===\"http:\"){t.protocol=\"https:\"}}}static getURLFromAnchorElement(t){if(t.port===\"80\"||t.port===\"443\"||t.port===\"\"){return`${t.protocol}//${t.hostname}/${t.pathname}`}}getEditorStats(){const t={};if(\"editor\"in this.environment){t.editor=this.environment.editor}else{t.editor=\"unknown\"}if(\"mode\"in this.environment){t.mode=this.environment.mode}else{t.mode=NT.get(\"saveMode\")}if(\"version\"in this.environment){t.version=this.environment.version}else{t.version=NT.get(\"version\")}return t}static isEditorLoaded(){return window.com&&window.com.wiris&&window.com.wiris.jsEditor&&window.com.wiris.jsEditor.JsEditor&&window.com.wiris.jsEditor.JsEditor.newInstance}setInitialContent(){if(!this.isNewElement){this.setMathML(this.mathML)}}setMathML(t,e){if(typeof e===\"undefined\"){e=false}this.editor.setMathMLWithCallback(t,()=>{this.editorListener.setWaitingForChanges(true)});setTimeout(()=>{this.editorListener.setIsContentChanged(false)},500);if(!e){this.onFocus()}}onFocus(){if(typeof this.editor!==\"undefined\"&&this.editor!=null){this.editor.focus()}}submitAction(){if(!this.editor.isFormulaEmpty()){let t=this.editor.getMathMLWithSemantics();if(this.customEditors.getActiveEditor()!==null){const{toolbar:e}=this.customEditors.getActiveEditor();t=LT.addCustomEditorClassAttribute(t,e)}else{Object.keys(this.customEditors.editors).forEach(e=>{t=LT.removeCustomEditorClassAttribute(t,e)})}const e=LT.mathMLEntities(t);this.integrationModel.updateFormula(e)}else{this.integrationModel.updateFormula(null)}this.customEditors.disable();this.integrationModel.notifyWindowClosed();this.setEmptyMathML();this.customEditors.disable()}setEmptyMathML(){if(this.deviceProperties.isAndroid||this.deviceProperties.isIOS){if(this.editor.getEditorModel().isRTL()){this.setMathML('<math dir=\"rtl\"><semantics><annotation encoding=\"application/json\">[]</annotation></semantics></math>',true)}else{this.setMathML('<math><semantics><annotation encoding=\"application/json\">[]</annotation></semantics></math>',true)}}else if(this.editor.getEditorModel().isRTL()){this.setMathML('<math dir=\"rtl\"/>',true)}else{this.setMathML(\"<math/>\",true)}}onOpen(){if(this.isNewElement){this.setEmptyMathML()}else{this.setMathML(this.mathML)}this.updateToolbar();this.onFocus()}updateToolbar(){this.updateTitle(this.modalDialogInstance);const t=this.customEditors.getActiveEditor();if(t){const e=t.toolbar?t.toolbar:_wrs_int_wirisProperties.toolbar;if(this.toolbar==null||this.toolbar!==e){this.setToolbar(e)}}else{const t=this.getToolbar();if(this.toolbar==null||this.toolbar!==t){this.setToolbar(t);this.customEditors.disable()}}}updateTitle(){const t=this.customEditors.getActiveEditor();if(t){this.modalDialogInstance.setTitle(t.title)}else{this.modalDialogInstance.setTitle(\"MathType\")}}getToolbar(){let t=\"general\";if(\"toolbar\"in this.editorAttributes){({toolbar:t}=this.editorAttributes)}if(t===\"general\"){t=typeof _wrs_int_wirisProperties===\"undefined\"||typeof _wrs_int_wirisProperties.toolbar===\"undefined\"?\"general\":_wrs_int_wirisProperties.toolbar}return t}setToolbar(t){this.toolbar=t;this.editor.setParams({toolbar:this.toolbar})}hasChanges(){return!this.editor.isFormulaEmpty()&&this.editorListener.getIsContentChanged()}onKeyDown(t){if(t.key!==undefined&&t.repeat===false){if(t.key===\"Escape\"||t.key===\"Esc\"){let e=document.getElementsByClassName(\"wrs_expandButton wrs_expandButtonFor3RowsLayout wrs_pressed\");if(e.length===0){e=document.getElementsByClassName(\"wrs_expandButton wrs_expandButtonFor2RowsLayout wrs_pressed\");if(e.length===0){e=document.getElementsByClassName(\"wrs_select wrs_pressed\");if(e.length===0){this.modalDialogInstance.cancelAction();t.stopPropagation();t.preventDefault()}}}}else if(t.shiftKey&&t.key===\"Tab\"){if(document.activeElement===this.modalDialogInstance.submitButton){this.editor.focus();t.stopPropagation();t.preventDefault()}else{const e=document.querySelector('[title=\"Manual\"]');if(document.activeElement===e){this.modalDialogInstance.cancelButton.focus();t.stopPropagation();t.preventDefault()}}}else if(t.key===\"Tab\"){if(document.activeElement===this.modalDialogInstance.cancelButton){const e=document.querySelector('[title=\"Manual\"]');e.focus();t.stopPropagation();t.preventDefault()}else{const e=document.getElementsByClassName(\"wrs_formulaDisplay\")[0];if(e.getAttribute(\"class\")===\"wrs_formulaDisplay wrs_focused\"){this.modalDialogInstance.submitButton.focus();t.stopPropagation();t.preventDefault()}}}}}}class KT{constructor(){this.editors=[];this.activeEditor=\"default\"}addEditor(t,e){const i={};i.name=e.name;i.toolbar=e.toolbar;i.icon=e.icon;i.confVariable=e.confVariable;i.title=e.title;i.tooltip=e.tooltip;this.editors[t]=i}enable(t){this.activeEditor=t}disable(){this.activeEditor=\"default\"}getActiveEditor(){if(this.activeEditor!==\"default\"){return this.editors[this.activeEditor]}return null}}const XT={imageCustomEditorName:\"data-custom-editor\",imageClassName:\"Wirisformula\",CASClassName:\"Wiriscas\"};var YT=XT;class QT{constructor(){this.cancelled=false;this.defaultPrevented=false}cancel(){this.cancelled=true}preventDefault(){this.defaultPrevented=true}}class ZT{constructor(t){this.overlayElement=t.overlayElement;this.callbacks=t.callbacks;this.overlayWrapper=this.overlayElement.appendChild(document.createElement(\"div\"));this.overlayWrapper.setAttribute(\"class\",\"wrs_popupmessage_overlay_envolture\");this.message=this.overlayWrapper.appendChild(document.createElement(\"div\"));this.message.id=\"wrs_popupmessage\";this.message.setAttribute(\"class\",\"wrs_popupmessage_panel\");this.message.setAttribute(\"role\",\"dialog\");this.message.setAttribute(\"aria-describedby\",\"description_txt\");const e=document.createElement(\"p\");const i=document.createTextNode(t.strings.message);e.appendChild(i);e.id=\"description_txt\";this.message.appendChild(e);const n=this.overlayWrapper.appendChild(document.createElement(\"div\"));n.setAttribute(\"class\",\"wrs_popupmessage_overlay\");n.addEventListener(\"click\",this.cancelAction.bind(this));this.buttonArea=this.message.appendChild(document.createElement(\"div\"));this.buttonArea.setAttribute(\"class\",\"wrs_popupmessage_button_area\");this.buttonArea.id=\"wrs_popup_button_area\";const o={class:\"wrs_button_accept\",innerHTML:t.strings.submitString,id:\"wrs_popup_accept_button\"};this.closeButton=this.createButton(o,this.closeAction.bind(this));this.buttonArea.appendChild(this.closeButton);const r={class:\"wrs_button_cancel\",innerHTML:t.strings.cancelString,id:\"wrs_popup_cancel_button\"};this.cancelButton=this.createButton(r,this.cancelAction.bind(this));this.buttonArea.appendChild(this.cancelButton)}createButton(t,e){let i={};i=document.createElement(\"button\");i.setAttribute(\"id\",t.id);i.setAttribute(\"class\",t.class);i.innerHTML=t.innerHTML;i.addEventListener(\"click\",e);return i}show(){if(this.overlayWrapper.style.display!==\"block\"){document.activeElement.blur();this.overlayWrapper.style.display=\"block\";this.closeButton.focus()}else{this.overlayWrapper.style.display=\"none\";_wrs_modalWindow.focus()}}cancelAction(){this.overlayWrapper.style.display=\"none\";if(typeof this.callbacks.cancelCallback!==\"undefined\"){this.callbacks.cancelCallback()}}closeAction(){this.cancelAction();if(typeof this.callbacks.closeCallback!==\"undefined\"){this.callbacks.closeCallback()}}onKeyDown(t){if(t.key!==undefined){if(t.key===\"Escape\"||t.key===\"Esc\"){this.cancelAction();t.stopPropagation();t.preventDefault()}else if(t.key===\"Tab\"){if(document.activeElement===this.closeButton){this.cancelButton.focus()}else{this.closeButton.focus()}t.stopPropagation();t.preventDefault()}}}}var tP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg3783\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata3789\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs3787\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image3791\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAACXBIWXMAAC4jAAAuIwF4pT92AAAB\\nvklEQVRYw83Z23GDMBAF0AsNhBIowSVQgjuISnAJKSEdZNOBS6CDOBUkqSC4gs2PyGhAQg92se4M\\n4w8bccYW2hVumBmRdAB6ADfopQcw2SOYNoIkAL8APgB8AzgLI0/2S/iy1xkt3B9m9h0dM9/YHxM4\\nJ/c4MfPkGX+y763OyYVKgUPQTXAJdC84Bg2CS6Gl4FSoF7wHmgvOhbrgzsW+8L4YJegccrEj749R\\ngs7ZXGdz8wbAeNbREcDTzrHvblEgBbAUFACuy6JALJeL0E/P9sbvmBnNojcgAM+oJ58AhrlnWM5Z\\nA+C9RmiokakBvIJuNTLSc7hojqY0Mo8EB6Ep2CPBm9BU7BHgKDQHqwlOguZiNcDJ0JLe4FV4iaLY\\nJjF16dLqnoob+EdDs8A1QJPBtUCTwDVBo+DaoJvgNvBIR6rDl9wirbA1QIPgVgl6VwHb+dAr7Jkk\\nS/Pg3mCkVOslxxV9yBFqSqTA/3N2Utkzye3pftw5OxzQ5tHeddcdzGj3o4VgClUwowgtAVOs3BpF\\naA6YUnsDowhNAVNu12UUoVtgCn2+ifxp1wO42Ner4KPR5dJ2tsse2ZLvTQxbVf4AmC2z7WnSvpIA\\nAAAASUVORK5CYII=\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var eP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg2\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata8\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs6\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image10\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAACXBIWXMAAC4jAAAuIwF4pT92AAAB\\n2ElEQVRYw9XZoXPCMBTH8S+5KfDzQ29606CH3/SmQTO96aGHHn/F0Himh8eDZSblQknSJH2F0DtE\\nQw8+12vyfulr7XY7LuW4qvj+DugD18AC+AE2woa+/mz07y9cF7Y8d7YPDEtjK2AsCB4BvdLYHPi0\\nXawioAA3wAfQaQiKHhuFYl1QSbAL6gWrSKgEuArqBKsEaB1wKNQKVsasHybcpRhwLNQED0zsoMbz\\nFwJOhWL6Cmzd2e0D14Wi1/k9di2wFNnAEtBifd9jv4GtIPgaeBOCAkzLFayr/6idWSSY6DJ8sHT9\\n6VK6zRFqKwo5gQ+grnKbA/gI6gsy5wRboT7sucBOaBX21GAvNAR7KnAlNBTbNDgIGoMtwO/C0Gko\\nNBZbN525tk+dJrAj4F4YGxXgVQS019DkCgarM0OjwCoDaDBYZQINAquMoJVglRnUC1YZQp1g1RB0\\nJryn65jYJ0HoRGPHguDX8hsZ6VAiGX4eUrJBbHqSArdN7LLBmCcBnpvYWfHWo6E8Wge8Ar7Kj8E4\\nARwcnBPBB20BE7uJBMdAU8BH/YvyBAsFp0BjwNZGi201qALXgYaAnR0hX2upAzwDj/p8raFL5I4u\\n8ALc6vNfvc+ztq5al9Rh/AfwZZ/LmlMllAAAAABJRU5ErkJggg==\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var iP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg3793\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata3799\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs3797\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image3801\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAAAXNSR0IArs4c6QAAAARnQU1BAACx\\njwv8YQUAAAAJcEhZcwAALiMAAC4jAXilP3YAAAG4SURBVFhHvZnhUYNAEEbRBkwH2oGUkA40FWgJ\\nKSEdaAmxA0vQDmIHKSFWgPuAHZkEAnd8y5v5kuNHMm+WY1mSm6qqCiGlZdUspXzxopY9Wu6bpZQf\\nSxlRWapwVx9p2dy2CxUHy9ryWx9pKdWyECYcIQshwlGyIBeOlAWpcLQsyISXkAWEX5tlPkvJwnP7\\nns1SsnvLS7PMZwlZiShEy8pEIVJWKgpRsnJRiJBNFf2wbCzjfZgRUZi9JYWDxT9bWk6WIXbKym4t\\nKRVloObO5oze6ZClWX9a5jyOcOrfmuUkXPRUH/1zVRhZpvsnCxN+jnDqHh0SdQaFu9vg0ZIqrBZ1\\neoXP92yKcJSocyHcd4FNEY4WdbrCR1rGrukMF9BWVhZvLZ7U9rS2nH9HVvoq63iFu+RUlOpIuCYL\\nCCPIqVjq1A9j5R3aBnMY2kKzMlbZHPQVbVHLhomCUjZUFFSy35ZQUVDIMo+Gi4JCltFwERSy75Y5\\n4+VkFLLcKHLHyyRUF1jOeJmMShbChZWy0Df8yFDLgg8/cpCN6I9cdHJhZHmy7X2anAnCtDUZ/j/Y\\ng2X2j709MHhTDAFF8QdK9SRpUl2yFgAAAABJRU5ErkJggg==\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var nP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg12\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata18\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs16\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image20\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAAAXNSR0IArs4c6QAAAARnQU1BAACx\\njwv8YQUAAAAJcEhZcwAALiMAAC4jAXilP3YAAAGMSURBVFhHvdk7TsNAFIVhQ0l6elLDJqCGngXQ\\nU7MA6rALahZATQ81C6APrXP/jEaKHD/i8TnzS1eaICF/2I4f4qxt20bYOmaVlrK2Mb8s1Nj3mIu0\\nlPYZszlPa1kvMf9pKe02Zq3Gcrhc4JUaSzawA0sWsAtLcrATS1KwG0sycA0sAd6kZXm1sNzVHtOy\\nvBpYoK8xV/tPC3JjZVByYqVQcmHlUHJgLVBSY0ugPP7xO5PXYSW2FMr19ytm8sahxD7ElEBzk3c6\\nsFysn/afymKPvsXMueh3oblRMNibmPuYZ34wsyWHfqhB8OFpwKvDHLADmusFd8/ZU8FOaO4I3PcF\\nmwLXgOYOwVtexdnwdUy3vg2UQPnD2eji+vZsrruHS/eoBEpjWMpgrhi1Dv1gY6fBkuRQmtqzJVmg\\npMbaoKTEWqGkwtqhpMBWgZICWwVKCuwpzxKSFNi5T2vFqb5gVcAqLNnBSixZwWos2cBg/9JSmgUM\\n9iMt5QFe8tZ8VP6n3WXMHQtxPzHfabm0ptkBwWhpthzMp7YAAAAASUVORK5CYII=\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var oP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg3813\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata3819\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs3817\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image3821\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAACXBIWXMAAC4jAAAuIwF4pT92AAAA\\nnUlEQVRYw+3Z0QnCMBSF4T/FATqCG1g3cISO0NE6iiPoCE5gneD40ohPvgkJ/AcC9/EjHELgliT0\\nkoGOIlasWLFixYoVK1asWLFixYoVK1bsjxy+5hlYgLEx47ofSEKSJW1nTUJJMgLPDlpwHoCpk8rO\\nvgZixf4Zu3Vi3cq+WroBp4ahL+BYa3AB7o1CH7vvc7M1U4N/g2sdSk8bxjfDaMNdr+hmAQAAAABJ\\nRU5ErkJggg==\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var rP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg32\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata38\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs36\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image40\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAACXBIWXMAAC4jAAAuIwF4pT92AAAA\\npklEQVRYw+3ZLQ4CMRCG4bcbFOvXg99T7FG4BafAw1VALx7dWyy2mIoGgSOZJu/n6p70ZybppFIK\\nvWSgo4gVK1asWLFixYoVK1asWLFixYoV+yO7r/UMHIAxiO8FZGBrsUfgDEwBN/QNXIA11S/PW1Bo\\nCz4N9ein4Nd1Dyw9PbDR0iVW7J+xudax6HkOtZVdg0MfQE7N0G4GlmANYgNW4A6QepowfgDMXB26\\nb1V6LAAAAABJRU5ErkJggg==\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var sP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg3823\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata3829\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs3827\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image3831\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAAAXNSR0IArs4c6QAAAARnQU1BAACx\\njwv8YQUAAAAJcEhZcwAALiMAAC4jAXilP3YAAAHOSURBVFhH1ZiLUcMwEEQNDcQl0AEuISVABZhO\\nUkroICVAB6ECoINQgdmVfR5FlmQrkZzjzezEzsc8NPqcdNd1XfVfuB9ec3NAmv4yiRo5ImzBlm+c\\nwZYtEHJCGsT3eSgHxKZFxs/tL+aMkCK8R3yMwu4PcsVmiXBIVDDCvh/miEtMeE5UaEsNMJcN8o64\\ng26PvPSXs9S+/zRHQtgtvLRFCb9blZpnYw/9Rb6RR3M3zxtiprFbyKYwipK1+uwlnIkSrbITUaJR\\n1itKtMkGRYk2WRZAQbTNBpzWtggrrwnaWja00hk0DrCgsEZZ4hXWKksmwjLAHobkgOv+V3+ZhXHQ\\niWxKqXYLKNyILDdqbPKlldASPhA+Mxc7uwatkSOSix1iP//q2APshLBvfJo7hbizgQj/mDtl+KYu\\nCj8h7NSqCM2zXJvZwqqEY4uCOuGYLKEwJ3kVzMlyscg5915FTFbdqhaSVbn8+mTV1gmurOqCxpZN\\nEeUu9BlZd1obioTkQ7IhPGTjYZuPIoUMK/GUFrX39asuHJTlH3w1d3FCBxCrCUufZX+NCUdPSsAq\\nwu4A8wnPiQrFhW1Z4govFRWKCoeOjzjoZF92CdwpZy6AquoPvJRHJxB8bJ8AAAAASUVORK5CYII=\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var aP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.76 13.76\"\\n height=\"13.76\"\\n width=\"13.76\"\\n id=\"svg42\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata48\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs46\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image50\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACsAAAArCAYAAADhXXHAAAAAAXNSR0IArs4c6QAAAARnQU1BAACx\\njwv8YQUAAAAJcEhZcwAALiMAAC4jAXilP3YAAAG/SURBVFhH1ZgxUsMwEEUNJRyAGmp6qKGn5xRQ\\nQ08NNfRQQw11DpAaanIAWrMv8WaELSlexhLLm/mRnImiF48jr7zVtm3zX9ju2ik5llxLdpdHNg4k\\nT5I7yWB8Cdl9yZHkRmIRRpQxOxK+YzC+hKwSnTBBKKoMxpeUBSbkksgRE1V+CJeWhUPJ5ao7ICeq\\nrIVryMKJpC88RlTZk1SThVDYIvoluZIsSqyz511SfEg4UxbRdw5qnlmFa9AsCn8hO4aBKHiUjYqC\\nN9mkKHiSzYqCJ9lPSVIUPMmySqTudEu8XbOxO90ab7KQFPYoC1Fhr7IwENbagMLCUtXnoCTM1QZW\\n3iS3dFT2mRfHvEjuVfZUckFnQh67dgqo1GYqC1MLn3XtZIR/sFcJW2C39FcD18KxpcutcGqddSmc\\nuykg/LDq+iAnC/OudUFOVrfLbkjJWvb11YjJuhSFvqxbUQhlXYuCylpE2YXy2SkLlVEgaxVluzyT\\nIEutWQ1kKZYtouF2maK4mjCyFN6bJsw9gKgmrNdsbsKNT0qEKsIqC7EJx4gqxYVDWQgntIgqRYXD\\nbY3CLpcVgmdPC974BYy3/MgRNM03hR9ubFTHT48AAAAASUVORK5CYII=\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.76\" />\\n</svg>\\n';var lP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.44 13.76\"\\n height=\"13.76\"\\n width=\"13.44\"\\n id=\"svg3803\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata3809\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs3807\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image3811\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACoAAAArCAYAAAAOnxr+AAAACXBIWXMAAC4jAAAuIwF4pT92AAAA\\nvElEQVRYw+3ZSw0CMRSF4b8T9iAFB4wDkDAWcICEkTA4GAeAA3AADurgsCkbAgsSMrmFczZNd1/a\\n3vSVJFFDGipJNdBZaRdAB2wC2TIwAgNAkrQEjsA86GBegDZJGoF18JnfJtVR9idXvaGGGmrod/b6\\nV9kD14k9LbD6FDqUM8CU2b2Deo0aaqihhhpqqKGGGhr1hH/wiP469FaBMzflEhc9PZKQ1CtmsqRO\\nEunpHbeNNN3A+dFJ/mf6V+gduGPIoUgKLbAAAAAASUVORK5CYII=\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.44\" />\\n</svg>\\n';var cP='<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\\n<svg\\n xmlns:dc=\"http://purl.org/dc/elements/1.1/\"\\n xmlns:cc=\"http://creativecommons.org/ns#\"\\n xmlns:rdf=\"http://www.w3.org/1999/02/22-rdf-syntax-ns#\"\\n xmlns:svg=\"http://www.w3.org/2000/svg\"\\n xmlns=\"http://www.w3.org/2000/svg\"\\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\\n viewBox=\"0 0 13.44 13.76\"\\n height=\"13.76\"\\n width=\"13.44\"\\n id=\"svg22\"\\n version=\"1.1\">\\n <metadata\\n id=\"metadata28\">\\n <rdf:RDF>\\n <cc:Work\\n rdf:about=\"\">\\n <dc:format>image/svg+xml</dc:format>\\n <dc:type\\n rdf:resource=\"http://purl.org/dc/dcmitype/StillImage\" />\\n <dc:title></dc:title>\\n </cc:Work>\\n </rdf:RDF>\\n </metadata>\\n <defs\\n id=\"defs26\" />\\n <image\\n y=\"0\"\\n x=\"0\"\\n id=\"image30\"\\n xlink:href=\"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACoAAAArCAYAAAAOnxr+AAAACXBIWXMAAC4jAAAuIwF4pT92AAAA\\nvUlEQVRYw+3ZsQ3CMBCF4d8WFekZgBqWIDUDZACmYBQWYIn0pGYAegZIexROERHRIBTdhXeVy08+\\nyT4/JzMjQmWCVBjoarSugK0z3/0degKODjeyBy5Am8ysARrnnT8nM7sCa+fQLgdAAlQ6ngQVVFBB\\nfzeUTK6t8VAwU328ztV6QQUVVFBBBRVUUEG9Ds41sJvZs/8GelDrlw7tAjhvmZLo9o6RD4bEGUp+\\nX1My/I0T4HN4rrcASf9M/wp9ASNzIKYYz2hAAAAAAElFTkSuQmCC\\n\"\\n style=\"image-rendering:optimizeQuality\"\\n preserveAspectRatio=\"none\"\\n height=\"13.76\"\\n width=\"13.44\" />\\n</svg>\\n';class dP{constructor(t){this.attributes=t;const e=navigator.userAgent.toLowerCase();const i=e.indexOf(\"android\")>-1;const n=e.indexOf(\"ipad\")>-1||e.indexOf(\"iphone\")>-1;this.iosSoftkeyboardOpened=false;this.iosMeasureUnit=e.indexOf(\"crios\")===-1?\"%\":\"vh\";this.iosDivHeight=`100%${this.iosMeasureUnit}`;const o=window.outerWidth;const r=window.outerHeight;const s=o>r;const a=o<r;const l=s&&this.attributes.height>r;const c=a&&this.attributes.width>o;const d=l||c;this.instanceId=document.getElementsByClassName(\"wrs_modal_dialogContainer\").length;this.deviceProperties={orientation:s?\"landscape\":\"portait\",isAndroid:i,isIOS:n,isMobile:d,isDesktop:!d&&!n&&!i};this.properties={created:false,state:\"\",previousState:\"\",position:{bottom:0,right:10},size:{height:338,width:580}};this.websiteBeforeLockParameters=null;let u={};u.class=\"wrs_modal_overlay\";u.id=this.getElementId(u.class);this.overlay=HT.createElement(\"div\",u);u={};u.class=\"wrs_modal_title_bar\";u.id=this.getElementId(u.class);this.titleBar=HT.createElement(\"div\",u);u={};u.class=\"wrs_modal_title\";u.id=this.getElementId(u.class);this.title=HT.createElement(\"div\",u);this.title.innerHTML=\"\";u={};u.class=\"wrs_modal_close_button\";u.id=this.getElementId(u.class);u.title=jT.get(\"close\");u.style={};this.closeDiv=HT.createElement(\"a\",u);this.closeDiv.setAttribute(\"role\",\"button\");let h=`background-size: 10px; background-image: url(data:image/svg+xml;base64,${window.btoa(tP)})`;let f=`background-size: 10px; background-image: url(data:image/svg+xml;base64,${window.btoa(eP)})`;this.closeDiv.setAttribute(\"style\",h);this.closeDiv.setAttribute(\"onmouseover\",`this.style = \"${f}\";`);this.closeDiv.setAttribute(\"onmouseout\",`this.style = \"${h}\";`);u={};u.class=\"wrs_modal_stack_button\";u.id=this.getElementId(u.class);u.title=jT.get(\"exit_fullscreen\");this.stackDiv=HT.createElement(\"a\",u);this.stackDiv.setAttribute(\"role\",\"button\");h=`background-size: 10px; background-image: url(data:image/svg+xml;base64,${window.btoa(sP)})`;f=`background-size: 10px; background-image: url(data:image/svg+xml;base64,${window.btoa(aP)})`;this.stackDiv.setAttribute(\"style\",h);this.stackDiv.setAttribute(\"onmouseover\",`this.style = \"${f}\";`);this.stackDiv.setAttribute(\"onmouseout\",`this.style = \"${h}\";`);u={};u.class=\"wrs_modal_maximize_button\";u.id=this.getElementId(u.class);u.title=jT.get(\"fullscreen\");this.maximizeDiv=HT.createElement(\"a\",u);this.maximizeDiv.setAttribute(\"role\",\"button\");h=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(iP)})`;f=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(nP)})`;this.maximizeDiv.setAttribute(\"style\",h);this.maximizeDiv.setAttribute(\"onmouseover\",`this.style = \"${f}\";`);this.maximizeDiv.setAttribute(\"onmouseout\",`this.style = \"${h}\";`);u={};u.class=\"wrs_modal_minimize_button\";u.id=this.getElementId(u.class);u.title=jT.get(\"minimize\");this.minimizeDiv=HT.createElement(\"a\",u);this.minimizeDiv.setAttribute(\"role\",\"button\");h=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(oP)})`;f=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(rP)})`;this.minimizeDiv.setAttribute(\"style\",h);this.minimizeDiv.setAttribute(\"onmouseover\",`this.style = \"${f}\";`);this.minimizeDiv.setAttribute(\"onmouseout\",`this.style = \"${h}\";`);u={};u.class=\"wrs_modal_dialogContainer\";u.id=this.getElementId(u.class);u.role=\"dialog\";this.container=HT.createElement(\"div\",u);this.container.setAttribute(\"aria-labeledby\",\"wrs_modal_title[0]\");u={};u.class=\"wrs_modal_wrapper\";u.id=this.getElementId(u.class);this.wrapper=HT.createElement(\"div\",u);u={};u.class=\"wrs_content_container\";u.id=this.getElementId(u.class);this.contentContainer=HT.createElement(\"div\",u);u={};u.class=\"wrs_modal_controls\";u.id=this.getElementId(u.class);this.controls=HT.createElement(\"div\",u);u={};u.class=\"wrs_modal_buttons_container\";u.id=this.getElementId(u.class);this.buttonContainer=HT.createElement(\"div\",u);this.submitButton=this.createSubmitButton({id:this.getElementId(\"wrs_modal_button_accept\"),class:\"wrs_modal_button_accept\",innerHTML:jT.get(\"accept\")},this.submitAction.bind(this));this.cancelButton=this.createSubmitButton({id:this.getElementId(\"wrs_modal_button_cancel\"),class:\"wrs_modal_button_cancel\",innerHTML:jT.get(\"cancel\")},this.cancelAction.bind(this));this.contentManager=null;const m={cancelString:jT.get(\"cancel\"),submitString:jT.get(\"close\"),message:jT.get(\"close_modal_warning\")};const g={closeCallback:()=>{this.close()},cancelCallback:()=>{this.focus()}};const p={overlayElement:this.container,callbacks:g,strings:m};this.popup=new ZT(p);this.rtl=false;if(\"rtl\"in this.attributes){this.rtl=this.attributes.rtl}this.handleOpenedIosSoftkeyboard=this.handleOpenedIosSoftkeyboard.bind(this);this.handleClosedIosSoftkeyboard=this.handleClosedIosSoftkeyboard.bind(this)}setContentManager(t){this.contentManager=t}getContentManager(){return this.contentManager}submitAction(){if(typeof this.contentManager.submitAction!==\"undefined\"){this.contentManager.submitAction()}this.close()}cancelAction(){if(typeof this.contentManager.hasChanges===\"undefined\"){this.close()}else if(!this.contentManager.hasChanges()){this.close()}else{this.showPopUpMessage()}}createSubmitButton(t,e){class i{constructor(){this.element=document.createElement(\"button\");this.element.id=t.id;this.element.className=t.class;this.element.innerHTML=t.innerHTML;HT.addEvent(this.element,\"click\",e)}getElement(){return this.element}}return new i(t,e).getElement()}create(){this.titleBar.appendChild(this.closeDiv);this.titleBar.appendChild(this.stackDiv);this.titleBar.appendChild(this.maximizeDiv);this.titleBar.appendChild(this.minimizeDiv);this.titleBar.appendChild(this.title);if(this.deviceProperties.isDesktop){this.container.appendChild(this.titleBar)}this.wrapper.appendChild(this.contentContainer);this.wrapper.appendChild(this.controls);this.controls.appendChild(this.buttonContainer);this.buttonContainer.appendChild(this.submitButton);this.buttonContainer.appendChild(this.cancelButton);this.container.appendChild(this.wrapper);this.recalculateScrollBar();document.body.appendChild(this.container);document.body.appendChild(this.overlay);if(this.deviceProperties.isDesktop){this.createModalWindowDesktop();this.createResizeButtons();this.addListeners();if(NT.get(\"modalWindowFullScreen\")){this.maximize()}}else if(this.deviceProperties.isAndroid){this.createModalWindowAndroid()}else if(this.deviceProperties.isIOS&&!this.deviceProperties.isMobile){this.createModalWindowIos()}if(this.contentManager!=null){this.contentManager.insert(this)}this.properties.open=true;this.properties.created=true;if(this.isRTL()){this.container.style.right=`${window.innerWidth-this.scrollbarWidth-this.container.offsetWidth}px`;this.container.className+=\" wrs_modal_rtl\"}}createResizeButtons(){this.resizerBR=document.createElement(\"div\");this.resizerBR.className=\"wrs_bottom_right_resizer\";this.resizerBR.innerHTML=\"◢\";this.resizerTL=document.createElement(\"div\");this.resizerTL.className=\"wrs_bottom_left_resizer\";this.container.appendChild(this.resizerBR);this.titleBar.appendChild(this.resizerTL);HT.addEvent(this.resizerBR,\"mousedown\",this.activateResizeStateBR.bind(this));HT.addEvent(this.resizerTL,\"mousedown\",this.activateResizeStateTL.bind(this))}activateResizeStateBR(t){this.initializeResizeProperties(t,false)}activateResizeStateTL(t){this.initializeResizeProperties(t,true)}initializeResizeProperties(t,e){HT.addClass(document.body,\"wrs_noselect\");HT.addClass(this.overlay,\"wrs_overlay_active\");this.resizeDataObject={x:this.eventClient(t).X,y:this.eventClient(t).Y};this.initialWidth=parseInt(this.container.style.width,10);this.initialHeight=parseInt(this.container.style.height,10);if(!e){this.initialRight=parseInt(this.container.style.right,10);this.initialBottom=parseInt(this.container.style.bottom,10)}else{this.leftScale=true}if(!this.initialRight){this.initialRight=0}if(!this.initialBottom){this.initialBottom=0}document.body.style[\"user-select\"]=\"none\"}open(){this.removeClass(\"wrs_closed\");const{isIOS:t}=this.deviceProperties;const{isAndroid:e}=this.deviceProperties;const{isMobile:i}=this.deviceProperties;if(t||e||i){this.restoreWebsiteScale();this.lockWebsiteScroll();setTimeout(()=>{this.hideKeyboard()},400)}if(!this.properties.created){this.create()}else{if(!this.properties.open){this.properties.open=true;if(!this.deviceProperties.isAndroid&&!this.deviceProperties.isIOS){this.restoreState()}}if(this.deviceProperties.isDesktop&&NT.get(\"modalWindowFullScreen\")){this.maximize()}if(this.deviceProperties.isIOS){this.iosSoftkeyboardOpened=false;this.setContainerHeight(`${100+this.iosMeasureUnit}`)}}if(!JT.isEditorLoaded()){const t=VT.newListener(\"onLoad\",()=>{this.contentManager.onOpen(this)});this.contentManager.addListener(t)}else{this.contentManager.onOpen(this)}}close(){this.removeClass(\"wrs_maximized\");this.removeClass(\"wrs_minimized\");this.removeClass(\"wrs_stack\");this.addClass(\"wrs_closed\");this.saveModalProperties();this.unlockWebsiteScroll();this.properties.open=false}restoreWebsiteScale(){let t=document.querySelector(\"meta[name=viewport]\");const e=[\"initial-scale=\",\"minimum-scale=\",\"maximum-scale=\"];const i=[\"1.0\",\"1.0\",\"1.0\"];const n=(t,e)=>{const n=t.getAttribute(\"content\");if(n){const o=n.split(\",\");let r=\"\";const s=[];for(let t=0;t<o.length;t+=1){let i=false;let n=0;while(!i&&n<e.length){if(o[t].indexOf(e[n])){i=true}n+=1}if(!i){s.push(o[t])}}for(let t=0;t<e.length;t+=1){const n=e[t]+i[t];r+=t===0?n:`,${n}`}for(let t=0;t<s.length;t+=1){r+=`,${s[t]}`}t.setAttribute(\"content\",r);t.setAttribute(\"content\",\"\");t.setAttribute(\"content\",n)}else{t.setAttribute(\"content\",\"initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0\");t.removeAttribute(\"content\")}};if(!t){t=document.createElement(\"meta\");document.getElementsByTagName(\"head\")[0].appendChild(t);n(t,e,i);t.remove()}else{n(t,e,i)}}lockWebsiteScroll(){this.websiteBeforeLockParameters={bodyStylePosition:document.body.style.position?document.body.style.position:\"\",bodyStyleOverflow:document.body.style.overflow?document.body.style.overflow:\"\",htmlStyleOverflow:document.documentElement.style.overflow?document.documentElement.style.overflow:\"\",windowScrollX:window.scrollX,windowScrollY:window.scrollY}}unlockWebsiteScroll(){if(this.websiteBeforeLockParameters){document.body.style.position=this.websiteBeforeLockParameters.bodyStylePosition;document.body.style.overflow=this.websiteBeforeLockParameters.bodyStyleOverflow;document.documentElement.style.overflow=this.websiteBeforeLockParameters.htmlStyleOverflow;const{windowScrollX:t}=this.websiteBeforeLockParameters;const{windowScrollY:e}=this.websiteBeforeLockParameters;window.scrollTo(t,e);this.websiteBeforeLockParameters=null}}isIE11(){if(navigator.userAgent.search(\"Msie/\")>=0||navigator.userAgent.search(\"Trident/\")>=0||navigator.userAgent.search(\"Edge/\")>=0){return true}return false}isRTL(){if(this.attributes.language===\"ar\"||this.attributes.language===\"he\"){return true}return this.rtl}addClass(t){HT.addClass(this.overlay,t);HT.addClass(this.titleBar,t);HT.addClass(this.overlay,t);HT.addClass(this.container,t);HT.addClass(this.contentContainer,t);HT.addClass(this.stackDiv,t);HT.addClass(this.minimizeDiv,t);HT.addClass(this.maximizeDiv,t);HT.addClass(this.wrapper,t)}removeClass(t){HT.removeClass(this.overlay,t);HT.removeClass(this.titleBar,t);HT.removeClass(this.overlay,t);HT.removeClass(this.container,t);HT.removeClass(this.contentContainer,t);HT.removeClass(this.stackDiv,t);HT.removeClass(this.minimizeDiv,t);HT.removeClass(this.maximizeDiv,t);HT.removeClass(this.wrapper,t)}createModalWindowDesktop(){this.addClass(\"wrs_modal_desktop\");this.stack()}createModalWindowAndroid(){this.addClass(\"wrs_modal_android\");window.addEventListener(\"resize\",this.orientationChangeAndroidSoftkeyboard.bind(this))}createModalWindowIos(){this.addClass(\"wrs_modal_ios\");window.addEventListener(\"resize\",this.orientationChangeIosSoftkeyboard.bind(this))}restoreState(){if(this.properties.state===\"maximized\"){this.maximize()}else if(this.properties.state===\"minimized\"){this.properties.state=this.properties.previousState;this.properties.previousState=\"\";this.minimize()}else{this.stack()}}stack(){this.properties.previousState=this.properties.state;this.properties.state=\"stack\";this.removeClass(\"wrs_maximized\");this.minimizeDiv.title=jT.get(\"minimize\");this.removeClass(\"wrs_minimized\");this.addClass(\"wrs_stack\");const t=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(oP)})`;const e=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(rP)})`;this.minimizeDiv.setAttribute(\"style\",t);this.minimizeDiv.setAttribute(\"onmouseover\",`this.style = \"${e}\";`);this.minimizeDiv.setAttribute(\"onmouseout\",`this.style = \"${t}\";`);this.restoreModalProperties();if(typeof this.resizerBR!==\"undefined\"&&typeof this.resizerTL!==\"undefined\"){this.setResizeButtonsVisibility()}this.recalculateScrollBar();this.recalculatePosition();this.recalculateScale();this.focus()}minimize(){this.saveModalProperties();this.title.style.cursor=\"pointer\";if(this.properties.state===\"minimized\"&&this.properties.previousState===\"stack\"){this.stack()}else if(this.properties.state===\"minimized\"&&this.properties.previousState===\"maximized\"){this.maximize()}else{this.container.style.height=\"30px\";this.container.style.width=\"250px\";this.container.style.bottom=\"0px\";this.container.style.right=\"10px\";this.removeListeners();this.properties.previousState=this.properties.state;this.properties.state=\"minimized\";this.setResizeButtonsVisibility();this.minimizeDiv.title=jT.get(\"maximize\");if(HT.containsClass(this.overlay,\"wrs_stack\")){this.removeClass(\"wrs_stack\")}else{this.removeClass(\"wrs_maximized\")}this.addClass(\"wrs_minimized\");const t=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(lP)})`;const e=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(cP)})`;this.minimizeDiv.setAttribute(\"style\",t);this.minimizeDiv.setAttribute(\"onmouseover\",`this.style = \"${e}\";`);this.minimizeDiv.setAttribute(\"onmouseout\",`this.style = \"${t}\";`)}}maximize(){this.saveModalProperties();if(this.properties.state!==\"maximized\"){this.properties.previousState=this.properties.state;this.properties.state=\"maximized\"}this.setResizeButtonsVisibility();if(HT.containsClass(this.overlay,\"wrs_minimized\")){this.minimizeDiv.title=jT.get(\"minimize\");this.removeClass(\"wrs_minimized\")}else if(HT.containsClass(this.overlay,\"wrs_stack\")){this.container.style.left=null;this.container.style.top=null;this.removeClass(\"wrs_stack\")}this.addClass(\"wrs_maximized\");const t=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(oP)})`;const e=`background-size: 10px; background-repeat: no-repeat; background-image: url(data:image/svg+xml;base64,${window.btoa(rP)})`;this.minimizeDiv.setAttribute(\"style\",t);this.minimizeDiv.setAttribute(\"onmouseover\",`this.style = \"${e}\";`);this.minimizeDiv.setAttribute(\"onmouseout\",`this.style = \"${t}\";`);this.setSize(parseInt(window.innerHeight*.8,10),parseInt(window.innerWidth*.8,10));if(this.container.clientHeight>700){this.container.style.height=\"700px\"}if(this.container.clientWidth>1200){this.container.style.width=\"1200px\"}const{innerHeight:i}=window;const{innerWidth:n}=window;const{offsetHeight:o}=this.container;const{offsetWidth:r}=this.container;const s=i/2-o/2;const a=n/2-r/2;this.setPosition(s,a);this.recalculateScale();this.recalculatePosition();this.recalculateSize();this.focus()}reExpand(){if(this.properties.state===\"minimized\"){if(this.properties.previousState===\"maximized\"){this.maximize()}else{this.stack()}this.title.style.cursor=\"\"}}setSize(t,e){this.container.style.height=`${t}px`;this.container.style.width=`${e}px`;this.recalculateSize()}setPosition(t,e){this.container.style.bottom=`${t}px`;this.container.style.right=`${e}px`}saveModalProperties(){if(this.properties.state===\"stack\"){this.properties.position.bottom=parseInt(this.container.style.bottom,10);this.properties.position.right=parseInt(this.container.style.right,10);this.properties.size.width=parseInt(this.container.style.width,10);this.properties.size.height=parseInt(this.container.style.height,10)}}restoreModalProperties(){if(this.properties.state===\"stack\"){this.setPosition(this.properties.position.bottom,this.properties.position.right);this.setSize(this.properties.size.height,this.properties.size.width)}}recalculateSize(){this.wrapper.style.width=`${this.container.clientWidth-12}px`;this.wrapper.style.height=`${this.container.clientHeight-38}px`;this.contentContainer.style.height=`${parseInt(this.wrapper.offsetHeight-50,10)}px`}setResizeButtonsVisibility(){if(this.properties.state===\"stack\"){this.resizerTL.style.visibility=\"visible\";this.resizerBR.style.visibility=\"visible\"}else{this.resizerTL.style.visibility=\"hidden\";this.resizerBR.style.visibility=\"hidden\"}}addListeners(){this.maximizeDiv.addEventListener(\"click\",this.maximize.bind(this),true);this.stackDiv.addEventListener(\"click\",this.stack.bind(this),true);this.minimizeDiv.addEventListener(\"click\",this.minimize.bind(this),true);this.closeDiv.addEventListener(\"click\",this.cancelAction.bind(this));this.title.addEventListener(\"click\",this.reExpand.bind(this));this.overlay.addEventListener(\"click\",this.cancelAction.bind(this));HT.addEvent(window,\"mousedown\",this.startDrag.bind(this));HT.addEvent(window,\"mouseup\",this.stopDrag.bind(this));HT.addEvent(window,\"mousemove\",this.drag.bind(this));HT.addEvent(window,\"resize\",this.onWindowResize.bind(this));HT.addEvent(this.container,\"keydown\",this.onKeyDown.bind(this))}removeListeners(){HT.removeEvent(window,\"mousedown\",this.startDrag);HT.removeEvent(window,\"mouseup\",this.stopDrag);HT.removeEvent(window,\"mousemove\",this.drag);HT.removeEvent(window,\"resize\",this.onWindowResize);HT.removeEvent(this.container,\"keydown\",this.onKeyDown)}eventClient(t){if(typeof t.clientX===\"undefined\"&&t.changedTouches){const e={X:t.changedTouches[0].clientX,Y:t.changedTouches[0].clientY};return e}const e={X:t.clientX,Y:t.clientY};return e}startDrag(t){if(this.properties.state===\"minimized\"){return}if(t.target===this.title){if(typeof this.dragDataObject===\"undefined\"||this.dragDataObject===null){this.dragDataObject={x:this.eventClient(t).X,y:this.eventClient(t).Y};this.lastDrag={x:\"0px\",y:\"0px\"};if(this.container.style.right===\"\"){this.container.style.right=\"0px\"}if(this.container.style.bottom===\"\"){this.container.style.bottom=\"0px\"}if(this.isIE11()){}HT.addClass(document.body,\"wrs_noselect\");HT.addClass(this.overlay,\"wrs_overlay_active\");this.limitWindow=this.getLimitWindow()}}}drag(t){if(this.dragDataObject){t.preventDefault();let e=Math.min(this.eventClient(t).Y,this.limitWindow.minPointer.y);e=Math.max(this.limitWindow.maxPointer.y,e);let i=Math.min(this.eventClient(t).X,this.limitWindow.minPointer.x);i=Math.max(this.limitWindow.maxPointer.x,i);const n=`${i-this.dragDataObject.x}px`;const o=`${e-this.dragDataObject.y}px`;this.lastDrag={x:n,y:o};this.container.style.transform=`translate3d(${n},${o},0)`}if(this.resizeDataObject){const{innerWidth:e}=window;const{innerHeight:i}=window;let n=Math.min(this.eventClient(t).X,e-this.scrollbarWidth-7);let o=Math.min(this.eventClient(t).Y,i-7);if(n<0){n=0}if(o<0){o=0}let r;if(this.leftScale){r=-1}else{r=1}this.container.style.width=`${this.initialWidth+r*(n-this.resizeDataObject.x)}px`;this.container.style.height=`${this.initialHeight+r*(o-this.resizeDataObject.y)}px`;if(!this.leftScale){if(this.resizeDataObject.x-n-this.initialWidth<-580){this.container.style.right=`${this.initialRight-(n-this.resizeDataObject.x)}px`}else{this.container.style.right=`${this.initialRight+this.initialWidth-580}px`;this.container.style.width=\"580px\"}if(this.resizeDataObject.y-o<this.initialHeight-338){this.container.style.bottom=`${this.initialBottom-(o-this.resizeDataObject.y)}px`}else{this.container.style.bottom=`${this.initialBottom+this.initialHeight-338}px`;this.container.style.height=\"338px\"}}this.recalculateScale();this.recalculatePosition()}}getLimitWindow(){const t=window.innerWidth;const e=window.innerHeight;const{offsetHeight:i}=this.container;const n=parseInt(this.container.style.bottom,10);const o=parseInt(this.container.style.right,10);const{pageXOffset:r}=window;const s=this.dragDataObject.y;const a=this.dragDataObject.x;const l=i+n-(e-(s-r));const c=t-this.scrollbarWidth-(a-r)-o;const d=e-this.container.offsetHeight+l;const u=this.title.offsetHeight-(this.title.offsetHeight-l);const h=t-c-this.scrollbarWidth;const f=this.container.offsetWidth-c;const m={x:h,y:d};const g={x:f,y:u};return{minPointer:m,maxPointer:g}}getScrollBarWidth(){const t=document.createElement(\"p\");t.style.width=\"100%\";t.style.height=\"200px\";const e=document.createElement(\"div\");e.style.position=\"absolute\";e.style.top=\"0px\";e.style.left=\"0px\";e.style.visibility=\"hidden\";e.style.width=\"200px\";e.style.height=\"150px\";e.style.overflow=\"hidden\";e.appendChild(t);document.body.appendChild(e);const i=t.offsetWidth;e.style.overflow=\"scroll\";let n=t.offsetWidth;if(i===n){n=e.clientWidth}document.body.removeChild(e);return i-n}stopDrag(){if(this.dragDataObject||this.resizeDataObject){this.container.style.transform=\"\";if(this.dragDataObject){this.container.style.right=`${parseInt(this.container.style.right,10)-parseInt(this.lastDrag.x,10)}px`;this.container.style.bottom=`${parseInt(this.container.style.bottom,10)-parseInt(this.lastDrag.y,10)}px`}this.focus();document.body.style[\"user-select\"]=\"\";if(this.isIE11()){}HT.removeClass(document.body,\"wrs_noselect\");HT.removeClass(this.overlay,\"wrs_overlay_active\")}this.dragDataObject=null;this.resizeDataObject=null;this.initialWidth=null;this.leftScale=null}onWindowResize(){this.recalculateScrollBar();this.recalculatePosition();this.recalculateScale()}onKeyDown(t){if(t.key!==undefined){if(this.popup.overlayWrapper.style.display!==\"block\"){if(t.key===\"Escape\"||t.key===\"Esc\"){if(this.properties.open){this.contentManager.onKeyDown(t)}}else if(t.shiftKey&&t.key===\"Tab\"){if(document.activeElement===this.cancelButton){this.submitButton.focus();t.stopPropagation();t.preventDefault()}else{this.contentManager.onKeyDown(t)}}else if(t.key===\"Tab\"){if(document.activeElement===this.submitButton){this.cancelButton.focus();t.stopPropagation();t.preventDefault()}else{this.contentManager.onKeyDown(t)}}}else{this.popup.onKeyDown(t)}}}recalculatePosition(){this.container.style.right=`${Math.min(parseInt(this.container.style.right,10),window.innerWidth-this.scrollbarWidth-this.container.offsetWidth)}px`;if(parseInt(this.container.style.right,10)<0){this.container.style.right=\"0px\"}this.container.style.bottom=`${Math.min(parseInt(this.container.style.bottom,10),window.innerHeight-this.container.offsetHeight)}px`;if(parseInt(this.container.style.bottom,10)<0){this.container.style.bottom=\"0px\"}}recalculateScale(){let t=false;if(parseInt(this.container.style.width,10)>580){this.container.style.width=`${Math.min(parseInt(this.container.style.width,10),window.innerWidth-this.scrollbarWidth)}px`;t=true}else{this.container.style.width=\"580px\";t=true}if(parseInt(this.container.style.height,10)>338){this.container.style.height=`${Math.min(parseInt(this.container.style.height,10),window.innerHeight)}px`;t=true}else{this.container.style.height=\"338px\";t=true}if(t){this.recalculateSize()}}recalculateScrollBar(){this.hasScrollBar=window.innerWidth>document.documentElement.clientWidth;if(this.hasScrollBar){this.scrollbarWidth=this.getScrollBarWidth()}else{this.scrollbarWidth=0}}hideKeyboard(){const t=document.createElement(\"input\");this.container.appendChild(t);t.focus();t.blur();t.remove()}focus(){if(this.contentManager!=null&&typeof this.contentManager.onFocus!==\"undefined\"){this.contentManager.onFocus()}}portraitMode(){return window.innerHeight>window.innerWidth}handleOpenedIosSoftkeyboard(){if(!this.iosSoftkeyboardOpened&&this.iosDivHeight!=null&&this.iosDivHeight===`100${this.iosMeasureUnit}`){if(this.portraitMode()){this.setContainerHeight(`63${this.iosMeasureUnit}`)}else{this.setContainerHeight(`40${this.iosMeasureUnit}`)}}this.iosSoftkeyboardOpened=true}handleClosedIosSoftkeyboard(){this.iosSoftkeyboardOpened=false;this.setContainerHeight(`100${this.iosMeasureUnit}`)}orientationChangeIosSoftkeyboard(){if(this.iosSoftkeyboardOpened){if(this.portraitMode()){this.setContainerHeight(`63${this.iosMeasureUnit}`)}else{this.setContainerHeight(`40${this.iosMeasureUnit}`)}}else{this.setContainerHeight(`100${this.iosMeasureUnit}`)}}orientationChangeAndroidSoftkeyboard(){this.setContainerHeight(\"100%\")}setContainerHeight(t){this.iosDivHeight=t;this.wrapper.style.height=t}showPopUpMessage(){if(this.properties.state===\"minimized\"){this.stack()}this.popup.show()}setTitle(t){this.title.innerHTML=t}getElementId(t){return`${t}[${this.instanceId}]`}}var uP;var hP=uP;\n/*! http://mths.be/codepointat v0.1.0 by @mathias */if(!String.prototype.codePointAt){(function(){\"use strict\";var t=function(t){if(this==null){throw TypeError()}var e=String(this);var i=e.length;var n=t?Number(t):0;if(n!=n){n=0}if(n<0||n>=i){return undefined}var o=e.charCodeAt(n);var r;if(o>=55296&&o<=56319&&i>n+1){r=e.charCodeAt(n+1);if(r>=56320&&r<=57343){return(o-55296)*1024+r-56320+65536}}return o};if(Object.defineProperty){Object.defineProperty(String.prototype,\"codePointAt\",{value:t,configurable:true,writable:true})}else{String.prototype.codePointAt=t}})()}if(typeof Object.assign!=\"function\"){Object.defineProperty(Object,\"assign\",{value:function t(e,i){\"use strict\";if(e==null){throw new TypeError(\"Cannot convert undefined or null to object\")}var n=Object(e);for(var o=1;o<arguments.length;o++){var r=arguments[o];if(r!=null){for(var s in r){if(Object.prototype.hasOwnProperty.call(r,s)){n[s]=r[s]}}}}return n},writable:true,configurable:true})}var fP=i(86);class mP{constructor(t){this.language=\"en\";this.editMode=\"images\";this.modalDialog=null;this.customEditors=new KT;const e={name:\"Chemistry\",toolbar:\"chemistry\",icon:\"chem.png\",confVariable:\"chemEnabled\",title:\"ChemType\",tooltip:\"Insert a chemistry formula - ChemType\"};this.customEditors.addEditor(\"chemistry\",e);this.environment={};this.editionProperties={};this.editionProperties.isNewElement=true;this.editionProperties.temporalImage=null;this.editionProperties.latexRange=null;this.editionProperties.range=null;this.integrationModel=null;this.contentManager=null;this.browser=(()=>{const t=navigator.userAgent;let e=\"none\";if(t.search(\"Edge/\")>=0){e=\"EDGE\"}else if(t.search(\"Chrome/\")>=0){e=\"CHROME\"}else if(t.search(\"Trident/\")>=0){e=\"IE\"}else if(t.search(\"Firefox/\")>=0){e=\"FIREFOX\"}else if(t.search(\"Safari/\")>=0){e=\"SAFARI\"}return e})();this.listeners=new VT;this.serviceProviderProperties={};if(\"serviceProviderProperties\"in t){this.serviceProviderProperties=t.serviceProviderProperties}else{throw new Error(\"serviceProviderProperties property missing.\")}}static get globalListeners(){return mP._globalListeners}static set globalListeners(t){mP._globalListeners=t}static get initialized(){return mP._initialized}static set initialized(t){mP._initialized=t}setIntegrationModel(t){this.integrationModel=t}setEnvironment(t){if(\"editor\"in t){this.environment.editor=t.editor}if(\"mode\"in t){this.environment.mode=t.mode}if(\"version\"in t){this.environment.version=t.version}}getModalDialog(){return this.modalDialog}init(){if(!mP.initialized){const t=VT.newListener(\"onInit\",()=>{const t=DT.getService(\"configurationjs\",\"\",\"get\");const e=JSON.parse(t);NT.addConfiguration(e);NT.addConfiguration(YT);jT.language=this.language;this.listeners.fire(\"onLoad\",{})});DT.addListener(t);DT.init(this.serviceProviderProperties);mP.initialized=true}else{this.listeners.fire(\"onLoad\",{})}}addListener(t){this.listeners.add(t)}static addGlobalListener(t){mP.globalListeners.add(t)}beforeUpdateFormula(t,e){const i=new QT;i.mathml=t;i.wirisProperties={};if(e!=null){Object.keys(e).forEach(t=>{i.wirisProperties[t]=e[t]})}i.language=this.language;i.editMode=this.editMode;if(this.listeners.fire(\"onBeforeFormulaInsertion\",i)){return{}}if(mP.globalListeners.fire(\"onBeforeFormulaInsertion\",i)){return{}}return{mathml:i.mathml,wirisProperties:i.wirisProperties}}insertFormula(t,e,i,n){const o={};if(!i){this.insertElementOnSelection(null,t,e)}else if(this.editMode===\"latex\"){o.latex=zT.getLatexFromMathML(i);if(!!this.integrationModel.fillNonLatexNode&&!o.latex){const n=new QT;n.editMode=this.editMode;n.windowTarget=e;n.focusElement=t;n.latex=o.latex;this.integrationModel.fillNonLatexNode(n,e,i)}else{o.node=e.document.createTextNode(`$$${o.latex}$$`)}this.insertElementOnSelection(o.node,t,e)}else{o.node=UT.mathmlToImgObject(e.document,i,n,this.language);this.insertElementOnSelection(o.node,t,e)}return o}afterUpdateFormula(t,e,i,n){const o=new QT;o.editMode=this.editMode;o.windowTarget=e;o.focusElement=t;o.node=i;o.latex=n;if(this.listeners.fire(\"onAfterFormulaInsertion\",o)){return{}}if(mP.globalListeners.fire(\"onAfterFormulaInsertion\",o)){return{}}return{}}placeCaretAfterNode(t){this.integrationModel.getSelection();const e=t.ownerDocument;if(typeof e.getSelection!==\"undefined\"&&!!t.parentElement){const i=e.createRange();i.setStartAfter(t);i.collapse(true);const n=e.getSelection();n.removeAllRanges();n.addRange(i);e.body.focus()}}insertElementOnSelection(t,e,i){if(this.editionProperties.isNewElement){if(t){if(e.type===\"textarea\"){HT.updateTextArea(e,t.textContent)}else if(document.selection&&document.getSelection===0){let e=i.document.selection.createRange();i.document.execCommand(\"InsertImage\",false,t.src);if(!(\"parentElement\"in e)){i.document.execCommand(\"delete\",false);e=i.document.selection.createRange();i.document.execCommand(\"InsertImage\",false,t.src)}if(\"parentElement\"in e){const i=e.parentElement();if(i.nodeName.toUpperCase()===\"IMG\"){i.parentNode.replaceChild(t,i)}else{e.pasteHTML(HT.createObjectCode(t))}}}else{const e=this.integrationModel.getSelection();let i=null;if(this.editionProperties.range){({range:i}=this.editionProperties);this.editionProperties.range=null}else{i=e.getRangeAt(0)}i.deleteContents();let n=i.startContainer;const o=i.startOffset;if(n.nodeType===3){n=n.splitText(o);n.parentNode.insertBefore(t,n)}else if(n.nodeType===1){n.insertBefore(t,n.childNodes[o])}this.placeCaretAfterNode(t)}}else if(e.type===\"textarea\"){e.focus()}else{const t=this.integrationModel.getSelection();t.removeAllRanges();if(this.editionProperties.range){const{range:e}=this.editionProperties;this.editionProperties.range=null;t.addRange(e)}}}else if(this.editionProperties.latexRange){if(document.selection&&document.getSelection===0){this.editionProperties.isNewElement=true;this.editionProperties.latexRange.select();this.insertElementOnSelection(t,e,i)}else{this.editionProperties.latexRange.deleteContents();this.editionProperties.latexRange.insertNode(t);this.placeCaretAfterNode(t)}}else if(e.type===\"textarea\"){let i;if(typeof this.integrationModel.getSelectedItem!==\"undefined\"){i=this.integrationModel.getSelectedItem(e,false)}else{i=HT.getSelectedItemOnTextarea(e)}HT.updateExistingTextOnTextarea(e,t.textContent,i.startPosition,i.endPosition)}else{if(t&&t.nodeName.toLowerCase()===\"img\"){WT.removeImgDataAttributes(this.editionProperties.temporalImage);WT.clone(t,this.editionProperties.temporalImage)}else{this.editionProperties.temporalImage.remove()}this.placeCaretAfterNode(this.editionProperties.temporalImage)}}openModalDialog(t,e){this.editMode=\"images\";try{if(e){t.contentWindow.focus();const e=t.contentWindow.getSelection();this.editionProperties.range=e.getRangeAt(0)}else{t.focus();const e=getSelection();this.editionProperties.range=e.getRangeAt(0)}}catch(t){this.editionProperties.range=null}if(e===undefined){e=true}this.editionProperties.latexRange=null;if(t){let i;if(typeof this.integrationModel.getSelectedItem!==\"undefined\"){i=this.integrationModel.getSelectedItem(t,e)}else{i=HT.getSelectedItem(t,e)}if(i){if(!i.caretPosition&&HT.containsClass(i.node,NT.get(\"imageClassName\"))){this.editionProperties.temporalImage=i.node;this.editionProperties.isNewElement=false}else if(i.node.nodeType===3){if(this.integrationModel.getMathmlFromTextNode){const t=this.integrationModel.getMathmlFromTextNode(i.node,i.caretPosition);if(t){this.editMode=\"latex\";this.editionProperties.isNewElement=false;this.editionProperties.temporalImage=document.createElement(\"img\");this.editionProperties.temporalImage.setAttribute(NT.get(\"imageMathmlAttribute\"),LT.safeXmlEncode(t))}}else{const n=zT.getLatexFromTextNode(i.node,i.caretPosition);if(n){const i=zT.getMathMLFromLatex(n.latex);this.editMode=\"latex\";this.editionProperties.isNewElement=false;this.editionProperties.temporalImage=document.createElement(\"img\");this.editionProperties.temporalImage.setAttribute(NT.get(\"imageMathmlAttribute\"),LT.safeXmlEncode(i));const o=e?t.contentWindow:window;if(t.tagName.toLowerCase()!==\"textarea\"){if(document.selection){let t=0;let e=n.startNode.previousSibling;while(e){t+=HT.getNodeLength(e);e=e.previousSibling}this.editionProperties.latexRange=o.document.selection.createRange();this.editionProperties.latexRange.moveToElementText(n.startNode.parentNode);this.editionProperties.latexRange.move(\"character\",t+n.startPosition);this.editionProperties.latexRange.moveEnd(\"character\",n.latex.length+4)}else{this.editionProperties.latexRange=o.document.createRange();this.editionProperties.latexRange.setStart(n.startNode,n.startPosition);this.editionProperties.latexRange.setEnd(n.endNode,n.endPosition)}}}}}}else if(t.tagName.toLowerCase()===\"textarea\"){this.editMode=\"latex\"}}const i=NT.get(\"editorAttributes\").split(\", \");const n={};for(let t=0,e=i.length;t<e;t+=1){const e=i[t].split(\"=\");const o=e[0];const r=e[1];n[o]=r}const o={};const r=NT.get(\"editorParameters\");const s=this.integrationModel.editorParameters;Object.assign(o,n,r);Object.assign(o,n,s);o.language=this.language;o.rtl=this.integrationModel.rtl;const a={};a.editorAttributes=o;a.language=this.language;a.customEditors=this.customEditors;a.environment=this.environment;if(this.modalDialog==null){this.modalDialog=new dP(o);this.contentManager=new JT(a);const t=VT.newListener(\"onLoad\",()=>{this.contentManager.isNewElement=this.editionProperties.isNewElement;if(this.editionProperties.temporalImage!=null){const t=LT.safeXmlDecode(this.editionProperties.temporalImage.getAttribute(NT.get(\"imageMathmlAttribute\")));this.contentManager.mathML=t}});this.contentManager.addListener(t);this.contentManager.init();this.modalDialog.setContentManager(this.contentManager);this.contentManager.setModalDialogInstance(this.modalDialog)}else{this.contentManager.isNewElement=this.editionProperties.isNewElement;if(this.editionProperties.temporalImage!=null){const t=LT.safeXmlDecode(this.editionProperties.temporalImage.getAttribute(NT.get(\"imageMathmlAttribute\")));this.contentManager.mathML=t}}this.contentManager.setIntegrationModel(this.integrationModel);this.modalDialog.open()}getCustomEditors(){return this.customEditors}}mP._globalListeners=new VT;mP._initialized=false;class gP{constructor(t){this.language=\"en\";this.serviceProviderProperties={};if(\"serviceProviderProperties\"in t){this.serviceProviderProperties=t.serviceProviderProperties}this.configurationService=\"\";if(\"configurationService\"in t){this.serviceProviderProperties.URI=t.configurationService;console.warn(\"Deprecated property configurationService. Use serviceParameters on instead.\",[t.configurationService])}this.version=\"version\"in t?t.version:\"\";this.target=null;if(\"target\"in t){this.target=t.target}else{throw new Error(\"IntegrationModel constructor error: target property missed.\")}if(\"scriptName\"in t){this.scriptName=t.scriptName}this.callbackMethodArguments={};if(\"callbackMethodArguments\"in t){this.callbackMethodArguments=t.callbackMethodArguments}this.environment={};if(\"environment\"in t){this.environment=t.environment}this.isIframe=false;if(this.target!=null){this.isIframe=this.target.tagName.toUpperCase()===\"IFRAME\"}this.editorObject=null;if(\"editorObject\"in t){this.editorObject=t.editorObject}this.rtl=false;if(\"rtl\"in t){this.rtl=t.rtl}this.managesLanguage=false;if(\"managesLanguage\"in t){this.managesLanguage=t.managesLanguage}this.temporalImageResizing=false;this.core=null;this.listeners=new VT;if(\"integrationParameters\"in t){gP.integrationParameters.forEach(e=>{if(e in t.integrationParameters){const i=t.integrationParameters[e];if(Object.keys(i).length!==0){this[e]=i}}})}}init(){this.language=this.getLanguage();const t=VT.newListener(\"onLoad\",()=>{this.callbackFunction(this.callbackMethodArguments)});if(this.serviceProviderProperties.URI.indexOf(\"configuration\")!==-1){const t=this.serviceProviderProperties.URI;const e=DT.getServerLanguageFromService(t);this.serviceProviderProperties.server=e;const i=this.serviceProviderProperties.URI.indexOf(\"configuration\");const n=this.serviceProviderProperties.URI.substring(0,i);this.serviceProviderProperties.URI=n}let e=this.serviceProviderProperties.URI;e=e.indexOf(\"/\")===0||e.indexOf(\"http\")===0?e:HT.concatenateUrl(this.getPath(),e);this.serviceProviderProperties.URI=e;const i={};i.serviceProviderProperties=this.serviceProviderProperties;this.setCore(new mP(i));this.core.addListener(t);this.core.language=this.language;this.core.init();this.core.setEnvironment(this.environment)}getPath(){if(typeof this.scriptName===\"undefined\"){throw new Error(\"scriptName property needed for getPath.\")}const t=document.getElementsByTagName(\"script\");let e=\"\";for(let i=0;i<t.length;i+=1){const n=t[i].src.lastIndexOf(this.scriptName);if(n>=0){e=t[i].src.substr(0,n-1)}}return e}getVersion(){return this.version}setLanguage(t){this.language=t}setCore(t){this.core=t;t.setIntegrationModel(this)}getCore(){return this.core}setTarget(t){this.target=t;this.isIframe=this.target.tagName.toUpperCase()===\"IFRAME\"}setEditorObject(t){this.editorObject=t}openNewFormulaEditor(){this.core.editionProperties.isNewElement=true;this.core.openModalDialog(this.target,this.isIframe)}openExistingFormulaEditor(){this.core.editionProperties.isNewElement=false;this.core.openModalDialog(this.target,this.isIframe)}updateFormula(t){if(this.editorParameters){t=com.wiris.editor.util.EditorUtils.addAnnotation(t,\"application/vnd.wiris.mtweb-params+json\",JSON.stringify(this.editorParameters))}let e;let i;const n=null;if(this.isIframe){e=this.target.contentWindow;i=this.target.contentWindow}else{e=this.target;i=window}let o=this.core.beforeUpdateFormula(t,n);if(!o){return\"\"}o=this.insertFormula(e,i,o.mathml,o.wirisProperties);if(!o){return\"\"}return this.core.afterUpdateFormula(o.focusElement,o.windowTarget,o.node,o.latex)}insertFormula(t,e,i,n){return this.core.insertFormula(t,e,i,n)}getSelection(){if(this.isIframe){this.target.contentWindow.focus();return this.target.contentWindow.getSelection()}this.target.focus();return window.getSelection()}addEvents(){const t=this.isIframe?this.target.contentWindow.document:this.target;HT.addElementEvents(t,(t,e)=>{this.doubleClickHandler(t,e)},(t,e)=>{this.mousedownHandler(t,e)},(t,e)=>{this.mouseupHandler(t,e)})}doubleClickHandler(t){if(t.nodeName.toLowerCase()===\"img\"){this.core.getCustomEditors().disable();const e=NT.get(\"imageCustomEditorName\");if(t.hasAttribute(e)){const i=t.getAttribute(e);this.core.getCustomEditors().enable(i)}if(HT.containsClass(t,NT.get(\"imageClassName\"))){this.core.editionProperties.temporalImage=t;this.core.editionProperties.isNewElement=true;this.openExistingFormulaEditor()}}}mouseupHandler(){if(this.temporalImageResizing){setTimeout(()=>{WT.fixAfterResize(this.temporalImageResizing)},10)}}mousedownHandler(t){if(t.nodeName.toLowerCase()===\"img\"){if(HT.containsClass(t,NT.get(\"imageClassName\"))){this.temporalImageResizing=t}}}getLanguage(){return this.getBrowserLanguage()}getBrowserLanguage(){let t=\"en\";if(navigator.userLanguage){t=navigator.userLanguage.substring(0,2)}else if(navigator.language){t=navigator.language.substring(0,2)}else{t=\"en\"}return t}callbackFunction(){const t=VT.newListener(\"onTargetReady\",()=>{this.addEvents(this.target)});this.listeners.add(t)}notifyWindowClosed(){}getMathmlFromTextNode(t,e){}fillNonLatexNode(t,e,i){}getSelectedItem(t,e){}}gP.prototype.getMathmlFromTextNode=undefined;gP.prototype.fillNonLatexNode=undefined;gP.prototype.getSelectedItem=undefined;gP.integrationParameters=[\"serviceProviderProperties\",\"editorParameters\"];class pP extends gP{constructor(t){const e=t.editorObject;if(typeof e.config!=\"undefined\"&&typeof e.config.get(\"mathTypeParameters\")!=\"undefined\"){t.integrationParameters=e.config.get(\"mathTypeParameters\")}super(t);this.integrationFolderName=\"ckeditor_wiris\"}getLanguage(){return this.editorObject.config.get(\"language\")}addEditorListeners(){const t=this.editorObject;if(typeof t.config.wirislistenersdisabled==\"undefined\"||!t.config.wirislistenersdisabled){this.checkElement()}}checkElement(){const t=this.editorObject;const e=t.sourceElement;if(!e.wirisActive){this.setTarget(e);this.addEvents();e.wirisActive=true}}doubleClickHandler(t,e){if(t.nodeName.toLowerCase()==\"img\"){if(HT.containsClass(t,NT.get(\"imageClassName\"))){if(typeof e.stopPropagation!=\"undefined\"){e.stopPropagation()}else{e.returnValue=false}this.core.getCustomEditors().disable();const i=t.getAttribute(NT.get(\"imageCustomEditorName\"));if(i){this.core.getCustomEditors().enable(i)}this.core.editionProperties.temporalImage=t;this.openExistingFormulaEditor()}}}getCorePath(){return null}callbackFunction(){super.callbackFunction();this.addEditorListeners()}openNewFormulaEditor(){this.core.editionProperties.selection=this.editorObject.editing.view.document.selection;return super.openNewFormulaEditor()}insertMathml(t){return this.editorObject.model.change(e=>{const i=this.getCore();const n=e.createElement(\"mathml\",{formula:t});if(i.editionProperties.isNewElement){if(!t)return;let i=this.core.editionProperties.selection||this.editorObject.editing.view.document.selection;let o=this.editorObject.editing.mapper.toModelPosition(i.getLastPosition());e.insert(n,o);if(!i.isCollapsed){for(const t of i.getRanges()){e.remove(this.editorObject.editing.mapper.toModelRange(t))}}}else{const o=i.editionProperties.temporalImage;const r=this.editorObject.editing.view.domConverter.domToView(o).parent;const s=this.editorObject.editing.mapper.toModelElement(r);const a=this.editorObject.model.createPositionBefore(s);if(t){e.insert(n,a)}e.remove(s)}return n})}findText(t){let e=t;let i;while(!i){i=this.editorObject.editing.mapper.toModelElement(this.editorObject.editing.view.domConverter.domToView(e));e=e.parentElement}const n=this.editorObject.model.createRangeIn(i);const o=Array.from(n.getItems());for(const e of o){if(e.is(\"textProxy\")&&e.data==t.data.replace(String.fromCharCode(160),\" \")){return e.textNode}}}insertFormula(t,e,i,n){let o={};if(!i){this.insertMathml(\"\")}else if(this.core.editMode==\"latex\"){o.latex=zT.getLatexFromMathML(i);o.node=e.document.createTextNode(\"$$\"+o.latex+\"$$\");this.editorObject.model.change(t=>{const e=this.core.editionProperties.latexRange;const i=this.findText(e.startContainer);const n=this.findText(e.endContainer);const r=t.createPositionAt(i.parent,i.startOffset+e.startOffset);const s=t.createPositionAt(n.parent,n.startOffset+e.endOffset);const a=t.createRange(r,s);t.remove(a);t.insertText(\"$$\"+o.latex+\"$$\",i.getAttributes(),r)})}else{o.node=this.editorObject.editing.view.domConverter.viewToDom(this.editorObject.editing.mapper.toViewElement(this.insertMathml(i)),e.document)}return o}notifyWindowClosed(){this.editorObject.editing.view.focus()}}class bP extends Vw{constructor(t){super(t)}execute(t={}){if(!t.hasOwnProperty(\"integration\")||!(t.integration instanceof pP)){throw'Must pass a valid CKEditor5Integration instance as attribute \"integration\" of options'}this.integration=t.integration;this.setEditor();this.openEditor()}setEditor(){this.integration.core.getCustomEditors().disable()}openEditor(){const t=this._getSelectedImage();if(typeof t!==\"undefined\"&&t!==null&&t.classList.contains(WirisPlugin.Configuration.get(\"imageClassName\"))){this.integration.core.editionProperties.temporalImage=t;this.integration.openExistingFormulaEditor()}else{this.integration.openNewFormulaEditor()}}_getSelectedImage(){const t=this.editor.editing.view.document.selection;if(t.isCollapsed||t.rangeCount!==1){return}const e=t.getFirstRange();let i;for(const t of e){if(t.item.name!==\"span\"){return}i=t.item.getChild(0);break}if(!i){return}return this.editor.editing.view.domConverter.mapViewToDom(i)}}class wP extends bP{setEditor(){this.integration.core.getCustomEditors().enable(\"chemistry\")}}var _P='<?xml version=\"1.0\" encoding=\"utf-8\"?>\\n\\x3c!-- Generator: Adobe Illustrator 22.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --\\x3e\\n<svg version=\"1.1\" id=\"Layer_1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\"\\n\\t viewBox=\"0 0 300 261.7\" style=\"enable-background:new 0 0 300 261.7;\" xml:space=\"preserve\">\\n<style type=\"text/css\">\\n\\t.st0{fill:#FFFFFF;}\\n\\t.st1{fill:#EF4A5F;}\\n\\t.st2{fill:#C8202F;}\\n</style>\\n<path class=\"st0\" d=\"M300,32.8c0-16.4-13.4-29.7-29.9-29.7c-2.9,0-7.2,0.8-7.2,0.8c-37.9,9.1-71.3,14-112,14c-0.3,0-0.6,0-1,0\\n\\tc-16.5,0-29.9,13.3-29.9,29.7c0,16.4,13.4,29.7,29.9,29.7l0,0c45.3,0,83.1-5.3,125.3-15.3h0C289.3,59.5,300,47.4,300,32.8\"/>\\n<path class=\"st0\" d=\"M90.2,257.7c-11.4,0-21.9-6.4-27-16.7l-60-119.9c-7.5-14.9-1.4-33.1,13.5-40.5c14.9-7.5,33.1-1.4,40.5,13.5\\n\\tl27.3,54.7L121.1,39c5.3-15.8,22.4-24.4,38.2-19.1c15.8,5.3,24.4,22.4,19.1,38.2l-59.6,179c-3.9,11.6-14.3,19.7-26.5,20.6\\n\\tC91.6,257.7,90.9,257.7,90.2,257.7\"/>\\n<g>\\n\\t<g>\\n\\t\\t<path class=\"st1\" d=\"M90.2,257.7c-11.4,0-21.9-6.4-27-16.7l-60-119.9c-7.5-14.9-1.4-33.1,13.5-40.5c14.9-7.5,33.1-1.4,40.5,13.5\\n\\t\\t\\tl27.3,54.7L121.1,39c5.3-15.8,22.4-24.4,38.2-19.1c15.8,5.3,24.4,22.4,19.1,38.2l-59.6,179c-3.9,11.6-14.3,19.7-26.5,20.6\\n\\t\\t\\tC91.6,257.7,90.9,257.7,90.2,257.7\"/>\\n\\t</g>\\n</g>\\n<g>\\n\\t<g>\\n\\t\\t<path class=\"st2\" d=\"M300,32.8c0-16.4-13.4-29.7-29.9-29.7c-2.9,0-7.2,0.8-7.2,0.8c-37.9,9.1-71.3,14-112,14c-0.3,0-0.6,0-1,0\\n\\t\\t\\tc-16.5,0-29.9,13.3-29.9,29.7c0,16.4,13.4,29.7,29.9,29.7l0,0c45.3,0,83.1-5.3,125.3-15.3h0C289.3,59.5,300,47.4,300,32.8\"/>\\n\\t</g>\\n</g>\\n</svg>\\n';var kP='<?xml version=\"1.0\" encoding=\"utf-8\"?>\\n\\x3c!-- Generator: Adobe Illustrator 22.0.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) --\\x3e\\n<svg version=\"1.1\" id=\"Layer_1\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" x=\"0px\" y=\"0px\"\\n\\t viewBox=\"0 0 40.3 49.5\" style=\"enable-background:new 0 0 40.3 49.5;\" xml:space=\"preserve\">\\n<style type=\"text/css\">\\n\\t.st0{fill:#A4CF61;}\\n</style>\\n<path class=\"st0\" d=\"M39.2,12.1c0-1.9-1.1-3.6-2.7-4.4L24.5,0.9l0,0c-0.7-0.4-1.5-0.6-2.4-0.6c-0.9,0-1.7,0.2-2.4,0.6l0,0L2.3,10.8\\n\\tl0,0C0.9,11.7,0,13.2,0,14.9h0v19.6h0c0,1.7,0.9,3.3,2.3,4.1l0,0l17.4,9.9l0,0c0.7,0.4,1.5,0.6,2.4,0.6c0.9,0,1.7-0.2,2.4-0.6l0,0\\n\\tl12.2-6.9h0c1.5-0.8,2.6-2.5,2.6-4.3c0-2.7-2.2-4.9-4.9-4.9c-0.9,0-1.8,0.3-2.5,0.7l0,0l-9.7,5.6l-12.3-7V17.8l12.3-7l9.9,5.7l0,0\\n\\tc0.7,0.4,1.5,0.6,2.4,0.6C37,17,39.2,14.8,39.2,12.1\"/>\\n</svg>\\n';class vP extends Nw{static get requires(){return[ET]}static get pluginName(){return\"MathType\"}init(){const t=this._addIntegration();this._addCommands();this._addViews(t);this._addSchema();this._addConverters();this._exposeWiris()}_addIntegration(){const t=this.editor;const e={};e.environment={};e.environment.editor=\"CKEditor5\";e.editorObject=t;e.serviceProviderProperties={};e.serviceProviderProperties.URI=\"https://www.wiris.net/demo/plugins/app\";e.serviceProviderProperties.server=\"java\";e.target=t.sourceElement;e.scriptName=\"bundle.js\";e.managesLanguage=true;let i;if(e.target){i=new pP(e);i.init();i.listeners.fire(\"onTargetReady\",{});i.checkElement();this.listenTo(t.editing.view.document,\"click\",(t,e)=>{if(e.domEvent.detail==2){i.doubleClickHandler(e.domTarget,e.domEvent);t.stop()}},{priority:\"highest\"})}return i}_addCommands(){const t=this.editor;t.commands.add(\"MathType\",new bP(t));t.commands.add(\"ChemType\",new wP(t))}_addViews(t){const e=this.editor;e.ui.componentFactory.add(\"MathType\",i=>{const n=new rw(i);n.bind(\"isEnabled\").to(e.commands.get(\"MathType\"),\"isEnabled\");n.set({label:\"Insert a math equation - MathType\",icon:_P,tooltip:true});n.on(\"execute\",()=>{e.execute(\"MathType\",{integration:t})});return n});e.ui.componentFactory.add(\"ChemType\",i=>{const n=new rw(i);n.bind(\"isEnabled\").to(e.commands.get(\"ChemType\"),\"isEnabled\");n.set({label:\"Insert a chemistry formula - ChemType\",icon:kP,tooltip:true});n.on(\"execute\",()=>{e.execute(\"ChemType\",{integration:t})});return n});e.editing.view.addObserver(RA)}_addSchema(){const t=this.editor.model.schema;t.register(\"mathml\",{allowWhere:\"$text\",isObject:true,isInline:true,allowAttributes:[\"formula\"]})}_addConverters(){const t=this.editor;t.conversion.for(\"upcast\").elementToElement({view:{name:\"span\",classes:\"ck-math-widget\"},model:(t,e)=>{const i=LT.safeXmlDecode(t.getChild(0).getAttribute(\"data-mathml\"));return e.createElement(\"mathml\",{formula:i})}});t.data.upcastDispatcher.on(\"element:math\",(i,n,o)=>{const{consumable:r,writer:s}=o;const a=n.viewItem;if(!r.test(a,{name:true})){return}let l=e(a);const c=new lT(t.editing.view.document);const d=new cT(t.editing.view.document);const u=d.createDocumentFragment(a.getChildren());const h=[...a.getAttributes()].map(([t,e])=>` ${t}=\"${e}\"`).join(\"\");let f=c.toData(u)||\"\";f=`<math${h}>${f}</math>`;const m=l?s.createText(UT.initParse(f,t.config.get(\"language\"))):s.createElement(\"mathml\",{formula:f});const g=o.splitToAllowedParent(m,n.modelCursor);if(!g){return}o.writer.insert(m,g.position);r.consume(a,{name:true});const p=o.getSplitParts(m);n.modelRange=s.createRange(o.writer.createPositionBefore(m),o.writer.createPositionAfter(p[p.length-1]));if(g.cursorParent){n.modelCursor=o.writer.createPositionAt(g.cursorParent,0)}else{n.modelCursor=n.modelRange.end}});function e(t){const e=t.getChild(0);if(!e||e.name!==\"semantics\")return false;for(const t of e.getChildren()){if(t.name===\"annotation\"&&t.getAttribute(\"encoding\")===\"LaTeX\"){return true}}return false}t.conversion.for(\"editingDowncast\").elementToElement({model:\"mathml\",view:o});t.conversion.for(\"dataDowncast\").elementToElement({model:\"mathml\",view:n});function i(t,e){if(e.is(\"text\")){return t.createText(e.data)}else if(e.is(\"element\")){if(e.is(\"emptyElement\")){return t.createEmptyElement(e.name,e.getAttributes())}else{const n=t.createContainerElement(e.name,e.getAttributes());for(const o of e.getChildren()){t.insert(t.createPositionAt(n,\"end\"),i(t,o))}return n}}throw new Exception(\"Given node has unsupported type.\")}function n(t,e){const n=new Cp(e.document);let o=UT.endParseSaveMode(t.getAttribute(\"formula\"));if(!NT.get(\"saveHandTraces\")){o=LT.removeAnnotation(o,\"application/json\")}const r=n.toView(o).getChild(0);return i(e,r)}function o(t,e){const i=e.createContainerElement(\"span\",{class:\"ck-math-widget\"});const n=r(t,e);e.insert(e.createPositionAt(i,0),n);return ax(i,e)}function r(e,i){const n=new Cp(i.document);const o=e.getAttribute(\"formula\");const r=UT.initParse(o,t.config.get(\"language\"));const s=n.toView(r).getChild(0);return i.createEmptyElement(\"img\",s.getAttributes())}}_exposeWiris(){window.WirisPlugin={Core:mP,Parser:UT,Image:WT,MathML:LT,Util:HT,Configuration:NT,Listeners:VT,IntegrationModel:gP,Latex:zT}}}var yP='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M8.69 14.915c.053.052.173.083.36.093a.366.366 0 0 1 .345.485l-.003.01a.738.738 0 0 1-.697.497h-2.67a.374.374 0 0 1-.353-.496l.013-.038a.681.681 0 0 1 .644-.458c.197-.012.325-.043.386-.093a.28.28 0 0 0 .072-.11L9.592 4.5H6.269c-.359-.017-.609.013-.75.09-.142.078-.289.265-.442.563-.192.29-.516.464-.864.464H4.17a.43.43 0 0 1-.407-.569L4.46 3h13.08l-.62 2.043a.81.81 0 0 1-.775.574h-.114a.486.486 0 0 1-.486-.486c.001-.284-.054-.464-.167-.54-.112-.076-.367-.106-.766-.091h-3.28l-2.68 10.257c-.006.074.007.127.038.158zM3 17h8a.5.5 0 1 1 0 1H3a.5.5 0 1 1 0-1zm11.299 1.17a.75.75 0 1 1-1.06-1.06l1.414-1.415-1.415-1.414a.75.75 0 0 1 1.06-1.06l1.415 1.414 1.414-1.415a.75.75 0 1 1 1.06 1.06l-1.413 1.415 1.414 1.415a.75.75 0 0 1-1.06 1.06l-1.415-1.414-1.414 1.414z\"/></svg>';const xP=\"removeFormat\";class CP extends Nw{static get pluginName(){return\"RemoveFormatUI\"}init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(xP,i=>{const n=t.commands.get(xP);const o=new rw(i);o.set({label:e(\"Remove Format\"),icon:yP,tooltip:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(xP);t.editing.view.focus()});return o})}}class AP extends Vw{refresh(){const t=this.editor.model;this.isEnabled=!!zw(this._getFormattingItems(t.document.selection,t.schema))}execute(){const t=this.editor.model;const e=t.schema;t.change(i=>{for(const n of this._getFormattingItems(t.document.selection,e)){if(n.is(\"selection\")){for(const t of this._getFormattingAttributes(n,e)){i.removeSelectionAttribute(t)}}else{const t=i.createRangeOn(n);for(const o of this._getFormattingAttributes(n,e)){i.removeAttribute(o,t)}}}})}*_getFormattingItems(t,e){const i=t=>!!zw(this._getFormattingAttributes(t,e));for(const e of t.getRanges()){for(const t of e.getItems()){if(i(t)){yield t}}}if(i(t)){yield t}}*_getFormattingAttributes(t,e){for(const[i]of t.getAttributes()){const t=e.getAttributeProperties(i);if(t&&t.isFormatting){yield i}}}}class TP extends Nw{static get pluginName(){return\"RemoveFormatEditing\"}init(){const t=this.editor;t.commands.add(\"removeFormat\",new AP(t))}}class PP extends Nw{static get requires(){return[TP,CP]}static get pluginName(){return\"RemoveFormat\"}}var EP=i(88);class SP extends _b{constructor(t,e={}){super(t);const i=this.bindTemplate;this.set(\"label\",e.label||\"\");this.set(\"class\",e.class||null);this.children=this.createCollection();this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-form__header\",i.to(\"class\")]},children:this.children});const n=new _b(t);n.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-form__header__label\"]},children:[{text:i.to(\"label\")}]});this.children.add(n)}}class MP extends SP{constructor(t,e){super(t);const i=t.t;this.set(\"class\",\"ck-special-characters-navigation\");this.groupDropdownView=this._createGroupDropdown(e);this.groupDropdownView.panelPosition=t.uiLanguageDirection===\"rtl\"?\"se\":\"sw\";this.label=i(\"Special characters\");this.children.add(this.groupDropdownView)}get currentGroupName(){return this.groupDropdownView.value}_createGroupDropdown(t){const e=this.locale;const i=e.t;const n=bw(e);const o=this._getCharacterGroupListItemDefinitions(n,t);n.set(\"value\",o.first.model.label);n.buttonView.bind(\"label\").to(n,\"value\");n.buttonView.set({isOn:false,withText:true,tooltip:i(\"Character categories\"),class:[\"ck-dropdown__button_label-width_auto\"]});n.on(\"execute\",t=>{n.value=t.source.label});n.delegate(\"execute\").to(this);_w(n,o);return n}_getCharacterGroupListItemDefinitions(t,e){const i=new xs;for(const n of e){const e={type:\"button\",model:new rk({label:n,withText:true})};e.model.bind(\"isOn\").to(t,\"value\",t=>t===e.model.label);i.add(e)}return i}}var OP=i(90);class IP extends _b{constructor(t){super(t);this.tiles=this.createCollection();this.setTemplate({tag:\"div\",children:[{tag:\"div\",attributes:{class:[\"ck\",\"ck-character-grid__tiles\"]},children:this.tiles}],attributes:{class:[\"ck\",\"ck-character-grid\"]}})}createTile(t,e){const i=new rw(this.locale);i.set({label:t,withText:true,class:\"ck-character-grid__tile\"});i.extendTemplate({attributes:{title:e},on:{mouseover:i.bindTemplate.to(\"mouseover\")}});i.on(\"mouseover\",()=>{this.fire(\"tileHover\",{name:e,character:t})});i.on(\"execute\",()=>{this.fire(\"execute\",{name:e,character:t})});return i}}var RP=i(92);class LP extends _b{constructor(t){super(t);const e=this.bindTemplate;this.set(\"character\",null);this.set(\"name\",null);this.bind(\"code\").to(this,\"character\",NP);this.setTemplate({tag:\"div\",children:[{tag:\"span\",attributes:{class:[\"ck-character-info__name\"]},children:[{text:e.to(\"name\",t=>t?t:\"​\")}]},{tag:\"span\",attributes:{class:[\"ck-character-info__code\"]},children:[{text:e.to(\"code\")}]}],attributes:{class:[\"ck\",\"ck-character-info\"]}})}}function NP(t){if(t===null){return\"\"}const e=t.codePointAt(0).toString(16);return\"U+\"+(\"0000\"+e).slice(-4)}var BP='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M10 2.5a7.47 7.47 0 0 1 4.231 1.31 7.268 7.268 0 0 1 2.703 3.454 7.128 7.128 0 0 1 .199 4.353c-.39 1.436-1.475 2.72-2.633 3.677h2.013c0-.226.092-.443.254-.603a.876.876 0 0 1 1.229 0c.163.16.254.377.254.603v.853c0 .209-.078.41-.22.567a.873.873 0 0 1-.547.28l-.101.006h-4.695a.517.517 0 0 1-.516-.518v-1.265c0-.21.128-.398.317-.489a5.601 5.601 0 0 0 2.492-2.371 5.459 5.459 0 0 0 .552-3.693 5.53 5.53 0 0 0-1.955-3.2A5.71 5.71 0 0 0 10 4.206 5.708 5.708 0 0 0 6.419 5.46 5.527 5.527 0 0 0 4.46 8.663a5.457 5.457 0 0 0 .554 3.695 5.6 5.6 0 0 0 2.497 2.37.55.55 0 0 1 .317.49v1.264c0 .286-.23.518-.516.518H2.618a.877.877 0 0 1-.614-.25.845.845 0 0 1-.254-.603v-.853c0-.226.091-.443.254-.603a.876.876 0 0 1 1.228 0c.163.16.255.377.255.603h1.925c-1.158-.958-2.155-2.241-2.545-3.678a7.128 7.128 0 0 1 .199-4.352 7.268 7.268 0 0 1 2.703-3.455A7.475 7.475 0 0 1 10 2.5z\"/></svg>';var VP=i(94);const DP=\"All\";class zP extends Nw{static get requires(){return[Kk]}static get pluginName(){return\"SpecialCharacters\"}constructor(t){super(t);this._characters=new Map;this._groups=new Map}init(){const t=this.editor;const e=t.t;const i=t.commands.get(\"input\");t.ui.componentFactory.add(\"specialCharacters\",n=>{const o=bw(n);let r;o.buttonView.set({label:e(\"Special characters\"),icon:BP,tooltip:true});o.bind(\"isEnabled\").to(i);o.on(\"execute\",(e,i)=>{t.execute(\"input\",{text:i.character});t.editing.view.focus()});o.on(\"change:isOpen\",()=>{if(!r){r=this._createDropdownPanelContent(n,o);o.panelView.children.add(r.navigationView);o.panelView.children.add(r.gridView);o.panelView.children.add(r.infoView)}r.infoView.set({character:null,name:null})});return o})}addItems(t,e){if(t===DP){throw new ss[\"b\"](`special-character-invalid-group-name: The name \"${DP}\" is reserved and cannot be used.`)}const i=this._getGroup(t);for(const t of e){i.add(t.title);this._characters.set(t.title,t.character)}}getGroups(){return this._groups.keys()}getCharactersForGroup(t){if(t===DP){return new Set(this._characters.keys())}return this._groups.get(t)}getCharacter(t){return this._characters.get(t)}_getGroup(t){if(!this._groups.has(t)){this._groups.set(t,new Set)}return this._groups.get(t)}_updateGrid(t,e){e.tiles.clear();const i=this.getCharactersForGroup(t);for(const t of i){const i=this.getCharacter(t);e.tiles.add(e.createTile(i,t))}}_createDropdownPanelContent(t,e){const i=[...this.getGroups()];i.unshift(DP);const n=new MP(t,i);const o=new IP(t);const r=new LP(t);o.delegate(\"execute\").to(e);o.on(\"tileHover\",(t,e)=>{r.set(e)});n.on(\"execute\",()=>{this._updateGrid(n.currentGroupName,o)});this._updateGrid(n.currentGroupName,o);return{navigationView:n,gridView:o,infoView:r}}}class FP extends Nw{init(){const t=this.editor;const e=t.t;t.plugins.get(\"SpecialCharacters\").addItems(\"Arrows\",[{title:e(\"leftwards double arrow\"),character:\"⇐\"},{title:e(\"rightwards double arrow\"),character:\"⇒\"},{title:e(\"upwards double arrow\"),character:\"⇑\"},{title:e(\"downwards double arrow\"),character:\"⇓\"},{title:e(\"leftwards dashed arrow\"),character:\"⇠\"},{title:e(\"rightwards dashed arrow\"),character:\"⇢\"},{title:e(\"upwards dashed arrow\"),character:\"⇡\"},{title:e(\"downwards dashed arrow\"),character:\"⇣\"},{title:e(\"leftwards arrow to bar\"),character:\"⇤\"},{title:e(\"rightwards arrow to bar\"),character:\"⇥\"},{title:e(\"upwards arrow to bar\"),character:\"⤒\"},{title:e(\"downwards arrow to bar\"),character:\"⤓\"},{title:e(\"up down arrow with base\"),character:\"↨\"},{title:e(\"back with leftwards arrow above\"),character:\"🔙\"},{title:e(\"end with leftwards arrow above\"),character:\"🔚\"},{title:e(\"on with exclamation mark with left right arrow above\"),character:\"🔛\"},{title:e(\"soon with rightwards arrow above\"),character:\"🔜\"},{title:e(\"top with upwards arrow above\"),character:\"🔝\"}])}}class jP extends Nw{init(){const t=this.editor;const e=t.t;t.plugins.get(\"SpecialCharacters\").addItems(\"Currency\",[{character:\"$\",title:e(\"Dollar sign\")},{character:\"€\",title:e(\"Euro sign\")},{character:\"¥\",title:e(\"Yen sign\")},{character:\"£\",title:e(\"Pound sign\")},{character:\"¢\",title:e(\"Cent sign\")},{character:\"₠\",title:e(\"Euro-currency sign\")},{character:\"₡\",title:e(\"Colon sign\")},{character:\"₢\",title:e(\"Cruzeiro sign\")},{character:\"₣\",title:e(\"French franc sign\")},{character:\"₤\",title:e(\"Lira sign\")},{character:\"¤\",title:e(\"Currency sign\")},{character:\"₿\",title:e(\"Bitcoin sign\")},{character:\"₥\",title:e(\"Mill sign\")},{character:\"₦\",title:e(\"Naira sign\")},{character:\"₧\",title:e(\"Peseta sign\")},{character:\"₨\",title:e(\"Rupee sign\")},{character:\"₩\",title:e(\"Won sign\")},{character:\"₪\",title:e(\"New sheqel sign\")},{character:\"₫\",title:e(\"Dong sign\")},{character:\"₭\",title:e(\"Kip sign\")},{character:\"₮\",title:e(\"Tugrik sign\")},{character:\"₯\",title:e(\"Drachma sign\")},{character:\"₰\",title:e(\"German penny sign\")},{character:\"₱\",title:e(\"Peso sign\")},{character:\"₲\",title:e(\"Guarani sign\")},{character:\"₳\",title:e(\"Austral sign\")},{character:\"₴\",title:e(\"Hryvnia sign\")},{character:\"₵\",title:e(\"Cedi sign\")},{character:\"₶\",title:e(\"Livre tournois sign\")},{character:\"₷\",title:e(\"Spesmilo sign\")},{character:\"₸\",title:e(\"Tenge sign\")},{character:\"₹\",title:e(\"Indian rupee sign\")},{character:\"₺\",title:e(\"Turkish lira sign\")},{character:\"₻\",title:e(\"Nordic mark sign\")},{character:\"₼\",title:e(\"Manat sign\")},{character:\"₽\",title:e(\"Ruble sign\")}])}}class HP extends Nw{init(){const t=this.editor;const e=t.t;t.plugins.get(\"SpecialCharacters\").addItems(\"Mathematical\",[{character:\"<\",title:e(\"Less-than sign\")},{character:\">\",title:e(\"Greater-than sign\")},{character:\"≤\",title:e(\"Less-than or equal to\")},{character:\"≥\",title:e(\"Greater-than or equal to\")},{character:\"–\",title:e(\"En dash\")},{character:\"—\",title:e(\"Em dash\")},{character:\"¯\",title:e(\"Macron\")},{character:\"‾\",title:e(\"Overline\")},{character:\"°\",title:e(\"Degree sign\")},{character:\"−\",title:e(\"Minus sign\")},{character:\"±\",title:e(\"Plus-minus sign\")},{character:\"÷\",title:e(\"Division sign\")},{character:\"⁄\",title:e(\"Fraction slash\")},{character:\"×\",title:e(\"Multiplication sign\")},{character:\"ƒ\",title:e(\"Latin small letter f with hook\")},{character:\"∫\",title:e(\"Integral\")},{character:\"∑\",title:e(\"N-ary summation\")},{character:\"∞\",title:e(\"Infinity\")},{character:\"√\",title:e(\"Square root\")},{character:\"∼\",title:e(\"Tilde operator\")},{character:\"≅\",title:e(\"Approximately equal to\")},{character:\"≈\",title:e(\"Almost equal to\")},{character:\"≠\",title:e(\"Not equal to\")},{character:\"≡\",title:e(\"Identical to\")},{character:\"∈\",title:e(\"Element of\")},{character:\"∉\",title:e(\"Not an element of\")},{character:\"∋\",title:e(\"Contains as member\")},{character:\"∏\",title:e(\"N-ary product\")},{character:\"∧\",title:e(\"Logical and\")},{character:\"∨\",title:e(\"Logical or\")},{character:\"¬\",title:e(\"Not sign\")},{character:\"∩\",title:e(\"Intersection\")},{character:\"∪\",title:e(\"Union\")},{character:\"∂\",title:e(\"Partial differential\")},{character:\"∀\",title:e(\"For all\")},{character:\"∃\",title:e(\"There exists\")},{character:\"∅\",title:e(\"Empty set\")},{character:\"∇\",title:e(\"Nabla\")},{character:\"∗\",title:e(\"Asterisk operator\")},{character:\"∝\",title:e(\"Proportional to\")},{character:\"∠\",title:e(\"Angle\")},{character:\"¼\",title:e(\"Vulgar fraction one quarter\")},{character:\"½\",title:e(\"Vulgar fraction one half\")},{character:\"¾\",title:e(\"Vulgar fraction three quarters\")}])}}class WP extends Nw{init(){const t=this.editor;const e=t.t;t.plugins.get(\"SpecialCharacters\").addItems(\"Latin\",[{character:\"Ā\",title:e(\"Latin capital letter a with macron\")},{character:\"ā\",title:e(\"Latin small letter a with macron\")},{character:\"Ă\",title:e(\"Latin capital letter a with breve\")},{character:\"ă\",title:e(\"Latin small letter a with breve\")},{character:\"Ą\",title:e(\"Latin capital letter a with ogonek\")},{character:\"ą\",title:e(\"Latin small letter a with ogonek\")},{character:\"Ć\",title:e(\"Latin capital letter c with acute\")},{character:\"ć\",title:e(\"Latin small letter c with acute\")},{character:\"Ĉ\",title:e(\"Latin capital letter c with circumflex\")},{character:\"ĉ\",title:e(\"Latin small letter c with circumflex\")},{character:\"Ċ\",title:e(\"Latin capital letter c with dot above\")},{character:\"ċ\",title:e(\"Latin small letter c with dot above\")},{character:\"Č\",title:e(\"Latin capital letter c with caron\")},{character:\"č\",title:e(\"Latin small letter c with caron\")},{character:\"Ď\",title:e(\"Latin capital letter d with caron\")},{character:\"ď\",title:e(\"Latin small letter d with caron\")},{character:\"Đ\",title:e(\"Latin capital letter d with stroke\")},{character:\"đ\",title:e(\"Latin small letter d with stroke\")},{character:\"Ē\",title:e(\"Latin capital letter e with macron\")},{character:\"ē\",title:e(\"Latin small letter e with macron\")},{character:\"Ĕ\",title:e(\"Latin capital letter e with breve\")},{character:\"ĕ\",title:e(\"Latin small letter e with breve\")},{character:\"Ė\",title:e(\"Latin capital letter e with dot above\")},{character:\"ė\",title:e(\"Latin small letter e with dot above\")},{character:\"Ę\",title:e(\"Latin capital letter e with ogonek\")},{character:\"ę\",title:e(\"Latin small letter e with ogonek\")},{character:\"Ě\",title:e(\"Latin capital letter e with caron\")},{character:\"ě\",title:e(\"Latin small letter e with caron\")},{character:\"Ĝ\",title:e(\"Latin capital letter g with circumflex\")},{character:\"ĝ\",title:e(\"Latin small letter g with circumflex\")},{character:\"Ğ\",title:e(\"Latin capital letter g with breve\")},{character:\"ğ\",title:e(\"Latin small letter g with breve\")},{character:\"Ġ\",title:e(\"Latin capital letter g with dot above\")},{character:\"ġ\",title:e(\"Latin small letter g with dot above\")},{character:\"Ģ\",title:e(\"Latin capital letter g with cedilla\")},{character:\"ģ\",title:e(\"Latin small letter g with cedilla\")},{character:\"Ĥ\",title:e(\"Latin capital letter h with circumflex\")},{character:\"ĥ\",title:e(\"Latin small letter h with circumflex\")},{character:\"Ħ\",title:e(\"Latin capital letter h with stroke\")},{character:\"ħ\",title:e(\"Latin small letter h with stroke\")},{character:\"Ĩ\",title:e(\"Latin capital letter i with tilde\")},{character:\"ĩ\",title:e(\"Latin small letter i with tilde\")},{character:\"Ī\",title:e(\"Latin capital letter i with macron\")},{character:\"ī\",title:e(\"Latin small letter i with macron\")},{character:\"Ĭ\",title:e(\"Latin capital letter i with breve\")},{character:\"ĭ\",title:e(\"Latin small letter i with breve\")},{character:\"Į\",title:e(\"Latin capital letter i with ogonek\")},{character:\"į\",title:e(\"Latin small letter i with ogonek\")},{character:\"İ\",title:e(\"Latin capital letter i with dot above\")},{character:\"ı\",title:e(\"Latin small letter dotless i\")},{character:\"IJ\",title:e(\"Latin capital ligature ij\")},{character:\"ij\",title:e(\"Latin small ligature ij\")},{character:\"Ĵ\",title:e(\"Latin capital letter j with circumflex\")},{character:\"ĵ\",title:e(\"Latin small letter j with circumflex\")},{character:\"Ķ\",title:e(\"Latin capital letter k with cedilla\")},{character:\"ķ\",title:e(\"Latin small letter k with cedilla\")},{character:\"ĸ\",title:e(\"Latin small letter kra\")},{character:\"Ĺ\",title:e(\"Latin capital letter l with acute\")},{character:\"ĺ\",title:e(\"Latin small letter l with acute\")},{character:\"Ļ\",title:e(\"Latin capital letter l with cedilla\")},{character:\"ļ\",title:e(\"Latin small letter l with cedilla\")},{character:\"Ľ\",title:e(\"Latin capital letter l with caron\")},{character:\"ľ\",title:e(\"Latin small letter l with caron\")},{character:\"Ŀ\",title:e(\"Latin capital letter l with middle dot\")},{character:\"ŀ\",title:e(\"Latin small letter l with middle dot\")},{character:\"Ł\",title:e(\"Latin capital letter l with stroke\")},{character:\"ł\",title:e(\"Latin small letter l with stroke\")},{character:\"Ń\",title:e(\"Latin capital letter n with acute\")},{character:\"ń\",title:e(\"Latin small letter n with acute\")},{character:\"Ņ\",title:e(\"Latin capital letter n with cedilla\")},{character:\"ņ\",title:e(\"Latin small letter n with cedilla\")},{character:\"Ň\",title:e(\"Latin capital letter n with caron\")},{character:\"ň\",title:e(\"Latin small letter n with caron\")},{character:\"ʼn\",title:e(\"Latin small letter n preceded by apostrophe\")},{character:\"Ŋ\",title:e(\"Latin capital letter eng\")},{character:\"ŋ\",title:e(\"Latin small letter eng\")},{character:\"Ō\",title:e(\"Latin capital letter o with macron\")},{character:\"ō\",title:e(\"Latin small letter o with macron\")},{character:\"Ŏ\",title:e(\"Latin capital letter o with breve\")},{character:\"ŏ\",title:e(\"Latin small letter o with breve\")},{character:\"Ő\",title:e(\"Latin capital letter o with double acute\")},{character:\"ő\",title:e(\"Latin small letter o with double acute\")},{character:\"Œ\",title:e(\"Latin capital ligature oe\")},{character:\"œ\",title:e(\"Latin small ligature oe\")},{character:\"Ŕ\",title:e(\"Latin capital letter r with acute\")},{character:\"ŕ\",title:e(\"Latin small letter r with acute\")},{character:\"Ŗ\",title:e(\"Latin capital letter r with cedilla\")},{character:\"ŗ\",title:e(\"Latin small letter r with cedilla\")},{character:\"Ř\",title:e(\"Latin capital letter r with caron\")},{character:\"ř\",title:e(\"Latin small letter r with caron\")},{character:\"Ś\",title:e(\"Latin capital letter s with acute\")},{character:\"ś\",title:e(\"Latin small letter s with acute\")},{character:\"Ŝ\",title:e(\"Latin capital letter s with circumflex\")},{character:\"ŝ\",title:e(\"Latin small letter s with circumflex\")},{character:\"Ş\",title:e(\"Latin capital letter s with cedilla\")},{character:\"ş\",title:e(\"Latin small letter s with cedilla\")},{character:\"Š\",title:e(\"Latin capital letter s with caron\")},{character:\"š\",title:e(\"Latin small letter s with caron\")},{character:\"Ţ\",title:e(\"Latin capital letter t with cedilla\")},{character:\"ţ\",title:e(\"Latin small letter t with cedilla\")},{character:\"Ť\",title:e(\"Latin capital letter t with caron\")},{character:\"ť\",title:e(\"Latin small letter t with caron\")},{character:\"Ŧ\",title:e(\"Latin capital letter t with stroke\")},{character:\"ŧ\",title:e(\"Latin small letter t with stroke\")},{character:\"Ũ\",title:e(\"Latin capital letter u with tilde\")},{character:\"ũ\",title:e(\"Latin small letter u with tilde\")},{character:\"Ū\",title:e(\"Latin capital letter u with macron\")},{character:\"ū\",title:e(\"Latin small letter u with macron\")},{character:\"Ŭ\",title:e(\"Latin capital letter u with breve\")},{character:\"ŭ\",title:e(\"Latin small letter u with breve\")},{character:\"Ů\",title:e(\"Latin capital letter u with ring above\")},{character:\"ů\",title:e(\"Latin small letter u with ring above\")},{character:\"Ű\",title:e(\"Latin capital letter u with double acute\")},{character:\"ű\",title:e(\"Latin small letter u with double acute\")},{character:\"Ų\",title:e(\"Latin capital letter u with ogonek\")},{character:\"ų\",title:e(\"Latin small letter u with ogonek\")},{character:\"Ŵ\",title:e(\"Latin capital letter w with circumflex\")},{character:\"ŵ\",title:e(\"Latin small letter w with circumflex\")},{character:\"Ŷ\",title:e(\"Latin capital letter y with circumflex\")},{character:\"ŷ\",title:e(\"Latin small letter y with circumflex\")},{character:\"Ÿ\",title:e(\"Latin capital letter y with diaeresis\")},{character:\"Ź\",title:e(\"Latin capital letter z with acute\")},{character:\"ź\",title:e(\"Latin small letter z with acute\")},{character:\"Ż\",title:e(\"Latin capital letter z with dot above\")},{character:\"ż\",title:e(\"Latin small letter z with dot above\")},{character:\"Ž\",title:e(\"Latin capital letter z with caron\")},{character:\"ž\",title:e(\"Latin small letter z with caron\")},{character:\"ſ\",title:e(\"Latin small letter long s\")}])}}class qP extends Nw{init(){const t=this.editor;const e=t.t;t.plugins.get(\"SpecialCharacters\").addItems(\"Text\",[{character:\"‹\",title:e(\"Single left-pointing angle quotation mark\")},{character:\"›\",title:e(\"Single right-pointing angle quotation mark\")},{character:\"«\",title:e(\"Left-pointing double angle quotation mark\")},{character:\"»\",title:e(\"Right-pointing double angle quotation mark\")},{character:\"‘\",title:e(\"Left single quotation mark\")},{character:\"’\",title:e(\"Right single quotation mark\")},{character:\"“\",title:e(\"Left double quotation mark\")},{character:\"”\",title:e(\"Right double quotation mark\")},{character:\"‚\",title:e(\"Single low-9 quotation mark\")},{character:\"„\",title:e(\"Double low-9 quotation mark\")},{character:\"¡\",title:e(\"Inverted exclamation mark\")},{character:\"¿\",title:e(\"Inverted question mark\")},{character:\"‥\",title:e(\"Two dot leader\")},{character:\"…\",title:e(\"Horizontal ellipsis\")},{character:\"‡\",title:e(\"Double dagger\")},{character:\"‰\",title:e(\"Per mille sign\")},{character:\"‱\",title:e(\"Per ten thousand sign\")},{character:\"‼\",title:e(\"Double exclamation mark\")},{character:\"⁈\",title:e(\"Question exclamation mark\")},{character:\"⁉\",title:e(\"Exclamation question mark\")},{character:\"⁇\",title:e(\"Double question mark\")},{character:\"©\",title:e(\"Copyright sign\")},{character:\"®\",title:e(\"Registered sign\")},{character:\"™\",title:e(\"Trade mark sign\")},{character:\"§\",title:e(\"Section sign\")},{character:\"¶\",title:e(\"Paragraph sign\")},{character:\"⁋\",title:e(\"Reversed paragraph sign\")}])}}class $P extends Nw{static get requires(){return[jP,qP,HP,FP,WP]}}const UP=\"strikethrough\";class GP extends Nw{static get pluginName(){return\"StrikethroughEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:UP});t.model.schema.setAttributeProperties(UP,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:UP,view:\"s\",upcastAlso:[\"del\",\"strike\",{styles:{\"text-decoration\":\"line-through\"}}]});t.commands.add(UP,new b_(t,UP));t.keystrokes.set(\"CTRL+SHIFT+X\",\"strikethrough\")}}var JP='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M7 16.4c-.8-.4-1.5-.9-2.2-1.5a.6.6 0 0 1-.2-.5l.3-.6h1c1 1.2 2.1 1.7 3.7 1.7 1 0 1.8-.3 2.3-.6.6-.4.6-1.2.6-1.3.2-1.2-.9-2.1-.9-2.1h2.1c.3.7.4 1.2.4 1.7v.8l-.6 1.2c-.6.8-1.1 1-1.6 1.2a6 6 0 0 1-2.4.6c-1 0-1.8-.3-2.5-.6zM6.8 9L6 8.3c-.4-.5-.5-.8-.5-1.6 0-.7.1-1.3.5-1.8.4-.6 1-1 1.6-1.3a6.3 6.3 0 0 1 4.7 0 4 4 0 0 1 1.7 1l.3.7c0 .1.2.4-.2.7-.4.2-.9.1-1 0a3 3 0 0 0-1.2-1c-.4-.2-1-.3-2-.4-.7 0-1.4.2-2 .6-.8.6-1 .8-1 1.5 0 .8.5 1 1.2 1.5.6.4 1.1.7 1.9 1H6.8z\"/><path d=\"M3 10.5V9h14v1.5z\"/></svg>';const KP=\"strikethrough\";class XP extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(KP,i=>{const n=t.commands.get(KP);const o=new rw(i);o.set({label:e(\"Strikethrough\"),icon:JP,keystroke:\"CTRL+SHIFT+X\",tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(KP);t.editing.view.focus()});return o})}}class YP extends Nw{static get requires(){return[GP,XP]}static get pluginName(){return\"Strikethrough\"}}const QP=\"subscript\";class ZP extends Nw{static get pluginName(){return\"SubscriptEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:QP});t.model.schema.setAttributeProperties(QP,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:QP,view:\"sub\",upcastAlso:[{styles:{\"vertical-align\":\"sub\"}}]});t.commands.add(QP,new b_(t,QP))}}var tE='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M7.03 10.349l3.818-3.819a.8.8 0 1 1 1.132 1.132L8.16 11.48l3.819 3.818a.8.8 0 1 1-1.132 1.132L7.03 12.61l-3.818 3.82a.8.8 0 1 1-1.132-1.132L5.9 11.48 2.08 7.662A.8.8 0 1 1 3.212 6.53l3.818 3.82zm8.147 7.829h2.549c.254 0 .447.05.58.152a.49.49 0 0 1 .201.413.54.54 0 0 1-.159.393c-.105.108-.266.162-.48.162h-3.594c-.245 0-.435-.066-.572-.197a.621.621 0 0 1-.205-.463c0-.114.044-.265.132-.453a1.62 1.62 0 0 1 .288-.444c.433-.436.824-.81 1.172-1.122.348-.312.597-.517.747-.615.267-.183.49-.368.667-.553.177-.185.312-.375.405-.57.093-.194.139-.384.139-.57a1.008 1.008 0 0 0-.554-.917 1.197 1.197 0 0 0-.56-.133c-.426 0-.761.182-1.005.546a2.332 2.332 0 0 0-.164.39 1.609 1.609 0 0 1-.258.488c-.096.114-.237.17-.423.17a.558.558 0 0 1-.405-.156.568.568 0 0 1-.161-.427c0-.218.05-.446.151-.683.101-.238.252-.453.452-.646s.454-.349.762-.467a2.998 2.998 0 0 1 1.081-.178c.498 0 .923.076 1.274.228a1.916 1.916 0 0 1 1.004 1.032 1.984 1.984 0 0 1-.156 1.794c-.2.32-.405.572-.613.754-.208.182-.558.468-1.048.857-.49.39-.826.691-1.008.906a2.703 2.703 0 0 0-.24.309z\"/></svg>';const eE=\"subscript\";class iE extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(eE,i=>{const n=t.commands.get(eE);const o=new rw(i);o.set({label:e(\"Subscript\"),icon:tE,tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(eE);t.editing.view.focus()});return o})}}class nE extends Nw{static get requires(){return[ZP,iE]}static get pluginName(){return\"Subscript\"}}const oE=\"superscript\";class rE extends Nw{static get pluginName(){return\"SuperscriptEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:oE});t.model.schema.setAttributeProperties(oE,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:oE,view:\"sup\",upcastAlso:[{styles:{\"vertical-align\":\"super\"}}]});t.commands.add(oE,new b_(t,oE))}}var sE='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M15.677 8.678h2.549c.254 0 .447.05.58.152a.49.49 0 0 1 .201.413.54.54 0 0 1-.159.393c-.105.108-.266.162-.48.162h-3.594c-.245 0-.435-.066-.572-.197a.621.621 0 0 1-.205-.463c0-.114.044-.265.132-.453a1.62 1.62 0 0 1 .288-.444c.433-.436.824-.81 1.172-1.122.348-.312.597-.517.747-.615.267-.183.49-.368.667-.553.177-.185.312-.375.405-.57.093-.194.139-.384.139-.57a1.008 1.008 0 0 0-.554-.917 1.197 1.197 0 0 0-.56-.133c-.426 0-.761.182-1.005.546a2.332 2.332 0 0 0-.164.39 1.609 1.609 0 0 1-.258.488c-.096.114-.237.17-.423.17a.558.558 0 0 1-.405-.156.568.568 0 0 1-.161-.427c0-.218.05-.446.151-.683.101-.238.252-.453.452-.646s.454-.349.762-.467a2.998 2.998 0 0 1 1.081-.178c.498 0 .923.076 1.274.228a1.916 1.916 0 0 1 1.004 1.032 1.984 1.984 0 0 1-.156 1.794c-.2.32-.405.572-.613.754-.208.182-.558.468-1.048.857-.49.39-.826.691-1.008.906a2.703 2.703 0 0 0-.24.309zM7.03 10.349l3.818-3.819a.8.8 0 1 1 1.132 1.132L8.16 11.48l3.819 3.818a.8.8 0 1 1-1.132 1.132L7.03 12.61l-3.818 3.82a.8.8 0 1 1-1.132-1.132L5.9 11.48 2.08 7.662A.8.8 0 1 1 3.212 6.53l3.818 3.82z\"/></svg>';const aE=\"superscript\";class lE extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(aE,i=>{const n=t.commands.get(aE);const o=new rw(i);o.set({label:e(\"Superscript\"),icon:sE,tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(aE);t.editing.view.focus()});return o})}}class cE extends Nw{static get requires(){return[rE,lE]}static get pluginName(){return\"Superscript\"}}function dE(t,e){let i=e.parent;while(i){if(i.name===t){return i}i=i.parent}}function uE(t,e,i,n,o=1){if(e>o){n.setAttribute(t,e,i)}else{n.removeAttribute(t,i)}}function hE(t,e,i={}){const n=t.createElement(\"tableCell\",i);t.insertElement(\"paragraph\",n);t.insert(n,e)}function fE(t){if(!t||!lt(t)){return t}const{top:e,right:i,bottom:n,left:o}=t;if(e==i&&i==n&&n==o){return e}}function mE(t,e){const i=parseFloat(t);if(Number.isNaN(i)){return t}if(String(i)!==String(t)){return t}return`${i}${e}`}function gE(t,e){const i=e.parent.parent;const n=parseInt(i.getAttribute(\"headingColumns\")||0);const{column:o}=t.getCellLocation(e);return!!n&&o<n}function pE(){return t=>{t.on(\"element:table\",(t,e,i)=>{const n=e.viewItem;if(!i.consumable.test(n,{name:true})){return}const{rows:o,headingRows:r,headingColumns:s}=_E(n);const a={};if(s){a.headingColumns=s}if(r){a.headingRows=r}const l=i.writer.createElement(\"table\",a);const c=i.splitToAllowedParent(l,e.modelCursor);if(!c){return}i.writer.insert(l,c.position);i.consumable.consume(n,{name:true});o.forEach(t=>i.convertItem(t,i.writer.createPositionAt(l,\"end\")));if(l.isEmpty){const t=i.writer.createElement(\"tableRow\");i.writer.insert(t,i.writer.createPositionAt(l,\"end\"));hE(i.writer,i.writer.createPositionAt(t,\"end\"))}e.modelRange=i.writer.createRange(i.writer.createPositionBefore(l),i.writer.createPositionAfter(l));if(c.cursorParent){e.modelCursor=i.writer.createPositionAt(c.cursorParent,0)}else{e.modelCursor=e.modelRange.end}})}}function bE(){return t=>{t.on(\"element:tr\",(t,e)=>{if(e.viewItem.isEmpty){t.stop()}},{priority:\"high\"})}}function wE(t){return e=>{e.on(`element:${t}`,(t,e,i)=>{const n=e.viewItem;if(!i.consumable.test(n,{name:true})){return}const o=i.writer.createElement(\"tableCell\");const r=i.splitToAllowedParent(o,e.modelCursor);if(!r){return}i.writer.insert(o,r.position);i.consumable.consume(n,{name:true});const s=i.writer.createPositionAt(o,0);i.convertChildren(n,s);if(!o.childCount){i.writer.insertElement(\"paragraph\",s)}e.modelRange=i.writer.createRange(i.writer.createPositionBefore(o),i.writer.createPositionAfter(o));e.modelCursor=e.modelRange.end})}}function _E(t){const e={headingRows:0,headingColumns:0};const i=[];const n=[];let o;for(const r of Array.from(t.getChildren())){if(r.name===\"tbody\"||r.name===\"thead\"||r.name===\"tfoot\"){if(r.name===\"thead\"&&!o){o=r}const t=Array.from(r.getChildren()).filter(t=>t.is(\"element\",\"tr\"));for(const r of t){if(r.parent.name===\"thead\"&&r.parent===o){e.headingRows++;i.push(r)}else{n.push(r);const t=kE(r,e,o);if(t>e.headingColumns){e.headingColumns=t}}}}}e.rows=[...i,...n];return e}function kE(t){let e=0;let i=0;const n=Array.from(t.getChildren()).filter(t=>t.name===\"th\"||t.name===\"td\");while(i<n.length&&n[i].name===\"th\"){const t=n[i];const o=parseInt(t.getAttribute(\"colspan\")||1);e=e+o;i++}return e}class vE{constructor(t,e={}){this.table=t;this.startRow=e.startRow||0;this.endRow=typeof e.endRow==\"number\"?e.endRow:undefined;this.includeSpanned=!!e.includeSpanned;this.column=typeof e.column==\"number\"?e.column:undefined;this._skipRows=new Set;this._row=0;this._column=0;this._cellIndex=0;this._spannedCells=new Map;this._nextCellAtColumn=-1}[Symbol.iterator](){return this}next(){const t=this.table.getChild(this._row);if(!t||this._isOverEndRow()){return{done:true}}let e,i,n;if(this._isSpanned(this._row,this._column)){e=this._getSpanned(this._row,this._column);i=!this.includeSpanned||this._shouldSkipRow()||this._shouldSkipColumn();n=this._formatOutValue(e,this._column,true)}else{e=t.getChild(this._cellIndex);if(!e){this._row++;this._column=0;this._cellIndex=0;this._nextCellAtColumn=-1;return this.next()}const o=parseInt(e.getAttribute(\"colspan\")||1);const r=parseInt(e.getAttribute(\"rowspan\")||1);if(o>1||r>1){this._recordSpans(this._row,this._column,r,o,e)}this._nextCellAtColumn=this._column+o;i=this._shouldSkipRow()||this._shouldSkipColumn();n=this._formatOutValue(e,this._column,false,r,o)}this._column++;if(this._column==this._nextCellAtColumn){this._cellIndex++}return i?this.next():n}skipRow(t){this._skipRows.add(t)}_isOverEndRow(){return this.endRow!==undefined&&this._row>this.endRow}_formatOutValue(t,e,i,n=1,o=1){return{done:false,value:{cell:t,row:this._row,column:e,isSpanned:i,rowspan:n,colspan:o,cellIndex:this._cellIndex}}}_shouldSkipRow(){const t=this._row<this.startRow;const e=this._skipRows.has(this._row);return t||e}_shouldSkipColumn(){if(this.column===undefined){return false}return this.column!=this._column}_isSpanned(t,e){if(!this._spannedCells.has(t)){return false}const i=this._spannedCells.get(t);return i.has(e)}_getSpanned(t,e){return this._spannedCells.get(t).get(e)}_recordSpans(t,e,i,n,o){for(let i=e+1;i<=e+n-1;i++){this._markSpannedCell(t,i,o)}for(let r=t+1;r<t+i;r++){for(let t=e;t<=e+n-1;t++){this._markSpannedCell(r,t,o)}}}_markSpannedCell(t,e,i){if(!this._spannedCells.has(t)){this._spannedCells.set(t,new Map)}const n=this._spannedCells.get(t);n.set(e,i)}}function yE(t,e){e.setCustomProperty(\"table\",true,t);return ax(t,e,{hasSelectionHandle:true})}function xE(t){return!!t.getCustomProperty(\"table\")&&sx(t)}function CE(t){const e=t.getSelectedElement();if(e&&xE(e)){return e}return null}function AE(t){const e=dE(\"table\",t.getFirstPosition());if(e&&xE(e.parent)){return e.parent}return null}function TE(t){const e=[];for(const i of VE(t.getRanges())){const t=i.getContainedElement();if(t&&t.is(\"tableCell\")){e.push(t)}}return e}function PE(t){const e=[];for(const i of t.getRanges()){const t=dE(\"tableCell\",i.start);if(t){e.push(t)}}return e}function EE(t){const e=TE(t);if(e.length){return e}return PE(t)}function SE(t){const e=t.map(t=>t.parent.index);return BE(e)}function ME(t){const e=dE(\"table\",t[0]);const i=[...new vE(e)];const n=i.filter(e=>t.includes(e.cell)).map(t=>t.column);return BE(n)}function OE(t,e){if(t.length<2||!FE(t)){return false}const i=new Set;const n=new Set;let o=0;for(const r of t){const{row:t,column:s}=e.getCellLocation(r);const a=parseInt(r.getAttribute(\"rowspan\")||1);const l=parseInt(r.getAttribute(\"colspan\")||1);i.add(t);n.add(s);if(a>1){i.add(t+a-1)}if(l>1){n.add(s+l-1)}o+=a*l}const r=zE(i,n);return r==o}function IE(t,e,i=0){const n=[];const o=new vE(t,{startRow:i,endRow:e-1});for(const t of o){const{row:i,rowspan:o}=t;const r=i+o-1;if(i<e&&e<=r){n.push(t)}}return n}function RE(t,e,i){const n=t.parent;const o=n.parent;const r=n.index;const s=parseInt(t.getAttribute(\"rowspan\"));const a=e-r;const l={};const c=s-a;if(c>1){l.rowspan=c}const d=parseInt(t.getAttribute(\"colspan\")||1);if(d>1){l.colspan=d}const u=r;const h=u+a;const f=[...new vE(o,{startRow:u,endRow:h,includeSpanned:true})];let m;for(const{row:e,column:n,cell:r,cellIndex:s}of f){if(r===t&&m===undefined){m=n}if(m!==undefined&&m===n&&e===h){const t=o.getChild(e);const n=i.createPositionAt(t,s);hE(i,n,l)}}uE(\"rowspan\",a,t,i)}function LE(t,e){const i=[];const n=new vE(t);for(const t of n){const{column:n,colspan:o}=t;const r=n+o-1;if(n<e&&e<=r){i.push(t)}}return i}function NE(t,e,i,n){const o=parseInt(t.getAttribute(\"colspan\"));const r=i-e;const s={};const a=o-r;if(a>1){s.colspan=a}const l=parseInt(t.getAttribute(\"rowspan\")||1);if(l>1){s.rowspan=l}hE(n,n.createPositionAfter(t),s);uE(\"colspan\",r,t,n)}function BE(t){const e=t.sort((t,e)=>t-e);const i=e[0];const n=e[e.length-1];return{first:i,last:n}}function VE(t){return Array.from(t).sort(DE)}function DE(t,e){const i=t.start;const n=e.start;return i.isBefore(n)?-1:1}function zE(t,e){const i=Array.from(t.values());const n=Array.from(e.values());const o=Math.max(...i);const r=Math.min(...i);const s=Math.max(...n);const a=Math.min(...n);return(o-r+1)*(s-a+1)}function FE(t){const e=dE(\"table\",t[0]);const i=SE(t);const n=parseInt(e.getAttribute(\"headingRows\")||0);if(!jE(i,n)){return false}const o=parseInt(e.getAttribute(\"headingColumns\")||0);const r=ME(t);return jE(r,o)}function jE({first:t,last:e},i){const n=t<i;const o=e<i;return n===o}function HE(t={}){return e=>e.on(\"insert:table\",(e,i,n)=>{const o=i.item;if(!n.consumable.consume(o,\"insert\")){return}n.consumable.consume(o,\"attribute:headingRows:table\");n.consumable.consume(o,\"attribute:headingColumns:table\");const r=t&&t.asWidget;const s=n.writer.createContainerElement(\"figure\",{class:\"table\"});const a=n.writer.createContainerElement(\"table\");n.writer.insert(n.writer.createPositionAt(s,0),a);let l;if(r){l=yE(s,n.writer)}const c=new vE(o);const d={headingRows:o.getAttribute(\"headingRows\")||0,headingColumns:o.getAttribute(\"headingColumns\")||0};const u=new Map;for(const e of c){const{row:i,cell:r}=e;const s=tS(ZE(i,d),a,n);const l=o.getChild(i);const c=u.get(i)||YE(l,i,s,n);u.set(i,c);n.consumable.consume(r,\"insert\");const h=n.writer.createPositionAt(c,\"end\");XE(e,d,h,n,t)}const h=n.mapper.toViewPosition(i.range.start);n.mapper.bindElements(o,r?l:s);n.writer.insert(h,r?l:s)})}function WE(t={}){return e=>e.on(\"insert:tableRow\",(e,i,n)=>{const o=i.item;if(!n.consumable.consume(o,\"insert\")){return}const r=o.parent;const s=n.mapper.toViewElement(r);const a=rS(s);const l=r.getChildIndex(o);const c=new vE(r,{startRow:l,endRow:l});const d={headingRows:r.getAttribute(\"headingRows\")||0,headingColumns:r.getAttribute(\"headingColumns\")||0};const u=new Map;for(const e of c){const i=tS(ZE(l,d),a,n);const r=u.get(l)||YE(o,l,i,n);u.set(l,r);n.consumable.consume(e.cell,\"insert\");const s=n.writer.createPositionAt(r,\"end\");XE(e,d,s,n,t)}})}function qE(t={}){return e=>e.on(\"insert:tableCell\",(e,i,n)=>{const o=i.item;if(!n.consumable.consume(o,\"insert\")){return}const r=o.parent;const s=r.parent;const a=s.getChildIndex(r);const l=new vE(s,{startRow:a,endRow:a});const c={headingRows:s.getAttribute(\"headingRows\")||0,headingColumns:s.getAttribute(\"headingColumns\")||0};for(const e of l){if(e.cell===o){const i=n.mapper.toViewElement(r);const s=n.writer.createPositionAt(i,r.getChildIndex(o));XE(e,c,s,n,t);return}}})}function $E(t={}){const e=!!t.asWidget;return t=>t.on(\"attribute:headingRows:table\",(t,i,n)=>{const o=i.item;if(!n.consumable.consume(i.item,t.name)){return}const r=n.mapper.toViewElement(o);const s=rS(r);const a=i.attributeOldValue;const l=i.attributeNewValue;if(l>a){const t=Array.from(o.getChildren()).filter(({index:t})=>c(t,a-1,l));const i=tS(\"thead\",s,n);oS(t,i,n,\"end\");for(const i of t){for(const t of i.getChildren()){JE(t,\"th\",n,e)}}}else{const t=Array.from(o.getChildren()).filter(({index:t})=>c(t,l-1,a)).reverse();const i=tS(\"tbody\",s,n);oS(t,i,n,0);const r=new vE(o,{startRow:l?l-1:l,endRow:a-1});const d={headingRows:o.getAttribute(\"headingRows\")||0,headingColumns:o.getAttribute(\"headingColumns\")||0};for(const t of r){KE(t,d,n,e)}}nS(\"thead\",s,n);nS(\"tbody\",s,n);function c(t,e,i){return t>e&&t<i}})}function UE(t={}){const e=!!t.asWidget;return t=>t.on(\"attribute:headingColumns:table\",(t,i,n)=>{const o=i.item;if(!n.consumable.consume(i.item,t.name)){return}const r={headingRows:o.getAttribute(\"headingRows\")||0,headingColumns:o.getAttribute(\"headingColumns\")||0};const s=i.attributeOldValue;const a=i.attributeNewValue;const l=(s>a?s:a)-1;for(const t of new vE(o)){if(t.column>l){continue}KE(t,r,n,e)}})}function GE(){return t=>t.on(\"remove:tableRow\",(t,e,i)=>{t.stop();const n=i.writer;const o=i.mapper;const r=o.toViewPosition(e.position).getLastMatchingPosition(t=>!t.item.is(\"tr\"));const s=r.nodeAfter;const a=s.parent;const l=a.parent;const c=n.createRangeOn(s);const d=n.remove(c);for(const t of n.createRangeIn(d).getItems()){o.unbindViewElement(t)}nS(\"thead\",l,i);nS(\"tbody\",l,i)},{priority:\"higher\"})}function JE(t,e,i,n){const o=i.writer;const r=i.mapper.toViewElement(t);if(!r){return}let s;if(n){const t=o.createEditableElement(e,r.getAttributes());s=ux(t,o);o.insert(o.createPositionAfter(r),s);o.move(o.createRangeIn(r),o.createPositionAt(s,0));o.remove(o.createRangeOn(r))}else{s=o.rename(e,r)}i.mapper.unbindViewElement(r);i.mapper.bindElements(t,s)}function KE(t,e,i,n){const{cell:o}=t;const r=QE(t,e);const s=i.mapper.toViewElement(o);if(s&&s.name!==r){JE(o,r,i,n)}}function XE(t,e,i,n,o){const r=o&&o.asWidget;const s=QE(t,e);const a=r?ux(n.writer.createEditableElement(s),n.writer):n.writer.createContainerElement(s);const l=t.cell;const c=l.getChild(0);const d=l.childCount===1&&c.name===\"paragraph\";n.writer.insert(i,a);if(d&&!sS(c)){const t=l.getChild(0);const e=n.writer.createPositionAt(a,\"end\");n.consumable.consume(t,\"insert\");if(o.asWidget){const i=n.writer.createContainerElement(\"span\",{style:\"display:inline-block\"});n.mapper.bindElements(t,i);n.writer.insert(e,i);n.mapper.bindElements(l,a)}else{n.mapper.bindElements(l,a);n.mapper.bindElements(t,a)}}else{n.mapper.bindElements(l,a)}}function YE(t,e,i,n){n.consumable.consume(t,\"insert\");const o=n.writer.createContainerElement(\"tr\");n.mapper.bindElements(t,o);const r=t.parent.getAttribute(\"headingRows\")||0;const s=r>0&&e>=r?e-r:e;const a=n.writer.createPositionAt(i,s);n.writer.insert(a,o);return o}function QE(t,e){const{row:i,column:n}=t;const{headingColumns:o,headingRows:r}=e;const s=r&&r>i;if(s){return\"th\"}const a=o&&o>n;return a?\"th\":\"td\"}function ZE(t,e){return t<e.headingRows?\"thead\":\"tbody\"}function tS(t,e,i){const n=eS(t,e);return n?n:iS(t,e,i)}function eS(t,e){for(const i of e.getChildren()){if(i.name==t){return i}}}function iS(t,e,i){const n=i.writer.createContainerElement(t);const o=i.writer.createPositionAt(e,t==\"tbody\"?\"end\":0);i.writer.insert(o,n);return n}function nS(t,e,i){const n=eS(t,e);if(n&&n.childCount===0){i.writer.remove(i.writer.createRangeOn(n))}}function oS(t,e,i,n){for(const o of t){const t=i.mapper.toViewElement(o);if(t){i.writer.move(i.writer.createRangeOn(t),i.writer.createPositionAt(e,n))}}}function rS(t){for(const e of t.getChildren()){if(e.name===\"table\"){return e}}}function sS(t){return!![...t.getAttributeKeys()].length}class aS extends Vw{refresh(){const t=this.editor.model;const e=t.document.selection;const i=t.schema;const n=lS(e.getFirstPosition());this.isEnabled=i.checkChild(n,\"table\")}execute(t={}){const e=this.editor.model;const i=e.document.selection;const n=this.editor.plugins.get(\"TableUtils\");const o=parseInt(t.rows)||2;const r=parseInt(t.columns)||2;const s=hx(i,e);e.change(t=>{const i=n.createTable(t,o,r);e.insertContent(i,s);t.setSelection(t.createPositionAt(i.getNodeByPath([0,0,0]),0))})}}function lS(t){const e=t.parent;return e===e.root?e:e.parent}class cS extends Vw{constructor(t,e={}){super(t);this.order=e.order||\"below\"}refresh(){const t=this.editor.model.document.selection;const e=dE(\"table\",t.getFirstPosition());this.isEnabled=!!e}execute(){const t=this.editor;const e=t.model.document.selection;const i=t.plugins.get(\"TableUtils\");const n=this.order===\"above\";const o=EE(e);const r=SE(o);const s=n?r.first:r.last;const a=dE(\"table\",o[0]);i.insertRows(a,{at:n?s:s+1,copyStructureFromAbove:!n})}}class dS extends Vw{constructor(t,e={}){super(t);this.order=e.order||\"right\"}refresh(){const t=this.editor.model.document.selection;const e=dE(\"table\",t.getFirstPosition());this.isEnabled=!!e}execute(){const t=this.editor;const e=t.model.document.selection;const i=t.plugins.get(\"TableUtils\");const n=this.order===\"left\";const o=EE(e);const r=ME(o);const s=n?r.first:r.last;const a=dE(\"table\",o[0]);i.insertColumns(a,{columns:1,at:n?s:s+1})}}class uS extends Vw{constructor(t,e={}){super(t);this.direction=e.direction||\"horizontally\"}refresh(){const t=EE(this.editor.model.document.selection);this.isEnabled=t.length===1}execute(){const t=EE(this.editor.model.document.selection)[0];const e=this.direction===\"horizontally\";const i=this.editor.plugins.get(\"TableUtils\");if(e){i.splitCellHorizontally(t,2)}else{i.splitCellVertically(t,2)}}}class hS extends Vw{constructor(t,e){super(t);this.direction=e.direction;this.isHorizontal=this.direction==\"right\"||this.direction==\"left\"}refresh(){const t=this._getMergeableCell();this.value=t;this.isEnabled=!!t}execute(){const t=this.editor.model;const e=t.document;const i=PE(e.selection)[0];const n=this.value;const o=this.direction;t.change(t=>{const e=o==\"right\"||o==\"down\";const r=e?i:n;const s=e?n:i;const a=s.parent;gS(s,r,t);const l=this.isHorizontal?\"colspan\":\"rowspan\";const c=parseInt(i.getAttribute(l)||1);const d=parseInt(n.getAttribute(l)||1);t.setAttribute(l,c+d,r);t.setSelection(t.createRangeIn(r));if(!a.childCount){const e=this.editor.plugins.get(\"TableUtils\");const i=dE(\"table\",a);e.removeRows(i,{at:a.index,batch:t.batch})}})}_getMergeableCell(){const t=this.editor.model;const e=t.document;const i=PE(e.selection)[0];if(!i){return}const n=this.editor.plugins.get(\"TableUtils\");const o=this.isHorizontal?fS(i,this.direction,n):mS(i,this.direction);if(!o){return}const r=this.isHorizontal?\"rowspan\":\"colspan\";const s=parseInt(i.getAttribute(r)||1);const a=parseInt(o.getAttribute(r)||1);if(a===s){return o}}}function fS(t,e,i){const n=t.parent;const o=n.parent;const r=e==\"right\"?t.nextSibling:t.previousSibling;const s=(o.getAttribute(\"headingColumns\")||0)>0;if(!r){return}const a=e==\"right\"?t:r;const l=e==\"right\"?r:t;const{column:c}=i.getCellLocation(a);const{column:d}=i.getCellLocation(l);const u=parseInt(a.getAttribute(\"colspan\")||1);const h=gE(i,a,o);const f=gE(i,l,o);if(s&&h!=f){return}const m=c+u===d;return m?r:undefined}function mS(t,e){const i=t.parent;const n=i.parent;const o=n.getChildIndex(i);if(e==\"down\"&&o===n.childCount-1||e==\"up\"&&o===0){return}const r=parseInt(t.getAttribute(\"rowspan\")||1);const s=n.getAttribute(\"headingRows\")||0;const a=e==\"down\"&&o+r===s;const l=e==\"up\"&&o===s;if(s&&(a||l)){return}const c=parseInt(t.getAttribute(\"rowspan\")||1);const d=e==\"down\"?o+c:o;const u=[...new vE(n,{endRow:d})];const h=u.find(e=>e.cell===t);const f=h.column;const m=u.find(({row:t,rowspan:i,column:n})=>{if(n!==f){return false}if(e==\"down\"){return t===d}else{return d===t+i}});return m&&m.cell}function gS(t,e,i){if(!pS(t)){if(pS(e)){i.remove(i.createRangeIn(e))}i.move(i.createRangeIn(t),i.createPositionAt(e,\"end\"))}i.remove(t)}function pS(t){return t.childCount==1&&t.getChild(0).is(\"paragraph\")&&t.getChild(0).isEmpty}class bS extends Vw{refresh(){const t=EE(this.editor.model.document.selection);const e=t[0];if(e){const i=dE(\"table\",e);const n=this.editor.plugins.get(\"TableUtils\").getRows(i);const o=n-1;const r=SE(t);const s=r.first===0&&r.last===o;this.isEnabled=!s}else{this.isEnabled=false}}execute(){const t=this.editor.model;const e=EE(t.document.selection);const i=SE(e);const n=e[0];const o=dE(\"table\",n);const r=this.editor.plugins.get(\"TableUtils\").getCellLocation(n).column;const s=t.createBatch();t.enqueueChange(s,t=>{t.setSelection(t.createSelection(o,\"on\"));const e=i.last-i.first+1;this.editor.plugins.get(\"TableUtils\").removeRows(o,{at:i.first,rows:e,batch:s})});t.enqueueChange(s,t=>{const e=wS(o,i.first,r);t.setSelection(t.createPositionAt(e,0))})}}function wS(t,e,i){const n=t.getChild(e)||t.getChild(t.childCount-1);let o=n.getChild(0);let r=0;for(const t of n.getChildren()){if(r>i){return o}o=t;r+=parseInt(t.getAttribute(\"colspan\")||1)}return o}class _S extends Vw{refresh(){const t=EE(this.editor.model.document.selection);const e=t[0];if(e){const i=dE(\"table\",e);const n=this.editor.plugins.get(\"TableUtils\").getColumns(i);const{first:o,last:r}=ME(t);this.isEnabled=r-o<n-1}else{this.isEnabled=false}}execute(){const[t,e]=vS(this.editor.model.document.selection);const i=t.parent.parent;const n=[...new vE(i)];const o={first:n.find(e=>e.cell===t).column,last:n.find(t=>t.cell===e).column};const r=kS(n,t,e,o);this.editor.model.change(t=>{const e=o.last-o.first+1;this.editor.plugins.get(\"TableUtils\").removeColumns(i,{at:o.first,columns:e});t.setSelection(t.createPositionAt(r,0))})}}function kS(t,e,i,n){const o=parseInt(i.getAttribute(\"colspan\")||1);if(o>1){return i}else if(e.previousSibling||i.nextSibling){return i.nextSibling||e.previousSibling}else{if(n.first){return t.reverse().find(({column:t})=>t<n.first).cell}else{return t.reverse().find(({column:t})=>t>n.last).cell}}}function vS(t){const e=EE(t);const i=e[0];const n=e.pop();const o=[i,n];return i.isBefore(n)?o:o.reverse()}class yS extends Vw{refresh(){const t=this.editor.model;const e=EE(t.document.selection);const i=e.length>0;this.isEnabled=i;this.value=i&&e.every(t=>this._isInHeading(t,t.parent.parent))}execute(t={}){if(t.forceValue===this.value){return}const e=this.editor.model;const i=EE(e.document.selection);const n=dE(\"table\",i[0]);const{first:o,last:r}=SE(i);const s=this.value?o:r+1;const a=n.getAttribute(\"headingRows\")||0;e.change(t=>{if(s){const e=s>a?a:0;const i=IE(n,s,e);for(const{cell:e}of i){RE(e,s,t)}}uE(\"headingRows\",s,n,t,0)})}_isInHeading(t,e){const i=parseInt(e.getAttribute(\"headingRows\")||0);return!!i&&t.parent.index<i}}class xS extends Vw{refresh(){const t=this.editor.model;const e=EE(t.document.selection);const i=this.editor.plugins.get(\"TableUtils\");const n=e.length>0;this.isEnabled=n;this.value=n&&e.every(t=>gE(i,t))}execute(t={}){if(t.forceValue===this.value){return}const e=this.editor.model;const i=EE(e.document.selection);const n=dE(\"table\",i[0]);const{first:o,last:r}=ME(i);const s=this.value?o:r+1;e.change(t=>{if(s){const e=LE(n,s);for(const{cell:i,column:n}of e){NE(i,n,s,t)}}uE(\"headingColumns\",s,n,t,0)})}}class CS extends Nw{static get pluginName(){return\"TableUtils\"}getCellLocation(t){const e=t.parent;const i=e.parent;const n=i.getChildIndex(e);const o=new vE(i,{startRow:n,endRow:n});for(const{cell:e,row:i,column:n}of o){if(e===t){return{row:i,column:n}}}}createTable(t,e,i){const n=t.createElement(\"table\");AS(t,n,0,e,i);return n}insertRows(t,e={}){const i=this.editor.model;const n=e.at||0;const o=e.rows||1;const r=e.copyStructureFromAbove!==undefined;const s=e.copyStructureFromAbove?n-1:n;const a=this.getRows(t);const l=this.getColumns(t);i.change(e=>{const i=t.getAttribute(\"headingRows\")||0;if(i>n){e.setAttribute(\"headingRows\",i+o,t)}if(!r&&(n===0||n===a)){AS(e,t,n,o,l);return}const c=r?Math.max(n,s):n;const d=new vE(t,{endRow:c});const u=new Array(l).fill(1);for(const{row:t,column:i,rowspan:a,colspan:l,cell:c}of d){const d=t+a-1;const h=t<n&&n<=d;const f=t<=s&&s<=d;if(h){e.setAttribute(\"rowspan\",a+o,c);u[i]=-l}else if(r&&f){u[i]=l}}for(let i=0;i<o;i++){const i=e.createElement(\"tableRow\");e.insert(i,t,n);for(let t=0;t<u.length;t++){const n=u[t];const o=e.createPositionAt(i,\"end\");if(n>0){hE(e,o,n>1?{colspan:n}:null)}t+=Math.abs(n)-1}}})}insertColumns(t,e={}){const i=this.editor.model;const n=e.at||0;const o=e.columns||1;i.change(e=>{const i=t.getAttribute(\"headingColumns\");if(n<i){e.setAttribute(\"headingColumns\",i+o,t)}const r=this.getColumns(t);if(n===0||r===n){for(const i of t.getChildren()){TS(o,e,e.createPositionAt(i,n?\"end\":0))}return}const s=new vE(t,{column:n,includeSpanned:true});for(const{row:i,cell:r,cellIndex:a}of s){const l=parseInt(r.getAttribute(\"rowspan\")||1);const c=parseInt(r.getAttribute(\"colspan\")||1);if(a!==n&&c>1){e.setAttribute(\"colspan\",c+o,r);s.skipRow(i);if(l>1){for(let t=i+1;t<i+l;t++){s.skipRow(t)}}}else{const n=e.createPositionAt(t.getChild(i),a);TS(o,e,n)}}})}removeRows(t,e){const i=this.editor.model;const n=e.rows||1;const o=e.at;const r=o+n-1;const s=e.batch||\"default\";i.enqueueChange(s,e=>{const{cellsToMove:n,cellsToTrim:a}=MS(t,o,r);if(n.size){const i=r+1;OS(t,i,n,e)}for(let i=r;i>=o;i--){e.remove(t.getChild(i))}for(const{rowspan:t,cell:i}of a){uE(\"rowspan\",t,i,e)}SS(t,o,r,i,s)})}removeColumns(t,e){const i=this.editor.model;const n=e.at;const o=e.columns||1;const r=e.at+o-1;i.change(e=>{ES(t,{first:n,last:r},e);const i=[];for(let o=r;o>=n;o--){for(const{cell:n,column:r,colspan:s}of[...new vE(t)]){if(r<=o&&s>1&&r+s>o){uE(\"colspan\",s-1,n,e)}else if(r===o){const t=n.parent;e.remove(n);if(!t.childCount){i.push(t.index)}}}}i.reverse().forEach(i=>this.removeRows(t,{at:i,batch:e.batch}))})}splitCellVertically(t,e=2){const i=this.editor.model;const n=t.parent;const o=n.parent;const r=parseInt(t.getAttribute(\"rowspan\")||1);const s=parseInt(t.getAttribute(\"colspan\")||1);i.change(i=>{if(s>1){const{newCellsSpan:n,updatedSpan:o}=PS(s,e);uE(\"colspan\",o,t,i);const a={};if(n>1){a.colspan=n}if(r>1){a.rowspan=r}const l=s>e?e-1:s-1;TS(l,i,i.createPositionAfter(t),a)}if(s<e){const n=e-s;const a=[...new vE(o)];const{column:l}=a.find(({cell:e})=>e===t);const c=a.filter(({cell:e,colspan:i,column:n})=>{const o=e!==t&&n===l;const r=n<l&&n+i>l;return o||r});for(const{cell:t,colspan:e}of c){i.setAttribute(\"colspan\",e+n,t)}const d={};if(r>1){d.rowspan=r}TS(n,i,i.createPositionAfter(t),d);const u=o.getAttribute(\"headingColumns\")||0;if(u>l){uE(\"headingColumns\",u+n,o,i)}}})}splitCellHorizontally(t,e=2){const i=this.editor.model;const n=t.parent;const o=n.parent;const r=o.getChildIndex(n);const s=parseInt(t.getAttribute(\"rowspan\")||1);const a=parseInt(t.getAttribute(\"colspan\")||1);i.change(i=>{if(s>1){const n=[...new vE(o,{startRow:r,endRow:r+s-1,includeSpanned:true})];const{newCellsSpan:l,updatedSpan:c}=PS(s,e);uE(\"rowspan\",c,t,i);const{column:d}=n.find(({cell:e})=>e===t);const u={};if(l>1){u.rowspan=l}if(a>1){u.colspan=a}for(const{column:t,row:e,cellIndex:s}of n){const n=e>=r+c;const a=t===d;const h=(e+r+c)%l===0;if(n&&a&&h){const t=i.createPositionAt(o.getChild(e),s);TS(1,i,t,u)}}}if(s<e){const n=e-s;const l=[...new vE(o,{startRow:0,endRow:r})];for(const{cell:e,rowspan:o,row:s}of l){if(e!==t&&s+o>r){const t=o+n;i.setAttribute(\"rowspan\",t,e)}}const c={};if(a>1){c.colspan=a}AS(i,o,r+1,n,1,c);const d=o.getAttribute(\"headingRows\")||0;if(d>r){uE(\"headingRows\",d+n,o,i)}}})}getColumns(t){const e=t.getChild(0);return[...e.getChildren()].reduce((t,e)=>{const i=parseInt(e.getAttribute(\"colspan\")||1);return t+i},0)}getRows(t){return t.childCount}}function AS(t,e,i,n,o,r={}){for(let s=0;s<n;s++){const n=t.createElement(\"tableRow\");t.insert(n,e,i);TS(o,t,t.createPositionAt(n,\"end\"),r)}}function TS(t,e,i,n={}){for(let o=0;o<t;o++){hE(e,i,n)}}function PS(t,e){if(t<e){return{newCellsSpan:1,updatedSpan:1}}const i=Math.floor(t/e);const n=t-i*e+i;return{newCellsSpan:i,updatedSpan:n}}function ES(t,e,i){const n=t.getAttribute(\"headingColumns\")||0;if(n&&e.first<n){const o=Math.min(n-1,e.last)-e.first+1;i.setAttribute(\"headingColumns\",n-o,t)}}function SS(t,e,i,n,o){n.enqueueChange(o,n=>{const o=t.getAttribute(\"headingRows\")||0;if(e<o){const r=i<o?o-(i-e+1):e;uE(\"headingRows\",r,t,n,0)}})}function MS(t,e,i){const n=new Map;const o=[];for(const{row:r,column:s,rowspan:a,cell:l}of new vE(t,{endRow:i})){const t=r+a-1;const c=r>=e&&r<=i&&t>i;if(c){const t=i-r+1;const e=a-t;n.set(s,{cell:l,rowspan:e})}const d=r<e&&t>=e;if(d){let n;if(t>=i){n=i-e+1}else{n=t-e+1}o.push({cell:l,rowspan:a-n})}}return{cellsToMove:n,cellsToTrim:o}}function OS(t,e,i,n){const o=new vE(t,{includeSpanned:true,startRow:e,endRow:e});const r=[...o];const s=t.getChild(e);let a;for(const{column:t,cell:e,isSpanned:o}of r){if(i.has(t)){const{cell:e,rowspan:o}=i.get(t);const r=a?n.createPositionAfter(a):n.createPositionAt(s,0);n.move(n.createRangeOn(e),r);uE(\"rowspan\",o,e,n);a=e}else if(!o){a=e}}}class IS extends Vw{refresh(){const t=TE(this.editor.model.document.selection);this.isEnabled=OE(t,this.editor.plugins.get(CS))}execute(){const t=this.editor.model;const e=this.editor.plugins.get(CS);t.change(i=>{const n=TE(t.document.selection);const o=n.shift();i.setSelection(o,0);const{mergeWidth:r,mergeHeight:s}=NS(o,n,e);uE(\"colspan\",r,o,i);uE(\"rowspan\",s,o,i);const a=[];for(const t of n){const e=t.parent;RS(t,o,i);if(!e.childCount){a.push(e.index)}}if(a.length){const t=dE(\"table\",o);a.reverse().forEach(n=>e.removeRows(t,{at:n,batch:i.batch}))}i.setSelection(o,\"in\")})}}function RS(t,e,i){if(!LS(t)){if(LS(e)){i.remove(i.createRangeIn(e))}i.move(i.createRangeIn(t),i.createPositionAt(e,\"end\"))}i.remove(t)}function LS(t){return t.childCount==1&&t.getChild(0).is(\"paragraph\")&&t.getChild(0).isEmpty}function NS(t,e,i){let n=0;let o=0;for(const t of e){const{row:e,column:r}=i.getCellLocation(t);n=BS(t,r,n,\"colspan\");o=BS(t,e,o,\"rowspan\")}const{row:r,column:s}=i.getCellLocation(t);const a=n-s;const l=o-r;return{mergeWidth:a,mergeHeight:l}}function BS(t,e,i,n){const o=parseInt(t.getAttribute(n)||1);return Math.max(i,e+o)}class VS extends Vw{refresh(){const t=EE(this.editor.model.document.selection);this.isEnabled=t.length>0}execute(){const t=this.editor.model;const e=EE(t.document.selection);const i=SE(e);const n=dE(\"table\",e[0]);const o=[];for(let e=i.first;e<=i.last;e++){for(const i of n.getChild(e).getChildren()){o.push(t.createRangeOn(i))}}t.change(t=>{t.setSelection(o)})}}class DS extends Vw{refresh(){const t=EE(this.editor.model.document.selection);this.isEnabled=t.length>0}execute(){const t=this.editor.model;const e=EE(t.document.selection);const i=e[0];const n=e.pop();const o=this.editor.plugins.get(\"TableUtils\");const r=o.getCellLocation(i);const s=o.getCellLocation(n);const a=Math.min(r.column,s.column);const l=Math.max(r.column,s.column);const c=[];for(const e of new vE(dE(\"table\",i))){if(e.column>=a&&e.column<=l){c.push(t.createRangeOn(e.cell))}}t.change(t=>{t.setSelection(c)})}}function zS(t){t.document.registerPostFixer(e=>FS(e,t))}function FS(t,e){const i=e.document.differ.getChanges();let n=false;const o=new Set;for(const e of i){let i;if(e.name==\"table\"&&e.type==\"insert\"){i=e.position.nodeAfter}if(e.name==\"tableRow\"||e.name==\"tableCell\"){i=dE(\"table\",e.position)}if($S(e)){i=dE(\"table\",e.range.start)}if(i&&!o.has(i)){n=jS(i,t)||n;n=HS(i,t)||n;o.add(i)}}return n}function jS(t,e){let i=false;const n=WS(t);if(n.length){i=true;for(const t of n){uE(\"rowspan\",t.rowspan,t.cell,e,1)}}return i}function HS(t,e){let i=false;const n=qS(t);const o=[];for(const[t,e]of n.entries()){if(!e){o.push(t)}}if(o.length){i=true;for(const i of o.reverse()){e.remove(t.getChild(i));n.splice(i,1)}}const r=n[0];const s=n.every(t=>t===r);if(!s){const o=n.reduce((t,e)=>e>t?e:t,0);for(const[r,s]of n.entries()){const n=o-s;if(n){for(let i=0;i<n;i++){hE(e,e.createPositionAt(t.getChild(r),\"end\"))}i=true}}}return i}function WS(t){const e=parseInt(t.getAttribute(\"headingRows\")||0);const i=t.childCount;const n=[];for(const{row:o,rowspan:r,cell:s}of new vE(t)){if(r<2){continue}const t=o<e;const a=t?e:i;if(o+r>a){const t=a-o;n.push({cell:s,rowspan:t})}}return n}function qS(t){const e=new Array(t.childCount).fill(0);for(const{row:i}of new vE(t,{includeSpanned:true})){e[i]++}return e}function $S(t){const e=t.type===\"attribute\";const i=t.attributeKey;return e&&(i===\"headingRows\"||i===\"colspan\"||i===\"rowspan\")}function US(t){t.document.registerPostFixer(e=>GS(e,t))}function GS(t,e){const i=e.document.differ.getChanges();let n=false;for(const e of i){if(e.type==\"insert\"&&e.name==\"table\"){n=JS(e.position.nodeAfter,t)||n}if(e.type==\"insert\"&&e.name==\"tableRow\"){n=KS(e.position.nodeAfter,t)||n}if(e.type==\"insert\"&&e.name==\"tableCell\"){n=XS(e.position.nodeAfter,t)||n}if(YS(e)){n=XS(e.position.parent,t)||n}}return n}function JS(t,e){let i=false;for(const n of t.getChildren()){i=KS(n,e)||i}return i}function KS(t,e){let i=false;for(const n of t.getChildren()){i=XS(n,e)||i}return i}function XS(t,e){if(t.childCount==0){e.insertElement(\"paragraph\",t);return true}const i=Array.from(t.getChildren()).filter(t=>t.is(\"text\"));for(const t of i){e.wrap(e.createRangeOn(t),\"paragraph\")}return!!i.length}function YS(t){if(!t.position||!t.position.parent.is(\"tableCell\")){return false}return t.type==\"insert\"&&t.name==\"$text\"||t.type==\"remove\"}function QS(t){t.document.registerPostFixer(()=>ZS(t))}function ZS(t){const e=t.document.differ;const i=new Set;let n=0;for(const t of e.getChanges()){const e=t.type==\"insert\"||t.type==\"remove\"?t.position.parent:t.range.start.parent;if(!e.is(\"tableCell\")){continue}if(t.type==\"insert\"){n++}if(tM(e,t.type,n)){i.add(e)}}if(i.size){for(const t of i.values()){e.refreshItem(t)}return true}return false}function tM(t,e,i){const n=Array.from(t.getChildren()).some(t=>t.is(\"paragraph\"));if(!n){return false}if(e==\"attribute\"){const e=Array.from(t.getChild(0).getAttributeKeys()).length;return t.childCount===1&&e<2}return t.childCount<=(e==\"insert\"?i+1:1)}var eM=i(96);class iM extends Nw{static get pluginName(){return\"TableEditing\"}init(){const t=this.editor;const e=t.model;const i=e.schema;const n=t.conversion;i.register(\"table\",{allowWhere:\"$block\",allowAttributes:[\"headingRows\",\"headingColumns\"],isLimit:true,isObject:true,isBlock:true});i.register(\"tableRow\",{allowIn:\"table\",isLimit:true});i.register(\"tableCell\",{allowIn:\"tableRow\",allowAttributes:[\"colspan\",\"rowspan\"],isObject:true});i.extend(\"$block\",{allowIn:\"tableCell\"});i.addChildCheck((t,e)=>{if(e.name==\"table\"&&Array.from(t.getNames()).includes(\"table\")){return false}});n.for(\"upcast\").add(pE());n.for(\"editingDowncast\").add(HE({asWidget:true}));n.for(\"dataDowncast\").add(HE());n.for(\"upcast\").elementToElement({model:\"tableRow\",view:\"tr\"});n.for(\"upcast\").add(bE());n.for(\"editingDowncast\").add(WE({asWidget:true}));n.for(\"dataDowncast\").add(WE());n.for(\"downcast\").add(GE());n.for(\"upcast\").add(wE(\"td\"));n.for(\"upcast\").add(wE(\"th\"));n.for(\"editingDowncast\").add(qE({asWidget:true}));n.for(\"dataDowncast\").add(qE());n.attributeToAttribute({model:\"colspan\",view:\"colspan\"});n.attributeToAttribute({model:\"rowspan\",view:\"rowspan\"});n.for(\"editingDowncast\").add(UE({asWidget:true}));n.for(\"dataDowncast\").add(UE());n.for(\"editingDowncast\").add($E({asWidget:true}));n.for(\"dataDowncast\").add($E());t.commands.add(\"insertTable\",new aS(t));t.commands.add(\"insertTableRowAbove\",new cS(t,{order:\"above\"}));t.commands.add(\"insertTableRowBelow\",new cS(t,{order:\"below\"}));t.commands.add(\"insertTableColumnLeft\",new dS(t,{order:\"left\"}));t.commands.add(\"insertTableColumnRight\",new dS(t,{order:\"right\"}));t.commands.add(\"removeTableRow\",new bS(t));t.commands.add(\"removeTableColumn\",new _S(t));t.commands.add(\"splitTableCellVertically\",new uS(t,{direction:\"vertically\"}));t.commands.add(\"splitTableCellHorizontally\",new uS(t,{direction:\"horizontally\"}));t.commands.add(\"mergeTableCells\",new IS(t));t.commands.add(\"mergeTableCellRight\",new hS(t,{direction:\"right\"}));t.commands.add(\"mergeTableCellLeft\",new hS(t,{direction:\"left\"}));t.commands.add(\"mergeTableCellDown\",new hS(t,{direction:\"down\"}));t.commands.add(\"mergeTableCellUp\",new hS(t,{direction:\"up\"}));t.commands.add(\"setTableColumnHeader\",new xS(t));t.commands.add(\"setTableRowHeader\",new yS(t));t.commands.add(\"selectTableRow\",new VS(t));t.commands.add(\"selectTableColumn\",new DS(t));zS(e);QS(e);US(e)}static get requires(){return[CS]}}var nM=i(98);class oM extends _b{constructor(t){super(t);const e=this.bindTemplate;this.items=this._createGridCollection();this.set(\"rows\",0);this.set(\"columns\",0);this.bind(\"label\").to(this,\"columns\",this,\"rows\",(t,e)=>`${e} × ${t}`);this.setTemplate({tag:\"div\",attributes:{class:[\"ck\"]},children:[{tag:\"div\",attributes:{class:[\"ck-insert-table-dropdown__grid\"]},on:{\"mouseover@.ck-insert-table-dropdown-grid-box\":e.to(\"boxover\")},children:this.items},{tag:\"div\",attributes:{class:[\"ck-insert-table-dropdown__label\"]},children:[{text:e.to(\"label\")}]}],on:{mousedown:e.to(t=>{t.preventDefault()}),click:e.to(()=>{this.fire(\"execute\")})}});this.on(\"boxover\",(t,e)=>{const{row:i,column:n}=e.target.dataset;this.set({rows:parseInt(i),columns:parseInt(n)})});this.on(\"change:columns\",()=>{this._highlightGridBoxes()});this.on(\"change:rows\",()=>{this._highlightGridBoxes()})}focus(){}focusLast(){}_highlightGridBoxes(){const t=this.rows;const e=this.columns;this.items.map((i,n)=>{const o=Math.floor(n/10);const r=n%10;const s=o<t&&r<e;i.set(\"isOn\",s)})}_createGridCollection(){const t=[];for(let e=0;e<100;e++){const i=Math.floor(e/10);const n=e%10;t.push(new rM(this.locale,i+1,n+1))}return this.createCollection(t)}}class rM extends _b{constructor(t,e,i){super(t);const n=this.bindTemplate;this.set(\"isOn\",false);this.setTemplate({tag:\"div\",attributes:{class:[\"ck-insert-table-dropdown-grid-box\",n.if(\"isOn\",\"ck-on\")],\"data-row\":e,\"data-column\":i}})}}var sM='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M3 6v3h4V6H3zm0 4v3h4v-3H3zm0 4v3h4v-3H3zm5 3h4v-3H8v3zm5 0h4v-3h-4v3zm4-4v-3h-4v3h4zm0-4V6h-4v3h4zm1.5 8a1.5 1.5 0 0 1-1.5 1.5H3A1.5 1.5 0 0 1 1.5 17V4c.222-.863 1.068-1.5 2-1.5h13c.932 0 1.778.637 2 1.5v13zM12 13v-3H8v3h4zm0-4V6H8v3h4z\"/></svg>';var aM='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2.5 1h15A1.5 1.5 0 0 1 19 2.5v15a1.5 1.5 0 0 1-1.5 1.5h-15A1.5 1.5 0 0 1 1 17.5v-15A1.5 1.5 0 0 1 2.5 1zM2 2v16h16V2H2z\" opacity=\".6\"/><path d=\"M18 7v1H2V7h16zm0 5v1H2v-1h16z\" opacity=\".6\"/><path d=\"M14 1v18a1 1 0 0 1-1 1H7a1 1 0 0 1-1-1V1a1 1 0 0 1 1-1h6a1 1 0 0 1 1 1zm-2 1H8v4h4V2zm0 6H8v4h4V8zm0 6H8v4h4v-4z\"/></svg>';var lM='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2.5 1h15A1.5 1.5 0 0 1 19 2.5v15a1.5 1.5 0 0 1-1.5 1.5h-15A1.5 1.5 0 0 1 1 17.5v-15A1.5 1.5 0 0 1 2.5 1zM2 2v16h16V2H2z\" opacity=\".6\"/><path d=\"M7 2h1v16H7V2zm5 0h1v16h-1V2z\" opacity=\".6\"/><path d=\"M1 6h18a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H1a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1zm1 2v4h4V8H2zm6 0v4h4V8H8zm6 0v4h4V8h-4z\"/></svg>';var cM='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2.5 1h15A1.5 1.5 0 0 1 19 2.5v15a1.5 1.5 0 0 1-1.5 1.5h-15A1.5 1.5 0 0 1 1 17.5v-15A1.5 1.5 0 0 1 2.5 1zM2 2v16h16V2H2z\" opacity=\".6\"/><path d=\"M7 2h1v16H7V2zm5 0h1v7h-1V2zm6 5v1H2V7h16zM8 12v1H2v-1h6z\" opacity=\".6\"/><path d=\"M7 7h12a1 1 0 0 1 1 1v11a1 1 0 0 1-1 1H7a1 1 0 0 1-1-1V8a1 1 0 0 1 1-1zm1 2v9h10V9H8z\"/></svg>';class dM extends Nw{init(){const t=this.editor;const e=this.editor.t;const i=t.locale.contentLanguageDirection;const n=i===\"ltr\";t.ui.componentFactory.add(\"insertTable\",i=>{const n=t.commands.get(\"insertTable\");const o=bw(i);o.bind(\"isEnabled\").to(n);o.buttonView.set({icon:sM,label:e(\"Insert table\"),tooltip:true});let r;o.on(\"change:isOpen\",()=>{if(r){return}r=new oM(i);o.panelView.children.add(r);r.delegate(\"execute\").to(o);o.buttonView.on(\"open\",()=>{r.rows=0;r.columns=0});o.on(\"execute\",()=>{t.execute(\"insertTable\",{rows:r.rows,columns:r.columns});t.editing.view.focus()})});return o});t.ui.componentFactory.add(\"tableColumn\",t=>{const i=[{type:\"switchbutton\",model:{commandName:\"setTableColumnHeader\",label:e(\"Header column\"),bindIsOn:true}},{type:\"separator\"},{type:\"button\",model:{commandName:n?\"insertTableColumnLeft\":\"insertTableColumnRight\",label:e(\"Insert column left\")}},{type:\"button\",model:{commandName:n?\"insertTableColumnRight\":\"insertTableColumnLeft\",label:e(\"Insert column right\")}},{type:\"button\",model:{commandName:\"removeTableColumn\",label:e(\"Delete column\")}},{type:\"button\",model:{commandName:\"selectTableColumn\",label:e(\"Select column\")}}];return this._prepareDropdown(e(\"Column\"),aM,i,t)});t.ui.componentFactory.add(\"tableRow\",t=>{const i=[{type:\"switchbutton\",model:{commandName:\"setTableRowHeader\",label:e(\"Header row\"),bindIsOn:true}},{type:\"separator\"},{type:\"button\",model:{commandName:\"insertTableRowAbove\",label:e(\"Insert row above\")}},{type:\"button\",model:{commandName:\"insertTableRowBelow\",label:e(\"Insert row below\")}},{type:\"button\",model:{commandName:\"removeTableRow\",label:e(\"Delete row\")}},{type:\"button\",model:{commandName:\"selectTableRow\",label:e(\"Select row\")}}];return this._prepareDropdown(e(\"Row\"),lM,i,t)});t.ui.componentFactory.add(\"mergeTableCells\",t=>{const i=[{type:\"button\",model:{commandName:\"mergeTableCellUp\",label:e(\"Merge cell up\")}},{type:\"button\",model:{commandName:n?\"mergeTableCellRight\":\"mergeTableCellLeft\",label:e(\"Merge cell right\")}},{type:\"button\",model:{commandName:\"mergeTableCellDown\",label:e(\"Merge cell down\")}},{type:\"button\",model:{commandName:n?\"mergeTableCellLeft\":\"mergeTableCellRight\",label:e(\"Merge cell left\")}},{type:\"separator\"},{type:\"button\",model:{commandName:\"splitTableCellVertically\",label:e(\"Split cell vertically\")}},{type:\"button\",model:{commandName:\"splitTableCellHorizontally\",label:e(\"Split cell horizontally\")}}];return this._prepareMergeSplitButtonDropdown(e(\"Merge cells\"),cM,i,t)})}_prepareDropdown(t,e,i,n){const o=this.editor;const r=bw(n);const s=this._fillDropdownWithListOptions(r,i);r.buttonView.set({label:t,icon:e,tooltip:true});r.bind(\"isEnabled\").toMany(s,\"isEnabled\",(...t)=>t.some(t=>t));this.listenTo(r,\"execute\",t=>{o.execute(t.source.commandName);o.editing.view.focus()});return r}_prepareMergeSplitButtonDropdown(t,e,i,n){const o=this.editor;const r=bw(n,ak);const s=\"mergeTableCells\";this._fillDropdownWithListOptions(r,i);r.buttonView.set({label:t,icon:e,tooltip:true,isEnabled:true});this.listenTo(r.buttonView,\"execute\",()=>{o.execute(s);o.editing.view.focus()});this.listenTo(r,\"execute\",t=>{o.execute(t.source.commandName);o.editing.view.focus()});return r}_fillDropdownWithListOptions(t,e){const i=this.editor;const n=[];const o=new xs;for(const t of e){uM(t,i,n,o)}_w(t,o,i.ui.componentFactory);return n}}function uM(t,e,i,n){const o=t.model=new rk(t.model);const{commandName:r,bindIsOn:s}=t.model;if(t.type===\"button\"||t.type===\"switchbutton\"){const t=e.commands.get(r);i.push(t);o.set({commandName:r});o.bind(\"isEnabled\").to(t);if(s){o.bind(\"isOn\").to(t,\"value\")}}o.set({withText:true});n.add(t)}class hM extends Ku{constructor(t){super(t);this.domEventType=[\"mousemove\",\"mouseup\",\"mouseleave\"]}onDomEvent(t){this.fire(t.type,t)}}function fM(t,e,i,n){const{startRow:o,startColumn:r,endRow:s,endColumn:a}=e;const l=i.createElement(\"table\");const c=s-o+1;for(let t=0;t<c;t++){i.insertElement(\"tableRow\",l,\"end\")}const d=[...new vE(t,{startRow:o,endRow:s,includeSpanned:true})];for(const{row:t,column:e,cell:c,isSpanned:u}of d){if(e<r||e>a){continue}const d=t-o;const h=l.getChild(d);if(u){const{row:t,column:e}=n.getCellLocation(c);if(t<o||e<r){hE(i,i.createPositionAt(h,\"end\"))}}else{const n=c._clone(true);i.append(n,h);mM(n,t,e,s,a,i)}}gM(l,t,o,r,i);return l}function mM(t,e,i,n,o,r){const s=parseInt(t.getAttribute(\"colspan\")||1);const a=parseInt(t.getAttribute(\"rowspan\")||1);const l=i+s-1;if(l>o){const e=o-i+1;uE(\"colspan\",e,t,r,1)}const c=e+a-1;if(c>n){const i=n-e+1;uE(\"rowspan\",i,t,r,1)}}function gM(t,e,i,n,o){const r=parseInt(e.getAttribute(\"headingRows\")||0);if(r>0){const e=r-i;uE(\"headingRows\",e,t,o,0)}const s=parseInt(e.getAttribute(\"headingColumns\")||0);if(s>0){const e=s-n;uE(\"headingColumns\",e,t,o,0)}}var pM=i(100);class bM extends Nw{static get pluginName(){return\"TableSelection\"}static get requires(){return[CS]}init(){const t=this.editor;const e=t.model;this.listenTo(e,\"deleteContent\",(t,e)=>this._handleDeleteContent(t,e),{priority:\"high\"});t.editing.view.addObserver(hM);this._defineSelectionConverter();this._enableShiftClickSelection();this._enableMouseDragSelection();this._enablePluginDisabling()}getSelectedTableCells(){const t=this.editor.model.document.selection;const e=TE(t);if(e.length==0){return null}return e}getSelectionAsFragment(){const t=this.getSelectedTableCells();if(!t){return null}return this.editor.model.change(e=>{const i=e.createDocumentFragment();const{first:n,last:o}=ME(t);const{first:r,last:s}=SE(t);const a=dE(\"table\",t[0]);const l={startRow:r,startColumn:n,endRow:s,endColumn:o};const c=fM(a,l,e,this.editor.plugins.get(\"TableUtils\"));e.insert(c,i,0);return i})}setCellSelection(t,e){const i=this._getCellsToSelect(t,e);this.editor.model.change(t=>{t.setSelection(i.cells.map(e=>t.createRangeOn(e)),{backward:i.backward})})}getFocusCell(){const t=this.editor.model.document.selection;const e=[...t.getRanges()].pop();const i=e.getContainedElement();if(i&&i.is(\"tableCell\")){return i}return null}getAnchorCell(){const t=this.editor.model.document.selection;const e=zw(t.getRanges());const i=e.getContainedElement();if(i&&i.is(\"tableCell\")){return i}return null}_defineSelectionConverter(){const t=this.editor;const e=new Set;t.conversion.for(\"editingDowncast\").add(t=>t.on(\"selection\",(t,n,o)=>{const r=o.writer;i(r);const s=this.getSelectedTableCells();if(!s){return}for(const t of s){const i=o.mapper.toViewElement(t);r.addClass(\"ck-editor__editable_selected\",i);e.add(i)}const a=o.mapper.toViewElement(s[s.length-1]);r.setSelection(a,0)},{priority:\"lowest\"}));function i(t){for(const i of e){t.removeClass(\"ck-editor__editable_selected\",i)}e.clear()}}_enableShiftClickSelection(){const t=this.editor;let e=false;this.listenTo(t.editing.view.document,\"mousedown\",(i,n)=>{if(!this.isEnabled){return}if(!n.domEvent.shiftKey){return}const o=this.getAnchorCell()||PE(t.model.document.selection)[0];if(!o){return}const r=this._getModelTableCellFromDomEvent(n);if(r&&wM(o,r)){e=true;this.setCellSelection(o,r);n.preventDefault()}});this.listenTo(t.editing.view.document,\"mouseup\",()=>{e=false});this.listenTo(t.editing.view.document,\"selectionChange\",t=>{if(e){t.stop()}},{priority:\"highest\"})}_enableMouseDragSelection(){const t=this.editor;let e,i;let n=false;let o=false;this.listenTo(t.editing.view.document,\"mousedown\",(t,i)=>{if(!this.isEnabled){return}if(i.domEvent.shiftKey||i.domEvent.ctrlKey||i.domEvent.altKey){return}e=this._getModelTableCellFromDomEvent(i)});this.listenTo(t.editing.view.document,\"mousemove\",(t,r)=>{if(!r.domEvent.buttons){return}if(!e){return}const s=this._getModelTableCellFromDomEvent(r);if(s&&wM(e,s)){i=s;if(!n&&i!=e){n=true}}if(!n){return}o=true;this.setCellSelection(e,i);r.preventDefault()});this.listenTo(t.editing.view.document,\"mouseup\",()=>{n=false;o=false;e=null;i=null});this.listenTo(t.editing.view.document,\"selectionChange\",t=>{if(o){t.stop()}},{priority:\"highest\"})}_enablePluginDisabling(){const t=this.editor;this.on(\"change:isEnabled\",()=>{if(!this.isEnabled){const e=this.getSelectedTableCells();if(!e){return}t.model.change(i=>{const n=i.createPositionAt(e[0],0);const o=t.model.schema.getNearestSelectionRange(n);i.setSelection(o)})}})}_handleDeleteContent(t,e){const[i,n]=e;const o=this.editor.model;const r=!n||n.direction==\"backward\";const s=TE(i);if(!s.length){return}t.stop();o.change(t=>{const e=s[r?s.length-1:0];o.change(t=>{for(const e of s){o.deleteContent(t.createSelection(e,\"in\"))}});const n=o.schema.getNearestSelectionRange(t.createPositionAt(e,0));if(i.is(\"documentSelection\")){t.setSelection(n)}else{i.setTo(n)}})}_getModelTableCellFromDomEvent(t){const e=t.target;const i=this.editor.editing.view.createPositionAt(e,0);const n=this.editor.editing.mapper.toModelPosition(i);const o=n.parent;if(o.is(\"tableCell\")){return o}return dE(\"tableCell\",o)}_getCellsToSelect(t,e){const i=this.editor.plugins.get(\"TableUtils\");const n=i.getCellLocation(t);const o=i.getCellLocation(e);const r=Math.min(n.row,o.row);const s=Math.max(n.row,o.row);const a=Math.min(n.column,o.column);const l=Math.max(n.column,o.column);const c=new Array(s-r+1).fill(null).map(()=>[]);for(const e of new vE(dE(\"table\",t),{startRow:r,endRow:s})){if(e.column>=a&&e.column<=l){c[e.row-r].push(e.cell)}}const d=o.row<n.row;const u=o.column<n.column;if(d){c.reverse()}if(u){c.forEach(t=>t.reverse())}return{cells:c.flat(),backward:d||u}}}function wM(t,e){return t.parent.parent==e.parent.parent}class _M extends Nw{static get pluginName(){return\"TableClipboard\"}static get requires(){return[bM,CS]}init(){const t=this.editor;const e=t.editing.view.document;this.listenTo(e,\"copy\",(t,e)=>this._onCopyCut(t,e));this.listenTo(e,\"cut\",(t,e)=>this._onCopyCut(t,e));this.listenTo(t.model,\"insertContent\",(t,e)=>this._onInsertContent(t,...e),{priority:\"high\"})}_onCopyCut(t,e){const i=this.editor.plugins.get(bM);if(!i.getSelectedTableCells()){return}if(t.name==\"cut\"&&this.editor.isReadOnly){return}e.preventDefault();t.stop();const n=this.editor.data;const o=this.editor.editing.view.document;const r=n.toView(i.getSelectionAsFragment());o.fire(\"clipboardOutput\",{dataTransfer:e.dataTransfer,content:r,method:t.name})}_onInsertContent(t,e,i){if(i&&!i.is(\"documentSelection\")){return}const n=this.editor.model;const o=this.editor.plugins.get(CS);const r=EE(n.document.selection);if(!r.length){return}let s=yM(e);if(!s){return}t.stop();n.change(t=>{const e=ME(r);const i=SE(r);let{first:n,last:a}=e;let{first:l,last:c}=i;const d=o.getRows(s);const u=o.getColumns(s);const h=dE(\"table\",r[0]);const f=r.length===1;if(f){c+=d-1;a+=u-1;vM(h,c+1,a+1,t,o)}if(f||!OE(r,o)){const e={firstRow:l,lastRow:c,firstColumn:n,lastColumn:a};CM(h,e,t)}else{c=EM(h,i,e);a=SM(h,i,e)}const m=c-l+1;const g=a-n+1;const p={startRow:0,startColumn:0,endRow:Math.min(m-1,d-1),endColumn:Math.min(g-1,u-1)};s=fM(s,p,t,o);const b={width:u,height:d};const w={firstColumnOfSelection:n,firstRowOfSelection:l,lastColumnOfSelection:a,lastRowOfSelection:c};kM(s,b,h,w,t)})}}function kM(t,e,i,n,o){const{firstColumnOfSelection:r,lastColumnOfSelection:s,firstRowOfSelection:a,lastRowOfSelection:l}=n;const{width:c,height:d}=e;const u=xM(t,c,d);const h=[...new vE(i,{startRow:a,endRow:l,includeSpanned:true})];const f=[];let m;for(const{row:t,column:e,cell:n,isSpanned:g}of h){if(e===0){m=null}if(e<r||e>s){if(!g){m=n}continue}if(!g){o.remove(n)}const h=t-a;const p=e-r;const b=u[h%d][p%c];if(!b){continue}const w=b._clone(true);mM(w,t,e,l,s,o);let _;if(!m){_=o.createPositionAt(i.getChild(t),0)}else{_=o.createPositionAfter(m)}o.insert(w,_);f.push(w);m=w}o.setSelection(f.map(t=>o.createRangeOn(t)))}function vM(t,e,i,n,o){const r=o.getColumns(t);const s=o.getRows(t);if(i>r){o.insertColumns(t,{batch:n.batch,at:r,columns:i-r})}if(e>s){o.insertRows(t,{batch:n.batch,at:s,rows:e-s})}}function yM(t){if(t.is(\"table\")){return t}if(t.childCount!=1||!t.getChild(0).is(\"table\")){return null}return t.getChild(0)}function xM(t,e,i){const n=new Array(i).fill(null).map(()=>new Array(e).fill(null));for(const{column:e,row:i,cell:o}of new vE(t)){n[i][e]=o}return n}function CM(t,e,i){const{firstRow:n,lastRow:o,firstColumn:r,lastColumn:s}=e;const a={first:n,last:o};const l={first:r,last:s};TM(t,r,a,i);TM(t,s+1,a,i);AM(t,n,l,i);AM(t,o+1,l,i,n)}function AM(t,e,i,n,o=0){if(e<1){return}const r=IE(t,e,o);const s=r.filter(({column:t,colspan:e})=>PM(t,e,i));for(const{cell:t}of s){RE(t,e,n)}}function TM(t,e,i,n){if(e<1){return}const o=LE(t,e);const r=o.filter(({row:t,rowspan:e})=>PM(t,e,i));for(const{cell:t,column:i}of r){NE(t,i,e,n)}}function PM(t,e,i){const n=t+e-1;const{first:o,last:r}=i;const s=t>=o&&t<=r;const a=t<o&&n>=o;return s||a}function EM(t,e,i){const n=new vE(t,{startRow:e.last,endRow:e.last});const o=Array.from(n).filter(({column:t})=>i.first<=t&&t<=i.last);const r=o.every(({rowspan:t})=>t===1);if(r){return e.last}const s=o[0].rowspan-1;return e.last+s}function SM(t,e,i){const n=Array.from(new vE(t,{startRow:e.first,endRow:e.last,column:i.last}));const o=n.every(({colspan:t})=>t===1);if(o){return i.last}const r=n[0].colspan-1;return i.last+r}class MM extends Nw{static get pluginName(){return\"TableNavigation\"}static get requires(){return[bM]}init(){const t=this.editor.editing.view;const e=t.document;this.editor.keystrokes.set(\"Tab\",(...t)=>this._handleTabOnSelectedTable(...t),{priority:\"low\"});this.editor.keystrokes.set(\"Tab\",this._getTabHandler(true),{priority:\"low\"});this.editor.keystrokes.set(\"Shift+Tab\",this._getTabHandler(false),{priority:\"low\"});this.listenTo(e,\"keydown\",(...t)=>this._onKeydown(...t),{priority:os.get(\"high\")+1})}_handleTabOnSelectedTable(t,e){const i=this.editor;const n=i.model.document.selection;if(!n.isCollapsed&&n.rangeCount===1&&n.getFirstRange().isFlat){const t=n.getSelectedElement();if(!t||!t.is(\"table\")){return}e();i.model.change(e=>{e.setSelection(e.createRangeIn(t.getChild(0).getChild(0)))})}}_getTabHandler(t){const e=this.editor;return(i,n)=>{const o=e.model.document.selection;const r=PE(o)[0];if(!r){return}n();const s=r.parent;const a=s.parent;const l=a.getChildIndex(s);const c=s.getChildIndex(r);const d=c===0;if(!t&&d&&l===0){return}const u=c===s.childCount-1;const h=l===a.childCount-1;if(t&&h&&u){e.execute(\"insertTableRowBelow\");if(l===a.childCount-1){return}}let f;if(t&&u){const t=a.getChild(l+1);f=t.getChild(0)}else if(!t&&d){const t=a.getChild(l-1);f=t.getChild(t.childCount-1)}else{f=s.getChild(c+(t?1:-1))}e.model.change(t=>{t.setSelection(t.createRangeIn(f))})}}_onKeydown(t,e){const i=e.keyCode;if(!OM(i)){return}const n=IM(i,this.editor.locale.contentLanguageDirection);const o=this._handleArrowKeys(n,e.shiftKey);if(o){e.preventDefault();e.stopPropagation();t.stop()}}_handleArrowKeys(t,e){const i=this.editor.model;const n=i.document.selection;const o=[\"right\",\"down\"].includes(t);const r=TE(n);if(r.length){let i;if(e){i=this.editor.plugins.get(\"TableSelection\").getFocusCell()}else{i=o?r[r.length-1]:r[0]}this._navigateFromCellInDirection(i,t,e);return true}const s=dE(\"tableCell\",n.focus);if(!s){return false}const a=i.createRangeIn(s);if(this._isSelectionAtCellEdge(n,o)){this._navigateFromCellInDirection(s,t,e);return true}const l=n.getSelectedElement();if(l&&i.schema.isObject(l)){return false}if(this._isObjectElementNextToSelection(n,o)){return false}const c=this._findTextRangeFromSelection(a,n,o);if(!c){this._navigateFromCellInDirection(s,t,e);return true}if([\"left\",\"right\"].includes(t)){return false}if(this._isSingleLineRange(c,o)){i.change(t=>{const r=o?a.end:a.start;if(e){const e=i.createSelection(n.anchor);e.setFocus(r);t.setSelection(e)}else{t.setSelection(r)}});return true}}_isSelectionAtCellEdge(t,e){const i=this.editor.model;const n=this.editor.model.schema;const o=e?t.getLastPosition():t.getFirstPosition();if(!n.getLimitElement(o).is(\"tableCell\")){return false}const r=i.createSelection(o);i.modifySelection(r,{direction:e?\"forward\":\"backward\"});return o.isEqual(r.focus)}_isObjectElementNextToSelection(t,e){const i=this.editor.model;const n=i.schema;const o=i.createSelection(t);i.modifySelection(o,{direction:e?\"forward\":\"backward\"});const r=e?o.focus.nodeBefore:o.focus.nodeAfter;return r&&n.isObject(r)}_findTextRangeFromSelection(t,e,i){const n=this.editor.model;if(i){const i=e.getLastPosition();const o=this._getNearestVisibleTextPosition(t,\"backward\");if(o&&i.isBefore(o)){return n.createRange(i,o)}return null}else{const i=e.getFirstPosition();const o=this._getNearestVisibleTextPosition(t,\"forward\");if(o&&i.isAfter(o)){return n.createRange(o,i)}return null}}_getNearestVisibleTextPosition(t,e){const i=this.editor.model.schema;const n=this.editor.editing.mapper;for(const{nextPosition:o,item:r}of t.getWalker({direction:e})){if(i.checkChild(o,\"$text\")){const t=n.toViewElement(r);if(t&&!t.hasClass(\"ck-hidden\")){return o}}}}_isSingleLineRange(t,e){const i=this.editor.model;const n=this.editor.editing;const o=n.view.domConverter;if(e){const e=i.createSelection(t.start);i.modifySelection(e);if(!e.focus.isAtEnd&&!t.start.isEqual(e.focus)){t=i.createRange(e.focus,t.end)}}const r=n.mapper.toViewRange(t);const s=o.viewRangeToDom(r);const a=vh.getDomRangeRects(s);let l;for(const t of a){if(l===undefined){l=Math.round(t.bottom);continue}if(Math.round(t.top)>=l){return false}l=Math.max(l,Math.round(t.bottom))}return true}_navigateFromCellInDirection(t,e,i=false){const n=this.editor.model;const o=dE(\"table\",t);const r=[...new vE(o,{includeSpanned:true})];const{row:s,column:a}=r[r.length-1];const l=r.find(({cell:e})=>e==t);let{row:c,column:d}=l;switch(e){case\"left\":d--;break;case\"up\":c--;break;case\"right\":d+=l.colspan;break;case\"down\":c+=l.rowspan;break}const u=c<0||c>s;const h=d<0&&c<=0;const f=d>a&&c>=s;if(u||h||f){n.change(t=>{t.setSelection(t.createRangeOn(o))});return}if(d<0){d=i?0:a;c--}else if(d>a){d=i?a:0;c++}const m=r.find(t=>t.row==c&&t.column==d).cell;const g=[\"right\",\"down\"].includes(e);if(i){const e=this.editor.plugins.get(\"TableSelection\");const i=e.getAnchorCell()||t;e.setCellSelection(i,m)}else{const t=n.createPositionAt(m,g?0:\"end\");n.change(e=>{e.setSelection(t)})}}}function OM(t){return t==Lc.arrowright||t==Lc.arrowleft||t==Lc.arrowup||t==Lc.arrowdown}function IM(t,e){const i=e===\"ltr\";switch(t){case Lc.arrowleft:return i?\"left\":\"right\";case Lc.arrowright:return i?\"right\":\"left\";case Lc.arrowup:return\"up\";case Lc.arrowdown:return\"down\"}}var RM=i(102);class LM extends Nw{static get requires(){return[iM,dM,bM,_M,MM,ET]}static get pluginName(){return\"Table\"}}var NM=i(104);class BM extends _b{constructor(t,e){super(t);const i=this.bindTemplate;this.set(\"value\",\"\");this.set(\"id\");this.set(\"isReadOnly\",false);this.set(\"hasError\",false);this.set(\"ariaDescribedById\");this.options=e;this._dropdownView=this._createDropdownView(t);this._inputView=this._createInputTextView(t);this._stillTyping=false;this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-input-color\",i.if(\"hasError\",\"ck-error\")],id:i.to(\"id\"),\"aria-invalid\":i.if(\"hasError\",true),\"aria-describedby\":i.to(\"ariaDescribedById\")},children:[this._inputView,this._dropdownView]});this.on(\"change:value\",(t,e,i)=>this._setInputValue(i))}focus(){this._inputView.focus()}_createDropdownView(){const t=this.locale;const e=t.t;const i=this.bindTemplate;const n=this._createColorGrid(t);const o=bw(t);const r=new _b;const s=this._createRemoveColorButton(t);r.setTemplate({tag:\"span\",attributes:{class:[\"ck\",\"ck-input-color__button__preview\"],style:{backgroundColor:i.to(\"value\")}},children:[{tag:\"span\",attributes:{class:[\"ck\",\"ck-input-color__button__preview__no-color-indicator\",i.if(\"value\",\"ck-hidden\",t=>t!=\"\")]}}]});o.buttonView.extendTemplate({attributes:{class:\"ck-input-color__button\"}});o.buttonView.children.add(r);o.buttonView.tooltip=e(\"Color picker\");o.panelPosition=t.uiLanguageDirection===\"rtl\"?\"se\":\"sw\";o.panelView.children.add(s);o.panelView.children.add(n);o.bind(\"isEnabled\").to(this,\"isReadOnly\",t=>!t);return o}_createInputTextView(){const t=this.locale;const e=new $A(t);e.extendTemplate({on:{blur:e.bindTemplate.to(\"blur\")}});e.value=this.value;e.bind(\"isReadOnly\").to(this);e.bind(\"hasError\").to(this);e.on(\"input\",()=>{const t=e.element.value;const i=this.options.colorDefinitions.find(e=>t===e.label);this._stillTyping=true;this.value=i&&i.color||t});e.on(\"blur\",()=>{this._stillTyping=false;this._setInputValue(e.element.value)});e.delegate(\"input\").to(this);return e}_createRemoveColorButton(){const t=this.locale;const e=t.t;const i=new rw(t);i.class=\"ck-input-color__remove-color\";i.withText=true;i.icon=Av;i.label=e(\"Remove color\");i.on(\"execute\",()=>{this.value=\"\";this._dropdownView.isOpen=false;this.fire(\"input\")});return i}_createColorGrid(t){const e=new xv(t,{colorDefinitions:this.options.colorDefinitions,columns:this.options.columns});e.on(\"execute\",(t,e)=>{this.value=e.value;this._dropdownView.isOpen=false;this.fire(\"input\")});e.bind(\"selectedColor\").to(this,\"value\");return e}_setInputValue(t){if(!this._stillTyping){const e=VM(t);const i=this.options.colorDefinitions.find(t=>e===VM(t.color));if(i){this._inputView.value=i.label}else{this._inputView.value=t||\"\"}}}}function VM(t){return t.replace(/([(,])\\s+/g,\"$1\").replace(/^\\s+|\\s+(?=[),\\s]|$)/g,\"\").replace(/,|\\s/g,\" \")}const DM=Zy.defaultPositions;const zM=[DM.northArrowSouth,DM.northArrowSouthWest,DM.northArrowSouthEast,DM.southArrowNorth,DM.southArrowNorthWest,DM.southArrowNorthEast];const FM=[...zM,mx];const jM=t=>t===\"\";function HM(t,e){const i=t.plugins.get(\"ContextualBalloon\");if(AE(t.editing.view.document.selection)){let n;if(e===\"cell\"){n=qM(t)}else{n=WM(t)}i.updatePosition(n)}}function WM(t){const e=t.model.document.selection.getFirstPosition();const i=dE(\"table\",e);const n=t.editing.mapper.toViewElement(i);return{target:t.editing.view.domConverter.viewToDom(n),positions:FM}}function qM(t){const e=t.editing.mapper;const i=t.editing.view.domConverter;const n=t.model.document.selection;if(n.rangeCount>1){return{target:()=>oO(n.getRanges(),t=>{const n=nO(t.start);const o=e.toViewElement(n);return new vh(i.viewToDom(o))}),positions:zM}}const o=nO(n.getFirstPosition());const r=e.toViewElement(o);return{target:i.viewToDom(r),positions:zM}}function $M(t){return{none:t(\"None\"),solid:t(\"Solid\"),dotted:t(\"Dotted\"),dashed:t(\"Dashed\"),double:t(\"Double\"),groove:t(\"Groove\"),ridge:t(\"Ridge\"),inset:t(\"Inset\"),outset:t(\"Outset\")}}function UM(t){return t('The color is invalid. Try \"#FF0000\" or \"rgb(255,0,0)\" or \"red\".')}function GM(t){return t('The value is invalid. Try \"10px\" or \"2em\" or simply \"2\".')}function JM(t){t=t.trim();return jM(t)||qx(t)}function KM(t){t=t.trim();return jM(t)||eO(t)||Jx(t)||Xx(t)}function XM(t){t=t.trim();return jM(t)||eO(t)||Jx(t)}function YM(t){const e=new xs;const i=$M(t.t);for(const n in i){const o={type:\"button\",model:new rk({_borderStyleValue:n===\"none\"?\"\":n,label:i[n],withText:true})};if(n===\"none\"){o.model.bind(\"isOn\").to(t,\"borderStyle\",t=>!t)}else{o.model.bind(\"isOn\").to(t,\"borderStyle\",t=>t===n)}e.add(o)}return e}function QM({view:t,icons:e,toolbar:i,labels:n,propertyName:o,nameToValue:r}){for(const s in n){const a=new rw(t.locale);a.set({label:n[s],icon:e[s],tooltip:n[s]});a.bind(\"isOn\").to(t,o,t=>t===r(s));a.on(\"execute\",()=>{t[o]=r(s)});i.items.add(a)}}const ZM=[{color:\"hsl(0, 0%, 0%)\",label:\"Black\"},{color:\"hsl(0, 0%, 30%)\",label:\"Dim grey\"},{color:\"hsl(0, 0%, 60%)\",label:\"Grey\"},{color:\"hsl(0, 0%, 90%)\",label:\"Light grey\"},{color:\"hsl(0, 0%, 100%)\",label:\"White\",hasBorder:true},{color:\"hsl(0, 75%, 60%)\",label:\"Red\"},{color:\"hsl(30, 75%, 60%)\",label:\"Orange\"},{color:\"hsl(60, 75%, 60%)\",label:\"Yellow\"},{color:\"hsl(90, 75%, 60%)\",label:\"Light green\"},{color:\"hsl(120, 75%, 60%)\",label:\"Green\"},{color:\"hsl(150, 75%, 60%)\",label:\"Aquamarine\"},{color:\"hsl(180, 75%, 60%)\",label:\"Turquoise\"},{color:\"hsl(210, 75%, 60%)\",label:\"Light blue\"},{color:\"hsl(240, 75%, 60%)\",label:\"Blue\"},{color:\"hsl(270, 75%, 60%)\",label:\"Purple\"}];function tO(t){return(e,i,n)=>{const o=new BM(e.locale,{colorDefinitions:iO(t.colorConfig),columns:t.columns});o.set({id:i,ariaDescribedById:n});o.bind(\"isReadOnly\").to(e,\"isEnabled\",t=>!t);o.bind(\"errorText\").to(e);o.on(\"input\",()=>{e.errorText=null});return o}}function eO(t){const e=parseFloat(t);return!Number.isNaN(e)&&t===String(e)}function iO(t){return t.map(t=>({color:t.model,label:t.label,options:{hasBorder:t.hasBorder}}))}function nO(t){const e=t.nodeAfter&&t.nodeAfter.is(\"tableCell\");return e?t.nodeAfter:dE(\"tableCell\",t)}function oO(t,e){const i={left:Number.POSITIVE_INFINITY,top:Number.POSITIVE_INFINITY,right:Number.NEGATIVE_INFINITY,bottom:Number.NEGATIVE_INFINITY};for(const n of t){const t=e(n);i.left=Math.min(i.left,t.left);i.top=Math.min(i.top,t.top);i.right=Math.max(i.right,t.right);i.bottom=Math.max(i.bottom,t.bottom)}i.width=i.right-i.left;i.height=i.bottom-i.top;return new vh(i)}var rO=i(106);class sO extends _b{constructor(t,e={}){super(t);const i=this.bindTemplate;this.set(\"class\",e.class||null);this.children=this.createCollection();if(e.children){e.children.forEach(t=>this.children.add(t))}this.set(\"_role\",null);this.set(\"_ariaLabelledBy\",null);if(e.labelView){this.set({_role:\"group\",_ariaLabelledBy:e.labelView.id})}this.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-form__row\",i.to(\"class\")],role:i.to(\"_role\"),\"aria-labelledby\":i.to(\"_ariaLabelledBy\")},children:this.children})}}var aO='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M10.261 7.062l2.88 1.663a.75.75 0 0 1-.75 1.3L10.5 8.933v7.317a.75.75 0 1 1-1.5 0V8.932l-1.89 1.093a.75.75 0 0 1-.75-1.3l2.879-1.663a.752.752 0 0 1 .511-.187.752.752 0 0 1 .511.187zM15.25 4a.75.75 0 1 1 0 1.5H4.75a.75.75 0 0 1 0-1.5h10.5z\"/></svg>';var lO='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M9.75 11.875a.752.752 0 0 1 .508.184l2.883 1.666a.75.75 0 0 1-.659 1.344l-.091-.044-1.892-1.093.001 4.318a.75.75 0 1 1-1.5 0v-4.317l-1.89 1.092a.75.75 0 0 1-.75-1.3l2.879-1.663a.752.752 0 0 1 .51-.187zM15.25 9a.75.75 0 1 1 0 1.5H4.75a.75.75 0 1 1 0-1.5h10.5zM9.75.375a.75.75 0 0 1 .75.75v4.318l1.89-1.093.092-.045a.75.75 0 0 1 .659 1.344l-2.883 1.667a.752.752 0 0 1-.508.184.752.752 0 0 1-.511-.187L6.359 5.65a.75.75 0 0 1 .75-1.299L9 5.442V1.125a.75.75 0 0 1 .75-.75z\"/></svg>';var cO='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M9.239 13.938l-2.88-1.663a.75.75 0 0 1 .75-1.3L9 12.067V4.75a.75.75 0 1 1 1.5 0v7.318l1.89-1.093a.75.75 0 0 1 .75 1.3l-2.879 1.663a.752.752 0 0 1-.511.187.752.752 0 0 1-.511-.187zM4.25 17a.75.75 0 1 1 0-1.5h10.5a.75.75 0 0 1 0 1.5H4.25z\"/></svg>';var dO=i(13);var uO=i(14);var hO=i(110);const fO={left:Kw,center:Yw,right:Xw,justify:Qw,top:aO,middle:lO,bottom:cO};class mO extends _b{constructor(t,e){super(t);this.set({borderStyle:\"\",borderWidth:\"\",borderColor:\"\",padding:\"\",backgroundColor:\"\",width:\"\",height:\"\",horizontalAlignment:\"\",verticalAlignment:\"\"});this.options=e;const{borderStyleDropdown:i,borderWidthInput:n,borderColorInput:o,borderRowLabel:r}=this._createBorderFields();const{widthInput:s,operatorLabel:a,heightInput:l,dimensionsLabel:c}=this._createDimensionFields();const{horizontalAlignmentToolbar:d,verticalAlignmentToolbar:u,alignmentLabel:h}=this._createAlignmentFields();this.focusTracker=new Pp;this.keystrokes=new mp;this.children=this.createCollection();this.borderStyleDropdown=i;this.borderWidthInput=n;this.borderColorInput=o;this.backgroundInput=this._createBackgroundField();this.paddingInput=this._createPaddingField();this.widthInput=s;this.heightInput=l;this.horizontalAlignmentToolbar=d;this.verticalAlignmentToolbar=u;const{saveButtonView:f,cancelButtonView:m}=this._createActionButtons();this.saveButtonView=f;this.cancelButtonView=m;this._focusables=new Wp;this._focusCycler=new Bb({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"shift + tab\",focusNext:\"tab\"}});this.children.add(new SP(t,{label:this.t(\"Cell properties\")}));this.children.add(new sO(t,{labelView:r,children:[r,i,o,n],class:\"ck-table-form__border-row\"}));this.children.add(new sO(t,{children:[this.backgroundInput]}));this.children.add(new sO(t,{children:[new sO(t,{labelView:c,children:[c,s,a,l],class:\"ck-table-form__dimensions-row\"}),new sO(t,{children:[this.paddingInput],class:\"ck-table-cell-properties-form__padding-row\"})]}));this.children.add(new sO(t,{labelView:h,children:[h,d,u],class:\"ck-table-cell-properties-form__alignment-row\"}));this.children.add(new sO(t,{children:[this.saveButtonView,this.cancelButtonView],class:\"ck-table-form__action-row\"}));this.setTemplate({tag:\"form\",attributes:{class:[\"ck\",\"ck-form\",\"ck-table-form\",\"ck-table-cell-properties-form\"],tabindex:\"-1\"},children:this.children})}render(){super.render();JA({view:this});[this.borderStyleDropdown,this.borderColorInput,this.borderWidthInput,this.backgroundInput,this.widthInput,this.heightInput,this.paddingInput,this.horizontalAlignmentToolbar,this.verticalAlignmentToolbar,this.saveButtonView,this.cancelButtonView].forEach(t=>{this._focusables.add(t);this.focusTracker.add(t.element)});this.keystrokes.listenTo(this.element)}focus(){this._focusCycler.focusFirst()}_createBorderFields(){const t=tO({colorConfig:this.options.borderColors,columns:5});const e=this.locale;const i=this.t;const n=new Eb(e);n.text=i(\"Border\");const o=$M(i);const r=new WA(e,GA);r.set({label:i(\"Style\"),class:\"ck-table-form__border-style\"});r.fieldView.buttonView.set({isOn:false,withText:true,tooltip:i(\"Style\")});r.fieldView.buttonView.bind(\"label\").to(this,\"borderStyle\",t=>o[t?t:\"none\"]);r.fieldView.on(\"execute\",t=>{this.borderStyle=t.source._borderStyleValue});_w(r.fieldView,YM(this));const s=new WA(e,UA);s.set({label:i(\"Width\"),class:\"ck-table-form__border-width\"});s.fieldView.bind(\"value\").to(this,\"borderWidth\");s.bind(\"isEnabled\").to(this,\"borderStyle\",gO);s.fieldView.on(\"input\",()=>{this.borderWidth=s.fieldView.element.value});const a=new WA(e,t);a.set({label:i(\"Color\"),class:\"ck-table-form__border-color\"});a.fieldView.bind(\"value\").to(this,\"borderColor\");a.bind(\"isEnabled\").to(this,\"borderStyle\",gO);a.fieldView.on(\"input\",()=>{this.borderColor=a.fieldView.value});this.on(\"change:borderStyle\",(t,e,i)=>{if(!gO(i)){this.borderColor=\"\";this.borderWidth=\"\"}});return{borderRowLabel:n,borderStyleDropdown:r,borderColorInput:a,borderWidthInput:s}}_createBackgroundField(){const t=this.locale;const e=this.t;const i=tO({colorConfig:this.options.backgroundColors,columns:5});const n=new WA(t,i);n.set({label:e(\"Background\"),class:\"ck-table-cell-properties-form__background\"});n.fieldView.bind(\"value\").to(this,\"backgroundColor\");n.fieldView.on(\"input\",()=>{this.backgroundColor=n.fieldView.value});return n}_createDimensionFields(){const t=this.locale;const e=this.t;const i=new Eb(t);i.text=e(\"Dimensions\");const n=new WA(t,UA);n.set({label:e(\"Width\"),class:\"ck-table-form__dimensions-row__width\"});n.fieldView.bind(\"value\").to(this,\"width\");n.fieldView.on(\"input\",()=>{this.width=n.fieldView.element.value});const o=new _b(t);o.setTemplate({tag:\"span\",attributes:{class:[\"ck-table-form__dimension-operator\"]},children:[{text:\"×\"}]});const r=new WA(t,UA);r.set({label:e(\"Height\"),class:\"ck-table-form__dimensions-row__height\"});r.fieldView.bind(\"value\").to(this,\"height\");r.fieldView.on(\"input\",()=>{this.height=r.fieldView.element.value});return{dimensionsLabel:i,widthInput:n,operatorLabel:o,heightInput:r}}_createPaddingField(){const t=this.locale;const e=this.t;const i=new WA(t,UA);i.set({label:e(\"Padding\"),class:\"ck-table-cell-properties-form__padding\"});i.fieldView.bind(\"value\").to(this,\"padding\");i.fieldView.on(\"input\",()=>{this.padding=i.fieldView.element.value});return i}_createAlignmentFields(){const t=this.locale;const e=this.t;const i=new Eb(t);i.text=e(\"Table cell text alignment\");const n=new Tw(t);const o=this.locale.contentLanguageDirection===\"rtl\";n.set({isCompact:true,ariaLabel:e(\"Horizontal text alignment toolbar\")});QM({view:this,icons:fO,toolbar:n,labels:this._horizontalAlignmentLabels,propertyName:\"horizontalAlignment\",nameToValue:t=>t===(o?\"right\":\"left\")?\"\":t});const r=new Tw(t);r.set({isCompact:true,ariaLabel:e(\"Vertical text alignment toolbar\")});QM({view:this,icons:fO,toolbar:r,labels:this._verticalAlignmentLabels,propertyName:\"verticalAlignment\",nameToValue:t=>t===\"middle\"?\"\":t});return{horizontalAlignmentToolbar:n,verticalAlignmentToolbar:r,alignmentLabel:i}}_createActionButtons(){const t=this.locale;const e=this.t;const i=new rw(t);const n=new rw(t);const o=[this.borderWidthInput,this.borderColorInput,this.backgroundInput,this.paddingInput];i.set({label:e(\"Save\"),icon:KA,class:\"ck-button-save\",type:\"submit\",withText:true});i.bind(\"isEnabled\").toMany(o,\"errorText\",(...t)=>t.every(t=>!t));n.set({label:e(\"Cancel\"),icon:XA,class:\"ck-button-cancel\",type:\"cancel\",withText:true});n.delegate(\"execute\").to(this,\"cancel\");return{saveButtonView:i,cancelButtonView:n}}get _horizontalAlignmentLabels(){const t=this.locale;const e=this.t;const i=e(\"Align cell text to the left\");const n=e(\"Align cell text to the center\");const o=e(\"Align cell text to the right\");const r=e(\"Justify cell text\");if(t.uiLanguageDirection===\"rtl\"){return{right:o,center:n,left:i,justify:r}}else{return{left:i,center:n,right:o,justify:r}}}get _verticalAlignmentLabels(){const t=this.t;return{top:t(\"Align cell text to the top\"),middle:t(\"Align cell text to the middle\"),bottom:t(\"Align cell text to the bottom\")}}}function gO(t){return!!t}var pO='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M11.105 18l-.17 1H2.5A1.5 1.5 0 0 1 1 17.5v-15A1.5 1.5 0 0 1 2.5 1h15A1.5 1.5 0 0 1 19 2.5v9.975l-.85-.124-.15-.302V8h-5v4h.021l-.172.351-1.916.28-.151.027c-.287.063-.54.182-.755.341L8 13v5h3.105zM2 12h5V8H2v4zm10-4H8v4h4V8zM2 2v5h5V2H2zm0 16h5v-5H2v5zM13 7h5V2h-5v5zM8 2v5h4V2H8z\" opacity=\".6\"/><path d=\"M15.5 11.5l1.323 2.68 2.957.43-2.14 2.085.505 2.946L15.5 18.25l-2.645 1.39.505-2.945-2.14-2.086 2.957-.43L15.5 11.5zM13 6a1 1 0 0 1 1 1v3.172a2.047 2.047 0 0 0-.293.443l-.858 1.736-1.916.28-.151.027A1.976 1.976 0 0 0 9.315 14H7a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h6zm-1 2H8v4h4V8z\"/></svg>';const bO=500;const wO={borderStyle:\"tableCellBorderStyle\",borderColor:\"tableCellBorderColor\",borderWidth:\"tableCellBorderWidth\",width:\"tableCellWidth\",height:\"tableCellHeight\",padding:\"tableCellPadding\",backgroundColor:\"tableCellBackgroundColor\",horizontalAlignment:\"tableCellHorizontalAlignment\",verticalAlignment:\"tableCellVerticalAlignment\"};class _O extends Nw{static get requires(){return[zA]}static get pluginName(){return\"TableCellPropertiesUI\"}constructor(t){super(t);t.config.define(\"table.tableCellProperties\",{borderColors:ZM,backgroundColors:ZM})}init(){const t=this.editor;const e=t.t;this._balloon=t.plugins.get(zA);this.view=this._createPropertiesView();this._undoStepBatch=null;t.ui.componentFactory.add(\"tableCellProperties\",i=>{const n=new rw(i);n.set({label:e(\"Cell properties\"),icon:pO,tooltip:true});this.listenTo(n,\"execute\",()=>this._showView());const o=Object.values(wO).map(e=>t.commands.get(e));n.bind(\"isEnabled\").toMany(o,\"isEnabled\",(...t)=>t.some(t=>t));return n})}destroy(){super.destroy();this.view.destroy()}_createPropertiesView(){const t=this.editor;const e=t.editing.view.document;const i=t.config.get(\"table.tableCellProperties\");const n=Fv(i.borderColors);const o=zv(t.locale,n);const r=Fv(i.backgroundColors);const s=zv(t.locale,r);const a=new mO(t.locale,{borderColors:o,backgroundColors:s});const l=t.t;a.render();this.listenTo(a,\"submit\",()=>{this._hideView()});this.listenTo(a,\"cancel\",()=>{if(this._undoStepBatch.operations.length){t.execute(\"undo\",this._undoStepBatch)}this._hideView()});a.keystrokes.set(\"Esc\",(t,e)=>{this._hideView();e()});this.listenTo(t.ui,\"update\",()=>{if(!AE(e.selection)){this._hideView()}else if(this._isViewVisible){HM(t,\"cell\")}});mw({emitter:a,activator:()=>this._isViewInBalloon,contextElements:[this._balloon.view.element],callback:()=>this._hideView()});const c=UM(l);const d=GM(l);a.on(\"change:borderStyle\",this._getPropertyChangeCallback(\"tableCellBorderStyle\"));a.on(\"change:borderColor\",this._getValidatedPropertyChangeCallback({viewField:a.borderColorInput,commandName:\"tableCellBorderColor\",errorText:c,validator:JM}));a.on(\"change:borderWidth\",this._getValidatedPropertyChangeCallback({viewField:a.borderWidthInput,commandName:\"tableCellBorderWidth\",errorText:d,validator:XM}));a.on(\"change:padding\",this._getValidatedPropertyChangeCallback({viewField:a.paddingInput,commandName:\"tableCellPadding\",errorText:d,validator:KM}));a.on(\"change:width\",this._getValidatedPropertyChangeCallback({viewField:a.widthInput,commandName:\"tableCellWidth\",errorText:d,validator:KM}));a.on(\"change:height\",this._getValidatedPropertyChangeCallback({viewField:a.heightInput,commandName:\"tableCellHeight\",errorText:d,validator:KM}));a.on(\"change:backgroundColor\",this._getValidatedPropertyChangeCallback({viewField:a.backgroundInput,commandName:\"tableCellBackgroundColor\",errorText:c,validator:JM}));a.on(\"change:horizontalAlignment\",this._getPropertyChangeCallback(\"tableCellHorizontalAlignment\"));a.on(\"change:verticalAlignment\",this._getPropertyChangeCallback(\"tableCellVerticalAlignment\"));return a}_fillViewFormFromCommandValues(){const t=this.editor.commands;Object.entries(wO).map(([e,i])=>[e,t.get(i).value||\"\"]).forEach(([t,e])=>this.view.set(t,e))}_showView(){const t=this.editor;this._balloon.add({view:this.view,position:qM(t)});this._undoStepBatch=t.model.createBatch();this._fillViewFormFromCommandValues();this.view.focus()}_hideView(){if(!this._isViewInBalloon){return}const t=this.editor;this.stopListening(t.ui,\"update\");this.view.saveButtonView.focus();this._balloon.remove(this.view);this.editor.editing.view.focus()}get _isViewVisible(){return this._balloon.visibleView===this.view}get _isViewInBalloon(){return this._balloon.hasView(this.view)}_getPropertyChangeCallback(t){return(e,i,n)=>{this.editor.execute(t,{value:n,batch:this._undoStepBatch})}}_getValidatedPropertyChangeCallback({commandName:t,viewField:e,validator:i,errorText:n}){const o=uh(()=>{e.errorText=n},bO);return(n,r,s)=>{o.cancel();if(i(s)){this.editor.execute(t,{value:s,batch:this._undoStepBatch});e.errorText=null}else{o()}}}}function kO(t){t.setNormalizer(\"border\",vO);t.setNormalizer(\"border-top\",yO(\"top\"));t.setNormalizer(\"border-right\",yO(\"right\"));t.setNormalizer(\"border-bottom\",yO(\"bottom\"));t.setNormalizer(\"border-left\",yO(\"left\"));t.setNormalizer(\"border-color\",xO(\"color\"));t.setNormalizer(\"border-width\",xO(\"width\"));t.setNormalizer(\"border-style\",xO(\"style\"));t.setNormalizer(\"border-top-color\",AO(\"color\",\"top\"));t.setNormalizer(\"border-top-style\",AO(\"style\",\"top\"));t.setNormalizer(\"border-top-width\",AO(\"width\",\"top\"));t.setNormalizer(\"border-right-color\",AO(\"color\",\"right\"));t.setNormalizer(\"border-right-style\",AO(\"style\",\"right\"));t.setNormalizer(\"border-right-width\",AO(\"width\",\"right\"));t.setNormalizer(\"border-bottom-color\",AO(\"color\",\"bottom\"));t.setNormalizer(\"border-bottom-style\",AO(\"style\",\"bottom\"));t.setNormalizer(\"border-bottom-width\",AO(\"width\",\"bottom\"));t.setNormalizer(\"border-left-color\",AO(\"color\",\"left\"));t.setNormalizer(\"border-left-style\",AO(\"style\",\"left\"));t.setNormalizer(\"border-left-width\",AO(\"width\",\"left\"));t.setExtractor(\"border-top\",TO(\"top\"));t.setExtractor(\"border-right\",TO(\"right\"));t.setExtractor(\"border-bottom\",TO(\"bottom\"));t.setExtractor(\"border-left\",TO(\"left\"));t.setExtractor(\"border-top-color\",\"border.color.top\");t.setExtractor(\"border-right-color\",\"border.color.right\");t.setExtractor(\"border-bottom-color\",\"border.color.bottom\");t.setExtractor(\"border-left-color\",\"border.color.left\");t.setExtractor(\"border-top-width\",\"border.width.top\");t.setExtractor(\"border-right-width\",\"border.width.right\");t.setExtractor(\"border-bottom-width\",\"border.width.bottom\");t.setExtractor(\"border-left-width\",\"border.width.left\");t.setExtractor(\"border-top-style\",\"border.style.top\");t.setExtractor(\"border-right-style\",\"border.style.right\");t.setExtractor(\"border-bottom-style\",\"border.style.bottom\");t.setExtractor(\"border-left-style\",\"border.style.left\");t.setReducer(\"border-color\",sC(\"border-color\"));t.setReducer(\"border-style\",sC(\"border-style\"));t.setReducer(\"border-width\",sC(\"border-width\"));t.setReducer(\"border-top\",MO(\"top\"));t.setReducer(\"border-right\",MO(\"right\"));t.setReducer(\"border-bottom\",MO(\"bottom\"));t.setReducer(\"border-left\",MO(\"left\"));t.setReducer(\"border\",SO);t.setStyleRelation(\"border\",[\"border-color\",\"border-style\",\"border-width\",\"border-top\",\"border-right\",\"border-bottom\",\"border-left\",\"border-top-color\",\"border-right-color\",\"border-bottom-color\",\"border-left-color\",\"border-top-style\",\"border-right-style\",\"border-bottom-style\",\"border-left-style\",\"border-top-width\",\"border-right-width\",\"border-bottom-width\",\"border-left-width\"]);t.setStyleRelation(\"border-color\",[\"border-top-color\",\"border-right-color\",\"border-bottom-color\",\"border-left-color\"]);t.setStyleRelation(\"border-style\",[\"border-top-style\",\"border-right-style\",\"border-bottom-style\",\"border-left-style\"]);t.setStyleRelation(\"border-width\",[\"border-top-width\",\"border-right-width\",\"border-bottom-width\",\"border-left-width\"]);t.setStyleRelation(\"border-top\",[\"border-top-color\",\"border-top-style\",\"border-top-width\"]);t.setStyleRelation(\"border-right\",[\"border-right-color\",\"border-right-style\",\"border-right-width\"]);t.setStyleRelation(\"border-bottom\",[\"border-bottom-color\",\"border-bottom-style\",\"border-bottom-width\"]);t.setStyleRelation(\"border-left\",[\"border-left-color\",\"border-left-style\",\"border-left-width\"])}function vO(t){const{color:e,style:i,width:n}=EO(t);return{path:\"border\",value:{color:rC(e),style:rC(i),width:rC(n)}}}function yO(t){return e=>{const{color:i,style:n,width:o}=EO(e);const r={};if(i!==undefined){r.color={[t]:i}}if(n!==undefined){r.style={[t]:n}}if(o!==undefined){r.width={[t]:o}}return{path:\"border\",value:r}}}function xO(t){return e=>({path:\"border\",value:CO(e,t)})}function CO(t,e){return{[e]:rC(t)}}function AO(t,e){return i=>({path:\"border\",value:{[t]:{[e]:i}}})}function TO(t){return(e,i)=>{if(i.border){return PO(i.border,t)}}}function PO(t,e){const i={};if(t.width&&t.width[e]){i.width=t.width[e]}if(t.style&&t.style[e]){i.style=t.style[e]}if(t.color&&t.color[e]){i.color=t.color[e]}return i}function EO(t){const e={};const i=cC(t);for(const t of i){if(Jx(t)||/thin|medium|thick/.test(t)){e.width=t}else if(Ux(t)){e.style=t}else{e.color=t}}return e}function SO(t){const e=[];e.push(...OO(PO(t,\"top\"),\"top\"));e.push(...OO(PO(t,\"right\"),\"right\"));e.push(...OO(PO(t,\"bottom\"),\"bottom\"));e.push(...OO(PO(t,\"left\"),\"left\"));return e}function MO(t){return e=>OO(e,t)}function OO(t,e){const i=[];if(t&&t.width!==undefined){i.push(t.width)}if(t&&t.style!==undefined){i.push(t.style)}if(t&&t.color!==undefined){i.push(t.color)}if(i.length){return[[`border-${e}`,i.join(\" \")]]}return[]}function IO(t){t.setNormalizer(\"padding\",lC(\"padding\"));t.setNormalizer(\"padding-top\",t=>({path:\"padding.top\",value:t}));t.setNormalizer(\"padding-right\",t=>({path:\"padding.right\",value:t}));t.setNormalizer(\"padding-bottom\",t=>({path:\"padding.bottom\",value:t}));t.setNormalizer(\"padding-left\",t=>({path:\"padding.left\",value:t}));t.setReducer(\"padding\",sC(\"padding\"));t.setStyleRelation(\"padding\",[\"padding-top\",\"padding-right\",\"padding-bottom\",\"padding-left\"])}function RO(t){t.setNormalizer(\"background\",LO);t.setNormalizer(\"background-color\",t=>({path:\"background.color\",value:t}));t.setReducer(\"background\",t=>{const e=[];e.push([\"background-color\",t.color]);return e})}function LO(t){const e={};const i=cC(t);for(const t of i){if(Qx(t)){e.repeat=e.repeat||[];e.repeat.push(t)}else if(tC(t)){e.position=e.position||[];e.position.push(t)}else if(iC(t)){e.attachment=t}else if(qx(t)){e.color=t}else if(oC(t)){e.image=t}}return{path:\"background\",value:e}}function NO(t,e,i,n){t.for(\"upcast\").attributeToAttribute({view:{styles:{[n]:/[\\s\\S]+/}},model:{name:e,key:i,value:t=>t.getNormalizedStyle(n)}})}function BO(t,e){t.for(\"upcast\").add(t=>t.on(\"element:\"+e,(t,e,i)=>{const n=[\"border-top\",\"border-right\",\"border-bottom\",\"border-left\"].filter(t=>e.viewItem.hasStyle(t));if(!n.length){return}const o={styles:n};if(!i.consumable.test(e.viewItem,o)){return}if(!e.modelRange){e=Object.assign(e,i.convertChildren(e.viewItem,e.modelCursor))}const r=[...e.modelRange.getItems({shallow:true})].pop();i.consumable.consume(e.viewItem,o);i.writer.setAttribute(\"borderStyle\",e.viewItem.getNormalizedStyle(\"border-style\"),r);i.writer.setAttribute(\"borderColor\",e.viewItem.getNormalizedStyle(\"border-color\"),r);i.writer.setAttribute(\"borderWidth\",e.viewItem.getNormalizedStyle(\"border-width\"),r)}))}function VO(t,e,i,n){t.for(\"downcast\").attributeToAttribute({model:{name:e,key:i},view:t=>({key:\"style\",value:{[n]:t}})})}function DO(t,e,i){t.for(\"downcast\").add(t=>t.on(`attribute:${e}:table`,(t,e,n)=>{const{item:o,attributeNewValue:r}=e;const{mapper:s,writer:a}=n;if(!n.consumable.consume(e.item,t.name)){return}const l=[...s.toViewElement(o).getChildren()].find(t=>t.is(\"table\"));if(r){a.setStyle(i,r,l)}else{a.removeStyle(i,l)}}))}class zO extends Vw{constructor(t,e){super(t);this.attributeName=e}refresh(){const t=this.editor;const e=EE(t.model.document.selection);this.isEnabled=!!e.length;this.value=this._getSingleValue(e)}execute(t={}){const{value:e,batch:i}=t;const n=this.editor.model;const o=EE(n.document.selection);const r=this._getValueToSet(e);n.enqueueChange(i||\"default\",t=>{if(r){o.forEach(e=>t.setAttribute(this.attributeName,r,e))}else{o.forEach(e=>t.removeAttribute(this.attributeName,e))}})}_getAttribute(t){if(!t){return}return t.getAttribute(this.attributeName)}_getValueToSet(t){return t}_getSingleValue(t){const e=this._getAttribute(t[0]);const i=t.every(t=>this._getAttribute(t)===e);return i?e:undefined}}class FO extends zO{constructor(t){super(t,\"padding\")}_getAttribute(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}_getValueToSet(t){return mE(t,\"px\")}}class jO extends zO{constructor(t){super(t,\"width\")}_getValueToSet(t){return mE(t,\"px\")}}class HO extends zO{constructor(t){super(t,\"height\")}_getValueToSet(t){return mE(t,\"px\")}}class WO extends zO{constructor(t){super(t,\"backgroundColor\")}}class qO extends zO{constructor(t){super(t,\"verticalAlignment\")}}class $O extends zO{constructor(t){super(t,\"horizontalAlignment\")}}class UO extends zO{constructor(t){super(t,\"borderStyle\")}_getAttribute(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}}class GO extends zO{constructor(t){super(t,\"borderColor\")}_getAttribute(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}}class JO extends zO{constructor(t){super(t,\"borderWidth\")}_getAttribute(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}_getValueToSet(t){return mE(t,\"px\")}}const KO=/^(top|bottom)$/;class XO extends Nw{static get pluginName(){return\"TableCellPropertiesEditing\"}static get requires(){return[iM]}init(){const t=this.editor;const e=t.model.schema;const i=t.conversion;const n=t.locale;t.data.addStyleProcessorRules(kO);YO(e,i);t.commands.add(\"tableCellBorderStyle\",new UO(t));t.commands.add(\"tableCellBorderColor\",new GO(t));t.commands.add(\"tableCellBorderWidth\",new JO(t));QO(e,i,n);t.commands.add(\"tableCellHorizontalAlignment\",new $O(t));tI(e,i,\"width\",\"width\");t.commands.add(\"tableCellWidth\",new jO(t));tI(e,i,\"height\",\"height\");t.commands.add(\"tableCellHeight\",new HO(t));t.data.addStyleProcessorRules(IO);tI(e,i,\"padding\",\"padding\");t.commands.add(\"tableCellPadding\",new FO(t));t.data.addStyleProcessorRules(RO);tI(e,i,\"backgroundColor\",\"background-color\");t.commands.add(\"tableCellBackgroundColor\",new WO(t));ZO(e,i);t.commands.add(\"tableCellVerticalAlignment\",new qO(t))}}function YO(t,e){t.extend(\"tableCell\",{allowAttributes:[\"borderWidth\",\"borderColor\",\"borderStyle\"]});BO(e,\"td\");BO(e,\"th\");VO(e,\"tableCell\",\"borderStyle\",\"border-style\");VO(e,\"tableCell\",\"borderColor\",\"border-color\");VO(e,\"tableCell\",\"borderWidth\",\"border-width\")}function QO(t,e,i){t.extend(\"tableCell\",{allowAttributes:[\"horizontalAlignment\"]});const n=[i.contentLanguageDirection==\"rtl\"?\"left\":\"right\",\"center\",\"justify\"];e.attributeToAttribute({model:{name:\"tableCell\",key:\"horizontalAlignment\",values:n},view:n.reduce((t,e)=>({...t,[e]:{key:\"style\",value:{\"text-align\":e}}}),{})})}function ZO(t,e){t.extend(\"tableCell\",{allowAttributes:[\"verticalAlignment\"]});e.attributeToAttribute({model:{name:\"tableCell\",key:\"verticalAlignment\",values:[\"top\",\"bottom\"]},view:{top:{key:\"style\",value:{\"vertical-align\":\"top\"}},bottom:{key:\"style\",value:{\"vertical-align\":\"bottom\"}}}});e.for(\"upcast\").attributeToAttribute({view:{attributes:{valign:KO}},model:{name:\"tableCell\",key:\"verticalAlignment\",value:t=>t.getAttribute(\"valign\")}})}function tI(t,e,i,n){t.extend(\"tableCell\",{allowAttributes:[i]});NO(e,\"tableCell\",i,n);VO(e,\"tableCell\",i,n)}class eI extends Nw{static get pluginName(){return\"TableCellProperties\"}static get requires(){return[XO,_O]}}class iI extends Vw{constructor(t,e){super(t);this.attributeName=e}refresh(){const t=this.editor;const e=t.model.document.selection;const i=dE(\"table\",e.getFirstPosition());this.isEnabled=!!i;this.value=this._getValue(i)}execute(t={}){const e=this.editor.model;const i=e.document.selection;const{value:n,batch:o}=t;const r=dE(\"table\",i.getFirstPosition());const s=this._getValueToSet(n);e.enqueueChange(o||\"default\",t=>{if(s){t.setAttribute(this.attributeName,s,r)}else{t.removeAttribute(this.attributeName,r)}})}_getValue(t){if(!t){return}return t.getAttribute(this.attributeName)}_getValueToSet(t){return t}}class nI extends iI{constructor(t){super(t,\"backgroundColor\")}}class oI extends iI{constructor(t){super(t,\"borderColor\")}_getValue(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}}class rI extends iI{constructor(t){super(t,\"borderStyle\")}_getValue(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}}class sI extends iI{constructor(t){super(t,\"borderWidth\")}_getValue(t){if(!t){return}return fE(t.getAttribute(this.attributeName))}_getValueToSet(t){return mE(t,\"px\")}}class aI extends iI{constructor(t){super(t,\"width\")}_getValueToSet(t){return mE(t,\"px\")}}class lI extends iI{constructor(t){super(t,\"height\")}_getValueToSet(t){return mE(t,\"px\")}}class cI extends iI{constructor(t){super(t,\"alignment\")}}const dI=/^(left|right)$/;class uI extends Nw{static get pluginName(){return\"TablePropertiesEditing\"}static get requires(){return[iM]}init(){const t=this.editor;const e=t.model.schema;const i=t.conversion;t.data.addStyleProcessorRules(kO);hI(e,i);t.commands.add(\"tableBorderColor\",new oI(t));t.commands.add(\"tableBorderStyle\",new rI(t));t.commands.add(\"tableBorderWidth\",new sI(t));fI(e,i);t.commands.add(\"tableAlignment\",new cI(t));gI(e,i,\"width\",\"width\");t.commands.add(\"tableWidth\",new aI(t));gI(e,i,\"height\",\"height\");t.commands.add(\"tableHeight\",new lI(t));t.data.addStyleProcessorRules(RO);mI(e,i,\"backgroundColor\",\"background-color\");t.commands.add(\"tableBackgroundColor\",new nI(t))}}function hI(t,e){t.extend(\"table\",{allowAttributes:[\"borderWidth\",\"borderColor\",\"borderStyle\"]});BO(e,\"table\");DO(e,\"borderColor\",\"border-color\");DO(e,\"borderStyle\",\"border-style\");DO(e,\"borderWidth\",\"border-width\")}function fI(t,e){t.extend(\"table\",{allowAttributes:[\"alignment\"]});e.attributeToAttribute({model:{name:\"table\",key:\"alignment\",values:[\"left\",\"right\"]},view:{left:{key:\"style\",value:{float:\"left\"}},right:{key:\"style\",value:{float:\"right\"}}},converterPriority:\"high\"});e.for(\"upcast\").attributeToAttribute({view:{attributes:{align:dI}},model:{name:\"table\",key:\"alignment\",value:t=>t.getAttribute(\"align\")}})}function mI(t,e,i,n){t.extend(\"table\",{allowAttributes:[i]});NO(e,\"table\",i,n);DO(e,i,n)}function gI(t,e,i,n){t.extend(\"table\",{allowAttributes:[i]});NO(e,\"table\",i,n);VO(e,\"table\",i,n)}var pI='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\" clip-rule=\"evenodd\" stroke-linejoin=\"round\" stroke-miterlimit=\"1.414\"><path d=\"M18 4.5V3H2v1.5h16zm0 3V6h-5.674v1.5H18zm0 3V9h-5.674v1.5H18zm0 3V12h-5.674v1.5H18zm-8.5-6V12h-6V7.5h6zm.818-1.5H2.682C2.305 6 2 6.407 2 6.91v5.68c0 .503.305.91.682.91h7.636c.377 0 .682-.407.682-.91V6.91c0-.503-.305-.91-.682-.91zM18 16.5V15H2v1.5h16z\"/></svg>';var bI='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 4.5V3h16v1.5zm0 3V6h5.674v1.5zm0 3V9h5.674v1.5zm0 3V12h5.674v1.5zm8.5-6V12h6V7.5h-6zM9.682 6h7.636c.377 0 .682.407.682.91v5.68c0 .503-.305.91-.682.91H9.682c-.377 0-.682-.407-.682-.91V6.91c0-.503.305-.91.682-.91zM2 16.5V15h16v1.5z\"/></svg>';var wI='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M2 4.5V3h16v1.5zm4.5 3V12h7V7.5h-7zM5.758 6h8.484c.419 0 .758.407.758.91v5.681c0 .502-.34.909-.758.909H5.758c-.419 0-.758-.407-.758-.91V6.91c0-.503.34-.91.758-.91zM2 16.5V15h16v1.5z\"/></svg>';var _I=i(112);const kI={left:pI,center:wI,right:bI};class vI extends _b{constructor(t,e){super(t);this.set({borderStyle:\"\",borderWidth:\"\",borderColor:\"\",backgroundColor:\"\",width:\"\",height:\"\",alignment:\"\"});this.options=e;const{borderStyleDropdown:i,borderWidthInput:n,borderColorInput:o,borderRowLabel:r}=this._createBorderFields();const{widthInput:s,operatorLabel:a,heightInput:l,dimensionsLabel:c}=this._createDimensionFields();const{alignmentToolbar:d,alignmentLabel:u}=this._createAlignmentFields();this.focusTracker=new Pp;this.keystrokes=new mp;this.children=this.createCollection();this.borderStyleDropdown=i;this.borderWidthInput=n;this.borderColorInput=o;this.backgroundInput=this._createBackgroundField();this.widthInput=s;this.heightInput=l;this.alignmentToolbar=d;const{saveButtonView:h,cancelButtonView:f}=this._createActionButtons();this.saveButtonView=h;this.cancelButtonView=f;this._focusables=new Wp;this._focusCycler=new Bb({focusables:this._focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:\"shift + tab\",focusNext:\"tab\"}});this.children.add(new SP(t,{label:this.t(\"Table properties\")}));this.children.add(new sO(t,{labelView:r,children:[r,i,o,n],class:\"ck-table-form__border-row\"}));this.children.add(new sO(t,{children:[this.backgroundInput]}));this.children.add(new sO(t,{children:[new sO(t,{labelView:c,children:[c,s,a,l],class:\"ck-table-form__dimensions-row\"}),new sO(t,{labelView:u,children:[u,d],class:\"ck-table-properties-form__alignment-row\"})]}));this.children.add(new sO(t,{children:[this.saveButtonView,this.cancelButtonView],class:\"ck-table-form__action-row\"}));this.setTemplate({tag:\"form\",attributes:{class:[\"ck\",\"ck-form\",\"ck-table-form\",\"ck-table-properties-form\"],tabindex:\"-1\"},children:this.children})}render(){super.render();JA({view:this});[this.borderStyleDropdown,this.borderColorInput,this.borderWidthInput,this.backgroundInput,this.widthInput,this.heightInput,this.alignmentToolbar,this.saveButtonView,this.cancelButtonView].forEach(t=>{this._focusables.add(t);this.focusTracker.add(t.element)});this.keystrokes.listenTo(this.element)}focus(){this._focusCycler.focusFirst()}_createBorderFields(){const t=tO({colorConfig:this.options.borderColors,columns:5});const e=this.locale;const i=this.t;const n=new Eb(e);n.text=i(\"Border\");const o=$M(this.t);const r=new WA(e,GA);r.set({label:i(\"Style\"),class:\"ck-table-form__border-style\"});r.fieldView.buttonView.set({isOn:false,withText:true,tooltip:i(\"Style\")});r.fieldView.buttonView.bind(\"label\").to(this,\"borderStyle\",t=>o[t?t:\"none\"]);r.fieldView.on(\"execute\",t=>{this.borderStyle=t.source._borderStyleValue});_w(r.fieldView,YM(this));const s=new WA(e,UA);s.set({label:i(\"Width\"),class:\"ck-table-form__border-width\"});s.fieldView.bind(\"value\").to(this,\"borderWidth\");s.bind(\"isEnabled\").to(this,\"borderStyle\",yI);s.fieldView.on(\"input\",()=>{this.borderWidth=s.fieldView.element.value});const a=new WA(e,t);a.set({label:i(\"Color\"),class:\"ck-table-form__border-color\"});a.fieldView.bind(\"value\").to(this,\"borderColor\");a.bind(\"isEnabled\").to(this,\"borderStyle\",yI);a.fieldView.on(\"input\",()=>{this.borderColor=a.fieldView.value});this.on(\"change:borderStyle\",(t,e,i)=>{if(!yI(i)){this.borderColor=\"\";this.borderWidth=\"\"}});return{borderRowLabel:n,borderStyleDropdown:r,borderColorInput:a,borderWidthInput:s}}_createBackgroundField(){const t=tO({colorConfig:this.options.backgroundColors,columns:5});const e=this.locale;const i=this.t;const n=new WA(e,t);n.set({label:i(\"Background\"),class:\"ck-table-properties-form__background\"});n.fieldView.bind(\"value\").to(this,\"backgroundColor\");n.fieldView.on(\"input\",()=>{this.backgroundColor=n.fieldView.value});return n}_createDimensionFields(){const t=this.locale;const e=this.t;const i=new Eb(t);i.text=e(\"Dimensions\");const n=new WA(t,UA);n.set({label:e(\"Width\"),class:\"ck-table-form__dimensions-row__width\"});n.fieldView.bind(\"value\").to(this,\"width\");n.fieldView.on(\"input\",()=>{this.width=n.fieldView.element.value});const o=new _b(t);o.setTemplate({tag:\"span\",attributes:{class:[\"ck-table-form__dimension-operator\"]},children:[{text:\"×\"}]});const r=new WA(t,UA);r.set({label:e(\"Height\"),class:\"ck-table-form__dimensions-row__height\"});r.fieldView.bind(\"value\").to(this,\"height\");r.fieldView.on(\"input\",()=>{this.height=r.fieldView.element.value});return{dimensionsLabel:i,widthInput:n,operatorLabel:o,heightInput:r}}_createAlignmentFields(){const t=this.locale;const e=this.t;const i=new Eb(t);i.text=e(\"Alignment\");const n=new Tw(t);n.set({isCompact:true,ariaLabel:e(\"Table alignment toolbar\")});QM({view:this,icons:kI,toolbar:n,labels:this._alignmentLabels,propertyName:\"alignment\",nameToValue:t=>t===\"center\"?\"\":t});return{alignmentLabel:i,alignmentToolbar:n}}_createActionButtons(){const t=this.locale;const e=this.t;const i=new rw(t);const n=new rw(t);const o=[this.borderWidthInput,this.borderColorInput,this.backgroundInput,this.widthInput,this.heightInput];i.set({label:e(\"Save\"),icon:KA,class:\"ck-button-save\",type:\"submit\",withText:true});i.bind(\"isEnabled\").toMany(o,\"errorText\",(...t)=>t.every(t=>!t));n.set({label:e(\"Cancel\"),icon:XA,class:\"ck-button-cancel\",type:\"cancel\",withText:true});n.delegate(\"execute\").to(this,\"cancel\");return{saveButtonView:i,cancelButtonView:n}}get _alignmentLabels(){const t=this.locale;const e=this.t;const i=e(\"Align table to the left\");const n=e(\"Center table\");const o=e(\"Align table to the right\");if(t.uiLanguageDirection===\"rtl\"){return{right:o,center:n,left:i}}else{return{left:i,center:n,right:o}}}}function yI(t){return!!t}var xI='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M8 2v5h4V2h1v5h5v1h-5v4h.021l-.172.351-1.916.28-.151.027c-.287.063-.54.182-.755.341L8 13v5H7v-5H2v-1h5V8H2V7h5V2h1zm4 6H8v4h4V8z\" opacity=\".6\"/><path d=\"M15.5 11.5l1.323 2.68 2.957.43-2.14 2.085.505 2.946L15.5 18.25l-2.645 1.39.505-2.945-2.14-2.086 2.957-.43L15.5 11.5zM17 1a2 2 0 0 1 2 2v9.475l-.85-.124-.857-1.736a2.048 2.048 0 0 0-.292-.44L17 3H3v14h7.808l.402.392L10.935 19H3a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h14z\"/></svg>';const CI=500;const AI={borderStyle:\"tableBorderStyle\",borderColor:\"tableBorderColor\",borderWidth:\"tableBorderWidth\",backgroundColor:\"tableBackgroundColor\",width:\"tableWidth\",height:\"tableHeight\",alignment:\"tableAlignment\"};class TI extends Nw{static get requires(){return[zA]}static get pluginName(){return\"TablePropertiesUI\"}constructor(t){super(t);t.config.define(\"table.tableProperties\",{borderColors:ZM,backgroundColors:ZM})}init(){const t=this.editor;const e=t.t;this._balloon=t.plugins.get(zA);this.view=this._createPropertiesView();this._undoStepBatch=null;t.ui.componentFactory.add(\"tableProperties\",i=>{const n=new rw(i);n.set({label:e(\"Table properties\"),icon:xI,tooltip:true});this.listenTo(n,\"execute\",()=>this._showView());const o=Object.values(AI).map(e=>t.commands.get(e));n.bind(\"isEnabled\").toMany(o,\"isEnabled\",(...t)=>t.some(t=>t));return n})}destroy(){super.destroy();this.view.destroy()}_createPropertiesView(){const t=this.editor;const e=t.editing.view.document;const i=t.config.get(\"table.tableProperties\");const n=Fv(i.borderColors);const o=zv(t.locale,n);const r=Fv(i.backgroundColors);const s=zv(t.locale,r);const a=new vI(t.locale,{borderColors:o,backgroundColors:s});const l=t.t;a.render();this.listenTo(a,\"submit\",()=>{this._hideView()});this.listenTo(a,\"cancel\",()=>{if(this._undoStepBatch.operations.length){t.execute(\"undo\",this._undoStepBatch)}this._hideView()});a.keystrokes.set(\"Esc\",(t,e)=>{this._hideView();e()});this.listenTo(t.ui,\"update\",()=>{if(!AE(e.selection)){this._hideView()}else if(this._isViewVisible){HM(t,\"table\")}});mw({emitter:a,activator:()=>this._isViewInBalloon,contextElements:[this._balloon.view.element],callback:()=>this._hideView()});const c=UM(l);const d=GM(l);a.on(\"change:borderStyle\",this._getPropertyChangeCallback(\"tableBorderStyle\"));a.on(\"change:borderColor\",this._getValidatedPropertyChangeCallback({viewField:a.borderColorInput,commandName:\"tableBorderColor\",errorText:c,validator:JM}));a.on(\"change:borderWidth\",this._getValidatedPropertyChangeCallback({viewField:a.borderWidthInput,commandName:\"tableBorderWidth\",errorText:d,validator:XM}));a.on(\"change:backgroundColor\",this._getValidatedPropertyChangeCallback({viewField:a.backgroundInput,commandName:\"tableBackgroundColor\",errorText:c,validator:JM}));a.on(\"change:width\",this._getValidatedPropertyChangeCallback({viewField:a.widthInput,commandName:\"tableWidth\",errorText:d,validator:KM}));a.on(\"change:height\",this._getValidatedPropertyChangeCallback({viewField:a.heightInput,commandName:\"tableHeight\",errorText:d,validator:KM}));a.on(\"change:alignment\",this._getPropertyChangeCallback(\"tableAlignment\"));return a}_fillViewFormFromCommandValues(){const t=this.editor.commands;Object.entries(AI).map(([e,i])=>[e,t.get(i).value||\"\"]).forEach(([t,e])=>this.view.set(t,e))}_showView(){const t=this.editor;this._balloon.add({view:this.view,position:WM(t)});this._undoStepBatch=t.model.createBatch();this._fillViewFormFromCommandValues();this.view.focus()}_hideView(){if(!this._isViewInBalloon){return}const t=this.editor;this.stopListening(t.ui,\"update\");this.view.saveButtonView.focus();this._balloon.remove(this.view);this.editor.editing.view.focus()}get _isViewVisible(){return this._balloon.visibleView===this.view}get _isViewInBalloon(){return this._balloon.hasView(this.view)}_getPropertyChangeCallback(t){return(e,i,n)=>{this.editor.execute(t,{value:n,batch:this._undoStepBatch})}}_getValidatedPropertyChangeCallback({commandName:t,viewField:e,validator:i,errorText:n}){const o=uh(()=>{e.errorText=n},CI);return(n,r,s)=>{o.cancel();if(i(s)){this.editor.execute(t,{value:s,batch:this._undoStepBatch});e.errorText=null}else{o()}}}}class PI extends Nw{static get pluginName(){return\"TableProperties\"}static get requires(){return[uI,TI]}}class EI extends Nw{static get requires(){return[zA]}static get pluginName(){return\"WidgetToolbarRepository\"}init(){const t=this.editor;if(t.plugins.has(\"BalloonToolbar\")){const e=t.plugins.get(\"BalloonToolbar\");this.listenTo(e,\"show\",e=>{if(OI(t.editing.view.document.selection)){e.stop()}},{priority:\"high\"})}this._toolbarDefinitions=new Map;this._balloon=this.editor.plugins.get(\"ContextualBalloon\");this.on(\"change:isEnabled\",()=>{this._updateToolbarsVisibility()});this.listenTo(t.ui,\"update\",()=>{this._updateToolbarsVisibility()});this.listenTo(t.ui.focusTracker,\"change:isFocused\",()=>{this._updateToolbarsVisibility()},{priority:\"low\"})}destroy(){super.destroy();for(const t of this._toolbarDefinitions.values()){t.view.destroy()}}register(t,{ariaLabel:e,items:i,getRelatedElement:n,balloonClassName:o=\"ck-toolbar-container\"}){const r=this.editor;const s=r.t;const a=new Tw(r.locale);a.ariaLabel=e||s(\"Widget toolbar\");if(this._toolbarDefinitions.has(t)){throw new ss[\"b\"](\"widget-toolbar-duplicated: Toolbar with the given id was already added.\",this,{toolbarId:t})}a.fillFromConfig(i,r.ui.componentFactory);this._toolbarDefinitions.set(t,{view:a,getRelatedElement:n,balloonClassName:o})}_updateToolbarsVisibility(){let t=0;let e=null;let i=null;for(const n of this._toolbarDefinitions.values()){const o=n.getRelatedElement(this.editor.editing.view.document.selection);if(!this.isEnabled||!o){if(this._isToolbarInBalloon(n)){this._hideToolbar(n)}}else if(!this.editor.ui.focusTracker.isFocused){if(this._isToolbarVisible(n)){this._hideToolbar(n)}}else{const r=o.getAncestors().length;if(r>t){t=r;e=o;i=n}}}if(i){this._showToolbar(i,e)}}_hideToolbar(t){this._balloon.remove(t.view);this.stopListening(this._balloon,\"change:visibleView\")}_showToolbar(t,e){if(this._isToolbarVisible(t)){SI(this.editor,e)}else if(!this._isToolbarInBalloon(t)){this._balloon.add({view:t.view,position:MI(this.editor,e),balloonClassName:t.balloonClassName});this.listenTo(this._balloon,\"change:visibleView\",()=>{for(const t of this._toolbarDefinitions.values()){if(this._isToolbarVisible(t)){const e=t.getRelatedElement(this.editor.editing.view.document.selection);SI(this.editor,e)}}})}}_isToolbarVisible(t){return this._balloon.visibleView===t.view}_isToolbarInBalloon(t){return this._balloon.hasView(t.view)}}function SI(t,e){const i=t.plugins.get(\"ContextualBalloon\");const n=MI(t,e);i.updatePosition(n)}function MI(t,e){const i=t.editing.view;const n=Zy.defaultPositions;return{target:i.domConverter.mapViewToDom(e),positions:[n.northArrowSouth,n.northArrowSouthWest,n.northArrowSouthEast,n.southArrowNorth,n.southArrowNorthWest,n.southArrowNorthEast,mx]}}function OI(t){const e=t.getSelectedElement();return!!(e&&sx(e))}class II extends Nw{static get requires(){return[EI]}static get pluginName(){return\"TableToolbar\"}afterInit(){const t=this.editor;const e=t.t;const i=t.plugins.get(EI);const n=t.config.get(\"table.contentToolbar\");const o=t.config.get(\"table.tableToolbar\");if(n){i.register(\"tableContent\",{ariaLabel:e(\"Table toolbar\"),items:n,getRelatedElement:AE})}if(o){i.register(\"table\",{ariaLabel:e(\"Table toolbar\"),items:o,getRelatedElement:CE})}}}class RI{constructor(t,e){this.model=t;this.testCallback=e;this.hasMatch=false;this.set(\"isEnabled\",true);this.on(\"change:isEnabled\",()=>{if(this.isEnabled){this._startListening()}else{this.stopListening(t.document.selection);this.stopListening(t.document)}});this._startListening()}_startListening(){const t=this.model;const e=t.document;this.listenTo(e.selection,\"change:range\",(t,{directChange:i})=>{if(!i){return}if(!e.selection.isCollapsed){if(this.hasMatch){this.fire(\"unmatched\");this.hasMatch=false}return}this._evaluateTextBeforeSelection(\"selection\")});this.listenTo(e,\"change:data\",(t,e)=>{if(e.type==\"transparent\"){return}this._evaluateTextBeforeSelection(\"data\",{batch:e})})}_evaluateTextBeforeSelection(t,e={}){const i=this.model;const n=i.document;const o=n.selection;const r=i.createRange(i.createPositionAt(o.focus.parent,0),o.focus);const{text:s,range:a}=n_(r,i);const l=this.testCallback(s);if(!l&&this.hasMatch){this.fire(\"unmatched\")}this.hasMatch=!!l;if(l){const i=Object.assign(e,{text:s,range:a});if(typeof l==\"object\"){Object.assign(i,l)}this.fire(`matched:${t}`,i)}}}ys(RI,Xl);var LI=/[\\\\^$.*+?()[\\]{}|]/g,NI=RegExp(LI.source);function BI(t){t=va(t);return t&&NI.test(t)?t.replace(LI,\"\\\\$&\"):t}var VI=BI;const DI={copyright:{from:\"(c)\",to:\"©\"},registeredTrademark:{from:\"(r)\",to:\"®\"},trademark:{from:\"(tm)\",to:\"™\"},oneHalf:{from:\"1/2\",to:\"½\"},oneThird:{from:\"1/3\",to:\"⅓\"},twoThirds:{from:\"2/3\",to:\"⅔\"},oneForth:{from:\"1/4\",to:\"¼\"},threeQuarters:{from:\"3/4\",to:\"¾\"},lessThanOrEqual:{from:\"<=\",to:\"≤\"},greaterThanOrEqual:{from:\">=\",to:\"≥\"},notEqual:{from:\"!=\",to:\"≠\"},arrowLeft:{from:\"<-\",to:\"←\"},arrowRight:{from:\"->\",to:\"→\"},horizontalEllipsis:{from:\"...\",to:\"…\"},enDash:{from:/(^| )(--)( )$/,to:[null,\"–\",null]},emDash:{from:/(^| )(---)( )$/,to:[null,\"—\",null]},quotesPrimary:{from:$I('\"'),to:[null,\"“\",null,\"”\"]},quotesSecondary:{from:$I(\"'\"),to:[null,\"‘\",null,\"’\"]},quotesPrimaryEnGb:{from:$I(\"'\"),to:[null,\"‘\",null,\"’\"]},quotesSecondaryEnGb:{from:$I('\"'),to:[null,\"“\",null,\"”\"]},quotesPrimaryPl:{from:$I('\"'),to:[null,\"„\",null,\"”\"]},quotesSecondaryPl:{from:$I(\"'\"),to:[null,\"‚\",null,\"’\"]}};const zI={symbols:[\"copyright\",\"registeredTrademark\",\"trademark\"],mathematical:[\"oneHalf\",\"oneThird\",\"twoThirds\",\"oneForth\",\"threeQuarters\",\"lessThanOrEqual\",\"greaterThanOrEqual\",\"notEqual\",\"arrowLeft\",\"arrowRight\"],typography:[\"horizontalEllipsis\",\"enDash\",\"emDash\"],quotes:[\"quotesPrimary\",\"quotesSecondary\"]};const FI=[\"symbols\",\"mathematical\",\"typography\",\"quotes\"];class jI extends Nw{static get pluginName(){return\"TextTransformation\"}constructor(t){super(t);t.config.define(\"typing\",{transformations:{include:FI}})}init(){const t=this.editor.model;const e=t.document.selection;e.on(\"change:range\",()=>{this.isEnabled=!e.anchor.parent.is(\"codeBlock\")});this._enableTransformationWatchers()}_enableTransformationWatchers(){const t=this.editor;const e=t.model;const i=t.plugins.get(\"Input\");const n=UI(t.config.get(\"typing.transformations\"));const o=t=>{for(const e of n){const i=e.from;const n=i.test(t);if(n){return{normalizedTransformation:e}}}};const r=(t,n)=>{if(!i.isInput(n.batch)){return}const{from:o,to:r}=n.normalizedTransformation;const s=o.exec(n.text);const a=r(s.slice(1));const l=n.range;let c=s.index;e.enqueueChange(t=>{for(let i=1;i<s.length;i++){const n=s[i];const o=a[i-1];if(o==null){c+=n.length;continue}const r=l.start.getShiftedBy(c);const d=e.createRange(r,r.getShiftedBy(n.length));const u=qI(r);e.insertContent(t.createText(o,u),d);c+=o.length}})};const s=new RI(t.model,o);s.on(\"matched:data\",r);s.bind(\"isEnabled\").to(this)}}function HI(t){if(typeof t==\"string\"){return new RegExp(`(${VI(t)})$`)}return t}function WI(t){if(typeof t==\"string\"){return()=>[t]}else if(t instanceof Array){return()=>t}return t}function qI(t){const e=t.textNode?t.textNode:t.nodeAfter;return e.getAttributes()}function $I(t){return new RegExp(`(^|\\\\s)(${t})([^${t}]*)(${t})$`)}function UI(t){const e=t.extra||[];const i=t.remove||[];const n=t=>!i.includes(t);const o=t.include.concat(e).filter(n);return GI(o).filter(n).map(t=>DI[t]||t).map(t=>({from:HI(t.from),to:WI(t.to)}))}function GI(t){const e=new Set;for(const i of t){if(zI[i]){for(const t of zI[i]){e.add(t)}}else{e.add(i)}}return Array.from(e)}const JI=\"underline\";class KI extends Nw{static get pluginName(){return\"UnderlineEditing\"}init(){const t=this.editor;t.model.schema.extend(\"$text\",{allowAttributes:JI});t.model.schema.setAttributeProperties(JI,{isFormatting:true,copyOnEnter:true});t.conversion.attributeToElement({model:JI,view:\"u\",upcastAlso:{styles:{\"text-decoration\":\"underline\"}}});t.commands.add(JI,new b_(t,JI));t.keystrokes.set(\"CTRL+U\",\"underline\")}}var XI='<svg viewBox=\"0 0 20 20\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M3 18v-1.5h14V18zm2.2-8V3.6c0-.4.4-.6.8-.6.3 0 .7.2.7.6v6.2c0 2 1.3 2.8 3.2 2.8 1.9 0 3.4-.9 3.4-2.9V3.6c0-.3.4-.5.8-.5.3 0 .7.2.7.5V10c0 2.7-2.2 4-4.9 4-2.6 0-4.7-1.2-4.7-4z\"/></svg>';const YI=\"underline\";class QI extends Nw{init(){const t=this.editor;const e=t.t;t.ui.componentFactory.add(YI,i=>{const n=t.commands.get(YI);const o=new rw(i);o.set({label:e(\"Underline\"),icon:XI,keystroke:\"CTRL+U\",tooltip:true,isToggleable:true});o.bind(\"isOn\",\"isEnabled\").to(n,\"value\",\"isEnabled\");this.listenTo(o,\"execute\",()=>{t.execute(YI);t.editing.view.focus()});return o})}}class ZI extends Nw{static get requires(){return[KI,QI]}static get pluginName(){return\"Underline\"}}function tR(t){if(t.is(\"text\")||t.is(\"textProxy\")){return t.data}let e=\"\";let i=null;for(const n of t.getChildren()){const t=tR(n);if(i&&i.is(\"element\")){e+=\"\\n\"}e+=t;i=n}return e}var eR=\"Expected a function\";function iR(t,e,i){var n=true,o=true;if(typeof t!=\"function\"){throw new TypeError(eR)}if(lt(i)){n=\"leading\"in i?!!i.leading:n;o=\"trailing\"in i?!!i.trailing:o}return uh(t,e,{leading:n,maxWait:e,trailing:o})}var nR=iR;class oR extends Nw{constructor(t){super(t);this.set(\"characters\",0);this.set(\"words\",0);Object.defineProperties(this,{characters:{get(){return this.characters=this._getCharacters()}},words:{get(){return this.words=this._getWords()}}});this.set(\"_wordsLabel\");this.set(\"_charactersLabel\");this._config=t.config.get(\"wordCount\")||{};this._outputView;this._wordsMatchRegExp=Tc.features.isRegExpUnicodePropertySupported?new RegExp(\"[\\\\p{L}\\\\p{N}\\\\p{M}\\\\p{Pd}\\\\p{Pc}]+\",\"gu\"):/[_\\-a-zA-Z0-9À-ž]+/gu}static get pluginName(){return\"WordCount\"}init(){const t=this.editor;t.model.document.on(\"change:data\",nR(this._refreshStats.bind(this),250));if(typeof this._config.onUpdate==\"function\"){this.on(\"update\",(t,e)=>{this._config.onUpdate(e)})}if(Jr(this._config.container)){this._config.container.appendChild(this.wordCountContainer)}}destroy(){if(this._outputView){this._outputView.element.remove();this._outputView.destroy()}super.destroy()}get wordCountContainer(){const t=this.editor;const e=t.t;const i=t.config.get(\"wordCount.displayWords\");const n=t.config.get(\"wordCount.displayCharacters\");const o=Up.bind(this,this);const r=[];if(!this._outputView){this._outputView=new _b;if(i||i===undefined){this.bind(\"_wordsLabel\").to(this,\"words\",t=>e(\"Words: %0\",[t]));r.push({tag:\"div\",children:[{text:[o.to(\"_wordsLabel\")]}],attributes:{class:\"ck-word-count__words\"}})}if(n||n===undefined){this.bind(\"_charactersLabel\").to(this,\"characters\",t=>e(\"Characters: %0\",[t]));r.push({tag:\"div\",children:[{text:[o.to(\"_charactersLabel\")]}],attributes:{class:\"ck-word-count__characters\"}})}this._outputView.setTemplate({tag:\"div\",attributes:{class:[\"ck\",\"ck-word-count\"]},children:r});this._outputView.render()}return this._outputView.element}_getCharacters(){const t=tR(this.editor.model.document.getRoot());return t.replace(/\\n/g,\"\").length}_getWords(){const t=tR(this.editor.model.document.getRoot());const e=t.match(this._wordsMatchRegExp)||[];return e.length}_refreshStats(){const t=this.words=this._getWords();const e=this.characters=this._getCharacters();this.fire(\"update\",{words:t,characters:e})}}class rR extends Rw{}rR.builtinPlugins=[e_,s_,p_,x_,M_,uk,wv,$v,Xv,sy,vy,Ny,$y,Px,Rx,uC,bC,aT,vP,Ay,PP,zP,FP,jP,$P,WP,HP,qP,YP,nE,cE,LM,eI,PI,II,jI,ZI,oR];var sR=e[\"default\"]=rR}])[\"default\"]}));"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA","sourceRoot":""}