π End-to-end encrypted cloud for everything.
Dart 2faandroidauthye2eeencryptionend-to-end-encryptionfluttergolanggoogle-photosgoogle-photos-alternativeiosopensourcephotosprivacyprivacy-toolstypescriptzero-knowledge
Align legacy kit PDF code block and listing icon
Neeraj Gupta0554c232da53
diff --git a/mobile/apps/locker/assets/2.0x/legacy_kit_favourite_circle.png b/mobile/apps/locker/assets/2.0x/legacy_kit_favourite_circle.pngnew file mode 100644index 0000000000..d9f344459dBinary files /dev/null and b/mobile/apps/locker/assets/2.0x/legacy_kit_favourite_circle.png differdiff --git a/mobile/apps/locker/assets/3.0x/legacy_kit_favourite_circle.png b/mobile/apps/locker/assets/3.0x/legacy_kit_favourite_circle.pngnew file mode 100644index 0000000000..a072a8fe2aBinary files /dev/null and b/mobile/apps/locker/assets/3.0x/legacy_kit_favourite_circle.png differdiff --git a/mobile/apps/locker/assets/legacy_kit_favourite_circle.png b/mobile/apps/locker/assets/legacy_kit_favourite_circle.pngnew file mode 100644index 0000000000..de8fce53fdBinary files /dev/null and b/mobile/apps/locker/assets/legacy_kit_favourite_circle.png differdiff --git a/mobile/packages/legacy/lib/pages/emergency_page.dart b/mobile/packages/legacy/lib/pages/emergency_page.dartindex 06164c1c9d..c7d39f14db 100644--- a/mobile/packages/legacy/lib/pages/emergency_page.dart+++ b/mobile/packages/legacy/lib/pages/emergency_page.dart@@ -537,8 +537,7 @@ class _EmergencyPageState extends State<EmergencyPage> {),),leadingIconSize: 36,- leadingIconWidget:- _LegacyKitLeadingIcon(color: colorScheme.primary700),+ leadingIconWidget: const _LegacyKitLeadingIcon(),menuItemColor: cardColor,singleBorderRadius: 20,trailingIcon: Icons.chevron_right,@@ -1040,79 +1039,21 @@ class _FullLegacyEmptyState extends StatelessWidget {}class _LegacyKitLeadingIcon extends StatelessWidget {- final Color color;-- const _LegacyKitLeadingIcon({required this.color});+ const _LegacyKitLeadingIcon();@overrideWidget build(BuildContext context) {return Center(- child: CustomPaint(- size: const Size.square(18),- painter: _LegacyKitLeadingIconPainter(color),+ child: Image.asset(+ "assets/legacy_kit_favourite_circle.png",+ width: 18,+ height: 18,+ fit: BoxFit.contain,),);}}-class _LegacyKitLeadingIconPainter extends CustomPainter {- final Color color;-- const _LegacyKitLeadingIconPainter(this.color);-- @override- void paint(Canvas canvas, Size size) {- final scale = size.width / 18;- canvas.save();- canvas.scale(scale);-- final strokePaint = Paint()- ..color = color- ..style = PaintingStyle.stroke- ..strokeWidth = 1.8- ..strokeCap = StrokeCap.round- ..strokeJoin = StrokeJoin.round;-- final filePath = Path()- ..moveTo(3.5, 2.5)- ..lineTo(10.2, 2.5)- ..lineTo(14.5, 6.8)- ..lineTo(14.5, 15.5)- ..lineTo(3.5, 15.5)- ..close();- canvas.drawPath(filePath, strokePaint);-- final foldPath = Path()- ..moveTo(10.2, 2.5)- ..lineTo(10.2, 6.8)- ..lineTo(14.5, 6.8);- canvas.drawPath(foldPath, strokePaint);-- final heartPath = Path()- ..moveTo(13.5, 16)- ..cubicTo(13.1, 15.7, 10, 13.8, 10, 11.5)- ..cubicTo(10, 10.3, 10.8, 9.4, 12, 9.4)- ..cubicTo(12.6, 9.4, 13.1, 9.7, 13.5, 10.2)- ..cubicTo(13.9, 9.7, 14.4, 9.4, 15, 9.4)- ..cubicTo(16.2, 9.4, 17, 10.3, 17, 11.5)- ..cubicTo(17, 13.8, 13.9, 15.7, 13.5, 16)- ..close();-- canvas.drawPath(- heartPath,- Paint()- ..color = color- ..style = PaintingStyle.fill,- );- canvas.restore();- }-- @override- bool shouldRepaint(_LegacyKitLeadingIconPainter oldDelegate) {- return color != oldDelegate.color;- }-}-class _WarningBanner extends StatelessWidget {final String text;diff --git a/mobile/packages/legacy/lib/services/legacy_kit_pdf_service.dart b/mobile/packages/legacy/lib/services/legacy_kit_pdf_service.dartindex ed9e6cbeee..38262bf7d2 100644--- a/mobile/packages/legacy/lib/services/legacy_kit_pdf_service.dart+++ b/mobile/packages/legacy/lib/services/legacy_kit_pdf_service.dart@@ -381,7 +381,7 @@ class LegacyKitPdfService {) {return pw.Container(width: 592,- height: 378,+ height: 429,padding: const pw.EdgeInsets.all(24),decoration: const pw.BoxDecoration(color: _dark,@@ -391,7 +391,7 @@ class LegacyKitPdfService {crossAxisAlignment: pw.CrossAxisAlignment.center,children: [pw.SizedBox(- width: 201,+ width: 242,child: pw.Column(crossAxisAlignment: pw.CrossAxisAlignment.center,children: [@@ -408,7 +408,7 @@ class LegacyKitPdfService {data: qrPayload,),),- pw.SizedBox(height: 8),+ pw.SizedBox(height: 6),pw.Text("OR",style: pw.TextStyle(@@ -421,11 +421,11 @@ class LegacyKitPdfService {"copy code text",style: const pw.TextStyle(color: _lightText, fontSize: 12),),- pw.SizedBox(height: 10),+ pw.SizedBox(height: 6),pw.Container(- width: 201,- height: 75,- padding: const pw.EdgeInsets.all(10),+ width: 242,+ height: 126,+ padding: const pw.EdgeInsets.all(12),decoration: pw.BoxDecoration(color: _green,border: pw.Border.all(@@ -442,9 +442,9 @@ class LegacyKitPdfService {textAlign: pw.TextAlign.center,style: pw.TextStyle(color: _background,- fontSize: copyCode.length > 220 ? 5.5 : 6.5,+ fontSize: 10,fontWeight: pw.FontWeight.bold,- lineSpacing: 1,+ lineSpacing: 3,),),),@@ -452,9 +452,9 @@ class LegacyKitPdfService {],),),- pw.SizedBox(width: 28),+ pw.Spacer(),pw.SizedBox(- width: 291,+ width: 266,child: pw.Column(mainAxisAlignment: pw.MainAxisAlignment.center,crossAxisAlignment: pw.CrossAxisAlignment.start,@@ -463,15 +463,22 @@ class LegacyKitPdfService {"1.","Get one other sheet. The other holders are:",extra: _holderChips(otherShares),+ bottomPadding: 24,),_instruction("2.","Go to ${displayRecoveryUrl(recoveryUrl)} and click Start recovery",+ bottomPadding: 24,+ ),+ _instruction(+ "3.",+ "Scan the QR codes from both sheets",+ bottomPadding: 24,),- _instruction("3.", "Scan the QR codes from both sheets"),_instruction("4.","Wait through the recovery period (if one is set).",+ bottomPadding: 24,),_instruction("5.",