oficina / equipo Public

Clone
git clone https://amadan.net/oficina/equipo

Plain git — no account needed to clone.

Download

Download this file

1{{define "brand"}}<a rst-shell-brand href="/">{{T "rastrillo.ui.shell_home"}}</a>{{end}}
2{{define "layout"}}<!doctype html>
3<html lang="{{block "lang" .}}en{{end}}" dir="{{block "dir" .}}ltr{{end}}">
4<head>
5<meta charset="utf-8">
6<meta name="viewport" content="width=device-width, interactive-widget=resizes-content">
7<title>{{block "title" .}}{{copy "brand"}}{{end}}</title>
8<link rel="stylesheet" href="{{asset "static/tokens.css"}}">
9<link rel="stylesheet" href="{{asset "static/theme.css"}}">
10{{/* shell.css is the slide between the index and a page on a phone;
11 only the two shells that have an index link it, because the opt-in
12 it holds cannot be scoped from tokens.css. */}}
13<link rel="stylesheet" href="{{asset "static/shell.css"}}">
14<script defer src="{{asset "static/rastrillo.js"}}"></script>
15<script defer src="{{asset "static/fiesta.js"}}"></script>
16<script defer src="{{asset "static/busy.js"}}"></script>
17<script defer src="{{asset "static/live.js"}}"></script>
18{{/* blocking="render": shell.js types the slide in pagereveal, at the
19 first render, and a plain deferred script can run after it. An
20 engine that ignores the attribute gets an untyped cross-fade. */}}
21<script defer blocking="render" src="{{asset "static/shell.js"}}"></script>
22{{iconAssets}}
23<script defer src="{{asset "static/select.js"}}"></script>
24<script defer src="{{asset "static/calendar.js"}}"></script>
25<script defer src="{{asset "static/datetime.js"}}"></script>
26<script defer src="{{asset "static/zone.js"}}"></script>
27{{/* head is the app's own slot in <head>: a favicon, a meta tag, one
28 more stylesheet. Empty by default, last in the head so an app's
29 own CSS wins over the framework's, and the only block in the
30 shells that is not chrome. */}}
31{{block "head" .}}{{end}}
32</head>
33<body>
34{{/* Below 800px this shell is two views of every URL, and the page says
35 which. The index page defines the view block as index: the rail is
36 then the whole page, a list of sections at a real URL, and there is
37 no hamburger. Every other page is a content page (the default, so a
38 page that forgets is content with a way back, never a hidden page)
39 and names its way back in the up block, normally the index with the
40 page's own nav link as the fragment, /#nav-invoices, so focus comes
41 back to where the reader was even with scripts off.
42
43 Two blocks and not one: a template cannot capture a block's output
44 to branch on it, so "an empty up means index" would have to be read
45 by CSS, through :has(), and without :has() the index would render as
46 a content page with a back link to itself and no navigation.
47
48 An app with its own template called view renames it: the name is
49 generic, and this one is now the shell's. At 800px and up both views
50 are the rail beside the page. */}}
51<div rst-shell-sidebar="{{block "view" .}}page{{end}}"{{if eq .Key "work"}} equipo-team-index{{end}}>
52<a rst-skip href="#main">{{T "rastrillo.ui.shell_skip"}}</a>
53{{/* The back control: first after the skip link, so focus order is what
54 is seen; a link, not a script; its visible word inside its
55 accessible name (WCAG 2.5.3); rel="up" for tools that read it. An
56 app that wants its name on it ("‹ Ledger") edits this line, which is
57 the app's own from the moment it is scaffolded. */}}
58<div rst-shell-back><a href="{{block "up" .}}/{{end}}" rel="up" aria-label="{{template "up-label" .}}">{{block "up-label" .}}{{copy "nav.work"}}{{end}}</a></div>
59<aside rst-shell-rail>
60{{/* The index's heading is the app's name: the brand, in a span of its
61 own, then the page's title for an app whose brand renders nothing
62 (one drawn from data that has none). tokens.css shows the title
63 only when the brand's span is blank, so the heading is never empty
64 and needs no new string. Both are executed again here rather than
65 redefined (a second definition would replace the app's), so an id
66 inside the brand would appear twice. tokens.css shows the heading
67 only on the phone index, so no page ever exposes two h1s. */}}
68<h1 rst-shell-title><span>{{template "brand" .}}</span><span>{{template "title" .}}</span></h1>
69{{block "rail-brand" .}}{{template "brand" .}}{{end}}
70{{block "nav" .}}<nav rst-shell-nav></nav>{{end}}
71{{/* The rail's foot: one profile menu, an avatar that opens a card with
72 the person's name, the language switcher and the account's links.
73 At the foot of the rail on a desktop it opens upward; on the phone
74 index tokens.css lifts the same element to the top of the index,
75 beside the heading, because the foot of a long index is out of a
76 thumb's reach. One element in two places, never two copies: the
77 blocks inside are the app's markup, and a second copy would
78 duplicate every id in them.
79
80 profile is the person, as the avatar and the name: an
81 [rst-person-av] and an [rst-person-name] (and an [rst-person-email]
82 if there is one), the inside of the person partial without its
83 link, since a link cannot sit in a summary. The summary shows the
84 avatar and keeps the name for the accessible name only; the card's
85 head shows the name and the email. The default is the empty avatar
86 named Account, so an app with no profile still gets a named button.
87
88 account is the menu body here, the links, as in topbar and
89 console; it used to be a bare slot holding the whole person.
90
91 name="rst-shell-menu", NOT rst-menus: exclusivity by a details
92 element's name is document-wide, and the language menu inside the
93 card is in rst-menus, so sharing its group would close the card the
94 moment it opened.
95
96 The default avatar is marked placeholder. tokens.css hides the
97 whole foot when the card's head is its only child AND the head is
98 the placeholder: no profile, no account, no language, so a button
99 would open an empty card. A real person is never hidden. */}}
100<div rst-shell-rail-foot><details rst-dropdown rst-shell-profile name="rst-shell-menu"><summary><span rst-shell-avatar>{{block "profile" .}}<span rst-person-av="empty placeholder" aria-hidden="true"></span><span rst-person-name>{{T "rastrillo.ui.shell_account"}}</span>{{end}}</span></summary><div rst-dropdown-menu><div rst-shell-who>{{template "profile" .}}</div>{{block "locale" .}}{{end}}{{block "account" .}}{{end}}</div></details></div>
101</aside>
102<main rst-shell-main id="main">
103<div rst-page>
104{{block "region:notice" .}}<div id="notice" role="status"></div>{{end}}
105{{template "content" .}}
106</div>
107</main>
108</div>
109</body>
110</html>
111{{end}}
112