Created
September 19, 2021 13:26
-
-
Save SafaElmali/13cc1afade5af5b01b9835799ae7a3a8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import "../styles/productDetail.css"; | |
import { useState } from "react"; | |
import Modal from "./Modal"; | |
const ProductDetail = () => { | |
const [isOpen, setIsOpen] = useState(false); | |
const handleOpen = () => { | |
setIsOpen(true); | |
}; | |
return ( | |
<div className="product-container"> | |
.... | |
<div className="product-button-container"> | |
<button className="add-to-basket-button" onClick={handleOpenPortal}> | |
Sepete Ekle | |
</button> | |
</div> | |
</div> | |
<Modal isOpen={isOpen} setIsOpen={setIsOpen} /> | |
</div> | |
); | |
}; | |
export default ProductDetail; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment