Skip to content

Long ScVal byte values overflow horizontally on mobile #12

@Signor1

Description

@Signor1

I ran into this while testing a passkey smart wallet on my phone. Opened the contract-creation transaction on stellar.expert and the page scrolls sideways. The operation row runs off the right edge and you have to drag the whole page to read it.

Image Image

I dug into it a bit. It's the __constructor args on the create-contract op. One of them is the wallet's secp256r1 public key, which renders as a long base64 bytes value with no spaces in it, so there's nothing for it to wrap on. On a phone-width screen that single token is wider than the viewport and pushes everything out.

Looking at ScVal in contract/sc-val.js, the bytes case renders into <span className="condensed">, and .condensed is just letter-spacing — no wrapping. The other long-value cases (str, sym, instance) already use word-break, so they're fine. And since the op row is a flex-wrap: nowrap layout, that one unbreakable token stops the row from ever shrinking, so the page overflows.

Happy to send a PR. I think it's a one-liner on .sc-val to let those long values break when they'd otherwise run off the edge.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions