Skip to content

Commit

Permalink
Added section tag in top article above image for mobile (I should sto…
Browse files Browse the repository at this point in the history
…p deploying before thoroughly testing)
  • Loading branch information
SamuelmdLow committed Nov 19, 2024
1 parent 811eca5 commit e27e784
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 1 deletion.
1 change: 1 addition & 0 deletions article/templates/article/objects/top_article.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ <h2 class="o-article__headline">
</div>

<div class="o-article__right">
<a href="{{article|get_section_link}}" class="o-article__section-tag">{{article|get_section_title}}</a>
<div class="o-article__meta__image">
{% if article.featured_media.first %}
<a class="o-article__image" href="{% pageurl article %}">
Expand Down
22 changes: 21 additions & 1 deletion ubyssey/static_src/src/styles/objects/_article_top.scss
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
width: auto;

border-radius: 0.5em;
border: 2px solid $color-ubyssey-blue-dark;
border: 2px solid $color-ubyssey-blue-dark-3;
}
}

Expand Down Expand Up @@ -143,13 +143,33 @@
.o-article--top_article {
flex-direction: row-reverse;
justify-content: left;
.o-article__left .o-article__section-tag {
display: none;
}
.o-article__meta__image {
margin-top: 0;
width: 4.5em;
border: 2px solid $color-ubyssey-blue-dark-3;
img {
border-radius: 0;
border: none;
}
}
.o-article__right {
margin-left: 0;
margin-right: 1em;
}
}
}

@media ($bp-larger-than-tablet) {
.o-article--top_article {
.o-article__right .o-article__section-tag {
display: none;
}
}
}

[color-css-theme="light"] {
.o-article--top_article {
border-color: #00000045;
Expand Down

0 comments on commit e27e784

Please sign in to comment.