Update app.css
Browse files
app.css
CHANGED
@@ -64,36 +64,26 @@ body {
|
|
64 |
|
65 |
.right_panel {
|
66 |
position: relative;
|
67 |
-
height:
|
68 |
-
min-height: 400px;
|
69 |
-
max-height: 800px;
|
70 |
-
resize: vertical;
|
71 |
-
overflow: hidden;
|
72 |
-
margin: 20px;
|
73 |
-
border-radius: 12px;
|
74 |
-
box-shadow: 0 4px 12px rgba(0,0,0,0.1);
|
75 |
display: flex;
|
76 |
flex-direction: column;
|
77 |
}
|
78 |
|
79 |
-
/* μμ λ HTML μ½ν
μΈ μμ */
|
80 |
.html_content {
|
81 |
-
flex: 1;
|
82 |
display: flex;
|
83 |
flex-direction: column;
|
84 |
-
|
85 |
-
overflow: hidden;
|
86 |
}
|
87 |
|
88 |
-
/* μμ λ iframe μ€νμΌ */
|
89 |
.html_content iframe {
|
90 |
-
flex: 1;
|
91 |
width: 100%;
|
|
|
92 |
border: none;
|
93 |
display: block;
|
94 |
}
|
95 |
|
96 |
-
|
97 |
/* iframe λ΄λΆ μ€νμΌμ μν μΆκ° */
|
98 |
.html_content iframe html,
|
99 |
.html_content iframe body {
|
@@ -104,7 +94,6 @@ body {
|
|
104 |
overflow: auto;
|
105 |
}
|
106 |
|
107 |
-
/* μμ λ λ λλ§ ν€λ */
|
108 |
.render_header {
|
109 |
height: 30px;
|
110 |
background: var(--neutral-100);
|
@@ -134,15 +123,14 @@ body {
|
|
134 |
background-color: var(--success);
|
135 |
}
|
136 |
|
137 |
-
/* μ€νλμ λΉ μν νμλ₯Ό μ€μμ λ°°μΉ */
|
138 |
.right_content {
|
139 |
-
|
140 |
display: flex;
|
141 |
justify-content: center;
|
142 |
align-items: center;
|
143 |
background: var(--surface);
|
144 |
}
|
145 |
-
|
146 |
.ant-tabs-content {
|
147 |
height: 100%;
|
148 |
display: flex;
|
@@ -155,27 +143,348 @@ body {
|
|
155 |
flex-direction: column;
|
156 |
}
|
157 |
|
158 |
-
|
159 |
-
.
|
160 |
flex: 1;
|
161 |
display: flex;
|
162 |
-
flex-direction: column;
|
163 |
justify-content: center;
|
164 |
align-items: center;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
165 |
background: var(--surface);
|
|
|
|
|
166 |
}
|
167 |
|
168 |
-
|
169 |
-
.
|
170 |
-
.ant-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
171 |
flex: 1;
|
172 |
display: flex;
|
173 |
justify-content: center;
|
174 |
align-items: center;
|
|
|
175 |
}
|
176 |
|
|
|
|
|
|
|
|
|
|
|
177 |
|
|
|
|
|
|
|
|
|
|
|
178 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
179 |
|
180 |
.history_chatbot button {
|
181 |
background: none;
|
@@ -258,7 +567,6 @@ footer, .footer, div[class*="footer"], #footer {
|
|
258 |
box-shadow: 0 4px 12px rgba(0, 102, 204, 0.1);
|
259 |
}
|
260 |
|
261 |
-
/* μ€ν¬λ‘€λ° μ€νμΌλ§ */
|
262 |
::-webkit-scrollbar {
|
263 |
width: 8px;
|
264 |
height: 8px;
|
@@ -277,7 +585,6 @@ footer, .footer, div[class*="footer"], #footer {
|
|
277 |
background: var(--neutral-400);
|
278 |
}
|
279 |
|
280 |
-
/* λ°μν μ‘°μ */
|
281 |
@media (max-width: 768px) {
|
282 |
.right_panel {
|
283 |
height: 400px;
|
@@ -294,7 +601,6 @@ footer, .footer, div[class*="footer"], #footer {
|
|
294 |
}
|
295 |
}
|
296 |
|
297 |
-
/* 리μ¬μ΄μ¦ νΈλ€ */
|
298 |
.right_panel::after {
|
299 |
content: '';
|
300 |
position: absolute;
|
@@ -306,7 +612,6 @@ footer, .footer, div[class*="footer"], #footer {
|
|
306 |
cursor: ns-resize;
|
307 |
}
|
308 |
|
309 |
-
/* Drawer customization */
|
310 |
.ant-drawer-content-wrapper {
|
311 |
border-radius: 16px 0 0 16px;
|
312 |
}
|
@@ -330,7 +635,6 @@ footer, .footer, div[class*="footer"], #footer {
|
|
330 |
background: var(--surface);
|
331 |
}
|
332 |
|
333 |
-
/* ν
νλ¦Ώ κ΄λ ¨ μ€νμΌ */
|
334 |
.session-drawer .chatbot {
|
335 |
height: calc(100vh - 200px);
|
336 |
overflow-y: auto;
|
@@ -394,59 +698,35 @@ footer, .footer, div[class*="footer"], #footer {
|
|
394 |
function adjustIframeContent() {
|
395 |
const iframes = document.querySelectorAll('.html_content iframe');
|
396 |
iframes.forEach(iframe => {
|
397 |
-
|
398 |
-
iframe.
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
display: flex;
|
414 |
-
flex-direction: column;
|
415 |
-
}
|
416 |
-
body > * {
|
417 |
-
width: 100%;
|
418 |
-
}
|
419 |
-
`;
|
420 |
-
|
421 |
-
// μ€νμΌ μ μ©
|
422 |
-
if (iframeDoc.head) {
|
423 |
-
iframeDoc.head.appendChild(style);
|
424 |
}
|
425 |
-
|
426 |
-
|
427 |
-
function updateIframeSize() {
|
428 |
-
const content = iframeDoc.body;
|
429 |
-
if (content) {
|
430 |
-
iframe.style.height = '100%';
|
431 |
-
content.style.minHeight = '100%';
|
432 |
-
}
|
433 |
}
|
434 |
-
|
435 |
-
|
436 |
-
|
437 |
-
|
438 |
-
|
439 |
-
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
iframeDoc.addEventListener('scroll', function(e) {
|
444 |
-
e.stopPropagation();
|
445 |
-
});
|
446 |
-
};
|
447 |
-
} catch (e) {
|
448 |
-
console.error('iframe μ‘°μ μ€ μ€λ₯:', e);
|
449 |
-
}
|
450 |
});
|
451 |
}
|
452 |
|
@@ -462,7 +742,7 @@ document.addEventListener('DOMContentLoaded', function() {
|
|
462 |
}
|
463 |
});
|
464 |
});
|
465 |
-
|
466 |
observer.observe(document.body, {
|
467 |
childList: true,
|
468 |
subtree: true
|
@@ -475,4 +755,5 @@ function send_to_sandbox(code) {
|
|
475 |
const data_uri = `data:text/html;base64,${encoded_html}`;
|
476 |
return `<div class="render_content"><iframe src="${data_uri}" style="width:100%;height:100%;border:none;"></iframe></div>`;
|
477 |
}
|
478 |
-
</script>
|
|
|
|
64 |
|
65 |
.right_panel {
|
66 |
position: relative;
|
67 |
+
height: 100%; /* μ 체 νλ©΄μ μ°¨μ§νλλ‘ λ³κ²½ */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
68 |
display: flex;
|
69 |
flex-direction: column;
|
70 |
}
|
71 |
|
|
|
72 |
.html_content {
|
73 |
+
flex: 1; /* λΆλͺ¨ μμμ λ¨μ 곡κ°μ λͺ¨λ μ°¨μ§ */
|
74 |
display: flex;
|
75 |
flex-direction: column;
|
76 |
+
height: 100%; /* λμ΄λ₯Ό 100%λ‘ */
|
|
|
77 |
}
|
78 |
|
|
|
79 |
.html_content iframe {
|
80 |
+
flex: 1; /* λ¨μ 곡κ°μ λͺ¨λ μ¬μ© */
|
81 |
width: 100%;
|
82 |
+
height: 100%; /* λμ΄ μ€μ */
|
83 |
border: none;
|
84 |
display: block;
|
85 |
}
|
86 |
|
|
|
87 |
/* iframe λ΄λΆ μ€νμΌμ μν μΆκ° */
|
88 |
.html_content iframe html,
|
89 |
.html_content iframe body {
|
|
|
94 |
overflow: auto;
|
95 |
}
|
96 |
|
|
|
97 |
.render_header {
|
98 |
height: 30px;
|
99 |
background: var(--neutral-100);
|
|
|
123 |
background-color: var(--success);
|
124 |
}
|
125 |
|
|
|
126 |
.right_content {
|
127 |
+
flex: 1;
|
128 |
display: flex;
|
129 |
justify-content: center;
|
130 |
align-items: center;
|
131 |
background: var(--surface);
|
132 |
}
|
133 |
+
|
134 |
.ant-tabs-content {
|
135 |
height: 100%;
|
136 |
display: flex;
|
|
|
143 |
flex-direction: column;
|
144 |
}
|
145 |
|
146 |
+
.ant-empty,
|
147 |
+
.ant-spin-container {
|
148 |
flex: 1;
|
149 |
display: flex;
|
|
|
150 |
justify-content: center;
|
151 |
align-items: center;
|
152 |
+
}
|
153 |
+
|
154 |
+
.history_chatbot button {
|
155 |
+
background: none;
|
156 |
+
border: none;
|
157 |
+
}
|
158 |
+
|
159 |
+
footer, .footer, div[class*="footer"], #footer {
|
160 |
+
display: none !important;
|
161 |
+
}
|
162 |
+
|
163 |
+
#component-0 textarea,
|
164 |
+
.gradio-container textarea,
|
165 |
+
.ant-input-textarea-large textarea {
|
166 |
+
height: 300px !important;
|
167 |
+
min-height: 300px !important;
|
168 |
+
resize: vertical !important;
|
169 |
+
border: 2px solid var(--neutral-200);
|
170 |
+
border-radius: 12px;
|
171 |
+
transition: all 0.3s;
|
172 |
background: var(--surface);
|
173 |
+
color: var(--text-primary);
|
174 |
+
padding: 1rem;
|
175 |
}
|
176 |
|
177 |
+
#component-0 textarea:focus,
|
178 |
+
.gradio-container textarea:focus,
|
179 |
+
.ant-input-textarea-large textarea:focus {
|
180 |
+
border-color: var(--accent);
|
181 |
+
box-shadow: 0 0 0 3px rgba(102, 163, 255, 0.2);
|
182 |
+
}
|
183 |
+
|
184 |
+
.setting-buttons {
|
185 |
+
position: sticky;
|
186 |
+
top: 1rem;
|
187 |
+
right: 0;
|
188 |
+
z-index: 1000;
|
189 |
+
display: flex;
|
190 |
+
gap: 8px;
|
191 |
+
padding: 12px;
|
192 |
+
background: rgba(255, 255, 255, 0.9);
|
193 |
+
backdrop-filter: blur(8px);
|
194 |
+
border-radius: 12px;
|
195 |
+
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
|
196 |
+
border: 1px solid var(--neutral-200);
|
197 |
+
}
|
198 |
+
|
199 |
+
.ant-btn {
|
200 |
+
flex: 1;
|
201 |
+
min-width: 80px;
|
202 |
+
border-radius: 8px;
|
203 |
+
font-weight: 500;
|
204 |
+
transition: all 0.3s;
|
205 |
+
height: 40px;
|
206 |
+
display: flex;
|
207 |
+
align-items: center;
|
208 |
+
justify-content: center;
|
209 |
+
}
|
210 |
+
|
211 |
+
.ant-btn-primary {
|
212 |
+
background: linear-gradient(to right, var(--primary), var(--secondary));
|
213 |
+
border: none;
|
214 |
+
color: white;
|
215 |
+
}
|
216 |
+
|
217 |
+
.ant-btn-primary:hover {
|
218 |
+
transform: translateY(-2px);
|
219 |
+
box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
|
220 |
+
}
|
221 |
+
|
222 |
+
.ant-btn-default {
|
223 |
+
background: var(--surface);
|
224 |
+
border: 1px solid var(--primary);
|
225 |
+
color: var(--primary);
|
226 |
+
}
|
227 |
+
|
228 |
+
.ant-btn-default:hover {
|
229 |
+
color: var(--secondary);
|
230 |
+
border-color: var(--secondary);
|
231 |
+
transform: translateY(-2px);
|
232 |
+
box-shadow: 0 4px 12px rgba(0, 102, 204, 0.1);
|
233 |
+
}
|
234 |
+
|
235 |
+
::-webkit-scrollbar {
|
236 |
+
width: 8px;
|
237 |
+
height: 8px;
|
238 |
+
}
|
239 |
+
|
240 |
+
::-webkit-scrollbar-track {
|
241 |
+
background: var(--neutral-100);
|
242 |
+
}
|
243 |
+
|
244 |
+
::-webkit-scrollbar-thumb {
|
245 |
+
background: var(--neutral-300);
|
246 |
+
border-radius: 4px;
|
247 |
+
}
|
248 |
+
|
249 |
+
::-webkit-scrollbar-thumb:hover {
|
250 |
+
background: var(--neutral-400);
|
251 |
+
}
|
252 |
+
|
253 |
+
@media (max-width: 768px) {
|
254 |
+
.right_panel {
|
255 |
+
height: 400px;
|
256 |
+
margin: 10px;
|
257 |
+
}
|
258 |
+
|
259 |
+
.setting-buttons {
|
260 |
+
flex-wrap: wrap;
|
261 |
+
}
|
262 |
+
|
263 |
+
.ant-btn {
|
264 |
+
min-width: 60px;
|
265 |
+
font-size: 0.9rem;
|
266 |
+
}
|
267 |
+
}
|
268 |
+
|
269 |
+
.right_panel::after {
|
270 |
+
content: '';
|
271 |
+
position: absolute;
|
272 |
+
bottom: 0;
|
273 |
+
left: 0;
|
274 |
+
right: 0;
|
275 |
+
height: 6px;
|
276 |
+
background: var(--neutral-200);
|
277 |
+
cursor: ns-resize;
|
278 |
+
}
|
279 |
+
|
280 |
+
.ant-drawer-content-wrapper {
|
281 |
+
border-radius: 16px 0 0 16px;
|
282 |
+
}
|
283 |
+
|
284 |
+
.ant-drawer-header {
|
285 |
+
background: var(--primary);
|
286 |
+
color: white;
|
287 |
+
border-radius: 16px 0 0 0;
|
288 |
+
}
|
289 |
+
|
290 |
+
.ant-drawer-title {
|
291 |
+
color: white;
|
292 |
+
font-weight: 500;
|
293 |
+
}
|
294 |
+
|
295 |
+
.ant-drawer-close {
|
296 |
+
color: white;
|
297 |
+
}
|
298 |
+
|
299 |
+
.ant-drawer-body {
|
300 |
+
background: var(--surface);
|
301 |
+
}
|
302 |
+
|
303 |
+
.session-drawer .chatbot {
|
304 |
+
height: calc(100vh - 200px);
|
305 |
+
overflow-y: auto;
|
306 |
+
}
|
307 |
+
|
308 |
+
.session-history {
|
309 |
+
height: 700px;
|
310 |
+
overflow-y: auto;
|
311 |
+
padding: 1rem;
|
312 |
+
}
|
313 |
+
|
314 |
+
.prompt-grid {
|
315 |
+
display: grid;
|
316 |
+
grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
|
317 |
+
gap: 1.5rem;
|
318 |
+
padding: 1.5rem;
|
319 |
+
}
|
320 |
+
|
321 |
+
.prompt-card {
|
322 |
+
background: var(--surface);
|
323 |
+
border-radius: 16px;
|
324 |
+
padding: 1.25rem;
|
325 |
+
cursor: pointer;
|
326 |
+
transition: all 0.3s;
|
327 |
+
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
|
328 |
+
border: 1px solid var(--neutral-200);
|
329 |
+
}
|
330 |
+
|
331 |
+
.prompt-card:hover {
|
332 |
+
transform: translateY(-4px);
|
333 |
+
box-shadow: 0
|
334 |
+
|
335 |
+
|
336 |
+
<style>
|
337 |
+
/* Modern color scheme */
|
338 |
+
:root {
|
339 |
+
/* μ£Όμ λΈλλ μ»¬λ¬ */
|
340 |
+
--primary: #0066cc; /* λ©μΈ λΈλλ μ»¬λ¬ */
|
341 |
+
--secondary: #3385ff; /* λ°μ μ‘μΌνΈ */
|
342 |
+
--accent: #66a3ff; /* λΆλλ¬μ΄ ν¬μΈνΈ μ»¬λ¬ */
|
343 |
+
|
344 |
+
/* λ°°κ²½ μ»¬λ¬ */
|
345 |
+
--background: #f7f9fc; /* λ©μΈ λ°°κ²½ */
|
346 |
+
--surface: #ffffff; /* μΉ΄λ λ°°κ²½ */
|
347 |
+
|
348 |
+
/* ν
μ€νΈ μ»¬λ¬ */
|
349 |
+
--text-primary: #2c3e50; /* μ£Όμ ν
μ€νΈ */
|
350 |
+
--text-secondary: #546e7a; /* λΆκ° ν
μ€νΈ */
|
351 |
+
--text-tertiary: #78909c; /* λ μ€μν ν
μ€νΈ */
|
352 |
+
|
353 |
+
/* κΈ°λ₯μ± μ»¬λ¬ */
|
354 |
+
--success: #34c759; /* μ±κ³΅/νμΈ */
|
355 |
+
--warning: #ff9500; /* κ²½κ³ /μ£Όμ */
|
356 |
+
--error: #ff3b30; /* μ€λ₯/μμ */
|
357 |
+
|
358 |
+
/* μ€λ¦½ μ»¬λ¬ */
|
359 |
+
--neutral-100: #f8f9fa;
|
360 |
+
--neutral-200: #e9ecef;
|
361 |
+
--neutral-300: #dee2e6;
|
362 |
+
--neutral-400: #ced4da;
|
363 |
+
}
|
364 |
+
|
365 |
+
body {
|
366 |
+
font-family: 'Inter', system-ui, sans-serif;
|
367 |
+
background: var(--background);
|
368 |
+
color: var(--text-primary);
|
369 |
+
line-height: 1.5;
|
370 |
+
}
|
371 |
+
|
372 |
+
.left_header {
|
373 |
+
display: flex;
|
374 |
+
flex-direction: column;
|
375 |
+
justify-content: center;
|
376 |
+
align-items: center;
|
377 |
+
background: linear-gradient(135deg, var(--surface), var(--neutral-100));
|
378 |
+
backdrop-filter: blur(10px);
|
379 |
+
border-radius: 24px;
|
380 |
+
padding: 2rem;
|
381 |
+
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
|
382 |
+
border: 1px solid var(--neutral-200);
|
383 |
+
text-align: center;
|
384 |
+
margin-bottom: 2rem;
|
385 |
+
}
|
386 |
+
|
387 |
+
.left_header img {
|
388 |
+
width: 180px;
|
389 |
+
margin-bottom: 1rem;
|
390 |
+
border-radius: 12px;
|
391 |
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
392 |
+
}
|
393 |
+
|
394 |
+
.left_header h1 {
|
395 |
+
margin: 0.5rem 0;
|
396 |
+
font-weight: 600;
|
397 |
+
color: var(--text-primary);
|
398 |
+
}
|
399 |
+
|
400 |
+
.right_panel {
|
401 |
+
position: relative;
|
402 |
+
height: 100%; /* μ 체 νλ©΄μ μ°¨μ§νλλ‘ λ³κ²½ */
|
403 |
+
display: flex;
|
404 |
+
flex-direction: column;
|
405 |
+
}
|
406 |
+
|
407 |
+
.html_content {
|
408 |
+
flex: 1; /* λΆλͺ¨ μμμ λ¨μ 곡κ°μ λͺ¨λ μ°¨μ§ */
|
409 |
+
display: flex;
|
410 |
+
flex-direction: column;
|
411 |
+
height: 100%; /* λμ΄λ₯Ό 100%λ‘ */
|
412 |
+
}
|
413 |
+
|
414 |
+
.html_content iframe {
|
415 |
+
flex: 1; /* λ¨μ 곡κ°μ λͺ¨λ μ¬μ© */
|
416 |
+
width: 100%;
|
417 |
+
height: 100%; /* λμ΄ μ€μ */
|
418 |
+
border: none;
|
419 |
+
display: block;
|
420 |
+
}
|
421 |
+
|
422 |
+
/* iframe λ΄λΆ μ€νμΌμ μν μΆκ° */
|
423 |
+
.html_content iframe html,
|
424 |
+
.html_content iframe body {
|
425 |
+
margin: 0;
|
426 |
+
padding: 0;
|
427 |
+
height: 100%;
|
428 |
+
width: 100%;
|
429 |
+
overflow: auto;
|
430 |
+
}
|
431 |
+
|
432 |
+
.render_header {
|
433 |
+
height: 30px;
|
434 |
+
background: var(--neutral-100);
|
435 |
+
border-radius: 8px 8px 0 0;
|
436 |
+
display: flex;
|
437 |
+
align-items: center;
|
438 |
+
padding: 0 12px;
|
439 |
+
gap: 6px;
|
440 |
+
flex-shrink: 0;
|
441 |
+
}
|
442 |
+
|
443 |
+
.header_btn {
|
444 |
+
width: 12px;
|
445 |
+
height: 12px;
|
446 |
+
border-radius: 50%;
|
447 |
+
}
|
448 |
+
|
449 |
+
.render_header > .header_btn:nth-child(1) {
|
450 |
+
background-color: var(--error);
|
451 |
+
}
|
452 |
+
|
453 |
+
.render_header > .header_btn:nth-child(2) {
|
454 |
+
background-color: var(--warning);
|
455 |
+
}
|
456 |
+
|
457 |
+
.render_header > .header_btn:nth-child(3) {
|
458 |
+
background-color: var(--success);
|
459 |
+
}
|
460 |
+
|
461 |
+
.right_content {
|
462 |
flex: 1;
|
463 |
display: flex;
|
464 |
justify-content: center;
|
465 |
align-items: center;
|
466 |
+
background: var(--surface);
|
467 |
}
|
468 |
|
469 |
+
.ant-tabs-content {
|
470 |
+
height: 100%;
|
471 |
+
display: flex;
|
472 |
+
flex-direction: column;
|
473 |
+
}
|
474 |
|
475 |
+
.ant-tabs-tabpane {
|
476 |
+
flex: 1;
|
477 |
+
display: flex;
|
478 |
+
flex-direction: column;
|
479 |
+
}
|
480 |
|
481 |
+
.ant-empty,
|
482 |
+
.ant-spin-container {
|
483 |
+
flex: 1;
|
484 |
+
display: flex;
|
485 |
+
justify-content: center;
|
486 |
+
align-items: center;
|
487 |
+
}
|
488 |
|
489 |
.history_chatbot button {
|
490 |
background: none;
|
|
|
567 |
box-shadow: 0 4px 12px rgba(0, 102, 204, 0.1);
|
568 |
}
|
569 |
|
|
|
570 |
::-webkit-scrollbar {
|
571 |
width: 8px;
|
572 |
height: 8px;
|
|
|
585 |
background: var(--neutral-400);
|
586 |
}
|
587 |
|
|
|
588 |
@media (max-width: 768px) {
|
589 |
.right_panel {
|
590 |
height: 400px;
|
|
|
601 |
}
|
602 |
}
|
603 |
|
|
|
604 |
.right_panel::after {
|
605 |
content: '';
|
606 |
position: absolute;
|
|
|
612 |
cursor: ns-resize;
|
613 |
}
|
614 |
|
|
|
615 |
.ant-drawer-content-wrapper {
|
616 |
border-radius: 16px 0 0 16px;
|
617 |
}
|
|
|
635 |
background: var(--surface);
|
636 |
}
|
637 |
|
|
|
638 |
.session-drawer .chatbot {
|
639 |
height: calc(100vh - 200px);
|
640 |
overflow-y: auto;
|
|
|
698 |
function adjustIframeContent() {
|
699 |
const iframes = document.querySelectorAll('.html_content iframe');
|
700 |
iframes.forEach(iframe => {
|
701 |
+
iframe.onload = function() {
|
702 |
+
const iframeDoc = iframe.contentDocument || iframe.contentWindow.document;
|
703 |
+
|
704 |
+
// μ€νμΌ μμ μμ±
|
705 |
+
const style = iframeDoc.createElement('style');
|
706 |
+
style.textContent = `
|
707 |
+
html, body {
|
708 |
+
margin: 0;
|
709 |
+
padding: 0;
|
710 |
+
height: 100%;
|
711 |
+
width: 100%;
|
712 |
+
overflow: auto;
|
713 |
+
}
|
714 |
+
body {
|
715 |
+
display: flex;
|
716 |
+
flex-direction: column;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
717 |
}
|
718 |
+
body > * {
|
719 |
+
width: 100%;
|
|
|
|
|
|
|
|
|
|
|
|
|
720 |
}
|
721 |
+
`;
|
722 |
+
|
723 |
+
if (iframeDoc.head) {
|
724 |
+
iframeDoc.head.appendChild(style);
|
725 |
+
}
|
726 |
+
|
727 |
+
// iframe ν¬κΈ° μ€μ
|
728 |
+
iframe.style.height = '100%';
|
729 |
+
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
730 |
});
|
731 |
}
|
732 |
|
|
|
742 |
}
|
743 |
});
|
744 |
});
|
745 |
+
|
746 |
observer.observe(document.body, {
|
747 |
childList: true,
|
748 |
subtree: true
|
|
|
755 |
const data_uri = `data:text/html;base64,${encoded_html}`;
|
756 |
return `<div class="render_content"><iframe src="${data_uri}" style="width:100%;height:100%;border:none;"></iframe></div>`;
|
757 |
}
|
758 |
+
</script>
|
759 |
+
|