Repository navigation
feat(render_map_tool): results carousel instead of the side list - #292
Open
mattpodwysocki wants to merge 7 commits into
Open
mattpodwysocki wants to merge 7 commits into
mattpodwysocki wants to merge 7 commits into
Conversation
Place results now show as swipeable cards along the bottom of the map, like ChatGPT's place results. The selected card and its pin stay in sync: swiping or clicking a card highlights its pin (white, on top, with the name under it) and pans only when the pin is hidden; clicking a pin scrolls to its card. Pins with a card no longer open popups. Cards show today's hours parsed from simple OSM opening_hours. Closes #283 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Found in a headless render: a pin just above the carousel kept its name label hidden behind the cards. Pan when the label (not just the pin) would be hidden, do it for pin clicks too, and pan only as far as needed instead of recentering, so nearby pins stay in view. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The "6 results for ..." chip sat on top of the zoom-in button. Same placeTopLeftControls fix as #278, copied as-is so the two merge cleanly. Co-Authored-By: Claude Opus 5.5 <[email protected]>
- Every card has a picture: Assembly's marker icon on a muted tile until a photo loads, or when there is none, labeled for screen readers. - Pin numbers pick dark or white text by WCAG contrast; white on the default orange was 2.8:1. - The tool description asks the model not to repeat the places the cards already show. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ange numbers Matches ChatGPT's place results and OpenAI's UI guidance: search results and other places in the carousel are white pins with a Maki icon for their category, black when selected, and their cards drop the number badge. The icon comes from Search Box's maki name, else the category, else a plain marker; about 20 common Maki icons (CC0) are inlined. Numbered badges stay where the number means something: a caller's numbered label (visit order), optimized stops, start/end. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The cards, summary chip, legend and messages follow the host's theme (MCP Apps hostContext.theme, at initialize and on host-context-changed), falling back to prefers-color-scheme. Colors use the host's style variables (--color-background-primary etc.) when sent, with light/dark fallbacks otherwise. The map and its pins are unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Moves
render_map_tool's numbered side list to a results carousel along the bottom of the map, the pattern ChatGPT uses for its built-in place results. Closes #283.makiname, else matched from the category, else a plain marker), turning black when selected, like ChatGPT's place results and OpenAI's layout guidance. About 20 common icons are inlined (~12 KB, CC0). Numbered badges stay where the number means something: a caller's numberedlabel(visit order), optimized stops, start/end.opening_hoursfor simple rules (Mo-Fr 07:00-19:00; Sa,Su 08:00-17:00,Su off,24/7, wrap-around day ranges). Anything else shows no hours rather than wrong ones. No "Open now", since the viewer's clock may be in a different time zone than the place.hostContext.themeatui/initializeand onhost-context-changed), falling back toprefers-color-scheme, and use the host's style variables (--color-background-primary,--color-text-primary, …) when sent. The map and pins look the same in both.Notes
resources/read(open question on render_map_tool: bottom carousel for place results on narrow/inline maps #283).Testing
npm test: 1117 pass. New tests cover card/pin selection, pin click scrolling to its card, swipe selection, pan-only-when-hidden, fit padding with the carousel, legend position, and 11 hours-parsing cases.npm run lint,tsc,npm run buildclean.category_search_toolresult (coffee near SF City Hall): cards, photos, hours and phone all fill in, and card click, pin click and selection sync work. That pass found a pin just above the cards whose name label was hidden behind them, fixed in the second commit (pan when the label is hidden, and only as far as needed). It also showed the summary chip covering the zoom-in button (already the case on main); the third commit moves the zoom buttons below it, copying feat(render_map_tool): live traffic and Satellite/Traffic buttons on the map #278'splaceTopLeftControlsas-is so the two PRs merge cleanly.Checklist
🤖 Generated with Claude Code