Skip to content

Commit 91c394a

Browse files
authored
fix: use proper selector for api-demo copy button styles (#201)
1 parent 9a2c982 commit 91c394a

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

.changeset/warm-mails-fry.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
"@api-viewer/demo": patch
3+
"@api-viewer/common": patch
4+
"@api-viewer/docs": patch
5+
"@api-viewer/tabs": patch
6+
"api-viewer-element": patch
7+
---
8+
9+
Use proper selector for demo copy button styles

packages/api-demo/src/styles.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ const highlightTheme = css`
6060
`;
6161

6262
const demoStyles = css`
63-
button {
63+
[part='button'] {
6464
position: absolute;
6565
top: 0.5rem;
6666
right: 0.5rem;
@@ -72,8 +72,8 @@ const demoStyles = css`
7272
color: var(--ave-button-color, #fff);
7373
}
7474
75-
button:focus,
76-
button:hover {
75+
[part='button']:focus,
76+
[part='button']:hover {
7777
background: var(--ave-button-active-background, rgba(0, 0, 0, 0.6));
7878
}
7979

0 commit comments

Comments
 (0)