kpi is the server for KoboToolbox. It includes an API for users to access data and manage their forms, question library, sharing settings, create reports, and export data.
When I click the x button to close a project it returns to My Projects rather than going back to the project view I was in. My expectation would be to go back to the project view with the same filters/sorting applied.
All the filters and sorting are being remembered on the endpoint, so a simple const navigate = useNavigate(); navigate(-1); should get us almost everything w need.
The optional improvement here would be to ensure that the project we are going back from is being displayed in the table. So if user was scrolling down on the table and loaded further pages, going back would also load these pages and scroll down the project row into view (like Element.scrollIntoView())
Let's address this:
All the filters and sorting are being remembered on the endpoint, so a simple
const navigate = useNavigate(); navigate(-1);
should get us almost everything w need.The optional improvement here would be to ensure that the project we are going back from is being displayed in the table. So if user was scrolling down on the table and loaded further pages, going back would also load these pages and scroll down the project row into view (like
Element.scrollIntoView()
)