This commit is contained in:
2026-01-19 02:05:30 +01:00
parent 46266a7bbc
commit 4f6264f2e2
24 changed files with 431 additions and 228 deletions

View File

@@ -1,4 +1,5 @@
import React from 'react';
import Scribble from '@/components/Scribble';
interface HighlightBoxProps {
title?: string;
@@ -7,21 +8,31 @@ interface HighlightBoxProps {
}
const colorStyles = {
primary: 'bg-gradient-to-br from-primary/10 to-primary/5 border-primary/30',
secondary: 'bg-gradient-to-br from-blue-50 to-blue-100/50 border-blue-200',
accent: 'bg-gradient-to-br from-green-50 to-green-100/50 border-green-200',
primary: 'bg-gradient-to-br from-primary/5 to-transparent border-primary/20',
secondary: 'bg-gradient-to-br from-blue-50/50 to-transparent border-blue-200/50',
accent: 'bg-gradient-to-br from-accent/5 to-transparent border-accent/20',
};
export default function HighlightBox({ title, children, color = 'primary' }: HighlightBoxProps) {
return (
<div className={`my-10 p-8 rounded-2xl border-2 ${colorStyles[color]} shadow-sm`}>
<div className={`my-12 p-8 md:p-10 rounded-3xl border ${colorStyles[color]} shadow-sm relative overflow-hidden group`}>
{/* Industrial accent corner */}
<div className="absolute top-0 right-0 w-16 h-16 bg-primary/5 -mr-8 -mt-8 rotate-45 transition-transform group-hover:scale-110" />
{title && (
<h3 className="text-2xl font-bold text-text-primary mb-4 flex items-center gap-3">
<span className="w-1.5 h-8 bg-primary rounded-full"></span>
{title}
<h3 className="text-2xl font-bold text-text-primary mb-6 flex items-center gap-4 relative">
<span className="relative">
{title}
{color === 'accent' && (
<Scribble
variant="underline"
className="absolute -bottom-2 left-0 w-full h-3 text-accent/40"
/>
)}
</span>
</h3>
)}
<div className="prose prose-lg max-w-none">
<div className="prose prose-lg max-w-none relative z-10">
{children}
</div>
</div>