add section previews during editing

This commit is contained in:
Torsten 2022-12-02 11:18:55 +02:00
parent 48cfcb592d
commit f81922fe01
2 changed files with 7 additions and 1 deletions

View File

@ -1,5 +1,8 @@
%p#notice= notice
- template = find_template(@section)
= render( template , section: @section)
.flex.flex-col.bg-white
.flex.items-center.justify-center.flex-1
.max-w-xl.px-4.py-8.mx-auto.text-center
@ -8,7 +11,7 @@
.flex.items-center.justify-center.flex-1
%h3.text-xl.font-bold.tracking-tight.text-gray-900
Cards for
= link_to "Section #{@section.index + 1}", page_sections_url(page_id: @section.page.name)
= link_to "Section #{@section.index + 1}", section_url( @section.id)
.grid.grid-cols-4.gap-2.m-8
- @section.cards.each_with_index do |card , index|

View File

@ -1,5 +1,8 @@
%p#notice= notice
- template = find_template(@section)
= render( template , section: @section)
.flex.flex-col.bg-white
.flex.items-center.justify-center.flex-1
.max-w-xl.px-4.py-8.mx-auto.text-center