Open Bebick opened 1 year ago
Please fork and make a PR. It is easier to see what you mean that way.
Okay I did that. My code is here: https://github.com/Bebick/WLED-main-4
I am not sure that what you try to do is a good idea. Hiding away parts of the settings pages is going to cause lots of confusion. It might give us a load of support requests if that code becomes part of WLED. In addition, we would need to rewrite docs to explain the concept, and what is visible in each user level, and why certain things are not visible.
WLED is written assuming that all settings will be availeable for users. Removing some pages may lead to very unexpected consequences.
I'm not sure why you want to hide away usermod setup? If people build WLED with usermods enabled, why should usermod setting be hidden?
please do not include a plain text password inside the JS parts. JS is delivered to the browser, and anybody who knows how to start IE developer mode will be able to retrieve it.
what "other web pages" would you like to split up? And why?
WLED is for users, so what is the reason to introduce a "developer mode" ? As a developer, I would compile with -D WLED_DEBUG
but I don't know what additional WLED "features for developers only" do you mean?
Maybe I need to better understand the motivation behind this proposal - can you describe a realistic use case where several user levels would be needed?
With settings, my stance is always "if you don't know what it does, leave it be", as such personally I see settings "advancedness" modes as an overhead and always set them to the highest level in every program even if I am just a novice user.
Given that not everyone might share this opinion though and many settings may overwhelm some users, I'd be open to include a Basic/Advanced toggle in the upcoming settings rework. I don't see any reason for a developer mode either though, "developer-only" settings are realized with compile flags :) And I just have no idea why one would password-protect advanced settings mode, sorry.
First of all, thank you for your opinion.
So I would also say that the developer mode is not absolutely necessary.
For me, the motivation behind it was that there are perhaps "too many" settings for some users, which you might need once a year and can therefore also hide. And the whole realized via the user and expert mode. It would be best if this mode is usable for multiple pages - so to set a kind of variable when the mode is on and this variable you can then arbitrarily in the sections you want to have hidden. So everyone can still customize the pages individually and it does not have to be adapted the complete documentation. But only a short explanation how to deal with this variable.
Hello all,
I think the software is great, but I don’t always want to have all settings displayed. For me it is clearer if some settings are hidden. Therefore I implemented a query to check in which user mode I am.
There are 3 user modes: User / Expert and Developer.
The two modes user and expert can be displayed via drop down menu. The expert mode is only activated after entering a password. In the expert mode, further functions are then displayed.
The Developer mode is activated at the bottom via a checkbox and another password request. If this mode is activated, all functions of the current page are displayed.
Now I would like to transfer these 3 user levels to other websites and use these functions there as well. Currently the code is only used on the Settings_UI page.
Do you have an idea how I can realize this?
If you see further optimizations of this code, please let me know :).