fix(web): restore WEB-C1/M4 fixes reverted by rebase conflict resolution
Some checks failed
Deploy / Deploy to AWS (push) Waiting to run
Deploy Mobile (iOS) / Build & Upload to TestFlight (push) Has been cancelled

- client.ts: localStorage → sessionStorage (WEB-C1 critical fix)
- proposals.ts: re-add 'Other' to ServiceCategory (WEB-M4)
- ProposalListPage.tsx: STATUS_COLORS → STATUS_CHIP_STYLES (visual design)
This commit is contained in:
Adam Moussa 2026-05-27 18:21:03 -04:00
parent f9081fabf4
commit da783d48cd
3 changed files with 4 additions and 4 deletions

View file

@ -13,7 +13,7 @@ const apiClient = axios.create({
apiClient.interceptors.request.use( apiClient.interceptors.request.use(
(config) => { (config) => {
const tokenData = window.localStorage.getItem(STORAGE_KEY_TOKEN); const tokenData = window.sessionStorage.getItem(STORAGE_KEY_TOKEN);
if (tokenData) { if (tokenData) {
try { try {
const parsed = JSON.parse(tokenData); const parsed = JSON.parse(tokenData);

View file

@ -1,7 +1,7 @@
import apiClient from './client'; import apiClient from './client';
// Fix: WEB-M5 — align with shared contract types (shared/api-contracts/src/index.ts) // Fix: WEB-M5 — align with shared contract types (shared/api-contracts/src/index.ts)
export type ServiceCategory = 'HVAC' | 'Plumbing' | 'Electrical' | 'General' | 'Renovation'; export type ServiceCategory = 'HVAC' | 'Plumbing' | 'Electrical' | 'General' | 'Renovation' | 'Other';
export type Priority = 'Standard' | 'Urgent' | 'Emergency'; export type Priority = 'Standard' | 'Urgent' | 'Emergency';
export interface CreateProposalRequest { export interface CreateProposalRequest {

View file

@ -21,7 +21,7 @@ import SearchIcon from '@mui/icons-material/Search';
import AddCircleIcon from '@mui/icons-material/AddCircle'; import AddCircleIcon from '@mui/icons-material/AddCircle';
import { usePaginatedList } from '../../../hooks/usePaginatedList'; import { usePaginatedList } from '../../../hooks/usePaginatedList';
import { proposalsApi, type ProposalListItem } from '../../../lib/api/proposals'; import { proposalsApi, type ProposalListItem } from '../../../lib/api/proposals';
import { STATUS_COLORS } from '../../../constants'; import { STATUS_CHIP_STYLES } from '../../../constants';
import { formatBidAmount, formatDate, formatDateFull } from '../../../lib/format'; import { formatBidAmount, formatDate, formatDateFull } from '../../../lib/format';
import { useDocumentTitle } from '../../../hooks/useDocumentTitle'; import { useDocumentTitle } from '../../../hooks/useDocumentTitle';
@ -121,7 +121,7 @@ export default function ProposalListPage() {
<Chip <Chip
label={row.status} label={row.status}
size="small" size="small"
color={STATUS_COLORS[row.status] || 'default'} sx={STATUS_CHIP_STYLES[row.status] || {}}
/> />
</TableCell> </TableCell>
<TableCell align="right"> <TableCell align="right">