forked from mirrors/gecko-dev
		
	Bug 1821468 - Improve cookie banner re-engagement dialog when titl is long
				
					
				
			This commit is contained in:
		
							parent
							
								
									4427f8a404
								
							
						
					
					
						commit
						1802511a9d
					
				
					 1 changed files with 19 additions and 26 deletions
				
			
		|  | @ -42,7 +42,7 @@ import org.mozilla.fenix.theme.defaultTypography | ||||||
| private fun CookieBannerReEngagementDialogComposePreview() { | private fun CookieBannerReEngagementDialogComposePreview() { | ||||||
|     FirefoxTheme { |     FirefoxTheme { | ||||||
|         CookieBannerReEngagementDialogCompose( |         CookieBannerReEngagementDialogCompose( | ||||||
|             dialogTitle = "Cookie banners begone!", |             dialogTitle = "Allow Firefox to reject cookie banners?", | ||||||
|             dialogText = |             dialogText = | ||||||
|             "Automatically reject cookie requests, when possible. Otherwise, " + |             "Automatically reject cookie requests, when possible. Otherwise, " + | ||||||
|                 "accept all cookies to dismiss cookie banners.", |                 "accept all cookies to dismiss cookie banners.", | ||||||
|  | @ -82,35 +82,28 @@ fun CookieBannerReEngagementDialogCompose( | ||||||
|                 .background(color = FirefoxTheme.colors.layer1), |                 .background(color = FirefoxTheme.colors.layer1), | ||||||
|         ) { |         ) { | ||||||
|             Column { |             Column { | ||||||
|                 Row( |                 IconButton( | ||||||
|                     modifier = Modifier |                     modifier = Modifier | ||||||
|                         .fillMaxWidth(), |                         .align(Alignment.End) | ||||||
|                     verticalAlignment = Alignment.CenterVertically, |                         .size(48.dp), | ||||||
|                     horizontalArrangement = Arrangement.SpaceBetween, |                     onClick = onCloseButtonClicked, | ||||||
|                 ) { |                 ) { | ||||||
|                     Text( |                     Icon( | ||||||
|                         modifier = Modifier.padding( |                         painter = painterResource(R.drawable.mozac_ic_close), | ||||||
|                             top = 24.dp, |                         contentDescription = stringResource(R.string.content_description_close_button), | ||||||
|                             start = 24.dp, |                         tint = FirefoxTheme.colors.iconPrimary, | ||||||
|                             end = 24.dp, |  | ||||||
|                             bottom = 8.dp, |  | ||||||
|                         ), |  | ||||||
|                         color = FirefoxTheme.colors.textPrimary, |  | ||||||
|                         text = dialogTitle, |  | ||||||
|                         style = defaultTypography.headline7, |  | ||||||
|                     ) |                     ) | ||||||
|                     IconButton( |  | ||||||
|                         modifier = Modifier |  | ||||||
|                             .size(48.dp), |  | ||||||
|                         onClick = onCloseButtonClicked, |  | ||||||
|                     ) { |  | ||||||
|                         Icon( |  | ||||||
|                             painter = painterResource(R.drawable.mozac_ic_close), |  | ||||||
|                             contentDescription = stringResource(R.string.content_description_close_button), |  | ||||||
|                             tint = FirefoxTheme.colors.iconPrimary, |  | ||||||
|                         ) |  | ||||||
|                     } |  | ||||||
|                 } |                 } | ||||||
|  |                 Text( | ||||||
|  |                     modifier = Modifier.padding( | ||||||
|  |                         start = 24.dp, | ||||||
|  |                         end = 24.dp, | ||||||
|  |                         bottom = 8.dp, | ||||||
|  |                     ), | ||||||
|  |                     color = FirefoxTheme.colors.textPrimary, | ||||||
|  |                     text = dialogTitle, | ||||||
|  |                     style = defaultTypography.headline7, | ||||||
|  |                 ) | ||||||
|                 Text( |                 Text( | ||||||
|                     modifier = Modifier.padding(horizontal = 24.dp), |                     modifier = Modifier.padding(horizontal = 24.dp), | ||||||
|                     color = FirefoxTheme.colors.textPrimary, |                     color = FirefoxTheme.colors.textPrimary, | ||||||
|  |  | ||||||
		Loading…
	
		Reference in a new issue
	
	 Arturo Mejia
						Arturo Mejia