def as_escaped_unicode_literal(
        text: str
) -> str:
    """Convert the given ``text``  into a string of escaped Unicode
    hexadecimal.

    Args:
         text (:obj:`str`): The string to convert.

    :rtype:
        :obj:`str`

            A string with each character of the given ``text`` converted
            into an escaped Python literal.

    Example:
        >>> from flutils.strutils import as_escaped_unicode_literal
        >>> t = '1.★ 🛑'
        >>> as_literal(t)
        '\\\\x31\\\\x2e\\\\u2605\\\\x20\\\\U0001f6d1'
    """
    out = ''
    for c in text:
        c_hex = hex(ord(c))[2:]
        c_len = len(c_hex)
        if c_len in (1, 2):
            out += '\\x{:0>2}'.format(c_hex)
        elif c_len in (3, 4):
            out += '\\u{:0>4}'.format(c_hex)
        else:
            out += '\\U{:0>8}'.format(c_hex)
    return out