This commit is contained in:
2023-01-10 11:39:21 +02:00
parent 68179949c8
commit 4e2c0c9687
6 changed files with 61 additions and 62 deletions

View File

@ -3,7 +3,7 @@
= @page.type.capitalize
.text-xl.font-bold.text-gray-900
=@page.name
%strong.rounded.bg-green-100.px-3.text-xs.font-medium.text-green-700{:class => "py-1.5"}
%strong.rounded.bg-green-100.px-4.py-2.text-lg.font-medium.text-green-700{:class => "py-1.5"}
= link_to 'Sections', merged.page_sections_path(@page.id)
.text-xl= distance_of_time_in_words_to_now(@page.updated_at)

View File

@ -8,7 +8,7 @@
-@page.sections.each do |section |
.flex.gap-10.mt-2{class: (section.index%2)==1 ? 'bg-cyan-50' : 'bg-red-50' , id: "section_#{section.id}"}
.basis-72.mx-20
.basis-72.ml-20
%h3.mt-4.text-lg.font-bold Section #{section.index} : #{section.header}
.flex.flex-wrap
= yellow_button("Edit" , merged.section_path(section.id) )

View File

@ -1,5 +1,6 @@
.mx-20.flex.h-16.items-center.gap-16
= render "sections_pagination" , section: @section
= link_to( "New Section" , merged.new_page_section_path(@section.page.id) , class: "p-2 border border-gray-200 bg-cyan-100 font-bold rounded-lg hover:bg-sky-100")
- template = find_template(@section)
= render( template , section: @section)