Skip to content

Simplify preset management on Generate page #181

@MassHesteria

Description

@MassHesteria

The process of adding a new preset to the Generate page is cumbersome at the moment. It looks like this:

  • Add an entry to presets.ts with each setting defined based on params.ts
  • Add a mode in GenerateFormParams
  • Add an entry to the MODES object with each setting defined in form.tsx
  • Add code to onSubmit() to map the preset name to the mode name
  • Add an entry to the Mode <Select>

For a preset that should be the default:

  • Update all other <Select> elements so that there first option matches the option used in the default preset

The code looks up the mode based on the default settings when the page is first loaded to pick the default Preset. This is much to complicated.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions