Sweep all .cshtml files for encoding corruption; add pre-commit guard

Replace all corruption variants with HTML entities across 226 view files:
- 3-char UTF-8-as-Win1252 sequences (ae-corruption)
- Standalone smart/curly quotes that break C# Razor expressions
- Partially re-corrupted variants where the 3rd byte was normalised to ASCII

tools/Fix-Encoding.ps1: re-runnable sweep; uses [char] code points so the
script itself never contains a literal non-ASCII character; supports -DryRun

.githooks/pre-commit: blocks commits containing the ae-corruption byte
signature (xc3xa2xe2x82xac); git core.hooksPath = .githooks so the
hook is repo-committed and active for all future work on this machine.

Build clean; 225 unit tests pass.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-20 21:37:10 -04:00
parent 21b39161a3
commit a0bdd2b5b4
252 changed files with 1785 additions and 1633 deletions
@@ -69,7 +69,7 @@
<a tabindex="0" class="help-icon" role="button"
data-bs-toggle="popover" data-bs-placement="top"
data-bs-title="Assigned Customers"
data-bs-content="The number of customers currently assigned to this tier. Tiers with assigned customers &lt;strong&gt;cannot be deleted&lt;/strong&gt; reassign or move customers first. You can deactivate a tier instead to prevent it appearing in the customer dropdown without losing history.">
data-bs-content="The number of customers currently assigned to this tier. Tiers with assigned customers &lt;strong&gt;cannot be deleted&lt;/strong&gt; &mdash; reassign or move customers first. You can deactivate a tier instead to prevent it appearing in the customer dropdown without losing history.">
<i class="bi bi-question-circle"></i>
</a>
</th>
@@ -93,7 +93,7 @@
<strong>@tier.TierName</strong>
</td>
<td>
<span class="text-muted small">@(tier.Description ?? "")</span>
<span class="text-muted small">@(tier.Description ?? "&mdash;")</span>
</td>
<td class="text-center">
@if (tier.DiscountPercent == 0)
@@ -161,6 +161,6 @@
<div class="alert alert-info mt-3 alert-permanent">
<i class="bi bi-info-circle me-2"></i>
<strong>How tiers work:</strong> Assign a tier to a customer on their profile. The tier's discount percentage is automatically deducted from quote totals when that customer is selected. Tiers with assigned customers cannot be deleted deactivate them instead.
<strong>How tiers work:</strong> Assign a tier to a customer on their profile. The tier's discount percentage is automatically deducted from quote totals when that customer is selected. Tiers with assigned customers cannot be deleted &mdash; deactivate them instead.
</div>
</div>