mosaico 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 33fbe9102d1dab2b39a3535f6d62705239318add
4
- data.tar.gz: 8b3ba8eda8e70ddecaba81c43d917d9f385aace7
3
+ metadata.gz: eb08eed391dc9fdea93dfd8112abada6639bc06a
4
+ data.tar.gz: c26b82633c819545823c7572b3005e54b7156af1
5
5
  SHA512:
6
- metadata.gz: 2d492517c2eb7d0a10a8c16a351c783b4f38289669f7d4e4ee54b99e2e12dff5d2d4e0f22547340e2a7b0ff0189312968209d341e2c1af868c3e184aff6e47c1
7
- data.tar.gz: 35ac624b3953e9ce59402381e06b5ed710f2524921abec4ca63f836cee54a707af5029918a91c2cb523123eb26aec953a603334e45eec441dd5f526ed14414fb
6
+ metadata.gz: f5e720c0531c1e0a8274fe4ec630382994b76b08d769c17d4bbb5772e0ef7e4bfef9a57c29ef9123377fe13c60d56e6b63daedc93afd8e5a7e15d2b6547d7ba8
7
+ data.tar.gz: 6ba2611446a7b050de4f643b9e9cbcf8f78fd9adeb8fd199142f607e1fd592234628a513e21f00a83fc1842abc2b8e13802803fccea4df43c193e7c967bd73ae
@@ -1,3 +1,7 @@
1
+ 1.1.1
2
+ ===
3
+ * Fixed asset delivery for custom templates.
4
+
1
5
  1.1.0
2
6
  ===
3
7
  * Fixed asset delivery for TinyMCE plugins, themes, and skins.
@@ -51,7 +51,7 @@ module Mosaico
51
51
  def asset_paths
52
52
  @asset_paths ||= list_assets.each_with_object({}) do |asset_path, ret|
53
53
  asset_path = replacement_asset_url(asset_path)
54
- short_path = asset_path.sub(/\A#{File.join('mosaico', 'templates', name)}#{File::SEPARATOR}/, '')
54
+ short_path = asset_path.sub(/\A#{dir}#{File::SEPARATOR}?/, '')
55
55
  ret[short_path] = Mosaico.resolve_asset(asset_path)
56
56
  end
57
57
  end
@@ -75,6 +75,7 @@ module Mosaico
75
75
  end
76
76
 
77
77
  def before_register
78
+ Rails.application.config.assets.paths << File.dirname(dir)
78
79
  Rails.application.config.assets.precompile += list_assets
79
80
  end
80
81
 
@@ -83,11 +84,9 @@ module Mosaico
83
84
 
84
85
  def list_assets
85
86
  subdirs.flat_map do |subdir|
86
- Dir.chdir(Mosaico.vendor_asset_root) do
87
- # only allow images through for now
88
- # TODO: what other file types are we going to need?
89
- Dir.glob(File.join('mosaico', 'templates', name, subdir, '**/*.{jpg,gif,png}'))
90
- end
87
+ # only allow images through for now
88
+ # TODO: what other file types are we going to need?
89
+ Dir.glob(File.join(dir, subdir, '**/*.{jpg,gif,png}'))
91
90
  end
92
91
  end
93
92
  end
@@ -14,7 +14,7 @@ module Mosaico
14
14
  new_asset_path = original_asset_path.sub('google+', 'google_plus')
15
15
 
16
16
  Rails.application.config.assets.generated.add(new_asset_path, precompile: true) do
17
- File.binread(File.join(Mosaico.vendor_asset_root, original_asset_path))
17
+ File.binread(original_asset_path)
18
18
  end
19
19
  end
20
20
 
@@ -1,4 +1,4 @@
1
1
  module Mosaico
2
- VERSION = '1.1.0'
2
+ VERSION = '1.1.1'
3
3
  MOSAICO_VERSION = '0.16.0'
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mosaico
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cameron Dutro
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-02-17 00:00:00.000000000 Z
11
+ date: 2019-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: css-rewrite