diff options
Diffstat (limited to 'src/data/things')
-rw-r--r-- | src/data/things/album.js | 17 | ||||
-rw-r--r-- | src/data/things/track.js | 17 |
2 files changed, 26 insertions, 8 deletions
diff --git a/src/data/things/album.js b/src/data/things/album.js index 539f4fb1..b8009063 100644 --- a/src/data/things/album.js +++ b/src/data/things/album.js @@ -19,6 +19,7 @@ import { parseContributors, parseDate, parseDimensions, + parseReferencedArtworks, } from '#yaml'; import {exitWithoutDependency, exposeDependency, exposeUpdateValueOrContinue} @@ -46,6 +47,7 @@ import { fileExtension, flag, name, + referencedArtworkList, referenceList, simpleDate, simpleString, @@ -223,7 +225,7 @@ export class Album extends Thing { value: input.value([]), }), - referenceList({ + referencedArtworkList({ class: input.value(Track), find: input.value(find.track), data: 'trackData', @@ -236,7 +238,7 @@ export class Album extends Thing { value: input.value([]), }), - referenceList({ + referencedArtworkList({ class: input.value(Album), find: input.value(find.album), data: 'albumData', @@ -410,8 +412,15 @@ export class Album extends Thing { transform: parseAdditionalFiles, }, - 'Referenced Track Artworks': {property: 'referencedTrackArtworks'}, - 'Referenced Album Artworks': {property: 'referencedAlbumArtworks'}, + 'Referenced Track Artworks': { + property: 'referencedTrackArtworks', + transform: parseReferencedArtworks, + }, + + 'Referenced Album Artworks': { + property: 'referencedAlbumArtworks', + transform: parseReferencedArtworks, + }, 'Franchises': {ignore: true}, diff --git a/src/data/things/track.js b/src/data/things/track.js index 586e5f4c..078ad11b 100644 --- a/src/data/things/track.js +++ b/src/data/things/track.js @@ -15,6 +15,7 @@ import { parseDate, parseDimensions, parseDuration, + parseReferencedArtworks, } from '#yaml'; import {withPropertyFromObject} from '#composite/data'; @@ -47,6 +48,7 @@ import { flag, name, referenceList, + referencedArtworkList, reverseReferenceList, simpleDate, simpleString, @@ -324,7 +326,7 @@ export class Track extends Thing { value: input.value([]), }), - referenceList({ + referencedArtworkList({ class: input.value(Track), find: input.value(find.track), data: 'trackData', @@ -336,7 +338,7 @@ export class Track extends Thing { value: input.value([]), }), - referenceList({ + referencedArtworkList({ class: input.value(Album), find: input.value(find.album), data: 'albumData', @@ -506,8 +508,15 @@ export class Track extends Thing { 'Referenced Tracks': {property: 'referencedTracks'}, 'Sampled Tracks': {property: 'sampledTracks'}, - 'Referenced Track Artworks': {property: 'referencedTrackArtworks'}, - 'Referenced Album Artworks': {property: 'referencedAlbumArtworks'}, + 'Referenced Track Artworks': { + property: 'referencedTrackArtworks', + transform: parseReferencedArtworks, + }, + + 'Referenced Album Artworks': { + property: 'referencedAlbumArtworks', + transform: parseReferencedArtworks, + }, 'Franchises': {ignore: true}, 'Inherit Franchises': {ignore: true}, |