Skip to content

Commit

Permalink
Improve styling
Browse files Browse the repository at this point in the history
  • Loading branch information
davenquinn committed Nov 26, 2024
1 parent 93c2ec6 commit 02fbdcb
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 9 deletions.
28 changes: 22 additions & 6 deletions packages/data-components/src/outcrops/base.module.sass
Original file line number Diff line number Diff line change
@@ -1,21 +1,37 @@
.location-basic-info
max-width: 650px
position: relative
img
max-width: 100%
margin: 0.3em 0 0.5em

.location-header
display: flex
flex-direction: row
gap: 1em
align-items: baseline
h2
flex-grow: 1
h2, h3
h2, h3, h4
margin: 0
h3.title
flex-grow: 1
.year
color: var(--secondary-color)
margin: 0.2em 0 1em
margin: 0.2em 0 0.8em

.location-link
color: var(--secondary-color)
transform: scale(0.8)

.image-panel
position: relative
img
border-radius: 6px
border: 1px solid var(--accent-color)
max-width: 100%

.star-rating
position: absolute
bottom: 8px
right: 5px
border-radius: 4px
color: #fff
background-color: var(--translucent-panel-background-color)
padding: 0.1em 0.3em 0.2em
6 changes: 3 additions & 3 deletions packages/data-components/src/outcrops/base.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import hyper from "@macrostrat/hyper";
import { AnchorButton, Icon } from "@blueprintjs/core";
import { Icon } from "@blueprintjs/core";
import styles from "./base.module.sass";

const h = hyper.styled(styles);
Expand Down Expand Up @@ -30,8 +30,8 @@ export function LocationBasicInfo({

return h("div.location-basic-info", { className }, [
h("div.location-header", { className: headerClassName }, [
h("h2", [title]),
h("h3.year", [year]),
h("h3.title", [title]),
h("h4.year", [year]),
h(LocationLink, { href: link }),
]),
h.if(description != null)("p.description", [description]),
Expand Down

0 comments on commit 02fbdcb

Please sign in to comment.