Project

General

Profile

Feature #39111 » 0001-Updates-propshaft-gem-to-1.1.0-39111.patch

Marius BĂLTEANU, 2024-10-28 22:39

View differences:

Gemfile
14 14
gem 'rbpdf', '~> 1.21.3'
15 15
gem 'addressable'
16 16
gem 'rubyzip', '~> 2.3.0'
17
gem 'propshaft', '~> 0.8.0'
17
gem 'propshaft', '~> 1.1.0'
18 18
gem 'rack', '>= 3.1.3'
19 19

  
20 20
#  Ruby Standard Gems
lib/redmine/asset_path.rb
34 34
        @transition.add_src  intermediate_path, logical_path
35 35
        @transition.add_dest intermediate_path, logical_path
36 36
        asset = if file.extname == '.css'
37
                  Redmine::Asset.new(file,   logical_path: logical_path, version: version, transition_map: transition_map)
37
                  Redmine::Asset.new(file, logical_path: logical_path, version: version, transition_map: transition_map)
38 38
                else
39
                  Propshaft::Asset.new(file, logical_path: logical_path, version: version)
39
                  load_path = Propshaft::LoadPath.new([ file ], compilers: Propshaft::Compilers.new(nil))
40
                  Propshaft::Asset.new(file, logical_path: logical_path, load_path: load_path)
40 41
                end
41 42
        assets[asset.logical_path.to_s] ||= asset
42 43
      end
......
135 136
    def initialize(config)
136 137
      @extension_paths    = config.redmine_extension_paths
137 138
      @default_asset_path = config.redmine_default_asset_path
138
      super(config.paths, version: config.version)
139
      super(config.paths, version: config.version, compilers: Propshaft::Compilers.new(nil))
139 140
    end
140 141

  
141 142
    def asset_files
......
191 192
  class Asset < Propshaft::Asset
192 193
    def initialize(file, logical_path:, version:, transition_map:)
193 194
      @transition_map = transition_map
194
      super(file, logical_path: logical_path, version: version)
195
      load_path = Propshaft::LoadPath.new([ file ], compilers: Propshaft::Compilers.new(nil))
196
      super(file, logical_path: logical_path, load_path: load_path)
195 197
    end
196 198

  
197 199
    def content
(6-6/10)