-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Fix] Copy to clipboard should work on schema diff and lineage diff
Signed-off-by: Kent Huang <[email protected]>
- Loading branch information
1 parent
bc68d1a
commit c9ec9de
Showing
7 changed files
with
75 additions
and
30 deletions.
There are no files selected for viewing
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,20 +1,28 @@ | ||
import { Check } from "@/lib/api/checks"; | ||
import { LineageView } from "../lineage/LineageView"; | ||
import { LineageView, LineageViewRef } from "../lineage/LineageView"; | ||
import { Flex } from "@chakra-ui/react"; | ||
import { ReactFlowProvider } from "reactflow"; | ||
import { forwardRef, Ref } from "react"; | ||
|
||
export interface LineageDiffViewProps { | ||
check: Check; | ||
} | ||
|
||
export function LineageDiffView({ check }: LineageDiffViewProps) { | ||
function _LineageDiffView( | ||
{ check }: LineageDiffViewProps, | ||
ref: Ref<LineageViewRef> | ||
) { | ||
const viewOptions = { ...check.params, ...check.view_options }; | ||
|
||
return ( | ||
<Flex direction="column" height="100%"> | ||
<ReactFlowProvider> | ||
<LineageView viewOptions={viewOptions} interactive={false} /> | ||
<LineageView viewOptions={viewOptions} interactive={false} ref={ref} /> | ||
</ReactFlowProvider> | ||
</Flex> | ||
); | ||
} | ||
|
||
export const LineageDiffView = forwardRef<LineageViewRef, LineageDiffViewProps>( | ||
_LineageDiffView | ||
); |
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