@sency/react-native-smkit-ui 2.1.0 → 2.1.1
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.
- package/android/build/intermediates/incremental/debug/packageDebugResources/compile-file-map.properties +1 -0
- package/android/build/intermediates/incremental/debug/packageDebugResources/merger.xml +2 -0
- package/android/build/intermediates/incremental/mergeDebugJniLibFolders/merger.xml +2 -0
- package/android/build/intermediates/local_only_symbol_list/debug/parseDebugLocalResources/R-def.txt +2 -0
- package/android/build/intermediates/nested_resources_validation_report/debug/generateDebugResources/nestedResourcesValidationReport.txt +1 -0
- package/android/build.gradle +1 -1
- package/android/src/main/java/com/smkituilibrary/SmkitUiLibraryModule.kt +40 -16
- package/ios/SMKitUIManager.swift +0 -1
- package/package.json +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
#Tue Mar 17 23:21:45 IST 2026
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<merger version="3"><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/src/main/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main" generated-set="main$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/src/main/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/src/debug/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug" generated-set="debug$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/src/debug/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/build/generated/res/resValues/debug"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated" generated-set="generated$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/build/generated/res/resValues/debug"/></dataSet><mergedItems/></merger>
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<merger version="3"><dataSet config="main" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/src/main/jniLibs"/></dataSet><dataSet config="debug" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/Users/offryhayon/PycharmProjects/smkit_ui_library/react-native-smkit-ui/android/src/debug/jniLibs"/></dataSet></merger>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
0 Warning/Error
|
package/android/build.gradle
CHANGED
|
@@ -95,7 +95,7 @@ dependencies {
|
|
|
95
95
|
implementation "com.facebook.react:react-android"
|
|
96
96
|
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
|
97
97
|
|
|
98
|
-
implementation("com.sency.smkitui:smkitui:1.5.
|
|
98
|
+
implementation("com.sency.smkitui:smkitui:1.5.4") {
|
|
99
99
|
exclude group: 'com.facebook.fbjni', module: 'fbjni-java-only'
|
|
100
100
|
// // Don't exclude native libraries
|
|
101
101
|
// exclude group: 'com.facebook.react', module: 'react-native'
|
|
@@ -514,12 +514,20 @@ class SmkitUiLibraryModule(reactContext: ReactApplicationContext) :
|
|
|
514
514
|
|
|
515
515
|
val (finalModifications, showPhoneCalibration) = processModifications(modifications)
|
|
516
516
|
|
|
517
|
-
smKitUI
|
|
517
|
+
val sdk = smKitUI
|
|
518
|
+
if (sdk == null) {
|
|
519
|
+
Log.e(TAG, "startAssessment: SMKitUI not configured. Call configure() first.")
|
|
520
|
+
promise.reject("Starting Assessment Failed", "SDK not configured. Call configure() first.")
|
|
521
|
+
return
|
|
522
|
+
}
|
|
523
|
+
// Some SDK versions NPE on null modifications; pass empty JSON object when null
|
|
524
|
+
val modificationsParam = finalModifications ?: "{}"
|
|
525
|
+
sdk.startAssessment(
|
|
518
526
|
listener = listener,
|
|
519
527
|
assessmentType = assessmentType,
|
|
520
528
|
userData = user,
|
|
521
529
|
showSummary = showSummary,
|
|
522
|
-
modifications =
|
|
530
|
+
modifications = modificationsParam,
|
|
523
531
|
showPhoneCalibration = showPhoneCalibration
|
|
524
532
|
)
|
|
525
533
|
} catch (e: Exception) {
|
|
@@ -550,10 +558,17 @@ class SmkitUiLibraryModule(reactContext: ReactApplicationContext) :
|
|
|
550
558
|
Log.d(TAG, "Verified: Workout has no scoring params")
|
|
551
559
|
}
|
|
552
560
|
val (finalModifications, showPhoneCalibration) = processModifications(modifications)
|
|
553
|
-
smKitUI
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
561
|
+
val sdk = smKitUI
|
|
562
|
+
if (sdk == null) {
|
|
563
|
+
Log.e(TAG, "startCustomWorkout: SMKitUI not configured. Call configure() first.")
|
|
564
|
+
promise.reject("Starting Custom Workout Failed", "SDK not configured. Call configure() first.")
|
|
565
|
+
return
|
|
566
|
+
}
|
|
567
|
+
val modificationsParam = finalModifications ?: "{}"
|
|
568
|
+
sdk.startCustomizedWorkout(
|
|
569
|
+
workout = workout,
|
|
570
|
+
listener = listener,
|
|
571
|
+
modifications = modificationsParam,
|
|
557
572
|
showPhoneCalibration = showPhoneCalibration
|
|
558
573
|
)
|
|
559
574
|
} catch (e: Exception) {
|
|
@@ -584,17 +599,20 @@ class SmkitUiLibraryModule(reactContext: ReactApplicationContext) :
|
|
|
584
599
|
Log.d(TAG, "Starting customized assessment with workout: ${workout.name}")
|
|
585
600
|
|
|
586
601
|
val (finalModifications, showPhoneCalibration) = processModifications(modifications)
|
|
587
|
-
|
|
588
|
-
|
|
602
|
+
val sdk = smKitUI
|
|
603
|
+
if (sdk == null) {
|
|
604
|
+
Log.e(TAG, "startCustomizedAssessment: SMKitUI not configured. Call configure() first.")
|
|
605
|
+
promise.reject("Starting Custom Assessment Failed", "SDK not configured. Call configure() first.")
|
|
606
|
+
return
|
|
607
|
+
}
|
|
608
|
+
val modificationsParam = finalModifications ?: "{}"
|
|
609
|
+
sdk.startCustomizedAssessment(
|
|
589
610
|
workout = workout,
|
|
590
611
|
showSummary = showSummary,
|
|
591
612
|
listener = listener,
|
|
592
|
-
modifications =
|
|
613
|
+
modifications = modificationsParam,
|
|
593
614
|
showPhoneCalibration = showPhoneCalibration
|
|
594
|
-
)
|
|
595
|
-
Log.e(TAG, "SMKitUI is null, cannot start assessment")
|
|
596
|
-
promise.reject("Starting Custom Assessment Failed", "SMKitUI not configured")
|
|
597
|
-
}
|
|
615
|
+
)
|
|
598
616
|
} catch (e: Exception) {
|
|
599
617
|
Log.e(TAG, "Exception in startCustomAssessment", e)
|
|
600
618
|
promise.reject("Starting Custom Assessment Failed", e.message ?: e.toString(), e)
|
|
@@ -662,11 +680,17 @@ class SmkitUiLibraryModule(reactContext: ReactApplicationContext) :
|
|
|
662
680
|
resultPromise = promise
|
|
663
681
|
|
|
664
682
|
val (finalModifications, showPhoneCalibration) = processModifications(modifications)
|
|
665
|
-
|
|
666
|
-
|
|
683
|
+
val sdk = smKitUI
|
|
684
|
+
if (sdk == null) {
|
|
685
|
+
Log.e(TAG, "startWorkoutProgram: SMKitUI not configured. Call configure() first.")
|
|
686
|
+
promise.reject("Starting workout from program Failed", "SDK not configured. Call configure() first.")
|
|
687
|
+
return
|
|
688
|
+
}
|
|
689
|
+
val modificationsParam = finalModifications ?: "{}"
|
|
690
|
+
sdk.startWorkoutProgram(
|
|
667
691
|
workoutConfig = smKitWorkoutConfig.toWorkoutConfig(),
|
|
668
692
|
listener = listener,
|
|
669
|
-
modifications =
|
|
693
|
+
modifications = modificationsParam,
|
|
670
694
|
showPhoneCalibration = showPhoneCalibration
|
|
671
695
|
)
|
|
672
696
|
} catch (e: Exception) {
|
package/ios/SMKitUIManager.swift
CHANGED
|
@@ -61,7 +61,6 @@ class SMKitUIManager: NSObject, RCTBridgeModule {
|
|
|
61
61
|
/// - onFailure: Rejecter block for failure
|
|
62
62
|
@objc(configure:onSuccess:onFailure:)
|
|
63
63
|
func configure(key: NSString, onSuccess: @escaping RCTPromiseResolveBlock, onFailure: @escaping RCTPromiseRejectBlock) {
|
|
64
|
-
print("SMKitUIManager: Configuring with key: \(key)")
|
|
65
64
|
DispatchQueue.main.async {
|
|
66
65
|
var isConfigDone = false
|
|
67
66
|
var didFail = false
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sency/react-native-smkit-ui",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.1",
|
|
4
4
|
"description": "React Native library for SMKit UI - Advanced fitness assessments and workout programs with AI-powered motion detection and real-time performance tracking",
|
|
5
5
|
"main": "lib/commonjs/index",
|
|
6
6
|
"module": "lib/module/index",
|
|
@@ -92,4 +92,4 @@
|
|
|
92
92
|
]
|
|
93
93
|
]
|
|
94
94
|
}
|
|
95
|
-
}
|
|
95
|
+
}
|