1import{c as $}from"./chunk-ROZBHU4H.js";import{m as O}from"./chunk-S6257IJQ.js";import{$c as R,Ad as E,Ed as H,Fa as F,Ra as a,Tc as C,bd as c,ka as S,la as I,ma as U,pa as b,ra as w}from"./chunk-EFOT74HE.js";import{$b as u,Eb as P,Ib as M,Jb as D,Ma as v,Xc as N,Zb as m,Zc as A,_c as x,cd as f,dd as T,ec as h,fc as L,gc as _,hc as g,ib as l,ma as p,md as o,ob as y,wc as d}from"./chunk-5UNX62IH.js";import"./chunk-UVUYC35V.js";var B=(t,r,e)=>({link:t,label:r,target:e}),V=t=>({text:t}),z=(t,r,e,n)=>({action:t,category:r,type:e,value:n});function W(t,r){if(t&1&&(g(0,"h2",0),f(1,"safeHTML")),t&2){let e=d(2);h("innerHTML",T(1,1,e.title()),l)}}function Y(t,r){if(t&1&&(L(0,"h2"),g(1,"a",1),f(2,"safeHTML"),_()),t&2){let e=d(2);y(),h("link",A(6,B,e.effectiveUrl(),e.title(),e.targetType()))("baseLink",e.effectiveUrl())("wxpTrackValues",x(12,z,e.TrackingAction.LinkClicked,e.TrackingCategory.Click,e.TrackingType.Action,N(10,V,e.title())))("innerHTML",T(2,4,e.title()),l)}}function j(t,r){if(t&1&&m(0,W,2,3,"h2",0)(1,Y,3,17,"h2"),t&2){let e=d();u(e.effectiveUrl()?1:0)}}var re=(()=>{class t extends ${constructor(){super(...arguments),this.handleTargetLink=p(c,{self:!0}),this.hostConfig=p(F),this.finderParameterService=p(H,{optional:!0}),this.TrackingAction=S,this.TrackingCategory=I,this.TrackingType=U,this.ACTIONS=[a.MARKETING_PAGE,a.SALES_PAGE,a.PRODUCT_INFORMATION_PAGE,a.DOCUMENT_DOWNLOAD_PAGE],this.useNewPdpRoutes=this.hostConfig.pdpConfig?.useNewPdpRoutes?this.hostConfig.pdpConfig?.useNewPdpRoutes:this.hostConfig.commerce?.core.useNewPdpRoutes,this.touchpoint=o(()=>{let e=this.pimData()?.touchpoints;return e?.length>0?this.touchPointMssDirectService.getSpecificTouchPoint(e,this.ACTIONS,this.pidProvider?.getChannels(),this.locale()):void 0}),this.selectedIndustryId=o(()=>{if(!this.finderParameterService)return;let e=this.finderParameterService.parameters().filter(s=>s.key===C.FACET_INDUSTRY),n=e.length>0?e:this.finderParameterService.configuredParameters().filter(s=>s.key===C.FACET_INDUSTRY);if(n.length!==1)return;let i=n[0].id;return i?.startsWith("/")?i.slice(1):i}),this.pdpLink=o(()=>{if(!this.useNewPdpRoutes||this.pimType()!==O.PRODUCT)return;let e=this.pimSignal();if(!e)return;let i=this.envService.isAuthor()&&!this.envService.isInViewMode()?this.hostConfig.pdpConfig?.authorUrl:this.hostConfig.pdpConfig?.publicUrl;if(!i)return;let s=`${i}/${this.locale()}/pdp/${e}`,k=this.selectedIndustryId(),G=k?`?industry=${encodeURIComponent(k)}`:"";return`${s}${G}`}),this.effectiveUrl=o(()=>this.pdpLink()??this.touchpoint()?.url),this.targetType=o(()=>this.handleTargetLink.handleTargetType(this.effectiveUrl())),this.title=o(()=>this.pimData()?.name),this.hasContentToDisplay=o(()=>!!this.effectiveUrl()||!!this.title())}static{this.\u0275fac=(()=>{let e;return function(i){return(e||(e=v(t)))(i||t)}})()}static{this.\u0275cmp=P({type:t,selectors:[["basf-mgnl-pim-name-link"]],features:[M([c]),D],decls:1,vars:1,consts:[[1,"wxp-mgnl-name-link-title",3,"innerHTML"],["wxpLink","","wxpTrackLinks","","wxpAutoLoginLink","",3,"link","baseLink","wxpTrackValues","innerHTML"]],template:function(n,i){n&1&&m(0,j,2,1),n&2&&u(i.hasContentToDisplay()?0:-1)},dependencies:[c,w,b,R,E],styles:[".wxp-mgnl-name-link-title[_ngcontent-%COMP%]{color:var(--wxp-primary-color)}"],changeDetection:0})}}return t})();export{re as MgnlPimNameLinkComponent};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.