ColorTheme.swift 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. import SwiftUI
  2. extension Color {
  3. /// Premium business accent (refined slate/navy blue, or dynamic primary)
  4. static let celestiaCyan = Color.primary
  5. /// Dynamic main background (Pure white in Light Mode, obsidian black in Dark Mode)
  6. static let spaceBlack = Color(uiColor: .systemBackground)
  7. /// Refined secondary outline/accent (monochrome slate grey)
  8. static let nebulaPurple = Color.secondary
  9. /// High-contrast primary text
  10. static let starWhite = Color.primary
  11. /// Dynamic cards background (subtle light grey in Light Mode, deep dark grey in Dark Mode)
  12. static let cardBackground = Color(uiColor: .secondarySystemBackground)
  13. /// Monospace-style subtle metadata grey
  14. static let subtleGray = Color.secondary
  15. /// The standardized line border color for wireframes (thin contrast lines)
  16. static let lineBorder = Color.primary.opacity(0.12)
  17. /// Precise red indicator for recording
  18. static let recordingRed = Color(red: 229/255, green: 57/255, blue: 53/255)
  19. }
  20. /// A no-op glow that replaces NeonGlow to avoid compile errors while removing glows.
  21. struct NeonGlow: ViewModifier {
  22. var color: Color = .clear
  23. var radius: CGFloat = 0
  24. func body(content: Content) -> some View {
  25. content
  26. }
  27. }
  28. extension View {
  29. func neonGlow(color: Color = .clear, radius: CGFloat = 0) -> some View {
  30. modifier(NeonGlow(color: color, radius: radius))
  31. }
  32. /// Applies a thin, sharp outline suitable for minimalist business interfaces.
  33. func businessBorder(cornerRadius: CGFloat = 8) -> some View {
  34. self.overlay(
  35. RoundedRectangle(cornerRadius: cornerRadius)
  36. .stroke(Color.lineBorder, lineWidth: 1)
  37. )
  38. }
  39. }