Skip to content

Commit 8a29240

Browse files
committed
style(accounts): 优化账号页面布局,收紧筛选栏间距并修复单元格垂直居中
1 parent de97701 commit 8a29240

2 files changed

Lines changed: 13 additions & 8 deletions

File tree

web/src/index.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1395,6 +1395,11 @@ input[type="number"]::-webkit-outer-spin-button {
13951395
min-height: var(--ag-accounts-table-row-height) !important;
13961396
line-height: 1 !important;
13971397
padding: 0 !important;
1398+
vertical-align: middle !important;
1399+
}
1400+
1401+
.ag-accounts-table-content :where([data-slot="table-cell"], [data-slot="td"], .table__cell) > div {
1402+
height: 100%;
13981403
}
13991404

14001405
.ag-accounts-table-content :where([data-slot="table-body"] [data-slot="table-row"]:hover [data-slot="table-cell"],

web/src/pages/admin/AccountsPage.tsx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1299,7 +1299,7 @@ export default function AccountsPage() {
12991299
selectedLabel: selectedPlatformLabel,
13001300
options: PLATFORM_OPTIONS,
13011301
setValue: setPlatformFilter,
1302-
widthClass: 'w-full sm:w-48',
1302+
widthClass: 'w-full sm:w-36',
13031303
},
13041304
{
13051305
key: 'state',
@@ -1308,7 +1308,7 @@ export default function AccountsPage() {
13081308
selectedLabel: selectedStateLabel,
13091309
options: STATE_OPTIONS,
13101310
setValue: setStateFilter,
1311-
widthClass: 'w-full sm:w-48',
1311+
widthClass: 'w-full sm:w-36',
13121312
},
13131313
{
13141314
key: 'type',
@@ -1317,7 +1317,7 @@ export default function AccountsPage() {
13171317
selectedLabel: selectedTypeLabel,
13181318
options: typeOptions,
13191319
setValue: setTypeFilter,
1320-
widthClass: 'w-full sm:w-48',
1320+
widthClass: 'w-full sm:w-36',
13211321
},
13221322
{
13231323
key: 'group',
@@ -1326,7 +1326,7 @@ export default function AccountsPage() {
13261326
selectedLabel: selectedGroupLabel,
13271327
options: groupOptions,
13281328
setValue: setGroupFilter,
1329-
widthClass: 'w-full sm:w-48',
1329+
widthClass: 'w-full sm:w-36',
13301330
},
13311331
{
13321332
key: 'proxy',
@@ -1335,7 +1335,7 @@ export default function AccountsPage() {
13351335
selectedLabel: selectedProxyLabel,
13361336
options: proxyOptions,
13371337
setValue: setProxyFilter,
1338-
widthClass: 'w-full sm:w-48',
1338+
widthClass: 'w-full sm:w-36',
13391339
},
13401340
];
13411341
const columnAlignClass = (align?: AccountTableColumn['align']) => (
@@ -1357,11 +1357,11 @@ export default function AccountsPage() {
13571357
<div>
13581358
<div className="relative mb-5 min-h-12">
13591359
<div
1360-
className={`flex min-h-12 flex-col sm:flex-row items-stretch sm:items-center gap-3 flex-wrap ${
1360+
className={`flex min-h-12 flex-col sm:flex-row items-stretch sm:items-center gap-2 flex-wrap ${
13611361
selectedIds.length > 0 ? 'invisible' : ''
13621362
}`}
13631363
>
1364-
<div className="w-full sm:w-48">
1364+
<div className="w-full sm:w-40">
13651365
<HeroTextField fullWidth>
13661366
<div className="relative">
13671367
<Search className="pointer-events-none absolute left-3 top-1/2 z-10 h-4 w-4 -translate-y-1/2 text-text-tertiary" />
@@ -1418,7 +1418,7 @@ export default function AccountsPage() {
14181418
</Button>
14191419
) : null}
14201420

1421-
<div className="flex flex-wrap items-center justify-end gap-2 sm:ml-auto">
1421+
<div className="flex flex-wrap items-center justify-end gap-1.5 sm:ml-auto">
14221422
<Button
14231423
isIconOnly
14241424
aria-label={t('common.refresh')}

0 commit comments

Comments
 (0)