File tree Expand file tree Collapse file tree 2 files changed +9
-7
lines changed Expand file tree Collapse file tree 2 files changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -406,9 +406,13 @@ const String _iOSBrandingRightBottomConstraints = '''
406406
407407/// Web related templates
408408const String _webCss = '''
409+ html {
410+ height: 100%
411+ }
412+
409413body {
410- margin:0;
411- height:100%;
414+ margin: 0;
415+ min- height: 100%;
412416 background-color: [LIGHTBACKGROUNDCOLOR];
413417 [LIGHTBACKGROUNDIMAGE]
414418 background-size: 100% 100%;
@@ -465,11 +469,8 @@ const String _webCssDark = '''
465469
466470@media (prefers-color-scheme: dark) {
467471 body {
468- margin:0;
469- height:100%;
470472 background-color: [DARKBACKGROUNDCOLOR];
471473 [DARKBACKGROUNDIMAGE]
472- background-size: 100% 100%;
473474 }
474475}
475476''' ;
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ part of flutter_native_splash_cli;
44class _WebLaunchImageTemplate {
55 final String fileName;
66 final double pixelDensity;
7+
78 _WebLaunchImageTemplate ({required this .fileName, required this .pixelDensity});
89}
910
@@ -171,10 +172,10 @@ void _createSplashCss({
171172 required bool hasDarkImage,
172173}) {
173174 print ('[Web] Creating CSS' );
174- color ?? = '000000 ' ;
175+ color ?? = 'ffffff ' ;
175176 var cssContent = _webCss.replaceFirst ('[LIGHTBACKGROUNDCOLOR]' , '#$color ' );
176177 if (darkColor != null || darkBackgroundImage != null || hasDarkImage) {
177- darkColor ?? = color ;
178+ darkColor ?? = '000000' ;
178179 cssContent +=
179180 _webCssDark.replaceFirst ('[DARKBACKGROUNDCOLOR]' , '#$darkColor ' );
180181 }
You can’t perform that action at this time.
0 commit comments