package templates import "dealroom/internal/model" import "fmt" type SubscriptionStats struct { RoomsUsed int RoomsLimit int UsersUsed int UsersLimit int StorageUsed string StorageLimit string } templ SubscriptionPage(profile *model.Profile, stats *SubscriptionStats) { @Layout(profile, "subscription") {

Subscription

Manage your plan and usage.

Growth Plan

Current

$799/month

Deal Rooms { fmt.Sprintf("%d / %d", stats.RoomsUsed, stats.RoomsLimit) }
Users { fmt.Sprintf("%d / %d", stats.UsersUsed, stats.UsersLimit) }
Storage { stats.StorageUsed } / { stats.StorageLimit }

Starter

$299/mo

  • 3 deal rooms
  • 5 users
  • 10GB storage
Current Plan

Growth

$799/mo

  • 15 deal rooms
  • 25 users
  • 100GB storage

Enterprise

Custom

  • Unlimited deal rooms
  • Unlimited users
  • 1TB storage
} } func usageWidth(used int, limit int) templ.Attributes { pct := 0 if limit > 0 { pct = (used * 100) / limit } return templ.Attributes{"style": fmt.Sprintf("width: %d%%", pct)} }