Class: Glimmer::CSS::RawCss
- Inherits:
-
Object
- Object
- Glimmer::CSS::RawCss
- Includes:
- CssFragment
- Defined in:
- lib/glimmer/css/raw_css.rb
Instance Attribute Summary collapse
-
#raw_css_string ⇒ Object
readonly
Returns the value of attribute raw_css_string.
Instance Method Summary collapse
-
#initialize(raw_css_string, parent:) ⇒ RawCss
constructor
A new instance of RawCss.
- #to_css ⇒ Object
Methods included from CssFragment
Constructor Details
#initialize(raw_css_string, parent:) ⇒ RawCss
Returns a new instance of RawCss.
32 33 34 35 36 37 |
# File 'lib/glimmer/css/raw_css.rb', line 32 def initialize(raw_css_string, parent:) @raw_css_string = raw_css_string @parent = parent @minifier = CSSMinifier.instance parent.children << self end |
Instance Attribute Details
#raw_css_string ⇒ Object (readonly)
Returns the value of attribute raw_css_string.
30 31 32 |
# File 'lib/glimmer/css/raw_css.rb', line 30 def raw_css_string @raw_css_string end |
Instance Method Details
#to_css ⇒ Object
39 40 41 |
# File 'lib/glimmer/css/raw_css.rb', line 39 def to_css @minifier.convert(@raw_css_string) end |