2
0

pagepreview.rst 1.0 KB

12345678910111213141516171819202122232425262728293031
  1. Page Preview Block
  2. ==================
  3. Shows a miniview (a condensed version) of a selected Page.
  4. Field Reference
  5. ---------------
  6. **Page to Preview** - Select the page that you want to display a preview
  7. .. figure:: images/page_preview_editor.jpeg
  8. :alt: A Page Preview block and its settings
  9. A Page Preview block and its settings
  10. The selected page is rendered using the page model's "miniview" template.
  11. The template can be overridden per model with the ``miniview_template`` attribute, the default of which is `coderedcms/pages/page.mini.html <https://github.com/coderedcorp/coderedcms/blob/main/coderedcms/templates/coderedcms/pages/pages.mini.html>`_.
  12. .. figure:: images/page_preview_card.jpeg
  13. :alt: A Page Preview block using the card template
  14. Most pages use the built-in card miniview.
  15. .. figure:: images/page_preview_form.jpeg
  16. :alt: A Page Preview block using the form inputs template
  17. Forms use the built-in form miniview.
  18. .. versionadded:: 2.1
  19. Miniview templates were added in Wagtail CRX 2.1