Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Docker ignore file for optimized builds
# This reduces build context size and improves build performance

# Development files
.git/
.github/
.vscode/
.nx/
node_modules/
target/
dist/

# Environment and config files
.env
.env.local
.env.*.local
*.log

# Test files
coverage/
.nyc_output/
.coverage/

# OS generated files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db

# IDE files
*.swp
*.swo
*~
.idea/
*.iml
*.ipr
*.iws

# Temporary files
*.tmp
*.temp
tmp/
temp/

# Cache directories
.cache/
.parcel-cache/
.next/
.nuxt/

# Documentation (not needed in production)
*.md
docs/
API_ANALYSIS.md
BLUR_OVERLAY_GUIDE.md
SWAGGER_IMPLEMENTATION.md

# Docker files (avoid recursion)
Dockerfile*
docker-compose*.yml
.dockerignore
29 changes: 29 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# RustForms Docker Environment Configuration
# Copy this file to .env and customize the values for your deployment

# Database Configuration
POSTGRES_USER=rustforms
POSTGRES_PASSWORD=rustforms_secure_password_change_this
POSTGRES_DB=rustforms_db
POSTGRES_PORT=5432

# API Configuration
API_PORT=3001
FORM_SECRET=your-super-secret-unguessable-token-change-this-in-production-make-it-long-and-random

# Web UI Configuration
WEB_UI_PORT=3000
NEXT_PUBLIC_API_URL=http://localhost:3001

# Email Configuration (required for form submissions)
RECIPIENT_EMAIL=admin@yourdomain.com
SMTP_HOST=smtp.yourdomain.com
SMTP_USERNAME=noreply@yourdomain.com
SMTP_PASSWORD=your-smtp-password

# Logging Level (debug, info, warn, error)
RUST_LOG=info

# Optional: If using reverse proxy
# DOMAIN=yourdomain.com
# SSL_EMAIL=admin@yourdomain.com
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,4 @@ target/
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
#.idea/
.env
69 changes: 69 additions & 0 deletions BLUR_OVERLAY_GUIDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Feature Flags - Blur Overlay Control

This document explains how to easily enable or disable the blur overlay for coming soon features and pro version content.

## Quick Start

To **remove blur** from any feature, edit `/lib/feature-flags.ts` and set the corresponding flag to `false`:

```typescript
export const FEATURE_FLAGS = {
// Pro features
BILLING: false, // Set to false to remove blur from billing page
TEAM_MEMBERS: false, // Set to false to remove blur from team page
ORGANIZATION: false, // Set to false to remove blur from organization page

// Coming soon features
ENTERPRISE_PLAN: false, // Set to false to show enterprise plan
// ... other flags
} as const
```

## Feature Flag Reference

### Pro Features
- `BILLING` - Controls billing page, payment methods, and invoices
- `TEAM_MEMBERS` - Controls team collaboration features
- `ORGANIZATION` - Controls organization settings, SSO, and audit logs

### Coming Soon Features
- `ENTERPRISE_PLAN` - Controls enterprise pricing tier
- `ADVANCED_ANALYTICS` - Controls advanced analytics features
- `SSO_INTEGRATION` - Controls SSO integration features
- `AUDIT_LOGS` - Controls audit logging features
- `CUSTOM_DOMAINS` - Controls custom domain features

## How It Works

1. **BlurOverlay Component**: Wraps content that should be hidden/blurred
2. **Feature Flags**: Control whether content is blurred or visible
3. **Sidebar Badges**: "Pro" badges are automatically hidden when features are enabled

## Files Modified

- `/lib/feature-flags.ts` - Main configuration file
- `/components/blur-overlay.tsx` - Blur overlay component
- `/src/app/dashboard/billing/page.tsx` - Billing page with blur overlays
- `/src/app/dashboard/team/page.tsx` - Team page with blur overlay
- `/src/app/dashboard/organization/page.tsx` - Organization page with blur overlay
- `/src/app/dashboard/layout.tsx` - Sidebar with conditional badges

## Example Usage

```tsx
// Using feature flag (recommended)
<BlurOverlay featureFlag="BILLING" variant="pro">
<YourContent />
</BlurOverlay>

// Manual control
<BlurOverlay isBlurred={true} variant="coming-soon" label="Coming Q2 2025">
<YourContent />
</BlurOverlay>
```

To unblur all features at once, you can run:
```bash
# This will set all flags to false (features visible)
sed -i 's/: true/: false/g' lib/feature-flags.ts
```
Loading
Loading