@valbuild/core 0.145.0 → 0.146.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @valbuild/core
2
2
 
3
+ ## 0.146.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [#871](https://github.com/valbuild/val/pull/871) [`e4913e1`](https://github.com/valbuild/val/commit/e4913e1f1178e09987a7c03fd540909ab4b499b0) Thanks [@freekh](https://github.com/freekh)! - An image, file or video picked from a gallery is checked against the gallery as it is now. Picking one uploaded since the site was built (still unpublished, saved in a proposal, or published without a rebuild) used to fail with "The gallery does not have an image at …" and refuse the save. In a proposal, Save now reads "Fix N" and goes to the validation errors instead of being refused by the server, as Publish does on the site.
8
+
3
9
  ## 0.145.0
4
10
 
5
11
  ### Minor Changes
@@ -51,7 +51,7 @@ import { getValidationBasis, getValidationHash } from "./remote/validationBasis.
51
51
  import { getFileHash, hashToRemoteFileHash } from "./remote/fileHash.js";
52
52
  import { splitRemoteRef } from "./remote/splitRemoteRef.js";
53
53
  import { galleriesOf } from "./source/galleries.js";
54
- import { fillFromGallery, galleryEntryOf, galleryKeyOf, isHlsVideo, isRemoteMediaPath, mediaUrl, resolveMedia, resolveVideo } from "./source/media.js";
54
+ import { fillFromGallery, galleryEntryOf, galleryKeyOf, galleryMarkerOf, isHlsVideo, isRemoteMediaPath, mediaUrl, resolveMedia, resolveVideo } from "./source/media.js";
55
55
  import { colorToHex, convertColor, detectColorFormat, formatColor, parseColor } from "./schema/colorFormat.js";
56
56
  export { type SerializedArraySchema, ArraySchema } from "./schema/array.js";
57
57
  export { type SerializedObjectSchema, ObjectSchema } from "./schema/object.js";
@@ -155,6 +155,7 @@ declare const Internal: {
155
155
  galleriesOf: typeof galleriesOf;
156
156
  galleryEntryOf: typeof galleryEntryOf;
157
157
  galleryKeyOf: typeof galleryKeyOf;
158
+ galleryMarkerOf: typeof galleryMarkerOf;
158
159
  GALLERY_DEFAULT_GROUPS: readonly (readonly string[])[];
159
160
  isHlsVideo: typeof isHlsVideo;
160
161
  HLS_MIME_TYPE: string;
@@ -167,6 +167,8 @@ export declare class ImageSchema<Src extends ImageSource | null> extends Schema<
167
167
  * alt — it carries its own — so it only needs the entry keys and the
168
168
  * dimensions, and a gallery of any alt shape can back it.
169
169
  */
170
+ /** The module path of the gallery this field points at. */
171
+ private galleryModulePath;
170
172
  private galleryEntries;
171
173
  protected executeAssert(path: SourcePath, src: unknown): SchemaAssertResult<Src>;
172
174
  nullable(): ImageSchema<Src | null>;
@@ -1,2 +1,2 @@
1
- export declare const ValidationFix: readonly ["image:add-metadata", "image:check-metadata", "image:upload-remote", "image:download-remote", "image:check-remote", "images:check-remote", "images:upload-remote", "file:add-metadata", "file:check-metadata", "file:upload-remote", "file:download-remote", "file:check-remote", "files:check-remote", "files:upload-remote", "video:add-metadata", "video:upload-remote", "video:download-remote", "videos:add-metadata", "videos:check-remote", "videos:upload-remote", "keyof:check-keys", "router:check-route", "locale:check-locale", "images:check-unique-folder", "files:check-unique-folder", "images:check-all-files", "files:check-all-files", "videos:check-unique-folder", "videos:check-all-files", "jsonValues:extract-entry", "record:fill-keys", "external:upload", "view:check-module"];
1
+ export declare const ValidationFix: readonly ["image:add-metadata", "image:check-metadata", "image:upload-remote", "image:download-remote", "image:check-remote", "images:check-remote", "images:upload-remote", "file:add-metadata", "file:check-metadata", "file:upload-remote", "file:download-remote", "file:check-remote", "files:check-remote", "files:upload-remote", "video:add-metadata", "video:upload-remote", "video:download-remote", "videos:add-metadata", "videos:check-remote", "videos:upload-remote", "keyof:check-keys", "image:check-gallery", "file:check-gallery", "video:check-gallery", "router:check-route", "locale:check-locale", "images:check-unique-folder", "files:check-unique-folder", "images:check-all-files", "files:check-all-files", "videos:check-unique-folder", "videos:check-all-files", "jsonValues:extract-entry", "record:fill-keys", "external:upload", "view:check-module"];
2
2
  export type ValidationFix = (typeof ValidationFix)[number];
@@ -10,6 +10,7 @@
10
10
  * a field can move between local and remote without a type error. Remote-ness
11
11
  * is read off the path: anything not under `/public` is remote.
12
12
  */
13
+ import type { ValidationError } from "../schema/validation/ValidationError.js";
13
14
  /** What must stay in frame when a page crops an image. */
14
15
  export type MediaHotspot = {
15
16
  x: number;
@@ -232,6 +233,27 @@ export declare function resolveVideo<S extends GalleryVideoSource>(src: S, video
232
233
  * without (how `splitRemoteRef` returns it).
233
234
  */
234
235
  export declare function galleryKeyOf(path: string, isKey: (key: string) => boolean): string | null;
236
+ /**
237
+ * A gallery-backed field whose path the gallery, as the schema holds it, does
238
+ * not have: the `image:check-gallery` (`file:`, `video:`) marker.
239
+ *
240
+ * The schema holds the gallery as it was EVALUATED -- in a built site, the
241
+ * gallery as it was built. An entry added since (a pending change, a save in
242
+ * a proposal, a content-only publish that never rebuilt the site) is only in
243
+ * the gallery's current Source, so whether the field is wrong is a question
244
+ * for a project-wide snapshot (`resolveSchemaSourceFixes`), as a keyOf's key
245
+ * is. The message is the answer when the gallery does not have it either, so
246
+ * a consumer that does not resolve markers reports what it always did.
247
+ */
248
+ export declare function galleryMarker(media: "image" | "file" | "video", source: {
249
+ path: string;
250
+ }, galleryModulePath: string): ValidationError;
251
+ /** A {@link galleryMarker}'s fields, or `null` for any other error. */
252
+ export declare function galleryMarkerOf(error: ValidationError): {
253
+ path: string;
254
+ gallery: string;
255
+ source: unknown;
256
+ } | null;
235
257
  /**
236
258
  * What a gallery entry holds as a DEFAULT for the fields picked from it, in
237
259
  * the groups a field overrides together.
@@ -3036,6 +3036,50 @@ function galleryKeyOf(path, isKey) {
3036
3036
  return null;
3037
3037
  }
3038
3038
 
3039
+ /**
3040
+ * A gallery-backed field whose path the gallery, as the schema holds it, does
3041
+ * not have: the `image:check-gallery` (`file:`, `video:`) marker.
3042
+ *
3043
+ * The schema holds the gallery as it was EVALUATED -- in a built site, the
3044
+ * gallery as it was built. An entry added since (a pending change, a save in
3045
+ * a proposal, a content-only publish that never rebuilt the site) is only in
3046
+ * the gallery's current Source, so whether the field is wrong is a question
3047
+ * for a project-wide snapshot (`resolveSchemaSourceFixes`), as a keyOf's key
3048
+ * is. The message is the answer when the gallery does not have it either, so
3049
+ * a consumer that does not resolve markers reports what it always did.
3050
+ */
3051
+ function galleryMarker(media, source, galleryModulePath) {
3052
+ var what = media === "image" ? "The gallery does not have an image" : media === "file" ? "The gallery does not have a file" : "The set does not have a video";
3053
+ return {
3054
+ message: "".concat(what, " at '").concat(source.path, "'."),
3055
+ value: {
3056
+ path: source.path,
3057
+ gallery: galleryModulePath,
3058
+ source: source
3059
+ },
3060
+ fixes: ["".concat(media, ":check-gallery")]
3061
+ };
3062
+ }
3063
+
3064
+ /** A {@link galleryMarker}'s fields, or `null` for any other error. */
3065
+ function galleryMarkerOf(error) {
3066
+ var _error$fixes;
3067
+ var fixes = (_error$fixes = error.fixes) !== null && _error$fixes !== void 0 ? _error$fixes : [];
3068
+ if (!fixes.includes("image:check-gallery") && !fixes.includes("file:check-gallery") && !fixes.includes("video:check-gallery")) {
3069
+ return null;
3070
+ }
3071
+ var value = error.value;
3072
+ if (_typeof(value) !== "object" || value === null) return null;
3073
+ var path = "path" in value ? value.path : undefined;
3074
+ var gallery = "gallery" in value ? value.gallery : undefined;
3075
+ if (typeof path !== "string" || typeof gallery !== "string") return null;
3076
+ return {
3077
+ path: path,
3078
+ gallery: gallery,
3079
+ source: "source" in value ? value.source : undefined
3080
+ };
3081
+ }
3082
+
3039
3083
  /**
3040
3084
  * What a gallery entry holds as a DEFAULT for the fields picked from it, in
3041
3085
  * the groups a field overrides together.
@@ -4228,10 +4272,7 @@ var ImageSchema = /*#__PURE__*/function (_Schema) {
4228
4272
  if (galleryKeyOf(src.path, function (key) {
4229
4273
  return key in galleryEntries;
4230
4274
  }) === null) {
4231
- return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [{
4232
- message: "The gallery does not have an image at '".concat(src.path, "'."),
4233
- value: src
4234
- }]));
4275
+ return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [galleryMarker("image", src, this.galleryModulePath())]));
4235
4276
  }
4236
4277
  return customValidationErrors.length > 0 ? _defineProperty({}, path, customValidationErrors) : false;
4237
4278
  }
@@ -4295,6 +4336,13 @@ var ImageSchema = /*#__PURE__*/function (_Schema) {
4295
4336
  * alt — it carries its own — so it only needs the entry keys and the
4296
4337
  * dimensions, and a gallery of any alt shape can back it.
4297
4338
  */
4339
+ /** The module path of the gallery this field points at. */
4340
+ }, {
4341
+ key: "galleryModulePath",
4342
+ value: function galleryModulePath() {
4343
+ var _Object$keys$;
4344
+ return (_Object$keys$ = Object.keys(this.moduleMetadata)[0]) !== null && _Object$keys$ !== void 0 ? _Object$keys$ : "";
4345
+ }
4298
4346
  }, {
4299
4347
  key: "galleryEntries",
4300
4348
  value: function galleryEntries() {
@@ -11227,10 +11275,8 @@ var FileSchema = /*#__PURE__*/function (_Schema) {
11227
11275
  if (galleryKeyOf(src.path, function (key) {
11228
11276
  return key in galleryEntries;
11229
11277
  }) === null) {
11230
- return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [{
11231
- message: "The gallery does not have a file at '".concat(src.path, "'."),
11232
- value: src
11233
- }]));
11278
+ var _Object$keys$;
11279
+ return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [galleryMarker("file", src, (_Object$keys$ = Object.keys(this.moduleMetadata)[0]) !== null && _Object$keys$ !== void 0 ? _Object$keys$ : "")]));
11234
11280
  }
11235
11281
  return customValidationErrors.length > 0 ? _defineProperty({}, path, customValidationErrors) : false;
11236
11282
  }
@@ -11686,10 +11732,7 @@ var VideoSchema = /*#__PURE__*/function (_Schema) {
11686
11732
  }
11687
11733
  var entry = gallery.entries === null ? null : gallery.entries[src.path];
11688
11734
  if (entry === undefined) {
11689
- return [{
11690
- message: "The set does not have a video at '".concat(src.path, "'."),
11691
- value: src
11692
- }];
11735
+ return [galleryMarker("video", src, gallery.modulePath)];
11693
11736
  }
11694
11737
  // The poster and the captions are the field's own files, and live where
11695
11738
  // the set keeps its videos. The video itself is the set's to move.
@@ -16132,7 +16175,7 @@ function isPageRouter(routerId) {
16132
16175
 
16133
16176
  var corePackageJson = {
16134
16177
  name: "@valbuild/core",
16135
- version: "0.145.0",
16178
+ version: "0.146.2",
16136
16179
  "private": false,
16137
16180
  description: "Val - supercharged hard-coded content",
16138
16181
  repository: {
@@ -16239,6 +16282,7 @@ var Internal = {
16239
16282
  galleriesOf: galleriesOf,
16240
16283
  galleryEntryOf: galleryEntryOf,
16241
16284
  galleryKeyOf: galleryKeyOf,
16285
+ galleryMarkerOf: galleryMarkerOf,
16242
16286
  GALLERY_DEFAULT_GROUPS: GALLERY_DEFAULT_GROUPS,
16243
16287
  isHlsVideo: isHlsVideo,
16244
16288
  HLS_MIME_TYPE: HLS_MIME_TYPE
@@ -3034,6 +3034,50 @@ function galleryKeyOf(path, isKey) {
3034
3034
  return null;
3035
3035
  }
3036
3036
 
3037
+ /**
3038
+ * A gallery-backed field whose path the gallery, as the schema holds it, does
3039
+ * not have: the `image:check-gallery` (`file:`, `video:`) marker.
3040
+ *
3041
+ * The schema holds the gallery as it was EVALUATED -- in a built site, the
3042
+ * gallery as it was built. An entry added since (a pending change, a save in
3043
+ * a proposal, a content-only publish that never rebuilt the site) is only in
3044
+ * the gallery's current Source, so whether the field is wrong is a question
3045
+ * for a project-wide snapshot (`resolveSchemaSourceFixes`), as a keyOf's key
3046
+ * is. The message is the answer when the gallery does not have it either, so
3047
+ * a consumer that does not resolve markers reports what it always did.
3048
+ */
3049
+ function galleryMarker(media, source, galleryModulePath) {
3050
+ var what = media === "image" ? "The gallery does not have an image" : media === "file" ? "The gallery does not have a file" : "The set does not have a video";
3051
+ return {
3052
+ message: "".concat(what, " at '").concat(source.path, "'."),
3053
+ value: {
3054
+ path: source.path,
3055
+ gallery: galleryModulePath,
3056
+ source: source
3057
+ },
3058
+ fixes: ["".concat(media, ":check-gallery")]
3059
+ };
3060
+ }
3061
+
3062
+ /** A {@link galleryMarker}'s fields, or `null` for any other error. */
3063
+ function galleryMarkerOf(error) {
3064
+ var _error$fixes;
3065
+ var fixes = (_error$fixes = error.fixes) !== null && _error$fixes !== void 0 ? _error$fixes : [];
3066
+ if (!fixes.includes("image:check-gallery") && !fixes.includes("file:check-gallery") && !fixes.includes("video:check-gallery")) {
3067
+ return null;
3068
+ }
3069
+ var value = error.value;
3070
+ if (_typeof(value) !== "object" || value === null) return null;
3071
+ var path = "path" in value ? value.path : undefined;
3072
+ var gallery = "gallery" in value ? value.gallery : undefined;
3073
+ if (typeof path !== "string" || typeof gallery !== "string") return null;
3074
+ return {
3075
+ path: path,
3076
+ gallery: gallery,
3077
+ source: "source" in value ? value.source : undefined
3078
+ };
3079
+ }
3080
+
3037
3081
  /**
3038
3082
  * What a gallery entry holds as a DEFAULT for the fields picked from it, in
3039
3083
  * the groups a field overrides together.
@@ -4226,10 +4270,7 @@ var ImageSchema = /*#__PURE__*/function (_Schema) {
4226
4270
  if (galleryKeyOf(src.path, function (key) {
4227
4271
  return key in galleryEntries;
4228
4272
  }) === null) {
4229
- return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [{
4230
- message: "The gallery does not have an image at '".concat(src.path, "'."),
4231
- value: src
4232
- }]));
4273
+ return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [galleryMarker("image", src, this.galleryModulePath())]));
4233
4274
  }
4234
4275
  return customValidationErrors.length > 0 ? _defineProperty({}, path, customValidationErrors) : false;
4235
4276
  }
@@ -4293,6 +4334,13 @@ var ImageSchema = /*#__PURE__*/function (_Schema) {
4293
4334
  * alt — it carries its own — so it only needs the entry keys and the
4294
4335
  * dimensions, and a gallery of any alt shape can back it.
4295
4336
  */
4337
+ /** The module path of the gallery this field points at. */
4338
+ }, {
4339
+ key: "galleryModulePath",
4340
+ value: function galleryModulePath() {
4341
+ var _Object$keys$;
4342
+ return (_Object$keys$ = Object.keys(this.moduleMetadata)[0]) !== null && _Object$keys$ !== void 0 ? _Object$keys$ : "";
4343
+ }
4296
4344
  }, {
4297
4345
  key: "galleryEntries",
4298
4346
  value: function galleryEntries() {
@@ -11225,10 +11273,8 @@ var FileSchema = /*#__PURE__*/function (_Schema) {
11225
11273
  if (galleryKeyOf(src.path, function (key) {
11226
11274
  return key in galleryEntries;
11227
11275
  }) === null) {
11228
- return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [{
11229
- message: "The gallery does not have a file at '".concat(src.path, "'."),
11230
- value: src
11231
- }]));
11276
+ var _Object$keys$;
11277
+ return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [galleryMarker("file", src, (_Object$keys$ = Object.keys(this.moduleMetadata)[0]) !== null && _Object$keys$ !== void 0 ? _Object$keys$ : "")]));
11232
11278
  }
11233
11279
  return customValidationErrors.length > 0 ? _defineProperty({}, path, customValidationErrors) : false;
11234
11280
  }
@@ -11684,10 +11730,7 @@ var VideoSchema = /*#__PURE__*/function (_Schema) {
11684
11730
  }
11685
11731
  var entry = gallery.entries === null ? null : gallery.entries[src.path];
11686
11732
  if (entry === undefined) {
11687
- return [{
11688
- message: "The set does not have a video at '".concat(src.path, "'."),
11689
- value: src
11690
- }];
11733
+ return [galleryMarker("video", src, gallery.modulePath)];
11691
11734
  }
11692
11735
  // The poster and the captions are the field's own files, and live where
11693
11736
  // the set keeps its videos. The video itself is the set's to move.
@@ -16130,7 +16173,7 @@ function isPageRouter(routerId) {
16130
16173
 
16131
16174
  var corePackageJson = {
16132
16175
  name: "@valbuild/core",
16133
- version: "0.145.0",
16176
+ version: "0.146.2",
16134
16177
  "private": false,
16135
16178
  description: "Val - supercharged hard-coded content",
16136
16179
  repository: {
@@ -16237,6 +16280,7 @@ var Internal = {
16237
16280
  galleriesOf: galleriesOf,
16238
16281
  galleryEntryOf: galleryEntryOf,
16239
16282
  galleryKeyOf: galleryKeyOf,
16283
+ galleryMarkerOf: galleryMarkerOf,
16240
16284
  GALLERY_DEFAULT_GROUPS: GALLERY_DEFAULT_GROUPS,
16241
16285
  isHlsVideo: isHlsVideo,
16242
16286
  HLS_MIME_TYPE: HLS_MIME_TYPE
@@ -3036,6 +3036,50 @@ function galleryKeyOf(path, isKey) {
3036
3036
  return null;
3037
3037
  }
3038
3038
 
3039
+ /**
3040
+ * A gallery-backed field whose path the gallery, as the schema holds it, does
3041
+ * not have: the `image:check-gallery` (`file:`, `video:`) marker.
3042
+ *
3043
+ * The schema holds the gallery as it was EVALUATED -- in a built site, the
3044
+ * gallery as it was built. An entry added since (a pending change, a save in
3045
+ * a proposal, a content-only publish that never rebuilt the site) is only in
3046
+ * the gallery's current Source, so whether the field is wrong is a question
3047
+ * for a project-wide snapshot (`resolveSchemaSourceFixes`), as a keyOf's key
3048
+ * is. The message is the answer when the gallery does not have it either, so
3049
+ * a consumer that does not resolve markers reports what it always did.
3050
+ */
3051
+ function galleryMarker(media, source, galleryModulePath) {
3052
+ var what = media === "image" ? "The gallery does not have an image" : media === "file" ? "The gallery does not have a file" : "The set does not have a video";
3053
+ return {
3054
+ message: "".concat(what, " at '").concat(source.path, "'."),
3055
+ value: {
3056
+ path: source.path,
3057
+ gallery: galleryModulePath,
3058
+ source: source
3059
+ },
3060
+ fixes: ["".concat(media, ":check-gallery")]
3061
+ };
3062
+ }
3063
+
3064
+ /** A {@link galleryMarker}'s fields, or `null` for any other error. */
3065
+ function galleryMarkerOf(error) {
3066
+ var _error$fixes;
3067
+ var fixes = (_error$fixes = error.fixes) !== null && _error$fixes !== void 0 ? _error$fixes : [];
3068
+ if (!fixes.includes("image:check-gallery") && !fixes.includes("file:check-gallery") && !fixes.includes("video:check-gallery")) {
3069
+ return null;
3070
+ }
3071
+ var value = error.value;
3072
+ if (_typeof(value) !== "object" || value === null) return null;
3073
+ var path = "path" in value ? value.path : undefined;
3074
+ var gallery = "gallery" in value ? value.gallery : undefined;
3075
+ if (typeof path !== "string" || typeof gallery !== "string") return null;
3076
+ return {
3077
+ path: path,
3078
+ gallery: gallery,
3079
+ source: "source" in value ? value.source : undefined
3080
+ };
3081
+ }
3082
+
3039
3083
  /**
3040
3084
  * What a gallery entry holds as a DEFAULT for the fields picked from it, in
3041
3085
  * the groups a field overrides together.
@@ -4228,10 +4272,7 @@ var ImageSchema = /*#__PURE__*/function (_Schema) {
4228
4272
  if (galleryKeyOf(src.path, function (key) {
4229
4273
  return key in galleryEntries;
4230
4274
  }) === null) {
4231
- return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [{
4232
- message: "The gallery does not have an image at '".concat(src.path, "'."),
4233
- value: src
4234
- }]));
4275
+ return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [galleryMarker("image", src, this.galleryModulePath())]));
4235
4276
  }
4236
4277
  return customValidationErrors.length > 0 ? _defineProperty({}, path, customValidationErrors) : false;
4237
4278
  }
@@ -4295,6 +4336,13 @@ var ImageSchema = /*#__PURE__*/function (_Schema) {
4295
4336
  * alt — it carries its own — so it only needs the entry keys and the
4296
4337
  * dimensions, and a gallery of any alt shape can back it.
4297
4338
  */
4339
+ /** The module path of the gallery this field points at. */
4340
+ }, {
4341
+ key: "galleryModulePath",
4342
+ value: function galleryModulePath() {
4343
+ var _Object$keys$;
4344
+ return (_Object$keys$ = Object.keys(this.moduleMetadata)[0]) !== null && _Object$keys$ !== void 0 ? _Object$keys$ : "";
4345
+ }
4298
4346
  }, {
4299
4347
  key: "galleryEntries",
4300
4348
  value: function galleryEntries() {
@@ -11227,10 +11275,8 @@ var FileSchema = /*#__PURE__*/function (_Schema) {
11227
11275
  if (galleryKeyOf(src.path, function (key) {
11228
11276
  return key in galleryEntries;
11229
11277
  }) === null) {
11230
- return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [{
11231
- message: "The gallery does not have a file at '".concat(src.path, "'."),
11232
- value: src
11233
- }]));
11278
+ var _Object$keys$;
11279
+ return _defineProperty({}, path, [].concat(_toConsumableArray(customValidationErrors), [galleryMarker("file", src, (_Object$keys$ = Object.keys(this.moduleMetadata)[0]) !== null && _Object$keys$ !== void 0 ? _Object$keys$ : "")]));
11234
11280
  }
11235
11281
  return customValidationErrors.length > 0 ? _defineProperty({}, path, customValidationErrors) : false;
11236
11282
  }
@@ -11686,10 +11732,7 @@ var VideoSchema = /*#__PURE__*/function (_Schema) {
11686
11732
  }
11687
11733
  var entry = gallery.entries === null ? null : gallery.entries[src.path];
11688
11734
  if (entry === undefined) {
11689
- return [{
11690
- message: "The set does not have a video at '".concat(src.path, "'."),
11691
- value: src
11692
- }];
11735
+ return [galleryMarker("video", src, gallery.modulePath)];
11693
11736
  }
11694
11737
  // The poster and the captions are the field's own files, and live where
11695
11738
  // the set keeps its videos. The video itself is the set's to move.
@@ -16132,7 +16175,7 @@ function isPageRouter(routerId) {
16132
16175
 
16133
16176
  var corePackageJson = {
16134
16177
  name: "@valbuild/core",
16135
- version: "0.145.0",
16178
+ version: "0.146.2",
16136
16179
  "private": false,
16137
16180
  description: "Val - supercharged hard-coded content",
16138
16181
  repository: {
@@ -16239,6 +16282,7 @@ var Internal = {
16239
16282
  galleriesOf: galleriesOf,
16240
16283
  galleryEntryOf: galleryEntryOf,
16241
16284
  galleryKeyOf: galleryKeyOf,
16285
+ galleryMarkerOf: galleryMarkerOf,
16242
16286
  GALLERY_DEFAULT_GROUPS: GALLERY_DEFAULT_GROUPS,
16243
16287
  isHlsVideo: isHlsVideo,
16244
16288
  HLS_MIME_TYPE: HLS_MIME_TYPE
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var dist_valbuildCore = require('./index-ee601322.cjs.dev.js');
5
+ var dist_valbuildCore = require('./index-89993829.cjs.dev.js');
6
6
  require('./result-bb1f436e.cjs.dev.js');
7
7
 
8
8
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var dist_valbuildCore = require('./index-93763025.cjs.prod.js');
5
+ var dist_valbuildCore = require('./index-4bd4b62a.cjs.prod.js');
6
6
  require('./result-787e35f6.cjs.prod.js');
7
7
 
8
8
 
@@ -1,2 +1,2 @@
1
- export { H as ASSISTANT_SETTINGS_MAX_LENGTH, A as ArraySchema, B as BooleanSchema, a4 as CODE_LANGUAGES, a5 as COLOR_FORMATS, a3 as CodeSchema, a2 as ColorSchema, e as DEFAULT_APP_HOST, a6 as DEFAULT_COLOR_FORMAT, D as DEFAULT_CONTENT_HOST, u as DEFAULT_FONT_ACCEPT, f as DEFAULT_STATIC_HOST, o as DEFAULT_VAL_REMOTE_HOST, x as DEFAULT_VIDEO_ACCEPT, y as DEFAULT_VIDEO_RENDITIONS, z as DEFAULT_VIDEO_SEGMENT_DURATION, C as DateSchema, a7 as DateTimeSchema, ad as DiscriminatedUnionSchema, ae as EnumSchema, F as FATAL_ERROR_TYPES, v as FONT_MIME_TYPES, t as FileSchema, G as GenericSelector, r as ImageSchema, I as Internal, a8 as KeyOfSchema, af as LiteralSchema, Z as LocaleSchema, M as ModuleFilePathSep, N as NumberSchema, O as ObjectSchema, R as RecordSchema, ac as RichTextSchema, ab as RouteSchema, Q as SETTINGS_MODULE_CONVENTION, S as Schema, E as SettingsSchema, q as StringSchema, T as THEME_LOGO_DIRECTORY, K as THEME_RADIUS_LENGTHS, J as THEME_RADIUS_STEPS, at as UNSAFE_URL_SCHEMES, V as VAL_EXTENSION, a9 as ValViewSchema, w as VideoSchema, L as assistantAvailability, k as computeSchemaSha, j as computeSourcesSha, h as computeValModuleShas, $ as declaredKeySetOf, p as derefPatch, ap as describeSchemeRejection, ag as deserializeSchema, a1 as discriminatedUnionBranchOf, g as extractValModules, an as getSourcePathFromRoute, n as hasMediaSchema, l as hasRemoteFileSchema, i as initVal, aq as isCheckableScheme, ai as isInlineRender, ao as isPageRouter, U as isRootModuleFilePath, aa as isValViewSource, Y as localeOfValue, X as localeTagError, a0 as missingDeclaredKeys, m as modules, aj as parseNextJsRoutePattern, ak as parseTanStackRoutePattern, ah as previewScope, ar as rejectScheme, W as resolveSettingsModule, as as schemeOf, al as tanStackSegmentsOfRoutePath, am as validateUrlAgainstPattern } from './index-307b907e.esm.js';
1
+ export { H as ASSISTANT_SETTINGS_MAX_LENGTH, A as ArraySchema, B as BooleanSchema, a4 as CODE_LANGUAGES, a5 as COLOR_FORMATS, a3 as CodeSchema, a2 as ColorSchema, e as DEFAULT_APP_HOST, a6 as DEFAULT_COLOR_FORMAT, D as DEFAULT_CONTENT_HOST, u as DEFAULT_FONT_ACCEPT, f as DEFAULT_STATIC_HOST, o as DEFAULT_VAL_REMOTE_HOST, x as DEFAULT_VIDEO_ACCEPT, y as DEFAULT_VIDEO_RENDITIONS, z as DEFAULT_VIDEO_SEGMENT_DURATION, C as DateSchema, a7 as DateTimeSchema, ad as DiscriminatedUnionSchema, ae as EnumSchema, F as FATAL_ERROR_TYPES, v as FONT_MIME_TYPES, t as FileSchema, G as GenericSelector, r as ImageSchema, I as Internal, a8 as KeyOfSchema, af as LiteralSchema, Z as LocaleSchema, M as ModuleFilePathSep, N as NumberSchema, O as ObjectSchema, R as RecordSchema, ac as RichTextSchema, ab as RouteSchema, Q as SETTINGS_MODULE_CONVENTION, S as Schema, E as SettingsSchema, q as StringSchema, T as THEME_LOGO_DIRECTORY, K as THEME_RADIUS_LENGTHS, J as THEME_RADIUS_STEPS, at as UNSAFE_URL_SCHEMES, V as VAL_EXTENSION, a9 as ValViewSchema, w as VideoSchema, L as assistantAvailability, k as computeSchemaSha, j as computeSourcesSha, h as computeValModuleShas, $ as declaredKeySetOf, p as derefPatch, ap as describeSchemeRejection, ag as deserializeSchema, a1 as discriminatedUnionBranchOf, g as extractValModules, an as getSourcePathFromRoute, n as hasMediaSchema, l as hasRemoteFileSchema, i as initVal, aq as isCheckableScheme, ai as isInlineRender, ao as isPageRouter, U as isRootModuleFilePath, aa as isValViewSource, Y as localeOfValue, X as localeTagError, a0 as missingDeclaredKeys, m as modules, aj as parseNextJsRoutePattern, ak as parseTanStackRoutePattern, ah as previewScope, ar as rejectScheme, W as resolveSettingsModule, as as schemeOf, al as tanStackSegmentsOfRoutePath, am as validateUrlAgainstPattern } from './index-8519c554.esm.js';
2
2
  import './result-daff1cae.esm.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@valbuild/core",
3
- "version": "0.145.0",
3
+ "version": "0.146.2",
4
4
  "private": false,
5
5
  "description": "Val - supercharged hard-coded content",
6
6
  "repository": {
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var dist_valbuildCore = require('../../dist/index-ee601322.cjs.dev.js');
5
+ var dist_valbuildCore = require('../../dist/index-89993829.cjs.dev.js');
6
6
  var result = require('../../dist/result-bb1f436e.cjs.dev.js');
7
7
  var util = require('../../dist/util-b213092b.cjs.dev.js');
8
8
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var dist_valbuildCore = require('../../dist/index-93763025.cjs.prod.js');
5
+ var dist_valbuildCore = require('../../dist/index-4bd4b62a.cjs.prod.js');
6
6
  var result = require('../../dist/result-787e35f6.cjs.prod.js');
7
7
  var util = require('../../dist/util-030d8a1f.cjs.prod.js');
8
8
 
@@ -1,5 +1,5 @@
1
- import { _ as _typeof, a as _slicedToArray, P as PatchError, s as splitModuleFilePathAndModulePath, b as _createClass, c as _classCallCheck, d as _toConsumableArray } from '../../dist/index-307b907e.esm.js';
2
- export { P as PatchError } from '../../dist/index-307b907e.esm.js';
1
+ import { _ as _typeof, a as _slicedToArray, P as PatchError, s as splitModuleFilePathAndModulePath, b as _createClass, c as _classCallCheck, d as _toConsumableArray } from '../../dist/index-8519c554.esm.js';
2
+ export { P as PatchError } from '../../dist/index-8519c554.esm.js';
3
3
  import { f as isNonEmpty, e as err, o as ok, m as map, g as flatMap, i as isErr, h as flatMapReduce, j as filterOrElse, k as mapErr, l as map$1, n as all, p as flatten, q as allT } from '../../dist/result-daff1cae.esm.js';
4
4
  import { p as pipe } from '../../dist/util-18613e99.esm.js';
5
5