MCPcopy Create free account
hub / github.com/streamlit/streamlit / is_emoji

Function is_emoji

lib/streamlit/string_util.py:50–57  ·  view source on GitHub ↗

Check if input string is a valid emoji.

(text: str)

Source from the content-addressed store, hash-verified

48
49
50def is_emoji(text: str) -> bool:
51 """Check if input string is a valid emoji."""
52 if not _contains_special_chars(text):
53 return False
54
55 from streamlit.emojis import ALL_EMOJIS
56
57 return text.replace("\U0000fe0f", "") in ALL_EMOJIS
58
59
60def is_material_icon(maybe_icon: str) -> bool:

Callers 7

_get_favicon_stringFunction · 0.90
_process_logo_imageFunction · 0.90
_navigationFunction · 0.90
_process_avatar_inputFunction · 0.90
chat_messageMethod · 0.90
validate_emojiFunction · 0.85

Calls 1

_contains_special_charsFunction · 0.85

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…