zmiany w ustawieniach

This commit is contained in:
2026-08-12 17:03:22 +02:00
parent 1e361bde93
commit fbb7ab2d90
32 changed files with 2784 additions and 1194 deletions
+8
View File
@@ -39,6 +39,8 @@ export const ROUTES = {
admin: '/admin',
listingDetail: '/oferta/:id',
publicProfile: '/profil/:id',
// Ten sam profil pod nazwą użytkownika - adres pokazywany w ustawieniach konta.
publicProfileByNick: '/u/:nick',
} as const;
export type RoutePath = (typeof ROUTES)[keyof typeof ROUTES];
@@ -58,6 +60,12 @@ export function listingEditPath(id: number): string {
return `/edytuj-ogloszenie/${id}`;
}
// Profil pod nazwą użytkownika. Nick jest unikalny w skali serwisu, więc jednoznacznie
// wskazuje osobę - imię i nazwisko może się powtarzać u wielu kont.
export function publicProfileNickPath(nick: string): string {
return `/u/${encodeURIComponent(nick)}`;
}
// Negocjacje dotyczą konkretnej oferty - bez identyfikatora pokazujemy pierwszą z listy.
export function negotiationPath(offerId?: number | null): string {
return offerId ? `${ROUTES.negotiation}/${offerId}` : ROUTES.negotiation;