Skip to content

Change renderExtraExportMenuItems to an array of ReactNodes#1205

Open
juhanikat wants to merge 2 commits into
mainfrom
change-extramenuitems-to-array
Open

Change renderExtraExportMenuItems to an array of ReactNodes#1205
juhanikat wants to merge 2 commits into
mainfrom
change-extramenuitems-to-array

Conversation

@juhanikat

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 updates the TableView/TableToolBar export-menu extension point so callers can provide multiple extra export items instead of a single one, and updates existing tables to use the new shape.

Changes:

  • Change renderExtraExportMenuItems from a single render function to an array of render functions.
  • Render the extra export items by iterating the array in TableToolBar.
  • Update SpeciesTable, LocalityTable, and CrossSearchTable call sites to pass arrays.

Reviewed changes

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

Show a summary per file
File Description
frontend/src/components/TableView/TableView.tsx Updates the renderExtraExportMenuItems prop type to support multiple items.
frontend/src/components/TableView/TableToolBar.tsx Updates prop typing and renders multiple extra export menu items.
frontend/src/components/Species/SpeciesTable.tsx Wraps the existing extra export menu item in an array.
frontend/src/components/Locality/LocalityTable.tsx Wraps the existing extra export menu item in an array.
frontend/src/components/CrossSearch/CrossSearchTable.tsx Converts multiple extra export items from a fragment to an array.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread frontend/src/components/TableView/TableView.tsx Outdated
Comment thread frontend/src/components/TableView/TableToolBar.tsx Outdated
Comment thread frontend/src/components/TableView/TableToolBar.tsx Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Change renderExtraExportMenuItems in tables from a Fragment to an array of MenuItems

2 participants