@developer_tribe/react-native-comnyx 0.6.2 → 0.7.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/Comnyx.podspec +1 -1
- package/README.md +192 -16
- package/android/app/build/generated/source/codegen/RCTAppDependencyProvider.h +25 -0
- package/android/app/build/generated/source/codegen/RCTAppDependencyProvider.mm +55 -0
- package/android/app/build/generated/source/codegen/RCTModulesConformingToProtocolsProvider.h +18 -0
- package/android/app/build/generated/source/codegen/RCTModulesConformingToProtocolsProvider.mm +33 -0
- package/android/app/build/generated/source/codegen/RCTThirdPartyComponentsProvider.h +16 -0
- package/android/app/build/generated/source/codegen/RCTThirdPartyComponentsProvider.mm +23 -0
- package/android/app/build/generated/source/codegen/ReactAppDependencyProvider.podspec +34 -0
- package/android/app/build/generated/source/codegen/java/com/facebook/fbreact/specs/NativeAsyncStorageModuleSpec.java +59 -0
- package/android/app/build/generated/source/codegen/jni/CMakeLists.txt +36 -0
- package/android/app/build/generated/source/codegen/jni/RNComnyxSpec-generated.cpp +22 -0
- package/android/app/build/generated/source/codegen/jni/RNComnyxSpec.h +24 -0
- package/android/app/build/generated/source/codegen/jni/react/renderer/components/RNComnyxSpec/RNComnyxSpecJSI-generated.cpp +17 -0
- package/android/app/build/generated/source/codegen/jni/react/renderer/components/RNComnyxSpec/RNComnyxSpecJSI.h +19 -0
- package/android/app/build/generated/source/codegen/jni/react/renderer/components/rnasyncstorage/rnasyncstorageJSI-generated.cpp +72 -0
- package/android/app/build/generated/source/codegen/jni/react/renderer/components/rnasyncstorage/rnasyncstorageJSI.h +116 -0
- package/android/app/build/generated/source/codegen/jni/rnasyncstorage-generated.cpp +62 -0
- package/android/app/build/generated/source/codegen/jni/rnasyncstorage.h +31 -0
- package/android/build.gradle +13 -1
- package/android/generated/RCTAppDependencyProvider.h +25 -0
- package/android/generated/RCTAppDependencyProvider.mm +55 -0
- package/android/generated/RCTModulesConformingToProtocolsProvider.h +18 -0
- package/android/generated/RCTModulesConformingToProtocolsProvider.mm +33 -0
- package/android/generated/RCTThirdPartyComponentsProvider.h +16 -0
- package/android/generated/RCTThirdPartyComponentsProvider.mm +23 -0
- package/android/generated/ReactAppDependencyProvider.podspec +34 -0
- package/android/generated/jni/RNComnyxSpec-generated.cpp +1 -11
- package/android/generated/jni/RNComnyxSpec.h +0 -7
- package/android/generated/jni/react/renderer/components/RNComnyxSpec/RNComnyxSpecJSI-generated.cpp +0 -11
- package/android/generated/jni/react/renderer/components/RNComnyxSpec/RNComnyxSpecJSI.h +0 -52
- package/android/src/main/AndroidManifestNew.xml +10 -0
- package/android/src/main/java/com/comnyx/ComnyxModule.kt +213 -5
- package/android/src/main/java/com/comnyx/ComnyxPackage.kt +10 -6
- package/android/src/main/java/com/comnyx/src/messaging/ComnyxMessaging.kt +25 -0
- package/android/src/main/java/com/comnyx/src/messaging/firebase/FCM.kt +38 -0
- package/android/src/main/java/com/comnyx/src/messaging/firebase/FirebaseMessagingService.kt +45 -0
- package/android/src/main/java/com/comnyx/src/messaging/notifications/NotificationsService.kt +99 -0
- package/ios/APNService.swift +74 -0
- package/ios/Comnyx-Bridging-Header.h +17 -0
- package/ios/Comnyx.m +18 -0
- package/ios/Comnyx.swift +117 -0
- package/ios/ComnyxMessaging.swift +84 -0
- package/ios/PushService.swift +7 -0
- package/lib/commonjs/NativeComnyx.js +15 -0
- package/lib/commonjs/NativeComnyx.js.map +1 -0
- package/lib/commonjs/api/api.js +14 -4
- package/lib/commonjs/api/api.js.map +1 -1
- package/lib/commonjs/api/customers.js +3 -8
- package/lib/commonjs/api/customers.js.map +1 -1
- package/lib/commonjs/api/index.js +1 -1
- package/lib/commonjs/components/AppText.js +1 -1
- package/lib/commonjs/components/AppText.js.map +1 -1
- package/lib/commonjs/components/ChatList.js +6 -2
- package/lib/commonjs/components/ChatList.js.map +1 -1
- package/lib/commonjs/components/CustomerForm.js +2 -16
- package/lib/commonjs/components/CustomerForm.js.map +1 -1
- package/lib/commonjs/components/EmptyList.js +1 -1
- package/lib/commonjs/components/EmptyList.js.map +1 -1
- package/lib/commonjs/components/MessageInput.js +1 -1
- package/lib/commonjs/components/MessageInput.js.map +1 -1
- package/lib/commonjs/constants/viewabilityConfig.js.map +1 -0
- package/lib/commonjs/hooks/isRtl.js +1 -1
- package/lib/commonjs/hooks/useLocalize.js +1 -1
- package/lib/commonjs/hooks/useLocalize.js.map +1 -1
- package/lib/commonjs/hooks/usePolling.js +1 -1
- package/lib/commonjs/hooks/usePolling.js.map +1 -1
- package/lib/commonjs/hooks/useTheme.js +1 -1
- package/lib/commonjs/hooks/useTheme.js.map +1 -1
- package/lib/commonjs/index.js +12 -12
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/notifications/index.js +22 -0
- package/lib/commonjs/notifications/index.js.map +1 -0
- package/lib/commonjs/{Accumulator.js → register/Accumulator.js} +13 -1
- package/lib/commonjs/register/Accumulator.js.map +1 -0
- package/lib/commonjs/{collectData.js → register/collectData.js} +2 -0
- package/lib/commonjs/register/collectData.js.map +1 -0
- package/lib/commonjs/register/index.js +17 -0
- package/lib/commonjs/register/index.js.map +1 -0
- package/lib/commonjs/register/init.js +14 -0
- package/lib/commonjs/register/init.js.map +1 -0
- package/lib/commonjs/register/login.js +25 -0
- package/lib/commonjs/register/login.js.map +1 -0
- package/lib/commonjs/register/logout.js +19 -0
- package/lib/commonjs/register/logout.js.map +1 -0
- package/lib/commonjs/{store.js → store/store.js} +3 -2
- package/lib/commonjs/store/store.js.map +1 -0
- package/lib/commonjs/support/ComnyxSupport.js +118 -0
- package/lib/commonjs/support/ComnyxSupport.js.map +1 -0
- package/lib/commonjs/support/index.js +13 -0
- package/lib/commonjs/support/index.js.map +1 -0
- package/lib/commonjs/utils/scalingUtils.js +1 -1
- package/lib/module/NativeComnyx.js +11 -0
- package/lib/module/NativeComnyx.js.map +1 -0
- package/lib/module/api/api.js +11 -4
- package/lib/module/api/api.js.map +1 -1
- package/lib/module/api/customers.js +3 -7
- package/lib/module/api/customers.js.map +1 -1
- package/lib/module/api/index.js +1 -1
- package/lib/module/api/index.js.map +1 -1
- package/lib/module/components/AppText.js +1 -1
- package/lib/module/components/AppText.js.map +1 -1
- package/lib/module/components/ChatList.js +6 -2
- package/lib/module/components/ChatList.js.map +1 -1
- package/lib/module/components/CustomerForm.js +3 -17
- package/lib/module/components/CustomerForm.js.map +1 -1
- package/lib/module/components/EmptyList.js +1 -1
- package/lib/module/components/EmptyList.js.map +1 -1
- package/lib/module/components/MessageInput.js +1 -1
- package/lib/module/components/MessageInput.js.map +1 -1
- package/lib/module/constants/viewabilityConfig.js.map +1 -0
- package/lib/module/hooks/isRtl.js +1 -1
- package/lib/module/hooks/isRtl.js.map +1 -1
- package/lib/module/hooks/useLocalize.js +1 -1
- package/lib/module/hooks/useLocalize.js.map +1 -1
- package/lib/module/hooks/usePolling.js +1 -1
- package/lib/module/hooks/usePolling.js.map +1 -1
- package/lib/module/hooks/useTheme.js +1 -1
- package/lib/module/hooks/useTheme.js.map +1 -1
- package/lib/module/index.js +9 -5
- package/lib/module/index.js.map +1 -1
- package/lib/module/notifications/index.js +20 -0
- package/lib/module/notifications/index.js.map +1 -0
- package/lib/module/{Accumulator.js → register/Accumulator.js} +12 -1
- package/lib/module/register/Accumulator.js.map +1 -0
- package/lib/module/{collectData.js → register/collectData.js} +2 -0
- package/lib/module/register/collectData.js.map +1 -0
- package/lib/module/register/index.js +13 -0
- package/lib/module/register/index.js.map +1 -0
- package/lib/module/register/init.js +10 -0
- package/lib/module/register/init.js.map +1 -0
- package/lib/module/register/login.js +21 -0
- package/lib/module/register/login.js.map +1 -0
- package/lib/module/register/logout.js +15 -0
- package/lib/module/register/logout.js.map +1 -0
- package/lib/module/{store.js → store/store.js} +2 -2
- package/lib/module/store/store.js.map +1 -0
- package/lib/module/support/ComnyxSupport.js +114 -0
- package/lib/module/support/ComnyxSupport.js.map +1 -0
- package/lib/module/support/index.js +4 -0
- package/lib/module/support/index.js.map +1 -0
- package/lib/module/utils/scalingUtils.js +1 -1
- package/lib/module/utils/scalingUtils.js.map +1 -1
- package/lib/typescript/jest.config.d.ts +4 -0
- package/lib/typescript/jest.config.d.ts.map +1 -0
- package/lib/typescript/setup-jest.d.ts +1 -0
- package/lib/typescript/setup-jest.d.ts.map +1 -0
- package/lib/typescript/src/NativeComnyx.d.ts +13 -0
- package/lib/typescript/src/NativeComnyx.d.ts.map +1 -0
- package/lib/typescript/src/api/api.d.ts +7 -0
- package/lib/typescript/src/api/api.d.ts.map +1 -0
- package/lib/typescript/src/api/conversations.d.ts.map +1 -0
- package/lib/typescript/src/api/customers.d.ts +5 -0
- package/lib/typescript/src/api/customers.d.ts.map +1 -0
- package/lib/typescript/{commonjs/src → src}/api/index.d.ts +1 -1
- package/lib/typescript/src/api/index.d.ts.map +1 -0
- package/lib/typescript/src/api/messages.d.ts.map +1 -0
- package/lib/typescript/src/components/AppText.d.ts.map +1 -0
- package/lib/typescript/src/components/ChatList.d.ts +5 -0
- package/lib/typescript/src/components/ChatList.d.ts.map +1 -0
- package/lib/typescript/src/components/CustomAlert.d.ts.map +1 -0
- package/lib/typescript/src/components/CustomerForm.d.ts +5 -0
- package/lib/typescript/src/components/CustomerForm.d.ts.map +1 -0
- package/lib/typescript/src/components/EmptyList.d.ts.map +1 -0
- package/lib/typescript/src/components/InitFailed.d.ts.map +1 -0
- package/lib/typescript/src/components/MessageInput.d.ts.map +1 -0
- package/lib/typescript/src/components/MessageItem.d.ts.map +1 -0
- package/lib/typescript/src/components/ScaledSheet.d.ts.map +1 -0
- package/lib/typescript/src/constants/activeOpacity.d.ts.map +1 -0
- package/lib/typescript/src/constants/countries.d.ts.map +1 -0
- package/lib/typescript/src/constants/rtl.d.ts.map +1 -0
- package/lib/typescript/src/constants/translations.d.ts.map +1 -0
- package/lib/typescript/src/constants/viewabilityConfig.d.ts.map +1 -0
- package/lib/typescript/src/data/fake/conversations.d.ts.map +1 -0
- package/lib/typescript/src/data/fake/customers.d.ts.map +1 -0
- package/lib/typescript/src/data/fake/messages.d.ts.map +1 -0
- package/lib/typescript/src/hooks/isRtl.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useLocalize.d.ts.map +1 -0
- package/lib/typescript/src/hooks/usePolling.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useTheme.d.ts.map +1 -0
- package/lib/typescript/src/hooks/useThemeColors.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +6 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/notifications/index.d.ts +21 -0
- package/lib/typescript/src/notifications/index.d.ts.map +1 -0
- package/lib/typescript/{commonjs/src → src/register}/Accumulator.d.ts +4 -3
- package/lib/typescript/src/register/Accumulator.d.ts.map +1 -0
- package/lib/typescript/src/register/collectData.d.ts.map +1 -0
- package/lib/typescript/src/register/index.d.ts +11 -0
- package/lib/typescript/src/register/index.d.ts.map +1 -0
- package/lib/typescript/src/register/init.d.ts +6 -0
- package/lib/typescript/src/register/init.d.ts.map +1 -0
- package/lib/typescript/src/register/login.d.ts +6 -0
- package/lib/typescript/src/register/login.d.ts.map +1 -0
- package/lib/typescript/src/register/logout.d.ts +2 -0
- package/lib/typescript/src/register/logout.d.ts.map +1 -0
- package/lib/typescript/{module/src → src/store}/store.d.ts +6 -4
- package/lib/typescript/src/store/store.d.ts.map +1 -0
- package/lib/typescript/src/support/ComnyxSupport.d.ts +12 -0
- package/lib/typescript/src/support/ComnyxSupport.d.ts.map +1 -0
- package/lib/typescript/src/support/index.d.ts +2 -0
- package/lib/typescript/src/support/index.d.ts.map +1 -0
- package/lib/typescript/src/types/ApiOptions.d.ts.map +1 -0
- package/lib/typescript/src/types/Conversation.d.ts.map +1 -0
- package/lib/typescript/src/types/Customer.d.ts.map +1 -0
- package/lib/typescript/src/types/GlobalTheme.d.ts.map +1 -0
- package/lib/typescript/src/types/Language.d.ts.map +1 -0
- package/lib/typescript/src/types/LocalizationKeys.d.ts.map +1 -0
- package/lib/typescript/src/types/MessageResponse.d.ts.map +1 -0
- package/lib/typescript/src/types/Theme.d.ts.map +1 -0
- package/lib/typescript/src/utils/date.d.ts.map +1 -0
- package/lib/typescript/src/utils/deepMap.d.ts.map +1 -0
- package/lib/typescript/src/utils/formatDate.d.ts.map +1 -0
- package/lib/typescript/src/utils/scalingUtils.d.ts.map +1 -0
- package/package.json +26 -27
- package/src/NativeComnyx.ts +13 -5
- package/src/api/api.ts +14 -4
- package/src/api/customers.ts +3 -8
- package/src/api/index.ts +1 -1
- package/src/components/AppText.tsx +1 -1
- package/src/components/ChatList.tsx +13 -3
- package/src/components/CustomerForm.tsx +10 -18
- package/src/components/EmptyList.tsx +1 -1
- package/src/components/MessageInput.tsx +1 -1
- package/src/hooks/isRtl.ts +1 -1
- package/src/hooks/useLocalize.ts +1 -1
- package/src/hooks/usePolling.ts +1 -1
- package/src/hooks/useTheme.ts +1 -1
- package/src/index.ts +9 -0
- package/src/notifications/index.ts +50 -0
- package/src/{Accumulator.ts → register/Accumulator.ts} +14 -2
- package/src/{collectData.ts → register/collectData.ts} +1 -0
- package/src/register/index.ts +11 -0
- package/src/register/init.ts +16 -0
- package/src/register/login.ts +24 -0
- package/src/register/logout.ts +13 -0
- package/src/{store.ts → store/store.ts} +7 -7
- package/src/support/ComnyxSupport.tsx +116 -0
- package/src/support/index.ts +1 -0
- package/src/utils/scalingUtils.ts +1 -1
- package/android/generated/java/com/comnyx/NativeComnyxSpec.java +0 -37
- package/ios/Comnyx.h +0 -6
- package/ios/Comnyx.mm +0 -18
- package/ios/generated/RNComnyxSpec/RNComnyxSpec-generated.mm +0 -39
- package/ios/generated/RNComnyxSpec/RNComnyxSpec.h +0 -63
- package/ios/generated/RNComnyxSpecJSI-generated.cpp +0 -28
- package/ios/generated/RNComnyxSpecJSI.h +0 -71
- package/lib/commonjs/Accumulator.js.map +0 -1
- package/lib/commonjs/App.js +0 -78
- package/lib/commonjs/App.js.map +0 -1
- package/lib/commonjs/NativeComnyx.ts +0 -8
- package/lib/commonjs/__dev__.js +0 -29
- package/lib/commonjs/__dev__.js.map +0 -1
- package/lib/commonjs/collectData.js.map +0 -1
- package/lib/commonjs/components/SizeMatter.js +0 -27
- package/lib/commonjs/components/SizeMatter.js.map +0 -1
- package/lib/commonjs/package.json +0 -1
- package/lib/commonjs/register.js +0 -26
- package/lib/commonjs/register.js.map +0 -1
- package/lib/commonjs/store.js.map +0 -1
- package/lib/commonjs/viewabilityConfig.js.map +0 -1
- package/lib/module/Accumulator.js.map +0 -1
- package/lib/module/App.js +0 -74
- package/lib/module/App.js.map +0 -1
- package/lib/module/NativeComnyx.ts +0 -8
- package/lib/module/__dev__.js +0 -29
- package/lib/module/__dev__.js.map +0 -1
- package/lib/module/collectData.js.map +0 -1
- package/lib/module/components/SizeMatter.js +0 -23
- package/lib/module/components/SizeMatter.js.map +0 -1
- package/lib/module/package.json +0 -1
- package/lib/module/register.js +0 -22
- package/lib/module/register.js.map +0 -1
- package/lib/module/store.js.map +0 -1
- package/lib/module/viewabilityConfig.js.map +0 -1
- package/lib/typescript/commonjs/package.json +0 -1
- package/lib/typescript/commonjs/src/Accumulator.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/App.d.ts +0 -12
- package/lib/typescript/commonjs/src/App.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/NativeComnyx.d.ts +0 -7
- package/lib/typescript/commonjs/src/NativeComnyx.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/__dev__.d.ts +0 -2
- package/lib/typescript/commonjs/src/__dev__.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/api/api.d.ts +0 -4
- package/lib/typescript/commonjs/src/api/api.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/api/conversations.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/api/customers.d.ts +0 -6
- package/lib/typescript/commonjs/src/api/customers.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/api/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/api/messages.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/collectData.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/AppText.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/ChatList.d.ts +0 -4
- package/lib/typescript/commonjs/src/components/ChatList.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/CustomAlert.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/CustomerForm.d.ts +0 -4
- package/lib/typescript/commonjs/src/components/CustomerForm.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/EmptyList.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/InitFailed.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/MessageInput.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/MessageItem.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/ScaledSheet.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/SizeMatter.d.ts +0 -7
- package/lib/typescript/commonjs/src/components/SizeMatter.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/constants/activeOpacity.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/constants/countries.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/constants/rtl.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/constants/translations.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/data/fake/conversations.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/data/fake/customers.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/data/fake/messages.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/hooks/isRtl.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/hooks/useLocalize.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/hooks/usePolling.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/hooks/useTheme.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/hooks/useThemeColors.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/index.d.ts +0 -7
- package/lib/typescript/commonjs/src/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/register.d.ts +0 -6
- package/lib/typescript/commonjs/src/register.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/store.d.ts +0 -40
- package/lib/typescript/commonjs/src/store.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/ApiOptions.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/Conversation.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/Customer.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/GlobalTheme.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/Language.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/LocalizationKeys.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/MessageResponse.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types/Theme.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/utils/date.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/utils/deepMap.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/utils/formatDate.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/utils/scalingUtils.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/viewabilityConfig.d.ts.map +0 -1
- package/lib/typescript/module/package.json +0 -1
- package/lib/typescript/module/src/Accumulator.d.ts +0 -18
- package/lib/typescript/module/src/Accumulator.d.ts.map +0 -1
- package/lib/typescript/module/src/App.d.ts +0 -12
- package/lib/typescript/module/src/App.d.ts.map +0 -1
- package/lib/typescript/module/src/NativeComnyx.d.ts +0 -7
- package/lib/typescript/module/src/NativeComnyx.d.ts.map +0 -1
- package/lib/typescript/module/src/__dev__.d.ts +0 -2
- package/lib/typescript/module/src/__dev__.d.ts.map +0 -1
- package/lib/typescript/module/src/api/api.d.ts +0 -4
- package/lib/typescript/module/src/api/api.d.ts.map +0 -1
- package/lib/typescript/module/src/api/conversations.d.ts +0 -7
- package/lib/typescript/module/src/api/conversations.d.ts.map +0 -1
- package/lib/typescript/module/src/api/customers.d.ts +0 -6
- package/lib/typescript/module/src/api/customers.d.ts.map +0 -1
- package/lib/typescript/module/src/api/index.d.ts +0 -4
- package/lib/typescript/module/src/api/index.d.ts.map +0 -1
- package/lib/typescript/module/src/api/messages.d.ts +0 -4
- package/lib/typescript/module/src/api/messages.d.ts.map +0 -1
- package/lib/typescript/module/src/collectData.d.ts +0 -3
- package/lib/typescript/module/src/collectData.d.ts.map +0 -1
- package/lib/typescript/module/src/components/AppText.d.ts +0 -14
- package/lib/typescript/module/src/components/AppText.d.ts.map +0 -1
- package/lib/typescript/module/src/components/ChatList.d.ts +0 -4
- package/lib/typescript/module/src/components/ChatList.d.ts.map +0 -1
- package/lib/typescript/module/src/components/CustomAlert.d.ts +0 -15
- package/lib/typescript/module/src/components/CustomAlert.d.ts.map +0 -1
- package/lib/typescript/module/src/components/CustomerForm.d.ts +0 -4
- package/lib/typescript/module/src/components/CustomerForm.d.ts.map +0 -1
- package/lib/typescript/module/src/components/EmptyList.d.ts +0 -2
- package/lib/typescript/module/src/components/EmptyList.d.ts.map +0 -1
- package/lib/typescript/module/src/components/InitFailed.d.ts +0 -6
- package/lib/typescript/module/src/components/InitFailed.d.ts.map +0 -1
- package/lib/typescript/module/src/components/MessageInput.d.ts +0 -5
- package/lib/typescript/module/src/components/MessageInput.d.ts.map +0 -1
- package/lib/typescript/module/src/components/MessageItem.d.ts +0 -6
- package/lib/typescript/module/src/components/MessageItem.d.ts.map +0 -1
- package/lib/typescript/module/src/components/ScaledSheet.d.ts +0 -2
- package/lib/typescript/module/src/components/ScaledSheet.d.ts.map +0 -1
- package/lib/typescript/module/src/components/SizeMatter.d.ts +0 -7
- package/lib/typescript/module/src/components/SizeMatter.d.ts.map +0 -1
- package/lib/typescript/module/src/constants/activeOpacity.d.ts +0 -2
- package/lib/typescript/module/src/constants/activeOpacity.d.ts.map +0 -1
- package/lib/typescript/module/src/constants/countries.d.ts +0 -7
- package/lib/typescript/module/src/constants/countries.d.ts.map +0 -1
- package/lib/typescript/module/src/constants/rtl.d.ts +0 -2
- package/lib/typescript/module/src/constants/rtl.d.ts.map +0 -1
- package/lib/typescript/module/src/constants/translations.d.ts +0 -4
- package/lib/typescript/module/src/constants/translations.d.ts.map +0 -1
- package/lib/typescript/module/src/data/fake/conversations.d.ts +0 -5
- package/lib/typescript/module/src/data/fake/conversations.d.ts.map +0 -1
- package/lib/typescript/module/src/data/fake/customers.d.ts +0 -3
- package/lib/typescript/module/src/data/fake/customers.d.ts.map +0 -1
- package/lib/typescript/module/src/data/fake/messages.d.ts +0 -3
- package/lib/typescript/module/src/data/fake/messages.d.ts.map +0 -1
- package/lib/typescript/module/src/hooks/isRtl.d.ts +0 -2
- package/lib/typescript/module/src/hooks/isRtl.d.ts.map +0 -1
- package/lib/typescript/module/src/hooks/useLocalize.d.ts +0 -3
- package/lib/typescript/module/src/hooks/useLocalize.d.ts.map +0 -1
- package/lib/typescript/module/src/hooks/usePolling.d.ts +0 -2
- package/lib/typescript/module/src/hooks/usePolling.d.ts.map +0 -1
- package/lib/typescript/module/src/hooks/useTheme.d.ts +0 -3
- package/lib/typescript/module/src/hooks/useTheme.d.ts.map +0 -1
- package/lib/typescript/module/src/hooks/useThemeColors.d.ts +0 -3
- package/lib/typescript/module/src/hooks/useThemeColors.d.ts.map +0 -1
- package/lib/typescript/module/src/index.d.ts +0 -7
- package/lib/typescript/module/src/index.d.ts.map +0 -1
- package/lib/typescript/module/src/register.d.ts +0 -6
- package/lib/typescript/module/src/register.d.ts.map +0 -1
- package/lib/typescript/module/src/store.d.ts.map +0 -1
- package/lib/typescript/module/src/types/ApiOptions.d.ts +0 -4
- package/lib/typescript/module/src/types/ApiOptions.d.ts.map +0 -1
- package/lib/typescript/module/src/types/Conversation.d.ts +0 -33
- package/lib/typescript/module/src/types/Conversation.d.ts.map +0 -1
- package/lib/typescript/module/src/types/Customer.d.ts +0 -39
- package/lib/typescript/module/src/types/Customer.d.ts.map +0 -1
- package/lib/typescript/module/src/types/GlobalTheme.d.ts +0 -6
- package/lib/typescript/module/src/types/GlobalTheme.d.ts.map +0 -1
- package/lib/typescript/module/src/types/Language.d.ts +0 -2
- package/lib/typescript/module/src/types/Language.d.ts.map +0 -1
- package/lib/typescript/module/src/types/LocalizationKeys.d.ts +0 -43
- package/lib/typescript/module/src/types/LocalizationKeys.d.ts.map +0 -1
- package/lib/typescript/module/src/types/MessageResponse.d.ts +0 -61
- package/lib/typescript/module/src/types/MessageResponse.d.ts.map +0 -1
- package/lib/typescript/module/src/types/Theme.d.ts +0 -28
- package/lib/typescript/module/src/types/Theme.d.ts.map +0 -1
- package/lib/typescript/module/src/utils/date.d.ts +0 -7
- package/lib/typescript/module/src/utils/date.d.ts.map +0 -1
- package/lib/typescript/module/src/utils/deepMap.d.ts +0 -7
- package/lib/typescript/module/src/utils/deepMap.d.ts.map +0 -1
- package/lib/typescript/module/src/utils/formatDate.d.ts +0 -2
- package/lib/typescript/module/src/utils/formatDate.d.ts.map +0 -1
- package/lib/typescript/module/src/utils/scalingUtils.d.ts +0 -10
- package/lib/typescript/module/src/utils/scalingUtils.d.ts.map +0 -1
- package/lib/typescript/module/src/viewabilityConfig.d.ts +0 -5
- package/lib/typescript/module/src/viewabilityConfig.d.ts.map +0 -1
- package/src/App.tsx +0 -77
- package/src/__dev__.ts +0 -22
- package/src/components/SizeMatter.tsx +0 -22
- package/src/index.tsx +0 -9
- package/src/register.ts +0 -34
- /package/lib/commonjs/{viewabilityConfig.js → constants/viewabilityConfig.js} +0 -0
- /package/lib/module/{viewabilityConfig.js → constants/viewabilityConfig.js} +0 -0
- /package/lib/typescript/{commonjs/src → src}/api/conversations.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/api/messages.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/AppText.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/CustomAlert.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/EmptyList.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/InitFailed.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/MessageInput.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/MessageItem.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/ScaledSheet.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/constants/activeOpacity.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/constants/countries.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/constants/rtl.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/constants/translations.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src/constants}/viewabilityConfig.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/data/fake/conversations.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/data/fake/customers.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/data/fake/messages.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/hooks/isRtl.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/hooks/useLocalize.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/hooks/usePolling.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/hooks/useTheme.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/hooks/useThemeColors.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src/register}/collectData.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/ApiOptions.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/Conversation.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/Customer.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/GlobalTheme.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/Language.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/LocalizationKeys.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/MessageResponse.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types/Theme.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/utils/date.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/utils/deepMap.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/utils/formatDate.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/utils/scalingUtils.d.ts +0 -0
- /package/src/{viewabilityConfig.ts → constants/viewabilityConfig.ts} +0 -0
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { accumulator } from './Accumulator';
|
|
2
|
+
import { isInitCalled, setLoginForAxios } from '../api/api';
|
|
3
|
+
import type { CreateCustomerRequest } from '../types/Customer';
|
|
4
|
+
import { useAppStore } from '../store/store';
|
|
5
|
+
import { updateCustomer } from '../api/customers';
|
|
6
|
+
|
|
7
|
+
interface LoginOptions {
|
|
8
|
+
externalId: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export function login(loginOptions: LoginOptions) {
|
|
12
|
+
if (!isInitCalled()) {
|
|
13
|
+
throw new Error('Please initialize the Comnyx SDK first');
|
|
14
|
+
}
|
|
15
|
+
if (!loginOptions.externalId) {
|
|
16
|
+
throw new Error('External ID is required for initialization');
|
|
17
|
+
}
|
|
18
|
+
accumulator.clear();
|
|
19
|
+
accumulator.register(async (accumulatedData: CreateCustomerRequest) => {
|
|
20
|
+
const data = await updateCustomer(accumulatedData, loginOptions.externalId);
|
|
21
|
+
setLoginForAxios(loginOptions.externalId);
|
|
22
|
+
useAppStore.getState().setCustomer(data.customer);
|
|
23
|
+
});
|
|
24
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { setLogoutForAxios } from '../api/api';
|
|
2
|
+
import { useAppStore } from '../store/store';
|
|
3
|
+
import { accumulator } from './Accumulator';
|
|
4
|
+
|
|
5
|
+
export async function logout() {
|
|
6
|
+
accumulator.clear();
|
|
7
|
+
setLogoutForAxios();
|
|
8
|
+
//TODO: state
|
|
9
|
+
useAppStore.setState({
|
|
10
|
+
customer: null,
|
|
11
|
+
formSubmitted: false,
|
|
12
|
+
});
|
|
13
|
+
}
|
|
@@ -3,9 +3,9 @@ import { shallow } from 'zustand/shallow';
|
|
|
3
3
|
import { createWithEqualityFn } from 'zustand/traditional';
|
|
4
4
|
import type { StateCreator } from 'zustand';
|
|
5
5
|
import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
6
|
-
import type {
|
|
7
|
-
import type {
|
|
8
|
-
import type {
|
|
6
|
+
import type { AppConversationMessage } from '../types/Conversation';
|
|
7
|
+
import type { LanguageCode } from '../types/Language';
|
|
8
|
+
import type { Customer } from '../types/Customer';
|
|
9
9
|
|
|
10
10
|
interface AppStoreState {
|
|
11
11
|
baseHeight: number;
|
|
@@ -23,7 +23,7 @@ interface AppStoreState {
|
|
|
23
23
|
) => AppConversationMessage[] | null
|
|
24
24
|
) => void;
|
|
25
25
|
setFirstMessage: (message: AppConversationMessage | null) => void;
|
|
26
|
-
setCustomer: (createCustomerResponse: Customer) => void;
|
|
26
|
+
setCustomer: (createCustomerResponse: Customer | null) => void;
|
|
27
27
|
setLanguage: (language: LanguageCode) => void;
|
|
28
28
|
setTheme: (theme: 'light' | 'dark') => void;
|
|
29
29
|
setFake: (fake: boolean) => void;
|
|
@@ -36,7 +36,7 @@ interface AppStoreState {
|
|
|
36
36
|
setForm: (form: Customer) => void;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
const storeCreator: StateCreator<AppStoreState> = (set, get) => ({
|
|
39
|
+
export const storeCreator: StateCreator<AppStoreState> = (set, get) => ({
|
|
40
40
|
baseWidth: 390,
|
|
41
41
|
baseHeight: 844,
|
|
42
42
|
initialized: false,
|
|
@@ -55,10 +55,10 @@ const storeCreator: StateCreator<AppStoreState> = (set, get) => ({
|
|
|
55
55
|
setFirstMessage: (message) => {
|
|
56
56
|
set({ firstMessage: message });
|
|
57
57
|
},
|
|
58
|
-
setCustomer: (createCustomerResponse: Customer) => {
|
|
58
|
+
setCustomer: (createCustomerResponse: Customer | null) => {
|
|
59
59
|
set({
|
|
60
60
|
customer: createCustomerResponse,
|
|
61
|
-
formSubmitted: !!createCustomerResponse
|
|
61
|
+
formSubmitted: !!createCustomerResponse?.name,
|
|
62
62
|
});
|
|
63
63
|
},
|
|
64
64
|
setLanguage: (language: LanguageCode) => {
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { View, TouchableOpacity, Image } from 'react-native';
|
|
2
|
+
import { ChatList } from '../components/ChatList';
|
|
3
|
+
import { CustomerForm } from '../components/CustomerForm';
|
|
4
|
+
import type { LanguageCode } from '../types/Language';
|
|
5
|
+
import { useEffect, useState } from 'react';
|
|
6
|
+
import { AppText } from '../components/AppText';
|
|
7
|
+
import { useThemeColors } from '../hooks/useThemeColors';
|
|
8
|
+
import { usePolling } from '../hooks/usePolling';
|
|
9
|
+
import { useAppStore } from '../store/store';
|
|
10
|
+
import { ScaledSheet } from '../components/ScaledSheet';
|
|
11
|
+
import { accumulator } from '../register/Accumulator';
|
|
12
|
+
const closeIcon = require('../assets/x-close.png');
|
|
13
|
+
|
|
14
|
+
interface SupportComnyxProps {
|
|
15
|
+
language?: LanguageCode;
|
|
16
|
+
theme?: 'light' | 'dark';
|
|
17
|
+
fake?: boolean;
|
|
18
|
+
onBack: () => void;
|
|
19
|
+
themes?: any;
|
|
20
|
+
rtlFix?: boolean;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export function ComnyxSupport({
|
|
24
|
+
language = 'en',
|
|
25
|
+
theme = 'dark',
|
|
26
|
+
fake = false,
|
|
27
|
+
onBack,
|
|
28
|
+
themes,
|
|
29
|
+
}: SupportComnyxProps) {
|
|
30
|
+
const { customer, formSubmitted } = useAppStore((s) => ({
|
|
31
|
+
customer: s.customer,
|
|
32
|
+
formSubmitted: s.formSubmitted,
|
|
33
|
+
}));
|
|
34
|
+
const themeColors = useThemeColors();
|
|
35
|
+
usePolling();
|
|
36
|
+
const [initLoading, setInitLoading] = useState(true);
|
|
37
|
+
useEffect(() => {
|
|
38
|
+
if (!accumulator.isListenerCalledOnce()) {
|
|
39
|
+
accumulator.flush().then(() => {
|
|
40
|
+
setTimeout(() => {
|
|
41
|
+
setInitLoading(false);
|
|
42
|
+
}, 100);
|
|
43
|
+
});
|
|
44
|
+
} else {
|
|
45
|
+
setInitLoading(false);
|
|
46
|
+
}
|
|
47
|
+
}, []);
|
|
48
|
+
useEffect(() => {
|
|
49
|
+
if (customer === null || !customer.external_id) {
|
|
50
|
+
useAppStore.setState({ data: [] });
|
|
51
|
+
}
|
|
52
|
+
}, [customer, customer?.external_id]);
|
|
53
|
+
|
|
54
|
+
useEffect(() => {
|
|
55
|
+
//TOOD: getState().initApp({language,theme,fake,rtlFix,themes})
|
|
56
|
+
useAppStore.getState().setLanguage(language);
|
|
57
|
+
useAppStore.getState().setTheme(theme);
|
|
58
|
+
useAppStore.getState().setFake(fake);
|
|
59
|
+
if (themes) {
|
|
60
|
+
useAppStore.getState().setThemes(themes);
|
|
61
|
+
}
|
|
62
|
+
}, [language, theme, fake, themes]);
|
|
63
|
+
|
|
64
|
+
if (!customer) {
|
|
65
|
+
//NOTE: customer yoksa register hiç çalışmamış
|
|
66
|
+
return (
|
|
67
|
+
<View
|
|
68
|
+
style={[
|
|
69
|
+
styles.container,
|
|
70
|
+
{ backgroundColor: themeColors.background, justifyContent: 'center' },
|
|
71
|
+
]}
|
|
72
|
+
>
|
|
73
|
+
<TouchableOpacity
|
|
74
|
+
activeOpacity={1}
|
|
75
|
+
style={[styles.iconContainer]}
|
|
76
|
+
onPress={onBack}
|
|
77
|
+
>
|
|
78
|
+
<Image
|
|
79
|
+
source={closeIcon}
|
|
80
|
+
style={[styles.closeIcon, { tintColor: themeColors.text }]}
|
|
81
|
+
/>
|
|
82
|
+
</TouchableOpacity>
|
|
83
|
+
<AppText
|
|
84
|
+
style={{ textAlign: 'center' }}
|
|
85
|
+
localization="app.initialization.required"
|
|
86
|
+
/>
|
|
87
|
+
</View>
|
|
88
|
+
);
|
|
89
|
+
} else if (!formSubmitted) {
|
|
90
|
+
//NOTE: customer var ama forSubmitted false (name===null)
|
|
91
|
+
return <CustomerForm loading={initLoading} onBack={onBack} />;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
return (
|
|
95
|
+
<View
|
|
96
|
+
style={[styles.container, { backgroundColor: themeColors.background }]}
|
|
97
|
+
>
|
|
98
|
+
<ChatList initLoading={initLoading} onBack={onBack} />
|
|
99
|
+
</View>
|
|
100
|
+
);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
const styles = ScaledSheet.create({
|
|
104
|
+
container: {
|
|
105
|
+
flex: 1,
|
|
106
|
+
},
|
|
107
|
+
iconContainer: {
|
|
108
|
+
position: 'absolute',
|
|
109
|
+
top: '60@vs',
|
|
110
|
+
left: '24@s',
|
|
111
|
+
},
|
|
112
|
+
closeIcon: {
|
|
113
|
+
width: '24@vs',
|
|
114
|
+
height: '24@vs',
|
|
115
|
+
},
|
|
116
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { ComnyxSupport } from './ComnyxSupport';
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
/**
|
|
3
|
-
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
|
4
|
-
*
|
|
5
|
-
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
|
6
|
-
* once the code is regenerated.
|
|
7
|
-
*
|
|
8
|
-
* @generated by codegen project: GenerateModuleJavaSpec.js
|
|
9
|
-
*
|
|
10
|
-
* @nolint
|
|
11
|
-
*/
|
|
12
|
-
|
|
13
|
-
package com.comnyx;
|
|
14
|
-
|
|
15
|
-
import com.facebook.proguard.annotations.DoNotStrip;
|
|
16
|
-
import com.facebook.react.bridge.ReactApplicationContext;
|
|
17
|
-
import com.facebook.react.bridge.ReactContextBaseJavaModule;
|
|
18
|
-
import com.facebook.react.bridge.ReactMethod;
|
|
19
|
-
import com.facebook.react.turbomodule.core.interfaces.TurboModule;
|
|
20
|
-
import javax.annotation.Nonnull;
|
|
21
|
-
|
|
22
|
-
public abstract class NativeComnyxSpec extends ReactContextBaseJavaModule implements TurboModule {
|
|
23
|
-
public static final String NAME = "Comnyx";
|
|
24
|
-
|
|
25
|
-
public NativeComnyxSpec(ReactApplicationContext reactContext) {
|
|
26
|
-
super(reactContext);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
@Override
|
|
30
|
-
public @Nonnull String getName() {
|
|
31
|
-
return NAME;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
@ReactMethod(isBlockingSynchronousMethod = true)
|
|
35
|
-
@DoNotStrip
|
|
36
|
-
public abstract double multiply(double a, double b);
|
|
37
|
-
}
|
package/ios/Comnyx.h
DELETED
package/ios/Comnyx.mm
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
#import "Comnyx.h"
|
|
2
|
-
|
|
3
|
-
@implementation Comnyx
|
|
4
|
-
RCT_EXPORT_MODULE()
|
|
5
|
-
|
|
6
|
-
- (NSNumber *)multiply:(double)a b:(double)b {
|
|
7
|
-
NSNumber *result = @(a * b);
|
|
8
|
-
|
|
9
|
-
return result;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
- (std::shared_ptr<facebook::react::TurboModule>)getTurboModule:
|
|
13
|
-
(const facebook::react::ObjCTurboModule::InitParams &)params
|
|
14
|
-
{
|
|
15
|
-
return std::make_shared<facebook::react::NativeComnyxSpecJSI>(params);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
@end
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
|
3
|
-
*
|
|
4
|
-
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
|
5
|
-
* once the code is regenerated.
|
|
6
|
-
*
|
|
7
|
-
* @generated by codegen project: GenerateModuleObjCpp
|
|
8
|
-
*
|
|
9
|
-
* We create an umbrella header (and corresponding implementation) here since
|
|
10
|
-
* Cxx compilation in BUCK has a limitation: source-code producing genrule()s
|
|
11
|
-
* must have a single output. More files => more genrule()s => slower builds.
|
|
12
|
-
*/
|
|
13
|
-
|
|
14
|
-
#import "RNComnyxSpec.h"
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
@implementation NativeComnyxSpecBase
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
- (void)setEventEmitterCallback:(EventEmitterCallbackWrapper *)eventEmitterCallbackWrapper
|
|
21
|
-
{
|
|
22
|
-
_eventEmitterCallback = std::move(eventEmitterCallbackWrapper->_eventEmitterCallback);
|
|
23
|
-
}
|
|
24
|
-
@end
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
namespace facebook::react {
|
|
28
|
-
|
|
29
|
-
static facebook::jsi::Value __hostFunction_NativeComnyxSpecJSI_multiply(facebook::jsi::Runtime& rt, TurboModule &turboModule, const facebook::jsi::Value* args, size_t count) {
|
|
30
|
-
return static_cast<ObjCTurboModule&>(turboModule).invokeObjCMethod(rt, NumberKind, "multiply", @selector(multiply:b:), args, count);
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
NativeComnyxSpecJSI::NativeComnyxSpecJSI(const ObjCTurboModule::InitParams ¶ms)
|
|
34
|
-
: ObjCTurboModule(params) {
|
|
35
|
-
|
|
36
|
-
methodMap_["multiply"] = MethodMetadata {2, __hostFunction_NativeComnyxSpecJSI_multiply};
|
|
37
|
-
|
|
38
|
-
}
|
|
39
|
-
} // namespace facebook::react
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
|
3
|
-
*
|
|
4
|
-
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
|
5
|
-
* once the code is regenerated.
|
|
6
|
-
*
|
|
7
|
-
* @generated by codegen project: GenerateModuleObjCpp
|
|
8
|
-
*
|
|
9
|
-
* We create an umbrella header (and corresponding implementation) here since
|
|
10
|
-
* Cxx compilation in BUCK has a limitation: source-code producing genrule()s
|
|
11
|
-
* must have a single output. More files => more genrule()s => slower builds.
|
|
12
|
-
*/
|
|
13
|
-
|
|
14
|
-
#ifndef __cplusplus
|
|
15
|
-
#error This file must be compiled as Obj-C++. If you are importing it, you must change your file extension to .mm.
|
|
16
|
-
#endif
|
|
17
|
-
|
|
18
|
-
// Avoid multiple includes of RNComnyxSpec symbols
|
|
19
|
-
#ifndef RNComnyxSpec_H
|
|
20
|
-
#define RNComnyxSpec_H
|
|
21
|
-
|
|
22
|
-
#import <Foundation/Foundation.h>
|
|
23
|
-
#import <RCTRequired/RCTRequired.h>
|
|
24
|
-
#import <RCTTypeSafety/RCTConvertHelpers.h>
|
|
25
|
-
#import <RCTTypeSafety/RCTTypedModuleConstants.h>
|
|
26
|
-
#import <React/RCTBridgeModule.h>
|
|
27
|
-
#import <React/RCTCxxConvert.h>
|
|
28
|
-
#import <React/RCTManagedPointer.h>
|
|
29
|
-
#import <ReactCommon/RCTTurboModule.h>
|
|
30
|
-
#import <optional>
|
|
31
|
-
#import <vector>
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
NS_ASSUME_NONNULL_BEGIN
|
|
35
|
-
|
|
36
|
-
@protocol NativeComnyxSpec <RCTBridgeModule, RCTTurboModule>
|
|
37
|
-
|
|
38
|
-
- (NSNumber *)multiply:(double)a
|
|
39
|
-
b:(double)b;
|
|
40
|
-
|
|
41
|
-
@end
|
|
42
|
-
|
|
43
|
-
@interface NativeComnyxSpecBase : NSObject {
|
|
44
|
-
@protected
|
|
45
|
-
facebook::react::EventEmitterCallback _eventEmitterCallback;
|
|
46
|
-
}
|
|
47
|
-
- (void)setEventEmitterCallback:(EventEmitterCallbackWrapper *)eventEmitterCallbackWrapper;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
@end
|
|
51
|
-
|
|
52
|
-
namespace facebook::react {
|
|
53
|
-
/**
|
|
54
|
-
* ObjC++ class for module 'NativeComnyx'
|
|
55
|
-
*/
|
|
56
|
-
class JSI_EXPORT NativeComnyxSpecJSI : public ObjCTurboModule {
|
|
57
|
-
public:
|
|
58
|
-
NativeComnyxSpecJSI(const ObjCTurboModule::InitParams ¶ms);
|
|
59
|
-
};
|
|
60
|
-
} // namespace facebook::react
|
|
61
|
-
|
|
62
|
-
NS_ASSUME_NONNULL_END
|
|
63
|
-
#endif // RNComnyxSpec_H
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
|
3
|
-
*
|
|
4
|
-
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
|
5
|
-
* once the code is regenerated.
|
|
6
|
-
*
|
|
7
|
-
* @generated by codegen project: GenerateModuleCpp.js
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
#include "RNComnyxSpecJSI.h"
|
|
11
|
-
|
|
12
|
-
namespace facebook::react {
|
|
13
|
-
|
|
14
|
-
static jsi::Value __hostFunction_NativeComnyxCxxSpecJSI_multiply(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
|
|
15
|
-
return static_cast<NativeComnyxCxxSpecJSI *>(&turboModule)->multiply(
|
|
16
|
-
rt,
|
|
17
|
-
count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber(),
|
|
18
|
-
count <= 1 ? throw jsi::JSError(rt, "Expected argument in position 1 to be passed") : args[1].asNumber()
|
|
19
|
-
);
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
NativeComnyxCxxSpecJSI::NativeComnyxCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker)
|
|
23
|
-
: TurboModule("Comnyx", jsInvoker) {
|
|
24
|
-
methodMap_["multiply"] = MethodMetadata {2, __hostFunction_NativeComnyxCxxSpecJSI_multiply};
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
} // namespace facebook::react
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
|
3
|
-
*
|
|
4
|
-
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
|
5
|
-
* once the code is regenerated.
|
|
6
|
-
*
|
|
7
|
-
* @generated by codegen project: GenerateModuleH.js
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
#pragma once
|
|
11
|
-
|
|
12
|
-
#include <ReactCommon/TurboModule.h>
|
|
13
|
-
#include <react/bridging/Bridging.h>
|
|
14
|
-
|
|
15
|
-
namespace facebook::react {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
class JSI_EXPORT NativeComnyxCxxSpecJSI : public TurboModule {
|
|
19
|
-
protected:
|
|
20
|
-
NativeComnyxCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker);
|
|
21
|
-
|
|
22
|
-
public:
|
|
23
|
-
virtual double multiply(jsi::Runtime &rt, double a, double b) = 0;
|
|
24
|
-
|
|
25
|
-
};
|
|
26
|
-
|
|
27
|
-
template <typename T>
|
|
28
|
-
class JSI_EXPORT NativeComnyxCxxSpec : public TurboModule {
|
|
29
|
-
public:
|
|
30
|
-
jsi::Value create(jsi::Runtime &rt, const jsi::PropNameID &propName) override {
|
|
31
|
-
return delegate_.create(rt, propName);
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
std::vector<jsi::PropNameID> getPropertyNames(jsi::Runtime& runtime) override {
|
|
35
|
-
return delegate_.getPropertyNames(runtime);
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
static constexpr std::string_view kModuleName = "Comnyx";
|
|
39
|
-
|
|
40
|
-
protected:
|
|
41
|
-
NativeComnyxCxxSpec(std::shared_ptr<CallInvoker> jsInvoker)
|
|
42
|
-
: TurboModule(std::string{NativeComnyxCxxSpec::kModuleName}, jsInvoker),
|
|
43
|
-
delegate_(reinterpret_cast<T*>(this), jsInvoker) {}
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
private:
|
|
47
|
-
class Delegate : public NativeComnyxCxxSpecJSI {
|
|
48
|
-
public:
|
|
49
|
-
Delegate(T *instance, std::shared_ptr<CallInvoker> jsInvoker) :
|
|
50
|
-
NativeComnyxCxxSpecJSI(std::move(jsInvoker)), instance_(instance) {
|
|
51
|
-
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
double multiply(jsi::Runtime &rt, double a, double b) override {
|
|
55
|
-
static_assert(
|
|
56
|
-
bridging::getParameterCount(&T::multiply) == 3,
|
|
57
|
-
"Expected multiply(...) to have 3 parameters");
|
|
58
|
-
|
|
59
|
-
return bridging::callFromJs<double>(
|
|
60
|
-
rt, &T::multiply, jsInvoker_, instance_, std::move(a), std::move(b));
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
private:
|
|
64
|
-
friend class NativeComnyxCxxSpec;
|
|
65
|
-
T *instance_;
|
|
66
|
-
};
|
|
67
|
-
|
|
68
|
-
Delegate delegate_;
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
} // namespace facebook::react
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["ACCUMULATOR_DEBOUNCE_TIME_IN_MS","Accumulator","registerData","__select_time","undefined","listener","_isListenerCalledOnce","constructor","register","customParameters","integrationParameters","debounce","add","data","Error","customParamsMap","Map","forEach","param","set","name","value","mergedCustomParameters","Array","from","entries","map","flush","reset","setTimeout","clearTimeout","get","isListenerCalledOnce","accumulator","exports"],"sourceRoot":"../../src","sources":["Accumulator.ts"],"mappings":";;;;;;AAEA,MAAMA,+BAA+B,GAAG,IAAI;AAE5C,MAAMC,WAAW,CAAC;EACRC,YAAY,GAAiC,IAAI;EACjDC,aAAa,GAA+BC,SAAS;EACrDC,QAAQ,GACd,IAAI;EACEC,qBAAqB,GAAY,KAAK;EAC9CC,WAAWA,CAAA,EAAG,CAAC;EAEfC,QAAQA,CAACH,QAAwD,EAAE;IACjE,IAAI,CAACH,YAAY,GAAG;MAClBO,gBAAgB,EAAE,EAAE;MACpBC,qBAAqB,EAAE,CAAC;IAC1B,CAAC;IACD,IAAI,CAACL,QAAQ,GAAGA,QAAQ;IACxB,IAAI,CAACM,QAAQ,CAAC,CAAC;EACjB;EAEAC,GAAGA,CAACC,IAAwD,EAAE;IAC5D,IAAI,CAAC,IAAI,CAACX,YAAY,EAAE;MACtB,MAAM,IAAIY,KAAK,CAAC,0BAA0B,CAAC;IAC7C;;IAEA;IACA,MAAMC,eAAe,GAAG,IAAIC,GAAG,CAAiB,CAAC;;IAEjD;IACA,CAAC,IAAI,CAACd,YAAY,CAACO,gBAAgB,IAAI,EAAE,EAAEQ,OAAO,CAAEC,KAAK,IAAK;MAC5DH,eAAe,CAACI,GAAG,CAACD,KAAK,CAACE,IAAI,EAAEF,KAAK,CAACG,KAAK,CAAC;IAC9C,CAAC,CAAC;;IAEF;IACA,CAACR,IAAI,CAACJ,gBAAgB,IAAI,EAAE,EAAEQ,OAAO,CAAEC,KAAK,IAAK;MAC/CH,eAAe,CAACI,GAAG,CAACD,KAAK,CAACE,IAAI,EAAEF,KAAK,CAACG,KAAK,CAAC;IAC9C,CAAC,CAAC;;IAEF;IACA,MAAMC,sBAAsB,GAAGC,KAAK,CAACC,IAAI,CAACT,eAAe,CAACU,OAAO,CAAC,CAAC,CAAC,CAACC,GAAG,CACtE,CAAC,CAACN,IAAI,EAAEC,KAAK,CAAC,MAAM;MAClBD,IAAI;MACJC;IACF,CAAC,CACH,CAAC;IAED,IAAI,CAACnB,YAAY,GAAG;MAClB,GAAG,IAAI,CAACA,YAAY;MACpB,GAAGW,IAAI;MACPH,qBAAqB,EAAE;QACrB,IAAI,IAAI,CAACR,YAAY,CAACQ,qBAAqB,IAAI,CAAC,CAAC,CAAC;QAClD,IAAIG,IAAI,CAACH,qBAAqB,IAAI,CAAC,CAAC;MACtC,CAAC;MACDD,gBAAgB,EAAEa;IACpB,CAAC;IACD,IAAI,CAACX,QAAQ,CAAC,CAAC;EACjB;EAEA,MAAMgB,KAAKA,CAAA,EAAG;IACZ,IAAI,CAAC,IAAI,CAACzB,YAAY,EAAE;MACtB,MAAM,IAAIY,KAAK,CAAC,0BAA0B,CAAC;IAC7C;IACA,IAAI,IAAI,CAACT,QAAQ,EAAE;MACjB,MAAM,IAAI,CAACA,QAAQ,CAAC,IAAI,CAACH,YAAa,CAAC;MACvC,IAAI,CAACA,YAAY,GAAG;QAClB,GAAG,IAAI,CAACA,YAAY;QACpBO,gBAAgB,EAAE;MACpB,CAAC;MACD,IAAI,CAACH,qBAAqB,GAAG,IAAI;IACnC;IACA,IAAI,CAACsB,KAAK,CAAC,CAAC;EACd;EAEAjB,QAAQA,CAAA,EAAG;IACT,IAAI,CAAC,IAAI,CAACT,YAAY,EAAE;MACtB,MAAM,IAAIY,KAAK,CAAC,0BAA0B,CAAC;IAC7C;IACA,IAAI,CAACc,KAAK,CAAC,CAAC;IACZ,IAAI,CAACzB,aAAa,GAAG0B,UAAU,CAAC,MAAM;MACpC,IAAI,IAAI,CAACxB,QAAQ,EAAE;QACjB,IAAI,CAACA,QAAQ,CAAC,IAAI,CAACH,YAAa,CAAC;QACjC,IAAI,CAACA,YAAY,GAAG;UAClB,GAAG,IAAI,CAACA,YAAa;UACrBO,gBAAgB,EAAE;QACpB,CAAC;QACD,IAAI,CAACH,qBAAqB,GAAG,IAAI;MACnC;IACF,CAAC,EAAEN,+BAA+B,CAAC;EACrC;EAEA4B,KAAKA,CAAA,EAAG;IACN,IAAI,IAAI,CAACzB,aAAa,EAAE;MACtB2B,YAAY,CAAC,IAAI,CAAC3B,aAAa,CAAC;IAClC;EACF;EAEA4B,GAAGA,CAAA,EAAG;IACJ,OAAO,IAAI,CAAC7B,YAAY;EAC1B;EAEA8B,oBAAoBA,CAAA,EAAG;IACrB,OAAO,IAAI,CAAC1B,qBAAqB;EACnC;AACF;AAEO,MAAM2B,WAAW,GAAAC,OAAA,CAAAD,WAAA,GAAG,IAAIhC,WAAW,CAAC,CAAC","ignoreList":[]}
|
package/lib/commonjs/App.js
DELETED
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.Comnyx = Comnyx;
|
|
7
|
-
var _reactNative = require("react-native");
|
|
8
|
-
var _store = require("./store.js");
|
|
9
|
-
var _ChatList = require("./components/ChatList.js");
|
|
10
|
-
var _CustomerForm = require("./components/CustomerForm.js");
|
|
11
|
-
var _react = require("react");
|
|
12
|
-
var _AppText = require("./components/AppText.js");
|
|
13
|
-
var _useThemeColors = require("./hooks/useThemeColors.js");
|
|
14
|
-
var _usePolling = require("./hooks/usePolling.js");
|
|
15
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
16
|
-
function Comnyx({
|
|
17
|
-
language = 'en',
|
|
18
|
-
theme = 'dark',
|
|
19
|
-
fake = false,
|
|
20
|
-
onBack,
|
|
21
|
-
themes
|
|
22
|
-
}) {
|
|
23
|
-
const {
|
|
24
|
-
customer,
|
|
25
|
-
formSubmitted
|
|
26
|
-
} = (0, _store.useAppStore)(s => ({
|
|
27
|
-
customer: s.customer,
|
|
28
|
-
formSubmitted: s.formSubmitted
|
|
29
|
-
}));
|
|
30
|
-
const themeColors = (0, _useThemeColors.useThemeColors)();
|
|
31
|
-
(0, _usePolling.usePolling)();
|
|
32
|
-
(0, _react.useEffect)(() => {
|
|
33
|
-
if (customer === null || !customer.external_id) {
|
|
34
|
-
_store.useAppStore.setState({
|
|
35
|
-
data: []
|
|
36
|
-
});
|
|
37
|
-
}
|
|
38
|
-
}, [customer, customer?.external_id]);
|
|
39
|
-
(0, _react.useEffect)(() => {
|
|
40
|
-
//TOOD: getState().initApp({language,theme,fake,rtlFix,themes})
|
|
41
|
-
_store.useAppStore.getState().setLanguage(language);
|
|
42
|
-
_store.useAppStore.getState().setTheme(theme);
|
|
43
|
-
_store.useAppStore.getState().setFake(fake);
|
|
44
|
-
if (themes) {
|
|
45
|
-
_store.useAppStore.getState().setThemes(themes);
|
|
46
|
-
}
|
|
47
|
-
}, [language, theme, fake, themes]);
|
|
48
|
-
if (!customer) {
|
|
49
|
-
//NOTE: customer yoksa register hiç çalışmamış
|
|
50
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
51
|
-
style: [styles.container, {
|
|
52
|
-
backgroundColor: themeColors.background
|
|
53
|
-
}],
|
|
54
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_AppText.AppText, {
|
|
55
|
-
localization: "app.initialization.required"
|
|
56
|
-
})
|
|
57
|
-
});
|
|
58
|
-
} else if (!formSubmitted) {
|
|
59
|
-
//NOTE: customer var ama forSubmitted false (name===null)
|
|
60
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_CustomerForm.CustomerForm, {
|
|
61
|
-
onBack: onBack
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
65
|
-
style: [styles.container, {
|
|
66
|
-
backgroundColor: themeColors.background
|
|
67
|
-
}],
|
|
68
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_ChatList.ChatList, {
|
|
69
|
-
onBack: onBack
|
|
70
|
-
})
|
|
71
|
-
});
|
|
72
|
-
}
|
|
73
|
-
const styles = _reactNative.StyleSheet.create({
|
|
74
|
-
container: {
|
|
75
|
-
flex: 1
|
|
76
|
-
}
|
|
77
|
-
});
|
|
78
|
-
//# sourceMappingURL=App.js.map
|
package/lib/commonjs/App.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_store","_ChatList","_CustomerForm","_react","_AppText","_useThemeColors","_usePolling","_jsxRuntime","Comnyx","language","theme","fake","onBack","themes","customer","formSubmitted","useAppStore","s","themeColors","useThemeColors","usePolling","useEffect","external_id","setState","data","getState","setLanguage","setTheme","setFake","setThemes","jsx","View","style","styles","container","backgroundColor","background","children","AppText","localization","CustomerForm","ChatList","StyleSheet","create","flex"],"sourceRoot":"../../src","sources":["App.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AACA,IAAAG,aAAA,GAAAH,OAAA;AAEA,IAAAI,MAAA,GAAAJ,OAAA;AACA,IAAAK,QAAA,GAAAL,OAAA;AACA,IAAAM,eAAA,GAAAN,OAAA;AACA,IAAAO,WAAA,GAAAP,OAAA;AAAgD,IAAAQ,WAAA,GAAAR,OAAA;AAWzC,SAASS,MAAMA,CAAC;EACrBC,QAAQ,GAAG,IAAI;EACfC,KAAK,GAAG,MAAM;EACdC,IAAI,GAAG,KAAK;EACZC,MAAM;EACNC;AACW,CAAC,EAAE;EACd,MAAM;IAAEC,QAAQ;IAAEC;EAAc,CAAC,GAAG,IAAAC,kBAAW,EAAEC,CAAC,KAAM;IACtDH,QAAQ,EAAEG,CAAC,CAACH,QAAQ;IACpBC,aAAa,EAAEE,CAAC,CAACF;EACnB,CAAC,CAAC,CAAC;EACH,MAAMG,WAAW,GAAG,IAAAC,8BAAc,EAAC,CAAC;EACpC,IAAAC,sBAAU,EAAC,CAAC;EAEZ,IAAAC,gBAAS,EAAC,MAAM;IACd,IAAIP,QAAQ,KAAK,IAAI,IAAI,CAACA,QAAQ,CAACQ,WAAW,EAAE;MAC9CN,kBAAW,CAACO,QAAQ,CAAC;QAAEC,IAAI,EAAE;MAAG,CAAC,CAAC;IACpC;EACF,CAAC,EAAE,CAACV,QAAQ,EAAEA,QAAQ,EAAEQ,WAAW,CAAC,CAAC;EAErC,IAAAD,gBAAS,EAAC,MAAM;IACd;IACAL,kBAAW,CAACS,QAAQ,CAAC,CAAC,CAACC,WAAW,CAACjB,QAAQ,CAAC;IAC5CO,kBAAW,CAACS,QAAQ,CAAC,CAAC,CAACE,QAAQ,CAACjB,KAAK,CAAC;IACtCM,kBAAW,CAACS,QAAQ,CAAC,CAAC,CAACG,OAAO,CAACjB,IAAI,CAAC;IACpC,IAAIE,MAAM,EAAE;MACVG,kBAAW,CAACS,QAAQ,CAAC,CAAC,CAACI,SAAS,CAAChB,MAAM,CAAC;IAC1C;EACF,CAAC,EAAE,CAACJ,QAAQ,EAAEC,KAAK,EAAEC,IAAI,EAAEE,MAAM,CAAC,CAAC;EAEnC,IAAI,CAACC,QAAQ,EAAE;IACb;IACA,oBACE,IAAAP,WAAA,CAAAuB,GAAA,EAAChC,YAAA,CAAAiC,IAAI;MACHC,KAAK,EAAE,CAACC,MAAM,CAACC,SAAS,EAAE;QAAEC,eAAe,EAAEjB,WAAW,CAACkB;MAAW,CAAC,CAAE;MAAAC,QAAA,eAEvE,IAAA9B,WAAA,CAAAuB,GAAA,EAAC1B,QAAA,CAAAkC,OAAO;QAACC,YAAY,EAAC;MAA6B,CAAE;IAAC,CAClD,CAAC;EAEX,CAAC,MAAM,IAAI,CAACxB,aAAa,EAAE;IACzB;IACA,oBAAO,IAAAR,WAAA,CAAAuB,GAAA,EAAC5B,aAAA,CAAAsC,YAAY;MAAC5B,MAAM,EAAEA;IAAO,CAAE,CAAC;EACzC;EAEA,oBACE,IAAAL,WAAA,CAAAuB,GAAA,EAAChC,YAAA,CAAAiC,IAAI;IACHC,KAAK,EAAE,CAACC,MAAM,CAACC,SAAS,EAAE;MAAEC,eAAe,EAAEjB,WAAW,CAACkB;IAAW,CAAC,CAAE;IAAAC,QAAA,eAEvE,IAAA9B,WAAA,CAAAuB,GAAA,EAAC7B,SAAA,CAAAwC,QAAQ;MAAC7B,MAAM,EAAEA;IAAO,CAAE;EAAC,CACxB,CAAC;AAEX;AAEA,MAAMqB,MAAM,GAAGS,uBAAU,CAACC,MAAM,CAAC;EAC/BT,SAAS,EAAE;IACTU,IAAI,EAAE;EACR;AACF,CAAC,CAAC","ignoreList":[]}
|
package/lib/commonjs/__dev__.js
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _store = require("./store.js");
|
|
4
|
-
// @ts-ignore
|
|
5
|
-
global.clearStorage = async () => {
|
|
6
|
-
_store.useAppStore.setState({
|
|
7
|
-
data: null
|
|
8
|
-
});
|
|
9
|
-
console.info('Storage cleared');
|
|
10
|
-
};
|
|
11
|
-
|
|
12
|
-
// @ts-ignore
|
|
13
|
-
global.changeLanguage = language => {
|
|
14
|
-
_store.useAppStore.setState({
|
|
15
|
-
language: language
|
|
16
|
-
});
|
|
17
|
-
console.info(`Language changed to: ${language}`);
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
// @ts-ignore
|
|
21
|
-
global.toggleTheme = () => {
|
|
22
|
-
const currentTheme = _store.useAppStore.getState().theme;
|
|
23
|
-
const newTheme = currentTheme === 'light' ? 'dark' : 'light';
|
|
24
|
-
_store.useAppStore.setState({
|
|
25
|
-
theme: newTheme
|
|
26
|
-
});
|
|
27
|
-
console.info(`Theme changed to: ${newTheme}`);
|
|
28
|
-
};
|
|
29
|
-
//# sourceMappingURL=__dev__.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_store","require","global","clearStorage","useAppStore","setState","data","console","info","changeLanguage","language","toggleTheme","currentTheme","getState","theme","newTheme"],"sourceRoot":"../../src","sources":["__dev__.ts"],"mappings":";;AAAA,IAAAA,MAAA,GAAAC,OAAA;AAGA;AACAC,MAAM,CAACC,YAAY,GAAG,YAAY;EAChCC,kBAAW,CAACC,QAAQ,CAAC;IAAEC,IAAI,EAAE;EAAK,CAAC,CAAC;EACpCC,OAAO,CAACC,IAAI,CAAC,iBAAiB,CAAC;AACjC,CAAC;;AAED;AACAN,MAAM,CAACO,cAAc,GAAIC,QAAgB,IAAK;EAC5CN,kBAAW,CAACC,QAAQ,CAAC;IAAEK,QAAQ,EAAEA;EAAyB,CAAC,CAAC;EAC5DH,OAAO,CAACC,IAAI,CAAC,wBAAwBE,QAAQ,EAAE,CAAC;AAClD,CAAC;;AAED;AACAR,MAAM,CAACS,WAAW,GAAG,MAAM;EACzB,MAAMC,YAAY,GAAGR,kBAAW,CAACS,QAAQ,CAAC,CAAC,CAACC,KAAK;EACjD,MAAMC,QAAQ,GAAGH,YAAY,KAAK,OAAO,GAAG,MAAM,GAAG,OAAO;EAC5DR,kBAAW,CAACC,QAAQ,CAAC;IAAES,KAAK,EAAEC;EAAS,CAAC,CAAC;EACzCR,OAAO,CAACC,IAAI,CAAC,qBAAqBO,QAAQ,EAAE,CAAC;AAC/C,CAAC","ignoreList":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_Accumulator","require","collectData","key","value","accumulator","add","customParameters","name","registerOneSignalForComnyx","external_id","integrationParameters","onesignal"],"sourceRoot":"../../src","sources":["collectData.ts"],"mappings":";;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAEO,SAASC,WAAWA,CAACC,GAAW,EAAEC,KAAa,EAAE;EACtDC,wBAAW,CAACC,GAAG,CAAC;IACdC,gBAAgB,EAAE,CAChB;MACEC,IAAI,EAAEL,GAAG;MACTC;IACF,CAAC;EAEL,CAAC,CAAC;AACJ;AAEO,SAASK,0BAA0BA,CAACC,WAAmB,EAAE;EAC9DL,wBAAW,CAACC,GAAG,CAAC;IACdK,qBAAqB,EAAE;MACrBC,SAAS,EAAE;QACTF;MACF;IACF;EACF,CAAC,CAAC;AACJ","ignoreList":[]}
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.SizeMatter = SizeMatter;
|
|
7
|
-
var _react = require("react");
|
|
8
|
-
var _store = require("../store.js");
|
|
9
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
10
|
-
function SizeMatter({
|
|
11
|
-
baseWidth = 390,
|
|
12
|
-
baseHeight = 844
|
|
13
|
-
}) {
|
|
14
|
-
const {
|
|
15
|
-
updateBaseDimensions
|
|
16
|
-
} = (0, _store.useAppStore)(s => ({
|
|
17
|
-
updateBaseDimensions: s.updateBaseDimensions
|
|
18
|
-
}));
|
|
19
|
-
(0, _react.useEffect)(() => {
|
|
20
|
-
updateBaseDimensions({
|
|
21
|
-
baseWidth,
|
|
22
|
-
baseHeight
|
|
23
|
-
});
|
|
24
|
-
}, [baseHeight, baseWidth, updateBaseDimensions]);
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_jsxRuntime.Fragment, {});
|
|
26
|
-
}
|
|
27
|
-
//# sourceMappingURL=SizeMatter.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"names":["_react","require","_store","_jsxRuntime","SizeMatter","baseWidth","baseHeight","updateBaseDimensions","useAppStore","s","useEffect","jsx","Fragment"],"sourceRoot":"../../../src","sources":["components/SizeMatter.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AAAuC,IAAAE,WAAA,GAAAF,OAAA;AAOhC,SAASG,UAAUA,CAAC;EAAEC,SAAS,GAAG,GAAG;EAAEC,UAAU,GAAG;AAAiB,CAAC,EAAE;EAC7E,MAAM;IAAEC;EAAqB,CAAC,GAAG,IAAAC,kBAAW,EAAEC,CAAC,KAAM;IACnDF,oBAAoB,EAAEE,CAAC,CAACF;EAC1B,CAAC,CAAC,CAAC;EAEH,IAAAG,gBAAS,EAAC,MAAM;IACdH,oBAAoB,CAAC;MACnBF,SAAS;MACTC;IACF,CAAC,CAAC;EACJ,CAAC,EAAE,CAACA,UAAU,EAAED,SAAS,EAAEE,oBAAoB,CAAC,CAAC;EAEjD,oBAAO,IAAAJ,WAAA,CAAAQ,GAAA,EAAAR,WAAA,CAAAS,QAAA,IAAI,CAAC;AACd","ignoreList":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"type":"commonjs"}
|