Replace Books island iframe with native Dioxus WASM view router #37

Closed
mik-tf wants to merge 0 commits from development_books_wasm_views into development
Owner

Replace the <iframe src="http://localhost:8883"> in the Books island with a native Dioxus view router using the already-complete views in views/mod.rs.

Changes

  • Cargo.toml: add [package.metadata.island] so build_standalone.sh discovers this island
  • island.rs: full rewrite — view router matching all 9 views (Home, BookList, Library, BookDetail, Page, Search, Import, Convert, Settings); base_url from context.api_host; view-change event dispatch
  • lib.rs: remove host/port thread_locals; pass only context to BooksApp

Testing

  • WASM build via wasm-pack build --target web --features standalone
  • Deployed in hero_services reliable19; Books island shows native UI in browser

Closes #36

Replace the `<iframe src="http://localhost:8883">` in the Books island with a native Dioxus view router using the already-complete views in `views/mod.rs`. ## Changes - `Cargo.toml`: add `[package.metadata.island]` so `build_standalone.sh` discovers this island - `island.rs`: full rewrite — view router matching all 9 views (Home, BookList, Library, BookDetail, Page, Search, Import, Convert, Settings); `base_url` from `context.api_host`; view-change event dispatch - `lib.rs`: remove `host`/`port` thread_locals; pass only `context` to `BooksApp` ## Testing - WASM build via `wasm-pack build --target web --features standalone` - Deployed in hero_services reliable19; Books island shows native UI in browser Closes #36
feat: replace Books island iframe with native Dioxus view router
Some checks failed
Build and Test / build (pull_request) Has been cancelled
8d993a400b
- Add [package.metadata.island] to Cargo.toml so build_standalone.sh
  discovers and builds this island as a standalone WASM package
- Rewrite island.rs: remove iframe + postMessage theme sync; render
  all 9 views (Home, BookList, Library, BookDetail, Page, Search,
  Import, Convert, Settings) as native Dioxus components
- base_url derived from context.api_host ("/hero_books" relative path
  works behind hero_proxy; absolute URL works for direct access)
- View changes dispatched via hero:view-change custom event
- lib.rs: remove host/port thread_locals, pass only context to BooksApp
- Add ViewList with 5 nav views + 4 hidden detail views to metadata()
fix: update books island lib.rs to use new register_custom_element API
Some checks failed
Build and Test / build (pull_request) Failing after 7s
f1957e9258
Rewrite lib.rs to match the current register_custom_element signature:
5-argument form (tag, observed_attrs, on_connected, on_disconnected,
on_attribute_changed). Follows the sprints island pattern.

Removes the old 3-argument register() approach that was incompatible
with the current hero_archipelagos_core API.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
feat: add top nav bar to Books island and disable wasm-opt
Some checks failed
Build and Test / build (pull_request) Failing after 6s
b6f84eeca7
- Add 5-tab navigation bar (Home, All Books, Import, Convert, Settings)
  with active tab highlighting using purple accent color
- Layout changed to flex-column to accommodate nav + view content
- Add wasm-opt = false to Cargo.toml to avoid bulk memory wasm-opt failure
  with older toolchain versions
mik-tf changed title from WIP: Replace Books island iframe with native Dioxus WASM view router to Replace Books island iframe with native Dioxus WASM view router 2026-03-03 04:11:31 +00:00
chore: set edition 2024 and rust-version 1.92 per ecosystem standard
Some checks failed
Build and Test / build (pull_request) Has been cancelled
054e925646
Aligns with hero_ecosystem skill requirement: all repos must use
edition = "2024" and rust-version = "1.92".

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
mik-tf closed this pull request 2026-03-03 18:54:15 +00:00
Some checks failed
Build and Test / build (pull_request) Has been cancelled

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
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_archipelagos!37
No description provided.