File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
invokeai/frontend/web/src/features/controlLayers/hooks Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change 11import { useAppSelector } from 'app/store/storeHooks' ;
22import { selectIsCogView4 , selectIsSD3 } from 'features/controlLayers/store/paramsSlice' ;
33import type { CanvasEntityType } from 'features/controlLayers/store/types' ;
4- import { useCallback } from 'react' ;
4+ import { useMemo } from 'react' ;
55
66export const useIsEntityTypeEnabled = ( entityType : CanvasEntityType ) => {
77 const isSD3 = useAppSelector ( selectIsSD3 ) ;
88 const isCogView4 = useAppSelector ( selectIsCogView4 ) ;
99
10- const isEntityTypeEnabled = useCallback ( ( ) => {
10+ const isEntityTypeEnabled = useMemo < boolean > ( ( ) => {
1111 switch ( entityType ) {
1212 case 'reference_image' :
1313 return ! isSD3 && ! isCogView4 ;
You can’t perform that action at this time.
0 commit comments