Rework about page, finally

Start foundation / about page work

Add some job descriptions

Add Advocacy role

Make things look barely tolerable

Cloin'd

Better About intro

no fundo

Link from manifesto

swanky changes
This commit is contained in:
Ben Visness 2022-12-10 15:32:19 -06:00
parent 587ac7643f
commit 9b3a972e37
20 changed files with 474 additions and 36 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 872 KiB

View File

@ -7369,6 +7369,10 @@ article code {
flex-grow: 1;
flex-shrink: 1; } }
.c--normal {
color: black;
color: var(--fg-font-color); }
.c--inherit {
color: inherit; }
.c--inherit:hover, .c--inherit:active {

View File

@ -172,6 +172,13 @@ func BuildAbout() string {
return Url("/about", nil)
}
var RegexFoundation = regexp.MustCompile("^/foundation$")
func BuildFoundation() string {
defer CatchPanic()
return Url("/foundation", nil)
}
var RegexCommunicationGuidelines = regexp.MustCompile("^/communication-guidelines$")
func BuildCommunicationGuidelines() string {
@ -207,6 +214,24 @@ func BuildConferences() string {
return Url("/conferences", nil)
}
/*
* Volunteer/Staff Roles
*/
var RegexStaffRolesIndex = regexp.MustCompile(`^/roles$`)
func BuildStaffRolesIndex() string {
defer CatchPanic()
return Url("/roles", nil)
}
var RegexStaffRole = regexp.MustCompile(`^/roles/(?P<slug>[^/]+)$`)
func BuildStaffRole(slug string) string {
defer CatchPanic()
return Url(fmt.Sprintf("/roles/%s", slug), nil)
}
/*
* User
*/

View File

@ -197,6 +197,10 @@ article code {
}
}
.c--normal {
@include usevar('color', 'fg-font-color');
}
.c--inherit {
color: inherit;

View File

@ -1,24 +1,102 @@
{{ template "base.html" . }}
{{ define "content" }}
<div class="content-block">
<div class="description mw7 ph3 ph0-ns">
<p>We're a small group of programmers and idealists who are trying to make programming better for everyone. And we think the best way to do that is by collecting the best, down-to-earth programming projects in one place and building a community of the most talented programmers and most eager learners we can find.</p>
<h2>Abner Coimbre</h2>
<p>Abner Coimbre started Handmade Network when rallying the Handmade Hero community around a common goal. He leads the policies, initiatives, and public facing of the network. Abner became NASA's Kennedy Intern of the Year in 2015 and was named to Kennedys 2016 Top 10 Innovators. In 2017 Abner moved to Seattle, WA to work for Jonathan Blow's studio Thekla Inc.</p>
<p>Twitter: <a class="external" href="https://twitter.com/AbnerCoimbre">@AbnerCoimbre</a></p>
<h2>Jeroen van Rijn</h2>
<p>Jeroen is just this guy, you know. He's a veteran programmer who at one time found himself chin deep in webdev and decided the best thing for his sanity was to retire from it. Then Abner proposed what would become Handmade Network and he decided to dust off his keyboard and join the fray, only to find the keyboard wasn't particularly dusty yet. Some keys were getting stuck or unresponsive, sure, but a replacement keyboard soon fixed that. When not wrangling RSI, he develops the backend software that makes the website tick.</p>
<p>Apart from this he has a keen interest in low-level programming, optimisation, compiler writing and games development, among other subjects. When the site software is sufficiently mature, he plans to do an educational series on the Handmade Network, passing on some of the 30 years of collected knowledge he's gathered.</p>
<p>Twitter: <a class="external" href="https://twitter.com/J_vanRijn">@J_vanRijn</a></p>
<h2>Matt Mascarenhas</h2>
<p>Matt is a lifelong computer user, music player and book reader. In contrast to everyone else on the Handmade Network team, his education only touched on computer programming, having culminated with a degree in English language and literature. Or, rather, it would have culminated there had Casey not begun his educational programming project Handmade Hero.</p>
<p>Within the Handmade Network, Matt has become the person to ask if you want to know if / when Casey covered a particular topic on Handmade Hero at least until the annotation system receives its long-expected overhaul, at which point he'll become partially redundant and will be the first port of call should you have any issues with the Handmade Network website.</p>
<p>While not annotating or grepping the annotations for answers to people's questions, Matt practises programming in C with a view to developing a bunch of software to play, to run your console-based applications, for doing linguistic research and for staging theatrical productions writes audio and story for games, and evangelises his Arch Linux system, taking full credit for Abner's discovery of the beautiful distribution.</p>
<p>Twitter: <a class="external" href="https://twitter.com/miblo_">@miblo_</a></p>
<h2>Andrew Chronister</h2>
<p>Andrew is co-developer of Handmade Network and a student of computer engineering at the University of Washington. When he's not coding away at his project of the month, he can be found doing pointless math and cracking bad jokes on niche experimental decentralized social networks.</p>
<p>Mastodon: <a class="external" href="https://cybre.space/@chr">@chr@cybre.space</a></p>
<div class="post-content">
<div class="mw7 ph3 ph0-ns margin-center">
<h3>
We're trying to put programming back on the right track.
</h3>
<p>
Software is bad and getting worse. Despite amazing advances in hardware, today's software has made computers slower and buggier than they were decades ago. People's computers are more powerful than they know. <b>They deserve better.</b>
</p>
<p>
Inspired by Casey Muratori's <a href="https://handmadehero.org/">Handmade Hero</a>, <a href="https://twitter.com/AbnerCoimbre">Abner Coimbre</a> founded Handmade Network as a hub for fans of the show. Since then, the community has grown massively, launched many careers, and spawned amazing projects that thousands of people use every day.
</p>
<!-- <p>
The Handmade Network's activities are funded by the <a href="{{ .FoundationUrl }}">Handmade Software Foundation</a>, a (soon-to-be) 501(c)(3) nonprofit corporation.
</p> -->
<p>
We can teach programmers how things actually work. We can teach users to expect better. We can build the best software you've ever seen. <a href="{{ .RolesUrl }}"><b>Join us.</b></a>
</p>
</div>
<div class="ph3 ph0-ns mt4">
<h2>Leadership</h2>
<div class="flex flex-column flex-row-ns g3">
<div class="flex-fair pa3 bg--dim br3">
<h3>Ben Visness</h3>
<h4>Lead<!--, Foundation President--></h4>
<p>
Ben is the leader of the Handmade Network. He has been a community admin since 2018, and became the official community lead in 2022. Frustrated by what he was being taught in college, Ben joined the Handmade community in 2016 and started learning what actually matters in programming. (He did graduate, though.)
</p>
<p>
As community lead and foundation president, Ben sets the vision and direction for the Handmade community and writes a lot of web pages like this one.
</p>
<p>
On the professional side, after many years in web development, Ben now works at Mozilla as a WebAssembly engineer. He also coaches a <a href="https://fightingcalculators.org/">FIRST Robotics Competition team</a>.
</p>
<!-- <p>
Twitter: <a target="_blank" href="https://twitter.com/its_bvisness">its_bvisness</a>
</p> -->
</div>
<div class="flex-fair pa3 bg--dim br3">
<h3>Asaf Gartner</h3>
<h4>Admin<!--, Foundation Secretary--></h4>
<p>
Asaf is an experienced member of the Handmade community, having been a part of it since its inception. He was drawn to the community while growing increasingly dissatisfied with the prevalent culture in web development, and in 2018 he joined the admin team to help build the HMN website and move the network forward.
</p>
<p>
With a severe allergy to unnecessary complexity, he is constantly looking for ways to create software that doesn't frustrate the user.
</p>
</div>
<div class="flex-fair pa3 bg--dim br3">
<h3>Colin Davidson</h3>
<h4>Admin<!--, Foundation Treasurer--></h4>
<p>
Colin is a generalist systems engineer who likes to tinker with strange hardware, and works up and down the tech stack for fun. He started the ball rolling on the education side of Handmade Network, looking to ease the learning process for new Handmade adventurers. He cares deeply about spreading mechanical sympathy, helping others write code that makes the computer happy, so that users running upstack can experience the same fast-computer joy that a lucky few embedded engineers on terrible hardware enjoy every day.
</p>
<p>
Professionally, Colin has worked with embedded user and kernelspace networking, front and backend webdev, and hypervisor infrastructure. He also spends a fair amount of time plonking around on the guitar, working with the Odin team, and writing code instrospection tools to debug his hobby kernel projects.
</p>
</div>
</div>
</div>
<div class="ph3 ph0-ns mt4">
<h2>Key Contributors</h2>
<div class="flex flex-column flex-row-ns g3">
<div class="flex-fair pa3 bg--dim br3">
<h3>Martin Fouilleul</h3>
<h4>[Secret Project] Lead</h4>
<p>Martin is a PhD student at <a href="https://www.ircam.fr/">Ircam</a>, researching programming languages and models for distributed temporal interactions in music and performing arts software. He is also a former sound engineer and computer music designer.</p>
<p>Right now he is working behind the scenes on a secret Handmade Network project, to be revealed at a later date.</p>
</div>
<div class="flex-fair pa3 bg--dim br3">
<h3>???</h3>
<h4>Education Lead</h4>
<p>
<strong>This could be you!</strong> Education is one of our flagship initiatives, and we are looking for someone to lead it. If you are excited about programming education and want to help out, please <a href="{{ .EducationLeadUrl }}">learn more and get in touch!</a>
</p>
</div>
</div>
<div class="flex flex-column flex-row-ns g3 mt3">
<div class="flex-fair pa3 bg--dim br3">
<h3>???</h3>
<h4>Advocacy Lead</h4>
<p>
<strong>This could be you!</strong> We want to go out into the world and advocate for better software and better programming practices. We need a strong communicator who can lead this for us. If this excites you, please <a href="{{ .AdvocacyLeadUrl }}">learn more and get in touch!</a>
</p>
</div>
<div class="flex-fair pa3 bg--dim br3">
<h3>???</h3>
<h4>Design Lead</h4>
<p>
<strong>This could be you!</strong> Building software for people means designing software for people. We are looking for someone with visual and UX design skills to design website features, event art, livestreaming assets, educational graphics, and more. If any of this sounds interesting to you, <a href="{{ .DesignLeadUrl }}">learn more and get in touch!</a>
</p>
</div>
</div>
</div>
</div>
{{ end }}

View File

@ -3,14 +3,12 @@
{{ define "content" }}
<div class="content-block">
<div class="description mw7 ph3 ph0-ns">
<p>If you are experiencing technical issues with the site, please send a detailed email to <a href="mailto:team@handmade.network">team@handmade.network</a> with a description of the problem, and we'll do our best to address it in a timely manner.</p>
<p>For administrative issues, such as moderation disputes or content revisions, contact any of the staff by email:</p>
<ul>
<li><a href="mailto:team@handmade.network">team@handmade.network</a></li>
<li><a href="mailto:ryan@handmade.network">ryan@handmade.network</a></li>
<li><a href="mailto:ben@handmade.network">ben@handmade.network</a></li>
<li><a href="mailto:asaf@handmade.network">asaf@handmade.network</a></li>
</ul>
<p>
If you are experiencing technical issues with the site, please send a detailed email to <a href="mailto:team@handmade.network">team@handmade.network</a> with a description of the problem, and we'll do our best to address it in a timely manner.
</p>
<p>
For administrative issues, such as moderation disputes or content revisions, contact any of the staff on Discord, or by email at <a href="mailto:team@handmade.network">team@handmade.network</a>.
</p>
</div>
</div>
{{ end }}

View File

@ -0,0 +1,8 @@
{{ template "base.html" . }}
{{ define "content" }}
<div class="post-content mw7 ph3 ph0-ns margin-center">
<h1>Handmade Software Foundation</h1>
<!-- <div> -->
</div>
{{ end }}

View File

@ -7,14 +7,14 @@
<li class="{{ $footerClasses }}">
<a href="{{ .Footer.HomepageUrl }}">Main Page</a>
</li>
<li class="{{ $footerClasses }}">
<a href="{{ .Footer.ManifestoUrl }}">Manifesto</a>
</li>
<li class="{{ $footerClasses }}">
<a href="{{ .Footer.AboutUrl }}">About</a>
</li>
<li class="{{ $footerClasses }}">
<a href="{{ .Footer.ManifestoUrl }}">Handmade Manifesto</a>
</li>
<li class="{{ $footerClasses }}">
<a href="{{ .Footer.ForumsUrl }}">Forums</a>
<a href="{{ .Footer.RolesUrl }}">Roles</a>
</li>
<li class="{{ $footerClasses }}">
<a href="{{ .Footer.ProjectIndexUrl }}">Projects</a>

View File

@ -0,0 +1,8 @@
<a href="{{ .Url }}">
<div class="role pa3 bg--dim br3">
<h2>{{ .Name }}</h2>
<div class="c--normal">
{{ .Description }}
</div>
</div>
</a>

View File

@ -0,0 +1,19 @@
{{ template "base.html" . }}
{{ define "content" }}
<div class="post-content mw7 ph3 ph0-ns margin-center">
<h1>{{ .Role.Name }}</h1>
{{ block "role content" . }}{{ end }}
<div class="mt4">
<h2>Other roles</h2>
<div class="flex flex-column flex-row-ns g3">
{{ range .OtherRoles }}
<div class="flex-fair">
{{ template "role_card.html" . }}
</div>
{{ end }}
</div>
</div>
</div>
{{ end }}

View File

@ -15,7 +15,7 @@
<p>Some of us aren't satisfied with the current state of software. We think that wheels need to be reinvented. We like looking under the hood, understanding what others take for granted. We remember how software used to be, and know how much potential there is to make it better. We fight against the status quo, because we know how things <em>could</em> be.</p>
<p>This is what Handmade means. It's not a technique or a language or a management strategy. It's not a library or a framework or a paradigm. It's an idea. The idea that we can build software that works with the computer, not against it. The idea that the user matters more than the programmer. The idea that sometimes a small group can do more than an army of software engineers, and <em>do it better</em>.</p>
<p>You don't need a degree, a dissertation, or a decade of experience. You don't need an expensive computer or a certificate. All you need is an open mind and a sense of curiosity. We'll help you with the rest.</p>
<h2>Will you join us?</h2>
<a href="{{ .AboutUrl }}"><h2>Will you join us?</h2></a>
<p>Will you build your software by hand?</p>
<p class="c--dim i">Written by Ben Visness and the Handmade community. Original by Andrew Chronister.</p>
</div>

View File

@ -0,0 +1,43 @@
{{ template "role_base.html" . }}
{{ define "role content" }}
<p>
We need to tell the outside world what we're all about. We want to convince programmers and users alike that software is bad and needs to be better. We want to do more than just complain - we want to advocate for better software development practices and better software, period.
</p>
<p>
To do this, we want someone with great communication skills who can communicate our vision to the outside world. As Advocacy Lead, you can shape the public face of the Handmade Network and Handmade Software Foundation and push for real change in the world of software.
</p>
<p>
To give you an idea of what we're looking for, here are some of our advocacy ideas:
</p>
<ul>
<li>
Take popular software that people hate (e.g. Adobe Premiere or New Reddit), reverse engineer it to find what's going on, and publish the results to put pressure on those companies to do better
</li>
<li>
Take an old computer and walk it through years of software updates, cataloguing the bloat and slowdown along the way
</li>
<li>
Organize the community to report bugs or build times and make a report detailing how much our software is dragging us down
</li>
</ul>
<p>
With your help, we can show people that there is a better way to build software. <strong>If this excites you, please get in touch!</strong> See the <b>How to apply</b> section below.
</p>
<h2>Commitment</h2>
<p>
We would like to produce a few key reports per year - big pieces that can make a splash on Hacker News or other tech media. In addition, we'd like to maintain a consistent public presence through e.g. social media.
</p>
<p>
How you achieve this is up to you - this position is flexible and many details are up in the air. Overall, we would expect ongoing communication with the leadership team and commitment to publishing the major pieces described above.
</p>
<h2>How to apply</h2>
<p>
Send us an email at <a href="mailto:team@handmade.network">team@handmade.network</a> or contact @bvisness on Discord. Please share with us:
</p>
<p>
Like all Handmade Network positions, this is a volunteer role. Thank you for your interest!
</p>
{{ end }}

View File

@ -0,0 +1,46 @@
{{ template "role_base.html" . }}
{{ define "role content" }}
<p>
We are looking for someone with visual design and UX skills to set the visual direction for everything the Network and Foundation does. Whether that's making promotional art for events or making infographics for education, we need a consistent visual voice and appealing presentation.
</p>
<p>
Here are some examples of what you might do:
<ul>
<li>
Redesign our <a target="_blank" href="https://handmade.network/projects">project gallery</a> to better highlight personal work without burying our flagship projects
</li>
<li>
Design layouts, logos, key art, and <a target="_blank" href="https://nextcloud.handmade.network/s/gMJ3Eb8e7wD3CkN">assets</a> for events like the <a target="_blank" href="https://handmade.network/jam/2022">Wheel Reinvention Jam</a>
</li>
<li>
Create cover art and infographics for <a target="_blank" href="https://handmade.network/education/http">educational articles</a>
</li>
<li>
Redesign this very website, and design reusable styles and UI components
</li>
<li>
Make sure our home page engages prospective community members and gets people excited about our mission
</li>
</ul>
</p>
<p>
<strong>If any of this excites you, please get in touch!</strong> See the <b>How to apply</b> section below.
</p>
<h2>Commitment</h2>
<p>
Our design needs fluctuate over time, but we always have a long list of things to improve.
</p>
<p>
At a minimum, we would expect you to be on call for design needs and to produce mockups or assets within a week of the request. (Timing may vary depending on the scope of work requested.) However, we would be thrilled with any other design work you choose to contribute - we want our stuff to look and feel good!
</p>
<h2>How to apply</h2>
<p>
Send us an email at <a href="mailto:team@handmade.network">team@handmade.network</a> or contact @bvisness on Discord. Please share a portfolio or other examples of your work.
</p>
<p>
Like all Handmade Network positions, this is a volunteer role. Thank you for your interest!
</p>
{{ end }}

View File

@ -0,0 +1,45 @@
{{ template "role_base.html" . }}
{{ define "role content" }}
<p>
<a target="_blank" href="https://handmade.network/education">Education</a> is one of the Foundation's flagship initiatives. We want to provide serious educational material for programmers that goes deeper than anything else on the internet, and equips programmers to learn directly from real sources.
</p>
<p>
We are looking for someone to head up our educational activities. This includes:
<ul>
<li>
Seeking out experts in various domains and working with them to produce educational content
</li>
<li>
Choosing educational topics and <a target="_blank" href="{{ static "roles/network_brainstorming.png" }}">structuring our curriculum</a>
</li>
<li>
Organizing beta tests and gathering community feedback on educational content
</li>
</ul>
</p>
<p>
<strong>If this sounds interesting to you, please get in touch!</strong> See the <b>How to apply</b> section below.
</p>
<h2>Commitment</h2>
<p>
As one of our flagship initiatives, our educational content needs ongoing attention. You would be expected to spend at least a few hours a week on Handmade education and to stay in frequent communication with external contributors. You would also be expected to lead any education-related meetings and to be the point of contact for any education-related inquiries.
</p>
<p>
In general, we want new and updated educational material to be released on a regular basis, and it would be your job to make that happen!
</p>
<h2>How to apply</h2>
<p>
Send us an email at <a href="mailto:team@handmade.network">team@handmade.network</a> or contact @bvisness on Discord. Please share with us:
<ul>
<li>Any background you have in education</li>
<li>Your personal domains of expertise in programming</li>
<li>What topics you'd love to see us cover!</li>
</ul>
</p>
<p>
Like all Handmade Network positions, this is a volunteer role. Thank you for your interest!
</p>
{{ end }}

View File

@ -0,0 +1,17 @@
{{ template "base.html" . }}
{{ define "content" }}
<div class="ph3 ph0-ns">
<h1>Get involved!</h1>
<p>
Excited about our mission? We want your help with the following positions:
</p>
<div class="flex flex-column flex-row-ns g3">
{{ range .Roles }}
<div class="flex-fair">
{{ template "role_card.html" . }}
</div>
{{ end }}
</div>
</div>
{{ end }}

View File

@ -75,7 +75,7 @@ type Footer struct {
CodeOfConductUrl string
CommunicationGuidelinesUrl string
ProjectIndexUrl string
ForumsUrl string
RolesUrl string
ContactUrl string
SearchActionUrl string
}

View File

@ -84,7 +84,7 @@ func getBaseData(c *RequestContext, title string, breadcrumbs []templates.Breadc
ManifestoUrl: hmnurl.BuildManifesto(),
CommunicationGuidelinesUrl: hmnurl.BuildCommunicationGuidelines(),
ProjectIndexUrl: hmnurl.BuildProjectIndex(1),
ForumsUrl: hmnurl.HMNProjectContext.BuildForum(nil, 1),
RolesUrl: hmnurl.BuildStaffRolesIndex(),
ContactUrl: hmnurl.BuildContactPage(),
SearchActionUrl: "https://duckduckgo.com",
},

107
src/website/roles.go Normal file
View File

@ -0,0 +1,107 @@
package website
import (
"net/http"
"git.handmade.network/hmn/hmn/src/hmnurl"
"git.handmade.network/hmn/hmn/src/templates"
)
type Role struct {
Slug string
Name string
Description string
Template string
Url string // weird and redundant
RedirectSlug string
}
var roles = []Role{
{
Slug: "education",
Name: "Education Lead",
Description: "Lead our flagship education initiative and make sure we're putting out a steady stream of content.",
Template: "role_education.html",
Url: hmnurl.BuildStaffRole("education"),
},
{
Slug: "advocacy",
Name: "Advocacy Lead",
Description: "Put the Handmade ethos into the world by advocating for better software and better programming practices.",
Template: "role_advocacy.html",
Url: hmnurl.BuildStaffRole("advocacy"),
},
{
Slug: "design",
Name: "Design Lead",
Description: "Set the visual direction for everything we do. Make key art, design website features, and more.",
Template: "role_design.html",
Url: hmnurl.BuildStaffRole("design"),
},
}
const StaffRolesIndexName = "Roles"
func StaffRolesIndex(c *RequestContext) ResponseData {
type TemplateData struct {
templates.BaseData
Roles []Role
}
var res ResponseData
res.MustWriteTemplate("roles.html", TemplateData{
BaseData: getBaseDataAutocrumb(c, StaffRolesIndexName),
Roles: roles,
}, c.Perf)
return res
}
func StaffRole(c *RequestContext) ResponseData {
type TemplateData struct {
templates.BaseData
Role Role
OtherRoles []Role
}
slug := c.PathParams["slug"]
role, ok := getRole(slug)
if !ok {
return FourOhFour(c) // TODO: Volunteering-specific 404
}
if role.RedirectSlug != "" {
return c.Redirect(hmnurl.BuildStaffRole(role.RedirectSlug), http.StatusSeeOther)
}
var otherRoles []Role
for _, otherRole := range roles {
if otherRole.Slug == role.Slug {
continue
}
otherRoles = append(otherRoles, otherRole)
if len(otherRoles) >= 3 {
break
}
}
var res ResponseData
res.MustWriteTemplate(role.Template, TemplateData{
BaseData: getBaseData(c, role.Name, []templates.Breadcrumb{
{Name: StaffRolesIndexName, Url: hmnurl.BuildStaffRolesIndex()},
{Name: role.Name, Url: ""},
}),
Role: role,
OtherRoles: otherRoles,
}, c.Perf)
return res
}
func getRole(slug string) (Role, bool) {
for _, role := range roles {
if role.Slug == slug {
return role, true
}
}
return Role{}, false
}

View File

@ -48,6 +48,7 @@ func NewWebsiteRoutes(conn *pgxpool.Pool) http.Handler {
// NOTE(asaf): HMN-only routes:
hmnOnly.GET(hmnurl.RegexManifesto, Manifesto)
hmnOnly.GET(hmnurl.RegexAbout, About)
// hmnOnly.GET(hmnurl.RegexFoundation, Foundation)
hmnOnly.GET(hmnurl.RegexCommunicationGuidelines, CommunicationGuidelines)
hmnOnly.GET(hmnurl.RegexContactPage, ContactPage)
hmnOnly.GET(hmnurl.RegexMonthlyUpdatePolicy, MonthlyUpdatePolicy)
@ -59,6 +60,9 @@ func NewWebsiteRoutes(conn *pgxpool.Pool) http.Handler {
hmnOnly.GET(hmnurl.RegexJamIndex2022, JamIndex2022)
hmnOnly.GET(hmnurl.RegexJamFeed2022, JamFeed2022)
hmnOnly.GET(hmnurl.RegexStaffRolesIndex, StaffRolesIndex)
hmnOnly.GET(hmnurl.RegexStaffRole, StaffRole)
hmnOnly.GET(hmnurl.RegexOldHome, Index)
hmnOnly.POST(hmnurl.RegexLoginAction, securityTimerMiddleware(time.Millisecond*100, Login))

View File

@ -1,8 +1,15 @@
package website
import "git.handmade.network/hmn/hmn/src/templates"
import (
"git.handmade.network/hmn/hmn/src/hmnurl"
"git.handmade.network/hmn/hmn/src/templates"
)
func Manifesto(c *RequestContext) ResponseData {
type TemplateData struct {
templates.BaseData
AboutUrl string
}
baseData := getBaseDataAutocrumb(c, "Handmade Manifesto")
baseData.OpenGraphItems = append(baseData.OpenGraphItems, templates.OpenGraphItem{
Property: "og:description",
@ -10,13 +17,38 @@ func Manifesto(c *RequestContext) ResponseData {
})
var res ResponseData
res.MustWriteTemplate("manifesto.html", baseData, c.Perf)
res.MustWriteTemplate("manifesto.html", TemplateData{
BaseData: baseData,
AboutUrl: hmnurl.BuildAbout(),
}, c.Perf)
return res
}
func About(c *RequestContext) ResponseData {
type TemplateData struct {
templates.BaseData
FoundationUrl string
RolesUrl string
EducationLeadUrl string
AdvocacyLeadUrl string
DesignLeadUrl string
}
var res ResponseData
res.MustWriteTemplate("about.html", getBaseDataAutocrumb(c, "About"), c.Perf)
res.MustWriteTemplate("about.html", TemplateData{
BaseData: getBaseDataAutocrumb(c, "About"),
FoundationUrl: hmnurl.BuildFoundation(),
RolesUrl: hmnurl.BuildStaffRolesIndex(),
EducationLeadUrl: hmnurl.BuildStaffRole("education"),
AdvocacyLeadUrl: hmnurl.BuildStaffRole("advocacy"),
DesignLeadUrl: hmnurl.BuildStaffRole("design"),
}, c.Perf)
return res
}
func Foundation(c *RequestContext) ResponseData {
var res ResponseData
res.MustWriteTemplate("foundation.html", getBaseDataAutocrumb(c, "Foundation"), c.Perf)
return res
}