Skip to content

fix: add missing gradient fields to banner pre-upload schema#105

Merged
james-cross merged 2 commits intostagingfrom
fix/banner-gradient-validation-schema
Feb 6, 2026
Merged

fix: add missing gradient fields to banner pre-upload schema#105
james-cross merged 2 commits intostagingfrom
fix/banner-gradient-validation-schema

Conversation

@james-cross
Copy link
Contributor

Summary

  • Adds missing gradient fields to BannerPreUploadApiSchema
  • Fixes gradient background colours not persisting when editing banners

Root Cause

The pre-upload validation schema was missing GradientStartColour, GradientEndColour, and GradientDirection fields. Zod strips unknown keys by default, so these values were being removed before reaching the database.

Test Plan

  • Create or edit a banner with gradient background
  • Choose custom start and end colours
  • Save and navigate away
  • Return to edit the banner
  • Verify the gradient colours are preserved

@james-cross james-cross merged commit 8a4ca4f into staging Feb 6, 2026
1 check passed
@james-cross james-cross deleted the fix/banner-gradient-validation-schema branch February 10, 2026 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant