@jmp-technologies/analytics 0.1.32 → 0.1.34

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.
Files changed (79) hide show
  1. package/dist/astro/client.cjs +4 -1
  2. package/dist/astro/client.cjs.map +1 -1
  3. package/dist/astro/client.d.cts +2 -2
  4. package/dist/astro/client.d.ts +2 -2
  5. package/dist/astro/client.js +1 -1
  6. package/dist/astro/content.cjs +33 -15
  7. package/dist/astro/content.cjs.map +1 -1
  8. package/dist/astro/content.d.cts +7 -7
  9. package/dist/astro/content.d.ts +7 -7
  10. package/dist/astro/content.js +2 -2
  11. package/dist/astro/integration.cjs +4 -1
  12. package/dist/astro/integration.cjs.map +1 -1
  13. package/dist/astro/integration.js +2 -2
  14. package/dist/astro/middleware.d.cts +2 -2
  15. package/dist/astro/middleware.d.ts +2 -2
  16. package/dist/astro/register.cjs +4 -1
  17. package/dist/astro/register.cjs.map +1 -1
  18. package/dist/astro/register.js +2 -2
  19. package/dist/{chunk-HKMDWTA2.js → chunk-4NUFHUWN.js} +10 -10
  20. package/dist/chunk-4NUFHUWN.js.map +1 -0
  21. package/dist/{chunk-NI7R6QZQ.js → chunk-NJAMXGIW.js} +73 -11
  22. package/dist/chunk-NJAMXGIW.js.map +1 -0
  23. package/dist/{chunk-7623G3XL.js → chunk-SIJ4TDRV.js} +2 -2
  24. package/dist/{chunk-NDSPSAWQ.js → chunk-UL7JTTTB.js} +2 -2
  25. package/dist/{chunk-KPTMZQCY.js → chunk-VUWHDHXS.js} +2 -2
  26. package/dist/{create-jmp-analytics-htx2oOEf.d.ts → create-jmp-analytics-CwtcXBd7.d.ts} +1 -1
  27. package/dist/{create-jmp-analytics-D1dUsqCQ.d.cts → create-jmp-analytics-lkGcysG_.d.cts} +1 -1
  28. package/dist/index.cjs +74 -10
  29. package/dist/index.cjs.map +1 -1
  30. package/dist/index.d.cts +23 -13
  31. package/dist/index.d.ts +23 -13
  32. package/dist/index.js +5 -1
  33. package/dist/next/content.cjs +33 -15
  34. package/dist/next/content.cjs.map +1 -1
  35. package/dist/next/content.d.cts +2 -2
  36. package/dist/next/content.d.ts +2 -2
  37. package/dist/next/content.js +2 -2
  38. package/dist/next/instrumentation.cjs +4 -1
  39. package/dist/next/instrumentation.cjs.map +1 -1
  40. package/dist/next/instrumentation.js +1 -1
  41. package/dist/next/landing-pages.cjs +4 -1
  42. package/dist/next/landing-pages.cjs.map +1 -1
  43. package/dist/next/landing-pages.d.cts +2 -2
  44. package/dist/next/landing-pages.d.ts +2 -2
  45. package/dist/next/landing-pages.js +2 -2
  46. package/dist/next/locations.cjs +4 -1
  47. package/dist/next/locations.cjs.map +1 -1
  48. package/dist/next/locations.d.cts +2 -2
  49. package/dist/next/locations.d.ts +2 -2
  50. package/dist/next/locations.js +2 -2
  51. package/dist/next/middleware.d.cts +2 -2
  52. package/dist/next/middleware.d.ts +2 -2
  53. package/dist/next/site-root-server.cjs +4 -1
  54. package/dist/next/site-root-server.cjs.map +1 -1
  55. package/dist/next/site-root-server.js +3 -3
  56. package/dist/next.cjs +4 -1
  57. package/dist/next.cjs.map +1 -1
  58. package/dist/next.d.cts +3 -3
  59. package/dist/next.d.ts +3 -3
  60. package/dist/next.js +3 -3
  61. package/dist/react.cjs +4 -1
  62. package/dist/react.cjs.map +1 -1
  63. package/dist/react.d.cts +2 -2
  64. package/dist/react.d.ts +2 -2
  65. package/dist/react.js +2 -2
  66. package/dist/{site-config-B7USGGzu.d.cts → site-config-BMlEQ_8g.d.cts} +1 -1
  67. package/dist/{site-config-C4bcUoLI.d.ts → site-config-BbE6kGDd.d.ts} +1 -1
  68. package/dist/{track-page-view-RiB-xgIx.d.ts → track-page-view-BPWGGoMr.d.ts} +1 -1
  69. package/dist/{track-page-view-C4TbbULE.d.cts → track-page-view-DaNOaIxF.d.cts} +1 -1
  70. package/dist/{types-DRljY1Yy.d.cts → types-BdC3SRH-.d.cts} +24 -1
  71. package/dist/{types-DRljY1Yy.d.ts → types-BdC3SRH-.d.ts} +24 -1
  72. package/dist/{utils-CHT3SQFv.d.ts → utils-B4E-pcQ0.d.ts} +1 -1
  73. package/dist/{utils-BajG58pj.d.cts → utils-DIHFgovG.d.cts} +1 -1
  74. package/package.json +1 -1
  75. package/dist/chunk-HKMDWTA2.js.map +0 -1
  76. package/dist/chunk-NI7R6QZQ.js.map +0 -1
  77. /package/dist/{chunk-7623G3XL.js.map → chunk-SIJ4TDRV.js.map} +0 -0
  78. /package/dist/{chunk-NDSPSAWQ.js.map → chunk-UL7JTTTB.js.map} +0 -0
  79. /package/dist/{chunk-KPTMZQCY.js.map → chunk-VUWHDHXS.js.map} +0 -0
package/dist/index.d.cts CHANGED
@@ -1,13 +1,13 @@
1
1
  export { b as buildLandingCaptureInlineScript } from './landing-capture-C8pyZWuF.cjs';
2
- import { J as JmpAnalytics } from './create-jmp-analytics-D1dUsqCQ.cjs';
3
- export { B as BOOKING_LINK_HOSTS, C as ClassifiedContactLink, b as ContactLinkChannel, c as classifyContactHref, d as createJmpAnalytics, i as isJmpTrackingConsentGranted, s as setJmpTrackingConsent, a as subscribeJmpTrackingConsent } from './create-jmp-analytics-D1dUsqCQ.cjs';
4
- import { m as JmpContentConfig, r as TrackServerPageViewOptions, h as JmpTrustBundle, k as JmpContentWrapper, d as JmpLandingPageKind, b as JmpLandingPage, c as JmpLandingPageDetail, J as JmpBlogPost, a as JmpFaqItem, e as JmpLandingPageSitemapEntry, j as JmpWebsiteLocationDetail, i as JmpWebsiteLocation, f as JmpSiteProfile, o as JmpAnalyticsConfig } from './types-DRljY1Yy.cjs';
5
- export { s as JmpContactExtraManifest, l as JmpContentManifest, t as JmpContentRouteManifest, u as JmpContentWrapperReportMode, v as JmpCredential, p as JmpEventType, w as JmpPartnerLogo, n as JmpServerRequestLike, g as JmpTestimonial, x as JmpTrustBlockManifest, y as JmpTrustSection, z as JmpTrustStat, A as JmpTrustSummary, L as LeadMetadata, B as LeadMetadataValue, q as TrackLeadOptions, T as TrackPageViewOptions, C as normalizeJmpContentManifest, D as stableJmpManifestFingerprint } from './types-DRljY1Yy.cjs';
2
+ import { J as JmpAnalytics } from './create-jmp-analytics-lkGcysG_.cjs';
3
+ export { B as BOOKING_LINK_HOSTS, C as ClassifiedContactLink, b as ContactLinkChannel, c as classifyContactHref, d as createJmpAnalytics, i as isJmpTrackingConsentGranted, s as setJmpTrackingConsent, a as subscribeJmpTrackingConsent } from './create-jmp-analytics-lkGcysG_.cjs';
4
+ import { m as JmpContentConfig, r as TrackServerPageViewOptions, h as JmpTrustBundle, k as JmpContentWrapper, d as JmpLandingPageKind, b as JmpLandingPage, c as JmpLandingPageDetail, J as JmpBlogPost, s as JmpBlogPostDetail, t as JmpFaqItemDetail, a as JmpFaqItem, e as JmpLandingPageSitemapEntry, j as JmpWebsiteLocationDetail, i as JmpWebsiteLocation, f as JmpSiteProfile, o as JmpAnalyticsConfig } from './types-BdC3SRH-.cjs';
5
+ export { u as JmpContactExtraManifest, v as JmpContentLocaleAlternate, l as JmpContentManifest, w as JmpContentRouteManifest, x as JmpContentWrapperReportMode, y as JmpCredential, p as JmpEventType, z as JmpPartnerLogo, n as JmpServerRequestLike, g as JmpTestimonial, A as JmpTrustBlockManifest, B as JmpTrustSection, C as JmpTrustStat, D as JmpTrustSummary, L as LeadMetadata, E as LeadMetadataValue, q as TrackLeadOptions, T as TrackPageViewOptions, F as normalizeJmpContentManifest, G as stableJmpManifestFingerprint } from './types-BdC3SRH-.cjs';
6
6
  export { J as JmpPublicEnv, r as readJmpPublicEnvFromProcess } from './env-public-B6Y0DG68.cjs';
7
- export { a as JmpSiteContactFallback, b as JmpSiteDefinition, d as defineJmpSite, g as getJmpContentConfig, c as getJmpSiteDefinition } from './site-config-B7USGGzu.cjs';
7
+ export { a as JmpSiteContactFallback, b as JmpSiteDefinition, d as defineJmpSite, g as getJmpContentConfig, c as getJmpSiteDefinition } from './site-config-BMlEQ_8g.cjs';
8
8
 
9
9
  /** Published package version — sent with capabilities for admin readiness. */
10
- declare const JMP_ANALYTICS_SDK_VERSION = "0.1.26";
10
+ declare const JMP_ANALYTICS_SDK_VERSION: string;
11
11
  /** `localStorage` key when {@link JmpAnalyticsConfig.requireConsent} is enabled. */
12
12
  declare const JMP_TRACKING_CONSENT_STORAGE_KEY = "jmp_analytics_consent_v1";
13
13
  /** Default `pageViewDedupeMs` when resolving browser config from env (Strict Mode / SPA). */
@@ -20,9 +20,15 @@ declare function inferTrustWrapperSlots(bundle: JmpTrustBundle): string[];
20
20
  declare function getDiscoveredContentWrappers(): string[];
21
21
  declare function resetContentWrapperDiscoveryForTests(): void;
22
22
 
23
- declare function getJmpBlogPosts(config: JmpContentConfig): Promise<JmpBlogPost[]>;
24
- declare function getJmpBlogPost(config: JmpContentConfig, slug: string): Promise<JmpBlogPost | null>;
25
- declare function getJmpFaqs(config: JmpContentConfig): Promise<JmpFaqItem[]>;
23
+ declare function getJmpBlogPosts(config: JmpContentConfig, filters?: {
24
+ locale?: string;
25
+ }): Promise<JmpBlogPost[]>;
26
+ declare function getJmpBlogPost(config: JmpContentConfig, slug: string, locale?: string): Promise<JmpBlogPost | null>;
27
+ declare function getJmpBlogPostDetail(config: JmpContentConfig, slug: string, locale?: string): Promise<JmpBlogPostDetail | null>;
28
+ declare function getJmpFaqs(config: JmpContentConfig, filters?: {
29
+ locale?: string;
30
+ }): Promise<JmpFaqItem[]>;
31
+ declare function getJmpFaqDetail(config: JmpContentConfig, slug: string, locale?: string): Promise<JmpFaqItemDetail | null>;
26
32
  declare function getJmpLandingPages(config: JmpContentConfig, filters?: {
27
33
  kind?: JmpLandingPageKind;
28
34
  locale?: string;
@@ -48,9 +54,13 @@ declare function registerJmpContentWrappers(config: JmpContentConfig): Promise<{
48
54
  }>;
49
55
 
50
56
  declare function createJmpContentClient(config: JmpContentConfig): {
51
- getBlogPosts: () => Promise<JmpBlogPost[]>;
52
- getBlogPost: (slug: string) => Promise<JmpBlogPost | null>;
53
- getFaqs: () => Promise<JmpFaqItem[]>;
57
+ getBlogPosts: (filters?: {
58
+ locale?: string;
59
+ }) => Promise<JmpBlogPost[]>;
60
+ getBlogPost: (slug: string, locale?: string) => Promise<JmpBlogPost | null>;
61
+ getFaqs: (filters?: {
62
+ locale?: string;
63
+ }) => Promise<JmpFaqItem[]>;
54
64
  getLandingPages: (filters?: Parameters<typeof getJmpLandingPages>[1]) => Promise<JmpLandingPage[]>;
55
65
  getLandingPageDetail: (kind: Parameters<typeof getJmpLandingPageDetail>[1], slug: string, locale?: string) => Promise<JmpLandingPageDetail | null>;
56
66
  getLandingPageSitemap: () => Promise<JmpLandingPageSitemapEntry[]>;
@@ -91,4 +101,4 @@ declare function getOrCreateJmpAnalyticsFromBrowserEnv(overrides?: Partial<JmpAn
91
101
  */
92
102
  declare function createJmpContentClientFromServerEnv(overrides?: Partial<JmpContentConfig>): JmpContentClient | null;
93
103
 
94
- export { DEFAULT_JMP_BROWSER_PAGE_VIEW_DEDUPE_MS, JMP_ANALYTICS_SDK_VERSION, JMP_TRACKING_CONSENT_STORAGE_KEY, JmpAnalytics, JmpAnalyticsConfig, JmpBlogPost, type JmpContentClient, JmpContentConfig, JmpContentWrapper, JmpFaqItem, JmpLandingPage, JmpLandingPageDetail, JmpLandingPageKind, JmpLandingPageSitemapEntry, JmpSiteProfile, JmpTrustBundle, JmpWebsiteLocation, JmpWebsiteLocationDetail, TrackServerPageViewOptions, createJmpContentClient, createJmpContentClientFromServerEnv, getDiscoveredContentWrappers, getJmpBlogPost, getJmpBlogPosts, getJmpBrowserAnalyticsConfigFromEnv, getJmpFaqs, getJmpLandingPageDetail, getJmpLandingPageSitemap, getJmpLandingPages, getJmpLocationDetail, getJmpLocations, getJmpRobotsTxt, getJmpServerContentConfigFromEnv, getJmpSiteProfile, getJmpTrustBundle, getOrCreateJmpAnalyticsFromBrowserEnv, inferTrustWrapperSlots, isJmpBrowserAnalyticsEnvConfigured, isJmpServerContentEnvConfigured, markContentWrapper, registerJmpContentWrappers, resetContentWrapperDiscoveryForTests, trackJmpServerPageView };
104
+ export { DEFAULT_JMP_BROWSER_PAGE_VIEW_DEDUPE_MS, JMP_ANALYTICS_SDK_VERSION, JMP_TRACKING_CONSENT_STORAGE_KEY, JmpAnalytics, JmpAnalyticsConfig, JmpBlogPost, JmpBlogPostDetail, type JmpContentClient, JmpContentConfig, JmpContentWrapper, JmpFaqItem, JmpFaqItemDetail, JmpLandingPage, JmpLandingPageDetail, JmpLandingPageKind, JmpLandingPageSitemapEntry, JmpSiteProfile, JmpTrustBundle, JmpWebsiteLocation, JmpWebsiteLocationDetail, TrackServerPageViewOptions, createJmpContentClient, createJmpContentClientFromServerEnv, getDiscoveredContentWrappers, getJmpBlogPost, getJmpBlogPostDetail, getJmpBlogPosts, getJmpBrowserAnalyticsConfigFromEnv, getJmpFaqDetail, getJmpFaqs, getJmpLandingPageDetail, getJmpLandingPageSitemap, getJmpLandingPages, getJmpLocationDetail, getJmpLocations, getJmpRobotsTxt, getJmpServerContentConfigFromEnv, getJmpSiteProfile, getJmpTrustBundle, getOrCreateJmpAnalyticsFromBrowserEnv, inferTrustWrapperSlots, isJmpBrowserAnalyticsEnvConfigured, isJmpServerContentEnvConfigured, markContentWrapper, registerJmpContentWrappers, resetContentWrapperDiscoveryForTests, trackJmpServerPageView };
package/dist/index.d.ts CHANGED
@@ -1,13 +1,13 @@
1
1
  export { b as buildLandingCaptureInlineScript } from './landing-capture-C8pyZWuF.js';
2
- import { J as JmpAnalytics } from './create-jmp-analytics-htx2oOEf.js';
3
- export { B as BOOKING_LINK_HOSTS, C as ClassifiedContactLink, b as ContactLinkChannel, c as classifyContactHref, d as createJmpAnalytics, i as isJmpTrackingConsentGranted, s as setJmpTrackingConsent, a as subscribeJmpTrackingConsent } from './create-jmp-analytics-htx2oOEf.js';
4
- import { m as JmpContentConfig, r as TrackServerPageViewOptions, h as JmpTrustBundle, k as JmpContentWrapper, d as JmpLandingPageKind, b as JmpLandingPage, c as JmpLandingPageDetail, J as JmpBlogPost, a as JmpFaqItem, e as JmpLandingPageSitemapEntry, j as JmpWebsiteLocationDetail, i as JmpWebsiteLocation, f as JmpSiteProfile, o as JmpAnalyticsConfig } from './types-DRljY1Yy.js';
5
- export { s as JmpContactExtraManifest, l as JmpContentManifest, t as JmpContentRouteManifest, u as JmpContentWrapperReportMode, v as JmpCredential, p as JmpEventType, w as JmpPartnerLogo, n as JmpServerRequestLike, g as JmpTestimonial, x as JmpTrustBlockManifest, y as JmpTrustSection, z as JmpTrustStat, A as JmpTrustSummary, L as LeadMetadata, B as LeadMetadataValue, q as TrackLeadOptions, T as TrackPageViewOptions, C as normalizeJmpContentManifest, D as stableJmpManifestFingerprint } from './types-DRljY1Yy.js';
2
+ import { J as JmpAnalytics } from './create-jmp-analytics-CwtcXBd7.js';
3
+ export { B as BOOKING_LINK_HOSTS, C as ClassifiedContactLink, b as ContactLinkChannel, c as classifyContactHref, d as createJmpAnalytics, i as isJmpTrackingConsentGranted, s as setJmpTrackingConsent, a as subscribeJmpTrackingConsent } from './create-jmp-analytics-CwtcXBd7.js';
4
+ import { m as JmpContentConfig, r as TrackServerPageViewOptions, h as JmpTrustBundle, k as JmpContentWrapper, d as JmpLandingPageKind, b as JmpLandingPage, c as JmpLandingPageDetail, J as JmpBlogPost, s as JmpBlogPostDetail, t as JmpFaqItemDetail, a as JmpFaqItem, e as JmpLandingPageSitemapEntry, j as JmpWebsiteLocationDetail, i as JmpWebsiteLocation, f as JmpSiteProfile, o as JmpAnalyticsConfig } from './types-BdC3SRH-.js';
5
+ export { u as JmpContactExtraManifest, v as JmpContentLocaleAlternate, l as JmpContentManifest, w as JmpContentRouteManifest, x as JmpContentWrapperReportMode, y as JmpCredential, p as JmpEventType, z as JmpPartnerLogo, n as JmpServerRequestLike, g as JmpTestimonial, A as JmpTrustBlockManifest, B as JmpTrustSection, C as JmpTrustStat, D as JmpTrustSummary, L as LeadMetadata, E as LeadMetadataValue, q as TrackLeadOptions, T as TrackPageViewOptions, F as normalizeJmpContentManifest, G as stableJmpManifestFingerprint } from './types-BdC3SRH-.js';
6
6
  export { J as JmpPublicEnv, r as readJmpPublicEnvFromProcess } from './env-public-B6Y0DG68.js';
7
- export { a as JmpSiteContactFallback, b as JmpSiteDefinition, d as defineJmpSite, g as getJmpContentConfig, c as getJmpSiteDefinition } from './site-config-C4bcUoLI.js';
7
+ export { a as JmpSiteContactFallback, b as JmpSiteDefinition, d as defineJmpSite, g as getJmpContentConfig, c as getJmpSiteDefinition } from './site-config-BbE6kGDd.js';
8
8
 
9
9
  /** Published package version — sent with capabilities for admin readiness. */
10
- declare const JMP_ANALYTICS_SDK_VERSION = "0.1.26";
10
+ declare const JMP_ANALYTICS_SDK_VERSION: string;
11
11
  /** `localStorage` key when {@link JmpAnalyticsConfig.requireConsent} is enabled. */
12
12
  declare const JMP_TRACKING_CONSENT_STORAGE_KEY = "jmp_analytics_consent_v1";
13
13
  /** Default `pageViewDedupeMs` when resolving browser config from env (Strict Mode / SPA). */
@@ -20,9 +20,15 @@ declare function inferTrustWrapperSlots(bundle: JmpTrustBundle): string[];
20
20
  declare function getDiscoveredContentWrappers(): string[];
21
21
  declare function resetContentWrapperDiscoveryForTests(): void;
22
22
 
23
- declare function getJmpBlogPosts(config: JmpContentConfig): Promise<JmpBlogPost[]>;
24
- declare function getJmpBlogPost(config: JmpContentConfig, slug: string): Promise<JmpBlogPost | null>;
25
- declare function getJmpFaqs(config: JmpContentConfig): Promise<JmpFaqItem[]>;
23
+ declare function getJmpBlogPosts(config: JmpContentConfig, filters?: {
24
+ locale?: string;
25
+ }): Promise<JmpBlogPost[]>;
26
+ declare function getJmpBlogPost(config: JmpContentConfig, slug: string, locale?: string): Promise<JmpBlogPost | null>;
27
+ declare function getJmpBlogPostDetail(config: JmpContentConfig, slug: string, locale?: string): Promise<JmpBlogPostDetail | null>;
28
+ declare function getJmpFaqs(config: JmpContentConfig, filters?: {
29
+ locale?: string;
30
+ }): Promise<JmpFaqItem[]>;
31
+ declare function getJmpFaqDetail(config: JmpContentConfig, slug: string, locale?: string): Promise<JmpFaqItemDetail | null>;
26
32
  declare function getJmpLandingPages(config: JmpContentConfig, filters?: {
27
33
  kind?: JmpLandingPageKind;
28
34
  locale?: string;
@@ -48,9 +54,13 @@ declare function registerJmpContentWrappers(config: JmpContentConfig): Promise<{
48
54
  }>;
49
55
 
50
56
  declare function createJmpContentClient(config: JmpContentConfig): {
51
- getBlogPosts: () => Promise<JmpBlogPost[]>;
52
- getBlogPost: (slug: string) => Promise<JmpBlogPost | null>;
53
- getFaqs: () => Promise<JmpFaqItem[]>;
57
+ getBlogPosts: (filters?: {
58
+ locale?: string;
59
+ }) => Promise<JmpBlogPost[]>;
60
+ getBlogPost: (slug: string, locale?: string) => Promise<JmpBlogPost | null>;
61
+ getFaqs: (filters?: {
62
+ locale?: string;
63
+ }) => Promise<JmpFaqItem[]>;
54
64
  getLandingPages: (filters?: Parameters<typeof getJmpLandingPages>[1]) => Promise<JmpLandingPage[]>;
55
65
  getLandingPageDetail: (kind: Parameters<typeof getJmpLandingPageDetail>[1], slug: string, locale?: string) => Promise<JmpLandingPageDetail | null>;
56
66
  getLandingPageSitemap: () => Promise<JmpLandingPageSitemapEntry[]>;
@@ -91,4 +101,4 @@ declare function getOrCreateJmpAnalyticsFromBrowserEnv(overrides?: Partial<JmpAn
91
101
  */
92
102
  declare function createJmpContentClientFromServerEnv(overrides?: Partial<JmpContentConfig>): JmpContentClient | null;
93
103
 
94
- export { DEFAULT_JMP_BROWSER_PAGE_VIEW_DEDUPE_MS, JMP_ANALYTICS_SDK_VERSION, JMP_TRACKING_CONSENT_STORAGE_KEY, JmpAnalytics, JmpAnalyticsConfig, JmpBlogPost, type JmpContentClient, JmpContentConfig, JmpContentWrapper, JmpFaqItem, JmpLandingPage, JmpLandingPageDetail, JmpLandingPageKind, JmpLandingPageSitemapEntry, JmpSiteProfile, JmpTrustBundle, JmpWebsiteLocation, JmpWebsiteLocationDetail, TrackServerPageViewOptions, createJmpContentClient, createJmpContentClientFromServerEnv, getDiscoveredContentWrappers, getJmpBlogPost, getJmpBlogPosts, getJmpBrowserAnalyticsConfigFromEnv, getJmpFaqs, getJmpLandingPageDetail, getJmpLandingPageSitemap, getJmpLandingPages, getJmpLocationDetail, getJmpLocations, getJmpRobotsTxt, getJmpServerContentConfigFromEnv, getJmpSiteProfile, getJmpTrustBundle, getOrCreateJmpAnalyticsFromBrowserEnv, inferTrustWrapperSlots, isJmpBrowserAnalyticsEnvConfigured, isJmpServerContentEnvConfigured, markContentWrapper, registerJmpContentWrappers, resetContentWrapperDiscoveryForTests, trackJmpServerPageView };
104
+ export { DEFAULT_JMP_BROWSER_PAGE_VIEW_DEDUPE_MS, JMP_ANALYTICS_SDK_VERSION, JMP_TRACKING_CONSENT_STORAGE_KEY, JmpAnalytics, JmpAnalyticsConfig, JmpBlogPost, JmpBlogPostDetail, type JmpContentClient, JmpContentConfig, JmpContentWrapper, JmpFaqItem, JmpFaqItemDetail, JmpLandingPage, JmpLandingPageDetail, JmpLandingPageKind, JmpLandingPageSitemapEntry, JmpSiteProfile, JmpTrustBundle, JmpWebsiteLocation, JmpWebsiteLocationDetail, TrackServerPageViewOptions, createJmpContentClient, createJmpContentClientFromServerEnv, getDiscoveredContentWrappers, getJmpBlogPost, getJmpBlogPostDetail, getJmpBlogPosts, getJmpBrowserAnalyticsConfigFromEnv, getJmpFaqDetail, getJmpFaqs, getJmpLandingPageDetail, getJmpLandingPageSitemap, getJmpLandingPages, getJmpLocationDetail, getJmpLocations, getJmpRobotsTxt, getJmpServerContentConfigFromEnv, getJmpSiteProfile, getJmpTrustBundle, getOrCreateJmpAnalyticsFromBrowserEnv, inferTrustWrapperSlots, isJmpBrowserAnalyticsEnvConfigured, isJmpServerContentEnvConfigured, markContentWrapper, registerJmpContentWrappers, resetContentWrapperDiscoveryForTests, trackJmpServerPageView };
package/dist/index.js CHANGED
@@ -9,8 +9,10 @@ import {
9
9
  createJmpContentClientFromServerEnv,
10
10
  getDiscoveredContentWrappers,
11
11
  getJmpBlogPost,
12
+ getJmpBlogPostDetail,
12
13
  getJmpBlogPosts,
13
14
  getJmpBrowserAnalyticsConfigFromEnv,
15
+ getJmpFaqDetail,
14
16
  getJmpFaqs,
15
17
  getJmpLandingPageDetail,
16
18
  getJmpLandingPageSitemap,
@@ -33,7 +35,7 @@ import {
33
35
  setJmpTrackingConsent,
34
36
  stableJmpManifestFingerprint,
35
37
  subscribeJmpTrackingConsent
36
- } from "./chunk-NI7R6QZQ.js";
38
+ } from "./chunk-NJAMXGIW.js";
37
39
  import {
38
40
  buildLandingCaptureInlineScript
39
41
  } from "./chunk-TCZ6TC2L.js";
@@ -57,9 +59,11 @@ export {
57
59
  defineJmpSite,
58
60
  getDiscoveredContentWrappers,
59
61
  getJmpBlogPost,
62
+ getJmpBlogPostDetail,
60
63
  getJmpBlogPosts,
61
64
  getJmpBrowserAnalyticsConfigFromEnv,
62
65
  getJmpContentConfig,
66
+ getJmpFaqDetail,
63
67
  getJmpFaqs,
64
68
  getJmpLandingPageDetail,
65
69
  getJmpLandingPageSitemap,
@@ -44,8 +44,11 @@ var import_react = require("react");
44
44
  // src/landing-capture.ts
45
45
  var LANDING_REFERER_COOKIE_MAX_AGE_SEC = 30 * 60;
46
46
 
47
+ // package.json
48
+ var version = "0.1.34";
49
+
47
50
  // src/constants.ts
48
- var JMP_ANALYTICS_SDK_VERSION = "0.1.26";
51
+ var JMP_ANALYTICS_SDK_VERSION = version;
49
52
 
50
53
  // src/http.ts
51
54
  function responseLooksLikeHtml(body) {
@@ -435,20 +438,30 @@ function sortWrapperSlots(slots) {
435
438
  function afterContentWrapperUse(config) {
436
439
  scheduleContentWrapperSync(config);
437
440
  }
438
- async function getJmpBlogPosts(config) {
441
+ async function getJmpBlogPosts(config, filters) {
442
+ const params = new URLSearchParams();
443
+ if (filters?.locale) {
444
+ params.set("locale", filters.locale);
445
+ }
446
+ const query = params.toString();
439
447
  const data = await getContent(
440
448
  config,
441
- "/api/content/blog"
449
+ `/api/content/blog${query ? `?${query}` : ""}`
442
450
  );
443
451
  markContentWrapper("blog");
444
452
  afterContentWrapperUse(config);
445
453
  return data.posts;
446
454
  }
447
- async function getJmpBlogPost(config, slug) {
455
+ async function getJmpBlogPost(config, slug, locale) {
448
456
  try {
457
+ const params = new URLSearchParams();
458
+ if (locale) {
459
+ params.set("locale", locale);
460
+ }
461
+ const query = params.toString();
449
462
  const data = await getContent(
450
463
  config,
451
- `/api/content/blog/${encodeURIComponent(slug)}`
464
+ `/api/content/blog/${encodeURIComponent(slug)}${query ? `?${query}` : ""}`
452
465
  );
453
466
  markContentWrapper("blog");
454
467
  afterContentWrapperUse(config);
@@ -460,10 +473,15 @@ async function getJmpBlogPost(config, slug) {
460
473
  throw error;
461
474
  }
462
475
  }
463
- async function getJmpFaqs(config) {
476
+ async function getJmpFaqs(config, filters) {
477
+ const params = new URLSearchParams();
478
+ if (filters?.locale) {
479
+ params.set("locale", filters.locale);
480
+ }
481
+ const query = params.toString();
464
482
  const data = await getContent(
465
483
  config,
466
- "/api/content/faqs"
484
+ `/api/content/faqs${query ? `?${query}` : ""}`
467
485
  );
468
486
  markContentWrapper("faq");
469
487
  afterContentWrapperUse(config);
@@ -782,47 +800,47 @@ function listResolvedSocialUrls(social) {
782
800
  social.youtube
783
801
  ].filter((url) => Boolean(url));
784
802
  }
785
- async function loadBlogPosts() {
803
+ async function loadBlogPosts(locale) {
786
804
  const c = getJmpContentConfig();
787
805
  if (!c) {
788
806
  return [];
789
807
  }
790
808
  try {
791
- const posts = await getJmpBlogPosts(c);
809
+ const posts = await getJmpBlogPosts(c, locale ? { locale } : void 0);
792
810
  return sortBlogPosts(posts);
793
811
  } catch {
794
812
  return [];
795
813
  }
796
814
  }
797
- async function loadBlogPost(slug) {
815
+ async function loadBlogPost(slug, locale) {
798
816
  const c = getJmpContentConfig();
799
817
  if (!c) {
800
818
  return null;
801
819
  }
802
820
  try {
803
- return await getJmpBlogPost(c, slug);
821
+ return await getJmpBlogPost(c, slug, locale);
804
822
  } catch {
805
823
  return null;
806
824
  }
807
825
  }
808
- async function loadFaqs() {
826
+ async function loadFaqs(locale) {
809
827
  const c = getJmpContentConfig();
810
828
  if (!c) {
811
829
  return [];
812
830
  }
813
831
  try {
814
- const faqs = await getJmpFaqs(c);
832
+ const faqs = await getJmpFaqs(c, locale ? { locale } : void 0);
815
833
  return sortFaqs(faqs);
816
834
  } catch {
817
835
  return [];
818
836
  }
819
837
  }
820
- async function loadFaqBySlug(slug) {
838
+ async function loadFaqBySlug(slug, locale) {
821
839
  const normalized = slug.trim();
822
840
  if (!normalized) {
823
841
  return null;
824
842
  }
825
- const items = await loadFaqs();
843
+ const items = await loadFaqs(locale);
826
844
  return items.find((item) => item.slug === normalized || item.id === normalized) ?? null;
827
845
  }
828
846
  async function loadLandingPages(filters) {