File tree Expand file tree Collapse file tree 7 files changed +11
-20
lines changed Expand file tree Collapse file tree 7 files changed +11
-20
lines changed Original file line number Diff line number Diff line change 1
- import 'package:flutter/cupertino .dart' ;
1
+ import 'package:flutter/widgets .dart' ;
2
2
import 'package:flutter_module/presentation/styles/dimens.dart' ;
3
3
4
4
class PaddingStyles extends Padding {
Original file line number Diff line number Diff line change 1
1
import 'package:flutter/material.dart' ;
2
- import 'package:flutter/widgets.dart' ;
3
2
4
3
class TextStyles extends Text {
5
4
final String text;
Original file line number Diff line number Diff line change @@ -55,10 +55,10 @@ class CodeTextView extends StatelessWidget {
55
55
56
56
return SelectableText .rich (
57
57
TextSpan (
58
- style: const TextStyle (color: Colors .black),
58
+ style: TextStyle (color: Colors .black),
59
59
children: tokens.toSpans (
60
60
code.lines (maxLinesOrAll),
61
- const TextStyle (color: Colors .black),
61
+ TextStyle (color: Colors .black),
62
62
),
63
63
),
64
64
minLines: 1 ,
Original file line number Diff line number Diff line change @@ -57,9 +57,9 @@ class SnippetListTile extends HookWidget {
57
57
}
58
58
59
59
class SnippetDetailsBar extends StatelessWidget {
60
- SnippetDetailsBar ({Key ? key, required this .snippet}) : super (key: key);
60
+ const SnippetDetailsBar ({Key ? key, required this .snippet}) : super (key: key);
61
61
62
- Snippet snippet;
62
+ final Snippet snippet;
63
63
64
64
@override
65
65
Widget build (BuildContext context) {
@@ -70,7 +70,7 @@ class SnippetDetailsBar extends StatelessWidget {
70
70
TextStyles .regular (snippet.language? .raw ?? "" ),
71
71
const SizedBox (height: Dimens .m),
72
72
TextStyles .regular (snippet.owner? .login ?? "" ),
73
- TextStyles .helper (snippet.modifiedAt? .elapsedDateTime () ?? "" )
73
+ TextStyles .helper (snippet.modifiedAt? .toElapsedTime () ?? "" )
74
74
],
75
75
),
76
76
],
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ extension TextExtensions on String {
43
43
}
44
44
45
45
String lines (int count) {
46
- final split = const LineSplitter ().convert (this ?? "" );
46
+ final split = const LineSplitter ().convert (this );
47
47
48
48
if (split.length == 1 ) {
49
49
return split.first;
@@ -52,7 +52,7 @@ extension TextExtensions on String {
52
52
return split.join ('\n ' );
53
53
}
54
54
55
- String elapsedDateTime () {
55
+ String toElapsedTime () {
56
56
final customDate = CustomTimeElapsed (
57
57
minutes: 'minutes' ,
58
58
hours: 'hours' ,
Original file line number Diff line number Diff line change @@ -263,13 +263,6 @@ packages:
263
263
url: "https://pub.dartlang.org"
264
264
source: hosted
265
265
version: "4.0.1"
266
- intl:
267
- dependency: "direct main"
268
- description:
269
- name: intl
270
- url: "https://pub.dartlang.org"
271
- source: hosted
272
- version: "0.17.0"
273
266
io:
274
267
dependency: transitive
275
268
description:
@@ -449,14 +442,14 @@ packages:
449
442
name: source_map_stack_trace
450
443
url: "https://pub.dartlang.org"
451
444
source: hosted
452
- version: "2.1.0 "
445
+ version: "2.1.1 "
453
446
source_maps:
454
447
dependency: transitive
455
448
description:
456
449
name: source_maps
457
450
url: "https://pub.dartlang.org"
458
451
source: hosted
459
- version: "0.10.10 "
452
+ version: "0.10.11 "
460
453
source_span:
461
454
dependency: transitive
462
455
description:
@@ -584,5 +577,5 @@ packages:
584
577
source: hosted
585
578
version: "3.1.1"
586
579
sdks:
587
- dart: ">=2.17 .0 <3.0.0"
580
+ dart: ">=2.18 .0 <3.0.0"
588
581
flutter: ">=3.0.0"
Original file line number Diff line number Diff line change @@ -33,7 +33,6 @@ dependencies:
33
33
flutter_hooks : ^0.18.5+1
34
34
test : ^1.21.4
35
35
equatable : ^2.0.5
36
- intl : ^0.17.0
37
36
time_elapsed : ^0.2.6
38
37
39
38
dev_dependencies :
You can’t perform that action at this time.
0 commit comments