--- // Import the necessary dependencies import TabNav from '@components/ui/blocks/TabNav.astro'; import TabContent from '@components/ui/blocks/TabContent.astro'; import Icon from '@components/ui/icons/Icon.astro'; // Define props from Astro const { title, tabs } = Astro.props; // Define TypeScript interface for tab object interface Tab { heading: string; content: string; svg: string; src: any; alt: string; first?: boolean; second?: boolean; } // Define TypeScript interface for props interface Props { title?: string; tabs: Tab[]; } ---
{/* Section's heading and tab navigation */}

{ /* About Fragment: https://docs.astro.build/en/basics/astro-syntax/#fragments */ }

{ /* Tab navigation - use the attribute 'first' in the first TabNav for the component to work */ }
{ /* Contents for each tab - the 'first' attribute should be used in the first tab for that tab to be initially visible, 'second' changes the styles */ }
{ tabs.map((tab, index) => ( )) }
{/* Decorative background and sizing */}