Add code block copy button with toast

This commit is contained in:
Tim
2025-07-21 22:47:57 +08:00
parent ae76260d8f
commit 9c0a63d054
5 changed files with 61 additions and 13 deletions

View File

@@ -101,6 +101,24 @@ body {
padding: 8px 12px;
border-radius: 4px;
line-height: 0.8;
position: relative;
}
.copy-code-btn {
position: absolute;
top: 4px;
right: 4px;
font-size: 12px;
padding: 2px 6px;
border: none;
border-radius: 4px;
background-color: var(--primary-color);
color: #fff;
cursor: pointer;
}
.copy-code-btn:hover {
background-color: var(--primary-color-hover);
}
.info-content-text code {