@guidelytech/sdk-core 0.11.0 → 0.13.0

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.cts CHANGED
@@ -6,14 +6,14 @@ export { Attributes, EvaluationResult, FlagDetails, FlagsBootstrap, FlagsClient,
6
6
  import { MessengerTab } from '@guidelytech/guide-runtime/messenger';
7
7
  import { AgentTurnInput } from '@guidelytech/shared/runtime';
8
8
  export { CAPTURE_PARAM } from '@guidelytech/shared/runtime';
9
- import { m as GuidelyOptions, c as GuidelyAccount, a as ConsentState, C as ChecklistProgressState, n as GuidelyEvents, e as GuidelyUser, G as GuideLocalState, S as SessionState } from './types-Mtlmlj5C.cjs';
10
- export { A as AgentTurnRedactor, E as EventQueue, b as EventQueueOptions, o as GuideStepInfo, d as GuidelyEnvironment, q as GuidelyEventName, P as PersistedState, f as areMutuallyExclusive, g as countsTowardThrottle, i as isExclusiveGuide, j as isFrequencyEligible, k as isThrottleEligible, l as isWithinSchedule, p as pruneLaunches } from './types-Mtlmlj5C.cjs';
11
- export { a as KEYS, K as KeyValueStore, c as StorageKind, d as createStorage } from './health-sbP9JwTE.cjs';
12
- export { C as CaptureMarker, a as CaptureOutgoingMessage } from './capture-CgN69Lxq.cjs';
13
- import './http-Cb6KYYFv.cjs';
9
+ import { m as GuidelyOptions, c as GuidelyAccount, a as ConsentState, C as ChecklistProgressState, n as GuidelyEvents, e as GuidelyUser, G as GuideLocalState, S as SessionState } from './types-Bkw8ErmO.cjs';
10
+ export { A as AgentTurnRedactor, E as EventQueue, b as EventQueueOptions, o as GuideStepInfo, d as GuidelyEnvironment, q as GuidelyEventName, P as PersistedState, f as areMutuallyExclusive, g as countsTowardThrottle, i as isExclusiveGuide, j as isFrequencyEligible, k as isThrottleEligible, l as isWithinSchedule, p as pruneLaunches } from './types-Bkw8ErmO.cjs';
11
+ export { a as KEYS, K as KeyValueStore, c as StorageKind, d as createStorage } from './health-DjZ2gwYa.cjs';
12
+ export { C as CaptureMarker, a as CaptureOutgoingMessage } from './capture-4EgpjK6Z.cjs';
13
+ import './http-zOI8d2c2.cjs';
14
14
 
15
15
  declare const SDK_NAME = "@guidelytech/sdk-core";
16
- declare const SDK_VERSION = "0.11.0";
16
+ declare const SDK_VERSION = "0.13.0";
17
17
  declare const DEFAULT_API_URL = "https://api.guidely.app";
18
18
  /**
19
19
  * Framework-independent Guidely client. Create one per page with {@link createGuidely} or
package/dist/index.d.ts CHANGED
@@ -6,14 +6,14 @@ export { Attributes, EvaluationResult, FlagDetails, FlagsBootstrap, FlagsClient,
6
6
  import { MessengerTab } from '@guidelytech/guide-runtime/messenger';
7
7
  import { AgentTurnInput } from '@guidelytech/shared/runtime';
8
8
  export { CAPTURE_PARAM } from '@guidelytech/shared/runtime';
9
- import { m as GuidelyOptions, c as GuidelyAccount, a as ConsentState, C as ChecklistProgressState, n as GuidelyEvents, e as GuidelyUser, G as GuideLocalState, S as SessionState } from './types-BDlebXrm.js';
10
- export { A as AgentTurnRedactor, E as EventQueue, b as EventQueueOptions, o as GuideStepInfo, d as GuidelyEnvironment, q as GuidelyEventName, P as PersistedState, f as areMutuallyExclusive, g as countsTowardThrottle, i as isExclusiveGuide, j as isFrequencyEligible, k as isThrottleEligible, l as isWithinSchedule, p as pruneLaunches } from './types-BDlebXrm.js';
11
- export { a as KEYS, K as KeyValueStore, c as StorageKind, d as createStorage } from './health-sbP9JwTE.js';
12
- export { C as CaptureMarker, a as CaptureOutgoingMessage } from './capture-Csz721-A.js';
13
- import './http-D047Ngxk.js';
9
+ import { m as GuidelyOptions, c as GuidelyAccount, a as ConsentState, C as ChecklistProgressState, n as GuidelyEvents, e as GuidelyUser, G as GuideLocalState, S as SessionState } from './types-Dy_uPu6S.js';
10
+ export { A as AgentTurnRedactor, E as EventQueue, b as EventQueueOptions, o as GuideStepInfo, d as GuidelyEnvironment, q as GuidelyEventName, P as PersistedState, f as areMutuallyExclusive, g as countsTowardThrottle, i as isExclusiveGuide, j as isFrequencyEligible, k as isThrottleEligible, l as isWithinSchedule, p as pruneLaunches } from './types-Dy_uPu6S.js';
11
+ export { a as KEYS, K as KeyValueStore, c as StorageKind, d as createStorage } from './health-DjZ2gwYa.js';
12
+ export { C as CaptureMarker, a as CaptureOutgoingMessage } from './capture-C-4R56G0.js';
13
+ import './http-BXys2d-j.js';
14
14
 
15
15
  declare const SDK_NAME = "@guidelytech/sdk-core";
16
- declare const SDK_VERSION = "0.11.0";
16
+ declare const SDK_VERSION = "0.13.0";
17
17
  declare const DEFAULT_API_URL = "https://api.guidely.app";
18
18
  /**
19
19
  * Framework-independent Guidely client. Create one per page with {@link createGuidely} or
package/dist/index.js CHANGED
@@ -10,7 +10,7 @@ import {
10
10
  isThrottleEligible,
11
11
  isWithinSchedule,
12
12
  pruneLaunches
13
- } from "./chunk-ZAF2KRJA.js";
13
+ } from "./chunk-2E2YUQAG.js";
14
14
  import {
15
15
  Api,
16
16
  KEYS,
@@ -19,7 +19,7 @@ import {
19
19
  postWithRetry,
20
20
  readJson,
21
21
  writeJson
22
- } from "./chunk-JUSM7J5N.js";
22
+ } from "./chunk-XML74K2P.js";
23
23
 
24
24
  // src/client.ts
25
25
  import { evaluateRules, localizeGuide, localizeResourceCenter, normalizeLocale, randomId as randomId2, rolloutBucket, sanitizeProperties, supportsPlatform, visibleAnnouncements, visitorLocales } from "@guidelytech/shared/runtime";
@@ -1415,7 +1415,7 @@ var loadRecorder = async () => (await import("./recorder.js")).recorder;
1415
1415
 
1416
1416
  // src/client.ts
1417
1417
  var SDK_NAME = "@guidelytech/sdk-core";
1418
- var SDK_VERSION = "0.11.0";
1418
+ var SDK_VERSION = "0.13.0";
1419
1419
  var DEFAULT_API_URL = "https://api.guidely.app";
1420
1420
  var PAGE_SCOPED = /* @__PURE__ */ new Set(["page_load", "url_match", "element_click", "element_visible", "delay"]);
1421
1421
  var DAY_MS = 24 * 60 * 60 * 1e3;
@@ -2803,7 +2803,7 @@ var GuidelyClient = class _GuidelyClient {
2803
2803
  loadMessenger() {
2804
2804
  if (this.messenger) return Promise.resolve(this.messenger);
2805
2805
  if (this.messengerLoading) return this.messengerLoading;
2806
- this.messengerLoading = import("@guidelytech/guide-runtime/messenger").then(({ renderMessenger }) => {
2806
+ this.messengerLoading = import("@guidelytech/guide-runtime/messenger").then(({ renderMessenger, parseLauncherSpot }) => {
2807
2807
  const cfg = this.config?.messenger;
2808
2808
  if (this.destroyed || !this.config || !cfg?.enabled || this.messenger) return this.messenger;
2809
2809
  const scope = createScope(this.theme());
@@ -2821,6 +2821,8 @@ var GuidelyClient = class _GuidelyClient {
2821
2821
  locale: () => this.rcLocale()
2822
2822
  }),
2823
2823
  visitor: () => this.messengerVisitor(),
2824
+ launcherSpot: parseLauncherSpot(this.store.get(KEYS.launcher(this.options.projectId))),
2825
+ onLauncherMove: (spot) => writeJson(this.store, KEYS.launcher(this.options.projectId), spot),
2824
2826
  brand: { logoUrl: this.theme().logoUrl ?? null, name: this.theme().brandName ?? null },
2825
2827
  onResumeGuide: (guideId, stepId) => this.startGuide(guideId, { stepId }),
2826
2828
  onNewsSeen: (ids) => {