import React from 'react';
import { PHXDropdown } from '../Dropdown';
const optionNumber = [150, 125, 100, 75, 50, 25, 10];
function PaginationSelectedV5({ rowQuantity, setIsChangeRowQty, setRowQuantity, routerPush, searchParams, tableKey, setCurrentPage, setPagi, paginationData, setAfterRecord, setBeforeRecord, }) {
    const options = optionNumber.map((item) => ({
        content: item + '',
        active: rowQuantity === item,
        onClick: () => {
            setRowQuantity(item);
            setIsChangeRowQty(true);
            const params = new URLSearchParams(searchParams + '');
            params.set(`row-${tableKey}`, item + '');
            params.set(`pagi-${tableKey}`, '1');
            params.delete(`after-${tableKey}`);
            params.delete(`before-${tableKey}`);
            setCurrentPage(1);
            setPagi(0);
            paginationData(0);
            setAfterRecord('');
            setBeforeRecord('');
            routerPush(`?${params + ''}`);
        },
    }));
    return (React.createElement("div", { className: 'relative' },
        React.createElement("div", { className: 'absolute bottom-0 top-0 flex items-center gap-x-1' },
            React.createElement(PHXDropdown, { buttonContent: `${rowQuantity}`, options: options, origin: 'top-left', type: 'default' }),
            React.createElement("div", { className: 'w-24 text-xs' }, "b\u1EA3n ghi/trang"))));
}
export default PaginationSelectedV5;
//# sourceMappingURL=PaginaitonSelectedV5.js.map