-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into kiahna-tucker/entity-status/init-controller-…
…status-history
- Loading branch information
Showing
19 changed files
with
212 additions
and
48 deletions.
There are no files selected for viewing
16 changes: 16 additions & 0 deletions
16
src/components/collection/DataPreview/NoCollectionJournalsAlert.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { authenticatedRoutes } from 'app/routes'; | ||
import MessageWithButton from 'components/content/MessageWithButton'; | ||
import { useNavigate } from 'react-router'; | ||
|
||
export default function NoCollectionJournalsAlert() { | ||
const navigate = useNavigate(); | ||
|
||
return ( | ||
<MessageWithButton | ||
messageId="collectionsPreview.notFound.message" | ||
clickHandler={() => { | ||
navigate(authenticatedRoutes.captures.fullPath); | ||
}} | ||
/> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
import { Stack, Typography } from '@mui/material'; | ||
import WrapperWithHeader from 'components/shared/Entity/WrapperWithHeader'; | ||
import ErrorBoundryWrapper from 'components/shared/ErrorBoundryWrapper'; | ||
import { useEntityType } from 'context/EntityContext'; | ||
import { useIntl } from 'react-intl'; | ||
import { useBindingStore } from 'stores/Binding/Store'; | ||
import OnIncompatibleSchemaChange from '../OnIncompatibleSchemaChange'; | ||
import TimeTravel from '../TimeTravel'; | ||
import { AdvancedOptionsProps } from './types'; | ||
|
||
export default function AdvancedOptions({ | ||
bindingIndex, | ||
bindingUUID, | ||
collectionName, | ||
}: AdvancedOptionsProps) { | ||
const intl = useIntl(); | ||
|
||
const entityType = useEntityType(); | ||
|
||
const fullSourceErrorExists = useBindingStore((state) => { | ||
const fullSourceErrors = state.fullSourceConfigs[bindingUUID]?.errors; | ||
|
||
if (!fullSourceErrors) { | ||
return false; | ||
} | ||
|
||
return fullSourceErrors.length > 0; | ||
}); | ||
|
||
const onIncompatibleSchemaChangeErrorExists = useBindingStore( | ||
(state) => state.onIncompatibleSchemaChangeErrorExists.binding | ||
); | ||
|
||
if (entityType !== 'materialization') { | ||
return null; | ||
} | ||
|
||
return ( | ||
<WrapperWithHeader | ||
forceOpen={ | ||
fullSourceErrorExists || onIncompatibleSchemaChangeErrorExists | ||
} | ||
header={ | ||
<Typography variant="formSectionHeader"> | ||
{intl.formatMessage({ | ||
id: 'workflows.advancedSettings.title', | ||
})} | ||
</Typography> | ||
} | ||
hideBorder | ||
mountClosed | ||
> | ||
<Stack spacing={4}> | ||
<ErrorBoundryWrapper> | ||
<OnIncompatibleSchemaChange bindingIndex={bindingIndex} /> | ||
</ErrorBoundryWrapper> | ||
|
||
<TimeTravel | ||
bindingUUID={bindingUUID} | ||
collectionName={collectionName} | ||
/> | ||
</Stack> | ||
</WrapperWithHeader> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
export interface AdvancedOptionsProps { | ||
bindingIndex: number; | ||
bindingUUID: string; | ||
collectionName: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
import { Box, Typography } from '@mui/material'; | ||
import WrapperWithHeader from 'components/shared/Entity/WrapperWithHeader'; | ||
import ErrorBoundryWrapper from 'components/shared/ErrorBoundryWrapper'; | ||
import { useEntityType } from 'context/EntityContext'; | ||
import { useIntl } from 'react-intl'; | ||
import { useBindingStore } from 'stores/Binding/Store'; | ||
import OnIncompatibleSchemaChange from './OnIncompatibleSchemaChange'; | ||
|
||
export default function AdvancedOptions() { | ||
const intl = useIntl(); | ||
|
||
const entityType = useEntityType(); | ||
|
||
const onIncompatibleSchemaChangeErrorExists = useBindingStore( | ||
(state) => state.onIncompatibleSchemaChangeErrorExists.spec | ||
); | ||
|
||
if (entityType !== 'materialization') { | ||
return null; | ||
} | ||
|
||
return ( | ||
<Box style={{ maxWidth: 850 }}> | ||
<WrapperWithHeader | ||
forceOpen={onIncompatibleSchemaChangeErrorExists} | ||
header={ | ||
<Typography variant="formSectionHeader"> | ||
{intl.formatMessage({ | ||
id: 'workflows.advancedSettings.title', | ||
})} | ||
</Typography> | ||
} | ||
hideBorder | ||
mountClosed | ||
> | ||
<ErrorBoundryWrapper> | ||
<OnIncompatibleSchemaChange /> | ||
</ErrorBoundryWrapper> | ||
</WrapperWithHeader> | ||
</Box> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,13 @@ | ||
import { CommonMessages } from './CommonMessages'; | ||
import { Details } from './Details'; | ||
import { RouteTitles } from './RouteTitles'; | ||
|
||
export const Collections: Record<string, string> = { | ||
'collectionsTable.title': `Collections`, | ||
'collectionsTable.cta.new': `New ${CommonMessages['terms.transformation']}`, | ||
'collectionsTable.detailsCTA': `Details`, | ||
'collectionsTable.filterLabel': `Filter collections`, | ||
'collectionsPreview.notFound.message': `We were unable to find any data which could mean the capture has not ingested data yet or is not running. Check the status on the Captures page to make sure it is running.`, | ||
'collectionsPreview.notFound.message': `We were unable to find any data which could mean the capture has not ingested data yet or is not running. Check the status on the {button} to make sure it is running.`, | ||
'collectionsPreview.notFound.message.button': `${RouteTitles['routeTitle.captures']} page`, | ||
'collectionsPreview.notFound.message.derivation': `We were unable to find any data which could mean the derivation has not ingested data yet or is not running. Check the status in the ${Details['detailsPanel.shardDetails.title']} section to make sure it is running.`, | ||
}; |
Oops, something went wrong.