From 64d2098ce2ab8efd4f245c15db36e20a841d5baa Mon Sep 17 00:00:00 2001 From: Hubert Bieszczad Date: Mon, 20 Jan 2025 10:34:14 +0100 Subject: [PATCH] fix: handle cssvars in native settings --- cxx/hybridObjects/HybridStyleSheet.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/cxx/hybridObjects/HybridStyleSheet.cpp b/cxx/hybridObjects/HybridStyleSheet.cpp index bda0f44e..5794360f 100644 --- a/cxx/hybridObjects/HybridStyleSheet.cpp +++ b/cxx/hybridObjects/HybridStyleSheet.cpp @@ -118,6 +118,10 @@ void HybridStyleSheet::parseSettings(jsi::Runtime &rt, jsi::Object settings) { return; } + if (propertyName == "CSSVars") { + return; + } + helpers::assertThat(rt, false, "StyleSheet.configure's settings received unexpected key: '" + std::string(propertyName) + "'"); }); } @@ -255,13 +259,13 @@ void HybridStyleSheet::onPlatformDependenciesChange(std::vectornotifyJSListeners(dependencies); @@ -306,13 +310,13 @@ void HybridStyleSheet::onPlatformNativeDependenciesChange(std::vectornotifyJSListeners(unistyleDependencies);