|
1 | 1 | import React from 'react'; |
| 2 | +import { Link } from "react-router-dom"; |
2 | 3 |
|
3 | 4 | function Bmodel() { |
4 | 5 | const stakeholders = [ |
5 | | - { name: 'Workers', position: 'left-top', side: 'left', icon: '👷', color: 'from-orange-400 to-red-500' }, |
6 | | - { name: 'Home Owners', position: 'left-middle', side: 'left', icon: '🏠', color: 'from-green-400 to-emerald-500' }, |
7 | | - { name: 'Architects/\nDesigners', position: 'left-bottom', side: 'left', icon: '📐', color: 'from-purple-400 to-violet-500' }, |
8 | | - { name: 'Contractors', position: 'right-top', side: 'right', icon: '🔨', color: 'from-yellow-400 to-amber-500' }, |
9 | | - { name: 'Developers', position: 'right-middle', side: 'right', icon: '🏗️', color: 'from-blue-400 to-cyan-500' }, |
10 | | - { name: 'Material\nSuppliers', position: 'right-bottom', side: 'right', icon: '📦', color: 'from-teal-400 to-green-500' } |
| 6 | + { name: 'Workers', position: 'left-top', side: 'left', icon: '👷', color: 'from-orange-400 to-red-500',link: '/categories/workers' }, |
| 7 | + { name: 'Home Owners', position: 'left-middle', side: 'left', icon: '🏠', color: 'from-green-400 to-emerald-500',link: '/categories/houseowners' }, |
| 8 | + { name: 'Architects/\nDesigners', position: 'left-bottom', side: 'left', icon: '📐', color: 'from-purple-400 to-violet-500',link: '/categories/architects' }, |
| 9 | + { name: 'Contractors', position: 'right-top', side: 'right', icon: '🔨', color: 'from-yellow-400 to-amber-500',link: '/categories/contractors' }, |
| 10 | + { name: 'Developers', position: 'right-middle', side: 'right', icon: '🏗️', color: 'from-blue-400 to-cyan-500',link: '/categories/developers' }, |
| 11 | + { name: 'Material\nSuppliers', position: 'right-bottom', side: 'right', icon: '📦', color: 'from-teal-400 to-green-500',link: '/categories/suppliers' } |
11 | 12 | ]; |
12 | 13 |
|
13 | 14 | const getPositionClasses = (position: string) => { |
@@ -126,49 +127,41 @@ function Bmodel() { |
126 | 127 | </div> |
127 | 128 | ))} |
128 | 129 |
|
129 | | - {/* Stakeholder Circles */} |
130 | | - {stakeholders.map((stakeholder, index) => ( |
131 | | - <div key={index} |
132 | | - className={`absolute ${getPositionClasses(stakeholder.position)} z-30 group cursor-pointer`}> |
133 | | - <div className="relative"> |
134 | | - {/* Outer glow ring */} |
135 | | - <div className={`absolute inset-0 w-24 h-24 sm:w-36 sm:h-36 lg:w-40 lg:h-40 rounded-full bg-gradient-to-r ${stakeholder.color} opacity-0 group-hover:opacity-40 transition-all duration-700 scale-125 blur-xl -m-1 sm:-m-3 lg:-m-4`}></div> |
136 | | - |
137 | | - {/* Animated border ring */} |
138 | | - <div className={`absolute inset-0 w-22 h-22 sm:w-32 sm:h-32 lg:w-36 lg:h-36 rounded-full bg-gradient-to-r ${stakeholder.color} opacity-15 animate-pulse -m-0.5 sm:-m-2 lg:-m-2`} |
139 | | - style={{ animationDelay: `${index * 0.5}s` }}></div> |
140 | | - |
141 | | - {/* Glass morphism circle */} |
142 | | - <div className="relative w-20 h-20 sm:w-28 sm:h-28 lg:w-32 lg:h-32 bg-white/80 backdrop-blur-md rounded-full shadow-xl border border-gray-200/40 flex flex-col items-center justify-center |
143 | | - transform transition-all duration-500 group-hover:scale-110 group-hover:shadow-2xl |
144 | | - group-hover:bg-white/90 group-hover:border-gray-300/50 group-hover:-translate-y-2 sm:group-hover:-translate-y-3"> |
145 | | - |
146 | | - {/* Icon */} |
147 | | - <div className="text-lg sm:text-2xl lg:text-3xl mb-0.5 sm:mb-1 lg:mb-1 transition-all duration-300 group-hover:scale-125 group-hover:animate-bounce"> |
148 | | - {stakeholder.icon} |
149 | | - </div> |
150 | | - |
151 | | - {/* Text */} |
152 | | - <div className="text-center px-0.5 sm:px-2"> |
153 | | - <div className="text-xs sm:text-sm lg:text-sm font-bold text-gray-800 leading-tight whitespace-pre-line group-hover:text-gray-900 transition-all duration-300"> |
154 | | - {stakeholder.name} |
155 | | - </div> |
156 | | - </div> |
157 | | - |
158 | | - {/* Connection dots */} |
159 | | - <div className={`absolute -top-0.5 -right-0.5 sm:-top-1 sm:-right-1 w-1.5 h-1.5 sm:w-2.5 sm:h-2.5 lg:w-3 lg:h-3 bg-gradient-to-r ${stakeholder.color} rounded-full animate-ping`} |
160 | | - style={{ animationDelay: `${index * 0.8}s` }}></div> |
161 | | - </div> |
| 130 | + {/* Stakeholder Circles */} |
| 131 | + {stakeholders.map((stakeholder, index) => ( |
| 132 | + <Link |
| 133 | + key={index} |
| 134 | + to={stakeholder.link} |
| 135 | + className={`absolute ${getPositionClasses(stakeholder.position)} z-30 group cursor-pointer`} |
| 136 | + > |
| 137 | + <div className="relative"> |
| 138 | + {/* Outer glow ring */} |
| 139 | + <div className={`absolute inset-0 w-24 h-24 sm:w-36 sm:h-36 lg:w-40 lg:h-40 rounded-full bg-gradient-to-r ${stakeholder.color} opacity-0 group-hover:opacity-40 transition-all duration-700 scale-125 blur-xl -m-1 sm:-m-3 lg:-m-4`}></div> |
162 | 140 |
|
163 | | - {/* Floating animation with trail effect */} |
164 | | - <div className="absolute inset-0 w-20 h-20 sm:w-28 sm:h-28 lg:w-32 lg:h-32 rounded-full" |
165 | | - style={{ animation: `float 5s ease-in-out infinite ${index * 0.8}s` }}> |
166 | | - <div className={`w-1 h-1 sm:w-2 sm:h-2 lg:w-2 lg:h-2 bg-gradient-to-r ${stakeholder.color} rounded-full absolute top-0 left-1/2 transform -translate-x-1/2 opacity-40 animate-ping`} |
167 | | - style={{ animationDelay: `${index * 0.3}s` }}></div> |
168 | | - </div> |
| 141 | + {/* Animated border ring */} |
| 142 | + <div className={`absolute inset-0 w-22 h-22 sm:w-32 sm:h-32 lg:w-36 lg:h-36 rounded-full bg-gradient-to-r ${stakeholder.color} opacity-15 animate-pulse -m-0.5 sm:-m-2 lg:-m-2`} |
| 143 | + style={{ animationDelay: `${index * 0.5}s` }}></div> |
| 144 | + |
| 145 | + {/* Glass morphism circle */} |
| 146 | + <div className="relative w-20 h-20 sm:w-28 sm:h-28 lg:w-32 lg:h-32 bg-white/80 backdrop-blur-md rounded-full shadow-xl border border-gray-200/40 flex flex-col items-center justify-center |
| 147 | + transform transition-all duration-500 group-hover:scale-110 group-hover:shadow-2xl |
| 148 | + group-hover:bg-white/90 group-hover:border-gray-300/50 group-hover:-translate-y-2 sm:group-hover:-translate-y-3"> |
| 149 | + |
| 150 | + {/* Icon */} |
| 151 | + <div className="text-lg sm:text-2xl lg:text-3xl mb-0.5 sm:mb-1 lg:mb-1 transition-all duration-300 group-hover:scale-125 group-hover:animate-bounce"> |
| 152 | + {stakeholder.icon} |
| 153 | + </div> |
| 154 | + |
| 155 | + {/* Text */} |
| 156 | + <div className="text-center px-0.5 sm:px-2"> |
| 157 | + <div className="text-xs sm:text-sm lg:text-sm font-bold text-gray-800 leading-tight whitespace-pre-line group-hover:text-gray-900 transition-all duration-300"> |
| 158 | + {stakeholder.name} |
169 | 159 | </div> |
170 | 160 | </div> |
171 | | - ))} |
| 161 | + </div> |
| 162 | + </div> |
| 163 | + </Link> |
| 164 | + ))} |
172 | 165 |
|
173 | 166 | {/* Artistic decorative elements */} |
174 | 167 | <div className="absolute top-[8%] left-[42%] sm:left-[45%] w-8 h-8 sm:w-10 sm:h-10 lg:w-12 lg:h-12 opacity-20"> |
|
0 commit comments