zoho / SalesIQ-Mobilisten-ReactNative

Your mobile app's ideal live chat partner. Power up your mobile App with the SalesIQ Mobilisten SDK for React-Native.
https://mobilisten.io/
9 stars 11 forks source link

ZohoSalesIQ.setThemeColorforiOS() and ZohoSalesIQ.setThemeColorforAndroid() are not functioning in React Native #67

Closed waseemViwell closed 4 months ago

waseemViwell commented 1 year ago

The ZohoSalesIQ.setThemeColorforiOS() and ZohoSalesIQ.setThemeColorforAndroid() function, which is used to set the theme color for Zoho SalesIQ in iOS and Android apps built using React Native, is not functioning as expected. When attempting to set a theme color using this function, the color does not update in the Zoho SalesIQ interface. Steps to Reproduce:

  1. Create a React Native app with Zoho SalesIQ integration.
  2. Attempt to set a theme color using the ZohoSalesIQ.setThemeColorforiOS() or ZohoSalesIQ.setThemeColorforAndroid() function in ios and Android respectively.
  3. Observe that the color does not update in the Zoho SalesIQ interface.

Expected Behavior: The ZohoSalesIQ.setThemeColorforiOS() and ZohoSalesIQ.setThemeColorforAndroid() functions should set the theme color for Zoho SalesIQ in iOS and Andriod apps built using React Native, and the color should update in the Zoho SalesIQ interface.

Actual Behavior: The ZohoSalesIQ.setThemeColorforiOS() and ZohoSalesIQ.setThemeColorforAndroid() function is not functioning as expected, and the color does not update in the Zoho SalesIQ interface.

Environment: React Native version: 0.68.2 Zoho SalesIQ SDK version: 5.2.0 iOS version: 16.2 Android Version: 12 Device: any IOS or Android

Screen Shot 2023-04-07 at 3 45 54 PM
bhahirathan-mb-11956 commented 1 year ago

Hi @waseemViwell ,

Thank you for reaching out to us. Please be advised that the setThemeColorForAndroid() API has been deprecated. Instead, you can modify the colors of the elements for the Android SDK by adding the style with the appropriate attribute and value in styles.xml. Specifically, the "colorAccent" attribute can be utilized to change the theme color of our SDK. For further clarification, please refer to the sample snippet provided below.

<resources>
<!--  This works, if syncThemeWithOsForAndroid is set as false for both light and dark mode -->
<style name="Theme.SalesIQ.Base" parent="Theme.SalesIQ.Base.DarkActionBar" >
           <item name="colorAccent">#ff0000</item>
           <item name="siq_toolbar_backgroundcolor">#ff0000</item>
           <item name="siq_forms_toolbar_backgroundcolor">#ff0000</item>
</style>

<!--  This works, if syncThemeWithOsForAndroid is set as true when the device is in dark mode  -->
<style name="Theme.SalesIQ.Base.Dark" parent="Theme.SalesIQ.Dark" >
            <item name="colorAccent">#0000ff</item>
            <item name="siq_toolbar_backgroundcolor">#0000ff</item>
            <item name="siq_forms_toolbar_backgroundcolor">#0000ff</item>
</style>
<!--  This works, if syncThemeWithOsForAndroid is set as true when the device is in light mode  -->
<style name="Theme.SalesIQ.Base.DarkActionBar" parent="Theme.SalesIQ.Light" >
           <item name="colorAccent">#00ff00</item>
           <item name="siq_toolbar_backgroundcolor">#00ff00</item>
           <item name="siq_forms_toolbar_backgroundcolor">#00ff00</item>
</style>
</resources>

For iOS, the .setThemeColorforiOS() API is functional, and also the screenshot you have attached shows that the theme color is changed. If you have any specific issue, please write back to us at support@zohosalesiq.com if the issue persists, we’ll be happy to assist you.

waseemViwell commented 1 year ago

Hi David, thank you so much for your kind response. yes, For iOS, the .setThemeColorforiOS() API is functional, but i was looking to change the background color as well in IOS. can you please guide me on this? Thanks


From: David Bhahirathan @.> Sent: 11 April 2023 14:29 To: zoho/SalesIQ-Mobilisten-ReactNative @.> Cc: Muhammad Waseem @.>; Mention @.> Subject: Re: [zoho/SalesIQ-Mobilisten-ReactNative] ZohoSalesIQ.setThemeColorforiOS() and ZohoSalesIQ.setThemeColorforAndroid() are not functioning in React Native (Issue #67)

You don't often get email from @.*** Learn why this is importanthttps://aka.ms/LearnAboutSenderIdentification

Hi @waseemViwellhttps://github.com/waseemViwell ,

Thank you for reaching out to us. Please be advised that the setThemeColorForAndroid() API has been deprecated. Instead, you can modify the colors of the elements for the Android SDK by adding the style with the appropriate attribute and value in styles.xml. Specifically, the "colorAccent" attribute can be utilized to change the theme color of our SDK. For further clarification, please refer to the sample snippet provided below.

For iOS, the .setThemeColorforiOS() API is functional, and also the screenshot you have attached shows that the theme color is changed. If you have any specific issue, please write back to us at @.**@.> if the issue persists, we’ll be happy to assist you.

— Reply to this email directly, view it on GitHubhttps://github.com/zoho/SalesIQ-Mobilisten-ReactNative/issues/67#issuecomment-1502988408, or unsubscribehttps://github.com/notifications/unsubscribe-auth/A7A6EEHG732V576E2JYMFKDXAUP6BANCNFSM6AAAAAAWWOHYPI. You are receiving this because you were mentioned.Message ID: @.***>

Confidentiality Notice: "The contents of this message and its attachments are confidential and intended solely for the sender and the addressee. If you are not the intended recipient, it is prohibited to use or share the information in any way. If you have received this email by mistake, please notify the sender immediately and delete it from your system. Electronic correspondence cannot be guaranteed to be secure or error-free. No employee or agent is authorized to conclude any binding agreement on behalf of the company with another party by email without specific confirmation "

venkatesh-ramesh-12517 commented 1 year ago

Hi @waseemViwell

As of now, we do not have support for customizing background colors. However, we have plans to add UI customization support in the future, though we do not have a confirmed timeline at the moment. Rest assured, you will be notified when this feature becomes available for use and when the new version is released. Thank you for your understanding.

Regards, Venkatesh Zoho SalesIQ.