open method
Future<void>
open({
- required SettingsPage page,
- List<
String> ? uiLocales, - ColorScheme? colorScheme,
- String? wechatRedirectURI,
Implementation
Future<void> open({
required SettingsPage page,
List<String>? uiLocales,
ColorScheme? colorScheme,
String? wechatRedirectURI,
}) async {
final Map<String, String> q = {};
final uiLocalesString = uiLocales?.join(" ") ?? "";
if (uiLocalesString != "") {
q["ui_locales"] = uiLocalesString;
}
if (colorScheme != null) {
q["x_color_scheme"] = colorScheme.name;
}
final url = Uri.parse(endpoint)
.replace(path: page.path, queryParameters: q)
.toString();
return openURL(url: url, wechatRedirectURI: wechatRedirectURI);
}