@ui5/webcomponents-react
Version:
React Wrapper for UI5 Web Components and additional components
37 lines (36 loc) • 1.59 kB
JavaScript
'use client';
import '@ui5/webcomponents/dist/TableGrowing.js';
import { withWebComponent } from '@ui5/webcomponents-react-base';
/**
* The `TableGrowing` component is used inside the `Table` to add a growing/data loading functionalities
* to the table.
*
* The component offers two options:
* * Button - a More button is displayed, clicking it will load more data.
* * Scroll - additional data is loaded automatically when the user scrolls to the end of the table.
*
* ### Usage
*
* The `TableGrowing` component is only used inside the `Table` component as a feature.
* It has to be slotted inside the `Table` in the `features` slot.
* The component is not intended to be used as a standalone component.
*
* ```html
* <Table>
* <TableGrowing mode="Button" text="More" slot="features"></TableGrowing>
* </Table>
* ```
*
* **Notes**:
* * When the `TableGrowing` component is used with the `Scroll` mode and the table is currently not scrollable,
* the component will render a growing button instead to ensure growing capabilities until the table becomes scrollable.
*
*
*
* __Note:__ This is a UI5 Web Component! [TableGrowing UI5 Web Component Documentation](https://ui5.github.io/webcomponents/components/TableGrowing) | [Repository](https://github.com/UI5/webcomponents)
*
* @since [2.0.0](https://github.com/UI5/webcomponents/releases/tag/v2.0.0) of __@ui5/webcomponents__.
*/
const TableGrowing = withWebComponent('ui5-table-growing', ['mode', 'subtext', 'text'], [], [], ['load-more']);
TableGrowing.displayName = 'TableGrowing';
export { TableGrowing };