2026-07-04 19:29:42 -05:00
|
|
|
import { useState, useEffect } from 'react';
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
import { toast } from 'sonner';
|
refactor(ts): convert the API client to TypeScript (TS9)
client/api.js -> api.ts. Types the fetch infrastructure: generic _fetch<T>
and get/post/put/patch/del<T> helpers, an ApiError interface (status/code/
details/data), a QueryParams type for the query-string builder, and File-typed
upload helpers. Endpoint response shapes are typed incrementally — most methods
default to Promise<unknown>; the ones consumed by typed .ts files get real
shapes (quickPay -> PaymentRecord, togglePaid -> TogglePaidResult, settings ->
settings map).
Typing togglePaid's result surfaced a latent narrowing bug in usePaymentActions:
the un-pay Undo closure read result.paymentId (number|undefined) inside a
deferred async callback where TS re-widens the if-narrowed value — fixed by
capturing the id in a const before the closure.
The 16 files importing '@/api.js' with an explicit extension were normalized to
'@/api' so Vite/TS resolve the .ts.
Verified: typecheck 0, lint 0 errors (47 warns), build green, 48 client tests,
and 17/17 e2e probe (every page renders, all API paths respond) — the central
fetch-module rename is runtime-safe.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-03 22:09:04 -05:00
|
|
|
import { api } from '@/api';
|
2026-07-04 19:29:42 -05:00
|
|
|
import { fmt, errMessage } from '@/lib/utils';
|
|
|
|
|
import { asDollars } from '@/lib/money';
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
import { Button } from '@/components/ui/button';
|
|
|
|
|
import { Input } from '@/components/ui/input';
|
|
|
|
|
import { Label } from '@/components/ui/label';
|
|
|
|
|
import {
|
|
|
|
|
Dialog, DialogContent, DialogHeader, DialogTitle, DialogFooter,
|
|
|
|
|
} from '@/components/ui/dialog';
|
|
|
|
|
|
|
|
|
|
const MONTHS = [
|
|
|
|
|
'January','February','March','April','May','June',
|
|
|
|
|
'July','August','September','October','November','December',
|
|
|
|
|
];
|
|
|
|
|
|
2026-07-04 19:29:42 -05:00
|
|
|
interface StartingAmountsPreview {
|
|
|
|
|
first_amount?: number;
|
|
|
|
|
fifteenth_amount?: number;
|
|
|
|
|
other_amount?: number;
|
|
|
|
|
paid_total?: number;
|
|
|
|
|
paid_from_first?: number;
|
|
|
|
|
paid_from_fifteenth?: number;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
interface StartingAmountsEditDialogProps {
|
|
|
|
|
open: boolean;
|
|
|
|
|
onClose: () => void;
|
|
|
|
|
year: number;
|
|
|
|
|
month: number;
|
|
|
|
|
onSave: () => void;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function StartingAmountsEditDialog({ open, onClose, year, month, onSave }: StartingAmountsEditDialogProps) {
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
const [loading, setLoading] = useState(false);
|
|
|
|
|
const [saving, setSaving] = useState(false);
|
|
|
|
|
const [error, setError] = useState('');
|
|
|
|
|
const [firstAmount, setFirstAmount] = useState('0');
|
|
|
|
|
const [fifteenthAmount, setFifteenthAmount] = useState('0');
|
|
|
|
|
const [otherAmount, setOtherAmount] = useState('0');
|
2026-07-04 19:29:42 -05:00
|
|
|
const [preview, setPreview] = useState<StartingAmountsPreview | null>(null);
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
|
|
|
|
|
const monthName = `${MONTHS[month - 1]} ${year}`;
|
|
|
|
|
const localFirst = Number(firstAmount) || 0;
|
|
|
|
|
const localFifteenth = Number(fifteenthAmount) || 0;
|
|
|
|
|
const localOther = Number(otherAmount) || 0;
|
|
|
|
|
const totalStarting = localFirst + localFifteenth + localOther;
|
|
|
|
|
const paidSoFar = Number(preview?.paid_total || 0);
|
|
|
|
|
const firstRemaining = localFirst - Number(preview?.paid_from_first || 0);
|
|
|
|
|
const fifteenthRemaining = localFifteenth - Number(preview?.paid_from_fifteenth || 0);
|
|
|
|
|
const totalRemaining = totalStarting - paidSoFar;
|
|
|
|
|
|
|
|
|
|
useEffect(() => {
|
|
|
|
|
let alive = true;
|
|
|
|
|
async function loadStartingAmounts() {
|
|
|
|
|
if (!open) return;
|
|
|
|
|
setLoading(true);
|
|
|
|
|
setError('');
|
|
|
|
|
try {
|
2026-07-04 19:29:42 -05:00
|
|
|
const result = await api.getMonthlyStartingAmounts(year, month) as StartingAmountsPreview;
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
if (!alive) return;
|
|
|
|
|
setPreview(result);
|
|
|
|
|
setFirstAmount(String(result.first_amount ?? 0));
|
|
|
|
|
setFifteenthAmount(String(result.fifteenth_amount ?? 0));
|
|
|
|
|
setOtherAmount(String(result.other_amount ?? 0));
|
|
|
|
|
} catch (err) {
|
|
|
|
|
if (!alive) return;
|
2026-07-04 19:29:42 -05:00
|
|
|
setError(errMessage(err, 'Monthly starting amounts could not be loaded.'));
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
} finally {
|
|
|
|
|
if (alive) setLoading(false);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
loadStartingAmounts();
|
|
|
|
|
return () => { alive = false; };
|
|
|
|
|
}, [open, year, month]);
|
|
|
|
|
|
2026-07-04 19:29:42 -05:00
|
|
|
async function handleSave(e: React.FormEvent) {
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
e.preventDefault();
|
|
|
|
|
const first = Number(firstAmount);
|
|
|
|
|
const fifteenth = Number(fifteenthAmount);
|
|
|
|
|
const other = Number(otherAmount);
|
|
|
|
|
if (![first, fifteenth, other].every(value => Number.isFinite(value) && value >= 0)) {
|
|
|
|
|
setError('Starting amounts must be non-negative numbers.');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
setSaving(true);
|
|
|
|
|
setError('');
|
|
|
|
|
try {
|
|
|
|
|
await api.updateMonthlyStartingAmounts({
|
|
|
|
|
year,
|
|
|
|
|
month,
|
|
|
|
|
first_amount: first,
|
|
|
|
|
fifteenth_amount: fifteenth,
|
|
|
|
|
other_amount: other,
|
|
|
|
|
});
|
|
|
|
|
toast.success('Monthly starting amounts saved.');
|
|
|
|
|
onSave();
|
|
|
|
|
} catch (err) {
|
2026-07-04 19:29:42 -05:00
|
|
|
setError(errMessage(err, 'Monthly starting amounts could not be saved.'));
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
} finally {
|
|
|
|
|
setSaving(false);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<Dialog open={open} onOpenChange={value => { if (!value) onClose(); }}>
|
|
|
|
|
<DialogContent className="max-h-[92vh] overflow-y-auto border-border/60 bg-card/95 backdrop-blur-xl sm:max-w-lg">
|
|
|
|
|
<DialogHeader>
|
|
|
|
|
<DialogTitle className="text-lg font-semibold tracking-tight">Monthly Starting Amounts</DialogTitle>
|
|
|
|
|
<p className="text-sm text-muted-foreground">{monthName}</p>
|
|
|
|
|
</DialogHeader>
|
|
|
|
|
|
|
|
|
|
<form id="starting-amounts-form" onSubmit={handleSave} className="space-y-5">
|
|
|
|
|
{error && (
|
|
|
|
|
<div className="rounded-lg border border-destructive/40 bg-destructive/10 px-3 py-2 text-sm text-destructive">
|
|
|
|
|
{error}
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
|
|
|
|
|
<div className="grid gap-3 sm:grid-cols-3">
|
|
|
|
|
<label className="space-y-1.5">
|
|
|
|
|
<Label htmlFor="starting-first" className="text-xs uppercase tracking-wider text-muted-foreground">
|
|
|
|
|
1st
|
|
|
|
|
</Label>
|
|
|
|
|
<Input
|
|
|
|
|
id="starting-first"
|
|
|
|
|
type="number"
|
|
|
|
|
min="0"
|
|
|
|
|
step="0.01"
|
|
|
|
|
value={firstAmount}
|
|
|
|
|
disabled={loading || saving}
|
|
|
|
|
onChange={e => setFirstAmount(e.target.value)}
|
|
|
|
|
className="font-mono bg-background/50 border-border/60"
|
|
|
|
|
/>
|
|
|
|
|
</label>
|
|
|
|
|
<label className="space-y-1.5">
|
|
|
|
|
<Label htmlFor="starting-fifteenth" className="text-xs uppercase tracking-wider text-muted-foreground">
|
|
|
|
|
15th
|
|
|
|
|
</Label>
|
|
|
|
|
<Input
|
|
|
|
|
id="starting-fifteenth"
|
|
|
|
|
type="number"
|
|
|
|
|
min="0"
|
|
|
|
|
step="0.01"
|
|
|
|
|
value={fifteenthAmount}
|
|
|
|
|
disabled={loading || saving}
|
|
|
|
|
onChange={e => setFifteenthAmount(e.target.value)}
|
|
|
|
|
className="font-mono bg-background/50 border-border/60"
|
|
|
|
|
/>
|
|
|
|
|
</label>
|
|
|
|
|
<label className="space-y-1.5">
|
|
|
|
|
<Label htmlFor="starting-other" className="text-xs uppercase tracking-wider text-muted-foreground">
|
|
|
|
|
Other
|
|
|
|
|
</Label>
|
|
|
|
|
<Input
|
|
|
|
|
id="starting-other"
|
|
|
|
|
type="number"
|
|
|
|
|
min="0"
|
|
|
|
|
step="0.01"
|
|
|
|
|
value={otherAmount}
|
|
|
|
|
disabled={loading || saving}
|
|
|
|
|
onChange={e => setOtherAmount(e.target.value)}
|
|
|
|
|
className="font-mono bg-background/50 border-border/60"
|
|
|
|
|
/>
|
|
|
|
|
</label>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div className="rounded-xl border border-border/60 bg-muted/35 p-4">
|
|
|
|
|
<div className="grid gap-3 sm:grid-cols-3">
|
|
|
|
|
<div>
|
|
|
|
|
<p className="text-xs font-medium text-muted-foreground">Total starting</p>
|
2026-07-04 19:29:42 -05:00
|
|
|
<p className="mt-1 font-mono text-lg font-bold">{fmt(asDollars(totalStarting))}</p>
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
</div>
|
|
|
|
|
<div>
|
|
|
|
|
<p className="text-xs font-medium text-muted-foreground">Paid so far</p>
|
2026-07-04 19:29:42 -05:00
|
|
|
<p className="mt-1 font-mono text-lg font-bold text-emerald-500">{fmt(asDollars(paidSoFar))}</p>
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
</div>
|
|
|
|
|
<div>
|
|
|
|
|
<p className="text-xs font-medium text-muted-foreground">Total remaining</p>
|
2026-07-04 19:29:42 -05:00
|
|
|
<p className="mt-1 font-mono text-lg font-bold">{fmt(asDollars(totalRemaining))}</p>
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="mt-4 grid gap-2 border-t border-border/60 pt-3 text-sm sm:grid-cols-3">
|
|
|
|
|
<div className="flex justify-between gap-3 sm:block">
|
|
|
|
|
<span className="text-muted-foreground">1st remaining</span>
|
2026-07-04 19:29:42 -05:00
|
|
|
<span className="font-mono font-semibold sm:block">{fmt(asDollars(firstRemaining))}</span>
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
</div>
|
|
|
|
|
<div className="flex justify-between gap-3 sm:block">
|
|
|
|
|
<span className="text-muted-foreground">15th remaining</span>
|
2026-07-04 19:29:42 -05:00
|
|
|
<span className="font-mono font-semibold sm:block">{fmt(asDollars(fifteenthRemaining))}</span>
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
</div>
|
|
|
|
|
<div className="flex justify-between gap-3 sm:block">
|
|
|
|
|
<span className="text-muted-foreground">Other</span>
|
2026-07-04 19:29:42 -05:00
|
|
|
<span className="font-mono font-semibold sm:block">{fmt(asDollars(localOther))}</span>
|
refactor: component splits, PWA support, CommandPalette
Component Splits:
- AdminPage.jsx: 1,906 -> 82 lines (logic moved to client/components/admin/ — 9 files)
- DataPage.jsx: 3,132 -> 60 lines (logic moved to client/components/data/ — 8 files)
- TrackerPage.jsx: 2,566 -> 2,132 lines (MonthlyStateDialog, StartingAmountsEditDialog, PaymentModal)
PWA:
- vite-plugin-pwa installed with NetworkFirst caching for API routes
- Square PWA icons (192x192, 512x512, apple-touch-icon)
- theme-color, apple meta tags, touch icon in index.html
- Build generates dist/sw.js + Workbox runtime
CommandPalette:
- Navigation commands, Add bill action, month jumps
- Grouped results with empty/filtered states
2026-05-28 20:53:22 -05:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</form>
|
|
|
|
|
|
|
|
|
|
<DialogFooter className="mt-2">
|
|
|
|
|
<Button type="button" variant="ghost" disabled={saving} onClick={onClose} className="text-xs">
|
|
|
|
|
Cancel
|
|
|
|
|
</Button>
|
|
|
|
|
<Button type="submit" form="starting-amounts-form" disabled={loading || saving} className="text-xs">
|
|
|
|
|
{saving ? 'Saving...' : 'Save'}
|
|
|
|
|
</Button>
|
|
|
|
|
</DialogFooter>
|
|
|
|
|
</DialogContent>
|
|
|
|
|
</Dialog>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default StartingAmountsEditDialog;
|