create-nextjs-cms 0.5.56 → 0.5.60

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (336) hide show
  1. package/package.json +4 -4
  2. package/templates/default/CHANGELOG.md +140 -140
  3. package/templates/default/_gitignore +1 -0
  4. package/templates/default/app/(rootLayout)/admins/page.tsx +7 -2
  5. package/templates/default/app/(rootLayout)/advanced/page.tsx +8 -2
  6. package/templates/default/app/(rootLayout)/browse/[section]/[page]/page.tsx +17 -3
  7. package/templates/default/app/(rootLayout)/categorized/[section]/page.tsx +9 -1
  8. package/templates/default/app/(rootLayout)/dashboard-new/page.tsx +7 -0
  9. package/templates/default/app/(rootLayout)/edit/[section]/[itemId]/page.tsx +11 -1
  10. package/templates/default/app/(rootLayout)/layout.tsx +8 -1
  11. package/templates/default/app/(rootLayout)/new/[section]/page.tsx +9 -1
  12. package/templates/default/app/(rootLayout)/section/[section]/page.tsx +10 -1
  13. package/templates/default/app/(rootLayout)/settings/page.tsx +7 -1
  14. package/templates/default/app/api/trpc/[trpc]/route.ts +1 -1
  15. package/templates/default/app/api/video/route.ts +1 -1
  16. package/templates/default/app/layout.tsx +1 -1
  17. package/templates/default/app/providers.tsx +4 -4
  18. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/LICENSE +191 -0
  19. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/README.md +118 -0
  20. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/install/build.js +38 -0
  21. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/install/check.js +14 -0
  22. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/channel.js +177 -0
  23. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/colour.js +195 -0
  24. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/composite.js +212 -0
  25. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/constructor.js +499 -0
  26. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/index.d.ts +1971 -0
  27. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/index.js +16 -0
  28. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/input.js +809 -0
  29. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/is.js +143 -0
  30. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/libvips.js +207 -0
  31. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/operation.js +1016 -0
  32. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/output.js +1666 -0
  33. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/resize.js +595 -0
  34. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/sharp.js +121 -0
  35. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/lib/utility.js +291 -0
  36. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/package.json +202 -0
  37. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/binding.gyp +298 -0
  38. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/common.cc +1130 -0
  39. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/common.h +402 -0
  40. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/metadata.cc +346 -0
  41. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/metadata.h +90 -0
  42. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/operations.cc +499 -0
  43. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/operations.h +137 -0
  44. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/pipeline.cc +1814 -0
  45. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/pipeline.h +408 -0
  46. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/sharp.cc +43 -0
  47. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/stats.cc +186 -0
  48. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/stats.h +62 -0
  49. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/utilities.cc +288 -0
  50. package/templates/default/apps/cms/node_modules/next/node_modules/_tmp_40516_de1b9f7e36eccb968b79dbd2b8c388ea/src/utilities.h +22 -0
  51. package/templates/default/components/BrowsePage.tsx +4 -4
  52. package/templates/default/components/DashboardNewPage.tsx +252 -0
  53. package/templates/default/components/LogPage.tsx +2 -3
  54. package/templates/default/components/SettingsPage.tsx +1 -1
  55. package/templates/default/components/form/Form.tsx +5 -5
  56. package/templates/default/components/form/helpers/_section-hot-reload.js +1 -1
  57. package/templates/default/components/form/helpers/util.ts +5 -5
  58. package/templates/default/dynamic-schemas/schema.ts +381 -381
  59. package/templates/default/next-env.d.ts +1 -1
  60. package/templates/default/next.config.ts +24 -0
  61. package/templates/default/package.json +23 -17
  62. package/templates/default/{middleware.ts → proxy.ts} +3 -4
  63. package/templates/default/tsconfig.json +6 -3
  64. package/templates/default/app/api/placeholder/route.ts +0 -7
  65. package/templates/default/public/tinymce/CHANGELOG.md +0 -3940
  66. package/templates/default/public/tinymce/README.md +0 -77
  67. package/templates/default/public/tinymce/bower.json +0 -27
  68. package/templates/default/public/tinymce/composer.json +0 -52
  69. package/templates/default/public/tinymce/icons/default/icons.js +0 -239
  70. package/templates/default/public/tinymce/icons/default/icons.min.js +0 -1
  71. package/templates/default/public/tinymce/icons/default/index.js +0 -7
  72. package/templates/default/public/tinymce/license.md +0 -9
  73. package/templates/default/public/tinymce/models/dom/index.js +0 -7
  74. package/templates/default/public/tinymce/models/dom/model.js +0 -8980
  75. package/templates/default/public/tinymce/models/dom/model.min.js +0 -1
  76. package/templates/default/public/tinymce/notices.txt +0 -21
  77. package/templates/default/public/tinymce/package.json +0 -32
  78. package/templates/default/public/tinymce/plugins/accordion/index.js +0 -7
  79. package/templates/default/public/tinymce/plugins/accordion/plugin.js +0 -1373
  80. package/templates/default/public/tinymce/plugins/accordion/plugin.min.js +0 -1
  81. package/templates/default/public/tinymce/plugins/advlist/index.js +0 -7
  82. package/templates/default/public/tinymce/plugins/advlist/plugin.js +0 -473
  83. package/templates/default/public/tinymce/plugins/advlist/plugin.min.js +0 -1
  84. package/templates/default/public/tinymce/plugins/anchor/index.js +0 -7
  85. package/templates/default/public/tinymce/plugins/anchor/plugin.js +0 -237
  86. package/templates/default/public/tinymce/plugins/anchor/plugin.min.js +0 -1
  87. package/templates/default/public/tinymce/plugins/autolink/index.js +0 -7
  88. package/templates/default/public/tinymce/plugins/autolink/plugin.js +0 -315
  89. package/templates/default/public/tinymce/plugins/autolink/plugin.min.js +0 -1
  90. package/templates/default/public/tinymce/plugins/autoresize/index.js +0 -7
  91. package/templates/default/public/tinymce/plugins/autoresize/plugin.js +0 -221
  92. package/templates/default/public/tinymce/plugins/autoresize/plugin.min.js +0 -1
  93. package/templates/default/public/tinymce/plugins/autosave/index.js +0 -7
  94. package/templates/default/public/tinymce/plugins/autosave/plugin.js +0 -249
  95. package/templates/default/public/tinymce/plugins/autosave/plugin.min.js +0 -1
  96. package/templates/default/public/tinymce/plugins/charmap/index.js +0 -7
  97. package/templates/default/public/tinymce/plugins/charmap/plugin.js +0 -997
  98. package/templates/default/public/tinymce/plugins/charmap/plugin.min.js +0 -1
  99. package/templates/default/public/tinymce/plugins/code/index.js +0 -7
  100. package/templates/default/public/tinymce/plugins/code/plugin.js +0 -98
  101. package/templates/default/public/tinymce/plugins/code/plugin.min.js +0 -1
  102. package/templates/default/public/tinymce/plugins/codesample/index.js +0 -7
  103. package/templates/default/public/tinymce/plugins/codesample/plugin.js +0 -3655
  104. package/templates/default/public/tinymce/plugins/codesample/plugin.min.js +0 -9
  105. package/templates/default/public/tinymce/plugins/directionality/index.js +0 -7
  106. package/templates/default/public/tinymce/plugins/directionality/plugin.js +0 -634
  107. package/templates/default/public/tinymce/plugins/directionality/plugin.min.js +0 -1
  108. package/templates/default/public/tinymce/plugins/emoticons/index.js +0 -7
  109. package/templates/default/public/tinymce/plugins/emoticons/js/emojiimages.js +0 -1
  110. package/templates/default/public/tinymce/plugins/emoticons/js/emojiimages.min.js +0 -1
  111. package/templates/default/public/tinymce/plugins/emoticons/js/emojis.js +0 -1
  112. package/templates/default/public/tinymce/plugins/emoticons/js/emojis.min.js +0 -1
  113. package/templates/default/public/tinymce/plugins/emoticons/plugin.js +0 -809
  114. package/templates/default/public/tinymce/plugins/emoticons/plugin.min.js +0 -1
  115. package/templates/default/public/tinymce/plugins/fullscreen/index.js +0 -7
  116. package/templates/default/public/tinymce/plugins/fullscreen/plugin.js +0 -1607
  117. package/templates/default/public/tinymce/plugins/fullscreen/plugin.min.js +0 -1
  118. package/templates/default/public/tinymce/plugins/help/index.js +0 -7
  119. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ar.js +0 -93
  120. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/bg-BG.js +0 -93
  121. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/bg_BG.js +0 -93
  122. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ca.js +0 -93
  123. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/cs.js +0 -93
  124. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/da.js +0 -93
  125. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/de.js +0 -93
  126. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/el.js +0 -93
  127. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/en.js +0 -93
  128. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/es.js +0 -93
  129. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/eu.js +0 -93
  130. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/fa.js +0 -93
  131. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/fi.js +0 -93
  132. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/fr-FR.js +0 -93
  133. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/fr_FR.js +0 -93
  134. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/he-IL.js +0 -93
  135. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/he_IL.js +0 -93
  136. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/hi.js +0 -93
  137. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/hr.js +0 -93
  138. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/hu-HU.js +0 -93
  139. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/hu_HU.js +0 -93
  140. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/id.js +0 -93
  141. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/it.js +0 -93
  142. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ja.js +0 -93
  143. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/kk.js +0 -93
  144. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ko-KR.js +0 -93
  145. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ko_KR.js +0 -93
  146. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ms.js +0 -93
  147. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/nb-NO.js +0 -93
  148. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/nb_NO.js +0 -93
  149. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/nl.js +0 -93
  150. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/pl.js +0 -93
  151. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/pt-BR.js +0 -93
  152. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/pt-PT.js +0 -93
  153. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/pt_BR.js +0 -93
  154. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/pt_PT.js +0 -93
  155. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ro.js +0 -93
  156. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/ru.js +0 -93
  157. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/sk.js +0 -93
  158. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/sl-SI.js +0 -93
  159. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/sl_SI.js +0 -93
  160. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/sv-SE.js +0 -93
  161. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/sv_SE.js +0 -93
  162. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/th-TH.js +0 -93
  163. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/th_TH.js +0 -93
  164. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/tr.js +0 -93
  165. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/uk.js +0 -93
  166. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/vi.js +0 -93
  167. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/zh-CN.js +0 -87
  168. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/zh-TW.js +0 -93
  169. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/zh_CN.js +0 -87
  170. package/templates/default/public/tinymce/plugins/help/js/i18n/keynav/zh_TW.js +0 -93
  171. package/templates/default/public/tinymce/plugins/help/plugin.js +0 -826
  172. package/templates/default/public/tinymce/plugins/help/plugin.min.js +0 -1
  173. package/templates/default/public/tinymce/plugins/image/index.js +0 -7
  174. package/templates/default/public/tinymce/plugins/image/plugin.js +0 -1691
  175. package/templates/default/public/tinymce/plugins/image/plugin.min.js +0 -1
  176. package/templates/default/public/tinymce/plugins/importcss/index.js +0 -7
  177. package/templates/default/public/tinymce/plugins/importcss/plugin.js +0 -401
  178. package/templates/default/public/tinymce/plugins/importcss/plugin.min.js +0 -1
  179. package/templates/default/public/tinymce/plugins/insertdatetime/index.js +0 -7
  180. package/templates/default/public/tinymce/plugins/insertdatetime/plugin.js +0 -187
  181. package/templates/default/public/tinymce/plugins/insertdatetime/plugin.min.js +0 -1
  182. package/templates/default/public/tinymce/plugins/link/index.js +0 -7
  183. package/templates/default/public/tinymce/plugins/link/plugin.js +0 -1709
  184. package/templates/default/public/tinymce/plugins/link/plugin.min.js +0 -1
  185. package/templates/default/public/tinymce/plugins/lists/index.js +0 -7
  186. package/templates/default/public/tinymce/plugins/lists/plugin.js +0 -602
  187. package/templates/default/public/tinymce/plugins/lists/plugin.min.js +0 -1
  188. package/templates/default/public/tinymce/plugins/media/index.js +0 -7
  189. package/templates/default/public/tinymce/plugins/media/plugin.js +0 -1442
  190. package/templates/default/public/tinymce/plugins/media/plugin.min.js +0 -1
  191. package/templates/default/public/tinymce/plugins/nonbreaking/index.js +0 -7
  192. package/templates/default/public/tinymce/plugins/nonbreaking/plugin.js +0 -128
  193. package/templates/default/public/tinymce/plugins/nonbreaking/plugin.min.js +0 -1
  194. package/templates/default/public/tinymce/plugins/pagebreak/index.js +0 -7
  195. package/templates/default/public/tinymce/plugins/pagebreak/plugin.js +0 -123
  196. package/templates/default/public/tinymce/plugins/pagebreak/plugin.min.js +0 -1
  197. package/templates/default/public/tinymce/plugins/preview/index.js +0 -7
  198. package/templates/default/public/tinymce/plugins/preview/plugin.js +0 -843
  199. package/templates/default/public/tinymce/plugins/preview/plugin.min.js +0 -1
  200. package/templates/default/public/tinymce/plugins/quickbars/index.js +0 -7
  201. package/templates/default/public/tinymce/plugins/quickbars/plugin.js +0 -654
  202. package/templates/default/public/tinymce/plugins/quickbars/plugin.min.js +0 -1
  203. package/templates/default/public/tinymce/plugins/save/index.js +0 -7
  204. package/templates/default/public/tinymce/plugins/save/plugin.js +0 -136
  205. package/templates/default/public/tinymce/plugins/save/plugin.min.js +0 -1
  206. package/templates/default/public/tinymce/plugins/searchreplace/index.js +0 -7
  207. package/templates/default/public/tinymce/plugins/searchreplace/plugin.js +0 -1367
  208. package/templates/default/public/tinymce/plugins/searchreplace/plugin.min.js +0 -1
  209. package/templates/default/public/tinymce/plugins/table/index.js +0 -7
  210. package/templates/default/public/tinymce/plugins/table/plugin.js +0 -4008
  211. package/templates/default/public/tinymce/plugins/table/plugin.min.js +0 -1
  212. package/templates/default/public/tinymce/plugins/visualblocks/index.js +0 -7
  213. package/templates/default/public/tinymce/plugins/visualblocks/plugin.js +0 -106
  214. package/templates/default/public/tinymce/plugins/visualblocks/plugin.min.js +0 -1
  215. package/templates/default/public/tinymce/plugins/visualchars/index.js +0 -7
  216. package/templates/default/public/tinymce/plugins/visualchars/plugin.js +0 -808
  217. package/templates/default/public/tinymce/plugins/visualchars/plugin.min.js +0 -1
  218. package/templates/default/public/tinymce/plugins/wordcount/index.js +0 -7
  219. package/templates/default/public/tinymce/plugins/wordcount/plugin.js +0 -480
  220. package/templates/default/public/tinymce/plugins/wordcount/plugin.min.js +0 -1
  221. package/templates/default/public/tinymce/skins/content/dark/content.css +0 -75
  222. package/templates/default/public/tinymce/skins/content/dark/content.js +0 -10
  223. package/templates/default/public/tinymce/skins/content/dark/content.min.css +0 -10
  224. package/templates/default/public/tinymce/skins/content/dark/content.min.ts +0 -3
  225. package/templates/default/public/tinymce/skins/content/dark/content.ts +0 -3
  226. package/templates/default/public/tinymce/skins/content/default/content.css +0 -70
  227. package/templates/default/public/tinymce/skins/content/default/content.js +0 -10
  228. package/templates/default/public/tinymce/skins/content/default/content.min.css +0 -10
  229. package/templates/default/public/tinymce/skins/content/default/content.min.ts +0 -3
  230. package/templates/default/public/tinymce/skins/content/default/content.ts +0 -3
  231. package/templates/default/public/tinymce/skins/content/document/content.css +0 -75
  232. package/templates/default/public/tinymce/skins/content/document/content.js +0 -10
  233. package/templates/default/public/tinymce/skins/content/document/content.min.css +0 -10
  234. package/templates/default/public/tinymce/skins/content/document/content.min.ts +0 -3
  235. package/templates/default/public/tinymce/skins/content/document/content.ts +0 -3
  236. package/templates/default/public/tinymce/skins/content/tinymce-5/content.css +0 -70
  237. package/templates/default/public/tinymce/skins/content/tinymce-5/content.js +0 -10
  238. package/templates/default/public/tinymce/skins/content/tinymce-5/content.min.css +0 -10
  239. package/templates/default/public/tinymce/skins/content/tinymce-5/content.min.ts +0 -3
  240. package/templates/default/public/tinymce/skins/content/tinymce-5/content.ts +0 -3
  241. package/templates/default/public/tinymce/skins/content/tinymce-5-dark/content.css +0 -75
  242. package/templates/default/public/tinymce/skins/content/tinymce-5-dark/content.js +0 -10
  243. package/templates/default/public/tinymce/skins/content/tinymce-5-dark/content.min.css +0 -10
  244. package/templates/default/public/tinymce/skins/content/tinymce-5-dark/content.min.ts +0 -3
  245. package/templates/default/public/tinymce/skins/content/tinymce-5-dark/content.ts +0 -3
  246. package/templates/default/public/tinymce/skins/content/writer/content.css +0 -71
  247. package/templates/default/public/tinymce/skins/content/writer/content.js +0 -10
  248. package/templates/default/public/tinymce/skins/content/writer/content.min.css +0 -10
  249. package/templates/default/public/tinymce/skins/content/writer/content.min.ts +0 -3
  250. package/templates/default/public/tinymce/skins/content/writer/content.ts +0 -3
  251. package/templates/default/public/tinymce/skins/ui/oxide/content.css +0 -1037
  252. package/templates/default/public/tinymce/skins/ui/oxide/content.inline.css +0 -1031
  253. package/templates/default/public/tinymce/skins/ui/oxide/content.inline.js +0 -10
  254. package/templates/default/public/tinymce/skins/ui/oxide/content.inline.min.css +0 -10
  255. package/templates/default/public/tinymce/skins/ui/oxide/content.inline.min.ts +0 -116
  256. package/templates/default/public/tinymce/skins/ui/oxide/content.inline.ts +0 -116
  257. package/templates/default/public/tinymce/skins/ui/oxide/content.js +0 -10
  258. package/templates/default/public/tinymce/skins/ui/oxide/content.min.css +0 -10
  259. package/templates/default/public/tinymce/skins/ui/oxide/content.min.ts +0 -116
  260. package/templates/default/public/tinymce/skins/ui/oxide/content.ts +0 -116
  261. package/templates/default/public/tinymce/skins/ui/oxide/skin.css +0 -5615
  262. package/templates/default/public/tinymce/skins/ui/oxide/skin.js +0 -1
  263. package/templates/default/public/tinymce/skins/ui/oxide/skin.min.css +0 -1
  264. package/templates/default/public/tinymce/skins/ui/oxide/skin.min.ts +0 -507
  265. package/templates/default/public/tinymce/skins/ui/oxide/skin.shadowdom.css +0 -30
  266. package/templates/default/public/tinymce/skins/ui/oxide/skin.shadowdom.js +0 -1
  267. package/templates/default/public/tinymce/skins/ui/oxide/skin.shadowdom.min.css +0 -1
  268. package/templates/default/public/tinymce/skins/ui/oxide/skin.shadowdom.min.ts +0 -9
  269. package/templates/default/public/tinymce/skins/ui/oxide/skin.shadowdom.ts +0 -9
  270. package/templates/default/public/tinymce/skins/ui/oxide/skin.ts +0 -507
  271. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.css +0 -1025
  272. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.inline.css +0 -1031
  273. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.inline.js +0 -10
  274. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.inline.min.css +0 -10
  275. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.inline.min.ts +0 -116
  276. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.inline.ts +0 -116
  277. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.js +0 -10
  278. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.min.css +0 -10
  279. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.min.ts +0 -116
  280. package/templates/default/public/tinymce/skins/ui/oxide-dark/content.ts +0 -116
  281. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.css +0 -5618
  282. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.js +0 -1
  283. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.min.css +0 -1
  284. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.min.ts +0 -507
  285. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.css +0 -30
  286. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.js +0 -1
  287. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.min.css +0 -1
  288. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.min.ts +0 -9
  289. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.shadowdom.ts +0 -9
  290. package/templates/default/public/tinymce/skins/ui/oxide-dark/skin.ts +0 -507
  291. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.css +0 -1037
  292. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.inline.css +0 -1031
  293. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.inline.js +0 -10
  294. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.inline.min.css +0 -10
  295. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.inline.min.ts +0 -116
  296. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.inline.ts +0 -116
  297. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.js +0 -10
  298. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.min.css +0 -10
  299. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.min.ts +0 -116
  300. package/templates/default/public/tinymce/skins/ui/tinymce-5/content.ts +0 -116
  301. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.css +0 -5734
  302. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.js +0 -1
  303. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.min.css +0 -1
  304. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.min.ts +0 -508
  305. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.css +0 -30
  306. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.js +0 -1
  307. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.min.css +0 -1
  308. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.min.ts +0 -9
  309. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.shadowdom.ts +0 -9
  310. package/templates/default/public/tinymce/skins/ui/tinymce-5/skin.ts +0 -508
  311. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.css +0 -1025
  312. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.inline.css +0 -1031
  313. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.inline.js +0 -10
  314. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.inline.min.css +0 -10
  315. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.inline.min.ts +0 -116
  316. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.inline.ts +0 -116
  317. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.js +0 -10
  318. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.min.css +0 -10
  319. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.min.ts +0 -116
  320. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/content.ts +0 -116
  321. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.css +0 -5734
  322. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.js +0 -1
  323. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.min.css +0 -1
  324. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.min.ts +0 -508
  325. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.css +0 -30
  326. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.js +0 -1
  327. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.min.css +0 -1
  328. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.min.ts +0 -9
  329. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.ts +0 -9
  330. package/templates/default/public/tinymce/skins/ui/tinymce-5-dark/skin.ts +0 -508
  331. package/templates/default/public/tinymce/themes/silver/index.js +0 -7
  332. package/templates/default/public/tinymce/themes/silver/theme.js +0 -34748
  333. package/templates/default/public/tinymce/themes/silver/theme.min.js +0 -1
  334. package/templates/default/public/tinymce/tinymce.d.ts +0 -3413
  335. package/templates/default/public/tinymce/tinymce.js +0 -41518
  336. package/templates/default/public/tinymce/tinymce.min.js +0 -10
@@ -1,843 +0,0 @@
1
- /**
2
- * TinyMCE version 8.3.1 (2025-12-17)
3
- */
4
-
5
- (function () {
6
- 'use strict';
7
-
8
- var global$2 = tinymce.util.Tools.resolve('tinymce.PluginManager');
9
-
10
- /* eslint-disable @typescript-eslint/no-wrapper-object-types */
11
- const isSimpleType = (type) => (value) => typeof value === type;
12
- const eq = (t) => (a) => t === a;
13
- const isUndefined = eq(undefined);
14
- const isNullable = (a) => a === null || a === undefined;
15
- const isNonNullable = (a) => !isNullable(a);
16
- const isFunction = isSimpleType('function');
17
-
18
- const constant = (value) => {
19
- return () => {
20
- return value;
21
- };
22
- };
23
- const identity = (x) => {
24
- return x;
25
- };
26
- const never = constant(false);
27
-
28
- /**
29
- * The `Optional` type represents a value (of any type) that potentially does
30
- * not exist. Any `Optional<T>` can either be a `Some<T>` (in which case the
31
- * value does exist) or a `None` (in which case the value does not exist). This
32
- * module defines a whole lot of FP-inspired utility functions for dealing with
33
- * `Optional` objects.
34
- *
35
- * Comparison with null or undefined:
36
- * - We don't get fancy null coalescing operators with `Optional`
37
- * - We do get fancy helper functions with `Optional`
38
- * - `Optional` support nesting, and allow for the type to still be nullable (or
39
- * another `Optional`)
40
- * - There is no option to turn off strict-optional-checks like there is for
41
- * strict-null-checks
42
- */
43
- class Optional {
44
- tag;
45
- value;
46
- // Sneaky optimisation: every instance of Optional.none is identical, so just
47
- // reuse the same object
48
- static singletonNone = new Optional(false);
49
- // The internal representation has a `tag` and a `value`, but both are
50
- // private: able to be console.logged, but not able to be accessed by code
51
- constructor(tag, value) {
52
- this.tag = tag;
53
- this.value = value;
54
- }
55
- // --- Identities ---
56
- /**
57
- * Creates a new `Optional<T>` that **does** contain a value.
58
- */
59
- static some(value) {
60
- return new Optional(true, value);
61
- }
62
- /**
63
- * Create a new `Optional<T>` that **does not** contain a value. `T` can be
64
- * any type because we don't actually have a `T`.
65
- */
66
- static none() {
67
- return Optional.singletonNone;
68
- }
69
- /**
70
- * Perform a transform on an `Optional` type. Regardless of whether this
71
- * `Optional` contains a value or not, `fold` will return a value of type `U`.
72
- * If this `Optional` does not contain a value, the `U` will be created by
73
- * calling `onNone`. If this `Optional` does contain a value, the `U` will be
74
- * created by calling `onSome`.
75
- *
76
- * For the FP enthusiasts in the room, this function:
77
- * 1. Could be used to implement all of the functions below
78
- * 2. Forms a catamorphism
79
- */
80
- fold(onNone, onSome) {
81
- if (this.tag) {
82
- return onSome(this.value);
83
- }
84
- else {
85
- return onNone();
86
- }
87
- }
88
- /**
89
- * Determine if this `Optional` object contains a value.
90
- */
91
- isSome() {
92
- return this.tag;
93
- }
94
- /**
95
- * Determine if this `Optional` object **does not** contain a value.
96
- */
97
- isNone() {
98
- return !this.tag;
99
- }
100
- // --- Functor (name stolen from Haskell / maths) ---
101
- /**
102
- * Perform a transform on an `Optional` object, **if** there is a value. If
103
- * you provide a function to turn a T into a U, this is the function you use
104
- * to turn an `Optional<T>` into an `Optional<U>`. If this **does** contain
105
- * a value then the output will also contain a value (that value being the
106
- * output of `mapper(this.value)`), and if this **does not** contain a value
107
- * then neither will the output.
108
- */
109
- map(mapper) {
110
- if (this.tag) {
111
- return Optional.some(mapper(this.value));
112
- }
113
- else {
114
- return Optional.none();
115
- }
116
- }
117
- // --- Monad (name stolen from Haskell / maths) ---
118
- /**
119
- * Perform a transform on an `Optional` object, **if** there is a value.
120
- * Unlike `map`, here the transform itself also returns an `Optional`.
121
- */
122
- bind(binder) {
123
- if (this.tag) {
124
- return binder(this.value);
125
- }
126
- else {
127
- return Optional.none();
128
- }
129
- }
130
- // --- Traversable (name stolen from Haskell / maths) ---
131
- /**
132
- * For a given predicate, this function finds out if there **exists** a value
133
- * inside this `Optional` object that meets the predicate. In practice, this
134
- * means that for `Optional`s that do not contain a value it returns false (as
135
- * no predicate-meeting value exists).
136
- */
137
- exists(predicate) {
138
- return this.tag && predicate(this.value);
139
- }
140
- /**
141
- * For a given predicate, this function finds out if **all** the values inside
142
- * this `Optional` object meet the predicate. In practice, this means that
143
- * for `Optional`s that do not contain a value it returns true (as all 0
144
- * objects do meet the predicate).
145
- */
146
- forall(predicate) {
147
- return !this.tag || predicate(this.value);
148
- }
149
- filter(predicate) {
150
- if (!this.tag || predicate(this.value)) {
151
- return this;
152
- }
153
- else {
154
- return Optional.none();
155
- }
156
- }
157
- // --- Getters ---
158
- /**
159
- * Get the value out of the inside of the `Optional` object, using a default
160
- * `replacement` value if the provided `Optional` object does not contain a
161
- * value.
162
- */
163
- getOr(replacement) {
164
- return this.tag ? this.value : replacement;
165
- }
166
- /**
167
- * Get the value out of the inside of the `Optional` object, using a default
168
- * `replacement` value if the provided `Optional` object does not contain a
169
- * value. Unlike `getOr`, in this method the `replacement` object is also
170
- * `Optional` - meaning that this method will always return an `Optional`.
171
- */
172
- or(replacement) {
173
- return this.tag ? this : replacement;
174
- }
175
- /**
176
- * Get the value out of the inside of the `Optional` object, using a default
177
- * `replacement` value if the provided `Optional` object does not contain a
178
- * value. Unlike `getOr`, in this method the `replacement` value is
179
- * "thunked" - that is to say that you don't pass a value to `getOrThunk`, you
180
- * pass a function which (if called) will **return** the `value` you want to
181
- * use.
182
- */
183
- getOrThunk(thunk) {
184
- return this.tag ? this.value : thunk();
185
- }
186
- /**
187
- * Get the value out of the inside of the `Optional` object, using a default
188
- * `replacement` value if the provided Optional object does not contain a
189
- * value.
190
- *
191
- * Unlike `or`, in this method the `replacement` value is "thunked" - that is
192
- * to say that you don't pass a value to `orThunk`, you pass a function which
193
- * (if called) will **return** the `value` you want to use.
194
- *
195
- * Unlike `getOrThunk`, in this method the `replacement` value is also
196
- * `Optional`, meaning that this method will always return an `Optional`.
197
- */
198
- orThunk(thunk) {
199
- return this.tag ? this : thunk();
200
- }
201
- /**
202
- * Get the value out of the inside of the `Optional` object, throwing an
203
- * exception if the provided `Optional` object does not contain a value.
204
- *
205
- * WARNING:
206
- * You should only be using this function if you know that the `Optional`
207
- * object **is not** empty (otherwise you're throwing exceptions in production
208
- * code, which is bad).
209
- *
210
- * In tests this is more acceptable.
211
- *
212
- * Prefer other methods to this, such as `.each`.
213
- */
214
- getOrDie(message) {
215
- if (!this.tag) {
216
- throw new Error(message ?? 'Called getOrDie on None');
217
- }
218
- else {
219
- return this.value;
220
- }
221
- }
222
- // --- Interop with null and undefined ---
223
- /**
224
- * Creates an `Optional` value from a nullable (or undefined-able) input.
225
- * Null, or undefined, is converted to `None`, and anything else is converted
226
- * to `Some`.
227
- */
228
- static from(value) {
229
- return isNonNullable(value) ? Optional.some(value) : Optional.none();
230
- }
231
- /**
232
- * Converts an `Optional` to a nullable type, by getting the value if it
233
- * exists, or returning `null` if it does not.
234
- */
235
- getOrNull() {
236
- return this.tag ? this.value : null;
237
- }
238
- /**
239
- * Converts an `Optional` to an undefined-able type, by getting the value if
240
- * it exists, or returning `undefined` if it does not.
241
- */
242
- getOrUndefined() {
243
- return this.value;
244
- }
245
- // --- Utilities ---
246
- /**
247
- * If the `Optional` contains a value, perform an action on that value.
248
- * Unlike the rest of the methods on this type, `.each` has side-effects. If
249
- * you want to transform an `Optional<T>` **into** something, then this is not
250
- * the method for you. If you want to use an `Optional<T>` to **do**
251
- * something, then this is the method for you - provided you're okay with not
252
- * doing anything in the case where the `Optional` doesn't have a value inside
253
- * it. If you're not sure whether your use-case fits into transforming
254
- * **into** something or **doing** something, check whether it has a return
255
- * value. If it does, you should be performing a transform.
256
- */
257
- each(worker) {
258
- if (this.tag) {
259
- worker(this.value);
260
- }
261
- }
262
- /**
263
- * Turn the `Optional` object into an array that contains all of the values
264
- * stored inside the `Optional`. In practice, this means the output will have
265
- * either 0 or 1 elements.
266
- */
267
- toArray() {
268
- return this.tag ? [this.value] : [];
269
- }
270
- /**
271
- * Turn the `Optional` object into a string for debugging or printing. Not
272
- * recommended for production code, but good for debugging. Also note that
273
- * these days an `Optional` object can be logged to the console directly, and
274
- * its inner value (if it exists) will be visible.
275
- */
276
- toString() {
277
- return this.tag ? `some(${this.value})` : 'none()';
278
- }
279
- }
280
-
281
- const nativeSlice = Array.prototype.slice;
282
- const nativeIndexOf = Array.prototype.indexOf;
283
- const rawIndexOf = (ts, t) => nativeIndexOf.call(ts, t);
284
- const contains$1 = (xs, x) => rawIndexOf(xs, x) > -1;
285
- const exists = (xs, pred) => {
286
- for (let i = 0, len = xs.length; i < len; i++) {
287
- const x = xs[i];
288
- if (pred(x, i)) {
289
- return true;
290
- }
291
- }
292
- return false;
293
- };
294
- const map = (xs, f) => {
295
- // pre-allocating array size when it's guaranteed to be known
296
- // http://jsperf.com/push-allocated-vs-dynamic/22
297
- const len = xs.length;
298
- const r = new Array(len);
299
- for (let i = 0; i < len; i++) {
300
- const x = xs[i];
301
- r[i] = f(x, i);
302
- }
303
- return r;
304
- };
305
- const findUntil = (xs, pred, until) => {
306
- for (let i = 0, len = xs.length; i < len; i++) {
307
- const x = xs[i];
308
- if (pred(x, i)) {
309
- return Optional.some(x);
310
- }
311
- else if (until(x, i)) {
312
- break;
313
- }
314
- }
315
- return Optional.none();
316
- };
317
- const find$1 = (xs, pred) => {
318
- return findUntil(xs, pred, never);
319
- };
320
- isFunction(Array.from) ? Array.from : (x) => nativeSlice.call(x);
321
- const findMap = (arr, f) => {
322
- for (let i = 0; i < arr.length; i++) {
323
- const r = f(arr[i], i);
324
- if (r.isSome()) {
325
- return r;
326
- }
327
- }
328
- return Optional.none();
329
- };
330
- const unique = (xs, comparator) => {
331
- const r = [];
332
- const isDuplicated = isFunction(comparator) ?
333
- (x) => exists(r, (i) => comparator(i, x)) :
334
- (x) => contains$1(r, x);
335
- for (let i = 0, len = xs.length; i < len; i++) {
336
- const x = xs[i];
337
- if (!isDuplicated(x)) {
338
- r.push(x);
339
- }
340
- }
341
- return r;
342
- };
343
-
344
- // There are many variations of Object iteration that are faster than the 'for-in' style:
345
- // http://jsperf.com/object-keys-iteration/107
346
- //
347
- // Use the native keys if it is available (IE9+), otherwise fall back to manually filtering
348
- const keys = Object.keys;
349
- const each = (obj, f) => {
350
- const props = keys(obj);
351
- for (let k = 0, len = props.length; k < len; k++) {
352
- const i = props[k];
353
- const x = obj[i];
354
- f(x, i);
355
- }
356
- };
357
- const mapToArray = (obj, f) => {
358
- const r = [];
359
- each(obj, (value, name) => {
360
- r.push(f(value, name));
361
- });
362
- return r;
363
- };
364
- const values = (obj) => {
365
- return mapToArray(obj, identity);
366
- };
367
-
368
- const contains = (str, substr, start = 0, end) => {
369
- const idx = str.indexOf(substr, start);
370
- if (idx !== -1) {
371
- return isUndefined(end) ? true : idx + substr.length <= end;
372
- }
373
- else {
374
- return false;
375
- }
376
- };
377
-
378
- const cached = (f) => {
379
- let called = false;
380
- let r;
381
- return (...args) => {
382
- if (!called) {
383
- called = true;
384
- r = f.apply(null, args);
385
- }
386
- return r;
387
- };
388
- };
389
-
390
- const DeviceType = (os, browser, userAgent, mediaMatch) => {
391
- const isiPad = os.isiOS() && /ipad/i.test(userAgent) === true;
392
- const isiPhone = os.isiOS() && !isiPad;
393
- const isMobile = os.isiOS() || os.isAndroid();
394
- const isTouch = isMobile || mediaMatch('(pointer:coarse)');
395
- const isTablet = isiPad || !isiPhone && isMobile && mediaMatch('(min-device-width:768px)');
396
- const isPhone = isiPhone || isMobile && !isTablet;
397
- const iOSwebview = browser.isSafari() && os.isiOS() && /safari/i.test(userAgent) === false;
398
- const isDesktop = !isPhone && !isTablet && !iOSwebview;
399
- return {
400
- isiPad: constant(isiPad),
401
- isiPhone: constant(isiPhone),
402
- isTablet: constant(isTablet),
403
- isPhone: constant(isPhone),
404
- isTouch: constant(isTouch),
405
- isAndroid: os.isAndroid,
406
- isiOS: os.isiOS,
407
- isWebView: constant(iOSwebview),
408
- isDesktop: constant(isDesktop)
409
- };
410
- };
411
-
412
- const firstMatch = (regexes, s) => {
413
- for (let i = 0; i < regexes.length; i++) {
414
- const x = regexes[i];
415
- if (x.test(s)) {
416
- return x;
417
- }
418
- }
419
- return undefined;
420
- };
421
- const find = (regexes, agent) => {
422
- const r = firstMatch(regexes, agent);
423
- if (!r) {
424
- return { major: 0, minor: 0 };
425
- }
426
- const group = (i) => {
427
- return Number(agent.replace(r, '$' + i));
428
- };
429
- return nu$2(group(1), group(2));
430
- };
431
- const detect$3 = (versionRegexes, agent) => {
432
- const cleanedAgent = String(agent).toLowerCase();
433
- if (versionRegexes.length === 0) {
434
- return unknown$2();
435
- }
436
- return find(versionRegexes, cleanedAgent);
437
- };
438
- const unknown$2 = () => {
439
- return nu$2(0, 0);
440
- };
441
- const nu$2 = (major, minor) => {
442
- return { major, minor };
443
- };
444
- const Version = {
445
- nu: nu$2,
446
- detect: detect$3,
447
- unknown: unknown$2
448
- };
449
-
450
- const detectBrowser$1 = (browsers, userAgentData) => {
451
- return findMap(userAgentData.brands, (uaBrand) => {
452
- const lcBrand = uaBrand.brand.toLowerCase();
453
- return find$1(browsers, (browser) => lcBrand === browser.brand?.toLowerCase())
454
- .map((info) => ({
455
- current: info.name,
456
- version: Version.nu(parseInt(uaBrand.version, 10), 0)
457
- }));
458
- });
459
- };
460
-
461
- const detect$2 = (candidates, userAgent) => {
462
- const agent = String(userAgent).toLowerCase();
463
- return find$1(candidates, (candidate) => {
464
- return candidate.search(agent);
465
- });
466
- };
467
- // They (browser and os) are the same at the moment, but they might
468
- // not stay that way.
469
- const detectBrowser = (browsers, userAgent) => {
470
- return detect$2(browsers, userAgent).map((browser) => {
471
- const version = Version.detect(browser.versionRegexes, userAgent);
472
- return {
473
- current: browser.name,
474
- version
475
- };
476
- });
477
- };
478
- const detectOs = (oses, userAgent) => {
479
- return detect$2(oses, userAgent).map((os) => {
480
- const version = Version.detect(os.versionRegexes, userAgent);
481
- return {
482
- current: os.name,
483
- version
484
- };
485
- });
486
- };
487
-
488
- const normalVersionRegex = /.*?version\/\ ?([0-9]+)\.([0-9]+).*/;
489
- const checkContains = (target) => {
490
- return (uastring) => {
491
- return contains(uastring, target);
492
- };
493
- };
494
- const browsers = [
495
- // This is legacy Edge
496
- {
497
- name: 'Edge',
498
- versionRegexes: [/.*?edge\/ ?([0-9]+)\.([0-9]+)$/],
499
- search: (uastring) => {
500
- return contains(uastring, 'edge/') && contains(uastring, 'chrome') && contains(uastring, 'safari') && contains(uastring, 'applewebkit');
501
- }
502
- },
503
- // This is Google Chrome and Chromium Edge
504
- {
505
- name: 'Chromium',
506
- brand: 'Chromium',
507
- versionRegexes: [/.*?chrome\/([0-9]+)\.([0-9]+).*/, normalVersionRegex],
508
- search: (uastring) => {
509
- return contains(uastring, 'chrome') && !contains(uastring, 'chromeframe');
510
- }
511
- },
512
- {
513
- name: 'IE',
514
- versionRegexes: [/.*?msie\ ?([0-9]+)\.([0-9]+).*/, /.*?rv:([0-9]+)\.([0-9]+).*/],
515
- search: (uastring) => {
516
- return contains(uastring, 'msie') || contains(uastring, 'trident');
517
- }
518
- },
519
- // INVESTIGATE: Is this still the Opera user agent?
520
- {
521
- name: 'Opera',
522
- versionRegexes: [normalVersionRegex, /.*?opera\/([0-9]+)\.([0-9]+).*/],
523
- search: checkContains('opera')
524
- },
525
- {
526
- name: 'Firefox',
527
- versionRegexes: [/.*?firefox\/\ ?([0-9]+)\.([0-9]+).*/],
528
- search: checkContains('firefox')
529
- },
530
- {
531
- name: 'Safari',
532
- versionRegexes: [normalVersionRegex, /.*?cpu os ([0-9]+)_([0-9]+).*/],
533
- search: (uastring) => {
534
- return (contains(uastring, 'safari') || contains(uastring, 'mobile/')) && contains(uastring, 'applewebkit');
535
- }
536
- }
537
- ];
538
- const oses = [
539
- {
540
- name: 'Windows',
541
- search: checkContains('win'),
542
- versionRegexes: [/.*?windows\ nt\ ?([0-9]+)\.([0-9]+).*/]
543
- },
544
- {
545
- name: 'iOS',
546
- search: (uastring) => {
547
- return contains(uastring, 'iphone') || contains(uastring, 'ipad');
548
- },
549
- versionRegexes: [/.*?version\/\ ?([0-9]+)\.([0-9]+).*/, /.*cpu os ([0-9]+)_([0-9]+).*/, /.*cpu iphone os ([0-9]+)_([0-9]+).*/]
550
- },
551
- {
552
- name: 'Android',
553
- search: checkContains('android'),
554
- versionRegexes: [/.*?android\ ?([0-9]+)\.([0-9]+).*/]
555
- },
556
- {
557
- name: 'macOS',
558
- search: checkContains('mac os x'),
559
- versionRegexes: [/.*?mac\ os\ x\ ?([0-9]+)_([0-9]+).*/]
560
- },
561
- {
562
- name: 'Linux',
563
- search: checkContains('linux'),
564
- versionRegexes: []
565
- },
566
- { name: 'Solaris',
567
- search: checkContains('sunos'),
568
- versionRegexes: []
569
- },
570
- {
571
- name: 'FreeBSD',
572
- search: checkContains('freebsd'),
573
- versionRegexes: []
574
- },
575
- {
576
- name: 'ChromeOS',
577
- search: checkContains('cros'),
578
- versionRegexes: [/.*?chrome\/([0-9]+)\.([0-9]+).*/]
579
- }
580
- ];
581
- const PlatformInfo = {
582
- browsers: constant(browsers),
583
- oses: constant(oses)
584
- };
585
-
586
- const edge = 'Edge';
587
- const chromium = 'Chromium';
588
- const ie = 'IE';
589
- const opera = 'Opera';
590
- const firefox = 'Firefox';
591
- const safari = 'Safari';
592
- const unknown$1 = () => {
593
- return nu$1({
594
- current: undefined,
595
- version: Version.unknown()
596
- });
597
- };
598
- const nu$1 = (info) => {
599
- const current = info.current;
600
- const version = info.version;
601
- const isBrowser = (name) => () => current === name;
602
- return {
603
- current,
604
- version,
605
- isEdge: isBrowser(edge),
606
- isChromium: isBrowser(chromium),
607
- // NOTE: isIe just looks too weird
608
- isIE: isBrowser(ie),
609
- isOpera: isBrowser(opera),
610
- isFirefox: isBrowser(firefox),
611
- isSafari: isBrowser(safari)
612
- };
613
- };
614
- const Browser = {
615
- unknown: unknown$1,
616
- nu: nu$1,
617
- edge: constant(edge),
618
- chromium: constant(chromium),
619
- ie: constant(ie),
620
- opera: constant(opera),
621
- firefox: constant(firefox),
622
- safari: constant(safari)
623
- };
624
-
625
- const windows = 'Windows';
626
- const ios = 'iOS';
627
- const android = 'Android';
628
- const linux = 'Linux';
629
- const macos = 'macOS';
630
- const solaris = 'Solaris';
631
- const freebsd = 'FreeBSD';
632
- const chromeos = 'ChromeOS';
633
- // Though there is a bit of dupe with this and Browser, trying to
634
- // reuse code makes it much harder to follow and change.
635
- const unknown = () => {
636
- return nu({
637
- current: undefined,
638
- version: Version.unknown()
639
- });
640
- };
641
- const nu = (info) => {
642
- const current = info.current;
643
- const version = info.version;
644
- const isOS = (name) => () => current === name;
645
- return {
646
- current,
647
- version,
648
- isWindows: isOS(windows),
649
- // TODO: Fix capitalisation
650
- isiOS: isOS(ios),
651
- isAndroid: isOS(android),
652
- isMacOS: isOS(macos),
653
- isLinux: isOS(linux),
654
- isSolaris: isOS(solaris),
655
- isFreeBSD: isOS(freebsd),
656
- isChromeOS: isOS(chromeos)
657
- };
658
- };
659
- const OperatingSystem = {
660
- unknown,
661
- nu,
662
- windows: constant(windows),
663
- ios: constant(ios),
664
- android: constant(android),
665
- linux: constant(linux),
666
- macos: constant(macos),
667
- solaris: constant(solaris),
668
- freebsd: constant(freebsd),
669
- chromeos: constant(chromeos)
670
- };
671
-
672
- const detect$1 = (userAgent, userAgentDataOpt, mediaMatch) => {
673
- const browsers = PlatformInfo.browsers();
674
- const oses = PlatformInfo.oses();
675
- const browser = userAgentDataOpt.bind((userAgentData) => detectBrowser$1(browsers, userAgentData))
676
- .orThunk(() => detectBrowser(browsers, userAgent))
677
- .fold(Browser.unknown, Browser.nu);
678
- const os = detectOs(oses, userAgent).fold(OperatingSystem.unknown, OperatingSystem.nu);
679
- const deviceType = DeviceType(os, browser, userAgent, mediaMatch);
680
- return {
681
- browser,
682
- os,
683
- deviceType
684
- };
685
- };
686
- const PlatformDetection = {
687
- detect: detect$1
688
- };
689
-
690
- const mediaMatch = (query) => window.matchMedia(query).matches;
691
- // IMPORTANT: Must be in a thunk, otherwise rollup thinks calling this immediately
692
- // causes side effects and won't tree shake this away
693
- // Note: navigator.userAgentData is not part of the native typescript types yet
694
- let platform = cached(() => PlatformDetection.detect(window.navigator.userAgent, Optional.from((window.navigator.userAgentData)), mediaMatch));
695
- const detect = () => platform();
696
-
697
- const isMacOS = () => detect().os.isMacOS();
698
- const isiOS = () => detect().os.isiOS();
699
-
700
- const getPreventClicksOnLinksScript = () => {
701
- const isMacOSOrIOS = isMacOS() || isiOS();
702
- const fn = (isMacOSOrIOS) => {
703
- document.addEventListener('click', (e) => {
704
- for (let elm = e.target; elm; elm = elm.parentNode) {
705
- if (elm.nodeName === 'A') {
706
- const anchor = elm;
707
- const href = anchor.getAttribute('href');
708
- if (href && href.startsWith('#')) {
709
- e.preventDefault();
710
- const targetElement = document.getElementById(href.substring(1));
711
- if (targetElement) {
712
- targetElement.scrollIntoView({ behavior: 'smooth' });
713
- }
714
- return;
715
- }
716
- const isMetaKeyPressed = isMacOSOrIOS ? e.metaKey : e.ctrlKey && !e.altKey;
717
- if (!isMetaKeyPressed) {
718
- e.preventDefault();
719
- }
720
- }
721
- }
722
- }, false);
723
- };
724
- return `<script>(${fn.toString()})(${isMacOSOrIOS})</script>`;
725
- };
726
-
727
- var global$1 = tinymce.util.Tools.resolve('tinymce.dom.ScriptLoader');
728
-
729
- var global = tinymce.util.Tools.resolve('tinymce.util.Tools');
730
-
731
- const option = (name) => (editor) => editor.options.get(name);
732
- const getContentStyle = option('content_style');
733
- const shouldUseContentCssCors = option('content_css_cors');
734
- const getBodyClass = option('body_class');
735
- const getBodyId = option('body_id');
736
-
737
- const getComponentScriptsHtml = (editor) => {
738
- const urls = unique(values(editor.schema.getComponentUrls()));
739
- return map(urls, (url) => {
740
- const attrs = mapToArray(global$1.ScriptLoader.getScriptAttributes(url), (v, k) => ` ${editor.dom.encode(k)}="${editor.dom.encode(v)}"`);
741
- return `<script src="${editor.dom.encode(url)}"${attrs.join('')}></script>`;
742
- }).join('');
743
- };
744
- const getPreviewHtml = (editor) => {
745
- let headHtml = '';
746
- const encode = editor.dom.encode;
747
- const contentStyle = getContentStyle(editor) ?? '';
748
- headHtml += `<base href="${encode(editor.documentBaseURI.getURI())}">`;
749
- const cors = shouldUseContentCssCors(editor) ? ' crossorigin="anonymous"' : '';
750
- global.each(editor.contentCSS, (url) => {
751
- headHtml += '<link type="text/css" rel="stylesheet" href="' + encode(editor.documentBaseURI.toAbsolute(url)) + '"' + cors + '>';
752
- });
753
- if (contentStyle) {
754
- headHtml += '<style type="text/css">' + contentStyle + '</style>';
755
- }
756
- headHtml += getComponentScriptsHtml(editor);
757
- const bodyId = getBodyId(editor);
758
- const bodyClass = getBodyClass(editor);
759
- const directionality = editor.getBody().dir;
760
- const dirAttr = directionality ? ' dir="' + encode(directionality) + '"' : '';
761
- const previewHtml = ('<!DOCTYPE html>' +
762
- '<html>' +
763
- '<head>' +
764
- headHtml +
765
- '</head>' +
766
- '<body id="' + encode(bodyId) + '" class="mce-content-body ' + encode(bodyClass) + '"' + dirAttr + '>' +
767
- editor.getContent() +
768
- getPreventClicksOnLinksScript() +
769
- '</body>' +
770
- '</html>');
771
- return previewHtml;
772
- };
773
-
774
- const open = (editor) => {
775
- const content = getPreviewHtml(editor);
776
- const dataApi = editor.windowManager.open({
777
- title: 'Preview',
778
- size: 'large',
779
- body: {
780
- type: 'panel',
781
- items: [
782
- {
783
- name: 'preview',
784
- type: 'iframe',
785
- sandboxed: true,
786
- transparent: false
787
- }
788
- ]
789
- },
790
- buttons: [
791
- {
792
- type: 'cancel',
793
- name: 'close',
794
- text: 'Close',
795
- primary: true
796
- }
797
- ],
798
- initialData: {
799
- preview: content
800
- }
801
- });
802
- // Focus the close button, as by default the first element in the body is selected
803
- // which we don't want to happen here since the body only has the iframe content
804
- dataApi.focus('close');
805
- };
806
-
807
- const register$1 = (editor) => {
808
- editor.addCommand('mcePreview', () => {
809
- open(editor);
810
- });
811
- };
812
-
813
- const register = (editor) => {
814
- const onAction = () => editor.execCommand('mcePreview');
815
- editor.ui.registry.addButton('preview', {
816
- icon: 'preview',
817
- tooltip: 'Preview',
818
- onAction,
819
- context: 'any'
820
- });
821
- editor.ui.registry.addMenuItem('preview', {
822
- icon: 'preview',
823
- text: 'Preview',
824
- onAction,
825
- context: 'any'
826
- });
827
- };
828
-
829
- var Plugin = () => {
830
- global$2.add('preview', (editor) => {
831
- register$1(editor);
832
- register(editor);
833
- });
834
- };
835
-
836
- Plugin();
837
- /** *****
838
- * DO NOT EXPORT ANYTHING
839
- *
840
- * IF YOU DO ROLLUP WILL LEAVE A GLOBAL ON THE PAGE
841
- *******/
842
-
843
- })();