feat: Enhance message handling for drawings

- Added properties to the Message model to track drawing status and associated drawing ID.
- Updated AppProvider to mark messages as drawings and link them to their respective drawing IDs.
- Enhanced DrawingProvider to manage received drawings and their visibility.
- Implemented navigation to drawings in MapProvider, including dynamic zoom levels based on drawing size.
- Updated MessagesProvider to parse drawing messages and manage linked drawings.
- Enhanced MessagesTab to support drawing message interactions, including navigation and coordinate copying.
- Created DrawingMinimapPreview widget for visual representation of drawings in message bubbles.
- Improved DrawingToolbar to handle sharing of drawings, ensuring only unshared drawings are sent.
- Added utility functions in DrawingMessageParser for extracting drawing metadata.
This commit is contained in:
Janez T
2025-10-23 20:14:51 +02:00
parent f32667997e
commit 1688d6f538
25 changed files with 1504 additions and 114 deletions

View File

@@ -3188,6 +3188,72 @@ abstract class AppLocalizations {
/// In en, this message translates to:
/// **'Medical Team'**
String get sampleMedicalTeam;
/// Label for map drawing messages
///
/// In en, this message translates to:
/// **'Map Drawing'**
String get mapDrawing;
/// Option to navigate to drawing on map
///
/// In en, this message translates to:
/// **'Navigate to Drawing'**
String get navigateToDrawing;
/// Option to copy coordinates to clipboard
///
/// In en, this message translates to:
/// **'Copy Coordinates'**
String get copyCoordinates;
/// Option to hide drawing from map
///
/// In en, this message translates to:
/// **'Hide from Map'**
String get hideFromMap;
/// Label for line type drawings
///
/// In en, this message translates to:
/// **'Line Drawing'**
String get lineDrawing;
/// Label for rectangle type drawings
///
/// In en, this message translates to:
/// **'Rectangle Drawing'**
String get rectangleDrawing;
/// Success message when coordinates are copied
///
/// In en, this message translates to:
/// **'Coordinates copied to clipboard'**
String get coordinatesCopiedToClipboard;
/// Label for shared drawing notifications
///
/// In en, this message translates to:
/// **'Map Drawing'**
String get drawingShared;
/// Success message when drawing is hidden
///
/// In en, this message translates to:
/// **'Drawing hidden from map'**
String get drawingHidden;
/// Message showing how many drawings were already shared
///
/// In en, this message translates to:
/// **'{count, plural, =1{1 already shared} other{{count} already shared}}'**
String alreadyShared(int count);
/// Success message after sharing new drawings
///
/// In en, this message translates to:
/// **'Shared {count} new drawing{plural}'**
String newDrawingsShared(int count, String plural);
}
class _AppLocalizationsDelegate