diff --git a/src/data/requestTypes.ts b/src/data/requestTypes.ts index ef015a2..cf53e47 100644 --- a/src/data/requestTypes.ts +++ b/src/data/requestTypes.ts @@ -32,7 +32,10 @@ export type RequestAction = "new" | "update"; export type RequestField = { key: string; + /** A short title for the field. */ label: string; + /** A line under the title: what it's for, or where it shows. */ + help?: string; input?: "text" | "date" | "url" | "email" | "textarea"; placeholder?: string; to?: { path: string } | { link: "website" | "email" | "action"; label: string } | { block: "card" }; @@ -56,7 +59,7 @@ const STATE: RequestField = { key: "state", label: "State or province", placehol const COUNTRY: RequestField = { key: "country", label: "Country", placeholder: "eg. US", to: { path: "country" } }; const WEBSITE: RequestField = { key: "website", label: "Website", input: "url", placeholder: "https://", to: { link: "website", label: "Website" } }; const EMAIL: RequestField = { key: "email", label: "Contact email", input: "email", to: { link: "email", label: "Email" } }; -const DESCRIPTION: RequestField = { key: "description", label: "Short description", input: "textarea", to: { block: "card" } }; +const DESCRIPTION: RequestField = { key: "description", label: "Short description", help: "A line or two shown on its card in lists and at the top of its page.", input: "textarea", to: { block: "card" } }; export const REQUEST_TYPES: RequestType[] = [ { @@ -68,8 +71,8 @@ export const REQUEST_TYPES: RequestType[] = [ entity: "blog_posts", heading: "title", fields: [ - { key: "author", label: "Author's name, as it should appear", to: { path: "guest_author" } }, - { key: "excerpt", label: "A line or two for the post's card", input: "textarea", to: { path: "excerpt" } }, + { key: "author", label: "Author", help: "Their name as it should appear on the post.", to: { path: "guest_author" } }, + { key: "excerpt", label: "Short description", help: "A line or two shown on the post's preview card, eg. in the Community blog.", input: "textarea", to: { path: "excerpt" } }, ], }, { @@ -100,11 +103,11 @@ export const REQUEST_TYPES: RequestType[] = [ heading: "name", preset: { kind: "group" }, fields: [ - { key: "region", label: "Region it's in", placeholder: "eg. Great Lakes" }, + { key: "region", label: "Region", help: "The Unity region it's part of, if you know it.", placeholder: "eg. Great Lakes" }, CITY, STATE, COUNTRY, - { key: "meets", label: "When it meets", placeholder: "eg. 2nd Sundays, 6:00pm", to: { path: "group.meets" } }, + { key: "meets", label: "Meeting time", placeholder: "eg. 2nd Sundays, 6:00pm", to: { path: "group.meets" } }, WEBSITE, EMAIL, DESCRIPTION, @@ -141,8 +144,8 @@ export const REQUEST_TYPES: RequestType[] = [ entity: "teams", heading: "name", fields: [ - { key: "organization", label: "Which organization it belongs to", placeholder: "eg. NGU national" }, - { key: "tagline", label: "What it does, in a line", to: { path: "tagline" } }, + { key: "organization", label: "Organization", help: "The organization the team belongs to.", placeholder: "eg. NGU national" }, + { key: "tagline", label: "Tagline", help: "What the team does, in a line.", to: { path: "tagline" } }, EMAIL, DESCRIPTION, ], @@ -156,9 +159,9 @@ export const REQUEST_TYPES: RequestType[] = [ entity: "awards", heading: "name", fields: [ - { key: "organization", label: "Who gives it", placeholder: "eg. NGU national" }, + { key: "organization", label: "Given by", help: "The organization that gives the award.", placeholder: "eg. NGU national" }, { key: "description", label: "What it's for", input: "textarea", to: { path: "description" } }, - { key: "recipients", label: "Who received it, and when", input: "textarea" }, + { key: "recipients", label: "Recipients", help: "Who received it, and in which year.", input: "textarea" }, ], }, { @@ -171,7 +174,7 @@ export const REQUEST_TYPES: RequestType[] = [ heading: "display_name", fields: [ { key: "pronouns", label: "Pronouns", placeholder: "eg. she/her", to: { path: "pronouns" } }, - { key: "tagline", label: "Role or title", to: { path: "tagline" } }, + { key: "tagline", label: "Role or title", help: "Shown under their name, eg. Retreat Team Lead.", to: { path: "tagline" } }, CITY, STATE, { key: "email", label: "Public email", input: "email", to: { path: "public_email" } }, diff --git a/src/pages/sections/RequestForm.tsx b/src/pages/sections/RequestForm.tsx index fad21d2..e42bc0c 100644 --- a/src/pages/sections/RequestForm.tsx +++ b/src/pages/sections/RequestForm.tsx @@ -235,8 +235,10 @@ export default function RequestForm() {
+ {f.help} +
+ )} {f.input === "textarea" ? (- A Word document (.docx) with the details or the post itself, photos (JPEG or PNG) or a PDF. Up to{" "} - {MAX_FILES}, {MAX_FILE_MB} MB each. + Why a file: a blog post sent as a Word document (.docx) can be imported straight onto the site, its + headings, lists, tables and links as written, so nothing needs retyping. For anything else, a document + with the details, photos (JPEG or PNG) or a PDF saves us asking. Up to {MAX_FILES} files,{" "} + {MAX_FILE_MB} MB each.