@srimandir/kundli-generator 5.30.31 → 5.30.33
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/components/KundliPage/sections/index.d.ts +0 -1
- package/dist/kundli-generator.js +27 -29
- package/dist/kundli-generator.js.map +1 -1
- package/package.json +2 -2
- package/dist/components/KundliPage/sections/UtmBannerSection/UtmBannerSection.d.ts +0 -8
- package/dist/components/KundliPage/sections/UtmBannerSection/index.d.ts +0 -2
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export { KundliHeader } from './KundliHeader';
|
|
2
2
|
export { HeroSection } from './HeroSection';
|
|
3
|
-
export { UtmBannerSection } from './UtmBannerSection';
|
|
4
3
|
export { PremiumReportOverview } from './PremiumReportOverview';
|
|
5
4
|
export { UniversityCertification } from './UniversityCertification';
|
|
6
5
|
export { ThreeStepsProcess } from './ThreeStepsProcess';
|
package/dist/kundli-generator.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./styles.js";
|
|
2
|
-
import { D as
|
|
3
|
-
import { K as U, a as
|
|
4
|
-
const
|
|
2
|
+
import { D as _, I as c, K as P, a as K, b as L, j as g, c as A, S as f, g as S, d as m, i as E, r as I, s as h, e as F, u as M, f as N, h as T } from "./analytics-B0Qcb00q.js";
|
|
3
|
+
import { K as U, a as C, b as p, c as v, P as D } from "./criticalCss-BDwGM-dx.js";
|
|
4
|
+
const s = [
|
|
5
5
|
"KundliFeatures_MultipleFeatures",
|
|
6
6
|
"KundliFeatures_ExpertFirst",
|
|
7
7
|
"KundliFeatures_PredictionLed",
|
|
@@ -12,7 +12,7 @@ const n = [
|
|
|
12
12
|
"Pricing_SolutionLed",
|
|
13
13
|
"Pricing_PredictionLed",
|
|
14
14
|
"Pricing_PredictionLed_30Years"
|
|
15
|
-
],
|
|
15
|
+
], d = {
|
|
16
16
|
KundliFeatures_MultipleFeatures: "200 Pages of Personalised Kundli Insights",
|
|
17
17
|
KundliFeatures_ExpertFirst: "More Than Just a Basic Kundli",
|
|
18
18
|
KundliFeatures_PredictionLed: "Not a Generic Kundli. A Personalised Life Roadmap",
|
|
@@ -25,38 +25,36 @@ const n = [
|
|
|
25
25
|
Pricing_PredictionLed_30Years: "Your 30-Year Life Roadmap",
|
|
26
26
|
default: "Personalised Kundli Report"
|
|
27
27
|
};
|
|
28
|
-
function
|
|
28
|
+
function t(e) {
|
|
29
29
|
return e.includes("{{") || e.includes("}}");
|
|
30
30
|
}
|
|
31
|
-
function
|
|
32
|
-
if (!e ||
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
);
|
|
36
|
-
return i || "default";
|
|
31
|
+
function o(e) {
|
|
32
|
+
if (!e || t(e)) return "default";
|
|
33
|
+
const r = [...s].sort((i, n) => n.length - i.length).find((i) => e.includes(i));
|
|
34
|
+
return r || "default";
|
|
37
35
|
}
|
|
38
36
|
export {
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
37
|
+
_ as DefaultKundliImage,
|
|
38
|
+
c as I18nProvider,
|
|
39
|
+
P as KUNDLI_ANALYTICS_EVENT_NAMES,
|
|
42
40
|
U as KUNDLI_CRITICAL_CSS,
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
41
|
+
K as KUNDLI_LANGUAGE_STORAGE_KEY,
|
|
42
|
+
L as KundliContext,
|
|
43
|
+
g as KundliForm,
|
|
44
|
+
C as KundliPage,
|
|
45
|
+
p as KundliPageBase,
|
|
46
|
+
v as KundliPageV1,
|
|
49
47
|
A as KundliProvider,
|
|
50
|
-
|
|
48
|
+
D as PREMIUM_REPORT_BACKGROUND_IMAGE_URL,
|
|
51
49
|
f as SUPPORTED_LOCALES,
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
50
|
+
d as UTM_BANNER_ALT_TEXT,
|
|
51
|
+
s as UTM_BANNER_PARAMS,
|
|
52
|
+
S as getItem,
|
|
53
|
+
m as getStoredKundliLocale,
|
|
54
|
+
E as isLocalStorageAvailable,
|
|
55
|
+
I as removeItem,
|
|
56
|
+
o as resolveUtmBannerKeyFromParam,
|
|
57
|
+
h as setItem,
|
|
60
58
|
F as setStoredKundliLocale,
|
|
61
59
|
M as useI18n,
|
|
62
60
|
N as useKundliContext,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"kundli-generator.js","sources":["../src/utils/utmBanner.ts"],"sourcesContent":["/**\n * UTM-based personalised banner config for the Kundli Guide landing page.\n *\n * Each recognised utm_param value maps to a banner (hero image).\n * Consumers supply the CDN image URLs via `utmBannerImageUrls` on KundliPageProps.\n * Key 'default' is used when utm_param is absent, unrecognised, or contains unresolved ad macros.\n */\n\nexport const UTM_BANNER_PARAMS = [\n 'KundliFeatures_MultipleFeatures',\n 'KundliFeatures_ExpertFirst',\n 'KundliFeatures_PredictionLed',\n 'KundliFeatures_OthersvsSriMandir',\n 'Prediction_Transit',\n 'Prediction_UseCases',\n 'Pricing_Discovery',\n 'Pricing_SolutionLed',\n 'Pricing_PredictionLed',\n 'Pricing_PredictionLed_30Years',\n] as const;\n\nexport type UtmBannerParam = typeof UTM_BANNER_PARAMS[number];\n\n/** Alt text for each banner (headline text baked into the image). */\nexport const UTM_BANNER_ALT_TEXT: Record<UtmBannerParam | 'default', string> = {\n KundliFeatures_MultipleFeatures: '200 Pages of Personalised Kundli Insights',\n KundliFeatures_ExpertFirst: 'More Than Just a Basic Kundli',\n KundliFeatures_PredictionLed: 'Not a Generic Kundli. A Personalised Life Roadmap',\n KundliFeatures_OthersvsSriMandir: \"What makes Sri Mandir's Kundli different\",\n Prediction_Transit: 'Know When Life May Change',\n Prediction_UseCases: 'Not Just Predictions — A Life Guide',\n Pricing_Discovery: 'Answers Written in Your Birth Chart',\n Pricing_SolutionLed: 'Find Answers in Your Kundli',\n Pricing_PredictionLed: 'Not Just Predictions — A Life Guide',\n Pricing_PredictionLed_30Years: 'Your 30-Year Life Roadmap',\n default: 'Personalised Kundli Report',\n};\n\n/**\n * Returns true when the utm_param value contains an unresolved ad macro\n * (e.g. `{{campaign_name}}`). These should be treated as absent.\n */\nfunction hasUnresolvedMacros(value: string): boolean {\n return value.includes('{{') || value.includes('}}');\n}\n\nexport type ResolvedUtmBannerKey = UtmBannerParam | 'default';\n\n/**\n * Pure version of the resolver — takes the raw utm_param string directly.\n * Use this on the server (e.g. in getServerSideProps) where window is unavailable.\n */\nexport function resolveUtmBannerKeyFromParam(\n raw: string | null | undefined,\n): ResolvedUtmBannerKey {\n if (!raw || hasUnresolvedMacros(raw)) return 'default';\n const matched = (UTM_BANNER_PARAMS as
|
|
1
|
+
{"version":3,"file":"kundli-generator.js","sources":["../src/utils/utmBanner.ts"],"sourcesContent":["/**\n * UTM-based personalised banner config for the Kundli Guide landing page.\n *\n * Each recognised utm_param value maps to a banner (hero image).\n * Consumers supply the CDN image URLs via `utmBannerImageUrls` on KundliPageProps.\n * Key 'default' is used when utm_param is absent, unrecognised, or contains unresolved ad macros.\n */\n\nexport const UTM_BANNER_PARAMS = [\n 'KundliFeatures_MultipleFeatures',\n 'KundliFeatures_ExpertFirst',\n 'KundliFeatures_PredictionLed',\n 'KundliFeatures_OthersvsSriMandir',\n 'Prediction_Transit',\n 'Prediction_UseCases',\n 'Pricing_Discovery',\n 'Pricing_SolutionLed',\n 'Pricing_PredictionLed',\n 'Pricing_PredictionLed_30Years',\n] as const;\n\nexport type UtmBannerParam = typeof UTM_BANNER_PARAMS[number];\n\n/** Alt text for each banner (headline text baked into the image). */\nexport const UTM_BANNER_ALT_TEXT: Record<UtmBannerParam | 'default', string> = {\n KundliFeatures_MultipleFeatures: '200 Pages of Personalised Kundli Insights',\n KundliFeatures_ExpertFirst: 'More Than Just a Basic Kundli',\n KundliFeatures_PredictionLed: 'Not a Generic Kundli. A Personalised Life Roadmap',\n KundliFeatures_OthersvsSriMandir: \"What makes Sri Mandir's Kundli different\",\n Prediction_Transit: 'Know When Life May Change',\n Prediction_UseCases: 'Not Just Predictions — A Life Guide',\n Pricing_Discovery: 'Answers Written in Your Birth Chart',\n Pricing_SolutionLed: 'Find Answers in Your Kundli',\n Pricing_PredictionLed: 'Not Just Predictions — A Life Guide',\n Pricing_PredictionLed_30Years: 'Your 30-Year Life Roadmap',\n default: 'Personalised Kundli Report',\n};\n\n/**\n * Returns true when the utm_param value contains an unresolved ad macro\n * (e.g. `{{campaign_name}}`). These should be treated as absent.\n */\nfunction hasUnresolvedMacros(value: string): boolean {\n return value.includes('{{') || value.includes('}}');\n}\n\nexport type ResolvedUtmBannerKey = UtmBannerParam | 'default';\n\n/**\n * Pure version of the resolver — takes the raw utm_param string directly.\n * Use this on the server (e.g. in getServerSideProps) where window is unavailable.\n */\nexport function resolveUtmBannerKeyFromParam(\n raw: string | null | undefined,\n): ResolvedUtmBannerKey {\n if (!raw || hasUnresolvedMacros(raw)) return 'default';\n // Sort longest first so more specific keys (e.g. Pricing_PredictionLed_30Years)\n // are matched before shorter overlapping ones (e.g. Pricing_PredictionLed).\n const matched = ([...UTM_BANNER_PARAMS] as string[])\n .sort((a, b) => b.length - a.length)\n .find((param) => raw.includes(param));\n return matched ? (matched as UtmBannerParam) : 'default';\n}\n\n/**\n * Reads `utm_param` from the current page URL and returns the resolved key.\n * Returns `null` when window is unavailable (SSR).\n * Returns `'default'` when utm_param is absent, unrecognised, or contains macros.\n */\nexport function resolveUtmBannerKey(): ResolvedUtmBannerKey | null {\n if (typeof window === 'undefined') return null;\n const raw = new URLSearchParams(window.location.search).get('utm_param');\n return resolveUtmBannerKeyFromParam(raw);\n}\n"],"names":["UTM_BANNER_PARAMS","UTM_BANNER_ALT_TEXT","hasUnresolvedMacros","value","resolveUtmBannerKeyFromParam","raw","matched","a","b","param"],"mappings":";;;AAQO,MAAMA,IAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAKaC,IAAkE;AAAA,EAC7E,iCAAiC;AAAA,EACjC,4BAA4B;AAAA,EAC5B,8BAA8B;AAAA,EAC9B,kCAAkC;AAAA,EAClC,oBAAoB;AAAA,EACpB,qBAAqB;AAAA,EACrB,mBAAmB;AAAA,EACnB,qBAAqB;AAAA,EACrB,uBAAuB;AAAA,EACvB,+BAA+B;AAAA,EAC/B,SAAS;AACX;AAMA,SAASC,EAAoBC,GAAwB;AACnD,SAAOA,EAAM,SAAS,IAAI,KAAKA,EAAM,SAAS,IAAI;AACpD;AAQO,SAASC,EACdC,GACsB;AACtB,MAAI,CAACA,KAAOH,EAAoBG,CAAG,EAAG,QAAO;AAG7C,QAAMC,IAAW,CAAC,GAAGN,CAAiB,EACnC,KAAK,CAACO,GAAGC,MAAMA,EAAE,SAASD,EAAE,MAAM,EAClC,KAAK,CAACE,MAAUJ,EAAI,SAASI,CAAK,CAAC;AACtC,SAAOH,KAAwC;AACjD;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@srimandir/kundli-generator",
|
|
3
|
-
"version": "5.30.
|
|
3
|
+
"version": "5.30.33",
|
|
4
4
|
"description": "React NPM package for Kundli generation",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": [
|
|
@@ -84,5 +84,5 @@
|
|
|
84
84
|
"react"
|
|
85
85
|
],
|
|
86
86
|
"license": "MIT",
|
|
87
|
-
"gitHead": "
|
|
87
|
+
"gitHead": "2f8e2a386802f016a4aa7ff4acf1777a0d5afe2a"
|
|
88
88
|
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { KundliImageComponent } from '../../../../types/image';
|
|
2
|
-
export interface UtmBannerSectionProps {
|
|
3
|
-
imageUrl: string;
|
|
4
|
-
altText: string;
|
|
5
|
-
imageComponent?: KundliImageComponent;
|
|
6
|
-
className?: string;
|
|
7
|
-
}
|
|
8
|
-
export declare const UtmBannerSection: React.FC<UtmBannerSectionProps>;
|