Skip to content

Commit

Permalink
💄 (sources) minor css tweaks (#3051)
Browse files Browse the repository at this point in the history
* 💄 (sources) make data citation smaller on smaller screens

* 💄 (sources) minor style tweaks
  • Loading branch information
sophiamersmann authored Jan 3, 2024
1 parent 9bc5aa7 commit 80956e3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@ export const DataCitation = (props: {
citationLong: string
}) => {
return (
<>
<div className="data-citation">
{props.citationShort && (
<>
<p className="citation__paragraph">
<span className="citation__type">In-line citation</span>
<br />
If you have limited space (e.g. in data visualizations),
you can use this abbreviated in-line citation:
</p>
Expand All @@ -34,6 +33,6 @@ export const DataCitation = (props: {
/>
</>
)}
</>
</div>
)
}
16 changes: 10 additions & 6 deletions packages/@ourworldindata/grapher/src/modal/SourcesModal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -125,12 +125,19 @@
margin-right: $tab-gap;
}

.data-citation .wp-code-snippet {
margin-bottom: 16px;
}

.citation__paragraph {
color: $light-text;
}

.citation__type {
display: block;
line-height: 1.5;
color: $dark-text;
font-weight: 500;
}

.indicator-processing .indicator-processing__link {
Expand All @@ -147,11 +154,6 @@
&:hover {
text-decoration: none;
}

svg {
//display: inline-block;
//transform: rotate(-90deg);
}
}
}
}
Expand Down Expand Up @@ -188,7 +190,9 @@
}

.indicator-descriptions .key-info__learn-more,
.indicator-processing .indicator-processing__link {
.indicator-processing .indicator-processing__link,
.citation__paragraph,
.citation__type {
font-size: var(--text-small);
}
}
Expand Down
1 change: 1 addition & 0 deletions site/DataPageContent.scss
Original file line number Diff line number Diff line change
Expand Up @@ -498,6 +498,7 @@
}

.citation__type {
display: block;
color: $blue-90;
}

Expand Down

0 comments on commit 80956e3

Please sign in to comment.