| 1 | {{/* A stand-in for rastrillo's ui "signin" and "signin-title" partials |
| 2 | (feat/smart-door, ui/partials/signin.html), for estilo's own tests: |
| 3 | estilo pins the old rastrillo path, which has neither, so its tests |
| 4 | render estilo-signin-screen around this instead. It keeps the real |
| 5 | partial's outer shape (the rst-signin card, its brand column, then the |
| 6 | door) and the rule that an unavailable state draws nothing, and it |
| 7 | writes back the keys it was handed, so a test can see what estilo |
| 8 | passes. The real partial is the apps' to render. |
| 9 | |
| 10 | Checked against rastrillo feat/smart-door at dbadd9a0 (2026-11-20): |
| 11 | the real partial's card is a <section rst-signin> of exactly two |
| 12 | children, the brand column then the door, which is what chrome.css's |
| 13 | structural rules rely on. This stand-in can drift from it silently, |
| 14 | and estilo must not depend on rastrillo's new module to check. The |
| 15 | contract test belongs where both modules meet: the first app to adopt |
| 16 | estilo-signin-screen (Docs, smart-door step 6) renders it over |
| 17 | rastrillo's sign-in states and asserts that |
| 18 | [estilo-signin-screen] > section has exactly two children, brand then |
| 19 | door. */}} |
| 20 | {{define "signin"}}{{$s := .State}}{{if not $s.Unavailable}}<section rst-signin aria-labelledby="rst-signin-heading"> |
| 21 | <div rst-signin-brand>{{with .Brand.Mark}}<div rst-signin-mark>{{.}}</div>{{end}}<p rst-signin-name>{{.Brand.Name}}</p></div> |
| 22 | <div rst-signin-door="one-way" data-stand-in-l="{{.L}}" data-stand-in-preview="{{.Preview}}" data-stand-in-hide-brand="{{.HideBrand}}"> |
| 23 | <h1 id="rst-signin-heading">Sign in to {{.Brand.Name}}</h1> |
| 24 | {{with $s.Federated}}<a rst-btn="primary block" href="{{.Href}}">{{.Icon}}<span>Continue with {{.Label}}</span></a> |
| 25 | {{end}}</div> |
| 26 | </section>{{end}}{{end}} |
| 27 | {{define "signin-title"}}Sign in to {{.Brand.Name}}{{end}} |
| 28 | |