How to use the patternfly-react.Paginator.propTypes function in patternfly-react

To help you get started, we’ve selected a few patternfly-react examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Katello / katello / webpack / components / PaginationRow / index.js View on Github external
onChange: () => {},
  ...Paginator.defaultProps,
};

PaginationRow.propTypes = {
  /** page and per-page selection callback */
  onChange: PropTypes.func,
  pagination: PropTypes.shape({
    /** the current page */
    page: PropTypes.number,
    /** the current per page setting */
    perPage: PropTypes.number,
    /** per page options */
    perPageOptions: PropTypes.array,
  }),
  ...Paginator.propTypes,
};

export default PaginationRow;
github theforeman / foreman / webpack / assets / javascripts / react_app / components / Pagination / PaginationWrapper.js View on Github external
onPerPageSelect={onPerPageSelectUpdate}
      dropdownButtonId={dropdownButtonId}
      pagination={initPagination(pagination)}
      {...otherProps}
    />
  );
};

PaginationWrapper.defaultProps = {
  onChange: () => {},
  viewType: 'list',
  ...Paginator.defaultProps,
};

PaginationWrapper.propTypes = {
  ...Paginator.propTypes,
  /** page and per-page selection callback */
  onChange: PropTypes.func,
  /** view type */
  viewType: PropTypes.string,
  /** pagination */
  pagination: PropTypes.shape({
    /** the current page */
    page: PropTypes.number,
    /** the current per page setting */
    perPage: PropTypes.number,
    /** per page options */
    perPageOptions: PropTypes.arrayOf(PropTypes.number),
  }),
};

export default PaginationWrapper;