-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Add lazy loading for images in CourseContentDetails, Course…
…InstructorDetails, HeaderPhone, Hero, and ProfileInfo components
- Loading branch information
1 parent
2b2bdf9
commit 1b6395a
Showing
5 changed files
with
115 additions
and
43 deletions.
There are no files selected for viewing
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
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
36 changes: 36 additions & 0 deletions
36
src/components/courses/courseDetails/PaymentDetailsModal.jsx
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import CourseEnrollmentDetails from "./CourseEnrollmentDetails"; | ||
const PaymentDetailsModal = ({ course }) => { | ||
const { duration, price, paymentModel, _id, videos, financialAid } = course; | ||
return ( | ||
<> | ||
<button | ||
className="btn bg-blue-400 text-white" | ||
onClick={() => document.getElementById("my_modal_1").showModal()} | ||
> | ||
Course Enrollment Details | ||
</button> | ||
<dialog id="my_modal_1" className="modal"> | ||
<div className="modal-box"> | ||
<h3 className="font-bold text-lg">Course Enrollment information</h3> | ||
<p className="py-4"> | ||
<CourseEnrollmentDetails | ||
duration={duration} | ||
price={price} | ||
paymentModel={paymentModel} | ||
courseId={_id} | ||
videos={videos} | ||
financialAid={financialAid} | ||
/> | ||
</p> | ||
<div className="modal-action"> | ||
<form method="dialog"> | ||
<button className="btn">Close</button> | ||
</form> | ||
</div> | ||
</div> | ||
</dialog> | ||
</> | ||
); | ||
}; | ||
|
||
export default PaymentDetailsModal; |
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
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