keystatic icon indicating copy to clipboard operation
keystatic copied to clipboard

Block add/edit dialog too small for markdoc/mdx editor toolbar

Open brandonaaron opened this issue 9 months ago • 1 comments

I was attempting to use a fields.markdoc.inline within a block like so:

        blocks: fields.blocks(
          {
            richText: {
              label: 'Rich Text',
              itemLabel: (props) =>
                props.fields?.adminLabel.value || 'Rich Text',
              schema: fields.object({
                adminLabel: fields.text({
                  label: 'Admin Label',
                  description: 'How this block will be labeled in the editor',
                }),
                content: fields.markdoc.inline({
                  label: 'Content',
                }),
              }),
            },
          },
          {
            label: 'Block Builder',
          },
        ),

This results in a dialog that is too small to host the editor (at least on a large enough screen). Which I suppose there are two issues here: the editor toolbar doesn't scroll and the dialog is too small.

Image

I believe size="large" should be passed to the Dialog here and here.

This at least makes the editor functional on a large enough screen.

Image

brandonaaron avatar Mar 22 '25 23:03 brandonaaron

+1 I'm also seeing this issue

highlyinteractive avatar Mar 31 '25 10:03 highlyinteractive