@adminide-stack/yantra-mobile 12.0.54-alpha.1 → 12.0.54-alpha.10

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/lib/components/CustomDrawer.js +28 -19
  2. package/lib/components/CustomDrawer.js.map +1 -1
  3. package/lib/components/NavigationHeader/HeaderMoreMenu.js +7 -4
  4. package/lib/components/NavigationHeader/HeaderMoreMenu.js.map +1 -1
  5. package/lib/components/NavigationHeader/HeaderSkillsButton.js +5 -2
  6. package/lib/components/NavigationHeader/HeaderSkillsButton.js.map +1 -1
  7. package/lib/components/NavigationHeader/HeaderTasksButton.js +4 -1
  8. package/lib/components/NavigationHeader/HeaderTasksButton.js.map +1 -1
  9. package/lib/components/NavigationHeader/NavigationHeader.js +7 -5
  10. package/lib/components/NavigationHeader/NavigationHeader.js.map +1 -1
  11. package/lib/features/agent-chat/NativeAgentChat.js +393 -0
  12. package/lib/features/agent-chat/NativeAgentChat.js.map +1 -0
  13. package/lib/features/attachments/displayUserMessageText.js +3 -2
  14. package/lib/features/attachments/displayUserMessageText.js.map +1 -1
  15. package/lib/features/attachments/useImageAttachments.js +9 -7
  16. package/lib/features/attachments/useImageAttachments.js.map +1 -1
  17. package/lib/features/canvas/withRemoteSafeArea.js +46 -0
  18. package/lib/features/canvas/withRemoteSafeArea.js.map +1 -0
  19. package/lib/features/chat/ChatTranscript.js +23 -15
  20. package/lib/features/chat/ChatTranscript.js.map +1 -1
  21. package/lib/features/chat/toolActivity.js +42 -6
  22. package/lib/features/chat/toolActivity.js.map +1 -1
  23. package/lib/features/chat/transcriptGroups.js +11 -2
  24. package/lib/features/chat/transcriptGroups.js.map +1 -1
  25. package/lib/features/shopping/chat/homeShoppingIntent.js +58 -0
  26. package/lib/features/shopping/chat/homeShoppingIntent.js.map +1 -0
  27. package/lib/features/shopping/chat/openShopNative.js +60 -0
  28. package/lib/features/shopping/chat/openShopNative.js.map +1 -0
  29. package/lib/graphql/typePolicies.js +35 -1
  30. package/lib/graphql/typePolicies.js.map +1 -1
  31. package/lib/hooks/useCdecliChannel.js +10 -8
  32. package/lib/hooks/useCdecliChannel.js.map +1 -1
  33. package/lib/hooks/useChatStream.js +13 -6
  34. package/lib/hooks/useChatStream.js.map +1 -1
  35. package/lib/index.js +1 -1
  36. package/lib/index.js.map +1 -1
  37. package/lib/screens/Chat/index.js +44 -5
  38. package/lib/screens/Chat/index.js.map +1 -1
  39. package/lib/screens/Home/HomeScreen.js +37 -10
  40. package/lib/screens/Home/HomeScreen.js.map +1 -1
  41. package/lib/screens/ShoppingNative/index.js +23 -2
  42. package/lib/screens/ShoppingNative/index.js.map +1 -1
  43. package/lib/screens/ShoppingNative/useShoppingHostChat.js +66 -0
  44. package/lib/screens/ShoppingNative/useShoppingHostChat.js.map +1 -0
  45. package/lib/services/brainQuickReply.js +72 -2
  46. package/lib/services/brainQuickReply.js.map +1 -1
  47. package/lib/utils/drawerNavigation.js +36 -0
  48. package/lib/utils/drawerNavigation.js.map +1 -0
  49. package/package.json +4 -4
@@ -0,0 +1 @@
1
+ {"version":3,"file":"drawerNavigation.js","sources":["../../src/utils/drawerNavigation.ts"],"sourcesContent":["import { DrawerActions } from '@react-navigation/native';\n\ntype NavLike = {\n openDrawer?: () => void;\n closeDrawer?: () => void;\n toggleDrawer?: () => void;\n getState?: () => { type?: string } | undefined;\n getParent?: () => NavLike | undefined;\n dispatch?: (action: unknown) => void;\n};\n\nexport type DrawerAction = 'open' | 'close' | 'toggle';\n\n/**\n * Home / Chat live inside the workspace drawer; Canvas, Apps, and Shop are\n * nested (or sibling) routes. After those screens, `DrawerActions.openDrawer()`\n * on the focused navigator is a no-op, and a half-closed drawer leaves a\n * left-edge overlay that eats hamburger taps.\n */\nexport function findDrawerNavigation(navigation: NavLike | null | undefined): NavLike | null {\n let current: NavLike | null | undefined = navigation;\n for (let i = 0; i < 12 && current; i += 1) {\n if (typeof current.openDrawer === 'function' || current.getState?.()?.type === 'drawer') {\n return current;\n }\n current = current.getParent?.();\n }\n return null;\n}\n\nexport function dispatchDrawerAction(navigation: NavLike | null | undefined, action: DrawerAction): void {\n const drawer = findDrawerNavigation(navigation);\n // Apps / Canvas / Shop sit on the root stack (`/:orgName/apps`), not inside\n // `main_drawer`. Dispatching CLOSE_DRAWER there logs \"not handled by any\n // navigator\" and does not reset the leftover overlay.\n if (!drawer) return;\n if (action === 'open' && typeof drawer.openDrawer === 'function') {\n drawer.openDrawer();\n return;\n }\n if (action === 'close' && typeof drawer.closeDrawer === 'function') {\n drawer.closeDrawer();\n return;\n }\n if (action === 'toggle' && typeof drawer.toggleDrawer === 'function') {\n drawer.toggleDrawer();\n return;\n }\n if (drawer.getState?.()?.type !== 'drawer') return;\n const creator =\n action === 'open'\n ? DrawerActions.openDrawer\n : action === 'close'\n ? DrawerActions.closeDrawer\n : DrawerActions.toggleDrawer;\n drawer.dispatch?.(creator());\n}\n\n/** Navigate after RN Modal `visible` has gone false (avoids iOS overlay leaks). */\nexport function afterNativeModalClose(run: () => void): void {\n requestAnimationFrame(() => {\n setTimeout(run, 40);\n });\n}\n"],"names":[],"mappings":"qDAmBO,SAAS,qBAAqB,UAAwD,EAAA;AAnB7F,EAAA,IAAA,EAAA,EAAA,EAAA,EAAA,EAAA;AAoBE,EAAA,IAAI,OAAsC,GAAA,UAAA;AAC1C,EAAA,KAAA,IAAS,IAAI,CAAG,EAAA,CAAA,GAAI,EAAM,IAAA,OAAA,EAAS,KAAK,CAAG,EAAA;AACzC,IAAI,IAAA,OAAO,QAAQ,UAAe,KAAA,UAAA,IAAA,CAAA,CAAc,mBAAQ,QAAR,KAAA,IAAA,GAAA,MAAA,GAAA,EAAA,CAAA,IAAA,CAAA,OAAA,CAAA,KAAA,IAAA,GAAA,MAAA,GAAA,EAAA,CAAsB,UAAS,QAAU,EAAA;AACvF,MAAO,OAAA,OAAA;AAAA;AAET,IAAA,OAAA,GAAA,CAAU,aAAQ,SAAR,KAAA,IAAA,GAAA,M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AA;AACH"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adminide-stack/yantra-mobile",
3
- "version": "12.0.54-alpha.1",
3
+ "version": "12.0.54-alpha.10",
4
4
  "description": "Sample core for higher packages to depend on",
5
5
  "license": "ISC",
6
6
  "author": "CDMBase LLC",
@@ -25,7 +25,7 @@
25
25
  "uuid": "^9.0.0"
26
26
  },
27
27
  "devDependencies": {
28
- "common": "12.0.54-alpha.0"
28
+ "common": "12.0.54-alpha.7"
29
29
  },
30
30
  "peerDependencies": {
31
31
  "@admin-layout/gluestack-ui-mobile": "*",
@@ -41,7 +41,7 @@
41
41
  "@messenger-box/platform-mobile": "*",
42
42
  "@react-native-async-storage/async-storage": "*",
43
43
  "@react-navigation/native": "*",
44
- "common": "12.0.54-alpha.0",
44
+ "common": "12.0.54-alpha.7",
45
45
  "expo-constants": "*",
46
46
  "expo-secure-store": "*",
47
47
  "lodash": "*",
@@ -57,5 +57,5 @@
57
57
  "typescript": {
58
58
  "definition": "lib/index.d.ts"
59
59
  },
60
- "gitHead": "b9a59386a5492c54933194f60d094d01423d9310"
60
+ "gitHead": "50a17d79556102aca8121d62a84d670f8951ad8c"
61
61
  }