Repository navigation
Articles: a newsletter issue as its own brick; Educators' Corner portraits, wide figures and a plain editor's note #1243
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
Open
LukasWallrich
wants to merge
6
commits into
rebrand-doors
Choose a base branch
from
hc/articles2
base: rebrand-doors
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
8a7d783
Articles: a newsletter issue as its own brick, Educators' Corner port…
LukasWallrich 658c1f2
Articles: authors found by their profile's name, role and bio in the …
LukasWallrich 1a26b56
Rebrand checks: allow the 17 descriptions that lose the stray space b…
LukasWallrich 70a4e1b
Rebrand checks: a description that only lost a space inside a bracket…
LukasWallrich 3de62b2
compare_builds: a description cut a word later counts as unchanged on…
LukasWallrich ce36865
Merge rebrand-doors into hc/articles2
LukasWallrich File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,2 +1,6 @@ | ||
| {{- /* A Hugo Markdown render hook to parse links, opening external links in new tabs. Trimmed so no whitespace is emitted before the link. */ -}} | ||
| <a href="{{ .Destination | safeURL }}"{{ with .Title}} title="{{ . }}"{{ end }}{{ if or (strings.HasPrefix .Destination "http://") (strings.HasPrefix .Destination "https://") (strings.HasPrefix .Destination "//") }} target="_blank" rel="noopener"{{ end }}>{{ .Text | safeHTML }}</a> | ||
| {{- /* Markdown links, opening other sites in new tabs; a link to forrt.org itself (site.Params.doors.host, with or | ||
| without www.) stays in the tab, as in booklet_contents. Overrides the theme's hook, whose comment line left a | ||
| line break before every link: rendered as a space, it split "(" from a link that follows it. */ -}} | ||
| {{- $host := strings.TrimPrefix "www." (urls.Parse .Destination).Host -}} | ||
| {{- $away := and $host (ne $host site.Params.doors.host) -}} | ||
| <a href="{{ .Destination | safeURL }}"{{ with .Title}} title="{{ . }}"{{ end }}{{ if $away }} target="_blank" rel="noopener"{{ end }}>{{ .Text | safeHTML }}</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,16 @@ | ||
| {{/* The profile page (/authors/<slug>/) for a name as written in a page's `authors`, or false. The slug is usually the | ||
| name made into a URL; a title such as "Dr." in front, or a profile whose folder differs from the credited name | ||
| ("Patrick Forscher" at patrick-s-forscher), is found by the profile's own name. Call it with partialCached and | ||
| the name as the key. */}} | ||
| {{ $raw := . }} | ||
| {{ $found := site.GetPage (printf "/authors/%s" (urlize $raw)) }} | ||
| {{ if not $found }} | ||
| {{ $plain := replaceRE `(?i)^(dr|prof|professor)\.?\s+` "" (trim $raw " ") }} | ||
| {{ $found = site.GetPage (printf "/authors/%s" (urlize $plain)) }} | ||
| {{ if not $found }} | ||
| {{ with site.GetPage "/authors" }}{{ range .Sections }} | ||
| {{ if and (not $found) (eq (lower (.Params.name | default .Title)) (lower $plain)) }}{{ $found = . }}{{ end }} | ||
| {{ end }}{{ end }} | ||
| {{ end }} | ||
| {{ end }} | ||
| {{ return $found }} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,62 @@ | ||
| {{/* A newsletter post (doors/reading): the issue as one large brick in its year's colour, as on the archive | ||
| (/newsletters/, one brick colour to a year, DESIGN.md §4), holding the title, what is in the issue, the link to | ||
| read it and when it was sent. Beside it, or below it on a phone, the issues around it by year and month, oldest | ||
| first, outlined in their years' colours, with this one solid and unlinked. FORRT sends every issue, so the | ||
| page names no author. Input: dict "page" and "body", the post's text with its link made a brick (doors/reading). */}} | ||
| {{ $p := .page }} | ||
| {{ $tone := add (mod $p.Date.Year 4) 1 }} | ||
| {{/* "FORRT Newsletter — January 2026": the name above, the month large. */}} | ||
| {{ $parts := split $p.Title " — " }} | ||
| {{ $name := "" }}{{ $issue := $p.Title }} | ||
| {{ if eq (len $parts) 2 }}{{ $name = index $parts 0 }}{{ $issue = index $parts 1 }}{{ end }} | ||
| {{ $issues := slice }} | ||
| {{ range (where site.RegularPages "Section" "post").ByDate }} | ||
| {{ if in (.Params.categories | default slice) "Newsletter" }}{{ $issues = $issues | append . }}{{ end }} | ||
| {{ end }} | ||
| {{ $here := 0 }} | ||
| {{ range $i, $q := $issues }}{{ if eq $q.RelPermalink $p.RelPermalink }}{{ $here = $i }}{{ end }}{{ end }} | ||
| {{/* Up to eight issues: three before this one where there are, the rest after. */}} | ||
| {{ $count := len $issues }} | ||
| {{ $start := cond (gt $here 3) (sub $here 3) 0 }} | ||
| {{ if gt (add $start 8) $count }}{{ $start = cond (gt $count 8) (sub $count 8) 0 }}{{ end }} | ||
| {{ $shown := first 8 (after $start $issues) }} | ||
| {{ $years := slice }} | ||
| {{ range $shown }}{{ $years = $years | append .Date.Year }}{{ end }} | ||
| <div class="wrap"> | ||
| <article class="nl-post"> | ||
| <nav class="crumbs" aria-label="Breadcrumb"> | ||
| <a href="{{ "" | relLangURL }}">Home</a> | ||
| {{ with $p.Parent }}<span aria-hidden="true">/</span> <a href="{{ .RelPermalink }}">{{ index (partialCached "doors/menu_labels" . "menu-labels") (strings.Trim .Path "/") | default .LinkTitle }}</a>{{ end }} | ||
| <span aria-hidden="true">/</span> <span aria-current="page">{{ $p.LinkTitle }}</span> | ||
| </nav> | ||
| <div class="nl-post-grid"> | ||
| <section class="nl-issue nla-brick-{{ $tone }}" aria-labelledby="nl-issue-title"> | ||
| <h1 id="nl-issue-title">{{ with $name }}<span class="nl-issue-name">{{ . }}</span> {{ end }}<span class="nl-issue-month">{{ $issue }}</span></h1> | ||
| <div class="nl-issue-body">{{ .body }}</div> | ||
| <div class="nl-issue-foot"> | ||
| <p class="nl-issue-sent">Sent <time datetime="{{ $p.Date.Format "2006-01-02" }}">{{ $p.Date.Format "2 January 2006" }}</time></p> | ||
| <p class="share-link"><button class="copy-link" type="button" data-copy-link="{{ $p.Permalink }}">Copy link</button> <span role="status"></span></p> | ||
| </div> | ||
| </section> | ||
| <nav class="nl-around" aria-labelledby="nl-around-title"> | ||
| <h2 id="nl-around-title">Newsletter issues</h2> | ||
| {{ range $year := uniq $years }} | ||
| <div class="nl-year nla-brick-{{ add (mod $year 4) 1 }}"> | ||
| <h3>{{ $year }}</h3> | ||
| <ol> | ||
| {{ range $i, $q := $shown }}{{ if eq $q.Date.Year $year }} | ||
| {{ $at := add $start $i }} | ||
| {{ if eq $at $here }} | ||
| <li class="nl-here" aria-current="page"><small>This issue</small>{{ $q.Date.Format "January" }}<span class="sr-only"> {{ $year }}</span></li> | ||
| {{ else }} | ||
| <li><a href="{{ $q.RelPermalink }}"{{ if eq $at (sub $here 1) }} rel="prev"{{ else if eq $at (add $here 1) }} rel="next"{{ end }}>{{ $q.Date.Format "January" }}<span class="sr-only"> {{ $year }}</span></a></li> | ||
| {{ end }} | ||
| {{ end }}{{ end }} | ||
| </ol> | ||
| </div> | ||
| {{ end }} | ||
| {{ with site.GetPage "/newsletters" }}<p class="nl-all"><a href="{{ .RelPermalink }}">All newsletters and sign-up</a></p>{{ end }} | ||
| </nav> | ||
| </div> | ||
| </article> | ||
| </div> |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.