Skip to content

[Bug]: Copy button not visible on hover in Learn section #3226

@heygogu

Description

@heygogu

Issue:
The “Copy” button appears correctly on the Download page when hovering over code snippets, but it doesn’t show up on Learn or Docs pages (e.g. for-loops).

Expected:
Copy button should appear on hover for all code snippets, including Learn and Scala Book pages.
Actual:
The button is missing or hidden in docs pages, even though .code-snippet-area markup exists.

Possible causes:
The JavaScript initializing copy buttons was only loaded on the main site and not on the docs pages.
Code snippets in the docs are rendered differently (plain code block without .code-snippet-area wrapper).
CSS visibility rules (e.g., opacity, z-index) prevented the button from showing.

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