diff --git a/client/scripts/eslint-baseline.json b/client/scripts/eslint-baseline.json index 8dbf83e06..b44d6298a 100644 --- a/client/scripts/eslint-baseline.json +++ b/client/scripts/eslint-baseline.json @@ -3,7 +3,7 @@ "@typescript-eslint/no-non-null-assertion": 338, "@typescript-eslint/no-misused-promises": 750, "no-console": 81, - "complexity": 214, + "complexity": 213, "@typescript-eslint/no-explicit-any": 113, "trek/no-swallowed-catch": 124, "max-params": 31, @@ -14,8 +14,8 @@ "react-hooks/exhaustive-deps": 112, "@typescript-eslint/no-unused-vars": 95, "react-hooks/immutability": 26, - "max-lines-per-function": 126, - "react-hooks/static-components": 35, + "max-lines-per-function": 125, + "react-hooks/static-components": 34, "react-hooks/preserve-manual-memoization": 12, "no-useless-assignment": 7, "no-empty": 18, diff --git a/client/src/mobile/screens/journey/MJourneySettingsSheet.tsx b/client/src/mobile/screens/journey/MJourneySettingsSheet.tsx index a1d25f441..a7b3d68f6 100644 --- a/client/src/mobile/screens/journey/MJourneySettingsSheet.tsx +++ b/client/src/mobile/screens/journey/MJourneySettingsSheet.tsx @@ -109,83 +109,83 @@ export default function MJourneySettingsSheet({ switch (area) { case null: return ( - - ) + + ) case 'profile': return case 'trips': return case 'linkTrip': return ( - - {loadingTrips || unlinkedTrips.length === 0 ? ( -

- {t(loadingTrips ? 'common.loading' : 'journey.trips.noTripsAvailable')} -

- ) : ( -
- {unlinkedTrips.map(trip => ( -
- - {trip.title} - -
- ))} -
- )} -
- ) + + {loadingTrips || unlinkedTrips.length === 0 ? ( +

+ {t(loadingTrips ? 'common.loading' : 'journey.trips.noTripsAvailable')} +

+ ) : ( +
+ {unlinkedTrips.map(trip => ( +
+ + {trip.title} + +
+ ))} +
+ )} +
+ ) case 'people': return ( - <> -
- {journey.contributors.map(c => ( -
- -
- {c.username} - {t(c.role === 'owner' ? 'members.owner' : c.role === 'editor' ? 'journey.invite.editor' : 'journey.invite.viewer')} + <> +
+ {journey.contributors.map(c => ( +
+ +
+ {c.username} + {t(c.role === 'owner' ? 'members.owner' : c.role === 'editor' ? 'journey.invite.editor' : 'journey.invite.viewer')} +
+ {c.role !== 'owner' && ( + setPendingContributor(c)} + ariaLabel={t('journey.contributors.remove')} + > + + + )} +
+ ))}
- {c.role !== 'owner' && ( - setPendingContributor(c)} - ariaLabel={t('journey.contributors.remove')} - > - - - )} -
- ))} -
- - - ) + + + ) case 'share': return case 'entries': diff --git a/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx b/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx index c5b27ec3b..08b0d0928 100644 --- a/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx +++ b/client/src/mobile/screens/trip/sheets/MPlaceEditSheet.tsx @@ -238,7 +238,6 @@ export default function MPlaceEditSheet({ planner, onOpenExpense }: MPlaceEditSh } finally { setIsSaving(false) } - return } const handleSubmit = async () => { @@ -384,8 +383,8 @@ export default function MPlaceEditSheet({ planner, onOpenExpense }: MPlaceEditSh - {placesEnrichEnabled ? ( -
+
+ {placesEnrichEnabled ? ( -
- ) : } + ) : ( + + )} +
{/* COSTS — same block, same flow as the booking sheet (#1298) */} {isBudgetEnabled && (