hadi-codes/twemoji
适用于 Flutter 的 Twitter 表情符号,此包支持 svg 和 png 72x72 表情符号
- Stars
- 14
- Forks
- 14
- 最近推送(UTC)
- 2024年6月17日
- 项目状态
- 未归档
语言DartHTMLSwiftKotlinObjective-C
技术话题
使用的依赖
依赖清单 7 项
- characters
^1.1.0 - flutter
{"sdk":"flutter"} - flutter_svg
^1.0.0 - io
^1.0.3 - path
^1.8.0 - yaml
^3.1.0 - flutter_test开发依赖
{"sdk":"flutter"}
原始 README
以下为英文项目原文快照,最新内容请访问 GitHub。
展开 / 收起项目 README
twemoji
Twitter Emojis for Flutter, this package supports svg and png 72x72 emojis
Usage
Twemoji widget for a single emoji
Twemoji(
emoji: '🍕',
height: 50,
width: 50,
)
TwemojiText returns a widget with rendered text with twitter emojis
TwemojiText(
text: 'wow 💻👩💻👨💻 ',
),
TwemojiTextSpan with RichText and it will render the text with twitter Emojies
RichText(
text: TwemojiTextSpan(
text: 'Text 🍕🍔🌭🍿🧂🥓🥨🥐🍞🥞🥞',
style: Theme.of(context).textTheme.headline6,
),
)
Including specific emojis
By default the library includes support for all emojis. To reduce bundle size and only build the emojis your application requires, specify a list of them in your pubspec.yaml:
twemoji:
includes: '👩👩👧👧👏👍'
Then call flutter pub run twemoji:include_emojis to have it filter down the list of emojis to generate assets for.
Screenshot
DemoTODO
- [x] Add SVG support
- [x] Find a way to get an emoji code. For example: 😀 => "1F600"
- [ ] Extend Textfield widget to support twemoji
About twemoji: https://twemoji.twitter.com/