UNPKG

@seidhr/sanity-plugin-muna-schemas

Version:

Muna or ᛗᚢᚾᚨ means remember in norse. Muna is a schema for the Sanity Studio that enables detailed descriptions of cultural heritage objects and knowledge about their contexts as well as pages about them (or anything else really.)

29 lines (26 loc) 870 B
import { defaultFieldsets } from '../../../../fieldsets/defaultFieldsets' import { coalesceLabel } from '../../../../helpers/coalesceLabel' import { label } from '../../../properties/datatype' import { digitallyShownBy, referredToBy, represents } from '../../../properties/object' export default { name: 'VisualObject', description: 'Image content worthy of description as distinct entities, such as the image shown by a painting or drawing.', type: 'object', title: 'Visuelt objekt', titleEN: 'Visual object', fieldsets: defaultFieldsets, fields: [represents, label, digitallyShownBy, referredToBy], preview: { select: { title: 'label', media: 'digitallyShownBy.0', }, prepare(selection) { const { title, media } = selection return { title: coalesceLabel(title), media: media, } }, }, }