Skip to content

Commit 65a2697

Browse files
committed
style: shrink code area when llm enabled
1 parent 2061cb4 commit 65a2697

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

main.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1480,6 +1480,9 @@ var app = new Vue({
14801480
},
14811481
llm_test: function () {
14821482
var that = this;
1483+
function shrinkCodeArea() {
1484+
document.getElementById('manualfile').style.height = '430px';
1485+
}
14831486
var request = new XMLHttpRequest();
14841487
request.open('GET', "/llm", true);
14851488
request.onreadystatechange = function() {
@@ -1489,7 +1492,7 @@ var app = new Vue({
14891492
} else {
14901493
that.llm = "llama";
14911494
}
1492-
document.getElementById('manualfile').style.height = '430px';
1495+
shrinkCodeArea();
14931496
}
14941497
}
14951498
request.send();
@@ -1499,6 +1502,7 @@ var app = new Vue({
14991502
request.onreadystatechange = function() {
15001503
if (request.readyState === 4 && request.status === 200) {
15011504
that.llm = "llama-serverless";
1505+
shrinkCodeArea();
15021506
}
15031507
}
15041508
request.send();

0 commit comments

Comments
 (0)