Skip to content

Commit e74b901

Browse files
committed
optimize param table mobile
1 parent fb3bab8 commit e74b901

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

src/components/DeviceParams.astro

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,7 @@ const showUsagesCol = rows.some((r) => r.usages.length > 0);
264264
</div>
265265
</div>
266266
)}
267+
<div class="device-params-scroll">
267268
<table>
268269
<thead>
269270
<tr>
@@ -322,6 +323,7 @@ const showUsagesCol = rows.some((r) => r.usages.length > 0);
322323
))}
323324
</tbody>
324325
</table>
326+
</div>
325327
</section>
326328
)
327329
}
@@ -334,10 +336,16 @@ const showUsagesCol = rows.some((r) => r.usages.length > 0);
334336
margin-bottom: 0.75rem;
335337
font-size: 1.25rem;
336338
}
339+
/* Horizontal scroll container — kicks in on narrow viewports so the
340+
table can keep its natural column widths instead of cramping. */
341+
.device-params-scroll {
342+
overflow-x: auto;
343+
-webkit-overflow-scrolling: touch;
344+
}
337345
.device-params table {
338346
display: table !important;
339347
width: 100% !important;
340-
min-width: 100%;
348+
min-width: 600px;
341349
table-layout: auto;
342350
border-collapse: collapse;
343351
font-size: 0.9rem;

0 commit comments

Comments
 (0)