lib/vedeu/models/attributes/foreground.rb in vedeu-0.1.17 vs lib/vedeu/models/attributes/foreground.rb in vedeu-0.1.18

- old
+ new

@@ -1,27 +1,35 @@ module Vedeu class Foreground < ColourTranslator private + # @api private + # @return [String] def named ["\e[", foreground_codes[colour], "m"].join end + # @api private + # @return [String] def numbered ["\e[38;5;", css_to_numbered, "m"].join end + # @api private + # @return [String] def rgb - if Terminal.colour_mode == 16777216 + if Configuration.colour_mode == 16777216 sprintf("\e[38;2;%s;%s;%sm", *css_to_rgb) else numbered end end + # @api private + # @return [Hash] def foreground_codes codes end end