refactor(Menu): Use items prop instead of deprecated Menu.Item HOC (#32587)

This commit is contained in:
Mehmet Salih Yavuz
2025-06-16 22:51:27 +03:00
committed by GitHub
parent 527c8de773
commit d15b0e4f6d
23 changed files with 849 additions and 729 deletions

View File

@@ -111,16 +111,18 @@ const SaveQuery = ({
database?.allows_virtual_table_explore !== undefined;
const overlayMenu = (
<Menu>
<Menu.Item
onClick={() => {
logAction(LOG_ACTIONS_SQLLAB_CREATE_CHART, {});
setShowSaveDatasetModal(true);
}}
>
{t('Save dataset')}
</Menu.Item>
</Menu>
<Menu
items={[
{
label: t('Save dataset'),
key: 'save-dataset',
onClick: () => {
logAction(LOG_ACTIONS_SQLLAB_CREATE_CHART, {});
setShowSaveDatasetModal(true);
},
},
]}
/>
);
const queryPayload = () => ({