Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🐛 Series does not show any list #1354

Merged
merged 1 commit into from
Mar 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,13 @@ <h1 class="mt-0 text-4xl font-extrabold text-neutral-900 dark:text-neutral">

<div class="min-w-0 min-h-0 max-w-fit">

{{ partial "series.html" . }}
{{ partial "series/series.html" . }}

<div class="article-content max-w-prose mb-20">
{{ .Content | emojify }}
</div>

{{ partial "series-closed.html" . }}
{{ partial "series/series-closed.html" . }}
{{ partial "sharing-links.html" . }}
{{ partial "related.html" . }}
</div>
Expand Down
27 changes: 0 additions & 27 deletions layouts/partials/series.html

This file was deleted.

5 changes: 5 additions & 0 deletions layouts/partials/series/series-closed.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{{ if .Params.series }}
<details style="margin-left:0px" class="mt-2 mb-5 overflow-hidden rounded-lg ltr:-ml-5 ltr:pl-5 rtl:-mr-5 rtl:pr-5">
{{ partial "series/series_base.html" . }}
</details>
{{end}}
6 changes: 6 additions & 0 deletions layouts/partials/series/series.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{{ if .Params.series }}
<details style="margin-left:0px" class="mt-2 mb-5 overflow-hidden rounded-lg ltr:-ml-5 ltr:pl-5 rtl:-mr-5 rtl:pr-5" {{
if .Params.seriesOpened | default (.Site.Params.article.seriesOpened | default false) }} open {{ end }}>
{{ partial "series/series_base.html" . }}
</details>
{{end}}
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
{{ if .Params.series }}
<details style="margin-left:0px" class="mt-2 mb-5 overflow-hidden rounded-lg ltr:-ml-5 ltr:pl-5 rtl:-mr-5 rtl:pr-5">
<summary
class="py-1 text-lg font-semibold cursor-pointer bg-primary-200 text-neutral-800 ltr:-ml-5 ltr:pl-5 rtl:-mr-5 rtl:pr-5 dark:bg-primary-800 dark:text-neutral-100">
{{ index .Params.series 0 }} - {{ i18n "article.part_of_series" }}
</summary>
{{ $seriesName := strings.ToLower (index .Params.series 0) }}
{{ $seriesNameURL := strings.Replace $seriesName " " "-" }}
{{ range $post := sort (index .Site.Taxonomies.series $seriesNameURL) "Params.series_order" }}
{{ range $post := sort (index .Site.Taxonomies.series $seriesName) "Params.series_order" }}
{{ if eq $post.Permalink $.Page.Permalink }}
<div
class="py-1 border-dotted border-neutral-300 ltr:-ml-5 ltr:border-l ltr:pl-5 rtl:-mr-5 rtl:border-r rtl:pr-5 dark:border-neutral-600">
Expand All @@ -21,6 +19,4 @@
</div>
{{end}}
{{end}}

</details>
{{end}}