Visual edit in Lovable
Edited UI in Lovable
This commit is contained in:
parent
207b77500e
commit
86183cf856
1 changed files with 3 additions and 30 deletions
|
|
@ -65,16 +65,11 @@ const allInteractives = [{
|
||||||
}];
|
}];
|
||||||
|
|
||||||
// Featured interactives (3 fixed ones)
|
// Featured interactives (3 fixed ones)
|
||||||
const featuredInteractives = allInteractives.filter(interactive =>
|
const featuredInteractives = allInteractives.filter(interactive => ['northcotts-game', 'ternary-search-trick', 'game-of-sim'].includes(interactive.id));
|
||||||
['northcotts-game', 'ternary-search-trick', 'game-of-sim'].includes(interactive.id)
|
|
||||||
);
|
|
||||||
|
|
||||||
// Function to get random interactives (excluding featured ones)
|
// Function to get random interactives (excluding featured ones)
|
||||||
const getRandomInteractives = (count: number) => {
|
const getRandomInteractives = (count: number) => {
|
||||||
const availableInteractives = allInteractives.filter(interactive =>
|
const availableInteractives = allInteractives.filter(interactive => !['northcotts-game', 'ternary-search-trick', 'game-of-sim'].includes(interactive.id));
|
||||||
!['northcotts-game', 'ternary-search-trick', 'game-of-sim'].includes(interactive.id)
|
|
||||||
);
|
|
||||||
|
|
||||||
const shuffled = [...availableInteractives].sort(() => 0.5 - Math.random());
|
const shuffled = [...availableInteractives].sort(() => 0.5 - Math.random());
|
||||||
return shuffled.slice(0, count);
|
return shuffled.slice(0, count);
|
||||||
};
|
};
|
||||||
|
|
@ -82,29 +77,7 @@ const Index = () => {
|
||||||
const randomInteractives = getRandomInteractives(3);
|
const randomInteractives = getRandomInteractives(3);
|
||||||
return <Layout>
|
return <Layout>
|
||||||
{/* Hero Section */}
|
{/* Hero Section */}
|
||||||
<section className="py-20 px-4">
|
|
||||||
<div className="max-w-6xl mx-auto text-center">
|
|
||||||
<div className="mb-8">
|
|
||||||
<p className="text-xl text-muted-foreground max-w-3xl mx-auto leading-relaxed">
|
|
||||||
Discover a collection of interactive educational tools designed to supplement lectures and enhance understanding across multiple disciplines. From discrete mathematics to social choice theory.
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="flex justify-center gap-4 mb-16">
|
|
||||||
<Button asChild size="lg" className="bg-accent hover:bg-accent/90">
|
|
||||||
<Link to="/index" className="inline-flex items-center">
|
|
||||||
Browse All Interactives
|
|
||||||
<ArrowRight className="ml-2 w-4 h-4" />
|
|
||||||
</Link>
|
|
||||||
</Button>
|
|
||||||
<Button asChild variant="outline" size="lg">
|
|
||||||
<Link to="/themes">
|
|
||||||
Explore Themes
|
|
||||||
</Link>
|
|
||||||
</Button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
{/* Featured Interactives Section */}
|
{/* Featured Interactives Section */}
|
||||||
<section className="py-16 px-4 bg-muted/20">
|
<section className="py-16 px-4 bg-muted/20">
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue