Button: Conflicting disabled state during loading
Describe the bug
The Button component has a loading prop to disable the button and show a spinner.
If the loading prop is true: The disabled attribute is set, as well as data-p-disabled="true"
<button class="p-button p-component p-button-loading" type="button" aria-label="Button" data-pc-name="button" data-p-disabled="true" pc0="" data-pc-section="root" disabled="">....</button>
However if while loading=true disabled=false the buttons disabled state is in an unclear state.
The disabled attribute is missing, while data-p-disabled="true".
<button class="p-button p-component p-button-loading" type="button" aria-label="Button" data-pc-name="button" data-p-disabled="true" pc0="" data-pc-section="root">....</button>
Pull Request Link
https://github.com/primefaces/primevue/pull/7712
Reason for not contributing a PR
- [ ] Lack of time
- [ ] Unsure how to implement the fix/feature
- [ ] Difficulty understanding the codebase
- [ ] Other
Other Reason
No response
Reproducer
https://stackblitz.com/edit/primevue-4-vite-issue-template-pkrbvmge
Environment
Stackblitz
Vue version
3.5.13
PrimeVue version
4.3.6
Node version
No response
Browser(s)
No response
Steps to reproduce the behavior
- Go to StackBlitz reproducer
- See button is loading but not disabled
Expected behavior
The button should always be disabled if it is loading, ignoring the value of the disabled prop
Update: Still an issue with PrimeVue 4.3.6
Still doesn't work with primevue 4.4.1