rubyforgood / rubyforgood/awbw
Story Share portal: Safety Exit quick-escape button
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 15
- Forks
- 26
- Avg merge
- 12h 42m
- Merged PRs (30d)
- 242
Description
Context
The Story Share portal (/story_shares) serves an audience that includes domestic-violence survivors. The live WordPress site (stories.awbw.org) has a prominent "Safety Exit" button that lets a visitor leave the site instantly.
An initial JS implementation (a safety_exit Stimulus controller doing window.open + location.replace) was built and then removed from the portal-parity PR (#2148) to keep it lean — and because a plain no-JS link gives false security (it navigates away but doesn't scrub browser history, so the back button still returns to the story).
What's needed
- A Safety Exit control that meaningfully protects the visitor:
- Navigates away to a neutral site (e.g. weather.com) immediately.
- Scrubs/replaces history so the back button doesn't return to the portal (
location.replace, and ideally overwrite prior entries). - Optionally opens a decoy tab and/or clears the current tab's content first.
- Keyboard shortcut (the WP site / common patterns use a quick key) and a fixed, always-visible button on every portal page, including mobile.
- Accessibility: clearly labeled, high-contrast, reachable without scrolling.
- Document the inherent limitation (client-side JS cannot fully erase browser history) and decide whether that's acceptable or whether to add guidance.
Notes
Prior implementation for reference is in the git history of PR #2148 (app/frontend/javascript/controllers/safety_exit_controller.js, since removed).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review the removed app/frontend/javascript/controllers/safety_exit_controller.js and the portal-parity changes in PR #2148 first. Trace how the /story_shares portal renders across pages and mobile, then define and verify an accessible, always-visible control and keyboard shortcut whose navigation and history behavior match the agreed safety requirements; document the client-side history limitation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- accessibility, frontend, security
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100