Skip to content

Commit 4b2f859

Browse files
committed
Add docs
1 parent dfd8d1e commit 4b2f859

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

docs/banner.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Banner
2+
3+
A banner can optionally be added at the bottom of the page with a custom message and link.
4+
5+
## Adding a new banner
6+
7+
Edit the banner text in the body of `src/content/text-detail/en/banner.tsx`.
8+
9+
Within the file's metadata:
10+
- Change the `title` metadata to a new slug for each message. This does not get displayed anywhere, but it gets recorded when a user dismisses the banner. This way, we can hide that banner for the user the next time they return, but still show them a new banner when we create a new message.
11+
- Make sure `hidden` is `true` for the banner to be visible
12+
13+
## Removing a banner
14+
15+
- Set `hidden` to `true` in `src/content/text-detail/en/banner.tsx`
16+
- Delete any translations of the banner that have been made in non-`en` locales.
17+
18+
This is to make sure that the next time a new banner is made, there is a clean slate to start from for translations.

0 commit comments

Comments
 (0)