@@ -2,7 +2,6 @@ import "maplibre-gl/dist/maplibre-gl.css";
22import { PageFrame } from "@/components/common/page-frame" ;
33import { parseStringParam } from "@/lib/routing" ;
44import { LayoutDashboard } from "lucide-react" ;
5- import ProjectMap from "./map" ;
65import { readZones } from "@/db/crud/zone" ;
76import {
87 readLocationsForProject ,
@@ -20,6 +19,7 @@ import {
2019 readNumberOfBoreholes ,
2120 readSptNValueStats ,
2221} from "@/db/crud/stat" ;
22+ import dynamic from "next/dynamic" ;
2323
2424// Props for Next.js dynamic route (project dashboard)
2525type Props = {
@@ -88,6 +88,10 @@ export default async function Page({ params }: Props) {
8888 . filter ( ( l ) => l . locationIdentifier !== null )
8989 . map ( ( l ) => ( { ...l , locationIdentifier : l . locationIdentifier ?? "" } ) ) ;
9090
91+ const ProjectMap = dynamic ( ( ) => import ( "./map" ) . then ( ( mod ) => mod ) , {
92+ ssr : false ,
93+ } ) ;
94+
9195 // Group project team members by role
9296 const owner = team . users . filter ( ( u ) => u . role === "OWNER" ) ;
9397 const contributors = team . users . filter ( ( u ) => u . role === "CONTRIBUTOR" ) ;
@@ -160,13 +164,13 @@ export default async function Page({ params }: Props) {
160164 />
161165 </ div >
162166 { /* Right Section: Team members by role */ }
163- < Card className = "flex w-full flex-shrink-0 flex-col overflow-y-auto p-4 sm:w-64 md:w-80" >
164- < CardHeader className = "p-0" >
165- < CardTitle className = "text-md font-semibold" > Team</ CardTitle >
167+ < Card className = "flex w-full flex-shrink-0 flex-col overflow-y-auto sm:w-64 md:w-80" >
168+ < CardHeader >
169+ < CardTitle > Team</ CardTitle >
166170 </ CardHeader >
167- < CardContent className = "ml-2 p-0" >
171+ < CardContent >
168172 < div >
169- < h3 className = "text-md mb-2 font-semibold" > Owner</ h3 >
173+ < h3 className = "mb-2 text-sm font-semibold" > Owner</ h3 >
170174 < div className = "flex flex-wrap gap-2" >
171175 { owner . length > 0 ? (
172176 owner . map ( ( { user } ) => (
@@ -184,7 +188,7 @@ export default async function Page({ params }: Props) {
184188 </ div >
185189 </ div >
186190 < div className = "mt-6" >
187- < h3 className = "text-md mb-2 font-semibold" > Contributors</ h3 >
191+ < h3 className = "mb-2 text-sm font-semibold" > Contributors</ h3 >
188192 < div className = "flex flex-wrap gap-2" >
189193 { contributors . length > 0 ? (
190194 contributors . map ( ( { user } ) => (
@@ -202,7 +206,7 @@ export default async function Page({ params }: Props) {
202206 </ div >
203207 </ div >
204208 < div className = "mt-6" >
205- < h3 className = "text-md mb-2 font-semibold" > Viewers</ h3 >
209+ < h3 className = "mb-2 text-sm font-semibold" > Viewers</ h3 >
206210 < div className = "flex flex-wrap gap-2" >
207211 { viewers . length > 0 ? (
208212 viewers . map ( ( { user } ) => (
0 commit comments