New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

countly-sdk-react-native-bridge

Package Overview
Dependencies
Maintainers
3
Versions
70
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

countly-sdk-react-native-bridge - npm Package Compare versions

Comparing version 20.11.0 to 20.11.1

countly-sdk-react-native-bridge-20.11.1.tgz

16

CHANGELOG.md

@@ -0,1 +1,9 @@

## 20.11.1
* Added "getFeedbackWidgets" method to get a list of available feedback widgets as array of object to handle multiple widgets of same type.
* Added "presentFeedbackWidgetObject" to show/present a feedback widget with the combined widget object.
* Deprecated "getAvailableFeedbackWidgets" method. Usinag this function it is not possible to see all the available feedback widgets. In case there are multiple ones for the same type, only the last one will be returned due to their id being overwritten in the type field.
* Deprecated "presentFeedbackWidget" method.
* Updated underlying android SDK to 20.11.2
* Updated underlying ios SDK to 20.11.1
## 20.11.0

@@ -6,6 +14,6 @@ * !! Due to cocoapods issue with Xcode 12, we have created a new temporary Pod with a fix for Countly iOS SDK and named it "CounltyPod". Due to that change if you have already add the reference of files "CountlyNotificationService.h/m" then you need to update these files references by adding the files from "CountlyPod" and remove the old reference files.

* Added Surveys and NPS feedback widgets
* Added replaceAllAppKeysInQueueWithCurrentAppKey method to replace all app keys in queue with the current app key
* Added removeDifferentAppKeysFromQueue method to remove all different app keys from the queue
* Added setStarRatingDialogTexts method to set text's for different fields of star rating dialog
* Added setViewTracking deprecated method back.
* Added "replaceAllAppKeysInQueueWithCurrentAppKey" method to replace all app keys in queue with the current app key
* Added "removeDifferentAppKeysFromQueue" method to remove all different app keys from the queue
* Added "setStarRatingDialogTexts" method to set text's for different fields of star rating dialog
* Added "setViewTracking" deprecated method back.
* Example app updated with single plugin for both IDFA and App tracking permission for iOS.

@@ -12,0 +20,0 @@ * Device id NSNull check added for iOS to fix the length on null crash.

@@ -637,10 +637,11 @@ /**

Countly.showFeedbackPopup = function(widgetId, closeButtonText,){
Countly.showFeedbackPopup = function(widgetId, closeButtonText){
CountlyReactNative.showFeedbackPopup([widgetId.toString() || "", closeButtonText.toString() || "Done"]);
}
/**
* Get a list of available feedback widgets for this device ID
* Get a list of available feedback widgets as array of object to handle multiple widgets of same type.
*/
Countly.getAvailableFeedbackWidgets = async function(){
const result = await CountlyReactNative.getAvailableFeedbackWidgets();
Countly.getFeedbackWidgets = async function(){
const result = await CountlyReactNative.getFeedbackWidgets();
return result;

@@ -650,13 +651,66 @@ }

/**
* Get a list of available feedback widgets for this device ID
* @deprecated in 20.11.1 : use 'getFeedbackWidgets' intead of 'getAvailableFeedbackWidgets'.
* Using the old function it will not be possible to see all the available feedback widgets.
* In case there are multiple ones for the same type, only the last one will be returned due to their id being overwritten in the type field.
* The newer function allow also to see the widgets 'name' field which can be further used to filter and identify specific widgets.
*/
Countly.getAvailableFeedbackWidgets = async function(){
const result = await CountlyReactNative.getAvailableFeedbackWidgets();
return result;
}
/**
* Present a chosen feedback widget
*
* @param {String} widgetType - type of widget : "nps" or "survey"
* @param {String} widgetId - id of widget to present
* @param {Object} feedbackWidget - feeback Widget with id, type and name
* @param {String} closeButtonText - text for cancel/close button
*/
Countly.presentFeedbackWidget = function(widgetType, widgetId, closeButtonText,){
CountlyReactNative.presentFeedbackWidget([widgetId.toString() || "",widgetType.toString() || "", closeButtonText.toString()]);
Countly.presentFeedbackWidgetObject = async function(feedbackWidget, closeButtonText){
if(!feedbackWidget) {
if(await CountlyReactNative.isLoggingEnabled()) {
console.error("[CountlyReactNative] presentFeedbackWidgetObject, feedbackWidget should not be null or undefined");
}
return "feedbackWidget should not be null or undefined";
}
if(!feedbackWidget.id) {
if(await CountlyReactNative.isLoggingEnabled()) {
console.error("[CountlyReactNative] presentFeedbackWidgetObject, feedbackWidget id should not be null or empty");
}
return "FeedbackWidget id should not be null or empty";
}
if(!feedbackWidget.type) {
if(await CountlyReactNative.isLoggingEnabled()) {
console.error("[CountlyReactNative] presentFeedbackWidgetObject, feedbackWidget type should not be null or empty");
}
return "FeedbackWidget type should not be null or empty";
}
if (typeof closeButtonText != "string") {
closeButtonText = "";
if(await CountlyReactNative.isLoggingEnabled()) {
console.warn("[CountlyReactNative] presentFeedbackWidgetObject, unsupported data type of closeButtonText : '" + (typeof args) + "'");
}
}
feedbackWidget.name = feedbackWidget.name || "";
closeButtonText = closeButtonText || "";
CountlyReactNative.presentFeedbackWidget([feedbackWidget.id, feedbackWidget.type, feedbackWidget.name, closeButtonText]);
}
/**
* Present a chosen feedback widget
*
* @param {String} widgetType - type of widget : "nps" or "survey"
* @param {String} widgetId - id of widget to present
* @param {String} closeButtonText - text for cancel/close button
* @deprecated in 20.11.1 : use 'presentFeedbackWidgetObject' intead of 'presentFeedbackWidget'.
*/
Countly.presentFeedbackWidget = function(widgetType, widgetId, closeButtonText){
var feedbackWidget = {
"id": widgetId,
"type": widgetType
};
Countly.presentFeedbackWidgetObject(feedbackWidget, closeButtonText)
}
/**
*

@@ -663,0 +717,0 @@ * Events get grouped together and are sent either every minute or after the unsent event count reaches a threshold. By default it is 10

@@ -344,8 +344,9 @@ import React, { Component } from 'react';

showSurvey = function(){
Countly.getAvailableFeedbackWidgets().then((retrivedWidgets) => {
if("survey" in retrivedWidgets) {
Countly.presentFeedbackWidget("survey", retrivedWidgets.survey, "Close")
Countly.getFeedbackWidgets().then((retrivedWidgets) => {
var surveyWidget = retrivedWidgets.find(x => x.type === 'survey')
if(surveyWidget) {
Countly.presentFeedbackWidgetObject(surveyWidget, "Close")
}
},(err) => {
console.error("[CountlyCordova] getAvailableFeedbackWidgets error : " +err);
console.error("showSurvey getFeedbackWidgets error : " +err);
});

@@ -355,9 +356,10 @@ }

showNPS = function(){
Countly.getAvailableFeedbackWidgets().then((retrivedWidgets) => {
if("nps" in retrivedWidgets) {
Countly.presentFeedbackWidget("nps", retrivedWidgets.survey, "Cancel")
}
},(err) => {
console.error("[CountlyCordova] getAvailableFeedbackWidgets error : " +err);
});
Countly.getFeedbackWidgets().then((retrivedWidgets) => {
var npsWidget = retrivedWidgets.find(x => x.type === 'nps')
if(npsWidget) {
Countly.presentFeedbackWidgetObject(npsWidget, "Close")
}
},(err) => {
console.error("showNPS getFeedbackWidgets error : " +err);
});
}

@@ -364,0 +366,0 @@

{
"name": "countly-sdk-react-native-bridge",
"version": "20.11.0",
"version": "20.11.1",
"author": "Countly <hello@count.ly> (https://count.ly/)",

@@ -5,0 +5,0 @@ "bugs": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc