merged/app/views/merged/view/_section_half_image.haml

19 lines
781 B
Plaintext

%section.overflow-hidden.grid.grid-cols-1.m-20.md:grid-cols-2
%div{ order_option(section)}
= image_for( section , "h-56 w-full object-cover sm:h-full")
.p-8.md:p-12.lg:px-16.lg:py-24{ background_option(section)}
.mx-auto.max-w-xl{options(section , :text_align , :color)}
%h2.mt-12.text-2xl.font-bold.md:text-4xl
= section.header
-if section.has_option?("subheader")
%h4.text-xl.mt-10.md:text-2xl
= section.option("subheader")
%p.prose.mt-8.md:block
= markdown(section)
-if section.has_option?("text")
%p.prose.mt-8.md:block
= markdown section.option("text")
-if section.has_option?("button_text")
.mt-8.md:mt-8
= render 'merged/view/elements/button' , section: section