PageSourceSearch

https://app.hightouch.com/assets/event-component-usage-DhjQx7tL.js

js hightouch.com collected 2026-10-01 07:48:10 UTC 3,028 bytes, 2 lines download raw bytes

1import{as as T,r as s,af as t,aI as C}from"./vendor-BgWhiDrf.js";import{b as f,sT as E,e2 as U,C as g,j as b,R as i,c4 as B,cr as o,sU as M,T as x,an as $}from"./main-COyT_q74.js";import{c as L}from"./event-contracts-C295whIJ.js";import{c as N}from"./utils-Clk3T56m.js";import{E as P}from"./event-type-badge-CfGqE9-k.js";import{g as k,a as z}from"./component-usage-Dwbi6mhG.js";import{u as A}from"./use-domains-6b95hjJp.js";import"./types-DyceCyeS.js";import{L as R}from"./last-updated-1y07vupx.js";import"./index-eYN535ij.js";import"./types-D1LGzhJp.js";import"./property-suggestions-B64YqAPy.js";import"./bounded-range-fetch-CggGfMWc.js";import"./vendor-charts-34qQJjVh.js";import"./utils-CqtH0mZs.js";import"./types-ypUuiJby.js";const v="/events/domains",w=()=>{const p=f(),{component_id:r}=T(),a=E({component_ids:r?[r]:[]},{enabled:!!r}),{domains:c,isLoading:h}=A(),u=s.useMemo(()=>new Map(c.map(e=>[e.id,{name:e.name,description:e.description}])),[c]),l=s.useMemo(()=>{var e;return k((((e=a.data)==null?void 0:e.event_schema_components)??[]).map(({event_schema:n})=>n))},[a.data]),d=s.useMemo(()=>{var e;return z((((e=a.data)==null?void 0:e.event_components_join)??[]).map(({importer:n})=>n))},[a.data]),y=s.useMemo(()=>[...l.map(e=>({type:"event",...e})),...d.map(e=>({type:"component",...e}))],[l,d]);return a.isLoading||h?t.jsx(U,{}):t.jsx(g,{gap:4,pt:4,children:t.jsx(b,{columns:[{name:"Domain",cell:({event_plan_id:e})=>{const n=u.get(e);return t.jsxs(i,{gap:4,align:"center",children:[t.jsx(B,{shape:"square",size:"lg",name:(n==null?void 0:n.name)??""}),t.jsxs(g,{gap:1,children:[t.jsx(o,{children:(n==null?void 0:n.name)??"Unknown domain"}),(n==null?void 0:n.description)&&t.jsx(o,{color:"text.secondary",children:(n==null?void 0:n.description)??""})]})]})}},{name:"Type",max:"max-content",cell:e=>e.type==="event"?t.jsx(P,{eventType:e.event_type}):t.jsxs(i,{align:"center",gap:2,fontSize:"lg",children:[t.jsx(M,{}),t.jsx(x,{children:"Component"})]})},{name:"Name",max:"max-content",cell:e=>e.type==="event"?t.jsx(o,{fontWeight:"medium",children:e.event_name||C(e.event_type)}):t.jsx(o,{fontWeight:"medium",children:e.name})},{name:"Versions",max:"max-content",breakpoint:"md",cell:({versions:e})=>t.jsx(t.Fragment,{children:t.jsxs(i,{gap:1,align:"center",children:[e.slice(0,3).map(n=>t.jsx($,{variant:"ghost",children:n},n)),e.length>3&&t.jsxs(x,{color:"text.secondary",size:"sm",children:["+",e.length-3," more"]})]})})},{...R,breakpoint:"md"}],data:y,error:!!a.error,placeholder:{image:L,title:"Not in use",body:"This component is not used in any events or components. Add it to an event schema or component to see its usage here.",error:"Usage failed to load, please try again."},onRowClick:e=>{if(e.type==="event"){const{event_plan_id:n,event_name:m,event_type:j,event_version:_}=e;p(`${v}/${n}/${N({eventName:m,eventType:j,eventVersion:_})}`)}else{const{event_plan_id:n,id:m}=e;p(`${v}/${n}/components/${m}`)}}})})};export{w as EventComponentUsage};
2//# sourceMappingURL=event-component-usage-DhjQx7tL.js.map

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.