Page MenuHomeDevCentral

Simplify FAQ layout
ClosedPublic

Authored by dereckson on May 28 2023, 13:44.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Nov 23, 08:44
Unknown Object (File)
Oct 25 2024, 13:24
Unknown Object (File)
Oct 25 2024, 11:36
Unknown Object (File)
Oct 25 2024, 11:23
Unknown Object (File)
Oct 15 2024, 21:55
Unknown Object (File)
Oct 14 2024, 04:22
Unknown Object (File)
Oct 14 2024, 04:22
Unknown Object (File)
Oct 14 2024, 04:21
Subscribers
None

Details

Summary

The structure faq_layout describes the FAQ and table of contents layout.

This produces the same code, with two single each loop, one for the ToC,
one for the content.

Handlebars seems to require custom partial development for advanced
features like {{#each <reference>}}. As a workaround, to keep the
templates as simple as possible, entries from faq_entries are
aliased into the faq_layout data structure.

To help go back to the table of contents, add buttons to go back up.
The round CSS class can be used to create such round bouttons.

This code has received some love so we can offer it as a pattern
to create a FAQ for other static sites.

Test Plan

Ensure the layout ToC and questions is no-op

Click arrow buttons, ensure the anchor leads us on the top

Diff Detail

Repository
rJOIN Join Nasqueron
Lint
Lint Passed
Unit
No Test Coverage
Branch
main
Build Status
Buildable 4966
Build 5247: arc lint + arc unit

Event Timeline

dereckson created this revision.

Tidy up HTML and template

This revision is now accepted and ready to land.May 28 2023, 13:46
This revision was automatically updated to reflect the committed changes.