This commit is contained in:
Dobromir Popov
2024-04-30 17:42:11 +03:00
parent 4ef2e60c30
commit e3d75180d7

View File

@ -109,20 +109,20 @@ function PublishersPage({ publishers = [] }: IProps) {
if (shownPubs.length === 0) { if (shownPubs.length === 0) {
return ( return (
<div className="flex justify-center"> <div className="flex justify-center">
<a <button
className="btn" className="px-4 py-2 text-white bg-blue-500 rounded hover:bg-blue-600 focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2"
href="javascript:void(0);"
onClick={() => { onClick={() => {
setFilter(""); setFilter(""); // Assuming setFilter directly updates the filter state
handleFilterChange({ target: { value: "" } }); if (typeof handleFilterChange === 'function') {
handleFilterChange({ target: { value: "" } }); // If needed for additional logic
}
}} }}
> >
Clear filters Clear filters
</a> </button>
</div> </div>
); );
} } else {
else {
return shownPubs.map((publisher) => ( return shownPubs.map((publisher) => (
<PublisherCard key={publisher.id} publisher={publisher} /> <PublisherCard key={publisher.id} publisher={publisher} />
)); ));