visjs / ngx-vis

An angular 5+ vis.js project
https://visjs.github.io/ngx-vis
MIT License
69 stars 31 forks source link

Timeline options template: provide angular template #400

Open fijackokresimir opened 4 years ago

fijackokresimir commented 4 years ago

Is there a way to pass angular template for template property in Timeline Options? Like in documentation: https://visjs.github.io/vis-timeline/docs/timeline/#Templates

YahyaRechaki commented 4 months ago

same question. @fijackokresimir did you find anything about this ?

kresimirfijacko commented 4 months ago

same question. @fijackokresimir did you find anything about this ? @YahyaRechaki i stopped working on that project 4 years ago, i have no idea if something happened in the meantime

YahyaRechaki commented 4 months ago

for this purpose, there is a work around that you can implement is to create the template yourself, meaning you prepare the HTML code yourself (the squelette, div, span, p...) manage data management, if conditions, ngFor... (if applicable) in the ts file, and then you can apply style using the :host ::ng-deep directly to your added template. you can target your template by checking it's parent that is added to, for the visjs timeline item : the content is added under the div with class name vis-item-content.