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
@@ -32,7 +32,7 @@
<a tabindex="0" class="help-icon" role="button"
data-bs-toggle="popover" data-bs-placement="right"
data-bs-title="Tier Name"
data-bs-content="Choose a name that communicates the customer relationship level for example &lt;em&gt;Silver&lt;/em&gt;, &lt;em&gt;Gold&lt;/em&gt;, &lt;em&gt;Preferred Shop&lt;/em&gt;, or &lt;em&gt;Wholesale&lt;/em&gt;. The name is visible to your staff when editing customers and appears in the quote pricing breakdown.">
data-bs-content="Choose a name that communicates the customer relationship level &mdash; for example &lt;em&gt;Silver&lt;/em&gt;, &lt;em&gt;Gold&lt;/em&gt;, &lt;em&gt;Preferred Shop&lt;/em&gt;, or &lt;em&gt;Wholesale&lt;/em&gt;. The name is visible to your staff when editing customers and appears in the quote pricing breakdown.">
<i class="bi bi-question-circle"></i>
</a>
<input asp-for="TierName" class="form-control" autofocus />
@@ -41,7 +41,7 @@
<div class="mb-3">
<label asp-for="Description" class="form-label fw-semibold">Description</label>
<input asp-for="Description" class="form-control" placeholder="Optional shown on customer profiles" />
<input asp-for="Description" class="form-control" placeholder="Optional &mdash; shown on customer profiles" />
<span asp-validation-for="Description" class="text-danger"></span>
</div>
@@ -50,7 +50,7 @@
<a tabindex="0" class="help-icon" role="button"
data-bs-toggle="popover" data-bs-placement="right"
data-bs-title="Discount Percentage"
data-bs-content="This percentage is automatically deducted from the subtotal of every new quote created for a customer on this tier. &lt;strong&gt;Changing this value affects all future quotes&lt;/strong&gt; for customers on the tier existing quotes are not recalculated. Enter &lt;strong&gt;0&lt;/strong&gt; for standard pricing with no discount.">
data-bs-content="This percentage is automatically deducted from the subtotal of every new quote created for a customer on this tier. &lt;strong&gt;Changing this value affects all future quotes&lt;/strong&gt; for customers on the tier &mdash; existing quotes are not recalculated. Enter &lt;strong&gt;0&lt;/strong&gt; for standard pricing with no discount.">
<i class="bi bi-question-circle"></i>
</a>
<div class="input-group" style="max-width: 200px;">
@@ -69,7 +69,7 @@
<a tabindex="0" class="help-icon" role="button"
data-bs-toggle="popover" data-bs-placement="right"
data-bs-title="Active Status"
data-bs-content="Active tiers appear in the tier dropdown when editing a customer record. Uncheck this to hide the tier from the dropdown without deleting it useful for legacy tiers that still have customers assigned but should not be used for new assignments.">
data-bs-content="Active tiers appear in the tier dropdown when editing a customer record. Uncheck this to hide the tier from the dropdown without deleting it &mdash; useful for legacy tiers that still have customers assigned but should not be used for new assignments.">
<i class="bi bi-question-circle"></i>
</a>
<div class="form-text">Inactive tiers cannot be assigned to new customers.</div>