Example #1
0
async def require_confirm_tx(ctx, to, value):

    text = Text("Confirm sending", ui.ICON_SEND, icon_color=ui.GREEN)
    text.bold(format_amount(value, helpers.DIVISIBILITY) + " XRP")
    text.normal("to")
    text.mono(*split_address(to))
    return await require_hold_to_confirm(ctx, text, ButtonRequestType.SignTx)
Example #2
0
async def require_confirm_verify_message(ctx, address, message):
    text = Text("Confirm address")
    text.mono(*split_address(address))
    await require_confirm(ctx, text)

    text = Text("Verify message")
    text.mono(*split_message(message))
    await require_confirm(ctx, text)
Example #3
0
async def require_confirm_verify_message(ctx, address, message):
    lines = split_address(address)
    content = Text('Confirm address', ui.ICON_DEFAULT, ui.MONO, *lines)
    await require_confirm(ctx, content)

    message = split_message(message)
    content = Text('Verify message', ui.ICON_DEFAULT, max_lines=5, *message)
    await require_confirm(ctx, content)
Example #4
0
async def require_confirm_verify_message(ctx, address, message):
    text = Text('Confirm address')
    text.mono(*split_address(address))
    await require_confirm(ctx, text)

    text = Text('Verify message')
    text.normal(*split_message(message))
    await require_confirm(ctx, text)
Example #5
0
async def _show(ctx, pubkey: bytes):
    lines = split_address(hexlify(pubkey))
    text = Text("Export Stellar ID", ui.ICON_RECEIVE, icon_color=ui.GREEN)
    text.mono(*lines)

    return await confirm(ctx,
                         text,
                         code=ButtonRequestType.Address,
                         cancel_style=ui.BTN_KEY)