Skip to content

Fix production build and navigation for S3/CloudFront deployment#40

Open
adamjohnwright wants to merge 9 commits intomainfrom
add-deploy-workflows
Open

Fix production build and navigation for S3/CloudFront deployment#40
adamjohnwright wants to merge 9 commits intomainfrom
add-deploy-workflows

Conversation

@adamjohnwright
Copy link
Contributor

Junaid and I are trying to work towards automatically building and deploying the Angular website to S3. These workflows will make website folders for the desired release. We will be working on trying to get AWS to point to them after this is working.

Summary

  • Remove --base-href /{version}/website/ from the deploy workflow build step — CloudFront's origin path handles the version prefix, so the app should build with the default
  • Fix StatsService to always use the full download URL from config.json instead of the dev-only /reactome proxy path
  • Convert internal navigation links from [href] to routerLink for proper SPA navigation (no full page reloads), while keeping external service links (/AnalysisService, /ContentService) as regular href with the base URL prepended from config
  • Convert homepage news and spotlight links to routerLink as well

Test plan

  • Build succeeds: npx ng build reactome-cytoscape-style && npx ng build reactome --configuration production
  • Serve dist/reactome/browser/ with a SPA-capable server (e.g. npx serve dist/reactome/browser/ -s -l 8081)
  • Homepage loads at / — search bar, shortcut tiles, spotlight, news list, stats, and footer all render
  • Stats show real numbers (fetched from download.reactome.org)
  • News articles listed on homepage (10 items)
  • Clicking nav links navigates via Angular router (no full page reload)
  • Deep links (e.g. /about/news, /documentation/faq, /PathwayBrowser) work with SPA fallback
  • Analysis Service and Content Service nav links go to https://reactome.org/AnalysisService and https://reactome.org/ContentService
  • CloudFront custom error responses configured: 403 → /index.html (200), 404 → /index.html (200)

@junaid7haque is going to be looking to see if this is correct or not before it is pulled in.

adamjohnwright and others added 3 commits March 18, 2026 11:58
Pushes to main deploy to the next release version folder
(e.g. /96/website/) and pushes to prod deploy to the current
production version folder (e.g. /95/website/). Version is determined
dynamically from the ContentService database version endpoint.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Change type-only namespace imports to `import type` (Relationship,
  Analysis, TissueExperiment) for isolatedModules compatibility
- Change `import X = Namespace.Type` aliases to `type X = ...`
- Remove unused default import from reactome-cytoscape-style, use
  named Types export instead
- Raise anyComponentStyle budget from 8kB to 16kB
- Add reactome-cytoscape-style library build step to deploy workflow

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@autofix-troubleshooter
Copy link

Hi! I'm the autofix logoautofix.ci troubleshooter bot.

It looks like you correctly set up a CI job that uses the autofix.ci GitHub Action, but the autofix.ci GitHub App has not been installed for this repository. This means that autofix.ci unfortunately does not have the permissions to fix this pull request. If you are the repository owner, please install the app and then restart the CI workflow! 😃

adamjohnwright and others added 6 commits March 19, 2026 09:32
Add /content/detail/:id route with a full detail page that includes:
- Description tab (reusing PathwayBrowser's DescriptionTabComponent)
- Locations in the PathwayBrowser section showing hierarchical tree
  of where an entity/event exists in Reactome's pathway hierarchy
- Provider stubs for services required by the description tab
- Animations support and PDBe Molstar for structure visualization

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Move LocationsTree into the description-tab as a proper section with
  divider header and TOC entry ("Locations in the Pathway Browser")
- Add species filtering, expand/collapse all, tree connector lines,
  type icons, and arrow expand icons matching site design language
- Add pathway-browser SVG icon assets to WebsiteAngular build config
  so entity icons (protein, pathway, etc.) render correctly
- Clean up detail component to pass showLocations flag instead of
  rendering LocationsTree standalone

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Provide DatePipe in DetailComponent to fix NullInjectorError that
silently broke the authorship template rendering. Add Created as a
separate row, fix @for tracking to use $index instead of dbId to
avoid JSOG shared-reference conflicts, and unset the background
override so detail pages match the standard page background.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
All search result types now have working detail pages:
- Complex, Set, Pathway, and DNA Sequence use the existing detail page
- Interactor results navigate to a new interactor detail page with
  summary info, synonyms, and interaction partners with Reactome entities
- Icon results navigate to a new icon detail page with SVG preview,
  credits, references, and associated physical entities
- Search links are now type-aware, routing each type to its correct page

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Extract diagramFromData() from DiagramService for reuse, create
ReactionDiagramComponent that fetches reaction layout JSON and renders
it client-side via Cytoscape. Integrate as a new section in
DescriptionTabComponent for reaction-type entities.

Fixes: handle missing endShape on INPUT connectors, missing centre on
PTM attachment shapes, and bidirectional arm segment traversal for
reaction diagrams from the ReactionExporter.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Change type-only namespace imports to `import type` (Relationship,
  Analysis, TissueExperiment) for isolatedModules compatibility
- Change `import X = Namespace.Type` aliases to `type X = ...`
- Remove unused default import from reactome-cytoscape-style, use
  named Types export instead
- Raise anyComponentStyle budget from 8kB to 16kB
- Add reactome-cytoscape-style library build step to deploy workflow

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants