[webview_flutter_wkwebview] Adds support for `WKNavigationAction.navigationType` (#6863)

* add navigation type to navigation action

* version bump and export

* remove import

* ios unit test

* lint warning

* formatting

* add readme change to CHANGELOG

* remove unused method

* undo mocks change

* last mocks change

* mention pigeon dependency
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/CHANGELOG.md b/packages/webview_flutter/webview_flutter_wkwebview/CHANGELOG.md
index f859df5..7ae38d3 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/CHANGELOG.md
+++ b/packages/webview_flutter/webview_flutter_wkwebview/CHANGELOG.md
@@ -1,3 +1,9 @@
+## 3.0.1
+
+* Adds support for retrieving navigation type with internal class.
+* Updates README with details on contributing.
+* Updates pigeon dev dependency to `4.2.13`.
+
 ## 3.0.0
 
 * **BREAKING CHANGE** Updates platform implementation to `2.0.0` release of
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/README.md b/packages/webview_flutter/webview_flutter_wkwebview/README.md
index 2e3a87b..7935963 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/README.md
+++ b/packages/webview_flutter/webview_flutter_wkwebview/README.md
@@ -7,5 +7,23 @@
 This package is [endorsed][2], which means you can simply use `webview_flutter`
 normally. This package will be automatically included in your app when you do.
 
+## Contributing
+
+This package uses [pigeon][3] to generate the communication layer between Flutter and the host
+platform (iOS). The communication interface is defined in the `pigeons/web_kit.dart`
+file. After editing the communication interface regenerate the communication layer by running
+`flutter pub run pigeon --input pigeons/web_kit.dart`.
+
+Besides [pigeon][3] this package also uses [mockito][4] to generate mock objects for testing
+purposes. To generate the mock objects run the following command:
+```bash
+flutter pub run build_runner build --delete-conflicting-outputs
+```
+
+If you would like to contribute to the plugin, check out our [contribution guide][5].
+
 [1]: https://pub.dev/packages/webview_flutter
 [2]: https://flutter.dev/docs/development/packages-and-plugins/developing-packages#endorsed-federated-plugin
+[3]: https://pub.dev/packages/pigeon
+[4]: https://pub.dev/packages/mockito
+[5]: https://github.com/flutter/plugins/blob/main/CONTRIBUTING.md
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/example/ios/RunnerTests/FWFDataConvertersTests.m b/packages/webview_flutter/webview_flutter_wkwebview/example/ios/RunnerTests/FWFDataConvertersTests.m
index ca7d6f9..63e13f9 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/example/ios/RunnerTests/FWFDataConvertersTests.m
+++ b/packages/webview_flutter/webview_flutter_wkwebview/example/ios/RunnerTests/FWFDataConvertersTests.m
@@ -59,6 +59,8 @@
 - (void)testFWFWKNavigationActionDataFromNavigationAction {
   WKNavigationAction *mockNavigationAction = OCMClassMock([WKNavigationAction class]);
 
+  OCMStub([mockNavigationAction navigationType]).andReturn(WKNavigationTypeReload);
+
   NSURLRequest *request =
       [NSURLRequest requestWithURL:[NSURL URLWithString:@"https://www.flutter.dev/"]];
   OCMStub([mockNavigationAction request]).andReturn(request);
@@ -70,6 +72,7 @@
   FWFWKNavigationActionData *data =
       FWFWKNavigationActionDataFromNavigationAction(mockNavigationAction);
   XCTAssertNotNil(data);
+  XCTAssertEqual(data.navigationType, FWFWKNavigationTypeReload);
 }
 
 - (void)testFWFNSUrlRequestDataFromNSURLRequest {
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.h b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.h
index 2863048..605ed53 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.h
+++ b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.h
@@ -151,4 +151,13 @@
  */
 extern FWFWKScriptMessageData *FWFWKScriptMessageDataFromWKScriptMessage(WKScriptMessage *message);
 
+/**
+ * Converts a WKNavigationType to an FWFWKNavigationType.
+ *
+ * @param type The object containing information to create a FWFWKNavigationType
+ *
+ * @return A FWFWKNavigationType.
+ */
+extern FWFWKNavigationType FWFWKNavigationTypeFromWKNavigationType(WKNavigationType type);
+
 NS_ASSUME_NONNULL_END
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.m b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.m
index 8ecc9d3..528c956 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.m
+++ b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFDataConverters.m
@@ -162,7 +162,8 @@
     WKNavigationAction *action) {
   return [FWFWKNavigationActionData
       makeWithRequest:FWFNSUrlRequestDataFromNSURLRequest(action.request)
-          targetFrame:FWFWKFrameInfoDataFromWKFrameInfo(action.targetFrame)];
+          targetFrame:FWFWKFrameInfoDataFromWKFrameInfo(action.targetFrame)
+       navigationType:FWFWKNavigationTypeFromWKNavigationType(action.navigationType)];
 }
 
 FWFNSUrlRequestData *FWFNSUrlRequestDataFromNSURLRequest(NSURLRequest *request) {
@@ -218,3 +219,20 @@
 FWFWKScriptMessageData *FWFWKScriptMessageDataFromWKScriptMessage(WKScriptMessage *message) {
   return [FWFWKScriptMessageData makeWithName:message.name body:message.body];
 }
+
+FWFWKNavigationType FWFWKNavigationTypeFromWKNavigationType(WKNavigationType type) {
+  switch (type) {
+    case WKNavigationTypeLinkActivated:
+      return FWFWKNavigationTypeLinkActivated;
+    case WKNavigationTypeFormSubmitted:
+      return FWFWKNavigationTypeFormResubmitted;
+    case WKNavigationTypeBackForward:
+      return FWFWKNavigationTypeBackForward;
+    case WKNavigationTypeReload:
+      return FWFWKNavigationTypeReload;
+    case WKNavigationTypeFormResubmitted:
+      return FWFWKNavigationTypeFormResubmitted;
+    case WKNavigationTypeOther:
+      return FWFWKNavigationTypeOther;
+  }
+}
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.h b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.h
index 8cbd2c7..cc41f4c 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.h
+++ b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.h
@@ -1,7 +1,7 @@
 // Copyright 2013 The Flutter Authors. All rights reserved.
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
-// Autogenerated from Pigeon (v3.1.5), do not edit directly.
+// Autogenerated from Pigeon (v4.2.13), do not edit directly.
 // See also: https://pub.dev/packages/pigeon
 #import <Foundation/Foundation.h>
 @protocol FlutterBinaryMessenger;
@@ -11,6 +11,10 @@
 
 NS_ASSUME_NONNULL_BEGIN
 
+/// Mirror of NSKeyValueObservingOptions.
+///
+/// See
+/// https://developer.apple.com/documentation/foundation/nskeyvalueobservingoptions?language=objc.
 typedef NS_ENUM(NSUInteger, FWFNSKeyValueObservingOptionsEnum) {
   FWFNSKeyValueObservingOptionsEnumNewValue = 0,
   FWFNSKeyValueObservingOptionsEnumOldValue = 1,
@@ -18,6 +22,9 @@
   FWFNSKeyValueObservingOptionsEnumPriorNotification = 3,
 };
 
+/// Mirror of NSKeyValueChange.
+///
+/// See https://developer.apple.com/documentation/foundation/nskeyvaluechange?language=objc.
 typedef NS_ENUM(NSUInteger, FWFNSKeyValueChangeEnum) {
   FWFNSKeyValueChangeEnumSetting = 0,
   FWFNSKeyValueChangeEnumInsertion = 1,
@@ -25,6 +32,9 @@
   FWFNSKeyValueChangeEnumReplacement = 3,
 };
 
+/// Mirror of NSKeyValueChangeKey.
+///
+/// See https://developer.apple.com/documentation/foundation/nskeyvaluechangekey?language=objc.
 typedef NS_ENUM(NSUInteger, FWFNSKeyValueChangeKeyEnum) {
   FWFNSKeyValueChangeKeyEnumIndexes = 0,
   FWFNSKeyValueChangeKeyEnumKind = 1,
@@ -33,11 +43,18 @@
   FWFNSKeyValueChangeKeyEnumOldValue = 4,
 };
 
+/// Mirror of WKUserScriptInjectionTime.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuserscriptinjectiontime?language=objc.
 typedef NS_ENUM(NSUInteger, FWFWKUserScriptInjectionTimeEnum) {
   FWFWKUserScriptInjectionTimeEnumAtDocumentStart = 0,
   FWFWKUserScriptInjectionTimeEnumAtDocumentEnd = 1,
 };
 
+/// Mirror of WKAudiovisualMediaTypes.
+///
+/// See
+/// [WKAudiovisualMediaTypes](https://developer.apple.com/documentation/webkit/wkaudiovisualmediatypes?language=objc).
 typedef NS_ENUM(NSUInteger, FWFWKAudiovisualMediaTypeEnum) {
   FWFWKAudiovisualMediaTypeEnumNone = 0,
   FWFWKAudiovisualMediaTypeEnumAudio = 1,
@@ -45,6 +62,10 @@
   FWFWKAudiovisualMediaTypeEnumAll = 3,
 };
 
+/// Mirror of WKWebsiteDataTypes.
+///
+/// See
+/// https://developer.apple.com/documentation/webkit/wkwebsitedatarecord/data_store_record_types?language=objc.
 typedef NS_ENUM(NSUInteger, FWFWKWebsiteDataTypeEnum) {
   FWFWKWebsiteDataTypeEnumCookies = 0,
   FWFWKWebsiteDataTypeEnumMemoryCache = 1,
@@ -56,11 +77,17 @@
   FWFWKWebsiteDataTypeEnumIndexedDBDatabases = 7,
 };
 
+/// Mirror of WKNavigationActionPolicy.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationactionpolicy?language=objc.
 typedef NS_ENUM(NSUInteger, FWFWKNavigationActionPolicyEnum) {
   FWFWKNavigationActionPolicyEnumAllow = 0,
   FWFWKNavigationActionPolicyEnumCancel = 1,
 };
 
+/// Mirror of NSHTTPCookiePropertyKey.
+///
+/// See https://developer.apple.com/documentation/foundation/nshttpcookiepropertykey.
 typedef NS_ENUM(NSUInteger, FWFNSHttpCookiePropertyKeyEnum) {
   FWFNSHttpCookiePropertyKeyEnumComment = 0,
   FWFNSHttpCookiePropertyKeyEnumCommentUrl = 1,
@@ -78,6 +105,44 @@
   FWFNSHttpCookiePropertyKeyEnumVersion = 13,
 };
 
+/// An object that contains information about an action that causes navigation
+/// to occur.
+///
+/// Wraps
+/// [WKNavigationType](https://developer.apple.com/documentation/webkit/wknavigationaction?language=objc).
+typedef NS_ENUM(NSUInteger, FWFWKNavigationType) {
+  /// A link activation.
+  ///
+  /// See
+  /// https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypelinkactivated?language=objc.
+  FWFWKNavigationTypeLinkActivated = 0,
+  /// A request to submit a form.
+  ///
+  /// See
+  /// https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeformsubmitted?language=objc.
+  FWFWKNavigationTypeSubmitted = 1,
+  /// A request for the frame’s next or previous item.
+  ///
+  /// See
+  /// https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypebackforward?language=objc.
+  FWFWKNavigationTypeBackForward = 2,
+  /// A request to reload the webpage.
+  ///
+  /// See
+  /// https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypereload?language=objc.
+  FWFWKNavigationTypeReload = 3,
+  /// A request to resubmit a form.
+  ///
+  /// See
+  /// https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeformresubmitted?language=objc.
+  FWFWKNavigationTypeFormResubmitted = 4,
+  /// A navigation request that originates for some other reason.
+  ///
+  /// See
+  /// https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeother?language=objc.
+  FWFWKNavigationTypeOther = 5,
+};
+
 @class FWFNSKeyValueObservingOptionsEnumData;
 @class FWFNSKeyValueChangeKeyEnumData;
 @class FWFWKUserScriptInjectionTimeEnumData;
@@ -142,6 +207,9 @@
 @property(nonatomic, assign) FWFNSHttpCookiePropertyKeyEnum value;
 @end
 
+/// Mirror of NSURLRequest.
+///
+/// See https://developer.apple.com/documentation/foundation/nsurlrequest?language=objc.
 @interface FWFNSUrlRequestData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
@@ -155,6 +223,9 @@
 @property(nonatomic, strong) NSDictionary<NSString *, NSString *> *allHttpHeaderFields;
 @end
 
+/// Mirror of WKUserScript.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuserscript?language=objc.
 @interface FWFWKUserScriptData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
@@ -166,15 +237,23 @@
 @property(nonatomic, strong) NSNumber *isMainFrameOnly;
 @end
 
+/// Mirror of WKNavigationAction.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationaction.
 @interface FWFWKNavigationActionData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
 + (instancetype)makeWithRequest:(FWFNSUrlRequestData *)request
-                    targetFrame:(FWFWKFrameInfoData *)targetFrame;
+                    targetFrame:(FWFWKFrameInfoData *)targetFrame
+                 navigationType:(FWFWKNavigationType)navigationType;
 @property(nonatomic, strong) FWFNSUrlRequestData *request;
 @property(nonatomic, strong) FWFWKFrameInfoData *targetFrame;
+@property(nonatomic, assign) FWFWKNavigationType navigationType;
 @end
 
+/// Mirror of WKFrameInfo.
+///
+/// See https://developer.apple.com/documentation/webkit/wkframeinfo?language=objc.
 @interface FWFWKFrameInfoData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
@@ -182,6 +261,9 @@
 @property(nonatomic, strong) NSNumber *isMainFrame;
 @end
 
+/// Mirror of NSError.
+///
+/// See https://developer.apple.com/documentation/foundation/nserror?language=objc.
 @interface FWFNSErrorData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
@@ -193,6 +275,9 @@
 @property(nonatomic, copy) NSString *localizedDescription;
 @end
 
+/// Mirror of WKScriptMessage.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessage?language=objc.
 @interface FWFWKScriptMessageData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
@@ -201,6 +286,9 @@
 @property(nonatomic, strong) id body;
 @end
 
+/// Mirror of NSHttpCookieData.
+///
+/// See https://developer.apple.com/documentation/foundation/nshttpcookie?language=objc.
 @interface FWFNSHttpCookieData : NSObject
 /// `init` unavailable to enforce nonnull fields, see the `make` class method.
 - (instancetype)init NS_UNAVAILABLE;
@@ -213,6 +301,9 @@
 /// The codec used by FWFWKWebsiteDataStoreHostApi.
 NSObject<FlutterMessageCodec> *FWFWKWebsiteDataStoreHostApiGetCodec(void);
 
+/// Mirror of WKWebsiteDataStore.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebsitedatastore?language=objc.
 @protocol FWFWKWebsiteDataStoreHostApi
 - (void)createFromWebViewConfigurationWithIdentifier:(NSNumber *)identifier
                              configurationIdentifier:(NSNumber *)configurationIdentifier
@@ -233,6 +324,9 @@
 /// The codec used by FWFUIViewHostApi.
 NSObject<FlutterMessageCodec> *FWFUIViewHostApiGetCodec(void);
 
+/// Mirror of UIView.
+///
+/// See https://developer.apple.com/documentation/uikit/uiview?language=objc.
 @protocol FWFUIViewHostApi
 - (void)setBackgroundColorForViewWithIdentifier:(NSNumber *)identifier
                                         toValue:(nullable NSNumber *)value
@@ -248,6 +342,9 @@
 /// The codec used by FWFUIScrollViewHostApi.
 NSObject<FlutterMessageCodec> *FWFUIScrollViewHostApiGetCodec(void);
 
+/// Mirror of UIScrollView.
+///
+/// See https://developer.apple.com/documentation/uikit/uiscrollview?language=objc.
 @protocol FWFUIScrollViewHostApi
 - (void)createFromWebViewWithIdentifier:(NSNumber *)identifier
                       webViewIdentifier:(NSNumber *)webViewIdentifier
@@ -272,6 +369,9 @@
 /// The codec used by FWFWKWebViewConfigurationHostApi.
 NSObject<FlutterMessageCodec> *FWFWKWebViewConfigurationHostApiGetCodec(void);
 
+/// Mirror of WKWebViewConfiguration.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebviewconfiguration?language=objc.
 @protocol FWFWKWebViewConfigurationHostApi
 - (void)createWithIdentifier:(NSNumber *)identifier error:(FlutterError *_Nullable *_Nonnull)error;
 - (void)createFromWebViewWithIdentifier:(NSNumber *)identifier
@@ -300,6 +400,9 @@
 /// The codec used by FWFWKWebViewConfigurationFlutterApi.
 NSObject<FlutterMessageCodec> *FWFWKWebViewConfigurationFlutterApiGetCodec(void);
 
+/// Handles callbacks from an WKWebViewConfiguration instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebviewconfiguration?language=objc.
 @interface FWFWKWebViewConfigurationFlutterApi : NSObject
 - (instancetype)initWithBinaryMessenger:(id<FlutterBinaryMessenger>)binaryMessenger;
 - (void)createWithIdentifier:(NSNumber *)identifier
@@ -308,6 +411,9 @@
 /// The codec used by FWFWKUserContentControllerHostApi.
 NSObject<FlutterMessageCodec> *FWFWKUserContentControllerHostApiGetCodec(void);
 
+/// Mirror of WKUserContentController.
+///
+/// See https://developer.apple.com/documentation/webkit/wkusercontentcontroller?language=objc.
 @protocol FWFWKUserContentControllerHostApi
 - (void)createFromWebViewConfigurationWithIdentifier:(NSNumber *)identifier
                              configurationIdentifier:(NSNumber *)configurationIdentifier
@@ -338,6 +444,9 @@
 /// The codec used by FWFWKPreferencesHostApi.
 NSObject<FlutterMessageCodec> *FWFWKPreferencesHostApiGetCodec(void);
 
+/// Mirror of WKUserPreferences.
+///
+/// See https://developer.apple.com/documentation/webkit/wkpreferences?language=objc.
 @protocol FWFWKPreferencesHostApi
 - (void)createFromWebViewConfigurationWithIdentifier:(NSNumber *)identifier
                              configurationIdentifier:(NSNumber *)configurationIdentifier
@@ -353,6 +462,9 @@
 /// The codec used by FWFWKScriptMessageHandlerHostApi.
 NSObject<FlutterMessageCodec> *FWFWKScriptMessageHandlerHostApiGetCodec(void);
 
+/// Mirror of WKScriptMessageHandler.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessagehandler?language=objc.
 @protocol FWFWKScriptMessageHandlerHostApi
 - (void)createWithIdentifier:(NSNumber *)identifier error:(FlutterError *_Nullable *_Nonnull)error;
 @end
@@ -364,6 +476,9 @@
 /// The codec used by FWFWKScriptMessageHandlerFlutterApi.
 NSObject<FlutterMessageCodec> *FWFWKScriptMessageHandlerFlutterApiGetCodec(void);
 
+/// Handles callbacks from an WKScriptMessageHandler instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessagehandler?language=objc.
 @interface FWFWKScriptMessageHandlerFlutterApi : NSObject
 - (instancetype)initWithBinaryMessenger:(id<FlutterBinaryMessenger>)binaryMessenger;
 - (void)didReceiveScriptMessageForHandlerWithIdentifier:(NSNumber *)identifier
@@ -374,6 +489,9 @@
 /// The codec used by FWFWKNavigationDelegateHostApi.
 NSObject<FlutterMessageCodec> *FWFWKNavigationDelegateHostApiGetCodec(void);
 
+/// Mirror of WKNavigationDelegate.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationdelegate?language=objc.
 @protocol FWFWKNavigationDelegateHostApi
 - (void)createWithIdentifier:(NSNumber *)identifier error:(FlutterError *_Nullable *_Nonnull)error;
 @end
@@ -385,6 +503,9 @@
 /// The codec used by FWFWKNavigationDelegateFlutterApi.
 NSObject<FlutterMessageCodec> *FWFWKNavigationDelegateFlutterApiGetCodec(void);
 
+/// Handles callbacks from an WKNavigationDelegate instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationdelegate?language=objc.
 @interface FWFWKNavigationDelegateFlutterApi : NSObject
 - (instancetype)initWithBinaryMessenger:(id<FlutterBinaryMessenger>)binaryMessenger;
 - (void)didFinishNavigationForDelegateWithIdentifier:(NSNumber *)identifier
@@ -422,6 +543,9 @@
 /// The codec used by FWFNSObjectHostApi.
 NSObject<FlutterMessageCodec> *FWFNSObjectHostApiGetCodec(void);
 
+/// Mirror of NSObject.
+///
+/// See https://developer.apple.com/documentation/objectivec/nsobject.
 @protocol FWFNSObjectHostApi
 - (void)disposeObjectWithIdentifier:(NSNumber *)identifier
                               error:(FlutterError *_Nullable *_Nonnull)error;
@@ -443,6 +567,9 @@
 /// The codec used by FWFNSObjectFlutterApi.
 NSObject<FlutterMessageCodec> *FWFNSObjectFlutterApiGetCodec(void);
 
+/// Handles callbacks from an NSObject instance.
+///
+/// See https://developer.apple.com/documentation/objectivec/nsobject.
 @interface FWFNSObjectFlutterApi : NSObject
 - (instancetype)initWithBinaryMessenger:(id<FlutterBinaryMessenger>)binaryMessenger;
 - (void)observeValueForObjectWithIdentifier:(NSNumber *)identifier
@@ -457,6 +584,9 @@
 /// The codec used by FWFWKWebViewHostApi.
 NSObject<FlutterMessageCodec> *FWFWKWebViewHostApiGetCodec(void);
 
+/// Mirror of WKWebView.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebview?language=objc.
 @protocol FWFWKWebViewHostApi
 - (void)createWithIdentifier:(NSNumber *)identifier
      configurationIdentifier:(NSNumber *)configurationIdentifier
@@ -521,6 +651,9 @@
 /// The codec used by FWFWKUIDelegateHostApi.
 NSObject<FlutterMessageCodec> *FWFWKUIDelegateHostApiGetCodec(void);
 
+/// Mirror of WKUIDelegate.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuidelegate?language=objc.
 @protocol FWFWKUIDelegateHostApi
 - (void)createWithIdentifier:(NSNumber *)identifier error:(FlutterError *_Nullable *_Nonnull)error;
 @end
@@ -531,6 +664,9 @@
 /// The codec used by FWFWKUIDelegateFlutterApi.
 NSObject<FlutterMessageCodec> *FWFWKUIDelegateFlutterApiGetCodec(void);
 
+/// Handles callbacks from an WKUIDelegate instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuidelegate?language=objc.
 @interface FWFWKUIDelegateFlutterApi : NSObject
 - (instancetype)initWithBinaryMessenger:(id<FlutterBinaryMessenger>)binaryMessenger;
 - (void)onCreateWebViewForDelegateWithIdentifier:(NSNumber *)identifier
@@ -542,6 +678,9 @@
 /// The codec used by FWFWKHttpCookieStoreHostApi.
 NSObject<FlutterMessageCodec> *FWFWKHttpCookieStoreHostApiGetCodec(void);
 
+/// Mirror of WKHttpCookieStore.
+///
+/// See https://developer.apple.com/documentation/webkit/wkhttpcookiestore?language=objc.
 @protocol FWFWKHttpCookieStoreHostApi
 - (void)createFromWebsiteDataStoreWithIdentifier:(NSNumber *)identifier
                              dataStoreIdentifier:(NSNumber *)websiteDataStoreIdentifier
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.m b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.m
index 1068022..b2a365b 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.m
+++ b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFGeneratedWebKitApis.m
@@ -1,7 +1,7 @@
 // Copyright 2013 The Flutter Authors. All rights reserved.
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
-// Autogenerated from Pigeon (v3.1.5), do not edit directly.
+// Autogenerated from Pigeon (v4.2.13), do not edit directly.
 // See also: https://pub.dev/packages/pigeon
 #import "FWFGeneratedWebKitApis.h"
 #import <Flutter/Flutter.h>
@@ -10,23 +10,13 @@
 #error File requires ARC to be enabled.
 #endif
 
-static NSDictionary<NSString *, id> *wrapResult(id result, FlutterError *error) {
-  NSDictionary *errorDict = (NSDictionary *)[NSNull null];
+static NSArray *wrapResult(id result, FlutterError *error) {
   if (error) {
-    errorDict = @{
-      @"code" : (error.code ?: [NSNull null]),
-      @"message" : (error.message ?: [NSNull null]),
-      @"details" : (error.details ?: [NSNull null]),
-    };
+    return @[
+      error.code ?: [NSNull null], error.message ?: [NSNull null], error.details ?: [NSNull null]
+    ];
   }
-  return @{
-    @"result" : (result ?: [NSNull null]),
-    @"error" : errorDict,
-  };
-}
-static id GetNullableObject(NSDictionary *dict, id key) {
-  id result = dict[key];
-  return (result == [NSNull null]) ? nil : result;
+  return @[ result ?: [NSNull null] ];
 }
 static id GetNullableObjectAtIndex(NSArray *array, NSInteger key) {
   id result = array[key];
@@ -34,74 +24,74 @@
 }
 
 @interface FWFNSKeyValueObservingOptionsEnumData ()
-+ (FWFNSKeyValueObservingOptionsEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFNSKeyValueObservingOptionsEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFNSKeyValueObservingOptionsEnumData *)fromList:(NSArray *)list;
++ (nullable FWFNSKeyValueObservingOptionsEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFNSKeyValueChangeKeyEnumData ()
-+ (FWFNSKeyValueChangeKeyEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFNSKeyValueChangeKeyEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFNSKeyValueChangeKeyEnumData *)fromList:(NSArray *)list;
++ (nullable FWFNSKeyValueChangeKeyEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKUserScriptInjectionTimeEnumData ()
-+ (FWFWKUserScriptInjectionTimeEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKUserScriptInjectionTimeEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKUserScriptInjectionTimeEnumData *)fromList:(NSArray *)list;
++ (nullable FWFWKUserScriptInjectionTimeEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKAudiovisualMediaTypeEnumData ()
-+ (FWFWKAudiovisualMediaTypeEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKAudiovisualMediaTypeEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKAudiovisualMediaTypeEnumData *)fromList:(NSArray *)list;
++ (nullable FWFWKAudiovisualMediaTypeEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKWebsiteDataTypeEnumData ()
-+ (FWFWKWebsiteDataTypeEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKWebsiteDataTypeEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKWebsiteDataTypeEnumData *)fromList:(NSArray *)list;
++ (nullable FWFWKWebsiteDataTypeEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKNavigationActionPolicyEnumData ()
-+ (FWFWKNavigationActionPolicyEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKNavigationActionPolicyEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKNavigationActionPolicyEnumData *)fromList:(NSArray *)list;
++ (nullable FWFWKNavigationActionPolicyEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFNSHttpCookiePropertyKeyEnumData ()
-+ (FWFNSHttpCookiePropertyKeyEnumData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFNSHttpCookiePropertyKeyEnumData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFNSHttpCookiePropertyKeyEnumData *)fromList:(NSArray *)list;
++ (nullable FWFNSHttpCookiePropertyKeyEnumData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFNSUrlRequestData ()
-+ (FWFNSUrlRequestData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFNSUrlRequestData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFNSUrlRequestData *)fromList:(NSArray *)list;
++ (nullable FWFNSUrlRequestData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKUserScriptData ()
-+ (FWFWKUserScriptData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKUserScriptData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKUserScriptData *)fromList:(NSArray *)list;
++ (nullable FWFWKUserScriptData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKNavigationActionData ()
-+ (FWFWKNavigationActionData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKNavigationActionData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKNavigationActionData *)fromList:(NSArray *)list;
++ (nullable FWFWKNavigationActionData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKFrameInfoData ()
-+ (FWFWKFrameInfoData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKFrameInfoData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKFrameInfoData *)fromList:(NSArray *)list;
++ (nullable FWFWKFrameInfoData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFNSErrorData ()
-+ (FWFNSErrorData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFNSErrorData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFNSErrorData *)fromList:(NSArray *)list;
++ (nullable FWFNSErrorData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFWKScriptMessageData ()
-+ (FWFWKScriptMessageData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFWKScriptMessageData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFWKScriptMessageData *)fromList:(NSArray *)list;
++ (nullable FWFWKScriptMessageData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 @interface FWFNSHttpCookieData ()
-+ (FWFNSHttpCookieData *)fromMap:(NSDictionary *)dict;
-+ (nullable FWFNSHttpCookieData *)nullableFromMap:(NSDictionary *)dict;
-- (NSDictionary *)toMap;
++ (FWFNSHttpCookieData *)fromList:(NSArray *)list;
++ (nullable FWFNSHttpCookieData *)nullableFromList:(NSArray *)list;
+- (NSArray *)toList;
 @end
 
 @implementation FWFNSKeyValueObservingOptionsEnumData
@@ -111,19 +101,19 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFNSKeyValueObservingOptionsEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFNSKeyValueObservingOptionsEnumData *)fromList:(NSArray *)list {
   FWFNSKeyValueObservingOptionsEnumData *pigeonResult =
       [[FWFNSKeyValueObservingOptionsEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFNSKeyValueObservingOptionsEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFNSKeyValueObservingOptionsEnumData fromMap:dict] : nil;
++ (nullable FWFNSKeyValueObservingOptionsEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFNSKeyValueObservingOptionsEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -133,18 +123,18 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFNSKeyValueChangeKeyEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFNSKeyValueChangeKeyEnumData *)fromList:(NSArray *)list {
   FWFNSKeyValueChangeKeyEnumData *pigeonResult = [[FWFNSKeyValueChangeKeyEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFNSKeyValueChangeKeyEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFNSKeyValueChangeKeyEnumData fromMap:dict] : nil;
++ (nullable FWFNSKeyValueChangeKeyEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFNSKeyValueChangeKeyEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -155,19 +145,19 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFWKUserScriptInjectionTimeEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFWKUserScriptInjectionTimeEnumData *)fromList:(NSArray *)list {
   FWFWKUserScriptInjectionTimeEnumData *pigeonResult =
       [[FWFWKUserScriptInjectionTimeEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFWKUserScriptInjectionTimeEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKUserScriptInjectionTimeEnumData fromMap:dict] : nil;
++ (nullable FWFWKUserScriptInjectionTimeEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKUserScriptInjectionTimeEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -178,19 +168,19 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFWKAudiovisualMediaTypeEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFWKAudiovisualMediaTypeEnumData *)fromList:(NSArray *)list {
   FWFWKAudiovisualMediaTypeEnumData *pigeonResult =
       [[FWFWKAudiovisualMediaTypeEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFWKAudiovisualMediaTypeEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKAudiovisualMediaTypeEnumData fromMap:dict] : nil;
++ (nullable FWFWKAudiovisualMediaTypeEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKAudiovisualMediaTypeEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -200,18 +190,18 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFWKWebsiteDataTypeEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFWKWebsiteDataTypeEnumData *)fromList:(NSArray *)list {
   FWFWKWebsiteDataTypeEnumData *pigeonResult = [[FWFWKWebsiteDataTypeEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFWKWebsiteDataTypeEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKWebsiteDataTypeEnumData fromMap:dict] : nil;
++ (nullable FWFWKWebsiteDataTypeEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKWebsiteDataTypeEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -222,19 +212,19 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFWKNavigationActionPolicyEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFWKNavigationActionPolicyEnumData *)fromList:(NSArray *)list {
   FWFWKNavigationActionPolicyEnumData *pigeonResult =
       [[FWFWKNavigationActionPolicyEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFWKNavigationActionPolicyEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKNavigationActionPolicyEnumData fromMap:dict] : nil;
++ (nullable FWFWKNavigationActionPolicyEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKNavigationActionPolicyEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -245,19 +235,19 @@
   pigeonResult.value = value;
   return pigeonResult;
 }
-+ (FWFNSHttpCookiePropertyKeyEnumData *)fromMap:(NSDictionary *)dict {
++ (FWFNSHttpCookiePropertyKeyEnumData *)fromList:(NSArray *)list {
   FWFNSHttpCookiePropertyKeyEnumData *pigeonResult =
       [[FWFNSHttpCookiePropertyKeyEnumData alloc] init];
-  pigeonResult.value = [GetNullableObject(dict, @"value") integerValue];
+  pigeonResult.value = [GetNullableObjectAtIndex(list, 0) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFNSHttpCookiePropertyKeyEnumData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFNSHttpCookiePropertyKeyEnumData fromMap:dict] : nil;
++ (nullable FWFNSHttpCookiePropertyKeyEnumData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFNSHttpCookiePropertyKeyEnumData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"value" : @(self.value),
-  };
+- (NSArray *)toList {
+  return @[
+    @(self.value),
+  ];
 }
 @end
 
@@ -273,26 +263,26 @@
   pigeonResult.allHttpHeaderFields = allHttpHeaderFields;
   return pigeonResult;
 }
-+ (FWFNSUrlRequestData *)fromMap:(NSDictionary *)dict {
++ (FWFNSUrlRequestData *)fromList:(NSArray *)list {
   FWFNSUrlRequestData *pigeonResult = [[FWFNSUrlRequestData alloc] init];
-  pigeonResult.url = GetNullableObject(dict, @"url");
+  pigeonResult.url = GetNullableObjectAtIndex(list, 0);
   NSAssert(pigeonResult.url != nil, @"");
-  pigeonResult.httpMethod = GetNullableObject(dict, @"httpMethod");
-  pigeonResult.httpBody = GetNullableObject(dict, @"httpBody");
-  pigeonResult.allHttpHeaderFields = GetNullableObject(dict, @"allHttpHeaderFields");
+  pigeonResult.httpMethod = GetNullableObjectAtIndex(list, 1);
+  pigeonResult.httpBody = GetNullableObjectAtIndex(list, 2);
+  pigeonResult.allHttpHeaderFields = GetNullableObjectAtIndex(list, 3);
   NSAssert(pigeonResult.allHttpHeaderFields != nil, @"");
   return pigeonResult;
 }
-+ (nullable FWFNSUrlRequestData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFNSUrlRequestData fromMap:dict] : nil;
++ (nullable FWFNSUrlRequestData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFNSUrlRequestData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"url" : (self.url ?: [NSNull null]),
-    @"httpMethod" : (self.httpMethod ?: [NSNull null]),
-    @"httpBody" : (self.httpBody ?: [NSNull null]),
-    @"allHttpHeaderFields" : (self.allHttpHeaderFields ?: [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.url ?: [NSNull null]),
+    (self.httpMethod ?: [NSNull null]),
+    (self.httpBody ?: [NSNull null]),
+    (self.allHttpHeaderFields ?: [NSNull null]),
+  ];
 }
 @end
 
@@ -306,53 +296,57 @@
   pigeonResult.isMainFrameOnly = isMainFrameOnly;
   return pigeonResult;
 }
-+ (FWFWKUserScriptData *)fromMap:(NSDictionary *)dict {
++ (FWFWKUserScriptData *)fromList:(NSArray *)list {
   FWFWKUserScriptData *pigeonResult = [[FWFWKUserScriptData alloc] init];
-  pigeonResult.source = GetNullableObject(dict, @"source");
+  pigeonResult.source = GetNullableObjectAtIndex(list, 0);
   NSAssert(pigeonResult.source != nil, @"");
-  pigeonResult.injectionTime = [FWFWKUserScriptInjectionTimeEnumData
-      nullableFromMap:GetNullableObject(dict, @"injectionTime")];
-  pigeonResult.isMainFrameOnly = GetNullableObject(dict, @"isMainFrameOnly");
+  pigeonResult.injectionTime =
+      [FWFWKUserScriptInjectionTimeEnumData nullableFromList:(GetNullableObjectAtIndex(list, 1))];
+  pigeonResult.isMainFrameOnly = GetNullableObjectAtIndex(list, 2);
   NSAssert(pigeonResult.isMainFrameOnly != nil, @"");
   return pigeonResult;
 }
-+ (nullable FWFWKUserScriptData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKUserScriptData fromMap:dict] : nil;
++ (nullable FWFWKUserScriptData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKUserScriptData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"source" : (self.source ?: [NSNull null]),
-    @"injectionTime" : (self.injectionTime ? [self.injectionTime toMap] : [NSNull null]),
-    @"isMainFrameOnly" : (self.isMainFrameOnly ?: [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.source ?: [NSNull null]),
+    (self.injectionTime ? [self.injectionTime toList] : [NSNull null]),
+    (self.isMainFrameOnly ?: [NSNull null]),
+  ];
 }
 @end
 
 @implementation FWFWKNavigationActionData
 + (instancetype)makeWithRequest:(FWFNSUrlRequestData *)request
-                    targetFrame:(FWFWKFrameInfoData *)targetFrame {
+                    targetFrame:(FWFWKFrameInfoData *)targetFrame
+                 navigationType:(FWFWKNavigationType)navigationType {
   FWFWKNavigationActionData *pigeonResult = [[FWFWKNavigationActionData alloc] init];
   pigeonResult.request = request;
   pigeonResult.targetFrame = targetFrame;
+  pigeonResult.navigationType = navigationType;
   return pigeonResult;
 }
-+ (FWFWKNavigationActionData *)fromMap:(NSDictionary *)dict {
++ (FWFWKNavigationActionData *)fromList:(NSArray *)list {
   FWFWKNavigationActionData *pigeonResult = [[FWFWKNavigationActionData alloc] init];
-  pigeonResult.request = [FWFNSUrlRequestData nullableFromMap:GetNullableObject(dict, @"request")];
+  pigeonResult.request = [FWFNSUrlRequestData nullableFromList:(GetNullableObjectAtIndex(list, 0))];
   NSAssert(pigeonResult.request != nil, @"");
   pigeonResult.targetFrame =
-      [FWFWKFrameInfoData nullableFromMap:GetNullableObject(dict, @"targetFrame")];
+      [FWFWKFrameInfoData nullableFromList:(GetNullableObjectAtIndex(list, 1))];
   NSAssert(pigeonResult.targetFrame != nil, @"");
+  pigeonResult.navigationType = [GetNullableObjectAtIndex(list, 2) integerValue];
   return pigeonResult;
 }
-+ (nullable FWFWKNavigationActionData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKNavigationActionData fromMap:dict] : nil;
++ (nullable FWFWKNavigationActionData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKNavigationActionData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"request" : (self.request ? [self.request toMap] : [NSNull null]),
-    @"targetFrame" : (self.targetFrame ? [self.targetFrame toMap] : [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.request ? [self.request toList] : [NSNull null]),
+    (self.targetFrame ? [self.targetFrame toList] : [NSNull null]),
+    @(self.navigationType),
+  ];
 }
 @end
 
@@ -362,19 +356,19 @@
   pigeonResult.isMainFrame = isMainFrame;
   return pigeonResult;
 }
-+ (FWFWKFrameInfoData *)fromMap:(NSDictionary *)dict {
++ (FWFWKFrameInfoData *)fromList:(NSArray *)list {
   FWFWKFrameInfoData *pigeonResult = [[FWFWKFrameInfoData alloc] init];
-  pigeonResult.isMainFrame = GetNullableObject(dict, @"isMainFrame");
+  pigeonResult.isMainFrame = GetNullableObjectAtIndex(list, 0);
   NSAssert(pigeonResult.isMainFrame != nil, @"");
   return pigeonResult;
 }
-+ (nullable FWFWKFrameInfoData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKFrameInfoData fromMap:dict] : nil;
++ (nullable FWFWKFrameInfoData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKFrameInfoData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"isMainFrame" : (self.isMainFrame ?: [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.isMainFrame ?: [NSNull null]),
+  ];
 }
 @end
 
@@ -388,25 +382,25 @@
   pigeonResult.localizedDescription = localizedDescription;
   return pigeonResult;
 }
-+ (FWFNSErrorData *)fromMap:(NSDictionary *)dict {
++ (FWFNSErrorData *)fromList:(NSArray *)list {
   FWFNSErrorData *pigeonResult = [[FWFNSErrorData alloc] init];
-  pigeonResult.code = GetNullableObject(dict, @"code");
+  pigeonResult.code = GetNullableObjectAtIndex(list, 0);
   NSAssert(pigeonResult.code != nil, @"");
-  pigeonResult.domain = GetNullableObject(dict, @"domain");
+  pigeonResult.domain = GetNullableObjectAtIndex(list, 1);
   NSAssert(pigeonResult.domain != nil, @"");
-  pigeonResult.localizedDescription = GetNullableObject(dict, @"localizedDescription");
+  pigeonResult.localizedDescription = GetNullableObjectAtIndex(list, 2);
   NSAssert(pigeonResult.localizedDescription != nil, @"");
   return pigeonResult;
 }
-+ (nullable FWFNSErrorData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFNSErrorData fromMap:dict] : nil;
++ (nullable FWFNSErrorData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFNSErrorData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"code" : (self.code ?: [NSNull null]),
-    @"domain" : (self.domain ?: [NSNull null]),
-    @"localizedDescription" : (self.localizedDescription ?: [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.code ?: [NSNull null]),
+    (self.domain ?: [NSNull null]),
+    (self.localizedDescription ?: [NSNull null]),
+  ];
 }
 @end
 
@@ -417,21 +411,21 @@
   pigeonResult.body = body;
   return pigeonResult;
 }
-+ (FWFWKScriptMessageData *)fromMap:(NSDictionary *)dict {
++ (FWFWKScriptMessageData *)fromList:(NSArray *)list {
   FWFWKScriptMessageData *pigeonResult = [[FWFWKScriptMessageData alloc] init];
-  pigeonResult.name = GetNullableObject(dict, @"name");
+  pigeonResult.name = GetNullableObjectAtIndex(list, 0);
   NSAssert(pigeonResult.name != nil, @"");
-  pigeonResult.body = GetNullableObject(dict, @"body");
+  pigeonResult.body = GetNullableObjectAtIndex(list, 1);
   return pigeonResult;
 }
-+ (nullable FWFWKScriptMessageData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFWKScriptMessageData fromMap:dict] : nil;
++ (nullable FWFWKScriptMessageData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFWKScriptMessageData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"name" : (self.name ?: [NSNull null]),
-    @"body" : (self.body ?: [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.name ?: [NSNull null]),
+    (self.body ?: [NSNull null]),
+  ];
 }
 @end
 
@@ -443,22 +437,22 @@
   pigeonResult.propertyValues = propertyValues;
   return pigeonResult;
 }
-+ (FWFNSHttpCookieData *)fromMap:(NSDictionary *)dict {
++ (FWFNSHttpCookieData *)fromList:(NSArray *)list {
   FWFNSHttpCookieData *pigeonResult = [[FWFNSHttpCookieData alloc] init];
-  pigeonResult.propertyKeys = GetNullableObject(dict, @"propertyKeys");
+  pigeonResult.propertyKeys = GetNullableObjectAtIndex(list, 0);
   NSAssert(pigeonResult.propertyKeys != nil, @"");
-  pigeonResult.propertyValues = GetNullableObject(dict, @"propertyValues");
+  pigeonResult.propertyValues = GetNullableObjectAtIndex(list, 1);
   NSAssert(pigeonResult.propertyValues != nil, @"");
   return pigeonResult;
 }
-+ (nullable FWFNSHttpCookieData *)nullableFromMap:(NSDictionary *)dict {
-  return (dict) ? [FWFNSHttpCookieData fromMap:dict] : nil;
++ (nullable FWFNSHttpCookieData *)nullableFromList:(NSArray *)list {
+  return (list) ? [FWFNSHttpCookieData fromList:list] : nil;
 }
-- (NSDictionary *)toMap {
-  return @{
-    @"propertyKeys" : (self.propertyKeys ?: [NSNull null]),
-    @"propertyValues" : (self.propertyValues ?: [NSNull null]),
-  };
+- (NSArray *)toList {
+  return @[
+    (self.propertyKeys ?: [NSNull null]),
+    (self.propertyValues ?: [NSNull null]),
+  ];
 }
 @end
 
@@ -468,7 +462,7 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFWKWebsiteDataTypeEnumData fromMap:[self readValue]];
+      return [FWFWKWebsiteDataTypeEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -482,7 +476,7 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFWKWebsiteDataTypeEnumData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -501,8 +495,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKWebsiteDataStoreHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKWebsiteDataStoreHostApiCodecReaderWriter *readerWriter =
         [[FWFWKWebsiteDataStoreHostApiCodecReaderWriter alloc] init];
@@ -591,35 +585,9 @@
     }
   }
 }
-@interface FWFUIViewHostApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFUIViewHostApiCodecReader
-@end
-
-@interface FWFUIViewHostApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFUIViewHostApiCodecWriter
-@end
-
-@interface FWFUIViewHostApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFUIViewHostApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFUIViewHostApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFUIViewHostApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFUIViewHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFUIViewHostApiCodecReaderWriter *readerWriter =
-        [[FWFUIViewHostApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -671,35 +639,9 @@
     }
   }
 }
-@interface FWFUIScrollViewHostApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFUIScrollViewHostApiCodecReader
-@end
-
-@interface FWFUIScrollViewHostApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFUIScrollViewHostApiCodecWriter
-@end
-
-@interface FWFUIScrollViewHostApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFUIScrollViewHostApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFUIScrollViewHostApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFUIScrollViewHostApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFUIScrollViewHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFUIScrollViewHostApiCodecReaderWriter *readerWriter =
-        [[FWFUIScrollViewHostApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -809,7 +751,7 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFWKAudiovisualMediaTypeEnumData fromMap:[self readValue]];
+      return [FWFWKAudiovisualMediaTypeEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -823,7 +765,7 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFWKAudiovisualMediaTypeEnumData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -842,8 +784,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKWebViewConfigurationHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKWebViewConfigurationHostApiCodecReaderWriter *readerWriter =
         [[FWFWKWebViewConfigurationHostApiCodecReaderWriter alloc] init];
@@ -956,35 +898,9 @@
     }
   }
 }
-@interface FWFWKWebViewConfigurationFlutterApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFWKWebViewConfigurationFlutterApiCodecReader
-@end
-
-@interface FWFWKWebViewConfigurationFlutterApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFWKWebViewConfigurationFlutterApiCodecWriter
-@end
-
-@interface FWFWKWebViewConfigurationFlutterApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFWKWebViewConfigurationFlutterApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFWKWebViewConfigurationFlutterApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFWKWebViewConfigurationFlutterApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFWKWebViewConfigurationFlutterApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFWKWebViewConfigurationFlutterApiCodecReaderWriter *readerWriter =
-        [[FWFWKWebViewConfigurationFlutterApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -1019,10 +935,10 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFWKUserScriptData fromMap:[self readValue]];
+      return [FWFWKUserScriptData fromList:[self readValue]];
 
     case 129:
-      return [FWFWKUserScriptInjectionTimeEnumData fromMap:[self readValue]];
+      return [FWFWKUserScriptInjectionTimeEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -1036,10 +952,10 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFWKUserScriptData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKUserScriptInjectionTimeEnumData class]]) {
     [self writeByte:129];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -1058,8 +974,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKUserContentControllerHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKUserContentControllerHostApiCodecReaderWriter *readerWriter =
         [[FWFWKUserContentControllerHostApiCodecReaderWriter alloc] init];
@@ -1223,35 +1139,9 @@
     }
   }
 }
-@interface FWFWKPreferencesHostApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFWKPreferencesHostApiCodecReader
-@end
-
-@interface FWFWKPreferencesHostApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFWKPreferencesHostApiCodecWriter
-@end
-
-@interface FWFWKPreferencesHostApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFWKPreferencesHostApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFWKPreferencesHostApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFWKPreferencesHostApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFWKPreferencesHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFWKPreferencesHostApiCodecReaderWriter *readerWriter =
-        [[FWFWKPreferencesHostApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -1309,35 +1199,9 @@
     }
   }
 }
-@interface FWFWKScriptMessageHandlerHostApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFWKScriptMessageHandlerHostApiCodecReader
-@end
-
-@interface FWFWKScriptMessageHandlerHostApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFWKScriptMessageHandlerHostApiCodecWriter
-@end
-
-@interface FWFWKScriptMessageHandlerHostApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFWKScriptMessageHandlerHostApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFWKScriptMessageHandlerHostApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFWKScriptMessageHandlerHostApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFWKScriptMessageHandlerHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFWKScriptMessageHandlerHostApiCodecReaderWriter *readerWriter =
-        [[FWFWKScriptMessageHandlerHostApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -1371,7 +1235,7 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFWKScriptMessageData fromMap:[self readValue]];
+      return [FWFWKScriptMessageData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -1385,7 +1249,7 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFWKScriptMessageData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -1404,8 +1268,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKScriptMessageHandlerFlutterApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKScriptMessageHandlerFlutterApiCodecReaderWriter *readerWriter =
         [[FWFWKScriptMessageHandlerFlutterApiCodecReaderWriter alloc] init];
@@ -1446,35 +1310,9 @@
                  }];
 }
 @end
-@interface FWFWKNavigationDelegateHostApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFWKNavigationDelegateHostApiCodecReader
-@end
-
-@interface FWFWKNavigationDelegateHostApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFWKNavigationDelegateHostApiCodecWriter
-@end
-
-@interface FWFWKNavigationDelegateHostApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFWKNavigationDelegateHostApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFWKNavigationDelegateHostApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFWKNavigationDelegateHostApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFWKNavigationDelegateHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFWKNavigationDelegateHostApiCodecReaderWriter *readerWriter =
-        [[FWFWKNavigationDelegateHostApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -1508,19 +1346,19 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFNSErrorData fromMap:[self readValue]];
+      return [FWFNSErrorData fromList:[self readValue]];
 
     case 129:
-      return [FWFNSUrlRequestData fromMap:[self readValue]];
+      return [FWFNSUrlRequestData fromList:[self readValue]];
 
     case 130:
-      return [FWFWKFrameInfoData fromMap:[self readValue]];
+      return [FWFWKFrameInfoData fromList:[self readValue]];
 
     case 131:
-      return [FWFWKNavigationActionData fromMap:[self readValue]];
+      return [FWFWKNavigationActionData fromList:[self readValue]];
 
     case 132:
-      return [FWFWKNavigationActionPolicyEnumData fromMap:[self readValue]];
+      return [FWFWKNavigationActionPolicyEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -1534,19 +1372,19 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFNSErrorData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSUrlRequestData class]]) {
     [self writeByte:129];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKFrameInfoData class]]) {
     [self writeByte:130];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionData class]]) {
     [self writeByte:131];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionPolicyEnumData class]]) {
     [self writeByte:132];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -1565,8 +1403,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKNavigationDelegateFlutterApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKNavigationDelegateFlutterApiCodecReaderWriter *readerWriter =
         [[FWFWKNavigationDelegateFlutterApiCodecReaderWriter alloc] init];
@@ -1702,7 +1540,7 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFNSKeyValueObservingOptionsEnumData fromMap:[self readValue]];
+      return [FWFNSKeyValueObservingOptionsEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -1716,7 +1554,7 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFNSKeyValueObservingOptionsEnumData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -1735,8 +1573,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFNSObjectHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFNSObjectHostApiCodecReaderWriter *readerWriter =
         [[FWFNSObjectHostApiCodecReaderWriter alloc] init];
@@ -1835,46 +1673,46 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFNSErrorData fromMap:[self readValue]];
+      return [FWFNSErrorData fromList:[self readValue]];
 
     case 129:
-      return [FWFNSHttpCookieData fromMap:[self readValue]];
+      return [FWFNSHttpCookieData fromList:[self readValue]];
 
     case 130:
-      return [FWFNSHttpCookiePropertyKeyEnumData fromMap:[self readValue]];
+      return [FWFNSHttpCookiePropertyKeyEnumData fromList:[self readValue]];
 
     case 131:
-      return [FWFNSKeyValueChangeKeyEnumData fromMap:[self readValue]];
+      return [FWFNSKeyValueChangeKeyEnumData fromList:[self readValue]];
 
     case 132:
-      return [FWFNSKeyValueObservingOptionsEnumData fromMap:[self readValue]];
+      return [FWFNSKeyValueObservingOptionsEnumData fromList:[self readValue]];
 
     case 133:
-      return [FWFNSUrlRequestData fromMap:[self readValue]];
+      return [FWFNSUrlRequestData fromList:[self readValue]];
 
     case 134:
-      return [FWFWKAudiovisualMediaTypeEnumData fromMap:[self readValue]];
+      return [FWFWKAudiovisualMediaTypeEnumData fromList:[self readValue]];
 
     case 135:
-      return [FWFWKFrameInfoData fromMap:[self readValue]];
+      return [FWFWKFrameInfoData fromList:[self readValue]];
 
     case 136:
-      return [FWFWKNavigationActionData fromMap:[self readValue]];
+      return [FWFWKNavigationActionData fromList:[self readValue]];
 
     case 137:
-      return [FWFWKNavigationActionPolicyEnumData fromMap:[self readValue]];
+      return [FWFWKNavigationActionPolicyEnumData fromList:[self readValue]];
 
     case 138:
-      return [FWFWKScriptMessageData fromMap:[self readValue]];
+      return [FWFWKScriptMessageData fromList:[self readValue]];
 
     case 139:
-      return [FWFWKUserScriptData fromMap:[self readValue]];
+      return [FWFWKUserScriptData fromList:[self readValue]];
 
     case 140:
-      return [FWFWKUserScriptInjectionTimeEnumData fromMap:[self readValue]];
+      return [FWFWKUserScriptInjectionTimeEnumData fromList:[self readValue]];
 
     case 141:
-      return [FWFWKWebsiteDataTypeEnumData fromMap:[self readValue]];
+      return [FWFWKWebsiteDataTypeEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -1888,46 +1726,46 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFNSErrorData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSHttpCookieData class]]) {
     [self writeByte:129];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSHttpCookiePropertyKeyEnumData class]]) {
     [self writeByte:130];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSKeyValueChangeKeyEnumData class]]) {
     [self writeByte:131];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSKeyValueObservingOptionsEnumData class]]) {
     [self writeByte:132];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSUrlRequestData class]]) {
     [self writeByte:133];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKAudiovisualMediaTypeEnumData class]]) {
     [self writeByte:134];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKFrameInfoData class]]) {
     [self writeByte:135];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionData class]]) {
     [self writeByte:136];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionPolicyEnumData class]]) {
     [self writeByte:137];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKScriptMessageData class]]) {
     [self writeByte:138];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKUserScriptData class]]) {
     [self writeByte:139];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKUserScriptInjectionTimeEnumData class]]) {
     [self writeByte:140];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKWebsiteDataTypeEnumData class]]) {
     [self writeByte:141];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -1946,8 +1784,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFNSObjectFlutterApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFNSObjectFlutterApiCodecReaderWriter *readerWriter =
         [[FWFNSObjectFlutterApiCodecReaderWriter alloc] init];
@@ -2007,46 +1845,46 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFNSErrorData fromMap:[self readValue]];
+      return [FWFNSErrorData fromList:[self readValue]];
 
     case 129:
-      return [FWFNSHttpCookieData fromMap:[self readValue]];
+      return [FWFNSHttpCookieData fromList:[self readValue]];
 
     case 130:
-      return [FWFNSHttpCookiePropertyKeyEnumData fromMap:[self readValue]];
+      return [FWFNSHttpCookiePropertyKeyEnumData fromList:[self readValue]];
 
     case 131:
-      return [FWFNSKeyValueChangeKeyEnumData fromMap:[self readValue]];
+      return [FWFNSKeyValueChangeKeyEnumData fromList:[self readValue]];
 
     case 132:
-      return [FWFNSKeyValueObservingOptionsEnumData fromMap:[self readValue]];
+      return [FWFNSKeyValueObservingOptionsEnumData fromList:[self readValue]];
 
     case 133:
-      return [FWFNSUrlRequestData fromMap:[self readValue]];
+      return [FWFNSUrlRequestData fromList:[self readValue]];
 
     case 134:
-      return [FWFWKAudiovisualMediaTypeEnumData fromMap:[self readValue]];
+      return [FWFWKAudiovisualMediaTypeEnumData fromList:[self readValue]];
 
     case 135:
-      return [FWFWKFrameInfoData fromMap:[self readValue]];
+      return [FWFWKFrameInfoData fromList:[self readValue]];
 
     case 136:
-      return [FWFWKNavigationActionData fromMap:[self readValue]];
+      return [FWFWKNavigationActionData fromList:[self readValue]];
 
     case 137:
-      return [FWFWKNavigationActionPolicyEnumData fromMap:[self readValue]];
+      return [FWFWKNavigationActionPolicyEnumData fromList:[self readValue]];
 
     case 138:
-      return [FWFWKScriptMessageData fromMap:[self readValue]];
+      return [FWFWKScriptMessageData fromList:[self readValue]];
 
     case 139:
-      return [FWFWKUserScriptData fromMap:[self readValue]];
+      return [FWFWKUserScriptData fromList:[self readValue]];
 
     case 140:
-      return [FWFWKUserScriptInjectionTimeEnumData fromMap:[self readValue]];
+      return [FWFWKUserScriptInjectionTimeEnumData fromList:[self readValue]];
 
     case 141:
-      return [FWFWKWebsiteDataTypeEnumData fromMap:[self readValue]];
+      return [FWFWKWebsiteDataTypeEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -2060,46 +1898,46 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFNSErrorData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSHttpCookieData class]]) {
     [self writeByte:129];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSHttpCookiePropertyKeyEnumData class]]) {
     [self writeByte:130];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSKeyValueChangeKeyEnumData class]]) {
     [self writeByte:131];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSKeyValueObservingOptionsEnumData class]]) {
     [self writeByte:132];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSUrlRequestData class]]) {
     [self writeByte:133];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKAudiovisualMediaTypeEnumData class]]) {
     [self writeByte:134];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKFrameInfoData class]]) {
     [self writeByte:135];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionData class]]) {
     [self writeByte:136];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionPolicyEnumData class]]) {
     [self writeByte:137];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKScriptMessageData class]]) {
     [self writeByte:138];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKUserScriptData class]]) {
     [self writeByte:139];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKUserScriptInjectionTimeEnumData class]]) {
     [self writeByte:140];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKWebsiteDataTypeEnumData class]]) {
     [self writeByte:141];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -2118,8 +1956,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKWebViewHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKWebViewHostApiCodecReaderWriter *readerWriter =
         [[FWFWKWebViewHostApiCodecReaderWriter alloc] init];
@@ -2555,35 +2393,9 @@
     }
   }
 }
-@interface FWFWKUIDelegateHostApiCodecReader : FlutterStandardReader
-@end
-@implementation FWFWKUIDelegateHostApiCodecReader
-@end
-
-@interface FWFWKUIDelegateHostApiCodecWriter : FlutterStandardWriter
-@end
-@implementation FWFWKUIDelegateHostApiCodecWriter
-@end
-
-@interface FWFWKUIDelegateHostApiCodecReaderWriter : FlutterStandardReaderWriter
-@end
-@implementation FWFWKUIDelegateHostApiCodecReaderWriter
-- (FlutterStandardWriter *)writerWithData:(NSMutableData *)data {
-  return [[FWFWKUIDelegateHostApiCodecWriter alloc] initWithData:data];
-}
-- (FlutterStandardReader *)readerWithData:(NSData *)data {
-  return [[FWFWKUIDelegateHostApiCodecReader alloc] initWithData:data];
-}
-@end
-
 NSObject<FlutterMessageCodec> *FWFWKUIDelegateHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
-  dispatch_once(&sPred, ^{
-    FWFWKUIDelegateHostApiCodecReaderWriter *readerWriter =
-        [[FWFWKUIDelegateHostApiCodecReaderWriter alloc] init];
-    sSharedObject = [FlutterStandardMessageCodec codecWithReaderWriter:readerWriter];
-  });
+  sSharedObject = [FlutterStandardMessageCodec sharedInstance];
   return sSharedObject;
 }
 
@@ -2617,13 +2429,13 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFNSUrlRequestData fromMap:[self readValue]];
+      return [FWFNSUrlRequestData fromList:[self readValue]];
 
     case 129:
-      return [FWFWKFrameInfoData fromMap:[self readValue]];
+      return [FWFWKFrameInfoData fromList:[self readValue]];
 
     case 130:
-      return [FWFWKNavigationActionData fromMap:[self readValue]];
+      return [FWFWKNavigationActionData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -2637,13 +2449,13 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFNSUrlRequestData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKFrameInfoData class]]) {
     [self writeByte:129];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFWKNavigationActionData class]]) {
     [self writeByte:130];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -2662,8 +2474,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKUIDelegateFlutterApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKUIDelegateFlutterApiCodecReaderWriter *readerWriter =
         [[FWFWKUIDelegateFlutterApiCodecReaderWriter alloc] init];
@@ -2709,10 +2521,10 @@
 - (nullable id)readValueOfType:(UInt8)type {
   switch (type) {
     case 128:
-      return [FWFNSHttpCookieData fromMap:[self readValue]];
+      return [FWFNSHttpCookieData fromList:[self readValue]];
 
     case 129:
-      return [FWFNSHttpCookiePropertyKeyEnumData fromMap:[self readValue]];
+      return [FWFNSHttpCookiePropertyKeyEnumData fromList:[self readValue]];
 
     default:
       return [super readValueOfType:type];
@@ -2726,10 +2538,10 @@
 - (void)writeValue:(id)value {
   if ([value isKindOfClass:[FWFNSHttpCookieData class]]) {
     [self writeByte:128];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else if ([value isKindOfClass:[FWFNSHttpCookiePropertyKeyEnumData class]]) {
     [self writeByte:129];
-    [self writeValue:[value toMap]];
+    [self writeValue:[value toList]];
   } else {
     [super writeValue:value];
   }
@@ -2748,8 +2560,8 @@
 @end
 
 NSObject<FlutterMessageCodec> *FWFWKHttpCookieStoreHostApiGetCodec() {
-  static dispatch_once_t sPred = 0;
   static FlutterStandardMessageCodec *sSharedObject = nil;
+  static dispatch_once_t sPred = 0;
   dispatch_once(&sPred, ^{
     FWFWKHttpCookieStoreHostApiCodecReaderWriter *readerWriter =
         [[FWFWKHttpCookieStoreHostApiCodecReaderWriter alloc] init];
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFUIViewHostApi.m b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFUIViewHostApi.m
index a990561..1e168d0 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFUIViewHostApi.m
+++ b/packages/webview_flutter/webview_flutter_wkwebview/ios/Classes/FWFUIViewHostApi.m
@@ -25,7 +25,7 @@
 - (void)setBackgroundColorForViewWithIdentifier:(nonnull NSNumber *)identifier
                                         toValue:(nullable NSNumber *)color
                                           error:(FlutterError *_Nullable *_Nonnull)error {
-  if (!color) {
+  if (color == nil) {
     [[self viewForIdentifier:identifier] setBackgroundColor:nil];
   }
   int colorInt = color.intValue;
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/lib/src/common/web_kit.pigeon.dart b/packages/webview_flutter/webview_flutter_wkwebview/lib/src/common/web_kit.pigeon.dart
index 54bb301..26f215e 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/lib/src/common/web_kit.pigeon.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/lib/src/common/web_kit.pigeon.dart
@@ -1,16 +1,18 @@
 // Copyright 2013 The Flutter Authors. All rights reserved.
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
-// Autogenerated from Pigeon (v3.1.5), do not edit directly.
+// Autogenerated from Pigeon (v4.2.13), do not edit directly.
 // See also: https://pub.dev/packages/pigeon
-// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name
-// @dart = 2.12
+// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, prefer_null_aware_operators, omit_local_variable_types, unused_shown_name, unnecessary_import
 import 'dart:async';
-import 'dart:typed_data' show Uint8List, Int32List, Int64List, Float64List;
+import 'dart:typed_data' show Float64List, Int32List, Int64List, Uint8List;
 
-import 'package:flutter/foundation.dart' show WriteBuffer, ReadBuffer;
+import 'package:flutter/foundation.dart' show ReadBuffer, WriteBuffer;
 import 'package:flutter/services.dart';
 
+/// Mirror of NSKeyValueObservingOptions.
+///
+/// See https://developer.apple.com/documentation/foundation/nskeyvalueobservingoptions?language=objc.
 enum NSKeyValueObservingOptionsEnum {
   newValue,
   oldValue,
@@ -18,6 +20,9 @@
   priorNotification,
 }
 
+/// Mirror of NSKeyValueChange.
+///
+/// See https://developer.apple.com/documentation/foundation/nskeyvaluechange?language=objc.
 enum NSKeyValueChangeEnum {
   setting,
   insertion,
@@ -25,6 +30,9 @@
   replacement,
 }
 
+/// Mirror of NSKeyValueChangeKey.
+///
+/// See https://developer.apple.com/documentation/foundation/nskeyvaluechangekey?language=objc.
 enum NSKeyValueChangeKeyEnum {
   indexes,
   kind,
@@ -33,11 +41,17 @@
   oldValue,
 }
 
+/// Mirror of WKUserScriptInjectionTime.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuserscriptinjectiontime?language=objc.
 enum WKUserScriptInjectionTimeEnum {
   atDocumentStart,
   atDocumentEnd,
 }
 
+/// Mirror of WKAudiovisualMediaTypes.
+///
+/// See [WKAudiovisualMediaTypes](https://developer.apple.com/documentation/webkit/wkaudiovisualmediatypes?language=objc).
 enum WKAudiovisualMediaTypeEnum {
   none,
   audio,
@@ -45,6 +59,9 @@
   all,
 }
 
+/// Mirror of WKWebsiteDataTypes.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebsitedatarecord/data_store_record_types?language=objc.
 enum WKWebsiteDataTypeEnum {
   cookies,
   memoryCache,
@@ -56,11 +73,17 @@
   indexedDBDatabases,
 }
 
+/// Mirror of WKNavigationActionPolicy.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationactionpolicy?language=objc.
 enum WKNavigationActionPolicyEnum {
   allow,
   cancel,
 }
 
+/// Mirror of NSHTTPCookiePropertyKey.
+///
+/// See https://developer.apple.com/documentation/foundation/nshttpcookiepropertykey.
 enum NSHttpCookiePropertyKeyEnum {
   comment,
   commentUrl,
@@ -78,6 +101,42 @@
   version,
 }
 
+/// An object that contains information about an action that causes navigation
+/// to occur.
+///
+/// Wraps [WKNavigationType](https://developer.apple.com/documentation/webkit/wknavigationaction?language=objc).
+enum WKNavigationType {
+  /// A link activation.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypelinkactivated?language=objc.
+  linkActivated,
+
+  /// A request to submit a form.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeformsubmitted?language=objc.
+  submitted,
+
+  /// A request for the frame’s next or previous item.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypebackforward?language=objc.
+  backForward,
+
+  /// A request to reload the webpage.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypereload?language=objc.
+  reload,
+
+  /// A request to resubmit a form.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeformresubmitted?language=objc.
+  formResubmitted,
+
+  /// A navigation request that originates for some other reason.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeother?language=objc.
+  other,
+}
+
 class NSKeyValueObservingOptionsEnumData {
   NSKeyValueObservingOptionsEnumData({
     required this.value,
@@ -86,15 +145,15 @@
   NSKeyValueObservingOptionsEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static NSKeyValueObservingOptionsEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static NSKeyValueObservingOptionsEnumData decode(Object result) {
+    result as List<Object?>;
     return NSKeyValueObservingOptionsEnumData(
-      value: NSKeyValueObservingOptionsEnum.values[pigeonMap['value']! as int],
+      value: NSKeyValueObservingOptionsEnum.values[result[0]! as int],
     );
   }
 }
@@ -107,15 +166,15 @@
   NSKeyValueChangeKeyEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static NSKeyValueChangeKeyEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static NSKeyValueChangeKeyEnumData decode(Object result) {
+    result as List<Object?>;
     return NSKeyValueChangeKeyEnumData(
-      value: NSKeyValueChangeKeyEnum.values[pigeonMap['value']! as int],
+      value: NSKeyValueChangeKeyEnum.values[result[0]! as int],
     );
   }
 }
@@ -128,15 +187,15 @@
   WKUserScriptInjectionTimeEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static WKUserScriptInjectionTimeEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKUserScriptInjectionTimeEnumData decode(Object result) {
+    result as List<Object?>;
     return WKUserScriptInjectionTimeEnumData(
-      value: WKUserScriptInjectionTimeEnum.values[pigeonMap['value']! as int],
+      value: WKUserScriptInjectionTimeEnum.values[result[0]! as int],
     );
   }
 }
@@ -149,15 +208,15 @@
   WKAudiovisualMediaTypeEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static WKAudiovisualMediaTypeEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKAudiovisualMediaTypeEnumData decode(Object result) {
+    result as List<Object?>;
     return WKAudiovisualMediaTypeEnumData(
-      value: WKAudiovisualMediaTypeEnum.values[pigeonMap['value']! as int],
+      value: WKAudiovisualMediaTypeEnum.values[result[0]! as int],
     );
   }
 }
@@ -170,15 +229,15 @@
   WKWebsiteDataTypeEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static WKWebsiteDataTypeEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKWebsiteDataTypeEnumData decode(Object result) {
+    result as List<Object?>;
     return WKWebsiteDataTypeEnumData(
-      value: WKWebsiteDataTypeEnum.values[pigeonMap['value']! as int],
+      value: WKWebsiteDataTypeEnum.values[result[0]! as int],
     );
   }
 }
@@ -191,15 +250,15 @@
   WKNavigationActionPolicyEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static WKNavigationActionPolicyEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKNavigationActionPolicyEnumData decode(Object result) {
+    result as List<Object?>;
     return WKNavigationActionPolicyEnumData(
-      value: WKNavigationActionPolicyEnum.values[pigeonMap['value']! as int],
+      value: WKNavigationActionPolicyEnum.values[result[0]! as int],
     );
   }
 }
@@ -212,19 +271,22 @@
   NSHttpCookiePropertyKeyEnum value;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['value'] = value.index;
-    return pigeonMap;
+    return <Object?>[
+      value.index,
+    ];
   }
 
-  static NSHttpCookiePropertyKeyEnumData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static NSHttpCookiePropertyKeyEnumData decode(Object result) {
+    result as List<Object?>;
     return NSHttpCookiePropertyKeyEnumData(
-      value: NSHttpCookiePropertyKeyEnum.values[pigeonMap['value']! as int],
+      value: NSHttpCookiePropertyKeyEnum.values[result[0]! as int],
     );
   }
 }
 
+/// Mirror of NSURLRequest.
+///
+/// See https://developer.apple.com/documentation/foundation/nsurlrequest?language=objc.
 class NSUrlRequestData {
   NSUrlRequestData({
     required this.url,
@@ -234,32 +296,37 @@
   });
 
   String url;
+
   String? httpMethod;
+
   Uint8List? httpBody;
+
   Map<String?, String?> allHttpHeaderFields;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['url'] = url;
-    pigeonMap['httpMethod'] = httpMethod;
-    pigeonMap['httpBody'] = httpBody;
-    pigeonMap['allHttpHeaderFields'] = allHttpHeaderFields;
-    return pigeonMap;
+    return <Object?>[
+      url,
+      httpMethod,
+      httpBody,
+      allHttpHeaderFields,
+    ];
   }
 
-  static NSUrlRequestData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static NSUrlRequestData decode(Object result) {
+    result as List<Object?>;
     return NSUrlRequestData(
-      url: pigeonMap['url']! as String,
-      httpMethod: pigeonMap['httpMethod'] as String?,
-      httpBody: pigeonMap['httpBody'] as Uint8List?,
+      url: result[0]! as String,
+      httpMethod: result[1] as String?,
+      httpBody: result[2] as Uint8List?,
       allHttpHeaderFields:
-          (pigeonMap['allHttpHeaderFields'] as Map<Object?, Object?>?)!
-              .cast<String?, String?>(),
+          (result[3] as Map<Object?, Object?>?)!.cast<String?, String?>(),
     );
   }
 }
 
+/// Mirror of WKUserScript.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuserscript?language=objc.
 class WKUserScriptData {
   WKUserScriptData({
     required this.source,
@@ -268,55 +335,69 @@
   });
 
   String source;
+
   WKUserScriptInjectionTimeEnumData? injectionTime;
+
   bool isMainFrameOnly;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['source'] = source;
-    pigeonMap['injectionTime'] = injectionTime?.encode();
-    pigeonMap['isMainFrameOnly'] = isMainFrameOnly;
-    return pigeonMap;
+    return <Object?>[
+      source,
+      injectionTime?.encode(),
+      isMainFrameOnly,
+    ];
   }
 
-  static WKUserScriptData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKUserScriptData decode(Object result) {
+    result as List<Object?>;
     return WKUserScriptData(
-      source: pigeonMap['source']! as String,
-      injectionTime: pigeonMap['injectionTime'] != null
+      source: result[0]! as String,
+      injectionTime: result[1] != null
           ? WKUserScriptInjectionTimeEnumData.decode(
-              pigeonMap['injectionTime']!)
+              result[1]! as List<Object?>)
           : null,
-      isMainFrameOnly: pigeonMap['isMainFrameOnly']! as bool,
+      isMainFrameOnly: result[2]! as bool,
     );
   }
 }
 
+/// Mirror of WKNavigationAction.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationaction.
 class WKNavigationActionData {
   WKNavigationActionData({
     required this.request,
     required this.targetFrame,
+    required this.navigationType,
   });
 
   NSUrlRequestData request;
+
   WKFrameInfoData targetFrame;
 
+  WKNavigationType navigationType;
+
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['request'] = request.encode();
-    pigeonMap['targetFrame'] = targetFrame.encode();
-    return pigeonMap;
+    return <Object?>[
+      request.encode(),
+      targetFrame.encode(),
+      navigationType.index,
+    ];
   }
 
-  static WKNavigationActionData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKNavigationActionData decode(Object result) {
+    result as List<Object?>;
     return WKNavigationActionData(
-      request: NSUrlRequestData.decode(pigeonMap['request']!),
-      targetFrame: WKFrameInfoData.decode(pigeonMap['targetFrame']!),
+      request: NSUrlRequestData.decode(result[0]! as List<Object?>),
+      targetFrame: WKFrameInfoData.decode(result[1]! as List<Object?>),
+      navigationType: WKNavigationType.values[result[2]! as int],
     );
   }
 }
 
+/// Mirror of WKFrameInfo.
+///
+/// See https://developer.apple.com/documentation/webkit/wkframeinfo?language=objc.
 class WKFrameInfoData {
   WKFrameInfoData({
     required this.isMainFrame,
@@ -325,19 +406,22 @@
   bool isMainFrame;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['isMainFrame'] = isMainFrame;
-    return pigeonMap;
+    return <Object?>[
+      isMainFrame,
+    ];
   }
 
-  static WKFrameInfoData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKFrameInfoData decode(Object result) {
+    result as List<Object?>;
     return WKFrameInfoData(
-      isMainFrame: pigeonMap['isMainFrame']! as bool,
+      isMainFrame: result[0]! as bool,
     );
   }
 }
 
+/// Mirror of NSError.
+///
+/// See https://developer.apple.com/documentation/foundation/nserror?language=objc.
 class NSErrorData {
   NSErrorData({
     required this.code,
@@ -346,27 +430,32 @@
   });
 
   int code;
+
   String domain;
+
   String localizedDescription;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['code'] = code;
-    pigeonMap['domain'] = domain;
-    pigeonMap['localizedDescription'] = localizedDescription;
-    return pigeonMap;
+    return <Object?>[
+      code,
+      domain,
+      localizedDescription,
+    ];
   }
 
-  static NSErrorData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static NSErrorData decode(Object result) {
+    result as List<Object?>;
     return NSErrorData(
-      code: pigeonMap['code']! as int,
-      domain: pigeonMap['domain']! as String,
-      localizedDescription: pigeonMap['localizedDescription']! as String,
+      code: result[0]! as int,
+      domain: result[1]! as String,
+      localizedDescription: result[2]! as String,
     );
   }
 }
 
+/// Mirror of WKScriptMessage.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessage?language=objc.
 class WKScriptMessageData {
   WKScriptMessageData({
     required this.name,
@@ -374,24 +463,28 @@
   });
 
   String name;
+
   Object? body;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['name'] = name;
-    pigeonMap['body'] = body;
-    return pigeonMap;
+    return <Object?>[
+      name,
+      body,
+    ];
   }
 
-  static WKScriptMessageData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static WKScriptMessageData decode(Object result) {
+    result as List<Object?>;
     return WKScriptMessageData(
-      name: pigeonMap['name']! as String,
-      body: pigeonMap['body'] as Object?,
+      name: result[0]! as String,
+      body: result[1] as Object?,
     );
   }
 }
 
+/// Mirror of NSHttpCookieData.
+///
+/// See https://developer.apple.com/documentation/foundation/nshttpcookie?language=objc.
 class NSHttpCookieData {
   NSHttpCookieData({
     required this.propertyKeys,
@@ -399,22 +492,22 @@
   });
 
   List<NSHttpCookiePropertyKeyEnumData?> propertyKeys;
+
   List<Object?> propertyValues;
 
   Object encode() {
-    final Map<Object?, Object?> pigeonMap = <Object?, Object?>{};
-    pigeonMap['propertyKeys'] = propertyKeys;
-    pigeonMap['propertyValues'] = propertyValues;
-    return pigeonMap;
+    return <Object?>[
+      propertyKeys,
+      propertyValues,
+    ];
   }
 
-  static NSHttpCookieData decode(Object message) {
-    final Map<Object?, Object?> pigeonMap = message as Map<Object?, Object?>;
+  static NSHttpCookieData decode(Object result) {
+    result as List<Object?>;
     return NSHttpCookieData(
-      propertyKeys: (pigeonMap['propertyKeys'] as List<Object?>?)!
+      propertyKeys: (result[0] as List<Object?>?)!
           .cast<NSHttpCookiePropertyKeyEnumData?>(),
-      propertyValues:
-          (pigeonMap['propertyValues'] as List<Object?>?)!.cast<Object?>(),
+      propertyValues: (result[1] as List<Object?>?)!.cast<Object?>(),
     );
   }
 }
@@ -443,13 +536,15 @@
   }
 }
 
+/// Mirror of WKWebsiteDataStore.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebsitedatastore?language=objc.
 class WKWebsiteDataStoreHostApi {
   /// Constructor for [WKWebsiteDataStoreHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKWebsiteDataStoreHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
   static const MessageCodec<Object?> codec = _WKWebsiteDataStoreHostApiCodec();
@@ -460,21 +555,19 @@
         'dev.flutter.pigeon.WKWebsiteDataStoreHostApi.createFromWebViewConfiguration',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_configurationIdentifier])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -486,20 +579,18 @@
         'dev.flutter.pigeon.WKWebsiteDataStoreHostApi.createDefaultDataStore',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -513,68 +604,62 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebsiteDataStoreHostApi.removeDataOfTypes', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel.send(<Object?>[
+    final List<Object?>? replyList = await channel.send(<Object?>[
       arg_identifier,
       arg_dataTypes,
       arg_modificationTimeInSecondsSinceEpoch
-    ]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    ]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
-    } else if (replyMap['result'] == null) {
+    } else if (replyList[0] == null) {
       throw PlatformException(
         code: 'null-error',
         message: 'Host platform returned null value for non-null return value.',
       );
     } else {
-      return (replyMap['result'] as bool?)!;
+      return (replyList[0] as bool?)!;
     }
   }
 }
 
-class _UIViewHostApiCodec extends StandardMessageCodec {
-  const _UIViewHostApiCodec();
-}
-
+/// Mirror of UIView.
+///
+/// See https://developer.apple.com/documentation/uikit/uiview?language=objc.
 class UIViewHostApi {
   /// Constructor for [UIViewHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   UIViewHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
-  static const MessageCodec<Object?> codec = _UIViewHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   Future<void> setBackgroundColor(int arg_identifier, int? arg_value) async {
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.UIViewHostApi.setBackgroundColor', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_value]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_value]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -585,20 +670,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.UIViewHostApi.setOpaque', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_opaque]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_opaque]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -606,41 +689,37 @@
   }
 }
 
-class _UIScrollViewHostApiCodec extends StandardMessageCodec {
-  const _UIScrollViewHostApiCodec();
-}
-
+/// Mirror of UIScrollView.
+///
+/// See https://developer.apple.com/documentation/uikit/uiscrollview?language=objc.
 class UIScrollViewHostApi {
   /// Constructor for [UIScrollViewHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   UIScrollViewHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
-  static const MessageCodec<Object?> codec = _UIScrollViewHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   Future<void> createFromWebView(
       int arg_identifier, int arg_webViewIdentifier) async {
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.UIScrollViewHostApi.createFromWebView', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
+    final List<Object?>? replyList =
         await channel.send(<Object?>[arg_identifier, arg_webViewIdentifier])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+            as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -651,28 +730,26 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.UIScrollViewHostApi.getContentOffset', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
-    } else if (replyMap['result'] == null) {
+    } else if (replyList[0] == null) {
       throw PlatformException(
         code: 'null-error',
         message: 'Host platform returned null value for non-null return value.',
       );
     } else {
-      return (replyMap['result'] as List<Object?>?)!.cast<double?>();
+      return (replyList[0] as List<Object?>?)!.cast<double?>();
     }
   }
 
@@ -680,21 +757,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.UIScrollViewHostApi.scrollBy', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier, arg_x, arg_y])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_x, arg_y]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -706,21 +780,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.UIScrollViewHostApi.setContentOffset', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier, arg_x, arg_y])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_x, arg_y]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -752,13 +823,15 @@
   }
 }
 
+/// Mirror of WKWebViewConfiguration.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebviewconfiguration?language=objc.
 class WKWebViewConfigurationHostApi {
   /// Constructor for [WKWebViewConfigurationHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKWebViewConfigurationHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
   static const MessageCodec<Object?> codec =
@@ -768,20 +841,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewConfigurationHostApi.create', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -794,21 +865,19 @@
         'dev.flutter.pigeon.WKWebViewConfigurationHostApi.createFromWebView',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
+    final List<Object?>? replyList =
         await channel.send(<Object?>[arg_identifier, arg_webViewIdentifier])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+            as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -821,20 +890,18 @@
         'dev.flutter.pigeon.WKWebViewConfigurationHostApi.setAllowsInlineMediaPlayback',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_allow]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_allow]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -847,20 +914,18 @@
         'dev.flutter.pigeon.WKWebViewConfigurationHostApi.setMediaTypesRequiringUserActionForPlayback',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_types]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_types]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -868,15 +933,14 @@
   }
 }
 
-class _WKWebViewConfigurationFlutterApiCodec extends StandardMessageCodec {
-  const _WKWebViewConfigurationFlutterApiCodec();
-}
-
+/// Handles callbacks from an WKWebViewConfiguration instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebviewconfiguration?language=objc.
 abstract class WKWebViewConfigurationFlutterApi {
-  static const MessageCodec<Object?> codec =
-      _WKWebViewConfigurationFlutterApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void create(int identifier);
+
   static void setup(WKWebViewConfigurationFlutterApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -931,13 +995,15 @@
   }
 }
 
+/// Mirror of WKUserContentController.
+///
+/// See https://developer.apple.com/documentation/webkit/wkusercontentcontroller?language=objc.
 class WKUserContentControllerHostApi {
   /// Constructor for [WKUserContentControllerHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKUserContentControllerHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
   static const MessageCodec<Object?> codec =
@@ -949,21 +1015,19 @@
         'dev.flutter.pigeon.WKUserContentControllerHostApi.createFromWebViewConfiguration',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_configurationIdentifier])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -976,21 +1040,19 @@
         'dev.flutter.pigeon.WKUserContentControllerHostApi.addScriptMessageHandler',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_handlerIdentifier, arg_name])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1003,20 +1065,18 @@
         'dev.flutter.pigeon.WKUserContentControllerHostApi.removeScriptMessageHandler',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_name]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_name]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1028,20 +1088,18 @@
         'dev.flutter.pigeon.WKUserContentControllerHostApi.removeAllScriptMessageHandlers',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1054,21 +1112,18 @@
         'dev.flutter.pigeon.WKUserContentControllerHostApi.addUserScript',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier, arg_userScript])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_userScript]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1080,20 +1135,18 @@
         'dev.flutter.pigeon.WKUserContentControllerHostApi.removeAllUserScripts',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1101,20 +1154,18 @@
   }
 }
 
-class _WKPreferencesHostApiCodec extends StandardMessageCodec {
-  const _WKPreferencesHostApiCodec();
-}
-
+/// Mirror of WKUserPreferences.
+///
+/// See https://developer.apple.com/documentation/webkit/wkpreferences?language=objc.
 class WKPreferencesHostApi {
   /// Constructor for [WKPreferencesHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKPreferencesHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
-  static const MessageCodec<Object?> codec = _WKPreferencesHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   Future<void> createFromWebViewConfiguration(
       int arg_identifier, int arg_configurationIdentifier) async {
@@ -1122,21 +1173,19 @@
         'dev.flutter.pigeon.WKPreferencesHostApi.createFromWebViewConfiguration',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_configurationIdentifier])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1148,20 +1197,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKPreferencesHostApi.setJavaScriptEnabled', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_enabled]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_enabled]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1169,40 +1216,35 @@
   }
 }
 
-class _WKScriptMessageHandlerHostApiCodec extends StandardMessageCodec {
-  const _WKScriptMessageHandlerHostApiCodec();
-}
-
+/// Mirror of WKScriptMessageHandler.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessagehandler?language=objc.
 class WKScriptMessageHandlerHostApi {
   /// Constructor for [WKScriptMessageHandlerHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKScriptMessageHandlerHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
-  static const MessageCodec<Object?> codec =
-      _WKScriptMessageHandlerHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   Future<void> create(int arg_identifier) async {
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKScriptMessageHandlerHostApi.create', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1234,12 +1276,16 @@
   }
 }
 
+/// Handles callbacks from an WKScriptMessageHandler instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessagehandler?language=objc.
 abstract class WKScriptMessageHandlerFlutterApi {
   static const MessageCodec<Object?> codec =
       _WKScriptMessageHandlerFlutterApiCodec();
 
   void didReceiveScriptMessage(int identifier,
       int userContentControllerIdentifier, WKScriptMessageData message);
+
   static void setup(WKScriptMessageHandlerFlutterApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -1273,40 +1319,35 @@
   }
 }
 
-class _WKNavigationDelegateHostApiCodec extends StandardMessageCodec {
-  const _WKNavigationDelegateHostApiCodec();
-}
-
+/// Mirror of WKNavigationDelegate.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationdelegate?language=objc.
 class WKNavigationDelegateHostApi {
   /// Constructor for [WKNavigationDelegateHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKNavigationDelegateHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
-  static const MessageCodec<Object?> codec =
-      _WKNavigationDelegateHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   Future<void> create(int arg_identifier) async {
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKNavigationDelegateHostApi.create', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1362,23 +1403,32 @@
   }
 }
 
+/// Handles callbacks from an WKNavigationDelegate instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationdelegate?language=objc.
 abstract class WKNavigationDelegateFlutterApi {
   static const MessageCodec<Object?> codec =
       _WKNavigationDelegateFlutterApiCodec();
 
   void didFinishNavigation(int identifier, int webViewIdentifier, String? url);
+
   void didStartProvisionalNavigation(
       int identifier, int webViewIdentifier, String? url);
+
   Future<WKNavigationActionPolicyEnumData> decidePolicyForNavigationAction(
       int identifier,
       int webViewIdentifier,
       WKNavigationActionData navigationAction);
+
   void didFailNavigation(
       int identifier, int webViewIdentifier, NSErrorData error);
+
   void didFailProvisionalNavigation(
       int identifier, int webViewIdentifier, NSErrorData error);
+
   void webViewWebContentProcessDidTerminate(
       int identifier, int webViewIdentifier);
+
   static void setup(WKNavigationDelegateFlutterApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -1565,13 +1615,15 @@
   }
 }
 
+/// Mirror of NSObject.
+///
+/// See https://developer.apple.com/documentation/objectivec/nsobject.
 class NSObjectHostApi {
   /// Constructor for [NSObjectHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   NSObjectHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
   static const MessageCodec<Object?> codec = _NSObjectHostApiCodec();
@@ -1580,20 +1632,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.NSObjectHostApi.dispose', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1608,24 +1658,22 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.NSObjectHostApi.addObserver', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel.send(<Object?>[
+    final List<Object?>? replyList = await channel.send(<Object?>[
       arg_identifier,
       arg_observerIdentifier,
       arg_keyPath,
       arg_options
-    ]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    ]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1637,21 +1685,19 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.NSObjectHostApi.removeObserver', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel.send(
+    final List<Object?>? replyList = await channel.send(
             <Object?>[arg_identifier, arg_observerIdentifier, arg_keyPath])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1761,6 +1807,9 @@
   }
 }
 
+/// Handles callbacks from an NSObject instance.
+///
+/// See https://developer.apple.com/documentation/objectivec/nsobject.
 abstract class NSObjectFlutterApi {
   static const MessageCodec<Object?> codec = _NSObjectFlutterApiCodec();
 
@@ -1770,7 +1819,9 @@
       int objectIdentifier,
       List<NSKeyValueChangeKeyEnumData?> changeKeys,
       List<Object?> changeValues);
+
   void dispose(int identifier);
+
   static void setup(NSObjectFlutterApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -1931,13 +1982,15 @@
   }
 }
 
+/// Mirror of WKWebView.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebview?language=objc.
 class WKWebViewHostApi {
   /// Constructor for [WKWebViewHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKWebViewHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
   static const MessageCodec<Object?> codec = _WKWebViewHostApiCodec();
@@ -1947,21 +2000,19 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.create', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_configurationIdentifier])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1973,21 +2024,19 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.setUIDelegate', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
+    final List<Object?>? replyList =
         await channel.send(<Object?>[arg_identifier, arg_uiDelegateIdentifier])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+            as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -1999,21 +2048,19 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.setNavigationDelegate', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_navigationDelegateIdentifier])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2024,23 +2071,21 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.getUrl', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
-      return (replyMap['result'] as String?);
+      return (replyList[0] as String?);
     }
   }
 
@@ -2048,28 +2093,26 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.getEstimatedProgress', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
-    } else if (replyMap['result'] == null) {
+    } else if (replyList[0] == null) {
       throw PlatformException(
         code: 'null-error',
         message: 'Host platform returned null value for non-null return value.',
       );
     } else {
-      return (replyMap['result'] as double?)!;
+      return (replyList[0] as double?)!;
     }
   }
 
@@ -2078,20 +2121,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.loadRequest', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_request]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_request]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2103,21 +2144,19 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.loadHtmlString', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
+    final List<Object?>? replyList =
         await channel.send(<Object?>[arg_identifier, arg_string, arg_baseUrl])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+            as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2129,21 +2168,19 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.loadFileUrl', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_url, arg_readAccessUrl])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2154,20 +2191,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.loadFlutterAsset', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_key]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_key]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2178,28 +2213,26 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.canGoBack', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
-    } else if (replyMap['result'] == null) {
+    } else if (replyList[0] == null) {
       throw PlatformException(
         code: 'null-error',
         message: 'Host platform returned null value for non-null return value.',
       );
     } else {
-      return (replyMap['result'] as bool?)!;
+      return (replyList[0] as bool?)!;
     }
   }
 
@@ -2207,28 +2240,26 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.canGoForward', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
-    } else if (replyMap['result'] == null) {
+    } else if (replyList[0] == null) {
       throw PlatformException(
         code: 'null-error',
         message: 'Host platform returned null value for non-null return value.',
       );
     } else {
-      return (replyMap['result'] as bool?)!;
+      return (replyList[0] as bool?)!;
     }
   }
 
@@ -2236,20 +2267,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.goBack', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2260,20 +2289,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.goForward', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2284,20 +2311,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.reload', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2308,23 +2333,21 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.getTitle', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
-      return (replyMap['result'] as String?);
+      return (replyList[0] as String?);
     }
   }
 
@@ -2334,20 +2357,18 @@
         'dev.flutter.pigeon.WKWebViewHostApi.setAllowsBackForwardNavigationGestures',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_allow]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_allow]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2359,21 +2380,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.setCustomUserAgent', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier, arg_userAgent])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_userAgent]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2385,61 +2403,55 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKWebViewHostApi.evaluateJavaScript', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
+    final List<Object?>? replyList =
         await channel.send(<Object?>[arg_identifier, arg_javaScriptString])
-            as Map<Object?, Object?>?;
-    if (replyMap == null) {
+            as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
-      return (replyMap['result'] as Object?);
+      return (replyList[0] as Object?);
     }
   }
 }
 
-class _WKUIDelegateHostApiCodec extends StandardMessageCodec {
-  const _WKUIDelegateHostApiCodec();
-}
-
+/// Mirror of WKUIDelegate.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuidelegate?language=objc.
 class WKUIDelegateHostApi {
   /// Constructor for [WKUIDelegateHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKUIDelegateHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
-  static const MessageCodec<Object?> codec = _WKUIDelegateHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   Future<void> create(int arg_identifier) async {
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKUIDelegateHostApi.create', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap =
-        await channel.send(<Object?>[arg_identifier]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList =
+        await channel.send(<Object?>[arg_identifier]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2483,11 +2495,15 @@
   }
 }
 
+/// Handles callbacks from an WKUIDelegate instance.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuidelegate?language=objc.
 abstract class WKUIDelegateFlutterApi {
   static const MessageCodec<Object?> codec = _WKUIDelegateFlutterApiCodec();
 
   void onCreateWebView(int identifier, int webViewIdentifier,
       int configurationIdentifier, WKNavigationActionData navigationAction);
+
   static void setup(WKUIDelegateFlutterApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -2553,13 +2569,15 @@
   }
 }
 
+/// Mirror of WKHttpCookieStore.
+///
+/// See https://developer.apple.com/documentation/webkit/wkhttpcookiestore?language=objc.
 class WKHttpCookieStoreHostApi {
   /// Constructor for [WKHttpCookieStoreHostApi].  The [binaryMessenger] named argument is
   /// available for dependency injection.  If it is left null, the default
   /// BinaryMessenger will be used which routes to the host platform.
   WKHttpCookieStoreHostApi({BinaryMessenger? binaryMessenger})
       : _binaryMessenger = binaryMessenger;
-
   final BinaryMessenger? _binaryMessenger;
 
   static const MessageCodec<Object?> codec = _WKHttpCookieStoreHostApiCodec();
@@ -2570,21 +2588,19 @@
         'dev.flutter.pigeon.WKHttpCookieStoreHostApi.createFromWebsiteDataStore',
         codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
+    final List<Object?>? replyList = await channel
             .send(<Object?>[arg_identifier, arg_websiteDataStoreIdentifier])
-        as Map<Object?, Object?>?;
-    if (replyMap == null) {
+        as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
@@ -2596,20 +2612,18 @@
     final BasicMessageChannel<Object?> channel = BasicMessageChannel<Object?>(
         'dev.flutter.pigeon.WKHttpCookieStoreHostApi.setCookie', codec,
         binaryMessenger: _binaryMessenger);
-    final Map<Object?, Object?>? replyMap = await channel
-        .send(<Object?>[arg_identifier, arg_cookie]) as Map<Object?, Object?>?;
-    if (replyMap == null) {
+    final List<Object?>? replyList = await channel
+        .send(<Object?>[arg_identifier, arg_cookie]) as List<Object?>?;
+    if (replyList == null) {
       throw PlatformException(
         code: 'channel-error',
         message: 'Unable to establish connection on channel.',
       );
-    } else if (replyMap['error'] != null) {
-      final Map<Object?, Object?> error =
-          (replyMap['error'] as Map<Object?, Object?>?)!;
+    } else if (replyList.length > 1) {
       throw PlatformException(
-        code: (error['code'] as String?)!,
-        message: error['message'] as String?,
-        details: error['details'],
+        code: replyList[0]! as String,
+        message: replyList[1] as String?,
+        details: replyList[2],
       );
     } else {
       return;
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit.dart b/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit.dart
index 566c46f..467fa87 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit.dart
@@ -10,6 +10,8 @@
 import '../ui_kit/ui_kit.dart';
 import 'web_kit_api_impls.dart';
 
+export 'web_kit_api_impls.dart' show WKNavigationType;
+
 /// Times at which to inject script content into a webpage.
 ///
 /// Wraps [WKUserScriptInjectionTime](https://developer.apple.com/documentation/webkit/wkuserscriptinjectiontime?language=objc).
@@ -144,13 +146,20 @@
 @immutable
 class WKNavigationAction {
   /// Constructs a [WKNavigationAction].
-  const WKNavigationAction({required this.request, required this.targetFrame});
+  const WKNavigationAction({
+    required this.request,
+    required this.targetFrame,
+    required this.navigationType,
+  });
 
   /// The URL request object associated with the navigation action.
   final NSUrlRequest request;
 
   /// The frame in which to display the new content.
   final WKFrameInfo targetFrame;
+
+  /// The type of action that triggered the navigation.
+  final WKNavigationType navigationType;
 }
 
 /// An object that contains information about a frame on a webpage.
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit_api_impls.dart b/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit_api_impls.dart
index 614d079..97a3e00 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit_api_impls.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/lib/src/web_kit/web_kit_api_impls.dart
@@ -10,6 +10,8 @@
 import '../foundation/foundation.dart';
 import 'web_kit.dart';
 
+export '../common/web_kit.pigeon.dart' show WKNavigationType;
+
 Iterable<WKWebsiteDataTypeEnumData> _toWKWebsiteDataTypeEnumData(
     Iterable<WKWebsiteDataType> types) {
   return types.map<WKWebsiteDataTypeEnumData>((WKWebsiteDataType type) {
@@ -169,6 +171,7 @@
     return WKNavigationAction(
       request: request.toNSUrlRequest(),
       targetFrame: targetFrame.toWKFrameInfo(),
+      navigationType: navigationType,
     );
   }
 }
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/pigeons/web_kit.dart b/packages/webview_flutter/webview_flutter_wkwebview/pigeons/web_kit.dart
index c20a10e..d32693e 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/pigeons/web_kit.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/pigeons/web_kit.dart
@@ -166,6 +166,42 @@
   late NSHttpCookiePropertyKeyEnum value;
 }
 
+/// An object that contains information about an action that causes navigation
+/// to occur.
+///
+/// Wraps [WKNavigationType](https://developer.apple.com/documentation/webkit/wknavigationaction?language=objc).
+enum WKNavigationType {
+  /// A link activation.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypelinkactivated?language=objc.
+  linkActivated,
+
+  /// A request to submit a form.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeformsubmitted?language=objc.
+  submitted,
+
+  /// A request for the frame’s next or previous item.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypebackforward?language=objc.
+  backForward,
+
+  /// A request to reload the webpage.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypereload?language=objc.
+  reload,
+
+  /// A request to resubmit a form.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeformresubmitted?language=objc.
+  formResubmitted,
+
+  /// A navigation request that originates for some other reason.
+  ///
+  /// See https://developer.apple.com/documentation/webkit/wknavigationtype/wknavigationtypeother?language=objc.
+  other,
+}
+
 /// Mirror of NSURLRequest.
 ///
 /// See https://developer.apple.com/documentation/foundation/nsurlrequest?language=objc.
@@ -191,6 +227,7 @@
 class WKNavigationActionData {
   late NSUrlRequestData request;
   late WKFrameInfoData targetFrame;
+  late WKNavigationType navigationType;
 }
 
 /// Mirror of WKFrameInfo.
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/pubspec.yaml b/packages/webview_flutter/webview_flutter_wkwebview/pubspec.yaml
index bf443e8..27a6a78 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/pubspec.yaml
+++ b/packages/webview_flutter/webview_flutter_wkwebview/pubspec.yaml
@@ -2,7 +2,7 @@
 description: A Flutter plugin that provides a WebView widget based on Apple's WKWebView control.
 repository: https://github.com/flutter/plugins/tree/main/packages/webview_flutter/webview_flutter_wkwebview
 issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+webview%22
-version: 3.0.0
+version: 3.0.1
 
 environment:
   sdk: ">=2.17.0 <3.0.0"
@@ -29,4 +29,4 @@
   flutter_test:
     sdk: flutter
   mockito: ^5.3.2
-  pigeon: ^3.0.3
+  pigeon: ^4.2.13
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/test/legacy/web_kit_webview_widget_test.dart b/packages/webview_flutter/webview_flutter_wkwebview/test/legacy/web_kit_webview_widget_test.dart
index b64c142..da7ce9b 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/test/legacy/web_kit_webview_widget_test.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/test/legacy/web_kit_webview_widget_test.dart
@@ -152,6 +152,7 @@
         const WKNavigationAction(
           request: request,
           targetFrame: WKFrameInfo(isMainFrame: false),
+          navigationType: WKNavigationType.linkActivated,
         ),
       );
 
@@ -1167,6 +1168,7 @@
             const WKNavigationAction(
               request: NSUrlRequest(url: 'https://google.com'),
               targetFrame: WKFrameInfo(isMainFrame: false),
+              navigationType: WKNavigationType.linkActivated,
             ),
           ),
           completion(WKNavigationActionPolicy.allow),
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/test/src/common/test_web_kit.pigeon.dart b/packages/webview_flutter/webview_flutter_wkwebview/test/src/common/test_web_kit.pigeon.dart
index a9e5c8b..73c1053 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/test/src/common/test_web_kit.pigeon.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/test/src/common/test_web_kit.pigeon.dart
@@ -1,14 +1,13 @@
 // Copyright 2013 The Flutter Authors. All rights reserved.
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
-// Autogenerated from Pigeon (v3.1.5), do not edit directly.
+// Autogenerated from Pigeon (v4.2.13), do not edit directly.
 // See also: https://pub.dev/packages/pigeon
-// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis
+// ignore_for_file: public_member_api_docs, non_constant_identifier_names, avoid_as, unused_import, unnecessary_parenthesis, unnecessary_import
 // ignore_for_file: avoid_relative_lib_imports
-// @dart = 2.12
 import 'dart:async';
-import 'dart:typed_data' show Uint8List, Int32List, Int64List, Float64List;
-import 'package:flutter/foundation.dart' show WriteBuffer, ReadBuffer;
+import 'dart:typed_data' show Float64List, Int32List, Int64List, Uint8List;
+import 'package:flutter/foundation.dart' show ReadBuffer, WriteBuffer;
 import 'package:flutter/services.dart';
 import 'package:flutter_test/flutter_test.dart';
 
@@ -38,17 +37,23 @@
   }
 }
 
+/// Mirror of WKWebsiteDataStore.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebsitedatastore?language=objc.
 abstract class TestWKWebsiteDataStoreHostApi {
   static const MessageCodec<Object?> codec =
       _TestWKWebsiteDataStoreHostApiCodec();
 
   void createFromWebViewConfiguration(
       int identifier, int configurationIdentifier);
+
   void createDefaultDataStore(int identifier);
+
   Future<bool> removeDataOfTypes(
       int identifier,
       List<WKWebsiteDataTypeEnumData?> dataTypes,
       double modificationTimeInSecondsSinceEpoch);
+
   static void setup(TestWKWebsiteDataStoreHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -71,7 +76,7 @@
               'Argument for dev.flutter.pigeon.WKWebsiteDataStoreHostApi.createFromWebViewConfiguration was null, expected non-null int.');
           api.createFromWebViewConfiguration(
               arg_identifier!, arg_configurationIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -91,7 +96,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebsiteDataStoreHostApi.createDefaultDataStore was null, expected non-null int.');
           api.createDefaultDataStore(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -120,22 +125,23 @@
               'Argument for dev.flutter.pigeon.WKWebsiteDataStoreHostApi.removeDataOfTypes was null, expected non-null double.');
           final bool output = await api.removeDataOfTypes(arg_identifier!,
               arg_dataTypes!, arg_modificationTimeInSecondsSinceEpoch!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
   }
 }
 
-class _TestUIViewHostApiCodec extends StandardMessageCodec {
-  const _TestUIViewHostApiCodec();
-}
-
+/// Mirror of UIView.
+///
+/// See https://developer.apple.com/documentation/uikit/uiview?language=objc.
 abstract class TestUIViewHostApi {
-  static const MessageCodec<Object?> codec = _TestUIViewHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void setBackgroundColor(int identifier, int? value);
+
   void setOpaque(int identifier, bool opaque);
+
   static void setup(TestUIViewHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -154,7 +160,7 @@
               'Argument for dev.flutter.pigeon.UIViewHostApi.setBackgroundColor was null, expected non-null int.');
           final int? arg_value = (args[1] as int?);
           api.setBackgroundColor(arg_identifier!, arg_value);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -176,24 +182,27 @@
           assert(arg_opaque != null,
               'Argument for dev.flutter.pigeon.UIViewHostApi.setOpaque was null, expected non-null bool.');
           api.setOpaque(arg_identifier!, arg_opaque!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
   }
 }
 
-class _TestUIScrollViewHostApiCodec extends StandardMessageCodec {
-  const _TestUIScrollViewHostApiCodec();
-}
-
+/// Mirror of UIScrollView.
+///
+/// See https://developer.apple.com/documentation/uikit/uiscrollview?language=objc.
 abstract class TestUIScrollViewHostApi {
-  static const MessageCodec<Object?> codec = _TestUIScrollViewHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void createFromWebView(int identifier, int webViewIdentifier);
+
   List<double?> getContentOffset(int identifier);
+
   void scrollBy(int identifier, double x, double y);
+
   void setContentOffset(int identifier, double x, double y);
+
   static void setup(TestUIScrollViewHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -214,7 +223,7 @@
           assert(arg_webViewIdentifier != null,
               'Argument for dev.flutter.pigeon.UIScrollViewHostApi.createFromWebView was null, expected non-null int.');
           api.createFromWebView(arg_identifier!, arg_webViewIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -233,7 +242,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.UIScrollViewHostApi.getContentOffset was null, expected non-null int.');
           final List<double?> output = api.getContentOffset(arg_identifier!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
@@ -258,7 +267,7 @@
           assert(arg_y != null,
               'Argument for dev.flutter.pigeon.UIScrollViewHostApi.scrollBy was null, expected non-null double.');
           api.scrollBy(arg_identifier!, arg_x!, arg_y!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -283,7 +292,7 @@
           assert(arg_y != null,
               'Argument for dev.flutter.pigeon.UIScrollViewHostApi.setContentOffset was null, expected non-null double.');
           api.setContentOffset(arg_identifier!, arg_x!, arg_y!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -314,15 +323,22 @@
   }
 }
 
+/// Mirror of WKWebViewConfiguration.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebviewconfiguration?language=objc.
 abstract class TestWKWebViewConfigurationHostApi {
   static const MessageCodec<Object?> codec =
       _TestWKWebViewConfigurationHostApiCodec();
 
   void create(int identifier);
+
   void createFromWebView(int identifier, int webViewIdentifier);
+
   void setAllowsInlineMediaPlayback(int identifier, bool allow);
+
   void setMediaTypesRequiringUserActionForPlayback(
       int identifier, List<WKAudiovisualMediaTypeEnumData?> types);
+
   static void setup(TestWKWebViewConfigurationHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -340,7 +356,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewConfigurationHostApi.create was null, expected non-null int.');
           api.create(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -363,7 +379,7 @@
           assert(arg_webViewIdentifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewConfigurationHostApi.createFromWebView was null, expected non-null int.');
           api.createFromWebView(arg_identifier!, arg_webViewIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -386,7 +402,7 @@
           assert(arg_allow != null,
               'Argument for dev.flutter.pigeon.WKWebViewConfigurationHostApi.setAllowsInlineMediaPlayback was null, expected non-null bool.');
           api.setAllowsInlineMediaPlayback(arg_identifier!, arg_allow!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -412,7 +428,7 @@
               'Argument for dev.flutter.pigeon.WKWebViewConfigurationHostApi.setMediaTypesRequiringUserActionForPlayback was null, expected non-null List<WKAudiovisualMediaTypeEnumData?>.');
           api.setMediaTypesRequiringUserActionForPlayback(
               arg_identifier!, arg_types!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -449,18 +465,27 @@
   }
 }
 
+/// Mirror of WKUserContentController.
+///
+/// See https://developer.apple.com/documentation/webkit/wkusercontentcontroller?language=objc.
 abstract class TestWKUserContentControllerHostApi {
   static const MessageCodec<Object?> codec =
       _TestWKUserContentControllerHostApiCodec();
 
   void createFromWebViewConfiguration(
       int identifier, int configurationIdentifier);
+
   void addScriptMessageHandler(
       int identifier, int handlerIdentifier, String name);
+
   void removeScriptMessageHandler(int identifier, String name);
+
   void removeAllScriptMessageHandlers(int identifier);
+
   void addUserScript(int identifier, WKUserScriptData userScript);
+
   void removeAllUserScripts(int identifier);
+
   static void setup(TestWKUserContentControllerHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -483,7 +508,7 @@
               'Argument for dev.flutter.pigeon.WKUserContentControllerHostApi.createFromWebViewConfiguration was null, expected non-null int.');
           api.createFromWebViewConfiguration(
               arg_identifier!, arg_configurationIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -510,7 +535,7 @@
               'Argument for dev.flutter.pigeon.WKUserContentControllerHostApi.addScriptMessageHandler was null, expected non-null String.');
           api.addScriptMessageHandler(
               arg_identifier!, arg_handlerIdentifier!, arg_name!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -533,7 +558,7 @@
           assert(arg_name != null,
               'Argument for dev.flutter.pigeon.WKUserContentControllerHostApi.removeScriptMessageHandler was null, expected non-null String.');
           api.removeScriptMessageHandler(arg_identifier!, arg_name!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -553,7 +578,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKUserContentControllerHostApi.removeAllScriptMessageHandlers was null, expected non-null int.');
           api.removeAllScriptMessageHandlers(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -577,7 +602,7 @@
           assert(arg_userScript != null,
               'Argument for dev.flutter.pigeon.WKUserContentControllerHostApi.addUserScript was null, expected non-null WKUserScriptData.');
           api.addUserScript(arg_identifier!, arg_userScript!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -597,23 +622,24 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKUserContentControllerHostApi.removeAllUserScripts was null, expected non-null int.');
           api.removeAllUserScripts(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
   }
 }
 
-class _TestWKPreferencesHostApiCodec extends StandardMessageCodec {
-  const _TestWKPreferencesHostApiCodec();
-}
-
+/// Mirror of WKUserPreferences.
+///
+/// See https://developer.apple.com/documentation/webkit/wkpreferences?language=objc.
 abstract class TestWKPreferencesHostApi {
-  static const MessageCodec<Object?> codec = _TestWKPreferencesHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void createFromWebViewConfiguration(
       int identifier, int configurationIdentifier);
+
   void setJavaScriptEnabled(int identifier, bool enabled);
+
   static void setup(TestWKPreferencesHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -636,7 +662,7 @@
               'Argument for dev.flutter.pigeon.WKPreferencesHostApi.createFromWebViewConfiguration was null, expected non-null int.');
           api.createFromWebViewConfiguration(
               arg_identifier!, arg_configurationIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -658,22 +684,21 @@
           assert(arg_enabled != null,
               'Argument for dev.flutter.pigeon.WKPreferencesHostApi.setJavaScriptEnabled was null, expected non-null bool.');
           api.setJavaScriptEnabled(arg_identifier!, arg_enabled!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
   }
 }
 
-class _TestWKScriptMessageHandlerHostApiCodec extends StandardMessageCodec {
-  const _TestWKScriptMessageHandlerHostApiCodec();
-}
-
+/// Mirror of WKScriptMessageHandler.
+///
+/// See https://developer.apple.com/documentation/webkit/wkscriptmessagehandler?language=objc.
 abstract class TestWKScriptMessageHandlerHostApi {
-  static const MessageCodec<Object?> codec =
-      _TestWKScriptMessageHandlerHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void create(int identifier);
+
   static void setup(TestWKScriptMessageHandlerHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -691,22 +716,21 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKScriptMessageHandlerHostApi.create was null, expected non-null int.');
           api.create(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
   }
 }
 
-class _TestWKNavigationDelegateHostApiCodec extends StandardMessageCodec {
-  const _TestWKNavigationDelegateHostApiCodec();
-}
-
+/// Mirror of WKNavigationDelegate.
+///
+/// See https://developer.apple.com/documentation/webkit/wknavigationdelegate?language=objc.
 abstract class TestWKNavigationDelegateHostApi {
-  static const MessageCodec<Object?> codec =
-      _TestWKNavigationDelegateHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void create(int identifier);
+
   static void setup(TestWKNavigationDelegateHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -724,7 +748,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKNavigationDelegateHostApi.create was null, expected non-null int.');
           api.create(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -755,13 +779,19 @@
   }
 }
 
+/// Mirror of NSObject.
+///
+/// See https://developer.apple.com/documentation/objectivec/nsobject.
 abstract class TestNSObjectHostApi {
   static const MessageCodec<Object?> codec = _TestNSObjectHostApiCodec();
 
   void dispose(int identifier);
+
   void addObserver(int identifier, int observerIdentifier, String keyPath,
       List<NSKeyValueObservingOptionsEnumData?> options);
+
   void removeObserver(int identifier, int observerIdentifier, String keyPath);
+
   static void setup(TestNSObjectHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -779,7 +809,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.NSObjectHostApi.dispose was null, expected non-null int.');
           api.dispose(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -810,7 +840,7 @@
               'Argument for dev.flutter.pigeon.NSObjectHostApi.addObserver was null, expected non-null List<NSKeyValueObservingOptionsEnumData?>.');
           api.addObserver(arg_identifier!, arg_observerIdentifier!,
               arg_keyPath!, arg_options!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -836,7 +866,7 @@
               'Argument for dev.flutter.pigeon.NSObjectHostApi.removeObserver was null, expected non-null String.');
           api.removeObserver(
               arg_identifier!, arg_observerIdentifier!, arg_keyPath!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -945,27 +975,48 @@
   }
 }
 
+/// Mirror of WKWebView.
+///
+/// See https://developer.apple.com/documentation/webkit/wkwebview?language=objc.
 abstract class TestWKWebViewHostApi {
   static const MessageCodec<Object?> codec = _TestWKWebViewHostApiCodec();
 
   void create(int identifier, int configurationIdentifier);
+
   void setUIDelegate(int identifier, int? uiDelegateIdentifier);
+
   void setNavigationDelegate(int identifier, int? navigationDelegateIdentifier);
+
   String? getUrl(int identifier);
+
   double getEstimatedProgress(int identifier);
+
   void loadRequest(int identifier, NSUrlRequestData request);
+
   void loadHtmlString(int identifier, String string, String? baseUrl);
+
   void loadFileUrl(int identifier, String url, String readAccessUrl);
+
   void loadFlutterAsset(int identifier, String key);
+
   bool canGoBack(int identifier);
+
   bool canGoForward(int identifier);
+
   void goBack(int identifier);
+
   void goForward(int identifier);
+
   void reload(int identifier);
+
   String? getTitle(int identifier);
+
   void setAllowsBackForwardNavigationGestures(int identifier, bool allow);
+
   void setCustomUserAgent(int identifier, String? userAgent);
+
   Future<Object?> evaluateJavaScript(int identifier, String javaScriptString);
+
   static void setup(TestWKWebViewHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -986,7 +1037,7 @@
           assert(arg_configurationIdentifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.create was null, expected non-null int.');
           api.create(arg_identifier!, arg_configurationIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1006,7 +1057,7 @@
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.setUIDelegate was null, expected non-null int.');
           final int? arg_uiDelegateIdentifier = (args[1] as int?);
           api.setUIDelegate(arg_identifier!, arg_uiDelegateIdentifier);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1027,7 +1078,7 @@
           final int? arg_navigationDelegateIdentifier = (args[1] as int?);
           api.setNavigationDelegate(
               arg_identifier!, arg_navigationDelegateIdentifier);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1046,7 +1097,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.getUrl was null, expected non-null int.');
           final String? output = api.getUrl(arg_identifier!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
@@ -1065,7 +1116,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.getEstimatedProgress was null, expected non-null int.');
           final double output = api.getEstimatedProgress(arg_identifier!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
@@ -1087,7 +1138,7 @@
           assert(arg_request != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.loadRequest was null, expected non-null NSUrlRequestData.');
           api.loadRequest(arg_identifier!, arg_request!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1110,7 +1161,7 @@
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.loadHtmlString was null, expected non-null String.');
           final String? arg_baseUrl = (args[2] as String?);
           api.loadHtmlString(arg_identifier!, arg_string!, arg_baseUrl);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1135,7 +1186,7 @@
           assert(arg_readAccessUrl != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.loadFileUrl was null, expected non-null String.');
           api.loadFileUrl(arg_identifier!, arg_url!, arg_readAccessUrl!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1157,7 +1208,7 @@
           assert(arg_key != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.loadFlutterAsset was null, expected non-null String.');
           api.loadFlutterAsset(arg_identifier!, arg_key!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1176,7 +1227,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.canGoBack was null, expected non-null int.');
           final bool output = api.canGoBack(arg_identifier!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
@@ -1195,7 +1246,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.canGoForward was null, expected non-null int.');
           final bool output = api.canGoForward(arg_identifier!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
@@ -1214,7 +1265,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.goBack was null, expected non-null int.');
           api.goBack(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1233,7 +1284,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.goForward was null, expected non-null int.');
           api.goForward(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1252,7 +1303,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.reload was null, expected non-null int.');
           api.reload(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1271,7 +1322,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.getTitle was null, expected non-null int.');
           final String? output = api.getTitle(arg_identifier!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
@@ -1295,7 +1346,7 @@
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.setAllowsBackForwardNavigationGestures was null, expected non-null bool.');
           api.setAllowsBackForwardNavigationGestures(
               arg_identifier!, arg_allow!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1315,7 +1366,7 @@
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.setCustomUserAgent was null, expected non-null int.');
           final String? arg_userAgent = (args[1] as String?);
           api.setCustomUserAgent(arg_identifier!, arg_userAgent);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1338,21 +1389,21 @@
               'Argument for dev.flutter.pigeon.WKWebViewHostApi.evaluateJavaScript was null, expected non-null String.');
           final Object? output = await api.evaluateJavaScript(
               arg_identifier!, arg_javaScriptString!);
-          return <Object?, Object?>{'result': output};
+          return <Object?>[output];
         });
       }
     }
   }
 }
 
-class _TestWKUIDelegateHostApiCodec extends StandardMessageCodec {
-  const _TestWKUIDelegateHostApiCodec();
-}
-
+/// Mirror of WKUIDelegate.
+///
+/// See https://developer.apple.com/documentation/webkit/wkuidelegate?language=objc.
 abstract class TestWKUIDelegateHostApi {
-  static const MessageCodec<Object?> codec = _TestWKUIDelegateHostApiCodec();
+  static const MessageCodec<Object?> codec = StandardMessageCodec();
 
   void create(int identifier);
+
   static void setup(TestWKUIDelegateHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -1370,7 +1421,7 @@
           assert(arg_identifier != null,
               'Argument for dev.flutter.pigeon.WKUIDelegateHostApi.create was null, expected non-null int.');
           api.create(arg_identifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1407,13 +1458,18 @@
   }
 }
 
+/// Mirror of WKHttpCookieStore.
+///
+/// See https://developer.apple.com/documentation/webkit/wkhttpcookiestore?language=objc.
 abstract class TestWKHttpCookieStoreHostApi {
   static const MessageCodec<Object?> codec =
       _TestWKHttpCookieStoreHostApiCodec();
 
   void createFromWebsiteDataStore(
       int identifier, int websiteDataStoreIdentifier);
+
   Future<void> setCookie(int identifier, NSHttpCookieData cookie);
+
   static void setup(TestWKHttpCookieStoreHostApi? api,
       {BinaryMessenger? binaryMessenger}) {
     {
@@ -1436,7 +1492,7 @@
               'Argument for dev.flutter.pigeon.WKHttpCookieStoreHostApi.createFromWebsiteDataStore was null, expected non-null int.');
           api.createFromWebsiteDataStore(
               arg_identifier!, arg_websiteDataStoreIdentifier!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
@@ -1458,7 +1514,7 @@
           assert(arg_cookie != null,
               'Argument for dev.flutter.pigeon.WKHttpCookieStoreHostApi.setCookie was null, expected non-null NSHttpCookieData.');
           await api.setCookie(arg_identifier!, arg_cookie!);
-          return <Object?, Object?>{};
+          return <Object?>[];
         });
       }
     }
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/test/src/web_kit/web_kit_test.dart b/packages/webview_flutter/webview_flutter_wkwebview/test/src/web_kit/web_kit_test.dart
index 4000e0d..a2b456e 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/test/src/web_kit/web_kit_test.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/test/src/web_kit/web_kit_test.dart
@@ -575,6 +575,7 @@
               allHttpHeaderFields: <String, String>{},
             ),
             targetFrame: WKFrameInfoData(isMainFrame: false),
+            navigationType: WKNavigationType.linkActivated,
           ),
         );
 
@@ -922,6 +923,7 @@
               allHttpHeaderFields: <String, String>{},
             ),
             targetFrame: WKFrameInfoData(isMainFrame: false),
+            navigationType: WKNavigationType.linkActivated,
           ),
         );
 
diff --git a/packages/webview_flutter/webview_flutter_wkwebview/test/webkit_navigation_delegate_test.dart b/packages/webview_flutter/webview_flutter_wkwebview/test/webkit_navigation_delegate_test.dart
index 731819f..62889b0 100644
--- a/packages/webview_flutter/webview_flutter_wkwebview/test/webkit_navigation_delegate_test.dart
+++ b/packages/webview_flutter/webview_flutter_wkwebview/test/webkit_navigation_delegate_test.dart
@@ -200,6 +200,7 @@
           const WKNavigationAction(
             request: NSUrlRequest(url: 'https://www.google.com'),
             targetFrame: WKFrameInfo(isMainFrame: false),
+            navigationType: WKNavigationType.linkActivated,
           ),
         ),
         completion(WKNavigationActionPolicy.allow),
@@ -229,6 +230,7 @@
         const WKNavigationAction(
           request: request,
           targetFrame: WKFrameInfo(isMainFrame: false),
+          navigationType: WKNavigationType.linkActivated,
         ),
       );