1 line
8.0 KiB
Plaintext
1 line
8.0 KiB
Plaintext
{"version":3,"file":"primeng-timeline.mjs","sources":["../../src/app/components/timeline/timeline.ts","../../src/app/components/timeline/primeng-timeline.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport { AfterContentInit, ChangeDetectionStrategy, Component, ContentChildren, ElementRef, Input, NgModule, QueryList, TemplateRef, ViewEncapsulation } from '@angular/core';\nimport { BlockableUI, PrimeTemplate, SharedModule } from 'primeng/api';\nimport { Nullable } from 'primeng/ts-helpers';\n/**\n * Timeline visualizes a series of chained events.\n * @group Components\n */\n@Component({\n selector: 'p-timeline',\n template: `\n <div\n [class]=\"styleClass\"\n [ngStyle]=\"style\"\n [ngClass]=\"{\n 'p-timeline p-component': true,\n 'p-timeline-left': align === 'left',\n 'p-timeline-right': align === 'right',\n 'p-timeline-top': align === 'top',\n 'p-timeline-bottom': align === 'bottom',\n 'p-timeline-alternate': align === 'alternate',\n 'p-timeline-vertical': layout === 'vertical',\n 'p-timeline-horizontal': layout === 'horizontal'\n }\"\n [attr.data-pc-name]=\"'timeline'\"\n [attr.data-pc-section]=\"'root'\"\n >\n <div *ngFor=\"let event of value; let last = last\" class=\"p-timeline-event\" [attr.data-pc-section]=\"'event'\">\n <div class=\"p-timeline-event-opposite\" [attr.data-pc-section]=\"'opposite'\">\n <ng-container *ngTemplateOutlet=\"oppositeTemplate; context: { $implicit: event }\"></ng-container>\n </div>\n <div class=\"p-timeline-event-separator\" [attr.data-pc-section]=\"'separator'\">\n <ng-container *ngIf=\"markerTemplate; else marker\">\n <ng-container *ngTemplateOutlet=\"markerTemplate; context: { $implicit: event }\"></ng-container>\n </ng-container>\n <ng-template #marker>\n <div class=\"p-timeline-event-marker\" [attr.data-pc-section]=\"'marker'\"></div>\n </ng-template>\n <div *ngIf=\"!last\" class=\"p-timeline-event-connector\"></div>\n </div>\n <div class=\"p-timeline-event-content\" [attr.data-pc-section]=\"'content'\">\n <ng-container *ngTemplateOutlet=\"contentTemplate; context: { $implicit: event }\"></ng-container>\n </div>\n </div>\n </div>\n `,\n changeDetection: ChangeDetectionStrategy.OnPush,\n encapsulation: ViewEncapsulation.None,\n styleUrls: ['./timeline.css'],\n host: {\n class: 'p-element'\n }\n})\nexport class Timeline implements AfterContentInit, BlockableUI {\n /**\n * An array of events to display.\n * @group Props\n */\n @Input() value: any[] | undefined;\n /**\n * Inline style of the component.\n * @group Props\n */\n @Input() style: { [klass: string]: any } | null | undefined;\n /**\n * Style class of the component.\n * @group Props\n */\n @Input() styleClass: string | undefined;\n /**\n * Position of the timeline bar relative to the content. Valid values are \"left\", \"right\" for vertical layout and \"top\", \"bottom\" for horizontal layout.\n * @group Props\n */\n @Input() align: string = 'left';\n /**\n * Orientation of the timeline.\n * @group Props\n */\n @Input() layout: 'vertical' | 'horizontal' = 'vertical';\n\n @ContentChildren(PrimeTemplate) templates: Nullable<QueryList<any>>;\n\n contentTemplate: Nullable<TemplateRef<any>>;\n\n oppositeTemplate: Nullable<TemplateRef<any>>;\n\n markerTemplate: Nullable<TemplateRef<any>>;\n\n constructor(private el: ElementRef) {}\n\n getBlockableElement(): HTMLElement {\n return this.el.nativeElement.children[0];\n }\n\n ngAfterContentInit() {\n (this.templates as QueryList<PrimeTemplate>).forEach((item) => {\n switch (item.getType()) {\n case 'content':\n this.contentTemplate = item.template;\n break;\n\n case 'opposite':\n this.oppositeTemplate = item.template;\n break;\n\n case 'marker':\n this.markerTemplate = item.template;\n break;\n }\n });\n }\n}\n\n@NgModule({\n imports: [CommonModule],\n exports: [Timeline, SharedModule],\n declarations: [Timeline]\n})\nexport class TimelineModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;AAIA;;;AAGG;MA8CU,QAAQ,CAAA;AAmCG,IAAA,EAAA,CAAA;AAlCpB;;;AAGG;AACM,IAAA,KAAK,CAAoB;AAClC;;;AAGG;AACM,IAAA,KAAK,CAA8C;AAC5D;;;AAGG;AACM,IAAA,U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