@arshdelight/practi 0.20.0 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -1
- package/dist/client.js +59 -1
- package/dist/client.js.map +1 -1
- package/dist/cmd/ls.js +53 -52
- package/dist/cmd/ls.js.map +1 -1
- package/dist/cmd/push.js +71 -9
- package/dist/cmd/push.js.map +1 -1
- package/dist/cmd/update.js +3 -3
- package/dist/cmd/update.js.map +1 -1
- package/dist/index.js +28 -4
- package/dist/index.js.map +1 -1
- package/dist/version-check.js +101 -0
- package/dist/version-check.js.map +1 -0
- package/package.json +1 -1
- package/skills/use-practi/SKILL.md +7 -1
- package/web-default/chain.html +9 -20
- package/web-default/chain.js +34 -20
- package/web-default/detail.html +1 -0
- package/web-default/detail.js +29 -23
- package/web-default/home.html +23 -18
- package/web-default/home.js +138 -25
- package/web-default/lang.js +20 -5
- package/web-default/style.css +267 -156
package/web-default/style.css
CHANGED
|
@@ -1,70 +1,188 @@
|
|
|
1
|
-
/* practi web
|
|
2
|
-
|
|
1
|
+
/* practi web 默认前端样式:视觉语言与 hub(arsh_practihub)同源——
|
|
2
|
+
token 逐值照抄其 src/app/globals.css(ink/navy 色阶 + 语义变量),
|
|
3
|
+
两处同步改;practi web 不维护自有配色。 */
|
|
3
4
|
:root {
|
|
4
5
|
color-scheme: light;
|
|
5
|
-
|
|
6
|
-
--
|
|
7
|
-
--
|
|
8
|
-
--
|
|
9
|
-
--
|
|
10
|
-
--
|
|
11
|
-
--
|
|
12
|
-
--
|
|
13
|
-
--
|
|
14
|
-
--
|
|
6
|
+
/* ── ink 中性灰蓝 11 档(hub globals.css @theme 逐值)── */
|
|
7
|
+
--ink-50: #F4F6F9;
|
|
8
|
+
--ink-100: #ECEEF2;
|
|
9
|
+
--ink-200: #E5E7EB;
|
|
10
|
+
--ink-300: #D0D3D8;
|
|
11
|
+
--ink-400: #A9ADB3;
|
|
12
|
+
--ink-500: #72777E;
|
|
13
|
+
--ink-600: #5E636C;
|
|
14
|
+
--ink-700: #464D59;
|
|
15
|
+
--ink-800: #2B3442;
|
|
16
|
+
--ink-900: #111827;
|
|
17
|
+
--ink-950: #030611;
|
|
18
|
+
/* ── 语义色关键档(hub 同名族;warning 还用到 50/200/700)── */
|
|
19
|
+
--success-500: #6BA179;
|
|
20
|
+
--warning-50: #FDF5EB;
|
|
21
|
+
--warning-200: #F5DEBF;
|
|
22
|
+
--warning-700: #8A5B00;
|
|
23
|
+
--danger-50: #FFF2F1;
|
|
24
|
+
--danger-200: #FAD5D1;
|
|
25
|
+
--danger-600: #AD5851;
|
|
26
|
+
--danger-700: #8D403A;
|
|
27
|
+
--info-500: #5698C2;
|
|
28
|
+
/* ── 语义变量(hub :root 逐值)── */
|
|
29
|
+
--background: #ffffff;
|
|
30
|
+
--ink: #111111; /* 正黑主墨(hub「字体尽量正黑」):正文/标题统一中性墨 */
|
|
31
|
+
--primary: #111827; /* =ink-900 */
|
|
32
|
+
--primary-foreground: #ffffff;
|
|
33
|
+
--muted: #F4F6F9; /* =ink-50 */
|
|
34
|
+
--muted-foreground: #72777E; /* =ink-500 */
|
|
35
|
+
--border: #E5E7EB; /* =ink-200 */
|
|
36
|
+
--radius: 8px;
|
|
37
|
+
/* 正墨透明度刻度(hub text-ink/40~70 同口径:弱化文字不换色,只降透明度) */
|
|
38
|
+
--ink-a15: rgba(17, 17, 17, .15);
|
|
39
|
+
--ink-a30: rgba(17, 17, 17, .3);
|
|
40
|
+
--ink-a35: rgba(17, 17, 17, .35);
|
|
41
|
+
--ink-a40: rgba(17, 17, 17, .4);
|
|
42
|
+
--ink-a45: rgba(17, 17, 17, .45);
|
|
43
|
+
--ink-a50: rgba(17, 17, 17, .5);
|
|
44
|
+
--ink-a55: rgba(17, 17, 17, .55);
|
|
45
|
+
--ink-a60: rgba(17, 17, 17, .6);
|
|
46
|
+
--ink-a65: rgba(17, 17, 17, .65);
|
|
15
47
|
}
|
|
16
48
|
* { box-sizing: border-box; }
|
|
17
49
|
/* 常驻滚动条水槽:内容超长时滚动条出现不再挤压视口,居中元素(操作区等)不左右平移 */
|
|
18
50
|
html { scrollbar-gutter: stable; }
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
51
|
+
/* 滚动条样式(hub globals.css 同款):细轨 + 中性 thumb */
|
|
52
|
+
::-webkit-scrollbar { width: 8px; height: 8px; }
|
|
53
|
+
::-webkit-scrollbar-track { background: transparent; }
|
|
54
|
+
::-webkit-scrollbar-thumb { background: var(--muted-foreground); border-radius: 4px; background-clip: content-box; border: 2px solid transparent; }
|
|
55
|
+
::-webkit-scrollbar-thumb:hover { background: var(--ink); background-clip: content-box; border: 2px solid transparent; }
|
|
56
|
+
* { scrollbar-width: thin; scrollbar-color: var(--muted-foreground) transparent; }
|
|
57
|
+
|
|
58
|
+
body { font: 14px/1.5 system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; margin: 0; color: var(--ink); background: var(--background); }
|
|
59
|
+
|
|
60
|
+
/* ── 页眉(hub 登录态灰底 sticky 页眉同款):LogoMark + 面包屑,右侧设置齿轮 ── */
|
|
61
|
+
header { position: sticky; top: 0; z-index: 50; height: 52px; background: var(--ink-50); display: flex; gap: 4px; align-items: center; padding: 0 16px; }
|
|
62
|
+
.brand-link { display: inline-flex; align-items: center; gap: 8px; border-radius: 6px; padding: 4px 6px; text-decoration: none; }
|
|
22
63
|
.brand-link:hover { text-decoration: none; }
|
|
23
64
|
.brand-link:hover .logo { opacity: .8; }
|
|
24
|
-
header .logo { width: 28px; height: 28px; color: var(--
|
|
25
|
-
header .brand { font-weight:
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
.
|
|
29
|
-
.
|
|
30
|
-
|
|
31
|
-
.
|
|
65
|
+
header .logo { width: 28px; height: 28px; color: var(--ink-900); flex: none; }
|
|
66
|
+
header .brand { font-weight: 650; letter-spacing: .2px; font-size: 15px; color: var(--ink); }
|
|
67
|
+
/* GitHub 式面包屑:owner 段可点(hover 浮起浅底),当前段 semibold;detail 页为不可点弱化段 */
|
|
68
|
+
.crumbs { display: flex; align-items: center; gap: 2px; font-size: 14px; min-width: 0; }
|
|
69
|
+
.crumb-sep { color: var(--ink-a35); }
|
|
70
|
+
.crumb { padding: 4px 8px; border-radius: 6px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
|
|
71
|
+
a.crumb { text-decoration: none; transition: background .15s; }
|
|
72
|
+
a.crumb:hover { background: var(--ink-100); text-decoration: none; }
|
|
73
|
+
.crumb.current { font-weight: 600; }
|
|
74
|
+
.crumb.muted { color: var(--ink-a55); cursor: default; }
|
|
75
|
+
/* 设置入口(lang.js 注入):header 右上角齿轮 ghost 钮(hub 图标钮口径:hover 只加深不换底) */
|
|
76
|
+
.settings-btn { margin-left: auto; display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; flex: none; border: none; border-radius: 6px; background: transparent; color: var(--ink-a45); cursor: pointer; }
|
|
77
|
+
.settings-btn:hover { color: var(--primary); }
|
|
78
|
+
|
|
79
|
+
/* 设置弹窗:hub AppDialog 同观感(白卡 16px 圆角 + xl 投影),固定大小(320×212) */
|
|
80
|
+
.settings-overlay { display: none; position: fixed; inset: 0; z-index: 100; background: rgba(0, 0, 0, .4); }
|
|
32
81
|
.settings-overlay.open { display: block; }
|
|
33
|
-
.settings-dialog { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 320px; height: 212px; background: #fff; border-radius:
|
|
34
|
-
.settings-title { margin: 0 0 12px; font-size: 15px; font-weight: 600; color: var(--
|
|
82
|
+
.settings-dialog { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 320px; height: 212px; background: #fff; border-radius: 16px; box-shadow: 0 20px 25px -5px rgba(0, 0, 0, .1), 0 8px 10px -6px rgba(0, 0, 0, .1); padding: 18px 20px 16px; display: flex; flex-direction: column; }
|
|
83
|
+
.settings-title { margin: 0 0 12px; font-size: 15px; font-weight: 600; color: var(--ink); }
|
|
35
84
|
.settings-body { flex: 1; }
|
|
36
|
-
.settings-field { margin: 0 0 8px; font-size: 12px; color: var(--
|
|
85
|
+
.settings-field { margin: 0 0 8px; font-size: 12px; color: var(--ink-a55); }
|
|
37
86
|
.settings-langs { display: flex; gap: 8px; }
|
|
38
|
-
.settings-lang { flex: 1; border: 1px solid var(--
|
|
39
|
-
.settings-lang:hover { border-color: var(--
|
|
40
|
-
.settings-lang.on { background:
|
|
87
|
+
.settings-lang { flex: 1; border: 1px solid var(--ink-200); border-radius: var(--radius); background: #fff; color: var(--ink-a60); font: inherit; font-size: 14px; padding: 8px 0; cursor: pointer; transition: background .15s, border-color .15s, color .15s; }
|
|
88
|
+
.settings-lang:hover { border-color: var(--ink-300); background: var(--ink-50); color: var(--ink); }
|
|
89
|
+
.settings-lang.on { background: var(--ink-100); border-color: var(--ink-300); color: var(--ink); font-weight: 500; }
|
|
41
90
|
.settings-foot { display: flex; justify-content: flex-end; }
|
|
42
|
-
|
|
91
|
+
|
|
92
|
+
main { max-width: 72rem; margin: 0 auto; padding: 32px 24px 64px; }
|
|
43
93
|
a { color: var(--primary); text-decoration: none; }
|
|
44
94
|
a:hover { text-decoration: underline; }
|
|
45
|
-
.page-title { font-size:
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
.
|
|
49
|
-
.
|
|
50
|
-
.
|
|
51
|
-
.
|
|
52
|
-
.
|
|
53
|
-
|
|
54
|
-
.
|
|
55
|
-
.
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
.
|
|
59
|
-
.
|
|
60
|
-
.
|
|
61
|
-
.
|
|
62
|
-
.
|
|
63
|
-
.empty {
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
95
|
+
.page-title { font-size: 24px; font-weight: 600; color: var(--ink); margin: 0 0 20px; }
|
|
96
|
+
|
|
97
|
+
/* ── 按钮原语(hub ui/Button 口径):secondary=白底描边 ink-300 hover ink-50;primary=实心 ── */
|
|
98
|
+
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 16px; border: 1px solid var(--ink-300); border-radius: var(--radius); background: #fff; color: var(--ink); font: inherit; font-size: 14px; cursor: pointer; text-decoration: none; transition: background .15s, border-color .15s, color .15s; }
|
|
99
|
+
.btn:hover { background: var(--ink-50); text-decoration: none; }
|
|
100
|
+
.btn:focus-visible { outline: none; box-shadow: 0 0 0 4px rgba(17, 24, 39, .1); }
|
|
101
|
+
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
|
|
102
|
+
.btn-primary:hover { background: rgba(17, 24, 39, .9); }
|
|
103
|
+
/* 胶囊描边徽章(hub ui/Badge 口径);warn=未推送(warning 族) */
|
|
104
|
+
.badge-pill { display: inline-flex; align-items: center; border-radius: 999px; border: 1px solid var(--ink-200); background: #fff; padding: 2px 10px; font-size: 12px; color: var(--ink-a60); white-space: nowrap; }
|
|
105
|
+
.badge-pill.badge-warn { border-color: var(--warning-200); background: var(--warning-50); color: var(--warning-700); }
|
|
106
|
+
|
|
107
|
+
/* ── 空态(hub 惯例:dashed 容器 + 大号淡色图标 + 弱化文案)── */
|
|
108
|
+
.empty { border: 1px dashed var(--ink-200); border-radius: var(--radius); text-align: center; padding: 56px 24px; }
|
|
109
|
+
.empty svg { width: 40px; height: 40px; color: var(--ink-a15); margin-bottom: 12px; }
|
|
110
|
+
.empty .lead { font-size: 14px; color: var(--ink-a55); margin: 0; }
|
|
111
|
+
.empty .hint { font-size: 12px; color: var(--ink-a45); margin: 12px 0 0; }
|
|
112
|
+
.empty code { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: .9em; background: var(--ink-50); border: 1px solid var(--ink-200); border-radius: 4px; padding: 1px 5px; }
|
|
113
|
+
.empty a { color: var(--primary); }
|
|
114
|
+
|
|
115
|
+
/* ── 目录页(home):hub /u/ 个人页同构——页眉下二级 tab 行 + [16rem_1fr] 栅格
|
|
116
|
+
(左资料栏位留空占位,右=总览/实践两档)── */
|
|
117
|
+
/* 二级 tab 行(hub ProfileTabs 位):灰底与页眉无缝合并,sticky top=页眉高 52px;
|
|
118
|
+
z-30 压内容、让位页眉 z-50(hub 同值) */
|
|
119
|
+
.tab-row { position: sticky; top: 52px; z-index: 30; background: var(--ink-50); border-bottom: 1px solid var(--ink-200); }
|
|
120
|
+
/* 下划线 tab(hub ui/Tabs=GitHub UnderlineNav):底部 2px 描边当前态;行高恰 48px */
|
|
121
|
+
.tabs { display: flex; align-items: center; gap: 4px; padding: 0 16px; }
|
|
122
|
+
.tab { display: inline-flex; align-items: center; gap: 8px; padding: 13.5px 8px; border: none; border-bottom: 2px solid transparent; margin-bottom: -1px; background: transparent; font: inherit; font-size: 14px; font-weight: 500; color: var(--ink-a50); cursor: pointer; user-select: none; transition: color .15s, border-color .15s; }
|
|
123
|
+
.tab svg { width: 16px; height: 16px; color: var(--ink-a45); flex: none; }
|
|
124
|
+
.tab:hover { color: var(--ink); border-bottom-color: var(--ink-300); }
|
|
125
|
+
.tab.on { color: var(--primary); border-bottom-color: var(--primary); }
|
|
126
|
+
.tab-count { border-radius: 999px; padding: 0 6px; font-size: 12px; line-height: 16px; font-weight: 400; background: var(--ink-100); color: var(--ink-a50); font-variant-numeric: tabular-nums; }
|
|
127
|
+
.tab.on .tab-count { background: rgba(17, 24, 39, .1); color: var(--primary); }
|
|
128
|
+
|
|
129
|
+
/* 内容栅格(hub /u/):pt-6 pb-12 + [16rem_1fr] gap-10;左栏=用户名占位(留空) */
|
|
130
|
+
main.u-main { padding: 24px 24px 48px; }
|
|
131
|
+
.u-grid { display: grid; grid-template-columns: 1fr; }
|
|
132
|
+
.u-content { min-width: 0; }
|
|
133
|
+
@media (min-width: 1024px) {
|
|
134
|
+
.u-grid { grid-template-columns: 16rem minmax(0, 1fr); gap: 40px; }
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/* 区块头(hub OverviewGrid 标题行):左=标题+弱化计数,右=查看全部 */
|
|
138
|
+
.sec-head { display: flex; align-items: center; justify-content: space-between; }
|
|
139
|
+
.sec-title { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); }
|
|
140
|
+
.sec-count { margin-left: 8px; font-size: 14px; font-weight: 400; color: var(--ink-a40); }
|
|
141
|
+
.view-all { border: none; background: none; padding: 0; font: inherit; font-size: 12px; color: var(--primary); cursor: pointer; user-select: none; }
|
|
142
|
+
.view-all:hover { text-decoration: underline; }
|
|
143
|
+
|
|
144
|
+
/* 总览双列卡网格(hub OverviewGrid:GitHub Popular repositories 同款,截前 6 张) */
|
|
145
|
+
.ov-grid { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 16px; }
|
|
146
|
+
@media (min-width: 640px) { .ov-grid { grid-template-columns: 1fr 1fr; } }
|
|
147
|
+
|
|
148
|
+
/* 查找框(hub MyInstances 工具栏):图标区在盒外左缘,focus-within 描边+ring */
|
|
149
|
+
.find-box { display: flex; align-items: center; height: 32px; width: 176px; border: 1px solid var(--ink-300); border-radius: var(--radius); background: #fff; transition: border-color .15s, box-shadow .15s; }
|
|
150
|
+
.find-box:focus-within { border-color: rgba(17, 24, 39, .4); box-shadow: 0 0 0 4px rgba(17, 24, 39, .1); }
|
|
151
|
+
.find-box svg { width: 14px; height: 14px; flex: none; margin-left: 10px; color: var(--ink-a35); pointer-events: none; user-select: none; }
|
|
152
|
+
.find-box input { flex: 1; min-width: 0; height: 100%; border: none; background: transparent; padding: 0 10px 0 6px; font: inherit; font-size: 14px; color: var(--ink); }
|
|
153
|
+
.find-box input::placeholder { color: var(--ink-a40); }
|
|
154
|
+
.find-box input:focus { outline: none; }
|
|
155
|
+
/* 实践档工具行:右对齐(hub 同款,标题由 tab 承担) */
|
|
156
|
+
.pr-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px; }
|
|
157
|
+
|
|
158
|
+
/* 实践档堆叠列表(hub:GitHub 仓库列表同款,独立描边卡片间距分隔) */
|
|
159
|
+
.stack-list { display: flex; flex-direction: column; gap: 12px; margin-top: 32px; }
|
|
160
|
+
|
|
161
|
+
/* 实践卡(hub InstanceCard 解剖逐条对齐):标题行 / 14px 摘录 line-clamp-2 / meta 沉底,
|
|
162
|
+
无头像与可见性徽章(本地无此数据) */
|
|
163
|
+
.card { display: block; border: 1px solid var(--ink-200); border-radius: var(--radius); background: #fff; padding: 16px; text-decoration: none; transition: border-color .15s, box-shadow .15s; }
|
|
164
|
+
.card:hover { border-color: var(--ink-300); box-shadow: 0 1px 2px rgba(0, 0, 0, .05); text-decoration: none; }
|
|
165
|
+
.card-title { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 14px; font-weight: 600; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
166
|
+
.card-excerpt { font-size: 14px; color: var(--ink-a60); margin: 4px 0 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
|
|
167
|
+
.card-excerpt .none { color: var(--ink-a40); }
|
|
168
|
+
.card-meta { font-size: 12px; color: var(--ink-a40); margin: 8px 0 0; font-variant-numeric: tabular-nums; }
|
|
169
|
+
/* 查找无结果的弱化空态(hub 同款:dashed 盒内回显查询词) */
|
|
170
|
+
.find-empty { margin-top: 32px; padding: 56px 24px; text-align: center; border: 1px dashed var(--ink-200); border-radius: var(--radius); font-size: 14px; color: var(--ink-a40); overflow-wrap: break-word; }
|
|
171
|
+
|
|
172
|
+
/* ── 提交链页(chain):hub commits 页同款——分支选择器行 + divide-y 版本行列表 ── */
|
|
173
|
+
.branch-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
|
|
174
|
+
.branch-btn { display: inline-flex; align-items: center; height: 32px; padding: 0 12px; border: 1px solid var(--ink-300); background: #fff; border-radius: var(--radius); font: inherit; font-size: 13px; color: var(--ink); cursor: pointer; transition: background .15s, border-color .15s; }
|
|
175
|
+
.branch-btn:hover { background: var(--ink-50); }
|
|
176
|
+
.branch-btn.current { background: var(--ink-100); border-color: var(--ink-300); font-weight: 600; }
|
|
177
|
+
.branch-default { color: var(--ink-a40); font-weight: 400; font-size: 11px; margin-left: 6px; }
|
|
178
|
+
.rev-count { display: inline-flex; align-items: center; height: 32px; padding: 0 10px; border: 1px solid var(--ink-200); border-radius: var(--radius); font-size: 12px; color: var(--ink-a55); font-variant-numeric: tabular-nums; }
|
|
179
|
+
.commit-list { border: 1px solid var(--ink-200); border-radius: var(--radius); background: #fff; }
|
|
180
|
+
.commit { display: flex; align-items: center; gap: 12px; padding: 12px 16px; }
|
|
181
|
+
.commit + .commit { border-top: 1px solid var(--ink-100); }
|
|
182
|
+
.rev-seq { flex: none; font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 12px; background: var(--ink-100); color: var(--ink-a50); border-radius: 6px; padding: 2px 8px; font-variant-numeric: tabular-nums; }
|
|
183
|
+
.commit .msg { flex: 1; min-width: 0; font-size: 14px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
184
|
+
.hash-link { flex: none; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; color: var(--ink-a45); }
|
|
185
|
+
.commit .browse { flex: none; font-size: 13px; }
|
|
68
186
|
|
|
69
187
|
/* ── 详情页(向导模式):一次一节点,op 决定呈现 ── */
|
|
70
188
|
/* 内容列=详情页唯一的滚动容器(应用壳布局);gutter 常驻防长文档切换时内容左右微移 */
|
|
@@ -72,15 +190,15 @@ a:hover { text-decoration: underline; }
|
|
|
72
190
|
内容限宽由子元素承担(.nav 是 fixed 定位,排除在限宽外)*/
|
|
73
191
|
.detail { max-width: none; overflow-y: auto; scrollbar-gutter: stable; padding-bottom: 110px; }
|
|
74
192
|
.detail > *:not(.nav) { max-width: 48rem; margin-inline: auto; }
|
|
75
|
-
.node-title { font-size: 22px; font-weight: 700; color: var(--
|
|
193
|
+
.node-title { font-size: 22px; font-weight: 700; color: var(--ink); margin: 8px 0 4px; }
|
|
76
194
|
h2.node-title.child { font-size: 20px; }
|
|
77
|
-
.node-desc { color: var(--
|
|
78
|
-
.op-note { font-size: 13px; color: var(--
|
|
79
|
-
.prose { font-size: 16px; line-height: 1.75; color: var(--
|
|
195
|
+
.node-desc { color: var(--ink-a60); margin: 0 0 12px; }
|
|
196
|
+
.op-note { font-size: 13px; color: var(--ink-a45); font-style: italic; margin: 0 0 8px; }
|
|
197
|
+
.prose { font-size: 16px; line-height: 1.75; color: var(--ink); }
|
|
80
198
|
.prose p { margin: 10px 0; }
|
|
81
199
|
.section-sm .prose p:first-child { margin-top: 0; }
|
|
82
200
|
.section-sm .prose p:last-child { margin-bottom: 0; }
|
|
83
|
-
.prose pre { background: #fff; border: 1px solid var(--border); border-radius:
|
|
201
|
+
.prose pre { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; overflow-x: auto; font-size: 13px; margin: 12px 0; }
|
|
84
202
|
/* 围栏代码块深色卡(detail.js enhanceCodeBlocks 生成,与 hub PopCodeBlock 统一:
|
|
85
203
|
GitHub Dark 底 #0d1117 + 顶栏语言标签/复制按钮);未增强的 pre 仍走上方白底规则 */
|
|
86
204
|
.codeblock { margin: 12px 0; border-radius: 12px; overflow: hidden; background: #0d1117; }
|
|
@@ -114,94 +232,91 @@ h2.node-title.child { font-size: 20px; }
|
|
|
114
232
|
.prose figure.media figcaption { text-align: left; }
|
|
115
233
|
/* 本地 blob 缺字节(/blobs/hash 404)→ 占位卡片(hub MediaMissingCard 同观感:
|
|
116
234
|
附件存在(hash 在手)、字节不在本机——非破图) */
|
|
117
|
-
.media-missing { display: flex; align-items: center; gap: 10px; margin: 10px 0; padding: 8px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--
|
|
118
|
-
.media-missing .mm-icon { width: 16px; height: 16px; flex: none; color: var(--
|
|
119
|
-
.media-missing .mm-title { font-size: 14px; color: var(--
|
|
120
|
-
.media-missing .mm-hash { margin-left: auto; flex: none; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; color: var(--
|
|
121
|
-
.media-missing .mm-badge { flex: none; font-size: 10px; color: var(--
|
|
235
|
+
.media-missing { display: flex; align-items: center; gap: 10px; margin: 10px 0; padding: 8px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--ink-50); user-select: none; }
|
|
236
|
+
.media-missing .mm-icon { width: 16px; height: 16px; flex: none; color: var(--ink-a40); }
|
|
237
|
+
.media-missing .mm-title { font-size: 14px; color: var(--ink-a60); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
238
|
+
.media-missing .mm-hash { margin-left: auto; flex: none; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; color: var(--ink-a40); }
|
|
239
|
+
.media-missing .mm-badge { flex: none; font-size: 10px; color: var(--ink-a50); background: #fff; border: 1px solid var(--border); border-radius: 6px; padding: 2px 6px; }
|
|
122
240
|
/* 缺失子树占位卡(引用的节点文件不在本工作区):media-missing 同视觉语言,复用 mm-* 子样式 */
|
|
123
|
-
.node-missing { display: flex; align-items: center; gap: 10px; margin: 10px 0; padding: 10px 12px; border: 1px dashed var(--border); border-radius: 12px; background: var(--
|
|
124
|
-
.node-missing .mm-icon { width: 16px; height: 16px; flex: none; color: var(--
|
|
125
|
-
.node-missing .mm-title { font-size: 14px; color: var(--
|
|
126
|
-
.node-missing .mm-hash { margin-left: auto; flex: none; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; color: var(--
|
|
127
|
-
.node-missing .nm-num { flex: none; font-size: 13px; color: var(--
|
|
241
|
+
.node-missing { display: flex; align-items: center; gap: 10px; margin: 10px 0; padding: 10px 12px; border: 1px dashed var(--border); border-radius: 12px; background: var(--ink-50); user-select: none; }
|
|
242
|
+
.node-missing .mm-icon { width: 16px; height: 16px; flex: none; color: var(--ink-a40); }
|
|
243
|
+
.node-missing .mm-title { font-size: 14px; color: var(--ink-a60); white-space: nowrap; }
|
|
244
|
+
.node-missing .mm-hash { margin-left: auto; flex: none; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 11px; color: var(--ink-a40); }
|
|
245
|
+
.node-missing .nm-num { flex: none; font-size: 13px; color: var(--ink-a40); font-variant-numeric: tabular-nums; }
|
|
128
246
|
/* 侧栏大纲里的缺失占位项:不可点的弱化条目 */
|
|
129
|
-
.side-item.side-missing { color: var(--
|
|
130
|
-
/* 图注气泡跟随光标(JS
|
|
131
|
-
#media-tip { position: fixed; background: #
|
|
247
|
+
.side-item.side-missing { color: var(--ink-a40); font-style: italic; cursor: default; }
|
|
248
|
+
/* 图注气泡跟随光标(JS 单例浮层)+ 通用悬停气泡:hub Tooltip 深色皮肤(#24292f 白字) */
|
|
249
|
+
#media-tip { position: fixed; background: #24292f; color: #fff; font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; font-size: 12px; line-height: 1.4; padding: 4px 8px; border-radius: 6px; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, .1), 0 2px 4px -2px rgba(0, 0, 0, .1); white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .15s ease; z-index: 110; }
|
|
132
250
|
#media-tip.show { opacity: 1; }
|
|
133
|
-
#lightbox { position: fixed; inset: 0; background: rgba(13, 17, 23, .92); z-index:
|
|
251
|
+
#lightbox { position: fixed; inset: 0; background: rgba(13, 17, 23, .92); z-index: 100; display: flex; flex-direction: column; align-items: center; justify-content: center; user-select: none; cursor: default; }
|
|
134
252
|
#lightbox img { max-width: 92vw; max-height: 84vh; border-radius: 8px; }
|
|
135
253
|
#lightbox .lb-cap { color: #e6edf3; font-size: 14px; margin-top: 12px; text-align: center; max-width: 80vw; }
|
|
136
254
|
#lightbox .lb-count { color: rgba(230, 237, 243, .55); font-size: 12px; margin-top: 4px; font-variant-numeric: tabular-nums; }
|
|
137
255
|
#lightbox .lb-close { position: absolute; top: 16px; right: 16px; border: none; background: none; color: rgba(230, 237, 243, .75); cursor: pointer; padding: 4px; display: flex; }
|
|
138
256
|
#lightbox .lb-close:hover { color: #fff; }
|
|
139
|
-
.prose figcaption { font-size: 12px; color: var(--
|
|
140
|
-
/* markdown 全语法排版(对齐 hub MarkdownView 的 prose
|
|
257
|
+
.prose figcaption { font-size: 12px; color: var(--ink-a45); text-align: center; margin-top: 4px; }
|
|
258
|
+
/* markdown 全语法排版(对齐 hub MarkdownView 的 prose 观感):标题正黑、链接 primary
|
|
141
259
|
无下划线 hover 下划线、行内 code 浅底胶囊、块内 code 交还 pre 默认、blockquote 弱化竖线、
|
|
142
|
-
列表 marker
|
|
143
|
-
.prose h3, .prose h4, .prose h5, .prose h6 { color: var(--
|
|
260
|
+
列表 marker 淡墨、表格细线表头浅底、hr 淡线 */
|
|
261
|
+
.prose h3, .prose h4, .prose h5, .prose h6 { color: var(--ink); font-weight: 600; line-height: 1.35; margin: 20px 0 8px; }
|
|
144
262
|
.prose h3 { font-size: 17px; }
|
|
145
263
|
.prose h4 { font-size: 16px; }
|
|
146
264
|
.prose h5, .prose h6 { font-size: 15px; }
|
|
147
265
|
.prose h3:first-child, .prose h4:first-child { margin-top: 0; }
|
|
148
266
|
.prose ul, .prose ol { margin: 10px 0; padding-left: 22px; }
|
|
149
267
|
.prose li { margin: 3px 0; }
|
|
150
|
-
.prose li::marker { color: var(--
|
|
151
|
-
.prose strong { color: var(--
|
|
268
|
+
.prose li::marker { color: var(--ink-a35); }
|
|
269
|
+
.prose strong { color: var(--ink); }
|
|
152
270
|
.prose a { color: var(--primary); text-decoration: none; }
|
|
153
271
|
.prose a:hover { text-decoration: underline; }
|
|
154
272
|
.prose code { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: .85em; background: #f8fafc; border: 1px solid rgba(226, 232, 240, .8); border-radius: 4px; padding: 1px 5px; }
|
|
155
273
|
.prose pre code { background: transparent; border: none; padding: 0; font-size: inherit; }
|
|
156
|
-
.prose blockquote { margin: 12px 0; padding: 2px 0 2px 14px; border-left: 3px solid var(--
|
|
274
|
+
.prose blockquote { margin: 12px 0; padding: 2px 0 2px 14px; border-left: 3px solid var(--ink-300); color: var(--ink-a60); }
|
|
157
275
|
.prose blockquote p { margin: 6px 0; }
|
|
158
276
|
.prose table { border-collapse: collapse; margin: 12px 0; font-size: 14px; }
|
|
159
277
|
.prose th, .prose td { border: 1px solid var(--border); padding: 6px 12px; text-align: left; }
|
|
160
|
-
.prose th { background:
|
|
278
|
+
.prose th { background: var(--ink-50); font-weight: 600; }
|
|
161
279
|
.prose hr { border: none; border-top: 1px solid var(--border); margin: 20px 0; }
|
|
162
280
|
/* action 管道读序:inputs → 正文 → outputs,各占一块有序列表;io 条目与正文同字体同字号 */
|
|
163
|
-
ol.io-list { margin: 0; padding-left: 24px; font-size: 16px; line-height: 1.75; color: var(--
|
|
281
|
+
ol.io-list { margin: 0; padding-left: 24px; font-size: 16px; line-height: 1.75; color: var(--ink); }
|
|
164
282
|
ol.io-list li { padding: 2px 0; }
|
|
165
283
|
/* spec 独立成行放在名字下方(弃括号内联),小一号弱化 */
|
|
166
|
-
.io-spec { display: block; font-size: 13px; line-height: 1.5; color: var(--
|
|
167
|
-
.io-from, .att-meta { color: var(--
|
|
284
|
+
.io-spec { display: block; font-size: 13px; line-height: 1.5; color: var(--ink-a45); }
|
|
285
|
+
.io-from, .att-meta { color: var(--ink-a35); font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 12px; }
|
|
168
286
|
/* from 反解命中的 #编号引用:小号等宽+点状下划线提示可悬停(title=来源节点名) */
|
|
169
|
-
/*
|
|
287
|
+
/* 通用悬停气泡(hub Tooltip.tsx 深色皮肤):#24292f 白字圆角,hover .5s 延迟出现 */
|
|
170
288
|
[data-tip] { position: relative; }
|
|
171
|
-
[data-tip]::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); background: #
|
|
289
|
+
[data-tip]::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%); background: #24292f; color: #fff; font-family: system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif; font-size: 12px; line-height: 1.4; padding: 4px 8px; border-radius: 6px; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, .1), 0 2px 4px -2px rgba(0, 0, 0, .1); white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .15s ease .5s; z-index: 20; }
|
|
172
290
|
[data-tip]:hover::after { opacity: 1; }
|
|
173
291
|
/* 侧栏 tab 的气泡朝下翻:tab 贴侧栏顶,朝上会被 .side 的 overflow-y:auto 裁剪
|
|
174
292
|
(absolute 元素出不了滚动容器,非 z-index 问题),朝下空间无限不受裁 */
|
|
175
293
|
.side-tab[data-tip]::after { bottom: auto; top: calc(100% + 6px); }
|
|
176
294
|
/* from 反解命中的 #编号引用:可点跳转(data-path 委托) */
|
|
177
|
-
.io-ref { color: var(--
|
|
178
|
-
.io-ref:hover { color: var(--
|
|
295
|
+
.io-ref { color: var(--ink-a50); font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 13px; cursor: pointer; border-bottom: 1px dotted var(--ink-a30); text-decoration: none; }
|
|
296
|
+
.io-ref:hover { color: var(--ink); text-decoration: none; }
|
|
179
297
|
.section-sm { margin-top: 18px; }
|
|
180
|
-
.section-sm .label { font-size: 12px; font-weight: 600; color: var(--
|
|
298
|
+
.section-sm .label { font-size: 12px; font-weight: 600; color: var(--ink-a55); margin-bottom: 6px; }
|
|
181
299
|
/* JSON 视图 label 行:label 居左 + 复制按钮居右(按钮复用 .codeblock-copy 深色样式,在浅底上取中性色) */
|
|
182
300
|
.label-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
|
|
183
301
|
.label-row .label { margin-bottom: 0; }
|
|
184
|
-
.label-row .json-copy { color: var(--
|
|
185
|
-
.label-row .json-copy:hover { color: var(--
|
|
186
|
-
.child-card { display: block; border: 1px solid var(--border); border-radius:
|
|
302
|
+
.label-row .json-copy { color: var(--ink-a40); }
|
|
303
|
+
.label-row .json-copy:hover { color: var(--ink); background: rgba(17, 17, 17, .06); }
|
|
304
|
+
.child-card { display: block; border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 14px; margin-bottom: 8px; font-size: 14px; color: var(--ink-a65); background: #fff; transition: border-color .15s, color .15s, background .15s; }
|
|
187
305
|
button.child-card { width: 100%; text-align: left; cursor: pointer; font: inherit; }
|
|
188
|
-
button.child-card:hover { border-color: var(--
|
|
189
|
-
.child-desc { font-size: 12px; color: var(--
|
|
190
|
-
/*
|
|
191
|
-
.choice-card { display: flex; align-items: center; width: 100%; text-align: left; border: 1px solid var(--border); border-radius:
|
|
192
|
-
.choice-card:hover { border-color: var(--
|
|
306
|
+
button.child-card:hover { border-color: var(--ink-400); color: var(--ink); }
|
|
307
|
+
.child-desc { font-size: 12px; color: var(--ink-a45); margin-top: 2px; display: block; }
|
|
308
|
+
/* 选项卡:无字母圈,内容竖直居中;选项名=正黑,描述回落全局 child-desc 浅色 */
|
|
309
|
+
.choice-card { display: flex; align-items: center; width: 100%; text-align: left; border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 16px; margin-bottom: 8px; background: #fff; cursor: pointer; font: inherit; color: var(--ink); transition: border-color .15s, background .15s; }
|
|
310
|
+
.choice-card:hover { border-color: var(--ink-400); background: var(--ink-50); }
|
|
193
311
|
/* 底部导航固定在视口底部:位置恒定,不随内容高度漂移;内行与正文列同宽对齐 */
|
|
194
312
|
/* 底部操作区:固定视口底悬浮于内容列上方,无分界线(仅极轻投影托起),行与正文列同宽 */
|
|
195
|
-
.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; background: #fff; padding: 10px 24px; box-shadow: 0 -1px 8px rgba(0,
|
|
313
|
+
.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 10; background: #fff; padding: 10px 24px; box-shadow: 0 -1px 8px rgba(0, 0, 0, .03); transition: right .25s ease; }
|
|
196
314
|
/* 笔记栏展开时操作区同步让位(与内容列居中一起平滑重排) */
|
|
197
315
|
body.note-open .nav { right: 18rem; }
|
|
198
316
|
.nav-row { max-width: 48rem; margin: 0 auto; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
|
|
199
|
-
.btn {
|
|
200
|
-
.
|
|
201
|
-
.
|
|
202
|
-
.btn-primary:hover { background: #1f2937; }
|
|
203
|
-
.nav-hint { font-size: 13px; color: var(--brand-40); }
|
|
204
|
-
.finish { font-size: 13px; color: var(--brand-40); }
|
|
317
|
+
.nav .btn { height: 34px; padding: 0 14px; }
|
|
318
|
+
.nav-hint { font-size: 13px; color: var(--ink-a45); }
|
|
319
|
+
.finish { font-size: 13px; color: var(--ink-a45); }
|
|
205
320
|
/* ── 详情页外壳:应用壳布局——整页不滚(滚动只属于中间内容列),header 常驻、左右栏满高 ── */
|
|
206
321
|
body.detail-page { height: 100dvh; overflow: hidden; display: flex; flex-direction: column; }
|
|
207
322
|
body.detail-page > header { flex: none; }
|
|
@@ -210,15 +325,13 @@ body.detail-page > header { flex: none; }
|
|
|
210
325
|
(面板展开时同理——轨在 main 与面板之间) */
|
|
211
326
|
.shell main { flex: 1; min-width: 0; margin-right: 26px; }
|
|
212
327
|
.side { display: none; }
|
|
213
|
-
.side-count { font-size: 12px; font-weight: 500; color: var(--
|
|
214
|
-
.side-item { display: block; border-radius: 6px; padding: 6px 10px; font-size: 13px; line-height: 1.45; color: var(--
|
|
215
|
-
.side-item:hover { color: var(--
|
|
216
|
-
.side-item.on { background: rgba(
|
|
217
|
-
.side-num { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 11px; color: var(--
|
|
218
|
-
.side-item.on .side-num { color: var(--
|
|
219
|
-
.side-root { font-weight: 600; color: var(--
|
|
220
|
-
/* 档案底仓:钉在侧栏最底(flex 末位),大纲长过侧栏时随滚动自然跟在内容后 */
|
|
221
|
-
.side-foot { margin-top: auto; padding-top: 4px; }
|
|
328
|
+
.side-count { font-size: 12px; font-weight: 500; color: var(--ink-a45); margin: 0 0 8px; }
|
|
329
|
+
.side-item { display: block; border-radius: 6px; padding: 6px 10px; font-size: 13px; line-height: 1.45; color: var(--ink-a60); }
|
|
330
|
+
.side-item:hover { color: var(--ink); text-decoration: none; background: rgba(17, 17, 17, .05); }
|
|
331
|
+
.side-item.on { background: rgba(17, 17, 17, .08); color: var(--ink); font-weight: 500; }
|
|
332
|
+
.side-num { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 11px; color: var(--ink-a35); margin-right: 6px; }
|
|
333
|
+
.side-item.on .side-num { color: var(--ink-a50); }
|
|
334
|
+
.side-root { font-weight: 600; color: var(--ink-a60); margin-bottom: 4px; }
|
|
222
335
|
@media (min-width: 1024px) {
|
|
223
336
|
.side { display: flex; flex-direction: column; overflow-y: auto; width: 16rem; flex: none; border-right: 1px solid var(--border); background: #f8fafc; padding: 12px 14px 24px; }
|
|
224
337
|
/* 操作区只覆盖内容列:left 让出侧栏,侧栏档案区完整可见 */
|
|
@@ -227,96 +340,94 @@ body.detail-page > header { flex: none; }
|
|
|
227
340
|
/* 视图三 tab(侧栏最顶):向导正文 / StandardView / document,切换内容区形态。
|
|
228
341
|
共用一枚胶囊:容器持边框与圆角,tab 自身无边框,选中以胶囊内填充块呈现 */
|
|
229
342
|
.side-tabs { display: flex; gap: 2px; margin-bottom: 12px; padding: 3px; border: 1px solid var(--border); border-radius: 999px; background: #fff; }
|
|
230
|
-
.side-tab { flex: 1; border: none; border-radius: 999px; background: transparent; color: var(--
|
|
343
|
+
.side-tab { flex: 1; border: none; border-radius: 999px; background: transparent; color: var(--ink-a40); font: inherit; font-size: 12px; padding: 4px 0; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
|
|
231
344
|
.side-tab svg { width: 16px; height: 16px; }
|
|
232
|
-
.side-tab:hover { color: var(--
|
|
233
|
-
.side-tab.on { background: rgba(
|
|
234
|
-
/* JSON 视图:pretty 渲染,当前节点/其子树 steps
|
|
235
|
-
.json-pre { margin: 0; padding: 12px 14px; border: 1px solid var(--border); border-radius:
|
|
236
|
-
.json-pre .jk { color: var(--
|
|
345
|
+
.side-tab:hover { color: var(--ink); }
|
|
346
|
+
.side-tab.on { background: rgba(17, 17, 17, .08); color: var(--ink); font-weight: 500; }
|
|
347
|
+
/* JSON 视图:pretty 渲染,当前节点/其子树 steps 命中行整行铺浅墨底(编辑器选中行形态) */
|
|
348
|
+
.json-pre { margin: 0; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 13px; line-height: 1.6; color: var(--ink); overflow: auto; white-space: pre; max-height: calc(100dvh - 260px); }
|
|
349
|
+
.json-pre .jk { color: var(--ink-a60); }
|
|
237
350
|
/* 行级块:短行铺满可视宽、长行铺到内容末尾,高亮行首尾与缩进、逗号全部入色带 */
|
|
238
351
|
.json-pre .ln { display: block; width: max-content; min-width: 100%; }
|
|
239
|
-
.json-pre .ln.hl { background: rgba(
|
|
352
|
+
.json-pre .ln.hl { background: rgba(17, 24, 39, .07); scroll-margin-top: 64px; }
|
|
240
353
|
/* 学习笔记:只住右侧笔记栏(内容区不出现);note-time 由右栏条目复用 */
|
|
241
|
-
.note-time { display: block; font-size: 12px; color: var(--
|
|
354
|
+
.note-time { display: block; font-size: 12px; color: var(--ink-a40); font-variant-numeric: tabular-nums; margin-bottom: 2px; }
|
|
242
355
|
/* 侧栏大纲的笔记数徽标:实心、可点(跳到该节点并展开笔记栏),
|
|
243
356
|
边框/文字继承所在条目的颜色(currentColor)——普通态/选中态/根标题自动同色 */
|
|
244
|
-
.note-badge { display: inline-block; min-width: 14px; height: 13px; line-height: 13px; padding: 0 4px; border-radius: 999px; background: var(--primary); color: #
|
|
245
|
-
.note-badge:hover { background:
|
|
357
|
+
.note-badge { display: inline-block; min-width: 14px; height: 13px; line-height: 13px; padding: 0 4px; border-radius: 999px; background: var(--primary); color: #fff; font-size: 9px; font-weight: 600; text-align: center; margin-left: 5px; vertical-align: middle; cursor: pointer; }
|
|
358
|
+
.note-badge:hover { background: var(--ink-700); }
|
|
246
359
|
|
|
247
360
|
/* ── 右侧笔记栏:布局列(非悬浮)——宽度 0↔18rem 平滑过渡,内容列随之在两栏之间保持居中 ── */
|
|
248
361
|
#note-side { flex: none; width: 0; overflow: hidden; align-self: stretch; transition: width .25s ease; }
|
|
249
362
|
#note-side.open { width: 18rem; }
|
|
250
363
|
/* 内层定宽:动画期间内容不被挤压,从右缘逐步露出(抽屉观感);边框/投影挂内层,
|
|
251
364
|
收起宽度 0 时被 overflow 裁掉,不留残线 */
|
|
252
|
-
#note-list { width: 18rem; height: 100%; overflow-y: auto; overflow-x: hidden; display: flex; flex-direction: column; background: #f8fafc; border-left: 1px solid var(--border); box-shadow: 0 0 24px rgba(0,
|
|
365
|
+
#note-list { width: 18rem; height: 100%; overflow-y: auto; overflow-x: hidden; display: flex; flex-direction: column; background: #f8fafc; border-left: 1px solid var(--border); box-shadow: 0 0 24px rgba(0, 0, 0, .05); padding: 14px 14px 16px; }
|
|
253
366
|
/* 展开收起舌片:钉在面板左缘垂直居中(面板的相邻兄弟,right 与面板宽度同参数过渡即贴合);
|
|
254
367
|
收起后停在屏幕右缘仍可点 */
|
|
255
|
-
#note-toggle { position: absolute; right: 0; top: 50%; transform: translateY(-50%); width: 26px; height: 56px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--border); border-right: none; border-radius: 8px 0 0 8px; background: #f8fafc; color: var(--
|
|
368
|
+
#note-toggle { position: absolute; right: 0; top: 50%; transform: translateY(-50%); width: 26px; height: 56px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--border); border-right: none; border-radius: 8px 0 0 8px; background: #f8fafc; color: var(--ink-a40); cursor: pointer; z-index: 5; transition: right .25s ease; }
|
|
256
369
|
#note-side.open + #note-toggle { right: 18rem; }
|
|
257
|
-
#note-toggle:hover { color: var(--
|
|
370
|
+
#note-toggle:hover { color: var(--ink); }
|
|
258
371
|
/* 箭头语义=面板去向:收起态朝左(展开=面板从右缘向左滑出),展开态朝右(收起=向右滑走) */
|
|
259
372
|
#note-toggle svg { width: 14px; height: 14px; transition: transform .25s ease; transform: rotate(180deg); }
|
|
260
373
|
#note-side.open + #note-toggle svg { transform: rotate(0deg); }
|
|
261
374
|
.nside-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
|
|
262
|
-
.nside-title { margin: 0; font-size: 12px; font-weight: 600; color: var(--
|
|
375
|
+
.nside-title { margin: 0; font-size: 12px; font-weight: 600; color: var(--ink-a55); }
|
|
263
376
|
/* 新建按钮:面板头部的小胶囊 */
|
|
264
|
-
.nside-new { flex: none; display: inline-flex; align-items: center; justify-content: center; border: none; background: transparent; color: var(--
|
|
377
|
+
.nside-new { flex: none; display: inline-flex; align-items: center; justify-content: center; border: none; background: transparent; color: var(--ink-a40); cursor: pointer; padding: 2px; }
|
|
265
378
|
.nside-new svg { width: 12px; height: 12px; }
|
|
266
|
-
.nside-new:hover { color: var(--
|
|
379
|
+
.nside-new:hover { color: var(--ink); }
|
|
267
380
|
/* 头部贴面板顶+右缘:气泡朝下开、右缘对齐,避免被 #note-list 的 overflow 裁掉 */
|
|
268
381
|
.nside-new[data-tip]::after { left: auto; right: 0; bottom: auto; top: calc(100% + 6px); transform: none; }
|
|
269
|
-
.nside-empty { font-size: 12px; line-height: 1.6; color: var(--
|
|
270
|
-
.nside-err { font-size: 12px; line-height: 1.5; color:
|
|
271
|
-
.nside-item { background: #fff; border: 1px solid var(--border); border-radius:
|
|
382
|
+
.nside-empty { font-size: 12px; line-height: 1.6; color: var(--ink-a45); margin: 0 0 10px; }
|
|
383
|
+
.nside-err { font-size: 12px; line-height: 1.5; color: var(--danger-700); background: var(--danger-50); border: 1px solid var(--danger-200); border-radius: var(--radius); padding: 6px 10px; margin: 0 0 10px; overflow-wrap: break-word; }
|
|
384
|
+
.nside-item { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 10px; margin-bottom: 8px; }
|
|
272
385
|
.nside-meta { display: flex; align-items: center; justify-content: space-between; gap: 6px; margin-bottom: 3px; }
|
|
273
386
|
.nside-acts { display: inline-flex; gap: 2px; }
|
|
274
|
-
.nside-act { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border: none; border-radius: 6px; background: transparent; color: var(--
|
|
387
|
+
.nside-act { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border: none; border-radius: 6px; background: transparent; color: var(--ink-a35); cursor: pointer; }
|
|
275
388
|
.nside-act svg { width: 13px; height: 13px; }
|
|
276
|
-
.nside-act:hover { background: var(--
|
|
389
|
+
.nside-act:hover { background: var(--ink-100); color: var(--ink); }
|
|
277
390
|
.nside-item .note-time { font-size: 11px; }
|
|
278
391
|
/* 行内编辑态与底部新增框共用输入框形态 */
|
|
279
|
-
.nside-input { display: block; width: 100%; border: none; background: transparent; resize: none; overflow: hidden; padding: 0; margin: 0; color: var(--
|
|
392
|
+
.nside-input { display: block; width: 100%; border: none; background: transparent; resize: none; overflow: hidden; padding: 0; margin: 0; color: var(--ink-a65); font-family: inherit; font-size: 13px; line-height: 1.6; cursor: default; caret-color: transparent; transition: color .15s ease; }
|
|
280
393
|
/* 支持 field-sizing 的浏览器:输入框只占文字本身宽度——点卡片空白处不会出现光标,
|
|
281
394
|
点文字才进编辑且光标落在点击处;autoGrow 在 JS 侧对支持的浏览器跳过 */
|
|
282
395
|
@supports (field-sizing: content) {
|
|
283
396
|
.nside-input { field-sizing: content; width: auto; min-width: 24px; max-width: 100%; min-height: 0; }
|
|
284
397
|
}
|
|
285
|
-
.nside-input:focus { outline: none; cursor: text; caret-color: auto; color: var(--
|
|
286
|
-
|
|
287
|
-
/* LR kick */
|
|
398
|
+
.nside-input:focus { outline: none; cursor: text; caret-color: auto; color: var(--ink); }
|
|
288
399
|
|
|
289
|
-
/* 复制 toast
|
|
290
|
-
|
|
291
|
-
.web-toast { position: fixed;
|
|
292
|
-
.web-toast.show { opacity: 1; transform:
|
|
400
|
+
/* 复制 toast:hub sonner(richColors, position=bottom-right)同位同观感——
|
|
401
|
+
白底细边浅投影、绿色对勾圆标居左,右下角上滑淡入 */
|
|
402
|
+
.web-toast { position: fixed; right: 16px; bottom: 16px; background: #fff; color: #1f2937; font-size: 13px; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: 0 4px 12px rgba(0, 0, 0, .08); display: flex; align-items: center; gap: 8px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .2s, transform .2s; z-index: 110; }
|
|
403
|
+
.web-toast.show { opacity: 1; transform: translateY(0); }
|
|
293
404
|
|
|
294
405
|
/* ── 内容列顶栏(hub 同款):返回居左、Info 居右;.detail > * 规则天然把它限宽居中 ── */
|
|
295
406
|
.detail-topbar { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 18px; }
|
|
296
|
-
.topbar-btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid
|
|
297
|
-
.topbar-btn:hover { color: var(--
|
|
407
|
+
.topbar-btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--ink-200); background: #fff; color: var(--ink-a60); border-radius: var(--radius); height: 32px; padding: 0 12px; font-size: 12px; font-weight: 500; font-family: inherit; cursor: pointer; text-decoration: none; transition: color .15s, border-color .15s, background .15s; }
|
|
408
|
+
.topbar-btn:hover { color: var(--ink); border-color: var(--ink-300); background: var(--ink-50); text-decoration: none; }
|
|
298
409
|
.topbar-icon { width: 32px; padding: 0; justify-content: center; }
|
|
299
|
-
/*
|
|
300
|
-
#info-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .4); z-index:
|
|
301
|
-
.info-card { width: 320px; max-width: calc(100vw - 32px); background: #fff; border-radius:
|
|
410
|
+
/* 文档信息/附件弹窗(hub AppDialog 同观感:白卡 16px 圆角、居中、遮罩;hub 浮层规则=模态统一 z-100) */
|
|
411
|
+
#info-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .4); z-index: 100; display: flex; align-items: center; justify-content: center; }
|
|
412
|
+
.info-card { width: 320px; max-width: calc(100vw - 32px); background: #fff; border-radius: 16px; box-shadow: 0 20px 25px -5px rgba(0, 0, 0, .1), 0 8px 10px -6px rgba(0, 0, 0, .1); padding: 24px; }
|
|
302
413
|
.info-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
|
|
303
|
-
.info-title { font-size:
|
|
304
|
-
.info-close { border: none; background: none; color: var(--
|
|
305
|
-
.info-close:hover { color: var(--
|
|
414
|
+
.info-title { font-size: 16px; font-weight: 600; color: var(--ink); }
|
|
415
|
+
.info-close { border: none; background: none; color: var(--ink-a45); cursor: pointer; padding: 2px; display: flex; }
|
|
416
|
+
.info-close:hover { color: var(--ink); }
|
|
306
417
|
/* 附件弹窗:与 Info 弹窗同皮肤,固定尺寸(内容少不缩水)、列表内滚 */
|
|
307
|
-
#att-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .4); z-index:
|
|
418
|
+
#att-overlay { position: fixed; inset: 0; background: rgba(0, 0, 0, .4); z-index: 100; display: flex; align-items: center; justify-content: center; }
|
|
308
419
|
.att-card { width: 380px; height: 400px; display: flex; flex-direction: column; }
|
|
309
420
|
.att-scroll { flex: 1; min-height: 0; overflow-y: auto; }
|
|
310
|
-
.att-row { padding: 8px 0; border-bottom: 1px solid
|
|
421
|
+
.att-row { padding: 8px 0; border-bottom: 1px solid var(--ink-100); font-size: 13px; }
|
|
311
422
|
.att-row:last-child { border-bottom: none; }
|
|
312
423
|
.att-row a { color: var(--primary); text-decoration: none; font-weight: 500; }
|
|
313
424
|
.att-row a:hover { text-decoration: underline; }
|
|
314
|
-
.att-row .att-meta { display: block; font-size: 11px; color: var(--
|
|
425
|
+
.att-row .att-meta { display: block; font-size: 11px; color: var(--ink-a45); margin-top: 2px; font-family: ui-monospace, "Cascadia Code", Consolas, monospace; }
|
|
315
426
|
.topbar-right { display: flex; align-items: center; gap: 8px; }
|
|
316
|
-
.info-row { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 13px; color: var(--
|
|
317
|
-
.info-row .info-key { color: var(--
|
|
427
|
+
.info-row { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; font-size: 13px; color: var(--ink); }
|
|
428
|
+
.info-row .info-key { color: var(--ink-a60); }
|
|
318
429
|
/* 哈希整行按钮(hub InfoDialog 同款):指纹图标+等宽哈希+复制图标,hover 沉到全色 */
|
|
319
|
-
.info-hash-btn { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; border: 1px solid
|
|
320
|
-
.info-hash-btn:hover { color: var(--
|
|
430
|
+
.info-hash-btn { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; border: 1px solid var(--ink-200); background: #fff; border-radius: var(--radius); padding: 8px 10px; font-family: ui-monospace, "Cascadia Code", Consolas, monospace; font-size: 12px; color: var(--ink-a60); cursor: pointer; transition: color .15s, border-color .15s; }
|
|
431
|
+
.info-hash-btn:hover { color: var(--ink); border-color: var(--ink-300); }
|
|
321
432
|
.info-hash-btn .info-hash { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
|
|
322
433
|
.info-hash-btn svg:last-child { opacity: .4; flex-shrink: 0; }
|