feat(10-01): create BrandingService with magic byte validation and auto-compression
- Add IBrandingService interface with ImportLogoAsync, Save/Clear/GetMspLogoAsync - Add BrandingService: PNG/JPEG magic byte detection, rejects unsupported formats with descriptive error, auto-compresses files over 512 KB using WPF PresentationCore imaging - Add BrandingServiceTests: 9 tests covering validation, rejection, compression, CRUD - Deviation: used WPF BitmapEncoder/TransformedBitmap instead of System.Drawing.Bitmap (System.Drawing.Common not available without new NuGet package; WPF PresentationCore is in the existing stack per architectural decisions)
This commit is contained in:
11
SharepointToolbox/Services/IBrandingService.cs
Normal file
11
SharepointToolbox/Services/IBrandingService.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
using SharepointToolbox.Core.Models;
|
||||
|
||||
namespace SharepointToolbox.Services;
|
||||
|
||||
public interface IBrandingService
|
||||
{
|
||||
Task<LogoData> ImportLogoAsync(string filePath);
|
||||
Task SaveMspLogoAsync(LogoData logo);
|
||||
Task ClearMspLogoAsync();
|
||||
Task<LogoData?> GetMspLogoAsync();
|
||||
}
|
||||
Reference in New Issue
Block a user