@kyro-cms/core 0.2.4 → 0.2.10

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 (37) hide show
  1. package/dist/{WebhookService-CXJ5oz6L.d.ts → WebhookService-BznDc2AT.d.ts} +1 -1
  2. package/dist/{WebhookService-Dqx9Is7m.d.cts → WebhookService-mZZ75syh.d.cts} +1 -1
  3. package/dist/{base-Cfek4fp3.d.cts → base-Db9LkB1N.d.cts} +1 -1
  4. package/dist/{base-CciYzoDF.d.ts → base-Hu6ij8sZ.d.ts} +1 -1
  5. package/dist/{chunk-RONAX6UU.js → chunk-KB6QF4HO.js} +389 -142
  6. package/dist/chunk-KB6QF4HO.js.map +1 -0
  7. package/dist/{chunk-KDVDIZ4Y.cjs → chunk-PNBZZ76A.cjs} +389 -142
  8. package/dist/chunk-PNBZZ76A.cjs.map +1 -0
  9. package/dist/client.d.cts +1 -1
  10. package/dist/client.d.ts +1 -1
  11. package/dist/drizzle/index.d.cts +2 -2
  12. package/dist/drizzle/index.d.ts +2 -2
  13. package/dist/graphql/index.d.cts +2 -2
  14. package/dist/graphql/index.d.ts +2 -2
  15. package/dist/{index-CTLPjpMH.d.cts → index-11MDNKce.d.cts} +1 -1
  16. package/dist/{index-BvZ1iWm2.d.ts → index-Ci6r4xnN.d.ts} +1 -1
  17. package/dist/index.cjs +234 -123
  18. package/dist/index.cjs.map +1 -1
  19. package/dist/index.d.cts +7 -7
  20. package/dist/index.d.ts +7 -7
  21. package/dist/index.js +223 -112
  22. package/dist/index.js.map +1 -1
  23. package/dist/mongodb/index.d.cts +2 -2
  24. package/dist/mongodb/index.d.ts +2 -2
  25. package/dist/rest/index.d.cts +3 -3
  26. package/dist/rest/index.d.ts +3 -3
  27. package/dist/templates/index.cjs +23 -23
  28. package/dist/templates/index.d.cts +1 -1
  29. package/dist/templates/index.d.ts +1 -1
  30. package/dist/templates/index.js +1 -1
  31. package/dist/trpc/index.d.cts +2 -2
  32. package/dist/trpc/index.d.ts +2 -2
  33. package/dist/{types-Bt1OEk0S.d.cts → types-kGfsGdos.d.cts} +10 -10
  34. package/dist/{types-Bt1OEk0S.d.ts → types-kGfsGdos.d.ts} +10 -10
  35. package/package.json +4 -4
  36. package/dist/chunk-KDVDIZ4Y.cjs.map +0 -1
  37. package/dist/chunk-RONAX6UU.js.map +0 -1
@@ -1,5 +1,5 @@
1
- import { A as AbstractBaseAdapter } from '../base-Cfek4fp3.cjs';
2
- import { x as FindArgs, y as FindResult, z as FindByIDArgs, H as CreateArgs, L as UpdateArgs, O as DeleteArgs } from '../types-Bt1OEk0S.cjs';
1
+ import { A as AbstractBaseAdapter } from '../base-Db9LkB1N.cjs';
2
+ import { x as FindArgs, y as FindResult, z as FindByIDArgs, H as CreateArgs, L as UpdateArgs, O as DeleteArgs } from '../types-kGfsGdos.cjs';
3
3
 
4
4
  declare class MongoDBAdapter extends AbstractBaseAdapter {
5
5
  private client;
@@ -1,5 +1,5 @@
1
- import { A as AbstractBaseAdapter } from '../base-CciYzoDF.js';
2
- import { x as FindArgs, y as FindResult, z as FindByIDArgs, H as CreateArgs, L as UpdateArgs, O as DeleteArgs } from '../types-Bt1OEk0S.js';
1
+ import { A as AbstractBaseAdapter } from '../base-Hu6ij8sZ.js';
2
+ import { x as FindArgs, y as FindResult, z as FindByIDArgs, H as CreateArgs, L as UpdateArgs, O as DeleteArgs } from '../types-kGfsGdos.js';
3
3
 
4
4
  declare class MongoDBAdapter extends AbstractBaseAdapter {
5
5
  private client;
@@ -1,7 +1,7 @@
1
1
  import { Hono } from 'hono';
2
- import { w as BaseAdapter, Q as User } from '../types-Bt1OEk0S.cjs';
3
- import { R as Registry } from '../index-CTLPjpMH.cjs';
4
- import { i as createWebhookService } from '../WebhookService-Dqx9Is7m.cjs';
2
+ import { w as BaseAdapter, Q as User } from '../types-kGfsGdos.cjs';
3
+ import { R as Registry } from '../index-11MDNKce.cjs';
4
+ import { i as createWebhookService } from '../WebhookService-mZZ75syh.cjs';
5
5
  import 'zod';
6
6
 
7
7
  interface HonoAppOptions {
@@ -1,7 +1,7 @@
1
1
  import { Hono } from 'hono';
2
- import { w as BaseAdapter, Q as User } from '../types-Bt1OEk0S.js';
3
- import { R as Registry } from '../index-BvZ1iWm2.js';
4
- import { i as createWebhookService } from '../WebhookService-CXJ5oz6L.js';
2
+ import { w as BaseAdapter, Q as User } from '../types-kGfsGdos.js';
3
+ import { R as Registry } from '../index-Ci6r4xnN.js';
4
+ import { i as createWebhookService } from '../WebhookService-BznDc2AT.js';
5
5
  import 'zod';
6
6
 
7
7
  interface HonoAppOptions {
@@ -1,97 +1,97 @@
1
1
  'use strict';
2
2
 
3
- var chunkKDVDIZ4Y_cjs = require('../chunk-KDVDIZ4Y.cjs');
3
+ var chunkPNBZZ76A_cjs = require('../chunk-PNBZZ76A.cjs');
4
4
  require('../chunk-G7VZBCD6.cjs');
5
5
 
6
6
 
7
7
 
8
8
  Object.defineProperty(exports, "accessSettingsGlobal", {
9
9
  enumerable: true,
10
- get: function () { return chunkKDVDIZ4Y_cjs.accessSettingsGlobal; }
10
+ get: function () { return chunkPNBZZ76A_cjs.accessSettingsGlobal; }
11
11
  });
12
12
  Object.defineProperty(exports, "allSettingsGlobals", {
13
13
  enumerable: true,
14
- get: function () { return chunkKDVDIZ4Y_cjs.allSettingsGlobals; }
14
+ get: function () { return chunkPNBZZ76A_cjs.allSettingsGlobals; }
15
15
  });
16
16
  Object.defineProperty(exports, "blogCollections", {
17
17
  enumerable: true,
18
- get: function () { return chunkKDVDIZ4Y_cjs.blogCollections; }
18
+ get: function () { return chunkPNBZZ76A_cjs.blogCollections; }
19
19
  });
20
20
  Object.defineProperty(exports, "blogGlobals", {
21
21
  enumerable: true,
22
- get: function () { return chunkKDVDIZ4Y_cjs.blogGlobals; }
22
+ get: function () { return chunkPNBZZ76A_cjs.blogGlobals; }
23
23
  });
24
24
  Object.defineProperty(exports, "coreSettingsGlobals", {
25
25
  enumerable: true,
26
- get: function () { return chunkKDVDIZ4Y_cjs.coreSettingsGlobals; }
26
+ get: function () { return chunkPNBZZ76A_cjs.coreSettingsGlobals; }
27
27
  });
28
28
  Object.defineProperty(exports, "createTemplateConfig", {
29
29
  enumerable: true,
30
- get: function () { return chunkKDVDIZ4Y_cjs.createTemplateConfig; }
30
+ get: function () { return chunkPNBZZ76A_cjs.createTemplateConfig; }
31
31
  });
32
32
  Object.defineProperty(exports, "ecommerceCollections", {
33
33
  enumerable: true,
34
- get: function () { return chunkKDVDIZ4Y_cjs.ecommerceCollections; }
34
+ get: function () { return chunkPNBZZ76A_cjs.ecommerceCollections; }
35
35
  });
36
36
  Object.defineProperty(exports, "ecommerceGlobals", {
37
37
  enumerable: true,
38
- get: function () { return chunkKDVDIZ4Y_cjs.ecommerceGlobals; }
38
+ get: function () { return chunkPNBZZ76A_cjs.ecommerceGlobals; }
39
39
  });
40
40
  Object.defineProperty(exports, "ecommerceSettingsGlobals", {
41
41
  enumerable: true,
42
- get: function () { return chunkKDVDIZ4Y_cjs.ecommerceSettingsGlobals; }
42
+ get: function () { return chunkPNBZZ76A_cjs.ecommerceSettingsGlobals; }
43
43
  });
44
44
  Object.defineProperty(exports, "emailSettingsGlobal", {
45
45
  enumerable: true,
46
- get: function () { return chunkKDVDIZ4Y_cjs.emailSettingsGlobal; }
46
+ get: function () { return chunkPNBZZ76A_cjs.emailSettingsGlobal; }
47
47
  });
48
48
  Object.defineProperty(exports, "getSettingsForTemplate", {
49
49
  enumerable: true,
50
- get: function () { return chunkKDVDIZ4Y_cjs.getSettingsForTemplate; }
50
+ get: function () { return chunkPNBZZ76A_cjs.getSettingsForTemplate; }
51
51
  });
52
52
  Object.defineProperty(exports, "kitchenSinkCollections", {
53
53
  enumerable: true,
54
- get: function () { return chunkKDVDIZ4Y_cjs.kitchenSinkCollections; }
54
+ get: function () { return chunkPNBZZ76A_cjs.kitchenSinkCollections; }
55
55
  });
56
56
  Object.defineProperty(exports, "mediaCollection", {
57
57
  enumerable: true,
58
- get: function () { return chunkKDVDIZ4Y_cjs.mediaCollection; }
58
+ get: function () { return chunkPNBZZ76A_cjs.mediaCollection; }
59
59
  });
60
60
  Object.defineProperty(exports, "mediaCollections", {
61
61
  enumerable: true,
62
- get: function () { return chunkKDVDIZ4Y_cjs.mediaCollections; }
62
+ get: function () { return chunkPNBZZ76A_cjs.mediaCollections; }
63
63
  });
64
64
  Object.defineProperty(exports, "minimalCollections", {
65
65
  enumerable: true,
66
- get: function () { return chunkKDVDIZ4Y_cjs.minimalCollections; }
66
+ get: function () { return chunkPNBZZ76A_cjs.minimalCollections; }
67
67
  });
68
68
  Object.defineProperty(exports, "paymentSettingsGlobal", {
69
69
  enumerable: true,
70
- get: function () { return chunkKDVDIZ4Y_cjs.paymentSettingsGlobal; }
70
+ get: function () { return chunkPNBZZ76A_cjs.paymentSettingsGlobal; }
71
71
  });
72
72
  Object.defineProperty(exports, "seoSettingsGlobal", {
73
73
  enumerable: true,
74
- get: function () { return chunkKDVDIZ4Y_cjs.seoSettingsGlobal; }
74
+ get: function () { return chunkPNBZZ76A_cjs.seoSettingsGlobal; }
75
75
  });
76
76
  Object.defineProperty(exports, "settingsBySlug", {
77
77
  enumerable: true,
78
- get: function () { return chunkKDVDIZ4Y_cjs.settingsBySlug; }
78
+ get: function () { return chunkPNBZZ76A_cjs.settingsBySlug; }
79
79
  });
80
80
  Object.defineProperty(exports, "siteSettingsGlobal", {
81
81
  enumerable: true,
82
- get: function () { return chunkKDVDIZ4Y_cjs.siteSettingsGlobal; }
82
+ get: function () { return chunkPNBZZ76A_cjs.siteSettingsGlobal; }
83
83
  });
84
84
  Object.defineProperty(exports, "socialSettingsGlobal", {
85
85
  enumerable: true,
86
- get: function () { return chunkKDVDIZ4Y_cjs.socialSettingsGlobal; }
86
+ get: function () { return chunkPNBZZ76A_cjs.socialSettingsGlobal; }
87
87
  });
88
88
  Object.defineProperty(exports, "storageSettingsGlobal", {
89
89
  enumerable: true,
90
- get: function () { return chunkKDVDIZ4Y_cjs.storageSettingsGlobal; }
90
+ get: function () { return chunkPNBZZ76A_cjs.storageSettingsGlobal; }
91
91
  });
92
92
  Object.defineProperty(exports, "storeSettingsGlobal", {
93
93
  enumerable: true,
94
- get: function () { return chunkKDVDIZ4Y_cjs.storeSettingsGlobal; }
94
+ get: function () { return chunkPNBZZ76A_cjs.storeSettingsGlobal; }
95
95
  });
96
96
  //# sourceMappingURL=index.cjs.map
97
97
  //# sourceMappingURL=index.cjs.map
@@ -1,4 +1,4 @@
1
- import { i as CollectionConfig, G as GlobalConfig } from '../types-Bt1OEk0S.cjs';
1
+ import { i as CollectionConfig, G as GlobalConfig } from '../types-kGfsGdos.cjs';
2
2
 
3
3
  declare const minimalCollections: Record<string, CollectionConfig>;
4
4
 
@@ -1,4 +1,4 @@
1
- import { i as CollectionConfig, G as GlobalConfig } from '../types-Bt1OEk0S.js';
1
+ import { i as CollectionConfig, G as GlobalConfig } from '../types-kGfsGdos.js';
2
2
 
3
3
  declare const minimalCollections: Record<string, CollectionConfig>;
4
4
 
@@ -1,4 +1,4 @@
1
- export { accessSettingsGlobal, allSettingsGlobals, blogCollections, blogGlobals, coreSettingsGlobals, createTemplateConfig, ecommerceCollections, ecommerceGlobals, ecommerceSettingsGlobals, emailSettingsGlobal, getSettingsForTemplate, kitchenSinkCollections, mediaCollection, mediaCollections, minimalCollections, paymentSettingsGlobal, seoSettingsGlobal, settingsBySlug, siteSettingsGlobal, socialSettingsGlobal, storageSettingsGlobal, storeSettingsGlobal } from '../chunk-RONAX6UU.js';
1
+ export { accessSettingsGlobal, allSettingsGlobals, blogCollections, blogGlobals, coreSettingsGlobals, createTemplateConfig, ecommerceCollections, ecommerceGlobals, ecommerceSettingsGlobals, emailSettingsGlobal, getSettingsForTemplate, kitchenSinkCollections, mediaCollection, mediaCollections, minimalCollections, paymentSettingsGlobal, seoSettingsGlobal, settingsBySlug, siteSettingsGlobal, socialSettingsGlobal, storageSettingsGlobal, storeSettingsGlobal } from '../chunk-KB6QF4HO.js';
2
2
  import '../chunk-Z6ZWNWWR.js';
3
3
  //# sourceMappingURL=index.js.map
4
4
  //# sourceMappingURL=index.js.map
@@ -1,5 +1,5 @@
1
- import { w as BaseAdapter, W as Request, Q as User, y as FindResult } from '../types-Bt1OEk0S.cjs';
2
- import { i as createWebhookService } from '../WebhookService-Dqx9Is7m.cjs';
1
+ import { w as BaseAdapter, W as Request, Q as User, y as FindResult } from '../types-kGfsGdos.cjs';
2
+ import { i as createWebhookService } from '../WebhookService-mZZ75syh.cjs';
3
3
 
4
4
  interface ApiKeyContext {
5
5
  userId: string;
@@ -1,5 +1,5 @@
1
- import { w as BaseAdapter, W as Request, Q as User, y as FindResult } from '../types-Bt1OEk0S.js';
2
- import { i as createWebhookService } from '../WebhookService-CXJ5oz6L.js';
1
+ import { w as BaseAdapter, W as Request, Q as User, y as FindResult } from '../types-kGfsGdos.js';
2
+ import { i as createWebhookService } from '../WebhookService-BznDc2AT.js';
3
3
 
4
4
  interface ApiKeyContext {
5
5
  userId: string;
@@ -351,7 +351,7 @@ interface AdminConfig {
351
351
  defaultLimit?: number;
352
352
  limits?: number[];
353
353
  };
354
- layout?: 'split' | 'single';
354
+ layout?: "split" | "single";
355
355
  }
356
356
  interface UploadConfig {
357
357
  staticDir?: string;
@@ -362,7 +362,7 @@ interface UploadConfig {
362
362
  crop?: boolean;
363
363
  focalPoint?: boolean;
364
364
  formatOptions?: {
365
- format: 'webp' | 'png' | 'jpg';
365
+ format: "webp" | "png" | "jpg";
366
366
  options?: Record<string, any>;
367
367
  };
368
368
  resizeOptions?: Record<string, any>;
@@ -375,7 +375,7 @@ interface ImageSize {
375
375
  crop?: string;
376
376
  position?: string;
377
377
  formatOptions?: {
378
- format: 'webp' | 'png' | 'jpg';
378
+ format: "webp" | "png" | "jpg";
379
379
  };
380
380
  generateImageName?: (doc: any) => string;
381
381
  }
@@ -393,7 +393,7 @@ interface AuthConfig {
393
393
  lockTime?: number;
394
394
  cookies?: {
395
395
  secure?: boolean;
396
- sameSite?: 'strict' | 'lax' | 'none';
396
+ sameSite?: "strict" | "lax" | "none";
397
397
  domain?: string;
398
398
  };
399
399
  forgotPassword?: {
@@ -425,7 +425,7 @@ interface CollectionConfig {
425
425
  pluralName?: string;
426
426
  };
427
427
  indexes?: Array<{
428
- fields: Record<string, number | 'text'>;
428
+ fields: Record<string, number | "text">;
429
429
  options?: Record<string, any>;
430
430
  }>;
431
431
  custom?: Record<string, any>;
@@ -558,7 +558,7 @@ interface BaseAdapter {
558
558
  transaction?<T>(fn: (tx: any) => Promise<T>): Promise<T>;
559
559
  }
560
560
  interface AdapterConfig {
561
- type: 'drizzle' | 'mongodb';
561
+ type: "drizzle" | "mongodb";
562
562
  client: any;
563
563
  schema?: any;
564
564
  connectionOptions?: Record<string, any>;
@@ -578,12 +578,12 @@ interface KyroConfig {
578
578
  globals?: GlobalConfig[];
579
579
  adapter: BaseAdapter;
580
580
  plugins?: PluginConfig[];
581
- auth?: {
582
- secret: string;
581
+ auth?: boolean | {
582
+ secret?: string;
583
583
  tokenExpiration?: number;
584
584
  cookie?: {
585
585
  secure?: boolean;
586
- sameSite?: 'strict' | 'lax' | 'none';
586
+ sameSite?: "strict" | "lax" | "none";
587
587
  domain?: string;
588
588
  };
589
589
  };
@@ -598,7 +598,7 @@ interface KyroConfig {
598
598
  ogImage?: string;
599
599
  };
600
600
  dateFormat?: string;
601
- avatar?: 'default' | 'gravatar';
601
+ avatar?: "default" | "gravatar";
602
602
  disable?: boolean;
603
603
  indexRoute?: string;
604
604
  components?: Record<string, any>;
@@ -351,7 +351,7 @@ interface AdminConfig {
351
351
  defaultLimit?: number;
352
352
  limits?: number[];
353
353
  };
354
- layout?: 'split' | 'single';
354
+ layout?: "split" | "single";
355
355
  }
356
356
  interface UploadConfig {
357
357
  staticDir?: string;
@@ -362,7 +362,7 @@ interface UploadConfig {
362
362
  crop?: boolean;
363
363
  focalPoint?: boolean;
364
364
  formatOptions?: {
365
- format: 'webp' | 'png' | 'jpg';
365
+ format: "webp" | "png" | "jpg";
366
366
  options?: Record<string, any>;
367
367
  };
368
368
  resizeOptions?: Record<string, any>;
@@ -375,7 +375,7 @@ interface ImageSize {
375
375
  crop?: string;
376
376
  position?: string;
377
377
  formatOptions?: {
378
- format: 'webp' | 'png' | 'jpg';
378
+ format: "webp" | "png" | "jpg";
379
379
  };
380
380
  generateImageName?: (doc: any) => string;
381
381
  }
@@ -393,7 +393,7 @@ interface AuthConfig {
393
393
  lockTime?: number;
394
394
  cookies?: {
395
395
  secure?: boolean;
396
- sameSite?: 'strict' | 'lax' | 'none';
396
+ sameSite?: "strict" | "lax" | "none";
397
397
  domain?: string;
398
398
  };
399
399
  forgotPassword?: {
@@ -425,7 +425,7 @@ interface CollectionConfig {
425
425
  pluralName?: string;
426
426
  };
427
427
  indexes?: Array<{
428
- fields: Record<string, number | 'text'>;
428
+ fields: Record<string, number | "text">;
429
429
  options?: Record<string, any>;
430
430
  }>;
431
431
  custom?: Record<string, any>;
@@ -558,7 +558,7 @@ interface BaseAdapter {
558
558
  transaction?<T>(fn: (tx: any) => Promise<T>): Promise<T>;
559
559
  }
560
560
  interface AdapterConfig {
561
- type: 'drizzle' | 'mongodb';
561
+ type: "drizzle" | "mongodb";
562
562
  client: any;
563
563
  schema?: any;
564
564
  connectionOptions?: Record<string, any>;
@@ -578,12 +578,12 @@ interface KyroConfig {
578
578
  globals?: GlobalConfig[];
579
579
  adapter: BaseAdapter;
580
580
  plugins?: PluginConfig[];
581
- auth?: {
582
- secret: string;
581
+ auth?: boolean | {
582
+ secret?: string;
583
583
  tokenExpiration?: number;
584
584
  cookie?: {
585
585
  secure?: boolean;
586
- sameSite?: 'strict' | 'lax' | 'none';
586
+ sameSite?: "strict" | "lax" | "none";
587
587
  domain?: string;
588
588
  };
589
589
  };
@@ -598,7 +598,7 @@ interface KyroConfig {
598
598
  ogImage?: string;
599
599
  };
600
600
  dateFormat?: string;
601
- avatar?: 'default' | 'gravatar';
601
+ avatar?: "default" | "gravatar";
602
602
  disable?: boolean;
603
603
  indexRoute?: string;
604
604
  components?: Record<string, any>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kyro-cms/core",
3
- "version": "0.2.4",
3
+ "version": "0.2.10",
4
4
  "description": "Astro-native headless CMS with multi-database adapters, multi-protocol APIs, and multi-vendor support",
5
5
  "private": false,
6
6
  "publishConfig": {
@@ -107,8 +107,7 @@
107
107
  "@trpc/react-query": "^11.0.0",
108
108
  "@trpc/server": "^11.0.0",
109
109
  "basic-ftp": "^5.3.0",
110
- "bcrypt": "^5.1.1",
111
- "bcryptjs": "^3.0.3",
110
+ "bcryptjs": "^2.4.3",
112
111
  "chalk": "^5.4.1",
113
112
  "commander": "^13.1.0",
114
113
  "cpu-features": "^0.0.10",
@@ -131,7 +130,6 @@
131
130
  "zod": "^3.24.0"
132
131
  },
133
132
  "devDependencies": {
134
- "@types/bcrypt": "^5.0.2",
135
133
  "@types/better-sqlite3": "^7.6.13",
136
134
  "@types/jsonwebtoken": "^9.0.9",
137
135
  "@types/node": "^22.13.0",
@@ -139,6 +137,7 @@
139
137
  "@types/pg": "^8.20.0",
140
138
  "@types/ssh2-sftp-client": "^9.0.6",
141
139
  "@types/ws": "^8.18.1",
140
+ "@typescript-eslint/parser": "^8.59.1",
142
141
  "better-sqlite3": "^11.8.1",
143
142
  "drizzle-kit": "^0.31.10",
144
143
  "eslint": "^9.20.0",
@@ -147,6 +146,7 @@
147
146
  "prettier": "^3.5.0",
148
147
  "tsup": "^8.4.0",
149
148
  "typescript": "^5.7.3",
149
+ "typescript-eslint": "^8.59.1",
150
150
  "vitest": "^3.0.0"
151
151
  },
152
152
  "peerDependencies": {