Skip to content

Commit cfb5e5c

Browse files
authored
Merge pull request #295 from UW-Macrostrat/homepage-styling
Minor Homepage Updates
2 parents be61037 + e221dbb commit cfb5e5c

File tree

30 files changed

+351
-237
lines changed

30 files changed

+351
-237
lines changed

pages/+Page.client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
import { Image, Navbar, Footer } from "./index";
1+
import { Image, Navbar, Footer } from "~/components/general";
22
import h from "./+Page.module.sass";
33
import { LinkCard } from "~/components/cards";
44
import { useData } from "vike-react/useData";
55
import { isDev } from "@macrostrat-web/settings";
66

77
export function Page() {
88
return h("div.page-main", [
9-
h(Navbar, { className: "main-navbar" }),
109
h("div.start", [
1110
h(Image, { className: "back-img cover-image", src: "cover_large.jpg" }),
1211
h("div.banner", [
@@ -18,6 +17,7 @@ export function Page() {
1817
h(MacrostratStats),
1918
]),
2019
]),
20+
h(Navbar, { className: "main-navbar" }),
2121
h("div.buttons", [
2222
h(LinkCard, { title: "Geologic Map", href: "/map/#3/40.78/-94.13" }, [
2323
h("p", { className: "long" }, [

pages/+Page.module.sass

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@
99
height: 50vh
1010
color: white
1111
position: relative
12+
margin-bottom: calc(1em + 1px)
13+
border-bottom: 2px solid var(--text-emphasized-color)
14+
1215

1316
li
1417
float: left
@@ -52,6 +55,8 @@
5255
height: 50vh
5356
width: 100%
5457
object-fit: cover
58+
border-bottom: 2px solid var(--text-emphasized-color)
59+
5560

5661
.sea-image
5762
position: absolute
@@ -105,7 +110,6 @@
105110
flex-direction: column
106111
width: 100%
107112
padding: 0 20%
108-
border-top: 2px solid var(--text-emphasized-color)
109113
border-bottom: 2px solid var(--text-emphasized-color)
110114

111115
.country_container

pages/_error/+Page.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { Link, PageHeader } from "~/components";
44
import { usePageContext } from "vike-react/usePageContext";
55
import { ClientOnly } from "vike-react/ClientOnly";
66
import { Spinner, Button, Card } from "@blueprintjs/core";
7-
import { BlankImage } from "../index";
7+
import { BlankImage } from "~/components/general";
88
import { LinkCard } from "~/components";
99

1010
export function Page() {

pages/about/+Page.client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Image, Navbar, Footer } from "../index";
1+
import { Image, Navbar, Footer } from "~/components/general";
22
import { Divider } from "@blueprintjs/core";
33
import h from "./main.module.sass";
44
import { ContentPage } from "~/layouts";
@@ -117,7 +117,7 @@ export function Page() {
117117
h(
118118
"a",
119119
{
120-
href: "http://fc.umn.edu/",
120+
href: "https://flyovercountry.io/",
121121
target: "_blank",
122122
rel: "noopener noreferrer",
123123
},

pages/columns/+Page.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import h from "./main.module.sass";
1212
import { useData } from "vike-react/useData";
1313
import { ClientOnly } from "vike-react/ClientOnly";
1414
import { navigate } from "vike/client/router";
15-
import { SearchBar } from "../index";
15+
import { SearchBar } from "~/components/general";
1616

1717
export function Page(props) {
1818
return h(ColumnListPage, props);

pages/columns/groups/@group/+Page.client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { usePageContext } from "vike-react/usePageContext";
2-
import { IndividualPage } from "../../../lex/index";
2+
import { IndividualPage } from "../../../../src/components/lex/index";
33

44
export function Page() {
55
const pageContext = usePageContext();

pages/donate/+Page.client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Image, Navbar, Footer } from "../index";
1+
import { Image, Navbar, Footer } from "~/components/general";
22
import h from "./main.module.sass";
33

44
export function Page() {

pages/lex/+Page.ts

Lines changed: 56 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { ContentPage } from "~/layouts";
33
import { apiV2Prefix } from "@macrostrat-web/settings";
44
import { useAPIResult } from "@macrostrat/ui-components";
55
import h from "./+Page.module.sass";
6-
import { Loading } from "../index";
6+
import { Loading, Footer } from "~/components/general";
77

88
export function Page() {
99
const res = useAPIResult(apiV2Prefix + "/stats?all")?.success?.data;
@@ -31,64 +31,67 @@ export function Page() {
3131
measurements += stat.measurements || 0;
3232
});
3333

34-
return h(ContentPage, [
35-
h(PageHeader, { title: "Lexicon" }),
34+
return h("div", [
35+
h(ContentPage, [
36+
h(PageHeader, { title: "Lexicon" }),
3637

37-
h("p", [
38-
"This is the homepage of Macrostrat's geological lexicons, which are assembled from many data sources including Canada's ",
38+
h("p", [
39+
"This is the homepage of Macrostrat's geological lexicons, which are assembled from many data sources including Canada's ",
40+
h(
41+
"a",
42+
{ href: "https://weblex.canada.ca/weblexnet4/weblex_e.aspx" },
43+
"WebLex"
44+
),
45+
", the USGS's ",
46+
h("a", { href: "https://ngmdb.usgs.gov/Geolex/search" }, "Geolex"),
47+
", and other sources. The lexicon is continually updated in partnership with researchers and data providers.",
48+
]),
49+
h("div.stats-table", [
50+
h("p.stat", `${formatNumber(columns)} columns`),
51+
h("p.stat", `${formatNumber(packages)} packages`),
52+
h("p.stat", `${formatNumber(units)} units`),
53+
h("p.stat", `${formatNumber(measurements)} measurements`),
54+
]),
55+
56+
h("h2", "Dictionaries"),
3957
h(
40-
"a",
41-
{ href: "https://weblex.canada.ca/weblexnet4/weblex_e.aspx" },
42-
"WebLex"
58+
LinkCard,
59+
{ href: "/lex/strat-names", title: "Stratigraphic names" },
60+
"Names of rock units, organized hierarchically and concepts that capture relationships between differently-named rock units"
4361
),
44-
", the USGS's ",
45-
h("a", { href: "https://ngmdb.usgs.gov/Geolex/search" }, "Geolex"),
46-
", and other sources. The lexicon is continually updated in partnership with researchers and data providers.",
47-
]),
48-
h("div.stats-table", [
49-
h("p.stat", `${formatNumber(columns)} columns`),
50-
h("p.stat", `${formatNumber(packages)} packages`),
51-
h("p.stat", `${formatNumber(units)} units`),
52-
h("p.stat", `${formatNumber(measurements)} measurements`),
53-
]),
54-
55-
h("h2", "Dictionaries"),
56-
h(
57-
LinkCard,
58-
{ href: "/lex/strat-names", title: "Stratigraphic names" },
59-
"Names of rock units, organized hierarchically and concepts that capture relationships between differently-named rock units"
60-
),
6162

62-
h(
63-
LinkCard,
64-
{ href: "/lex/intervals", title: "Intervals" },
65-
"Time intervals"
66-
),
67-
h(
68-
LinkCard,
69-
{ href: "/lex/timescales", title: "Timescales" },
70-
"Continuous representations of relative geologic time"
71-
),
72-
h(
73-
LinkCard,
74-
{ href: "/lex/lithology", title: "Lithologies" },
75-
"Names of geologic materials"
76-
),
77-
h(
78-
LinkCard,
79-
{ href: "/lex/environments", title: "Environments" },
80-
"Depositional environments and formation mechanisms"
81-
),
82-
h(
83-
LinkCard,
84-
{ href: "/lex/economics", title: "Economics" },
85-
"Economic uses of geologic materials"
86-
),
63+
h(
64+
LinkCard,
65+
{ href: "/lex/intervals", title: "Intervals" },
66+
"Time intervals"
67+
),
68+
h(
69+
LinkCard,
70+
{ href: "/lex/timescales", title: "Timescales" },
71+
"Continuous representations of relative geologic time"
72+
),
73+
h(
74+
LinkCard,
75+
{ href: "/lex/lithology", title: "Lithologies" },
76+
"Names of geologic materials"
77+
),
78+
h(
79+
LinkCard,
80+
{ href: "/lex/environments", title: "Environments" },
81+
"Depositional environments and formation mechanisms"
82+
),
83+
h(
84+
LinkCard,
85+
{ href: "/lex/economics", title: "Economics" },
86+
"Economic uses of geologic materials"
87+
),
8788

88-
h("p", [
89-
h("strong", h("a", { href: "/sift" }, "Sift")),
90-
", Macrostrat's legacy lexicon app, is still available for use as it is gradually brought into this new framework.",
89+
h("p", [
90+
h("strong", h("a", { href: "/sift" }, "Sift")),
91+
", Macrostrat's legacy lexicon app, is still available for use as it is gradually brought into this new framework.",
92+
]),
9193
]),
94+
h(Footer),
9295
]);
9396
}
9497

pages/lex/economics/+Page.client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { Card, Popover } from "@blueprintjs/core";
66
import { useState } from "react";
77
import { ContentPage } from "~/layouts";
88
import { asChromaColor } from "@macrostrat/color-utils";
9-
import { Loading, SearchBar } from "../../index";
9+
import { Loading, SearchBar } from "~/components/general";
1010

1111
export function Page() {
1212
const [input, setInput] = useState("");

pages/lex/economics/@id/+Page.client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { usePageContext } from "vike-react/usePageContext";
2-
import { IndividualPage } from "../../index";
2+
import { IndividualPage } from "~/components/lex";
33

44
export function Page() {
55
const pageContext = usePageContext();

0 commit comments

Comments
 (0)