fix(theme): clear button disabled inputs (#5607)

* fix(input): disable pointer events on clear button when inactive

* chore(changeset): add changeset
This commit is contained in:
luis angel lopez huari 2025-08-18 05:05:33 -05:00 committed by GitHub
parent 8e51a855b1
commit 928383bcfc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,5 @@
---
"@heroui/theme": patch
---
use peer-data-[filled=true]:pointer-events-none to disable clear button interaction when input is disabled and has content

View File

@ -890,6 +890,14 @@ const input = tv({
],
},
},
// isClearable & isDisabled
{
isClearable: true,
isDisabled: true,
class: {
clearButton: "peer-data-[filled=true]:pointer-events-none",
},
},
],
});

View File

@ -849,6 +849,14 @@ const numberInput = tv({
label: ["pe-2", "max-w-full", "text-ellipsis", "overflow-hidden"],
},
},
// isClearable & isDisabled
{
isClearable: true,
isDisabled: true,
class: {
clearButton: "peer-data-[filled=true]:pointer-events-none",
},
},
],
});