Skip to content

Conversation

@dhairyashiil
Copy link
Member

@dhairyashiil dhairyashiil commented Jan 5, 2026

What does this PR do?

This PR unifies dropdown menu implementations from .android.tsx files into base .tsx files so both Android and extension/web platforms share the same code. This is a stacked PR on top of #26434.

Changes:

  • Merged Android-specific dropdown implementations into 5 base component files
  • Deleted all .android.tsx files after merging
  • Replaced TouchableOpacity with Pressable for Android ripple effects
  • Added DropdownMenu components with proper safe area insets
  • Added AlertDialog for cancel confirmation on Android (BookingDetailScreen)

Components unified:

  1. EventTypeListItem - Preview, Copy link, Edit, Duplicate, Delete actions
  2. BookingListItem - Reschedule, Edit Location, Add Guests, View Recordings, etc.
  3. RecurringBookingListItem - Same booking actions for recurring events
  4. AvailabilityListItem - Set as Default, Duplicate, Delete actions
  5. BookingDetailScreen - Header dropdown with all booking actions

Updates since last revision

Unified booking filter UI for Android and extension/web:

  • Removed SegmentedControl from the bookings page - both platforms now use the Header dropdown for booking status filter (Upcoming, Unconfirmed, Past, Cancelled, Recurring)
  • Unified event type filter dropdown for both Android and web/extension
  • Removed platform-specific conditionals (Platform.OS === "android" checks) from the bookings page
  • Removed unused showFilterModal state and related code

Fixed header button clipping on web/extension (revised approach):

  • Created new HeaderButtonWrapper component that adds 12px margin on web platform only
  • Wrapped all header buttons with HeaderButtonWrapper to prevent clipping on edges
  • Applied to all screens with native header buttons:
    • reschedule.tsx, edit-location.tsx, add-guests.tsx
    • mark-no-show.tsx, view-recordings.tsx, meeting-session-details.tsx
    • event-type-detail.tsx, BookingDetailScreen.tsx, profile-sheet.tsx
    • edit-availability-day.tsx, edit-availability-name.tsx, edit-availability-override.tsx
  • Android remains unaffected as the wrapper only applies margin on web

Mandatory Tasks (DO NOT REMOVE)

  • I have self-reviewed the code (A decent size PR without self-review might be rejected).
  • I have updated the developer docs in /docs if this PR makes changes that would require a documentation change. N/A - no documentation changes needed.
  • I confirm automated tests are in place that prove my fix is effective or that my feature works.

How should this be tested?

  1. Android testing:

    • Open each screen (Event Types, Bookings, Recurring Bookings, Availability, Booking Detail)
    • Tap the three-dot menu button on list items
    • Verify dropdown menu appears with correct actions
    • Verify destructive actions (Delete, Cancel) have a separator before them
    • Test cancel booking flow - should show AlertDialog with reason input
  2. Extension/Web testing:

    • Same screens should work with the unified dropdown implementation
    • Verify android_ripple prop doesn't cause issues on non-Android platforms
    • Verify the booking status filter dropdown in the Header works (replaces the old SegmentedControl)
    • Verify the event type filter dropdown works correctly
    • Verify header buttons (X, checkmark, ellipsis) have proper spacing from edges
    • Test screens with both left and right header buttons (Reschedule, Edit Location, Add Guests)
    • Verify buttons are not touching each other or getting clipped

Human Review Checklist

  • Verify dropdown menus work correctly on web/extension (previously only used on Android)
  • Verify booking status filter (Upcoming, Unconfirmed, etc.) changes work via Header dropdown on web/extension
  • Verify event type filter dropdown works on both platforms
  • Verify header buttons have proper spacing on web/extension - buttons should not touch edges or get clipped
  • Verify Android UI is not affected by the HeaderButtonWrapper changes (wrapper only applies margin on web)
  • Verify all screens with header buttons were updated consistently

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have checked if my changes generate no new warnings

Link to Devin run: https://app.devin.ai/sessions/cc58599bc56e4651bb76fa450213311b
Requested by: Dhairyashil Shinde (@dhairyashiil)

- Merge Android-specific dropdown implementations into base component files
- EventTypeListItem: Add DropdownMenu with Preview, Copy link, Edit, Duplicate, Delete actions
- BookingListItem: Add DropdownMenu with booking actions (reschedule, edit location, add guests, etc.)
- RecurringBookingListItem: Add DropdownMenu with recurring booking actions
- AvailabilityListItem: Add DropdownMenu with Set as Default, Duplicate, Delete actions
- BookingDetailScreen: Add DropdownMenu in header for Android with AlertDialog for cancel confirmation
- Delete all .android.tsx files as implementations are now unified
@devin-ai-integration
Copy link
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR that start with 'DevinAI' or '@devin'.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

- Remove unused props from EventTypeListItem.ios.tsx (copiedEventTypeId, handleEventTypeLongPress)
- Remove unused onActionsPress prop from BookingListItem.ios.tsx
- Remove copiedEventTypeId and handleEventTypeLongPress props from index.ios.tsx and index.tsx
- Remove onLongPress and onActionsPress props from BookingListScreen.tsx
- Remove handleScheduleLongPress, setSelectedSchedule, setShowActionsModal props from AvailabilityListScreen.tsx
- Fix BookingDetailScreen.tsx to use correct action property names (reschedule.visible instead of canReschedule, etc.)
@vercel
Copy link

vercel bot commented Jan 5, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

3 Skipped Deployments
Project Deployment Review Updated (UTC)
cal Ignored Ignored Jan 5, 2026 11:44pm
cal-companion Ignored Ignored Preview Jan 5, 2026 11:44pm
cal-eu Ignored Ignored Jan 5, 2026 11:44pm

- Remove unused handleEventTypeLongPress function and ActionSheetIOS import from index.ios.tsx
- Remove unused copiedEventTypeId state, handleEventTypeLongPress function, and ActionSheetIOS import from index.tsx
- Prefix unused setSelectedBooking with underscore in BookingListScreen.tsx
- Remove unused handleScheduleLongPress function and ActionSheetIOS import from AvailabilityListScreen.tsx
- Remove SegmentedControl from web/extension booking list page
- Use Header dropdown for booking status filter on both Android and web
- Use unified event type filter dropdown for both platforms
- Remove unused showFilterModal state and related code
- Pass filterOptions, activeFilter, and onFilterChange to Header for all platforms
…n clipping

- Add headerLeftContainerStyle and headerRightContainerStyle with 12px padding for web platform
- Applied to root Stack and all nested tab Stack layouts
- Fixes issue where header buttons were touching edges and getting chopped off on extension/web
- Android remains unaffected as the fix is web-only
- Create HeaderButtonWrapper component that adds 12px margin on web only
- Wrap all header buttons with HeaderButtonWrapper to prevent clipping
- Revert invalid screenOptions changes that caused typecheck errors
- Apply fix to all screens with native header buttons:
  - reschedule.tsx, edit-location.tsx, add-guests.tsx
  - mark-no-show.tsx, view-recordings.tsx, meeting-session-details.tsx
  - event-type-detail.tsx, BookingDetailScreen.tsx, profile-sheet.tsx
  - edit-availability-day.tsx, edit-availability-name.tsx, edit-availability-override.tsx
@dhairyashiil dhairyashiil marked this pull request as ready for review January 5, 2026 23:38
@graphite-app graphite-app bot added the community Created by Linear-GitHub Sync label Jan 5, 2026
@graphite-app graphite-app bot requested a review from a team January 5, 2026 23:38
@dhairyashiil dhairyashiil removed the request for review from a team January 5, 2026 23:40
Copy link
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

1 issue found across 32 files

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them.


<file name="companion/components/booking-list-screen/BookingListScreen.tsx">

<violation number="1" location="companion/components/booking-list-screen/BookingListScreen.tsx:131">
P2: Marking `setSelectedBooking` as unused creates dead code. The `showBookingActionsModal` state (line 564) is never set to true, and `selectedBooking` is never populated after removing the handlers. Consider also removing the `showBookingActionsModal` state and the related `BookingModals` props/callbacks that depend on `selectedBooking` to complete the cleanup.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

@dhairyashiil dhairyashiil merged commit f3d9a86 into feat/companion-android-ui-upgrade Jan 5, 2026
13 of 14 checks passed
@dhairyashiil dhairyashiil deleted the feat/companion-unify-dropdown-menu-android-extension branch January 5, 2026 23:46
dhairyashiil added a commit that referenced this pull request Jan 7, 2026
* feat: companion-android-ui-upgrade version 1

* recurrings and unconfirmed booking filter and page implementation

* add badge and links to event type list page

* address cubics comments

* feat(companion): unify dropdown menu for Android and extension (#26486)

* feat(companion): unify dropdown menu for Android and extension

- Merge Android-specific dropdown implementations into base component files
- EventTypeListItem: Add DropdownMenu with Preview, Copy link, Edit, Duplicate, Delete actions
- BookingListItem: Add DropdownMenu with booking actions (reschedule, edit location, add guests, etc.)
- RecurringBookingListItem: Add DropdownMenu with recurring booking actions
- AvailabilityListItem: Add DropdownMenu with Set as Default, Duplicate, Delete actions
- BookingDetailScreen: Add DropdownMenu in header for Android with AlertDialog for cancel confirmation
- Delete all .android.tsx files as implementations are now unified

* fix(companion): fix typecheck errors after dropdown unification

- Remove unused props from EventTypeListItem.ios.tsx (copiedEventTypeId, handleEventTypeLongPress)
- Remove unused onActionsPress prop from BookingListItem.ios.tsx
- Remove copiedEventTypeId and handleEventTypeLongPress props from index.ios.tsx and index.tsx
- Remove onLongPress and onActionsPress props from BookingListScreen.tsx
- Remove handleScheduleLongPress, setSelectedSchedule, setShowActionsModal props from AvailabilityListScreen.tsx
- Fix BookingDetailScreen.tsx to use correct action property names (reschedule.visible instead of canReschedule, etc.)

* fix(companion): remove unused code after dropdown unification

- Remove unused handleEventTypeLongPress function and ActionSheetIOS import from index.ios.tsx
- Remove unused copiedEventTypeId state, handleEventTypeLongPress function, and ActionSheetIOS import from index.tsx
- Prefix unused setSelectedBooking with underscore in BookingListScreen.tsx
- Remove unused handleScheduleLongPress function and ActionSheetIOS import from AvailabilityListScreen.tsx

* feat(companion): unify booking filter UI for Android and extension

- Remove SegmentedControl from web/extension booking list page
- Use Header dropdown for booking status filter on both Android and web
- Use unified event type filter dropdown for both platforms
- Remove unused showFilterModal state and related code
- Pass filterOptions, activeFilter, and onFilterChange to Header for all platforms

* fix(companion): add header padding for web/extension to prevent button clipping

- Add headerLeftContainerStyle and headerRightContainerStyle with 12px padding for web platform
- Applied to root Stack and all nested tab Stack layouts
- Fixes issue where header buttons were touching edges and getting chopped off on extension/web
- Android remains unaffected as the fix is web-only

* fix(companion): add HeaderButtonWrapper for web-only header padding

- Create HeaderButtonWrapper component that adds 12px margin on web only
- Wrap all header buttons with HeaderButtonWrapper to prevent clipping
- Revert invalid screenOptions changes that caused typecheck errors
- Apply fix to all screens with native header buttons:
  - reschedule.tsx, edit-location.tsx, add-guests.tsx
  - mark-no-show.tsx, view-recordings.tsx, meeting-session-details.tsx
  - event-type-detail.tsx, BookingDetailScreen.tsx, profile-sheet.tsx
  - edit-availability-day.tsx, edit-availability-name.tsx, edit-availability-override.tsx

* update more ui-ux

* address cubics comments

* address cubics comments & open event type list page first for inttial render of app
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

community Created by Linear-GitHub Sync size/XXL

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants