Skip to content

Cropped SVG rendering that previously resized to fit Ordinals thumbnail #4300

@tesmonclara

Description

@tesmonclara

SVG inscriptions with specific width and height attributes now override the viewBox, causing content to appear cropped rather than scaled proportionally

​<svg xmlns="http://www.w3.org/2000/svg" width="509" height="509" viewBox="0 0 509 509">....

Found it hard to find official documentation regarding SVG safe structures for Ordinals.

I would suggest adding Best practices to create solid SVGs to the Ordinals Theory Handbook, something like:

  • Use viewBox alone (e.g., viewBox="0 0 1000 1000") to ensure proportional scaling across all display sizes.

  • Avoid width and height attributes unless explicitly matching the explorer’s thumbnail size (if documented, e.g., 300x300).

  • Test SVGs against common thumbnail dimensions to confirm full visibility. Free online tools: https://www.svgviewer.dev/ , https://boxy-svg.com/ , https://editor.method.ac

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions