// import MicrosoftPowerApps from '@/components/microsoftPowerApps/MicrosoftPowerApps';
import { NextPage } from 'next';
import dynamic from 'next/dynamic';
import StrapiSeo from '@/components/common/seo/StrapiSeo';
import { fetchSingleTypePageData } from '@/helpers/utilities/fetchAPI';
const MicrosoftPowerApps = dynamic(() => import('@/components/microsoftPowerApps/MicrosoftPowerApps'));

const populateFields = [
    'seo.ogImage',
    'seo.multiStructureData',
    'Hero.buttonIcon',
    'Hero.bottomImages',
    'service.serviceList.image',
    'Key.typeCard.image',
    'Advantage.typeCard.image',
    'overview.tabs.icon',
    'overview.tabs.bigImage',
    'Slider.ThreeDSlider.icon',
    'Slider.ThreeDSlider.image',
    'ChooseUs.chooseCard.image',
    'FAQ.FAQ.icon',
    'clients.brandLogos.brands.logo',
];

export async function getStaticProps() {
    return await fetchSingleTypePageData(populateFields, 'power-page');
}

const MicrosoftPowerAppsPage: NextPage = ({ data }: any) => {
    return (
        <>
            <StrapiSeo content={data.data?.attributes?.seo} />
            <MicrosoftPowerApps data={data.data?.attributes} />
        </>
    );
};

export default MicrosoftPowerAppsPage;
