vinistock / sail

Sail is a lightweight Rails engine that brings an admin panel for managing configuration settings on a live Rails app
Other
507 stars 32 forks source link

Reducing visual complexity: Disable save buttons until setting is changed? Hide type label? #340

Closed denny closed 3 years ago

denny commented 3 years ago

Hiya :) I've been thinking about ways to make the settings page less busy - once you fill it up with cards there's a lot of detail on there to take in at a glance.

One thing that I thought might help was if the settings card SAVE buttons were all in a disabled greyed-out state initially, only changing to active eye-catching tangerine when that particular setting has been changed.

Relatedly, I'd be interested in having the option to show/hide different parts of the card UI, maybe as a set of config options... or even a way to override the card template? For instance, I don't think the end-users of my CMS will care about whether a setting is a 'boolean', a 'float', etc, so that label is one detail I would hide by default - again to reduce the overall complexity of the settings page.

vinistock commented 3 years ago

Hey! I like the idea of being able to customize cards. It'll make the presentation flexible and each application can decide what to display.

I know some other Rails engines do this, such as Devise, which allows users to generate views and edit them. I'll take a look at how it's done so that we can have a similar feature in Sail. Maybe it's just a matter of adding a views generator that creates the HTML files in the right folder structure.

And concerning the button, I think that should be a part of the engine itself. Shouldn't need too much other than some JavaScript to change the state of the button once the value of the input changes. I'll look into that too. Thanks!