@easy-cms/core 1.21.0 → 1.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4973,7 +4973,7 @@ var GLOBAL = keys(
4973
4973
  );
4974
4974
  var CONTAINER_ADMIN = keys("icon order sidebar layout group");
4975
4975
  var COLLECTION_ADMIN = keys(
4976
- "icon order sidebar layout group editIn badge count empty list ownerField confirmDelete"
4976
+ "icon order sidebar layout group editIn badge count empty list calendar ownerField confirmDelete"
4977
4977
  );
4978
4978
  var FIELD_ADMIN = keys(
4979
4979
  "description width condition component after cell column allowCreate initialValue position filter"
@@ -5109,6 +5109,8 @@ function checkConfigKeys(config, add) {
5109
5109
  collection2 ? COLLECTION_ADMIN : CONTAINER_ADMIN,
5110
5110
  add
5111
5111
  );
5112
+ if (collection2 && isObject(item.admin) && isObject(item.admin.calendar))
5113
+ check2(item.admin.calendar, `${at}.admin.calendar`, "calendar", keys("start end color"), add);
5112
5114
  if (isObject(item.versions))
5113
5115
  check2(item.versions, `${at}.versions`, "versions", keys("keep"), add);
5114
5116
  checkFields(item.fields, `${at}.fields`, add);
@@ -5140,6 +5142,7 @@ var BUILTIN_NAV = [
5140
5142
  }
5141
5143
  ];
5142
5144
  var MEDIA_ORDER = 10;
5145
+ var CALENDAR_ORDER = 5;
5143
5146
  var LABEL_ORDER = 500;
5144
5147
  var NAV_ID = /^[a-z][a-z0-9-]*$/;
5145
5148
  function mergeGroups(lists, parent = "") {
@@ -6756,6 +6759,9 @@ function validateContainer(container, path, collectionSlugs, add, { collection:
6756
6759
  validateCollectionAdmin(admin, `${path}.admin`, add);
6757
6760
  const list = admin.list;
6758
6761
  if (list !== void 0) validateList(list, container, `${path}.admin.list`, add);
6762
+ const calendar = admin.calendar;
6763
+ if (collection2 && calendar !== void 0)
6764
+ validateCalendar(calendar, container, `${path}.admin.calendar`, add);
6759
6765
  const owner = admin.ownerField;
6760
6766
  if (owner !== void 0) {
6761
6767
  const field = container.fields.find((f) => f.name === owner);
@@ -6828,6 +6834,35 @@ function validateFields2(fields, path, reserved, collectionSlugs, add) {
6828
6834
  validateField(field, fieldPath, byName, collectionSlugs, add);
6829
6835
  }
6830
6836
  }
6837
+ function validateCalendar(calendar, container, path, add) {
6838
+ if (typeof calendar !== "object" || calendar === null) {
6839
+ add(path, "must be an object", "e.g. calendar: { start: 'startsAt', end: 'endsAt' }");
6840
+ return;
6841
+ }
6842
+ const { start, end, color } = calendar;
6843
+ const fieldNamed = (name) => typeof name === "string" ? container.fields.find((f) => f.name === name) : void 0;
6844
+ for (const [key, value, required] of [
6845
+ ["start", start, true],
6846
+ ["end", end, false]
6847
+ ]) {
6848
+ if (value === void 0 && !required) continue;
6849
+ if (fieldNamed(value)?.type !== "date")
6850
+ add(
6851
+ `${path}.${key}`,
6852
+ "must name a top-level date field",
6853
+ `e.g. { name: '${key}sAt', type: 'date' }`
6854
+ );
6855
+ }
6856
+ if (start !== void 0 && start === end) add(`${path}.end`, "must differ from start");
6857
+ if (color === void 0) return;
6858
+ const field = fieldNamed(color);
6859
+ if (field?.type !== "select" && field?.type !== "relationship" || "hasMany" in field && field.hasMany)
6860
+ add(
6861
+ `${path}.color`,
6862
+ "must name a top-level select or relationship field (not hasMany)",
6863
+ "e.g. color: 'category'"
6864
+ );
6865
+ }
6831
6866
  function validateList(list, container, path, add) {
6832
6867
  if (typeof list !== "object" || list === null) {
6833
6868
  add(path, "must be an object", "e.g. list: { tree: 'parent' }");
@@ -7422,7 +7457,7 @@ function cacheableResponse(request, body, status, headers, times, tags) {
7422
7457
  }
7423
7458
 
7424
7459
  // src/version.ts
7425
- var VERSION = true ? "1.21.0" : "0.0.0-dev";
7460
+ var VERSION = true ? "1.23.0" : "0.0.0-dev";
7426
7461
 
7427
7462
  // src/telemetry.ts
7428
7463
  var DB_CALLS = /* @__PURE__ */ new Set([
@@ -9619,15 +9654,28 @@ var EasyCMS = class {
9619
9654
  }
9620
9655
  /**
9621
9656
  * The next pending jobs across all collections and globals, soonest first; with access
9622
- * enforced, only those the user may update.
9657
+ * enforced, only those the user may update. `from` and `to` (ISO) keep those due in that
9658
+ * range, e.g. for a calendar; `collection` (and `docs`, its ids) those of a list page.
9623
9659
  */
9624
9660
  async upcomingSchedules(options = {}) {
9625
9661
  if (!this.config.collections.some((c) => c.slug === SCHEDULED_JOBS)) return [];
9626
9662
  const guard = guardOf(options);
9627
9663
  const limit = options.limit ?? 10;
9664
+ const due = {
9665
+ ...options.from !== void 0 ? { gte: options.from } : {},
9666
+ ...options.to !== void 0 ? { lt: options.to } : {}
9667
+ };
9628
9668
  const rows = await this.db.find({
9629
9669
  collection: SCHEDULED_JOBS,
9630
- where: { state: { equals: "pending" } },
9670
+ where: {
9671
+ and: [
9672
+ { state: { equals: "pending" } },
9673
+ ...Object.keys(due).length ? [{ runAt: due }] : [],
9674
+ ...options.collection !== void 0 ? [{ parent: { equals: options.collection } }] : [],
9675
+ // Jobs keep the document's id as a number (`doc`).
9676
+ ...options.docs !== void 0 ? [{ doc: { in: options.docs.map(Number) } }] : []
9677
+ ]
9678
+ },
9631
9679
  sort: ["runAt"],
9632
9680
  limit: limit * 5,
9633
9681
  page: 1
@@ -10672,6 +10720,9 @@ var has = (config, slug2) => config.collections.some((c) => c.slug === slug2);
10672
10720
  function hasJobsPage(config) {
10673
10721
  return config.jobs.length > 0 || has(config, SCHEDULED_JOBS) || has(config, OUTBOX);
10674
10722
  }
10723
+ function hasCalendarPage(config) {
10724
+ return config.collections.some((c) => c.admin?.calendar !== void 0 || c.schedule === true);
10725
+ }
10675
10726
  var text2 = (value) => typeof value === "string" && value !== "" ? value : null;
10676
10727
  async function adminJobs(cms, user) {
10677
10728
  const { config } = cms;
@@ -10946,7 +10997,8 @@ var Roles = class {
10946
10997
  if ((id === "deliveries" || id === "jobs") && user.scoped === true) return false;
10947
10998
  if (id === "audit" && user.role === "admin" && user.scoped === true && this.config.audit !== false && typeof this.config.audit.scope === "function")
10948
10999
  return true;
10949
- if (!this.enabled) return id.startsWith("page:") || id.startsWith("widget:");
11000
+ if (!this.enabled)
11001
+ return id === "calendar" || id.startsWith("page:") || id.startsWith("widget:");
10950
11002
  return (await this.permissionsOf(user.role)).admin?.includes(id) ?? false;
10951
11003
  }
10952
11004
  /**
@@ -11230,6 +11282,7 @@ var Roles = class {
11230
11282
  (c) => c.slug === WEBHOOK_DELIVERIES || c.slug === EMAIL_DELIVERIES
11231
11283
  ) ? [{ id: "deliveries" }] : [],
11232
11284
  ...hasJobsPage(this.config) ? [{ id: "jobs" }] : [],
11285
+ ...hasCalendarPage(this.config) ? [{ id: "calendar" }] : [],
11233
11286
  ...this.config.admin.pages.map((page) => ({ id: viewId.page(page.path), label: page.label })),
11234
11287
  ...this.config.admin.dashboard.map((widget) => ({
11235
11288
  id: viewId.widget(widget.id ?? tagOf(widget.component)),
@@ -11845,6 +11898,7 @@ async function collection(cms, config, user, localized, roles, context) {
11845
11898
  if (config.admin?.empty) result.empty = JSON.parse(JSON.stringify(config.admin.empty));
11846
11899
  if (config.admin?.list?.tree) result.tree = config.admin.list.tree;
11847
11900
  if (config.admin?.list?.sort) result.defaultSort = config.admin.list.sort;
11901
+ if (config.admin?.calendar) result.calendar = { ...config.admin.calendar };
11848
11902
  if (config.admin?.confirmDelete) result.confirmDelete = { ...config.admin.confirmDelete };
11849
11903
  const owner = cms.roles.ownerOf(config.slug);
11850
11904
  if (owner && fields.some((f) => f.name === owner)) result.owner = owner;
@@ -11893,7 +11947,8 @@ async function adminSchema(cms, user, origin, context = {}) {
11893
11947
  email: admin,
11894
11948
  roles: admin && cms.roles.enabled,
11895
11949
  sso: admin && cms.auth.sso.enabled,
11896
- audit: cms.audit.enabled && await cms.roles.canView(user, "audit")
11950
+ audit: cms.audit.enabled && await cms.roles.canView(user, "audit"),
11951
+ calendar: hasCalendarPage(cms.config) && await cms.roles.canView(user, "calendar")
11897
11952
  };
11898
11953
  const roles = await cms.roles.options();
11899
11954
  const adminCollections = await Promise.all(
@@ -12104,6 +12159,7 @@ function buildNav(cms, collections, globals, pageRefs, views) {
12104
12159
  if (own.length)
12105
12160
  root.push({ order: LABEL_ORDER + i++, node: { kind: "group", id, label, items: own } });
12106
12161
  }
12162
+ if (views.calendar) root.push({ order: CALENDAR_ORDER, node: { kind: "view", view: "calendar" } });
12107
12163
  if (media) root.push({ order: MEDIA_ORDER, node: { kind: "collection", slug: MEDIA } });
12108
12164
  return root.sort((a, b) => a.order - b.order).map((r) => r.node);
12109
12165
  }
@@ -12398,6 +12454,7 @@ function parseDepth(url) {
12398
12454
  }
12399
12455
 
12400
12456
  // src/rest/handler.ts
12457
+ var SCHEDULED_RANGE_LIMIT = 500;
12401
12458
  var CSRF_COOKIE = "ecms-csrf";
12402
12459
  var CSRF_HEADER = "x-csrf-token";
12403
12460
  var MAX_BODY_BYTES = 1024 * 1024;
@@ -13125,14 +13182,34 @@ async function route(cms, ctx, method, path, options) {
13125
13182
  if (!await cms.roles.canView(ctx.user, "status")) throw new ForbiddenError();
13126
13183
  return { body: await adminStatus(cms) };
13127
13184
  }
13128
- if (second === "scheduled" && third === void 0)
13185
+ if (second === "scheduled" && third === void 0) {
13186
+ const moment = (name) => {
13187
+ const value = ctx.url.searchParams.get(name);
13188
+ if (value === null) return void 0;
13189
+ if (Number.isNaN(Date.parse(value)))
13190
+ throw new HttpError(`${name} must be an ISO date and time`, 400);
13191
+ return new Date(value).toISOString();
13192
+ };
13193
+ const from = moment("from");
13194
+ const to = moment("to");
13195
+ const collection4 = ctx.url.searchParams.get("collection") ?? void 0;
13196
+ const docs = ctx.url.searchParams.get("docs")?.split(",").filter(Boolean);
13197
+ if (docs && docs.length > SCHEDULED_RANGE_LIMIT)
13198
+ throw new HttpError(`docs: at most ${SCHEDULED_RANGE_LIMIT}`, 400);
13199
+ const ranged = from !== void 0 || to !== void 0 || collection4 !== void 0;
13129
13200
  return {
13130
13201
  body: await cms.upcomingSchedules({
13131
13202
  user: ctx.user,
13132
13203
  context: ctx.context,
13133
- overrideAccess: false
13204
+ overrideAccess: false,
13205
+ ...from !== void 0 ? { from } : {},
13206
+ ...to !== void 0 ? { to } : {},
13207
+ ...collection4 !== void 0 ? { collection: collection4 } : {},
13208
+ ...docs !== void 0 ? { docs } : {},
13209
+ ...ranged ? { limit: SCHEDULED_RANGE_LIMIT } : {}
13134
13210
  })
13135
13211
  };
13212
+ }
13136
13213
  const [, , collection3, id2, extra] = segments;
13137
13214
  if (second === "access" && collection3 && id2 && extra === void 0) {
13138
13215
  if (INTERNAL_COLLECTIONS.has(collection3) || !cms.config.collections.some((c) => c.slug === collection3)) {
@@ -2242,10 +2242,15 @@ declare class EasyCMS<C extends Config = Config> {
2242
2242
  private addJob;
2243
2243
  /**
2244
2244
  * The next pending jobs across all collections and globals, soonest first; with access
2245
- * enforced, only those the user may update.
2245
+ * enforced, only those the user may update. `from` and `to` (ISO) keep those due in that
2246
+ * range, e.g. for a calendar; `collection` (and `docs`, its ids) those of a list page.
2246
2247
  */
2247
2248
  upcomingSchedules(options?: AccessOptions & {
2248
2249
  limit?: number;
2250
+ from?: string;
2251
+ to?: string;
2252
+ collection?: string;
2253
+ docs?: readonly ID[];
2249
2254
  }): Promise<(ScheduledPublish & {
2250
2255
  collection?: string;
2251
2256
  global?: string;
@@ -3002,6 +3007,8 @@ interface CollectionAdmin extends ContainerAdmin {
3002
3007
  };
3003
3008
  };
3004
3009
  readonly list?: CollectionListAdmin;
3010
+ /** A Calendar mode beside the list, placing documents by date. See `CollectionCalendarAdmin`. */
3011
+ readonly calendar?: CollectionCalendarAdmin;
3005
3012
  /**
3006
3013
  * With `auth.rbac`: the relationship field to `users` that names a document's owner, e.g.
3007
3014
  * `author`, for roles given "own documents only". Default: who created it (`createdBy`).
@@ -3018,6 +3025,18 @@ interface CollectionAdmin extends ContainerAdmin {
3018
3025
  readonly impact?: string;
3019
3026
  };
3020
3027
  }
3028
+ /**
3029
+ * Where a document sits in the list's Calendar mode: top-level date fields, and optionally a field
3030
+ * that colours it. E.g. `{ start: 'startsAt', end: 'endsAt', color: 'category' }`.
3031
+ */
3032
+ interface CollectionCalendarAdmin {
3033
+ /** A top-level date field: when it starts. */
3034
+ readonly start: string;
3035
+ /** A top-level date field: when it ends. Without it, a document takes one hour (or the day). */
3036
+ readonly end?: string;
3037
+ /** A top-level select or relationship field (not hasMany): one colour per value. */
3038
+ readonly color?: string;
3039
+ }
3021
3040
  interface CollectionListAdmin {
3022
3041
  /**
3023
3042
  * Show the list as a tree: the name of a relationship field to this same collection (e.g.
@@ -3770,5 +3789,5 @@ interface ResolvedConfig extends Omit<Config, 'cors' | 'localization' | 'routes'
3770
3789
  */
3771
3790
  declare function defineConfig<const TConfig extends Config>(config: TConfig): TConfig;
3772
3791
 
3773
- export { ADAPTER_API_VERSION as A, EasyCMS as E, AuditLog as S, Auth as V, EasyCMSError as aD, FIELD_TYPES as aK, ConfigError as al, ForbiddenError as b2, PLUGIN_API_VERSION as bB, PayloadTooLargeError as bG, QueryError as bM, ROLE_OPERATIONS as bN, Roles as bX, SchemaError as b_, NotFoundError as bv, API_KEYS as c$, WEBHOOK_EVENTS as cC, anyone as cH, consoleEmail as cI, consoleLogger as cJ, createEasyCMS as cK, defineConfig as cL, defineFieldType as cM, definePlugin as cN, diskStorage as cO, hasRows as cP, isAdmin as cQ, isHasMany as cR, isSignedIn as cS, isStaff as cT, isSystemAdmin as cU, jsonLogger as cV, memorySearch as cW, mimeAllowedBy as cX, rowFields as cY, silentLogger as cZ, uniqueWithinOf as c_, SingleSignOn as cd, TRIGRAM_LIKE_MIN as ck, TooManyRequestsError as co, UnauthorizedError as cq, ValidationError as cy, API_KEY_GLOBAL_OPERATIONS as d0, API_KEY_OPERATIONS as d1, DEFAULT_MAX_VERSIONS as d2, DEFAULT_PASSWORD_EMAILS as d3, FIELD_TYPE_BASES as d4, FOLDER_LEVELS as d5, MediaFolders as d6, SSO_COOKIE as d7, codeOfStatus as d9, isJsonLogger as da, keyAllows as db, logFormat as dc, secretsOf as dd, ADMIN_ICONS as e };
3774
- export type { AuthUser as $, AfterDeleteHook as B, Config as C, AfterReadHook as D, Field as F, ApiKeyContext as G, ApiKeyGlobalOperation as H, ID as I, ApiKeyOperation as J, ApiKeyPermissions as K, LocalizationConfig as L, ArrayField as M, AuditChange as N, AuditConfig as O, PaginatedDocs as P, AuditEntry as Q, ResolvedConfig as R, AuditPage as T, AuditVerification as U, WebhookPayload as W, AuthConfig as X, AuthProvider as Y, AuthProviderProfile as Z, AuthProviderRequest as _, FieldError as a, FindOptions as a$, BackupsConfig as a0, BeforeChangeHook as a1, BeforeDeleteHook as a2, BeforeValidateHook as a3, Block as a4, BlocksField as a5, BooleanField as a6, BuiltinApiKeysCollection as a7, BuiltinMediaCollection as a8, BuiltinMediaFoldersCollection as a9, DirectUpload as aA, DiskStorageOptions as aB, DocumentOf as aC, EmailAdapter as aE, EmailField as aF, EmailMessage as aG, Endpoint as aH, EndpointRequest as aI, ErrorCode as aJ, FieldAccess as aL, FieldAccessFn as aM, FieldAdmin as aN, FieldRule as aO, FieldType as aP, FieldTypeBase as aQ, FieldTypeDefinition as aR, FieldTypeValidateContext as aS, FieldValidate as aT, FieldValidateContext as aU, FieldValue as aV, FieldsInput as aW, FieldsValue as aX, FilterOptionsArgs as aY, FindAfterArgs as aZ, FindArgs as a_, BuiltinUsersCollection as aa, BundleHints as ab, CliCommand as ac, CollectionAccess as ad, CollectionAdmin as ae, CollectionConfig as af, CollectionDocument as ag, CollectionHooks as ah, CollectionListAdmin as ai, CollectionSearch as aj, CollectionSlug as ak, ConfigIssue as am, ContainerAdmin as an, CreateInput as ao, CreateMigrationResult as ap, CursorDocs as aq, CustomField as ar, CustomFieldTypes as as, DashboardWidget as at, Database as au, DatabaseAdapter as av, DatabaseInitArgs as aw, DatabaseTransfer as ax, DateField as ay, DepthOptions as az, FilterOptions as b, SchemaMode as b$, FolderLevel as b0, FolderPermissions as b1, GlobalAccess as b3, GlobalConfig as b4, GlobalDocument as b5, GlobalHooks as b6, GlobalInput as b7, GlobalSlug as b8, GroupField as b9, OutboxRow as bA, PasswordEmail as bC, PasswordEmailArgs as bD, PasswordEmailFn as bE, PasswordLinkOptions as bF, Plugin as bH, PluginInfo as bI, PluginTypes as bJ, PreviewTarget as bK, PreviewURL as bL, RawDocument as bO, ReadOptions as bP, RelationshipField as bQ, RequestContext as bR, RichTextDocument as bS, RichTextField as bT, Role as bU, RoleOperation as bV, RolePermissions as bW, RoutesConfig as bY, ScheduledPublish as bZ, ImageSize as ba, IncrementOptions as bb, InferCollection as bc, InferGlobal as bd, JobConfig as be, JsonField as bf, KeysetPage as bg, Label as bh, LayoutNode as bi, LivePreview as bj, LocaleOf as bk, LogDetails as bl, Logger as bm, LoginArgs as bn, LogsConfig as bo, MediaDocument as bp, MediaSize as bq, MembersConfig as br, MembersSignup as bs, MigrationInfo as bt, NavGroup as bu, NumberField as bw, OnRequest as bx, OnRequestArgs as by, Operation as bz, CreateEasyCMSOptions as c, SearchAdapter as c0, SearchEntry as c1, SearchHits as c2, SearchOptions as c3, SearchQuery as c4, SearchResults as c5, SearchSetting as c6, SelectField as c7, SelectOption as c8, Session as c9, VersionSummary as cA, VersionsConfig as cB, WebhookConfig as cD, WebhookEvent as cE, Where as cF, WhereOperators as cG, SidebarPanel as ca, SignupArgs as cb, SignupResult as cc, SlugField as ce, SlugOf as cf, SsoOutcome as cg, SsoProviderRef as ch, StorageAdapter as ci, StoredFile as cj, TelemetryConfig as cl, TextField as cm, TextareaField as cn, TypedPlugin as cp, UncountedDocs as cr, UpdateInput as cs, UpdateOptions as ct, UploadConfig as cu, UploadField as cv, UploadFromURLConfig as cw, UserIdentity as cx, Version as cz, EmailSetting as d, Secrets as d8, Access as f, AccessArgs as g, AccessOptions as h, AdminBrand as i, AdminCommand as j, AdminComponent as k, AdminConfig as l, AdminFieldArgs as m, AdminIcon as n, AdminLocale as o, AdminPage as p, AdminRole as q, AdminRoleChange as r, AdminRoleField as s, AdminRoleTarget as t, AdminRoleView as u, AdminRoles as v, AdminSso as w, AdminSwitcher as x, AdminViewAccess as y, AfterChangeHook as z };
3792
+ export { ADAPTER_API_VERSION as A, EasyCMS as E, AuditLog as S, Auth as V, EasyCMSError as aE, FIELD_TYPES as aL, ConfigError as am, SchemaError as b$, ForbiddenError as b3, PLUGIN_API_VERSION as bC, PayloadTooLargeError as bH, QueryError as bN, ROLE_OPERATIONS as bO, Roles as bY, NotFoundError as bw, uniqueWithinOf as c$, WEBHOOK_EVENTS as cD, anyone as cI, consoleEmail as cJ, consoleLogger as cK, createEasyCMS as cL, defineConfig as cM, defineFieldType as cN, definePlugin as cO, diskStorage as cP, hasRows as cQ, isAdmin as cR, isHasMany as cS, isSignedIn as cT, isStaff as cU, isSystemAdmin as cV, jsonLogger as cW, memorySearch as cX, mimeAllowedBy as cY, rowFields as cZ, silentLogger as c_, SingleSignOn as ce, TRIGRAM_LIKE_MIN as cl, TooManyRequestsError as cp, UnauthorizedError as cr, ValidationError as cz, API_KEYS as d0, API_KEY_GLOBAL_OPERATIONS as d1, API_KEY_OPERATIONS as d2, DEFAULT_MAX_VERSIONS as d3, DEFAULT_PASSWORD_EMAILS as d4, FIELD_TYPE_BASES as d5, FOLDER_LEVELS as d6, MediaFolders as d7, SSO_COOKIE as d8, codeOfStatus as da, isJsonLogger as db, keyAllows as dc, logFormat as dd, secretsOf as de, ADMIN_ICONS as e };
3793
+ export type { AuthUser as $, AfterDeleteHook as B, Config as C, AfterReadHook as D, Field as F, ApiKeyContext as G, ApiKeyGlobalOperation as H, ID as I, ApiKeyOperation as J, ApiKeyPermissions as K, LocalizationConfig as L, ArrayField as M, AuditChange as N, AuditConfig as O, PaginatedDocs as P, AuditEntry as Q, ResolvedConfig as R, AuditPage as T, AuditVerification as U, WebhookPayload as W, AuthConfig as X, AuthProvider as Y, AuthProviderProfile as Z, AuthProviderRequest as _, FieldError as a, FindArgs as a$, BackupsConfig as a0, BeforeChangeHook as a1, BeforeDeleteHook as a2, BeforeValidateHook as a3, Block as a4, BlocksField as a5, BooleanField as a6, BuiltinApiKeysCollection as a7, BuiltinMediaCollection as a8, BuiltinMediaFoldersCollection as a9, DepthOptions as aA, DirectUpload as aB, DiskStorageOptions as aC, DocumentOf as aD, EmailAdapter as aF, EmailField as aG, EmailMessage as aH, Endpoint as aI, EndpointRequest as aJ, ErrorCode as aK, FieldAccess as aM, FieldAccessFn as aN, FieldAdmin as aO, FieldRule as aP, FieldType as aQ, FieldTypeBase as aR, FieldTypeDefinition as aS, FieldTypeValidateContext as aT, FieldValidate as aU, FieldValidateContext as aV, FieldValue as aW, FieldsInput as aX, FieldsValue as aY, FilterOptionsArgs as aZ, FindAfterArgs as a_, BuiltinUsersCollection as aa, BundleHints as ab, CliCommand as ac, CollectionAccess as ad, CollectionAdmin as ae, CollectionCalendarAdmin as af, CollectionConfig as ag, CollectionDocument as ah, CollectionHooks as ai, CollectionListAdmin as aj, CollectionSearch as ak, CollectionSlug as al, ConfigIssue as an, ContainerAdmin as ao, CreateInput as ap, CreateMigrationResult as aq, CursorDocs as ar, CustomField as as, CustomFieldTypes as at, DashboardWidget as au, Database as av, DatabaseAdapter as aw, DatabaseInitArgs as ax, DatabaseTransfer as ay, DateField as az, FilterOptions as b, FindOptions as b0, FolderLevel as b1, FolderPermissions as b2, GlobalAccess as b4, GlobalConfig as b5, GlobalDocument as b6, GlobalHooks as b7, GlobalInput as b8, GlobalSlug as b9, Operation as bA, OutboxRow as bB, PasswordEmail as bD, PasswordEmailArgs as bE, PasswordEmailFn as bF, PasswordLinkOptions as bG, Plugin as bI, PluginInfo as bJ, PluginTypes as bK, PreviewTarget as bL, PreviewURL as bM, RawDocument as bP, ReadOptions as bQ, RelationshipField as bR, RequestContext as bS, RichTextDocument as bT, RichTextField as bU, Role as bV, RoleOperation as bW, RolePermissions as bX, RoutesConfig as bZ, ScheduledPublish as b_, GroupField as ba, ImageSize as bb, IncrementOptions as bc, InferCollection as bd, InferGlobal as be, JobConfig as bf, JsonField as bg, KeysetPage as bh, Label as bi, LayoutNode as bj, LivePreview as bk, LocaleOf as bl, LogDetails as bm, Logger as bn, LoginArgs as bo, LogsConfig as bp, MediaDocument as bq, MediaSize as br, MembersConfig as bs, MembersSignup as bt, MigrationInfo as bu, NavGroup as bv, NumberField as bx, OnRequest as by, OnRequestArgs as bz, CreateEasyCMSOptions as c, SchemaMode as c0, SearchAdapter as c1, SearchEntry as c2, SearchHits as c3, SearchOptions as c4, SearchQuery as c5, SearchResults as c6, SearchSetting as c7, SelectField as c8, SelectOption as c9, Version as cA, VersionSummary as cB, VersionsConfig as cC, WebhookConfig as cE, WebhookEvent as cF, Where as cG, WhereOperators as cH, Session as ca, SidebarPanel as cb, SignupArgs as cc, SignupResult as cd, SlugField as cf, SlugOf as cg, SsoOutcome as ch, SsoProviderRef as ci, StorageAdapter as cj, StoredFile as ck, TelemetryConfig as cm, TextField as cn, TextareaField as co, TypedPlugin as cq, UncountedDocs as cs, UpdateInput as ct, UpdateOptions as cu, UploadConfig as cv, UploadField as cw, UploadFromURLConfig as cx, UserIdentity as cy, EmailSetting as d, Secrets as d9, Access as f, AccessArgs as g, AccessOptions as h, AdminBrand as i, AdminCommand as j, AdminComponent as k, AdminConfig as l, AdminFieldArgs as m, AdminIcon as n, AdminLocale as o, AdminPage as p, AdminRole as q, AdminRoleChange as r, AdminRoleField as s, AdminRoleTarget as t, AdminRoleView as u, AdminRoles as v, AdminSso as w, AdminSwitcher as x, AdminViewAccess as y, AfterChangeHook as z };
@@ -1,4 +1,4 @@
1
- import { I as ID, C as Config, E as EasyCMS, L as LocalizationConfig, F as Field, a as FieldError, b as FilterOptions, c as CreateEasyCMSOptions, R as ResolvedConfig } from './config-Daj_EbDR.js';
1
+ import { I as ID, C as Config, E as EasyCMS, L as LocalizationConfig, F as Field, a as FieldError, b as FilterOptions, c as CreateEasyCMSOptions, R as ResolvedConfig } from './config-BQ53ulBF.js';
2
2
 
3
3
  /** Decrypts a file from `encryptBackup`; throws for another key or a changed file. */
4
4
  declare function decryptBackup(data: Uint8Array, encryptionKey: string): Uint8Array;
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
- import { P as PaginatedDocs, I as ID, d as EmailSetting, W as WebhookPayload } from './config-Daj_EbDR.js';
2
- export { A as ADAPTER_API_VERSION, e as ADMIN_ICONS, f as Access, g as AccessArgs, h as AccessOptions, i as AdminBrand, j as AdminCommand, k as AdminComponent, l as AdminConfig, m as AdminFieldArgs, n as AdminIcon, o as AdminLocale, p as AdminPage, q as AdminRole, r as AdminRoleChange, s as AdminRoleField, t as AdminRoleTarget, u as AdminRoleView, v as AdminRoles, w as AdminSso, x as AdminSwitcher, y as AdminViewAccess, z as AfterChangeHook, B as AfterDeleteHook, D as AfterReadHook, G as ApiKeyContext, H as ApiKeyGlobalOperation, J as ApiKeyOperation, K as ApiKeyPermissions, M as ArrayField, N as AuditChange, O as AuditConfig, Q as AuditEntry, S as AuditLog, T as AuditPage, U as AuditVerification, V as Auth, X as AuthConfig, Y as AuthProvider, Z as AuthProviderProfile, _ as AuthProviderRequest, $ as AuthUser, a0 as BackupsConfig, a1 as BeforeChangeHook, a2 as BeforeDeleteHook, a3 as BeforeValidateHook, a4 as Block, a5 as BlocksField, a6 as BooleanField, a7 as BuiltinApiKeysCollection, a8 as BuiltinMediaCollection, a9 as BuiltinMediaFoldersCollection, aa as BuiltinUsersCollection, ab as BundleHints, ac as CliCommand, ad as CollectionAccess, ae as CollectionAdmin, af as CollectionConfig, ag as CollectionDocument, ah as CollectionHooks, ai as CollectionListAdmin, aj as CollectionSearch, ak as CollectionSlug, C as Config, al as ConfigError, am as ConfigIssue, an as ContainerAdmin, c as CreateEasyCMSOptions, ao as CreateInput, ap as CreateMigrationResult, aq as CursorDocs, ar as CustomField, as as CustomFieldTypes, at as DashboardWidget, au as Database, av as DatabaseAdapter, aw as DatabaseInitArgs, ax as DatabaseTransfer, ay as DateField, az as DepthOptions, aA as DirectUpload, aB as DiskStorageOptions, aC as DocumentOf, E as EasyCMS, aD as EasyCMSError, aE as EmailAdapter, aF as EmailField, aG as EmailMessage, aH as Endpoint, aI as EndpointRequest, aJ as ErrorCode, aK as FIELD_TYPES, F as Field, aL as FieldAccess, aM as FieldAccessFn, aN as FieldAdmin, a as FieldError, aO as FieldRule, aP as FieldType, aQ as FieldTypeBase, aR as FieldTypeDefinition, aS as FieldTypeValidateContext, aT as FieldValidate, aU as FieldValidateContext, aV as FieldValue, aW as FieldsInput, aX as FieldsValue, b as FilterOptions, aY as FilterOptionsArgs, aZ as FindAfterArgs, a_ as FindArgs, a$ as FindOptions, b0 as FolderLevel, b1 as FolderPermissions, b2 as ForbiddenError, b3 as GlobalAccess, b4 as GlobalConfig, b5 as GlobalDocument, b6 as GlobalHooks, b7 as GlobalInput, b8 as GlobalSlug, b9 as GroupField, ba as ImageSize, bb as IncrementOptions, bc as InferCollection, bd as InferGlobal, be as JobConfig, bf as JsonField, bg as KeysetPage, bh as Label, bi as LayoutNode, bj as LivePreview, bk as LocaleOf, L as LocalizationConfig, bl as LogDetails, bm as Logger, bn as LoginArgs, bo as LogsConfig, bp as MediaDocument, bq as MediaSize, br as MembersConfig, bs as MembersSignup, bt as MigrationInfo, bu as NavGroup, bv as NotFoundError, bw as NumberField, bx as OnRequest, by as OnRequestArgs, bz as Operation, bA as OutboxRow, bB as PLUGIN_API_VERSION, bC as PasswordEmail, bD as PasswordEmailArgs, bE as PasswordEmailFn, bF as PasswordLinkOptions, bG as PayloadTooLargeError, bH as Plugin, bI as PluginInfo, bJ as PluginTypes, bK as PreviewTarget, bL as PreviewURL, bM as QueryError, bN as ROLE_OPERATIONS, bO as RawDocument, bP as ReadOptions, bQ as RelationshipField, bR as RequestContext, R as ResolvedConfig, bS as RichTextDocument, bT as RichTextField, bU as Role, bV as RoleOperation, bW as RolePermissions, bX as Roles, bY as RoutesConfig, bZ as ScheduledPublish, b_ as SchemaError, b$ as SchemaMode, c0 as SearchAdapter, c1 as SearchEntry, c2 as SearchHits, c3 as SearchOptions, c4 as SearchQuery, c5 as SearchResults, c6 as SearchSetting, c7 as SelectField, c8 as SelectOption, c9 as Session, ca as SidebarPanel, cb as SignupArgs, cc as SignupResult, cd as SingleSignOn, ce as SlugField, cf as SlugOf, cg as SsoOutcome, ch as SsoProviderRef, ci as StorageAdapter, cj as StoredFile, ck as TRIGRAM_LIKE_MIN, cl as TelemetryConfig, cm as TextField, cn as TextareaField, co as TooManyRequestsError, cp as TypedPlugin, cq as UnauthorizedError, cr as UncountedDocs, cs as UpdateInput, ct as UpdateOptions, cu as UploadConfig, cv as UploadField, cw as UploadFromURLConfig, cx as UserIdentity, cy as ValidationError, cz as Version, cA as VersionSummary, cB as VersionsConfig, cC as WEBHOOK_EVENTS, cD as WebhookConfig, cE as WebhookEvent, cF as Where, cG as WhereOperators, cH as anyone, cI as consoleEmail, cJ as consoleLogger, cK as createEasyCMS, cL as defineConfig, cM as defineFieldType, cN as definePlugin, cO as diskStorage, cP as hasRows, cQ as isAdmin, cR as isHasMany, cS as isSignedIn, cT as isStaff, cU as isSystemAdmin, cV as jsonLogger, cW as memorySearch, cX as mimeAllowedBy, cY as rowFields, cZ as silentLogger, c_ as uniqueWithinOf } from './config-Daj_EbDR.js';
3
- export { A as ADMIN_API_VERSION, a as AdminCollection, b as AdminComponentRef, c as AdminElementProps, d as AdminField, e as AdminGlobal, f as AdminLayoutNode, g as AdminNavGroup, h as AdminNavItem, i as AdminNavNode, j as AdminPageRef, k as AdminPageRoute, l as AdminSchema, m as AdminWidgetRef, S as SetFieldDetail, w as warnDeprecated } from './plugin-DRe5S9Wi.js';
4
- export { A as AdminBackup, a as AdminBackups, b as ApiHandlerOptions, B as BackupState, L as LoadConfigOptions, R as RestHandler, c as RestHandlerOptions, d as createApiHandler, e as createRestHandler, l as loadConfig, r as resolveConfig, s as sharedEasyCMS, f as slugify } from './handler-5PPSC9o4.js';
1
+ import { P as PaginatedDocs, I as ID, d as EmailSetting, W as WebhookPayload } from './config-BQ53ulBF.js';
2
+ export { A as ADAPTER_API_VERSION, e as ADMIN_ICONS, f as Access, g as AccessArgs, h as AccessOptions, i as AdminBrand, j as AdminCommand, k as AdminComponent, l as AdminConfig, m as AdminFieldArgs, n as AdminIcon, o as AdminLocale, p as AdminPage, q as AdminRole, r as AdminRoleChange, s as AdminRoleField, t as AdminRoleTarget, u as AdminRoleView, v as AdminRoles, w as AdminSso, x as AdminSwitcher, y as AdminViewAccess, z as AfterChangeHook, B as AfterDeleteHook, D as AfterReadHook, G as ApiKeyContext, H as ApiKeyGlobalOperation, J as ApiKeyOperation, K as ApiKeyPermissions, M as ArrayField, N as AuditChange, O as AuditConfig, Q as AuditEntry, S as AuditLog, T as AuditPage, U as AuditVerification, V as Auth, X as AuthConfig, Y as AuthProvider, Z as AuthProviderProfile, _ as AuthProviderRequest, $ as AuthUser, a0 as BackupsConfig, a1 as BeforeChangeHook, a2 as BeforeDeleteHook, a3 as BeforeValidateHook, a4 as Block, a5 as BlocksField, a6 as BooleanField, a7 as BuiltinApiKeysCollection, a8 as BuiltinMediaCollection, a9 as BuiltinMediaFoldersCollection, aa as BuiltinUsersCollection, ab as BundleHints, ac as CliCommand, ad as CollectionAccess, ae as CollectionAdmin, af as CollectionCalendarAdmin, ag as CollectionConfig, ah as CollectionDocument, ai as CollectionHooks, aj as CollectionListAdmin, ak as CollectionSearch, al as CollectionSlug, C as Config, am as ConfigError, an as ConfigIssue, ao as ContainerAdmin, c as CreateEasyCMSOptions, ap as CreateInput, aq as CreateMigrationResult, ar as CursorDocs, as as CustomField, at as CustomFieldTypes, au as DashboardWidget, av as Database, aw as DatabaseAdapter, ax as DatabaseInitArgs, ay as DatabaseTransfer, az as DateField, aA as DepthOptions, aB as DirectUpload, aC as DiskStorageOptions, aD as DocumentOf, E as EasyCMS, aE as EasyCMSError, aF as EmailAdapter, aG as EmailField, aH as EmailMessage, aI as Endpoint, aJ as EndpointRequest, aK as ErrorCode, aL as FIELD_TYPES, F as Field, aM as FieldAccess, aN as FieldAccessFn, aO as FieldAdmin, a as FieldError, aP as FieldRule, aQ as FieldType, aR as FieldTypeBase, aS as FieldTypeDefinition, aT as FieldTypeValidateContext, aU as FieldValidate, aV as FieldValidateContext, aW as FieldValue, aX as FieldsInput, aY as FieldsValue, b as FilterOptions, aZ as FilterOptionsArgs, a_ as FindAfterArgs, a$ as FindArgs, b0 as FindOptions, b1 as FolderLevel, b2 as FolderPermissions, b3 as ForbiddenError, b4 as GlobalAccess, b5 as GlobalConfig, b6 as GlobalDocument, b7 as GlobalHooks, b8 as GlobalInput, b9 as GlobalSlug, ba as GroupField, bb as ImageSize, bc as IncrementOptions, bd as InferCollection, be as InferGlobal, bf as JobConfig, bg as JsonField, bh as KeysetPage, bi as Label, bj as LayoutNode, bk as LivePreview, bl as LocaleOf, L as LocalizationConfig, bm as LogDetails, bn as Logger, bo as LoginArgs, bp as LogsConfig, bq as MediaDocument, br as MediaSize, bs as MembersConfig, bt as MembersSignup, bu as MigrationInfo, bv as NavGroup, bw as NotFoundError, bx as NumberField, by as OnRequest, bz as OnRequestArgs, bA as Operation, bB as OutboxRow, bC as PLUGIN_API_VERSION, bD as PasswordEmail, bE as PasswordEmailArgs, bF as PasswordEmailFn, bG as PasswordLinkOptions, bH as PayloadTooLargeError, bI as Plugin, bJ as PluginInfo, bK as PluginTypes, bL as PreviewTarget, bM as PreviewURL, bN as QueryError, bO as ROLE_OPERATIONS, bP as RawDocument, bQ as ReadOptions, bR as RelationshipField, bS as RequestContext, R as ResolvedConfig, bT as RichTextDocument, bU as RichTextField, bV as Role, bW as RoleOperation, bX as RolePermissions, bY as Roles, bZ as RoutesConfig, b_ as ScheduledPublish, b$ as SchemaError, c0 as SchemaMode, c1 as SearchAdapter, c2 as SearchEntry, c3 as SearchHits, c4 as SearchOptions, c5 as SearchQuery, c6 as SearchResults, c7 as SearchSetting, c8 as SelectField, c9 as SelectOption, ca as Session, cb as SidebarPanel, cc as SignupArgs, cd as SignupResult, ce as SingleSignOn, cf as SlugField, cg as SlugOf, ch as SsoOutcome, ci as SsoProviderRef, cj as StorageAdapter, ck as StoredFile, cl as TRIGRAM_LIKE_MIN, cm as TelemetryConfig, cn as TextField, co as TextareaField, cp as TooManyRequestsError, cq as TypedPlugin, cr as UnauthorizedError, cs as UncountedDocs, ct as UpdateInput, cu as UpdateOptions, cv as UploadConfig, cw as UploadField, cx as UploadFromURLConfig, cy as UserIdentity, cz as ValidationError, cA as Version, cB as VersionSummary, cC as VersionsConfig, cD as WEBHOOK_EVENTS, cE as WebhookConfig, cF as WebhookEvent, cG as Where, cH as WhereOperators, cI as anyone, cJ as consoleEmail, cK as consoleLogger, cL as createEasyCMS, cM as defineConfig, cN as defineFieldType, cO as definePlugin, cP as diskStorage, cQ as hasRows, cR as isAdmin, cS as isHasMany, cT as isSignedIn, cU as isStaff, cV as isSystemAdmin, cW as jsonLogger, cX as memorySearch, cY as mimeAllowedBy, cZ as rowFields, c_ as silentLogger, c$ as uniqueWithinOf } from './config-BQ53ulBF.js';
3
+ export { A as ADMIN_API_VERSION, a as AdminCollection, b as AdminComponentRef, c as AdminElementProps, d as AdminField, e as AdminGlobal, f as AdminLayoutNode, g as AdminNavGroup, h as AdminNavItem, i as AdminNavNode, j as AdminPageRef, k as AdminPageRoute, l as AdminSchema, m as AdminWidgetRef, S as SetFieldDetail, w as warnDeprecated } from './plugin-I5C-9kXl.js';
4
+ export { A as AdminBackup, a as AdminBackups, b as ApiHandlerOptions, B as BackupState, L as LoadConfigOptions, R as RestHandler, c as RestHandlerOptions, d as createApiHandler, e as createRestHandler, l as loadConfig, r as resolveConfig, s as sharedEasyCMS, f as slugify } from './handler-B4GC_p5n.js';
5
5
  export { FieldCondition, matchesCondition } from './conditions.js';
6
6
 
7
7
  type DeliveryKind = 'webhook' | 'email';
package/dist/index.js CHANGED
@@ -28,7 +28,7 @@ import {
28
28
  silentLogger,
29
29
  slugify,
30
30
  verifyWebhook
31
- } from "./chunk-S7Q2NGAL.js";
31
+ } from "./chunk-7S2HXNF5.js";
32
32
  import {
33
33
  matchesCondition
34
34
  } from "./chunk-U266LV4M.js";
@@ -1,6 +1,6 @@
1
1
  import { Config, Database, EasyCMS, NavGroup, CollectionConfig, ID, RawDocument, Field, ResolvedConfig, ConfigIssue } from './index.js';
2
- export { c$ as API_KEYS, d0 as API_KEY_GLOBAL_OPERATIONS, d1 as API_KEY_OPERATIONS, d2 as DEFAULT_MAX_VERSIONS, d3 as DEFAULT_PASSWORD_EMAILS, d4 as FIELD_TYPE_BASES, d5 as FOLDER_LEVELS, d6 as MediaFolders, d7 as SSO_COOKIE, d8 as Secrets, ck as TRIGRAM_LIKE_MIN, d9 as codeOfStatus, cP as hasRows, cR as isHasMany, da as isJsonLogger, db as keyAllows, dc as logFormat, cX as mimeAllowedBy, cY as rowFields, dd as secretsOf, c_ as uniqueWithinOf } from './config-Daj_EbDR.js';
3
- export { C as CONFIG_FILE_NAMES, g as CSRF_COOKIE, h as CSRF_HEADER, D as DEFAULT_ADMIN_PATH, i as DEFAULT_API_PATH, j as DEFAULT_MAX_FILE_SIZE, k as DEFAULT_TOKEN_EXPIRATION, m as applyDefaults, n as applyPlugins, o as createRootEndpointHandler, p as decryptBackup, q as fillMissing, t as findConfigFile, u as forwardedClientIp, v as generateSlugs, w as importConfig, x as isEmail, y as mergeForUpdate, z as parseId, E as platformClientIp, F as readCookie, G as validateFields, H as writeBackupFile } from './handler-5PPSC9o4.js';
2
+ export { d0 as API_KEYS, d1 as API_KEY_GLOBAL_OPERATIONS, d2 as API_KEY_OPERATIONS, d3 as DEFAULT_MAX_VERSIONS, d4 as DEFAULT_PASSWORD_EMAILS, d5 as FIELD_TYPE_BASES, d6 as FOLDER_LEVELS, d7 as MediaFolders, d8 as SSO_COOKIE, d9 as Secrets, cl as TRIGRAM_LIKE_MIN, da as codeOfStatus, cQ as hasRows, cS as isHasMany, db as isJsonLogger, dc as keyAllows, dd as logFormat, cY as mimeAllowedBy, cZ as rowFields, de as secretsOf, c$ as uniqueWithinOf } from './config-BQ53ulBF.js';
3
+ export { C as CONFIG_FILE_NAMES, g as CSRF_COOKIE, h as CSRF_HEADER, D as DEFAULT_ADMIN_PATH, i as DEFAULT_API_PATH, j as DEFAULT_MAX_FILE_SIZE, k as DEFAULT_TOKEN_EXPIRATION, m as applyDefaults, n as applyPlugins, o as createRootEndpointHandler, p as decryptBackup, q as fillMissing, t as findConfigFile, u as forwardedClientIp, v as generateSlugs, w as importConfig, x as isEmail, y as mergeForUpdate, z as parseId, E as platformClientIp, F as readCookie, G as validateFields, H as writeBackupFile } from './handler-B4GC_p5n.js';
4
4
  export { conditionIssues } from './conditions.js';
5
5
 
6
6
  /** The session cookie the REST API sets at login. */
package/dist/internal.js CHANGED
@@ -58,7 +58,7 @@ import {
58
58
  verifyPassword,
59
59
  verifyTurnstile,
60
60
  writeBackupFile
61
- } from "./chunk-S7Q2NGAL.js";
61
+ } from "./chunk-7S2HXNF5.js";
62
62
  import {
63
63
  conditionIssues
64
64
  } from "./chunk-U266LV4M.js";
@@ -1,4 +1,4 @@
1
- import { bh as Label, F as Field, I as ID, o as AdminLocale, x as AdminSwitcher, ch as SsoProviderRef } from './config-Daj_EbDR.js';
1
+ import { bi as Label, F as Field, I as ID, o as AdminLocale, x as AdminSwitcher, ci as SsoProviderRef } from './config-BQ53ulBF.js';
2
2
  import { FieldCondition } from './conditions.js';
3
3
 
4
4
  /** A Web Component from an admin module, with its `props` (plain JSON). */
@@ -39,7 +39,7 @@ type AdminNavItem = {
39
39
  path: string;
40
40
  } | {
41
41
  kind: 'view';
42
- view: 'roles' | 'sso' | 'backups' | 'email' | 'deliveries' | 'jobs' | 'audit';
42
+ view: 'roles' | 'sso' | 'backups' | 'email' | 'deliveries' | 'jobs' | 'audit' | 'calendar';
43
43
  };
44
44
  /** A group of the admin menu (`admin.nav`), with what this user may open in it. */
45
45
  interface AdminNavGroup {
@@ -159,6 +159,12 @@ interface AdminCollection {
159
159
  tree?: string;
160
160
  /** The list's default order (`admin.list.sort`). */
161
161
  defaultSort?: string;
162
+ /** The list's Calendar mode (`admin.calendar`): the fields placing and colouring documents. */
163
+ calendar?: {
164
+ start: string;
165
+ end?: string;
166
+ color?: string;
167
+ };
162
168
  permissions: {
163
169
  read: boolean;
164
170
  create: boolean;
@@ -270,6 +276,8 @@ interface AdminSchema {
270
276
  roles: boolean;
271
277
  sso: boolean;
272
278
  audit: boolean;
279
+ /** The Calendar page (#272): documents with `admin.calendar` and scheduled publishing. */
280
+ calendar: boolean;
273
281
  };
274
282
  /** Roles from the admin are on (`auth.rbac`): documents have owners. */
275
283
  rbac: boolean;
package/dist/plugin.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- export { e as ADMIN_ICONS, k as AdminComponent, n as AdminIcon, $ as AuthUser, ac as CliCommand, ad as CollectionAccess, af as CollectionConfig, C as Config, al as ConfigError, at as DashboardWidget, aD as EasyCMSError, aH as Endpoint, aI as EndpointRequest, aJ as ErrorCode, F as Field, aL as FieldAccess, a as FieldError, aQ as FieldTypeBase, aR as FieldTypeDefinition, aS as FieldTypeValidateContext, b2 as ForbiddenError, b4 as GlobalConfig, I as ID, be as JobConfig, bh as Label, bu as NavGroup, bv as NotFoundError, bx as OnRequest, by as OnRequestArgs, bB as PLUGIN_API_VERSION, bG as PayloadTooLargeError, bH as Plugin, bI as PluginInfo, bJ as PluginTypes, bM as QueryError, bR as RequestContext, co as TooManyRequestsError, cp as TypedPlugin, cq as UnauthorizedError, cy as ValidationError, cF as Where, cM as defineFieldType, cN as definePlugin } from './config-Daj_EbDR.js';
2
- export { A as ADMIN_API_VERSION, c as AdminElementProps, k as AdminPageRoute, S as SetFieldDetail, w as warnDeprecated } from './plugin-DRe5S9Wi.js';
1
+ export { e as ADMIN_ICONS, k as AdminComponent, n as AdminIcon, $ as AuthUser, ac as CliCommand, ad as CollectionAccess, ag as CollectionConfig, C as Config, am as ConfigError, au as DashboardWidget, aE as EasyCMSError, aI as Endpoint, aJ as EndpointRequest, aK as ErrorCode, F as Field, aM as FieldAccess, a as FieldError, aR as FieldTypeBase, aS as FieldTypeDefinition, aT as FieldTypeValidateContext, b3 as ForbiddenError, b5 as GlobalConfig, I as ID, bf as JobConfig, bi as Label, bv as NavGroup, bw as NotFoundError, by as OnRequest, bz as OnRequestArgs, bC as PLUGIN_API_VERSION, bH as PayloadTooLargeError, bI as Plugin, bJ as PluginInfo, bK as PluginTypes, bN as QueryError, bS as RequestContext, cp as TooManyRequestsError, cq as TypedPlugin, cr as UnauthorizedError, cz as ValidationError, cG as Where, cN as defineFieldType, cO as definePlugin } from './config-BQ53ulBF.js';
2
+ export { A as ADMIN_API_VERSION, c as AdminElementProps, k as AdminPageRoute, S as SetFieldDetail, w as warnDeprecated } from './plugin-I5C-9kXl.js';
3
3
  import './conditions.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easy-cms/core",
3
- "version": "1.21.0",
3
+ "version": "1.23.0",
4
4
  "description": "Embedded, code-first headless CMS for Nuxt and Next.js",
5
5
  "license": "MIT",
6
6
  "type": "module",