# Fix Icon() syntax - Icon takes positional parameter, not named 'icon:'

$files = @(
    "lib\screens\profile\profile_screen.dart",
    "lib\screens\compose\compose_screen.dart",
    "lib\screens\post\post_detail_screen.dart"
)

foreach ($file in $files) {
    if (Test-Path $file) {
        $content = Get-Content $file -Raw
        
        # Fix Icon(icon: Icons.something) to Icon(Icons.something)
        $content = $content -replace 'Icon\(icon:\s*', 'Icon('
        
        # Save the file
        $content | Set-Content $file -NoNewline
        Write-Host "Fixed: $file"
    }
}

Write-Host "`nDone! Icon syntax fixed."
