mirror of
https://github.com/shoelace-style/webawesome.git
synced 2026-01-12 12:09:26 +00:00
30 lines
587 B
CSS
30 lines
587 B
CSS
wa-copy-button.copy-button {
|
|
--background-color: var(--wa-color-gray-20);
|
|
--background-color-hover: color-mix(in oklab, var(--background-color), white 5%);
|
|
position: absolute;
|
|
top: 0.25rem;
|
|
right: 0.25rem;
|
|
font-family: var(--wa-font-family-body);
|
|
color: var(--wa-color-gray-80);
|
|
border-radius: var(--wa-border-radius-m);
|
|
padding: 0.25rem;
|
|
|
|
&:hover {
|
|
color: white;
|
|
}
|
|
|
|
&:focus-visible {
|
|
outline: var(--wa-focus-ring);
|
|
}
|
|
}
|
|
|
|
@media (hover: hover) {
|
|
.copy-button:not(:focus-within) {
|
|
opacity: 0;
|
|
}
|
|
|
|
pre:hover > .copy-button {
|
|
opacity: 1;
|
|
}
|
|
}
|