Documentation - add StreamFieldPanel to available panel types

pull/5679/head
Dan Swain 2019-11-12 09:52:07 -05:00 zatwierdzone przez LB
rodzic 4945acf2db
commit 5a8c4edba5
1 zmienionych plików z 17 dodań i 0 usunięć

Wyświetl plik

@ -28,6 +28,23 @@ FieldPanel
This parameter allows you to specify a :doc:`Django form widget <django:ref/forms/widgets>` to use instead of the default widget for this field type.
StreamFieldPanel
----------------
.. class:: StreamFieldPanel(field_name, classname=None, widget=None)
This is the panel used for Wagtail's StreamField type (see :ref:`streamfield`).
.. attribute:: FieldPanel.field_name
This is the name of the class property used in your model definition.
.. attribute:: FieldPanel.classname (optional)
This is a string of optional CSS classes given to the panel which are used in formatting and scripted interactivity. By default, panels are formatted as inset fields.
The CSS class ``full`` can be used to format the panel so it covers the full width of the Wagtail page editor.
MultiFieldPanel
---------------