@sprig-technologies/sprig-bundled 1.1.1 → 1.1.3

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.ts CHANGED
@@ -1361,13 +1361,13 @@ type StringifyOptions = {
1361
1361
  depthOfLimit: number;
1362
1362
  };
1363
1363
  type LogRecordOptions = {
1364
- level?: LogLevel[];
1364
+ level?: LogLevel$1[];
1365
1365
  lengthThreshold?: number;
1366
1366
  stringifyOptions?: StringifyOptions;
1367
1367
  logger?: Logger | 'console';
1368
1368
  };
1369
1369
  type LogData = {
1370
- level: LogLevel;
1370
+ level: LogLevel$1;
1371
1371
  trace: string[];
1372
1372
  payload: string[];
1373
1373
  };
@@ -1392,13 +1392,13 @@ type Logger = {
1392
1392
  trace?: typeof console.trace;
1393
1393
  warn?: typeof console.warn;
1394
1394
  };
1395
- type LogLevel = keyof Logger;
1395
+ type LogLevel$1 = keyof Logger;
1396
1396
  declare const PLUGIN_NAME = "rrweb/console@1";
1397
1397
  declare const getRecordConsolePlugin: (options?: LogRecordOptions) => RecordPlugin;
1398
1398
 
1399
- type ReplayLogger = Partial<Record<LogLevel, (data: LogData) => void>>;
1399
+ type ReplayLogger = Partial<Record<LogLevel$1, (data: LogData) => void>>;
1400
1400
  type LogReplayConfig = {
1401
- level?: LogLevel[];
1401
+ level?: LogLevel$1[];
1402
1402
  replayLogger?: ReplayLogger;
1403
1403
  };
1404
1404
  declare const getReplayConsolePlugin: (options?: LogReplayConfig) => ReplayPlugin;
@@ -1408,7 +1408,6 @@ declare const rrweb_EventType: typeof EventType;
1408
1408
  type rrweb_IncrementalSource = IncrementalSource;
1409
1409
  declare const rrweb_IncrementalSource: typeof IncrementalSource;
1410
1410
  type rrweb_LogData = LogData;
1411
- type rrweb_LogLevel = LogLevel;
1412
1411
  type rrweb_Logger = Logger;
1413
1412
  type rrweb_MouseInteractions = MouseInteractions;
1414
1413
  declare const rrweb_MouseInteractions: typeof MouseInteractions;
@@ -1427,7 +1426,7 @@ declare const rrweb_record: typeof record;
1427
1426
  type rrweb_recordOptions<T> = recordOptions<T>;
1428
1427
  declare const rrweb_unpack: typeof unpack;
1429
1428
  declare namespace rrweb {
1430
- export { rrweb_EventType as EventType, rrweb_IncrementalSource as IncrementalSource, type rrweb_LogData as LogData, type rrweb_LogLevel as LogLevel, type rrweb_Logger as Logger, rrweb_MouseInteractions as MouseInteractions, rrweb_PLUGIN_NAME as PLUGIN_NAME, rrweb_Replayer as Replayer, rrweb_ReplayerEvents as ReplayerEvents, type rrweb_StringifyOptions as StringifyOptions, rrweb_addCustomEvent as addCustomEvent, rrweb_freezePage as freezePage, rrweb_getRecordConsolePlugin as getRecordConsolePlugin, rrweb_getReplayConsolePlugin as getReplayConsolePlugin, _mirror as mirror, rrweb_pack as pack, rrweb_record as record, type rrweb_recordOptions as recordOptions, rrweb_unpack as unpack, utils_d as utils };
1429
+ export { rrweb_EventType as EventType, rrweb_IncrementalSource as IncrementalSource, type rrweb_LogData as LogData, type LogLevel$1 as LogLevel, type rrweb_Logger as Logger, rrweb_MouseInteractions as MouseInteractions, rrweb_PLUGIN_NAME as PLUGIN_NAME, rrweb_Replayer as Replayer, rrweb_ReplayerEvents as ReplayerEvents, type rrweb_StringifyOptions as StringifyOptions, rrweb_addCustomEvent as addCustomEvent, rrweb_freezePage as freezePage, rrweb_getRecordConsolePlugin as getRecordConsolePlugin, rrweb_getReplayConsolePlugin as getReplayConsolePlugin, _mirror as mirror, rrweb_pack as pack, rrweb_record as record, type rrweb_recordOptions as recordOptions, rrweb_unpack as unpack, utils_d as utils };
1431
1430
  }
1432
1431
 
1433
1432
  interface XhrResponse {
@@ -2097,7 +2096,9 @@ interface MultipleChoiceOption {
2097
2096
  id: number;
2098
2097
  label: string;
2099
2098
  optionProperties: null | {
2100
- allowsTextEntry: boolean;
2099
+ allowsTextEntry?: boolean;
2100
+ noneOfTheAbove?: boolean;
2101
+ isPinned?: boolean;
2101
2102
  };
2102
2103
  order: number;
2103
2104
  productId: number;
@@ -2113,7 +2114,7 @@ interface CommonMultipleChoiceProps {
2113
2114
  buttonText?: string;
2114
2115
  captionText: string;
2115
2116
  conceptUrl: ConceptUrl;
2116
- randomize: "none" | "keeplast" | "all";
2117
+ randomize: "none" | "all";
2117
2118
  required: boolean;
2118
2119
  };
2119
2120
  }
@@ -2241,6 +2242,7 @@ declare const EVENTS: {
2241
2242
  SURVEY_DIMENSIONS: SprigEvent;
2242
2243
  SURVEY_FADING_OUT: SprigEvent;
2243
2244
  SURVEY_HEIGHT: SprigEvent;
2245
+ SURVEY_WIDTH: SprigEvent;
2244
2246
  SURVEY_PRESENTED: SprigEvent;
2245
2247
  SURVEY_LIFE_CYCLE: SprigEvent;
2246
2248
  SURVEY_WILL_CLOSE: SprigEvent;
@@ -2455,6 +2457,14 @@ type SprigEventMap = {
2455
2457
  declare const eventEmitter: Emitter<SprigEventMap>;
2456
2458
  type SprigEventEmitter = typeof eventEmitter;
2457
2459
 
2460
+ declare const LogLevels: {
2461
+ readonly Error: 1;
2462
+ readonly Warn: 2;
2463
+ readonly Info: 3;
2464
+ readonly Debug: 4;
2465
+ };
2466
+ type LogLevel = (typeof LogLevels)[keyof typeof LogLevels];
2467
+
2458
2468
  declare const enum FramePosition {
2459
2469
  BottomLeft = "bottomLeft",
2460
2470
  BottomRight = "bottomRight",
@@ -2554,6 +2564,8 @@ interface Config extends MobileReplayConfig {
2554
2564
  isPreview?: boolean;
2555
2565
  launchDarklyEnabled?: boolean;
2556
2566
  locale: string;
2567
+ logLevel?: LogLevel;
2568
+ logBufferLimit?: number;
2557
2569
  marketingUrl?: string;
2558
2570
  maxAttrNameLength: number;
2559
2571
  maxAttrValueLength: number;
@@ -2691,7 +2703,7 @@ declare namespace sprigConfig {
2691
2703
  surveyId: number;
2692
2704
  responseGroupUuid: string;
2693
2705
  eventDigest?: EventDigest[];
2694
- }) => Promise<void>;
2706
+ }) => Promise<boolean>;
2695
2707
  _generateVideoUploadUrl: (body: {
2696
2708
  mediaRecordingUid?: string;
2697
2709
  mediaType?: MediaType;
@@ -2734,7 +2746,10 @@ declare namespace sprigConfig {
2734
2746
  ) => Promise<void>;
2735
2747
  removeSurveyListener: (listener: SprigListener) => Promise<void>;
2736
2748
  reviewSurvey: (surveyId: number) => void;
2737
- setAttribute: (attribute: string, value: string | number) => IdentifyResult;
2749
+ setAttribute: (
2750
+ attribute: string,
2751
+ value: string | number | boolean,
2752
+ ) => IdentifyResult;
2738
2753
  setAttributes: (attributes?: SprigAttributes) => IdentifyResult;
2739
2754
  setPartnerAnonymousId: (
2740
2755
  partnerAnonymousId: string,
@@ -2826,7 +2841,7 @@ declare global {
2826
2841
  };
2827
2842
  Intercom: { ul_wasVisible?: boolean } & ((
2828
2843
  method: string,
2829
- data: unknown,
2844
+ data?: unknown,
2830
2845
  ) => void);
2831
2846
  optimizely?: optimizely.Optimizely;
2832
2847
  optimizelyDatafile?: object;
@@ -2873,6 +2888,7 @@ declare class SprigAPI {
2873
2888
  SURVEY_DIMENSIONS: SprigEvent;
2874
2889
  SURVEY_FADING_OUT: SprigEvent;
2875
2890
  SURVEY_HEIGHT: SprigEvent;
2891
+ SURVEY_WIDTH: SprigEvent;
2876
2892
  SURVEY_PRESENTED: SprigEvent;
2877
2893
  SURVEY_LIFE_CYCLE: SprigEvent;
2878
2894
  SURVEY_WILL_CLOSE: SprigEvent;
@@ -2911,7 +2927,7 @@ declare class SprigAPI {
2911
2927
  /**
2912
2928
  * Set an arbitrary attribute on the visitor
2913
2929
  */
2914
- setAttribute(attribute: string, value: string): void;
2930
+ setAttribute(attribute: string, value: string | number | boolean): void;
2915
2931
  /**
2916
2932
  * Set attributes on visitor
2917
2933
  */
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { D as i, B as r, S as p, F as e } from "./index-BuamjNZy.js";
1
+ import { D as i, F as r, S as p, G as e } from "./index-Ist5vU7V.js";
2
2
  export {
3
3
  i as DismissReason,
4
4
  r as SprigAPI,