Skip to content

Commit 9833a61

Browse files
committed
This PR fixes issue #1286 where mobile screens showed extra blank space above the homepage hero content.
1 parent caabde4 commit 9833a61

7 files changed

Lines changed: 130 additions & 272 deletions

File tree

src/components/FloatingContributors/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ The `FloatingContributors` component is a dynamic React component that displays
7979

8080
2. Use it in your application:
8181
```tsx
82-
<FloatingContributors headerEmbedded={false} />
82+
<FloatingContributors heroEmbedded={false} />
8383
```
8484

8585
---

src/components/FloatingContributors/index.tsx

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -100,11 +100,11 @@ interface ContributorActivity {
100100
}
101101

102102
interface FloatingContributorsProps {
103-
headerEmbedded?: boolean;
103+
heroEmbedded?: boolean;
104104
}
105105

106106
const FloatingContributors: React.FC<FloatingContributorsProps> = ({
107-
headerEmbedded = false,
107+
heroEmbedded = false,
108108
}) => {
109109
const [contributors, setContributors] = useState<Contributor[]>([]);
110110
const [activities, setActivities] = useState<ContributorActivity[]>([]);
@@ -491,11 +491,11 @@ const FloatingContributors: React.FC<FloatingContributorsProps> = ({
491491
<AnimatePresence>
492492
{isVisible && (
493493
<motion.div
494-
className={`floating-contributors-container ${headerEmbedded ? "header-embedded" : ""}`}
494+
className={`floating-contributors-container ${heroEmbedded ? "header-embedded" : ""}`}
495495
initial={{
496496
opacity: 0,
497-
y: headerEmbedded ? 0 : 50,
498-
scale: headerEmbedded ? 1 : 0.9,
497+
y: heroEmbedded ? 0 : 50,
498+
scale: heroEmbedded ? 1 : 0.9,
499499
}}
500500
animate={{
501501
opacity: 1,
@@ -504,26 +504,26 @@ const FloatingContributors: React.FC<FloatingContributorsProps> = ({
504504
}}
505505
exit={{
506506
opacity: 0,
507-
y: headerEmbedded ? 0 : 50,
508-
scale: headerEmbedded ? 1 : 0.9,
507+
y: heroEmbedded ? 0 : 50,
508+
scale: heroEmbedded ? 1 : 0.9,
509509
}}
510510
transition={{
511-
duration: headerEmbedded ? 0.8 : 0.6,
511+
duration: heroEmbedded ? 0.8 : 0.6,
512512
ease: [0.4, 0, 0.2, 1],
513513
}}
514514
>
515515
{/* Main floating card */}
516516
<motion.div
517517
className="floating-contributors-card"
518518
animate={
519-
headerEmbedded
519+
heroEmbedded
520520
? {}
521521
: {
522522
y: [0, -8, 0],
523523
}
524524
}
525525
transition={
526-
headerEmbedded
526+
heroEmbedded
527527
? {}
528528
: {
529529
duration: 4,

src/components/header.tsx

Lines changed: 0 additions & 180 deletions
This file was deleted.

0 commit comments

Comments
 (0)