mirror of
				https://github.com/immich-app/immich.git
				synced 2025-11-04 03:27:09 -05:00 
			
		
		
		
	Implemented a mechanism to extract the correct time zone from the GPS coordinate if presented in the file's EXIF, and to convert the timestamp to the correct UTC time so that the time will show correctly based on the mobile/web local time zone.
		
			
				
	
	
		
			32 lines
		
	
	
		
			813 B
		
	
	
	
		
			Dart
		
	
	
	
	
	
			
		
		
	
	
			32 lines
		
	
	
		
			813 B
		
	
	
	
		
			Dart
		
	
	
	
	
	
import 'package:easy_localization/easy_localization.dart';
 | 
						|
import 'package:flutter/material.dart';
 | 
						|
 | 
						|
class MonthlyTitleText extends StatelessWidget {
 | 
						|
  const MonthlyTitleText({
 | 
						|
    Key? key,
 | 
						|
    required this.isoDate,
 | 
						|
  }) : super(key: key);
 | 
						|
 | 
						|
  final String isoDate;
 | 
						|
 | 
						|
  @override
 | 
						|
  Widget build(BuildContext context) {
 | 
						|
    var monthTitleText = DateFormat("monthly_title_text_date_format".tr())
 | 
						|
        .format(DateTime.parse(isoDate).toLocal());
 | 
						|
 | 
						|
    return SliverToBoxAdapter(
 | 
						|
      child: Padding(
 | 
						|
        padding: const EdgeInsets.only(left: 12.0, top: 32),
 | 
						|
        child: Text(
 | 
						|
          monthTitleText,
 | 
						|
          style: TextStyle(
 | 
						|
            fontSize: 26,
 | 
						|
            fontWeight: FontWeight.bold,
 | 
						|
            color: Theme.of(context).textTheme.headline1?.color,
 | 
						|
          ),
 | 
						|
        ),
 | 
						|
      ),
 | 
						|
    );
 | 
						|
  }
 | 
						|
}
 |