style: better map

This commit is contained in:
hamster1963 2024-11-28 17:54:45 +08:00
parent db3338c159
commit 6788aab22e
2 changed files with 3 additions and 2 deletions

View File

@ -68,7 +68,7 @@ export function InteractiveMap({
d={path(feature) || ""}
className={
isHighlighted
? "fill-orange-500 hover:fill-orange-300 stroke-orange-500 dark:stroke-amber-900 dark:fill-amber-900 dark:hover:fill-amber-700 transition-all cursor-pointer"
? "fill-green-700 hover:fill-green-600 dark:fill-green-900 dark:hover:fill-green-700 transition-all cursor-pointer"
: "fill-neutral-200/50 dark:fill-neutral-800 stroke-neutral-300/40 dark:stroke-neutral-700 stroke-[0.5]"
}
onMouseEnter={() => {
@ -120,7 +120,7 @@ export function InteractiveMap({
cx={x}
cy={y}
r={4}
className="fill-orange-500 hover:fill-orange-300 stroke-orange-500 dark:stroke-amber-900 dark:fill-amber-900 dark:hover:fill-amber-700 transition-all"
className="fill-sky-700 stroke-white hover:fill-sky-600 dark:fill-sky-900 dark:hover:fill-sky-700 transition-all"
/>
</g>
);

View File

@ -12,6 +12,7 @@ export const countryCoordinates: Record<
BN: { lat: 4.5, lng: 114.6667, name: "Brunei" }, // 文莱
KH: { lat: 13.0, lng: 105.0, name: "Cambodia" }, // 柬埔寨
CN: { lat: 35.0, lng: 105.0, name: "China" }, // 中国
HK: { lat: 22.0, lng: 114.0, name: "Hong Kong" }, // 香港
CY: { lat: 35.0, lng: 33.0, name: "Cyprus" }, // 塞浦路斯
GE: { lat: 42.0, lng: 43.5, name: "Georgia" }, // 格鲁吉亚
IN: { lat: 20.0, lng: 77.0, name: "India" }, // 印度