Skip to content

Commit

Permalink
add count to home + style in header + css to community group items + …
Browse files Browse the repository at this point in the history
…hide "read more" button in aside
  • Loading branch information
arthur-lemeur committed Apr 3, 2024
1 parent 90aa24f commit e5f0e74
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 5 deletions.
37 changes: 36 additions & 1 deletion assets/sass/_custom.sass
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,26 @@
grid-template-columns: repeat(2, 1fr)
overflow: auto

.excerpt:has(.communityGroup)
display: flex
flex-direction: column
align-items: center
justify-content: center

.excerpt:has(.communityGroup) .excerpt_header,
.excerpt:has(.communityGroup) .excerpt_footer .pale
display: flex
flex-direction: column
align-items: center
justify-content: center

.excerpt:has(.communityGroup) .excerpt_header h3
font-size: 200%

.communityGroup
color: #0077b8!important
text-align: center

.image_excerpt
display: bloc
width: 10em
Expand All @@ -19,6 +39,13 @@
.nav_item
text-decoration: none
color: inherit

.nav_item[title="Main EDRLab website"]
border: 1px solid white
border-radius: 5px
color: white
background-color: #002538
font-weight: bold

.post_link
text-decoration: none
Expand All @@ -29,4 +56,12 @@

.post_tag
text-transform: lowercase
font-size: 1em
font-size: 1em

.membersCounter
background-color: #0077b8
color: white
border-radius: 1.5rem
width: fit-content
padding: 5px 15px
margin: 30px auto
1 change: 1 addition & 0 deletions config/_default/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ Collaborations = "ig"
# series = "series"
Services = "services"
# geographies = "geographies"
draft = "draft"

[outputs]
home = ["HTML", "RSS", "JSON"]
2 changes: 2 additions & 0 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@
{{- end }}
{{- $image := $scratch.Get "image" }}
{{- $bg := absLangURL (path.Join "images" $image) }}
{{ $taxonomyObject := .Site.Taxonomies.draft }}
<div class="{{ if ne $p.singleColumn true }}grid-inverse {{ end }}wrap content">
<article class="post_content">
<h2 class="membersCounter">Current Members: <strong>{{ $taxonomyObject.Count "false" }}</strong></h2>
{{- $t := .Title }}
<h1 class="post_title">{{ $t | markdownify }}</h1>
{{- partial "post-meta" . }}
Expand Down
4 changes: 2 additions & 2 deletions layouts/partials/excerpt.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<li class="post_item">
<div class="excerpt">
<div class="excerpt_header">
<h3 class="post_link">
<a class="post_link" href="{{ .Permalink }}" title="{{ .Title }}">{{ .Title | markdownify }}</a>
<h3 class="post_link">
<a {{ if or (in .Params.title "group") }}class="post_link communityGroup"{{ else }}class="post_link"{{ end }} href="{{ .Permalink }}" title="{{ .Title | markdownify }}">{{ .Title | markdownify }}</a>
</h3>
{{ partial "post-meta" . }}
<br/>
Expand Down
4 changes: 2 additions & 2 deletions layouts/partials/sidebar.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@ <h2>{{ if $fullAuthor }}{{ $author.name }}{{ else }}{{ $author }}{{ end }}</h2>
<div class="author_bio">
{{ markdownify $introDescription }}
</div>
{{- if ( ne $s.introURL false ) }}
<!-- {{- if ( ne $s.introURL false ) }}
{{- $r := T "read_more" }}
<a href='{{ absLangURL (default "about/" $s.introURL) }}' class="button mt-1" role="button" title='{{ $r }}'>{{ $r }}</a>
{{- end }}
{{- end }} -->
{{- end }}

{{ if .Site.Params.sidebardisclaimer }}
Expand Down

0 comments on commit e5f0e74

Please sign in to comment.