File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src-ts/tools/learn/learn-lib/hiring-manager-view Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 6
6
SetStateAction ,
7
7
useCallback ,
8
8
useLayoutEffect ,
9
+ useMemo ,
9
10
useRef ,
10
11
useState ,
11
12
} from 'react'
@@ -50,6 +51,7 @@ function renderBasicList(items: Array<string> = []): ReactNode {
50
51
</ ul >
51
52
)
52
53
}
54
+
53
55
export interface HiringManagerViewProps {
54
56
certification ?: TCACertification
55
57
completedAt ?: string
@@ -91,7 +93,9 @@ const HiringManagerView: FC<HiringManagerViewProps> = (props: HiringManagerViewP
91
93
)
92
94
const shareModal : TCAShareCertificateModalData = useTCAShareCertificateModal ( ssrCertUrl )
93
95
94
- const renderShareActions : boolean = props . isOwner && ! props . isModalView
96
+ const renderShareActions : boolean = useMemo ( ( ) => (
97
+ ! ! props . isOwner && ! props . isModalView
98
+ ) , [ props . isOwner , props . isModalView ] )
95
99
96
100
const getCertificateCanvas : ( ) => Promise < HTMLCanvasElement | void >
97
101
= useCertificateCanvas ( certificateElRef )
You can’t perform that action at this time.
0 commit comments