fix(ui): honor X-Forwarded-Prefix in redirects and embed hero-bootstrap-bridge.css #18

Merged
zaelgohary merged 1 commit from development_fix_iframe_mount_bugs into development 2026-05-04 14:04:33 +00:00
Member

Summary

Two iframe-mount bugs: (1) absolute redirects bypassed the iframe mount path because state.base_path was read once at startup from a possibly-unset env var; (2) hero-bootstrap-bridge.css referenced at root was never served.

Closes #19
Closes #20

Changes

  • Added prefix_middleware capturing X-Forwarded-Prefix into a tokio task-local
  • Added effective_base_path(state) helper preferring the per-request prefix
  • Replaced state.base_path usages in handlers with the helper
  • Embedded hero-bootstrap-bridge.css and added a dedicated route with Cache-Control: immutable

Test Results

Verified via curl through hero_router: redirects under /hero_biz/ui/c/threefold resolve correctly; CSS endpoint returns 200 with cache headers.

## Summary Two iframe-mount bugs: (1) absolute redirects bypassed the iframe mount path because `state.base_path` was read once at startup from a possibly-unset env var; (2) `hero-bootstrap-bridge.css` referenced at root was never served. ## Related Issue Closes #19 Closes #20 ## Changes - Added `prefix_middleware` capturing `X-Forwarded-Prefix` into a tokio task-local - Added `effective_base_path(state)` helper preferring the per-request prefix - Replaced `state.base_path` usages in handlers with the helper - Embedded `hero-bootstrap-bridge.css` and added a dedicated route with `Cache-Control: immutable` ## Test Results Verified via curl through hero_router: redirects under `/hero_biz/ui/c/threefold` resolve correctly; CSS endpoint returns 200 with cache headers.
fix(ui): honor X-Forwarded-Prefix in redirects and embed hero-bootstrap-bridge.css
All checks were successful
Build and Test / build (pull_request) Successful in 4m26s
94ea94dfb3
zaelgohary merged commit ec1047be1d into development 2026-05-04 14:04:33 +00:00
zaelgohary deleted branch development_fix_iframe_mount_bugs 2026-05-04 14:04:33 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lhumina_code/hero_biz!18
No description provided.