Sha256: ae02fe792c0434ac9fa4187fbd25c0f8e35f8d783688d3ea85727b5a629b5e8c
Contents?: true
Size: 492 Bytes
Versions: 19
Compression:
Stored size: 492 Bytes
Contents
module Spree class TaxonImage < Asset include Rails.application.config.use_paperclip ? Configuration::Paperclip : Configuration::ActiveStorage include Rails.application.routes.url_helpers def styles self.class.styles.map do |_, size| width, height = size[/(\d+)x(\d+)/].split('x') { url: polymorphic_path(attachment.variant(resize: size), only_path: true), width: width, height: height } end end end end
Version data entries
19 entries across 19 versions & 1 rubygems