JsonFormatter.less
3.19 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
163
164
165
.jsonMain{
}
.jsonFormatterContainer {
display: flex;
width: 100%;
border: 1px solid #e8e8e8;
border-radius: 4px;
overflow: hidden;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.jsonPanel {
width: 30%;
padding: 20px;
background-color: #f9f9f9;
font-size: 13px;
max-height: 600px;
overflow: hidden;
}
.jsonPanel2 {
width: 60%;
padding: 20px;
background-color: #f9f9f9;
font-size: 13px;
max-height: 600px;
overflow: auto;
}
.jsonPanel3 {
width: 30%;
padding: 20px;
background-color: #f9f9f9;
font-size: 13px;
max-height: 600px;
overflow: auto;
box-sizing: border-box;
display: flex;
flex-direction: column;
position: relative;
}
.jsonPanel h3,
.jsonPanel2 h3,
.jsonPanel3 h3 {
margin-top: 0;
margin-bottom: 10px;
color: #333;
}
.jsonPanel2 pre {
width: 100%;
margin: 0;
background-color: #fff;
padding: 10px;
border: 1px solid #e8e8e8;
border-radius: 4px;
overflow: auto;
}
.divider {
width: 1px;
background-color: #e8e8e8;
}
.jsonTextarea {
min-height: 520px; /* 设置最小高度为 6 行,假设每行约 20px */
width: 100%;
height: fit-content;
padding: 10px;
border: 1px solid #e8e8e8;
border-radius: 4px;
resize: vertical;
font-family: 'Courier New', Courier, monospace;
font-size: 14px;
}
.btnStyle{
padding: 10px;
display: flex;
justify-content: right;
}
.btnStyle button {
margin-right: 20px;
}
.answerContainer,
.formattedJson {
border: 2px solid #ccc; /* 初始灰色边框 */
border-radius: 4px;
box-shadow: 0 0 0 rgba(0, 0, 0, 0); /* 初始无阴影 */
padding: 10px;
margin-bottom: 20px;
min-height: 300px;
transition: all 0.3s ease; /* 过渡效果 */
}
.answerContainer:hover,
.formattedJson:hover {
border-color: #007BFF; /* 悬浮时彩色边框 */
box-shadow: 0 0 10px rgba(0, 123, 255, 0.5); /* 悬浮时阴影效果 */
}
.questionBox {
display: flex;
justify-content: center;
align-items: center;
width: 100%;
position: absolute;
bottom: 10px;
//width: calc(100% - 40px); /* 减去左右内边距 */
padding: 20px;
background-color: #f9f9f9;
box-sizing: border-box;
}
.questionInput {
width: calc(100% - 20px);
padding: 8px;
margin-right: 10px;
border: 1px solid #e8e8e8;
border-radius: 14px;
box-sizing: border-box;
resize: none; /* 禁止调整大小 */
}
.answerText {
margin: 0;
color: #333;
}
// ... 原有样式 ...
.historyIcon {
position: absolute;
top: 50%;
right: 10px;
transform: translateY(-50%);
font-size: 20px;
cursor: pointer;
}
.qaHistoryItem {
margin-bottom: 15px; /* 增加项与项之间的间距 */
}
.qaQuestion {
background-color: #e6f7ff; /* 问题背景颜色 */
border-radius: 8px; /* 圆角边框 */
padding: 10px; /* 内边距 */
margin-bottom: 8px; /* 与回复之间的间距 */
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* 轻微阴影 */
font-weight: bold;
}
.qaAnswer {
background-color: #f6ffed; /* 回复背景颜色 */
border-radius: 8px; /* 圆角边框 */
padding: 10px; /* 内边距 */
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); /* 轻微阴影 */
color: #666;
}
.qaHistoryContainer {
max-height: 300px; /* 设置最大高度 */
overflow-y: auto; /* 超出高度时显示滚动条 */
}