Signing Page - New Design #152
@ -35,10 +35,10 @@ const PdfView = ({
|
||||
}, [currentFile])
|
||||
const filterByFile = (
|
||||
currentUserMarks: CurrentUserMark[],
|
||||
fileName: string
|
||||
hash: string
|
||||
): CurrentUserMark[] => {
|
||||
return currentUserMarks.filter(
|
||||
(currentUserMark) => currentUserMark.mark.fileName === fileName
|
||||
(currentUserMark) => currentUserMark.mark.pdfFileHash === hash
|
||||
)
|
||||
}
|
||||
const isNotLastPdfFile = (index: number, files: CurrentUserFile[]): boolean =>
|
||||
@ -46,7 +46,7 @@ const PdfView = ({
|
||||
return (
|
||||
<>
|
||||
{files.map((currentUserFile, index, arr) => {
|
||||
const { hash, pdfFile, filename, id } = currentUserFile
|
||||
const { hash, pdfFile, id } = currentUserFile
|
||||
if (!hash) return
|
||||
return (
|
||||
<div
|
||||
@ -56,7 +56,7 @@ const PdfView = ({
|
||||
>
|
||||
<PdfItem
|
||||
pdfFile={pdfFile}
|
||||
currentUserMarks={filterByFile(currentUserMarks, filename)}
|
||||
currentUserMarks={filterByFile(currentUserMarks, hash)}
|
||||
selectedMark={selectedMark}
|
||||
handleMarkClick={handleMarkClick}
|
||||
selectedMarkValue={selectedMarkValue}
|
||||
|
Loading…
Reference in New Issue
Block a user