From d76552d35ca21a711d6ddfb2e29818946570d5e5 Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Sat, 12 Apr 2025 20:20:26 -0300 Subject: data: Artwork: "Dimensions" field --- src/data/things/artwork.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/data/things/artwork.js b/src/data/things/artwork.js index bb69dbd3..2a97fd6d 100644 --- a/src/data/things/artwork.js +++ b/src/data/things/artwork.js @@ -3,7 +3,6 @@ import {inspect} from 'node:util'; import {input} from '#composite'; import find from '#find'; import Thing from '#thing'; -import {parseAnnotatedReferences, parseContributors, parseDate} from '#yaml'; import { isContentString, @@ -18,6 +17,13 @@ import { validateReferenceList, } from '#validators'; +import { + parseAnnotatedReferences, + parseContributors, + parseDate, + parseDimensions, +} from '#yaml'; + import {withPropertyFromObject} from '#composite/data'; import { @@ -303,6 +309,11 @@ export class Artwork extends Thing { 'Directory': {property: 'unqualifiedDirectory'}, 'File Extension': {property: 'fileExtension'}, + 'Dimensions': { + property: 'dimensions', + transform: parseDimensions, + }, + 'Label': {property: 'label'}, 'Source': {property: 'source'}, -- cgit 1.3.0-6-gf8a5