Skip to content

feat: add invoice template system with custom branding#277

Open
Xanoutas wants to merge 1 commit intodavedumto:mainfrom
Xanoutas:feat-add-invoice-template-system
Open

feat: add invoice template system with custom branding#277
Xanoutas wants to merge 1 commit intodavedumto:mainfrom
Xanoutas:feat-add-invoice-template-system

Conversation

@Xanoutas
Copy link

@Xanoutas Xanoutas commented Mar 3, 2026

Description

Implements the invoice template system with custom branding as requested in #240.

Type of Change

  • New feature

Changes Made

Database

  • Added InvoiceTemplate model to Prisma schema with fields: name, isDefault, logoUrl, primaryColor, accentColor, showLogo, showFooter, footerText, layout

API Endpoints

  • GET /api/routes-d/invoice-templates — List all templates (max 5 per user)
  • POST /api/routes-d/invoice-templates — Create new template
  • GET /api/routes-d/invoice-templates/[id] — Get single template
  • PUT /api/routes-d/invoice-templates/[id] — Update template
  • DELETE /api/routes-d/invoice-templates/[id] — Delete template

Components

  • Added InvoiceTemplateEditor component with live preview
  • Integrated into Settings page under "Invoice Templates" section

Acceptance Criteria

  • Hex color picker for primary/accent colors
  • Live preview of invoice template
  • Set default template
  • Max 5 templates per user
  • Logo URL support
  • Custom footer text
  • Layout options (modern/classic/minimal)

Testing

  • API endpoints validated with Zod schema
  • Auth verified on all routes
  • Max 5 templates enforced at API level

Closes #240

- Add InvoiceTemplate model to Prisma schema with layout, accentColor, showLogo, showFooter fields
- Add GET/POST /api/routes-d/invoice-templates endpoint (max 5 templates per user)
- Add GET/PUT/DELETE /api/routes-d/invoice-templates/[id] endpoint
- Add InvoiceTemplateEditor component with live preview
- Integrate template editor into Settings page

Closes davedumto#240
@vercel
Copy link

vercel bot commented Mar 3, 2026

@Xanoutas is attempting to deploy a commit to the david's projects Team on Vercel.

A member of the Team first needs to authorize it.

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.

Add invoice template system with custom branding

1 participant