Add "Load from URL" tab to GTFS selector - #13
Merged
Conversation
Add a new UrlInput component and tab that allows users to paste a GTFS feed URL directly. The tab is enabled by default and appears between the file import and source search tabs. No URL format validation is performed per design. https://claude.ai/code/session_01C57bNoi7igqU1xEtLS2Coy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds a new "Load from URL" feature to the GTFS selector, allowing users to input a GTFS feed URL directly instead of only being able to upload files or search predefined sources.
Key Changes
UrlInputcomponent: A reusable form component that accepts a GTFS feed URL, trims whitespace, and calls a callback with the resultGtfsSelectoras a new tab option alongside file import and source searchUrlInputandUrlInputPropsfrom the main index for standalone useImplementation Details
UrlInputcomponent uses React hooks (useState,useCallback) for state managemente.preventDefault()and validates that the URL is not empty after trimmingGtfsSelectorhttps://claude.ai/code/session_01C57bNoi7igqU1xEtLS2Coy