awesome_translations 0.0.48 → 0.0.49

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: 87fb57b6f7196a47481c8c5adeacf547ca70e7af
4
- data.tar.gz: 9e011b33b5d4c20998abdc81d15875459b2f8719
3
+ metadata.gz: cca092061f3714443e7e6e6f7826b73faa351ea4
4
+ data.tar.gz: 8fa96a5335f63b2d8eca1ba7ab26d077a39e8524
5
5
  SHA512:
6
- metadata.gz: 94767871086980e4971835074c538e7614e8d41a463a1f1940226747aa17c0d0e84e8b97fa788c748d374af924ed73cedc737ff81aaa0b8b0a7954411ef64566
7
- data.tar.gz: a229e58d17f4ce289668bb361670c4287c496b866de63f82dfb960e5060e91696ae6dd63e1ec7db499e37f4bbb63e90acf01a2f5fef32f4739fe58a7e8dc6b0a
6
+ metadata.gz: 2103763bcc4bf66d8155ecbc0483299cdc8f9f1e7f5ff7efc31c7a8269d180c88362fb994809e3d3b04bdb046a1cf351daa58a7d7c3afef28b11d2a8aa01e159
7
+ data.tar.gz: a1944952f71a89af1987ce700d2f0c45706a780c933ad4be4f0ab4163eb4b9a65c703cf779fed4266cdf35d0d1c84121d10d25e7f7a7b3e2a3cda30138a5d534
@@ -46,11 +46,11 @@ class AwesomeTranslations::ErbInspector::FileInspector
46
46
  private
47
47
 
48
48
  def parse_content_liquid(line_no, line, translations_found, yielder)
49
- line.scan(/\"([^\"]+?)\"\s+\|\s+t\s*(\%}|\}\})/) do |match|
49
+ line.scan(/\"([^\"]+?)\"\s+\|\s+t\s*(\%}|\}\}|\|)/) do |match|
50
50
  add_translation(line_no, "t", match[0], translations_found, yielder)
51
51
  end
52
52
 
53
- line.scan(/\'([^\']+?)\'\s+\|\s+t\s*(\%}|\}\})/) do |match|
53
+ line.scan(/\'([^\']+?)\'\s+\|\s+t\s*(\%}|\}\}|\|)/) do |match|
54
54
  add_translation(line_no, "t", match[0], translations_found, yielder)
55
55
  end
56
56
 
@@ -1,3 +1,3 @@
1
1
  module AwesomeTranslations
2
- VERSION = "0.0.48".freeze
2
+ VERSION = "0.0.49".freeze
3
3
  end
@@ -1,5 +1,7 @@
1
1
  <h1>{{ ".edit_user" | t }}</h1>
2
2
 
3
3
  {{ '.test_for_liquid_templates' | t }}
4
+ {{ ".test_for_liquid_templates_with_escape" | t | escape }}
5
+ {{ ".test_for_liquid_templates_with_var_escape" | val: "something", something | t | escape }}
4
6
  {{ ".test_for_liquid_templates_with_var_double_quotes" | val: "something", something | t }}
5
7
  {{ '.test_for_liquid_templates_with_var_single_quotes' | val: 'something', something | t }}
@@ -26,6 +26,8 @@ describe AwesomeTranslations::ErbInspector::FileInspector do
26
26
  expect(translation_keys).to include ".test_for_liquid_templates"
27
27
  expect(translation_keys).to include ".test_for_liquid_templates_with_var_double_quotes"
28
28
  expect(translation_keys).to include ".test_for_liquid_templates_with_var_single_quotes"
29
+ expect(translation_keys).to include ".test_for_liquid_templates_with_escape"
30
+ expect(translation_keys).to include ".test_for_liquid_templates_with_var_escape"
29
31
  end
30
32
  end
31
33
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awesome_translations
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.48
4
+ version: 0.0.49
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kasper Johansen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-06-06 00:00:00.000000000 Z
11
+ date: 2017-07-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: array_enumerator