Closed kirillplatonov closed 3 months ago
Hi @kirillplatonov
I came from the v2.2.2 release note and found the functionality of the disable/enable function seems to have become a purely UI change after this PR. Does this mean that users need to manually change the button's disabled state, rather than continuing to rely on the function in the button controller after this release?
The functionality should be the same. When the button is disabled we ignoring future clicks until it's enabled again: https://github.com/baoagency/polaris_view_components/blob/main/app/assets/javascripts/polaris_view_components/button_controller.js#L8
I updated preview for this feature to better demonstrate how it works. If it's not working for you then it's probably a bug. https://polarisviewcomponents.org/lookbook/inspect/button/disable_with_actions
Changes in this PR must only improve the internal implementation to better work with external controller (eg when button state is managed by form controller and synchronized with App Bridge save bar).
Value attributes are more reliable when button state changed by external Stimulus controller.