Open stephenwf opened 5 days ago
Currently the id property inside of a TextualBody annotation prevent Manifests from being validated. It is valid to have an identifier, but it is not required - so the Manifest Editor could still remove it when serialising the P3 resource.
id
TextualBody
The relevant code is here: https://github.com/IIIF-Commons/parser/blob/main/src/presentation-3/serialize-presentation-3.ts#L17-L18
Where we do remove the ID if it was generated internally entity.id?.startsWith('vault://') - so when creating an HTML Body:
entity.id?.startsWith('vault://')
https://github.com/digirati-co-uk/iiif-manifest-editor/blob/main/packages/creators/src/ContentResource/HTMLBodyCreator/create-html-body.tsx#L15
We should make sure the ID is prefixed with vault:// if we want to ensure it's removed.
vault://
Currently the
id
property inside of aTextualBody
annotation prevent Manifests from being validated. It is valid to have an identifier, but it is not required - so the Manifest Editor could still remove it when serialising the P3 resource.The relevant code is here: https://github.com/IIIF-Commons/parser/blob/main/src/presentation-3/serialize-presentation-3.ts#L17-L18
Where we do remove the ID if it was generated internally
entity.id?.startsWith('vault://')
- so when creating an HTML Body:https://github.com/digirati-co-uk/iiif-manifest-editor/blob/main/packages/creators/src/ContentResource/HTMLBodyCreator/create-html-body.tsx#L15
We should make sure the ID is prefixed with
vault://
if we want to ensure it's removed.