@adminide-stack/yantra-mobile 12.0.141-alpha.1 → 12.0.141

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 (220) hide show
  1. package/lib/features/agent-chat/NativeAgentChat.js +21 -4
  2. package/lib/features/agent-chat/NativeAgentChat.js.map +1 -1
  3. package/lib/features/chat/ApprovalCard.js +353 -0
  4. package/lib/features/chat/ApprovalCard.js.map +1 -0
  5. package/lib/features/chat/AskUserCard.js +9 -2
  6. package/lib/features/chat/AskUserCard.js.map +1 -1
  7. package/lib/features/chat/askUser.js +25 -3
  8. package/lib/features/chat/askUser.js.map +1 -1
  9. package/lib/features/chat/queuedFollowUpRows.js +13 -0
  10. package/lib/features/chat/queuedFollowUpRows.js.map +1 -0
  11. package/lib/features/devices/bodyComposition.js +116 -0
  12. package/lib/features/devices/bodyComposition.js.map +1 -0
  13. package/lib/features/devices/readings.js.map +1 -1
  14. package/lib/features/devices/session.js +22 -2
  15. package/lib/features/devices/session.js.map +1 -1
  16. package/lib/features/discover/DiscoverArticle.js +105 -92
  17. package/lib/features/discover/DiscoverArticle.js.map +1 -1
  18. package/lib/features/discover/DiscoverFeed.js +97 -48
  19. package/lib/features/discover/DiscoverFeed.js.map +1 -1
  20. package/lib/features/discover/DiscoverFollowUp.js +135 -0
  21. package/lib/features/discover/DiscoverFollowUp.js.map +1 -0
  22. package/lib/features/discover/DiscoverSidebar.js +555 -0
  23. package/lib/features/discover/DiscoverSidebar.js.map +1 -0
  24. package/lib/features/discover/DiscoverSkeletons.js +123 -0
  25. package/lib/features/discover/DiscoverSkeletons.js.map +1 -0
  26. package/lib/features/discover/DiscoverStoryCards.js +193 -87
  27. package/lib/features/discover/DiscoverStoryCards.js.map +1 -1
  28. package/lib/features/discover/followUpQuery.js +42 -0
  29. package/lib/features/discover/followUpQuery.js.map +1 -0
  30. package/lib/features/discover/markets.js +37 -0
  31. package/lib/features/discover/markets.js.map +1 -0
  32. package/lib/features/discover/useDiscoverSidebar.js +148 -0
  33. package/lib/features/discover/useDiscoverSidebar.js.map +1 -0
  34. package/lib/features/discover/weather.js +42 -0
  35. package/lib/features/discover/weather.js.map +1 -0
  36. package/lib/features/expenses/ExpensesAgentChatPane.js +1 -1
  37. package/lib/features/expenses/ExpensesAgentChatPane.js.map +1 -1
  38. package/lib/features/inbox/InboxAgentChatPane.js +1 -1
  39. package/lib/features/inbox/InboxAgentChatPane.js.map +1 -1
  40. package/lib/features/job-search/JobSearchAgentChatPane.js +1 -0
  41. package/lib/features/job-search/JobSearchAgentChatPane.js.map +1 -1
  42. package/lib/features/local-services/LocalServicesAgentChatPane.js +1 -1
  43. package/lib/features/local-services/LocalServicesAgentChatPane.js.map +1 -1
  44. package/lib/features/movies/MoviesAgentChatPane.js +1 -1
  45. package/lib/features/movies/MoviesAgentChatPane.js.map +1 -1
  46. package/lib/features/notion/NotionBlockSheets.js +206 -0
  47. package/lib/features/notion/NotionBlockSheets.js.map +1 -0
  48. package/lib/features/notion/NotionBlockView.js +36 -0
  49. package/lib/features/notion/NotionBlockView.js.map +1 -0
  50. package/lib/features/notion/NotionCommentsSheet.js +461 -0
  51. package/lib/features/notion/NotionCommentsSheet.js.map +1 -0
  52. package/lib/features/notion/NotionConnectionsSheet.js +244 -0
  53. package/lib/features/notion/NotionConnectionsSheet.js.map +1 -0
  54. package/lib/features/notion/NotionHistorySheet.js +439 -0
  55. package/lib/features/notion/NotionHistorySheet.js.map +1 -0
  56. package/lib/features/notion/NotionMediaBlocks.js +803 -0
  57. package/lib/features/notion/NotionMediaBlocks.js.map +1 -0
  58. package/lib/features/notion/NotionMentionSheet.js +279 -0
  59. package/lib/features/notion/NotionMentionSheet.js.map +1 -0
  60. package/lib/features/notion/NotionPageMenu.js +585 -0
  61. package/lib/features/notion/NotionPageMenu.js.map +1 -0
  62. package/lib/features/notion/NotionPageTree.js +220 -0
  63. package/lib/features/notion/NotionPageTree.js.map +1 -0
  64. package/lib/features/notion/NotionPageView.js +1253 -152
  65. package/lib/features/notion/NotionPageView.js.map +1 -1
  66. package/lib/features/notion/NotionShareSheet.js +606 -0
  67. package/lib/features/notion/NotionShareSheet.js.map +1 -0
  68. package/lib/features/notion/NotionSheets.js +87 -15
  69. package/lib/features/notion/NotionSheets.js.map +1 -1
  70. package/lib/features/notion/NotionSidebarSections.js +492 -0
  71. package/lib/features/notion/NotionSidebarSections.js.map +1 -0
  72. package/lib/features/notion/NotionWorkspaceAdmin.js +659 -0
  73. package/lib/features/notion/NotionWorkspaceAdmin.js.map +1 -0
  74. package/lib/features/notion/NotionWorkspaceView.js +257 -45
  75. package/lib/features/notion/NotionWorkspaceView.js.map +1 -1
  76. package/lib/features/notion/database/DatabaseCells.js +554 -0
  77. package/lib/features/notion/database/DatabaseCells.js.map +1 -0
  78. package/lib/features/notion/database/DatabaseDateLayouts.js +792 -0
  79. package/lib/features/notion/database/DatabaseDateLayouts.js.map +1 -0
  80. package/lib/features/notion/database/DatabaseLayouts.js +461 -0
  81. package/lib/features/notion/database/DatabaseLayouts.js.map +1 -0
  82. package/lib/features/notion/database/DatabaseSheets.js +791 -0
  83. package/lib/features/notion/database/DatabaseSheets.js.map +1 -0
  84. package/lib/features/notion/database/NotionDatabaseView.js +817 -0
  85. package/lib/features/notion/database/NotionDatabaseView.js.map +1 -0
  86. package/lib/features/notion/database/RowPropertiesPanel.js +162 -0
  87. package/lib/features/notion/database/RowPropertiesPanel.js.map +1 -0
  88. package/lib/features/notion/database/chartData.js +89 -0
  89. package/lib/features/notion/database/chartData.js.map +1 -0
  90. package/lib/features/notion/database/chartView.js +112 -0
  91. package/lib/features/notion/database/chartView.js.map +1 -0
  92. package/lib/features/notion/database/connectorButton.js +33 -0
  93. package/lib/features/notion/database/connectorButton.js.map +1 -0
  94. package/lib/features/notion/database/databaseCalc.js +208 -0
  95. package/lib/features/notion/database/databaseCalc.js.map +1 -0
  96. package/lib/features/notion/database/databaseCalendar.js +157 -0
  97. package/lib/features/notion/database/databaseCalendar.js.map +1 -0
  98. package/lib/features/notion/database/databaseCsv.js +98 -0
  99. package/lib/features/notion/database/databaseCsv.js.map +1 -0
  100. package/lib/features/notion/database/databaseCsvActions.js +58 -0
  101. package/lib/features/notion/database/databaseCsvActions.js.map +1 -0
  102. package/lib/features/notion/database/databaseFilter.js +473 -0
  103. package/lib/features/notion/database/databaseFilter.js.map +1 -0
  104. package/lib/features/notion/database/databaseFormula.js +1072 -0
  105. package/lib/features/notion/database/databaseFormula.js.map +1 -0
  106. package/lib/features/notion/database/databaseGroup.js +151 -0
  107. package/lib/features/notion/database/databaseGroup.js.map +1 -0
  108. package/lib/features/notion/database/databaseRollup.js +58 -0
  109. package/lib/features/notion/database/databaseRollup.js.map +1 -0
  110. package/lib/features/notion/database/databaseTimeline.js +156 -0
  111. package/lib/features/notion/database/databaseTimeline.js.map +1 -0
  112. package/lib/features/notion/database/databaseView.js +1188 -0
  113. package/lib/features/notion/database/databaseView.js.map +1 -0
  114. package/lib/features/notion/database/databaseViews.js +310 -0
  115. package/lib/features/notion/database/databaseViews.js.map +1 -0
  116. package/lib/features/notion/database/relationSource.js +92 -0
  117. package/lib/features/notion/database/relationSource.js.map +1 -0
  118. package/lib/features/notion/database/uniqueId.js +17 -0
  119. package/lib/features/notion/database/uniqueId.js.map +1 -0
  120. package/lib/features/notion/database/useNotionDatabase.js +617 -0
  121. package/lib/features/notion/database/useNotionDatabase.js.map +1 -0
  122. package/lib/features/notion/notionAgentRunStatus.js +39 -0
  123. package/lib/features/notion/notionAgentRunStatus.js.map +1 -0
  124. package/lib/features/notion/notionCodeLanguages.js +112 -0
  125. package/lib/features/notion/notionCodeLanguages.js.map +1 -0
  126. package/lib/features/notion/notionComments.js +86 -0
  127. package/lib/features/notion/notionComments.js.map +1 -0
  128. package/lib/features/notion/notionConnections.js +74 -0
  129. package/lib/features/notion/notionConnections.js.map +1 -0
  130. package/lib/features/notion/notionDocuments.js +453 -1
  131. package/lib/features/notion/notionDocuments.js.map +1 -1
  132. package/lib/features/notion/notionEditorModel.js +142 -7
  133. package/lib/features/notion/notionEditorModel.js.map +1 -1
  134. package/lib/features/notion/notionMarkdownShortcuts.js +51 -0
  135. package/lib/features/notion/notionMarkdownShortcuts.js.map +1 -0
  136. package/lib/features/notion/notionMedia.js +119 -0
  137. package/lib/features/notion/notionMedia.js.map +1 -0
  138. package/lib/features/notion/notionMentionDate.js +32 -0
  139. package/lib/features/notion/notionMentionDate.js.map +1 -0
  140. package/lib/features/notion/notionMentionOptions.js +162 -0
  141. package/lib/features/notion/notionMentionOptions.js.map +1 -0
  142. package/lib/features/notion/notionNotesAgent.js +445 -0
  143. package/lib/features/notion/notionNotesAgent.js.map +1 -0
  144. package/lib/features/notion/notionPageAccess.js +168 -0
  145. package/lib/features/notion/notionPageAccess.js.map +1 -0
  146. package/lib/features/notion/notionPageActions.js +138 -0
  147. package/lib/features/notion/notionPageActions.js.map +1 -0
  148. package/lib/features/notion/notionPageHistory.js +154 -0
  149. package/lib/features/notion/notionPageHistory.js.map +1 -0
  150. package/lib/features/notion/notionPageKinds.js +200 -0
  151. package/lib/features/notion/notionPageKinds.js.map +1 -0
  152. package/lib/features/notion/notionRecents.js +48 -0
  153. package/lib/features/notion/notionRecents.js.map +1 -0
  154. package/lib/features/notion/notionRichText.js +177 -0
  155. package/lib/features/notion/notionRichText.js.map +1 -0
  156. package/lib/features/notion/notionRichTitle.js +336 -0
  157. package/lib/features/notion/notionRichTitle.js.map +1 -0
  158. package/lib/features/notion/useNotionWorkspace.js +272 -13
  159. package/lib/features/notion/useNotionWorkspace.js.map +1 -1
  160. package/lib/features/notion/usePageActions.js +155 -0
  161. package/lib/features/notion/usePageActions.js.map +1 -0
  162. package/lib/features/resume/ResumeAgentChatPane.js +1 -1
  163. package/lib/features/resume/ResumeAgentChatPane.js.map +1 -1
  164. package/lib/features/shopping/ShoppingAgentChatPane.js +1 -1
  165. package/lib/features/shopping/ShoppingAgentChatPane.js.map +1 -1
  166. package/lib/features/study/StudyAgentChatPane.js +1 -1
  167. package/lib/features/study/StudyAgentChatPane.js.map +1 -1
  168. package/lib/features/travel/TravelAgentChatPane.js +1 -1
  169. package/lib/features/travel/TravelAgentChatPane.js.map +1 -1
  170. package/lib/features/webbuilder/WebBuilderExperience.js +40 -8
  171. package/lib/features/webbuilder/WebBuilderExperience.js.map +1 -1
  172. package/lib/features/webbuilder/buildFragments.js +1 -1
  173. package/lib/features/webbuilder/buildFragments.js.map +1 -1
  174. package/lib/features/webbuilder/codeFiles.js +302 -0
  175. package/lib/features/webbuilder/codeFiles.js.map +1 -0
  176. package/lib/features/webbuilder/codeHighlight.js +209 -0
  177. package/lib/features/webbuilder/codeHighlight.js.map +1 -0
  178. package/lib/features/webbuilder/components/CodeView.js +682 -52
  179. package/lib/features/webbuilder/components/CodeView.js.map +1 -1
  180. package/lib/features/webbuilder/components/PreviewScreen.js +59 -38
  181. package/lib/features/webbuilder/components/PreviewScreen.js.map +1 -1
  182. package/lib/features/webbuilder/components/ProjectChat.js +3 -3
  183. package/lib/features/webbuilder/components/ProjectChat.js.map +1 -1
  184. package/lib/features/webbuilder/stepLabels.js +68 -0
  185. package/lib/features/webbuilder/stepLabels.js.map +1 -0
  186. package/lib/hooks/useHostChatSteering.js +45 -0
  187. package/lib/hooks/useHostChatSteering.js.map +1 -0
  188. package/lib/screens/Chat/index.js +2 -12
  189. package/lib/screens/Chat/index.js.map +1 -1
  190. package/lib/screens/Devices/index.js +205 -3
  191. package/lib/screens/Devices/index.js.map +1 -1
  192. package/lib/screens/ExpensesNative/useExpensesHostChat.js +25 -5
  193. package/lib/screens/ExpensesNative/useExpensesHostChat.js.map +1 -1
  194. package/lib/screens/InboxNative/useInboxHostChat.js +25 -5
  195. package/lib/screens/InboxNative/useInboxHostChat.js.map +1 -1
  196. package/lib/screens/JobSearchNative/useJobSearchHostChat.js +25 -5
  197. package/lib/screens/JobSearchNative/useJobSearchHostChat.js.map +1 -1
  198. package/lib/screens/LocalServicesNative/useLocalServicesHostChat.js +25 -5
  199. package/lib/screens/LocalServicesNative/useLocalServicesHostChat.js.map +1 -1
  200. package/lib/screens/MoviesNative/useMoviesHostChat.js +25 -5
  201. package/lib/screens/MoviesNative/useMoviesHostChat.js.map +1 -1
  202. package/lib/screens/NotionPage/index.js +2 -2
  203. package/lib/screens/NotionPage/index.js.map +1 -1
  204. package/lib/screens/ResumeNative/useResumeHostChat.js +25 -5
  205. package/lib/screens/ResumeNative/useResumeHostChat.js.map +1 -1
  206. package/lib/screens/ShoppingNative/useShoppingHostChat.js +25 -5
  207. package/lib/screens/ShoppingNative/useShoppingHostChat.js.map +1 -1
  208. package/lib/screens/StudyNative/useStudyHostChat.js +25 -5
  209. package/lib/screens/StudyNative/useStudyHostChat.js.map +1 -1
  210. package/lib/screens/TravelNative/useTravelHostChat.js +25 -5
  211. package/lib/screens/TravelNative/useTravelHostChat.js.map +1 -1
  212. package/lib/screens/WebBuilderNative/codeWorkspaceApi.js +222 -0
  213. package/lib/screens/WebBuilderNative/codeWorkspaceApi.js.map +1 -0
  214. package/lib/screens/WebBuilderNative/index.js +1 -1
  215. package/lib/screens/WebBuilderNative/index.js.map +1 -1
  216. package/lib/screens/WebBuilderNative/sandboxProxyApi.js +126 -4
  217. package/lib/screens/WebBuilderNative/sandboxProxyApi.js.map +1 -1
  218. package/lib/screens/WebBuilderNative/useWebBuilderHost.js +120 -11
  219. package/lib/screens/WebBuilderNative/useWebBuilderHost.js.map +1 -1
  220. package/package.json +4 -4
@@ -1,4 +1,4 @@
1
- import {jsxs,jsx,Fragment}from'react/jsx-runtime';import React__default,{useState,useMemo,useCallback,useEffect,useRef}from'react';import {BackHandler,StyleSheet,View,Pressable,ActivityIndicator,ScrollView,Linking,Alert,Animated,Easing,Platform}from'react-native';import {Ionicons}from'@expo/vector-icons';import {Text}from'@admin-layout/gluestack-ui-mobile';import {useNavigation,useRoute,CommonActions}from'@react-navigation/native';import {useSafeAreaInsets,SafeAreaView}from'react-native-safe-area-context';import {mobileColors,mobileTokens}from'../../theme/mobileTokens.js';import {useAppTheme}from'../../theme/AppThemeProvider.js';import {deviceKind,DEVICE_KINDS}from'../../features/devices/catalog.js';import {useDevices,useDeviceSession,platformWriter,deviceStore}from'../../features/devices/devices.js';import {describeReading}from'../../features/devices/readings.js';import {useHealthSync}from'../../features/health/healthSync.js';var __defProp = Object.defineProperty;
1
+ import {jsxs,jsx,Fragment}from'react/jsx-runtime';import React__default,{useState,useMemo,useCallback,useEffect,useRef}from'react';import {BackHandler,StyleSheet,View,Pressable,ActivityIndicator,ScrollView,Linking,Alert,Animated,Easing,Platform}from'react-native';import {Ionicons}from'@expo/vector-icons';import {Text}from'@admin-layout/gluestack-ui-mobile';import {useNavigation,useRoute,CommonActions}from'@react-navigation/native';import {useSafeAreaInsets,SafeAreaView}from'react-native-safe-area-context';import {mobileColors,mobileTokens}from'../../theme/mobileTokens.js';import {useAppTheme}from'../../theme/AppThemeProvider.js';import {deviceKind,DEVICE_KINDS}from'../../features/devices/catalog.js';import {useDevices,useDeviceSession,platformWriter,deviceStore}from'../../features/devices/devices.js';import {describeReading}from'../../features/devices/readings.js';import {compositionRows}from'../../features/devices/bodyComposition.js';import {useHealthSync}from'../../features/health/healthSync.js';var __defProp = Object.defineProperty;
2
2
  var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3
3
  var __hasOwnProp = Object.prototype.hasOwnProperty;
4
4
  var __propIsEnum = Object.prototype.propertyIsEnumerable;
@@ -305,6 +305,53 @@ const styles = StyleSheet.create({
305
305
  fontSize: 14,
306
306
  marginTop: 2
307
307
  },
308
+ measureBox: {
309
+ alignItems: "center",
310
+ paddingVertical: 24,
311
+ gap: 6
312
+ },
313
+ measureRing: {
314
+ position: "absolute",
315
+ top: 24,
316
+ width: 176,
317
+ height: 176,
318
+ borderRadius: 88,
319
+ borderWidth: 2
320
+ },
321
+ measureCore: {
322
+ width: 176,
323
+ height: 176,
324
+ borderRadius: 88,
325
+ alignItems: "center",
326
+ justifyContent: "center",
327
+ marginBottom: 12
328
+ },
329
+ measureWeight: {
330
+ fontSize: 44,
331
+ fontWeight: "700"
332
+ },
333
+ measureUnit: {
334
+ fontSize: 18,
335
+ fontWeight: "600"
336
+ },
337
+ compositionGrid: {
338
+ flexDirection: "row",
339
+ flexWrap: "wrap",
340
+ marginTop: 10,
341
+ rowGap: 10
342
+ },
343
+ compositionItem: {
344
+ width: "33.33%",
345
+ paddingRight: 8
346
+ },
347
+ compositionLabel: {
348
+ fontSize: 12
349
+ },
350
+ compositionValue: {
351
+ fontSize: 15,
352
+ fontWeight: "600",
353
+ marginTop: 1
354
+ },
308
355
  savedLine: {
309
356
  flexDirection: "row",
310
357
  alignItems: "center",
@@ -567,7 +614,15 @@ function ReadingsCard({
567
614
  }], children: whenLabel(r.at, now) }),
568
615
  r.kind === "blood-pressure" && ((_a = r.problems) == null ? void 0 : _a.length) ? /* @__PURE__ */ jsx(Text, { style: [styles.readingNote, {
569
616
  color: colors.warningText
570
- }], children: r.problems.join(" ") }) : null
617
+ }], children: r.problems.join(" ") }) : null,
618
+ r.kind === "body" && r.composition ? /* @__PURE__ */ jsx(View, { style: styles.compositionGrid, children: compositionRows(r.composition, units).map((m) => /* @__PURE__ */ jsxs(View, { style: styles.compositionItem, children: [
619
+ /* @__PURE__ */ jsx(Text, { style: [styles.compositionLabel, {
620
+ color: colors.textMuted
621
+ }], children: m.label }),
622
+ /* @__PURE__ */ jsx(Text, { style: [styles.compositionValue, {
623
+ color: colors.text
624
+ }], children: m.value })
625
+ ] }, m.label)) }) : null
571
626
  ] })
572
627
  ] }, r.id);
573
628
  }) })
@@ -772,10 +827,151 @@ function PickKind({
772
827
  ] }, k.id)) })
773
828
  ] });
774
829
  }
830
+ function formatWeight(kg, units) {
831
+ if (kg === void 0) return "--";
832
+ const v = units === "imperial" ? kg / 0.45359237 : kg;
833
+ return (Math.round(v * 10) / 10).toFixed(1);
834
+ }
835
+ function ScaleMeasuring({
836
+ colors,
837
+ live,
838
+ units
839
+ }) {
840
+ const pulse = useRef(new Animated.Value(0)).current;
841
+ useEffect(() => {
842
+ const loop = Animated.loop(Animated.timing(pulse, {
843
+ toValue: 1,
844
+ duration: 1400,
845
+ easing: Easing.out(Easing.ease),
846
+ useNativeDriver: true
847
+ }));
848
+ loop.start();
849
+ return () => loop.stop();
850
+ }, [pulse]);
851
+ const ringScale = pulse.interpolate({
852
+ inputRange: [0, 1],
853
+ outputRange: [0.9, 1.5]
854
+ });
855
+ const ringOpacity = pulse.interpolate({
856
+ inputRange: [0, 1],
857
+ outputRange: [0.5, 0]
858
+ });
859
+ const unitLabel = units === "imperial" ? "lb" : "kg";
860
+ return /* @__PURE__ */ jsxs(View, { style: styles.measureBox, children: [
861
+ /* @__PURE__ */ jsx(Animated.View, { style: [styles.measureRing, {
862
+ borderColor: colors.primary,
863
+ opacity: ringOpacity,
864
+ transform: [{
865
+ scale: ringScale
866
+ }]
867
+ }], accessibilityElementsHidden: true, importantForAccessibility: "no-hide-descendants" }),
868
+ /* @__PURE__ */ jsx(View, { style: [styles.measureCore, {
869
+ backgroundColor: colors.primarySoft
870
+ }], children: /* @__PURE__ */ jsxs(Text, { style: [styles.measureWeight, {
871
+ color: colors.text
872
+ }], accessibilityLabel: `${formatWeight(live.weightKg, units)} ${unitLabel}`, children: [
873
+ formatWeight(live.weightKg, units),
874
+ /* @__PURE__ */ jsxs(Text, { style: [styles.measureUnit, {
875
+ color: colors.textMuted
876
+ }], children: [
877
+ " ",
878
+ unitLabel
879
+ ] })
880
+ ] }) }),
881
+ /* @__PURE__ */ jsx(Text, { style: [styles.statusTitle, {
882
+ color: colors.text
883
+ }], children: "Measuring" }),
884
+ /* @__PURE__ */ jsx(Text, { style: [styles.statusBody, {
885
+ color: colors.textMuted
886
+ }], children: "Stand still, barefoot, until it settles." })
887
+ ] });
888
+ }
889
+ function BrandLive({
890
+ kind,
891
+ colors,
892
+ live,
893
+ units
894
+ }) {
895
+ var _a, _b, _c;
896
+ const items = [];
897
+ const round1 = (n) => Math.round(n * 10) / 10;
898
+ if (kind === "kitchen-scale") items.push({
899
+ label: "Weight",
900
+ value: `${Math.round((_a = live.grams) != null ? _a : 0)} g`
901
+ });
902
+ if (kind === "tape") {
903
+ const cm = (_b = live.lengthCm) != null ? _b : 0;
904
+ items.push({
905
+ label: live.bodyPart ? live.bodyPart.replace(/_/g, " ") : "Length",
906
+ value: units === "imperial" ? `${round1(cm / 2.54)} in` : `${round1(cm)} cm`
907
+ });
908
+ }
909
+ if (kind === "jump-rope") {
910
+ items.push({
911
+ label: "Jumps",
912
+ value: String((_c = live.jumps) != null ? _c : 0)
913
+ });
914
+ if (live.elapsedS !== void 0) items.push({
915
+ label: "Time",
916
+ value: clockOf(live.elapsedS)
917
+ });
918
+ }
919
+ if (kind === "treadmill") {
920
+ if (live.speedKmh !== void 0) items.push({
921
+ label: "Speed",
922
+ value: `${round1(live.speedKmh)} km/h`
923
+ });
924
+ if (live.distanceM !== void 0) items.push({
925
+ label: "Distance",
926
+ value: `${round1(live.distanceM / 1e3)} km`
927
+ });
928
+ if (live.kcal !== void 0) items.push({
929
+ label: "Calories",
930
+ value: `${Math.round(live.kcal)} kcal`
931
+ });
932
+ if (live.elapsedS !== void 0) items.push({
933
+ label: "Time",
934
+ value: clockOf(live.elapsedS)
935
+ });
936
+ }
937
+ if (kind === "ring") {
938
+ if (live.bpm !== void 0) items.push({
939
+ label: "Heart rate",
940
+ value: `${live.bpm} bpm`
941
+ });
942
+ if (live.spo2 !== void 0) items.push({
943
+ label: "Blood oxygen",
944
+ value: `${live.spo2}%`
945
+ });
946
+ if (live.skinTempC !== void 0) items.push({
947
+ label: "Skin temp",
948
+ value: `${round1(live.skinTempC)} \xB0C`
949
+ });
950
+ if (live.steps !== void 0) items.push({
951
+ label: "Steps",
952
+ value: String(live.steps)
953
+ });
954
+ }
955
+ if (live.battery !== void 0) items.push({
956
+ label: "Battery",
957
+ value: `${live.battery}%`
958
+ });
959
+ return /* @__PURE__ */ jsx(View, { style: [styles.card, styles.livePanel, {
960
+ backgroundColor: colors.surface
961
+ }], children: /* @__PURE__ */ jsx(View, { style: styles.compositionGrid, children: items.map((m) => /* @__PURE__ */ jsxs(View, { style: styles.compositionItem, children: [
962
+ /* @__PURE__ */ jsx(Text, { style: [styles.compositionLabel, {
963
+ color: colors.textMuted
964
+ }], children: m.label }),
965
+ /* @__PURE__ */ jsx(Text, { style: [styles.compositionValue, {
966
+ color: colors.text
967
+ }], children: m.value })
968
+ ] }, m.label)) }) });
969
+ }
775
970
  function LivePanel({
776
971
  kind,
777
972
  colors,
778
973
  live,
974
+ units,
779
975
  recording,
780
976
  connected,
781
977
  onStart,
@@ -784,6 +980,12 @@ function LivePanel({
784
980
  }) {
785
981
  var _a, _b, _c, _d, _e;
786
982
  const [type, setType] = useState("run");
983
+ if (kind === "scale") {
984
+ return /* @__PURE__ */ jsx(ScaleMeasuring, { colors, live, units });
985
+ }
986
+ if (kind === "kitchen-scale" || kind === "tape" || kind === "jump-rope" || kind === "treadmill" || kind === "ring") {
987
+ return /* @__PURE__ */ jsx(BrandLive, { kind, colors, live, units });
988
+ }
787
989
  const [, tick] = useState(0);
788
990
  useEffect(() => {
789
991
  if (!recording) return void 0;
@@ -943,7 +1145,7 @@ function Measure({
943
1145
  "."
944
1146
  ] })
945
1147
  ] }) : null,
946
- (state.step === "connected" || state.step === "ended") && live ? /* @__PURE__ */ jsx(LivePanel, { kind, colors, live, recording, connected: state.step === "connected", onStart: (type) => session == null ? void 0 : session.startRecording(type), onStop: () => {
1148
+ (state.step === "connected" || state.step === "ended") && live ? /* @__PURE__ */ jsx(LivePanel, { kind, colors, live, units, recording, connected: state.step === "connected", onStart: (type) => session == null ? void 0 : session.startRecording(type), onStop: () => {
947
1149
  void (session == null ? void 0 : session.stopRecording());
948
1150
  }, onSave: () => {
949
1151
  void (session == null ? void 0 : session.saveLive());