background color for two col

This commit is contained in:
2022-12-05 12:38:57 +02:00
parent 6bb1a814ad
commit 7728767b3d
5 changed files with 31 additions and 7 deletions

View File

@ -23,9 +23,23 @@ module Merged
def order_option(section)
return {} unless section.has_option?("order")
puts "Option #{section.option('order')}"
return {} if section.option("order") == "left"
{class: "order-first"}
puts "Order #{section.option('order')}"
return {} if section.option("order") == "right"
{class: "order-last"}
end
def background_option(section)
return {} unless section.has_option?("background")
option = section.option('background')
puts "Background #{option}"
return {} if option == "white"
case option
when "blue"
background = "bg-cyan-100"
else
background = "white"
end
{class: background}
end
def button(text , url , color)