twitter_cldr 6.11.2 → 6.11.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +5 -5
- data/lib/twitter_cldr/segmentation/cj_break_engine.rb +2 -2
- data/lib/twitter_cldr/segmentation/cursor.rb +5 -1
- data/lib/twitter_cldr/shared/currencies.rb +1 -1
- data/lib/twitter_cldr/version.rb +1 -1
- data/spec/shared/currencies_spec.rb +2 -2
- data/twitter_cldr.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d26d9731806317d617136ada2344232764fe69a39ff76449918dfec104289ce
|
4
|
+
data.tar.gz: 843246cba66a4e80cf85c5e032a0a7062e3bd3c58809aaff10d993b11e47bf7c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ed165782eb0a31ebbc45393ca9893e00215de7163163f7c3355a0dba6c0441cc9af2de74485fc739056d79959247d047f1f93e35d7bd3abcf76fc2085375ea84
|
7
|
+
data.tar.gz: 349eeb7c7e36cdee993785d7fb37093e73457886d6bdb68e4f43e8d9258029222b537cc9dd32cbeab016bd39351cd8c66728573847500254f59f90a7def17e86
|
data/README.md
CHANGED
@@ -71,7 +71,7 @@ If you're looking for a list of supported currencies, use the `TwitterCldr::Shar
|
|
71
71
|
TwitterCldr::Shared::Currencies.currency_codes # ["ADP", "AED", "AFA", "AFN", ... ]
|
72
72
|
|
73
73
|
# data for a specific currency code
|
74
|
-
TwitterCldr::Shared::Currencies.for_code("CAD") # {:currency=>:CAD, :name=>"Canadian
|
74
|
+
TwitterCldr::Shared::Currencies.for_code("CAD") # {:currency=>:CAD, :name=>"Canadian Dollar", :cldr_symbol=>"CA$", :symbol=>"$", :code_points=>[36]}
|
75
75
|
```
|
76
76
|
|
77
77
|
#### Short / Long Decimals
|
@@ -247,7 +247,7 @@ It's important to know that, even though any given format may not be available a
|
|
247
247
|
| Hmv | 12:20 GMT |
|
248
248
|
| M | 2 |
|
249
249
|
| MEd | Fri, 2/14 |
|
250
|
-
| MMM |
|
250
|
+
| MMM | Feb |
|
251
251
|
| MMMEd | Fri, Feb 14 |
|
252
252
|
| MMMMW | week 3 of February |
|
253
253
|
| MMMMd | February 14 |
|
@@ -602,7 +602,7 @@ postal_code.regexp # /(\d{5})(?:[ \-](\d{4}))?/
|
|
602
602
|
Get a sample of valid postal codes with the `#sample` method:
|
603
603
|
|
604
604
|
```ruby
|
605
|
-
postal_code.sample(5) # ["
|
605
|
+
postal_code.sample(5) # ["32934", "29974", "17881-2274", "67896", "26121"]
|
606
606
|
```
|
607
607
|
|
608
608
|
### Phone Codes
|
@@ -1073,7 +1073,7 @@ TwitterCldr.locale # will return :ru
|
|
1073
1073
|
|
1074
1074
|
## Compatibility
|
1075
1075
|
|
1076
|
-
TwitterCLDR is fully compatible with Ruby 2.
|
1076
|
+
TwitterCLDR is fully compatible with Ruby 2.3, 2.4, 2.5, 2.6, 2.7, 3.0, 3.1.
|
1077
1077
|
|
1078
1078
|
## Requirements
|
1079
1079
|
|
@@ -1106,6 +1106,6 @@ TwitterCLDR currently supports localization of certain textual objects in JavaSc
|
|
1106
1106
|
|
1107
1107
|
## License
|
1108
1108
|
|
1109
|
-
Copyright
|
1109
|
+
Copyright 2022 Twitter, Inc.
|
1110
1110
|
|
1111
1111
|
Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0
|
@@ -96,10 +96,10 @@ module TwitterCldr
|
|
96
96
|
is_katakana = is_katakana?(cursor.codepoint)
|
97
97
|
|
98
98
|
if !is_prev_katakana && is_katakana
|
99
|
-
j =
|
99
|
+
j = idx + 1
|
100
100
|
cursor.advance
|
101
101
|
|
102
|
-
while
|
102
|
+
while cursor.position < end_pos && (j - idx) < MAX_KATAKANA_GROUP_LENGTH && is_katakana?(cursor.codepoint)
|
103
103
|
cursor.advance
|
104
104
|
j += 1
|
105
105
|
end
|
@@ -19,7 +19,7 @@ module TwitterCldr
|
|
19
19
|
if data
|
20
20
|
result = {
|
21
21
|
currency: currency_code,
|
22
|
-
name: data[:
|
22
|
+
name: data[:name],
|
23
23
|
cldr_symbol: data[:symbol] || currency_code.to_s,
|
24
24
|
symbol: data[:symbol] || currency_code.to_s,
|
25
25
|
code_points: (data[:symbol] || currency_code.to_s).unpack("U*")
|
data/lib/twitter_cldr/version.rb
CHANGED
@@ -23,7 +23,7 @@ describe TwitterCldr::Shared::Currencies do
|
|
23
23
|
data = described_class.for_code("PEN")
|
24
24
|
expect(data).to be_a(Hash)
|
25
25
|
expect(data).to include(
|
26
|
-
name: "Peruvian
|
26
|
+
name: "Peruvian Sol",
|
27
27
|
currency: :PEN,
|
28
28
|
symbol: "S/.",
|
29
29
|
cldr_symbol: "PEN"
|
@@ -34,7 +34,7 @@ describe TwitterCldr::Shared::Currencies do
|
|
34
34
|
data = described_class.for_code("CAD")
|
35
35
|
expect(data).to be_a(Hash)
|
36
36
|
expect(data).to include(
|
37
|
-
name: "Canadian
|
37
|
+
name: "Canadian Dollar",
|
38
38
|
currency: :CAD,
|
39
39
|
symbol: "$",
|
40
40
|
cldr_symbol: "CA$"
|
data/twitter_cldr.gemspec
CHANGED
@@ -6,7 +6,7 @@ Gem::Specification.new do |s|
|
|
6
6
|
s.version = ::TwitterCldr::VERSION
|
7
7
|
s.authors = ["Cameron Dutro"]
|
8
8
|
s.email = ["cdutro@twitter.com"]
|
9
|
-
s.homepage = "https://
|
9
|
+
s.homepage = "https://github.com/twitter/twitter-cldr-rb"
|
10
10
|
s.license = "Apache-2.0"
|
11
11
|
|
12
12
|
s.description = s.summary = "Ruby implementation of the ICU (International Components for Unicode) that uses the Common Locale Data Repository to format dates, plurals, and more."
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: twitter_cldr
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.11.
|
4
|
+
version: 6.11.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cameron Dutro
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: camertron-eprun
|
@@ -3983,7 +3983,7 @@ files:
|
|
3983
3983
|
- spec/utils/yaml/yaml_spec.rb
|
3984
3984
|
- spec/utils_spec.rb
|
3985
3985
|
- twitter_cldr.gemspec
|
3986
|
-
homepage: https://
|
3986
|
+
homepage: https://github.com/twitter/twitter-cldr-rb
|
3987
3987
|
licenses:
|
3988
3988
|
- Apache-2.0
|
3989
3989
|
metadata: {}
|
@@ -4002,7 +4002,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
4002
4002
|
- !ruby/object:Gem::Version
|
4003
4003
|
version: '0'
|
4004
4004
|
requirements: []
|
4005
|
-
rubygems_version: 3.
|
4005
|
+
rubygems_version: 3.2.22
|
4006
4006
|
signing_key:
|
4007
4007
|
specification_version: 4
|
4008
4008
|
summary: Ruby implementation of the ICU (International Components for Unicode) that
|