Skip to content

Commit 6354d96

Browse files
author
rick
committed
fix :Try to optimize the mobile display
1 parent 8ed0e7d commit 6354d96

File tree

1 file changed

+51
-23
lines changed

1 file changed

+51
-23
lines changed

index.html

Lines changed: 51 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,29 @@
1111
<style>
1212
body {
1313
font-family: Arial, sans-serif;
14-
margin: 40px;
14+
margin: 50px 10px;
15+
padding: 20px;
16+
box-sizing: border-box;
1517
}
1618

1719
.container {
18-
width: 100%;
19-
max-width: 600px;
20+
display: flex;
21+
flex-direction: column;
2022
margin: auto;
2123
padding: 20px;
2224
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
25+
width: 90%;
26+
max-width: 600px;
2327
}
2428

2529
.response-container {
26-
width: 100%;
30+
width: 90%;
2731
margin: 20px auto 0;
2832
max-width: 1000px;
2933
padding: 20px;
3034
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
3135
font-size: 16px;
36+
3237
}
3338

3439
input[type="text"], textarea {
@@ -39,6 +44,7 @@
3944
}
4045

4146
textarea {
47+
resize: vertical;
4248
height: 100px;
4349
}
4450

@@ -107,7 +113,6 @@
107113

108114
h1 {
109115
font-weight: bold;
110-
margin-bottom: 20px;
111116
}
112117

113118
h2, h3 {
@@ -127,20 +132,21 @@
127132
display: flex;
128133
justify-content: space-between;
129134
margin-top: 10px;
135+
margin-bottom: 15px
130136
}
131137

132138
.model-timeout, .model-concurrency {
133-
width: 48%;
139+
height: 35px;
140+
width: 40%;
134141
}
135142

136143
.model-timeout input, .model-concurrency input {
137144
width: 100%;
145+
height: 25px;
138146
}
139147

140148
table {
141-
width: 90%; /* 或任何其他固定宽度 */
142-
margin-left: auto;
143-
margin-right: auto;
149+
width: 100%;
144150
border-collapse: collapse;
145151
margin-top: 20px;
146152
}
@@ -390,6 +396,30 @@
390396
color: #333;
391397
}
392398

399+
.copyright {
400+
margin-top: 20px;
401+
text-align: center;
402+
font-size: 14px;
403+
color: #666;
404+
}
405+
406+
.copyright img {
407+
width: 24px;
408+
height: 24px;
409+
border-radius: 50%;
410+
margin-right: 5px;
411+
vertical-align: middle;
412+
}
413+
414+
.copyright a {
415+
color: #1e88e5;
416+
text-decoration: none;
417+
}
418+
419+
.copyright a:hover {
420+
text-decoration: underline;
421+
}
422+
393423
</style>
394424
</head>
395425
<body>
@@ -398,8 +428,8 @@ <h1>API CHECKER</h1>
398428
<h3>(适配 oneapi/newapi 等中转格式)</h3>
399429

400430
<form id="apiForm">
401-
<textarea id="api_info" name="api_info"
402-
placeholder="懒人专用文本框,支持同时粘贴接口地址和密钥,智能提取,如:https://api.openai.com,sk-TodayIsThursdayVme50ForKFC"></textarea>
431+
<textarea id="api_info" name="api_info"
432+
placeholder="懒人专用文本框,支持同时粘贴接口地址和密钥,智能提取,如:https://api.openai.com,sk-TodayIsThursdayVme50ForKFC"></textarea>
403433
<input type="text" id="api_url" name="api_url" placeholder="接口地址,如:https://api.openai.com" value="">
404434
<input type="text" id="api_key" name="api_key" placeholder="密钥,如:sk-TodayIsThursdayVme50ForKFC" value="">
405435
<div class="model-input-container" id="model-input-container">
@@ -411,13 +441,13 @@ <h3>(适配 oneapi/newapi 等中转格式)</h3>
411441
<div class="model-timeout-concurrency">
412442
<div class="model-timeout">
413443
<label for="model_timeout">设置请求超时(秒):</label>
414-
<input type="number" style="height: 30px;width: 70px" id="model_timeout" name="model_timeout" value="10"
415-
min="1">
444+
<input type="number" id="model_timeout" name="model_timeout" value="10" min="1"
445+
style="max-width: 100px;">
416446
</div>
417-
<div class="model-concurrency" style="height: 50px">
447+
<div class="model-concurrency">
418448
<label for="model_concurrency">设置请求并发数量:</label>
419-
<input type="number" style="height: 30px;width: 70px" id="model_concurrency" name="model_concurrency"
420-
value="5" min="1">
449+
<input type="number" id="model_concurrency" name="model_concurrency" value="5" min="1"
450+
style="max-width: 100px;">
421451
</div>
422452
</div>
423453
<div class="submit-container">
@@ -824,12 +854,10 @@ <h3>(适配 oneapi/newapi 等中转格式)</h3>
824854
const resultsDiv = document.getElementById('results');
825855
let content = '<h2>测试结果</h2>' +
826856
'<h3>(结果仅供参考,防君子不防小人)</h3>' +
827-
'<div class="copy-buttons">' +
828-
'<div className="submit-container">' +
829-
'<button class="check-quota copy-btn" onclick="copyConsistentModels()">复制一致模型</button>' +
830-
'<button class="check-quota copy-btn" onclick="copyConsistentAndInconsistentModels()">复制所有可用模型</button>' +
831-
'<button class="check-quota copy-btn" onclick="copyConsistentAndInconsistentReturedModels()">复制可用原始模型</button>' +
832-
'</div>' +
857+
'<div class="submit-container">' +
858+
'<input type="button" onclick="copyConsistentModels()" value="复制一致模型" class="check-quota">' +
859+
'<input type="button" onclick="copyConsistentAndInconsistentModels()" value="复制一致模型" class="check-quota">' +
860+
'<input type="button" onclick="copyConsistentAndInconsistentReturedModels()" value="复制可用原始模型" class="check-quota">' +
833861
'</div>' +
834862
'<table>' +
835863
'<tr>' +
@@ -842,7 +870,7 @@ <h3>(适配 oneapi/newapi 等中转格式)</h3>
842870
results.valid.forEach(function (r) {
843871
content += '<tr>' +
844872
'<td class="td1 td1-ok">模型一致可用</ td>' +
845-
'<td class="td2"><span class="copy-btn2"" onclick="copyText(\'' + r.model + '\')">' + r.model + '</span></td>' +
873+
'<td class="td2"><span class="copy-btn2" onclick="copyText(\'' + r.model + '\')">' + r.model + '</span></td>' +
846874
'<td class="td3">' + r.responseTime.toFixed(2) + '</td>'
847875

848876
let verifyButtons = `

0 commit comments

Comments
 (0)