@sprig-technologies/sprig-browser 2.26.4 → 2.26.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-rCLyJyii.cjs → index-1NW718SB.cjs} +7 -7
- package/dist/{index-GurVf9fu.js → index-IMQ1RWe8.js} +644 -627
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +6 -8
- package/dist/index.js +1 -1
- package/dist/{view-KfdScd8f.js → view-8NEFT9sC.js} +4 -3
- package/dist/{view-TTq-V8ms.cjs → view-kCdkKjUT.cjs} +3 -3
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./index-1NW718SB.cjs");exports.DismissReason=e.DismissReason;exports.SprigAPI=e.SprigAPI;exports.SprigEvent=e.SprigEvent;exports.default=e.index;exports.sprig=e.sprig;
|
package/dist/index.d.ts
CHANGED
|
@@ -2746,7 +2746,10 @@ declare namespace sprigConfig {
|
|
|
2746
2746
|
) => Promise<void>;
|
|
2747
2747
|
removeSurveyListener: (listener: SprigListener) => Promise<void>;
|
|
2748
2748
|
reviewSurvey: (surveyId: number) => void;
|
|
2749
|
-
setAttribute: (
|
|
2749
|
+
setAttribute: (
|
|
2750
|
+
attribute: string,
|
|
2751
|
+
value: string | number | boolean,
|
|
2752
|
+
) => IdentifyResult;
|
|
2750
2753
|
setAttributes: (attributes?: SprigAttributes) => IdentifyResult;
|
|
2751
2754
|
setPartnerAnonymousId: (
|
|
2752
2755
|
partnerAnonymousId: string,
|
|
@@ -2887,18 +2890,13 @@ declare class SprigAPI {
|
|
|
2887
2890
|
SURVEY_HEIGHT: SprigEvent;
|
|
2888
2891
|
SURVEY_WIDTH: SprigEvent;
|
|
2889
2892
|
SURVEY_PRESENTED: SprigEvent;
|
|
2890
|
-
/**
|
|
2891
|
-
* Remove all listeners set on Sprig
|
|
2892
|
-
*/
|
|
2893
2893
|
SURVEY_LIFE_CYCLE: SprigEvent;
|
|
2894
2894
|
SURVEY_WILL_CLOSE: SprigEvent;
|
|
2895
2895
|
SURVEY_WILL_PRESENT: SprigEvent;
|
|
2896
2896
|
QUESTION_ANSWERED: SprigEvent;
|
|
2897
2897
|
REPLAY_CAPTURE: SprigEvent;
|
|
2898
2898
|
CLOSE_SURVEY_ON_OVERLAY_CLICK: SprigEvent;
|
|
2899
|
-
VISITOR_ID_UPDATED: SprigEvent;
|
|
2900
|
-
* Set a partner anonymous id for future requests.
|
|
2901
|
-
*/
|
|
2899
|
+
VISITOR_ID_UPDATED: SprigEvent;
|
|
2902
2900
|
DATA: {
|
|
2903
2901
|
DISMISS_REASONS: {
|
|
2904
2902
|
API: DismissReason;
|
|
@@ -2929,7 +2927,7 @@ declare class SprigAPI {
|
|
|
2929
2927
|
/**
|
|
2930
2928
|
* Set an arbitrary attribute on the visitor
|
|
2931
2929
|
*/
|
|
2932
|
-
setAttribute(attribute: string, value: string): void;
|
|
2930
|
+
setAttribute(attribute: string, value: string | number | boolean): void;
|
|
2933
2931
|
/**
|
|
2934
2932
|
* Set attributes on visitor
|
|
2935
2933
|
*/
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { g as zo, a as qo, T as X, i as ot, C as Vt, D as $t, A as ke, I as ce, e as $e, s as We, S as he, b as Re, P as pt, c as wn, R as Wo, u as ht, d as Go, f as Zo, h as Yo, j as E, E as Qo, k as B, l as Ie, m as wt, n as q, o as U, M as re, v as mt, p as Ko, q as Jo, r as Xo, t as er } from "./index-
|
|
1
|
+
import { g as zo, a as qo, T as X, i as ot, C as Vt, D as $t, A as ke, I as ce, e as $e, s as We, S as he, b as Re, P as pt, c as wn, R as Wo, u as ht, d as Go, f as Zo, h as Yo, j as E, E as Qo, k as B, l as Ie, m as wt, n as q, o as U, M as re, v as mt, p as Ko, q as Jo, r as Xo, t as er } from "./index-IMQ1RWe8.js";
|
|
2
2
|
var b = /* @__PURE__ */ ((e) => (e.ConsentLegal = "consentlegal", e.Likert = "likert", e.Matrix = "matrix", e.MultipleChoice = "multiplechoice", e.MultipleSelect = "multipleselect", e.NPS = "nps", e.Open = "open", e.RecordedTask = "recordedtask", e.TextUrlPrompt = "texturlprompt", e.Thanks = "thanks", e.Uploading = "uploading", e.VideoVoice = "videovoice", e))(b || {}), J = /* @__PURE__ */ ((e) => (e.Answered = "answered", e.Contains = "contains", e.DoesNotContain = "notcontains", e.DoesNotInclude = "list_dni", e.Equal = "eq", e.GivenUp = "given_up", e.GreaterThan = "gt", e.GreaterThanOrEqual = "gte", e.LessThan = "lt", e.LessThanOrEqual = "lte", e.ListAll = "list_all", e.ListAtLeastOne = "list_alo", e.ListExact = "list_exact", e.NotEqual = "neq", e.Partial = "partial", e.Skipped = "skipped", e))(J || {}), we = /* @__PURE__ */ ((e) => (e.Camera = "camera", e.Microphone = "microphone", e.Screen = "screen", e))(we || {}), Y = /* @__PURE__ */ ((e) => (e.AvPermission = "av_permission", e.ScreenPermission = "screen_permission", e.StartTask = "start_task", e.CompleteTask = "complete_task", e))(Y || {}), be = /* @__PURE__ */ ((e) => (e.Number = "number", e.Smiley = "smiley", e.Star = "star", e))(be || {}), Oe, S, Sn, ve, Ht, En, ft, Tn, Ne = {}, Pn = [], tr = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, Qe = Array.isArray;
|
|
3
3
|
function ae(e, t) {
|
|
4
4
|
for (var n in t)
|
|
@@ -1522,7 +1522,8 @@ const cn = 1, Lt = {
|
|
|
1522
1522
|
previewKey: s.previewKey
|
|
1523
1523
|
};
|
|
1524
1524
|
ot(`Submitting response: ${JSON.stringify(r.value, null, 2)} for survey: ${s.surveyId}`), n && (ot("Survey complete"), Wo({
|
|
1525
|
-
id: s.surveyId
|
|
1525
|
+
id: s.surveyId,
|
|
1526
|
+
userAgent: window.navigator.userAgent
|
|
1526
1527
|
}));
|
|
1527
1528
|
const d = await s.trackPromise(ht(`${s.apiURL}/sdk/1/environments/${s.envId}/visitors/${s.userId}/responses/submit`, {
|
|
1528
1529
|
body: JSON.stringify(a),
|
|
@@ -5319,7 +5320,7 @@ function is(e, t = !0) {
|
|
|
5319
5320
|
}, _.appendChild(C);
|
|
5320
5321
|
} else
|
|
5321
5322
|
console.warn("[Sprig] - recording functionality not configured due to missing UpChunk dependency");
|
|
5322
|
-
const k = "2.26.
|
|
5323
|
+
const k = "2.26.5", T = s || ((w = d.eventEmitter) == null ? void 0 : w.emit);
|
|
5323
5324
|
T == null || T(ce.VerifyViewVersion, {
|
|
5324
5325
|
[Re.ViewVersion]: k
|
|
5325
5326
|
}), m && t && Ee(u(Ki, {}), m);
|