-
Notifications
You must be signed in to change notification settings - Fork 2k
Description
📌 Description
Hi!
Several visual elements, such as selector, button, or scenario have an active argument, which defaults to True and can be set to False. When set to False (usually with a bound variable that I interact with from a callback), it makes the element inactive. This is super useful to prevent changing bound variables or triggering a callback while a certain callback is already running.
In the case of a scenario_selector, we can have an on_change callback, an on_creation callback, as well as a bound variable: Adding an active parameter could help deal with unstable situations.
I specifically encountered a small issue in an app I coded that could benefit from such evolution, but I think that this optional parameter could be added to any visual element that either changes bound variables or triggers callbacks --> It seems to only be missing in other Scenario controls, like data_node_selector, job_selector and scenario_dag.
📜 Code of Conduct
- I have checked the existing issues to avoid duplicates.
- I am willing to work on this issue (optional)
✅ Acceptance Criteria
- The refactored code maintains existing functionality without breaking changes.
- Any new code is covered by unit tests.
- Code coverage remains at least 90%.
- Performance improvements are documented, if applicable.