qarpeo 0.1.18 → 0.1.21

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 (237) hide show
  1. package/README.md +96 -96
  2. package/dist/chunks/auth-schema.mjs +3 -1
  3. package/dist/chunks/wrangler.mjs +22 -3
  4. package/dist/cli/index.mjs +448 -221
  5. package/dist/fate/index.d.ts +29 -22
  6. package/dist/fate/index.mjs +1 -3
  7. package/dist/module.d.ts +1 -1
  8. package/dist/module.mjs +103 -82
  9. package/dist/runtime/ai.d.ts +2 -2
  10. package/dist/runtime/app/components/BlobImage.vue +119 -107
  11. package/dist/runtime/app/components/CMSBlocks.vue +104 -93
  12. package/dist/runtime/app/components/CMSContent.vue +24 -23
  13. package/dist/runtime/app/components/CMSImage.vue +49 -49
  14. package/dist/runtime/app/components/CMSLocaleSwitcher.vue +110 -110
  15. package/dist/runtime/app/components/CMSPreviewBanner.vue +83 -79
  16. package/dist/runtime/app/components/CMSVersionBanner.vue +53 -49
  17. package/dist/runtime/app/components/CMSVersionSwitcher.vue +140 -140
  18. package/dist/runtime/app/components/ContentRenderer.vue +83 -80
  19. package/dist/runtime/app/components/FileUpload.vue +200 -196
  20. package/dist/runtime/app/components/ImpersonationBanner.vue +61 -57
  21. package/dist/runtime/app/components/QarpeoWelcome.vue +84 -84
  22. package/dist/runtime/app/components/SignedIn.vue +13 -13
  23. package/dist/runtime/app/components/SignedOut.vue +13 -13
  24. package/dist/runtime/app/components/shiki.css +34 -34
  25. package/dist/runtime/app/composables/ai.d.ts +22 -22
  26. package/dist/runtime/app/composables/ai.mjs +3 -7
  27. package/dist/runtime/app/composables/analytics.mjs +1 -1
  28. package/dist/runtime/app/composables/api-tokens.mjs +1 -1
  29. package/dist/runtime/app/composables/auth.d.ts +6 -7
  30. package/dist/runtime/app/composables/auth.mjs +6 -3
  31. package/dist/runtime/app/composables/chat.mjs +3 -7
  32. package/dist/runtime/app/composables/cms-preview.d.ts +3 -3
  33. package/dist/runtime/app/composables/cms-preview.mjs +1 -1
  34. package/dist/runtime/app/composables/cms.d.ts +3 -5
  35. package/dist/runtime/app/composables/cms.mjs +2 -2
  36. package/dist/runtime/app/composables/docs-version.d.ts +8 -7
  37. package/dist/runtime/app/composables/docs-version.mjs +3 -3
  38. package/dist/runtime/app/composables/impersonation.mjs +1 -1
  39. package/dist/runtime/app/composables/notifications.d.ts +5 -5
  40. package/dist/runtime/app/composables/notifications.mjs +4 -5
  41. package/dist/runtime/app/composables/organization.mjs +1 -1
  42. package/dist/runtime/app/composables/passkey.mjs +1 -1
  43. package/dist/runtime/app/composables/passwordless.mjs +1 -1
  44. package/dist/runtime/app/composables/payments.d.ts +2 -1
  45. package/dist/runtime/app/composables/payments.mjs +1 -1
  46. package/dist/runtime/app/composables/realtime.d.ts +13 -13
  47. package/dist/runtime/app/composables/realtime.mjs +2 -2
  48. package/dist/runtime/app/composables/resumable-upload.d.ts +11 -11
  49. package/dist/runtime/app/composables/resumable-upload.mjs +1 -1
  50. package/dist/runtime/app/composables/site.mjs +1 -1
  51. package/dist/runtime/app/composables/storage.d.ts +151 -11
  52. package/dist/runtime/app/composables/storage.mjs +291 -33
  53. package/dist/runtime/app/composables/turnstile.mjs +1 -1
  54. package/dist/runtime/app/composables/two-factor.mjs +1 -1
  55. package/dist/runtime/app/pages/devtools/agents.vue +716 -716
  56. package/dist/runtime/app/pages/devtools/analytics.vue +616 -616
  57. package/dist/runtime/app/pages/devtools/auth.vue +381 -350
  58. package/dist/runtime/app/pages/devtools/blob.vue +743 -744
  59. package/dist/runtime/app/pages/devtools/db.vue +545 -545
  60. package/dist/runtime/app/pages/devtools/domains.vue +771 -771
  61. package/dist/runtime/app/pages/devtools/kv.vue +827 -828
  62. package/dist/runtime/app/pages/devtools/logs.vue +649 -653
  63. package/dist/runtime/app/pages/devtools/mail.vue +388 -388
  64. package/dist/runtime/app/pages/devtools/overview.vue +391 -389
  65. package/dist/runtime/app/pages/devtools/realtime.vue +89 -27
  66. package/dist/runtime/app/pages/devtools/security.vue +20 -5
  67. package/dist/runtime/app/pages/devtools/settings.vue +559 -559
  68. package/dist/runtime/app/pages/devtools/tasks.vue +26 -10
  69. package/dist/runtime/app/pages/devtools.vue +176 -176
  70. package/dist/runtime/app/plugins/seo.mjs +1 -1
  71. package/dist/runtime/app/plugins/shortcuts.client.d.ts +1 -4
  72. package/dist/runtime/app/public/sw-notifications.mjs +47 -52
  73. package/dist/runtime/blob.mjs +11 -4
  74. package/dist/runtime/browser.d.ts +1 -1
  75. package/dist/runtime/browser.mjs +12 -2
  76. package/dist/runtime/cache.d.ts +2 -1
  77. package/dist/runtime/kv.mjs +4 -1
  78. package/dist/runtime/providers/qarpeo.d.ts +3 -3
  79. package/dist/runtime/server/durable-objects/agent.mjs +1 -1
  80. package/dist/runtime/server/durable-objects/room.d.ts +2 -2
  81. package/dist/runtime/server/durable-objects/room.mjs +5 -5
  82. package/dist/runtime/server/middleware/devtools.mjs +6 -2
  83. package/dist/runtime/server/plugins/cms.d.ts +4 -2
  84. package/dist/runtime/server/plugins/dev-proxy.mjs +1 -1
  85. package/dist/runtime/server/routes/__qarpeo/agents/chat.post.d.ts +2 -2
  86. package/dist/runtime/server/routes/__qarpeo/agents/chat.post.mjs +4 -1
  87. package/dist/runtime/server/routes/__qarpeo/analytics/events.get.d.ts +1 -4
  88. package/dist/runtime/server/routes/__qarpeo/analytics/summary.get.d.ts +2 -2
  89. package/dist/runtime/server/routes/__qarpeo/analytics/summary.get.mjs +5 -1
  90. package/dist/runtime/server/routes/__qarpeo/db/tables.get.d.ts +2 -2
  91. package/dist/runtime/server/routes/__qarpeo/db/tables.get.mjs +1 -1
  92. package/dist/runtime/server/routes/__qarpeo/logs.get.d.ts +4 -1
  93. package/dist/runtime/server/routes/__qarpeo/mail/track/click/[id].get.mjs +1 -1
  94. package/dist/runtime/server/routes/__qarpeo/mail/track/open/[id].get.mjs +2 -2
  95. package/dist/runtime/server/routes/__qarpeo/overview.get.d.ts +2 -2
  96. package/dist/runtime/server/routes/__qarpeo/realtime/broadcast.post.d.ts +2 -2
  97. package/dist/runtime/server/routes/__qarpeo/realtime/broadcast.post.mjs +1 -1
  98. package/dist/runtime/server/routes/__qarpeo/realtime/clear.post.d.ts +1 -4
  99. package/dist/runtime/server/routes/__qarpeo/realtime/clear.post.mjs +1 -1
  100. package/dist/runtime/server/routes/__qarpeo/realtime/disconnect.post.d.ts +1 -4
  101. package/dist/runtime/server/routes/__qarpeo/realtime/disconnect.post.mjs +1 -1
  102. package/dist/runtime/server/routes/__qarpeo/realtime/room.get.d.ts +2 -2
  103. package/dist/runtime/server/routes/__qarpeo/realtime/rooms.get.d.ts +2 -2
  104. package/dist/runtime/server/routes/__qarpeo/security/analytics.get.d.ts +2 -2
  105. package/dist/runtime/server/routes/__qarpeo/security/ban.post.d.ts +1 -4
  106. package/dist/runtime/server/routes/__qarpeo/security/clear.post.d.ts +1 -4
  107. package/dist/runtime/server/routes/__qarpeo/security/unban.post.d.ts +1 -4
  108. package/dist/runtime/server/routes/__qarpeo/settings.get.mjs +1 -1
  109. package/dist/runtime/server/routes/__qarpeo/tasks/run.post.mjs +3 -1
  110. package/dist/runtime/server/routes/agents/[agent]/chat.post.mjs +8 -2
  111. package/dist/runtime/server/routes/agents/[agent]/clear.post.mjs +8 -2
  112. package/dist/runtime/server/routes/agents/[agent]/history.get.mjs +8 -2
  113. package/dist/runtime/server/routes/ai/embed.post.d.ts +1 -4
  114. package/dist/runtime/server/routes/ai/search.post.d.ts +2 -2
  115. package/dist/runtime/server/routes/auth/account.delete.mjs +1 -1
  116. package/dist/runtime/server/routes/auth/handler.mjs +6 -1
  117. package/dist/runtime/server/routes/auth/magic-link/verify.get.mjs +1 -1
  118. package/dist/runtime/server/routes/auth/organization/members/[id].delete.mjs +7 -1
  119. package/dist/runtime/server/routes/auth/otp/verify.post.mjs +1 -1
  120. package/dist/runtime/server/routes/auth/sso/login.get.mjs +7 -1
  121. package/dist/runtime/server/routes/auth/sso/oidc/callback.get.mjs +8 -2
  122. package/dist/runtime/server/routes/auth/sso/saml/acs.post.mjs +7 -2
  123. package/dist/runtime/server/routes/auth/webauthn/login/options.post.mjs +1 -1
  124. package/dist/runtime/server/routes/auth/webauthn/login/verify.post.mjs +7 -2
  125. package/dist/runtime/server/routes/auth/webauthn/register/options.post.mjs +6 -1
  126. package/dist/runtime/server/routes/auth/webauthn/register/verify.post.mjs +6 -1
  127. package/dist/runtime/server/routes/browser/crawl.post.d.ts +1 -2
  128. package/dist/runtime/server/routes/browser/invoice.post.d.ts +1 -2
  129. package/dist/runtime/server/routes/browser/og-image.post.d.ts +2 -2
  130. package/dist/runtime/server/routes/browser/pdf.post.d.ts +1 -2
  131. package/dist/runtime/server/routes/browser/pdf.post.mjs +6 -1
  132. package/dist/runtime/server/routes/browser/screenshot.post.d.ts +2 -2
  133. package/dist/runtime/server/routes/browser/screenshot.post.mjs +5 -1
  134. package/dist/runtime/server/routes/cms/components/index.get.d.ts +2 -2
  135. package/dist/runtime/server/routes/cms/preview/disable.get.d.ts +4 -3
  136. package/dist/runtime/server/routes/cms/preview/enable.get.d.ts +8 -8
  137. package/dist/runtime/server/routes/cms/search.get.mjs +1 -1
  138. package/dist/runtime/server/routes/cms/webhooks/[provider].post.d.ts +7 -7
  139. package/dist/runtime/server/routes/cms/webhooks/[provider].post.mjs +9 -2
  140. package/dist/runtime/server/routes/docs/search.get.d.ts +9 -9
  141. package/dist/runtime/server/routes/fate.mjs +5 -8
  142. package/dist/runtime/server/routes/mail/bounce.post.d.ts +2 -2
  143. package/dist/runtime/server/routes/mail/unsubscribe.d.ts +2 -2
  144. package/dist/runtime/server/routes/mail/webhooks.post.d.ts +2 -2
  145. package/dist/runtime/server/routes/mail/webhooks.post.mjs +7 -1
  146. package/dist/runtime/server/routes/payments/usage.get.d.ts +8 -8
  147. package/dist/runtime/server/routes/payments/usage.post.d.ts +2 -2
  148. package/dist/runtime/server/routes/realtime/history.delete.d.ts +4 -3
  149. package/dist/runtime/server/routes/realtime/history.get.d.ts +7 -6
  150. package/dist/runtime/server/routes/realtime/ws.get.mjs +6 -1
  151. package/dist/runtime/server/routes/robots.txt.get.mjs +1 -1
  152. package/dist/runtime/server/routes/sitemap.xml.get.mjs +2 -1
  153. package/dist/runtime/server/routes/storage/multipart/abort.post.d.ts +2 -2
  154. package/dist/runtime/server/routes/storage/multipart/complete.post.d.ts +2 -2
  155. package/dist/runtime/server/routes/storage/multipart/complete.post.mjs +2 -2
  156. package/dist/runtime/server/routes/storage/multipart/create.post.d.ts +2 -2
  157. package/dist/runtime/server/routes/storage/multipart/create.post.mjs +7 -3
  158. package/dist/runtime/server/routes/storage/multipart/part.put.d.ts +2 -2
  159. package/dist/runtime/server/routes/storage/multipart/part.put.mjs +1 -1
  160. package/dist/runtime/server/routes/tenants/[tenant]/domains/[domain]/index.delete.mjs +2 -4
  161. package/dist/runtime/server/routes/tenants/[tenant]/domains/[domain]/verify.post.mjs +2 -4
  162. package/dist/runtime/server/routes/tenants/[tenant]/domains/index.get.mjs +1 -1
  163. package/dist/runtime/server/routes/tenants/[tenant]/domains/index.post.mjs +2 -4
  164. package/dist/runtime/server/tasks/cms/publish.mjs +1 -1
  165. package/dist/runtime/server/utils/ai.d.ts +9 -9
  166. package/dist/runtime/server/utils/ai.mjs +3 -3
  167. package/dist/runtime/server/utils/auth.d.ts +12 -16
  168. package/dist/runtime/server/utils/auth.mjs +15 -9
  169. package/dist/runtime/server/utils/bots.mjs +21 -7
  170. package/dist/runtime/server/utils/browser-utils.d.ts +44 -41
  171. package/dist/runtime/server/utils/browser-utils.mjs +14 -4
  172. package/dist/runtime/server/utils/cache.d.ts +5 -5
  173. package/dist/runtime/server/utils/cms/common.d.ts +26 -0
  174. package/dist/runtime/server/utils/cms/common.mjs +68 -0
  175. package/dist/runtime/server/utils/cms/git.d.ts +24 -0
  176. package/dist/runtime/server/utils/cms/git.mjs +240 -0
  177. package/dist/runtime/server/utils/cms/markdown.d.ts +22 -0
  178. package/dist/runtime/server/utils/cms/markdown.mjs +92 -0
  179. package/dist/runtime/server/utils/cms/path.d.ts +51 -0
  180. package/dist/runtime/server/utils/cms/path.mjs +127 -0
  181. package/dist/runtime/server/utils/cms/search.d.ts +22 -0
  182. package/dist/runtime/server/utils/cms/search.mjs +221 -0
  183. package/dist/runtime/server/utils/cms-events.d.ts +1 -1
  184. package/dist/runtime/server/utils/cms-events.mjs +2 -2
  185. package/dist/runtime/server/utils/cms-filter.mjs +2 -2
  186. package/dist/runtime/server/utils/cms.d.ts +17 -149
  187. package/dist/runtime/server/utils/cms.mjs +52 -761
  188. package/dist/runtime/server/utils/config.d.ts +5 -4
  189. package/dist/runtime/server/utils/domains.mjs +7 -4
  190. package/dist/runtime/server/utils/email-templates.d.ts +10 -7
  191. package/dist/runtime/server/utils/email-templates.mjs +20 -5
  192. package/dist/runtime/server/utils/feed.d.ts +2 -2
  193. package/dist/runtime/server/utils/feed.mjs +3 -1
  194. package/dist/runtime/server/utils/mail-suppression.d.ts +8 -24
  195. package/dist/runtime/server/utils/mail-suppression.mjs +2 -2
  196. package/dist/runtime/server/utils/mail.d.ts +7 -8
  197. package/dist/runtime/server/utils/mail.mjs +17 -12
  198. package/dist/runtime/server/utils/multipart-store.d.ts +2 -2
  199. package/dist/runtime/server/utils/notifications.d.ts +9 -23
  200. package/dist/runtime/server/utils/organization.mjs +4 -12
  201. package/dist/runtime/server/utils/passwordless.mjs +1 -1
  202. package/dist/runtime/server/utils/payments.d.ts +2 -6
  203. package/dist/runtime/server/utils/payments.mjs +1 -1
  204. package/dist/runtime/server/utils/queue.d.ts +21 -31
  205. package/dist/runtime/server/utils/rag.d.ts +4 -4
  206. package/dist/runtime/server/utils/rag.mjs +8 -8
  207. package/dist/runtime/server/utils/realtime-store.d.ts +2 -2
  208. package/dist/runtime/server/utils/realtime.d.ts +26 -28
  209. package/dist/runtime/server/utils/scheduled-task.d.ts +1 -3
  210. package/dist/runtime/server/utils/security-store.d.ts +2 -2
  211. package/dist/runtime/server/utils/session.d.ts +9 -11
  212. package/dist/runtime/server/utils/sso.d.ts +9 -15
  213. package/dist/runtime/server/utils/sso.mjs +4 -8
  214. package/dist/runtime/server/utils/storage.d.ts +19 -2
  215. package/dist/runtime/server/utils/storage.mjs +36 -7
  216. package/dist/runtime/server/utils/tenant.mjs +3 -1
  217. package/dist/runtime/server/utils/turnstile.d.ts +3 -5
  218. package/dist/runtime/server/utils/vapid.d.ts +5 -8
  219. package/dist/runtime/server/utils/vapid.mjs +26 -13
  220. package/dist/runtime/service.d.ts +13 -13
  221. package/dist/runtime/service.mjs +4 -2
  222. package/dist/runtime/test-utils.d.ts +20 -30
  223. package/dist/runtime/test-utils.mjs +5 -4
  224. package/dist/runtime/types/auth-globals.d.ts +14 -14
  225. package/dist/runtime/types/imports.d.ts +82 -82
  226. package/dist/runtime/types/index.d.ts +2 -2
  227. package/dist/runtime/types/r2.d.ts +5 -0
  228. package/dist/runtime/types/service.d.ts +11 -18
  229. package/dist/types.d.ts +100 -107
  230. package/dist/utils/auth-schema.d.ts +2 -2
  231. package/dist/utils/cms-sources.d.ts +3 -3
  232. package/dist/utils/local-db.d.ts +3 -3
  233. package/dist/utils/notifications-schema.d.ts +1 -3
  234. package/dist/utils/pkg.d.ts +7 -0
  235. package/dist/utils/queue.d.ts +3 -3
  236. package/dist/utils/tasks.d.ts +3 -2
  237. package/package.json +11 -8
@@ -1,29 +1,36 @@
1
1
  /**
2
- * qarpeo/fate — DX helpers for integrating Fate Relay-style data fetching.
2
+ * Qarpeo/fate — DX helpers for integrating Fate Relay-style data fetching.
3
3
  *
4
4
  * Usage in `server/fate/views.ts`:
5
+ *
5
6
  * ```ts
6
- * import { defineFateViews } from 'qarpeo/fate'
7
- * import type { InferSelectModel } from 'drizzle-orm'
8
- * import { recipes } from '../db/schema/recipes'
7
+ * import { defineFateViews } from "qarpeo/fate"
8
+ * import type { InferSelectModel } from "drizzle-orm"
9
+ * import { recipes } from "../db/schema/recipes"
9
10
  *
10
11
  * type RecipeRow = InferSelectModel<typeof recipes>
11
12
  *
12
13
  * export default defineFateViews({
13
14
  * recipes: {
14
- * entity: 'Recipe',
15
- * fields: ['id', 'name', 'description', 'thumbnail'] as (keyof RecipeRow)[],
15
+ * entity: "Recipe",
16
+ * fields: ["id", "name", "description", "thumbnail"] as (keyof RecipeRow)[],
16
17
  * resolve: async ({ db, schema }) => db.select().from(schema.recipes).all(),
17
18
  * },
18
19
  * })
19
20
  * ```
20
21
  *
21
22
  * Usage in `app/fate/views.ts`:
23
+ *
22
24
  * ```ts
23
- * import { defineFateView } from 'qarpeo/fate'
24
- * import type { Recipe } from '~~/server/fate/views'
25
+ * import { defineFateView } from "qarpeo/fate"
26
+ * import type { Recipe } from "~~/server/fate/views"
25
27
  *
26
- * export const RecipeCardView = defineFateView<Recipe>(['id', 'name', 'description', 'thumbnail'])
28
+ * export const RecipeCardView = defineFateView<Recipe>([
29
+ * "id",
30
+ * "name",
31
+ * "description",
32
+ * "thumbnail",
33
+ * ])
27
34
  * ```
28
35
  */
29
36
  export type FateListOptions = {
@@ -53,24 +60,24 @@ export type FateViews = {
53
60
  lists: Record<string, any>;
54
61
  };
55
62
  /**
56
- * Define Fate server views from a plain config object.
57
- * Wraps `dataView`, `list`, and resolver wiring from `@nkzw/fate/server`.
58
- * Returns a `{ roots, lists }` object expected by the qarpeo virtual fate handler.
63
+ * Define Fate server views from a plain config object. Wraps `dataView`, `list`, and resolver
64
+ * wiring from `@nkzw/fate/server`. Returns a `{ roots, lists }` object expected by the qarpeo
65
+ * virtual fate handler.
59
66
  */
60
67
  export declare function defineFateViews<T extends FateViewMap>(config: T): FateViews;
61
68
  /**
62
- * Define a client-side Fate view selector for a component.
63
- * Removes the awkward `view<T>()({})` double-call syntax from `vue-fate`.
69
+ * Define a client-side Fate view selector for a component. Removes the awkward `view<T>()({})`
70
+ * double-call syntax from `vue-fate`.
64
71
  *
65
72
  * @example
66
- * ```ts
67
- * // Before (raw vue-fate):
68
- * import { view } from 'vue-fate'
69
- * export const RecipeCardView = view<Recipe>()({ id: true, name: true })
73
+ * ;```ts
74
+ * // Before (raw vue-fate):
75
+ * import { view } from "vue-fate"
76
+ * export const RecipeCardView = view<Recipe>()({ id: true, name: true })
70
77
  *
71
- * // After (qarpeo/fate):
72
- * import { defineFateView } from 'qarpeo/fate'
73
- * export const RecipeCardView = defineFateView<Recipe>(['id', 'name'])
74
- * ```
78
+ * // After (qarpeo/fate):
79
+ * import { defineFateView } from "qarpeo/fate"
80
+ * export const RecipeCardView = defineFateView<Recipe>(["id", "name"])
81
+ * ```
75
82
  */
76
83
  export declare function defineFateView<T extends Record<string, any>>(fields: (keyof T)[]): any;
@@ -28,9 +28,7 @@ function defineFateViews(config) {
28
28
  cursor: String(row.id ?? Math.random()),
29
29
  node: {
30
30
  __typename: def.entity,
31
- ...Object.fromEntries(
32
- def.fields.map((f) => [f, row[f]])
33
- )
31
+ ...Object.fromEntries(def.fields.map((f) => [f, row[f]]))
34
32
  }
35
33
  })),
36
34
  pagination: {
package/dist/module.d.ts CHANGED
@@ -9,7 +9,7 @@ export { findAgentFiles } from "./utils/agents";
9
9
  export { generateAuthSchema, getActiveAuthTableNames } from "./utils/auth-schema";
10
10
  export { cmsCollections, cmsEntries, cmsRevisions, ALL_CMS_TABLE_NAMES, getActiveCmsTableNames, } from "./utils/cms-schema";
11
11
  export { generatePaymentsSchema, getActivePaymentsTableNames } from "./utils/payments-schema";
12
- export { generateNotificationsSchema, getActiveNotificationsTableNames } from "./utils/notifications-schema";
12
+ export { generateNotificationsSchema, getActiveNotificationsTableNames, } from "./utils/notifications-schema";
13
13
  export { scanContentEntries } from "./utils/cms-scan";
14
14
  export { generateTenantsSchema, getActiveTenantsTableNames } from "./utils/tenants-schema";
15
15
  export { resolveAllCmsSources, discoverSources, resolveSourcePrefix, isRemoteSource, matchesSourceFilters, matchesGlobFilter, stripOrderPrefix, extractOrderPrefix, isGroupSegment, extractGroupTitle, matchPathPatterns, resolveCollectionForPath, } from "./utils/cms-sources";
package/dist/module.mjs CHANGED
@@ -4,7 +4,7 @@ import { fileURLToPath } from 'node:url';
4
4
  import { defineNuxtModule, useLogger, createResolver, addTemplate, addComponent, hasNuxtModule, installModule, addServerHandler, addPlugin, addServerImports, addImports, addImportsDir, addNitroPlugin, addTypeTemplate, updateTemplates, addServerImportsDir, addRouteMiddleware, extendPages } from '@nuxt/kit';
5
5
  import { defu } from 'defu';
6
6
  import { join, resolve, extname, basename, dirname, normalize, relative } from 'pathe';
7
- import { e as ensurePackage, c as createWranglerConfig, r as resolveBindingName, a as checkDrizzleVersion, s as scanSchemaExports, f as findScheduledTasks, b as resolveProjectName, d as findQueueFiles, g as findJobFiles, h as generateDevWranglerConfig, i as applyD1Migrations, j as findSchemaFiles } from './chunks/wrangler.mjs';
7
+ import { v as version, e as ensurePackage, c as createWranglerConfig, r as resolveBindingName, a as checkDrizzleVersion, s as scanSchemaExports, f as findScheduledTasks, b as resolveProjectName, d as findQueueFiles, g as findJobFiles, h as generateDevWranglerConfig, i as applyD1Migrations, j as findSchemaFiles } from './chunks/wrangler.mjs';
8
8
  import { generateAuthSchema } from './chunks/auth-schema.mjs';
9
9
  export { getActiveAuthTableNames } from './chunks/auth-schema.mjs';
10
10
  import { createHash } from 'node:crypto';
@@ -19,14 +19,14 @@ import 'drizzle-orm/node-sqlite';
19
19
  import 'node:process';
20
20
  import 'node:readline/promises';
21
21
 
22
- const version = "0.1.18";
23
-
24
22
  function ensureDevEnv(rootDir) {
25
23
  const envPath = join(rootDir, ".env");
26
24
  if (existsSync(envPath)) {
27
25
  try {
28
26
  let content2 = readFileSync(envPath, "utf8");
29
- if (content2.includes("NUXT_SESSION_PASSWORD=dev-session-password-must-be-at-least-32-chars-long")) {
27
+ if (content2.includes(
28
+ "NUXT_SESSION_PASSWORD=dev-session-password-must-be-at-least-32-chars-long"
29
+ )) {
30
30
  content2 = content2.replace(
31
31
  "NUXT_SESSION_PASSWORD=dev-session-password-must-be-at-least-32-chars-long",
32
32
  "NUXT_APP_SECRET=dev-app-secret-must-be-at-least-32-chars-long"
@@ -41,8 +41,6 @@ function ensureDevEnv(rootDir) {
41
41
  }
42
42
  }
43
43
  const dummyEntries = {
44
- CLOUDFLARE_ACCOUNT_ID: "dummy-dev-account-id",
45
- CLOUDFLARE_API_TOKEN: "dummy-dev-api-token",
46
44
  NUXT_APP_SECRET: "dev-app-secret-must-be-at-least-32-chars-long"
47
45
  };
48
46
  const needsFile = {};
@@ -120,7 +118,7 @@ function matchesSourceFilters(relPath, include, exclude) {
120
118
  for (const raw of list) {
121
119
  if (!raw) continue;
122
120
  try {
123
- const pattern = raw.replace(/\\/g, "/").replace(/[.+^$\{\}\|\[\]\\]/g, (m) => "\\" + m).replace(/\*\*/g, ".*").replace(/(?<!\.)\*/g, "[^/]*").replace(/\?/g, "[^/]");
121
+ const pattern = raw.replace(/\\/g, "/").replace(/[.+^${}|[\]\\]/g, (m) => "\\" + m).replace(/\*\*/g, ".*").replace(/(?<!\.)\*/g, "[^/]*").replace(/\?/g, "[^/]");
124
122
  const exRegex = new RegExp(pattern);
125
123
  if (exRegex.test(p)) return false;
126
124
  } catch {
@@ -133,7 +131,7 @@ function matchesSourceFilters(relPath, include, exclude) {
133
131
  for (const raw of list) {
134
132
  if (!raw) continue;
135
133
  try {
136
- const pattern = raw.replace(/\\/g, "/").replace(/[.+^$\{\}\|\[\]\\]/g, (m) => "\\" + m).replace(/\*\*/g, ".*").replace(/(?<!\.)\*/g, "[^/]*").replace(/\?/g, "[^/]");
134
+ const pattern = raw.replace(/\\/g, "/").replace(/[.+^${}|[\]\\]/g, (m) => "\\" + m).replace(/\*\*/g, ".*").replace(/(?<!\.)\*/g, "[^/]*").replace(/\?/g, "[^/]");
137
135
  const incRegex = new RegExp(pattern);
138
136
  if (incRegex.test(p)) {
139
137
  matched = true;
@@ -460,9 +458,7 @@ async function scanContentEntries(options) {
460
458
  } catch {
461
459
  return;
462
460
  }
463
- dirItems.sort(
464
- (a, b) => a.name.localeCompare(b.name, void 0, { numeric: true })
465
- );
461
+ dirItems.sort((a, b) => a.name.localeCompare(b.name, void 0, { numeric: true }));
466
462
  const navMeta = await readNavJson(dir);
467
463
  if (navMeta.private === true || navMeta.draft === true || navMeta.exclude === true) {
468
464
  return;
@@ -611,7 +607,8 @@ async function scanContentEntries(options) {
611
607
  updated_at: now
612
608
  });
613
609
  } else if (item.isFile() && (item.name.endsWith(".json") || item.name.endsWith(".yaml") || item.name.endsWith(".yml"))) {
614
- if (item.name.startsWith(".navigation.") || item.name.startsWith(".sources.") || item.name.startsWith("_sources.") || item.name.startsWith(".schema.")) continue;
610
+ if (item.name.startsWith(".navigation.") || item.name.startsWith(".sources.") || item.name.startsWith("_sources.") || item.name.startsWith(".schema."))
611
+ continue;
615
612
  const filePath = `${dir}/${item.name}`;
616
613
  let rawContent = "";
617
614
  try {
@@ -682,6 +679,55 @@ async function scanContentEntries(options) {
682
679
  return entries;
683
680
  }
684
681
 
682
+ function getActiveNotificationsTableNames(notifications) {
683
+ if (!notifications) return [];
684
+ const notifTable = (typeof notifications === "object" ? notifications.tableName : void 0) || "_qarpeo_notifications";
685
+ return [notifTable, "_qarpeo_push_subscriptions"];
686
+ }
687
+ function generateNotificationsSchema(notifications) {
688
+ if (!notifications) {
689
+ return "// Qarpeo Notifications is disabled\nexport default {};\n";
690
+ }
691
+ const notifTable = (typeof notifications === "object" ? notifications.tableName : void 0) || "_qarpeo_notifications";
692
+ const pushTable = "_qarpeo_push_subscriptions";
693
+ const lines = [
694
+ `// Auto-generated by qarpeo \u2014 Notifications & Push Subscriptions Engine`,
695
+ `// snakeCase.table maps camelCase property names \u2192 snake_case column names automatically`,
696
+ `import { integer, text, index, snakeCase } from "drizzle-orm/sqlite-core";`,
697
+ ``,
698
+ `// \u2500\u2500\u2500 1. In-App Notifications \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500`,
699
+ `export const notifications = snakeCase.table("${notifTable}", {`,
700
+ ` id: text().primaryKey(),`,
701
+ ` userId: text().notNull(),`,
702
+ ` tenantId: text(),`,
703
+ ` title: text().notNull(),`,
704
+ ` body: text(),`,
705
+ ` icon: text(),`,
706
+ ` actionUrl: text(),`,
707
+ ` channels: text().notNull().default('["in-app"]'),`,
708
+ ` read: integer().notNull().default(0),`,
709
+ ` readAt: integer(),`,
710
+ ` createdAt: integer().notNull(),`,
711
+ ` metadata: text(),`,
712
+ `}, (t) => [`,
713
+ ` index("idx_qarpeo_notifs_user").on(t.userId, t.createdAt),`,
714
+ `]);`,
715
+ ``,
716
+ `// \u2500\u2500\u2500 2. Web Push Subscriptions \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500`,
717
+ `export const pushSubscriptions = snakeCase.table("${pushTable}", {`,
718
+ ` endpoint: text().primaryKey(),`,
719
+ ` userId: text().notNull(),`,
720
+ ` tenantId: text(),`,
721
+ ` keysP256dh: text().notNull(),`,
722
+ ` keysAuth: text().notNull(),`,
723
+ ` createdAt: integer().notNull(),`,
724
+ `}, (t) => [`,
725
+ ` index("idx_qarpeo_push_user").on(t.userId),`,
726
+ `]);`
727
+ ];
728
+ return lines.join("\n") + "\n";
729
+ }
730
+
685
731
  const ALL_PAYMENTS_TABLE_NAMES = [
686
732
  "_qarpeo_customers",
687
733
  "_qarpeo_subscriptions",
@@ -793,55 +839,6 @@ function generatePaymentsSchema(payments) {
793
839
  return lines.join("\n");
794
840
  }
795
841
 
796
- function getActiveNotificationsTableNames(notifications) {
797
- if (!notifications) return [];
798
- const notifTable = (typeof notifications === "object" ? notifications.tableName : void 0) || "_qarpeo_notifications";
799
- return [notifTable, "_qarpeo_push_subscriptions"];
800
- }
801
- function generateNotificationsSchema(notifications) {
802
- if (!notifications) {
803
- return "// Qarpeo Notifications is disabled\nexport default {};\n";
804
- }
805
- const notifTable = (typeof notifications === "object" ? notifications.tableName : void 0) || "_qarpeo_notifications";
806
- const pushTable = "_qarpeo_push_subscriptions";
807
- const lines = [
808
- `// Auto-generated by qarpeo \u2014 Notifications & Push Subscriptions Engine`,
809
- `// snakeCase.table maps camelCase property names \u2192 snake_case column names automatically`,
810
- `import { integer, text, index, snakeCase } from "drizzle-orm/sqlite-core";`,
811
- ``,
812
- `// \u2500\u2500\u2500 1. In-App Notifications \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500`,
813
- `export const notifications = snakeCase.table("${notifTable}", {`,
814
- ` id: text().primaryKey(),`,
815
- ` userId: text().notNull(),`,
816
- ` tenantId: text(),`,
817
- ` title: text().notNull(),`,
818
- ` body: text(),`,
819
- ` icon: text(),`,
820
- ` actionUrl: text(),`,
821
- ` channels: text().notNull().default('["in-app"]'),`,
822
- ` read: integer().notNull().default(0),`,
823
- ` readAt: integer(),`,
824
- ` createdAt: integer().notNull(),`,
825
- ` metadata: text(),`,
826
- `}, (t) => [`,
827
- ` index("idx_qarpeo_notifs_user").on(t.userId, t.createdAt),`,
828
- `]);`,
829
- ``,
830
- `// \u2500\u2500\u2500 2. Web Push Subscriptions \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500`,
831
- `export const pushSubscriptions = snakeCase.table("${pushTable}", {`,
832
- ` endpoint: text().primaryKey(),`,
833
- ` userId: text().notNull(),`,
834
- ` tenantId: text(),`,
835
- ` keysP256dh: text().notNull(),`,
836
- ` keysAuth: text().notNull(),`,
837
- ` createdAt: integer().notNull(),`,
838
- `}, (t) => [`,
839
- ` index("idx_qarpeo_push_user").on(t.userId),`,
840
- `]);`
841
- ];
842
- return lines.join("\n") + "\n";
843
- }
844
-
845
842
  const ALL_TENANTS_TABLE_NAMES = ["_qarpeo_tenants", "_qarpeo_domains"];
846
843
  function getActiveTenantsTableNames(multitenant) {
847
844
  if (!multitenant) return [];
@@ -1231,8 +1228,12 @@ ${extraSources}
1231
1228
  nuxt.options.alias["#qarpeo/payments"] = resolver.resolve("./runtime/payments");
1232
1229
  nuxt.options.alias["qarpeo/storage"] = resolver.resolve("./runtime/storage");
1233
1230
  nuxt.options.alias["#qarpeo/storage"] = resolver.resolve("./runtime/storage");
1234
- nuxt.options.alias["qarpeo/notifications"] = resolver.resolve("./runtime/server/utils/notifications");
1235
- nuxt.options.alias["#qarpeo/notifications"] = resolver.resolve("./runtime/server/utils/notifications");
1231
+ nuxt.options.alias["qarpeo/notifications"] = resolver.resolve(
1232
+ "./runtime/server/utils/notifications"
1233
+ );
1234
+ nuxt.options.alias["#qarpeo/notifications"] = resolver.resolve(
1235
+ "./runtime/server/utils/notifications"
1236
+ );
1236
1237
  nuxt.options.alias["qarpeo/vapid"] = resolver.resolve("./runtime/server/utils/vapid");
1237
1238
  nuxt.options.alias["#qarpeo/vapid"] = resolver.resolve("./runtime/server/utils/vapid");
1238
1239
  const emptyAgentsTemplate = addTemplate({
@@ -1285,7 +1286,10 @@ ${extraSources}
1285
1286
  nuxt.options.alias["better-auth/client"] = resolve(betterAuthDir, "dist/client/index.mjs");
1286
1287
  nuxt.options.alias["better-auth"] = resolve(betterAuthDir, "dist/index.mjs");
1287
1288
  const betterAuthAdapterDir = resolvePkgDir("@better-auth/drizzle-adapter");
1288
- nuxt.options.alias["@better-auth/drizzle-adapter"] = resolve(betterAuthAdapterDir, "dist/index.mjs");
1289
+ nuxt.options.alias["@better-auth/drizzle-adapter"] = resolve(
1290
+ betterAuthAdapterDir,
1291
+ "dist/index.mjs"
1292
+ );
1289
1293
  const comarkNuxtDir = resolvePkgDir("@comark/nuxt");
1290
1294
  nuxt.options.alias["@comark/nuxt/utils"] = resolve(comarkNuxtDir, "dist/utils/index.js");
1291
1295
  nuxt.options.alias["@comark/nuxt/render"] = resolve(comarkNuxtDir, "dist/render.js");
@@ -1438,13 +1442,13 @@ ${extraSources}
1438
1442
  nuxt.options.auth = defu(nuxt.options.auth || {}, { webAuthn: true });
1439
1443
  }
1440
1444
  }
1441
- if (options.cms && !hasNuxtModule("@comark/vue") && !hasNuxtModule("@comark/nuxt")) {
1445
+ if (options.cms && !hasNuxtModule("@comark/vue/nuxt") && !hasNuxtModule("@comark/vue") && !hasNuxtModule("@comark/nuxt")) {
1442
1446
  try {
1443
- const comarkModulePath = fileURLToPath(import.meta.resolve("@comark/vue"));
1447
+ const comarkModulePath = fileURLToPath(import.meta.resolve("@comark/vue/nuxt"));
1444
1448
  await installModule(comarkModulePath);
1445
1449
  } catch {
1446
1450
  try {
1447
- await installModule("@comark/vue");
1451
+ await installModule("@comark/vue/nuxt");
1448
1452
  } catch {
1449
1453
  try {
1450
1454
  await installModule("@comark/nuxt");
@@ -1478,11 +1482,7 @@ ${extraSources}
1478
1482
  nuxt.options.alias["vue-fate/"] = `${vueFateDir}/`;
1479
1483
  } catch {
1480
1484
  }
1481
- const userFateViewsPath = resolve(
1482
- nuxt.options.rootDir,
1483
- fateViewsDir,
1484
- "views"
1485
- );
1485
+ const userFateViewsPath = resolve(nuxt.options.rootDir, fateViewsDir, "views");
1486
1486
  addTemplate({
1487
1487
  filename: "qarpeo/fate/views.mjs",
1488
1488
  getContents: () => `export { default as fateViews } from '${userFateViewsPath}'
@@ -1498,9 +1498,7 @@ ${extraSources}
1498
1498
  handler: resolver.resolve("./runtime/server/routes/fate")
1499
1499
  });
1500
1500
  addPlugin(resolver.resolve("./runtime/app/plugins/fate"));
1501
- addServerImports([
1502
- { name: "defineFateViews", from: "qarpeo/fate" }
1503
- ]);
1501
+ addServerImports([{ name: "defineFateViews", from: "qarpeo/fate" }]);
1504
1502
  addImports([
1505
1503
  { name: "defineFateView", from: "qarpeo/fate" },
1506
1504
  { name: "useRequest", from: "vue-fate" },
@@ -1512,7 +1510,9 @@ ${extraSources}
1512
1510
  nuxt.hook("builder:watch", () => {
1513
1511
  });
1514
1512
  addImportsDir(appFateDir);
1515
- logger.info(`[qarpeo] Fate enabled \u2014 handler at ${fateEndpoint}, views from ${fateViewsDir}/views.ts`);
1513
+ logger.info(
1514
+ `[qarpeo] Fate enabled \u2014 handler at ${fateEndpoint}, views from ${fateViewsDir}/views.ts`
1515
+ );
1516
1516
  }
1517
1517
  if (options.cms) {
1518
1518
  const cmsOptions = typeof options.cms === "object" ? options.cms : {};
@@ -2004,7 +2004,10 @@ export default async function (batch: any, env?: any, ctx?: any) {
2004
2004
  nitroConfig.alias["better-auth/client"] = resolve(betterAuthDir, "dist/client/index.mjs");
2005
2005
  nitroConfig.alias["better-auth"] = resolve(betterAuthDir, "dist/index.mjs");
2006
2006
  const betterAuthAdapterDir = resolvePkgDir("@better-auth/drizzle-adapter");
2007
- nitroConfig.alias["@better-auth/drizzle-adapter"] = resolve(betterAuthAdapterDir, "dist/index.mjs");
2007
+ nitroConfig.alias["@better-auth/drizzle-adapter"] = resolve(
2008
+ betterAuthAdapterDir,
2009
+ "dist/index.mjs"
2010
+ );
2008
2011
  const comarkNuxtDir = resolvePkgDir("@comark/nuxt");
2009
2012
  nitroConfig.alias["@comark/nuxt/utils"] = resolve(comarkNuxtDir, "dist/utils/index.js");
2010
2013
  nitroConfig.alias["@comark/nuxt/render"] = resolve(comarkNuxtDir, "dist/render.js");
@@ -2188,16 +2191,25 @@ export default async function (batch: any, env?: any, ctx?: any) {
2188
2191
  }
2189
2192
  });
2190
2193
  nitroConfig.cloudflare.wrangler = nitroConfig.cloudflare.wrangler || {};
2194
+ nitroConfig.framework = nitroConfig.framework || {};
2195
+ nitroConfig.framework.previewCommand = "vpx nuxt preview";
2196
+ nitroConfig.framework.deployCommand = "vpx qp deploy";
2191
2197
  nitroConfig.externals = nitroConfig.externals || {};
2192
2198
  nitroConfig.externals.external = nitroConfig.externals.external || [];
2193
2199
  if (!nitroConfig.externals.external.includes("wrangler")) {
2194
2200
  nitroConfig.externals.external.push("wrangler");
2195
2201
  }
2202
+ if (!nitroConfig.externals.external.includes("@cloudflare/puppeteer")) {
2203
+ nitroConfig.externals.external.push("@cloudflare/puppeteer");
2204
+ }
2196
2205
  nitroConfig.rollupConfig = nitroConfig.rollupConfig || {};
2197
2206
  if (Array.isArray(nitroConfig.rollupConfig.external)) {
2198
2207
  if (!nitroConfig.rollupConfig.external.includes("wrangler")) {
2199
2208
  nitroConfig.rollupConfig.external.push("wrangler");
2200
2209
  }
2210
+ if (!nitroConfig.rollupConfig.external.includes("@cloudflare/puppeteer")) {
2211
+ nitroConfig.rollupConfig.external.push("@cloudflare/puppeteer");
2212
+ }
2201
2213
  }
2202
2214
  if (options.kv) {
2203
2215
  const kvBinding = resolveBindingName("kv");
@@ -2299,7 +2311,7 @@ export default async function (batch: any, env?: any, ctx?: any) {
2299
2311
  nitroConfig.runtimeConfig = nitroConfig.runtimeConfig || {};
2300
2312
  nitroConfig.runtimeConfig.nitro = nitroConfig.runtimeConfig.nitro || {};
2301
2313
  nitroConfig.runtimeConfig.nitro.defaultCacheOptions = {
2302
- ...nitroConfig.runtimeConfig.nitro.defaultCacheOptions || {},
2314
+ ...nitroConfig.runtimeConfig.nitro.defaultCacheOptions,
2303
2315
  swr: true
2304
2316
  };
2305
2317
  }
@@ -2506,7 +2518,10 @@ export default async function (batch: any, env?: any, ctx?: any) {
2506
2518
  { name: "verifyWebhookSignature", from: resolver.resolve("./runtime/server/utils/bots") },
2507
2519
  { name: "createRAGPipeline", from: resolver.resolve("./runtime/server/utils/rag") },
2508
2520
  { name: "splitTextIntoChunks", from: resolver.resolve("./runtime/server/utils/rag") },
2509
- { name: "defineScheduledTask", from: resolver.resolve("./runtime/server/utils/scheduled-task") },
2521
+ {
2522
+ name: "defineScheduledTask",
2523
+ from: resolver.resolve("./runtime/server/utils/scheduled-task")
2524
+ },
2510
2525
  { name: "useServiceBinding", from: "qarpeo/runtime" },
2511
2526
  { name: "getServiceBinding", from: "qarpeo/runtime" },
2512
2527
  { name: "createServiceClient", from: "qarpeo/runtime" }
@@ -3765,7 +3780,7 @@ export const manifestCollections = ${JSON.stringify(cmsConfig.collections || {})
3765
3780
  nitroConfig.alias = nitroConfig.alias || {};
3766
3781
  nitroConfig.alias["#qarpeo/cms/manifest"] = cmsManifestTemplate.dst;
3767
3782
  const routeRules = nuxt.options.routeRules || {};
3768
- const prerenderPatterns = Object.entries(routeRules).filter(([_, rule]) => rule?.prerender === true).map(([pattern]) => pattern);
3783
+ const prerenderPatterns = Object.entries(routeRules).filter(([, rule]) => rule?.prerender === true).map(([pattern]) => pattern);
3769
3784
  if (prerenderPatterns.length > 0) {
3770
3785
  try {
3771
3786
  const shikiOpt = cmsConfig.shiki !== void 0 ? cmsConfig.shiki : cmsConfig.plugins?.shiki;
@@ -3960,7 +3975,10 @@ export const manifestCollections = ${JSON.stringify(cmsConfig.collections || {})
3960
3975
  },
3961
3976
  { name: "useCMSLocale", from: resolver.resolve("./runtime/app/composables/cms") },
3962
3977
  { name: "useDocsSearch", from: resolver.resolve("./runtime/app/composables/cms") },
3963
- { name: "useDocsVersion", from: resolver.resolve("./runtime/app/composables/docs-version") },
3978
+ {
3979
+ name: "useDocsVersion",
3980
+ from: resolver.resolve("./runtime/app/composables/docs-version")
3981
+ },
3964
3982
  { name: "useCMSPreview", from: resolver.resolve("./runtime/app/composables/cms-preview") }
3965
3983
  ]);
3966
3984
  addComponent({
@@ -4513,7 +4531,10 @@ export const manifestCollections = ${JSON.stringify(cmsConfig.collections || {})
4513
4531
  { name: "recordSoftBounce", from: resolver.resolve("./runtime/server/utils/mail") },
4514
4532
  { name: "generateUnsubscribeToken", from: resolver.resolve("./runtime/server/utils/mail") },
4515
4533
  { name: "verifyUnsubscribeToken", from: resolver.resolve("./runtime/server/utils/mail") },
4516
- { name: "buildListUnsubscribeHeaders", from: resolver.resolve("./runtime/server/utils/mail") },
4534
+ {
4535
+ name: "buildListUnsubscribeHeaders",
4536
+ from: resolver.resolve("./runtime/server/utils/mail")
4537
+ },
4517
4538
  { name: "injectEmailTracking", from: resolver.resolve("./runtime/server/utils/mail") },
4518
4539
  { name: "deliverMailDirect", from: resolver.resolve("./runtime/server/utils/mail") },
4519
4540
  {
@@ -1,6 +1,6 @@
1
+ import { generateImage, textToImage, generateSpeech, textToSpeech, transcribeAudio, speechToText, generateText, streamText, embedText, similaritySearch } from "./server/utils/ai";
1
2
  import type { AiBinding, QarpeoAI } from "./types/ai";
2
3
  import type { CFEvent } from "./types/index";
3
- import { generateImage, textToImage, generateSpeech, textToSpeech, transcribeAudio, speechToText, generateText, streamText, embedText, similaritySearch } from "./server/utils/ai";
4
4
  export type { AiBinding, AiOptions, QarpeoAI, GenerateImageOptions, GenerateImageResult, GenerateSpeechOptions, GenerateSpeechResult, TranscribeAudioInput, TranscribeAudioOptions, TranscribeAudioResult, StreamTextOptions, } from "./types/ai";
5
5
  export { generateImage, textToImage, generateSpeech, textToSpeech, transcribeAudio, speechToText, generateText, streamText, embedText, similaritySearch, };
6
6
  /**
@@ -24,4 +24,4 @@ export declare const ai: QarpeoAI;
24
24
  export { useChat, useAgentChat } from "./app/composables/chat";
25
25
  export type { UseChatOptions, UseAgentChatOptions } from "./app/composables/chat";
26
26
  export { useAIStream, useVectorSearch, useEmbeddings } from "./app/composables/ai";
27
- export type { UseAIStreamOptions, UseVectorSearchOptions, UseEmbeddingsOptions } from "./app/composables/ai";
27
+ export type { UseAIStreamOptions, UseVectorSearchOptions, UseEmbeddingsOptions, } from "./app/composables/ai";