opacacms 0.3.2 → 0.3.4
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.
- package/dist/admin/index.js +1 -1
- package/dist/admin/react.js +1 -1
- package/dist/admin/vue.js +1 -1
- package/dist/admin/webcomponent.js +35 -37
- package/dist/{chunk-g9bxb6h0.js → chunk-2fm4kv2q.js} +1 -1
- package/dist/chunk-2vbfc4q8.js +6 -0
- package/dist/{chunk-adq2b75c.js → chunk-40tky6qh.js} +2 -2
- package/dist/{chunk-e0g6gn7n.js → chunk-49e16hjg.js} +3 -3
- package/dist/{chunk-fnsf1dfm.js → chunk-526a3gqx.js} +1 -1
- package/dist/{chunk-sqsfk9p4.js → chunk-6m1jhxmd.js} +1 -1
- package/dist/{chunk-6bywt602.js → chunk-8sqjbsgt.js} +1 -26
- package/dist/{chunk-n1twhqmf.js → chunk-acghejk8.js} +1 -1
- package/dist/{chunk-m24yqkeq.js → chunk-b1g8jmth.js} +3 -3
- package/dist/{chunk-5422w4eq.js → chunk-cm5rvcnn.js} +5 -5
- package/dist/{chunk-941zxavt.js → chunk-h2y2t07h.js} +4 -4
- package/dist/{chunk-6qs0g65f.js → chunk-h8v093av.js} +1 -1
- package/dist/{chunk-m5ems3hh.js → chunk-hthm9srb.js} +1 -1
- package/dist/{chunk-2k3ysje3.js → chunk-nch158fe.js} +1 -1
- package/dist/{chunk-naqcqj8n.js → chunk-pj31j6j0.js} +4 -4
- package/dist/{chunk-qsh2nqz3.js → chunk-pw2a9war.js} +3 -3
- package/dist/{chunk-j8js1y0h.js → chunk-r5k7jw66.js} +1 -1
- package/dist/{chunk-48ywpd0a.js → chunk-vmz9ncf1.js} +1 -1
- package/dist/{chunk-qhdsjek6.js → chunk-wry3rqh0.js} +3 -3
- package/dist/cli/index.js +6793 -6
- package/dist/client.js +3 -3
- package/dist/db/better-sqlite.js +4 -4
- package/dist/db/bun-sqlite.js +4 -4
- package/dist/db/d1.js +4 -4
- package/dist/db/index.js +8 -8
- package/dist/db/postgres.js +4 -4
- package/dist/db/sqlite.js +4 -4
- package/dist/index.js +7 -7
- package/dist/runtimes/bun.js +6 -6
- package/dist/runtimes/cloudflare-workers.js +6 -6
- package/dist/runtimes/next.js +6 -6
- package/dist/runtimes/node.js +6 -6
- package/dist/schema/index.js +3 -3
- package/dist/server.js +6 -6
- package/dist/storage/index.js +1 -1
- package/package.json +12 -11
- package/dist/chunk-0hxz770x.js +0 -10
- package/dist/chunk-2gdsy99f.js +0 -581
- package/dist/chunk-3j9zjfmn.js +0 -376
- package/dist/chunk-5b8r0v8c.js +0 -47
- package/dist/chunk-71wwx9vj.js +0 -413
- package/dist/chunk-9by912e9.js +0 -318
- package/dist/chunk-f3dg5dq4.js +0 -75
- package/dist/chunk-g17v7yfr.js +0 -237
- package/dist/chunk-gzdfc1ct.js +0 -1137
- package/dist/chunk-h6dhexzr.js +0 -94
- package/dist/chunk-jvv72110.js +0 -98
- package/dist/chunk-rg3jrfgg.js +0 -93
- package/dist/chunk-rjvcp6ph.js +0 -95
- package/dist/chunk-v0nazhmk.js +0 -263
- package/dist/chunk-wqvdwck9.js +0 -326
- package/dist/chunk-x7bnzswh.js +0 -174
- package/dist/chunk-y4e9twg2.js +0 -76
- package/src/cli/index.ts +0 -117
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
flattenPayload,
|
|
4
4
|
pushSchema,
|
|
5
5
|
unflattenRow
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-r5k7jw66.js";
|
|
7
7
|
import {
|
|
8
8
|
BaseDatabaseAdapter
|
|
9
9
|
} from "./chunk-s8mqwnm1.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
} from "./chunk-jq1drsen.js";
|
|
21
21
|
import {
|
|
22
22
|
__require
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-8sqjbsgt.js";
|
|
24
24
|
|
|
25
25
|
// src/db/sqlite.ts
|
|
26
26
|
import fs from "node:fs/promises";
|
|
@@ -63,7 +63,7 @@ class SQLiteAdapter extends BaseDatabaseAdapter {
|
|
|
63
63
|
const require2 = createRequire(import.meta.url);
|
|
64
64
|
const Database = require2("better-sqlite3");
|
|
65
65
|
this._rawDb = new Database(this.path);
|
|
66
|
-
const { createOpacaKysely } = await import("./chunk-
|
|
66
|
+
const { createOpacaKysely } = await import("./chunk-6m1jhxmd.js");
|
|
67
67
|
this._db = createOpacaKysely({
|
|
68
68
|
dialect: new SqliteDialect({
|
|
69
69
|
database: this._rawDb
|
|
@@ -1,6 +1,4 @@
|
|
|
1
1
|
import { createRequire } from "node:module";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
2
|
var __defProp = Object.defineProperty;
|
|
5
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -8,28 +6,6 @@ var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
|
8
6
|
function __accessProp(key) {
|
|
9
7
|
return this[key];
|
|
10
8
|
}
|
|
11
|
-
var __toESMCache_node;
|
|
12
|
-
var __toESMCache_esm;
|
|
13
|
-
var __toESM = (mod, isNodeMode, target) => {
|
|
14
|
-
var canCache = mod != null && typeof mod === "object";
|
|
15
|
-
if (canCache) {
|
|
16
|
-
var cache = isNodeMode ? __toESMCache_node ??= new WeakMap : __toESMCache_esm ??= new WeakMap;
|
|
17
|
-
var cached = cache.get(mod);
|
|
18
|
-
if (cached)
|
|
19
|
-
return cached;
|
|
20
|
-
}
|
|
21
|
-
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
22
|
-
const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
23
|
-
for (let key of __getOwnPropNames(mod))
|
|
24
|
-
if (!__hasOwnProp.call(to, key))
|
|
25
|
-
__defProp(to, key, {
|
|
26
|
-
get: __accessProp.bind(mod, key),
|
|
27
|
-
enumerable: true
|
|
28
|
-
});
|
|
29
|
-
if (canCache)
|
|
30
|
-
cache.set(mod, to);
|
|
31
|
-
return to;
|
|
32
|
-
};
|
|
33
9
|
var __toCommonJS = (from) => {
|
|
34
10
|
var entry = (__moduleCache ??= new WeakMap).get(from), desc;
|
|
35
11
|
if (entry)
|
|
@@ -47,7 +23,6 @@ var __toCommonJS = (from) => {
|
|
|
47
23
|
return entry;
|
|
48
24
|
};
|
|
49
25
|
var __moduleCache;
|
|
50
|
-
var __commonJS = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
51
26
|
var __returnValue = (v) => v;
|
|
52
27
|
function __exportSetter(name, newValue) {
|
|
53
28
|
this[name] = __returnValue.bind(null, newValue);
|
|
@@ -64,4 +39,4 @@ var __export = (target, all) => {
|
|
|
64
39
|
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
65
40
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
66
41
|
|
|
67
|
-
export {
|
|
42
|
+
export { __toCommonJS, __export, __esm, __require };
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
exports_compiler,
|
|
3
3
|
init_compiler
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-hthm9srb.js";
|
|
5
5
|
import {
|
|
6
6
|
OpacaLogger
|
|
7
7
|
} from "./chunk-jq1drsen.js";
|
|
8
8
|
import {
|
|
9
9
|
getSystemCollections,
|
|
10
10
|
init_system_schema
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-h8v093av.js";
|
|
12
12
|
import {
|
|
13
13
|
__toCommonJS
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-8sqjbsgt.js";
|
|
15
15
|
|
|
16
16
|
// src/auth/index.ts
|
|
17
17
|
import { apiKey } from "@better-auth/api-key";
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
flattenPayload,
|
|
4
4
|
pushSchema,
|
|
5
5
|
unflattenRow
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-r5k7jw66.js";
|
|
7
7
|
import {
|
|
8
8
|
BaseDatabaseAdapter
|
|
9
9
|
} from "./chunk-s8mqwnm1.js";
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
} from "./chunk-jq1drsen.js";
|
|
20
20
|
import {
|
|
21
21
|
__require
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-8sqjbsgt.js";
|
|
23
23
|
|
|
24
24
|
// src/db/postgres.ts
|
|
25
25
|
import fs from "node:fs/promises";
|
|
@@ -71,7 +71,7 @@ class PostgresAdapter extends BaseDatabaseAdapter {
|
|
|
71
71
|
ssl: this.config.ssl
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
|
-
const { createOpacaKysely } = await import("./chunk-
|
|
74
|
+
const { createOpacaKysely } = await import("./chunk-6m1jhxmd.js");
|
|
75
75
|
this._db = createOpacaKysely({
|
|
76
76
|
dialect: new PostgresDialect({
|
|
77
77
|
pool: {
|
|
@@ -184,7 +184,7 @@ class PostgresAdapter extends BaseDatabaseAdapter {
|
|
|
184
184
|
const unflattened = unflattenRow(row);
|
|
185
185
|
const colDef = this._collections.find((c) => c.slug === collection);
|
|
186
186
|
if (colDef) {
|
|
187
|
-
const { getRelationalFields: getRelationalFields2, toSnakeCase: toSnakeCase2 } = await import("./chunk-
|
|
187
|
+
const { getRelationalFields: getRelationalFields2, toSnakeCase: toSnakeCase2 } = await import("./chunk-526a3gqx.js");
|
|
188
188
|
const relationalFields = getRelationalFields2(colDef.fields);
|
|
189
189
|
for (const field of relationalFields) {
|
|
190
190
|
if (!field.name)
|
|
@@ -584,7 +584,7 @@ class PostgresAdapter extends BaseDatabaseAdapter {
|
|
|
584
584
|
}
|
|
585
585
|
}
|
|
586
586
|
async migrate(collections, globals = []) {
|
|
587
|
-
const { getSystemCollections } = await import("./chunk-
|
|
587
|
+
const { getSystemCollections } = await import("./chunk-40tky6qh.js");
|
|
588
588
|
this._collections = [...getSystemCollections(), ...collections];
|
|
589
589
|
this._globals = globals;
|
|
590
590
|
if (this.push && this._db) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createAuth,
|
|
3
3
|
sanitizeConfig
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-b1g8jmth.js";
|
|
5
5
|
import {
|
|
6
6
|
sanitizeGraphQLName
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-2vbfc4q8.js";
|
|
8
8
|
import {
|
|
9
9
|
requestContext
|
|
10
10
|
} from "./chunk-q5sb5dcr.js";
|
|
@@ -19,11 +19,11 @@ import {
|
|
|
19
19
|
exports_system_schema,
|
|
20
20
|
getSystemCollections,
|
|
21
21
|
init_system_schema
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-h8v093av.js";
|
|
23
23
|
import {
|
|
24
24
|
__require,
|
|
25
25
|
__toCommonJS
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-8sqjbsgt.js";
|
|
27
27
|
|
|
28
28
|
// src/server/admin.ts
|
|
29
29
|
function createAdminHandlers(config, settings, getAuth) {
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
flattenPayload,
|
|
4
4
|
pushSchema,
|
|
5
5
|
unflattenRow
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-r5k7jw66.js";
|
|
7
7
|
import {
|
|
8
8
|
BaseDatabaseAdapter
|
|
9
9
|
} from "./chunk-s8mqwnm1.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
} from "./chunk-jq1drsen.js";
|
|
21
21
|
import {
|
|
22
22
|
__require
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-8sqjbsgt.js";
|
|
24
24
|
|
|
25
25
|
// src/db/better-sqlite.ts
|
|
26
26
|
import fs from "node:fs/promises";
|
|
@@ -63,7 +63,7 @@ class BetterSQLiteAdapter extends BaseDatabaseAdapter {
|
|
|
63
63
|
const require2 = createRequire(import.meta.url);
|
|
64
64
|
const Database = require2("better-sqlite3");
|
|
65
65
|
this._rawDb = new Database(this.path);
|
|
66
|
-
const { createOpacaKysely } = await import("./chunk-
|
|
66
|
+
const { createOpacaKysely } = await import("./chunk-6m1jhxmd.js");
|
|
67
67
|
this._db = createOpacaKysely({
|
|
68
68
|
dialect: new SqliteDialect({
|
|
69
69
|
database: this._rawDb
|
|
@@ -178,7 +178,7 @@ class BetterSQLiteAdapter extends BaseDatabaseAdapter {
|
|
|
178
178
|
const unflattened = unflattenRow(row);
|
|
179
179
|
const colDef = this._collections.find((c) => c.slug === collection);
|
|
180
180
|
if (colDef) {
|
|
181
|
-
const { getRelationalFields: getRelationalFields2, toSnakeCase: toSnakeCase2 } = await import("./chunk-
|
|
181
|
+
const { getRelationalFields: getRelationalFields2, toSnakeCase: toSnakeCase2 } = await import("./chunk-526a3gqx.js");
|
|
182
182
|
const relationalFields = getRelationalFields2(colDef.fields);
|
|
183
183
|
for (const field of relationalFields) {
|
|
184
184
|
if (!field.name)
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
flattenPayload,
|
|
4
4
|
pushSchema,
|
|
5
5
|
unflattenRow
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-r5k7jw66.js";
|
|
7
7
|
import {
|
|
8
8
|
BaseDatabaseAdapter
|
|
9
9
|
} from "./chunk-s8mqwnm1.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
} from "./chunk-jq1drsen.js";
|
|
21
21
|
import {
|
|
22
22
|
__require
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-8sqjbsgt.js";
|
|
24
24
|
|
|
25
25
|
// src/db/bun-sqlite.ts
|
|
26
26
|
import fs from "node:fs/promises";
|
|
@@ -57,7 +57,7 @@ class BunSQLiteAdapter extends BaseDatabaseAdapter {
|
|
|
57
57
|
const { Database } = await import("bun:sqlite");
|
|
58
58
|
const { BunSqliteDialect } = await import("kysely-bun-sqlite");
|
|
59
59
|
this._rawDb = new Database(this.path);
|
|
60
|
-
const { createOpacaKysely } = await import("./chunk-
|
|
60
|
+
const { createOpacaKysely } = await import("./chunk-6m1jhxmd.js");
|
|
61
61
|
this._db = createOpacaKysely({
|
|
62
62
|
dialect: new BunSqliteDialect({
|
|
63
63
|
database: this._rawDb
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
flattenPayload,
|
|
4
4
|
pushSchema,
|
|
5
5
|
unflattenRow
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-r5k7jw66.js";
|
|
7
7
|
import {
|
|
8
8
|
BaseDatabaseAdapter
|
|
9
9
|
} from "./chunk-s8mqwnm1.js";
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
} from "./chunk-jq1drsen.js";
|
|
21
21
|
import {
|
|
22
22
|
__require
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-8sqjbsgt.js";
|
|
24
24
|
|
|
25
25
|
// src/db/d1.ts
|
|
26
26
|
import fs from "node:fs/promises";
|
|
@@ -55,7 +55,7 @@ class D1Adapter extends BaseDatabaseAdapter {
|
|
|
55
55
|
if (this._db)
|
|
56
56
|
return;
|
|
57
57
|
const { D1Dialect } = await import("kysely-d1");
|
|
58
|
-
const { createOpacaKysely } = await import("./chunk-
|
|
58
|
+
const { createOpacaKysely } = await import("./chunk-6m1jhxmd.js");
|
|
59
59
|
this._db = createOpacaKysely({
|
|
60
60
|
dialect: new D1Dialect({ database: this._rawDb }),
|
|
61
61
|
config: {
|