@kontextso/sdk-react-native 0.0.5-rc.8 → 0.0.5

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/dist/index.d.mts CHANGED
@@ -140,7 +140,6 @@ interface AdsProviderProps {
140
140
  logLevel?: any;
141
141
  conversationId?: string;
142
142
  styles?: AdStyles;
143
- throwError?: boolean;
144
143
  }
145
144
  declare const VISITOR_ID_KEY = "brain-visitor-id";
146
145
  declare const AdsProvider: ({ children, messages, publisherToken, isLoading, adserverUrl, isDisabled, character, conversationId, userId, logLevel, onAdView, onAdClick, ...props }: AdsProviderProps) => react_jsx_runtime.JSX.Element;
package/dist/index.d.ts CHANGED
@@ -140,7 +140,6 @@ interface AdsProviderProps {
140
140
  logLevel?: any;
141
141
  conversationId?: string;
142
142
  styles?: AdStyles;
143
- throwError?: boolean;
144
143
  }
145
144
  declare const VISITOR_ID_KEY = "brain-visitor-id";
146
145
  declare const AdsProvider: ({ children, messages, publisherToken, isLoading, adserverUrl, isDisabled, character, conversationId, userId, logLevel, onAdView, onAdClick, ...props }: AdsProviderProps) => react_jsx_runtime.JSX.Element;
package/dist/index.js CHANGED
@@ -201,7 +201,7 @@ var parseMessageText = (text) => {
201
201
  var import_loglevel = __toESM(require("loglevel"));
202
202
 
203
203
  // package.json
204
- var version = "0.0.5-rc.7";
204
+ var version = "0.0.5-rc.8";
205
205
 
206
206
  // src/hooks/useInitializeAds.tsx
207
207
  async function initialize(adServerUrl, publisherToken, userId, conversationId, legacyVisitorId, character) {
@@ -858,12 +858,6 @@ var AdsProviderWithoutBoundary = ({
858
858
  publisherToken
859
859
  });
860
860
  const ads = mergeAds({ initAds, preloadAds, streamAds, viewedAds });
861
- if (props.throwError && Math.random() < 0.1) {
862
- throw new Error("Test error");
863
- }
864
- if (props.throwError && Math.random() < 0.1) {
865
- Promise.reject(new Error("Test async error"));
866
- }
867
861
  const markAdAsViewed = (ad) => {
868
862
  import_loglevel5.default.debug("[Brain] Calling onAdView");
869
863
  onAdView && onAdView({
@@ -954,8 +948,7 @@ var AdsProvider = ({
954
948
  userId,
955
949
  logLevel,
956
950
  onAdView,
957
- onAdClick,
958
- throwError: props.throwError
951
+ onAdClick
959
952
  }
960
953
  )
961
954
  }
package/dist/index.mjs CHANGED
@@ -175,7 +175,7 @@ var parseMessageText = (text) => {
175
175
  import log from "loglevel";
176
176
 
177
177
  // package.json
178
- var version = "0.0.5-rc.7";
178
+ var version = "0.0.5-rc.8";
179
179
 
180
180
  // src/hooks/useInitializeAds.tsx
181
181
  async function initialize(adServerUrl, publisherToken, userId, conversationId, legacyVisitorId, character) {
@@ -832,12 +832,6 @@ var AdsProviderWithoutBoundary = ({
832
832
  publisherToken
833
833
  });
834
834
  const ads = mergeAds({ initAds, preloadAds, streamAds, viewedAds });
835
- if (props.throwError && Math.random() < 0.1) {
836
- throw new Error("Test error");
837
- }
838
- if (props.throwError && Math.random() < 0.1) {
839
- Promise.reject(new Error("Test async error"));
840
- }
841
835
  const markAdAsViewed = (ad) => {
842
836
  log5.debug("[Brain] Calling onAdView");
843
837
  onAdView && onAdView({
@@ -928,8 +922,7 @@ var AdsProvider = ({
928
922
  userId,
929
923
  logLevel,
930
924
  onAdView,
931
- onAdClick,
932
- throwError: props.throwError
925
+ onAdClick
933
926
  }
934
927
  )
935
928
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kontextso/sdk-react-native",
3
- "version": "0.0.5-rc.8",
3
+ "version": "0.0.5",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",