@onekeyfe/react-native-chart-webview 3.0.55 → 3.0.57

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/ChartWebview.podspec +3 -0
  2. package/android/src/main/java/com/margelo/nitro/chartwebview/ChartWebview.kt +85 -18
  3. package/android/src/main/java/com/margelo/nitro/chartwebview/PooledChartWebView.kt +185 -23
  4. package/ios/ChartWebview.swift +190 -31
  5. package/lib/nitrogen/generated/android/c++/JHybridChartWebviewSpec.cpp +18 -0
  6. package/lib/nitrogen/generated/android/c++/JHybridChartWebviewSpec.hpp +4 -0
  7. package/lib/nitrogen/generated/android/c++/views/JHybridChartWebviewStateUpdater.cpp +8 -0
  8. package/lib/nitrogen/generated/android/kotlin/com/margelo/nitro/chartwebview/HybridChartWebviewSpec.kt +12 -0
  9. package/lib/nitrogen/generated/ios/c++/HybridChartWebviewSpecSwift.hpp +14 -0
  10. package/lib/nitrogen/generated/ios/c++/views/HybridChartWebviewComponent.mm +10 -0
  11. package/lib/nitrogen/generated/ios/swift/HybridChartWebviewSpec.swift +2 -0
  12. package/lib/nitrogen/generated/ios/swift/HybridChartWebviewSpec_cxx.swift +48 -0
  13. package/lib/nitrogen/generated/shared/c++/HybridChartWebviewSpec.cpp +4 -0
  14. package/lib/nitrogen/generated/shared/c++/HybridChartWebviewSpec.hpp +4 -0
  15. package/lib/nitrogen/generated/shared/c++/views/HybridChartWebviewComponent.cpp +24 -0
  16. package/lib/nitrogen/generated/shared/c++/views/HybridChartWebviewComponent.hpp +2 -0
  17. package/lib/nitrogen/generated/shared/json/ChartWebviewConfig.json +2 -0
  18. package/lib/nitrogen/nitrogen/generated/android/c++/JHybridChartWebviewSpec.cpp +18 -0
  19. package/lib/nitrogen/nitrogen/generated/android/c++/JHybridChartWebviewSpec.hpp +4 -0
  20. package/lib/nitrogen/nitrogen/generated/android/c++/views/JHybridChartWebviewStateUpdater.cpp +8 -0
  21. package/lib/nitrogen/nitrogen/generated/android/kotlin/com/margelo/nitro/chartwebview/HybridChartWebviewSpec.kt +12 -0
  22. package/lib/nitrogen/nitrogen/generated/ios/c++/HybridChartWebviewSpecSwift.hpp +14 -0
  23. package/lib/nitrogen/nitrogen/generated/ios/c++/views/HybridChartWebviewComponent.mm +10 -0
  24. package/lib/nitrogen/nitrogen/generated/ios/swift/HybridChartWebviewSpec.swift +2 -0
  25. package/lib/nitrogen/nitrogen/generated/ios/swift/HybridChartWebviewSpec_cxx.swift +48 -0
  26. package/lib/nitrogen/nitrogen/generated/shared/c++/HybridChartWebviewSpec.cpp +4 -0
  27. package/lib/nitrogen/nitrogen/generated/shared/c++/HybridChartWebviewSpec.hpp +4 -0
  28. package/lib/nitrogen/nitrogen/generated/shared/c++/views/HybridChartWebviewComponent.cpp +24 -0
  29. package/lib/nitrogen/nitrogen/generated/shared/c++/views/HybridChartWebviewComponent.hpp +2 -0
  30. package/lib/nitrogen/nitrogen/generated/shared/json/ChartWebviewConfig.json +2 -0
  31. package/lib/typescript/src/ChartWebview.nitro.d.ts +2 -0
  32. package/lib/typescript/src/ChartWebview.nitro.d.ts.map +1 -1
  33. package/lib/typescript/src/index.d.ts +2 -0
  34. package/lib/typescript/src/index.d.ts.map +1 -1
  35. package/nitrogen/generated/android/c++/JHybridChartWebviewSpec.cpp +18 -0
  36. package/nitrogen/generated/android/c++/JHybridChartWebviewSpec.hpp +4 -0
  37. package/nitrogen/generated/android/c++/views/JHybridChartWebviewStateUpdater.cpp +8 -0
  38. package/nitrogen/generated/android/kotlin/com/margelo/nitro/chartwebview/HybridChartWebviewSpec.kt +12 -0
  39. package/nitrogen/generated/ios/c++/HybridChartWebviewSpecSwift.hpp +14 -0
  40. package/nitrogen/generated/ios/c++/views/HybridChartWebviewComponent.mm +10 -0
  41. package/nitrogen/generated/ios/swift/HybridChartWebviewSpec.swift +2 -0
  42. package/nitrogen/generated/ios/swift/HybridChartWebviewSpec_cxx.swift +48 -0
  43. package/nitrogen/generated/shared/c++/HybridChartWebviewSpec.cpp +4 -0
  44. package/nitrogen/generated/shared/c++/HybridChartWebviewSpec.hpp +4 -0
  45. package/nitrogen/generated/shared/c++/views/HybridChartWebviewComponent.cpp +24 -0
  46. package/nitrogen/generated/shared/c++/views/HybridChartWebviewComponent.hpp +2 -0
  47. package/nitrogen/generated/shared/json/ChartWebviewConfig.json +2 -0
  48. package/package.json +1 -1
  49. package/src/ChartWebview.nitro.ts +18 -0
@@ -54,6 +54,8 @@ namespace margelo::nitro::chartwebview {
54
54
  virtual void setEntry(const std::optional<std::string>& entry) = 0;
55
55
  virtual std::optional<std::string> getParamsJson() = 0;
56
56
  virtual void setParamsJson(const std::optional<std::string>& paramsJson) = 0;
57
+ virtual std::optional<std::string> getAssetHost() = 0;
58
+ virtual void setAssetHost(const std::optional<std::string>& assetHost) = 0;
57
59
  virtual std::optional<std::string> getBridgeScript() = 0;
58
60
  virtual void setBridgeScript(const std::optional<std::string>& bridgeScript) = 0;
59
61
  virtual std::optional<std::string> getReuseKey() = 0;
@@ -62,6 +64,8 @@ namespace margelo::nitro::chartwebview {
62
64
  virtual void setPooled(std::optional<bool> pooled) = 0;
63
65
  virtual std::optional<bool> getActive() = 0;
64
66
  virtual void setActive(std::optional<bool> active) = 0;
67
+ virtual std::optional<bool> getWebviewDebuggingEnabled() = 0;
68
+ virtual void setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) = 0;
65
69
  virtual std::optional<std::function<void(const std::string& /* message */)>> getOnMessage() = 0;
66
70
  virtual void setOnMessage(const std::optional<std::function<void(const std::string& /* message */)>>& onMessage) = 0;
67
71
  virtual std::optional<std::function<void()>> getOnLoadEnd() = 0;
@@ -65,6 +65,16 @@ namespace margelo::nitro::chartwebview::views {
65
65
  throw std::runtime_error(std::string("ChartWebview.paramsJson: ") + exc.what());
66
66
  }
67
67
  }()),
68
+ assetHost([&]() -> CachedProp<std::optional<std::string>> {
69
+ try {
70
+ const react::RawValue* rawValue = rawProps.at("assetHost", nullptr, nullptr);
71
+ if (rawValue == nullptr) return sourceProps.assetHost;
72
+ const auto& [runtime, value] = (std::pair<jsi::Runtime*, jsi::Value>)*rawValue;
73
+ return CachedProp<std::optional<std::string>>::fromRawValue(*runtime, value, sourceProps.assetHost);
74
+ } catch (const std::exception& exc) {
75
+ throw std::runtime_error(std::string("ChartWebview.assetHost: ") + exc.what());
76
+ }
77
+ }()),
68
78
  bridgeScript([&]() -> CachedProp<std::optional<std::string>> {
69
79
  try {
70
80
  const react::RawValue* rawValue = rawProps.at("bridgeScript", nullptr, nullptr);
@@ -105,6 +115,16 @@ namespace margelo::nitro::chartwebview::views {
105
115
  throw std::runtime_error(std::string("ChartWebview.active: ") + exc.what());
106
116
  }
107
117
  }()),
118
+ webviewDebuggingEnabled([&]() -> CachedProp<std::optional<bool>> {
119
+ try {
120
+ const react::RawValue* rawValue = rawProps.at("webviewDebuggingEnabled", nullptr, nullptr);
121
+ if (rawValue == nullptr) return sourceProps.webviewDebuggingEnabled;
122
+ const auto& [runtime, value] = (std::pair<jsi::Runtime*, jsi::Value>)*rawValue;
123
+ return CachedProp<std::optional<bool>>::fromRawValue(*runtime, value, sourceProps.webviewDebuggingEnabled);
124
+ } catch (const std::exception& exc) {
125
+ throw std::runtime_error(std::string("ChartWebview.webviewDebuggingEnabled: ") + exc.what());
126
+ }
127
+ }()),
108
128
  onMessage([&]() -> CachedProp<std::optional<std::function<void(const std::string& /* message */)>>> {
109
129
  try {
110
130
  const react::RawValue* rawValue = rawProps.at("onMessage", nullptr, nullptr);
@@ -152,10 +172,12 @@ namespace margelo::nitro::chartwebview::views {
152
172
  localBundle(other.localBundle),
153
173
  entry(other.entry),
154
174
  paramsJson(other.paramsJson),
175
+ assetHost(other.assetHost),
155
176
  bridgeScript(other.bridgeScript),
156
177
  reuseKey(other.reuseKey),
157
178
  pooled(other.pooled),
158
179
  active(other.active),
180
+ webviewDebuggingEnabled(other.webviewDebuggingEnabled),
159
181
  onMessage(other.onMessage),
160
182
  onLoadEnd(other.onLoadEnd),
161
183
  onError(other.onError),
@@ -167,10 +189,12 @@ namespace margelo::nitro::chartwebview::views {
167
189
  case hashString("localBundle"): return true;
168
190
  case hashString("entry"): return true;
169
191
  case hashString("paramsJson"): return true;
192
+ case hashString("assetHost"): return true;
170
193
  case hashString("bridgeScript"): return true;
171
194
  case hashString("reuseKey"): return true;
172
195
  case hashString("pooled"): return true;
173
196
  case hashString("active"): return true;
197
+ case hashString("webviewDebuggingEnabled"): return true;
174
198
  case hashString("onMessage"): return true;
175
199
  case hashString("onLoadEnd"): return true;
176
200
  case hashString("onError"): return true;
@@ -47,10 +47,12 @@ namespace margelo::nitro::chartwebview::views {
47
47
  CachedProp<std::optional<std::string>> localBundle;
48
48
  CachedProp<std::optional<std::string>> entry;
49
49
  CachedProp<std::optional<std::string>> paramsJson;
50
+ CachedProp<std::optional<std::string>> assetHost;
50
51
  CachedProp<std::optional<std::string>> bridgeScript;
51
52
  CachedProp<std::optional<std::string>> reuseKey;
52
53
  CachedProp<std::optional<bool>> pooled;
53
54
  CachedProp<std::optional<bool>> active;
55
+ CachedProp<std::optional<bool>> webviewDebuggingEnabled;
54
56
  CachedProp<std::optional<std::function<void(const std::string& /* message */)>>> onMessage;
55
57
  CachedProp<std::optional<std::function<void()>>> onLoadEnd;
56
58
  CachedProp<std::optional<std::function<void(const std::string& /* message */)>>> onError;
@@ -8,10 +8,12 @@
8
8
  "localBundle": true,
9
9
  "entry": true,
10
10
  "paramsJson": true,
11
+ "assetHost": true,
11
12
  "bridgeScript": true,
12
13
  "reuseKey": true,
13
14
  "pooled": true,
14
15
  "active": true,
16
+ "webviewDebuggingEnabled": true,
15
17
  "onMessage": true,
16
18
  "onLoadEnd": true,
17
19
  "onError": true,
@@ -81,6 +81,15 @@ namespace margelo::nitro::chartwebview {
81
81
  static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JString> /* paramsJson */)>("setParamsJson");
82
82
  method(_javaPart, paramsJson.has_value() ? jni::make_jstring(paramsJson.value()) : nullptr);
83
83
  }
84
+ std::optional<std::string> JHybridChartWebviewSpec::getAssetHost() {
85
+ static const auto method = javaClassStatic()->getMethod<jni::local_ref<jni::JString>()>("getAssetHost");
86
+ auto __result = method(_javaPart);
87
+ return __result != nullptr ? std::make_optional(__result->toStdString()) : std::nullopt;
88
+ }
89
+ void JHybridChartWebviewSpec::setAssetHost(const std::optional<std::string>& assetHost) {
90
+ static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JString> /* assetHost */)>("setAssetHost");
91
+ method(_javaPart, assetHost.has_value() ? jni::make_jstring(assetHost.value()) : nullptr);
92
+ }
84
93
  std::optional<std::string> JHybridChartWebviewSpec::getBridgeScript() {
85
94
  static const auto method = javaClassStatic()->getMethod<jni::local_ref<jni::JString>()>("getBridgeScript");
86
95
  auto __result = method(_javaPart);
@@ -117,6 +126,15 @@ namespace margelo::nitro::chartwebview {
117
126
  static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* active */)>("setActive");
118
127
  method(_javaPart, active.has_value() ? jni::JBoolean::valueOf(active.value()) : nullptr);
119
128
  }
129
+ std::optional<bool> JHybridChartWebviewSpec::getWebviewDebuggingEnabled() {
130
+ static const auto method = javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getWebviewDebuggingEnabled");
131
+ auto __result = method(_javaPart);
132
+ return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
133
+ }
134
+ void JHybridChartWebviewSpec::setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) {
135
+ static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* webviewDebuggingEnabled */)>("setWebviewDebuggingEnabled");
136
+ method(_javaPart, webviewDebuggingEnabled.has_value() ? jni::JBoolean::valueOf(webviewDebuggingEnabled.value()) : nullptr);
137
+ }
120
138
  std::optional<std::function<void(const std::string& /* message */)>> JHybridChartWebviewSpec::getOnMessage() {
121
139
  static const auto method = javaClassStatic()->getMethod<jni::local_ref<JFunc_void_std__string::javaobject>()>("getOnMessage_cxx");
122
140
  auto __result = method(_javaPart);
@@ -58,6 +58,8 @@ namespace margelo::nitro::chartwebview {
58
58
  void setEntry(const std::optional<std::string>& entry) override;
59
59
  std::optional<std::string> getParamsJson() override;
60
60
  void setParamsJson(const std::optional<std::string>& paramsJson) override;
61
+ std::optional<std::string> getAssetHost() override;
62
+ void setAssetHost(const std::optional<std::string>& assetHost) override;
61
63
  std::optional<std::string> getBridgeScript() override;
62
64
  void setBridgeScript(const std::optional<std::string>& bridgeScript) override;
63
65
  std::optional<std::string> getReuseKey() override;
@@ -66,6 +68,8 @@ namespace margelo::nitro::chartwebview {
66
68
  void setPooled(std::optional<bool> pooled) override;
67
69
  std::optional<bool> getActive() override;
68
70
  void setActive(std::optional<bool> active) override;
71
+ std::optional<bool> getWebviewDebuggingEnabled() override;
72
+ void setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) override;
69
73
  std::optional<std::function<void(const std::string& /* message */)>> getOnMessage() override;
70
74
  void setOnMessage(const std::optional<std::function<void(const std::string& /* message */)>>& onMessage) override;
71
75
  std::optional<std::function<void()>> getOnLoadEnd() override;
@@ -52,6 +52,10 @@ void JHybridChartWebviewStateUpdater::updateViewProps(jni::alias_ref<jni::JClass
52
52
  view->setParamsJson(props.paramsJson.value);
53
53
  // TODO: Set isDirty = false
54
54
  }
55
+ if (props.assetHost.isDirty) {
56
+ view->setAssetHost(props.assetHost.value);
57
+ // TODO: Set isDirty = false
58
+ }
55
59
  if (props.bridgeScript.isDirty) {
56
60
  view->setBridgeScript(props.bridgeScript.value);
57
61
  // TODO: Set isDirty = false
@@ -68,6 +72,10 @@ void JHybridChartWebviewStateUpdater::updateViewProps(jni::alias_ref<jni::JClass
68
72
  view->setActive(props.active.value);
69
73
  // TODO: Set isDirty = false
70
74
  }
75
+ if (props.webviewDebuggingEnabled.isDirty) {
76
+ view->setWebviewDebuggingEnabled(props.webviewDebuggingEnabled.value);
77
+ // TODO: Set isDirty = false
78
+ }
71
79
  if (props.onMessage.isDirty) {
72
80
  view->setOnMessage(props.onMessage.value);
73
81
  // TODO: Set isDirty = false
@@ -66,6 +66,12 @@ abstract class HybridChartWebviewSpec: HybridView() {
66
66
  @set:Keep
67
67
  abstract var paramsJson: String?
68
68
 
69
+ @get:DoNotStrip
70
+ @get:Keep
71
+ @set:DoNotStrip
72
+ @set:Keep
73
+ abstract var assetHost: String?
74
+
69
75
  @get:DoNotStrip
70
76
  @get:Keep
71
77
  @set:DoNotStrip
@@ -90,6 +96,12 @@ abstract class HybridChartWebviewSpec: HybridView() {
90
96
  @set:Keep
91
97
  abstract var active: Boolean?
92
98
 
99
+ @get:DoNotStrip
100
+ @get:Keep
101
+ @set:DoNotStrip
102
+ @set:Keep
103
+ abstract var webviewDebuggingEnabled: Boolean?
104
+
93
105
  abstract var onMessage: ((message: String) -> Unit)?
94
106
 
95
107
  private var onMessage_cxx: Func_void_std__string?
@@ -86,6 +86,13 @@ namespace margelo::nitro::chartwebview {
86
86
  inline void setParamsJson(const std::optional<std::string>& paramsJson) noexcept override {
87
87
  _swiftPart.setParamsJson(paramsJson);
88
88
  }
89
+ inline std::optional<std::string> getAssetHost() noexcept override {
90
+ auto __result = _swiftPart.getAssetHost();
91
+ return __result;
92
+ }
93
+ inline void setAssetHost(const std::optional<std::string>& assetHost) noexcept override {
94
+ _swiftPart.setAssetHost(assetHost);
95
+ }
89
96
  inline std::optional<std::string> getBridgeScript() noexcept override {
90
97
  auto __result = _swiftPart.getBridgeScript();
91
98
  return __result;
@@ -114,6 +121,13 @@ namespace margelo::nitro::chartwebview {
114
121
  inline void setActive(std::optional<bool> active) noexcept override {
115
122
  _swiftPart.setActive(active);
116
123
  }
124
+ inline std::optional<bool> getWebviewDebuggingEnabled() noexcept override {
125
+ auto __result = _swiftPart.getWebviewDebuggingEnabled();
126
+ return __result;
127
+ }
128
+ inline void setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) noexcept override {
129
+ _swiftPart.setWebviewDebuggingEnabled(webviewDebuggingEnabled);
130
+ }
117
131
  inline std::optional<std::function<void(const std::string& /* message */)>> getOnMessage() noexcept override {
118
132
  auto __result = _swiftPart.getOnMessage();
119
133
  return __result;
@@ -91,6 +91,11 @@ using namespace margelo::nitro::chartwebview::views;
91
91
  swiftPart.setParamsJson(newViewProps.paramsJson.value);
92
92
  newViewProps.paramsJson.isDirty = false;
93
93
  }
94
+ // assetHost: optional
95
+ if (newViewProps.assetHost.isDirty) {
96
+ swiftPart.setAssetHost(newViewProps.assetHost.value);
97
+ newViewProps.assetHost.isDirty = false;
98
+ }
94
99
  // bridgeScript: optional
95
100
  if (newViewProps.bridgeScript.isDirty) {
96
101
  swiftPart.setBridgeScript(newViewProps.bridgeScript.value);
@@ -111,6 +116,11 @@ using namespace margelo::nitro::chartwebview::views;
111
116
  swiftPart.setActive(newViewProps.active.value);
112
117
  newViewProps.active.isDirty = false;
113
118
  }
119
+ // webviewDebuggingEnabled: optional
120
+ if (newViewProps.webviewDebuggingEnabled.isDirty) {
121
+ swiftPart.setWebviewDebuggingEnabled(newViewProps.webviewDebuggingEnabled.value);
122
+ newViewProps.webviewDebuggingEnabled.isDirty = false;
123
+ }
114
124
  // onMessage: optional
115
125
  if (newViewProps.onMessage.isDirty) {
116
126
  swiftPart.setOnMessage(newViewProps.onMessage.value);
@@ -15,10 +15,12 @@ public protocol HybridChartWebviewSpec_protocol: HybridObject, HybridView {
15
15
  var localBundle: String? { get set }
16
16
  var entry: String? { get set }
17
17
  var paramsJson: String? { get set }
18
+ var assetHost: String? { get set }
18
19
  var bridgeScript: String? { get set }
19
20
  var reuseKey: String? { get set }
20
21
  var pooled: Bool? { get set }
21
22
  var active: Bool? { get set }
23
+ var webviewDebuggingEnabled: Bool? { get set }
22
24
  var onMessage: ((_ message: String) -> Void)? { get set }
23
25
  var onLoadEnd: (() -> Void)? { get set }
24
26
  var onError: ((_ message: String) -> Void)? { get set }
@@ -210,6 +210,30 @@ open class HybridChartWebviewSpec_cxx {
210
210
  }
211
211
  }
212
212
 
213
+ public final var assetHost: bridge.std__optional_std__string_ {
214
+ @inline(__always)
215
+ get {
216
+ return { () -> bridge.std__optional_std__string_ in
217
+ if let __unwrappedValue = self.__implementation.assetHost {
218
+ return bridge.create_std__optional_std__string_(std.string(__unwrappedValue))
219
+ } else {
220
+ return .init()
221
+ }
222
+ }()
223
+ }
224
+ @inline(__always)
225
+ set {
226
+ self.__implementation.assetHost = { () -> String? in
227
+ if bridge.has_value_std__optional_std__string_(newValue) {
228
+ let __unwrapped = bridge.get_std__optional_std__string_(newValue)
229
+ return String(__unwrapped)
230
+ } else {
231
+ return nil
232
+ }
233
+ }()
234
+ }
235
+ }
236
+
213
237
  public final var bridgeScript: bridge.std__optional_std__string_ {
214
238
  @inline(__always)
215
239
  get {
@@ -306,6 +330,30 @@ open class HybridChartWebviewSpec_cxx {
306
330
  }
307
331
  }
308
332
 
333
+ public final var webviewDebuggingEnabled: bridge.std__optional_bool_ {
334
+ @inline(__always)
335
+ get {
336
+ return { () -> bridge.std__optional_bool_ in
337
+ if let __unwrappedValue = self.__implementation.webviewDebuggingEnabled {
338
+ return bridge.create_std__optional_bool_(__unwrappedValue)
339
+ } else {
340
+ return .init()
341
+ }
342
+ }()
343
+ }
344
+ @inline(__always)
345
+ set {
346
+ self.__implementation.webviewDebuggingEnabled = { () -> Bool? in
347
+ if bridge.has_value_std__optional_bool_(newValue) {
348
+ let __unwrapped = bridge.get_std__optional_bool_(newValue)
349
+ return __unwrapped
350
+ } else {
351
+ return nil
352
+ }
353
+ }()
354
+ }
355
+ }
356
+
309
357
  public final var onMessage: bridge.std__optional_std__function_void_const_std__string_____message______ {
310
358
  @inline(__always)
311
359
  get {
@@ -22,6 +22,8 @@ namespace margelo::nitro::chartwebview {
22
22
  prototype.registerHybridSetter("entry", &HybridChartWebviewSpec::setEntry);
23
23
  prototype.registerHybridGetter("paramsJson", &HybridChartWebviewSpec::getParamsJson);
24
24
  prototype.registerHybridSetter("paramsJson", &HybridChartWebviewSpec::setParamsJson);
25
+ prototype.registerHybridGetter("assetHost", &HybridChartWebviewSpec::getAssetHost);
26
+ prototype.registerHybridSetter("assetHost", &HybridChartWebviewSpec::setAssetHost);
25
27
  prototype.registerHybridGetter("bridgeScript", &HybridChartWebviewSpec::getBridgeScript);
26
28
  prototype.registerHybridSetter("bridgeScript", &HybridChartWebviewSpec::setBridgeScript);
27
29
  prototype.registerHybridGetter("reuseKey", &HybridChartWebviewSpec::getReuseKey);
@@ -30,6 +32,8 @@ namespace margelo::nitro::chartwebview {
30
32
  prototype.registerHybridSetter("pooled", &HybridChartWebviewSpec::setPooled);
31
33
  prototype.registerHybridGetter("active", &HybridChartWebviewSpec::getActive);
32
34
  prototype.registerHybridSetter("active", &HybridChartWebviewSpec::setActive);
35
+ prototype.registerHybridGetter("webviewDebuggingEnabled", &HybridChartWebviewSpec::getWebviewDebuggingEnabled);
36
+ prototype.registerHybridSetter("webviewDebuggingEnabled", &HybridChartWebviewSpec::setWebviewDebuggingEnabled);
33
37
  prototype.registerHybridGetter("onMessage", &HybridChartWebviewSpec::getOnMessage);
34
38
  prototype.registerHybridSetter("onMessage", &HybridChartWebviewSpec::setOnMessage);
35
39
  prototype.registerHybridGetter("onLoadEnd", &HybridChartWebviewSpec::getOnLoadEnd);
@@ -54,6 +54,8 @@ namespace margelo::nitro::chartwebview {
54
54
  virtual void setEntry(const std::optional<std::string>& entry) = 0;
55
55
  virtual std::optional<std::string> getParamsJson() = 0;
56
56
  virtual void setParamsJson(const std::optional<std::string>& paramsJson) = 0;
57
+ virtual std::optional<std::string> getAssetHost() = 0;
58
+ virtual void setAssetHost(const std::optional<std::string>& assetHost) = 0;
57
59
  virtual std::optional<std::string> getBridgeScript() = 0;
58
60
  virtual void setBridgeScript(const std::optional<std::string>& bridgeScript) = 0;
59
61
  virtual std::optional<std::string> getReuseKey() = 0;
@@ -62,6 +64,8 @@ namespace margelo::nitro::chartwebview {
62
64
  virtual void setPooled(std::optional<bool> pooled) = 0;
63
65
  virtual std::optional<bool> getActive() = 0;
64
66
  virtual void setActive(std::optional<bool> active) = 0;
67
+ virtual std::optional<bool> getWebviewDebuggingEnabled() = 0;
68
+ virtual void setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) = 0;
65
69
  virtual std::optional<std::function<void(const std::string& /* message */)>> getOnMessage() = 0;
66
70
  virtual void setOnMessage(const std::optional<std::function<void(const std::string& /* message */)>>& onMessage) = 0;
67
71
  virtual std::optional<std::function<void()>> getOnLoadEnd() = 0;
@@ -65,6 +65,16 @@ namespace margelo::nitro::chartwebview::views {
65
65
  throw std::runtime_error(std::string("ChartWebview.paramsJson: ") + exc.what());
66
66
  }
67
67
  }()),
68
+ assetHost([&]() -> CachedProp<std::optional<std::string>> {
69
+ try {
70
+ const react::RawValue* rawValue = rawProps.at("assetHost", nullptr, nullptr);
71
+ if (rawValue == nullptr) return sourceProps.assetHost;
72
+ const auto& [runtime, value] = (std::pair<jsi::Runtime*, jsi::Value>)*rawValue;
73
+ return CachedProp<std::optional<std::string>>::fromRawValue(*runtime, value, sourceProps.assetHost);
74
+ } catch (const std::exception& exc) {
75
+ throw std::runtime_error(std::string("ChartWebview.assetHost: ") + exc.what());
76
+ }
77
+ }()),
68
78
  bridgeScript([&]() -> CachedProp<std::optional<std::string>> {
69
79
  try {
70
80
  const react::RawValue* rawValue = rawProps.at("bridgeScript", nullptr, nullptr);
@@ -105,6 +115,16 @@ namespace margelo::nitro::chartwebview::views {
105
115
  throw std::runtime_error(std::string("ChartWebview.active: ") + exc.what());
106
116
  }
107
117
  }()),
118
+ webviewDebuggingEnabled([&]() -> CachedProp<std::optional<bool>> {
119
+ try {
120
+ const react::RawValue* rawValue = rawProps.at("webviewDebuggingEnabled", nullptr, nullptr);
121
+ if (rawValue == nullptr) return sourceProps.webviewDebuggingEnabled;
122
+ const auto& [runtime, value] = (std::pair<jsi::Runtime*, jsi::Value>)*rawValue;
123
+ return CachedProp<std::optional<bool>>::fromRawValue(*runtime, value, sourceProps.webviewDebuggingEnabled);
124
+ } catch (const std::exception& exc) {
125
+ throw std::runtime_error(std::string("ChartWebview.webviewDebuggingEnabled: ") + exc.what());
126
+ }
127
+ }()),
108
128
  onMessage([&]() -> CachedProp<std::optional<std::function<void(const std::string& /* message */)>>> {
109
129
  try {
110
130
  const react::RawValue* rawValue = rawProps.at("onMessage", nullptr, nullptr);
@@ -152,10 +172,12 @@ namespace margelo::nitro::chartwebview::views {
152
172
  localBundle(other.localBundle),
153
173
  entry(other.entry),
154
174
  paramsJson(other.paramsJson),
175
+ assetHost(other.assetHost),
155
176
  bridgeScript(other.bridgeScript),
156
177
  reuseKey(other.reuseKey),
157
178
  pooled(other.pooled),
158
179
  active(other.active),
180
+ webviewDebuggingEnabled(other.webviewDebuggingEnabled),
159
181
  onMessage(other.onMessage),
160
182
  onLoadEnd(other.onLoadEnd),
161
183
  onError(other.onError),
@@ -167,10 +189,12 @@ namespace margelo::nitro::chartwebview::views {
167
189
  case hashString("localBundle"): return true;
168
190
  case hashString("entry"): return true;
169
191
  case hashString("paramsJson"): return true;
192
+ case hashString("assetHost"): return true;
170
193
  case hashString("bridgeScript"): return true;
171
194
  case hashString("reuseKey"): return true;
172
195
  case hashString("pooled"): return true;
173
196
  case hashString("active"): return true;
197
+ case hashString("webviewDebuggingEnabled"): return true;
174
198
  case hashString("onMessage"): return true;
175
199
  case hashString("onLoadEnd"): return true;
176
200
  case hashString("onError"): return true;
@@ -47,10 +47,12 @@ namespace margelo::nitro::chartwebview::views {
47
47
  CachedProp<std::optional<std::string>> localBundle;
48
48
  CachedProp<std::optional<std::string>> entry;
49
49
  CachedProp<std::optional<std::string>> paramsJson;
50
+ CachedProp<std::optional<std::string>> assetHost;
50
51
  CachedProp<std::optional<std::string>> bridgeScript;
51
52
  CachedProp<std::optional<std::string>> reuseKey;
52
53
  CachedProp<std::optional<bool>> pooled;
53
54
  CachedProp<std::optional<bool>> active;
55
+ CachedProp<std::optional<bool>> webviewDebuggingEnabled;
54
56
  CachedProp<std::optional<std::function<void(const std::string& /* message */)>>> onMessage;
55
57
  CachedProp<std::optional<std::function<void()>>> onLoadEnd;
56
58
  CachedProp<std::optional<std::function<void(const std::string& /* message */)>>> onError;
@@ -8,10 +8,12 @@
8
8
  "localBundle": true,
9
9
  "entry": true,
10
10
  "paramsJson": true,
11
+ "assetHost": true,
11
12
  "bridgeScript": true,
12
13
  "reuseKey": true,
13
14
  "pooled": true,
14
15
  "active": true,
16
+ "webviewDebuggingEnabled": true,
15
17
  "onMessage": true,
16
18
  "onLoadEnd": true,
17
19
  "onError": true,
@@ -4,10 +4,12 @@ export interface ChartWebviewProps extends HybridViewProps {
4
4
  localBundle?: string;
5
5
  entry?: string;
6
6
  paramsJson?: string;
7
+ assetHost?: string;
7
8
  bridgeScript?: string;
8
9
  reuseKey?: string;
9
10
  pooled?: boolean;
10
11
  active?: boolean;
12
+ webviewDebuggingEnabled?: boolean;
11
13
  onMessage?: (message: string) => void;
12
14
  onLoadEnd?: () => void;
13
15
  onError?: (message: string) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"ChartWebview.nitro.d.ts","sourceRoot":"","sources":["../../../src/ChartWebview.nitro.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,iBAAiB,EACjB,eAAe,EAChB,MAAM,4BAA4B,CAAC;AAKpC,MAAM,WAAW,iBAAkB,SAAQ,eAAe;IAGxD,GAAG,CAAC,EAAE,MAAM,CAAC;IAIb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IAIf,UAAU,CAAC,EAAE,MAAM,CAAC;IAMpB,YAAY,CAAC,EAAE,MAAM,CAAC;IAItB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,MAAM,CAAC,EAAE,OAAO,CAAC;IAMjB,MAAM,CAAC,EAAE,OAAO,CAAC;IAIjB,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC;AAED,MAAM,WAAW,mBAAoB,SAAQ,iBAAiB;IAG5D,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,MAAM,IAAI,IAAI,CAAC;IAGf,aAAa,IAAI,IAAI,CAAC;CACvB;AAED,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,iBAAiB,EAAE,mBAAmB,CAAC,CAAC"}
1
+ {"version":3,"file":"ChartWebview.nitro.d.ts","sourceRoot":"","sources":["../../../src/ChartWebview.nitro.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,iBAAiB,EACjB,eAAe,EAChB,MAAM,4BAA4B,CAAC;AAKpC,MAAM,WAAW,iBAAkB,SAAQ,eAAe;IAGxD,GAAG,CAAC,EAAE,MAAM,CAAC;IAIb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IAIf,UAAU,CAAC,EAAE,MAAM,CAAC;IAQpB,SAAS,CAAC,EAAE,MAAM,CAAC;IAMnB,YAAY,CAAC,EAAE,MAAM,CAAC;IAItB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,MAAM,CAAC,EAAE,OAAO,CAAC;IAMjB,MAAM,CAAC,EAAE,OAAO,CAAC;IAUjB,uBAAuB,CAAC,EAAE,OAAO,CAAC;IAIlC,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CACrC;AAED,MAAM,WAAW,mBAAoB,SAAQ,iBAAiB;IAG5D,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACnC,MAAM,IAAI,IAAI,CAAC;IAGf,aAAa,IAAI,IAAI,CAAC;CACvB;AAED,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,iBAAiB,EAAE,mBAAmB,CAAC,CAAC"}
@@ -16,10 +16,12 @@ export declare function ChartWebviewView({ bridgeScript, hybridRef, onMessage, o
16
16
  localBundle?: string | undefined;
17
17
  entry?: string | undefined;
18
18
  paramsJson?: string | undefined;
19
+ assetHost?: string | undefined;
19
20
  bridgeScript?: string | undefined;
20
21
  reuseKey?: string | undefined;
21
22
  pooled?: boolean | undefined;
22
23
  active?: boolean | undefined;
24
+ webviewDebuggingEnabled?: boolean | undefined;
23
25
  onMessage?: NitroViewWrappedCallback<((message: string) => void) | undefined> | undefined;
24
26
  onLoadEnd?: NitroViewWrappedCallback<(() => void) | undefined> | undefined;
25
27
  onError?: NitroViewWrappedCallback<((message: string) => void) | undefined> | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAGL,KAAK,wBAAwB,EAC9B,MAAM,4BAA4B,CAAC;AAEpC,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAGnF,YAAY,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACnF,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAO3C,KAAK,oBAAoB,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,IACxD,CAAC,GACD,wBAAwB,CAAC,CAAC,CAAC,CAAC;AAEhC,KAAK,qBAAqB,GAAG,IAAI,CAC/B,iBAAiB,EACjB,WAAW,GAAG,WAAW,GAAG,SAAS,CACtC,GACC,SAAS,GAAG;IACV,SAAS,CAAC,EAAE,oBAAoB,CAAC,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAC,CAAC;IACrD,SAAS,CAAC,EAAE,oBAAoB,CAAC,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC,CAAC;IAC5D,SAAS,CAAC,EAAE,oBAAoB,CAAC,MAAM,IAAI,CAAC,CAAC;IAC7C,OAAO,CAAC,EAAE,oBAAoB,CAAC,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC,CAAC;CAC3D,CAAC;AAcJ,wBAAgB,gBAAgB,CAAC,EAC/B,YAAY,EACZ,SAAS,EACT,SAAS,EACT,SAAS,EACT,OAAO,EACP,GAAG,KAAK,EACT,EAAE,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDvB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAGL,KAAK,wBAAwB,EAC9B,MAAM,4BAA4B,CAAC;AAEpC,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAGnF,YAAY,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACnF,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAO3C,KAAK,oBAAoB,CAAC,CAAC,SAAS,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,IAAI,IACxD,CAAC,GACD,wBAAwB,CAAC,CAAC,CAAC,CAAC;AAEhC,KAAK,qBAAqB,GAAG,IAAI,CAC/B,iBAAiB,EACjB,WAAW,GAAG,WAAW,GAAG,SAAS,CACtC,GACC,SAAS,GAAG;IACV,SAAS,CAAC,EAAE,oBAAoB,CAAC,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAC,CAAC;IACrD,SAAS,CAAC,EAAE,oBAAoB,CAAC,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC,CAAC;IAC5D,SAAS,CAAC,EAAE,oBAAoB,CAAC,MAAM,IAAI,CAAC,CAAC;IAC7C,OAAO,CAAC,EAAE,oBAAoB,CAAC,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC,CAAC;CAC3D,CAAC;AAcJ,wBAAgB,gBAAgB,CAAC,EAC/B,YAAY,EACZ,SAAS,EACT,SAAS,EACT,SAAS,EACT,OAAO,EACP,GAAG,KAAK,EACT,EAAE,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqDvB"}
@@ -81,6 +81,15 @@ namespace margelo::nitro::chartwebview {
81
81
  static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JString> /* paramsJson */)>("setParamsJson");
82
82
  method(_javaPart, paramsJson.has_value() ? jni::make_jstring(paramsJson.value()) : nullptr);
83
83
  }
84
+ std::optional<std::string> JHybridChartWebviewSpec::getAssetHost() {
85
+ static const auto method = javaClassStatic()->getMethod<jni::local_ref<jni::JString>()>("getAssetHost");
86
+ auto __result = method(_javaPart);
87
+ return __result != nullptr ? std::make_optional(__result->toStdString()) : std::nullopt;
88
+ }
89
+ void JHybridChartWebviewSpec::setAssetHost(const std::optional<std::string>& assetHost) {
90
+ static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JString> /* assetHost */)>("setAssetHost");
91
+ method(_javaPart, assetHost.has_value() ? jni::make_jstring(assetHost.value()) : nullptr);
92
+ }
84
93
  std::optional<std::string> JHybridChartWebviewSpec::getBridgeScript() {
85
94
  static const auto method = javaClassStatic()->getMethod<jni::local_ref<jni::JString>()>("getBridgeScript");
86
95
  auto __result = method(_javaPart);
@@ -117,6 +126,15 @@ namespace margelo::nitro::chartwebview {
117
126
  static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* active */)>("setActive");
118
127
  method(_javaPart, active.has_value() ? jni::JBoolean::valueOf(active.value()) : nullptr);
119
128
  }
129
+ std::optional<bool> JHybridChartWebviewSpec::getWebviewDebuggingEnabled() {
130
+ static const auto method = javaClassStatic()->getMethod<jni::local_ref<jni::JBoolean>()>("getWebviewDebuggingEnabled");
131
+ auto __result = method(_javaPart);
132
+ return __result != nullptr ? std::make_optional(static_cast<bool>(__result->value())) : std::nullopt;
133
+ }
134
+ void JHybridChartWebviewSpec::setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) {
135
+ static const auto method = javaClassStatic()->getMethod<void(jni::alias_ref<jni::JBoolean> /* webviewDebuggingEnabled */)>("setWebviewDebuggingEnabled");
136
+ method(_javaPart, webviewDebuggingEnabled.has_value() ? jni::JBoolean::valueOf(webviewDebuggingEnabled.value()) : nullptr);
137
+ }
120
138
  std::optional<std::function<void(const std::string& /* message */)>> JHybridChartWebviewSpec::getOnMessage() {
121
139
  static const auto method = javaClassStatic()->getMethod<jni::local_ref<JFunc_void_std__string::javaobject>()>("getOnMessage_cxx");
122
140
  auto __result = method(_javaPart);
@@ -58,6 +58,8 @@ namespace margelo::nitro::chartwebview {
58
58
  void setEntry(const std::optional<std::string>& entry) override;
59
59
  std::optional<std::string> getParamsJson() override;
60
60
  void setParamsJson(const std::optional<std::string>& paramsJson) override;
61
+ std::optional<std::string> getAssetHost() override;
62
+ void setAssetHost(const std::optional<std::string>& assetHost) override;
61
63
  std::optional<std::string> getBridgeScript() override;
62
64
  void setBridgeScript(const std::optional<std::string>& bridgeScript) override;
63
65
  std::optional<std::string> getReuseKey() override;
@@ -66,6 +68,8 @@ namespace margelo::nitro::chartwebview {
66
68
  void setPooled(std::optional<bool> pooled) override;
67
69
  std::optional<bool> getActive() override;
68
70
  void setActive(std::optional<bool> active) override;
71
+ std::optional<bool> getWebviewDebuggingEnabled() override;
72
+ void setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) override;
69
73
  std::optional<std::function<void(const std::string& /* message */)>> getOnMessage() override;
70
74
  void setOnMessage(const std::optional<std::function<void(const std::string& /* message */)>>& onMessage) override;
71
75
  std::optional<std::function<void()>> getOnLoadEnd() override;
@@ -52,6 +52,10 @@ void JHybridChartWebviewStateUpdater::updateViewProps(jni::alias_ref<jni::JClass
52
52
  view->setParamsJson(props.paramsJson.value);
53
53
  // TODO: Set isDirty = false
54
54
  }
55
+ if (props.assetHost.isDirty) {
56
+ view->setAssetHost(props.assetHost.value);
57
+ // TODO: Set isDirty = false
58
+ }
55
59
  if (props.bridgeScript.isDirty) {
56
60
  view->setBridgeScript(props.bridgeScript.value);
57
61
  // TODO: Set isDirty = false
@@ -68,6 +72,10 @@ void JHybridChartWebviewStateUpdater::updateViewProps(jni::alias_ref<jni::JClass
68
72
  view->setActive(props.active.value);
69
73
  // TODO: Set isDirty = false
70
74
  }
75
+ if (props.webviewDebuggingEnabled.isDirty) {
76
+ view->setWebviewDebuggingEnabled(props.webviewDebuggingEnabled.value);
77
+ // TODO: Set isDirty = false
78
+ }
71
79
  if (props.onMessage.isDirty) {
72
80
  view->setOnMessage(props.onMessage.value);
73
81
  // TODO: Set isDirty = false
@@ -66,6 +66,12 @@ abstract class HybridChartWebviewSpec: HybridView() {
66
66
  @set:Keep
67
67
  abstract var paramsJson: String?
68
68
 
69
+ @get:DoNotStrip
70
+ @get:Keep
71
+ @set:DoNotStrip
72
+ @set:Keep
73
+ abstract var assetHost: String?
74
+
69
75
  @get:DoNotStrip
70
76
  @get:Keep
71
77
  @set:DoNotStrip
@@ -90,6 +96,12 @@ abstract class HybridChartWebviewSpec: HybridView() {
90
96
  @set:Keep
91
97
  abstract var active: Boolean?
92
98
 
99
+ @get:DoNotStrip
100
+ @get:Keep
101
+ @set:DoNotStrip
102
+ @set:Keep
103
+ abstract var webviewDebuggingEnabled: Boolean?
104
+
93
105
  abstract var onMessage: ((message: String) -> Unit)?
94
106
 
95
107
  private var onMessage_cxx: Func_void_std__string?
@@ -86,6 +86,13 @@ namespace margelo::nitro::chartwebview {
86
86
  inline void setParamsJson(const std::optional<std::string>& paramsJson) noexcept override {
87
87
  _swiftPart.setParamsJson(paramsJson);
88
88
  }
89
+ inline std::optional<std::string> getAssetHost() noexcept override {
90
+ auto __result = _swiftPart.getAssetHost();
91
+ return __result;
92
+ }
93
+ inline void setAssetHost(const std::optional<std::string>& assetHost) noexcept override {
94
+ _swiftPart.setAssetHost(assetHost);
95
+ }
89
96
  inline std::optional<std::string> getBridgeScript() noexcept override {
90
97
  auto __result = _swiftPart.getBridgeScript();
91
98
  return __result;
@@ -114,6 +121,13 @@ namespace margelo::nitro::chartwebview {
114
121
  inline void setActive(std::optional<bool> active) noexcept override {
115
122
  _swiftPart.setActive(active);
116
123
  }
124
+ inline std::optional<bool> getWebviewDebuggingEnabled() noexcept override {
125
+ auto __result = _swiftPart.getWebviewDebuggingEnabled();
126
+ return __result;
127
+ }
128
+ inline void setWebviewDebuggingEnabled(std::optional<bool> webviewDebuggingEnabled) noexcept override {
129
+ _swiftPart.setWebviewDebuggingEnabled(webviewDebuggingEnabled);
130
+ }
117
131
  inline std::optional<std::function<void(const std::string& /* message */)>> getOnMessage() noexcept override {
118
132
  auto __result = _swiftPart.getOnMessage();
119
133
  return __result;