From 2c98f1e5157875e43bd230db365a06b3cff66af5 Mon Sep 17 00:00:00 2001 From: Colin Slater Date: Mon, 24 Jun 2024 16:08:46 -0700 Subject: [PATCH] Switch to Link element to accommodate basePath. --- app/collection/[...path]/page.js | 9 +++++---- app/globals.css | 6 ++++++ app/page.js | 7 ++++--- app/plot/[plotName]/[...path]/page.js | 3 ++- app/tract/[tract]/[...path]/page.js | 3 ++- 5 files changed, 19 insertions(+), 9 deletions(-) diff --git a/app/collection/[...path]/page.js b/app/collection/[...path]/page.js index 4c9dfd3..561e202 100644 --- a/app/collection/[...path]/page.js +++ b/app/collection/[...path]/page.js @@ -1,5 +1,6 @@ import React from 'react'; +import Link from 'next/link' import SelectionDropdown from '../../selectionDropdown' import { GetSummary } from '../../summaries' @@ -81,7 +82,7 @@ export default async function Collection({params}) { return (
-
<- Back to collections
+
<- Back to collections
{collection}
@@ -96,7 +97,7 @@ export default async function Collection({params}) { {tractKeys.map((tract, n) => - {tract} + {tract} {tractEntries[tract]} )} @@ -111,7 +112,7 @@ export default async function Collection({params}) { {visitKeys.map((visit, n) => - {visit} + {visit} {visitEntries[visit]} )} @@ -131,7 +132,7 @@ export default async function Collection({params}) { {plotKeys.map((plot, n) => - {plot} + {plot} {plotEntries[plot].count} )} diff --git a/app/globals.css b/app/globals.css index 76e0715..8b7534a 100644 --- a/app/globals.css +++ b/app/globals.css @@ -16,6 +16,12 @@ } } +@layer base { + a { + @apply hover:underline; + } +} + /* body { color: rgb(var(--foreground-rgb)); diff --git a/app/page.js b/app/page.js index 9384d8a..c492ab1 100644 --- a/app/page.js +++ b/app/page.js @@ -1,4 +1,5 @@ +import Link from 'next/link' import {ListSummaries, GetSummary, ListReports} from './summaries' @@ -37,7 +38,7 @@ export default async function Collections() { {collections.map((collection, n) => - ({collection} + ({collection} 4321 2024-05-06 ))} @@ -50,14 +51,14 @@ export default async function Collections() { - + {reports.map((collection, n) => - ( + ())} diff --git a/app/plot/[plotName]/[...path]/page.js b/app/plot/[plotName]/[...path]/page.js index 66340f6..6081040 100644 --- a/app/plot/[plotName]/[...path]/page.js +++ b/app/plot/[plotName]/[...path]/page.js @@ -1,5 +1,6 @@ import React from 'react'; +import Link from 'next/link' import { GetSummary } from '../../../summaries' @@ -33,7 +34,7 @@ export default async function Collection({params, searchParams}) { return (
-
<- Back to collection
+
<- Back to collection
{collection}
{plotName}
diff --git a/app/tract/[tract]/[...path]/page.js b/app/tract/[tract]/[...path]/page.js index 33f1a4c..30c3f0b 100644 --- a/app/tract/[tract]/[...path]/page.js +++ b/app/tract/[tract]/[...path]/page.js @@ -1,5 +1,6 @@ import React from 'react'; +import Link from 'next/link' import { GetSummary } from '../../../summaries' @@ -49,7 +50,7 @@ export default async function Collection({params, searchParams}) { return (
- +
<- Back to collection
{collection}
Tract {tract}
CollectionReport Plots Last Updated
{collection}
{collection} 4321 2024-05-06