File tree Expand file tree Collapse file tree 4 files changed +29
-0
lines changed
Expand file tree Collapse file tree 4 files changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -60,6 +60,13 @@ class _CameraPageState extends ExamplePageState<CameraPage> {
6060 await GoogleMapsNavigator .showTermsAndConditionsDialog (
6161 'test_title' ,
6262 'test_company_name' ,
63+ uiParams: const TermsAndConditionsUIParams (
64+ backgroundColor: Color (0xFFF5F5F5 ),
65+ titleColor: Color (0xFF1976D2 ),
66+ mainTextColor: Color (0xFF212121 ),
67+ acceptButtonTextColor: Color (0xFF4CAF50 ),
68+ cancelButtonTextColor: Color (0xFFF44336 ),
69+ ),
6370 );
6471 }
6572 await GoogleMapsNavigator .initializeNavigationSession ();
Original file line number Diff line number Diff line change @@ -80,6 +80,13 @@ class _NavigationWithoutMapPageState
8080 companyName,
8181 shouldOnlyShowDriverAwarenessDisclaimer:
8282 shouldOnlyShowDriverAwarenessDisclaimer,
83+ uiParams: const TermsAndConditionsUIParams (
84+ backgroundColor: Color (0xFFECEFF1 ),
85+ titleColor: Color (0xFF01579B ),
86+ mainTextColor: Color (0xFF263238 ),
87+ acceptButtonTextColor: Color (0xFF00695C ),
88+ cancelButtonTextColor: Color (0xFFD32F2F ),
89+ ),
8390 );
8491 showMessage (accepted ? 'Terms accepted' : 'Terms not accepted' );
8592 setState (() {
Original file line number Diff line number Diff line change @@ -47,6 +47,13 @@ class _TurnByTurnPageState extends ExamplePageState<TurnByTurnPage> {
4747 await GoogleMapsNavigator .showTermsAndConditionsDialog (
4848 'test_title' ,
4949 'test_company_name' ,
50+ uiParams: const TermsAndConditionsUIParams (
51+ backgroundColor: Color (0xFFFAFAFA ),
52+ titleColor: Color (0xFF0D47A1 ),
53+ mainTextColor: Color (0xFF212121 ),
54+ acceptButtonTextColor: Color (0xFF1B5E20 ),
55+ cancelButtonTextColor: Color (0xFFB71C1C ),
56+ ),
5057 );
5158 }
5259
Original file line number Diff line number Diff line change 1414
1515// ignore_for_file: public_member_api_docs
1616
17+ import 'package:flutter/material.dart' ;
1718import 'package:google_navigation_flutter/google_navigation_flutter.dart' ;
1819
1920Future <bool > requestTermsAndConditionsAcceptance () async {
2021 return (await GoogleMapsNavigator .areTermsAccepted ()) ||
2122 (await GoogleMapsNavigator .showTermsAndConditionsDialog (
2223 'Example title' ,
2324 'Example company' ,
25+ uiParams: const TermsAndConditionsUIParams (
26+ backgroundColor: Color (0xFFFFFFFF ),
27+ titleColor: Color (0xFF1565C0 ),
28+ mainTextColor: Color (0xFF424242 ),
29+ acceptButtonTextColor: Color (0xFF2E7D32 ),
30+ cancelButtonTextColor: Color (0xFFC62828 ),
31+ ),
2432 ));
2533}
You can’t perform that action at this time.
0 commit comments