Class: Eyeliner::Application
- Inherits:
-
Object
- Object
- Eyeliner::Application
- Defined in:
- lib/eyeliner.rb
Overview
encapsulates the application of CSS to some HTML input
Instance Method Summary collapse
- #apply ⇒ Object
-
#initialize(eyeliner, input) ⇒ Application
constructor
A new instance of Application.
Constructor Details
#initialize(eyeliner, input) ⇒ Application
Returns a new instance of Application.
40 41 42 43 44 |
# File 'lib/eyeliner.rb', line 40 def initialize(eyeliner, input) @eyeliner = eyeliner @input = input @css = @eyeliner.css end |
Instance Method Details
#apply ⇒ Object
46 47 48 49 50 51 52 53 |
# File 'lib/eyeliner.rb', line 46 def apply parse_input extract_stylesheets parse_css map_styles_to_elements apply_styles_to_elements @doc.to_html end |