{"version":3,"sources":["Timeline.tsx"],"sourcesContent":["export type TimelineItemOption = {\n\ttitle?: string | HTMLElement;\n\tdescription?: string | HTMLElement;\n}\nexport type TimelineOptions = {\n\titems?: TimelineItemOption[];\n\tgap?: number | string;\n\toffsetX?: number | string;\n\toffsetY?: number | string;\n\tbulletSize?: number | string;\n\tbulletOffset?: number | string;\n}\n\nexport const TimelineItem = blankTemplate<TimelineItemOption & { children?: any }>(({title, description, children, ...props}) => \n\t<div class=\"unyt-timeline-item\" {...props}>\n\t\t{title ? <h3>{title}</h3> : null}\n\t\t{description ? <p>{description}</p> : null}\n\t\t{children}\n\t</div>\n);\n\nexport const Timeline = blankTemplate<TimelineOptions & { children?: any }>(({style, bulletOffset, gap, offsetX, offsetY, bulletSize, items, children, ...props}) => \n\t<div stylesheet=\"./Timeline.css?\" class=\"unyt-timeline\"  style={{\n\t\t[gap ? \"--timeline-gap\" : \"\"]: gap ?? \"0\",\n\t\t[offsetX ? \"--timeline-offset-x\" : \"\"]: offsetX ?? \"0\",\n\t\t[offsetY ? \"--timeline-offset-y\" : \"\"]: offsetY ?? \"0\",\n\t\t[bulletSize ? \"--timeline-bullet-size\" : \"\"]: bulletSize ?? \"0\",\n\t\t[bulletOffset ? \"--timeline-bullet-offset\" : \"\"]: bulletOffset ?? \"0\",\n\t\t...((style ?? {}) as Record<string, string>),\n\t}} {...props}>\n\t\t{children && children.length ? children : (items ?? []).map(({title, description}) => \n\t\t\t<TimelineItem title={title as string} description={description}/>)}\n\t</div>\n);"],"names":["TimelineItem","blankTemplate","title","description","children","props","div","class","h3","p","Timeline","style","bulletOffset","gap","offsetX","offsetY","bulletSize","items","stylesheet","length","map"],"mappings":";AAaA,OAAO,MAAMA,eAAeC,cAAuD,CAAC,EAACC,KAAK,EAAEC,WAAW,EAAEC,QAAQ,EAAE,GAAGC,OAAM,iBAC3H,MAACC;QAAIC,OAAM;QAAsB,GAAGF,KAAK;;YACvCH,sBAAQ,KAACM;0BAAIN;iBAAc;YAC3BC,4BAAc,KAACM;0BAAGN;iBAAmB;YACrCC;;QAED;AAEF,OAAO,MAAMM,WAAWT,cAAoD,CAAC,EAACU,KAAK,EAAEC,YAAY,EAAEC,GAAG,EAAEC,OAAO,EAAEC,OAAO,EAAEC,UAAU,EAAEC,KAAK,EAAEb,QAAQ,EAAE,GAAGC,OAAM,iBAC/J,KAACC;QAAIY,YAAW;QAAkBX,OAAM;QAAiBI,OAAO;YAC/D,CAACE,MAAM,mBAAmB,GAAG,EAAEA,OAAO;YACtC,CAACC,UAAU,wBAAwB,GAAG,EAAEA,WAAW;YACnD,CAACC,UAAU,wBAAwB,GAAG,EAAEA,WAAW;YACnD,CAACC,aAAa,2BAA2B,GAAG,EAAEA,cAAc;YAC5D,CAACJ,eAAe,6BAA6B,GAAG,EAAEA,gBAAgB;YAClE,GAAKD,SAAS,CAAC,CAAC;QACjB;QAAI,GAAGN,KAAK;kBACVD,YAAYA,SAASe,MAAM,GAAGf,WAAW,AAACa,CAAAA,SAAS,EAAE,AAAD,EAAGG,GAAG,CAAC,CAAC,EAAClB,KAAK,EAAEC,WAAW,EAAC,iBAChF,KAACH;gBAAaE,OAAOA;gBAAiBC,aAAaA;;QAEpD","sourceRoot":"/lib/unyt-components-0.0.17/components/timeline/","file":"Timeline.tsx"}