Prerequisites
Describe the issue
When there is a onClick handler passed in the slot, the function will still be triggered:
<sgds-link disabled>
<a href='#' onClick={handleClick}>Link</a>
</sgds-link>
Solution: we could try to use the CSS pointer-events: none on disabled to prevent any events from bubbling down to the slots.
What operating system(s) are you seeing the problem on?
macOS
What browser(s) are you seeing the problem on?
Chrome
Describe your frontend stack. What version of React and @govtechsg/sgds-web-component are you using? CSR or SSR?
react-19
Prerequisites
Describe the issue
When there is a onClick handler passed in the slot, the function will still be triggered:
Solution: we could try to use the CSS pointer-events: none on disabled to prevent any events from bubbling down to the slots.
What operating system(s) are you seeing the problem on?
macOS
What browser(s) are you seeing the problem on?
Chrome
Describe your frontend stack. What version of React and @govtechsg/sgds-web-component are you using? CSR or SSR?
react-19