diff --git a/components/lib/autocomplete/AutoComplete.js b/components/lib/autocomplete/AutoComplete.js index fadf1b6803..c330e29a28 100644 --- a/components/lib/autocomplete/AutoComplete.js +++ b/components/lib/autocomplete/AutoComplete.js @@ -454,7 +454,8 @@ export const AutoComplete = React.memo(React.forwardRef((props, ref) => { }); React.useImperativeHandle(ref, () => ({ - search + search, + ...ref })); const createSimpleAutoComplete = () => { diff --git a/components/lib/blockui/BlockUI.js b/components/lib/blockui/BlockUI.js index b8c49ad833..d28c9d9724 100644 --- a/components/lib/blockui/BlockUI.js +++ b/components/lib/blockui/BlockUI.js @@ -64,7 +64,8 @@ export const BlockUI = React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ block, - unblock + unblock, + ...ref })); const createMask = () => { diff --git a/components/lib/calendar/Calendar.js b/components/lib/calendar/Calendar.js index 0e03e7f785..d63076dee7 100644 --- a/components/lib/calendar/Calendar.js +++ b/components/lib/calendar/Calendar.js @@ -2484,7 +2484,8 @@ export const Calendar = React.memo(React.forwardRef((props, ref) => { hide, getCurrentDateTime, getViewDate, - updateViewDate + updateViewDate, + ...ref })); const createBackwardNavigator = (isVisible) => { diff --git a/components/lib/captcha/Captcha.js b/components/lib/captcha/Captcha.js index b3a9876f05..4cde81ae7b 100644 --- a/components/lib/captcha/Captcha.js +++ b/components/lib/captcha/Captcha.js @@ -82,7 +82,8 @@ export const Captcha = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ reset, - getResponse + getResponse, + ...ref })); const otherProps = ObjectUtils.findDiffKeys(props, Captcha.defaultProps); diff --git a/components/lib/chart/Chart.js b/components/lib/chart/Chart.js index c61cddd646..e29324911e 100644 --- a/components/lib/chart/Chart.js +++ b/components/lib/chart/Chart.js @@ -35,7 +35,8 @@ export const Chart = React.memo(React.forwardRef((props, ref) => { getChart: () => chartRef.current, getBase64Image: () => chartRef.current.toBase64Image(), generateLegend: () => chartRef.current && chartRef.current.generateLegend(), - refresh: () => chartRef.current && chartRef.current.update() + refresh: () => chartRef.current && chartRef.current.update(), + ...ref })); React.useEffect(() => { diff --git a/components/lib/confirmdialog/ConfirmDialog.js b/components/lib/confirmdialog/ConfirmDialog.js index 1ea2ac4599..6fad13678c 100644 --- a/components/lib/confirmdialog/ConfirmDialog.js +++ b/components/lib/confirmdialog/ConfirmDialog.js @@ -94,7 +94,8 @@ export const ConfirmDialog = React.memo(React.forwardRef((props, ref) => { }); React.useImperativeHandle(ref, () => ({ - confirm + confirm, + ...ref })); const createFooter = () => { diff --git a/components/lib/confirmpopup/ConfirmPopup.js b/components/lib/confirmpopup/ConfirmPopup.js index 2fa8940e9a..6ec85a1ca4 100644 --- a/components/lib/confirmpopup/ConfirmPopup.js +++ b/components/lib/confirmpopup/ConfirmPopup.js @@ -179,7 +179,8 @@ export const ConfirmPopup = React.memo(React.forwardRef((props, ref) => { }); React.useImperativeHandle(ref, () => ({ - confirm + confirm, + ...ref })); const createContent = () => { diff --git a/components/lib/contextmenu/ContextMenu.js b/components/lib/contextmenu/ContextMenu.js index ef94d158ba..a3db4145b1 100644 --- a/components/lib/contextmenu/ContextMenu.js +++ b/components/lib/contextmenu/ContextMenu.js @@ -165,7 +165,8 @@ export const ContextMenu = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ show, - hide + hide, + ...ref })); const createContextMenu = () => { diff --git a/components/lib/datascroller/DataScroller.js b/components/lib/datascroller/DataScroller.js index 19b868b1ea..aae82381f1 100644 --- a/components/lib/datascroller/DataScroller.js +++ b/components/lib/datascroller/DataScroller.js @@ -142,7 +142,8 @@ export const DataScroller = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ load, - reset + reset, + ...ref })); const createHeader = () => { diff --git a/components/lib/datatable/DataTable.js b/components/lib/datatable/DataTable.js index 11c53fdbfb..745be39f3f 100644 --- a/components/lib/datatable/DataTable.js +++ b/components/lib/datatable/DataTable.js @@ -1324,7 +1324,8 @@ export const DataTable = React.forwardRef((props, ref) => { resetColumnOrder, closeEditingCell, restoreTableState, - clearState + clearState, + ...ref })); const createLoader = () => { diff --git a/components/lib/dialog/Dialog.js b/components/lib/dialog/Dialog.js index 2adcf2ae07..179c275234 100644 --- a/components/lib/dialog/Dialog.js +++ b/components/lib/dialog/Dialog.js @@ -399,7 +399,8 @@ export const Dialog = React.forwardRef((props, ref) => { }); React.useImperativeHandle(ref, () => ({ - resetPosition + resetPosition, + ...ref })); const createCloseIcon = () => { diff --git a/components/lib/editor/Editor.js b/components/lib/editor/Editor.js index f8ad8f9393..b56299182b 100644 --- a/components/lib/editor/Editor.js +++ b/components/lib/editor/Editor.js @@ -86,7 +86,8 @@ export const Editor = React.memo(React.forwardRef((props, ref) => { }, [props.value]); React.useImperativeHandle(ref, () => ({ - getQuill + getQuill, + ...ref })); const createToolbarHeader = () => { diff --git a/components/lib/fileupload/FileUpload.js b/components/lib/fileupload/FileUpload.js index 8e5084dce4..a082085d8e 100644 --- a/components/lib/fileupload/FileUpload.js +++ b/components/lib/fileupload/FileUpload.js @@ -315,7 +315,8 @@ export const FileUpload = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ upload, clear, - formatSize + formatSize, + ...ref })); const createChooseButton = () => { diff --git a/components/lib/galleria/Galleria.js b/components/lib/galleria/Galleria.js index 979a601fad..bf39c1e1de 100644 --- a/components/lib/galleria/Galleria.js +++ b/components/lib/galleria/Galleria.js @@ -106,7 +106,8 @@ export const Galleria = React.memo(React.forwardRef((props, ref) => { hide, isAutoPlayActive, startSlideShow, - stopSlideShow + stopSlideShow, + ...ref })); const createHeader = () => { diff --git a/components/lib/gmap/GMap.js b/components/lib/gmap/GMap.js index 9bcfbd1895..2760b244c0 100644 --- a/components/lib/gmap/GMap.js +++ b/components/lib/gmap/GMap.js @@ -111,7 +111,8 @@ export const GMap = React.memo(React.forwardRef((props, ref) => { }); React.useImperativeHandle(ref, () => ({ - getMap + getMap, + ...ref })); const otherProps = ObjectUtils.findDiffKeys(props, GMap.defaultProps); diff --git a/components/lib/inputnumber/InputNumber.js b/components/lib/inputnumber/InputNumber.js index ba975b8ea7..68c060d1ea 100644 --- a/components/lib/inputnumber/InputNumber.js +++ b/components/lib/inputnumber/InputNumber.js @@ -934,7 +934,8 @@ export const InputNumber = React.memo(React.forwardRef((props, ref) => { } React.useImperativeHandle(ref, () => ({ - getFormatter + getFormatter, + ...ref })); React.useEffect(() => { diff --git a/components/lib/menu/Menu.js b/components/lib/menu/Menu.js index 49755bba8b..519536542f 100644 --- a/components/lib/menu/Menu.js +++ b/components/lib/menu/Menu.js @@ -124,7 +124,8 @@ export const Menu = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ toggle, show, - hide + hide, + ...ref })); const createSubmenu = (submenu, index) => { diff --git a/components/lib/menubar/Menubar.js b/components/lib/menubar/Menubar.js index 7fe4c84156..e43b7e34b0 100644 --- a/components/lib/menubar/Menubar.js +++ b/components/lib/menubar/Menubar.js @@ -49,7 +49,8 @@ export const Menubar = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ toggle, - useCustomContent + useCustomContent, + ...ref })); const createStartContent = () => { diff --git a/components/lib/messages/Messages.js b/components/lib/messages/Messages.js index d0e0a567b0..e3d5dd3d5c 100644 --- a/components/lib/messages/Messages.js +++ b/components/lib/messages/Messages.js @@ -45,7 +45,8 @@ export const Messages = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ show, replace, - clear + clear, + ...ref })); const otherProps = ObjectUtils.findDiffKeys(props, Messages.defaultProps); diff --git a/components/lib/overlaypanel/OverlayPanel.js b/components/lib/overlaypanel/OverlayPanel.js index 4bb0e9ecf9..afc2cc787f 100644 --- a/components/lib/overlaypanel/OverlayPanel.js +++ b/components/lib/overlaypanel/OverlayPanel.js @@ -176,7 +176,8 @@ export const OverlayPanel = React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ toggle, show, - hide + hide, + ...ref })); const createCloseIcon = () => { diff --git a/components/lib/radiobutton/RadioButton.js b/components/lib/radiobutton/RadioButton.js index 9d387118da..ca72370ea6 100644 --- a/components/lib/radiobutton/RadioButton.js +++ b/components/lib/radiobutton/RadioButton.js @@ -52,7 +52,8 @@ export const RadioButton = React.memo(React.forwardRef((props, ref) => { }, [inputRef, props.inputRef]); React.useImperativeHandle(ref, () => ({ - select + select, + ...ref })); const hasTooltip = ObjectUtils.isNotEmpty(props.tooltip); diff --git a/components/lib/scrollpanel/ScrollPanel.js b/components/lib/scrollpanel/ScrollPanel.js index 7bb8ca3dcf..0a9a797cb2 100644 --- a/components/lib/scrollpanel/ScrollPanel.js +++ b/components/lib/scrollpanel/ScrollPanel.js @@ -149,7 +149,8 @@ export const ScrollPanel = React.forwardRef((props, ref) => { }); React.useImperativeHandle(ref, () => ({ - refresh + refresh, + ...ref })); const otherProps = ObjectUtils.findDiffKeys(props, ScrollPanel.defaultProps); diff --git a/components/lib/slidemenu/SlideMenu.js b/components/lib/slidemenu/SlideMenu.js index d273a75783..a14bd55799 100644 --- a/components/lib/slidemenu/SlideMenu.js +++ b/components/lib/slidemenu/SlideMenu.js @@ -88,7 +88,8 @@ export const SlideMenu = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ toggle, show, - hide + hide, + ...ref })); const createBackward = () => { diff --git a/components/lib/speeddial/SpeedDial.js b/components/lib/speeddial/SpeedDial.js index 30e7fe3103..e2f52f552d 100644 --- a/components/lib/speeddial/SpeedDial.js +++ b/components/lib/speeddial/SpeedDial.js @@ -147,7 +147,8 @@ export const SpeedDial = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ show, - hide + hide, + ...ref })); const createItem = (item, index) => { diff --git a/components/lib/splitbutton/SplitButton.js b/components/lib/splitbutton/SplitButton.js index 963e5c1a82..69b743ec83 100644 --- a/components/lib/splitbutton/SplitButton.js +++ b/components/lib/splitbutton/SplitButton.js @@ -81,7 +81,8 @@ export const SplitButton = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ show, - hide + hide, + ...ref })); const createItems = () => { diff --git a/components/lib/tabview/TabView.js b/components/lib/tabview/TabView.js index 98545f9c58..2e8d1c713f 100644 --- a/components/lib/tabview/TabView.js +++ b/components/lib/tabview/TabView.js @@ -146,7 +146,8 @@ export const TabView = React.forwardRef((props, ref) => { }, [props.activeIndex]); React.useImperativeHandle(ref, () => ({ - reset + reset, + ...ref })); const createTabHeader = (tab, index) => { diff --git a/components/lib/tieredmenu/TieredMenu.js b/components/lib/tieredmenu/TieredMenu.js index 1655c92136..7a982494ed 100644 --- a/components/lib/tieredmenu/TieredMenu.js +++ b/components/lib/tieredmenu/TieredMenu.js @@ -73,7 +73,8 @@ export const TieredMenu = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ toggle, show, - hide + hide, + ...ref })); const createElement = () => { diff --git a/components/lib/toast/Toast.js b/components/lib/toast/Toast.js index b0b1abb002..98b7e14537 100644 --- a/components/lib/toast/Toast.js +++ b/components/lib/toast/Toast.js @@ -68,7 +68,8 @@ export const Toast = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ show, replace, - clear + clear, + ...ref })); const createElement = () => { diff --git a/components/lib/tooltip/Tooltip.js b/components/lib/tooltip/Tooltip.js index fab0888955..47081ee40d 100644 --- a/components/lib/tooltip/Tooltip.js +++ b/components/lib/tooltip/Tooltip.js @@ -432,7 +432,8 @@ export const Tooltip = React.memo(React.forwardRef((props, ref) => { React.useImperativeHandle(ref, () => ({ updateTargetEvents, loadTargetEvents, - unloadTargetEvents + unloadTargetEvents, + ...ref })); const createElement = () => { diff --git a/components/lib/tree/Tree.js b/components/lib/tree/Tree.js index f1d042c7bc..32b4823e12 100644 --- a/components/lib/tree/Tree.js +++ b/components/lib/tree/Tree.js @@ -286,7 +286,8 @@ export const Tree = React.memo(React.forwardRef((props, ref) => { } React.useImperativeHandle(ref, () => ({ - filter + filter, + ...ref })); const createRootChild = (node, index, last) => { diff --git a/components/lib/treetable/TreeTable.js b/components/lib/treetable/TreeTable.js index a629eac40c..7a7af85ecb 100644 --- a/components/lib/treetable/TreeTable.js +++ b/components/lib/treetable/TreeTable.js @@ -791,7 +791,8 @@ export const TreeTable = React.forwardRef((props, ref) => { } React.useImperativeHandle(ref, () => ({ - filter + filter, + ...ref })); const createTableHeader = (columns, columnGroup) => { diff --git a/components/lib/virtualscroller/VirtualScroller.js b/components/lib/virtualscroller/VirtualScroller.js index 28d68f4b5d..970780a384 100644 --- a/components/lib/virtualscroller/VirtualScroller.js +++ b/components/lib/virtualscroller/VirtualScroller.js @@ -517,7 +517,8 @@ export const VirtualScroller = React.memo(React.forwardRef((props, ref) => { scrollTo, scrollToIndex, scrollInView, - getRenderedRange + getRenderedRange, + ...ref })); const createLoaderItem = (index, extOptions = {}) => { diff --git a/package-lock.json b/package-lock.json index 272653a0a5..5fcad8cd06 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "primereact", - "version": "8.2.0-SNAPSHOT", + "version": "9.0.0-SNAPSHOT", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "primereact", - "version": "8.2.0-SNAPSHOT", + "version": "9.0.0-SNAPSHOT", "dependencies": { "chart.js": "3.3.2", "file-saver": "2.0.5", diff --git a/pages/datatable/export.js b/pages/datatable/export.js index 1a2a12e80b..8f600341e2 100644 --- a/pages/datatable/export.js +++ b/pages/datatable/export.js @@ -102,7 +102,7 @@ const DataTableExportDemo = () => { import('jspdf').then((jsPDF) => { import('jspdf-autotable').then(() => { const doc = new jsPDF.default(0, 0); - doc.autoTable(exportColumns, products); + doc.autoTable(exportColumns, dt.current.value); doc.save('products.pdf'); }); });