Merge pull request #29 from xcuYao/dev_xcuYao2 update:this example can run on xcode13, though it’s blank
Merge pull request #29 from xcuYao/dev_xcuYao2
update:this example can run on xcode13, though it’s blank
❤️ Support my apps ❤️
❤️❤️😇😍🤘❤️❤️
Emoji in Swift. For reference, go to https://github.com/onmyway133/emoji
Smile.list() emojiList emojiCategories
Smile.isEmoji(character: "🎉") // true
Smile.containsEmoji(string: "🎈 and 🎁") // true
Smile.countEmoji("🎈 and 🎁") // 2
Smile.countNonEmoji("🎈 and 🎁") // 5
Smile.isSingleEmoji("🎈 and 🎁") // false Smile.isSingleEmoji("👨") // true Smile.isSingleEmoji("👩🏽🧑") // false Smile.isSingleEmoji("just plain text") // false
Smile.isEmojiOnly("🎈 and 🎁") // false Smile.isEmojiOnly("👨") // true Smile.isEmojiOnly("👩🏽🧑") // true Smile.isEmojiOnly("just plain text") // false
XCTAssertEqual(Smile.emoji(unicodeValues: [0x1F47B]), "👻") XCTAssertEqual(Smile.emoji(unicodeValues: [0x0001F468, 0x200D, 0x2708]), "👨✈")
Smile.unmodify(emoji: "👨🏿") // 👨
Smile.name(emoji: "🇳🇴") // ["REGIONAL INDICATOR SYMBOL LETTER N", "REGIONAL INDICATOR SYMBOL LETTER O"])
Smile.emojis(keywords: ["GRINNING"]) // 😁, 😸
Smile.emoji(countryCode: "no") // 🇳🇴
Emoji data is from https://github.com/github/gemoji/blob/master/db/emoji.json
Smile.emoji(alias: "japanese_castle") // 🏯
Smile.alias(emoji: "🏯") // japanese_castle
Smile.replaceAlias(string: " is coming to ") // 🎅 is coming to 🏰
Emoji data is from https://github.com/github/gemoji/blob/master/db/Category-Emoji.json
Smile.category(emoji: "😁") // people
Smile.extractEmojis(string: "Find 🔑and🔎") // 🔑🔎
Smile.removeEmojis(string: "Find 🔑and🔎") // Find and
Smile.assemble(emojis: ["👨", "🏫") // 👨🏫 Smile.assemble(emojis: ["👨", "👩", "👧", "👦"] // 👨👩👧👦
Smile.disassemble(emoji: "👨🏫") // [👨, 🏫]
Update emoji list by running
node parser.js
Smile is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'Smile'
Smile is also available through Carthage. To install just write into your Cartfile:
github "onmyway133/Smile"
Khoa Pham, onmyway133@gmail.com
We would love you to contribute to Smile, check the CONTRIBUTING file for more info.
Smile is available under the MIT license. See the LICENSE file for more info.
©Copyright 2023 CCF 开源发展委员会 Powered by Trustie& IntelliDE 京ICP备13000930号
Smile
❤️ Support my apps ❤️
❤️❤️😇😍🤘❤️❤️
Emoji in Swift. For reference, go to https://github.com/onmyway133/emoji
Features
List
List all emojis
Emoji
Check if a character is emoji
Check if a string contains any emoji
Count number of emoji characters in a string
Count number of non-emoji characters in a string
Check if a string contains only a single emoji
Check if a string contains only emojis
Get emoji from unicode values
Unmodify an emoji
Name
Show standard name of an emoji
Search emoji by keywords
Flag
Search emoji flag by country code
Alias
Search emoji by alias
Emoji data is from https://github.com/github/gemoji/blob/master/db/emoji.json
Find alias by emoji
Replace alias within a string
Category
Find category of emoji
Emoji data is from https://github.com/github/gemoji/blob/master/db/Category-Emoji.json
Manipulation
Extract all emojis within a string
Remove all emojis within a string
Assemble
Disassemble
Script
Update emoji list by running
Installation
Smile is available through CocoaPods. To install it, simply add the following line to your Podfile:
Smile is also available through Carthage. To install just write into your Cartfile:
Author
Khoa Pham, onmyway133@gmail.com
Contributing
We would love you to contribute to Smile, check the CONTRIBUTING file for more info.
License
Smile is available under the MIT license. See the LICENSE file for more info.