@envive-ai/react-hooks 0.1.2 → 0.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/adapters/amplitude/index.cjs +13 -13
- package/dist/adapters/amplitude/index.js +10 -10
- package/dist/{api-B2euFL-5.cjs → api-BtzLHcfU.cjs} +27 -27
- package/dist/{api-XRr_lAG6.js → api-kpPTZhV9.js} +27 -27
- package/dist/application/config/index.cjs +1 -1
- package/dist/application/config/index.js +1 -1
- package/dist/application/models/graphql/index.cjs +12 -12
- package/dist/application/models/graphql/index.js +10 -10
- package/dist/application/models/guards/api/index.cjs +2 -2
- package/dist/application/models/guards/api/index.js +2 -2
- package/dist/application/models/index.cjs +54 -54
- package/dist/application/models/index.js +10 -10
- package/dist/application/models/utilityTypes/index.cjs +1 -1
- package/dist/application/models/utilityTypes/index.js +1 -1
- package/dist/application/models/variantInfo/index.cjs +1 -1
- package/dist/application/models/variantInfo/index.js +1 -1
- package/dist/application/service/customerService/index.cjs +2 -2
- package/dist/application/service/customerService/index.js +2 -2
- package/dist/application/service/index.cjs +82 -82
- package/dist/application/service/index.d.cts +1 -1
- package/dist/application/service/index.d.ts +1 -1
- package/dist/application/service/index.js +16 -16
- package/dist/application/utils/index.cjs +37 -37
- package/dist/application/utils/index.d.ts +1 -1
- package/dist/application/utils/index.js +10 -10
- package/dist/atoms/app/index.cjs +16 -16
- package/dist/atoms/app/index.d.cts +1 -1
- package/dist/atoms/app/index.d.ts +2 -2
- package/dist/atoms/app/index.js +10 -10
- package/dist/atoms/atomStore/index.cjs +1 -1
- package/dist/atoms/atomStore/index.js +1 -1
- package/dist/atoms/chat/index.cjs +40 -40
- package/dist/atoms/chat/index.d.cts +26 -26
- package/dist/atoms/chat/index.d.ts +28 -28
- package/dist/atoms/chat/index.js +10 -10
- package/dist/atoms/globalSearch/index.d.cts +5 -5
- package/dist/atoms/globalSearch/index.d.ts +5 -5
- package/dist/atoms/org/index.cjs +33 -33
- package/dist/atoms/org/index.d.cts +26 -26
- package/dist/atoms/org/index.d.ts +26 -26
- package/dist/atoms/org/index.js +11 -11
- package/dist/atoms/search/index.cjs +12 -12
- package/dist/atoms/search/index.d.cts +1 -1
- package/dist/atoms/search/index.d.ts +1 -1
- package/dist/atoms/search/index.js +12 -12
- package/dist/{bandolier-oMkFDJMF.cjs → bandolier-CQrxBHsk.cjs} +37 -37
- package/dist/{bandolier-C7PAIw02.js → bandolier-Di9DpZ8e.js} +12 -12
- package/dist/{carpe-C0ccKuR9.cjs → carpe-3NJOR-Rj.cjs} +23 -23
- package/dist/{carpe-DFc78_lJ.js → carpe-DmWKaIQq.js} +12 -12
- package/dist/{cdnService-DvDSpfVJ.js → cdnService-BNreZjqy.js} +1 -1
- package/dist/{cdnService-dJU3sHpF.cjs → cdnService-vLxePdrU.cjs} +1 -1
- package/dist/{api-CxGedDxj.cjs → chat-CCQMmhc1.cjs} +2807 -2807
- package/dist/{api-NJEaveju.js → chat-H6YcCS4I.js} +2774 -2774
- package/dist/contexts/index.cjs +19 -19
- package/dist/contexts/index.d.cts +3 -3
- package/dist/contexts/index.js +14 -14
- package/dist/{coterie-Cp9FAJTQ.cjs → coterie-D0UFsFC5.cjs} +17 -17
- package/dist/{coterie-BGT8hqFR.js → coterie-JblRmIZL.js} +12 -12
- package/dist/{customerService-CUyZzowx.js → customerService-C4wc0glQ.js} +1 -1
- package/dist/{customerService-DqPw_XKf.cjs → customerService-zsDlp7g2.cjs} +1 -1
- package/dist/default-C5ZTV8HA.cjs +4 -0
- package/dist/{default-wf_IORgo.js → default-DPv8m-eQ.js} +1 -1
- package/dist/{default-BAXPatxf.cjs → default-DRKBosow.cjs} +1 -1
- package/dist/default-ao0vRl0W.js +4 -0
- package/dist/{dreamlandBaby-DZvM81LQ.js → dreamlandBaby-CyS8oW8X.js} +12 -12
- package/dist/{dreamlandBaby-BzuMvUFS.cjs → dreamlandBaby-y7kSvwH2.cjs} +19 -19
- package/dist/events/index.cjs +1 -1
- package/dist/events/index.js +1 -1
- package/dist/{fiveCbd-DE-tDY3d.cjs → fiveCbd-CXVuIBiZ.cjs} +24 -24
- package/dist/{fiveCbd-HNBPqPtX.js → fiveCbd-Cyc3-Ab9.js} +12 -12
- package/dist/{forLoveAndLemons-BeVEBOiu.cjs → forLoveAndLemons-CxQS0USq.cjs} +14 -14
- package/dist/{forLoveAndLemons-BKmJJ9pq.js → forLoveAndLemons-D8mcgmdk.js} +12 -12
- package/dist/{greenpan-BX1viAZB.js → greenpan-JM6SHcqO.js} +12 -12
- package/dist/{greenpan-chd3aa5I.cjs → greenpan-eIzyxVsn.cjs} +21 -21
- package/dist/{grooveLife-CHot3rZw.js → grooveLife-BmsUc2cD.js} +12 -12
- package/dist/{grooveLife-DEob7rK0.cjs → grooveLife-KdTizVUn.cjs} +19 -19
- package/dist/{homegrownCannabis-CoIjcehi.cjs → homegrownCannabis-C0GDai4r.cjs} +18 -18
- package/dist/{homegrownCannabis-CwkS1qDA.js → homegrownCannabis-a9udocBT.js} +12 -12
- package/dist/hooks/index.cjs +36 -36
- package/dist/hooks/index.d.cts +7 -7
- package/dist/hooks/index.d.ts +4 -4
- package/dist/hooks/index.js +14 -14
- package/dist/{contexts-iAzSvZjb.cjs → hooks-DjOa7ihH.cjs} +195 -195
- package/dist/{contexts-DO75-Kmx.js → hooks-fneW8SWw.js} +93 -93
- package/dist/{index-BkhvV8RZ.d.cts → index-BQErGgfM.d.cts} +29 -29
- package/dist/{index-CzMrMKx-.d.ts → index-CnqHN_jz.d.ts} +29 -29
- package/dist/interceptors/index.cjs +11 -11
- package/dist/interceptors/index.js +11 -11
- package/dist/{jackArcher-bewC0q1T.cjs → jackArcher-B6OJ0N3a.cjs} +25 -25
- package/dist/{jackArcher-BA-pkB4A.js → jackArcher-B9fe4Hv8.js} +12 -12
- package/dist/{jordanCraig-B5k9nlAw.cjs → jordanCraig-0CB_m_ts.cjs} +65 -65
- package/dist/{jordanCraig-BsQ1mYbt.js → jordanCraig-DNm1iw1L.js} +12 -12
- package/dist/{kindredBravely-BxYkCpGY.js → kindredBravely-CZgt7DJA.js} +12 -12
- package/dist/{kindredBravely-DsN0fo3s.cjs → kindredBravely-KvYPbckZ.cjs} +19 -19
- package/dist/{kutFromTheKloth-BQTCu3ct.cjs → kutFromTheKloth-BxgtWZs9.cjs} +19 -19
- package/dist/{kutFromTheKloth-bukOQM3P.js → kutFromTheKloth-SmteSZjk.js} +12 -12
- package/dist/{larryAndSerges-bj7fgy9b.cjs → larryAndSerges-6O_u3L90.cjs} +15 -15
- package/dist/{larryAndSerges-D1ecaT5a.js → larryAndSerges-DO-zG8ES.js} +11 -11
- package/dist/{leapsAndRebounds-DhNpZETg.js → leapsAndRebounds-BK62AmXw.js} +12 -12
- package/dist/{leapsAndRebounds-BfneG_0c.cjs → leapsAndRebounds-gPsWVUmQ.cjs} +20 -20
- package/dist/{longevityrx-D0goIuX0.cjs → longevityrx-DjKbwJo3.cjs} +17 -17
- package/dist/{longevityrx-CnoGcw0w.js → longevityrx-eq5TeUcy.js} +12 -12
- package/dist/{lookOptic-C4afLPZP.cjs → lookOptic-BPPqms_j.cjs} +17 -17
- package/dist/{lookOptic-uJWIKpER.js → lookOptic-jRpBXQCN.js} +12 -12
- package/dist/{mantraBrand-DuwKHM26.js → mantraBrand-BZOZfkUK.js} +12 -12
- package/dist/{mantraBrand-8JUlYtCE.cjs → mantraBrand-Cp8zptkj.cjs} +30 -30
- package/dist/{medterra-DH067P-V.cjs → medterra-BHYCBgvQ.cjs} +27 -27
- package/dist/{medterra-BQec8rzn.js → medterra-CShe6CLY.js} +12 -12
- package/dist/{modells-DUFnLmAz.cjs → modells-DE7-gmjK.cjs} +23 -23
- package/dist/{modells-DAgLE2xo.js → modells-DFyJxNwT.js} +12 -12
- package/dist/{org-CnHL2I9B.cjs → org-Bkn6fl6I.cjs} +22 -22
- package/dist/{org-C11APG3v.js → org-CX8HFbc9.js} +20 -20
- package/dist/{pressedFloral-DVZVfOSQ.cjs → pressedFloral-BMkCVs8c.cjs} +26 -26
- package/dist/{pressedFloral-MdbuoRyA.js → pressedFloral-aK9br-LF.js} +12 -12
- package/dist/{search-bSYdOBhY.cjs → search-DtIFZeMA.cjs} +28 -28
- package/dist/{search-CvHb1M3S.js → search-eWwg8pNn.js} +5 -5
- package/dist/{search-filter-types-BsJjrxk0.d.ts → search-filter-types-ByJnFPc4.d.cts} +8 -8
- package/dist/{search-filter-types-CqaGK3nM.d.cts → search-filter-types-DPgeG8FS.d.ts} +8 -8
- package/dist/{skinPerfection-bGiYxq1i.js → skinPerfection-B9G6yLM2.js} +12 -12
- package/dist/{skinPerfection-BcEWICQN.cjs → skinPerfection-BBC1q65Z.cjs} +17 -17
- package/dist/{snapSupplements-BXSXTjqF.cjs → snapSupplements-D7hx6Kgj.cjs} +17 -17
- package/dist/{snapSupplements-D7hHhdC9.js → snapSupplements-DKvJl__T.js} +12 -12
- package/dist/{spanx-lUzP6Lva.cjs → spanx-D-ZKkxjM.cjs} +20 -20
- package/dist/{spanx-5-0yX3iK.js → spanx-yl7YfVrf.js} +12 -12
- package/dist/{spanxStaging-hreMR0MS.cjs → spanxStaging-CXeIg6zI.cjs} +26 -26
- package/dist/{spanxStaging-HglCMJag.js → spanxStaging-DzGXL9wD.js} +12 -12
- package/dist/{supergoop-CkjtuRck.cjs → supergoop-CSpDPOpl.cjs} +18 -18
- package/dist/{supergoop-C9DDT3lY.js → supergoop-D0UkuRiA.js} +11 -11
- package/dist/types/index.d.cts +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/{types-BVsTRyxL.js → types-C3S1H4hl.js} +33 -33
- package/dist/{types-BUjohkXp.cjs → types-lcjuhDBt.cjs} +33 -33
- package/dist/{uniqueVintage-DIMGtYAU.cjs → uniqueVintage-DygVpCqU.cjs} +36 -36
- package/dist/{uniqueVintage-DPWA5Ed6.js → uniqueVintage-_n0FZFVj.js} +12 -12
- package/dist/{useMessageInterceptor-C2RZM-fo.js → useMessageInterceptor-BP6gzo8a.js} +3 -3
- package/dist/{useMessageInterceptor-B-P_rw73.cjs → useMessageInterceptor-BnUG2Pzt.cjs} +9 -9
- package/dist/{variant-XITncuI3.d.ts → variant-DH4zusMi.d.cts} +1 -1
- package/dist/{variant-BGjOVpY3.d.cts → variant-DTEqSBHd.d.ts} +3 -3
- package/dist/{venaCbd-B-znfAsl.js → venaCbd-BS0dvdBm.js} +12 -12
- package/dist/{venaCbd-BOwOtpOz.cjs → venaCbd-Pqg0bj-P.cjs} +21 -21
- package/dist/{westonJonBoucher-DCRagGu3.js → westonJonBoucher-CLw8Hy6u.js} +12 -12
- package/dist/{westonJonBoucher-CraTzRVt.cjs → westonJonBoucher-CeA0jwxe.cjs} +20 -20
- package/dist/{wineEnthusiast-Bv7umajk.js → wineEnthusiast-M9P18d1w.js} +12 -12
- package/dist/{wineEnthusiast-sVuATrq6.cjs → wineEnthusiast-gHBaQMbe.cjs} +20 -20
- package/dist/{wolfMattress-BUH-Rhov.js → wolfMattress-BQHjoQYu.js} +12 -12
- package/dist/{wolfMattress-DpVHIEnJ.cjs → wolfMattress-CdmN-Evm.cjs} +19 -19
- package/dist/{wolfTactical-Q14A1fpw.js → wolfTactical-Cc2ZLBRh.js} +12 -12
- package/dist/{wolfTactical-BcvF_sy-.cjs → wolfTactical-dObnPgAG.cjs} +20 -20
- package/package.json +1 -1
- package/src/contexts/systemSettingsContext.tsx +21 -8
- package/src/hooks/useSearch.tsx +6 -3
- package/src/types/search-filter-types.ts +7 -7
- package/dist/default-BR3225LZ.js +0 -4
- package/dist/default-DR6YjE9B.cjs +0 -4
- /package/dist/{atomStore-CeJm9Llb.cjs → atomStore-BNQyGmU_.cjs} +0 -0
- /package/dist/{atomStore-BFtpknLM.js → atomStore-TnLPtYns.js} +0 -0
- /package/dist/{enviveConfigContext-Dfr2VH6u.cjs → enviveConfigContext-Bs8kepnO.cjs} +0 -0
- /package/dist/{enviveConfigContext-CUGLpPGU.js → enviveConfigContext-CWVdVWKW.js} +0 -0
- /package/dist/{events-ClCDFK7t.js → events-DgFzlVJR.js} +0 -0
- /package/dist/{events-Da7gpmGv.cjs → events-bH-24eRW.cjs} +0 -0
- /package/dist/{logger-Dln20ans.cjs → logger-Be0NyKaY.cjs} +0 -0
- /package/dist/{logger-pdEEY8T2.js → logger-BexDfK3W.js} +0 -0
- /package/dist/{utilityTypes-C4h2wgAK.cjs → utilityTypes-DMdsI0DG.cjs} +0 -0
- /package/dist/{utilityTypes-BVikejDo.js → utilityTypes-UWdNHElu.js} +0 -0
- /package/dist/{variantInfo-CzhR5W6h.js → variantInfo-BTvC6CQh.js} +0 -0
- /package/dist/{variantInfo-CNRTY0gH.cjs → variantInfo-Cz2YXraO.cjs} +0 -0
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
const require_chunk = require('../../chunk-CUT6urMc.cjs');
|
|
2
|
-
|
|
3
|
-
require('../../
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
require('../../
|
|
7
|
-
|
|
8
|
-
const
|
|
9
|
-
require('../../
|
|
10
|
-
require('../../
|
|
11
|
-
require('../../
|
|
12
|
-
|
|
13
|
-
require('../../
|
|
14
|
-
|
|
2
|
+
require('../../events-bH-24eRW.cjs');
|
|
3
|
+
const require_hooks = require('../../hooks-DjOa7ihH.cjs');
|
|
4
|
+
const require_logger = require('../../logger-Be0NyKaY.cjs');
|
|
5
|
+
const require_chat = require('../../chat-CCQMmhc1.cjs');
|
|
6
|
+
const require_types = require('../../types-lcjuhDBt.cjs');
|
|
7
|
+
require('../../enviveConfigContext-Bs8kepnO.cjs');
|
|
8
|
+
const require_atomStore = require('../../atomStore-BNQyGmU_.cjs');
|
|
9
|
+
require('../../api-BtzLHcfU.cjs');
|
|
10
|
+
const require_customerService = require('../../customerService-zsDlp7g2.cjs');
|
|
11
|
+
require('../../utilityTypes-DMdsI0DG.cjs');
|
|
12
|
+
require('../../variantInfo-Cz2YXraO.cjs');
|
|
13
|
+
const require_org = require('../../org-Bkn6fl6I.cjs');
|
|
14
|
+
require('../../search-DtIFZeMA.cjs');
|
|
15
15
|
require('../../globalSearch-hxbXekus.cjs');
|
|
16
|
-
require('../../useMessageInterceptor-
|
|
16
|
+
require('../../useMessageInterceptor-BnUG2Pzt.cjs');
|
|
17
17
|
require('../../atomStore-B3tsg6mF.cjs');
|
|
18
|
-
const require_cdnService = require('../../cdnService-
|
|
19
|
-
let jotai = require("jotai");
|
|
20
|
-
jotai = require_chunk.__toESM(jotai);
|
|
18
|
+
const require_cdnService = require('../../cdnService-vLxePdrU.cjs');
|
|
21
19
|
let react = require("react");
|
|
22
20
|
react = require_chunk.__toESM(react);
|
|
21
|
+
let jotai = require("jotai");
|
|
22
|
+
jotai = require_chunk.__toESM(jotai);
|
|
23
23
|
let uuid = require("uuid");
|
|
24
24
|
uuid = require_chunk.__toESM(uuid);
|
|
25
25
|
|
|
@@ -76,7 +76,7 @@ function cacheable(func, expiry) {
|
|
|
76
76
|
var DomMutationListenerState = class {
|
|
77
77
|
constructor(listener) {
|
|
78
78
|
this.listener = listener;
|
|
79
|
-
this.currentState =
|
|
79
|
+
this.currentState = require_chat.DomMutationObserverContinuation.CONTINUE;
|
|
80
80
|
this.attached = false;
|
|
81
81
|
this.currentTryCount = 0;
|
|
82
82
|
}
|
|
@@ -172,7 +172,7 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
172
172
|
this.mutationsQueue = [];
|
|
173
173
|
}
|
|
174
174
|
static {
|
|
175
|
-
this.observationStrategy =
|
|
175
|
+
this.observationStrategy = require_chat.DomObservationStrategy.None;
|
|
176
176
|
}
|
|
177
177
|
static addDomMutationListener(listener) {
|
|
178
178
|
const existingListener = this.listeners.find((l) => l.getListener().getName() === listener.getName());
|
|
@@ -185,19 +185,19 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
185
185
|
this.listeners.push(listenerState);
|
|
186
186
|
}
|
|
187
187
|
static invokeListener(l) {
|
|
188
|
-
if (l.getCurrentState() ===
|
|
188
|
+
if (l.getCurrentState() === require_chat.DomMutationObserverContinuation.STOP) return;
|
|
189
189
|
const previousState = l.getCurrentState();
|
|
190
190
|
try {
|
|
191
191
|
const continuation = l.getListener().onDomChange();
|
|
192
192
|
l.setCurrentState(continuation);
|
|
193
193
|
l.incrementCurrentTryCount();
|
|
194
194
|
if (l.getListener().triesMax() > 0 && l.getCurrentTryCount() >= l.getListener().triesMax()) {
|
|
195
|
-
l.setCurrentState(
|
|
195
|
+
l.setCurrentState(require_chat.DomMutationObserverContinuation.STOP);
|
|
196
196
|
require_logger.logger_default.logDebug(`DomMutationObserver invokeListener ${l.getListener().getName()} tries exceeded! max: ${l.getListener().triesMax()} current: ${l.getCurrentTryCount()}`);
|
|
197
197
|
}
|
|
198
198
|
} catch (e) {
|
|
199
|
-
require_logger.logger_default.logError(`DomMutationObserver invokeListener ${l?.getListener()?.getName()} state:${previousState}->${
|
|
200
|
-
l.setCurrentState(
|
|
199
|
+
require_logger.logger_default.logError(`DomMutationObserver invokeListener ${l?.getListener()?.getName()} state:${previousState}->${require_chat.DomMutationObserverContinuation.STOP} error: ${e}`, e);
|
|
200
|
+
l.setCurrentState(require_chat.DomMutationObserverContinuation.STOP);
|
|
201
201
|
}
|
|
202
202
|
}
|
|
203
203
|
static observeOnDomReady(strategy) {
|
|
@@ -208,7 +208,7 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
208
208
|
else this.observe(strategy);
|
|
209
209
|
}
|
|
210
210
|
static observe(strategyRequested) {
|
|
211
|
-
if (this.observationStrategy ===
|
|
211
|
+
if (this.observationStrategy === require_chat.DomObservationStrategy.None) this.observationStrategy = strategyRequested;
|
|
212
212
|
const strategy = this.observationStrategy;
|
|
213
213
|
const listenersNotBound = this.listeners.filter((l) => !l.getIsAttached());
|
|
214
214
|
if (listenersNotBound.length === 0) {
|
|
@@ -217,7 +217,7 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
217
217
|
}
|
|
218
218
|
require_logger.logger_default.logInfo(`DomMutationObserver::observe (${this.observerVersion}) listeners to attach strategy=${strategy} (${listenersNotBound.length}/${this.listeners.length})`);
|
|
219
219
|
switch (strategy) {
|
|
220
|
-
case
|
|
220
|
+
case require_chat.DomObservationStrategy.Polling:
|
|
221
221
|
this.observeByPolling(listenersNotBound);
|
|
222
222
|
break;
|
|
223
223
|
default:
|
|
@@ -262,8 +262,8 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
262
262
|
for (let i = 0; i < listenersNotBound.length; i++) {
|
|
263
263
|
const l = listenersNotBound[i];
|
|
264
264
|
new MutationObserver(() => {
|
|
265
|
-
if (l.getCurrentState() ===
|
|
266
|
-
l.setCurrentState(
|
|
265
|
+
if (l.getCurrentState() === require_chat.DomMutationObserverContinuation.CONTINUE) {
|
|
266
|
+
l.setCurrentState(require_chat.DomMutationObserverContinuation.EXECUTING);
|
|
267
267
|
setTimeout(() => {
|
|
268
268
|
this.invokeListener(l);
|
|
269
269
|
}, this.deferredExecutionDelay);
|
|
@@ -279,8 +279,8 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
279
279
|
if (!this.mutationsQueue.length) setTimeout(() => {
|
|
280
280
|
for (let i = 0; i < listenersNotBound.length; i++) {
|
|
281
281
|
const l = listenersNotBound[i];
|
|
282
|
-
if (l.getCurrentState() ===
|
|
283
|
-
l.setCurrentState(
|
|
282
|
+
if (l.getCurrentState() === require_chat.DomMutationObserverContinuation.CONTINUE) {
|
|
283
|
+
l.setCurrentState(require_chat.DomMutationObserverContinuation.EXECUTING);
|
|
284
284
|
this.invokeListener(l);
|
|
285
285
|
}
|
|
286
286
|
}
|
|
@@ -297,8 +297,8 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
297
297
|
setTimeout(() => {
|
|
298
298
|
for (let i = 0; i < listenersNotBound.length; i++) {
|
|
299
299
|
const l = listenersNotBound[i];
|
|
300
|
-
if (l.getCurrentState() ===
|
|
301
|
-
l.setCurrentState(
|
|
300
|
+
if (l.getCurrentState() === require_chat.DomMutationObserverContinuation.CONTINUE) {
|
|
301
|
+
l.setCurrentState(require_chat.DomMutationObserverContinuation.EXECUTING);
|
|
302
302
|
this.invokeListener(l);
|
|
303
303
|
}
|
|
304
304
|
}
|
|
@@ -328,8 +328,8 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
328
328
|
this.poll(async () => {
|
|
329
329
|
for (let i = 0; i < listenersNotBound.length; i++) {
|
|
330
330
|
const l = listenersNotBound[i];
|
|
331
|
-
if (l.getCurrentState() ===
|
|
332
|
-
l.setCurrentState(
|
|
331
|
+
if (l.getCurrentState() === require_chat.DomMutationObserverContinuation.CONTINUE) {
|
|
332
|
+
l.setCurrentState(require_chat.DomMutationObserverContinuation.EXECUTING);
|
|
333
333
|
this.invokeListener(l);
|
|
334
334
|
}
|
|
335
335
|
}
|
|
@@ -340,7 +340,7 @@ var DomMutationObserver = class DomMutationObserver {
|
|
|
340
340
|
if (!listenerState) require_logger.logger_default.logDebug(`DomMutationObserver::disconnect listener not found`, void 0);
|
|
341
341
|
else {
|
|
342
342
|
require_logger.logger_default.logDebug(`DomMutationObserver::disconnect listener found`, void 0);
|
|
343
|
-
listenerState.setCurrentState(
|
|
343
|
+
listenerState.setCurrentState(require_chat.DomMutationObserverContinuation.STOP);
|
|
344
344
|
}
|
|
345
345
|
}
|
|
346
346
|
static setStartingPollingInterval(interval) {
|
|
@@ -367,7 +367,7 @@ var KustomerIntegrationService = class KustomerIntegrationService {
|
|
|
367
367
|
initOnce() {
|
|
368
368
|
if (this.initialized) return;
|
|
369
369
|
const This = this;
|
|
370
|
-
|
|
370
|
+
require_chat.LocalStorageService.attachListener({
|
|
371
371
|
storageKey: KustomerIntegrationService.KUSTOMER_LOCAL_STORAGE_KEY,
|
|
372
372
|
listener: (event) => This.onCustomerStateChange(event)
|
|
373
373
|
});
|
|
@@ -376,7 +376,7 @@ var KustomerIntegrationService = class KustomerIntegrationService {
|
|
|
376
376
|
disconnect() {
|
|
377
377
|
require_logger.logger_default.logDebug("[spiffy-ai] Disconnecting KustomerIntegrationService");
|
|
378
378
|
const This = this;
|
|
379
|
-
|
|
379
|
+
require_chat.LocalStorageService.detachListener({
|
|
380
380
|
storageKey: KustomerIntegrationService.KUSTOMER_LOCAL_STORAGE_KEY,
|
|
381
381
|
listener: (event) => This.onCustomerStateChange(event)
|
|
382
382
|
});
|
|
@@ -396,7 +396,7 @@ var KustomerIntegrationService = class KustomerIntegrationService {
|
|
|
396
396
|
require_logger.logger_default.logDebug("[spiffy-ai] Kustomer iFrame element not found");
|
|
397
397
|
return false;
|
|
398
398
|
}
|
|
399
|
-
let kustomerStateStorageItem =
|
|
399
|
+
let kustomerStateStorageItem = require_chat.LocalStorageService.getItem(KustomerIntegrationService.KUSTOMER_LOCAL_STORAGE_KEY);
|
|
400
400
|
if (kustomerStateStorageItem == null) {
|
|
401
401
|
require_logger.logger_default.logDebug("[spiffy-ai] Kustomer state not found in local storage (defaulting)");
|
|
402
402
|
kustomerStateStorageItem = JSON.stringify({ wasWidgetOpen: false });
|
|
@@ -434,9 +434,9 @@ var KustomerIntegrationService = class KustomerIntegrationService {
|
|
|
434
434
|
//#region src/application/service/windowChatToggleService.ts
|
|
435
435
|
let hasAttachedEnviveChatToggle = false;
|
|
436
436
|
const WindowChatToggleBinder = () => {
|
|
437
|
-
const triggerLocation =
|
|
438
|
-
const hook =
|
|
439
|
-
const setReply = (0, jotai.useSetAtom)(
|
|
437
|
+
const triggerLocation = require_chat.ChatElementDisplayLocation.WINDOW_API_CALL;
|
|
438
|
+
const hook = require_hooks.useChatToggle();
|
|
439
|
+
const setReply = (0, jotai.useSetAtom)(require_chat.handleReplyAtom);
|
|
440
440
|
const openChatRef = (0, react.useRef)();
|
|
441
441
|
const closeChatRef = (0, react.useRef)();
|
|
442
442
|
const toggleChatRef = (0, react.useRef)();
|
|
@@ -451,8 +451,8 @@ const WindowChatToggleBinder = () => {
|
|
|
451
451
|
const message = {
|
|
452
452
|
id: (0, uuid.v4)(),
|
|
453
453
|
createdAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
454
|
-
role:
|
|
455
|
-
type:
|
|
454
|
+
role: require_chat.MessageRole.User,
|
|
455
|
+
type: require_chat.MessageType.QueryTyped,
|
|
456
456
|
metadata: { content: prompt }
|
|
457
457
|
};
|
|
458
458
|
setReply({
|
|
@@ -469,7 +469,7 @@ const WindowChatToggleBinder = () => {
|
|
|
469
469
|
]);
|
|
470
470
|
(0, react.useEffect)(() => {
|
|
471
471
|
if (hasAttachedEnviveChatToggle) return;
|
|
472
|
-
const identifyingPrefix =
|
|
472
|
+
const identifyingPrefix = require_chat.EnvironmentService.getIdentifyingPrefix();
|
|
473
473
|
try {
|
|
474
474
|
if (!window[identifyingPrefix]) window[identifyingPrefix] = {};
|
|
475
475
|
window[identifyingPrefix].openChat = (triggerId) => openChatRef.current?.(triggerId);
|
|
@@ -500,7 +500,7 @@ var WindowFrontendConfigService = class WindowFrontendConfigService {
|
|
|
500
500
|
if (this.isInitialized) return;
|
|
501
501
|
this.isInitialized = true;
|
|
502
502
|
try {
|
|
503
|
-
const identifyingPrefix =
|
|
503
|
+
const identifyingPrefix = require_chat.EnvironmentService.getIdentifyingPrefix();
|
|
504
504
|
if (!window[identifyingPrefix]) window[identifyingPrefix] = {};
|
|
505
505
|
const apply = (overrides) => {
|
|
506
506
|
require_logger.logger_default.logDebug("[spiffy-ai] applyFrontendConfigOverrides invoked");
|
|
@@ -515,22 +515,22 @@ var WindowFrontendConfigService = class WindowFrontendConfigService {
|
|
|
515
515
|
static async applyOverridesToFrontendConfig(overrides) {
|
|
516
516
|
const atomStore = require_atomStore.getAtomStore();
|
|
517
517
|
try {
|
|
518
|
-
const frontendConfig = await atomStore.get(
|
|
518
|
+
const frontendConfig = await atomStore.get(require_chat.frontendConfigAtom);
|
|
519
519
|
const orgPageConfig = await atomStore.get(require_org.orgPageConfigAtom);
|
|
520
520
|
let currentConfig = {
|
|
521
|
-
orgUIConfig: atomStore.get(
|
|
522
|
-
colorsConfig: await atomStore.get(
|
|
521
|
+
orgUIConfig: atomStore.get(require_chat.orgUIConfigAtom),
|
|
522
|
+
colorsConfig: await atomStore.get(require_chat.colorsConfigAtom),
|
|
523
523
|
mountingConfigs: orgPageConfig.mountingConfigs,
|
|
524
524
|
widgetConfigs: orgPageConfig.widgetConfigs
|
|
525
525
|
};
|
|
526
526
|
require_logger.logger_default.logInfo("[spiffy-ai] base config", { baseConfig: currentConfig });
|
|
527
527
|
for (let i = 0; i < overrides.length; i += 1) {
|
|
528
528
|
const currentOverride = overrides[i];
|
|
529
|
-
currentConfig =
|
|
529
|
+
currentConfig = require_chat.applyOverrides(currentConfig, currentOverride, { arrayStrategy: "mergeByIndex" });
|
|
530
530
|
}
|
|
531
|
-
atomStore.set(
|
|
532
|
-
atomStore.set(
|
|
533
|
-
atomStore.set(
|
|
531
|
+
atomStore.set(require_chat.orgUIConfigAtom, currentConfig.orgUIConfig);
|
|
532
|
+
atomStore.set(require_chat.colorsConfigAtom, currentConfig.colorsConfig);
|
|
533
|
+
atomStore.set(require_chat.frontendConfigAtom, {
|
|
534
534
|
...frontendConfig,
|
|
535
535
|
mountingConfigs: currentConfig.mountingConfigs,
|
|
536
536
|
widgetConfigs: currentConfig.widgetConfigs
|
|
@@ -551,7 +551,7 @@ var DataLayerEventsListener = class {
|
|
|
551
551
|
require_logger.logger_default.logDebug("[spiffy-ai] DataLayerEventsListener created", void 0);
|
|
552
552
|
this.onDataLayerPush = onDataLayerPush;
|
|
553
553
|
this.eventsToIntercept = eventsToIntercept;
|
|
554
|
-
this.windowDataLayerService =
|
|
554
|
+
this.windowDataLayerService = require_chat.WindowDataLayerService.getSingletonInstanceOf(gaConfig);
|
|
555
555
|
}
|
|
556
556
|
runOnceImmediately() {
|
|
557
557
|
return true;
|
|
@@ -560,12 +560,12 @@ var DataLayerEventsListener = class {
|
|
|
560
560
|
return 10;
|
|
561
561
|
}
|
|
562
562
|
onDomChange() {
|
|
563
|
-
if (!
|
|
563
|
+
if (!require_chat.WindowDataLayerService.isDataLayerAvailable()) return require_chat.DomMutationObserverContinuation.CONTINUE;
|
|
564
564
|
require_logger.logger_default.logDebug(`[spiffy-ai] ${this.getName()} [subscribing] to DataLayer push events`);
|
|
565
565
|
const This = this;
|
|
566
566
|
function dataLayerPushProxyMethod() {
|
|
567
567
|
try {
|
|
568
|
-
const allArguments =
|
|
568
|
+
const allArguments = require_chat.WindowDataLayerService.tryFlattenArguments(arguments);
|
|
569
569
|
let event = allArguments[0];
|
|
570
570
|
if (!event) {
|
|
571
571
|
require_logger.logger_default.logDebug(`[spiffy-ai] ${This.getName()} dataLayer event undefined. all_arguments=`, allArguments);
|
|
@@ -573,7 +573,7 @@ var DataLayerEventsListener = class {
|
|
|
573
573
|
}
|
|
574
574
|
if (event?.length > 1) {
|
|
575
575
|
if (event[0] === "event") {
|
|
576
|
-
const eventName$1 =
|
|
576
|
+
const eventName$1 = require_chat.StringUtils.trimToNull(event[1]) || "";
|
|
577
577
|
if (This.eventsToIntercept.includes(eventName$1)) {
|
|
578
578
|
require_logger.logger_default.logDebug(`[spiffy-ai] ${This.getName()} [datalayer-event] (1) event_name=${eventName$1} events_to_intercept=${This.eventsToIntercept} all_arguments=`, allArguments);
|
|
579
579
|
event[2]["event"] = eventName$1;
|
|
@@ -582,9 +582,9 @@ var DataLayerEventsListener = class {
|
|
|
582
582
|
}
|
|
583
583
|
}
|
|
584
584
|
}
|
|
585
|
-
let eventName =
|
|
585
|
+
let eventName = require_chat.StringUtils.trimToNull(event["event"]) || "";
|
|
586
586
|
if (!eventName && event["0"]) {
|
|
587
|
-
eventName =
|
|
587
|
+
eventName = require_chat.StringUtils.trimToNull(event["0"]["event"]) || "";
|
|
588
588
|
event = event["0"];
|
|
589
589
|
}
|
|
590
590
|
if (This.eventsToIntercept.includes(eventName)) {
|
|
@@ -596,7 +596,7 @@ var DataLayerEventsListener = class {
|
|
|
596
596
|
}
|
|
597
597
|
}
|
|
598
598
|
this.windowDataLayerService.wrapWithProxyMethod("push", dataLayerPushProxyMethod);
|
|
599
|
-
return
|
|
599
|
+
return require_chat.DomMutationObserverContinuation.STOP;
|
|
600
600
|
}
|
|
601
601
|
getName() {
|
|
602
602
|
return "DataLayerEventsListener";
|
|
@@ -615,7 +615,7 @@ var EmbeddedChatsPlacementsListener = class {
|
|
|
615
615
|
}
|
|
616
616
|
onDomChange() {
|
|
617
617
|
const continuation = this.findPlacementNodes();
|
|
618
|
-
if (continuation ===
|
|
618
|
+
if (continuation === require_chat.DomMutationObserverContinuation.STOP) require_logger.logger_default.logDebug("[spiffy-ai] EmbeddedChatsPlacementsListener [STOP requested]", void 0);
|
|
619
619
|
return continuation;
|
|
620
620
|
}
|
|
621
621
|
getName() {
|
|
@@ -649,9 +649,9 @@ var GladlyListener = class GladlyListener {
|
|
|
649
649
|
if (window.Gladly && window.Gladly.getUser != null && window.Gladly.on != null && window.Gladly.show != null) {
|
|
650
650
|
require_logger.logger_default.logDebug(`[spiffy-ai] subscribing to Gladly ${GladlyListener.GLADLY_CONVERSATION_STARTED_EVENT_NAME} event`);
|
|
651
651
|
window.Gladly.on(GladlyListener.GLADLY_CONVERSATION_STARTED_EVENT_NAME, this.onGladlyAvailable);
|
|
652
|
-
return
|
|
652
|
+
return require_chat.DomMutationObserverContinuation.STOP;
|
|
653
653
|
}
|
|
654
|
-
return
|
|
654
|
+
return require_chat.DomMutationObserverContinuation.CONTINUE;
|
|
655
655
|
}
|
|
656
656
|
getName() {
|
|
657
657
|
return "GladlyListener";
|
|
@@ -676,8 +676,8 @@ var KustomerVisibilityListener = class {
|
|
|
676
676
|
}
|
|
677
677
|
onDomChange() {
|
|
678
678
|
this.kustomerIntegrationService.initOnce();
|
|
679
|
-
if (this.kustomerIntegrationService.updateVisibility()) return
|
|
680
|
-
return
|
|
679
|
+
if (this.kustomerIntegrationService.updateVisibility()) return require_chat.DomMutationObserverContinuation.STOP;
|
|
680
|
+
return require_chat.DomMutationObserverContinuation.CONTINUE;
|
|
681
681
|
}
|
|
682
682
|
getName() {
|
|
683
683
|
return "KustomerVisibilityListener";
|
|
@@ -703,7 +703,7 @@ var OrgsCommonDataLayerListener = class OrgsCommonDataLayerListener {
|
|
|
703
703
|
if (OrgsCommonDataLayerListener.dataLayerCache[orgShortName]) return { dataLayerListener: OrgsCommonDataLayerListener.dataLayerCache[orgShortName] };
|
|
704
704
|
const callback = (event) => {
|
|
705
705
|
require_logger.logger_default.logDebug(`[spiffy-ai] dataLayer event:`, event);
|
|
706
|
-
if (event?.event !==
|
|
706
|
+
if (event?.event !== require_chat.GoogleAnalyticsEvents.ADD_TO_CART_v1 && event?.event !== require_chat.GoogleAnalyticsEvents.ADD_TO_CART_v2) {
|
|
707
707
|
require_logger.logger_default.logDebug(`[spiffy-ai] dataLayer [pass-through] event. event_not_captured=`, event);
|
|
708
708
|
return;
|
|
709
709
|
}
|
|
@@ -713,15 +713,15 @@ var OrgsCommonDataLayerListener = class OrgsCommonDataLayerListener {
|
|
|
713
713
|
const eventProps = {
|
|
714
714
|
"ecommerce.item_id_list": itemIdList,
|
|
715
715
|
"ecommerce.item_category_list": itemCategoryList,
|
|
716
|
-
display_location:
|
|
716
|
+
display_location: require_chat.ChatElementDisplayLocation.UNSPECIFIED
|
|
717
717
|
};
|
|
718
|
-
|
|
719
|
-
eventName:
|
|
718
|
+
require_chat.AmplitudeAdapter.trackEvent({
|
|
719
|
+
eventName: require_chat.SpiffyMetricsEventName.AddToCartClicked,
|
|
720
720
|
eventProps,
|
|
721
721
|
alsoSendToGoogleAnalytics: true
|
|
722
722
|
});
|
|
723
723
|
};
|
|
724
|
-
const dataLayerListener = new DataLayerEventsListener(callback, [
|
|
724
|
+
const dataLayerListener = new DataLayerEventsListener(callback, [require_chat.GoogleAnalyticsEvents.ADD_TO_CART_v1, require_chat.GoogleAnalyticsEvents.ADD_TO_CART_v2], orgAnalyticsConfig.googleAnalytics);
|
|
725
725
|
OrgsCommonDataLayerListener.dataLayerCache[orgShortName] = dataLayerListener;
|
|
726
726
|
return { dataLayerListener };
|
|
727
727
|
}
|
|
@@ -731,30 +731,30 @@ var OrgsCommonDataLayerListener = class OrgsCommonDataLayerListener {
|
|
|
731
731
|
exports.CdnService = require_cdnService.CdnService;
|
|
732
732
|
exports.CustomerServiceIntegrationMode = require_types.CustomerServiceIntegrationMode;
|
|
733
733
|
exports.CustomerServiceType = require_types.CustomerServiceType;
|
|
734
|
-
exports.DOMInsertionService =
|
|
735
|
-
exports.DOMInsertionType =
|
|
736
|
-
exports.DOMInsertionTypeToInsertPosition =
|
|
734
|
+
exports.DOMInsertionService = require_chat.DOMInsertionService;
|
|
735
|
+
exports.DOMInsertionType = require_chat.DOMInsertionType;
|
|
736
|
+
exports.DOMInsertionTypeToInsertPosition = require_chat.DOMInsertionTypeToInsertPosition;
|
|
737
737
|
exports.DataLayerEventsListener = DataLayerEventsListener;
|
|
738
738
|
exports.DomMutationListenerState = DomMutationListenerState;
|
|
739
739
|
exports.DomMutationObserver = DomMutationObserver;
|
|
740
740
|
exports.EmbeddedChatsPlacementsListener = EmbeddedChatsPlacementsListener;
|
|
741
|
-
exports.EnvironmentService =
|
|
742
|
-
exports.FeatureFlagService =
|
|
741
|
+
exports.EnvironmentService = require_chat.EnvironmentService;
|
|
742
|
+
exports.FeatureFlagService = require_chat.FeatureFlagService;
|
|
743
743
|
exports.GladlyListener = GladlyListener;
|
|
744
|
-
exports.GridInsertionService =
|
|
745
|
-
exports.GridInsertionType =
|
|
744
|
+
exports.GridInsertionService = require_chat.GridInsertionService;
|
|
745
|
+
exports.GridInsertionType = require_chat.GridInsertionType;
|
|
746
746
|
exports.KustomerIntegrationService = KustomerIntegrationService;
|
|
747
747
|
exports.KustomerVisibilityListener = KustomerVisibilityListener;
|
|
748
|
-
exports.LocalStorageKeys =
|
|
749
|
-
exports.LocalStorageService =
|
|
748
|
+
exports.LocalStorageKeys = require_chat.LocalStorageKeys;
|
|
749
|
+
exports.LocalStorageService = require_chat.LocalStorageService;
|
|
750
750
|
exports.OrgsCommonDataLayerListener = OrgsCommonDataLayerListener;
|
|
751
|
-
exports.PageVariantService =
|
|
752
|
-
exports.SessionStorageService =
|
|
753
|
-
exports.ShopifyUrlService =
|
|
751
|
+
exports.PageVariantService = require_hooks.PageVariantService;
|
|
752
|
+
exports.SessionStorageService = require_chat.SessionStorageService;
|
|
753
|
+
exports.ShopifyUrlService = require_hooks.ShopifyUrlService;
|
|
754
754
|
exports.UnsupportedCustomerService = require_customerService.UnsupportedCustomerService;
|
|
755
|
-
exports.UserIdentityService =
|
|
755
|
+
exports.UserIdentityService = require_chat.UserIdentityService;
|
|
756
756
|
exports.WindowChatToggleBinder = WindowChatToggleBinder;
|
|
757
|
-
exports.WindowDataLayerService =
|
|
757
|
+
exports.WindowDataLayerService = require_chat.WindowDataLayerService;
|
|
758
758
|
exports.cacheable = cacheable;
|
|
759
759
|
exports.cacheableAsync = cacheableAsync;
|
|
760
760
|
exports.findCustomerServiceImpl = require_customerService.findCustomerServiceImpl;
|
|
@@ -9,7 +9,7 @@ import { CustomerServiceIntegration, CustomerServiceIntegrationMode, CustomerSer
|
|
|
9
9
|
import "../../test-types-CpKCxk8U.cjs";
|
|
10
10
|
import { VariantInfo } from "../../index-hdbCEjYy.cjs";
|
|
11
11
|
import { findCustomerServiceImpl } from "../../index-CVxe7FpL.cjs";
|
|
12
|
-
import { SupportedEvent } from "../../variant-
|
|
12
|
+
import { SupportedEvent } from "../../variant-DH4zusMi.cjs";
|
|
13
13
|
import { ContextSourceEnum, PageVisitCategory } from "@spiffy-ai/commerce-api-client";
|
|
14
14
|
|
|
15
15
|
//#region src/application/service/cachingService.d.ts
|
|
@@ -9,7 +9,7 @@ import { CustomerServiceIntegration, CustomerServiceIntegrationMode, CustomerSer
|
|
|
9
9
|
import "../../test-types-C9b_OdfO.js";
|
|
10
10
|
import { VariantInfo } from "../../index-Cqg6ltII.js";
|
|
11
11
|
import { findCustomerServiceImpl } from "../../index-CGB6CAmr.js";
|
|
12
|
-
import { SupportedEvent } from "../../variant-
|
|
12
|
+
import { SupportedEvent } from "../../variant-DTEqSBHd.js";
|
|
13
13
|
import { ContextSourceEnum, PageVisitCategory } from "@spiffy-ai/commerce-api-client";
|
|
14
14
|
|
|
15
15
|
//#region src/application/service/cachingService.d.ts
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "../../
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import "../../
|
|
6
|
-
import
|
|
7
|
-
import {
|
|
8
|
-
import "../../
|
|
9
|
-
import "../../
|
|
10
|
-
import "../../
|
|
11
|
-
import
|
|
12
|
-
import "../../
|
|
13
|
-
import
|
|
1
|
+
import "../../events-DgFzlVJR.js";
|
|
2
|
+
import { PageVariantService, ShopifyUrlService, useChatToggle } from "../../hooks-fneW8SWw.js";
|
|
3
|
+
import { logger_default } from "../../logger-BexDfK3W.js";
|
|
4
|
+
import { AmplitudeAdapter, ChatElementDisplayLocation, DOMInsertionService, DOMInsertionType, DOMInsertionTypeToInsertPosition, DomMutationObserverContinuation, DomObservationStrategy, EnvironmentService, FeatureFlagService, GoogleAnalyticsEvents, GridInsertionService, GridInsertionType, LocalStorageKeys, LocalStorageService, MessageRole, MessageType, SessionStorageService, SpiffyMetricsEventName, StringUtils, UserIdentityService, WindowDataLayerService, applyOverrides, colorsConfigAtom, frontendConfigAtom, handleReplyAtom, orgUIConfigAtom } from "../../chat-H6YcCS4I.js";
|
|
5
|
+
import { CustomerServiceIntegrationMode, CustomerServiceType } from "../../types-C3S1H4hl.js";
|
|
6
|
+
import "../../enviveConfigContext-CWVdVWKW.js";
|
|
7
|
+
import { getAtomStore } from "../../atomStore-TnLPtYns.js";
|
|
8
|
+
import "../../api-kpPTZhV9.js";
|
|
9
|
+
import { UnsupportedCustomerService, findCustomerServiceImpl } from "../../customerService-C4wc0glQ.js";
|
|
10
|
+
import "../../utilityTypes-UWdNHElu.js";
|
|
11
|
+
import "../../variantInfo-BTvC6CQh.js";
|
|
12
|
+
import { orgPageConfigAtom } from "../../org-CX8HFbc9.js";
|
|
13
|
+
import "../../search-eWwg8pNn.js";
|
|
14
14
|
import "../../globalSearch-BC0rOX3E.js";
|
|
15
|
-
import "../../useMessageInterceptor-
|
|
15
|
+
import "../../useMessageInterceptor-BP6gzo8a.js";
|
|
16
16
|
import "../../atomStore-FSZd_20F.js";
|
|
17
|
-
import { CdnService } from "../../cdnService-
|
|
18
|
-
import { useSetAtom } from "jotai";
|
|
17
|
+
import { CdnService } from "../../cdnService-BNreZjqy.js";
|
|
19
18
|
import { useEffect, useRef } from "react";
|
|
19
|
+
import { useSetAtom } from "jotai";
|
|
20
20
|
import { v4 } from "uuid";
|
|
21
21
|
|
|
22
22
|
//#region src/application/service/cachingService.ts
|
|
@@ -1,38 +1,38 @@
|
|
|
1
|
-
require('../../
|
|
2
|
-
require('../../
|
|
3
|
-
const
|
|
4
|
-
require('../../types-
|
|
5
|
-
require('../../enviveConfigContext-
|
|
6
|
-
require('../../atomStore-
|
|
7
|
-
require('../../
|
|
8
|
-
require('../../
|
|
9
|
-
require('../../
|
|
10
|
-
require('../../
|
|
1
|
+
require('../../events-bH-24eRW.cjs');
|
|
2
|
+
require('../../logger-Be0NyKaY.cjs');
|
|
3
|
+
const require_chat = require('../../chat-CCQMmhc1.cjs');
|
|
4
|
+
require('../../types-lcjuhDBt.cjs');
|
|
5
|
+
require('../../enviveConfigContext-Bs8kepnO.cjs');
|
|
6
|
+
require('../../atomStore-BNQyGmU_.cjs');
|
|
7
|
+
require('../../api-BtzLHcfU.cjs');
|
|
8
|
+
require('../../customerService-zsDlp7g2.cjs');
|
|
9
|
+
require('../../utilityTypes-DMdsI0DG.cjs');
|
|
10
|
+
require('../../variantInfo-Cz2YXraO.cjs');
|
|
11
11
|
|
|
12
|
-
exports.DOMObserver =
|
|
13
|
-
exports.ElementObserver =
|
|
14
|
-
exports.MutationHelper =
|
|
15
|
-
exports.NodeSelector =
|
|
16
|
-
exports.SelectorFactory =
|
|
17
|
-
exports.StringUtils =
|
|
18
|
-
exports.applyOverrides =
|
|
19
|
-
exports.buildSearchHash =
|
|
20
|
-
exports.buildSearchStartHash =
|
|
21
|
-
exports.coreContextToApiContext =
|
|
22
|
-
exports.coreSupportedEventRequestToApiRequest =
|
|
23
|
-
exports.coreUserEventToApiUserEvent =
|
|
24
|
-
exports.createUrlWithQueryParams =
|
|
25
|
-
exports.divideArray =
|
|
26
|
-
exports.getQueryParam =
|
|
27
|
-
exports.getRecentProductImageUrls =
|
|
28
|
-
exports.initAmplitude =
|
|
29
|
-
exports.initDataLayerWrapper =
|
|
30
|
-
exports.messageFromFormSubmittedEvent =
|
|
31
|
-
exports.messageFromQueryEvent =
|
|
32
|
-
exports.messageFromResponse =
|
|
33
|
-
exports.messageFromSuggestionEvent =
|
|
34
|
-
exports.messageRequestToCommerceMessageRequest =
|
|
35
|
-
exports.parseHref =
|
|
36
|
-
exports.parseSearchHash =
|
|
37
|
-
exports.prepareMerchantPage =
|
|
38
|
-
exports.validateEmail =
|
|
12
|
+
exports.DOMObserver = require_chat.DOMObserver;
|
|
13
|
+
exports.ElementObserver = require_chat.ElementObserver;
|
|
14
|
+
exports.MutationHelper = require_chat.MutationHelper;
|
|
15
|
+
exports.NodeSelector = require_chat.NodeSelector;
|
|
16
|
+
exports.SelectorFactory = require_chat.SelectorFactory;
|
|
17
|
+
exports.StringUtils = require_chat.StringUtils;
|
|
18
|
+
exports.applyOverrides = require_chat.applyOverrides;
|
|
19
|
+
exports.buildSearchHash = require_chat.buildSearchHash;
|
|
20
|
+
exports.buildSearchStartHash = require_chat.buildSearchStartHash;
|
|
21
|
+
exports.coreContextToApiContext = require_chat.coreContextToApiContext;
|
|
22
|
+
exports.coreSupportedEventRequestToApiRequest = require_chat.coreSupportedEventRequestToApiRequest;
|
|
23
|
+
exports.coreUserEventToApiUserEvent = require_chat.coreUserEventToApiUserEvent;
|
|
24
|
+
exports.createUrlWithQueryParams = require_chat.createUrlWithQueryParams;
|
|
25
|
+
exports.divideArray = require_chat.divideArray;
|
|
26
|
+
exports.getQueryParam = require_chat.getQueryParam;
|
|
27
|
+
exports.getRecentProductImageUrls = require_chat.getRecentProductImageUrls;
|
|
28
|
+
exports.initAmplitude = require_chat.initAmplitude;
|
|
29
|
+
exports.initDataLayerWrapper = require_chat.initDataLayerWrapper;
|
|
30
|
+
exports.messageFromFormSubmittedEvent = require_chat.messageFromFormSubmittedEvent;
|
|
31
|
+
exports.messageFromQueryEvent = require_chat.messageFromQueryEvent;
|
|
32
|
+
exports.messageFromResponse = require_chat.messageFromResponse;
|
|
33
|
+
exports.messageFromSuggestionEvent = require_chat.messageFromSuggestionEvent;
|
|
34
|
+
exports.messageRequestToCommerceMessageRequest = require_chat.messageRequestToCommerceMessageRequest;
|
|
35
|
+
exports.parseHref = require_chat.parseHref;
|
|
36
|
+
exports.parseSearchHash = require_chat.parseSearchHash;
|
|
37
|
+
exports.prepareMerchantPage = require_chat.prepareMerchantPage;
|
|
38
|
+
exports.validateEmail = require_chat.validateEmail;
|
|
@@ -8,9 +8,9 @@ import "../../types-TD8g7LnH.js";
|
|
|
8
8
|
import "../../test-types-C9b_OdfO.js";
|
|
9
9
|
import "../../index-Cqg6ltII.js";
|
|
10
10
|
import { MouseEventTypes, NodeSelector, SelectorFactory } from "../../nodeSelector-DpKXszfU.js";
|
|
11
|
-
import { Context, NextMessageRequest, SupportedEventRequest, UserEvent } from "@spiffy-ai/commerce-api-client";
|
|
12
11
|
import * as react0 from "react";
|
|
13
12
|
import { ReactElement } from "react";
|
|
13
|
+
import { Context, NextMessageRequest, SupportedEventRequest, UserEvent } from "@spiffy-ai/commerce-api-client";
|
|
14
14
|
|
|
15
15
|
//#region src/application/utils/analyticsUtils.d.ts
|
|
16
16
|
/**
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import "../../
|
|
2
|
-
import "../../
|
|
3
|
-
import { DOMObserver, ElementObserver, MutationHelper, NodeSelector, SelectorFactory, StringUtils, applyOverrides, buildSearchHash, buildSearchStartHash, coreContextToApiContext, coreSupportedEventRequestToApiRequest, coreUserEventToApiUserEvent, createUrlWithQueryParams, divideArray, getQueryParam, getRecentProductImageUrls, initAmplitude, initDataLayerWrapper, messageFromFormSubmittedEvent, messageFromQueryEvent, messageFromResponse, messageFromSuggestionEvent, messageRequestToCommerceMessageRequest, parseHref, parseSearchHash, prepareMerchantPage, validateEmail } from "../../
|
|
4
|
-
import "../../types-
|
|
5
|
-
import "../../enviveConfigContext-
|
|
6
|
-
import "../../atomStore-
|
|
7
|
-
import "../../
|
|
8
|
-
import "../../
|
|
9
|
-
import "../../
|
|
10
|
-
import "../../
|
|
1
|
+
import "../../events-DgFzlVJR.js";
|
|
2
|
+
import "../../logger-BexDfK3W.js";
|
|
3
|
+
import { DOMObserver, ElementObserver, MutationHelper, NodeSelector, SelectorFactory, StringUtils, applyOverrides, buildSearchHash, buildSearchStartHash, coreContextToApiContext, coreSupportedEventRequestToApiRequest, coreUserEventToApiUserEvent, createUrlWithQueryParams, divideArray, getQueryParam, getRecentProductImageUrls, initAmplitude, initDataLayerWrapper, messageFromFormSubmittedEvent, messageFromQueryEvent, messageFromResponse, messageFromSuggestionEvent, messageRequestToCommerceMessageRequest, parseHref, parseSearchHash, prepareMerchantPage, validateEmail } from "../../chat-H6YcCS4I.js";
|
|
4
|
+
import "../../types-C3S1H4hl.js";
|
|
5
|
+
import "../../enviveConfigContext-CWVdVWKW.js";
|
|
6
|
+
import "../../atomStore-TnLPtYns.js";
|
|
7
|
+
import "../../api-kpPTZhV9.js";
|
|
8
|
+
import "../../customerService-C4wc0glQ.js";
|
|
9
|
+
import "../../utilityTypes-UWdNHElu.js";
|
|
10
|
+
import "../../variantInfo-BTvC6CQh.js";
|
|
11
11
|
|
|
12
12
|
export { DOMObserver, ElementObserver, MutationHelper, NodeSelector, SelectorFactory, StringUtils, applyOverrides, buildSearchHash, buildSearchStartHash, coreContextToApiContext, coreSupportedEventRequestToApiRequest, coreUserEventToApiUserEvent, createUrlWithQueryParams, divideArray, getQueryParam, getRecentProductImageUrls, initAmplitude, initDataLayerWrapper, messageFromFormSubmittedEvent, messageFromQueryEvent, messageFromResponse, messageFromSuggestionEvent, messageRequestToCommerceMessageRequest, parseHref, parseSearchHash, prepareMerchantPage, validateEmail };
|
package/dist/atoms/app/index.cjs
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
require('../../
|
|
2
|
-
require('../../
|
|
3
|
-
const
|
|
4
|
-
require('../../types-
|
|
5
|
-
require('../../enviveConfigContext-
|
|
6
|
-
require('../../atomStore-
|
|
7
|
-
require('../../
|
|
8
|
-
require('../../
|
|
9
|
-
require('../../
|
|
10
|
-
require('../../
|
|
1
|
+
require('../../events-bH-24eRW.cjs');
|
|
2
|
+
require('../../logger-Be0NyKaY.cjs');
|
|
3
|
+
const require_chat = require('../../chat-CCQMmhc1.cjs');
|
|
4
|
+
require('../../types-lcjuhDBt.cjs');
|
|
5
|
+
require('../../enviveConfigContext-Bs8kepnO.cjs');
|
|
6
|
+
require('../../atomStore-BNQyGmU_.cjs');
|
|
7
|
+
require('../../api-BtzLHcfU.cjs');
|
|
8
|
+
require('../../customerService-zsDlp7g2.cjs');
|
|
9
|
+
require('../../utilityTypes-DMdsI0DG.cjs');
|
|
10
|
+
require('../../variantInfo-Cz2YXraO.cjs');
|
|
11
11
|
|
|
12
|
-
exports.appDetailsAtom =
|
|
13
|
-
exports.appSourceAtom =
|
|
14
|
-
exports.chatIdAtom =
|
|
15
|
-
exports.envAtom =
|
|
16
|
-
exports.userIdAtom =
|
|
17
|
-
exports.variantInfoAtom =
|
|
12
|
+
exports.appDetailsAtom = require_chat.appDetailsAtom;
|
|
13
|
+
exports.appSourceAtom = require_chat.appSourceAtom;
|
|
14
|
+
exports.chatIdAtom = require_chat.chatIdAtom;
|
|
15
|
+
exports.envAtom = require_chat.envAtom;
|
|
16
|
+
exports.userIdAtom = require_chat.userIdAtom;
|
|
17
|
+
exports.variantInfoAtom = require_chat.variantInfoAtom;
|
|
@@ -7,7 +7,7 @@ import "../../frontendConfig-KeNqU1wa.cjs";
|
|
|
7
7
|
import "../../types-BE4faOO_.cjs";
|
|
8
8
|
import "../../test-types-CpKCxk8U.cjs";
|
|
9
9
|
import { VariantInfo } from "../../index-hdbCEjYy.cjs";
|
|
10
|
-
import { variantInfoAtom } from "../../variant-
|
|
10
|
+
import { variantInfoAtom } from "../../variant-DH4zusMi.cjs";
|
|
11
11
|
import { ContextEnvEnum, ContextSourceEnum } from "@spiffy-ai/commerce-api-client";
|
|
12
12
|
import * as jotai0 from "jotai";
|
|
13
13
|
import * as jotai_utils0 from "jotai/utils";
|