Who is here on the wordmark's line; every form carries a signed-in person's name and address
Test / test (pull_request) Successful in 1m6s
Test / test (pull_request) Successful in 1m6s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GT37Z1Xtfd9pUuQtMTg6Yt
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
9b50c9cab8
commit
78f42e6f8a
+7
-3
@@ -998,10 +998,12 @@ fn Hero(
|
||||
}
|
||||
};
|
||||
|
||||
let top = view! { <div class="hero-top">{mark()}{session}</div> };
|
||||
let (bar_top, copy_top) = if has_slides { (Some(top), None) } else { (None, Some(top)) };
|
||||
|
||||
view! {
|
||||
<header class="hero" class:hero-module=has_module class:hero-slides=has_slides>
|
||||
<Announcements current_id=current_id/>
|
||||
{session}
|
||||
{has_module
|
||||
.then(|| {
|
||||
view! {
|
||||
@@ -1012,10 +1014,12 @@ fn Hero(
|
||||
// With pictures, the wordmark is a bar of its own above
|
||||
// them and the question comes under; without, the wordmark
|
||||
// heads the copy as it always has.
|
||||
{has_slides.then(|| view! { <div class="hero-bar">{mark()}</div> })}
|
||||
// Who is here sits on the wordmark's own line, not on a row
|
||||
// of its own above it.
|
||||
{bar_top.map(|top| view! { <div class="hero-bar">{top}</div> })}
|
||||
{slideshow.map(|show| view! { <SlideStrip show=show/> })}
|
||||
<div class="hero-copy">
|
||||
{(!has_slides).then(|| mark())}
|
||||
{copy_top}
|
||||
<h1>{title}</h1>
|
||||
<p inner_html=render_inline_markdown(&description)></p>
|
||||
</div>
|
||||
|
||||
@@ -1953,13 +1953,12 @@ fn form_alternative(plan: &Plan, need: &PlanNeed, w: &Value, action: &str) -> Va
|
||||
if f.multiple { r["multiple"] = json!(true); }
|
||||
let hint = s(&w["hints"][&f.name]).trim();
|
||||
if !hint.is_empty() && f.kind != "select" { r["placeholder"] = json!(hint); }
|
||||
// Someone signed in is not asked for what the site knows: on a
|
||||
// group's page they always are, and answering a record they
|
||||
// may be.
|
||||
if parent.is_some() || need.enters_as.is_some() {
|
||||
if f.kind == "email" && matches!(f.name.as_str(), "email" | "epost" | "e-post") { r["value"] = json!("{user.email}"); }
|
||||
if f.kind == "text" && matches!(f.name.as_str(), "name" | "navn") { r["value"] = json!("{user.name}"); }
|
||||
}
|
||||
// Someone signed in is not asked for what the site knows, on any
|
||||
// form: portal carries their name and address and the fields take
|
||||
// no room (`content::fill_from_user`). A visitor sees the fields
|
||||
// as usual, so a public form loses nothing by it.
|
||||
if f.kind == "email" && matches!(f.name.as_str(), "email" | "epost" | "e-post") { r["value"] = json!("{user.email}"); }
|
||||
if f.kind == "text" && matches!(f.name.as_str(), "name" | "navn") { r["value"] = json!("{user.name}"); }
|
||||
r
|
||||
}).collect();
|
||||
// The record this answer is about, carried in from the page's own
|
||||
|
||||
Reference in New Issue
Block a user