Skip to content
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

show more relevant presets when switching preset of an object #10138

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from

Commits on Feb 28, 2024

  1. wip: show more relevant presets when chaning preset of an object

    suggestions are based on the object's previous preset:
    * if it was part of a category, show that category again (e.g. editing a `highway=primary` will offer the "Major Roads" category)
    * if a preset has sub-presets: offer up to 5 of these (e.g. `barrier=kerb` will offer presets like Raised Curb, Lowered Curb, etc.)
    * show the "partent" i.e. more generic preset if there is a matching one
    * show up to 5 "sibling" presets
    
    this also increases the number of shown previously used presets from 4 to 5.
    
    todo:
    * should these be sorted differently, e.g. before the previously used presets)?
    * should there be a visual separation between these suggestions, the recents and the defaults
    * investigate if better candidates could be found when many siblings exist
    * add mechanism to show more related presets (or recently used presets)
    * write test cases
    tyrasd committed Feb 28, 2024
    Configuration menu
    Copy the full SHA
    89247d9 View commit details
    Browse the repository at this point in the history