From ac01925be79caf5896d39f9e62f034123a16c3f3 Mon Sep 17 00:00:00 2001 From: Maurice Date: Thu, 19 Nov 2026 21:20:33 +0100 Subject: [PATCH] fix(mobile): show a place's full name in its details sheet The details sheet cut the place name to one line, and nothing in the sheet showed the rest; only the edit form did. The sheet is where a place is read in full, so the name now wraps onto as many lines as it needs, as the desktop inspector already does. The address under it wrapped before and still does. Closes #3140 --- .../mobile/screens/trip/sheets/MPlaceSheet.test.tsx | 12 ++++++++++++ .../src/mobile/screens/trip/sheets/MPlaceSheet.tsx | 8 +++++--- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/client/src/mobile/screens/trip/sheets/MPlaceSheet.test.tsx b/client/src/mobile/screens/trip/sheets/MPlaceSheet.test.tsx index c758ad2f9..892d2e293 100644 --- a/client/src/mobile/screens/trip/sheets/MPlaceSheet.test.tsx +++ b/client/src/mobile/screens/trip/sheets/MPlaceSheet.test.tsx @@ -122,3 +122,15 @@ describe('MPlaceSheet ask the assistant', () => { expect(chatOf(useAssistantStore.getState(), 5).focus).toEqual({ placeIds: [42] }) }) }) + +describe('MPlaceSheet header (#3140)', () => { + it('lets a long place name wrap instead of cutting it to one line', () => { + const longName = 'Broad Street Christmas Lights & Market' + render() + + const title = screen.getByText(longName) + expect(title).not.toHaveClass('truncate') + expect(title).toHaveClass('break-words') + expect(screen.getByText('Broad Street, RG1 2AF, Reading').closest('div')).not.toHaveClass('truncate') + }) +}) diff --git a/client/src/mobile/screens/trip/sheets/MPlaceSheet.tsx b/client/src/mobile/screens/trip/sheets/MPlaceSheet.tsx index 4f7036a84..0b4e5eafc 100644 --- a/client/src/mobile/screens/trip/sheets/MPlaceSheet.tsx +++ b/client/src/mobile/screens/trip/sheets/MPlaceSheet.tsx @@ -208,12 +208,14 @@ export default function MPlaceSheet({ planner, shell }: MTripSheetsProps) {
-
- {place.name} +
+ {/* The sheet is where a place is read in full, so its name wraps + onto as many lines as it needs, as on the desktop (#3140). */} + {place.name} {/* Accepted out of the traveller's own recordings — the same mark the desktop inspector carries. */} {place.source === 'dawarich' && ( - + )}