@paroicms/server 0.150.0 → 0.151.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (570) hide show
  1. package/README.md +10 -7
  2. package/package.json +17 -8
  3. package/dist/cli.d.ts +0 -2
  4. package/dist/cli.js +0 -5
  5. package/dist/cli.js.map +0 -1
  6. package/dist/common/child-ordering-query.d.ts +0 -13
  7. package/dist/common/child-ordering-query.js +0 -107
  8. package/dist/common/child-ordering-query.js.map +0 -1
  9. package/dist/common/data-format.d.ts +0 -19
  10. package/dist/common/data-format.js +0 -86
  11. package/dist/common/data-format.js.map +0 -1
  12. package/dist/common/mail/html-helpers.d.ts +0 -7
  13. package/dist/common/mail/html-helpers.js +0 -46
  14. package/dist/common/mail/html-helpers.js.map +0 -1
  15. package/dist/common/mail/sendMail.helpers.d.ts +0 -14
  16. package/dist/common/mail/sendMail.helpers.js +0 -51
  17. package/dist/common/mail/sendMail.helpers.js.map +0 -1
  18. package/dist/common/media-handles.helpers.d.ts +0 -19
  19. package/dist/common/media-handles.helpers.js +0 -52
  20. package/dist/common/media-handles.helpers.js.map +0 -1
  21. package/dist/common/serve-html-or.d.ts +0 -16
  22. package/dist/common/serve-html-or.js +0 -72
  23. package/dist/common/serve-html-or.js.map +0 -1
  24. package/dist/common/text-cache.d.ts +0 -57
  25. package/dist/common/text-cache.js +0 -87
  26. package/dist/common/text-cache.js.map +0 -1
  27. package/dist/common/tracker-report.d.ts +0 -2
  28. package/dist/common/tracker-report.js +0 -27
  29. package/dist/common/tracker-report.js.map +0 -1
  30. package/dist/context.d.ts +0 -29
  31. package/dist/context.js +0 -60
  32. package/dist/context.js.map +0 -1
  33. package/dist/express/http-helpers.d.ts +0 -16
  34. package/dist/express/http-helpers.js +0 -44
  35. package/dist/express/http-helpers.js.map +0 -1
  36. package/dist/express/static-middlewares.d.ts +0 -3
  37. package/dist/express/static-middlewares.js +0 -114
  38. package/dist/express/static-middlewares.js.map +0 -1
  39. package/dist/helpers/configuration.helpers.d.ts +0 -2
  40. package/dist/helpers/configuration.helpers.js +0 -8
  41. package/dist/helpers/configuration.helpers.js.map +0 -1
  42. package/dist/helpers/excerpt.helpers.d.ts +0 -2
  43. package/dist/helpers/excerpt.helpers.js +0 -31
  44. package/dist/helpers/excerpt.helpers.js.map +0 -1
  45. package/dist/helpers/jwt-secret.helpers.d.ts +0 -2
  46. package/dist/helpers/jwt-secret.helpers.js +0 -30
  47. package/dist/helpers/jwt-secret.helpers.js.map +0 -1
  48. package/dist/helpers/label-translator.helper.d.ts +0 -9
  49. package/dist/helpers/label-translator.helper.js +0 -14
  50. package/dist/helpers/label-translator.helper.js.map +0 -1
  51. package/dist/helpers/passwordEncrypt-helper.d.ts +0 -2
  52. package/dist/helpers/passwordEncrypt-helper.js +0 -37
  53. package/dist/helpers/passwordEncrypt-helper.js.map +0 -1
  54. package/dist/helpers/relative-id-helper.d.ts +0 -10
  55. package/dist/helpers/relative-id-helper.js +0 -37
  56. package/dist/helpers/relative-id-helper.js.map +0 -1
  57. package/dist/helpers/simple-i18n.d.ts +0 -14
  58. package/dist/helpers/simple-i18n.js +0 -82
  59. package/dist/helpers/simple-i18n.js.map +0 -1
  60. package/dist/helpers/special-account.helpers.d.ts +0 -9
  61. package/dist/helpers/special-account.helpers.js +0 -43
  62. package/dist/helpers/special-account.helpers.js.map +0 -1
  63. package/dist/helpers/url.helpers.d.ts +0 -2
  64. package/dist/helpers/url.helpers.js +0 -12
  65. package/dist/helpers/url.helpers.js.map +0 -1
  66. package/dist/helpers/utils-helper.d.ts +0 -4
  67. package/dist/helpers/utils-helper.js +0 -32
  68. package/dist/helpers/utils-helper.js.map +0 -1
  69. package/dist/index.d.ts +0 -7
  70. package/dist/index.js +0 -69
  71. package/dist/index.js.map +0 -1
  72. package/dist/liquidjs-tools/liquidjs-drop.d.ts +0 -31
  73. package/dist/liquidjs-tools/liquidjs-drop.js +0 -45
  74. package/dist/liquidjs-tools/liquidjs-drop.js.map +0 -1
  75. package/dist/liquidjs-tools/liquidjs-filter.d.ts +0 -10
  76. package/dist/liquidjs-tools/liquidjs-filter.js +0 -23
  77. package/dist/liquidjs-tools/liquidjs-filter.js.map +0 -1
  78. package/dist/liquidjs-tools/liquidjs-rendering/render-liquidjs.d.ts +0 -6
  79. package/dist/liquidjs-tools/liquidjs-rendering/render-liquidjs.js +0 -40
  80. package/dist/liquidjs-tools/liquidjs-rendering/render-liquidjs.js.map +0 -1
  81. package/dist/liquidjs-tools/liquidjs-rendering/rendering-context.d.ts +0 -25
  82. package/dist/liquidjs-tools/liquidjs-rendering/rendering-context.js +0 -35
  83. package/dist/liquidjs-tools/liquidjs-rendering/rendering-context.js.map +0 -1
  84. package/dist/liquidjs-tools/liquidjs-utils.d.ts +0 -5
  85. package/dist/liquidjs-tools/liquidjs-utils.js +0 -22
  86. package/dist/liquidjs-tools/liquidjs-utils.js.map +0 -1
  87. package/dist/liquidjs-tools/render-clone/collection.d.ts +0 -1
  88. package/dist/liquidjs-tools/render-clone/collection.js +0 -18
  89. package/dist/liquidjs-tools/render-clone/collection.js.map +0 -1
  90. package/dist/liquidjs-tools/render-clone/forloop-drop.d.ts +0 -15
  91. package/dist/liquidjs-tools/render-clone/forloop-drop.js +0 -40
  92. package/dist/liquidjs-tools/render-clone/forloop-drop.js.map +0 -1
  93. package/dist/liquidjs-tools/render-clone/render.d.ts +0 -13
  94. package/dist/liquidjs-tools/render-clone/render.js +0 -108
  95. package/dist/liquidjs-tools/render-clone/render.js.map +0 -1
  96. package/dist/maintenance/maintenance-task.d.ts +0 -4
  97. package/dist/maintenance/maintenance-task.js +0 -27
  98. package/dist/maintenance/maintenance-task.js.map +0 -1
  99. package/dist/maintenance/shutdown.d.ts +0 -7
  100. package/dist/maintenance/shutdown.js +0 -51
  101. package/dist/maintenance/shutdown.js.map +0 -1
  102. package/dist/modules/app.controller.d.ts +0 -5
  103. package/dist/modules/app.controller.js +0 -89
  104. package/dist/modules/app.controller.js.map +0 -1
  105. package/dist/modules/app.module.d.ts +0 -2
  106. package/dist/modules/app.module.js +0 -48
  107. package/dist/modules/app.module.js.map +0 -1
  108. package/dist/modules/core/account/account.model.d.ts +0 -18
  109. package/dist/modules/core/account/account.model.js +0 -59
  110. package/dist/modules/core/account/account.model.js.map +0 -1
  111. package/dist/modules/core/account/account.module.d.ts +0 -2
  112. package/dist/modules/core/account/account.module.js +0 -20
  113. package/dist/modules/core/account/account.module.js.map +0 -1
  114. package/dist/modules/core/account/account.queries.d.ts +0 -18
  115. package/dist/modules/core/account/account.queries.js +0 -150
  116. package/dist/modules/core/account/account.queries.js.map +0 -1
  117. package/dist/modules/core/account/account.resolver.d.ts +0 -11
  118. package/dist/modules/core/account/account.resolver.js +0 -107
  119. package/dist/modules/core/account/account.resolver.js.map +0 -1
  120. package/dist/modules/core/account/account.schema.d.ts +0 -24
  121. package/dist/modules/core/account/account.schema.js +0 -114
  122. package/dist/modules/core/account/account.schema.js.map +0 -1
  123. package/dist/modules/core/account-auth/account-auth.module.d.ts +0 -2
  124. package/dist/modules/core/account-auth/account-auth.module.js +0 -24
  125. package/dist/modules/core/account-auth/account-auth.module.js.map +0 -1
  126. package/dist/modules/core/account-auth/account-auth.service.d.ts +0 -5
  127. package/dist/modules/core/account-auth/account-auth.service.js +0 -41
  128. package/dist/modules/core/account-auth/account-auth.service.js.map +0 -1
  129. package/dist/modules/core/account-auth/account-auth.strategy.d.ts +0 -10
  130. package/dist/modules/core/account-auth/account-auth.strategy.js +0 -49
  131. package/dist/modules/core/account-auth/account-auth.strategy.js.map +0 -1
  132. package/dist/modules/core/auth/auth.module.d.ts +0 -2
  133. package/dist/modules/core/auth/auth.module.js +0 -35
  134. package/dist/modules/core/auth/auth.module.js.map +0 -1
  135. package/dist/modules/core/auth/auth.service.d.ts +0 -11
  136. package/dist/modules/core/auth/auth.service.js +0 -164
  137. package/dist/modules/core/auth/auth.service.js.map +0 -1
  138. package/dist/modules/core/auth/auth.types.d.ts +0 -27
  139. package/dist/modules/core/auth/auth.types.js +0 -3
  140. package/dist/modules/core/auth/auth.types.js.map +0 -1
  141. package/dist/modules/core/auth/jwt.auth.guard.d.ts +0 -6
  142. package/dist/modules/core/auth/jwt.auth.guard.js +0 -23
  143. package/dist/modules/core/auth/jwt.auth.guard.js.map +0 -1
  144. package/dist/modules/core/auth/jwt.strategy.d.ts +0 -10
  145. package/dist/modules/core/auth/jwt.strategy.js +0 -35
  146. package/dist/modules/core/auth/jwt.strategy.js.map +0 -1
  147. package/dist/modules/core/backup/backup.controller.d.ts +0 -7
  148. package/dist/modules/core/backup/backup.controller.js +0 -61
  149. package/dist/modules/core/backup/backup.controller.js.map +0 -1
  150. package/dist/modules/core/backup/backup.module.d.ts +0 -2
  151. package/dist/modules/core/backup/backup.module.js +0 -22
  152. package/dist/modules/core/backup/backup.module.js.map +0 -1
  153. package/dist/modules/core/backup/backup.resolver.d.ts +0 -8
  154. package/dist/modules/core/backup/backup.resolver.js +0 -54
  155. package/dist/modules/core/backup/backup.resolver.js.map +0 -1
  156. package/dist/modules/core/backup/backup.shema.d.ts +0 -4
  157. package/dist/modules/core/backup/backup.shema.js +0 -30
  158. package/dist/modules/core/backup/backup.shema.js.map +0 -1
  159. package/dist/modules/core/core.module.d.ts +0 -2
  160. package/dist/modules/core/core.module.js +0 -50
  161. package/dist/modules/core/core.module.js.map +0 -1
  162. package/dist/modules/core/document/document.helper.d.ts +0 -2
  163. package/dist/modules/core/document/document.helper.js +0 -10
  164. package/dist/modules/core/document/document.helper.js.map +0 -1
  165. package/dist/modules/core/document/document.model.d.ts +0 -9
  166. package/dist/modules/core/document/document.model.js +0 -59
  167. package/dist/modules/core/document/document.model.js.map +0 -1
  168. package/dist/modules/core/document/document.module.d.ts +0 -2
  169. package/dist/modules/core/document/document.module.js +0 -25
  170. package/dist/modules/core/document/document.module.js.map +0 -1
  171. package/dist/modules/core/document/document.resolver.d.ts +0 -12
  172. package/dist/modules/core/document/document.resolver.extend.d.ts +0 -10
  173. package/dist/modules/core/document/document.resolver.extend.js +0 -69
  174. package/dist/modules/core/document/document.resolver.extend.js.map +0 -1
  175. package/dist/modules/core/document/document.resolver.js +0 -154
  176. package/dist/modules/core/document/document.resolver.js.map +0 -1
  177. package/dist/modules/core/document/document.schema.d.ts +0 -39
  178. package/dist/modules/core/document/document.schema.js +0 -181
  179. package/dist/modules/core/document/document.schema.js.map +0 -1
  180. package/dist/modules/core/document/load-documents.queries.d.ts +0 -17
  181. package/dist/modules/core/document/load-documents.queries.js +0 -119
  182. package/dist/modules/core/document/load-documents.queries.js.map +0 -1
  183. package/dist/modules/core/document/save-documents.queries.d.ts +0 -18
  184. package/dist/modules/core/document/save-documents.queries.js +0 -199
  185. package/dist/modules/core/document/save-documents.queries.js.map +0 -1
  186. package/dist/modules/core/fields/_fields.helpers.d.ts +0 -2
  187. package/dist/modules/core/fields/_fields.helpers.js +0 -12
  188. package/dist/modules/core/fields/_fields.helpers.js.map +0 -1
  189. package/dist/modules/core/fields/fields.model.d.ts +0 -17
  190. package/dist/modules/core/fields/fields.model.js +0 -99
  191. package/dist/modules/core/fields/fields.model.js.map +0 -1
  192. package/dist/modules/core/fields/fields.module.d.ts +0 -2
  193. package/dist/modules/core/fields/fields.module.js +0 -20
  194. package/dist/modules/core/fields/fields.module.js.map +0 -1
  195. package/dist/modules/core/fields/fields.resolver.d.ts +0 -14
  196. package/dist/modules/core/fields/fields.resolver.js +0 -165
  197. package/dist/modules/core/fields/fields.resolver.js.map +0 -1
  198. package/dist/modules/core/fields/load-fields.queries.d.ts +0 -20
  199. package/dist/modules/core/fields/load-fields.queries.js +0 -233
  200. package/dist/modules/core/fields/load-fields.queries.js.map +0 -1
  201. package/dist/modules/core/fields/quill-delta.d.ts +0 -1
  202. package/dist/modules/core/fields/quill-delta.js +0 -40
  203. package/dist/modules/core/fields/quill-delta.js.map +0 -1
  204. package/dist/modules/core/fields/save-fields.queries.d.ts +0 -9
  205. package/dist/modules/core/fields/save-fields.queries.js +0 -135
  206. package/dist/modules/core/fields/save-fields.queries.js.map +0 -1
  207. package/dist/modules/core/leaf/leaf.model.d.ts +0 -9
  208. package/dist/modules/core/leaf/leaf.model.js +0 -61
  209. package/dist/modules/core/leaf/leaf.model.js.map +0 -1
  210. package/dist/modules/core/leaf/leaf.module.d.ts +0 -2
  211. package/dist/modules/core/leaf/leaf.module.js +0 -21
  212. package/dist/modules/core/leaf/leaf.module.js.map +0 -1
  213. package/dist/modules/core/leaf/leaf.queries.d.ts +0 -21
  214. package/dist/modules/core/leaf/leaf.queries.js +0 -159
  215. package/dist/modules/core/leaf/leaf.queries.js.map +0 -1
  216. package/dist/modules/core/leaf/leaf.resolver.d.ts +0 -9
  217. package/dist/modules/core/leaf/leaf.resolver.extend.d.ts +0 -6
  218. package/dist/modules/core/leaf/leaf.resolver.extend.js +0 -42
  219. package/dist/modules/core/leaf/leaf.resolver.extend.js.map +0 -1
  220. package/dist/modules/core/leaf/leaf.resolver.js +0 -84
  221. package/dist/modules/core/leaf/leaf.resolver.js.map +0 -1
  222. package/dist/modules/core/leaf/leaf.schema.d.ts +0 -7
  223. package/dist/modules/core/leaf/leaf.schema.js +0 -45
  224. package/dist/modules/core/leaf/leaf.schema.js.map +0 -1
  225. package/dist/modules/core/leaf-item/leaf-item.model.d.ts +0 -6
  226. package/dist/modules/core/leaf-item/leaf-item.model.js +0 -44
  227. package/dist/modules/core/leaf-item/leaf-item.model.js.map +0 -1
  228. package/dist/modules/core/leaf-item/leaf-item.queries.d.ts +0 -9
  229. package/dist/modules/core/leaf-item/leaf-item.queries.js +0 -120
  230. package/dist/modules/core/leaf-item/leaf-item.queries.js.map +0 -1
  231. package/dist/modules/core/login/login.controller.d.ts +0 -8
  232. package/dist/modules/core/login/login.controller.js +0 -54
  233. package/dist/modules/core/login/login.controller.js.map +0 -1
  234. package/dist/modules/core/login/login.module.d.ts +0 -2
  235. package/dist/modules/core/login/login.module.js +0 -22
  236. package/dist/modules/core/login/login.module.js.map +0 -1
  237. package/dist/modules/core/media/media-upload.controller.d.ts +0 -21
  238. package/dist/modules/core/media/media-upload.controller.js +0 -160
  239. package/dist/modules/core/media/media-upload.controller.js.map +0 -1
  240. package/dist/modules/core/media/media.d.ts +0 -22
  241. package/dist/modules/core/media/media.js +0 -53
  242. package/dist/modules/core/media/media.js.map +0 -1
  243. package/dist/modules/core/media/media.module.d.ts +0 -2
  244. package/dist/modules/core/media/media.module.js +0 -22
  245. package/dist/modules/core/media/media.module.js.map +0 -1
  246. package/dist/modules/core/media/media.resolver.d.ts +0 -14
  247. package/dist/modules/core/media/media.resolver.js +0 -199
  248. package/dist/modules/core/media/media.resolver.js.map +0 -1
  249. package/dist/modules/core/media/media.schema.d.ts +0 -30
  250. package/dist/modules/core/media/media.schema.js +0 -144
  251. package/dist/modules/core/media/media.schema.js.map +0 -1
  252. package/dist/modules/core/part/part.module.d.ts +0 -2
  253. package/dist/modules/core/part/part.module.js +0 -21
  254. package/dist/modules/core/part/part.module.js.map +0 -1
  255. package/dist/modules/core/part/part.queries.d.ts +0 -22
  256. package/dist/modules/core/part/part.queries.js +0 -167
  257. package/dist/modules/core/part/part.queries.js.map +0 -1
  258. package/dist/modules/core/part/part.resolver.d.ts +0 -14
  259. package/dist/modules/core/part/part.resolver.extend.d.ts +0 -5
  260. package/dist/modules/core/part/part.resolver.extend.js +0 -49
  261. package/dist/modules/core/part/part.resolver.extend.js.map +0 -1
  262. package/dist/modules/core/part/part.resolver.js +0 -135
  263. package/dist/modules/core/part/part.resolver.js.map +0 -1
  264. package/dist/modules/core/part/part.schema.d.ts +0 -12
  265. package/dist/modules/core/part/part.schema.js +0 -66
  266. package/dist/modules/core/part/part.schema.js.map +0 -1
  267. package/dist/modules/core/section/section-wrap.resolver.d.ts +0 -11
  268. package/dist/modules/core/section/section-wrap.resolver.js +0 -168
  269. package/dist/modules/core/section/section-wrap.resolver.js.map +0 -1
  270. package/dist/modules/core/section/section.model.d.ts +0 -6
  271. package/dist/modules/core/section/section.model.js +0 -44
  272. package/dist/modules/core/section/section.model.js.map +0 -1
  273. package/dist/modules/core/section/section.module.d.ts +0 -2
  274. package/dist/modules/core/section/section.module.js +0 -21
  275. package/dist/modules/core/section/section.module.js.map +0 -1
  276. package/dist/modules/core/section/section.queries.d.ts +0 -51
  277. package/dist/modules/core/section/section.queries.js +0 -228
  278. package/dist/modules/core/section/section.queries.js.map +0 -1
  279. package/dist/modules/core/section/section.resolver.d.ts +0 -7
  280. package/dist/modules/core/section/section.resolver.js +0 -78
  281. package/dist/modules/core/section/section.resolver.js.map +0 -1
  282. package/dist/modules/core/section/section.schema.d.ts +0 -27
  283. package/dist/modules/core/section/section.schema.js +0 -129
  284. package/dist/modules/core/section/section.schema.js.map +0 -1
  285. package/dist/modules/core/site-info/site-info.module.d.ts +0 -2
  286. package/dist/modules/core/site-info/site-info.module.js +0 -20
  287. package/dist/modules/core/site-info/site-info.module.js.map +0 -1
  288. package/dist/modules/core/site-info/site-info.resolver.d.ts +0 -5
  289. package/dist/modules/core/site-info/site-info.resolver.js +0 -44
  290. package/dist/modules/core/site-info/site-info.resolver.js.map +0 -1
  291. package/dist/modules/core/site-info/site-info.schema.d.ts +0 -6
  292. package/dist/modules/core/site-info/site-info.schema.js +0 -36
  293. package/dist/modules/core/site-info/site-info.schema.js.map +0 -1
  294. package/dist/modules/core/site-schema/site-schema.module.d.ts +0 -2
  295. package/dist/modules/core/site-schema/site-schema.module.js +0 -20
  296. package/dist/modules/core/site-schema/site-schema.module.js.map +0 -1
  297. package/dist/modules/core/site-schema/site-schema.resolver.d.ts +0 -4
  298. package/dist/modules/core/site-schema/site-schema.resolver.js +0 -35
  299. package/dist/modules/core/site-schema/site-schema.resolver.js.map +0 -1
  300. package/dist/modules/core/term-flag/term-flag.model.d.ts +0 -6
  301. package/dist/modules/core/term-flag/term-flag.model.js +0 -45
  302. package/dist/modules/core/term-flag/term-flag.model.js.map +0 -1
  303. package/dist/modules/core/term-flag/term-flag.module.d.ts +0 -2
  304. package/dist/modules/core/term-flag/term-flag.module.js +0 -20
  305. package/dist/modules/core/term-flag/term-flag.module.js.map +0 -1
  306. package/dist/modules/core/term-flag/term-flag.queries.d.ts +0 -7
  307. package/dist/modules/core/term-flag/term-flag.queries.js +0 -44
  308. package/dist/modules/core/term-flag/term-flag.queries.js.map +0 -1
  309. package/dist/modules/core/term-flag/term-flag.resolver.d.ts +0 -5
  310. package/dist/modules/core/term-flag/term-flag.resolver.js +0 -47
  311. package/dist/modules/core/term-flag/term-flag.resolver.js.map +0 -1
  312. package/dist/modules/core/term-flag/term-flag.schema.d.ts +0 -9
  313. package/dist/modules/core/term-flag/term-flag.schema.js +0 -51
  314. package/dist/modules/core/term-flag/term-flag.schema.js.map +0 -1
  315. package/dist/modules/core/unprotected/unprotected.module.d.ts +0 -2
  316. package/dist/modules/core/unprotected/unprotected.module.js +0 -20
  317. package/dist/modules/core/unprotected/unprotected.module.js.map +0 -1
  318. package/dist/modules/core/unprotected/unprotected.resolver.d.ts +0 -8
  319. package/dist/modules/core/unprotected/unprotected.resolver.js +0 -106
  320. package/dist/modules/core/unprotected/unprotected.resolver.js.map +0 -1
  321. package/dist/modules/core/unprotected/unprotected.schema.d.ts +0 -19
  322. package/dist/modules/core/unprotected/unprotected.schema.js +0 -93
  323. package/dist/modules/core/unprotected/unprotected.schema.js.map +0 -1
  324. package/dist/modules/graphql.types.d.ts +0 -6
  325. package/dist/modules/graphql.types.js +0 -3
  326. package/dist/modules/graphql.types.js.map +0 -1
  327. package/dist/modules/private-api.module.d.ts +0 -2
  328. package/dist/modules/private-api.module.js +0 -50
  329. package/dist/modules/private-api.module.js.map +0 -1
  330. package/dist/modules/public-api/class-validator-options.d.ts +0 -7
  331. package/dist/modules/public-api/class-validator-options.js +0 -11
  332. package/dist/modules/public-api/class-validator-options.js.map +0 -1
  333. package/dist/modules/public-api/mail/contact-form-mail.d.ts +0 -8
  334. package/dist/modules/public-api/mail/contact-form-mail.js +0 -96
  335. package/dist/modules/public-api/mail/contact-form-mail.js.map +0 -1
  336. package/dist/modules/public-api/mail/mail.dto.d.ts +0 -8
  337. package/dist/modules/public-api/mail/mail.dto.js +0 -56
  338. package/dist/modules/public-api/mail/mail.dto.js.map +0 -1
  339. package/dist/modules/public-api/partials/partials-params.dto.d.ts +0 -6
  340. package/dist/modules/public-api/partials/partials-params.dto.js +0 -45
  341. package/dist/modules/public-api/partials/partials-params.dto.js.map +0 -1
  342. package/dist/modules/public-api/password-reset/password-reset.controller.d.ts +0 -11
  343. package/dist/modules/public-api/password-reset/password-reset.controller.js +0 -59
  344. package/dist/modules/public-api/password-reset/password-reset.controller.js.map +0 -1
  345. package/dist/modules/public-api/password-reset/password-reset.dto.d.ts +0 -9
  346. package/dist/modules/public-api/password-reset/password-reset.dto.js +0 -55
  347. package/dist/modules/public-api/password-reset/password-reset.dto.js.map +0 -1
  348. package/dist/modules/public-api/password-reset/password-reset.module.d.ts +0 -2
  349. package/dist/modules/public-api/password-reset/password-reset.module.js +0 -22
  350. package/dist/modules/public-api/password-reset/password-reset.module.js.map +0 -1
  351. package/dist/modules/public-api/password-reset/password-reset.service.d.ts +0 -14
  352. package/dist/modules/public-api/password-reset/password-reset.service.js +0 -56
  353. package/dist/modules/public-api/password-reset/password-reset.service.js.map +0 -1
  354. package/dist/modules/public-api/public-api-controller.d.ts +0 -32
  355. package/dist/modules/public-api/public-api-controller.js +0 -198
  356. package/dist/modules/public-api/public-api-controller.js.map +0 -1
  357. package/dist/modules/public-api/public-api.module.d.ts +0 -2
  358. package/dist/modules/public-api/public-api.module.js +0 -22
  359. package/dist/modules/public-api/public-api.module.js.map +0 -1
  360. package/dist/modules/public-api/search-text/search-text.dto.d.ts +0 -7
  361. package/dist/modules/public-api/search-text/search-text.dto.js +0 -50
  362. package/dist/modules/public-api/search-text/search-text.dto.js.map +0 -1
  363. package/dist/modules/public-api/search-text/search-text.queries.d.ts +0 -14
  364. package/dist/modules/public-api/search-text/search-text.queries.js +0 -58
  365. package/dist/modules/public-api/search-text/search-text.queries.js.map +0 -1
  366. package/dist/modules/public-site/app-exception-filter.d.ts +0 -4
  367. package/dist/modules/public-site/app-exception-filter.js +0 -41
  368. package/dist/modules/public-site/app-exception-filter.js.map +0 -1
  369. package/dist/modules/public-site/helpers/format-date.helper.d.ts +0 -4
  370. package/dist/modules/public-site/helpers/format-date.helper.js +0 -35
  371. package/dist/modules/public-site/helpers/format-date.helper.js.map +0 -1
  372. package/dist/modules/public-site/helpers/medias.helpers.d.ts +0 -3
  373. package/dist/modules/public-site/helpers/medias.helpers.js +0 -16
  374. package/dist/modules/public-site/helpers/medias.helpers.js.map +0 -1
  375. package/dist/modules/public-site/helpers/obfuscate.helper.d.ts +0 -2
  376. package/dist/modules/public-site/helpers/obfuscate.helper.js +0 -27
  377. package/dist/modules/public-site/helpers/obfuscate.helper.js.map +0 -1
  378. package/dist/modules/public-site/liquidjs-filters/format-date.d.ts +0 -7
  379. package/dist/modules/public-site/liquidjs-filters/format-date.js +0 -15
  380. package/dist/modules/public-site/liquidjs-filters/format-date.js.map +0 -1
  381. package/dist/modules/public-site/liquidjs-filters/format-number.d.ts +0 -6
  382. package/dist/modules/public-site/liquidjs-filters/format-number.js +0 -17
  383. package/dist/modules/public-site/liquidjs-filters/format-number.js.map +0 -1
  384. package/dist/modules/public-site/liquidjs-filters/info-filter.d.ts +0 -1
  385. package/dist/modules/public-site/liquidjs-filters/info-filter.js +0 -144
  386. package/dist/modules/public-site/liquidjs-filters/info-filter.js.map +0 -1
  387. package/dist/modules/public-site/liquidjs-filters/inject-facebook-chat.d.ts +0 -1
  388. package/dist/modules/public-site/liquidjs-filters/inject-facebook-chat.js +0 -40
  389. package/dist/modules/public-site/liquidjs-filters/inject-facebook-chat.js.map +0 -1
  390. package/dist/modules/public-site/liquidjs-filters/inject-menu-items-data.d.ts +0 -6
  391. package/dist/modules/public-site/liquidjs-filters/inject-menu-items-data.js +0 -25
  392. package/dist/modules/public-site/liquidjs-filters/inject-menu-items-data.js.map +0 -1
  393. package/dist/modules/public-site/liquidjs-filters/make-excerpt.d.ts +0 -3
  394. package/dist/modules/public-site/liquidjs-filters/make-excerpt.js +0 -10
  395. package/dist/modules/public-site/liquidjs-filters/make-excerpt.js.map +0 -1
  396. package/dist/modules/public-site/liquidjs-filters/obfuscate.d.ts +0 -2
  397. package/dist/modules/public-site/liquidjs-filters/obfuscate.js +0 -18
  398. package/dist/modules/public-site/liquidjs-filters/obfuscate.js.map +0 -1
  399. package/dist/modules/public-site/liquidjs-filters/open-graph-filter.d.ts +0 -6
  400. package/dist/modules/public-site/liquidjs-filters/open-graph-filter.js +0 -41
  401. package/dist/modules/public-site/liquidjs-filters/open-graph-filter.js.map +0 -1
  402. package/dist/modules/public-site/liquidjs-filters/translate-filter.d.ts +0 -7
  403. package/dist/modules/public-site/liquidjs-filters/translate-filter.js +0 -23
  404. package/dist/modules/public-site/liquidjs-filters/translate-filter.js.map +0 -1
  405. package/dist/modules/public-site/liquidjs-tags/get-page-tag.d.ts +0 -13
  406. package/dist/modules/public-site/liquidjs-tags/get-page-tag.js +0 -69
  407. package/dist/modules/public-site/liquidjs-tags/get-page-tag.js.map +0 -1
  408. package/dist/modules/public-site/liquidjs-tags/get-pages-tag.d.ts +0 -13
  409. package/dist/modules/public-site/liquidjs-tags/get-pages-tag.js +0 -95
  410. package/dist/modules/public-site/liquidjs-tags/get-pages-tag.js.map +0 -1
  411. package/dist/modules/public-site/liquidjs-tags/use-image-tag.d.ts +0 -13
  412. package/dist/modules/public-site/liquidjs-tags/use-image-tag.js +0 -54
  413. package/dist/modules/public-site/liquidjs-tags/use-image-tag.js.map +0 -1
  414. package/dist/modules/public-site/media-serve/_media-serve-helpers.d.ts +0 -11
  415. package/dist/modules/public-site/media-serve/_media-serve-helpers.js +0 -26
  416. package/dist/modules/public-site/media-serve/_media-serve-helpers.js.map +0 -1
  417. package/dist/modules/public-site/media-serve/media-serve.controller.d.ts +0 -4
  418. package/dist/modules/public-site/media-serve/media-serve.controller.js +0 -140
  419. package/dist/modules/public-site/media-serve/media-serve.controller.js.map +0 -1
  420. package/dist/modules/public-site/media-serve/media-serve.module.d.ts +0 -2
  421. package/dist/modules/public-site/media-serve/media-serve.module.js +0 -20
  422. package/dist/modules/public-site/media-serve/media-serve.module.js.map +0 -1
  423. package/dist/modules/public-site/oauth2-client.controller.d.ts +0 -10
  424. package/dist/modules/public-site/oauth2-client.controller.js +0 -144
  425. package/dist/modules/public-site/oauth2-client.controller.js.map +0 -1
  426. package/dist/modules/public-site/public-route/make-url.d.ts +0 -11
  427. package/dist/modules/public-site/public-route/make-url.js +0 -150
  428. package/dist/modules/public-site/public-route/make-url.js.map +0 -1
  429. package/dist/modules/public-site/public-route/public-route-parser.d.ts +0 -16
  430. package/dist/modules/public-site/public-route/public-route-parser.js +0 -154
  431. package/dist/modules/public-site/public-route/public-route-parser.js.map +0 -1
  432. package/dist/modules/public-site/public-route/raw-document-payload.d.ts +0 -8
  433. package/dist/modules/public-site/public-route/raw-document-payload.js +0 -86
  434. package/dist/modules/public-site/public-route/raw-document-payload.js.map +0 -1
  435. package/dist/modules/public-site/public-site.controller.d.ts +0 -7
  436. package/dist/modules/public-site/public-site.controller.js +0 -58
  437. package/dist/modules/public-site/public-site.controller.js.map +0 -1
  438. package/dist/modules/public-site/public-site.middleware.d.ts +0 -5
  439. package/dist/modules/public-site/public-site.middleware.js +0 -67
  440. package/dist/modules/public-site/public-site.middleware.js.map +0 -1
  441. package/dist/modules/public-site/public-site.module.d.ts +0 -4
  442. package/dist/modules/public-site/public-site.module.js +0 -27
  443. package/dist/modules/public-site/public-site.module.js.map +0 -1
  444. package/dist/modules/public-site/serve-document/serve-document.d.ts +0 -20
  445. package/dist/modules/public-site/serve-document/serve-document.js +0 -60
  446. package/dist/modules/public-site/serve-document/serve-document.js.map +0 -1
  447. package/dist/modules/security/app-throttler-guard.d.ts +0 -8
  448. package/dist/modules/security/app-throttler-guard.js +0 -18
  449. package/dist/modules/security/app-throttler-guard.js.map +0 -1
  450. package/dist/modules/security/complexity-plugin.d.ts +0 -8
  451. package/dist/modules/security/complexity-plugin.js +0 -46
  452. package/dist/modules/security/complexity-plugin.js.map +0 -1
  453. package/dist/nest-custom-logger.d.ts +0 -8
  454. package/dist/nest-custom-logger.js +0 -23
  455. package/dist/nest-custom-logger.js.map +0 -1
  456. package/dist/public-payload/breadcrumb.queries.d.ts +0 -5
  457. package/dist/public-payload/breadcrumb.queries.js +0 -26
  458. package/dist/public-payload/breadcrumb.queries.js.map +0 -1
  459. package/dist/public-payload/create-page-drop.d.ts +0 -11
  460. package/dist/public-payload/create-page-drop.js +0 -160
  461. package/dist/public-payload/create-page-drop.js.map +0 -1
  462. package/dist/public-payload/create-page-part-drop.d.ts +0 -7
  463. package/dist/public-payload/create-page-part-drop.js +0 -39
  464. package/dist/public-payload/create-page-part-drop.js.map +0 -1
  465. package/dist/public-payload/excerpt.queries.d.ts +0 -10
  466. package/dist/public-payload/excerpt.queries.js +0 -38
  467. package/dist/public-payload/excerpt.queries.js.map +0 -1
  468. package/dist/public-payload/field-values.d.ts +0 -9
  469. package/dist/public-payload/field-values.js +0 -99
  470. package/dist/public-payload/field-values.js.map +0 -1
  471. package/dist/public-payload/get-siblings.queries.d.ts +0 -5
  472. package/dist/public-payload/get-siblings.queries.js +0 -117
  473. package/dist/public-payload/get-siblings.queries.js.map +0 -1
  474. package/dist/public-payload/load-default-image.d.ts +0 -8
  475. package/dist/public-payload/load-default-image.js +0 -52
  476. package/dist/public-payload/load-default-image.js.map +0 -1
  477. package/dist/public-payload/make-basic-payload.d.ts +0 -6
  478. package/dist/public-payload/make-basic-payload.js +0 -19
  479. package/dist/public-payload/make-basic-payload.js.map +0 -1
  480. package/dist/public-payload/make-image-available.d.ts +0 -26
  481. package/dist/public-payload/make-image-available.js +0 -38
  482. package/dist/public-payload/make-image-available.js.map +0 -1
  483. package/dist/public-payload/page-values.queries.d.ts +0 -27
  484. package/dist/public-payload/page-values.queries.js +0 -110
  485. package/dist/public-payload/page-values.queries.js.map +0 -1
  486. package/dist/public-payload/parts.queries.d.ts +0 -6
  487. package/dist/public-payload/parts.queries.js +0 -123
  488. package/dist/public-payload/parts.queries.js.map +0 -1
  489. package/dist/public-payload/public-payload.types.d.ts +0 -130
  490. package/dist/public-payload/public-payload.types.js +0 -3
  491. package/dist/public-payload/public-payload.types.js.map +0 -1
  492. package/dist/public-payload/site-payload.d.ts +0 -4
  493. package/dist/public-payload/site-payload.js +0 -43
  494. package/dist/public-payload/site-payload.js.map +0 -1
  495. package/dist/public-payload/taxonomies.queries.d.ts +0 -13
  496. package/dist/public-payload/taxonomies.queries.js +0 -45
  497. package/dist/public-payload/taxonomies.queries.js.map +0 -1
  498. package/dist/public-payload/translations.queries.d.ts +0 -7
  499. package/dist/public-payload/translations.queries.js +0 -62
  500. package/dist/public-payload/translations.queries.js.map +0 -1
  501. package/dist/public.types.d.ts +0 -5
  502. package/dist/public.types.js +0 -3
  503. package/dist/public.types.js.map +0 -1
  504. package/dist/share/pino-app-log.d.ts +0 -26
  505. package/dist/share/pino-app-log.js +0 -138
  506. package/dist/share/pino-app-log.js.map +0 -1
  507. package/dist/share/read-configuration.d.ts +0 -7
  508. package/dist/share/read-configuration.js +0 -31
  509. package/dist/share/read-configuration.js.map +0 -1
  510. package/dist/site-backup/archiver.helper.d.ts +0 -12
  511. package/dist/site-backup/archiver.helper.js +0 -43
  512. package/dist/site-backup/archiver.helper.js.map +0 -1
  513. package/dist/site-backup/backup-tasks.d.ts +0 -10
  514. package/dist/site-backup/backup-tasks.js +0 -50
  515. package/dist/site-backup/backup-tasks.js.map +0 -1
  516. package/dist/site-backup/backup.d.ts +0 -11
  517. package/dist/site-backup/backup.helper.d.ts +0 -3
  518. package/dist/site-backup/backup.helper.js +0 -13
  519. package/dist/site-backup/backup.helper.js.map +0 -1
  520. package/dist/site-backup/backup.js +0 -35
  521. package/dist/site-backup/backup.js.map +0 -1
  522. package/dist/site-context/create-site-context.d.ts +0 -3
  523. package/dist/site-context/create-site-context.js +0 -183
  524. package/dist/site-context/create-site-context.js.map +0 -1
  525. package/dist/site-context/db-init/db-init.d.ts +0 -11
  526. package/dist/site-context/db-init/db-init.js +0 -38
  527. package/dist/site-context/db-init/db-init.js.map +0 -1
  528. package/dist/site-context/db-init/ddl-migration.d.ts +0 -13
  529. package/dist/site-context/db-init/ddl-migration.js +0 -26
  530. package/dist/site-context/db-init/ddl-migration.js.map +0 -1
  531. package/dist/site-context/db-init/init-routing-points.d.ts +0 -5
  532. package/dist/site-context/db-init/init-routing-points.js +0 -149
  533. package/dist/site-context/db-init/init-routing-points.js.map +0 -1
  534. package/dist/site-context/site-conf.d.ts +0 -17
  535. package/dist/site-context/site-conf.js +0 -103
  536. package/dist/site-context/site-conf.js.map +0 -1
  537. package/dist/site-context/site-context.d.ts +0 -12
  538. package/dist/site-context/site-context.js +0 -87
  539. package/dist/site-context/site-context.js.map +0 -1
  540. package/dist/site-context/site-context.types.d.ts +0 -46
  541. package/dist/site-context/site-context.types.js +0 -3
  542. package/dist/site-context/site-context.types.js.map +0 -1
  543. package/dist/site-context/theme-conf-reader.d.ts +0 -4
  544. package/dist/site-context/theme-conf-reader.js +0 -33
  545. package/dist/site-context/theme-conf-reader.js.map +0 -1
  546. package/dist/site-context/theme-conf-types.d.ts +0 -4
  547. package/dist/site-context/theme-conf-types.js +0 -3
  548. package/dist/site-context/theme-conf-types.js.map +0 -1
  549. package/dist/site-schema/common-schema-reader.d.ts +0 -6
  550. package/dist/site-schema/common-schema-reader.js +0 -29
  551. package/dist/site-schema/common-schema-reader.js.map +0 -1
  552. package/dist/site-schema/merged-schema-lib.d.ts +0 -30
  553. package/dist/site-schema/merged-schema-lib.js +0 -118
  554. package/dist/site-schema/merged-schema-lib.js.map +0 -1
  555. package/dist/site-schema/read-locales.d.ts +0 -24
  556. package/dist/site-schema/read-locales.js +0 -171
  557. package/dist/site-schema/read-locales.js.map +0 -1
  558. package/dist/site-schema/site-schema-factory.d.ts +0 -2
  559. package/dist/site-schema/site-schema-factory.js +0 -385
  560. package/dist/site-schema/site-schema-factory.js.map +0 -1
  561. package/dist/site-schema/site-schema-helpers.d.ts +0 -5
  562. package/dist/site-schema/site-schema-helpers.js +0 -27
  563. package/dist/site-schema/site-schema-helpers.js.map +0 -1
  564. package/dist/site-schema/site-schema-lib-reader.d.ts +0 -14
  565. package/dist/site-schema/site-schema-lib-reader.js +0 -48
  566. package/dist/site-schema/site-schema-lib-reader.js.map +0 -1
  567. package/dist/start.d.ts +0 -1
  568. package/dist/start.js +0 -5
  569. package/dist/start.js.map +0 -1
  570. package/dist/types.to.json +0 -1
@@ -1,57 +0,0 @@
1
- import { ParsedSectionId } from "@paroicms/anywhere-lib";
2
- import { SiteContext } from "../site-context/site-context.types";
3
- export declare function makeCacheDependencyKey(options: {
4
- documentId: ParsedSectionId;
5
- perimeter?: "slug";
6
- } | {
7
- documentId: ParsedSectionId;
8
- relation: "children";
9
- } | {
10
- leafId: string;
11
- relation: "flagged";
12
- taxonomyLeafType: string;
13
- } | {
14
- leafId: string;
15
- }): string;
16
- export declare function makeCacheKey(options: {
17
- kind: "redirect";
18
- urlKey: string;
19
- }): string;
20
- export declare function makeCacheKey(options: {
21
- kind: "url";
22
- documentId: ParsedSectionId;
23
- }): string;
24
- export declare function makeCacheKey(options: {
25
- kind: "html";
26
- url: string;
27
- }): string;
28
- export declare function makeCacheKey(options: {
29
- kind: "api";
30
- url: string;
31
- }): string;
32
- export declare function invalidateDocumentInCache(siteContext: Pick<SiteContext, "mainCn" | "textCache" | "siteSchema">, options: {
33
- parentOf: ParsedSectionId;
34
- } | {
35
- documentId: ParsedSectionId;
36
- perimeter?: "slug";
37
- } | {
38
- documentId: ParsedSectionId;
39
- fully: true;
40
- parentId: ParsedSectionId | undefined;
41
- }): Promise<void>;
42
- export declare function invalidateDocumentRelationCache(siteContext: Pick<SiteContext, "textCache">, options: {
43
- documentId: ParsedSectionId;
44
- relation: "children";
45
- } | {
46
- leafId: string;
47
- relation: "flagged";
48
- taxonomyLeafType: string;
49
- }): Promise<void>;
50
- export declare function invalidateMultipleDocumentsInCache(siteContext: Pick<SiteContext, "mainCn" | "textCache" | "siteSchema">, options: {
51
- leafId: string;
52
- parentIds?: ParsedSectionId[];
53
- fully?: boolean;
54
- } | {
55
- parentOfLeafId: string;
56
- fully?: boolean;
57
- }): Promise<void>;
@@ -1,87 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.invalidateMultipleDocumentsInCache = exports.invalidateDocumentRelationCache = exports.invalidateDocumentInCache = exports.makeCacheKey = exports.makeCacheDependencyKey = void 0;
4
- const anywhere_lib_1 = require("@paroicms/anywhere-lib");
5
- const load_documents_queries_1 = require("../modules/core/document/load-documents.queries");
6
- function makeCacheDependencyKey(options) {
7
- if ("leafId" in options) {
8
- if ("relation" in options && options.relation === "flagged") {
9
- const { leafId, taxonomyLeafType } = options;
10
- return `*:${leafId}:flagged:${taxonomyLeafType}`;
11
- }
12
- return `*:${options.leafId}`;
13
- }
14
- const encodedId = (0, anywhere_lib_1.encodeSectionId)(options.documentId);
15
- if ("relation" in options)
16
- return `${encodedId}:${options.relation}`;
17
- if (options.perimeter)
18
- return `${encodedId}:${options.perimeter}`;
19
- return encodedId;
20
- }
21
- exports.makeCacheDependencyKey = makeCacheDependencyKey;
22
- function makeCacheKey(options) {
23
- const { kind, url, urlKey, documentId } = options;
24
- if (kind === "html")
25
- return `${kind}:${url}`;
26
- if (kind === "api")
27
- return `${kind}:${url}`;
28
- if (kind === "redirect")
29
- return `${kind}:${urlKey}`;
30
- if (documentId)
31
- return `${kind}:${(0, anywhere_lib_1.encodeSectionId)(documentId)}`;
32
- throw new Error("invalid parameter");
33
- }
34
- exports.makeCacheKey = makeCacheKey;
35
- async function invalidateDocumentInCache(siteContext, options) {
36
- const dependencyKeys = [];
37
- const documentId = "documentId" in options
38
- ? options.documentId
39
- : await (0, load_documents_queries_1.getParentSectionIdOf)(siteContext, options.parentOf);
40
- if (!documentId)
41
- return;
42
- const fully = "fully" in options && options.fully;
43
- const withSlug = ("perimeter" in options && options.perimeter === "slug") || fully;
44
- dependencyKeys.push(makeCacheDependencyKey({ documentId }), makeCacheDependencyKey({ leafId: documentId.leafId }));
45
- if (withSlug) {
46
- dependencyKeys.push(makeCacheDependencyKey({ documentId, perimeter: "slug" }));
47
- }
48
- if (fully) {
49
- dependencyKeys.push(makeCacheDependencyKey({ documentId, relation: "children" }));
50
- }
51
- const parentId = "parentId" in options ? options.parentId : await (0, load_documents_queries_1.getParentSectionIdOf)(siteContext, documentId);
52
- if (parentId) {
53
- dependencyKeys.push(makeCacheDependencyKey({ documentId: parentId, relation: "children" }));
54
- }
55
- await siteContext.textCache.invalidate(dependencyKeys);
56
- }
57
- exports.invalidateDocumentInCache = invalidateDocumentInCache;
58
- async function invalidateDocumentRelationCache(siteContext, options) {
59
- await siteContext.textCache.invalidate([makeCacheDependencyKey(options)]);
60
- }
61
- exports.invalidateDocumentRelationCache = invalidateDocumentRelationCache;
62
- async function invalidateMultipleDocumentsInCache(siteContext, options) {
63
- const langs = siteContext.siteSchema.langs;
64
- const leafId = "leafId" in options
65
- ? options.leafId
66
- : await (0, load_documents_queries_1.getParentLeafIdOf)(siteContext, options.parentOfLeafId);
67
- if (leafId === undefined)
68
- return;
69
- const documentIds = langs.map((lang) => ({ lang, leafId }));
70
- const dependencyKeys = [makeCacheDependencyKey({ leafId })];
71
- for (const documentId of documentIds) {
72
- dependencyKeys.push(makeCacheDependencyKey({ documentId }));
73
- if (options.fully) {
74
- dependencyKeys.push(makeCacheDependencyKey({ documentId, perimeter: "slug" }), makeCacheDependencyKey({ documentId, relation: "children" }));
75
- }
76
- }
77
- const parentIds = "parentIds" in options && options.parentIds !== undefined
78
- ? options.parentIds
79
- : await (0, load_documents_queries_1.getParentDocumentIdsOf)(siteContext, {
80
- langs,
81
- leafId,
82
- });
83
- dependencyKeys.push(...parentIds.map((parentId) => makeCacheDependencyKey({ documentId: parentId, relation: "children" })));
84
- await siteContext.textCache.invalidate(dependencyKeys);
85
- }
86
- exports.invalidateMultipleDocumentsInCache = invalidateMultipleDocumentsInCache;
87
- //# sourceMappingURL=text-cache.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"text-cache.js","sourceRoot":"","sources":["../../src/common/text-cache.ts"],"names":[],"mappings":";;;AAAA,yDAA0E;AAC1E,4FAIyD;AAGzD,SAAgB,sBAAsB,CACpC,OAIsB;IAEtB,IAAI,QAAQ,IAAI,OAAO,EAAE,CAAC;QACxB,IAAI,UAAU,IAAI,OAAO,IAAI,OAAO,CAAC,QAAQ,KAAK,SAAS,EAAE,CAAC;YAC5D,MAAM,EAAE,MAAM,EAAE,gBAAgB,EAAE,GAAG,OAAO,CAAC;YAC7C,OAAO,KAAK,MAAM,YAAY,gBAAgB,EAAE,CAAC;QACnD,CAAC;QACD,OAAO,KAAK,OAAO,CAAC,MAAM,EAAE,CAAC;IAC/B,CAAC;IAED,MAAM,SAAS,GAAG,IAAA,8BAAe,EAAC,OAAO,CAAC,UAAU,CAAC,CAAC;IACtD,IAAI,UAAU,IAAI,OAAO;QAAE,OAAO,GAAG,SAAS,IAAI,OAAO,CAAC,QAAQ,EAAE,CAAC;IACrE,IAAI,OAAO,CAAC,SAAS;QAAE,OAAO,GAAG,SAAS,IAAI,OAAO,CAAC,SAAS,EAAE,CAAC;IAClE,OAAO,SAAS,CAAC;AACnB,CAAC;AAnBD,wDAmBC;AAMD,SAAgB,YAAY,CAAC,OAK5B;IACC,MAAM,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,GAAG,OAAO,CAAC;IAClD,IAAI,IAAI,KAAK,MAAM;QAAE,OAAO,GAAG,IAAI,IAAI,GAAG,EAAE,CAAC;IAC7C,IAAI,IAAI,KAAK,KAAK;QAAE,OAAO,GAAG,IAAI,IAAI,GAAG,EAAE,CAAC;IAC5C,IAAI,IAAI,KAAK,UAAU;QAAE,OAAO,GAAG,IAAI,IAAI,MAAM,EAAE,CAAC;IACpD,IAAI,UAAU;QAAE,OAAO,GAAG,IAAI,IAAI,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,QAAQ,EAAE,UAAU,EAAE,CAAC,CAC7D,CAAC;QACJ,CAAC;IACH,CAAC;IAED,MAAM,SAAS,GACb,WAAW,IAAI,OAAO,IAAI,OAAO,CAAC,SAAS,KAAK,SAAS;QACvD,CAAC,CAAC,OAAO,CAAC,SAAS;QACnB,CAAC,CAAC,MAAM,IAAA,+CAAsB,EAAC,WAAW,EAAE;YACxC,KAAK;YACL,MAAM;SACP,CAAC,CAAC;IACT,cAAc,CAAC,IAAI,CACjB,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAC5B,sBAAsB,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,EAAE,CAAC,CACvE,CACF,CAAC;IAEF,MAAM,WAAW,CAAC,SAAS,CAAC,UAAU,CAAC,cAAc,CAAC,CAAC;AACzD,CAAC;AAzCD,gFAyCC"}
@@ -1,2 +0,0 @@
1
- import { TrackerReport } from "@paroicms/server-lib";
2
- export declare function trackerReportToMessage(report: TrackerReport, about: string): string;
@@ -1,27 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.trackerReportToMessage = void 0;
4
- function trackerReportToMessage(report, about) {
5
- const parts = [];
6
- if (report.main)
7
- parts.push(dbReportToMessage(report.main, "main"));
8
- if (report.medias)
9
- parts.push(dbReportToMessage(report.medias, "medias"));
10
- if (report["text-cache"])
11
- parts.push(dbReportToMessage(report["text-cache"], "text-cache"));
12
- if (report["image-cache"])
13
- parts.push(dbReportToMessage(report["image-cache"], "image-cache"));
14
- return `${about}: ${parts.join(" • ")}`;
15
- }
16
- exports.trackerReportToMessage = trackerReportToMessage;
17
- function dbReportToMessage(report, dbName) {
18
- const parts = [];
19
- if (report.read)
20
- parts.push(`read(${report.read})`);
21
- if (report.write)
22
- parts.push(`write(${report.write})`);
23
- if (report.delete)
24
- parts.push(`delete(${report.delete})`);
25
- return `${dbName}: ${parts.join(", ")}`;
26
- }
27
- //# s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AM,KAAK,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC;AAC1C,CAAC"}
package/dist/context.d.ts DELETED
@@ -1,29 +0,0 @@
1
- import { VariantName } from "@paroicms/server-image-cache-engine";
2
- import { SimpleTranslator } from "./helpers/simple-i18n";
3
- import { SiteConf } from "./site-context/site-conf";
4
- import { SiteSchemaLibrary } from "./site-schema/site-schema-lib-reader";
5
- import { Configuration } from "./typeonly/configuration-types";
6
- export declare const dbAnyLang = ".";
7
- export declare const packageDir: string;
8
- export declare const appVersion: any, appName: any;
9
- export declare const typeValidator: import("@typeonly/validator").TypeOnlyValidator;
10
- export declare const appConf: Configuration;
11
- export declare const platformLog: import("./share/pino-app-log").PlatformLog;
12
- export declare const boAppVersion: {
13
- version: any;
14
- devTools: boolean;
15
- };
16
- export declare const langs: string[];
17
- export declare const langLabels: {
18
- [lang: string]: string;
19
- };
20
- export declare const thumbVariantName: VariantName;
21
- export declare let siteConfs: Map<string, SiteConf>;
22
- export declare function initSiteSchemaLib(val: SiteSchemaLibrary): void;
23
- export declare function getSiteSchemaLib(): SiteSchemaLibrary;
24
- export declare const jwtSecret: string;
25
- export declare const jwtExpiresIn = "180d";
26
- export declare const platformJwtSecret: string;
27
- export declare const platformAuthUrl: string;
28
- export declare let simpleI18n: SimpleTranslator;
29
- export declare function initializeContext(siteConfsVal: Map<string, SiteConf>): Promise<void>;
package/dist/context.js DELETED
@@ -1,60 +0,0 @@
1
- "use strict";
2
- var _a;
3
- Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.initializeContext = exports.simpleI18n = exports.platformAuthUrl = exports.platformJwtSecret = exports.jwtExpiresIn = exports.jwtSecret = exports.getSiteSchemaLib = exports.initSiteSchemaLib = exports.siteConfs = exports.thumbVariantName = exports.langLabels = exports.langs = exports.boAppVersion = exports.platformLog = exports.appConf = exports.typeValidator = exports.appName = exports.appVersion = exports.packageDir = exports.dbAnyLang = void 0;
5
- const validator_1 = require("@typeonly/validator");
6
- const path_1 = require("path");
7
- const configuration_helpers_1 = require("./helpers/configuration.helpers");
8
- const jwt_secret_helpers_1 = require("./helpers/jwt-secret.helpers");
9
- const simple_i18n_1 = require("./helpers/simple-i18n");
10
- const pino_app_log_1 = require("./share/pino-app-log");
11
- const read_configuration_1 = require("./share/read-configuration");
12
- exports.dbAnyLang = ".";
13
- exports.packageDir = (0, path_1.dirname)(__dirname);
14
- _a = require((0, path_1.join)(exports.packageDir, "package.json")), exports.appVersion = _a.version, exports.appName = _a.name;
15
- exports.typeValidator = (0, validator_1.createValidator)({
16
- bundle: require((0, path_1.join)(exports.packageDir, "dist", "types.to.json")),
17
- });
18
- exports.appConf = (0, read_configuration_1.readConfigFileSync)({
19
- typeValidator: exports.typeValidator,
20
- typeName: "Configuration",
21
- defaultFileName: "config.json",
22
- });
23
- exports.platformLog = (0, pino_app_log_1.createPlatformLog)(exports.appConf.log);
24
- exports.boAppVersion = {
25
- version: exports.appVersion,
26
- devTools: exports.appConf.devTools,
27
- };
28
- exports.langs = ["en", "fr"];
29
- exports.langLabels = {
30
- en: "English",
31
- fr: "Français",
32
- };
33
- exports.thumbVariantName = "x200x";
34
- let siteSchemaLib;
35
- function initSiteSchemaLib(val) {
36
- siteSchemaLib = val;
37
- }
38
- exports.initSiteSchemaLib = initSiteSchemaLib;
39
- function getSiteSchemaLib() {
40
- if (!siteSchemaLib) {
41
- throw new Error("siteSchemaLib is undefined.");
42
- }
43
- return siteSchemaLib;
44
- }
45
- exports.getSiteSchemaLib = getSiteSchemaLib;
46
- exports.jwtSecret = (0, jwt_secret_helpers_1.getJwtSecretSync)((0, path_1.join)((0, configuration_helpers_1.isMultiSiteConfiguration)(exports.appConf) ? exports.appConf.platformDataDir : exports.appConf.singleSite.dataDir, "jwt-secret.txt"));
47
- exports.jwtExpiresIn = "180d";
48
- exports.platformJwtSecret = (0, jwt_secret_helpers_1.getJwtSecretSync)((0, path_1.join)((0, configuration_helpers_1.isMultiSiteConfiguration)(exports.appConf) ? exports.appConf.platformDataDir : exports.appConf.singleSite.dataDir, "platform-jwt-secret.txt"));
49
- const protocol = exports.appConf.thisServer.https ? "https" : "http";
50
- exports.platformAuthUrl = `${protocol}://${exports.appConf.googleAuth.fqdn}${exports.appConf.thisServer.publicPort ? `:${exports.appConf.thisServer.publicPort}` : ""}/auth`;
51
- async function initializeContext(siteConfsVal) {
52
- exports.siteConfs = siteConfsVal;
53
- exports.simpleI18n = await (0, simple_i18n_1.createSimpleTranslator)({
54
- l10nDir: (0, path_1.join)(exports.packageDir, "locales"),
55
- langs: exports.langs,
56
- appLog: exports.platformLog,
57
- });
58
- }
59
- exports.initializeContext = initializeContext;
60
- //# sourceMappingURL=context.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"context.js","sourceRoot":"","sources":["../src/context.ts"],"names":[],"mappings":";;;;AACA,mDAAsD;AACtD,+BAAqC;AACrC,2EAA2E;AAC3E,qEAAgE;AAChE,uDAAiF;AACjF,uDAAyD;AACzD,mEAAgE;AAKnD,QAAA,SAAS,GAAG,GAAG,CAAC;AAEhB,QAAA,UAAU,GAAG,IAAA,cAAO,EAAC,SAAS,CAAC,CAAC;AAChC,KAAyC,OAAO,CAAC,IAAA,WAAI,EAAC,kBAAU,EAAE,cAAc,CAAC,CAAC,EAAvE,kBAAU,eAAQ,eAAO,WAA+C;AAEnF,QAAA,aAAa,GAAG,IAAA,2BAAe,EAAC;IAC3C,MAAM,EAAE,OAAO,CAAC,IAAA,WAAI,EAAC,kBAAU,EAAE,MAAM,EAAE,eAAe,CAAC,CAAC;CAC3D,CAAC,CAAC;AAEU,QAAA,OAAO,GAAG,IAAA,uCAAkB,EAAgB;IACvD,aAAa,EAAb,qBAAa;IACb,QAAQ,EAAE,eAAe;IACzB,eAAe,EAAE,aAAa;CAC/B,CAAC,CAAC;AACU,QAAA,WAAW,GAAG,IAAA,gCAAiB,EAAC,eAAO,CAAC,GAAG,CAAC,CAAC;AAC7C,QAAA,YAAY,GAAG;IAC1B,OAAO,EAAE,kBAAU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C,UAAU,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC;AAGnJ,KAAK,UAAU,iBAAiB,CAAC,YAAmC;IACzE,iBAAS,GAAG,YAAY,CAAC;IACzB,kBAAU,GAAG,MAAM,IAAA,oCAAsB,EAAC;QACxC,OAAO,EAAE,IAAA,WAAI,EAAC,kBAAU,EAAE,SAAS,CAAC;QACpC,KAAK,EAAL,aAAK;QACL,MAAM,EAAE,mBAAW;KACpB,CAAC,CAAC;AACL,CAAC;AAPD,8CAOC"}
@@ -1,16 +0,0 @@
1
- import { Request, Response } from "express";
2
- import { SiteContext } from "../site-context/site-context.types";
3
- export declare function serveContent({ res, status, contentType, html, or304, }: {
4
- res: Response;
5
- status?: number;
6
- contentType?: string;
7
- html: string;
8
- or304?: {
9
- lastModified: string;
10
- req: Request;
11
- };
12
- }): void;
13
- export declare function serve500Html(res: Response, _siteContext?: SiteContext): void;
14
- export declare function serve404NoSiteHtml(res: Response): void;
15
- export declare function serve304NotModified(res: Response): void;
16
- export declare function serve301Redirect(res: Response, redirectTo: string): void;
@@ -1,44 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.serve301Redirect = exports.serve304NotModified = exports.serve404NoSiteHtml = exports.serve500Html = exports.serveContent = void 0;
4
- function serveContent({ res, status, contentType, html, or304, }) {
5
- res.status(status ?? 200);
6
- res.setHeader("Content-Type", contentType ?? "text/html");
7
- if (or304) {
8
- res.append("Last-Modified", or304.lastModified);
9
- if (or304.req.headers["if-modified-since"] === or304.lastModified) {
10
- serve304NotModified(res);
11
- return;
12
- }
13
- }
14
- res.send(html);
15
- res.end();
16
- }
17
- exports.serveContent = serveContent;
18
- function serve500Html(res, _siteContext) {
19
- res.status(500);
20
- res.setHeader("Content-Type", "text/html");
21
- res.send(`<!DOCTYPE html>
22
- <p>Internal error</p>`);
23
- res.end();
24
- }
25
- exports.serve500Html = serve500Html;
26
- function serve404NoSiteHtml(res) {
27
- res.status(404);
28
- res.setHeader("Content-Type", "text/html");
29
- res.send(`<!DOCTYPE html>
30
- <p>404 Not Found</p>`);
31
- res.end();
32
- }
33
- exports.serve404NoSiteHtml = serve404NoSiteHtml;
34
- function serve304NotModified(res) {
35
- res.status(304);
36
- res.end();
37
- }
38
- exports.serve304NotModified = serve304NotModified;
39
- function serve301Redirect(res, redirectTo) {
40
- res.set("location", redirectTo);
41
- res.status(301).send();
42
- }
43
- exports.serve301Redirect = serve301Redirect;
44
- //# sourceMappingURL=http-helpers.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"http-helpers.js","sourceRoot":"","sources":["../../src/express/http-helpers.ts"],"names":[],"mappings":";;;AAGA,SAAgB,YAAY,CAAC,EAC3B,GAAG,EACH,MAAM,EACN,WAAW,EACX,IAAI,EACJ,KAAK,GAaN;IACC,GAAG,CAAC,MAAM,CAAC,MAAM,IAAI,GAAG,CAAC,CAAC;IAC1B,GAAG,CAAC,SAAS,CAAC,cAAc,EAAE,WAAW,IAAI,WAAW,CAAC,CAAC;IAC1D,IAAI,KAAK,EAAE,CAAC;QACV,GAAG,CAAC,MAAM,CAAC,eAAe,EAAE,KAAK,CAAC,YAAY,CAAC,CAAC;QAChD,IAAI,KAAK,CAAC,GAAG,CAAC,OAAO,CAAC,mBAAmB,CAAC,KAAK,KAAK,CAAC,YAAY,EAAE,CAAC;YAClE,mBAAmB,CAAC,GAAG,CAAC,CAAC;YACzB,OAAO;QACT,CAAC;IACH,CAAC;IACD,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACf,GAAG,CAAC,GAAG,EAAE,CAAC;AACZ,CAAC;AA9BD,oCA8BC;AAED,SAAgB,YAAY,CAAC,GAAa,EAAE,YAA0B;IACpE,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAChB,GAAG,CAAC,SAAS,CAAC,cAAc,EAAE,WAAW,CAAC,CAAC;IAC3C,GAAG,CAAC,IAAI,CAAC;sBACW,CAAC,CAAC;IACtB,GAAG,CAAC,GAAG,EAAE,CAAC;AACZ,CAAC;AAND,oCAMC;AAED,SAAgB,kBAAkB,CAAC,GAAa;IAC9C,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAChB,GAAG,CAAC,SAAS,CAAC,cAAc,EAAE,WAAW,CAAC,CAAC;IAC3C,GAAG,CAAC,IAAI,CAAC;qBACU,CAAC,CAAC;IACrB,GAAG,CAAC,GAAG,EAAE,CAAC;AACZ,CAAC;AAND,gDAMC;AAED,SAAgB,mBAAmB,CAAC,GAAa;IAC/C,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAChB,GAAG,CAAC,GAAG,EAAE,CAAC;AACZ,CAAC;AAHD,kDAGC;AAED,SAAgB,gBAAgB,CAAC,GAAa,EAAE,UAAkB;IAChE,GAAG,CAAC,GAAG,CAAC,UAAU,EAAE,UAAU,CAAC,CAAC;IAChC,GAAG,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,CAAC;AACzB,CAAC;AAHD,4CAGC"}
@@ -1,3 +0,0 @@
1
- import { Request, Response } from "express";
2
- export declare function themeAssetsMiddleware(req: Request, res: Response, next: () => void): Promise<void>;
3
- export declare function boMiddleware(req: Request, res: Response, next: () => void): Promise<void>;
@@ -1,114 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.boMiddleware = exports.themeAssetsMiddleware = void 0;
4
- const bo_1 = require("@paroicms/bo");
5
- const server_lib_1 = require("@paroicms/server-lib");
6
- const site_app_1 = require("@paroicms/site-app");
7
- const path_1 = require("path");
8
- const data_format_1 = require("../common/data-format");
9
- const serve_html_or_1 = require("../common/serve-html-or");
10
- const context_1 = require("../context");
11
- const site_context_1 = require("../site-context/site-context");
12
- const http_helpers_1 = require("./http-helpers");
13
- async function themeAssetsMiddleware(req, res, next) {
14
- let path = req.path;
15
- if (!path.startsWith("/assets/")) {
16
- next();
17
- return;
18
- }
19
- let siteContext;
20
- try {
21
- siteContext = await (0, site_context_1.getSiteContext)(req.hostname);
22
- }
23
- catch (error) {
24
- (0, http_helpers_1.serve404NoSiteHtml)(res);
25
- return;
26
- }
27
- let pathPrefix;
28
- let baseDir;
29
- if (path.startsWith("/assets/site-app/")) {
30
- pathPrefix = `${(0, data_format_1.getSiteAppBaseUrl)()}/`;
31
- baseDir = site_app_1.distDir;
32
- }
33
- else {
34
- pathPrefix = `${(0, data_format_1.getAssetsBaseUrl)(siteContext)}/`;
35
- baseDir = (0, path_1.join)(siteContext.themeDir, "assets");
36
- }
37
- if (!path.startsWith(pathPrefix)) {
38
- void render404Asset(siteContext, res);
39
- return;
40
- }
41
- path = path.substring(pathPrefix.length);
42
- try {
43
- res.sendFile(path, { root: baseDir, immutable: context_1.appConf.immutableAssets }, (error) => {
44
- if (!error)
45
- return;
46
- sendFileErrorHandler(error, siteContext, res, path);
47
- });
48
- }
49
- catch (error) {
50
- siteContext.siteLog.error(error);
51
- (0, http_helpers_1.serve500Html)(res, siteContext);
52
- }
53
- }
54
- exports.themeAssetsMiddleware = themeAssetsMiddleware;
55
- async function boMiddleware(req, res, next) {
56
- let path = req.path;
57
- if (req.method !== "GET" ||
58
- path.startsWith("/adm/api/v1") ||
59
- (path !== "/adm" && !path.startsWith("/adm/"))) {
60
- next();
61
- return;
62
- }
63
- let siteContext;
64
- try {
65
- siteContext = await (0, site_context_1.getSiteContext)(req.hostname);
66
- }
67
- catch (error) {
68
- (0, http_helpers_1.serve404NoSiteHtml)(res);
69
- return;
70
- }
71
- try {
72
- path = path.substring("/adm/".length);
73
- if (path === "")
74
- path = "index.html";
75
- if (!(await (0, server_lib_1.pathExists)((0, path_1.join)(bo_1.distDir, path)))) {
76
- path = "index.html";
77
- }
78
- res.sendFile(path, { root: bo_1.distDir }, (error) => {
79
- if (!error)
80
- return;
81
- sendFileErrorHandler(error, siteContext, res, path);
82
- });
83
- }
84
- catch (error) {
85
- siteContext.siteLog.error(error);
86
- (0, http_helpers_1.serve500Html)(res, siteContext);
87
- }
88
- }
89
- exports.boMiddleware = boMiddleware;
90
- function sendFileErrorHandler(error, siteContext, res, path) {
91
- if ("statusCode" in error && error.statusCode === 404) {
92
- void render404Asset(siteContext, res);
93
- }
94
- else {
95
- if ("code" in error) {
96
- if (error.code === "ECONNABORTED") {
97
- res.end();
98
- return;
99
- }
100
- siteContext.siteLog.error(`failed to serve file '${path}':`, error.code, error);
101
- }
102
- (0, http_helpers_1.serve500Html)(res, siteContext);
103
- }
104
- }
105
- async function render404Asset(siteContext, res) {
106
- try {
107
- await (0, serve_html_or_1.render404Html)(siteContext, res);
108
- }
109
- catch (error) {
110
- siteContext.siteLog.error("failed to render 404", error);
111
- (0, http_helpers_1.serve500Html)(res, siteContext);
112
- }
113
- }
114
- //# sourceMappingURL=static-middlewares.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"static-middlewares.js","sourceRoot":"","sources":["../../src/express/static-middlewares.ts"],"names":[],"mappings":";;;AAAA,qCAAoD;AACpD,qDAAkD;AAClD,iDAA+D;AAE/D,+BAA4B;AAC5B,uDAA4E;AAC5E,2DAAwD;AACxD,wCAAqC;AACrC,+DAA8D;AAE9D,iDAAkE;AAE3D,KAAK,UAAU,qBAAqB,CAAC,GAAY,EAAE,GAAa,EAAE,IAAgB;IACvF,IAAI,IAAI,GAAG,GAAG,CAAC,IAAI,CAAC;IACpB,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,EAAE,CAAC;QACjC,IAAI,EAAE,CAAC;QACP,OAAO;IACT,CAAC;IAED,IAAI,WAAwB,CAAC;IAC7B,IAAI,CAAC;QACH,WAAW,GAAG,MAAM,IAAA,6BAAc,EAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;IACnD,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,IAAA,iCAAkB,EAAC,GAAG,CAAC,CAAC;QACxB,OAAO;IACT,CAAC;IAED,IAAI,UAAkB,CAAC;IACvB,IAAI,OAAe,CAAC;IACpB,IAA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EAAE,CAAC;QACtD,KAAK,cAAc,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC;IACxC,CAAC;SAAM,CAAC;QACN,IAAI,MAAM,IAAI,KAAK,EAAE,CAAC;YACpB,IAAI,KAAK,CAAC,IAAI,KAAK,cAAc,EAAE,CAAC;gBAClC,GAAG,CAAC,GAAG,EAAE,CAAC;gBACV,OAAO;YACT,CAAC;YACD,WAAW,CAAC,OAAO,CAAC,KAAK,CAAC,yBAAyB,IAAI,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,CAAC;QAClF,CAAC;QACD,IAAA,2BAAY,EAAC,GAAG,EAAE,WAAW,CAAC,CAAC;IACjC,CAAC;AACH,CAAC;AAED,KAAK,UAAU,cAAc,CAAC,WAAwB,EAAE,GAAa;IACnE,IAAI,CAAC;QACH,MAAM,IAAA,6BAAa,EAAC,WAAW,EAAE,GAAG,CAAC,CAAC;IACxC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,WAAW,CAAC,OAAO,CAAC,KAAK,CAAC,sBAAsB,EAAE,KAAK,CAAC,CAAC;QACzD,IAAA,2BAAY,EAAC,GAAG,EAAE,WAAW,CAAC,CAAC;IACjC,CAAC;AACH,CAAC"}
@@ -1,2 +0,0 @@
1
- import { Configuration, MultiSiteConfiguration } from "../typeonly/configuration-types";
2
- export declare function isMultiSiteConfiguration(appConf: Configuration): appConf is MultiSiteConfiguration;
@@ -1,8 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.isMultiSiteConfiguration = void 0;
4
- function isMultiSiteConfiguration(appConf) {
5
- return "platformDataDir" in appConf;
6
- }
7
- exports.isMultiSiteConfiguration = isMultiSiteConfiguration;
8
- //# sourceMappingURL=configuration.helpers.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"configuration.helpers.js","sourceRoot":"","sources":["../../src/helpers/configuration.helpers.ts"],"names":[],"mappings":";;;AAEA,SAAgB,wBAAwB,CACtC,OAAsB;IAEtB,OAAO,iBAAiB,IAAI,OAAO,CAAC;AACtC,CAAC;AAJD,4DAIC"}
@@ -1,2 +0,0 @@
1
- export declare function toExcerptString(rawText: string): string;
2
- export declare function truncExcerptToWord(input: string, maxLength: number): string;
@@ -1,31 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.truncExcerptToWord = exports.toExcerptString = void 0;
4
- function toExcerptString(rawText) {
5
- return rawText.replaceAll(/[.…,;:!?\s]+/g, replacer).trim();
6
- }
7
- exports.toExcerptString = toExcerptString;
8
- function replacer(match) {
9
- return match === " " ? " " : " ";
10
- }
11
- function truncExcerptToWord(input, maxLength) {
12
- const hasEllipsis = input.charAt(input.length - 1) === "…";
13
- const excerpt = toExcerptString(input);
14
- let sepIndex = maxLength;
15
- if (sepIndex >= excerpt.length) {
16
- sepIndex = excerpt.length;
17
- }
18
- else {
19
- for (sepIndex = maxLength; sepIndex >= 0; --sepIndex) {
20
- if (excerpt.charAt(sepIndex) === " ")
21
- break;
22
- }
23
- }
24
- const result = excerpt.substring(0, sepIndex);
25
- if (hasEllipsis || sepIndex < excerpt.length) {
26
- return `${result}…`;
27
- }
28
- return result;
29
- }
30
- exports.truncExcerptToWord = truncExcerptToWord;
31
- //# sourceMappingURL=excerpt.helpers.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"excerpt.helpers.js","sourceRoot":"","sources":["../../src/helpers/excerpt.helpers.ts"],"names":[],"mappings":";;;AACA,SAAgB,eAAe,CAAC,OAAe;IAC7C,OAAO,OAAO,CAAC,UAAU,CAAC,eAAe,EAAE,QAAQ,CAAC,CAAC,IAAI,EAAE,CAAC;AAC9D,CAAC;AAFD,0CAEC;AAED,SAAS,QAAQ,CAAE,KAAa;IAC9B,OAAO,KAAK,KAAK,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC;AACnC,CAAC;AAED,SAAgB,kBAAkB,CAAC,KAAa,EAAE,SAAiB;IACjE,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,GAAG,CAAC;IAC3D,MAAM,OAAO,GAAI,eAAe,CAAC,KAAK,CAAC,CAAC;IAExC,IAAI,QAAQ,GAAG,SAAS,CAAC;IACzB,IAAI,QAAQ,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;QAC/B,QAAQ,GAAG,OAAO,CAAC,MAAM,CAAC;IAC5B,CAAC;SAAM,CAAC;QACN,KAAK,QAAQ,GAAG,SAAS,EAAE,QAAQ,IAAI,CAAC,EAAE,EAAE,QAAQ,EAAE,CAAC;YACrD,IAAI,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,GAAG;gBAAE,MAAM;QAC9C,CAAC;IACH,CAAC;IACD,MAAM,MAAM,GAAG,OAAO,CAAC,SAAS,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC;IAE9C,IAAI,WAAW,IAAI,QAAQ,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;QAC7C,OAAO,GAAG,MAAM,GAAG,CAAC;IACtB,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AAnBD,gDAmBC"}
@@ -1,2 +0,0 @@
1
- export declare function getJwtSecretSync(file: string): string;
2
- export declare function makeSecret(length: number): string;
@@ -1,30 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.makeSecret = exports.getJwtSecretSync = void 0;
4
- const fs_1 = require("fs");
5
- function getJwtSecretSync(file) {
6
- if (!pathExistsSync(file)) {
7
- (0, fs_1.writeFileSync)(file, makeSecret(50), "utf8");
8
- }
9
- return (0, fs_1.readFileSync)(file, "utf8");
10
- }
11
- exports.getJwtSecretSync = getJwtSecretSync;
12
- function makeSecret(length) {
13
- const characters = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
14
- let result = "";
15
- for (let i = 0; i < length; i++) {
16
- result += characters.charAt(Math.floor(Math.random() * characters.length));
17
- }
18
- return result;
19
- }
20
- exports.makeSecret = makeSecret;
21
- function pathExistsSync(path) {
22
- try {
23
- (0, fs_1.accessSync)(path);
24
- return true;
25
- }
26
- catch {
27
- return false;
28
- }
29
- }
30
- //# sourceMappingURL=jwt-secret.helpers.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"jwt-secret.helpers.js","sourceRoot":"","sources":["../../src/helpers/jwt-secret.helpers.ts"],"names":[],"mappings":";;;AAAA,2BAA6D;AAE7D,SAAgB,gBAAgB,CAAC,IAAY;IAC3C,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,EAAE,CAAC;QAC1B,IAAA,kBAAa,EAAC,IAAI,EAAE,UAAU,CAAC,EAAE,CAAC,EAAE,MAAM,CAAC,CAAC;IAC9C,CAAC;IACD,OAAO,IAAA,iBAAY,EAAC,IAAI,EAAE,MAAM,CAAC,CAAC;AACpC,CAAC;AALD,4CAKC;AAED,SAAgB,UAAU,CAAC,MAAc;IACvC,MAAM,UAAU,GAAG,gEAAgE,CAAC;IACpF,IAAI,MAAM,GAAG,EAAE,CAAC;IAChB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QAChC,MAAM,IAAI,UAAU,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,EAAE,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;IAC7E,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC;AAPD,gCAOC;AAED,SAAS,cAAc,CAAC,IAAY;IAClC,IAAI,CAAC;QACH,IAAA,eAAU,EAAC,IAAI,CAAC,CAAC;QACjB,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC"}
@@ -1,9 +0,0 @@
1
- import { SiteSchema } from "@paroicms/anywhere-lib";
2
- export declare function getDocumentLeafTypeLabel(siteSchema: SiteSchema, options: {
3
- leafType: string;
4
- lang: string;
5
- }): string;
6
- export declare function getPartLeafTypeLabel(siteSchema: SiteSchema, options: {
7
- leafType: string;
8
- lang: string;
9
- }): string;
@@ -1,14 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getPartLeafTypeLabel = exports.getDocumentLeafTypeLabel = void 0;
4
- function getDocumentLeafTypeLabel(siteSchema, options) {
5
- const label = siteSchema.l10n[options.lang]?.documentTypes[options.leafType]?.label;
6
- return typeof label === "string" ? label : options.leafType;
7
- }
8
- exports.getDocumentLeafTypeLabel = getDocumentLeafTypeLabel;
9
- function getPartLeafTypeLabel(siteSchema, options) {
10
- const label = siteSchema.l10n[options.lang]?.partTypes[options.leafType]?.label;
11
- return typeof label === "string" ? label : options.leafType;
12
- }
13
- exports.getPartLeafTypeLabel = getPartLeafTypeLabel;
14
- //# sourceMappingURL=label-translator.helper.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"label-translator.helper.js","sourceRoot":"","sources":["../../src/helpers/label-translator.helper.ts"],"names":[],"mappings":";;;AAEA,SAAgB,wBAAwB,CACtC,UAAsB,EACtB,OAA2C;IAE3C,MAAM,KAAK,GAAG,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,aAAa,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,KAAK,CAAC;IACpF,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;AAC9D,CAAC;AAND,4DAMC;AAED,SAAgB,oBAAoB,CAClC,UAAsB,EACtB,OAA2C;IAE3C,MAAM,KAAK,GAAG,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,SAAS,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE,KAAK,CAAC;IAChF,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;AAC9D,CAAC;AAND,oDAMC"}
@@ -1,2 +0,0 @@
1
- export declare function hashPassword(password: string): Promise<string>;
2
- export declare function comparePassword(password: string, passwordHash: string): Promise<boolean>;