Sha256: e40251264f4ce93f015534e942bf9077daaf08bad2ff8453019234afea380449

Contents?: true

Size: 382 Bytes

Versions: 8

Compression:

Stored size: 382 Bytes

Contents

module Octopress
  module AssetPipeline
    class Css < Asset
      def media
        path.to_s.scan(/@(.+?)\./).flatten[0] || 'all'
      end

      def destination
        File.join(base, filename.sub(/@(.+?)\./,'.'))
      end

      def tag
        "<link href='#{Filters.expand_url(destination)}' media='#{media}' rel='stylesheet' type='text/css'>"
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
octopress-asset-pipeline-2.0.0 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.7 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.6 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.5 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.4 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.3 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.2 lib/octopress-asset-pipeline/assets/css.rb
octopress-asset-pipeline-1.1.1 lib/octopress-asset-pipeline/assets/css.rb