Add dependencies and update code for PDF parsing and searching

This commit is contained in:
n4ze3m
2024-02-25 00:12:46 +05:30
parent f87953ba5c
commit 06b32176a9
22 changed files with 577 additions and 249 deletions

View File

@@ -1,11 +1,12 @@
import { useState } from "react"
type Props = {
onClick: () => void
onClick?: () => void
disabled?: boolean
className?: string
text?: string
textOnSave?: string
btnType?: "button" | "submit" | "reset"
}
export const SaveButton = ({
@@ -13,11 +14,13 @@ export const SaveButton = ({
disabled,
className,
text = "Save",
textOnSave = "Saved"
textOnSave = "Saved",
btnType = "button"
}: Props) => {
const [clickedSave, setClickedSave] = useState(false)
return (
<button
type={btnType}
onClick={() => {
setClickedSave(true)
onClick()