update user count query to exclude hidden users; enhance modal backdrop styling
Build Images and Deploy / Update-PROD-Stack (push) Successful in 1m20s
Build Images and Deploy / Update-PROD-Stack (push) Successful in 1m20s
This commit is contained in:
@@ -88,7 +88,7 @@ export function AdminUserActions({ user }: { user: UserData }) {
|
|||||||
</button>
|
</button>
|
||||||
|
|
||||||
{open && (
|
{open && (
|
||||||
<div className="fixed inset-0 z-50 bg-black/60 flex items-center justify-center p-4" onClick={() => setOpen(false)}>
|
<div className="fixed inset-0 z-50 bg-black/80 backdrop-blur-sm flex items-center justify-center p-4" onClick={() => setOpen(false)}>
|
||||||
<div
|
<div
|
||||||
className="bg-surface-card border border-surface-border rounded-xl p-6 w-full max-w-md space-y-4"
|
className="bg-surface-card border border-surface-border rounded-xl p-6 w-full max-w-md space-y-4"
|
||||||
onClick={(e) => e.stopPropagation()}
|
onClick={(e) => e.stopPropagation()}
|
||||||
@@ -125,11 +125,11 @@ export function AdminUserActions({ user }: { user: UserData }) {
|
|||||||
type="button"
|
type="button"
|
||||||
onClick={() => setHidden((h) => !h)}
|
onClick={() => setHidden((h) => !h)}
|
||||||
className={`relative inline-flex h-6 w-11 items-center rounded-full transition-colors ${
|
className={`relative inline-flex h-6 w-11 items-center rounded-full transition-colors ${
|
||||||
hidden ? 'bg-slate-600' : 'bg-indigo-600'
|
hidden ? 'bg-indigo-600' : 'bg-slate-600'
|
||||||
}`}
|
}`}
|
||||||
>
|
>
|
||||||
<span className={`inline-block h-4 w-4 transform rounded-full bg-white transition-transform ${
|
<span className={`inline-block h-4 w-4 transform rounded-full bg-white transition-transform ${
|
||||||
hidden ? 'translate-x-1' : 'translate-x-6'
|
hidden ? 'translate-x-6' : 'translate-x-1'
|
||||||
}`} />
|
}`} />
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
+1
-1
@@ -11,7 +11,7 @@ export const revalidate = 0
|
|||||||
|
|
||||||
async function getStats() {
|
async function getStats() {
|
||||||
const [userCount, hashtagCount, tradeCount, topHashtags, recentTrades] = await Promise.all([
|
const [userCount, hashtagCount, tradeCount, topHashtags, recentTrades] = await Promise.all([
|
||||||
prisma.user.count({ where: { isFund: false } }),
|
prisma.user.count({ where: { isFund: false, isHidden: false } }),
|
||||||
prisma.hashtag.count({ where: { isActive: true } }),
|
prisma.hashtag.count({ where: { isActive: true } }),
|
||||||
prisma.trade.count(),
|
prisma.trade.count(),
|
||||||
// Top by current price (most active)
|
// Top by current price (most active)
|
||||||
|
|||||||
Reference in New Issue
Block a user