Use new sixteen api

This commit is contained in:
2024-08-09 10:25:24 -03:00
parent 8167af78f0
commit d3439563f2
4 changed files with 39 additions and 38 deletions

View File

@ -83,9 +83,9 @@ module Tartrazine
theme.styles.each do |token, style|
outp << ".#{get_css_class(token, theme)} {"
# These are set or nil
outp << "color: #{style.color};" if style.color
outp << "background-color: #{style.background};" if style.background
outp << "border: 1px solid #{style.border};" if style.border
outp << "color: #{style.color.try &.hex};" if style.color
outp << "background-color: #{style.background.try &.hex};" if style.background
outp << "border: 1px solid #{style.border.try &.hex};" if style.border
# These are true/false/nil
outp << "border: none;" if style.border == false