feat: 添加自定义滚动条样式,优化布局和组件结构

This commit is contained in:
2026-05-22 17:02:07 +08:00
parent d3cb786edb
commit c286db68b1
10 changed files with 125 additions and 15 deletions
+35
View File
@@ -116,13 +116,48 @@
@layer base {
* {
@apply border-border outline-ring/50;
scrollbar-width: thin;
scrollbar-color: color-mix(in oklch, var(--foreground) 28%, transparent)
transparent;
}
body {
@apply bg-background text-foreground;
@apply font-sans;
}
button:not(:disabled),
[role="button"]:not(:disabled) {
cursor: pointer;
}
/* Chrome / Edge / Safari */
*::-webkit-scrollbar {
width: 8px;
height: 8px;
}
*::-webkit-scrollbar-track {
background: transparent;
}
*::-webkit-scrollbar-thumb {
background: color-mix(in oklch, var(--foreground) 22%, transparent);
border-radius: 999px;
}
*::-webkit-scrollbar-thumb:hover {
background: color-mix(in oklch, var(--foreground) 38%, transparent);
}
/* 去掉滚动条两头的箭头按钮 */
*::-webkit-scrollbar-button {
display: none;
width: 0;
height: 0;
}
*::-webkit-scrollbar-corner {
background: transparent;
}
}