| 11-html-export-branding |
01 |
export |
| html-export |
| branding |
| csharp |
| tdd |
| dotnet |
|
| phase |
provides |
| 10-branding-data-foundation |
LogoData record with Base64 and MimeType properties |
|
|
| ReportBranding positional record bundling MspLogo and ClientLogo as nullable LogoData |
| BrandingHtmlHelper static class generating flex branding header HTML fragment |
| 8 unit tests covering all logo combination states |
|
| 11-02 (export services inject BrandingHtmlHelper.BuildBrandingHeader) |
| 11-03 (ViewModels assemble ReportBranding from IBrandingService and TenantProfile) |
|
| added |
patterns |
|
|
| Internal static helper class with single static method for HTML fragment generation |
| Positional record as simple DTO for passing logo pair to export pipeline |
| InternalsVisibleTo via MSBuild AssemblyAttribute ItemGroup (not AssemblyInfo.cs) |
|
|
| created |
modified |
| SharepointToolbox/Core/Models/ReportBranding.cs |
| SharepointToolbox/Services/Export/BrandingHtmlHelper.cs |
| SharepointToolbox.Tests/Services/Export/BrandingHtmlHelperTests.cs |
|
| SharepointToolbox/SharepointToolbox.csproj |
|
|
| BrandingHtmlHelper is internal — only used within Services.Export namespace, tests access via InternalsVisibleTo |
| InternalsVisibleTo added via MSBuild AssemblyAttribute ItemGroup rather than AssemblyInfo.cs |
| ReportBranding is a positional record — always constructed in code, never deserialized from JSON |
| Returns empty string (not null) when no branding — callers need no null checks |
| Flex spacer div only added when both logos present — single logo has no wasted space |
|
| HTML helper returns empty string for no-op case — safe to concatenate without null guard |
| data-URI inline format: src="data:{MimeType};base64,{Base64}" for self-contained HTML reports |
| alt="" on decorative logos — accessibility-correct for non-content images |
|
|
15min |
2026-04-08 |