Skip to content

Allow to set the maximum number of transfers in the UI #910

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

schaerfo
Copy link
Contributor

This is how it looks:

grafik

Feel free to make changes, I am not very familiar with CSS/Tailwind

@traines-source
Copy link
Contributor

A maxTransfers UI element is added for the isochrones over in #891 as well. While I don't recall rn how the unlimited transfers case was handled there (although actually it's not unlimited, but 14 :), I think we should unify this between the two – especially since the isochrones tab is already reusing the AdancedOptions component. And I personally think that a dropdown like over there or maybe a input type="number" should be sufficient.

@MichaelKutzner
Copy link
Contributor

Thank you for bringing this to my attention.
For isochrones, the upper limit is set to match the server limit. As the number isn't that high, I found a drop-down menu still easy to use.
Right now, this option is not enabled on the “Connection” tab. But this can be changes without much afford.
The current design looks like that:
image

@MichaelKutzner
Copy link
Contributor

With #891 merged, I made the adjustments to show the dropdown to select maxTransfers for connection searches as well: MichaelKutzner@9af2884
As I don't know, what options are reasonable for maxTravelTime here, the corresponding dropdown is disabled for now.
Do you plan to update your Pull Request? Or should I create a new one for this?

@schaerfo
Copy link
Contributor Author

Great, I'll take a look at the NumberSelect you merged and update this PR

@schaerfo schaerfo force-pushed the feature/ui-max-transfers branch from 08405e6 to 36a5523 Compare July 12, 2025 20:04
@schaerfo
Copy link
Contributor Author

Ok, I rebased the patch and it got a quite a bit smaller :) It now looks like this:
grafik

  • The connections and isochrones tabs share state, so setting max transfers in one tab will also change it in the other
  • I removed the switch to enable limiting the number of transfers

@traines-source
Copy link
Contributor

traines-source commented Jul 14, 2025

Nice, what do you think, what is less confusing? Always showing the actual technical upper limit of 14 transfers or showing some special label like "Unlimited" for that in the dropdown which is technically wrong?
Also, the Linter is unhappy, you can probably just run (p)npm run format

@felixguendling
Copy link
Member

some special label like "Unlimited"

I think the concrete number is better. Maybe even configurable in the server because for small datasets a smaller number might improve performance without any disadvantage for the user.

@traines-source
Copy link
Contributor

traines-source commented Jul 14, 2025

configurable in the server

Ok but I think this is out of scope for this PR, since we have no straightforward way yet to pass this to the UI.
I.e. we can leave everything as it is apart from the formatting/linting.

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.

4 participants