diff --git a/dev/test-studio/schema/standard/portableText/blocks.tsx b/dev/test-studio/schema/standard/portableText/blocks.tsx index e23710fb497..7c256bf3ba7 100644 --- a/dev/test-studio/schema/standard/portableText/blocks.tsx +++ b/dev/test-studio/schema/standard/portableText/blocks.tsx @@ -16,6 +16,24 @@ function CustomEditor(props: PortableTextInputProps) { return } +const linkType = defineArrayMember({ + type: 'object', + name: 'link', + fields: [ + { + type: 'string', + name: 'href', + validation: (Rule) => Rule.uri({scheme: ['http', 'https']}).required(), + }, + ], + options: { + modal: { + type: 'popover', + width: 2, + }, + }, +}) + export default defineType({ name: 'blocksTest', title: 'Blocks test', @@ -31,7 +49,14 @@ export default defineType({ name: 'first', title: 'Block array as first field', type: 'array', - of: [{type: 'block'}], + of: [ + { + type: 'block', + marks: { + annotations: [linkType], + }, + }, + ], }, defineField({ name: 'defaults',