Skip to content

Commit

Permalink
fix: eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
rpenido committed Dec 6, 2023
1 parent 58964a2 commit 2a56eab
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/taxonomy/taxonomy-card/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ const TaxonomyCard = ({ className, original }) => {
} = original;

const intl = useIntl();

const getHeaderActions = () => (
<TaxonomyMenu
taxonomy={original}
Expand Down
27 changes: 19 additions & 8 deletions src/taxonomy/taxonomy-menu/TaxonomyMenu.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,24 @@ const TaxonomyMenu = ({

const menuItems = getTaxonomyMenuItems();

const renderModals = () => isExportModalOpen && (
<ExportModal
isOpen={isExportModalOpen}
onClose={exportModalClose}
taxonomyId={taxonomy.id}
taxonomyName={taxonomy.name}
/>
const renderModals = () => (
<>
{isExportModalOpen && (
<ExportModal
taxonomyId={taxonomy.id}
isOpen={isExportModalOpen}
onClose={exportModalClose}
taxonomyName={taxonomy.name}
/>
)}
{isImportModalOpen && (
<ImportTagsWizard
taxonomy={taxonomy}
isOpen={isImportModalOpen}
close={importModalClose}
/>
)}
</>
);

return (
Expand Down Expand Up @@ -98,4 +109,4 @@ TaxonomyMenu.propTypes = {
iconMenu: PropTypes.bool.isRequired,
};

export default TaxonomyMenu;
export default TaxonomyMenu;
2 changes: 1 addition & 1 deletion src/taxonomy/taxonomy-menu/TaxonomyMenu.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -168,4 +168,4 @@ describe('<TaxonomyMenu />', async () => {
expect(getTaxonomyExportFile).toHaveBeenCalledWith(taxonomyId, 'json');
});
});
});
});

0 comments on commit 2a56eab

Please sign in to comment.