1
0
mirror of https://github.com/flutter/samples.git synced 2026-03-31 00:33:02 +00:00

Deps update, utilize super.key (#1265)

* Deps update, utilize `super.key`

* `flutter format`
This commit is contained in:
Brett Morgan
2022-05-13 12:31:56 -07:00
committed by GitHub
parent 52ef797b9a
commit 58bc5d7a58
244 changed files with 449 additions and 500 deletions

View File

@@ -108,7 +108,7 @@ class Sample {
var screenshotUrl = screenshots.first.url;
var prefix = path.dirname(screenshotUrl);
var filename = path.basenameWithoutExtension(screenshotUrl);
return path.join(prefix, filename + '_thumb.png');
return path.join(prefix, '${filename}_thumb.png');
}
String get searchAttributes {
@@ -155,7 +155,7 @@ class Sample {
if (description.length < 64) {
return description;
}
return description.substring(0, 64) + '...';
return '${description.substring(0, 64)}...';
}
}

View File

@@ -69,12 +69,12 @@ String searchQueryFromParams(Map<String, String> params) {
if (params.containsKey('type')) {
if (buf.isNotEmpty) buf.write(' ');
var value = params['type'];
if (value != null) buf.write('type:' + value);
if (value != null) buf.write('type:$value');
}
if (params.containsKey('platform')) {
if (buf.isNotEmpty) buf.write(' ');
var value = params['platform'];
if (value != null) buf.write('platform:' + value);
if (value != null) buf.write('platform:$value');
}
return buf.toString();

View File

@@ -5,7 +5,7 @@
import 'dart:convert';
String indent(String content, int spaces) =>
LineSplitter.split(content).join('\n' + ' ' * spaces);
LineSplitter.split(content).join('\n${' ' * spaces}');
String kebabCase(String input) => _fixCase(input, '-');