unicode-emoji 4.0.0 β†’ 4.0.2

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
  SHA256:
3
- metadata.gz: 5cc77126aeb986e5645ebce97fc3e1be5835b9e5adb9764af980e0175d7d9284
4
- data.tar.gz: ffd47af7c556ee26951f6c5f30122ecd44520f1a3aa6856c526c4e4dec050e77
3
+ metadata.gz: d94f58ea61375a083bf39d43197503aa257981effa0be11f4ad1224a427f62e9
4
+ data.tar.gz: 59b4eee9136d1b7360234491a0edbfc61000ad951cbcb5d9d4e41b410a59e9cd
5
5
  SHA512:
6
- metadata.gz: 810730ae1a796edc6c80c87d0d4e7c0a5bfdbda45c43f57dfde3a05afee7ee5df8d43f378c5c0de34d9e9bca8e9edfaee67261d16057a0aacc79f50c39d703d2
7
- data.tar.gz: f300c259b7389d60130b9f910b1301f31bf60d47c32fd16f86935cdf63c740bb44c28ab8fd38bc643f35cd6b4d7e9a76583d3be156683404439069ccf58d8250
6
+ metadata.gz: e8ab356aa91cd24e7085cdd40251eeec64a78f22792c1698a08100fd6716e0ef3be1f41bb7ef6641527cf79680d22502b6601676a8eaca49f0c8fbe4ec057326
7
+ data.tar.gz: 3cef152d23b2fca1db09c16129a62694bd9311d38cd825247a6017f3f3a45018e123b0a821b1fc86450031ceca5bd8447ec7c8ef7f5517cbf026780724584128
data/CHANGELOG.md CHANGED
@@ -1,6 +1,11 @@
1
1
  # CHANGELOG
2
2
 
3
- ### 4.0.0
3
+ ## 4.0.2
4
+
5
+ - Directly use `RbConfig::CONFIG["UNICODE_EMOJI_VERSION"]` to detect Ruby's Emoji version,
6
+ drop unicode-version dependency
7
+
8
+ ## 4.0.0
4
9
 
5
10
  - **Breaking change:** Regexes now include single skin tone modifiers (`🏻`) and hair components (`🦰`).
6
11
  They were previously considered to be invalid partial Emoji, however since they are supposed to be
@@ -13,7 +18,7 @@
13
18
  - Add `REGEX_EMOJI_KEYCAP` for matching specifically Emoji keycaps
14
19
  - Use character class instead of lookbehind for native text emoji and non-emoji pictographic regexes
15
20
 
16
- ### 3.8.0
21
+ ## 3.8.0
17
22
 
18
23
  - Add new RGI-based regexes `REGEX_INCLUDE_MQE` and `REGEX_INCLUDE_MQE_UQE` which allows to match
19
24
  for minimally-qualified and unqualified RGI sequences (Emoji that lack some VS16)
@@ -23,7 +28,7 @@
23
28
  - Update CLDR to v46 (valid subdivisions)
24
29
  - Further improvements (see commit log)
25
30
 
26
- ### 3.7.0
31
+ ## 3.7.0
27
32
 
28
33
  - Bump required Ruby slightly to 2.5
29
34
  - Introduce new `REGEX_POSSIBLE` which contains the regex described in
@@ -36,46 +41,46 @@
36
41
  - Separately autoload emoji list, so it can be loaded when other indexes
37
42
  are not needed
38
43
 
39
- ### 3.6.0
44
+ ## 3.6.0
40
45
 
41
46
  - `Unicode::Emoji::REGEX_TEXT` now matches non-emoji keycaps like "3⃣" (U+0033 U+20E3)
42
47
  - Minor refactorings
43
48
 
44
- ### 3.5.0
49
+ ## 3.5.0
45
50
 
46
51
  - Emoji 16.0
47
52
 
48
- ### 3.4.0
53
+ ## 3.4.0
49
54
 
50
55
  - Emoji 15.1
51
56
 
52
- ### 3.3.2
57
+ ## 3.3.2
53
58
 
54
59
  - Update valid subdivisions to CLDR 43 (no changes)
55
60
  -> there won't be any new RGI subdivision flags in Emoji
56
61
 
57
- ### 3.3.1
62
+ ## 3.3.1
58
63
 
59
64
  - Update valid subdivisions to CLDR 42 (no changes)
60
65
 
61
- ### 3.3.0
66
+ ## 3.3.0
62
67
 
63
68
  - Emoji 15.0
64
69
 
65
- ### 3.2.0
70
+ ## 3.2.0
66
71
 
67
72
  - Update valid subdivisions to CLDR 41
68
73
 
69
- ### 3.1.1
74
+ ## 3.1.1
70
75
 
71
76
  - Fix `REGEX` to be able to match complete family emoji, instead of
72
77
  sub-matching partial families, thanks @matt17r
73
78
 
74
- ### 3.1.0
79
+ ## 3.1.0
75
80
 
76
81
  - Update valid subdivisions to CLDR 40
77
82
 
78
- ### 3.0.0
83
+ ## 3.0.0
79
84
 
80
85
  - Vastly improve memory usage, patch by @radarek
81
86
  - Emoji regexes are now pre-generated and bundled with the release
@@ -83,54 +88,54 @@
83
88
  - Most constants (e.g. regexes) now get autoloaded
84
89
  - See https://github.com/janlelis/unicode-emoji/pull/9 for more details
85
90
 
86
- ### 2.9.0
91
+ ## 2.9.0
87
92
 
88
93
  - Emoji 14.0
89
94
 
90
- ### 2.8.0
95
+ ## 2.8.0
91
96
 
92
97
  - Update valid subdivisions to CLDR 39
93
98
 
94
- ### 2.7.1
99
+ ## 2.7.1
95
100
 
96
101
  - Update valid subdivisions to CLDR 38.1
97
102
 
98
- ### 2.7.0
103
+ ## 2.7.0
99
104
 
100
105
  - Update valid subdivisions to CLDR 38
101
106
  - Loosen Ruby dependency to allow Ruby 3.0
102
107
 
103
- ### 2.6.0
108
+ ## 2.6.0
104
109
 
105
110
  - Emoji 13.1
106
111
 
107
- ### 2.5.0
112
+ ## 2.5.0
108
113
 
109
114
  - Use native Emoji regex properties when current Ruby's Emoji support is the same as our current Emoji version
110
115
  - Update valid subdivisions to CLDR 37
111
116
 
112
- ### 2.4.0
117
+ ## 2.4.0
113
118
 
114
119
  - Emoji 13.0
115
120
 
116
- ### 2.3.1
121
+ ## 2.3.1
117
122
 
118
123
  - Fix index to actually include Emoji 12.1
119
124
 
120
- ### 2.3.0
125
+ ## 2.3.0
121
126
 
122
127
  - Emoji 12.1
123
128
 
124
- ### 2.2.0
129
+ ## 2.2.0
125
130
 
126
131
  - Update subdivisions to CLDR 36
127
132
 
128
- ### 2.1.0
133
+ ## 2.1.0
129
134
 
130
135
  - Add `REGEX_PICTO` which matches codepoints with the **Extended_Pictographic** property
131
136
  - Add `REGEX_PICTO_NO_EMOJI` which matches codepoints with the **Extended_Pictographic** property, but no **Emoji** property
132
137
 
133
- ### 2.0.0
138
+ ## 2.0.0
134
139
 
135
140
  - Emoji 12.0 data (including valid subdivisions)
136
141
  - Introduce new `REGEX_WELL_FORMED` to be able to match for invalid tag and region sequences
@@ -139,40 +144,40 @@
139
144
  - Issue warning when using `#list` method to retrieve outdated category
140
145
  - Change matching for ZWJ sequences: Do not limit sequence to a maximum of 3 ZWJs
141
146
 
142
- ### 1.1.0
147
+ ## 1.1.0
143
148
 
144
149
  - Emoji 11.0
145
150
  - Do not depend on rubygems (only use zlib stdlib for unzipping)
146
151
 
147
- ### 1.0.3
152
+ ## 1.0.3
148
153
 
149
154
  - Explicitly load rubygems/util, fixes regression in 1.2.1
150
155
 
151
- ### 1.0.2
156
+ ## 1.0.2
152
157
 
153
158
  - Use `Gem::Util` for `gunzip`, removes deprecation warning
154
159
 
155
- ### 1.0.1
160
+ ## 1.0.1
156
161
 
157
162
  - Actually set required Ruby version to 2.3 in gemspec
158
163
 
159
- ### 1.0.0
164
+ ## 1.0.0
160
165
 
161
166
  - Drop support for Ruby below 2.3, use 0.9 if you need to
162
167
  - Internal refactorings, no API change
163
168
 
164
- ### 0.9.3
169
+ ## 0.9.3
165
170
 
166
171
  - Implement native Emoji regex matchers, but do not activate or document, yet
167
172
 
168
- ### 0.9.2
173
+ ## 0.9.2
169
174
 
170
175
  - REGEX_TEXT: Do not match if the text emoji is followed by a emoji modifier
171
176
 
172
- ### 0.9.1
177
+ ## 0.9.1
173
178
 
174
179
  - Include a categorized list of recommended Emoji
175
180
 
176
- ### 0.9.0
181
+ ## 0.9.0
177
182
 
178
183
  - Initial release (Emoji version 5.0)
data/Gemfile.lock CHANGED
@@ -1,8 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- unicode-emoji (4.0.0)
5
- unicode-version (~> 1.0)
4
+ unicode-emoji (4.0.2)
6
5
 
7
6
  GEM
8
7
  remote: https://rubygems.org/
@@ -20,7 +19,6 @@ GEM
20
19
  reline (0.3.8)
21
20
  io-console (~> 0.5)
22
21
  stringio (3.0.8)
23
- unicode-version (1.4.0)
24
22
 
25
23
  PLATFORMS
26
24
  ruby
data/README.md CHANGED
@@ -37,7 +37,7 @@ string = "String which contains all types of Emoji sequences:
37
37
  - Sequence using ZWJ (zero width joiner): πŸ€ΎπŸ½β€β™€οΈ
38
38
  "
39
39
 
40
- string.scan(Unicode::Emoji::REGEX) # => ["😴", "▢️", "πŸ›ŒπŸ½", "πŸ‡΅πŸ‡Ή", "🏴󠁧󠁒󠁳󠁣󠁴󠁿", "2️⃣", "πŸ€ΎπŸ½β€β™€οΈ"]
40
+ string.scan(Unicode::Emoji::REGEX) # => ["😴", "▢️", "πŸ›ŒπŸ½", "πŸ‡΅πŸ‡Ή", "🏴󠁧󠁒󠁳󠁣󠁴󠁿", "2️⃣", "🏻", "πŸ€ΎπŸ½β€β™€οΈ"]
41
41
  ```
42
42
 
43
43
  Depending on your exact usecase, you can choose between multiple levels of Emoji detection:
@@ -79,7 +79,7 @@ Regex | Description | Example Matches | Example Non-Matc
79
79
  `Unicode::Emoji::REGEX_BASIC` | Matches (non-textual) Basic Emoji, but no sequences at all | `😴`, `▢️`, `🏻` | `😴︎`, `β–Ά`, `πŸ›ŒπŸ½`, `πŸ‡΅πŸ‡Ή`, `πŸ‡΅πŸ‡΅`,`2️⃣`, `🏴󠁧󠁒󠁳󠁣󠁴󠁿`, `🏴󠁧󠁒󠁑󠁧󠁒󠁿`, `πŸ€ΎπŸ½β€β™€οΈ`, `πŸ€ΎπŸ½β€β™€`, `πŸŒβ€β™‚οΈ`, `πŸ€ β€πŸ€’`, `1`
80
80
  `Unicode::Emoji::REGEX_TEXT` | Matches only textual singleton Emoji | `😴︎`, `β–Ά` | `😴`, `▢️`, `🏻`, `πŸ›ŒπŸ½`, `πŸ‡΅πŸ‡Ή`, `πŸ‡΅πŸ‡΅`,`2️⃣`, `🏴󠁧󠁒󠁳󠁣󠁴󠁿`, `🏴󠁧󠁒󠁑󠁧󠁒󠁿`, `πŸ€ΎπŸ½β€β™€οΈ`, `πŸ€ΎπŸ½β€β™€`, `πŸŒβ€β™‚οΈ`, `πŸ€ β€πŸ€’`, `1`
81
81
 
82
- Here is a list of all Emoji that can be matched using the two regexes: [character.construction/emoji-vs-text](https://character.construction/emoji-vs-text). The `REGEX_BASIC` regex also matches visual Emoji components (skin tone modifiers and hair components).
82
+ Here is a list of all Emoji that can be matched using the two regexes: [character.construction/emoji-vs-text](https://character.construction/emoji-vs-text). The `REGEX_BASIC` regex also matches [visual Emoji components](https://character.construction/emoji-components) (skin tone modifiers and hair components).
83
83
 
84
84
  While `REGEX_BASIC` is part of the above regexes, `REGEX_TEXT` is only included in the `*_INCLUDE_TEXT` or `*_UQE` variants.
85
85
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Unicode
4
4
  module Emoji
5
- VERSION = "4.0.0"
5
+ VERSION = "4.0.2"
6
6
  EMOJI_VERSION = "16.0"
7
7
  CLDR_VERSION = "46"
8
8
  DATA_DIRECTORY = File.expand_path('../../../data', __dir__).freeze
@@ -44,6 +44,6 @@ module Unicode
44
44
 
45
45
  # The current list of Emoji components that should have a visual representation
46
46
  # Currently skin tone modifiers + hair components
47
- VISUAL_COMPONENT = [*0x1F3FB..0x1F3FF, *0x1F9B0..0x1F9B3]
47
+ VISUAL_COMPONENT = [*0x1F3FB..0x1F3FF, *0x1F9B0..0x1F9B3].freeze
48
48
  end
49
49
  end
data/lib/unicode/emoji.rb CHANGED
@@ -1,7 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "unicode/version"
4
-
5
3
  require_relative "emoji/constants"
6
4
 
7
5
  module Unicode
@@ -34,7 +32,7 @@ module Unicode
34
32
  end
35
33
 
36
34
  generated_constants_dirpath = File.expand_path(
37
- EMOJI_VERSION == Unicode::Version.emoji_version ? "emoji/generated_native/" : "emoji/generated/",
35
+ EMOJI_VERSION == RbConfig::CONFIG["UNICODE_EMOJI_VERSION"] ? "emoji/generated_native/" : "emoji/generated/",
38
36
  __dir__
39
37
  )
40
38
 
@@ -19,6 +19,4 @@ Gem::Specification.new do |gem|
19
19
  gem.metadata = { "rubygems_mfa_required" => "true" }
20
20
 
21
21
  gem.required_ruby_version = ">= 2.5", "< 4.0"
22
-
23
- gem.add_dependency "unicode-version", "~> 1.0"
24
22
  end
metadata CHANGED
@@ -1,29 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: unicode-emoji
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jan Lelis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-11-06 00:00:00.000000000 Z
12
- dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: unicode-version
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '1.0'
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: '1.0'
11
+ date: 2024-11-13 00:00:00.000000000 Z
12
+ dependencies: []
27
13
  description: "[Emoji 16.0] Provides Unicode Emoji data and regexes, incorporating
28
14
  the latest Unicode and Emoji standards. Includes a categorized list of recommended
29
15
  Emoji."