fix some bug in some blocks

This commit is contained in:
mr.sabri
2026-07-23 06:55:21 +03:30
parent 89fbd6d158
commit edb3e10469
65 changed files with 1565 additions and 1476 deletions
+30 -25
View File
@@ -14,12 +14,16 @@ interface Feature250Props {
const Feature250 = ({ className }: Feature250Props) => {
return (
<section dir="rtl" lang="fa" className={cn("py-32", className)}>
<div className="container">
<section
dir="rtl"
lang="fa"
className={cn("relative w-full min-w-0 overflow-hidden py-32", className)}
>
<div className="container min-w-0">
<p className="mx-auto mb-4 max-w-sm text-center text-pretty text-muted-foreground md:text-xl">
با سگمنت‌بندی دقیق، پیام مناسب را به مخاطب مناسب برسانید. داده رفتاری نشان می‌دهد کدام محتوا بیشترین تأثیر را روی تبدیل دارد.
</p>
<h1 className="mx-auto -mb-12 max-w-3xl text-center text-xl font-medium tracking-tighter text-balance md:text-2xll lg:mb-5 lg:text-2xll">
<h1 className="mx-auto mb-2 max-w-3xl text-center text-xl font-medium tracking-tighter text-balance break-words md:text-2xll lg:mb-5 lg:text-2xll">
کمپین‌هایی بسازید که واقعاً تبدیل می‌شوند
</h1>
<AnimatedBeamIllustration />
@@ -44,14 +48,15 @@ function AnimatedBeamIllustration() {
const div7Ref = useRef<HTMLDivElement>(null);
return (
<div
className="relative flex w-full items-center justify-center overflow-hidden p-10"
className="relative flex w-full min-w-0 max-w-full items-center justify-center overflow-hidden p-6 sm:p-10"
ref={containerRef}
>
<div className="flex w-full flex-col items-center justify-between gap-10 lg:flex-row">
<div className="relative z-10 flex h-100 w-full items-center justify-center rounded-3xl lg:w-0">
<div className="flex w-full min-w-0 flex-col items-center justify-between gap-10 lg:flex-row">
{/* Reserve width on lg so absolute nodes/beams stay inside the frame (avoid lg:w-0 bleed). */}
<div className="relative z-10 flex h-100 w-full min-w-0 items-center justify-center rounded-3xl lg:w-56 lg:shrink-0">
<div
ref={div1Ref}
className="absolute start-0 top-40 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-0 lg:top-1/2"
className="absolute start-2 top-40 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-2 lg:top-1/2"
>
<div className="flex size-10 items-center justify-center rounded-lg border border-border bg-background p-[5px]">
<div className="flex size-full items-center justify-center rounded-md border border-border bg-muted">
@@ -61,7 +66,7 @@ function AnimatedBeamIllustration() {
</div>
<div
ref={div2Ref}
className="absolute end-0 top-40 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-20 lg:top-20"
className="absolute end-2 top-40 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-16 lg:top-20"
>
<div className="flex size-10 items-center justify-center rounded-lg border border-border bg-background p-[5px]">
<div className="flex size-full items-center justify-center rounded-md border border-border bg-muted">
@@ -71,7 +76,7 @@ function AnimatedBeamIllustration() {
</div>
<div
ref={div3Ref}
className="absolute start-6 bottom-0 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-20 lg:bottom-2"
className="absolute start-6 bottom-4 z-10 flex size-18 items-center justify-center rounded-full bg-background p-1 lg:start-16 lg:bottom-4"
>
<div className="flex size-10 items-center justify-center rounded-lg border border-border bg-background p-[5px]">
<div className="flex size-full items-center justify-center rounded-md border border-border bg-muted">
@@ -81,7 +86,7 @@ function AnimatedBeamIllustration() {
</div>
<div
ref={div4Ref}
className="absolute end-6 bottom-0 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-50 lg:top-0"
className="absolute end-6 bottom-4 z-10 flex size-18 items-center justify-center rounded-full bg-background p-1 lg:start-36 lg:top-4"
>
<div className="flex size-10 items-center justify-center rounded-lg border border-border bg-background p-[5px]">
<div className="flex size-full items-center justify-center rounded-md border border-border bg-muted">
@@ -91,7 +96,7 @@ function AnimatedBeamIllustration() {
</div>
<div
ref={div5Ref}
className="absolute top-20 z-10 flex size-18 -translate-y-1/2 items-center justify-center rounded-full bg-background p-1 lg:start-50 lg:top-100"
className="absolute start-1/2 top-20 z-10 flex size-18 -translate-x-1/2 items-center justify-center rounded-full bg-background p-1 rtl:translate-x-1/2 lg:start-36 lg:top-auto lg:bottom-4 lg:translate-x-0 rtl:lg:translate-x-0"
>
<div className="flex size-10 items-center justify-center rounded-lg border border-border bg-background p-[5px]">
<div className="flex size-full items-center justify-center rounded-md border border-border bg-muted">
@@ -102,7 +107,7 @@ function AnimatedBeamIllustration() {
</div>
<div
ref={div6Ref}
className="z-10 flex size-32 items-center justify-center rounded-3xl border bg-muted lg:size-42"
className="z-10 flex size-32 shrink-0 items-center justify-center rounded-3xl border bg-muted lg:size-42"
>
<img
src="/block-media/shadcnblocks/block/block-1.svg"
@@ -112,7 +117,7 @@ function AnimatedBeamIllustration() {
</div>
<div
ref={div7Ref}
className="z-10 mt-40 flex size-15 items-center justify-center rounded-xl border bg-muted lg:mt-0"
className="z-10 mt-24 flex size-15 shrink-0 items-center justify-center rounded-xl border bg-muted lg:mt-0"
>
<Zap fill="currentColor" />
</div>
@@ -180,10 +185,10 @@ function AnimatedBeamIllustration() {
reverse={REVERSE}
/>
<AnimatedBeam
endYOffset={-30}
endXOffset={60}
endYOffset={-24}
endXOffset={24}
duration={DURATION}
curvature={-140}
curvature={-80}
containerRef={containerRef}
fromRef={div2Ref}
toRef={div6Ref}
@@ -191,8 +196,8 @@ function AnimatedBeamIllustration() {
/>
<AnimatedBeam
duration={DURATION}
endYOffset={30}
curvature={140}
endYOffset={24}
curvature={80}
containerRef={containerRef}
fromRef={div3Ref}
toRef={div6Ref}
@@ -200,9 +205,9 @@ function AnimatedBeamIllustration() {
/>
<AnimatedBeam
duration={DURATION}
endYOffset={-30}
endXOffset={-60}
curvature={-180}
endYOffset={-24}
endXOffset={-24}
curvature={-100}
containerRef={containerRef}
fromRef={div4Ref}
toRef={div6Ref}
@@ -211,9 +216,9 @@ function AnimatedBeamIllustration() {
<AnimatedBeam
duration={DURATION}
endXOffset={-60}
endYOffset={30}
curvature={180}
endXOffset={-24}
endYOffset={24}
curvature={100}
containerRef={containerRef}
fromRef={div5Ref}
toRef={div6Ref}
@@ -386,7 +391,7 @@ const AnimatedBeam: React.FC<AnimatedBeamProps> = ({
height={svgDimensions.height}
xmlns="http://www.w3.org/2000/svg"
className={cn(
"pointer-events-none absolute start-0 top-0 transform-gpu stroke-2",
"pointer-events-none absolute start-0 top-0 max-w-full overflow-hidden transform-gpu stroke-2",
className,
)}
viewBox={`0 0 ${svgDimensions.width} ${svgDimensions.height}`}