"use client";

import React, { useEffect } from 'react'
import Breadcrumb_comp from '../common-components/breadcrumb-comp/Breadcrumb_comp';
import './Terms_Conditions.css'
import { useDispatch, useSelector } from 'react-redux';
import parse from "html-react-parser"
import { getTerms_and_Conditions } from '../../features/terms_conditions.js/Slice';


const Terms_Conditions = () => {

    const breadcrumbs = [
        { label: "Home", link: "/", isActive: false },
        { label: "Terms and Conditions", link: "", isActive: true },
    ];

    const termsconditions = useSelector((state) => state.termsconditions.termsconditions)
    const dispatch = useDispatch()
    useEffect(() => {
        dispatch(getTerms_and_Conditions());

    }, [])

    return (
        <>
            <section className='Privacy_Policy Terms_Conditions'>
                <div className='bg_img_div'>
                    <div className='bg_div'>
                        {/* <img src='/assets/images/privacy/bg2.png' className='bg_img' /> */}
                    </div>
                    <div className='white_bg_div'>
                        <Breadcrumb_comp breadcrumbs={breadcrumbs} />
                        <div className='container'>
                            <p className='section_title heading_text'></p>
                        </div>
                    </div>
                </div>
                <div className='container'>
                    <div className='main_content_div'>
                        {termsconditions?.map((terms) => (<p className='dark_black_text'>{parse(terms.content)}</p>))}
                        {/* <div className='btns_holder'>
                                           <Light_Gray_Outline_Btn btnText={"Decline"} />
                                           <Green_Outline_Btn btnText={"Accept"} />
                                       </div> */}
                    </div>
                </div>
            </section >

            {/* <Stay_Connected /> */}
        </>

    )
}

export default Terms_Conditions
