Skip to content

Commit

Permalink
chore: fix ts errors
Browse files Browse the repository at this point in the history
  • Loading branch information
dominik-stumpf committed Jul 10, 2024
1 parent 8e1d8bf commit 35575c9
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 102 deletions.
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"@chakra-ui/next-js": "^2.2.0",
"@chakra-ui/react": "^2.8.2",
"@chakra-ui/theme-tools": "^2.0.17",
"@coinbase/waas-sdk-web": "^3.3.2",
"@dotlottie/react-player": "^1.6.18",
"@emotion/react": "^11.11.4",
"@emotion/styled": "^11.11.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { ConnectEmailButton } from "@/components/Account/components/AccountModal/components/EmailAddress"
import { cn } from "@/lib/utils"
import { Tooltip } from "@chakra-ui/react"
import { EnvelopeSimple } from "@phosphor-icons/react"
import useUser from "components/[guild]/hooks/useUser"
import { useAccount } from "wagmi"
import { JoinStepUI } from "./JoinStep"
Expand Down
7 changes: 5 additions & 2 deletions src/hooks/useScrollBatchedRendering.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ interface CommonProps {
batchSize: number
disableRendering: boolean
setElementCount: Dispatch<SetStateAction<number>>
offsetPixel?: number
}

interface WithScrollTarget extends CommonProps {
Expand All @@ -19,14 +20,16 @@ export function useScrollBatchedRendering({
scrollTarget,
disableRendering,
setElementCount,
offsetPixel = 0,
}: WithScrollTarget) {
const localScrollTarget = useRef<HTMLElement>(null)
const localScrollTarget = useRef<HTMLElement | null>(null)

useScrollEffect(() => {
const target = scrollTarget === undefined ? localScrollTarget : scrollTarget
if (
!target.current ||
target.current.getBoundingClientRect().bottom > window.innerHeight ||
target.current.getBoundingClientRect().bottom - offsetPixel >
window.innerHeight ||
disableRendering
) {
return
Expand Down

This file was deleted.

0 comments on commit 35575c9

Please sign in to comment.