File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed
Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change 44from wagtail .admin .edit_handlers import FieldPanel , StreamFieldPanel
55from wagtail .core .fields import StreamField
66from wagtail .core .models import Page
7+ from wagtail .core import blocks as streamfield_blocks
78
89from streams import blocks
910
@@ -25,6 +26,13 @@ class FlexPage(Page):
2526 ("cards" , blocks .CardBlock ()),
2627 ("cta" , blocks .CTABlock ()),
2728 ("button" , blocks .ButtonBlock ()),
29+ ("char_block" , streamfield_blocks .CharBlock (
30+ required = True ,
31+ help_text = 'Oh wow this is help text!!' ,
32+ min_length = 10 ,
33+ max_length = 50 ,
34+ template = "streams/char_block.html" ,
35+ ))
2836 ],
2937 null = True ,
3038 blank = True ,
Original file line number Diff line number Diff line change 1+ < div class ="container ">
2+ < div class ="row ">
3+ < div class ="col-sm-10 offset-sm-1 ">
4+ {{ self }}
5+ </ div >
6+ </ div >
7+ </ div >
You can’t perform that action at this time.
0 commit comments