@fynd-design-engineering/fynd-one-v2 3.4.63 → 3.4.65

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/accordians/dropdown.js +1 -95
  2. package/dist/accordians/index.js +1 -391
  3. package/dist/cms-listing/index.js +1 -24
  4. package/dist/filters/clear-search.js +1 -32
  5. package/dist/filters/konnect.js +1 -165
  6. package/dist/filters/show-count.js +1 -66
  7. package/dist/form/country-dropdown.css +1 -160
  8. package/dist/form/cs-gated-redirection.js +1 -40
  9. package/dist/form/download-file.js +1 -70
  10. package/dist/form/validation.css +1 -1019
  11. package/dist/form/validation.js +7 -10611
  12. package/dist/global/anchor-scroll.js +1 -174
  13. package/dist/global/auth.js +1 -87
  14. package/dist/global/chat.js +1 -185
  15. package/dist/global/console-links.js +1 -89
  16. package/dist/global/contact-popup.js +2 -83
  17. package/dist/global/css/in-page-embed.css +1 -1043
  18. package/dist/global/css/in-project-settings.css +1 -173
  19. package/dist/global/css/temp.css +1 -89
  20. package/dist/global/custom-bg-video.js +1 -40
  21. package/dist/global/footer-accordion.js +1 -44
  22. package/dist/global/lazy-loader.js +1 -135
  23. package/dist/global/loader.js +2 -166
  24. package/dist/global/media-card.js +1 -166
  25. package/dist/global/miscellaneous.js +1 -136
  26. package/dist/global/number-count.js +1 -82
  27. package/dist/global/popup-video.js +1 -276
  28. package/dist/global/progressive-scroll.js +1 -222
  29. package/dist/global/responsive-video.js +1 -321
  30. package/dist/global/style.css +1 -1065
  31. package/dist/global/video-card.js +1 -50
  32. package/dist/hacktimus/2025.js +1 -177
  33. package/dist/hacktimus/styles.css +1 -91
  34. package/dist/home/index.js +1 -17
  35. package/dist/marquee/index.js +1 -3104
  36. package/dist/marquee/marquee-swiper.js +1 -36
  37. package/dist/navigation/announcement/index.js +1 -5169
  38. package/dist/navigation/context-menu/index.js +1 -31
  39. package/dist/navigation/desktop/index.js +1 -4603
  40. package/dist/navigation/initialization.js +1 -602
  41. package/dist/navigation/main.js +1 -4911
  42. package/dist/navigation/mobile/index.js +1 -286
  43. package/dist/navigation/scroll/index.js +1 -62
  44. package/dist/navigation/secondary-navigation/index.js +1 -437
  45. package/dist/navigation/style.css +1 -154
  46. package/dist/navigation/temp.css +0 -2
  47. package/dist/navigation/theme.css +1 -69
  48. package/dist/navigation-v2/index.js +1 -4990
  49. package/dist/navigation-v2/styles.css +1 -233
  50. package/dist/others/feature-detail.js +1 -75
  51. package/dist/others/geolocation.js +1 -50
  52. package/dist/others/hero-aniamtion.js +1 -53
  53. package/dist/others/hero-india-animation-2.js +1 -70
  54. package/dist/others/hero-india-animation.js +1 -93
  55. package/dist/others/home-solution-tab.js +1 -115
  56. package/dist/others/storefront-chat/index.js +1 -487
  57. package/dist/others/storefront-chat/styles.css +1 -107
  58. package/dist/playbook-2026/hero-reveal.js +1 -47
  59. package/dist/playbook-2026/index.js +1 -536
  60. package/dist/playbook-2026/styles.css +1 -110
  61. package/dist/posthog-and-ga/attributes.js +1 -190
  62. package/dist/posthog-and-ga/main.js +1 -528
  63. package/dist/progressive-scroll/index.js +1 -147
  64. package/dist/quick-fix/reload.js +1 -22
  65. package/dist/seo/schema.js +1 -465
  66. package/dist/slider/freescroll.js +1 -34
  67. package/dist/test/sample.js +1 -15
  68. package/dist/testimonials/index.js +1 -2654
  69. package/dist/timeline/index.js +1 -160
  70. package/dist/timeline/style.css +1 -42
  71. package/dist/tracking/custom-id.js +1 -75
  72. package/dist/tracking/fill-form-fields.js +1 -238
  73. package/dist/tracking/form-tracker.js +1 -146
  74. package/dist/tracking/page-categories.js +1 -20
  75. package/dist/tracking/user-journey.js +1 -839
  76. package/dist/tracking/utm-links.js +1 -194
  77. package/dist/utils/sample.js +1 -17
  78. package/dist/validations/localhost.js +1 -221
  79. package/package.json +1 -1
@@ -1,194 +1 @@
1
- "use strict";
2
- (() => {
3
- // bin/live-reload.js
4
- if (window.location.hostname === "localhost" || window.location.hostname === "127.0.0.1") {
5
- new EventSource(`${"http://localhost:3000"}/esbuild`).addEventListener(
6
- "change",
7
- () => location.reload()
8
- );
9
- } else {
10
- }
11
-
12
- // src/tracking/utm-links.ts
13
- (function() {
14
- "use strict";
15
- const config = {
16
- utmKeys: [
17
- "utm_source",
18
- "utm_medium",
19
- "utm_campaign",
20
- "utm_term",
21
- "utm_content",
22
- "utm_id"
23
- ],
24
- selectors: [
25
- "a[href]",
26
- 'button[onclick*="location"]',
27
- 'button[onclick*="window.open"]',
28
- 'button[onclick*="href"]',
29
- "[data-href]"
30
- ]
31
- };
32
- function getCurrentUTMParams() {
33
- const urlParams = new URLSearchParams(window.location.search);
34
- const utmParams = {};
35
- config.utmKeys.forEach((key) => {
36
- if (urlParams.has(key)) {
37
- const value = urlParams.get(key);
38
- if (value) {
39
- utmParams[key] = value;
40
- }
41
- }
42
- });
43
- return utmParams;
44
- }
45
- function isInternalLink(url, currentHost) {
46
- try {
47
- if (url.startsWith("/") || url.startsWith("./") || url.startsWith("../")) {
48
- return true;
49
- }
50
- if (url.startsWith("http")) {
51
- const linkHost = new URL(url).hostname;
52
- return linkHost === currentHost;
53
- }
54
- if (url.startsWith("//")) {
55
- const linkHost = new URL("http:" + url).hostname;
56
- return linkHost === currentHost;
57
- }
58
- if (!url.includes("://")) {
59
- return true;
60
- }
61
- return false;
62
- } catch (e) {
63
- console.warn("Error parsing URL:", url, e);
64
- return true;
65
- }
66
- }
67
- function addUTMToURL(url, utmParams) {
68
- try {
69
- const urlObj = new URL(url, window.location.origin);
70
- Object.keys(utmParams).forEach((key) => {
71
- if (!urlObj.searchParams.has(key)) {
72
- urlObj.searchParams.set(key, utmParams[key]);
73
- }
74
- });
75
- return urlObj.toString();
76
- } catch (e) {
77
- console.warn("Error processing URL:", url, e);
78
- return url;
79
- }
80
- }
81
- function hasUTMException(element) {
82
- return element.hasAttribute("data-utm-exception") && element.getAttribute("data-utm-exception") === "true";
83
- }
84
- function extractURLFromOnclick(onclickStr) {
85
- const urlMatch = onclickStr.match(
86
- /["'](https?:\/\/[^"']+|\/[^"']*|[^"']*\.html?[^"']*)["']/
87
- );
88
- return urlMatch ? urlMatch[1] : null;
89
- }
90
- function updateOnclickAttribute(element, oldUrl, newUrl) {
91
- if (!(element instanceof HTMLElement) || !element.onclick) return;
92
- const onclickStr = element.onclick.toString();
93
- const newOnclick = onclickStr.replace(oldUrl, newUrl);
94
- const funcBody = newOnclick.slice(
95
- newOnclick.indexOf("{") + 1,
96
- newOnclick.lastIndexOf("}")
97
- );
98
- element.setAttribute("onclick", funcBody);
99
- }
100
- function propagateUTMParameters() {
101
- const utmParams = getCurrentUTMParams();
102
- if (Object.keys(utmParams).length === 0) {
103
- return;
104
- }
105
- const currentHost = window.location.hostname;
106
- const elements = document.querySelectorAll(config.selectors.join(", "));
107
- elements.forEach((element) => {
108
- if (hasUTMException(element)) {
109
- return;
110
- }
111
- let url = null;
112
- if (element instanceof HTMLAnchorElement && element.href) {
113
- url = element.href;
114
- } else if (element instanceof HTMLElement && element.dataset.href) {
115
- url = element.dataset.href;
116
- } else if (element instanceof HTMLElement && element.onclick) {
117
- const onclickStr = element.onclick.toString();
118
- url = extractURLFromOnclick(onclickStr);
119
- }
120
- if (url && isInternalLink(url, currentHost)) {
121
- const updatedURL = addUTMToURL(url, utmParams);
122
- if (element instanceof HTMLAnchorElement && element.href) {
123
- element.href = updatedURL;
124
- } else if (element instanceof HTMLElement && element.dataset.href) {
125
- element.dataset.href = updatedURL;
126
- }
127
- if (element instanceof HTMLElement && element.onclick && url !== updatedURL) {
128
- updateOnclickAttribute(element, url, updatedURL);
129
- }
130
- }
131
- });
132
- console.log(`UTM parameters propagated to internal links:`, utmParams);
133
- }
134
- function observeNewContent() {
135
- const utmParams = getCurrentUTMParams();
136
- if (Object.keys(utmParams).length === 0) {
137
- return;
138
- }
139
- const observer = new MutationObserver(function(mutations) {
140
- mutations.forEach(function(mutation) {
141
- mutation.addedNodes.forEach(function(node) {
142
- if (node.nodeType === Node.ELEMENT_NODE) {
143
- const element = node;
144
- if (element.matches && element.matches(config.selectors.join(", "))) {
145
- processElement(element, utmParams);
146
- }
147
- if ("querySelectorAll" in element) {
148
- const links = element.querySelectorAll(config.selectors.join(", "));
149
- links.forEach((link) => processElement(link, utmParams));
150
- }
151
- }
152
- });
153
- });
154
- });
155
- observer.observe(document.body, {
156
- childList: true,
157
- subtree: true
158
- });
159
- }
160
- function processElement(element, utmParams) {
161
- if (hasUTMException(element)) {
162
- return;
163
- }
164
- const currentHost = window.location.hostname;
165
- let url = null;
166
- if (element instanceof HTMLAnchorElement && element.href) {
167
- url = element.href;
168
- } else if (element instanceof HTMLElement && element.dataset.href) {
169
- url = element.dataset.href;
170
- }
171
- if (url && isInternalLink(url, currentHost)) {
172
- const updatedURL = addUTMToURL(url, utmParams);
173
- if (element instanceof HTMLAnchorElement && element.href) {
174
- element.href = updatedURL;
175
- } else if (element instanceof HTMLElement && element.dataset.href) {
176
- element.dataset.href = updatedURL;
177
- }
178
- }
179
- }
180
- function init() {
181
- if (document.readyState === "loading") {
182
- document.addEventListener("DOMContentLoaded", function() {
183
- propagateUTMParameters();
184
- observeNewContent();
185
- });
186
- } else {
187
- propagateUTMParameters();
188
- observeNewContent();
189
- }
190
- }
191
- init();
192
- })();
193
- })();
194
- //# sourceMappingURL=utm-links.js.map
1
+ "use strict";(()=>{(function(){"use strict";let e={utmKeys:["utm_source","utm_medium","utm_campaign","utm_term","utm_content","utm_id"],selectors:["a[href]",'button[onclick*="location"]','button[onclick*="window.open"]','button[onclick*="href"]',"[data-href]"]};function a(){let t=new URLSearchParams(window.location.search),s={};return e.utmKeys.forEach(r=>{if(t.has(r)){let n=t.get(r);n&&(s[r]=n)}}),s}function c(t,s){try{return t.startsWith("/")||t.startsWith("./")||t.startsWith("../")?!0:t.startsWith("http")?new URL(t).hostname===s:t.startsWith("//")?new URL("http:"+t).hostname===s:!t.includes("://")}catch(r){return console.warn("Error parsing URL:",t,r),!0}}function u(t,s){try{let r=new URL(t,window.location.origin);return Object.keys(s).forEach(n=>{r.searchParams.has(n)||r.searchParams.set(n,s[n])}),r.toString()}catch(r){return console.warn("Error processing URL:",t,r),t}}function f(t){return t.hasAttribute("data-utm-exception")&&t.getAttribute("data-utm-exception")==="true"}function g(t){let s=t.match(/["'](https?:\/\/[^"']+|\/[^"']*|[^"']*\.html?[^"']*)["']/);return s?s[1]:null}function m(t,s,r){if(!(t instanceof HTMLElement)||!t.onclick)return;let o=t.onclick.toString().replace(s,r),i=o.slice(o.indexOf("{")+1,o.lastIndexOf("}"));t.setAttribute("onclick",i)}function h(){let t=a();if(Object.keys(t).length===0)return;let s=window.location.hostname;document.querySelectorAll(e.selectors.join(", ")).forEach(n=>{if(f(n))return;let o=null;if(n instanceof HTMLAnchorElement&&n.href)o=n.href;else if(n instanceof HTMLElement&&n.dataset.href)o=n.dataset.href;else if(n instanceof HTMLElement&&n.onclick){let i=n.onclick.toString();o=g(i)}if(o&&c(o,s)){let i=u(o,t);n instanceof HTMLAnchorElement&&n.href?n.href=i:n instanceof HTMLElement&&n.dataset.href&&(n.dataset.href=i),n instanceof HTMLElement&&n.onclick&&o!==i&&m(n,o,i)}}),console.log("UTM parameters propagated to internal links:",t)}function d(){let t=a();if(Object.keys(t).length===0)return;new MutationObserver(function(r){r.forEach(function(n){n.addedNodes.forEach(function(o){if(o.nodeType===Node.ELEMENT_NODE){let i=o;i.matches&&i.matches(e.selectors.join(", "))&&l(i,t),"querySelectorAll"in i&&i.querySelectorAll(e.selectors.join(", ")).forEach(E=>l(E,t))}})})}).observe(document.body,{childList:!0,subtree:!0})}function l(t,s){if(f(t))return;let r=window.location.hostname,n=null;if(t instanceof HTMLAnchorElement&&t.href?n=t.href:t instanceof HTMLElement&&t.dataset.href&&(n=t.dataset.href),n&&c(n,r)){let o=u(n,s);t instanceof HTMLAnchorElement&&t.href?t.href=o:t instanceof HTMLElement&&t.dataset.href&&(t.dataset.href=o)}}function M(){document.readyState==="loading"?document.addEventListener("DOMContentLoaded",function(){h(),d()}):(h(),d())}M()})();})();
@@ -1,17 +1 @@
1
- "use strict";
2
- (() => {
3
- // bin/live-reload.js
4
- if (window.location.hostname === "localhost" || window.location.hostname === "127.0.0.1") {
5
- new EventSource(`${"http://localhost:3000"}/esbuild`).addEventListener(
6
- "change",
7
- () => location.reload()
8
- );
9
- } else {
10
- }
11
-
12
- // src/utils/sample.ts
13
- function logMessage(message) {
14
- console.log("Logged message:", message);
15
- }
16
- })();
17
- //# sourceMappingURL=sample.js.map
1
+ "use strict";(()=>{function e(o){console.log("Logged message:",o)}})();
@@ -1,221 +1 @@
1
- "use strict";
2
- (() => {
3
- var __create = Object.create;
4
- var __defProp = Object.defineProperty;
5
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
- var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getProtoOf = Object.getPrototypeOf;
8
- var __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __esm = (fn, res) => function __init() {
10
- return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
11
- };
12
- var __commonJS = (cb, mod) => function __require() {
13
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
14
- };
15
- var __copyProps = (to, from, except, desc) => {
16
- if (from && typeof from === "object" || typeof from === "function") {
17
- for (let key of __getOwnPropNames(from))
18
- if (!__hasOwnProp.call(to, key) && key !== except)
19
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
20
- }
21
- return to;
22
- };
23
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
24
- // If the importer is in node compatibility mode or this is not an ESM
25
- // file that has been converted to a CommonJS file using a Babel-
26
- // compatible transform (i.e. "__esModule" has not been set), then set
27
- // "default" to the CommonJS "module.exports" for node compatibility.
28
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
29
- mod
30
- ));
31
-
32
- // bin/live-reload.js
33
- var init_live_reload = __esm({
34
- "bin/live-reload.js"() {
35
- "use strict";
36
- if (window.location.hostname === "localhost" || window.location.hostname === "127.0.0.1") {
37
- new EventSource(`${"http://localhost:3000"}/esbuild`).addEventListener(
38
- "change",
39
- () => location.reload()
40
- );
41
- } else {
42
- }
43
- }
44
- });
45
-
46
- // node_modules/.pnpm/@fynd-design-engineering+web-utils@1.0.1/node_modules/@fynd-design-engineering/web-utils/dist/window/get-path-segments.js
47
- var require_get_path_segments = __commonJS({
48
- "node_modules/.pnpm/@fynd-design-engineering+web-utils@1.0.1/node_modules/@fynd-design-engineering/web-utils/dist/window/get-path-segments.js"(exports) {
49
- "use strict";
50
- init_live_reload();
51
- Object.defineProperty(exports, "__esModule", { value: true });
52
- exports.getPathSegments = getPathSegments;
53
- function getPathSegments() {
54
- const pathSegments = window.location.pathname.replace(/^\//, "").split("/");
55
- return pathSegments.filter((segment) => segment !== "");
56
- }
57
- }
58
- });
59
-
60
- // node_modules/.pnpm/@fynd-design-engineering+web-utils@1.0.1/node_modules/@fynd-design-engineering/web-utils/dist/validations/localhost.js
61
- var require_localhost = __commonJS({
62
- "node_modules/.pnpm/@fynd-design-engineering+web-utils@1.0.1/node_modules/@fynd-design-engineering/web-utils/dist/validations/localhost.js"(exports) {
63
- "use strict";
64
- init_live_reload();
65
- Object.defineProperty(exports, "__esModule", { value: true });
66
- exports.checkForLocalhostUrls = checkForLocalhostUrls2;
67
- exports.enableAutomaticLocalhostCheck = enableAutomaticLocalhostCheck;
68
- function checkForLocalhostUrls2(options = {}) {
69
- const { checkLinks = true, checkImages = true, checkScripts = true, checkTextContent = true } = options;
70
- const localhostPatterns = [
71
- /localhost/gi,
72
- /127\.0\.0\.1/g,
73
- /0\.0\.0\.0/g,
74
- /\b(?:https?:\/\/)?(?:www\.)?localhost(?::\d+)?(?:\/[^\s]*)?/gi,
75
- /\b(?:https?:\/\/)?127\.0\.0\.1(?::\d+)?(?:\/[^\s]*)?/g,
76
- /\b(?:https?:\/\/)?0\.0\.0\.0(?::\d+)?(?:\/[^\s]*)?/g
77
- ];
78
- const warnings = [];
79
- const foundUrls = /* @__PURE__ */ new Set();
80
- if (checkLinks) {
81
- const links = document.querySelectorAll("a[href], link[href]");
82
- links.forEach((element) => {
83
- const href = element.getAttribute("href");
84
- if (href && localhostPatterns.some((pattern) => pattern.test(href))) {
85
- foundUrls.add(href);
86
- warnings.push(`Found localhost URL in ${element.tagName.toLowerCase()} href: ${href}`);
87
- }
88
- });
89
- }
90
- if (checkImages) {
91
- const images = document.querySelectorAll("img[src]");
92
- images.forEach((element) => {
93
- const src = element.getAttribute("src");
94
- if (src && localhostPatterns.some((pattern) => pattern.test(src))) {
95
- foundUrls.add(src);
96
- warnings.push(`Found localhost URL in img src: ${src}`);
97
- }
98
- });
99
- }
100
- if (checkScripts) {
101
- const scripts = document.querySelectorAll("script[src]");
102
- scripts.forEach((element) => {
103
- const src = element.getAttribute("src");
104
- if (src && localhostPatterns.some((pattern) => pattern.test(src))) {
105
- foundUrls.add(src);
106
- warnings.push(`Found localhost URL in script src: ${src}`);
107
- }
108
- });
109
- }
110
- if (checkTextContent) {
111
- const walker = document.createTreeWalker(document.body, NodeFilter.SHOW_TEXT, null);
112
- let node;
113
- while (node = walker.nextNode()) {
114
- const textContent = node.textContent || "";
115
- localhostPatterns.forEach((pattern) => {
116
- const matches = textContent.match(pattern);
117
- if (matches) {
118
- matches.forEach((match) => {
119
- foundUrls.add(match);
120
- warnings.push(`Found localhost URL in text content: ${match}`);
121
- });
122
- }
123
- });
124
- }
125
- }
126
- if (warnings.length > 0) {
127
- console.group("\u{1F6A8} LOCALHOST URLs DETECTED - PRODUCTION WARNING");
128
- console.warn("\u26A0\uFE0F CRITICAL: Localhost URLs found in production environment!");
129
- console.warn(`\u{1F4CA} Total issues found: ${warnings.length}`);
130
- console.warn(`\u{1F517} Unique URLs: ${foundUrls.size}`);
131
- console.log("");
132
- warnings.forEach((warning, index) => {
133
- console.warn(`${index + 1}. ${warning}`);
134
- });
135
- console.log("");
136
- console.warn("\u{1F527} Please replace all localhost URLs with production URLs before deployment.");
137
- console.warn("\u{1F4DA} This can cause broken links, missing resources, and poor user experience.");
138
- console.groupEnd();
139
- if (false) {
140
- throw new Error(`Production build contains ${foundUrls.size} localhost URLs. Please fix before deployment.`);
141
- }
142
- } else {
143
- console.log("\u2705 No localhost URLs detected in the document.");
144
- }
145
- }
146
- function enableAutomaticLocalhostCheck() {
147
- if (document.readyState === "loading") {
148
- document.addEventListener("DOMContentLoaded", () => checkForLocalhostUrls2());
149
- } else {
150
- checkForLocalhostUrls2();
151
- }
152
- }
153
- }
154
- });
155
-
156
- // node_modules/.pnpm/@fynd-design-engineering+web-utils@1.0.1/node_modules/@fynd-design-engineering/web-utils/dist/index.js
157
- var require_dist = __commonJS({
158
- "node_modules/.pnpm/@fynd-design-engineering+web-utils@1.0.1/node_modules/@fynd-design-engineering/web-utils/dist/index.js"(exports) {
159
- "use strict";
160
- init_live_reload();
161
- var __createBinding = exports && exports.__createBinding || (Object.create ? function(o, m, k, k2) {
162
- if (k2 === void 0) k2 = k;
163
- var desc = Object.getOwnPropertyDescriptor(m, k);
164
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
165
- desc = { enumerable: true, get: function() {
166
- return m[k];
167
- } };
168
- }
169
- Object.defineProperty(o, k2, desc);
170
- } : function(o, m, k, k2) {
171
- if (k2 === void 0) k2 = k;
172
- o[k2] = m[k];
173
- });
174
- var __setModuleDefault = exports && exports.__setModuleDefault || (Object.create ? function(o, v) {
175
- Object.defineProperty(o, "default", { enumerable: true, value: v });
176
- } : function(o, v) {
177
- o["default"] = v;
178
- });
179
- var __importStar = exports && exports.__importStar || /* @__PURE__ */ function() {
180
- var ownKeys = function(o) {
181
- ownKeys = Object.getOwnPropertyNames || function(o2) {
182
- var ar = [];
183
- for (var k in o2) if (Object.prototype.hasOwnProperty.call(o2, k)) ar[ar.length] = k;
184
- return ar;
185
- };
186
- return ownKeys(o);
187
- };
188
- return function(mod) {
189
- if (mod && mod.__esModule) return mod;
190
- var result = {};
191
- if (mod != null) {
192
- for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
193
- }
194
- __setModuleDefault(result, mod);
195
- return result;
196
- };
197
- }();
198
- Object.defineProperty(exports, "__esModule", { value: true });
199
- exports.navigation = exports.validations = exports.enableAutomaticLocalhostCheck = exports.checkForLocalhostUrls = exports.getPathSegments = void 0;
200
- var get_path_segments_1 = require_get_path_segments();
201
- Object.defineProperty(exports, "getPathSegments", { enumerable: true, get: function() {
202
- return get_path_segments_1.getPathSegments;
203
- } });
204
- var localhost_1 = require_localhost();
205
- Object.defineProperty(exports, "checkForLocalhostUrls", { enumerable: true, get: function() {
206
- return localhost_1.checkForLocalhostUrls;
207
- } });
208
- Object.defineProperty(exports, "enableAutomaticLocalhostCheck", { enumerable: true, get: function() {
209
- return localhost_1.enableAutomaticLocalhostCheck;
210
- } });
211
- exports.validations = __importStar(require_localhost());
212
- exports.navigation = __importStar(require_get_path_segments());
213
- }
214
- });
215
-
216
- // src/validations/localhost.ts
217
- init_live_reload();
218
- var import_web_utils = __toESM(require_dist(), 1);
219
- (0, import_web_utils.checkForLocalhostUrls)();
220
- })();
221
- //# sourceMappingURL=localhost.js.map
1
+ "use strict";(()=>{var S=Object.create;var v=Object.defineProperty;var C=Object.getOwnPropertyDescriptor;var E=Object.getOwnPropertyNames;var A=Object.getPrototypeOf,R=Object.prototype.hasOwnProperty;var g=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var j=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of E(e))!R.call(t,o)&&o!==n&&v(t,o,{get:()=>e[o],enumerable:!(r=C(e,o))||r.enumerable});return t};var k=(t,e,n)=>(n=t!=null?S(A(t)):{},j(e||!t||!t.__esModule?v(n,"default",{value:t,enumerable:!0}):n,t));var m=g(p=>{"use strict";Object.defineProperty(p,"__esModule",{value:!0});p.getPathSegments=F;function F(){return window.location.pathname.replace(/^\//,"").split("/").filter(e=>e!=="")}});var L=g(f=>{"use strict";Object.defineProperty(f,"__esModule",{value:!0});f.checkForLocalhostUrls=b;f.enableAutomaticLocalhostCheck=T;function b(t={}){let{checkLinks:e=!0,checkImages:n=!0,checkScripts:r=!0,checkTextContent:o=!0}=t,d=[/localhost/gi,/127\.0\.0\.1/g,/0\.0\.0\.0/g,/\b(?:https?:\/\/)?(?:www\.)?localhost(?::\d+)?(?:\/[^\s]*)?/gi,/\b(?:https?:\/\/)?127\.0\.0\.1(?::\d+)?(?:\/[^\s]*)?/g,/\b(?:https?:\/\/)?0\.0\.0\.0(?::\d+)?(?:\/[^\s]*)?/g],i=[],u=new Set;if(e&&document.querySelectorAll("a[href], link[href]").forEach(a=>{let s=a.getAttribute("href");s&&d.some(l=>l.test(s))&&(u.add(s),i.push(`Found localhost URL in ${a.tagName.toLowerCase()} href: ${s}`))}),n&&document.querySelectorAll("img[src]").forEach(a=>{let s=a.getAttribute("src");s&&d.some(l=>l.test(s))&&(u.add(s),i.push(`Found localhost URL in img src: ${s}`))}),r&&document.querySelectorAll("script[src]").forEach(a=>{let s=a.getAttribute("src");s&&d.some(l=>l.test(s))&&(u.add(s),i.push(`Found localhost URL in script src: ${s}`))}),o){let h=document.createTreeWalker(document.body,NodeFilter.SHOW_TEXT,null),a;for(;a=h.nextNode();){let s=a.textContent||"";d.forEach(l=>{let _=s.match(l);_&&_.forEach(w=>{u.add(w),i.push(`Found localhost URL in text content: ${w}`)})})}}if(i.length>0)throw console.group("\u{1F6A8} LOCALHOST URLs DETECTED - PRODUCTION WARNING"),console.warn("\u26A0\uFE0F CRITICAL: Localhost URLs found in production environment!"),console.warn(`\u{1F4CA} Total issues found: ${i.length}`),console.warn(`\u{1F517} Unique URLs: ${u.size}`),console.log(""),i.forEach((h,a)=>{console.warn(`${a+1}. ${h}`)}),console.log(""),console.warn("\u{1F527} Please replace all localhost URLs with production URLs before deployment."),console.warn("\u{1F4DA} This can cause broken links, missing resources, and poor user experience."),console.groupEnd(),new Error(`Production build contains ${u.size} localhost URLs. Please fix before deployment.`);console.log("\u2705 No localhost URLs detected in the document.")}function T(){document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>b()):b()}});var y=g(c=>{"use strict";var N=c&&c.__createBinding||(Object.create?function(t,e,n,r){r===void 0&&(r=n);var o=Object.getOwnPropertyDescriptor(e,n);(!o||("get"in o?!e.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return e[n]}}),Object.defineProperty(t,r,o)}:function(t,e,n,r){r===void 0&&(r=n),t[r]=e[n]}),$=c&&c.__setModuleDefault||(Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e}),O=c&&c.__importStar||function(){var t=function(e){return t=Object.getOwnPropertyNames||function(n){var r=[];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(r[r.length]=o);return r},t(e)};return function(e){if(e&&e.__esModule)return e;var n={};if(e!=null)for(var r=t(e),o=0;o<r.length;o++)r[o]!=="default"&&N(n,e,r[o]);return $(n,e),n}}();Object.defineProperty(c,"__esModule",{value:!0});c.navigation=c.validations=c.enableAutomaticLocalhostCheck=c.checkForLocalhostUrls=c.getPathSegments=void 0;var q=m();Object.defineProperty(c,"getPathSegments",{enumerable:!0,get:function(){return q.getPathSegments}});var P=L();Object.defineProperty(c,"checkForLocalhostUrls",{enumerable:!0,get:function(){return P.checkForLocalhostUrls}});Object.defineProperty(c,"enableAutomaticLocalhostCheck",{enumerable:!0,get:function(){return P.enableAutomaticLocalhostCheck}});c.validations=O(L());c.navigation=O(m())});var U=k(y(),1);(0,U.checkForLocalhostUrls)();})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fynd-design-engineering/fynd-one-v2",
3
- "version": "3.4.63",
3
+ "version": "3.4.65",
4
4
  "description": "Updated CDN for fynd.com",
5
5
  "homepage": "https://github.com/Fynd-Design-Engineering/Fynd-Utils/blob/main/README.md",
6
6
  "license": "ISC",