-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* change Emojis() class API to static -> Generally `Emojis()` becomes simply `Emojis` (without brackets at the end) * change `Emojis().get` to `Emojis.all`: * remove `any`, `replaceEach`, `hasAny`, `hasEach` and `everyOf` * introduce new `Emoji()` constructor that takes single emoji as parameter * add shortcut methods and getters from package collection * export package collection * add topics and small logo * update CHANGELOG * update README * bump version to 1.0.0
- Loading branch information
Showing
59 changed files
with
12,560 additions
and
6,961 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
/// Enum representing the color of an emoji. | ||
enum Color { | ||
/// Red color of emoji. | ||
red('red'), | ||
|
||
/// Pink color of emoji. | ||
pink('pink'), | ||
|
||
/// Orange color of emoji. | ||
orange('orange'), | ||
|
||
/// Yellow color of emoji. | ||
yellow('yellow'), | ||
|
||
/// Green color of emoji. | ||
green('green'), | ||
|
||
/// Blue color of emoji. | ||
blue('blue'), | ||
|
||
/// Light blue color of emoji. | ||
lightBlue('light blue'), | ||
|
||
/// Purple color of emoji. | ||
purple('purple'), | ||
|
||
/// Brown color of emoji. | ||
brown('brown'), | ||
|
||
/// Black color of emoji. | ||
black('black'), | ||
|
||
/// Grey color of emoji. | ||
grey('grey'), | ||
|
||
/// White color of emoji. | ||
white('white'); | ||
|
||
/// Creates a new Color object with the given String value. | ||
const Color(this.value); | ||
|
||
/// Returns the Color enum value that matches the given [value]. | ||
/// | ||
/// If no match is found, this method throws a [StateError]. | ||
factory Color.from(String value) { | ||
return values.firstWhere((v) => v.value == value); | ||
} | ||
|
||
/// The String value of the color. | ||
final String value; | ||
} |
Oops, something went wrong.