@fynd-design-engineering/fynd-one-v2 3.4.33 → 3.4.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.
@@ -1 +1 @@
1
- "use strict";(()=>{var g=[{optionName:"Building a website",selectValues:["Storefront","Commerce"]},{optionName:"Supply chain solutions",selectValues:["WMS","OMS","TMS","Commerce"]},{optionName:"Retail store solutions",selectValues:["Store OS","Commerce"]},{optionName:"Sell on Marketplaces",selectValues:["Konnect","Commerce"]},{optionName:"AI solutions",selectValues:["Kaily, Workflow builder, AI photoshoot"]},{optionName:"Fashion manufacturing solution",selectValues:["GaaS","DaaS"]}],y=[{slug:"/solutions/transport-management-system",selectValues:["TMS"]},{slug:"/solutions/storefront",selectValues:["Storefront"]}];function l(){try{let e=h(),r="Inbound Form",n="Inbound",s="Prospect";if(!e||e.userJourney.length===0)return;let t=e.userJourney[0],u=e.userJourney[e.userJourney.length-1];e.userJourney.length>1&&e.userJourney[e.userJourney.length-1].page==="/contact-us"&&(u=e.userJourney[e.userJourney.length-2]);let o={utm_source:t.utm.source,utm_medium:t.utm.medium,utm_campaign:t.utm.campaign,source:r,source_direction:n,contact_type:s,userjourney:JSON.stringify(e.userJourney),device:e.deviceCategory,browser:e.browser,refferer_domain:document.referrer?new URL(document.referrer).hostname:"",host_url:window.location.hostname,"current-page-url":window.location.href};Object.entries(o).forEach(([a,c])=>{E(a,c)})}catch(e){console.error("Error filling form with user journey data:",e)}}function h(){try{let e=localStorage.getItem("userJourney");return e?JSON.parse(e):null}catch(e){return console.error("Error getting user journey data:",e),null}}function E(e,r){try{let n=`[fynd-queryparam-name="${e}"]`,s=document.querySelectorAll(n);s.length>0&&s.forEach(t=>{t.value=r;let u=new Event("input",{bubbles:!0});t.dispatchEvent(u);let o=new Event("change",{bubbles:!0});t.dispatchEvent(o)})}catch(n){console.error(`Error filling field [${e}]:`,n)}}function d(e){return Array.isArray(e)?e.join("; "):""}function v(){return!window.location.pathname.startsWith("/solutions/")}function S(){let e=window.location.pathname,r=y.find(t=>t.slug===e);if(!r)return;let n=d(r.selectValues);document.querySelectorAll('[fynd-form-field="product-interested-input"]').forEach(t=>{t instanceof HTMLInputElement||t instanceof HTMLSelectElement||t instanceof HTMLTextAreaElement?t.value=n:t.textContent=n})}function b(){let e='[fynd-wrapper-field="product-interested-select"]',r='[fynd-form-field="product-interested-select"]',n='[fynd-form-field="product-interested-input"]',s=document.querySelectorAll(r),t=document.querySelectorAll(n),u=document.querySelectorAll(e);if(!v()){S(),u.forEach(o=>{o.style.display="none"});return}u.forEach(o=>{o.style.display="flex"}),s.length&&s.forEach(o=>{o.addEventListener("change",()=>{let a=o.value,c=g.find(i=>i.optionName===a),f=c?d(c.selectValues):"";t.forEach(i=>{i.value=f;let m=new Event("input",{bubbles:!0});i.dispatchEvent(m);let p=new Event("change",{bubbles:!0});i.dispatchEvent(p)})})})}document.addEventListener("DOMContentLoaded",()=>{setTimeout(()=>{l(),b()},500)});document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{setTimeout(()=>{l()},500)}):setTimeout(()=>{l()},500);window.fillFormWithUserJourney=l;})();
1
+ "use strict";(()=>{var p=[{optionName:"Building a website",selectValues:["Storefront","Commerce"]},{optionName:"Supply chain solutions",selectValues:["WMS","OMS","TMS","Commerce"]},{optionName:"Retail store solutions",selectValues:["Store OS","Commerce"]},{optionName:"Sell on Marketplaces",selectValues:["Konnect","Commerce"]},{optionName:"AI solutions",selectValues:["Kaily, Workflow builder, AI photoshoot"]},{optionName:"Fashion manufacturing solution",selectValues:["GaaS","DaaS"]}],y=[{slug:"/solutions/transport-management-system",selectValues:["TMS","Commerce"]},{slug:"/solutions/storefront",selectValues:["Storefront","Commerce"]},{slug:"/solutions/wms",selectValues:["WMS","Commerce"]},{slug:"/solutions/order-management-system",selectValues:["OMS","Commerce"]},{slug:"/solutions/order-management-system",selectValues:["OMS","Commerce"]},{slug:"/solutions/fynd-quick",selectValues:["Quick Commerce","Commerce"]},{slug:"/solutions/b2b-commerce",selectValues:["Commerce B2B","Commerce"]},{slug:"/solutions/ai-pim",selectValues:["AI PIM","Commerce"]},{slug:"/solutions/konnect-integrations",selectValues:["OMS","Commerce"]},{slug:"/solutions/logistics",selectValues:["Fynd Logistics","Commerce"]},{slug:"/solutions/returns-management-system",selectValues:["StoreOS"]},{slug:"/solutions/pos",selectValues:["StoreOS","POS"]},{slug:"/solutions/endless-aisle",selectValues:["StoreOS","Endless Aisle"]},{slug:"/solutions/clienteling",selectValues:["StoreOS","Clienteling"]},{slug:"/solutions/self-checkout",selectValues:["StoreOS","Self Checkout Kiosk"]},{slug:"/solutions/engage",selectValues:["Engage","Commerce"]},{slug:"/solutions/forge",selectValues:["Forge"]},{slug:"/solutions/ai-photoshoots",selectValues:["Snap"]},{slug:"/solutions/ai-agent-builder",selectValues:["Kaily"]},{slug:"/solutions/workflow-automation",selectValues:["Boltic"]},{slug:"/solutions/3d-ar-vr-try-ons",selectValues:["GlamAR"]},{slug:"/solutions/ai-editing-for-commerce",selectValues:["Pixelbin"]},{slug:"/solutions/ai-photoshoots",selectValues:["Create Design"]}];function c(){try{let e=h(),s="Inbound Form",o="Inbound",r="Prospect";if(!e||e.userJourney.length===0)return;let t=e.userJourney[0],l=e.userJourney[e.userJourney.length-1];e.userJourney.length>1&&e.userJourney[e.userJourney.length-1].page==="/contact-us"&&(l=e.userJourney[e.userJourney.length-2]);let n={utm_source:t.utm.source,utm_medium:t.utm.medium,utm_campaign:t.utm.campaign,source:s,source_direction:o,contact_type:r,userjourney:JSON.stringify(e.userJourney),device:e.deviceCategory,browser:e.browser,refferer_domain:document.referrer?new URL(document.referrer).hostname:"",host_url:window.location.hostname,"current-page-url":window.location.href};Object.entries(n).forEach(([a,i])=>{S(a,i)})}catch(e){console.error("Error filling form with user journey data:",e)}}function h(){try{let e=localStorage.getItem("userJourney");return e?JSON.parse(e):null}catch(e){return console.error("Error getting user journey data:",e),null}}function S(e,s){try{let o=`[fynd-queryparam-name="${e}"]`,r=document.querySelectorAll(o);r.length>0&&r.forEach(t=>{t.value=s;let l=new Event("input",{bubbles:!0});t.dispatchEvent(l);let n=new Event("change",{bubbles:!0});t.dispatchEvent(n)})}catch(o){console.error(`Error filling field [${e}]:`,o)}}function m(e){return Array.isArray(e)?e.join("; "):""}function E(){return!window.location.pathname.startsWith("/solutions/")}function V(){let e=window.location.pathname,s=y.find(t=>t.slug===e);if(!s)return;let o=m(s.selectValues);document.querySelectorAll('[fynd-form-field="product-interested-input"]').forEach(t=>{t instanceof HTMLInputElement||t instanceof HTMLSelectElement||t instanceof HTMLTextAreaElement?t.value=o:t.textContent=o})}function v(){let e='[fynd-wrapper-field="product-interested-select"]',s='[fynd-form-field="product-interested-select"]',o='[fynd-form-field="product-interested-input"]',r=document.querySelectorAll(s),t=document.querySelectorAll(o),l=document.querySelectorAll(e);if(!E()){V(),l.forEach(n=>{n.style.display="none"});return}l.forEach(n=>{n.style.display="flex"}),r.length&&r.forEach(n=>{n.addEventListener("change",()=>{let a=n.value,i=p.find(u=>u.optionName===a),g=i?m(i.selectValues):"";t.forEach(u=>{u.value=g;let d=new Event("input",{bubbles:!0});u.dispatchEvent(d);let f=new Event("change",{bubbles:!0});u.dispatchEvent(f)})})})}document.addEventListener("DOMContentLoaded",()=>{setTimeout(()=>{c(),v()},500)});document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{setTimeout(()=>{c()},500)}):setTimeout(()=>{c()},500);window.fillFormWithUserJourney=c;})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fynd-design-engineering/fynd-one-v2",
3
- "version": "3.4.33",
3
+ "version": "3.4.34",
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",