Skip to content

πŸ› Bug: Copy Button & Schema Label Missing Top/Right Margin in Code BlocksΒ #2284

@Tushar8466

Description

@Tushar8466

Describe the bug

The copy icon (πŸ“‹) and the "schema" / "data" label that appear in code blocks are positioned fixed/sticky to the top-right corner without any margin from the top and right edges of the code block container. This causes them to appear flush against the border, which looks visually unpolished and can also partially overlap the code content.

Steps To Reproduce

  1. Navigate to the "The basics" page in the Docs section.
  2. Observe any code block (e.g., the empty schema {} block or the data examples below it).
  3. Notice the copy icon and "schema"/"data" label are pinned with no spacing from the top-right corner of the code block.

Expected Behavior

The copy button and label should have consistent margin/padding from the top and right edges of the code block β€” e.g., margin-top: 8px and margin-right: 8px (or equivalent) β€” so they appear visually balanced and do not touch the border.

Actual Behaviour

The copy button and label are flush to the top-right with no visible margin, making the UI feel cramped.

Suggested Fix

Add top and right margin/padding to the sticky copy button and badge container inside code blocks:

.code-block-actions {
  margin-top: 8px;
  margin-right: 8px;
}

Device Information [optional]

  • OS:MacOS
  • Browser:Chrome
  • version:

Screenshots

Image

Are you working on this issue?

Yes

Do you think this work might require an [Architectural Decision Record (ADR)]? (significant or noteworthy)

Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: TriageThis is the initial status for an issue that requires triage.πŸ› BugIndicates that the issue is a bug or defect.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions