Sha256: 52c36348e70b0d88547c70bf4ead8f3bef2f59653ed8f0df523fbb6dcd3d4d69

Contents?: true

Size: 866 Bytes

Versions: 6

Compression:

Stored size: 866 Bytes

Contents

module Assets
  class Rule
    class Compile
      # Abstract base class for compilers that compile to css
      class Css < self

        MIME = Mime::CSS

        # Compiler for sass
        class Sass < self
          handle(Mime::SASS)

          # Return body
          #
          # @return [String]
          #
          # @api private
          #
          def body
            binary(::Sass.compile(input.body, :syntax => :sass))
          end

        end # Sass

        # Compiler for sass in scss flavor
        class Scss < self
          handle(Mime::SCSS)

          # Return body
          #
          # @return [String]
          #
          # @api private
          #
          def body
            binary(::Sass.compile(input.body, :syntax => :scss))
          end

        end # Scss

      end # Css
    end # Compile
  end # Rule
end # Assets

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
mbj-assets-0.0.11 lib/assets/rule/compile/css.rb
mbj-assets-0.0.10 lib/assets/rule/compile/css.rb
mbj-assets-0.0.9 lib/assets/rule/compile/css.rb
mbj-assets-0.0.8 lib/assets/rule/compile/css.rb
mbj-assets-0.0.7 lib/assets/rule/compile/css.rb
mbj-assets-0.0.6 lib/assets/rule/compile/css.rb