Skip to content

feat: enhance map popups with dropdown menus and API links#71

Merged
fityannugroho merged 3 commits intomainfrom
feat-popup-actions
Aug 25, 2025
Merged

feat: enhance map popups with dropdown menus and API links#71
fityannugroho merged 3 commits intomainfrom
feat-popup-actions

Conversation

@fityannugroho
Copy link
Owner

🚀 Features

Enhanced Map Popup Actions

  • Improved Island Markers: Added dropdown menu with more actions and better UX
  • Enhanced Area Popups: Redesigned with dropdown menu for cleaner interface
  • API Integration: Added direct links to view API data for islands and areas

🎨 UI/UX Improvements

Island Markers

  • ✨ Added dropdown menu with "More" options
  • 🔗 New "View API data" button linking to area API endpoints
  • 📋 Better copy coordinate functionality with toast notifications
  • 🗺️ Maintained "See on Google Maps" functionality in dropdown
  • 📏 Improved popup sizing with min/max width constraints

Area Popups

  • ✨ Added dropdown menu for better action organization
  • 🔗 New "View API data" button for each area type (provinces, regencies, districts, villages)
  • 📋 Moved "Copy link" action to dropdown menu
  • 🗺️ Moved "See on Google Maps" to dropdown menu
  • 🎯 Better spacing and layout

🛠️ Technical Changes

Component Updates

  • IslandMarkers.tsx: Complete redesign with dropdown menu implementation
  • PopupArea.tsx: Enhanced with dropdown menu and better action organization
  • Added modal={false} to prevent unwanted modal behavior in map context
  • Added onCloseAutoFocus prevention for better map interaction

Styling Fixes

  • globals.css: Fixed link color inheritance in leaflet containers with !important override
  • Added proper color inheritance for links within map popups

🔧 Dependencies

  • Utilizes existing UI components: DropdownMenu, Button
  • Added new Lucide React icons: MoreVerticalIcon, ExternalLinkIcon, ClipboardIcon
  • Integrates with existing config and endpoints from lib

📱 User Experience

  • More organized actions in dropdown menus
  • Better visual hierarchy with buttons and dropdowns
  • Consistent styling across island markers and area popups
  • Improved accessibility with proper ARIA labels
  • Toast notifications for user feedback

🧪 Testing

  • Dropdown menus work correctly in map popup context
  • API links navigate to correct endpoints
  • Copy actions provide proper user feedback
  • Google Maps links function as expected
  • No modal interference with map interactions

@fityannugroho fityannugroho added the enhancement New feature or request label Aug 25, 2025
@fityannugroho fityannugroho requested a review from Copilot August 25, 2025 09:55

This comment was marked as outdated.

@fityannugroho fityannugroho requested a review from Copilot August 25, 2025 10:53
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enhances the map popup experience by introducing dropdown menus for both island markers and area popups, providing better organization of actions and adding API data access links.

  • Added dropdown menus to consolidate actions in popups for better UX
  • Integrated API data links for direct access to area and island data endpoints
  • Improved popup styling with consistent button layouts and proper width constraints

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
modules/MapDashboard/PopupArea.tsx Redesigned area popups with dropdown menu containing copy link and Google Maps actions, plus new API data button
modules/MapDashboard/IslandMarkers.tsx Complete redesign of island markers with dropdown menu for coordinate copying and Google Maps, plus API data button
app/globals.css Fixed link color inheritance in leaflet containers to prevent styling conflicts

@fityannugroho fityannugroho merged commit 1fed56d into main Aug 25, 2025
6 checks passed
@fityannugroho fityannugroho deleted the feat-popup-actions branch August 25, 2025 11:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant