Skip to content
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions DESIGN.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

How pages on forrt.org should look and behave, for anyone changing a template, a style or the layout of a page, on any part of the site. The site uses the Doors design, which came out of community feedback on the earlier site and a design brief; this guide holds what still applies from both, together with the principles learnt from applying Doors across the site's templates.

Styles live in `assets/css/doors/`, with colours and type defined once in `tokens.css`. Shared page parts are in `layouts/partials/doors/` and `layouts/shortcodes/`.
Styles live in `assets/css/`, with colours and type defined once in `tokens.css`. Shared page parts are in `layouts/partials/` and `layouts/shortcodes/`.

## 1. Character

Expand Down Expand Up @@ -67,8 +67,8 @@ Every repeated device has to earn its place. In practice:
- No italics anywhere outside references, including menus, captions, labels and quotes. A publication's venue is part of its reference, so a journal name on a publication card is italic. Emphasis is semi-bold.
- Headings, buttons and labels are in sentence case.
- Paragraphs keep to a measure of about 640 px (`--measure` in `article.css`), so reading lines average about 75 characters, and no rendered line reaches 100. The reading column is for prose; tables, tools, programmes and directories may use the full width.
- On a wide page, prose never stands alone in the narrow column with an empty band beside it. When a full-width list follows, the list starts beside the prose or flows around it (Community, Teams). Otherwise something useful sits beside the prose, such as a contents card, an image, the article's authors with their photos, the ways to take part (Nowhere Lab), or the search of a list long enough to need one (Β§4). A date alone is not enough: on news, Educators' Corner and Pedagogies articles the card also names the authors (`doors/reading_card.html`). Nothing beside or around the prose says the same thing twice: the card names the authors so the byline beside it does not, and the section is linked by the breadcrumb and the heading of the cards at the end, not again in the card. The measure is for the length of lines, not a reason to leave half the screen empty.
- Nor does prose stand alone in the middle of the screen on the reading layout. A page with no contents, dates or contact for its side card gets the other pages of its menu group there instead (`doors/section_nav_card.html`), without those its text already links; phones have the menu for that and leave the card out. Pages outside the menu groups (Submit, Imprint, the authors index, 404), or with fewer than two unlinked peers left to list, stand alone.
- On a wide page, prose never stands alone in the narrow column with an empty band beside it. When a full-width list follows, the list starts beside the prose or flows around it (Community, Teams). Otherwise something useful sits beside the prose, such as a contents card, an image, the article's authors with their photos, the ways to take part (Nowhere Lab), or the search of a list long enough to need one (Β§4). A date alone is not enough: on news, Educators' Corner and Pedagogies articles the card also names the authors (`reading_card.html`). Nothing beside or around the prose says the same thing twice: the card names the authors so the byline beside it does not, and the section is linked by the breadcrumb and the heading of the cards at the end, not again in the card. The measure is for the length of lines, not a reason to leave half the screen empty.
- Nor does prose stand alone in the middle of the screen on the reading layout. A page with no contents, dates or contact for its side card gets the other pages of its menu group there instead (`section_nav_card.html`), without those its text already links; phones have the menu for that and leave the card out. Pages outside the menu groups (Submit, Imprint, the authors index, 404), or with fewer than two unlinked peers left to list, stand alone.
- Use the FORRT logo as supplied. Century Schoolbook is not a web font here.
- On desktop, an open header menu is a card under its button, with its first column beneath the button's label, staying inside the header row. It has at most three columns; four groups sit two by two so headings align. The overview link that heads it is semi-bold.

Expand All @@ -78,13 +78,13 @@ Before writing a new component, check these:

| Need | Use |
|---|---|
| A page with a lead image beside its title | `doors/page_hero.html`, through `hero_image` in front matter (AWoP, Citational Justice, AI in Metascience) |
| A page with a lead image beside its title | `page_hero.html`, through `hero_image` in front matter (AWoP, Citational Justice, AI in Metascience) |
| A set of actions as cards | `{{< action_cards >}}` |
| Search and a count over a long list | `{{< list_filter >}}`, with `noun` for the count ("Showing 12 of 436 effects") |
| Contents on a phone | `doors/toc_phone.html`: an open, labelled list; a list of more than six sections shows the first five, with a button for the rest |
| Names with links | `doors/name_list.html` |
| Keywords on a resource | `doors/resource_keywords.html` |
| Previous and next | `doors/pager.html`: Previous on the left, Next on the right; at the end of an article, `doors/read_next.html` shows them with related articles as the news list's cards |
| Contents on a phone | `toc_phone.html`: an open, labelled list; a list of more than six sections shows the first five, with a button for the rest |
| Names with links | `name_list.html` |
| Keywords on a resource | `resource_keywords.html` |
| Previous and next | `pager.html`: Previous on the left, Next on the right; at the end of an article, `read_next.html` shows them with related articles as the news list's cards |
| Information to keep but not lead with | a `details` disclosure with a plain label |

Images in the first screen are not lazy-loaded.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* The contributor analysis page: figures, charts and the network drawn by doors/network.js. */
/* The contributor analysis page: figures, charts and the network drawn by network.js. */
.analysis-page{padding:24px 0 56px}
.analysis-head h1{font-size:clamp(36px,4.2vw,58px);line-height:1.06;letter-spacing:-.01em;margin:14px 0 0;text-wrap:balance}
.analysis-standfirst{font:500 clamp(21px,1.9vw,25px)/1.4 var(--display);margin:18px 0 0;max-width:30em}
Expand Down
20 changes: 10 additions & 10 deletions assets/css/doors/article.css β†’ assets/css/article.css
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ main:lang(ar) .article-layout .article-style,main:lang(ar) .article-layout .arti
.article-layout-callouts .doc-section-tinted .callout{margin-inline-end:-344px}
}
@media(max-width:1000px){.article-layout .article-card{order:1}}
/* The side card listing the other pages of the page's menu group (doors/section_nav_card). Phones and tablets have
/* The side card listing the other pages of the page's menu group (section_nav_card). Phones and tablets have
the menu for that, so the card is left out there rather than following the text (DESIGN.md Β§9). */
.article-layout .section-nav ul{list-style:none;margin:0;padding:0}
.article-layout .section-nav li>*{display:block;padding:5px 0;font-size:16px;line-height:1.35}
Expand Down Expand Up @@ -513,7 +513,7 @@ main:lang(ar) .article-layout .article-style,main:lang(ar) .article-layout .arti
.article-layout .article-style .lesson-reading p:last-child,.article-layout .article-style .lesson-reading ul:last-child{margin-bottom:0}
.article-layout .post-nav-lesson{margin-top:12px;padding-top:16px;border-top:1px solid var(--line)}

/* A tool page's direct actions, under its title (doors/page_actions). */
/* A tool page's direct actions, under its title (page_actions). */
.article-layout .page-actions{display:flex;flex-wrap:wrap;gap:10px;margin:0 0 28px}
.article-layout .page-actions .btn{padding:10px 22px;font-size:17px}
/* On phones a tall cover image pushed the page's contents a screen down, so it is held to part of the screen. */
Expand Down Expand Up @@ -611,7 +611,7 @@ main:lang(ar) .article-layout .article-style,main:lang(ar) .article-layout .arti
.article-layout .article-style .list-filter-jump{display:flex;align-items:center;gap:8px;margin:10px 0 0;font:600 16px/1.3 var(--text)}
.article-layout .article-style .list-filter-jump select{flex:1;padding:8px 10px;border:1.5px solid var(--line);border-radius:var(--r-small);background:#fff;font:400 16px/1.3 var(--text);color:var(--ink)}

/* A page's opening with its picture in view (partials/doors/page_hero.html: the AWoP and citation wheels, a banner): on a
/* A page's opening with its picture in view (partials/page_hero.html: the AWoP and citation wheels, a banner): on a
desktop the title, lede and actions sit beside a large image and span the side card and text below;
on a phone the image follows the actions at a size that keeps them on the first screen. */
.article-layout .page-hero{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,400px);column-gap:48px;align-items:center}
Expand Down Expand Up @@ -771,7 +771,7 @@ html:has(.list-filter-section){scroll-padding-top:calc(var(--list-filter-bar,0px
.article-layout .article-style .list-filter-section li:has(>.entry-text)>.spoiler>summary{min-height:44px}
.article-layout .article-style .list-filter-section .is-long>.entry-text>.entry-more{min-height:1lh}
}
/* News cards with a picture (DESIGN.md Β§1): the news list (section/post.html) and the end of each article (doors/read_next). */
/* News cards with a picture (DESIGN.md Β§1): the news list (section/post.html) and the end of each article (read_next). */
.announcements-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,290px),1fr));gap:20px;margin:0;padding:0;list-style:none}
.announcements-grid>li[hidden]{display:none}
.announcement-card{position:relative;display:flex;flex-direction:column;height:100%;background:var(--surface);border-radius:var(--r-large);overflow:hidden}
Expand Down Expand Up @@ -839,16 +839,16 @@ html:has(.list-filter-section){scroll-padding-top:calc(var(--list-filter-bar,0px
}
/* On the narrowest phones six 44 px links are wider than the card. */
@media(max-width:359px){.article-layout .card-authors>li>div>.network-icon{flex-wrap:wrap;width:auto}}
/* A news post's single action: one brick with studs (doors/reading). A newsletter's takes the colour the news list
gives that issue (doors/post_panels). */
/* A news post's single action: one brick with studs (reading). A newsletter's takes the colour the news list
gives that issue (post_panels). */
.article-layout .article-style .post-brick{position:relative;display:inline-block;box-sizing:border-box;min-width:min(100%,280px);max-width:100%;min-height:76px;margin-top:10px;padding:20px 26px 26px;background:var(--brick);border-radius:3px;box-shadow:inset 0 -6px 0 rgb(0 0 0/.24);font:500 26px/1.15 var(--display);color:#fff;text-decoration:none;-webkit-print-color-adjust:exact;print-color-adjust:exact}
.article-layout .article-style .post-brick::before{content:"";position:absolute;left:14px;right:14px;top:-8px;height:8px;background:linear-gradient(90deg,transparent 6px,var(--brick) 6px 28px,transparent 28px) left top/34px 8px space no-repeat;border-radius:3px 3px 0 0;pointer-events:none}
.article-layout .article-style .post-brick::after{content:"\2192" / "";margin-inline-start:10px;font-family:var(--text);font-size:22px}
.article-layout .article-style .post-brick:hover{text-decoration:underline;text-decoration-thickness:1.5px;text-underline-offset:5px}
.article-layout .article-style .post-brick:focus-visible{outline:3px solid var(--ink);outline-offset:3px}
.ac-panel-1{--brick:var(--brick1)}.ac-panel-2{--brick:var(--brick2)}.ac-panel-3{--brick:var(--brick3)}.ac-panel-4{--brick:var(--brick4)}
.article-layout .article-style .post-action{margin:24px 0}
/* The end of an article: previous, next and related as the news list's cards, across the page (doors/read_next). */
/* The end of an article: previous, next and related as the news list's cards, across the page (read_next). */
.read-next{padding:8px 0 48px}
.read-next h2{margin:0 0 18px;font-size:30px;line-height:1.15}
.read-next .announcements-grid{grid-template-columns:repeat(auto-fill,minmax(min(100%,250px),1fr))}
Expand Down Expand Up @@ -908,7 +908,7 @@ html:has(.list-filter-section){scroll-padding-top:calc(var(--list-filter-bar,0px
:is(.article-type-educators-corner,.article-type-pedagogies) .toc-phone{background:var(--edu-bg)}
/* In the text column (below 1320 px) a call-out keeps to the text's measure. */
.article-layout:not(.article-layout-wide) .article-style .callout{max-width:calc(var(--measure) + 2.4em)}
/* The end band's heading leads to the whole section (doors/read_next). */
/* The end band's heading leads to the whole section (read_next). */
.read-next h2 a{color:var(--link);text-decoration:none}
.read-next h2 a:is(:hover,:focus-visible){text-decoration-line:underline;text-decoration-color:currentColor;text-decoration-thickness:var(--u-thick-hover);text-underline-offset:var(--u-offset)}
.read-next h2 a:hover{color:var(--link)}
Expand Down Expand Up @@ -1084,7 +1084,7 @@ html:has(.list-filter-section){scroll-padding-top:calc(var(--list-filter-bar,0px
.article-layout .article-style .summary-chapter:first-of-type .summary-chapter-head{margin-top:6px}
.summary-chapter{scroll-margin-top:16px}
.summary-chapter[hidden]{display:none}
/* Questions to start from (doors/summary_questions): each a brick, like those on the summaries overview, with
/* Questions to start from (summary_questions): each a brick, like those on the summaries overview, with
studs in the area's colour along its top and a shaded foot; white, so they stand apart from the pale filter panel
beside them. The question in display type, the answer, the citation at the foot. All the questions are in the
page in an order the script shuffles; three show on a wide screen, one on a phone. */
Expand Down Expand Up @@ -1189,7 +1189,7 @@ html:has(.list-filter-section){scroll-padding-top:calc(var(--list-filter-bar,0px
.summaries-layout .summary-entry>summary:hover .summary-title{text-decoration:underline;text-underline-offset:3px}
.article-layout.summaries-layout .article-style .summary-entry>summary h3{display:block;margin:0;font-size:22px;line-height:1.25}
.article-layout.summaries-layout .article-style .summary-entry>summary>*{grid-column:2}
/* The first takeaway under the citation, cut by length in doors/summary_entries (about two or three lines, a whole
/* The first takeaway under the citation, cut by length in summary_entries (about two or three lines, a whole
first sentence where one fits); the open entry gives the takeaways in full. */
.summary-gist{display:block;max-width:29em;text-wrap:pretty;margin-top:6px;font-size:17px;line-height:1.45;color:var(--ink)}
.summary-gist-short{display:none}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions assets/css/doors/lists.css β†’ assets/css/lists.css
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,7 @@ html:has(.tag-az){scroll-padding-top:84px}
.taxonomy-head .standfirst a{text-decoration-line:underline;text-decoration-color:var(--u-rest-color);text-decoration-thickness:var(--u-thick);text-underline-offset:var(--u-offset);text-decoration-skip-ink:auto}
.taxonomy-head .standfirst a:is(:hover,:focus-visible){text-decoration-color:currentColor;text-decoration-thickness:var(--u-thick-hover)}

/* /forrt_clusters/<term>/ (doors/topic_resources.html). The head: a chart of where the resources are now, one row per
/* /forrt_clusters/<term>/ (topic_resources.html). The head: a chart of where the resources are now, one row per
current cluster, its bar in the cluster's colour and laid in bricks; the directory's illustration beside it. */
.article-style.cluster-resources-list{max-width:none}
.topic-head{display:grid;min-width:0;grid-template-columns:minmax(0,1fr) 230px;gap:48px;align-items:end;max-width:1240px;margin:4px 0 26px}
Expand All @@ -415,7 +415,7 @@ html:has(.tag-az){scroll-padding-top:84px}
.topic-now__rows a:hover .topic-now__bar{box-shadow:inset 0 -3px 0 rgb(0 0 0/.22)}
.topic-now__count{font-size:16px;font-weight:600;font-variant-numeric:tabular-nums}
/* The bars lay their bricks once, row after row, within about 1.7 s, when the chart comes into view (the script in
doors/topic_resources.html sets is-waiting, then is-laying). Without the script, or with reduced motion, they stand
topic_resources.html sets is-waiting, then is-laying). Without the script, or with reduced motion, they stand
finished (DESIGN.md Β§11). */
.topic-now.is-waiting .topic-now__bar{clip-path:inset(0 100% 0 0)}
.topic-now.is-laying .topic-now__bar{animation:topic-bar-lay .7s steps(9,end) calc(.15s + var(--i,0) * 70ms) both}
Expand Down Expand Up @@ -445,7 +445,7 @@ html:has(.tag-az){scroll-padding-top:84px}
.topic-types .list-filter-reset{display:inline-flex;align-items:center;min-height:44px;margin-top:6px}
.topic-types .list-filter-reset[hidden]{display:none}
.article-style .topic-types__note{max-width:none;margin:0;font-size:15px;color:var(--soft)}
/* A long group shows its first eight titles until its button or a search shows the rest (doors/topic_resources.html). */
/* A long group shows its first eight titles until its button or a search shows the rest (topic_resources.html). */
.cluster-resources-list:not(.is-filtering) ul.is-collapsed>li:nth-child(n+9){display:none}
.cluster-resources-list .topic-showall{display:inline-flex;align-items:center;min-height:44px;margin:4px 16px 0;text-align:left}
/* Readings follow the typed materials, and A to Z starts again with them. */
Expand Down Expand Up @@ -494,7 +494,7 @@ html:has(.tag-az){scroll-padding-top:84px}
.article-style ol.topic-now__rows>li{break-inside:avoid}
}

/* /category/<term>/ (doors/category_term.html): the news list's head, chips and cards (above, and article.css). */
/* /category/<term>/ (category_term.html): the news list's head, chips and cards (above, and article.css). */
.category-nav .ac-chip{display:inline-flex;align-items:center;gap:7px;text-decoration:none}
.category-nav .chip-count{color:var(--soft);font-size:15px;font-weight:600}
.category-nav .ac-chip.active .chip-count{color:inherit}
Expand Down
2 changes: 1 addition & 1 deletion assets/css/doors/map.css β†’ assets/css/map.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* The community map page (layouts/community-map/single.html) and the map with its ranked cities
(layouts/partials/doors/community_map.html), which may also sit inside an article. The map belongs to Community &
(layouts/partials/community_map.html), which may also sit inside an article. The map belongs to Community &
Sustainability, so --com carries magnitude: the stat cards' crenellated tops, the bubbles' steps and the bars. */
.map-page{padding:32px 0 56px}
.map-head .crumbs{margin-bottom:18px}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* The newsletter sign-up form (layouts/partials/doors/newsletter.html). The note and status carry
/* The newsletter sign-up form (layouts/partials/newsletter.html). The note and status carry
element selectors to outweigh article.css, which loads later and resets paragraph type. */
.newsletter-form{max-width:520px}
.newsletter-row{display:flex;flex-wrap:wrap;gap:8px}
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* /about/visitors/ (layouts/shortcodes/ga_visitors.html): one switch for the period; each period has a summary row,
the map beside its ranked countries, then the most-read pages beside visitors by day. Slate (--brick3) carries
magnitude, since it belongs to no area; orange (--hot) marks the single busiest day. Loaded on this page only
(doors/assets.html). Rules sit under .article-style so they outrank the article's own text rules. */
(assets.html). Rules sit under .article-style so they outrank the article's own text rules. */
.vis{
--vis-ocean:#e8eef3;
--vis-step-0:#fffefa;--vis-step-1:#ccd6e0;--vis-step-2:#a7b6c6;--vis-step-3:#8297ad;
Expand Down
File renamed without changes.
File renamed without changes
File renamed without changes.
Loading
Loading