ColorTheme.swift 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  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. /// Less and Cosmos brand gold (#E6C687)
  20. static let lessCosmosGold = Color(red: 230/255, green: 198/255, blue: 135/255)
  21. }
  22. /// A no-op glow that replaces NeonGlow to avoid compile errors while removing glows.
  23. struct NeonGlow: ViewModifier {
  24. var color: Color = .clear
  25. var radius: CGFloat = 0
  26. func body(content: Content) -> some View {
  27. content
  28. }
  29. }
  30. extension View {
  31. func neonGlow(color: Color = .clear, radius: CGFloat = 0) -> some View {
  32. modifier(NeonGlow(color: color, radius: radius))
  33. }
  34. /// Applies a thin, sharp outline suitable for minimalist business interfaces.
  35. func businessBorder(cornerRadius: CGFloat = 8) -> some View {
  36. self.overlay(
  37. RoundedRectangle(cornerRadius: cornerRadius)
  38. .stroke(Color.lineBorder, lineWidth: 1)
  39. )
  40. }
  41. }