klenod-build 0.0.24 → 0.0.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6f22c9acfae008123fd3b68c5ab499c7bc8df3da4d5e135dea331f0fe6563596
4
- data.tar.gz: da87ac500d4d0f26bdeb4ff3249afacd1e34d594bb2f4e18bff1c1c4dd818e64
3
+ metadata.gz: ceb99aac4328e67769eebf0c137e9e2f8412bbfc65c51c0757906f7e5e1ce88f
4
+ data.tar.gz: 7bd420cb85700ace2a34e6e0460ee5f63f8a9b1530264f8b1f5d4a8f7f4583e3
5
5
  SHA512:
6
- metadata.gz: 0dd4bce3f8c250ed256e4362e6337f8ddee38c2865b9aba9ae7153066b1fb4d34f0fb324714626b4787011fde4118b1bc3f80a487865e2ee409248aebb44375f
7
- data.tar.gz: a65805c594f8d0823ce2df36a1b9d2f5c00e7b5ff71d3a178c1b8d7cc5f24a0f69d09d5d254d8bd16479d9c476b3ac14f67d097ea28efb2ccc7d89fd34f6dcec
6
+ metadata.gz: a8225fdd2f9208f17b2feeb832d03ed7bbb0fd5669bfd875fccdff579d05050a846f229996ccdce028e028d47b48cc70f24355b7a9384409d99c77e31a0a4a62
7
+ data.tar.gz: 0c5e2b51e492c0a56772ff6a9ed4309924a2da19e3a973c60782b1182605be59cec2cc3b10cc4c20a1641c21ae8102d9d37c3a6b00549fcf0e6a2b6347e84430
@@ -1106,6 +1106,15 @@
1106
1106
  "unitsPerEm": 1000,
1107
1107
  "xWidthAvg": 362
1108
1108
  },
1109
+ "Asap Sharp": {
1110
+ "familyName": "Asap Sharp",
1111
+ "category": "sans-serif",
1112
+ "ascent": 934,
1113
+ "descent": -212,
1114
+ "lineGap": 0,
1115
+ "unitsPerEm": 1000,
1116
+ "xWidthAvg": 442
1117
+ },
1109
1118
  "Asar": {
1110
1119
  "familyName": "Asar",
1111
1120
  "category": "serif",
@@ -2537,6 +2546,15 @@
2537
2546
  "unitsPerEm": 16,
2538
2547
  "xWidthAvg": 8
2539
2548
  },
2549
+ "Caacupe One": {
2550
+ "familyName": "Caacupe One",
2551
+ "category": "display",
2552
+ "ascent": 960,
2553
+ "descent": -340,
2554
+ "lineGap": 0,
2555
+ "unitsPerEm": 1000,
2556
+ "xWidthAvg": 309
2557
+ },
2540
2558
  "Cabin": {
2541
2559
  "familyName": "Cabin",
2542
2560
  "category": "sans-serif",
@@ -8187,7 +8205,7 @@
8187
8205
  "descent": -120,
8188
8206
  "lineGap": 0,
8189
8207
  "unitsPerEm": 1000,
8190
- "xWidthAvg": 311
8208
+ "xWidthAvg": 313
8191
8209
  },
8192
8210
  "Macondo": {
8193
8211
  "familyName": "Macondo",
@@ -14993,6 +15011,15 @@
14993
15011
  "unitsPerEm": 1000,
14994
15012
  "xWidthAvg": 457
14995
15013
  },
15014
+ "Scoutie Sans": {
15015
+ "familyName": "Scoutie Sans",
15016
+ "category": "sans-serif",
15017
+ "ascent": 2000,
15018
+ "descent": -600,
15019
+ "lineGap": 0,
15020
+ "unitsPerEm": 2000,
15021
+ "xWidthAvg": 920
15022
+ },
14996
15023
  "Seaweed Script": {
14997
15024
  "familyName": "Seaweed Script",
14998
15025
  "category": "display",
@@ -16847,6 +16874,15 @@
16847
16874
  "unitsPerEm": 1000,
16848
16875
  "xWidthAvg": 400
16849
16876
  },
16877
+ "Valley Sans": {
16878
+ "familyName": "Valley Sans",
16879
+ "category": "sans-serif",
16880
+ "ascent": 960,
16881
+ "descent": -240,
16882
+ "lineGap": 0,
16883
+ "unitsPerEm": 1000,
16884
+ "xWidthAvg": 487
16885
+ },
16850
16886
  "Vampiro One": {
16851
16887
  "familyName": "Vampiro One",
16852
16888
  "category": "display",
@@ -5,7 +5,7 @@ Update them to the latest Capsize revision from the Klenod repository root:
5
5
  bundle exec rake google_fonts:metrics:update
6
6
 
7
7
  Project: https://github.com/seek-oss/capsize
8
- Commit: b0eb891c39e2ecd8b680f550bcda6f5fe9e38326
8
+ Commit: 8df97f098adc19d8a6d33df301757d7e9670bae6
9
9
  Source: packages/metrics/src/entireMetricsCollection.json
10
10
 
11
11
  MIT License
@@ -46,6 +46,7 @@ module Klenod
46
46
  # invalid attribute list. Join the lines of an unclosed list first so
47
47
  # both forms work across lines.
48
48
  def parse_new_attributes(text)
49
+ tag_prefix = @line.text.strip[/\A[^(]*/]
49
50
  joined_lines = 0
50
51
  until (close_index = attribute_list_close_index(text)) || @next_line.eod?
51
52
  text = "#{text} #{@next_line.text}"
@@ -56,7 +57,13 @@ module Klenod
56
57
  pairs = close_index && extended_attribute_pairs(text[1...close_index])
57
58
  rest = close_index && text[(close_index + 1)..]
58
59
  unless pairs&.any? { |_name, value| value.match?(/[.\[]/) }
59
- attributes, rest, last_line = super
60
+ begin
61
+ attributes, rest, last_line = super
62
+ rescue ::Haml::SyntaxError => error
63
+ raise unless pairs && error.message.start_with?("Invalid attribute list")
64
+
65
+ raise ::Haml::SyntaxError.new("#{error.message}\n\n#{hash_attributes_hint(tag_prefix, pairs)}", error.line)
66
+ end
60
67
  return [attributes, rest, last_line + joined_lines]
61
68
  end
62
69
 
@@ -147,6 +154,19 @@ module Klenod
147
154
  pairs
148
155
  end
149
156
 
157
+ # Every value is valid Ruby, but some are neither Haml's bare variables
158
+ # nor the member and index expressions handled above. Suggest the
159
+ # equivalent hash attributes, which accept any Ruby expression.
160
+ def hash_attributes_hint(tag_prefix, pairs)
161
+ entries = pairs.map do |name, value|
162
+ key = name.match?(/\A[a-z_]\w*\z/i) ? name : name.inspect
163
+ "#{key}: #{value}"
164
+ end
165
+ tag_prefix = "" unless tag_prefix.match?(/\A[%.#][-:\w.#]*\z/)
166
+
167
+ "Hint:\n Use {} attributes for Ruby expressions: #{tag_prefix}{#{entries.join(", ")}}"
168
+ end
169
+
150
170
  # Returns the index of the `)` that closes the list opened at index 0,
151
171
  # ignoring brackets inside quoted values.
152
172
  def attribute_list_close_index(source)
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Klenod
4
4
  module Build
5
- VERSION = "0.0.24"
5
+ VERSION = "0.0.25"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: klenod-build
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.24
4
+ version: 0.0.25
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrés Alin
@@ -15,14 +15,14 @@ dependencies:
15
15
  requirements:
16
16
  - - '='
17
17
  - !ruby/object:Gem::Version
18
- version: 0.0.24
18
+ version: 0.0.25
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - '='
24
24
  - !ruby/object:Gem::Version
25
- version: 0.0.24
25
+ version: 0.0.25
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: async
28
28
  requirement: !ruby/object:Gem::Requirement