mirror of
https://github.com/ralsina/tartrazine.git
synced 2024-11-10 05:22:23 +00:00
Basic theme parser
This commit is contained in:
parent
c6dce10322
commit
7392c8a74e
@ -51,9 +51,9 @@ module Tartrazine
|
|||||||
s.underline = true if style.includes?("underline")
|
s.underline = true if style.includes?("underline")
|
||||||
s.underline = false if style.includes?("nounderline")
|
s.underline = false if style.includes?("nounderline")
|
||||||
|
|
||||||
s.color = style.find { |w| w.starts_with?("#") }.try &.split("#").last
|
s.color = style.find(&.starts_with?("#")).try &.split("#").last
|
||||||
s.background = style.find { |w| w.starts_with?("bg:#") }.try &.split("#").last
|
s.background = style.find(&.starts_with?("bg:#")).try &.split("#").last
|
||||||
s.border = style.find { |w| w.starts_with?("border:#") }.try &.split("#").last
|
s.border = style.find(&.starts_with?("border:#")).try &.split("#").last
|
||||||
|
|
||||||
theme.styles[node["type"]] = s
|
theme.styles[node["type"]] = s
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user