darkpool
darkpool

Reputation: 14641

Wagtail full width admin

I have the following StructBlock

class ArticleSectionBlock(blocks.StructBlock):
    sections = blocks.ListBlock(
        blocks.StructBlock(
            [("header", blocks.CharBlock()), ("content", blocks.RichTextBlock())]
        )
    )

I am using the above block in my page model as follows:

content = StreamField(
    [("article_sections", blocks.ArticleSectionBlock())], null=False, blank=False
)
content_panels = Page.content_panels + [StreamFieldPanel("content")]

In the wagtail admin, this field is very narrow and hard to use:

enter image description here

Is there a way to make it full width in the admin to provide more space to type?

Upvotes: 1

Views: 330

Answers (2)

gasman
gasman

Reputation: 25237

Wagtail 2.7 (due to be released in November 2019) will include a redesign of StreamField to address this problem and others. In the meantime, installing the wagtail-react-streamfield package will provide the improved design.

Upvotes: 2

Caspianstrider
Caspianstrider

Reputation: 31

I have not personally done this but try customizing the editor interface using custom css as described in this section of the official documentation.

Upvotes: 0

Related Questions