Skip to content

Commit

Permalink
Add skip datasource alert
Browse files Browse the repository at this point in the history
Signed-off-by: Wei-Chun, Chang <[email protected]>
  • Loading branch information
wcchang1115 committed Sep 25, 2023
1 parent 2324b66 commit 9fcdfe1
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 9 deletions.
14 changes: 14 additions & 0 deletions static_report/src/components/Common/SkipDatasource.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { Alert, AlertIcon, AlertDescription } from '@chakra-ui/react';

export function SkipDatasource() {
return (
<Alert status="error" mb={3} rounded={10}>
<AlertIcon />
<AlertDescription>
Schemas and reports generated from manifest files are limited to
information in those manifests. For a more detailed report, follow these
instructions
</AlertDescription>
</Alert>
);
}
10 changes: 2 additions & 8 deletions static_report/src/components/Overview/Overview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import { LineageGraphData } from '../../utils/dbt';
import { topologySort } from '../../utils/graph';
import { CompDbtNodeEntryItem, useReportStore } from '../../utils/store';
import { SearchTextInput } from '../Common/SearchTextInput';
import { SkipDatasource } from '../Common/SkipDatasource';
import { ModelList } from './ModelList';
import { MetricList } from './MetricList';
import { NodeList } from './NodeList';
Expand Down Expand Up @@ -364,14 +365,7 @@ export function Overview({ singleOnly }: Props) {
return (
<>
<Flex direction="column" w={'100%'} minHeight="650px">
<Alert status="error" mb={3} rounded={10}>
<AlertIcon />
<AlertDescription>
Schemas and reports generated from manifest files are limited to
information in those manifests. <u>For a more detailed report, follow
these instructions</u>
</AlertDescription>
</Alert>
<SkipDatasource></SkipDatasource>
<Flex w={'100%'} paddingBottom="10px" marginBottom="20px">
<Heading fontSize={24}>
{singleOnly ? 'Overview' : 'Impact Summary'}
Expand Down
3 changes: 2 additions & 1 deletion static_report/src/pages/CRTableDetailPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import { useTableRoute } from '../utils/routes';
import { NO_VALUE } from '../components/Columns/constants';
import { TableGeneralStats } from '../components/Tables/TableMetrics/TableGeneralStats';
import { DupedTableRowsWidget } from '../components/Widgets/DupedTableRowsWidget';
import { SkipDatasource } from '../components/Common/SkipDatasource';

export default function CRTableDetailPage() {
let { tableName, uniqueId } = useTableRoute();
Expand Down Expand Up @@ -178,6 +179,7 @@ export default function CRTableDetailPage() {

return (
<Box>
<SkipDatasource />
<HStack alignItems="flex-start">
<TableColumnHeader
title={name}
Expand All @@ -200,7 +202,6 @@ export default function CRTableDetailPage() {
Show Dependencies
</Button> */}
</HStack>

<ComparableGridHeader />
<ComparisonContent>
<VStack spacing={10}>
Expand Down
2 changes: 2 additions & 0 deletions static_report/src/pages/SRTableDetailPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import {
import { TableColumnHeader } from '../components/Tables/TableColumnHeader';
import { useReportStore } from '../utils/store';
import { useTableRoute } from '../utils/routes';
import { SkipDatasource } from '../components/Common/SkipDatasource';

export default function SRTableDetailPage() {
let { tableName, uniqueId } = useTableRoute();
Expand Down Expand Up @@ -59,6 +60,7 @@ export default function SRTableDetailPage() {

return (
<>
<SkipDatasource></SkipDatasource>
<TableColumnHeader
title={name}
subtitle={'Table'}
Expand Down

0 comments on commit 9fcdfe1

Please sign in to comment.