These are the main areas relevant to any Local instance:
- Environment Variables
- Static File Folder
- SCSS Theme
- Local Constants File
-
SITE_ENV
is the variable that determines if the instance is a Local, if it has a value oflocal
. This variable also needs to be set up inconstants/env.js
. -
LOCAL_ID
determines what Local will be loaded in the given instance, since all Locals share the same codebase. Each Local must have a descriptive and unique ID (with no spaces, for example:wisconsin
for Recollection Wisconsin). This variable also needs to be set up inconstants/env.js
.
Static files belonging to each Local need to be placed in a subfolder of the public/static/local
folder. The subfolder needs to be named with the LOCAL_ID
(for example static/wisconsin/
for Recollection Wisconsin). Files that go in this folder are:
- Local favicon file displayed in browser tabs (filename defined in the Constants file below)
- Local logo file displayed in the header and footer (filename defined in the Constants file below)
about.md
containing the text for the about pagehomepage.md
containing the text for the home pageterms.md
containing the text for the terms and conditions pagehome-hero-bg.jpg
with the hero image shown in the home pagemanifest.json
with a manifest of files
Locals use a theming system that allows basic color customization. This customization must follow WCAG contrast and color requirements. Theme files follow a similar structure as the static file folder above but in the stylesheets/themes/
folder and contain a single theme.scss
file (for example stylesheets/themes/wisconsin/theme.scss
for Recollection Wisconsin). The file itself contains the necessary color customizations for the Local.
Since all Local instances share the same codebase, there is a constants/local.js
file that contains the necessary configuration variables for an instance:
theme
: name of the SCSS file that contains the theme (should preferrably be the same as theLOCAL_ID
for consistency)name
: name of the Local, appearing throughout the sitefavicon
: filename for the Local'sfavicon
displayed in browser tabslogo
: filename Local's logo shown in header and footerdescription
: used in thedescription
metadata field, sometimes displayed by search engines in their resultsprovider
: URL-encoded value used to restrict the search interface results to items belonging only to the specifiedprovider
(for example%22Recollection%20Wisconsin%22
for Recollection Wisconsin)locationFacet
: URL-encoded value used to restrict the search interface results to items with the specifiedsourceResource.spatial.name
(for example%22Wisconsin%22
for Recollection Wisconsin)subjectFacet
: URL-encoded value used to restrict the search interface results to items with the specifiedsourceResource.subject.name
(for example%22Wisconsin%22
for Recollection Wisconsin)hasAbout
: determines whether to show (true
) or not (false
) the “About” link in the top navigationexternalLink
: URL for the top navigation link with the Local'sname