updates on the ui changes and table

This commit is contained in:
2026-08-17 15:39:46 +05:30
parent a46212f291
commit 809d046323
38 changed files with 6403 additions and 7019 deletions

View File

@@ -33,7 +33,7 @@
flex-direction: column;
background: var(--bg);
color: var(--text);
font-family: 'Inter', -apple-system, sans-serif;
font-family: var(--font-family-body);
overflow: hidden;
position: relative;
}
@@ -260,7 +260,7 @@
font-size: 13px;
color: var(--text);
font-weight: 600;
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
background: var(--bg-sub);
padding: 7px 16px;
border-radius: 10px;
@@ -4367,7 +4367,7 @@
}
.dispatch-container .cmp-pop {
font-family: 'Inter', -apple-system, sans-serif;
font-family: var(--font-family-body);
color: #0f172a;
line-height: 1.35;
}
@@ -4479,7 +4479,7 @@
}
.dispatch-container .cmp-pop-coord {
font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
font-family: var(--font-family-code);
font-size: 10.5px;
font-weight: 600;
color: #475569;
@@ -4798,7 +4798,7 @@
/* Custom Order ID & Phone tags */
.dispatch-container .pu-order-tag {
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
font-size: 11px;
color: #4f46e5 !important;
background: #f5f3ff;
@@ -4808,13 +4808,13 @@
}
.dispatch-container .pu-phone-tag {
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
font-size: 11.5px;
color: #334155;
}
.dispatch-container .pu-coord-tag {
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
font-size: 10.5px;
color: #64748b !important;
}
@@ -5003,7 +5003,7 @@
}
.dispatch-container .live-rider-popup .pu-order-badge {
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
font-size: 11px;
color: #4f46e5;
background: #f5f3ff;
@@ -5017,7 +5017,7 @@
color: #0284c7;
text-decoration: none;
transition: color 0.15s ease;
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
font-weight: 700;
}
@@ -5039,7 +5039,7 @@
}
.dispatch-container .live-rider-popup .pu-coordinates {
font-family: 'JetBrains Mono', monospace;
font-family: var(--font-family-code);
font-size: 11px;
color: #64748b;
background: #f8fafc;
@@ -8099,7 +8099,7 @@
}
.dispatch-container .cdp-clock-time {
font-family: 'SF Mono', 'Roboto Mono', 'Menlo', 'Consolas', monospace;
font-family: var(--font-family-code);
font-size: 24px;
font-weight: 700;
color: #f1f5f9;
@@ -9088,7 +9088,7 @@
padding: 1px 6px;
border-radius: 4px;
margin: 0 4px;
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-family: var(--font-family-code);
font-size: 11.5px;
}
@@ -9404,7 +9404,7 @@
.dispatch-container .da-error-meta {
font-size: 11px;
color: #b45353;
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-family: var(--font-family-code);
}
/* ---- Single-batch detail view ---- */
@@ -9572,7 +9572,7 @@
background: #f1f5f9;
padding: 2px 6px;
border-radius: 4px;
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-family: var(--font-family-code);
font-size: 11.5px;
color: #1e293b;
}
@@ -9986,7 +9986,7 @@
.dispatch-container .da-transfer-id {
font-weight: 800;
color: #1e293b;
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
font-family: var(--font-family-code);
}
.dispatch-container .da-transfer-from {

View File

@@ -885,7 +885,7 @@ const Preview = () => {
</HStack>
</HStack>
<HStack gap={1.5} wrap="wrap" vAlign="center" style={{ marginTop: 12 }}>
<HStack gap={1.5} wrap="wrap" vAlign="center" style={{ marginTop: 'var(--spacing-6)' }}>
{r.orders.map((o, idx) => (
<StepChip
key={`${o.orderid}-${idx}`}

View File

@@ -15,6 +15,7 @@ import {
} from 'react-icons/md';
import { Grid } from '@astryxdesign/core/Grid';
import { KpiGrid } from 'components/nearle_components/PageLayout';
import { HStack } from '@astryxdesign/core/HStack';
import { VStack } from '@astryxdesign/core/VStack';
import { Center } from '@astryxdesign/core/Center';
@@ -237,13 +238,7 @@ function CustomerCell({ order }) {
/** Orders table inside an expanded rider card. */
function OrdersBreakdownTable({ orders, getRevenue }) {
if (!orders?.length) {
return (
<EmptyState
title="No orders yet"
description="No orders assigned to this rider yet."
icon={<MdReceipt size={24} />}
/>
);
return <EmptyState title="No orders yet" description="No orders assigned to this rider yet." icon={<MdReceipt size={24} />} />;
}
return (
@@ -295,7 +290,11 @@ function CostTile({ icon, color, label, amount, footnote }) {
return (
<Card padding={3}>
<HStack gap={2} vAlign="center">
<Center width={34} height={34} style={{ flexShrink: 0, borderRadius: 'var(--radius-element)', backgroundColor: `${color}14`, color }}>
<Center
width={34}
height={34}
style={{ flexShrink: 0, borderRadius: 'var(--radius-element)', backgroundColor: `${color}14`, color }}
>
{icon}
</Center>
<VStack gap={0} padding={0}>
@@ -322,7 +321,7 @@ function RiderDetailPanel({ metrics }) {
return (
<VStack gap={3} padding={3}>
<Grid columns={{ minWidth: 200 }} gap={3}>
<Grid columns={{ minWidth: 200, repeat: 'fit' }} gap={3}>
<CostTile
icon={<MdPayments size={16} />}
color={STATUS.info}
@@ -506,7 +505,7 @@ export default function ProfitabilitySection({
</VStack>
</HStack>
<Grid columns={{ minWidth: 200 }} gap={3}>
<KpiGrid minWidth={200}>
<StatCard
title={`Daily ${dailyIsProfit ? 'profit' : 'loss'}`}
value={rupees(Math.abs(totalDailyProfit))}
@@ -549,16 +548,12 @@ export default function ProfitabilitySection({
color={moneyColor(slotIsProfit)}
caption={`${slotMargin >= 0 ? '+' : ''}${slotMargin.toFixed(0)}% margin`}
/>
</Grid>
</KpiGrid>
<VStack gap={2} padding={0}>
<Text weight="bold">Riders list</Text>
{sorted.length === 0 ? (
<EmptyState
title="No riders to show"
description="No riders have orders in this slot."
icon={<MdPeopleAlt size={28} />}
/>
<EmptyState title="No riders to show" description="No riders have orders in this slot." icon={<MdPeopleAlt size={28} />} />
) : (
<VStack gap={2} padding={0}>
{sorted.map((rider) => (