1
0
mirror of https://github.com/chinchang/web-maker.git synced 2025-07-13 10:06:23 +02:00

fix: update the syntax from class components to functional

This commit is contained in:
Arnab Sen
2022-04-02 21:06:00 +05:30
parent 1e0d04d7a0
commit c7e2084d15

View File

@ -46,7 +46,7 @@ const Modal = ({
if (show) {
// HACK: refs will evaluate on next tick due to portals
setTimeout(() => {
const closeButton = this.overlayEl.querySelector(
const closeButton = overlayRef.current.querySelector(
'.js-modal__close-btn'
);
if (closeButton) {