Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 28, 2025

Converts the dive planning application from Angular 18 to React 19 with Next.js 16, replacing Angular Material with MUI as requested.

Completed

Infrastructure

  • Next.js 16 with App Router and TypeScript
  • MUI v6 theme provider with Material Design
  • React Context for dive planner state management

Business Logic (Framework-Agnostic)

All core services migrated without framework dependencies:

  • Dive planning: DivePlannerService, DiveProfile, DiveSegment
  • Gas calculations: BreathingGas with standard gas mixtures
  • Decompression: BuhlmannZHL16C algorithm, Tissue compartments
  • Chart generation: ChartGeneratorService
  • Settings: DiveSettingsService

Pages

  • Home page: YouTube embed, navigation, GitHub links
  • New Dive: Placeholder structure

Components

  • MUIProvider: Theme configuration
  • StandardGasList: Gas selection with MUI List

Pattern Example

// React component with dive planner context
'use client';

import { Button } from '@mui/material';
import { useDivePlanner } from '@/lib/dive-planner-context';

export default function MyComponent({ gas, onSelect }: Props) {
  const divePlanner = useDivePlanner();
  
  return <Button onClick={() => onSelect(gas)}>Select</Button>;
}

Remaining Work

~40 Angular components need conversion following established patterns documented in CONVERSION_SUMMARY.md:

  • NewDive page components (CustomGasInput, DiveSettings, StartGasStats)
  • DiveOverview page (DivePlan, DiveSummary, CurrentStats, charts)
  • Segment pages (ChangeDepth, ChangeGas, MaintainDepth)
  • Chart components (Depth, PO2, END, Tissues - using plotly.js)

Component mapping reference:

  • mat-button<Button>
  • mat-form-field + mat-input<TextField>
  • mat-radio-group<RadioGroup> + <Radio>
  • *ngIf{condition && <Component />}
  • *ngFor{array.map(item => <Component key={item.id} />)}

Screenshots

Home Page
Home

New Dive Page Structure
New Dive

Documentation

  • CONVERSION_SUMMARY.md: Complete conversion guide with patterns
  • NEXT_STEPS.md: Quick start for continuing component conversion
  • CONVERSION_STATUS.md: Component checklist

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • fonts.gstatic.com
    • Triggering command: /usr/local/bin/node node /home/REDACTED/work/DiveIntelligence/DiveIntelligence/src/node_modules/.bin/next build (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

This section details on the original issue you should resolve

<issue_title>Convert application to use React instead of Angular</issue_title>
<issue_description>Convert the application to use the latest version of React and NextJS instead of Angular.

It should continue to use the Material design system, but use the React components from MUI.</issue_description>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI self-assigned this Dec 28, 2025
Copilot AI and others added 3 commits December 28, 2025 07:11
Co-authored-by: dylan-smith <1508559+dylan-smith@users.noreply.github.com>
Co-authored-by: dylan-smith <1508559+dylan-smith@users.noreply.github.com>
Co-authored-by: dylan-smith <1508559+dylan-smith@users.noreply.github.com>
Copilot AI changed the title [WIP] Convert application to use React instead of Angular Convert Angular app to React/Next.js with MUI Dec 28, 2025
Copilot AI requested a review from dylan-smith December 28, 2025 07:19
@github-actions
Copy link

github-actions bot commented Jan 5, 2026

Unit Test Results

0 tests   - 6   0 ✅  - 6   0s ⏱️ ±0s
0 suites  - 1   0 💤 ±0 
0 files    - 1   0 ❌ ±0 

Results for commit 1d0490b. ± Comparison against base commit 8b24ed6.

@github-actions
Copy link

github-actions bot commented Jan 5, 2026

UI Test Results

0 files   - 1  0 suites   - 9   0s ⏱️ - 3m 12s
0 tests  - 3  0 ✅  - 3  0 💤 ±0  0 ❌ ±0 
0 runs   - 9  0 ✅  - 9  0 💤 ±0  0 ❌ ±0 

Results for commit 1d0490b. ± Comparison against base commit 8b24ed6.

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.

Convert application to use React instead of Angular

2 participants