-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathstyle.css
More file actions
162 lines (142 loc) · 3.97 KB
/
Copy pathstyle.css
File metadata and controls
162 lines (142 loc) · 3.97 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
/* SToolBook - 工具函数编辑器样式 */
/* ---- 面板整体(直接在 .inline-drawer 内部,与 .inline-drawer-content 平级)---- */
.stoolbook_panel {
width: 100%;
padding: 5px 0;
border-top: 1px solid var(--SmartThemeBorderColor, #555);
}
/* ---- 工具栏:左右布局 ---- */
.stoolbook_toolbar {
display: flex;
justify-content: space-between;
align-items: center;
padding: 4px 0;
margin-bottom: 4px;
}
/* ---- 开关标签 ---- */
.stoolbook_toggle_label {
display: flex;
align-items: center;
gap: 5px;
cursor: pointer;
user-select: none;
}
.stoolbook_toggle {
width: 16px;
height: 16px;
cursor: pointer;
accent-color: var(--SmartThemeQuoteColor, #5bc0de);
}
/* ---- 保存按钮 ---- */
.stoolbook_save_btn {
display: flex;
align-items: center;
gap: 4px;
font-size: calc(var(--mainFontSize, 14px) * 0.9);
padding: 2px 8px;
}
/* ---- 代码编辑器 textarea ---- */
.stoolbook_code_editor {
width: 100%;
min-height: 120px;
max-height: 500px;
resize: vertical;
font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
font-size: calc(var(--mainFontSize, 14px) * 0.9);
line-height: 1.5;
tab-size: 4;
white-space: pre;
overflow-wrap: normal;
overflow-x: auto;
}
/* ============================================================
回合合并 —— Turn Merging(内嵌在 display_text 中的样式)
============================================================ */
/* 内联工具调用摘要(折叠态)
DOMPurify 的 MESSAGE_SANITIZE 会把 class 加 custom- 前缀,
所以每条规则需同时匹配原始和 custom- 版本 */
.stoolbook-tool-summary,
.custom-stoolbook-tool-summary {
margin: 0.6em 0;
padding: 6px 10px;
border-left: 3px solid var(--SmartThemeQuoteColor, #5bc0de);
background: var(--SmartThemeBlurTintColor, rgba(0, 0, 0, 0.1));
border-radius: 4px;
font-size: calc(var(--mainFontSize, 14px) * 0.9);
}
.stoolbook-tool-summary > summary,
.custom-stoolbook-tool-summary > summary {
cursor: pointer;
user-select: none;
padding: 2px 0;
color: var(--SmartThemeQuoteColor, #5bc0de);
font-weight: 500;
display: flex;
align-items: center;
gap: 6px;
list-style: none;
}
.stoolbook-tool-summary > summary::-webkit-details-marker,
.custom-stoolbook-tool-summary > summary::-webkit-details-marker {
display: none;
}
.stoolbook-tool-summary > summary::before,
.custom-stoolbook-tool-summary > summary::before {
content: '▸';
font-size: 0.85em;
transition: transform 0.15s ease;
}
.stoolbook-tool-summary[open] > summary::before,
.custom-stoolbook-tool-summary[open] > summary::before {
transform: rotate(90deg);
}
.stoolbook-tool-summary > summary i,
.custom-stoolbook-tool-summary > summary i {
font-size: 0.85em;
opacity: 0.8;
}
/* 工具详情区 */
.stoolbook-tool-details,
.custom-stoolbook-tool-details {
padding: 4px 0;
}
.stoolbook-tool-label,
.custom-stoolbook-tool-label {
font-size: calc(var(--mainFontSize, 14px) * 0.8);
font-weight: 600;
opacity: 0.7;
margin: 6px 0 2px;
text-transform: uppercase;
letter-spacing: 0.03em;
}
.stoolbook-tool-invocation pre,
.custom-stoolbook-tool-invocation pre {
margin: 2px 0 6px;
padding: 6px 8px;
background: var(--SmartThemeCodeColor, rgba(0, 0, 0, 0.15));
border-radius: 3px;
overflow-x: auto;
max-height: 200px;
overflow-y: auto;
}
.stoolbook-tool-invocation code,
.custom-stoolbook-tool-invocation code {
font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
font-size: calc(var(--mainFontSize, 14px) * 0.85);
white-space: pre;
}
/* 设置面板补充 */
.stoolbook_settings .checkbox_label {
display: flex;
align-items: center;
gap: 8px;
cursor: pointer;
}
/* seamless 开启时子选项灰化 */
.stoolbook_sub_option.stoolbook_disabled {
opacity: 0.4;
pointer-events: none;
}
.stoolbook_sub_option {
margin-left: 16px;
}