File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3131 - name : Use GH Pages layout (no navbar)
3232 run : cp frontend/app/layout.ghpages.tsx frontend/app/layout.tsx
3333
34+ - name : Stub non-data-model pages (avoids codegen dependency at build time)
35+ run : |
36+ stub='export default function Page() { return null; }'
37+ echo "$stub" > 'frontend/app/(home)/page.tsx'
38+ echo "$stub" > 'frontend/app/(admin)/dashboard/page.tsx'
39+ echo "$stub" > 'frontend/app/(driver)/map/page.tsx'
40+ echo "$stub" > 'frontend/app/(driver)/sessions/page.tsx'
41+
3442 - name : Build static export
3543 run : cd frontend && npm run build
3644 env :
Original file line number Diff line number Diff line change @@ -36,11 +36,22 @@ stop-atlas:
3636clean-atlas :
3737 $(COMPOSE_ATLAS ) rm -f -s $(ATLAS_SERVICES )
3838
39+ GHPAGES_PAGES := frontend/app/layout.tsx \
40+ frontend/app/\(home\)/page.tsx \
41+ frontend/app/\(admin\)/dashboard/page.tsx \
42+ frontend/app/\(driver\)/map/page.tsx \
43+ frontend/app/\(driver\)/sessions/page.tsx
44+
3945preview-ghpages :
4046 cp frontend/app/layout.ghpages.tsx frontend/app/layout.tsx
47+ printf ' %s\n' ' export default function Page() { return null; }' \
48+ | tee frontend/app/\( home\) /page.tsx \
49+ frontend/app/\( admin\) /dashboard/page.tsx \
50+ frontend/app/\( driver\) /map/page.tsx \
51+ frontend/app/\( driver\) /sessions/page.tsx > /dev/null
4152 (cd frontend && GITHUB_PAGES_PREVIEW=true NEXT_PUBLIC_GITHUB_PAGES=true npm run build) \
42- || (git checkout frontend/app/layout.tsx && exit 1)
43- git checkout frontend/app/layout.tsx
53+ || (git checkout $( GHPAGES_PAGES ) && exit 1)
54+ git checkout $( GHPAGES_PAGES )
4455 rm -rf frontend/out/map frontend/out/sessions frontend/out/dashboard
4556 printf ' <!doctype html><html><head><meta charset="utf-8"/><meta http-equiv="refresh" content="0;url=data-model/"/></head><body></body></html>\n' \
4657 > frontend/out/index.html
Original file line number Diff line number Diff line change 11import type { Metadata } from "next" ;
22
3- import { Providers } from "./providers" ;
43import "./globals.css" ;
54
65export const metadata : Metadata = {
@@ -23,9 +22,7 @@ export default function RootLayout({
2322 />
2423 < style > { `[data-route="data-model"] { height: 100vh !important; }` } </ style >
2524 </ head >
26- < body >
27- < Providers > { children } </ Providers >
28- </ body >
25+ < body > { children } </ body >
2926 </ html >
3027 ) ;
3128}
You can’t perform that action at this time.
0 commit comments