update
This commit is contained in:
@@ -1,17 +1,22 @@
|
||||
// @keep-sorted
|
||||
export default defineAppConfig({
|
||||
component: {
|
||||
codeblock: {
|
||||
/** 代码块触发折叠的行数 */
|
||||
triggerRows: 32,
|
||||
/** 代码块折叠后的行数 */
|
||||
collapsedRows: 16,
|
||||
/** 启用代码块缩进导航会关闭空格渲染 */
|
||||
enableIndentGuide: true,
|
||||
/** 代码块缩进导航(Indent Guige)竖线匹配空格数 */
|
||||
indent: 4,
|
||||
/** tab渲染宽度 */
|
||||
tabSize: 3,
|
||||
ui: {
|
||||
prose: {
|
||||
// pre: {
|
||||
// slots: {
|
||||
// root: "relative my-4 group rounded-lg bg-(--c-bg-2,#0f1419)",
|
||||
// header:
|
||||
// "sticky top-0 z-20 flex items-center justify-between gap-3 px-4 py-2.5 bg-(--c-bg-2,#0f1419) border-b border-(--c-border,#2a2e38) backdrop-blur-sm",
|
||||
// filename:
|
||||
// "flex items-center gap-1.5 px-2.5 py-1.5 rounded-md bg-(--c-bg-3,#1a1f2e) text-xs font-mono text-(--c-text-1,#e8eaed) whitespace-nowrap border border-(--c-border,#2a2e38)",
|
||||
// icon: "w-3.5 h-3.5 shrink-0 opacity-80",
|
||||
// copy: "px-2.5 py-1.5 rounded-md text-xs font-mono bg-(--c-bg-3,#1a1f2e) hover:bg-(--c-border,#2a2e38) transition-colors text-(--c-text-2,#a8adb8) hover:text-(--c-text-1,#e8eaed) border border-transparent hover:border-(--c-border,#2a2e38)",
|
||||
// base: "overflow-auto m-0 text-(--c-text-1,#e8eaed) shiki font-mono text-sm leading-relaxed",
|
||||
// },
|
||||
// },
|
||||
codeIcon: {
|
||||
config: "i-lucide-settings",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
width: 5.25rem;
|
||||
padding-right: 1rem;
|
||||
text-align: right;
|
||||
color: #999999;
|
||||
color: white;
|
||||
user-select: none;
|
||||
font-size: 0.85em;
|
||||
}
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
/* @import url("https://fontsapi.zeoseven.com/292/main/result.css"); */
|
||||
@import "tailwindcss";
|
||||
@import "@nuxt/ui";
|
||||
@import "code.css";
|
||||
@plugin "@tailwindcss/typography";
|
||||
@plugin "@tailwindcss/forms";
|
||||
@tailwind utilities;
|
||||
@@ -20,6 +19,27 @@
|
||||
--font-roboto: "LXGW WenKai", sans-serif;
|
||||
} */
|
||||
|
||||
/* 先定义计数器 */
|
||||
pre[class*="language-"] {
|
||||
counter-reset: line;
|
||||
}
|
||||
|
||||
/* 每个代码行 <span> / <div> 前自增计数并打印 */
|
||||
pre[class*="language-"] code > * {
|
||||
counter-increment: line;
|
||||
position: relative;
|
||||
padding-left: 3rem; /* 行号留出空间 */
|
||||
}
|
||||
|
||||
pre[class*="language-"] code > *::before {
|
||||
content: counter(line);
|
||||
position: absolute;
|
||||
left: 0;
|
||||
width: 2rem;
|
||||
text-align: right;
|
||||
color: #6b7280; /* Tailwind gray-500 */
|
||||
}
|
||||
|
||||
@theme {
|
||||
--font-roboto: "JetBrains Maple Mono", sans-serif;
|
||||
--font-display: "JetBrains Maple Mono", sans-serif;
|
||||
|
||||
@@ -13,6 +13,9 @@ interface Props {
|
||||
}
|
||||
|
||||
const props = withDefaults(defineProps<Props>(), {
|
||||
title: "",
|
||||
icon: "",
|
||||
color: "",
|
||||
type: "info",
|
||||
card: false,
|
||||
flat: false,
|
||||
@@ -95,7 +98,7 @@ const iconName = computed(() => props.icon || config.value.icon);
|
||||
</div>
|
||||
|
||||
<!-- Description -->
|
||||
<div class="text-sm text-white/85 leading-relaxed">
|
||||
<div class="text-sm font-bold text-zinc-800 dark:text-white/85 leading-relaxed">
|
||||
<slot></slot>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user