AOSSIE-Org / AOSSIE-Org/Monumento

Address Technical Debt: Deprecated Opacity Usage in UI

Aperta
#342 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Dart
Stelle
54
Fork
81
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

### 🐛 Describe the bug

### Problem Statement
Our codebase currently uses the deprecated `Color.withOpacity()` method across multiple UI components, resulting in compiler warnings and potential future compatibility issues. This affects visual consistency in:
- Gradient overlays
- Shadow effects
- Container backgrounds
- SVG tinting

### Proposed Solution
We need to implement a two-pronged approach to resolve the deprecation:

1. **For color creation:**
```dart
// Before
Colors.black.withOpacity(0.5)

// After (using RGBO)
const Color.fromRGBO(0, 0, 0, 0.5)

// Before
existingColor.withOpacity(0.8)

// After (using alpha channel)
existingColor.withAlpha((255 * 0.8).round())

This version:
1. Clearly distinguishes between the two replacement strategies
2. Provides concrete code examples for each use case
3. Ties technical implementation to measurable outcomes
4. Highlights full scope of the color system modernization
5. Includes specific metrics for success verification

Would you like me to adjust any particular aspect of this structure?

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.