fix(theme): fix render overflow of code block within Card on mobile, close #782 (#787)

This commit is contained in:
pengzhanbo 2025-12-12 20:40:04 +08:00 committed by GitHub
parent 65da8469ce
commit 46797a0757
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -78,4 +78,16 @@ const iconName = computed<string | { svg: string }>(() => {
.vp-card-wrapper .body > :last-child { .vp-card-wrapper .body > :last-child {
margin-bottom: 0; margin-bottom: 0;
} }
@media (max-width: 419px) {
.vp-card-wrapper .body :where(div[class*="language-"], .vp-block) {
margin: 16px -20px;
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
}
.vp-card-wrapper .body :deep(.code-block-title-bar) {
margin-inline: -20px;
}
}
</style> </style>