toCustomTabsOptions method
Converts to CustomTabsOptions.
Implementation
@internal
CustomTabsOptions toCustomTabsOptions() {
CustomTabsColorSchemes? colorSchemes;
if (barColor != null || systemNavigationBarParams != null) {
colorSchemes = CustomTabsColorSchemes.defaults(
toolbarColor: barColor,
navigationBarColor: systemNavigationBarParams?.backgroundColor,
navigationBarDividerColor: systemNavigationBarParams?.dividerColor,
);
}
bool? urlBarHidingEnabled;
if (barFixingEnabled != null) {
urlBarHidingEnabled = !(barFixingEnabled!);
}
return CustomTabsOptions(
colorSchemes: colorSchemes,
urlBarHidingEnabled: urlBarHidingEnabled,
shareState: CustomTabsShareState.on,
showTitle: true,
browser: const CustomTabsBrowserConfiguration(
prefersDefaultBrowser: true,
),
);
}