Project Case Study · Offline-Capable ya Progressive Web App
Rural Mail Digital Helper
Sakey ya libre tan nai-instol ya Progressive Web App (PWA) ya dinisenyo tan ginawa nen Tyson Berry-Wogan parad saray rural letter carrier. Ipatipon to ray nisinop ya ebat ed kontrata na USPS-NRLCA tan RRECS, library na saray napan-anapan ya excerpt na dokumento, browser-local ya naprinta iran working draft ed PS Form 8191 tan RRECS evaluation dispute Form 1, tan offline ya mapa na ruta ed USGS/OpenStreetMap.
Saray rural letter carrier ya man-tsetsek na saray probisyon na kontrata, mamaparaan parad saray tongtongan ed steward, odino man-rerebyu na saray tonda ed ruta diad silong na Rural Route Evaluated Compensation System (RRECS) et aarapen day taloran paulit-ulit ya balakid:
1. Pakaawat ed saray Abitlan Ebat ed Kontrata tan RRECS
Saray tepet nipaakar ed deadline na Step 1 grievance, bayar ed relief-day, komaduan biyahe, coverage factor, tan say Rural Route Evaluation Dispute Process (RREDP) et walad NRLCA National Agreement, Memoranda of Understanding (MOUs), tan saray manual na USPS. Kaukolan na saray carrier so maples tan malinew ya anapen a makakonekta ed partikular ya titulo na dokumento, numero na pahina, tan petsa.
2. Pangigawa na Saray Form na Grievance tan Dispute ed Pribado
Say pamparaan na Step 1 grievance working draft (PS Form 8191) odino sakey ya RRECS evaluation dispute draft (Form 1) parad sakey ya union steward et kabiang iray maseselan ya detalye na empleyado (saray ngaran, 8-digit ya Employee ID Number, numero na ruta, tan saray salaysay na agawa) ya nakaukolan ya manayam labat ed browser na carrier imbes ya ipawit ed server, tan saray andukey ya salaysay et nakaukolan na saray continuation page imbes ya silenteng napereng ed loob na melag iran kahon na PDF form.
3. Panangimapa na Saray Sardengan tan Pangipapasen Offline ed Saray Ruta ed Baryo
Saray ruta na panangideliber ed rural et mabetbet ya onlabas ed pasen a makapoy odino anggapoy mobile signal. Saray carrier a mamaparaan na Mailbox, Park point, tan Front door ya lokasyon et kaukolan day mapper na ruta a mansinop na saray tonda ed lokal ed browser, mangikonekta ed nankakaindan ya tonda, mangieksport na saray portable map file ya agla kaukolan so manggaway account, tan mangi-download na public-domain ya map tiles parad offline reference.
Antoy Gagawaen na Produkto (Nipanengneng a Kakayahan)
Iyuorganisa na Rural Mail Digital Helper so apatiran integrated workspace ed loob na sakey ya nai-instol tan offline-capable ya Progressive Web App:
1. Saved Contract & RRECS Q&A (`#ask`)
I-tsek iray nisinop ya ebat ed kimey na rural-carrier, bayar, saray ebalwasyon na RRECS, coverage factor, komaduan biyahe, saray pagalogan ed relief-day, tan timeline na Step 1 ya walay kaibang citation na subol.
Supported unanswered public questions can be queued via `/rural-mail-digital-assistant/engine/ask` without generating in engine-open, scheduling up to six read-only cache refreshes 30 seconds apart.
When the engine reports `answer_status: "needs_material"`, the page states that the question is kept on file while looking for supporting material, with no set wait time and no queue promise.
Displays turnaround estimates only from verified completed samples in `flash-turnaround.json` (verified within the last 7 days, deduplicated by `evidence_sha256`), falling back to 7-day `healthz.cache_turnaround` statistics when at least five samples exist and showing an explicit no-estimate message rather than an invented wait time when fewer than five samples exist.
Man-aanap na saray excerpt ed NRLCA National Agreement, saray MOU, saray guide na RREDP, tan postal manual unong ed tema, artikulo, odino numero na porma.
Kabiang iray pamasulon ya tema parad Article 15 grievance procedure, PS Form 8191, Rural Route Evaluation Dispute Process (RREDP), tan Article 31 kerew parad impormasyon.
Mangiiter na saray na-quote ya excerpt a kaiba iray titulo na subol ya dokumento, numero na pahina, tan petsa (saray excerpt labat, aliwan kompleton download na dokumento).
3. Browser-Local Printable Form Drafts (`#tools`)
Questionnaire na Isyu tan Working Draft: Builds a steward preparation checklist and an escaped-text worksheet that can be printed or downloaded as `.txt` without clipping long entries.
Tuan Draft na PS Form 8191 (Marso 2007 — Edisyon na EIN): Uses locally vendored `pdf-lib`, `@pdf-lib/fontkit`, and `DejaVuSans.ttf` (`ps8191.js`) to fill the authentic blank AcroForm entirely in the browser. Enforces explicit bounds (100,000 characters per entry; 400,000 across the draft), carries overflow onto labelled continuation pages on whole Unicode code-point boundaries, validates Item 1b EIN as 8 digits or blank, checks glyph coverage against embedded DejaVu (Latin, Greek, Cyrillic, accents, and typographic punctuation), and immediately detaches the PDF blob if any field changes.
Inulit ya Ginawan Draft na RRECS Evaluation Dispute Form 1 (Oktubre 2026): Fills a recreated vector PDF layout (`rrecs-form1.js`) in the browser, preserving leading zeros on plain-text phone, installation, finance-number, and ZIP fields, with independent checkboxes for Office Time, Route Time, and Street Volume Time.
4. Interactive Offline Route Mapper (`#map`)
Lazy-load ed locally vendored Leaflet 1.9.4 ya walay apatiran base layer: Dalan (OpenStreetMap), Satellite (imahe na USGS National Map a tekep so saray etiketa), Aerial (USGS imahe-labat ya orthoimagery), tan Topo (USGS National Map).
Pangikana na color-code ed pasen Baston na sulat (`#15803d`), Park point (`#7c3aed`), and Front door (`#eab308`) pins with optional user names (up to 140 UTF-16 code units, keeping leading zeros such as `007`), undo last placement, and click-to-undo mode.
Connect Mode: Links a mailbox, a park point, and a front door in order with an optional verbatim box number (up to 40 characters), computing geodesic (haversine) straight-line distance estimates and displaying a proximity advisory when a mailbox is under 5 feet (`1.523999 m`) from another stop.
Offline USGS Tile Packs tan Portable Files: Downloads USGS Satellite or Topo tile packs (up to 6,000 tiles, zoom ≤ 16) into Cache Storage (`helper-tiles-v1`) with parallel fetch, retry, cancel/sweep cleanup, and dateline (`±180°`) wrapping. Checkpoints working maps (`nrlca_route_map_working_session_v1`), saves named routes in `localStorage`, records foreground-only GPS location trails, and exports/imports strict `nrlca-map/v1` and `nrlca-map/v2` portable JSON files plus GeoJSON and print summaries.
Betang na Tyson
Tyson Berry-Wogan conceived, designed, and built Rural Mail Digital Helper (`/rural-mail-digital-helper/`) and its companion three-minute interactive walkthrough demo (`/nrlca-demo/`).
Client-Side ya PDF tan Typography Engineering: Built `ps8191.js` and `rrecs-form1.js` to render printable working drafts on the March 2007 PS Form 8191 AcroForm and the recreated October 2026 RRECS Form 1 vector layout directly in the browser, with surrogate-safe Unicode code-point wrapping, pre-build glyph validation, continuation page layout, and SHA-256 vendor provenance verification (`vendor/ps8191/PROVENANCE.json`).
Geospatial tan Portable Schema Design: Authored the `nrlca-map/v1` and `nrlca-map/v2` JSON Schema 2020-12 contracts and portable JavaScript codecs (`shared/map-portable-v1.js`, `shared/map-portable-v2.js`) shared between the web helper and native iOS/Android mapping parsers, including strict unknown-field refusal, dateline unwrapping, and non-destructive legacy route migration.
Atomic PWA Service Worker Architecture: Engineered the v6 atomic generation service worker (`rural-mail-digital-helper/sw.js`) that stages and validates the 30 `SHELL` entries—verifying MIME types, format magic signatures, and 22 pinned SHA-256 hashes—into a new immutable generation cache (`helper-shell-v6-g-<build>`) before updating the `__selected_generation__` pointer, without deleting the previously selected generation during publication so a failure at any promotion step keeps the old verified shell live and serving.
Saray Screenshot na Aplikasyon tan Visual Asset
The images below are the existing raster visual assets committed in the repository for Rural Mail Digital Helper: the walkthrough interface capture (`/posters/nrlca-demo.webp`) and the standard and maskable Progressive Web App icons (`/rural-mail-digital-helper/icons/icon-512.png` and `/rural-mail-digital-helper/icons/maskable-512.png`), which depict the three connected stop types used in the route mapper.
Walkthrough Capture — Nisinop ya Ebat ed RRECS & Saray Citation na Dokumento
Interface capture (`/posters/nrlca-demo.webp`, 720×480) showing the Ask workspace returning a cached answer on the Rural Route Evaluation Dispute Process (RREDP) with document page citations and verification notices.
Progressive Web App Icon — Saray Akakonektan Tonda ed Ruta
Standard 512×512 PNG application icon (`/rural-mail-digital-helper/icons/icon-512.png`, SHA-256 pinned in `sw.js`) illustrating three linked route stops along a mapped path.
Maskable ya Icon ed Home-Screen — Android tan PWA Safe-Zone Asset
Full-bleed 512×512 maskable icon (`/rural-mail-digital-helper/icons/maskable-512.png`, SHA-256 pinned in `sw.js`) referenced by `manifest.webmanifest` for adaptive mobile home-screen installation.
Saray Limitasyon, Setup, Privacy tan Saray Platform
Ipaakseb na Rural Mail Digital Helper so estrikton legal, teknikal, tan privacy boundaries pian natalosan na saray carrier tan steward no anto so gagawaen tan ag gagawaen na kagawaan:
Aliwan Opisyal ya Sistema na Unyon odino USPS
Say Rural Mail Digital Helper et sakey ya independienten tulong ed edukasyon tan panagplano—aliwan lapuan na katuaan—tan ag dapat ibaga ya ontan. Kanayon ya i-beripika iray kaplesan ya dokumento na kontrata tan mitongtong ed sakey ya union steward sakbay iray deadline na panag-file.
Saray Working Draft Labat (Agan-ganas ya Pinirmaan odino In-file Dya)
Say pamparaan odino pamprinta na worksheet, draft na PS Form 8191, odino draft na RRECS Evaluation Dispute Form 1 et mangiter na working draft parad panag-rebyu labat na steward; ag-iay balot pirmaan, ipila, odino ipasa dia. Saray palinew na management, karkula ed kusto a panaon, disposisyon, tan gulis na pirma et tinuyoan ya pinaulyan a bakante. Say Form 1 na RRECS nen Oktubre 2026 et binuo lamet a vector layout, aliwan opisyal ya orihinal na USPS.
Browser-Local ya Saray Porma tan Pansinopan na Ruta
Form entries run in the browser: they are not sent anywhere, not logged, and not saved by the site. Unsaved route pins stay in the current page; working map checkpoints (`nrlca_route_map_working_session_v1`), named saved routes (`nrlca_route_map_saved_routes_v1`), and downloaded offline tile packs (`helper-tiles-v1`) are stored only in that browser profile on that device (up to 500 pins, 500 connections, and a 4 MiB checkpoint JSON cap) and are not uploaded or synced. No user account is created, anyone using the same browser profile may be able to see saved local storage, and clearing browser site data removes local routes.
Saray Layer na Mapa, Tile Policy tan Dinekdek ya Arawi (Straight-Line)
Say mapa et mangusar na saray tile na OpenStreetMap tan USGS National Map—aliwan say opisyal ya mapa na USPS Digital Point Mapping (DPM)—tan saray Mailbox, Park point, tan Front door pin to et personal ya marka parad panagplano, aliwan opisyal ya simbolo na DPM odino sukat na RRECS. Saray ingisulat ya linya tan distansya na Connect et kalkula labat ya straight-line geodesic, aliwan mileage ya akatuglep ed dalan, oras na panangideliber, odino credit na RRECS. Unong ed tile usage policy na OpenStreetMap Foundation, saray OSM Street tile et ag-balot i-prefetch odino i-download ya bulto; saray offline pack et mangi-cache labat na public-domain USGS Satellite odino Topo tile (anggad zoom 16, limitado ed 6,000 tiles kada ruta).
Pangirekord Labat na Lokasyon ed Foreground
Kerewen labat so permiso ed lokasyon sano i-klik na user Usaren so kawalaan ko odino Gapoan so panag-rekord na lokasyon. Say panagrekord na dalan et mankikilos labat legan a nanenengneng so bolong (anggan 10,000 a narekord a fix/segment); say pangebat ed tab, pananguman na app, panangikandad ed screen, odino baetan na provider a masulok ed 30 segundo et mamapatunda ed panagrekord tan mangigulis na putot ed segment. Saray posisyon ed GPS na browser tan telepono et karkula labat.
Saray Platform, Offline Scope tan Android Test Build
Runs on desktop and mobile browsers (Web, iOS, Android) and installs as an offline-capable PWA. Saved routes, pins, Connect links, and local draft forms work offline once cached; asking new questions, searching the document library, and viewing undownloaded map areas require a network connection. Interactive helper features require JavaScript enabled. The Route Map section also offers a signed Android test APK (`RuralMailDigitalHelper-Android-1.0.1-native-20261016-debug.apk`, 58.4 MiB, Android 8.0+, with SHA-256 checksum), explicitly labelled as an October 16 test candidate—not a Play Store release or the newer marker-guard source—where phone compatibility, saved-map recovery, and background/locked-screen GPS still require device verification.
Onsublay ya Aksyon — Lukasan so Mananulong odino Bantayan so Walkthrough
I-lukas so Rural Mail Digital Helper a diretsa ed browser mo (odino i-instol ed home screen mo), onloob ed sakey ya partikular ya kagawaan, odino bantayan so taloran-minuto ya interactive walkthrough demo: