refactor(ui): refine positions table controls
This commit is contained in:
parent
bfd7d3bfec
commit
fd64fecbce
@ -1613,7 +1613,7 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
]}
|
]}
|
||||||
controlSize="sm"
|
controlSize="sm"
|
||||||
variant="muted"
|
variant="muted"
|
||||||
className="w-full bg-white/5 border border-white/10 rounded px-2 py-1 text-[10px] font-semibold text-gray-200 focus:outline-none focus:ring-2 focus:ring-orange-500/40"
|
className="w-full"
|
||||||
/>
|
/>
|
||||||
</th>
|
</th>
|
||||||
<th className="px-4 py-2">
|
<th className="px-4 py-2">
|
||||||
@ -1624,7 +1624,6 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
onChange={(e: ChangeEvent<HTMLInputElement>) => setOrdersDateFrom(e.target.value)}
|
onChange={(e: ChangeEvent<HTMLInputElement>) => setOrdersDateFrom(e.target.value)}
|
||||||
controlSize="sm"
|
controlSize="sm"
|
||||||
variant="muted"
|
variant="muted"
|
||||||
className="bg-white/5 border border-white/10 rounded px-2 py-1 text-[10px] text-gray-200 focus:outline-none focus:ring-2 focus:ring-orange-500/40"
|
|
||||||
/>
|
/>
|
||||||
<Input
|
<Input
|
||||||
type="date"
|
type="date"
|
||||||
@ -1632,7 +1631,6 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
onChange={(e: ChangeEvent<HTMLInputElement>) => setOrdersDateTo(e.target.value)}
|
onChange={(e: ChangeEvent<HTMLInputElement>) => setOrdersDateTo(e.target.value)}
|
||||||
controlSize="sm"
|
controlSize="sm"
|
||||||
variant="muted"
|
variant="muted"
|
||||||
className="bg-white/5 border border-white/10 rounded px-2 py-1 text-[10px] text-gray-200 focus:outline-none focus:ring-2 focus:ring-orange-500/40"
|
|
||||||
/>
|
/>
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
<Button
|
<Button
|
||||||
@ -1643,7 +1641,7 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
}}
|
}}
|
||||||
variant="outline"
|
variant="outline"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto px-2 py-1 rounded border border-white/10 text-[9px] font-bold uppercase tracking-wider text-gray-300 hover:bg-white/5 transition-colors"
|
className="min-h-7 px-2 text-[9px]"
|
||||||
>
|
>
|
||||||
Clear
|
Clear
|
||||||
</Button>
|
</Button>
|
||||||
@ -1652,7 +1650,7 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
onClick={() => setOrdersSortDirection((current) => current === 'desc' ? 'asc' : 'desc')}
|
onClick={() => setOrdersSortDirection((current) => current === 'desc' ? 'asc' : 'desc')}
|
||||||
variant="outline"
|
variant="outline"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto px-2 py-1 rounded border border-white/10 text-[9px] font-bold uppercase tracking-wider text-gray-300 hover:bg-white/5 transition-colors"
|
className="min-h-7 px-2 text-[9px]"
|
||||||
>
|
>
|
||||||
{ordersSortDirection === 'desc' ? 'Newest' : 'Oldest'}
|
{ordersSortDirection === 'desc' ? 'Newest' : 'Oldest'}
|
||||||
</Button>
|
</Button>
|
||||||
@ -1807,7 +1805,6 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
disabled={ordersPage === 1}
|
disabled={ordersPage === 1}
|
||||||
variant="outline"
|
variant="outline"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto px-3 py-1.5 rounded border border-white/10 disabled:opacity-40 disabled:cursor-not-allowed hover:bg-white/5 transition-colors"
|
|
||||||
>
|
>
|
||||||
Prev
|
Prev
|
||||||
</Button>
|
</Button>
|
||||||
@ -1820,7 +1817,6 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
disabled={ordersPage >= ordersTotalPages}
|
disabled={ordersPage >= ordersTotalPages}
|
||||||
variant="outline"
|
variant="outline"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto px-3 py-1.5 rounded border border-white/10 disabled:opacity-40 disabled:cursor-not-allowed hover:bg-white/5 transition-colors"
|
|
||||||
>
|
>
|
||||||
Next
|
Next
|
||||||
</Button>
|
</Button>
|
||||||
@ -1880,7 +1876,7 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
]}
|
]}
|
||||||
controlSize="sm"
|
controlSize="sm"
|
||||||
variant="muted"
|
variant="muted"
|
||||||
className="w-full bg-white/5 border border-white/10 rounded px-2 py-1 text-[10px] font-semibold text-gray-200 focus:outline-none focus:ring-2 focus:ring-cyan-500/40"
|
className="w-full"
|
||||||
/>
|
/>
|
||||||
</th>
|
</th>
|
||||||
<th className="px-4 py-2 text-[10px] text-gray-500 font-medium">
|
<th className="px-4 py-2 text-[10px] text-gray-500 font-medium">
|
||||||
@ -1894,7 +1890,6 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
onChange={(e: ChangeEvent<HTMLInputElement>) => setLifecycleDateFrom(e.target.value)}
|
onChange={(e: ChangeEvent<HTMLInputElement>) => setLifecycleDateFrom(e.target.value)}
|
||||||
controlSize="sm"
|
controlSize="sm"
|
||||||
variant="muted"
|
variant="muted"
|
||||||
className="bg-white/5 border border-white/10 rounded px-2 py-1 text-[10px] text-gray-200 focus:outline-none focus:ring-2 focus:ring-cyan-500/40"
|
|
||||||
/>
|
/>
|
||||||
<Input
|
<Input
|
||||||
type="date"
|
type="date"
|
||||||
@ -1902,7 +1897,6 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
onChange={(e: ChangeEvent<HTMLInputElement>) => setLifecycleDateTo(e.target.value)}
|
onChange={(e: ChangeEvent<HTMLInputElement>) => setLifecycleDateTo(e.target.value)}
|
||||||
controlSize="sm"
|
controlSize="sm"
|
||||||
variant="muted"
|
variant="muted"
|
||||||
className="bg-white/5 border border-white/10 rounded px-2 py-1 text-[10px] text-gray-200 focus:outline-none focus:ring-2 focus:ring-cyan-500/40"
|
|
||||||
/>
|
/>
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
<Button
|
<Button
|
||||||
@ -1913,7 +1907,7 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
}}
|
}}
|
||||||
variant="outline"
|
variant="outline"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto px-2 py-1 rounded border border-white/10 text-[9px] font-bold uppercase tracking-wider text-gray-300 hover:bg-white/5 transition-colors"
|
className="min-h-7 px-2 text-[9px]"
|
||||||
>
|
>
|
||||||
Clear
|
Clear
|
||||||
</Button>
|
</Button>
|
||||||
@ -1922,7 +1916,7 @@ export const PositionsTab = ({ botState, onManageHolding }: PositionsTabProps) =
|
|||||||
onClick={() => setLifecycleSortDirection((current) => current === 'desc' ? 'asc' : 'desc')}
|
onClick={() => setLifecycleSortDirection((current) => current === 'desc' ? 'asc' : 'desc')}
|
||||||
variant="outline"
|
variant="outline"
|
||||||
size="sm"
|
size="sm"
|
||||||
className="h-auto px-2 py-1 rounded border border-white/10 text-[9px] font-bold uppercase tracking-wider text-gray-300 hover:bg-white/5 transition-colors"
|
className="min-h-7 px-2 text-[9px]"
|
||||||
>
|
>
|
||||||
{lifecycleSortDirection === 'desc' ? 'Newest' : 'Oldest'}
|
{lifecycleSortDirection === 'desc' ? 'Newest' : 'Oldest'}
|
||||||
</Button>
|
</Button>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user