Feat: Set the color of the canvas's control button #3851 (#4053)

### What problem does this PR solve?

Feat: Set the color of the canvas's control button #3851

### Type of change


- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
balibabu 2024-12-17 11:23:00 +08:00 committed by GitHub
parent 1053ef5551
commit b5e4a5563c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 10 additions and 2 deletions

View File

@ -58,3 +58,9 @@ export const useTheme = () => {
return context;
};
export const useIsDarkTheme = () => {
const { theme } = useTheme();
return theme === 'dark';
};

View File

@ -103,6 +103,8 @@ function FlowCanvas({ drawerVisible, hideDrawer }: IProps) {
hideSingleDebugDrawer,
} = useShowSingleDebugDrawer();
const controlIconClassname = 'text-black';
const { formDrawerVisible, hideFormDrawer, showFormDrawer, clickedNode } =
useShowFormDrawer();
@ -229,7 +231,7 @@ function FlowCanvas({ drawerVisible, hideDrawer }: IProps) {
<TooltipProvider>
<Tooltip>
<TooltipTrigger asChild>
<FolderInput />
<FolderInput className={controlIconClassname} />
</TooltipTrigger>
<TooltipContent>Import</TooltipContent>
</Tooltip>
@ -239,7 +241,7 @@ function FlowCanvas({ drawerVisible, hideDrawer }: IProps) {
<TooltipProvider>
<Tooltip>
<TooltipTrigger asChild>
<FolderOutput />
<FolderOutput className={controlIconClassname} />
</TooltipTrigger>
<TooltipContent>Export</TooltipContent>
</Tooltip>