1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-08-02 04:15:28 +02:00

fix(app): datatable global checkbox doesn't reflect the selected state (#520)

This commit is contained in:
James Player 2025-03-17 15:35:51 +13:00 committed by GitHub
parent b0de6d41b7
commit d5981a4be9
10 changed files with 114 additions and 18 deletions

View file

@ -1,9 +1,15 @@
import { addPlural } from '@/react/common/string-utils';
interface SelectedRowsCountProps {
value: number;
hidden: number;
}
export function SelectedRowsCount({ value }: SelectedRowsCountProps) {
export function SelectedRowsCount({ value, hidden }: SelectedRowsCountProps) {
return value !== 0 ? (
<div className="infoBar">{value} item(s) selected</div>
<div className="infoBar">
{addPlural(value, 'item')} selected
{hidden !== 0 && ` (${hidden} hidden by filters)`}
</div>
) : null;
}