@stonecrop/graphql-middleware 0.8.8 → 0.8.9

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/index.js CHANGED
@@ -1,30 +1,30 @@
1
- import { validateDoctype as D, parseDoctype as M } from "@stonecrop/schema";
2
- import { ActionDefinition as me, DoctypeMeta as ge, FieldMeta as he, FieldOptions as $e, FieldValidation as Se, GQL_SCALAR_MAP as we, StonecropFieldType as be, TYPE_MAP as Ne, WELL_KNOWN_SCALARS as Re, WorkflowMeta as De, camelToLabel as Me, camelToSnake as ke, classifyFieldType as Ae, convertGraphQLSchema as qe, defaultIsEntityField as Oe, defaultIsEntityType as Be, getDefaultComponent as Fe, parseDoctype as Ce, parseField as Ee, pascalToSnake as je, snakeToCamel as xe, snakeToLabel as Te, toPascalCase as Ie, toSlug as Je, validateDoctype as Le, validateField as _e } from "@stonecrop/schema";
3
- import { readdirSync as q, statSync as O, readFileSync as B } from "node:fs";
4
- import { join as F } from "node:path";
5
- import { extendSchema as C, gql as E } from "postgraphile/utils";
6
- import { loadOne as w, object as b, constant as j, lambda as x } from "postgraphile/grafast";
7
- const l = /* @__PURE__ */ new Map();
8
- class N extends Error {
9
- constructor(e, o) {
10
- const n = o.map((r) => ` ${r.path.join(".")}: ${r.message}`).join(`
1
+ import { validateDoctype as N, parseDoctype as D } from "@stonecrop/schema";
2
+ import { ActionDefinition as ue, DoctypeMeta as fe, FieldMeta as me, FieldOptions as ge, FieldValidation as he, GQL_SCALAR_MAP as Se, StonecropFieldType as $e, TYPE_MAP as we, WELL_KNOWN_SCALARS as be, WorkflowMeta as Ne, camelToLabel as De, camelToSnake as Re, classifyFieldType as Me, convertGraphQLSchema as ke, defaultIsEntityField as Ae, defaultIsEntityType as qe, getDefaultComponent as Oe, parseDoctype as Fe, parseField as Be, pascalToSnake as Ce, snakeToCamel as Ee, snakeToLabel as je, toPascalCase as xe, toSlug as Te, validateDoctype as Ie, validateField as Je } from "@stonecrop/schema";
3
+ import { readdirSync as k, statSync as A, readFileSync as q } from "node:fs";
4
+ import { join as O } from "node:path";
5
+ import { extendSchema as F, gql as B } from "postgraphile/utils";
6
+ import { loadOne as S, object as $, constant as C, lambda as E } from "postgraphile/grafast";
7
+ const p = /* @__PURE__ */ new Map();
8
+ class w extends Error {
9
+ constructor(e, r) {
10
+ const n = r.map((o) => ` ${o.path.join(".")}: ${o.message}`).join(`
11
11
  `);
12
12
  super(`Invalid doctype definition in ${e}:
13
- ${n}`), this.file = e, this.errors = o, this.name = "DoctypeValidationError";
13
+ ${n}`), this.file = e, this.errors = r, this.name = "DoctypeValidationError";
14
14
  }
15
15
  }
16
- function T(t, e = {}) {
17
- const o = q(t);
18
- for (const n of o) {
19
- const r = F(t, n);
20
- O(r).isDirectory() ? T(r, e) : n.endsWith(".json") && I(r, e);
16
+ function j(t, e = {}) {
17
+ const r = k(t);
18
+ for (const n of r) {
19
+ const o = O(t, n);
20
+ A(o).isDirectory() ? j(o, e) : n.endsWith(".json") && x(o, e);
21
21
  }
22
22
  }
23
- function I(t, e) {
24
- const o = B(t, "utf-8");
23
+ function x(t, e) {
24
+ const r = q(t, "utf-8");
25
25
  let n;
26
26
  try {
27
- n = JSON.parse(o);
27
+ n = JSON.parse(r);
28
28
  } catch (c) {
29
29
  const s = {
30
30
  path: [],
@@ -34,102 +34,102 @@ function I(t, e) {
34
34
  e.onError?.(t, [s]);
35
35
  return;
36
36
  }
37
- throw new N(t, [s]);
37
+ throw new w(t, [s]);
38
38
  }
39
- const r = D(n);
40
- if (!r.success) {
39
+ const o = N(n);
40
+ if (!o.success) {
41
41
  if (e.continueOnError) {
42
- e.onError?.(t, r.errors);
42
+ e.onError?.(t, o.errors);
43
43
  return;
44
44
  }
45
- throw new N(t, r.errors);
45
+ throw new w(t, o.errors);
46
46
  }
47
- const a = M(n);
48
- l.set(a.name, a);
47
+ const a = D(n);
48
+ p.set(a.name, a);
49
49
  }
50
- function ne(t, e = {}) {
51
- for (const [o, n] of Object.entries(t)) {
52
- const r = { ...n, name: o }, a = D(r);
50
+ function re(t, e = {}) {
51
+ for (const [r, n] of Object.entries(t)) {
52
+ const o = { ...n, name: r }, a = N(o);
53
53
  if (!a.success) {
54
54
  if (e.continueOnError) {
55
- e.onError?.(o, a.errors);
55
+ e.onError?.(r, a.errors);
56
56
  continue;
57
57
  }
58
- throw new N(o, a.errors);
58
+ throw new w(r, a.errors);
59
59
  }
60
- const c = M(r);
61
- l.set(c.name, c);
60
+ const c = D(o);
61
+ p.set(c.name, c);
62
62
  }
63
63
  }
64
- function h(t) {
65
- return l.get(t);
64
+ function m(t) {
65
+ return p.get(t);
66
66
  }
67
- function J() {
68
- return Array.from(l.values());
67
+ function T() {
68
+ return Array.from(p.values());
69
69
  }
70
- function ae(t) {
71
- return l.has(t);
70
+ function oe(t) {
71
+ return p.has(t);
72
72
  }
73
- function ce() {
74
- l.clear();
73
+ function ne() {
74
+ p.clear();
75
75
  }
76
- function se() {
76
+ function ae() {
77
77
  const t = [];
78
- for (const e of l.values()) {
79
- e.inherits && !l.has(e.inherits) && t.push({
78
+ for (const e of p.values()) {
79
+ e.inherits && !p.has(e.inherits) && t.push({
80
80
  path: [e.name, "inherits"],
81
81
  message: `References unknown doctype: ${e.inherits}`
82
- }), e.listDoctype && !l.has(e.listDoctype) && t.push({
82
+ }), e.listDoctype && !p.has(e.listDoctype) && t.push({
83
83
  path: [e.name, "listDoctype"],
84
84
  message: `References unknown doctype: ${e.listDoctype}`
85
- }), e.parentDoctype && !l.has(e.parentDoctype) && t.push({
85
+ }), e.parentDoctype && !p.has(e.parentDoctype) && t.push({
86
86
  path: [e.name, "parentDoctype"],
87
87
  message: `References unknown doctype: ${e.parentDoctype}`
88
88
  });
89
- for (const o of e.fields)
90
- o.fieldtype === "Link" && typeof o.options == "string" && (l.has(o.options) || t.push({
91
- path: [e.name, "fields", o.fieldname, "options"],
92
- message: `Link references unknown doctype: ${o.options}`
89
+ for (const r of e.fields)
90
+ r.fieldtype === "Link" && typeof r.options == "string" && (p.has(r.options) || t.push({
91
+ path: [e.name, "fields", r.fieldname, "options"],
92
+ message: `Link references unknown doctype: ${r.options}`
93
93
  }));
94
94
  }
95
95
  return t;
96
96
  }
97
- const $ = /* @__PURE__ */ new Map();
98
- function L(t, e) {
99
- $.set(t, e);
97
+ const g = /* @__PURE__ */ new Map();
98
+ function I(t, e) {
99
+ g.set(t, e);
100
100
  }
101
- function _(t) {
102
- return $.get(t);
101
+ function J(t) {
102
+ return g.get(t);
103
103
  }
104
- function ie(t) {
105
- return $.has(t);
104
+ function ce(t) {
105
+ return g.has(t);
106
106
  }
107
- function de() {
108
- $.clear();
107
+ function se() {
108
+ g.clear();
109
109
  }
110
- const G = async (t, e) => {
111
- const [o] = t, { doctype: n } = e, r = [];
110
+ const L = async (t, e) => {
111
+ const [r] = t, { doctype: n } = e, o = [];
112
112
  for (const a of n.fields)
113
- a.required && (o[a.fieldname] === void 0 || o[a.fieldname] === null) && r.push(a.label ?? a.fieldname);
114
- if (r.length > 0)
115
- throw new Error(`Missing required fields: ${r.join(", ")}`);
113
+ a.required && (r[a.fieldname] === void 0 || r[a.fieldname] === null) && o.push(a.label ?? a.fieldname);
114
+ if (o.length > 0)
115
+ throw new Error(`Missing required fields: ${o.join(", ")}`);
116
116
  return { valid: !0 };
117
- }, U = async (t, e) => {
118
- const [o] = t, { doctype: n } = e, r = [];
117
+ }, _ = async (t, e) => {
118
+ const [r] = t, { doctype: n } = e, o = [];
119
119
  for (const a of n.fields) {
120
- const c = o[a.fieldname];
120
+ const c = r[a.fieldname];
121
121
  if (c == null) continue;
122
- const s = H(a.fieldname, c, a.fieldtype);
123
- s && r.push(s);
122
+ const s = G(a.fieldname, c, a.fieldtype);
123
+ s && o.push(s);
124
124
  }
125
- if (r.length > 0)
125
+ if (o.length > 0)
126
126
  throw new Error(`Field type validation failed:
127
- ${r.join(`
127
+ ${o.join(`
128
128
  `)}`);
129
129
  return { valid: !0 };
130
130
  };
131
- function H(t, e, o) {
132
- switch (o) {
131
+ function G(t, e, r) {
132
+ switch (r) {
133
133
  case "Int":
134
134
  if (typeof e != "number" || !Number.isInteger(e))
135
135
  return `${t}: expected integer, got ${typeof e}`;
@@ -169,19 +169,19 @@ function H(t, e, o) {
169
169
  }
170
170
  return null;
171
171
  }
172
- const P = async () => ({ ok: !0 }), Q = {
173
- validateRequiredFields: G,
174
- validateFieldTypes: U,
175
- noop: P
172
+ const U = async () => ({ ok: !0 }), H = {
173
+ validateRequiredFields: L,
174
+ validateFieldTypes: _,
175
+ noop: U
176
176
  };
177
- function le() {
178
- for (const [t, e] of Object.entries(Q))
179
- L(t, e);
177
+ function ie() {
178
+ for (const [t, e] of Object.entries(H))
179
+ I(t, e);
180
180
  }
181
- const pe = (t) => {
182
- const e = t.inflection?.recordFieldName ?? W, o = t.inflection?.connectionFieldName ?? V, n = t.inflection?.orderByTypeName ?? v;
183
- return C(() => ({
184
- typeDefs: E`
181
+ const de = (t) => {
182
+ const e = t.inflection?.recordFieldName ?? P, r = t.inflection?.connectionFieldName ?? Q, n = t.inflection?.orderByTypeName ?? W;
183
+ return F(() => ({
184
+ typeDefs: B`
185
185
  type StonecropFieldMeta {
186
186
  fieldname: String!
187
187
  fieldtype: String!
@@ -250,65 +250,62 @@ const pe = (t) => {
250
250
  objects: {
251
251
  Query: {
252
252
  plans: {
253
- stonecropMeta(r, a) {
254
- const c = a.getRaw().doctype;
255
- return x(c, (s) => h(s) ?? null);
253
+ stonecropMeta(o, { $doctype: a }) {
254
+ return E(a, (c) => m(c) ?? null);
256
255
  },
257
256
  stonecropAllMeta() {
258
- return j(J());
257
+ return C(T());
259
258
  },
260
- stonecropRecord(r, a) {
261
- const c = a.getRaw().doctype, s = a.getRaw().id;
262
- return w(b({ doctype: c, id: s }), async (y) => await Promise.all(
263
- y.map(async (d) => {
264
- const u = h(d.doctype);
265
- if (!u)
266
- throw new Error(`Unknown doctype: ${d.doctype}`);
267
- if (!u.tableName)
268
- throw new Error(`Doctype ${d.doctype} has no table mapping`);
269
- const p = z(u, e), f = await t.executor.query(p, { id: d.id });
259
+ stonecropRecord(o, { $doctype: a, $id: c }) {
260
+ return S($({ doctype: a, id: c }), async (s) => await Promise.all(
261
+ s.map(async (l) => {
262
+ const d = m(l.doctype);
263
+ if (!d)
264
+ throw new Error(`Unknown doctype: ${l.doctype}`);
265
+ if (!d.tableName)
266
+ throw new Error(`Doctype ${l.doctype} has no table mapping`);
267
+ const y = V(d, e), i = await t.executor.query(y, { id: l.id });
270
268
  return {
271
- data: Y(f, u, e),
272
- doctype: d.doctype
269
+ data: z(i, d, e),
270
+ doctype: l.doctype
273
271
  };
274
272
  })
275
273
  ));
276
274
  },
277
- stonecropRecords(r, a) {
278
- const c = a.getRaw(), s = c.doctype, y = c.filters, d = c.orderBy, u = c.limit, p = c.offset;
279
- return w(
280
- b({
281
- doctype: s,
282
- filters: y,
283
- orderBy: d,
284
- limit: u,
285
- offset: p
275
+ stonecropRecords(o, { $doctype: a, $filters: c, $orderBy: s, $limit: l, $offset: d }) {
276
+ return S(
277
+ $({
278
+ doctype: a,
279
+ filters: c,
280
+ orderBy: s,
281
+ limit: l,
282
+ offset: d
286
283
  }),
287
- async (f) => await Promise.all(
288
- f.map(async (i) => {
289
- const m = h(i.doctype);
290
- if (!m)
284
+ async (y) => await Promise.all(
285
+ y.map(async (i) => {
286
+ const u = m(i.doctype);
287
+ if (!u)
291
288
  throw new Error(`Unknown doctype: ${i.doctype}`);
292
- if (!m.tableName)
289
+ if (!u.tableName)
293
290
  throw new Error(`Doctype ${i.doctype} has no table mapping`);
294
- const S = K(
295
- m,
291
+ const h = v(
292
+ u,
296
293
  {
297
294
  limit: i.limit,
298
295
  offset: i.offset,
299
296
  orderBy: i.orderBy
300
297
  },
301
- o,
298
+ r,
302
299
  n
303
- ), g = await t.executor.query(S, {
300
+ ), f = await t.executor.query(h, {
304
301
  limit: i.limit,
305
302
  offset: i.offset,
306
303
  orderBy: i.orderBy
307
- }), R = X(g, m, o);
304
+ }), b = K(f, u, r);
308
305
  return {
309
- data: R,
306
+ data: b,
310
307
  doctype: i.doctype,
311
- count: R.length
308
+ count: b.length
312
309
  };
313
310
  })
314
311
  )
@@ -318,52 +315,51 @@ const pe = (t) => {
318
315
  },
319
316
  Mutation: {
320
317
  plans: {
321
- stonecropAction(r, a) {
322
- const c = a.getRaw(), s = c.doctype, y = c.action, d = c.args;
323
- return w(
324
- b({
325
- doctype: s,
326
- action: y,
327
- actionArgs: d
318
+ stonecropAction(o, { $doctype: a, $action: c, $args: s }) {
319
+ return S(
320
+ $({
321
+ doctype: a,
322
+ action: c,
323
+ actionArgs: s
328
324
  }),
329
- async (u) => await Promise.all(
330
- u.map(async (p) => {
331
- const f = h(p.doctype);
332
- if (!f)
325
+ async (l) => await Promise.all(
326
+ l.map(async (d) => {
327
+ const y = m(d.doctype);
328
+ if (!y)
333
329
  return {
334
330
  success: !1,
335
331
  data: null,
336
- error: `Unknown doctype: ${p.doctype}`
332
+ error: `Unknown doctype: ${d.doctype}`
337
333
  };
338
- const i = f.workflow?.actions?.[p.action];
334
+ const i = y.workflow?.actions?.[d.action];
339
335
  if (!i)
340
336
  return {
341
337
  success: !1,
342
338
  data: null,
343
- error: `Unknown action: ${p.action} on ${p.doctype}`
339
+ error: `Unknown action: ${d.action} on ${d.doctype}`
344
340
  };
345
- const m = _(i.handler);
346
- if (!m)
341
+ const u = J(i.handler);
342
+ if (!u)
347
343
  return {
348
344
  success: !1,
349
345
  data: null,
350
346
  error: `Handler not registered: ${i.handler}`
351
347
  };
352
- const S = {
353
- doctype: f,
348
+ const h = {
349
+ doctype: y,
354
350
  executor: t.executor
355
351
  };
356
352
  try {
357
353
  return {
358
354
  success: !0,
359
- data: await m(p.actionArgs ?? [], S),
355
+ data: await u(d.actionArgs ?? [], h),
360
356
  error: null
361
357
  };
362
- } catch (g) {
358
+ } catch (f) {
363
359
  return {
364
360
  success: !1,
365
361
  data: null,
366
- error: g instanceof Error ? g.message : String(g)
362
+ error: f instanceof Error ? f.message : String(f)
367
363
  };
368
364
  }
369
365
  })
@@ -375,58 +371,58 @@ const pe = (t) => {
375
371
  }
376
372
  }));
377
373
  };
378
- function k(t) {
379
- return t.replace(/_([a-z])/g, (e, o) => o.toUpperCase());
374
+ function R(t) {
375
+ return t.replace(/_([a-z])/g, (e, r) => r.toUpperCase());
380
376
  }
381
- function A(t) {
382
- const e = k(t);
377
+ function M(t) {
378
+ const e = R(t);
383
379
  return e.charAt(0).toUpperCase() + e.slice(1);
384
380
  }
385
- function W(t) {
381
+ function P(t) {
386
382
  const e = t.replace(/s$/, "");
387
- return `${k(e)}ById`;
383
+ return `${R(e)}ById`;
388
384
  }
389
- function V(t) {
390
- return `all${A(t)}`;
385
+ function Q(t) {
386
+ return `all${M(t)}`;
391
387
  }
392
- function v(t) {
393
- return `${A(t)}OrderBy`;
388
+ function W(t) {
389
+ return `${M(t)}OrderBy`;
394
390
  }
395
- function z(t, e) {
396
- const o = t.fields.map((r) => r.fieldname).join(`
391
+ function V(t, e) {
392
+ const r = t.fields.map((o) => o.fieldname).join(`
397
393
  `);
398
394
  return `
399
395
  query GetRecord($id: UUID!) {
400
396
  ${e(t.tableName)}(id: $id) {
401
- ${o}
397
+ ${r}
402
398
  }
403
399
  }
404
400
  `;
405
401
  }
406
- function K(t, e, o, n) {
407
- const r = t.fields.map((d) => d.fieldname).join(`
408
- `), a = o(t.tableName), c = n(t.tableName), s = [];
402
+ function v(t, e, r, n) {
403
+ const o = t.fields.map((d) => d.fieldname).join(`
404
+ `), a = r(t.tableName), c = n(t.tableName), s = [];
409
405
  e.limit && s.push("first: $limit"), e.offset && s.push("offset: $offset"), e.orderBy && s.push("orderBy: $orderBy");
410
- const y = s.length > 0 ? `(${s.join(", ")})` : "";
406
+ const l = s.length > 0 ? `(${s.join(", ")})` : "";
411
407
  return `
412
408
  query GetRecords($limit: Int, $offset: Int, $orderBy: [${c}!]) {
413
- ${a}${y} {
409
+ ${a}${l} {
414
410
  nodes {
415
- ${r}
411
+ ${o}
416
412
  }
417
413
  }
418
414
  }
419
415
  `;
420
416
  }
421
- function Y(t, e, o) {
422
- const n = o(e.tableName);
417
+ function z(t, e, r) {
418
+ const n = r(e.tableName);
423
419
  return t[n];
424
420
  }
425
- function X(t, e, o) {
426
- const n = o(e.tableName);
421
+ function K(t, e, r) {
422
+ const n = r(e.tableName);
427
423
  return t[n]?.nodes ?? [];
428
424
  }
429
- class ye {
425
+ class le {
430
426
  endpoint;
431
427
  headers;
432
428
  metaCache = /* @__PURE__ */ new Map();
@@ -441,31 +437,31 @@ class ye {
441
437
  * @param query - GraphQL query string
442
438
  * @param variables - Query variables
443
439
  */
444
- async query(e, o) {
445
- const r = await (await fetch(this.endpoint, {
440
+ async query(e, r) {
441
+ const o = await (await fetch(this.endpoint, {
446
442
  method: "POST",
447
443
  headers: this.headers,
448
- body: JSON.stringify({ query: e, variables: o })
444
+ body: JSON.stringify({ query: e, variables: r })
449
445
  })).json();
450
- if (r.errors?.length)
451
- throw new Error(r.errors[0].message);
452
- return r.data;
446
+ if (o.errors?.length)
447
+ throw new Error(o.errors[0].message);
448
+ return o.data;
453
449
  }
454
450
  /**
455
451
  * Execute a GraphQL mutation
456
452
  * @param mutation - GraphQL mutation string
457
453
  * @param variables - Mutation variables
458
454
  */
459
- async mutate(e, o) {
460
- return this.query(e, o);
455
+ async mutate(e, r) {
456
+ return this.query(e, r);
461
457
  }
462
458
  /**
463
459
  * Get doctype metadata
464
460
  * @param context - Route context containing doctype name
465
461
  */
466
462
  async getMeta(e) {
467
- const o = this.metaCache.get(e.doctype);
468
- if (o) return o;
463
+ const r = this.metaCache.get(e.doctype);
464
+ if (r) return r;
469
465
  const n = await this.query(
470
466
  `
471
467
  query GetMeta($doctype: String!) {
@@ -531,8 +527,8 @@ class ye {
531
527
  }
532
528
  `
533
529
  );
534
- for (const o of e.stonecropAllMeta)
535
- this.metaCache.set(o.name, o);
530
+ for (const r of e.stonecropAllMeta)
531
+ this.metaCache.set(r.name, r);
536
532
  return e.stonecropAllMeta;
537
533
  }
538
534
  /**
@@ -540,7 +536,7 @@ class ye {
540
536
  * @param doctype - Doctype metadata
541
537
  * @param recordId - Record ID to fetch
542
538
  */
543
- async getRecord(e, o) {
539
+ async getRecord(e, r) {
544
540
  return (await this.query(
545
541
  `
546
542
  query GetRecord($doctype: String!, $id: String!) {
@@ -549,7 +545,7 @@ class ye {
549
545
  }
550
546
  }
551
547
  `,
552
- { doctype: e.name, id: o }
548
+ { doctype: e.name, id: r }
553
549
  )).stonecropRecord.data;
554
550
  }
555
551
  /**
@@ -557,7 +553,7 @@ class ye {
557
553
  * @param doctype - Doctype metadata
558
554
  * @param options - Query options (filters, orderBy, limit, offset)
559
555
  */
560
- async getRecords(e, o) {
556
+ async getRecords(e, r) {
561
557
  return (await this.query(
562
558
  `
563
559
  query GetRecords(
@@ -581,7 +577,7 @@ class ye {
581
577
  `,
582
578
  {
583
579
  doctype: e.name,
584
- ...o
580
+ ...r
585
581
  }
586
582
  )).stonecropRecords.data;
587
583
  }
@@ -591,7 +587,7 @@ class ye {
591
587
  * @param action - Action name to execute
592
588
  * @param args - Action arguments
593
589
  */
594
- async runAction(e, o, n) {
590
+ async runAction(e, r, n) {
595
591
  return (await this.query(
596
592
  `
597
593
  mutation RunAction($doctype: String!, $action: String!, $args: JSON) {
@@ -604,7 +600,7 @@ class ye {
604
600
  `,
605
601
  {
606
602
  doctype: e.name,
607
- action: o,
603
+ action: r,
608
604
  args: n
609
605
  }
610
606
  )).stonecropAction;
@@ -617,46 +613,47 @@ class ye {
617
613
  }
618
614
  }
619
615
  export {
620
- me as ActionDefinition,
621
- ge as DoctypeMeta,
622
- N as DoctypeValidationError,
623
- he as FieldMeta,
624
- $e as FieldOptions,
625
- Se as FieldValidation,
626
- we as GQL_SCALAR_MAP,
627
- ye as StonecropClient,
628
- be as StonecropFieldType,
629
- Ne as TYPE_MAP,
630
- Re as WELL_KNOWN_SCALARS,
631
- De as WorkflowMeta,
632
- Q as builtinHandlers,
633
- Me as camelToLabel,
634
- ke as camelToSnake,
635
- Ae as classifyFieldType,
636
- de as clearHandlers,
637
- ce as clearRegistry,
638
- qe as convertGraphQLSchema,
639
- pe as createStonecropPlugin,
640
- Oe as defaultIsEntityField,
641
- Be as defaultIsEntityType,
642
- J as getAllMeta,
643
- Fe as getDefaultComponent,
644
- _ as getHandler,
645
- h as getMeta,
646
- ie as hasHandler,
647
- ae as hasMeta,
648
- T as loadDoctypes,
649
- ne as loadDoctypesFromObject,
650
- Ce as parseDoctype,
651
- Ee as parseField,
652
- je as pascalToSnake,
653
- le as registerBuiltinHandlers,
654
- L as registerHandler,
655
- xe as snakeToCamel,
656
- Te as snakeToLabel,
657
- Ie as toPascalCase,
658
- Je as toSlug,
659
- Le as validateDoctype,
660
- _e as validateField,
661
- se as validateReferences
616
+ ue as ActionDefinition,
617
+ fe as DoctypeMeta,
618
+ w as DoctypeValidationError,
619
+ me as FieldMeta,
620
+ ge as FieldOptions,
621
+ he as FieldValidation,
622
+ Se as GQL_SCALAR_MAP,
623
+ le as StonecropClient,
624
+ $e as StonecropFieldType,
625
+ we as TYPE_MAP,
626
+ be as WELL_KNOWN_SCALARS,
627
+ Ne as WorkflowMeta,
628
+ H as builtinHandlers,
629
+ De as camelToLabel,
630
+ Re as camelToSnake,
631
+ Me as classifyFieldType,
632
+ se as clearHandlers,
633
+ ne as clearRegistry,
634
+ ke as convertGraphQLSchema,
635
+ de as createStonecropPlugin,
636
+ Ae as defaultIsEntityField,
637
+ qe as defaultIsEntityType,
638
+ T as getAllMeta,
639
+ Oe as getDefaultComponent,
640
+ J as getHandler,
641
+ m as getMeta,
642
+ ce as hasHandler,
643
+ oe as hasMeta,
644
+ j as loadDoctypes,
645
+ re as loadDoctypesFromObject,
646
+ Fe as parseDoctype,
647
+ Be as parseField,
648
+ Ce as pascalToSnake,
649
+ ie as registerBuiltinHandlers,
650
+ I as registerHandler,
651
+ Ee as snakeToCamel,
652
+ je as snakeToLabel,
653
+ xe as toPascalCase,
654
+ Te as toSlug,
655
+ Ie as validateDoctype,
656
+ Je as validateField,
657
+ ae as validateReferences
662
658
  };
659
+ //# sourceMappingURL=index.js.map