Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
b4148eb5
Unverified
Commit
b4148eb5
authored
Jun 10, 2021
by
Aneesh Rao
Committed by
GitHub
Jun 10, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add maskable icons to improve lighthouse score (#83182)
parent
fe7e1614
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
36 additions
and
3 deletions
+36
-3
update_packages.dart
packages/flutter_tools/lib/src/commands/update_packages.dart
+1
-1
pubspec.yaml
packages/flutter_tools/pubspec.yaml
+2
-2
Icon-maskable-192.png.img.tmpl
...ls/templates/app/web/icons/Icon-maskable-192.png.img.tmpl
+0
-0
Icon-maskable-512.png.img.tmpl
...ls/templates/app/web/icons/Icon-maskable-512.png.img.tmpl
+0
-0
manifest.json.tmpl
packages/flutter_tools/templates/app/web/manifest.json.tmpl
+12
-0
template_manifest.json
packages/flutter_tools/templates/template_manifest.json
+2
-0
create_test.dart
...tter_tools/test/commands.shard/permeable/create_test.dart
+19
-0
No files found.
packages/flutter_tools/lib/src/commands/update_packages.dart
View file @
b4148eb5
...
...
@@ -27,7 +27,7 @@ const Map<String, String> _kManuallyPinnedDependencies = <String, String>{
// Therefore, we control the version of flutter_gallery_assets so that
// existing tests do not fail when the package has a new version.
'flutter_gallery_assets'
:
'^1.0.1'
,
'flutter_template_images'
:
'3.0.
0
'
,
// Must always exactly match flutter_tools template.
'flutter_template_images'
:
'3.0.
1
'
,
// Must always exactly match flutter_tools template.
// DART TEAM OWNED NNBD DEPS
'archive'
:
'">=3.0.0-nullsafety.0"'
,
'async'
:
'">=2.5.0-nullsafety.3"'
,
...
...
packages/flutter_tools/pubspec.yaml
View file @
b4148eb5
...
...
@@ -17,7 +17,7 @@ dependencies:
coverage
:
1.0.3
crypto
:
3.0.1
file
:
6.1.1
flutter_template_images
:
3.0.
0
flutter_template_images
:
3.0.
1
html
:
0.15.0
http
:
0.13.3
intl
:
0.17.0
...
...
@@ -110,4 +110,4 @@ dartdoc:
# Exclude this package from the hosted API docs.
nodoc
:
true
# PUBSPEC CHECKSUM:
3695
# PUBSPEC CHECKSUM:
2996
packages/flutter_tools/templates/app/web/icons/Icon-maskable-192.png.img.tmpl
0 → 100644
View file @
b4148eb5
packages/flutter_tools/templates/app/web/icons/Icon-maskable-512.png.img.tmpl
0 → 100644
View file @
b4148eb5
packages/flutter_tools/templates/app/web/manifest.json.tmpl
View file @
b4148eb5
...
...
@@ -18,6 +18,18 @@
"src": "icons/Icon-512.png",
"sizes": "512x512",
"type": "image/png"
},
{
"src": "icons/Icon-maskable-192.png",
"sizes": "192x192",
"type": "image/png",
"purpose": "maskable"
},
{
"src": "icons/Icon-maskable-512.png",
"sizes": "512x512",
"type": "image/png",
"purpose": "maskable"
}
]
}
packages/flutter_tools/templates/template_manifest.json
View file @
b4148eb5
...
...
@@ -119,6 +119,8 @@
"templates/app/web/favicon.png.copy.tmpl"
,
"templates/app/web/icons/Icon-192.png.copy.tmpl"
,
"templates/app/web/icons/Icon-512.png.copy.tmpl"
,
"templates/app/web/icons/Icon-maskable-192.png.img.tmpl"
,
"templates/app/web/icons/Icon-maskable-512.png.img.tmpl"
,
"templates/app/web/index.html.tmpl"
,
"templates/app/web/manifest.json.tmpl"
,
"templates/app/windows.tmpl/.gitignore"
,
...
...
packages/flutter_tools/test/commands.shard/permeable/create_test.dart
View file @
b4148eb5
...
...
@@ -1062,6 +1062,25 @@ void main() {
Logger:
()
=>
logger
,
});
testUsingContext
(
'app creates maskable icons for web'
,
()
async
{
Cache
.
flutterRoot
=
'../..'
;
final
CreateCommand
command
=
CreateCommand
();
final
CommandRunner
<
void
>
runner
=
createTestCommandRunner
(
command
);
await
runner
.
run
(<
String
>[
'create'
,
'--no-pub'
,
'--platforms=web'
,
projectDir
.
path
,
]);
final
Directory
iconsDir
=
projectDir
.
childDirectory
(
'web'
).
childDirectory
(
'icons'
);
expect
(
iconsDir
.
childFile
(
'Icon-maskable-192.png'
),
exists
);
expect
(
iconsDir
.
childFile
(
'Icon-maskable-512.png'
),
exists
);
});
testUsingContext
(
'plugin uses new platform schema'
,
()
async
{
Cache
.
flutterRoot
=
'../..'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment