Replace all .withOpacity() with .withValues(alpha:) across 32 files (189 occurrences) - zero deprecation warnings remaining

This commit is contained in:
Patrick Britton 2026-02-10 16:18:50 -06:00
parent 2f9f0aaaf2
commit 6867c95ca6
32 changed files with 189 additions and 190 deletions

View file

@ -111,7 +111,7 @@ class _CategorySelectScreenState extends ConsumerState<CategorySelectScreen> {
Text(
'We\'ll use this to personalize your feed. You can adjust this anytime.',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.8), // Replaced AppTheme.textSecondary
color: AppTheme.navyText.withValues(alpha: 0.8), // Replaced AppTheme.textSecondary
),
textAlign: TextAlign.center,
),
@ -120,7 +120,7 @@ class _CategorySelectScreenState extends ConsumerState<CategorySelectScreen> {
Container(
padding: const EdgeInsets.all(AppTheme.spacingMd),
decoration: BoxDecoration(
color: AppTheme.error.withOpacity(0.1), // Replaced withValues
color: AppTheme.error.withValues(alpha: 0.1), // Replaced withValues
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.error, width: 1),
),

View file

@ -109,7 +109,7 @@ class _ProfileSetupScreenState extends ConsumerState<ProfileSetupScreen> {
Text(
'Your handle is permanent. Choose thoughtfully.',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.8), // Replaced AppTheme.textSecondary
color: AppTheme.navyText.withValues(alpha: 0.8), // Replaced AppTheme.textSecondary
),
textAlign: TextAlign.center,
),
@ -120,7 +120,7 @@ class _ProfileSetupScreenState extends ConsumerState<ProfileSetupScreen> {
Container(
padding: const EdgeInsets.all(AppTheme.spacingMd),
decoration: BoxDecoration(
color: AppTheme.error.withOpacity(0.1), // Replaced withValues
color: AppTheme.error.withValues(alpha: 0.1), // Replaced withValues
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.error, width: 1),
),

View file

@ -251,7 +251,7 @@ class _SignInScreenState extends ConsumerState<SignInScreen> {
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(20),
border: Border.all(
color: AppTheme.queenPink.withOpacity(0.6),
color: AppTheme.queenPink.withValues(alpha: 0.6),
),
boxShadow: [
BoxShadow(
@ -283,7 +283,7 @@ class _SignInScreenState extends ConsumerState<SignInScreen> {
padding:
const EdgeInsets.all(AppTheme.spacingMd),
decoration: BoxDecoration(
color: AppTheme.error.withOpacity(0.08),
color: AppTheme.error.withValues(alpha: 0.08),
borderRadius: BorderRadius.circular(12),
border: Border.all(
color: AppTheme.error, width: 1),
@ -408,7 +408,7 @@ class _SignInScreenState extends ConsumerState<SignInScreen> {
border: Border.all(
color: _turnstileToken != null
? AppTheme.success
: AppTheme.egyptianBlue.withOpacity(0.3),
: AppTheme.egyptianBlue.withValues(alpha: 0.3),
width: 1,
),
borderRadius: BorderRadius.circular(12),
@ -452,7 +452,7 @@ class _SignInScreenState extends ConsumerState<SignInScreen> {
style: AppTheme.textTheme.labelSmall
?.copyWith(
color: AppTheme.navyText
.withOpacity(0.75),
.withValues(alpha: 0.75),
),
),
),
@ -495,7 +495,7 @@ class _SignInScreenState extends ConsumerState<SignInScreen> {
BorderRadius.circular(26),
border: Border.all(
color: AppTheme.egyptianBlue
.withOpacity(0.5),
.withValues(alpha: 0.5),
),
boxShadow: [
BoxShadow(
@ -526,7 +526,7 @@ class _SignInScreenState extends ConsumerState<SignInScreen> {
style: AppTheme.textTheme.labelSmall
?.copyWith(
color: AppTheme.navyText
.withOpacity(0.7),
.withValues(alpha: 0.7),
),
),
],

View file

@ -249,7 +249,7 @@ class _SignUpScreenState extends ConsumerState<SignUpScreen> {
Text(
'Your vibrant journey begins now',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.8),
color: AppTheme.navyText.withValues(alpha: 0.8),
),
textAlign: TextAlign.center,
),
@ -260,7 +260,7 @@ class _SignUpScreenState extends ConsumerState<SignUpScreen> {
Container(
padding: const EdgeInsets.all(AppTheme.spacingMd),
decoration: BoxDecoration(
color: AppTheme.error.withOpacity(0.1),
color: AppTheme.error.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.error, width: 1),
),
@ -379,7 +379,7 @@ class _SignUpScreenState extends ConsumerState<SignUpScreen> {
Text(
'You must be at least 16 to use Sojorn. Users under 18 cannot access sensitive content.',
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.6),
color: AppTheme.navyText.withValues(alpha: 0.6),
),
),
const SizedBox(height: AppTheme.spacingSm),
@ -439,7 +439,7 @@ class _SignUpScreenState extends ConsumerState<SignUpScreen> {
border: Border.all(
color: _turnstileToken != null
? AppTheme.success
: AppTheme.egyptianBlue.withOpacity(0.3),
: AppTheme.egyptianBlue.withValues(alpha: 0.3),
width: 1,
),
borderRadius: BorderRadius.circular(12),

View file

@ -56,7 +56,7 @@ class sojornImageEditor extends StatelessWidget {
activeTrackColor: AppTheme.brightNavy,
inactiveTrackColor: SojornColors.basicWhite.withValues(alpha: 0.24),
thumbColor: AppTheme.brightNavy,
overlayColor: AppTheme.brightNavy.withOpacity(0.2),
overlayColor: AppTheme.brightNavy.withValues(alpha: 0.2),
),
textButtonTheme: TextButtonThemeData(
style: TextButton.styleFrom(

View file

@ -287,7 +287,7 @@ class _sojornVideoEditorState extends State<sojornVideoEditor> {
},
child: Container(
width: 20,
color: _brightNavy.withOpacity(0.3),
color: _brightNavy.withValues(alpha: 0.3),
child: Center(
child: Container(
width: 4,
@ -309,7 +309,7 @@ class _sojornVideoEditorState extends State<sojornVideoEditor> {
},
child: Container(
width: 20,
color: _brightNavy.withOpacity(0.3),
color: _brightNavy.withValues(alpha: 0.3),
child: Center(
child: Container(
width: 4,
@ -357,7 +357,7 @@ class _sojornVideoEditorState extends State<sojornVideoEditor> {
activeTrackColor: _brightNavy,
inactiveTrackColor: SojornColors.basicWhite.withValues(alpha: 0.24),
thumbColor: _brightNavy,
overlayColor: _brightNavy.withOpacity(0.2),
overlayColor: _brightNavy.withValues(alpha: 0.2),
trackHeight: 4,
thumbShape: const RoundSliderThumbShape(enabledThumbRadius: 8),
),

View file

@ -324,12 +324,12 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
decoration: BoxDecoration(
color: AppTheme.scaffoldBg,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.3)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.3)),
),
child: Row(
children: [
Icon(Icons.search,
color: AppTheme.egyptianBlue.withOpacity(0.6), size: 20),
color: AppTheme.egyptianBlue.withValues(alpha: 0.6), size: 20),
const SizedBox(width: 10),
Expanded(
child: TextField(
@ -337,7 +337,7 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
focusNode: focusNode,
decoration: InputDecoration(
hintText: 'Search people, hashtags, posts...',
hintStyle: TextStyle(color: AppTheme.egyptianBlue.withOpacity(0.5)),
hintStyle: TextStyle(color: AppTheme.egyptianBlue.withValues(alpha: 0.5)),
border: InputBorder.none,
isDense: true,
contentPadding: EdgeInsets.zero,
@ -396,7 +396,7 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
fontWeight: FontWeight.w600,
fontSize: 14,
),
backgroundColor: AppTheme.royalPurple.withOpacity(0.1),
backgroundColor: AppTheme.royalPurple.withValues(alpha: 0.1),
side: BorderSide.none,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(20),
@ -480,11 +480,11 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(Icons.search_off,
size: 64, color: AppTheme.egyptianBlue.withOpacity(0.5)),
size: 64, color: AppTheme.egyptianBlue.withValues(alpha: 0.5)),
const SizedBox(height: 16),
Text('No results found',
style: AppTheme.headlineSmall
.copyWith(color: AppTheme.navyText.withOpacity(0.7))),
.copyWith(color: AppTheme.navyText.withValues(alpha: 0.7))),
const SizedBox(height: 8),
Text('Try a different search term',
style: AppTheme.bodyMedium.copyWith(color: AppTheme.egyptianBlue)),
@ -562,7 +562,7 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
children: [
CircleAvatar(
radius: 30,
backgroundColor: AppTheme.royalPurple.withOpacity(0.2),
backgroundColor: AppTheme.royalPurple.withValues(alpha: 0.2),
child: user.avatarUrl != null
? ClipRRect(
borderRadius: BorderRadius.circular(30),
@ -596,7 +596,7 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
Text(
'@${user.username}',
style: TextStyle(
color: AppTheme.egyptianBlue.withOpacity(0.7), fontSize: 11),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7), fontSize: 11),
maxLines: 1,
overflow: TextOverflow.ellipsis,
),
@ -615,7 +615,7 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.2)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
child: Row(
children: [
@ -623,7 +623,7 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
width: 40,
height: 40,
decoration: BoxDecoration(
color: AppTheme.royalPurple.withOpacity(0.1),
color: AppTheme.royalPurple.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(10),
),
child: Icon(Icons.tag, color: AppTheme.royalPurple, size: 20),
@ -640,13 +640,13 @@ class _DiscoverScreenState extends ConsumerState<DiscoverScreen> {
fontSize: 15)),
Text('${tag.count} posts',
style: TextStyle(
color: AppTheme.egyptianBlue.withOpacity(0.7),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7),
fontSize: 13)),
],
),
),
Icon(Icons.chevron_right,
color: AppTheme.egyptianBlue.withOpacity(0.5)),
color: AppTheme.egyptianBlue.withValues(alpha: 0.5)),
],
),
),

View file

@ -239,7 +239,7 @@ class _EmptyState extends StatelessWidget {
'Your feed is vibrant!', // Updated text
style: AppTheme.headlineSmall.copyWith(
color: AppTheme.navyText
.withOpacity(0.8), // Replaced AppTheme.textSecondary
.withValues(alpha: 0.8), // Replaced AppTheme.textSecondary
),
),
const SizedBox(height: AppTheme.spacingSm),

View file

@ -129,7 +129,7 @@ class _HomeShellState extends ConsumerState<HomeShell> with WidgetsBindingObserv
borderRadius: BorderRadius.circular(16),
boxShadow: [
BoxShadow(
color: (hasState ? AppTheme.brightNavy : AppTheme.navyBlue).withOpacity(0.4),
color: (hasState ? AppTheme.brightNavy : AppTheme.navyBlue).withValues(alpha: 0.4),
blurRadius: 12,
offset: const Offset(0, 4),
),

View file

@ -370,7 +370,7 @@ class _NotificationsScreenState extends ConsumerState<NotificationsScreen> {
},
indicatorColor: AppTheme.egyptianBlue,
labelColor: AppTheme.egyptianBlue,
unselectedLabelColor: AppTheme.egyptianBlue.withOpacity(0.5),
unselectedLabelColor: AppTheme.egyptianBlue.withValues(alpha: 0.5),
tabs: const [
Tab(text: 'Active'),
Tab(text: 'Archived'),
@ -429,7 +429,7 @@ class _NotificationsScreenState extends ConsumerState<NotificationsScreen> {
background: Container(
alignment: Alignment.centerRight,
padding: const EdgeInsets.only(right: 20),
color: AppTheme.royalPurple.withOpacity(0.8),
color: AppTheme.royalPurple.withValues(alpha: 0.8),
child: const Row(
mainAxisAlignment: MainAxisAlignment.end,
children: [
@ -507,10 +507,10 @@ class _NotificationItem extends StatelessWidget {
decoration: BoxDecoration(
color: notification.isRead
? SojornColors.transparent
: AppTheme.royalPurple.withOpacity(0.05),
: AppTheme.royalPurple.withValues(alpha: 0.05),
border: Border(
bottom: BorderSide(
color: AppTheme.egyptianBlue.withOpacity(0.15),
color: AppTheme.egyptianBlue.withValues(alpha: 0.15),
width: 1,
),
),
@ -552,7 +552,7 @@ class _NotificationItem extends StatelessWidget {
Text(
notification.postBody!,
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.6),
color: AppTheme.navyText.withValues(alpha: 0.6),
),
maxLines: 2,
overflow: TextOverflow.ellipsis,
@ -562,7 +562,7 @@ class _NotificationItem extends StatelessWidget {
Text(
timeago.format(notification.createdAt, locale: 'en_short'),
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.egyptianBlue.withOpacity(0.7),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7),
),
),
],
@ -625,10 +625,10 @@ class _NotificationItem extends StatelessWidget {
width: 40,
height: 40,
decoration: BoxDecoration(
color: iconColor.withOpacity(0.1),
color: iconColor.withValues(alpha: 0.1),
shape: BoxShape.circle,
border: Border.all(
color: iconColor.withOpacity(0.3),
color: iconColor.withValues(alpha: 0.3),
width: 1,
),
),
@ -664,10 +664,10 @@ class _FollowRequestItem extends StatelessWidget {
decoration: BoxDecoration(
color: notification.isRead
? SojornColors.transparent
: AppTheme.royalPurple.withOpacity(0.05),
: AppTheme.royalPurple.withValues(alpha: 0.05),
border: Border(
bottom: BorderSide(
color: AppTheme.egyptianBlue.withOpacity(0.15),
color: AppTheme.egyptianBlue.withValues(alpha: 0.15),
width: 1,
),
),
@ -715,7 +715,7 @@ class _FollowRequestItem extends StatelessWidget {
Text(
'@$handle',
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.7),
color: AppTheme.navyText.withValues(alpha: 0.7),
),
),
],
@ -723,7 +723,7 @@ class _FollowRequestItem extends StatelessWidget {
Text(
'requested to follow you',
style: AppTheme.textTheme.bodySmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.8),
color: AppTheme.navyText.withValues(alpha: 0.8),
),
),
const SizedBox(height: AppTheme.spacingSm),
@ -746,7 +746,7 @@ class _FollowRequestItem extends StatelessWidget {
Text(
timeago.format(notification.createdAt, locale: 'en_short'),
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.egyptianBlue.withOpacity(0.7),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7),
),
),
],
@ -807,7 +807,7 @@ class _EmptyState extends StatelessWidget {
Icon(
Icons.notifications_none,
size: 80,
color: AppTheme.egyptianBlue.withOpacity(0.3),
color: AppTheme.egyptianBlue.withValues(alpha: 0.3),
),
const SizedBox(height: AppTheme.spacingLg),
Text(
@ -819,7 +819,7 @@ class _EmptyState extends StatelessWidget {
Text(
"You'll see notifications here when someone appreciates your posts, chains them, or follows you.",
style: AppTheme.textTheme.bodyMedium?.copyWith(
color: AppTheme.navyText.withOpacity(0.7),
color: AppTheme.navyText.withValues(alpha: 0.7),
),
textAlign: TextAlign.center,
),

View file

@ -174,12 +174,12 @@ class _BlockedUsersScreenState extends ConsumerState<BlockedUsersScreen> {
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(Icons.block, size: 64, color: AppTheme.egyptianBlue.withOpacity(0.3)),
Icon(Icons.block, size: 64, color: AppTheme.egyptianBlue.withValues(alpha: 0.3)),
const SizedBox(height: 16),
Text(
'No blocked users',
style: AppTheme.textTheme.titleMedium?.copyWith(
color: AppTheme.navyText.withOpacity(0.5),
color: AppTheme.navyText.withValues(alpha: 0.5),
),
),
],

View file

@ -81,7 +81,7 @@ class _CategoryDiscoveryScreenState extends ConsumerState<CategoryDiscoveryScree
decoration: BoxDecoration(
color: SojornColors.basicWhite,
borderRadius: BorderRadius.circular(16),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.1)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.1)),
),
child: SwitchListTile(
activeColor: AppTheme.brightNavy,

View file

@ -126,7 +126,7 @@ class _FollowRequestsScreenState extends ConsumerState<FollowRequestsScreen> {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.queenPink.withOpacity(0.6)),
border: Border.all(color: AppTheme.queenPink.withValues(alpha: 0.6)),
),
child: Row(
children: [
@ -168,7 +168,7 @@ class _FollowRequestsScreenState extends ConsumerState<FollowRequestsScreen> {
Text(
'@${request.handle}',
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.7),
color: AppTheme.navyText.withValues(alpha: 0.7),
),
),
],

View file

@ -165,7 +165,7 @@ class _FollowersFollowingScreenState
controller: _tabController,
indicatorColor: AppTheme.ksuPurple,
labelColor: AppTheme.navyText,
unselectedLabelColor: AppTheme.navyText.withOpacity(0.5),
unselectedLabelColor: AppTheme.navyText.withValues(alpha: 0.5),
tabs: [
Tab(text: 'Followers (${_followers.length})'),
Tab(text: 'Following (${_following.length})'),
@ -216,7 +216,7 @@ class _FollowersFollowingScreenState
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(Icons.error_outline, size: 48, color: AppTheme.navyText.withOpacity(0.5)),
Icon(Icons.error_outline, size: 48, color: AppTheme.navyText.withValues(alpha: 0.5)),
const SizedBox(height: 16),
Text('Failed to load', style: AppTheme.bodyLarge),
const SizedBox(height: 8),
@ -237,12 +237,12 @@ class _FollowersFollowingScreenState
Icon(
isFollowersList ? Icons.people_outline : Icons.person_add_outlined,
size: 64,
color: AppTheme.navyText.withOpacity(0.3),
color: AppTheme.navyText.withValues(alpha: 0.3),
),
const SizedBox(height: 16),
Text(
isFollowersList ? 'No followers yet' : 'Not following anyone yet',
style: AppTheme.bodyLarge.copyWith(color: AppTheme.navyText.withOpacity(0.6)),
style: AppTheme.bodyLarge.copyWith(color: AppTheme.navyText.withValues(alpha: 0.6)),
),
],
),
@ -342,7 +342,7 @@ class _UserListTile extends StatelessWidget {
case 'bronze':
return const Color(0xFFCD7F32);
default:
return AppTheme.navyText.withOpacity(0.5);
return AppTheme.navyText.withValues(alpha: 0.5);
}
}
@ -382,7 +382,7 @@ class _UserListTile extends StatelessWidget {
Container(
padding: const EdgeInsets.symmetric(horizontal: 6, vertical: 2),
decoration: BoxDecoration(
color: _getTierColor(user.harmonyTier).withOpacity(0.2),
color: _getTierColor(user.harmonyTier).withValues(alpha: 0.2),
borderRadius: BorderRadius.circular(4),
),
child: Text(
@ -399,14 +399,14 @@ class _UserListTile extends StatelessWidget {
),
subtitle: Text(
'@${user.handle}',
style: AppTheme.labelSmall.copyWith(color: AppTheme.navyText.withOpacity(0.6)),
style: AppTheme.labelSmall.copyWith(color: AppTheme.navyText.withValues(alpha: 0.6)),
),
trailing: isFollowersList
? null // Followers don't have action button for now
: TextButton(
onPressed: onAction,
style: TextButton.styleFrom(
foregroundColor: AppTheme.navyText.withOpacity(0.7),
foregroundColor: AppTheme.navyText.withValues(alpha: 0.7),
padding: const EdgeInsets.symmetric(horizontal: 12),
),
child: const Text('Unfollow'),

View file

@ -214,7 +214,7 @@ class _FollowingScreenState extends ConsumerState<FollowingScreen> {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
border: Border(
bottom: BorderSide(color: AppTheme.egyptianBlue.withOpacity(0.3)),
bottom: BorderSide(color: AppTheme.egyptianBlue.withValues(alpha: 0.3)),
),
),
child: TabBar(
@ -222,7 +222,7 @@ class _FollowingScreenState extends ConsumerState<FollowingScreen> {
return Tab(text: tab.displayName);
}).toList(),
labelColor: AppTheme.navyBlue,
unselectedLabelColor: AppTheme.egyptianBlue.withOpacity(0.5),
unselectedLabelColor: AppTheme.egyptianBlue.withValues(alpha: 0.5),
indicatorColor: AppTheme.royalPurple,
indicatorWeight: 3,
onTap: (index) {
@ -240,7 +240,7 @@ class _FollowingScreenState extends ConsumerState<FollowingScreen> {
decoration: BoxDecoration(
color: AppTheme.scaffoldBg,
border: Border(
bottom: BorderSide(color: AppTheme.egyptianBlue.withOpacity(0.2)),
bottom: BorderSide(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
),
child: Row(
@ -264,7 +264,7 @@ class _FollowingScreenState extends ConsumerState<FollowingScreen> {
),
underline: Container(
height: 1,
color: AppTheme.royalPurple.withOpacity(0.3),
color: AppTheme.royalPurple.withValues(alpha: 0.3),
),
onChanged: (FollowingSort? newValue) {
if (newValue != null) {
@ -350,7 +350,7 @@ class _FollowingScreenState extends ConsumerState<FollowingScreen> {
Icon(
Icons.people_outline,
size: 64,
color: AppTheme.egyptianBlue.withOpacity(0.5),
color: AppTheme.egyptianBlue.withValues(alpha: 0.5),
),
const SizedBox(height: AppTheme.spacingMd),
Text(
@ -483,7 +483,7 @@ class _UserListItem extends StatelessWidget {
color: AppTheme.scaffoldBg,
borderRadius: BorderRadius.circular(8),
border: Border.all(
color: AppTheme.egyptianBlue.withOpacity(0.2),
color: AppTheme.egyptianBlue.withValues(alpha: 0.2),
),
),
child: Column(
@ -503,7 +503,7 @@ class _UserListItem extends StatelessWidget {
? timeago.format(user.latestPostCreatedAt!)
: '',
style: AppTheme.labelSmall.copyWith(
color: AppTheme.egyptianBlue.withOpacity(0.7),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7),
),
),
],
@ -516,13 +516,13 @@ class _UserListItem extends StatelessWidget {
Icon(
Icons.access_time,
size: 12,
color: AppTheme.egyptianBlue.withOpacity(0.6),
color: AppTheme.egyptianBlue.withValues(alpha: 0.6),
),
const SizedBox(width: 4),
Text(
'Active ${timeago.format(user.lastActive)}',
style: AppTheme.labelSmall.copyWith(
color: AppTheme.egyptianBlue.withOpacity(0.7),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7),
),
),
const SizedBox(width: 12),
@ -546,7 +546,7 @@ class _UserListItem extends StatelessWidget {
),
Icon(
Icons.chevron_right,
color: AppTheme.egyptianBlue.withOpacity(0.5),
color: AppTheme.egyptianBlue.withValues(alpha: 0.5),
),
],
),

View file

@ -195,13 +195,13 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
height: 180,
width: double.infinity,
decoration: BoxDecoration(
color: AppTheme.egyptianBlue.withOpacity(0.1),
color: AppTheme.egyptianBlue.withValues(alpha: 0.1),
),
child: _isBannerUploading
? const Center(child: CircularProgressIndicator())
: profile.coverUrl != null
? SignedMediaImage(url: profile.coverUrl!, fit: BoxFit.cover)
: Center(child: Icon(Icons.add_photo_alternate_outlined, color: AppTheme.egyptianBlue.withOpacity(0.5), size: 40)),
: Center(child: Icon(Icons.add_photo_alternate_outlined, color: AppTheme.egyptianBlue.withValues(alpha: 0.5), size: 40)),
),
),
// Glass Overlay for Banner Action
@ -264,16 +264,16 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
return Container(
padding: const EdgeInsets.all(AppTheme.spacingMd),
decoration: BoxDecoration(
color: AppTheme.royalPurple.withOpacity(0.05),
color: AppTheme.royalPurple.withValues(alpha: 0.05),
borderRadius: BorderRadius.circular(16),
border: Border.all(color: AppTheme.royalPurple.withOpacity(0.2)),
border: Border.all(color: AppTheme.royalPurple.withValues(alpha: 0.2)),
),
child: Row(
children: [
Container(
padding: const EdgeInsets.all(10),
decoration: BoxDecoration(
color: AppTheme.royalPurple.withOpacity(0.1),
color: AppTheme.royalPurple.withValues(alpha: 0.1),
shape: BoxShape.circle,
),
child: Icon(Icons.spa_outlined, color: AppTheme.royalPurple),
@ -287,7 +287,7 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
const SizedBox(height: 2),
Text(
'Your current reach multiplier is based on your contribution to the community.',
style: AppTheme.textTheme.bodySmall?.copyWith(color: AppTheme.navyText.withOpacity(0.6)),
style: AppTheme.textTheme.bodySmall?.copyWith(color: AppTheme.navyText.withValues(alpha: 0.6)),
),
],
),
@ -302,13 +302,13 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(title, style: AppTheme.textTheme.headlineSmall),
Text(subtitle, style: AppTheme.textTheme.labelSmall?.copyWith(color: AppTheme.navyText.withOpacity(0.5))),
Text(subtitle, style: AppTheme.textTheme.labelSmall?.copyWith(color: AppTheme.navyText.withValues(alpha: 0.5))),
const SizedBox(height: AppTheme.spacingMd),
Container(
decoration: BoxDecoration(
color: SojornColors.basicWhite.withValues(alpha: 0.5),
borderRadius: BorderRadius.circular(20),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.1)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.1)),
),
clipBehavior: Clip.antiAlias,
child: Column(children: children),
@ -322,7 +322,7 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
onTap: onTap,
leading: Icon(icon, color: color ?? AppTheme.navyBlue, size: 22),
title: Text(title, style: AppTheme.textTheme.bodyLarge),
trailing: Icon(Icons.chevron_right, color: AppTheme.egyptianBlue.withOpacity(0.3)),
trailing: Icon(Icons.chevron_right, color: AppTheme.egyptianBlue.withValues(alpha: 0.3)),
);
}
@ -362,8 +362,8 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
return Center(
child: Column(
children: [
Text('Sojorn Sanctuary', style: AppTheme.textTheme.labelMedium?.copyWith(color: AppTheme.navyText.withOpacity(0.4))),
Text('A product of MPLS LLC \u00a9 ${DateTime.now().year}', style: AppTheme.textTheme.labelSmall?.copyWith(color: AppTheme.navyText.withOpacity(0.3))),
Text('Sojorn Sanctuary', style: AppTheme.textTheme.labelMedium?.copyWith(color: AppTheme.navyText.withValues(alpha: 0.4))),
Text('A product of MPLS LLC \u00a9 ${DateTime.now().year}', style: AppTheme.textTheme.labelSmall?.copyWith(color: AppTheme.navyText.withValues(alpha: 0.3))),
],
),
);
@ -441,7 +441,7 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
width: double.infinity,
padding: const EdgeInsets.symmetric(vertical: 14, horizontal: 20),
decoration: BoxDecoration(
color: AppTheme.cardSurface.withOpacity(0.6),
color: AppTheme.cardSurface.withValues(alpha: 0.6),
borderRadius: BorderRadius.circular(16),
border: Border.all(color: AppTheme.navyBlue.withValues(alpha: 0.08)),
),
@ -451,13 +451,13 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
Icon(
Icons.shield_outlined,
size: 16,
color: AppTheme.textSecondary.withOpacity(0.5),
color: AppTheme.textSecondary.withValues(alpha: 0.5),
),
const SizedBox(width: 8),
Text(
'Content Sensitivity Settings',
style: AppTheme.textTheme.labelSmall?.copyWith(
color: AppTheme.textSecondary.withOpacity(0.5),
color: AppTheme.textSecondary.withValues(alpha: 0.5),
fontSize: 12,
),
),
@ -465,7 +465,7 @@ class _ProfileSettingsScreenState extends ConsumerState<ProfileSettingsScreen> {
Icon(
_nsfwSectionExpanded ? Icons.expand_less : Icons.expand_more,
size: 16,
color: AppTheme.textSecondary.withOpacity(0.5),
color: AppTheme.textSecondary.withValues(alpha: 0.5),
),
],
),

View file

@ -667,7 +667,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
'Control who can see your profile and posts.',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.7),
color: AppTheme.navyText.withValues(alpha: 0.7),
),
),
const SizedBox(height: AppTheme.spacingLg),
@ -972,7 +972,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
TabBar(
controller: _tabController,
labelColor: AppTheme.navyText,
unselectedLabelColor: AppTheme.navyText.withOpacity(0.6),
unselectedLabelColor: AppTheme.navyText.withValues(alpha: 0.6),
indicatorColor: AppTheme.royalPurple,
indicatorWeight: 3,
labelStyle: AppTheme.labelMedium,
@ -1064,7 +1064,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
child: Text(
'No posts yet',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.7),
color: AppTheme.navyText.withValues(alpha: 0.7),
),
),
),
@ -1134,7 +1134,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Icon(
Icons.lock_outline,
size: 64,
color: AppTheme.navyText.withOpacity(0.5),
color: AppTheme.navyText.withValues(alpha: 0.5),
),
const SizedBox(height: AppTheme.spacingMd),
Text(
@ -1146,7 +1146,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
'Follow @${profile.handle} to see their bio, location, website, and interests.',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.8),
color: AppTheme.navyText.withValues(alpha: 0.8),
),
textAlign: TextAlign.center,
),
@ -1172,7 +1172,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
profile.bio!,
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.85),
color: AppTheme.navyText.withValues(alpha: 0.85),
),
),
const SizedBox(height: AppTheme.spacingLg),
@ -1185,7 +1185,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
profile.location!,
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.85),
color: AppTheme.navyText.withValues(alpha: 0.85),
),
),
],
@ -1262,7 +1262,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
_formatDate(profile.createdAt),
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.85),
color: AppTheme.navyText.withValues(alpha: 0.85),
),
),
if (profile.trustState != null) ...[
@ -1300,7 +1300,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
'Tier: ',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.85),
color: AppTheme.navyText.withValues(alpha: 0.85),
),
),
Text(
@ -1318,7 +1318,7 @@ class _UnifiedProfileScreenState extends ConsumerState<UnifiedProfileScreen>
Text(
'Harmony Score: ',
style: AppTheme.bodyMedium.copyWith(
color: AppTheme.navyText.withOpacity(0.85),
color: AppTheme.navyText.withValues(alpha: 0.85),
),
),
Text(
@ -1421,7 +1421,6 @@ class _ProfileHeader extends StatelessWidget {
child: Column(
mainAxisAlignment: MainAxisAlignment.end,
mainAxisSize: MainAxisSize.min,
clipBehavior: Clip.hardEdge,
children: [
if (isOwnProfile)
Align(
@ -1464,7 +1463,7 @@ class _ProfileHeader extends StatelessWidget {
Text(
profile.displayName,
style: AppTheme.headlineMedium.copyWith(
color: AppTheme.white.withOpacity(0.95),
color: AppTheme.white.withValues(alpha: 0.95),
fontSize: isCompact ? 16 : 18,
shadows: [
Shadow(
@ -1485,7 +1484,7 @@ class _ProfileHeader extends StatelessWidget {
'@${profile.handle}',
style: AppTheme.bodyMedium.copyWith(
fontSize: 12,
color: AppTheme.white.withOpacity(0.85),
color: AppTheme.white.withValues(alpha: 0.85),
shadows: [
Shadow(
color: const Color(0x33000000),
@ -1558,7 +1557,7 @@ class _ProfileHeader extends StatelessWidget {
onPressed: onMessageTap,
style: OutlinedButton.styleFrom(
foregroundColor: AppTheme.white,
side: BorderSide(color: AppTheme.white.withOpacity(0.7)),
side: BorderSide(color: AppTheme.white.withValues(alpha: 0.7)),
padding: const EdgeInsets.symmetric(
horizontal: AppTheme.spacingMd,
vertical: AppTheme.spacingSm,
@ -1777,13 +1776,13 @@ class _HarmonyAvatar extends StatelessWidget {
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(radius * 0.45),
border: Border.all(
color: ringWidth >= 4 ? ringColor : ringColor.withOpacity(0.8),
color: ringWidth >= 4 ? ringColor : ringColor.withValues(alpha: 0.8),
width: ringWidth,
),
boxShadow: [
if (ringWidth >= 4)
BoxShadow(
color: ringColor.withOpacity(0.5),
color: ringColor.withValues(alpha: 0.5),
blurRadius: 12,
spreadRadius: 2,
),
@ -1852,7 +1851,7 @@ class _HarmonyBadge extends StatelessWidget {
vertical: 4,
),
decoration: BoxDecoration(
color: badgeColor.withOpacity(0.2),
color: badgeColor.withValues(alpha: 0.2),
border: Border.all(color: badgeColor, width: 1.5),
borderRadius: BorderRadius.circular(AppTheme.radiusSm),
),
@ -1911,7 +1910,7 @@ class _HeaderActionButton extends StatelessWidget {
onPressed: onPressed,
style: OutlinedButton.styleFrom(
foregroundColor: AppTheme.white,
side: BorderSide(color: AppTheme.white.withOpacity(0.7)),
side: BorderSide(color: AppTheme.white.withValues(alpha: 0.7)),
padding: const EdgeInsets.symmetric(
horizontal: AppTheme.spacingMd,
vertical: AppTheme.spacingSm,

View file

@ -191,7 +191,7 @@ class _QuipEditorScreenState extends ConsumerState<QuipEditorScreen> {
color: SojornColors.basicBlack,
borderRadius: BorderRadius.circular(16),
border: Border.all(
color: AppTheme.brightNavy.withOpacity(0.3),
color: AppTheme.brightNavy.withValues(alpha: 0.3),
width: 2,
),
),
@ -295,7 +295,7 @@ class _QuipEditorScreenState extends ConsumerState<QuipEditorScreen> {
backgroundColor: AppTheme.brightNavy,
foregroundColor: SojornColors.basicWhite,
padding: const EdgeInsets.symmetric(vertical: 16),
disabledBackgroundColor: AppTheme.brightNavy.withOpacity(0.5),
disabledBackgroundColor: AppTheme.brightNavy.withValues(alpha: 0.5),
),
),
],

View file

@ -282,12 +282,12 @@ class _SearchScreenState extends ConsumerState<SearchScreen> {
decoration: BoxDecoration(
color: AppTheme.scaffoldBg,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.3)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.3)),
),
child: Row(
children: [
Icon(Icons.search,
color: AppTheme.egyptianBlue.withOpacity(0.6), size: 20),
color: AppTheme.egyptianBlue.withValues(alpha: 0.6), size: 20),
const SizedBox(width: 10),
Expanded(
child: TextField(
@ -349,11 +349,11 @@ class _SearchScreenState extends ConsumerState<SearchScreen> {
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(Icons.search_off,
size: 64, color: AppTheme.egyptianBlue.withOpacity(0.5)),
size: 64, color: AppTheme.egyptianBlue.withValues(alpha: 0.5)),
const SizedBox(height: 16),
Text('No results found',
style: AppTheme.headlineSmall
.copyWith(color: AppTheme.navyText.withOpacity(0.7))),
.copyWith(color: AppTheme.navyText.withValues(alpha: 0.7))),
const SizedBox(height: 8),
Text('Try a different search term',
style:
@ -471,7 +471,7 @@ class _SearchScreenState extends ConsumerState<SearchScreen> {
search.type == RecentSearchType.user
? Icons.person
: Icons.tag,
color: AppTheme.egyptianBlue.withOpacity(0.6),
color: AppTheme.egyptianBlue.withValues(alpha: 0.6),
),
title: Text(
search.type == RecentSearchType.user
@ -480,7 +480,7 @@ class _SearchScreenState extends ConsumerState<SearchScreen> {
style: AppTheme.bodyMedium,
),
trailing: Icon(Icons.history,
color: AppTheme.egyptianBlue.withOpacity(0.4), size: 18),
color: AppTheme.egyptianBlue.withValues(alpha: 0.4), size: 18),
onTap: () => onRecentSearchTap(search),
);
},
@ -547,7 +547,7 @@ class _SearchScreenState extends ConsumerState<SearchScreen> {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.2)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
child: sojornPostCard(
post: post,
@ -611,7 +611,7 @@ class _SearchScreenState extends ConsumerState<SearchScreen> {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.2)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
child: sojornPostCard(
post: minimalPost,
@ -680,7 +680,7 @@ class UserResultItem extends StatelessWidget {
Text(
'@${user.username}',
style: TextStyle(
color: AppTheme.egyptianBlue.withOpacity(0.7), fontSize: 11),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7), fontSize: 11),
maxLines: 1,
overflow: TextOverflow.ellipsis,
),
@ -707,7 +707,7 @@ class TagResultItem extends StatelessWidget {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.2)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
child: Row(
children: [
@ -732,13 +732,13 @@ class TagResultItem extends StatelessWidget {
fontSize: 15)),
Text('${tag.count} posts',
style: TextStyle(
color: AppTheme.egyptianBlue.withOpacity(0.7),
color: AppTheme.egyptianBlue.withValues(alpha: 0.7),
fontSize: 13)),
],
),
),
Icon(Icons.chevron_right,
color: AppTheme.egyptianBlue.withOpacity(0.5)),
color: AppTheme.egyptianBlue.withValues(alpha: 0.5)),
],
),
),
@ -760,7 +760,7 @@ class TrendingTagItem extends StatelessWidget {
decoration: BoxDecoration(
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.2)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
child: Row(
children: [

View file

@ -108,14 +108,14 @@ class _ChatDataManagementScreenState extends State<ChatDataManagementScreen> {
decoration: BoxDecoration(
gradient: LinearGradient(
colors: isHealthy
? [AppTheme.brightNavy.withOpacity(0.08), AppTheme.brightNavy.withOpacity(0.03)]
? [AppTheme.brightNavy.withValues(alpha: 0.08), AppTheme.brightNavy.withValues(alpha: 0.03)]
: [AppTheme.cardSurface, AppTheme.cardSurface],
begin: Alignment.topLeft,
end: Alignment.bottomRight,
),
borderRadius: BorderRadius.circular(16),
border: Border.all(
color: isHealthy ? AppTheme.brightNavy.withOpacity(0.2) : AppTheme.border,
color: isHealthy ? AppTheme.brightNavy.withValues(alpha: 0.2) : AppTheme.border,
),
),
child: Column(
@ -125,7 +125,7 @@ class _ChatDataManagementScreenState extends State<ChatDataManagementScreen> {
Container(
padding: const EdgeInsets.all(10),
decoration: BoxDecoration(
color: color.withOpacity(0.12),
color: color.withValues(alpha: 0.12),
borderRadius: BorderRadius.circular(12),
),
child: Icon(icon, color: color, size: 28),
@ -191,7 +191,7 @@ class _ChatDataManagementScreenState extends State<ChatDataManagementScreen> {
return Expanded(
child: Column(
children: [
Icon(icon, size: 18, color: AppTheme.brightNavy.withOpacity(0.6)),
Icon(icon, size: 18, color: AppTheme.brightNavy.withValues(alpha: 0.6)),
const SizedBox(height: 4),
Text(
value,
@ -318,7 +318,7 @@ class _ChatDataManagementScreenState extends State<ChatDataManagementScreen> {
label: Text(_isRestoring ? 'Restoring...' : 'Restore Backup'),
style: OutlinedButton.styleFrom(
foregroundColor: AppTheme.royalPurple,
side: BorderSide(color: AppTheme.royalPurple.withOpacity(0.4)),
side: BorderSide(color: AppTheme.royalPurple.withValues(alpha: 0.4)),
padding: const EdgeInsets.symmetric(vertical: 14),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(12),
@ -483,7 +483,7 @@ class _ChatDataManagementScreenState extends State<ChatDataManagementScreen> {
padding: const EdgeInsets.symmetric(vertical: 12),
child: Row(
children: [
Icon(icon, color: color.withOpacity(0.7), size: 20),
Icon(icon, color: color.withValues(alpha: 0.7), size: 20),
const SizedBox(width: 12),
Expanded(
child: Column(

View file

@ -226,7 +226,7 @@ class _SecureChatScreenState extends State<SecureChatScreen>
width: 36,
height: 36,
decoration: BoxDecoration(
color: AppTheme.queenPink.withOpacity(0.3),
color: AppTheme.queenPink.withValues(alpha: 0.3),
borderRadius: BorderRadius.circular(10),
),
child: widget.conversation.otherUserAvatarUrl != null
@ -559,7 +559,7 @@ class _SecureChatScreenState extends State<SecureChatScreen>
key: ValueKey(_activeDateLabel),
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
decoration: BoxDecoration(
color: AppTheme.cardSurface.withOpacity(0.95),
color: AppTheme.cardSurface.withValues(alpha: 0.95),
borderRadius: BorderRadius.circular(12),
),
child: Text(
@ -639,7 +639,7 @@ class _SecureChatScreenState extends State<SecureChatScreen>
width: 80,
height: 80,
decoration: BoxDecoration(
color: AppTheme.queenPink.withOpacity(0.3),
color: AppTheme.queenPink.withValues(alpha: 0.3),
shape: BoxShape.circle,
),
child: Icon(
@ -714,7 +714,7 @@ class _SecureChatScreenState extends State<SecureChatScreen>
height: 4,
margin: const EdgeInsets.symmetric(vertical: 12),
decoration: BoxDecoration(
color: AppTheme.navyBlue.withOpacity(0.2),
color: AppTheme.navyBlue.withValues(alpha: 0.2),
borderRadius: BorderRadius.circular(2),
),
),
@ -897,9 +897,9 @@ class _SecureChatScreenState extends State<SecureChatScreen>
Container(
padding: const EdgeInsets.all(12),
decoration: BoxDecoration(
color: AppTheme.error.withOpacity(0.1),
color: AppTheme.error.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(8),
border: Border.all(color: AppTheme.error.withOpacity(0.3)),
border: Border.all(color: AppTheme.error.withValues(alpha: 0.3)),
),
child: Text(
'⚠️ THIS ACTION CANNOT BE UNDONE\n\nBoth you and the other person will lose all messages permanently.',

View file

@ -263,7 +263,7 @@ class _ImageFiltersScreenState extends ConsumerState<ImageFiltersScreen> {
return Container(
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 2),
decoration: BoxDecoration(
color: AppTheme.egyptianBlue.withOpacity(0.1),
color: AppTheme.egyptianBlue.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(4),
),
child: Text(
@ -282,9 +282,9 @@ class _ImageFiltersScreenState extends ConsumerState<ImageFiltersScreen> {
return Container(
padding: const EdgeInsets.all(AppTheme.spacingMd),
decoration: BoxDecoration(
color: AppTheme.royalPurple.withOpacity(0.1),
color: AppTheme.royalPurple.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(12),
border: Border.all(color: AppTheme.royalPurple.withOpacity(0.3)),
border: Border.all(color: AppTheme.royalPurple.withValues(alpha: 0.3)),
),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
@ -306,7 +306,7 @@ class _ImageFiltersScreenState extends ConsumerState<ImageFiltersScreen> {
'Filters are applied to images before upload. Custom filters can be created from presets. '
'The original image is preserved - filters only affect the uploaded version.',
style: AppTheme.textTheme.bodySmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.8),
color: AppTheme.navyText.withValues(alpha: 0.8),
),
),
const SizedBox(height: AppTheme.spacingMd),
@ -329,7 +329,7 @@ class _ImageFiltersScreenState extends ConsumerState<ImageFiltersScreen> {
child: Text(
tip,
style: AppTheme.textTheme.bodySmall?.copyWith(
color: AppTheme.navyText.withOpacity(0.7),
color: AppTheme.navyText.withValues(alpha: 0.7),
),
),
),

View file

@ -708,12 +708,12 @@ class _NotificationBannerState extends State<_NotificationBanner>
color: AppTheme.cardSurface,
borderRadius: BorderRadius.circular(20),
border: Border.all(
color: AppTheme.egyptianBlue.withOpacity(0.1),
color: AppTheme.egyptianBlue.withValues(alpha: 0.1),
width: 1.5,
),
boxShadow: [
BoxShadow(
color: AppTheme.brightNavy.withOpacity(0.12),
color: AppTheme.brightNavy.withValues(alpha: 0.12),
blurRadius: 20,
offset: const Offset(0, 8),
),
@ -726,7 +726,7 @@ class _NotificationBannerState extends State<_NotificationBanner>
width: 44,
height: 44,
decoration: BoxDecoration(
color: AppTheme.brightNavy.withOpacity(0.1),
color: AppTheme.brightNavy.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(12),
),
child: Center(
@ -758,7 +758,7 @@ class _NotificationBannerState extends State<_NotificationBanner>
Text(
notification!.body!,
style: TextStyle(
color: AppTheme.textSecondary.withOpacity(0.8),
color: AppTheme.textSecondary.withValues(alpha: 0.8),
fontSize: 13,
height: 1.3,
),
@ -776,7 +776,7 @@ class _NotificationBannerState extends State<_NotificationBanner>
padding: const EdgeInsets.all(8),
child: Icon(
Icons.close,
color: AppTheme.textSecondary.withOpacity(0.3),
color: AppTheme.textSecondary.withValues(alpha: 0.3),
size: 18,
),
),

View file

@ -38,7 +38,7 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
color: AppTheme.scaffoldBg,
borderRadius: const BorderRadius.vertical(top: Radius.circular(30)),
border: Border.all(
color: AppTheme.egyptianBlue.withOpacity(0.1),
color: AppTheme.egyptianBlue.withValues(alpha: 0.1),
width: 1.5,
),
),
@ -51,7 +51,7 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
width: 40,
height: 5,
decoration: BoxDecoration(
color: AppTheme.egyptianBlue.withOpacity(0.2),
color: AppTheme.egyptianBlue.withValues(alpha: 0.2),
borderRadius: BorderRadius.circular(10),
),
),
@ -96,7 +96,7 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
Text(
"Protect the harmony of your Circle.",
style: AppTheme.labelSmall.copyWith(
color: AppTheme.navyText.withOpacity(0.6),
color: AppTheme.navyText.withValues(alpha: 0.6),
),
),
const SizedBox(height: 32),
@ -167,9 +167,9 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
style: TextStyle(color: AppTheme.navyText),
decoration: InputDecoration(
hintText: "Briefly describe the violation...",
hintStyle: TextStyle(color: AppTheme.navyText.withOpacity(0.4)),
hintStyle: TextStyle(color: AppTheme.navyText.withValues(alpha: 0.4)),
filled: true,
fillColor: AppTheme.egyptianBlue.withOpacity(0.05),
fillColor: AppTheme.egyptianBlue.withValues(alpha: 0.05),
border: OutlineInputBorder(
borderRadius: BorderRadius.circular(15),
borderSide: BorderSide.none,
@ -212,7 +212,7 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
child: Text(
"This will structurally separate you and @${widget.post.author?.handle ?? 'this user'}. You will both be invisible to each other across Sojorn.",
textAlign: TextAlign.center,
style: AppTheme.bodyMedium.copyWith(color: AppTheme.navyText.withOpacity(0.7)),
style: AppTheme.bodyMedium.copyWith(color: AppTheme.navyText.withValues(alpha: 0.7)),
),
),
const SizedBox(height: 32),
@ -250,14 +250,14 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
child: Container(
padding: const EdgeInsets.all(16),
decoration: BoxDecoration(
color: (color ?? AppTheme.navyText).withOpacity(0.05),
color: (color ?? AppTheme.navyText).withValues(alpha: 0.05),
borderRadius: BorderRadius.circular(15),
border: Border.all(color: (color ?? AppTheme.navyText).withOpacity(0.1)),
border: Border.all(color: (color ?? AppTheme.navyText).withValues(alpha: 0.1)),
),
child: Row(
children: [
if (icon != null) ...[
Icon(icon, color: color ?? AppTheme.navyText.withOpacity(0.7), size: 28),
Icon(icon, color: color ?? AppTheme.navyText.withValues(alpha: 0.7), size: 28),
const SizedBox(width: 16),
],
Expanded(
@ -266,11 +266,11 @@ class _SanctuarySheetState extends State<SanctuarySheet> {
children: [
Text(title, style: AppTheme.labelLarge.copyWith(color: color ?? AppTheme.navyText)),
const SizedBox(height: 2),
Text(subtitle, style: AppTheme.labelSmall.copyWith(color: (color ?? AppTheme.navyText).withOpacity(0.6))),
Text(subtitle, style: AppTheme.labelSmall.copyWith(color: (color ?? AppTheme.navyText).withValues(alpha: 0.6))),
],
),
),
Icon(Icons.chevron_right, color: AppTheme.egyptianBlue.withOpacity(0.3)),
Icon(Icons.chevron_right, color: AppTheme.egyptianBlue.withValues(alpha: 0.3)),
],
),
),

View file

@ -271,7 +271,7 @@ class _PrivacyIcon extends StatelessWidget {
child: Icon(
icon,
size: 12,
color: AppTheme.navyText.withOpacity(0.6),
color: AppTheme.navyText.withValues(alpha: 0.6),
),
);
}

View file

@ -358,7 +358,7 @@ class _sojornSwipeablePostState extends ConsumerState<sojornSwipeablePost> {
width: double.infinity,
height: double.infinity,
loadingBuilder: (context) => Container(
color: _getTrustColor().withOpacity(0.3),
color: _getTrustColor().withValues(alpha: 0.3),
),
errorBuilder: (context, error, stackTrace) =>
_buildGradientBackground(palette),
@ -467,7 +467,7 @@ class _sojornSwipeablePostState extends ConsumerState<sojornSwipeablePost> {
child: Icon(
_privacyIcon(_visibility),
size: 12,
color: palette.subTextColor.withOpacity(0.8),
color: palette.subTextColor.withValues(alpha: 0.8),
),
),
],

View file

@ -193,7 +193,7 @@ class _ChatBubbleWidgetState extends State<ChatBubbleWidget>
Widget _buildAvatar() {
final background =
widget.isMe ? AppTheme.navyBlue.withOpacity(0.12) : AppTheme.queenPink;
widget.isMe ? AppTheme.navyBlue.withValues(alpha: 0.12) : AppTheme.queenPink;
final border = widget.isMe ? AppTheme.navyBlue : AppTheme.brightNavy;
final textColor = widget.isMe ? AppTheme.navyBlue : AppTheme.navyBlue;
final label = (widget.avatarInitial ?? '?').trim();
@ -225,7 +225,7 @@ class _ChatBubbleWidgetState extends State<ChatBubbleWidget>
decoration: BoxDecoration(
color: background,
borderRadius: BorderRadius.circular(10),
border: Border.all(color: border.withOpacity(0.3), width: 1),
border: Border.all(color: border.withValues(alpha: 0.3), width: 1),
),
alignment: Alignment.center,
child: Text(
@ -242,8 +242,8 @@ class _ChatBubbleWidgetState extends State<ChatBubbleWidget>
final background = widget.isMe ? AppTheme.navyBlue : AppTheme.cardSurface;
final textColor = widget.isMe ? AppTheme.white : AppTheme.navyText;
final borderColor = widget.isMe
? AppTheme.navyBlue.withOpacity(0.35)
: AppTheme.navyBlue.withOpacity(0.08);
? AppTheme.navyBlue.withValues(alpha: 0.35)
: AppTheme.navyBlue.withValues(alpha: 0.08);
final parsed = _parseReply(widget.message);
final attachments = _extractAttachments(parsed?.body ?? widget.message);
@ -276,7 +276,7 @@ class _ChatBubbleWidgetState extends State<ChatBubbleWidget>
border: Border.all(color: borderColor, width: 1),
boxShadow: [
BoxShadow(
color: AppTheme.navyBlue.withOpacity(0.08),
color: AppTheme.navyBlue.withValues(alpha: 0.08),
blurRadius: 10,
offset: const Offset(0, 4),
),
@ -297,7 +297,7 @@ class _ChatBubbleWidgetState extends State<ChatBubbleWidget>
border: Border.all(
color: widget.isMe
? SojornColors.basicWhite.withValues(alpha: 0.12)
: AppTheme.navyBlue.withOpacity(0.08),
: AppTheme.navyBlue.withValues(alpha: 0.08),
),
),
child: Column(
@ -497,7 +497,7 @@ class _ChatBubbleWidgetState extends State<ChatBubbleWidget>
duration: const Duration(milliseconds: 150),
child: DecoratedBox(
decoration: BoxDecoration(
color: AppTheme.cardSurface.withOpacity(0.95),
color: AppTheme.cardSurface.withValues(alpha: 0.95),
borderRadius: BorderRadius.circular(16),
boxShadow: [
BoxShadow(
@ -602,7 +602,7 @@ class _VideoAttachment extends StatelessWidget {
border: Border.all(
color: isMine
? SojornColors.basicWhite.withValues(alpha: 0.2)
: AppTheme.navyBlue.withOpacity(0.1),
: AppTheme.navyBlue.withValues(alpha: 0.1),
),
),
child: ListTile(

View file

@ -201,7 +201,7 @@ class _ComposerWidgetState extends State<ComposerWidget>
color: AppTheme.cardSurface,
border: Border(
top: BorderSide(
color: AppTheme.navyBlue.withOpacity(0.1),
color: AppTheme.navyBlue.withValues(alpha: 0.1),
),
),
),
@ -241,7 +241,7 @@ class _ComposerWidgetState extends State<ComposerWidget>
color: SojornColors.basicWhite.withValues(alpha: 0.04),
borderRadius: BorderRadius.circular(18),
border: Border.all(
color: AppTheme.navyBlue.withOpacity(0.08),
color: AppTheme.navyBlue.withValues(alpha: 0.08),
),
),
child: Shortcuts(

View file

@ -100,7 +100,7 @@ class sojornButton extends StatelessWidget {
disabledBackgroundColor:
AppTheme.queenPinkLight, // Replaced AppTheme.surfaceVariant
disabledForegroundColor: AppTheme.navyText
.withOpacity(0.5), // Replaced AppTheme.textDisabled
.withValues(alpha: 0.5), // Replaced AppTheme.textDisabled
elevation: 0,
shadowColor: SojornColors.transparent,
padding: _getPadding(),
@ -121,7 +121,7 @@ class sojornButton extends StatelessWidget {
disabledBackgroundColor:
AppTheme.queenPinkLight, // Replaced AppTheme.surfaceVariant
disabledForegroundColor: AppTheme.navyText
.withOpacity(0.5), // Replaced AppTheme.textDisabled
.withValues(alpha: 0.5), // Replaced AppTheme.textDisabled
elevation: 0,
shadowColor: SojornColors.transparent,
padding: _getPadding(),
@ -139,10 +139,10 @@ class sojornButton extends StatelessWidget {
style: OutlinedButton.styleFrom(
foregroundColor: AppTheme.brightNavy, // Replaced AppTheme.accent
disabledForegroundColor: AppTheme.navyText
.withOpacity(0.5), // Replaced AppTheme.textDisabled
.withValues(alpha: 0.5), // Replaced AppTheme.textDisabled
side: BorderSide(
color: isDisabled
? AppTheme.egyptianBlue.withOpacity(0.5)
? AppTheme.egyptianBlue.withValues(alpha: 0.5)
: AppTheme.egyptianBlue, // Replaced borderSubtle and border
width: 1,
),
@ -161,7 +161,7 @@ class sojornButton extends StatelessWidget {
style: TextButton.styleFrom(
foregroundColor: AppTheme.brightNavy, // Replaced AppTheme.accent
disabledForegroundColor: AppTheme.navyText
.withOpacity(0.5), // Replaced AppTheme.textDisabled
.withValues(alpha: 0.5), // Replaced AppTheme.textDisabled
padding: _getPadding(),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(

View file

@ -225,13 +225,13 @@ class _sojornPostCardState extends ConsumerState<sojornPostCard> {
margin: const EdgeInsets.symmetric(horizontal: 4),
padding: const EdgeInsets.symmetric(horizontal: 10, vertical: 4),
decoration: BoxDecoration(
color: AppTheme.ksuPurple.withOpacity(0.1),
color: AppTheme.ksuPurple.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(12),
),
child: Text("!", style: TextStyle(
fontSize: 18,
fontWeight: FontWeight.w900,
color: AppTheme.royalPurple.withOpacity(0.7),
color: AppTheme.royalPurple.withValues(alpha: 0.7),
)),
),
),

View file

@ -98,7 +98,7 @@ class sojornRichText extends StatelessWidget {
fontWeight: FontWeight.w600, // Bolder for "Awake" feel
decoration:
isMention || isHashtag ? null : TextDecoration.underline,
decorationColor: linkColor.withOpacity(0.7),
decorationColor: linkColor.withValues(alpha: 0.7),
) ??
TextStyle(
color: linkColor,

View file

@ -300,7 +300,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
borderRadius: const BorderRadius.vertical(top: Radius.circular(24)),
border: Border(
bottom: BorderSide(
color: AppTheme.egyptianBlue.withOpacity(0.1),
color: AppTheme.egyptianBlue.withValues(alpha: 0.1),
width: 1
),
),
@ -313,7 +313,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
height: 4,
margin: const EdgeInsets.only(top: 12, bottom: 4),
decoration: BoxDecoration(
color: AppTheme.navyBlue.withOpacity(0.1),
color: AppTheme.navyBlue.withValues(alpha: 0.1),
borderRadius: BorderRadius.circular(2),
),
),
@ -414,11 +414,11 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(Icons.chat_bubble_outline, size: 48, color: AppTheme.navyBlue.withOpacity(0.1)),
Icon(Icons.chat_bubble_outline, size: 48, color: AppTheme.navyBlue.withValues(alpha: 0.1)),
const SizedBox(height: 16),
Text(
'No messages yet',
style: GoogleFonts.inter(color: AppTheme.textSecondary.withOpacity(0.5), fontSize: 16),
style: GoogleFonts.inter(color: AppTheme.textSecondary.withValues(alpha: 0.5), fontSize: 16),
),
],
),
@ -479,7 +479,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
if (_replyingToNode != null)
Container(
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),
color: AppTheme.brightNavy.withOpacity(0.05),
color: AppTheme.brightNavy.withValues(alpha: 0.05),
child: Row(
children: [
Icon(Icons.reply, size: 14, color: AppTheme.brightNavy),
@ -503,7 +503,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
padding: EdgeInsets.fromLTRB(16, 12, 16, MediaQuery.of(context).viewInsets.bottom + 16),
decoration: BoxDecoration(
color: AppTheme.cardSurface,
border: Border(top: BorderSide(color: AppTheme.egyptianBlue.withOpacity(0.1))),
border: Border(top: BorderSide(color: AppTheme.egyptianBlue.withValues(alpha: 0.1))),
),
child: Row(
children: [
@ -513,7 +513,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
decoration: BoxDecoration(
color: AppTheme.scaffoldBg,
borderRadius: BorderRadius.circular(16),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.2)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.2)),
),
child: TextField(
controller: _commentController,
@ -521,7 +521,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
style: TextStyle(color: AppTheme.textPrimary),
decoration: InputDecoration(
hintText: _replyingToNode != null ? 'Type your reply...' : 'Add a comment...',
hintStyle: TextStyle(color: AppTheme.textSecondary.withOpacity(0.5)),
hintStyle: TextStyle(color: AppTheme.textSecondary.withValues(alpha: 0.5)),
border: InputBorder.none,
),
),
@ -537,7 +537,7 @@ class _TraditionalQuipsSheetState extends ConsumerState<TraditionalQuipsSheet> {
borderRadius: BorderRadius.circular(12),
boxShadow: [
BoxShadow(
color: AppTheme.brightNavy.withOpacity(0.2),
color: AppTheme.brightNavy.withValues(alpha: 0.2),
blurRadius: 8,
offset: const Offset(0, 4),
),
@ -601,10 +601,10 @@ class _CommentTile extends StatelessWidget {
child: Container(
padding: const EdgeInsets.all(14),
decoration: BoxDecoration(
color: isSelected ? AppTheme.brightNavy.withOpacity(0.08) : AppTheme.cardSurface,
color: isSelected ? AppTheme.brightNavy.withValues(alpha: 0.08) : AppTheme.cardSurface,
borderRadius: BorderRadius.circular(20),
border: Border.all(
color: isSelected ? AppTheme.brightNavy.withOpacity(0.3) : AppTheme.egyptianBlue.withOpacity(0.1),
color: isSelected ? AppTheme.brightNavy.withValues(alpha: 0.3) : AppTheme.egyptianBlue.withValues(alpha: 0.1),
width: isSelected ? 2 : 1,
),
boxShadow: [
@ -664,7 +664,7 @@ class _CommentTile extends StatelessWidget {
children: [
Text(
timeago.format(node.post.createdAt, locale: 'en_short'),
style: TextStyle(color: AppTheme.textSecondary.withOpacity(0.5), fontSize: 13),
style: TextStyle(color: AppTheme.textSecondary.withValues(alpha: 0.5), fontSize: 13),
),
const SizedBox(width: 24),
GestureDetector(
@ -706,7 +706,7 @@ class _CommentTile extends StatelessWidget {
icon: Icon(
node.post.isLiked == true ? Icons.favorite : Icons.favorite_border,
size: 20,
color: node.post.isLiked == true ? SojornColors.destructive : AppTheme.textSecondary.withOpacity(0.2),
color: node.post.isLiked == true ? SojornColors.destructive : AppTheme.textSecondary.withValues(alpha: 0.2),
),
onPressed: () => onReaction('❤️'),
visualDensity: VisualDensity.compact,
@ -714,7 +714,7 @@ class _CommentTile extends StatelessWidget {
if (node.post.likeCount != null && node.post.likeCount! > 0)
Text(
'${node.post.likeCount}',
style: TextStyle(color: AppTheme.textSecondary.withOpacity(0.6), fontSize: 13, fontWeight: FontWeight.w700),
style: TextStyle(color: AppTheme.textSecondary.withValues(alpha: 0.6), fontSize: 13, fontWeight: FontWeight.w700),
),
],
),
@ -730,9 +730,9 @@ class _CommentTile extends StatelessWidget {
width: 40,
height: 40,
decoration: BoxDecoration(
color: AppTheme.navyBlue.withOpacity(0.05),
color: AppTheme.navyBlue.withValues(alpha: 0.05),
borderRadius: BorderRadius.circular(20),
border: Border.all(color: AppTheme.egyptianBlue.withOpacity(0.1)),
border: Border.all(color: AppTheme.egyptianBlue.withValues(alpha: 0.1)),
),
child: author?.avatarUrl != null && author!.avatarUrl!.isNotEmpty
? ClipRRect(
@ -745,12 +745,12 @@ class _CommentTile extends StatelessWidget {
Widget _buildMenu(BuildContext context, bool isMyComment, bool isVideoAuthor) {
return PopupMenuButton<String>(
icon: Icon(Icons.more_horiz, size: 22, color: AppTheme.textSecondary.withOpacity(0.4)),
icon: Icon(Icons.more_horiz, size: 22, color: AppTheme.textSecondary.withValues(alpha: 0.4)),
padding: EdgeInsets.zero,
color: AppTheme.cardSurface,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(16),
side: BorderSide(color: AppTheme.egyptianBlue.withOpacity(0.1)),
side: BorderSide(color: AppTheme.egyptianBlue.withValues(alpha: 0.1)),
),
itemBuilder: (context) => [
if (isVideoAuthor)