Improve Test App
Render Custom Emoji in Text. Supports local and remote emojis. Remote emojis are loaded and cached using Nuke
Text
Remote emoji
EmojiText(verbatim: "Hello :my_emoji:", emojis: [RemoteEmoji(shortcode: "my_emoji", url: /* URL to emoji */)])
Local emoji
EmojiText(verbatim: "Hello :my_emoji:", emojis: [LocalEmoji(shortcode: "my_emoji", image: /* some UIImage or NSImage */)])
SF Symbol
EmojiText(verbatim: "Hello Moon & Starts :moon.stars:", emojis: [SFSymbolEmoji(shortcode: "moon.stars")])
Also supports Markdown
EmojiText(markdown: "**Hello** *World* :my_emoji:", emojis: [RemoteEmoji(shortcode: "my_emoji", url: /* URL to emoji */)])
Remote emojis are replaced by a placeholder image when loading. Default is the SF Symbol square.dashed but you can overide the placeholder image with
square.dashed
.placeholderEmoji(systemName: /* SF Symbol */)
or
.placeholderEmoji(image: /* some UIImage or NSImage */)
Remote emojis use ImagePipeline.shared from Nuke to load them, but you can provide a custom pipeline with
ImagePipeline.shared
.environment(\.emojiImagePipeline, ImagePipeline())
See LICENSE
©Copyright 2023 CCF 开源发展委员会 Powered by Trustie& IntelliDE 京ICP备13000930号
EmojiText
Render Custom Emoji in
Text
. Supports local and remote emojis. Remote emojis are loaded and cached using NukeUsage
Remote emoji
Local emoji
SF Symbol
Markdown
Also supports Markdown
Configuration
Remote emojis are replaced by a placeholder image when loading. Default is the SF Symbol
square.dashed
but you can overide the placeholder image withor
Remote emojis use
ImagePipeline.shared
from Nuke to load them, but you can provide a custom pipeline withLicense
See LICENSE