Skip to content

Commit

Permalink
Merge pull request #16 from trailofbits/dev-fix-copy
Browse files Browse the repository at this point in the history
Fix copy icon position on numbered code snippets
  • Loading branch information
ahpaleus authored Feb 9, 2024
2 parents 4437577 + fa8498f commit 63db667
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions assets/_custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,21 @@

.markdown .highlight {
position: relative;
padding: 1rem 0;

> pre {
margin: inherit;
}

code:first-child::before {
content: url('svg/copy-regular.svg');
width: 1rem;
height: 1rem;
content: "Copy";
font-size: 0;
background: no-repeat center url('svg/copy-regular.svg');
width: 1.4rem;
height: 1.4rem;
position: absolute;
right: 1rem;
top: 1.1rem;
top: 2rem;
display: inline-block;
opacity: 0.3;
transition: opacity 0.1s ease-in;
Expand Down

0 comments on commit 63db667

Please sign in to comment.