main page

This commit is contained in:
Flatlogic Bot 2025-07-02 16:49:21 +00:00
parent 6b8ab3d956
commit 44604aa457
6 changed files with 39 additions and 319 deletions

5
.gitignore vendored
View File

@ -1,3 +1,8 @@
node_modules/ node_modules/
*/node_modules/ */node_modules/
*/build/ */build/
**/node_modules/
**/build/
.DS_Store
.env

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
{}

View File

@ -11,17 +11,8 @@ import { baseURLApi } from '../config';
import { useRouter } from 'next/router'; import { useRouter } from 'next/router';
import ErrorBoundary from '../components/ErrorBoundary'; import ErrorBoundary from '../components/ErrorBoundary';
import DevModeBadge from '../components/DevModeBadge'; import DevModeBadge from '../components/DevModeBadge';
import 'intro.js/introjs.css';
import { appWithTranslation } from 'next-i18next'; import { appWithTranslation } from 'next-i18next';
import '../i18n'; import '../i18n';
import IntroGuide from '../components/IntroGuide';
import {
appSteps,
landingSteps,
loginSteps,
usersSteps,
rolesSteps,
} from '../stores/introSteps';
// Initialize axios // Initialize axios
axios.defaults.baseURL = process.env.NEXT_PUBLIC_BACK_API axios.defaults.baseURL = process.env.NEXT_PUBLIC_BACK_API
@ -45,9 +36,6 @@ function MyApp({ Component, pageProps }: AppPropsWithLayout) {
// Use the layout defined at the page level, if available // Use the layout defined at the page level, if available
const getLayout = Component.getLayout || ((page) => page); const getLayout = Component.getLayout || ((page) => page);
const router = useRouter(); const router = useRouter();
const [stepsEnabled, setStepsEnabled] = React.useState(false);
const [stepName, setStepName] = React.useState('');
const [steps, setSteps] = React.useState([]);
axios.interceptors.request.use( axios.interceptors.request.use(
(config) => { (config) => {
@ -93,98 +81,16 @@ function MyApp({ Component, pageProps }: AppPropsWithLayout) {
window.addEventListener('message', handleMessage); window.addEventListener('message', handleMessage);
return () => window.removeEventListener('message', handleMessage); return () => window.removeEventListener('message', handleMessage);
}, []); }, []);
React.useEffect(() => {
const isCompleted = (stepKey: string) => {
return localStorage.getItem(`completed_${stepKey}`) === 'true';
};
if (router.pathname === '/login' && !isCompleted('loginSteps')) {
setSteps(loginSteps);
setStepName('loginSteps');
setStepsEnabled(true);
} else if (router.pathname === '/' && !isCompleted('landingSteps')) {
setSteps(landingSteps);
setStepName('landingSteps');
setStepsEnabled(true);
} else if (router.pathname === '/dashboard' && !isCompleted('appSteps')) {
setTimeout(() => {
setSteps(appSteps);
setStepName('appSteps');
setStepsEnabled(true);
}, 1000);
} else if (
router.pathname === '/users/users-list' &&
!isCompleted('usersSteps')
) {
setTimeout(() => {
setSteps(usersSteps);
setStepName('usersSteps');
setStepsEnabled(true);
}, 1000);
} else if (
router.pathname === '/roles/roles-list' &&
!isCompleted('rolesSteps')
) {
setTimeout(() => {
setSteps(rolesSteps);
setStepName('rolesSteps');
setStepsEnabled(true);
}, 1000);
} else {
setSteps([]);
setStepsEnabled(false);
}
}, [router.pathname]);
const handleExit = () => {
setStepsEnabled(false);
};
const title = 'philip';
const description = 'philip generated by Flatlogic';
const url = 'https://flatlogic.com/';
const image = `https://flatlogic.com/logo.svg`;
const imageWidth = '1920';
const imageHeight = '960';
return ( return (
<Provider store={store}> <Provider store={store}>
{getLayout( {getLayout(
<> <>
<Head>
<meta name='description' content={description} />
<meta property='og:url' content={url} />
<meta property='og:site_name' content='https://flatlogic.com/' />
<meta property='og:title' content={title} />
<meta property='og:description' content={description} />
<meta property='og:image' content={image} />
<meta property='og:image:type' content='image/png' />
<meta property='og:image:width' content={imageWidth} />
<meta property='og:image:height' content={imageHeight} />
<meta property='twitter:card' content='summary_large_image' />
<meta property='twitter:title' content={title} />
<meta property='twitter:description' content={description} />
<meta property='twitter:image:src' content={image} />
<meta property='twitter:image:width' content={imageWidth} />
<meta property='twitter:image:height' content={imageHeight} />
<link rel='icon' href='/favicon.svg' />
</Head>
<ErrorBoundary> <ErrorBoundary>
<Component {...pageProps} /> <Component {...pageProps} />
</ErrorBoundary> </ErrorBoundary>
<IntroGuide
steps={steps}
stepsName={stepName}
stepsEnabled={stepsEnabled}
onExit={handleExit}
/>
{(process.env.NODE_ENV === 'development' || {(process.env.NODE_ENV === 'development' ||
process.env.NODE_ENV === 'dev_stage') && <DevModeBadge />} process.env.NODE_ENV === 'dev_stage') && <DevModeBadge />}
</>, </>
)} )}
</Provider> </Provider>
); );

View File

@ -1,127 +1,26 @@
import React, { useEffect, useState } from 'react'; import React from 'react';
import type { ReactElement } from 'react';
import Head from 'next/head'; import Head from 'next/head';
import Link from 'next/link';
import { useAppSelector } from '../stores/hooks';
import LayoutGuest from '../layouts/Guest';
import WebSiteHeader from '../components/WebPageComponents/Header';
import WebSiteFooter from '../components/WebPageComponents/Footer';
import {
HeroDesigns,
FeaturesDesigns,
AboutUsDesigns,
ContactFormDesigns,
} from '../components/WebPageComponents/designs';
import HeroSection from '../components/WebPageComponents/HeroComponent';
import FeaturesSection from '../components/WebPageComponents/FeaturesComponent';
import AboutUsSection from '../components/WebPageComponents/AboutUsComponent';
import ContactFormSection from '../components/WebPageComponents/ContactFormComponent';
export default function WebSite() {
const cardsStyle = useAppSelector((state) => state.style.cardsStyle);
const bgColor = useAppSelector((state) => state.style.bgLayoutColor);
const projectName = 'philip';
useEffect(() => {
const darkElement = document.querySelector('body .dark');
if (darkElement) {
darkElement.classList.remove('dark');
}
}, []);
const pages = [
{
href: '/home',
label: 'home',
},
{
href: '/about',
label: 'about',
},
{
href: '/contact',
label: 'contact',
},
];
const features_points = [
{
name: 'Centralized Profile Links',
description:
"Access all of Philip Daineka's professional profiles in one convenient location. Simplify your networking and stay connected effortlessly.",
icon: 'mdiLinkVariant',
},
{
name: 'Real-Time Updates',
description:
'Stay informed with the latest updates from Philip Daineka. Our platform ensures you never miss important announcements or content.',
icon: 'mdiUpdate',
},
{
name: 'User-Friendly Interface',
description:
'Navigate through the platform with ease. Our intuitive design ensures a seamless experience for all users, regardless of technical expertise.',
icon: 'mdiAccountCircle',
},
];
export default function Home() {
return ( return (
<div className='flex flex-col min-h-screen'> <>
<Head> <Head>
<title>{`Philip Daineka's Linktree - Connect with Flatlogic CEO`}</title> <title>Philip Daineka</title>
<meta <meta name="description" content="Philip Daineka, CEO of Flatlogic; Building the future of AI-powered development" />
name='description'
content={`Explore and connect with Philip Daineka, CEO of Flatlogic. Access links to his professional profiles and stay updated with his latest content.`}
/>
</Head> </Head>
<WebSiteHeader projectName={'philip'} pages={pages} /> <main className="min-h-screen flex flex-col items-center justify-center bg-[#F8F9FF] p-4">
<main className={`flex-grow bg-white rounded-none `}> <h1 className="text-4xl font-bold text-[#02004E] mb-2">Philip Daineka</h1>
<HeroSection <p className="text-xl text-gray-600 mb-2">CEO, Flatlogic</p>
projectName={'philip'} <p className="text-lg text-gray-500 mb-8">Building the future of AI-powered development</p>
image={["Philip Daineka's professional profile links"]} <div className="w-full max-w-md">
mainText={`Connect with Philip Daineka, Flatlogic CEO`} <a href="https://www.linkedin.com/in/philip-daineka/" target="_blank" rel="noopener noreferrer" className="block bg-[#ffb531] hover:bg-[#e0a620] text-white rounded-lg py-3 mb-4 text-center font-medium">LinkedIn</a>
subTitle={`Discover all of Philip Daineka's professional profiles and stay updated with his latest content. Connect with the Flatlogic CEO across various platforms.`} <a href="https://x.com/Okendokenn" target="_blank" rel="noopener noreferrer" className="block bg-[#415FFF] hover:bg-[#2f4edd] text-white rounded-lg py-3 mb-4 text-center font-medium">Twitter / X</a>
design={HeroDesigns.IMAGE_LEFT || ''} <a href="https://www.instagram.com/okendoken/" target="_blank" rel="noopener noreferrer" className="block bg-[#F75249] hover:bg-[#d6413c] text-white rounded-lg py-3 mb-4 text-center font-medium">Instagram</a>
buttonText={`Explore Now`} <a href="https://www.threads.com/@okendoken" target="_blank" rel="noopener noreferrer" className="block bg-[#25d398] hover:bg-[#1fa884] text-white rounded-lg py-3 mb-4 text-center font-medium">Threads</a>
/> <a href="https://flatlogic.com" target="_blank" rel="noopener noreferrer" className="block bg-[#02004E] hover:bg-[#000039] text-white rounded-lg py-3 mb-4 text-center font-medium">Flatlogic</a>
<FeaturesSection
projectName={'philip'}
image={['Showcasing key platform features']}
withBg={0}
features={features_points}
mainText={`Explore ${projectName}'s Unique Features`}
subTitle={`Discover the key features that make ${projectName} your go-to platform for connecting with Philip Daineka.`}
design={FeaturesDesigns.CARDS_GRID_WITH_ICONS || ''}
/>
<AboutUsSection
projectName={'philip'}
image={["Philip Daineka's inspiring journey"]}
mainText={`Meet Philip Daineka, Flatlogic Visionary`}
subTitle={`Discover the journey and vision of Philip Daineka, the driving force behind Flatlogic. Learn about his mission to innovate and connect through technology.`}
design={AboutUsDesigns.IMAGE_RIGHT || ''}
buttonText={`Learn More`}
/>
<ContactFormSection
projectName={'philip'}
design={ContactFormDesigns.WITH_IMAGE || ''}
image={['Contact form for quick inquiries']}
mainText={`Get in Touch with Philip Daineka `}
subTitle={`Reach out to Philip Daineka for inquiries or collaborations. We aim to respond within 24 hours to all messages received through ${projectName}.`}
/>
</main>
<WebSiteFooter projectName={'philip'} pages={pages} />
</div> </div>
<footer className="mt-12 text-sm text-gray-400">© 2025 Flatlogic. Built with AI-powered tools.</footer>
</main>
</>
); );
} }
WebSite.getLayout = function getLayout(page: ReactElement) {
return <LayoutGuest>{page}</LayoutGuest>;
};

View File

@ -1,111 +1,21 @@
import React, { useEffect, useState } from 'react'; import React from 'react';
import type { ReactElement } from 'react'; import type { ReactElement } from 'react';
import Head from 'next/head'; import Head from 'next/head';
import Link from 'next/link';
import { useAppSelector } from '../../stores/hooks';
import LayoutGuest from '../../layouts/Guest'; import LayoutGuest from '../../layouts/Guest';
import WebSiteHeader from '../../components/WebPageComponents/Header';
import WebSiteFooter from '../../components/WebPageComponents/Footer';
import {
HeroDesigns,
FeaturesDesigns,
AboutUsDesigns,
ContactFormDesigns,
} from '../../components/WebPageComponents/designs';
import HeroSection from '../../components/WebPageComponents/HeroComponent';
import FeaturesSection from '../../components/WebPageComponents/FeaturesComponent';
import AboutUsSection from '../../components/WebPageComponents/AboutUsComponent';
import ContactFormSection from '../../components/WebPageComponents/ContactFormComponent';
export default function WebSite() {
const cardsStyle = useAppSelector((state) => state.style.cardsStyle);
const bgColor = useAppSelector((state) => state.style.bgLayoutColor);
const projectName = 'philip';
useEffect(() => {
const darkElement = document.querySelector('body .dark');
if (darkElement) {
darkElement.classList.remove('dark');
}
}, []);
const features_points = [
{
name: 'Centralized Profile Links',
description:
"Access all of Philip Daineka's professional profiles in one convenient location. Simplify your networking and stay connected effortlessly.",
icon: 'mdiLinkVariant',
},
{
name: 'Real-Time Updates',
description:
'Stay informed with the latest updates from Philip Daineka. Our platform ensures you never miss important announcements or content.',
icon: 'mdiUpdate',
},
{
name: 'User-Friendly Interface',
description:
'Navigate through the platform with ease. Our intuitive design ensures a seamless experience for all users, regardless of technical expertise.',
icon: 'mdiAccountCircle',
},
];
export default function HomePage() {
return ( return (
<div className='flex flex-col min-h-screen'> <>
<Head> <Head>
<title>{`Philip Daineka's Linktree - Connect with Flatlogic CEO`}</title> <meta charSet="utf-8" />
<meta <meta name="viewport" content="width=device-width, initial-scale=1" />
name='description' <title>Philip Daineka - Flatlogic CEO</title>
content={`Explore and connect with Philip Daineka, CEO of Flatlogic. Access links to his professional profiles and stay updated with his latest content.`}
/>
</Head> </Head>
<WebSiteHeader projectName={'philip'} /> <main />
<main className={`flex-grow bg-white rounded-none `}> </>
<HeroSection
projectName={'philip'}
image={["Philip Daineka's professional profile links"]}
mainText={`Connect with Philip Daineka, Flatlogic CEO`}
subTitle={`Discover all of Philip Daineka's professional profiles and stay updated with his latest content. Connect with the Flatlogic CEO across various platforms.`}
design={HeroDesigns.IMAGE_LEFT || ''}
buttonText={`Explore Now`}
/>
<FeaturesSection
projectName={'philip'}
image={['Showcasing key platform features']}
withBg={0}
features={features_points}
mainText={`Explore ${projectName}'s Unique Features`}
subTitle={`Discover the key features that make ${projectName} your go-to platform for connecting with Philip Daineka.`}
design={FeaturesDesigns.CARDS_GRID_WITH_ICONS || ''}
/>
<AboutUsSection
projectName={'philip'}
image={["Philip Daineka's inspiring journey"]}
mainText={`Meet Philip Daineka, Flatlogic Visionary`}
subTitle={`Discover the journey and vision of Philip Daineka, the driving force behind Flatlogic. Learn about his mission to innovate and connect through technology.`}
design={AboutUsDesigns.IMAGE_RIGHT || ''}
buttonText={`Learn More`}
/>
<ContactFormSection
projectName={'philip'}
design={ContactFormDesigns.WITH_IMAGE || ''}
image={['Contact form for quick inquiries']}
mainText={`Get in Touch with Philip Daineka `}
subTitle={`Reach out to Philip Daineka for inquiries or collaborations. We aim to respond within 24 hours to all messages received through ${projectName}.`}
/>
</main>
<WebSiteFooter projectName={'philip'} />
</div>
); );
} }
WebSite.getLayout = function getLayout(page: ReactElement) { HomePage.getLayout = function getLayout(page: ReactElement) {
return <LayoutGuest>{page}</LayoutGuest>; return <LayoutGuest>{page}</LayoutGuest>;
}; };