diff --git a/src/components/analyses/AnalysisCommentDialog.js b/src/components/analyses/AnalysisCommentDialog.js index 500d07adb..ca6501191 100644 --- a/src/components/analyses/AnalysisCommentDialog.js +++ b/src/components/analyses/AnalysisCommentDialog.js @@ -105,7 +105,7 @@ function AnalysisCommentDialog(props) { diff --git a/src/components/analyses/RenameAnalysisDialog.js b/src/components/analyses/RenameAnalysisDialog.js index 5284452ad..09d2af09f 100644 --- a/src/components/analyses/RenameAnalysisDialog.js +++ b/src/components/analyses/RenameAnalysisDialog.js @@ -122,7 +122,7 @@ function RenameAnalysisDialog(props) { diff --git a/src/components/analyses/details/InfoPanel.js b/src/components/analyses/details/InfoPanel.js index de7bf88f1..1a1e94648 100644 --- a/src/components/analyses/details/InfoPanel.js +++ b/src/components/analyses/details/InfoPanel.js @@ -109,7 +109,7 @@ function InfoPanel(props) { return ; } - if (!info && !isInfoFetching && !infoFetchError) { + if (!(info?.steps || isInfoFetching || infoFetchError)) { return null; } diff --git a/src/components/apps/AgaveAuthPromptDialog.js b/src/components/apps/AgaveAuthPromptDialog.js index 4f779539d..e28a5ded0 100644 --- a/src/components/apps/AgaveAuthPromptDialog.js +++ b/src/components/apps/AgaveAuthPromptDialog.js @@ -62,7 +62,7 @@ function AgaveAuthPromptDialog(props) { {i18nCommon("submit")} diff --git a/src/components/apps/admin/details/AdminAppDetails.js b/src/components/apps/admin/details/AdminAppDetails.js index 6b6d49135..7a3a4e070 100644 --- a/src/components/apps/admin/details/AdminAppDetails.js +++ b/src/components/apps/admin/details/AdminAppDetails.js @@ -209,7 +209,7 @@ function AdminAppDetailsForm(props) { {i18nCommon("save")} diff --git a/src/components/apps/admin/referenceGenomes/Edit.js b/src/components/apps/admin/referenceGenomes/Edit.js index 85ed0c6d4..e3998f032 100644 --- a/src/components/apps/admin/referenceGenomes/Edit.js +++ b/src/components/apps/admin/referenceGenomes/Edit.js @@ -167,7 +167,7 @@ function Edit(props) { {t("ok")} diff --git a/src/components/dashboard/DashboardSection.js b/src/components/dashboard/DashboardSection.js index e5f0cf964..384fb3dd2 100644 --- a/src/components/dashboard/DashboardSection.js +++ b/src/components/dashboard/DashboardSection.js @@ -1,7 +1,7 @@ import React, { useState } from "react"; import clsx from "clsx"; -import { Typography, Collapse, Button, useTheme, Divider } from "@mui/material"; +import { Typography, Collapse, Button, Divider } from "@mui/material"; import getItem from "./dashboardItem"; @@ -9,9 +9,10 @@ import useStyles from "./styles"; import * as fns from "./functions"; import * as constants from "./constants"; import ids from "./ids"; -import { useTranslation } from "i18n"; const DashboardSection = ({ + t, + theme, name, kind, items, @@ -29,9 +30,7 @@ const DashboardSection = ({ computeLimitExceeded, }) => { const classes = useStyles(); - const { t } = useTranslation("dashboard"); const [expanded, setExpanded] = useState(false); - const theme = useTheme(); const isNewsSection = section === constants.SECTION_NEWS; const isEventsSection = section === constants.SECTION_EVENTS; @@ -115,6 +114,7 @@ class SectionBase { getComponent({ t, + theme, cardWidth, cardHeight, data, @@ -169,6 +169,8 @@ class SectionBase { setPendingAnalysis={setPendingAnalysis} setTerminateAnalysis={setTerminateAnalysis} computeLimitExceeded={computeLimitExceeded} + t={t} + theme={theme} /> ); } diff --git a/src/components/dashboard/dashboardItem/AnalysisItem.js b/src/components/dashboard/dashboardItem/AnalysisItem.js index c280bcfe8..116398218 100644 --- a/src/components/dashboard/dashboardItem/AnalysisItem.js +++ b/src/components/dashboard/dashboardItem/AnalysisItem.js @@ -8,7 +8,7 @@ import { Cancel, Launch, } from "@mui/icons-material"; -import { IconButton, useTheme } from "@mui/material"; +import { IconButton } from "@mui/material"; import { formatDate } from "components/utils/DateFormatter"; @@ -20,7 +20,6 @@ import { getFolderPage } from "../../data/utils"; import NavConstants from "../../../common/NavigationConstants"; import { isTerminated } from "components/analyses/utils"; -import { useTranslation } from "i18n"; import { isInteractive, openInteractiveUrl } from "components/analyses/utils"; class AnalysisItem extends ItemBase { @@ -36,11 +35,14 @@ class AnalysisItem extends ItemBase { static create(props) { const analysis = props.content; - const { setDetailsAnalysis, setPendingAnalysis, setTerminateAnalysis } = - props; + const { + setDetailsAnalysis, + setPendingAnalysis, + setTerminateAnalysis, + t, + theme, + } = props; const item = new AnalysisItem(props); - const { t } = useTranslation("dashboard"); - const theme = useTheme(); const isTerminatedAnalysis = isTerminated(analysis); const isVICE = isInteractive(analysis); const interactiveUrls = analysis?.interactive_urls; diff --git a/src/components/dashboard/dashboardItem/AppItem.js b/src/components/dashboard/dashboardItem/AppItem.js index 28feba0c7..460e6d3c4 100644 --- a/src/components/dashboard/dashboardItem/AppItem.js +++ b/src/components/dashboard/dashboardItem/AppItem.js @@ -12,10 +12,8 @@ import { appFavorite, APP_BY_ID_QUERY_KEY } from "serviceFacades/apps"; import * as constants from "../constants"; import ItemBase, { ItemAction } from "./ItemBase"; -import { useTranslation } from "i18n"; import AppFavorite from "components/apps/AppFavorite"; import { useAppLaunchLink } from "components/apps/utils"; -import { useTheme } from "@mui/material"; class AppItem extends ItemBase { constructor(props) { @@ -30,9 +28,7 @@ class AppItem extends ItemBase { static create(props) { const item = new AppItem(props); - const { showErrorAnnouncer, setDetailsApp } = props; - const { t } = useTranslation("dashboard"); - const theme = useTheme(); + const { showErrorAnnouncer, setDetailsApp, t, theme } = props; // Extract app details. Note: dashboard-aggregator only queries the DE database. const app = props.content; diff --git a/src/components/dashboard/dashboardItem/EventItem.js b/src/components/dashboard/dashboardItem/EventItem.js index 3ede16e06..356dca36b 100644 --- a/src/components/dashboard/dashboardItem/EventItem.js +++ b/src/components/dashboard/dashboardItem/EventItem.js @@ -13,7 +13,6 @@ import * as fns from "../functions"; import * as constants from "../constants"; import ItemBase, { ItemAction, DashboardFeedItem } from "./ItemBase"; -import { useTranslation } from "i18n"; class EventItem extends ItemBase { constructor({ section, content, height, width }) { @@ -28,7 +27,7 @@ class EventItem extends ItemBase { static create(props) { const item = new EventItem(props); - const { t } = useTranslation("dashboard"); + const { t } = props; return item.addActions([ , diff --git a/src/components/dashboard/dashboardItem/NewsItem.js b/src/components/dashboard/dashboardItem/NewsItem.js index 6fbbb059d..043241730 100644 --- a/src/components/dashboard/dashboardItem/NewsItem.js +++ b/src/components/dashboard/dashboardItem/NewsItem.js @@ -12,7 +12,6 @@ import * as fns from "../functions"; import * as constants from "../constants"; import ItemBase, { ItemAction, DashboardFeedItem } from "./ItemBase"; -import { useTranslation } from "i18n"; class NewsItem extends ItemBase { constructor({ section, content, height, width }) { @@ -27,7 +26,7 @@ class NewsItem extends ItemBase { static create(props) { const item = new NewsItem(props); - const { t } = useTranslation("dashboard"); + const { t } = props; return item.addActions([ setRunTour(true)} > {t("startTour")} diff --git a/src/components/dashboard/index.js b/src/components/dashboard/index.js index eab08bd88..7f2836902 100644 --- a/src/components/dashboard/index.js +++ b/src/components/dashboard/index.js @@ -12,7 +12,7 @@ import clsx from "clsx"; import { useQueryClient, useQuery, useMutation } from "react-query"; import { useTranslation } from "i18n"; -import { Typography } from "@mui/material"; +import { Typography, useTheme } from "@mui/material"; import { Skeleton } from "@mui/material"; @@ -118,6 +118,7 @@ const Dashboard = (props) => { const [userProfile] = useUserProfile(); const [config] = useConfig(); const queryClient = useQueryClient(); + const theme = useTheme(); const [resourceUsageSummary, setResourceUsageSummary] = useState(null); const [resourceUsageError, setResourceUsageError] = useState(null); @@ -261,6 +262,7 @@ const Dashboard = (props) => { .map((section) => section.getComponent({ t, + theme, data, cardWidth, cardHeight, diff --git a/src/components/data/CreateFolderDialog.js b/src/components/data/CreateFolderDialog.js index 3ac8896dc..cf714d43f 100644 --- a/src/components/data/CreateFolderDialog.js +++ b/src/components/data/CreateFolderDialog.js @@ -151,7 +151,7 @@ function CreateFolderDialog(props) { diff --git a/src/components/data/MoveDialog.js b/src/components/data/MoveDialog.js index 688a14fef..19e35b7cd 100644 --- a/src/components/data/MoveDialog.js +++ b/src/components/data/MoveDialog.js @@ -88,7 +88,7 @@ function MoveDialog(props) { diff --git a/src/components/data/PathListAutomation.js b/src/components/data/PathListAutomation.js index fc28d19e8..789d28aeb 100644 --- a/src/components/data/PathListAutomation.js +++ b/src/components/data/PathListAutomation.js @@ -459,7 +459,7 @@ export default function PathListAutomation(props) { baseId, ids.PATH_LIST_AUTO_DONE_BTN )} - color="primary" + variant="contained" type="submit" onClick={handleSubmit} > diff --git a/src/components/data/RenameDialog.js b/src/components/data/RenameDialog.js index 90c59cd99..eba69234d 100644 --- a/src/components/data/RenameDialog.js +++ b/src/components/data/RenameDialog.js @@ -107,7 +107,7 @@ function RenameDialog(props) { diff --git a/src/components/data/SaveAsDialog.js b/src/components/data/SaveAsDialog.js index 9e665afaf..b3aebfe7a 100644 --- a/src/components/data/SaveAsDialog.js +++ b/src/components/data/SaveAsDialog.js @@ -69,7 +69,7 @@ function SaveAsDialog(props) { diff --git a/src/components/data/SelectionDrawer.js b/src/components/data/SelectionDrawer.js index 2ab70a14e..09a1c905d 100644 --- a/src/components/data/SelectionDrawer.js +++ b/src/components/data/SelectionDrawer.js @@ -337,10 +337,12 @@ function SelectionDrawer(props) { onClose={onClose} open={open} anchor="right" + elevation={0} PaperProps={{ variant: "outlined", classes: { root: classes.selectionDrawer }, }} + sx={{ zIndex: "modal" }} > { setConfirmDOIRequestDialogOpen(false); requestDOI({ diff --git a/src/components/data/listing/TableView.js b/src/components/data/listing/TableView.js index 3fe691181..5840ac43a 100644 --- a/src/components/data/listing/TableView.js +++ b/src/components/data/listing/TableView.js @@ -36,6 +36,7 @@ import { TableBody, TableCell, TableContainer, + useTheme, } from "@mui/material"; import makeStyles from "@mui/styles/makeStyles"; @@ -154,11 +155,13 @@ function TableView(props) { instantLaunchDefaultsMapping, computeLimitExceeded, } = props; + const invalidRowClass = invalidRowStyles(); const { t } = useTranslation("data"); const dataRecordFields = dataFields(t); const tableId = buildID(baseId, ids.LISTING_TABLE); const trashPath = useBaseTrashPath(); + const theme = useTheme(); const [displayColumns, setDisplayColumns] = useState( getLocalStorageCols(rowDotMenuVisibility, dataRecordFields) || @@ -403,7 +406,10 @@ function TableView(props) { resource={resource} size="small" color="default" - themeSpacing={3} + style={{ + marginLeft: + theme.spacing(3), + }} computeLimitExceeded={ computeLimitExceeded } diff --git a/src/components/data/viewers/FileTypeSelectionDialog.js b/src/components/data/viewers/FileTypeSelectionDialog.js index 90cb78cf4..7235f3398 100644 --- a/src/components/data/viewers/FileTypeSelectionDialog.js +++ b/src/components/data/viewers/FileTypeSelectionDialog.js @@ -50,7 +50,7 @@ export default function FileTypeSelectionDialog(props) { onFileTypeSelected(type)} > {i18nCommon("create")} diff --git a/src/components/data/viewers/PathListViewer.js b/src/components/data/viewers/PathListViewer.js index 3899cec1f..a40fb00f3 100644 --- a/src/components/data/viewers/PathListViewer.js +++ b/src/components/data/viewers/PathListViewer.js @@ -23,6 +23,7 @@ import Toolbar from "./Toolbar"; import { getColumns, LINE_NUMBER_ACCESSOR } from "./utils"; import DataSelectionDrawer from "components/data/SelectionDrawer"; +import { useSelectorDefaultFolderPath } from "components/data/utils"; import PageWrapper from "components/layout/PageWrapper"; import withErrorAnnouncer from "components/error/withErrorAnnouncer"; @@ -67,6 +68,7 @@ function PathListViewer(props) { fileName, data, editable, + startingPath, } = props; const { t } = useTranslation("data"); @@ -76,6 +78,8 @@ function PathListViewer(props) { const [editorData, setEditorData] = useState([]); const [fileSaveStatus, setFileSaveStatus] = useState(); + const defaultStartingPath = useSelectorDefaultFolderPath(); + const columns = useMemo( () => getColumns(data, false, t("path")), [data, t] @@ -266,6 +270,7 @@ function PathListViewer(props) { } }} multiSelect={true} + startingPath={startingPath || defaultStartingPath} /> diff --git a/src/components/help/Feedback.js b/src/components/help/Feedback.js index 80e2c723d..72c529322 100644 --- a/src/components/help/Feedback.js +++ b/src/components/help/Feedback.js @@ -98,7 +98,7 @@ export default function Feedback(props) { {i18nHelp("submit_feedback")} diff --git a/src/components/instantlaunches/index.js b/src/components/instantlaunches/index.js index 650c3ecb7..8682a941f 100644 --- a/src/components/instantlaunches/index.js +++ b/src/components/instantlaunches/index.js @@ -7,7 +7,6 @@ import { IconButton, LinearProgress, Typography, - useTheme, } from "@mui/material"; import makeStyles from "@mui/styles/makeStyles"; @@ -93,12 +92,11 @@ const InstantLaunchButton = ({ instantLaunch, resource = {}, size = "medium", - themeSpacing = 0, + style, color = "primary", computeLimitExceeded = false, }) => { const baseID = buildID(ids.BASE, ids.LAUNCH, ids.BUTTON); - const theme = useTheme(); return ( diff --git a/src/components/metadata/ApplyBulkMetadataDialog.js b/src/components/metadata/ApplyBulkMetadataDialog.js index d5c644078..193d69f3b 100644 --- a/src/components/metadata/ApplyBulkMetadataDialog.js +++ b/src/components/metadata/ApplyBulkMetadataDialog.js @@ -83,7 +83,7 @@ export default function ApplyBulkMetadataDialog(props) { {i18nCommon("done")} diff --git a/src/components/metadata/CopyMetadataDialog.js b/src/components/metadata/CopyMetadataDialog.js index 78607d33b..87ecfcf9f 100644 --- a/src/components/metadata/CopyMetadataDialog.js +++ b/src/components/metadata/CopyMetadataDialog.js @@ -62,7 +62,7 @@ export default function CopyMetadataDialog(props) { {i18nCommon("copy")} diff --git a/src/components/metadata/form/AVUFormList.js b/src/components/metadata/form/AVUFormList.js index 884dc4e1e..468b7639b 100644 --- a/src/components/metadata/form/AVUFormList.js +++ b/src/components/metadata/form/AVUFormList.js @@ -99,7 +99,7 @@ const AVUFormDialog = (props) => { {t("done")} diff --git a/src/components/metadata/templates/Listing.js b/src/components/metadata/templates/Listing.js index 01bb3a579..787111ed8 100644 --- a/src/components/metadata/templates/Listing.js +++ b/src/components/metadata/templates/Listing.js @@ -120,7 +120,7 @@ const MetadataTemplateListing = (props) => { selectedTemplateId && onSelectTemplate(selectedTemplateId) diff --git a/src/components/metadata/templates/index.js b/src/components/metadata/templates/index.js index 674e0d635..4dac61475 100644 --- a/src/components/metadata/templates/index.js +++ b/src/components/metadata/templates/index.js @@ -509,7 +509,7 @@ const MetadataTemplateForm = (props) => { )} disabled={loading || isSubmitting} onClick={handleSubmitWrapper} - color="primary" + variant="contained" > {t("save")} diff --git a/src/components/notifications/dialogs/AdminJoinTeamRequestDialog.js b/src/components/notifications/dialogs/AdminJoinTeamRequestDialog.js index 0dabf6da8..bb70ae4d4 100644 --- a/src/components/notifications/dialogs/AdminJoinTeamRequestDialog.js +++ b/src/components/notifications/dialogs/AdminJoinTeamRequestDialog.js @@ -316,7 +316,7 @@ function AdminJoinTeamRequestDialog(props) { {t("common:cancel")} diff --git a/src/components/notifications/dialogs/JoinTeamDeniedDialog.js b/src/components/notifications/dialogs/JoinTeamDeniedDialog.js index 77ebe9a29..4ea31a4d8 100644 --- a/src/components/notifications/dialogs/JoinTeamDeniedDialog.js +++ b/src/components/notifications/dialogs/JoinTeamDeniedDialog.js @@ -35,7 +35,7 @@ function JoinTeamDeniedDialog(props) { title={t("denyDetailsHeader")} actions={ diff --git a/src/components/preferences/Preferences.js b/src/components/preferences/Preferences.js index a1ad513f6..fc04db513 100644 --- a/src/components/preferences/Preferences.js +++ b/src/components/preferences/Preferences.js @@ -616,7 +616,7 @@ function Preferences(props) { onClick={restoreDefaults( props.setFieldValue )} - color="primary" + variant="contained" > {t("okBtnLbl")} diff --git a/src/components/sharing/index.js b/src/components/sharing/index.js index 2c73ffa7e..3d90ca379 100644 --- a/src/components/sharing/index.js +++ b/src/components/sharing/index.js @@ -359,7 +359,7 @@ function Sharing(props) { diff --git a/src/components/subscriptions/edit/AddSubAddon.js b/src/components/subscriptions/edit/AddSubAddon.js index aa3412b91..48fb09cec 100644 --- a/src/components/subscriptions/edit/AddSubAddon.js +++ b/src/components/subscriptions/edit/AddSubAddon.js @@ -82,8 +82,7 @@ function AddSubAddonsDialog(props) { {t("submit")} diff --git a/src/components/subscriptions/edit/EditQuotas.js b/src/components/subscriptions/edit/EditQuotas.js index c87cf2d60..b6be35c5c 100644 --- a/src/components/subscriptions/edit/EditQuotas.js +++ b/src/components/subscriptions/edit/EditQuotas.js @@ -93,8 +93,7 @@ function EditQuotasDialog(props) { ids.SUBMIT_BUTTON )} type="submit" - color="primary" - variant="outlined" + variant="contained" onClick={handleSubmit} > {t("submit")} diff --git a/src/components/subscriptions/edit/EditSubAddons.js b/src/components/subscriptions/edit/EditSubAddons.js index ac8ebc08e..8e397c4c3 100644 --- a/src/components/subscriptions/edit/EditSubAddons.js +++ b/src/components/subscriptions/edit/EditSubAddons.js @@ -152,9 +152,8 @@ function EditSubAddonsDialog(props) { parentId, ids.SUBMIT_BUTTON )} - variant="outlined" type="submit" - color="primary" + variant="contained" onClick={handleSubmit} > {t("submit")} diff --git a/src/components/subscriptions/edit/EditSubscription.js b/src/components/subscriptions/edit/EditSubscription.js index 2f5174c7b..4118b1b40 100644 --- a/src/components/subscriptions/edit/EditSubscription.js +++ b/src/components/subscriptions/edit/EditSubscription.js @@ -154,8 +154,7 @@ function EditSubscriptionDialog(props) { ids.SUBMIT_BUTTON )} type="submit" - color="primary" - variant="outlined" + variant="contained" onClick={handleSubmit} > {t("submit")} diff --git a/src/components/teams/dialogs/JoinTeamDialog.js b/src/components/teams/dialogs/JoinTeamDialog.js index 1b7c91f54..f955b766c 100644 --- a/src/components/teams/dialogs/JoinTeamDialog.js +++ b/src/components/teams/dialogs/JoinTeamDialog.js @@ -78,7 +78,7 @@ function JoinTeamDialog(props) { diff --git a/src/components/tools/NewToolRequestDialog.js b/src/components/tools/NewToolRequestDialog.js index c7a1b652f..bed58615d 100644 --- a/src/components/tools/NewToolRequestDialog.js +++ b/src/components/tools/NewToolRequestDialog.js @@ -79,7 +79,7 @@ export default function NewToolRequestDialog(props) { title={t("newToolRequestDialogHeading")} actions={ {t("common:cancel")} { onConfirm(selectedTool); }} diff --git a/src/components/tools/edit/EditTool.js b/src/components/tools/edit/EditTool.js index 661c20e40..c59746e0d 100644 --- a/src/components/tools/edit/EditTool.js +++ b/src/components/tools/edit/EditTool.js @@ -245,7 +245,7 @@ function EditToolDialog(props) { ids.BUTTONS.SAVE )} type="submit" - color="primary" + variant="contained" onClick={handleSubmit} > {isAdminPublishing @@ -394,7 +394,7 @@ function EditToolDialog(props) { setShowOverwriteWarningDialog(false); setOverwriteAppsAffectedByTool(true); }} - color="primary" + variant="contained" > {t("overwrite")} diff --git a/src/components/tools/requests/Details.js b/src/components/tools/requests/Details.js index ce701b105..d931a0b23 100644 --- a/src/components/tools/requests/Details.js +++ b/src/components/tools/requests/Details.js @@ -61,7 +61,7 @@ function DetailsDialog(props) { {i18nCommon("ok")} diff --git a/src/components/uploads/dialog/index.js b/src/components/uploads/dialog/index.js index b2c4e9056..c51542849 100644 --- a/src/components/uploads/dialog/index.js +++ b/src/components/uploads/dialog/index.js @@ -81,7 +81,7 @@ const UploadDialog = ({ open, handleClose = () => {} }) => { {t("close")} diff --git a/src/components/utils/UpdateRequestDialog.js b/src/components/utils/UpdateRequestDialog.js index 4cb32e02c..14980de44 100644 --- a/src/components/utils/UpdateRequestDialog.js +++ b/src/components/utils/UpdateRequestDialog.js @@ -147,7 +147,7 @@ export default function UpdateRequestDialog(props) { {t("cancel")} {i18nCommon("submit")} diff --git a/src/components/vice/RunErrorDialog.js b/src/components/vice/RunErrorDialog.js index 024ea9e06..fddddb730 100644 --- a/src/components/vice/RunErrorDialog.js +++ b/src/components/vice/RunErrorDialog.js @@ -30,7 +30,7 @@ const RunErrorDialog = (props) => { title={title} open={open} actions={ - + {t("common:ok")} } diff --git a/src/components/vice/admin/accessRequests/Listing.js b/src/components/vice/admin/accessRequests/Listing.js index e86b95e2b..13d95c9aa 100644 --- a/src/components/vice/admin/accessRequests/Listing.js +++ b/src/components/vice/admin/accessRequests/Listing.js @@ -208,7 +208,7 @@ function Listing(props) { setJobLimitDialogOpen(false)}> {i18nCommon("cancel")} - + {i18nCommon("done")} > @@ -255,7 +255,7 @@ function Listing(props) { setDeniedMsgDialogOpen(false)}> {i18nCommon("cancel")} - + {i18nCommon("done")} > diff --git a/src/components/vice/loading/ContactSupportDialog.js b/src/components/vice/loading/ContactSupportDialog.js index 5ba2fb2b3..c91339e62 100644 --- a/src/components/vice/loading/ContactSupportDialog.js +++ b/src/components/vice/loading/ContactSupportDialog.js @@ -136,7 +136,7 @@ function ContactSupportDialog(props) { {t("common:cancel")} diff --git a/stories/analyses/Listing.stories.js b/stories/analyses/Listing.stories.js index a98f0740c..66ce5f609 100644 --- a/stories/analyses/Listing.stories.js +++ b/stories/analyses/Listing.stories.js @@ -6,7 +6,7 @@ import constants from "../../src/constants"; import { mockAxios } from "../axiosMock"; -import { listing } from "./AnalysesMocks"; +import { info, listing } from "./AnalysesMocks"; import Listing from "components/analyses/listing/Listing"; import analysisFields from "components/analyses/analysisFields"; @@ -71,7 +71,8 @@ const errorResponse = { }; export const AnalysesListingTest = () => { - mockAxios.onGet(/\/api\/analyses*/).reply(200, listing); + mockAxios.onGet(new RegExp("/api/analyses/.*/history")).reply(200, info); + mockAxios.onGet("/api/analyses").reply(200, listing); mockAxios.onPost("/api/analyses/relauncher").replyOnce(500, errorResponse); mockAxios.onPost("/api/analyses/relauncher").reply((config) => {