Merged
Conversation
- add/edit/delete icon in activity - show activity's icon in activity - refactor other places to use useCallback too
5b2a138 to
b71aceb
Compare
There was a problem hiding this comment.
Pull request overview
This PR adds customizable emoji icons for activities, addressing feature request #107. The implementation allows users to replace default map pins with custom emoji icons (e.g., 🍴 for restaurants) to improve visual identification on maps and throughout the UI.
Changes:
- Introduces new
EmojiTextFieldcomponent with comprehensive keyboard navigation and accessibility features - Updates database schema to add optional
iconfield to activities - Refactors form event handlers across multiple components to use extracted
useCallbackhooks with proper TypeScript types - Integrates icon display throughout activity UI (forms, dialogs, lists, map markers)
Reviewed changes
Copilot reviewed 24 out of 25 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/common/EmojiTextField/EmojiTextField.tsx | New comprehensive emoji picker component with keyboard navigation and ARIA support |
| src/common/EmojiTextField/EmojiTextField.module.css | Styles for emoji picker including grid layout, accessibility classes, and responsive design |
| instant.schema.ts | Adds optional icon string field to activity schema |
| src/Activity/db.ts | Updates DbActivity type to include optional icon field with comment |
| src/Activity/ActivityForm/ActivityForm.tsx | Integrates EmojiTextField component and handles icon in form submission |
| src/Activity/Activity.tsx | Displays icon with activity title and includes icon in memo comparison |
| src/Activity/ActivityIdea/ActivityIdea.tsx | Shows icon with activity title for idea items |
| src/Activity/ActivityDialog/*.tsx | Updates dialog components to display icon with activity title |
| src/Map/marker.ts | Uses custom icon for map markers when available |
| src/Map/constants.ts | Adds customIcon field to MarkerLocation types |
| src/Map/TripMap.tsx | Passes icon to map markers, null for destinations/accommodations |
| src/Map/popups/ActivityPopup.tsx | Displays icon in activity popup title |
| src/Trip/store/types.ts | Updates query return type to include icon field |
| package.json | Adds @emoji-mart/data dependency, updates @types/react version |
| src/{Trip,Macroplan,Comment,Account,Accommodation}/Form*.tsx | Refactors form handlers to extracted useCallback hooks |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 24 out of 25 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Fixes #107
Introduce idea of having customizable icon for activity, with emoji selector in activity form. Can be used to replace icon in map too