@progress/kendo-angular-layout 16.0.0-develop.2 → 16.0.0-develop.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/avatar/avatar.component.d.ts +1 -1
- package/avatar/l10n/custom-messages.component.d.ts +1 -1
- package/avatar/l10n/localized-messages.directive.d.ts +1 -1
- package/avatar/l10n/messages.d.ts +1 -1
- package/card/card-actions.component.d.ts +1 -1
- package/card/card-body.component.d.ts +1 -1
- package/card/card-footer.component.d.ts +1 -1
- package/card/card-header.component.d.ts +1 -1
- package/card/card.component.d.ts +1 -1
- package/card/directives/card-media.directive.d.ts +1 -1
- package/card/directives/card-separator.directive.d.ts +1 -1
- package/card/directives/card-subtitle.directive.d.ts +1 -1
- package/card/directives/card-title.directive.d.ts +1 -1
- package/drawer/drawer-container.component.d.ts +1 -1
- package/drawer/drawer-content.component.d.ts +1 -1
- package/drawer/drawer.component.d.ts +1 -1
- package/drawer/item.component.d.ts +1 -1
- package/drawer/list.component.d.ts +1 -1
- package/drawer/template-directives/drawer-template.directive.d.ts +1 -1
- package/drawer/template-directives/footer-template.directive.d.ts +1 -1
- package/drawer/template-directives/header-template.directive.d.ts +1 -1
- package/drawer/template-directives/item-template.directive.d.ts +1 -1
- package/esm2020/avatar/avatar.component.mjs +7 -7
- package/esm2020/avatar/l10n/custom-messages.component.mjs +3 -3
- package/esm2020/avatar/l10n/localized-messages.directive.mjs +3 -3
- package/esm2020/avatar/l10n/messages.mjs +3 -3
- package/esm2020/avatar.module.mjs +4 -4
- package/esm2020/card/card-actions.component.mjs +4 -4
- package/esm2020/card/card-body.component.mjs +3 -3
- package/esm2020/card/card-footer.component.mjs +3 -3
- package/esm2020/card/card-header.component.mjs +3 -3
- package/esm2020/card/card.component.mjs +3 -3
- package/esm2020/card/directives/card-media.directive.mjs +3 -3
- package/esm2020/card/directives/card-separator.directive.mjs +3 -3
- package/esm2020/card/directives/card-subtitle.directive.mjs +3 -3
- package/esm2020/card/directives/card-title.directive.mjs +3 -3
- package/esm2020/card.module.mjs +4 -4
- package/esm2020/drawer/drawer-container.component.mjs +4 -4
- package/esm2020/drawer/drawer-content.component.mjs +3 -3
- package/esm2020/drawer/drawer.component.mjs +6 -6
- package/esm2020/drawer/drawer.service.mjs +3 -3
- package/esm2020/drawer/item.component.mjs +6 -6
- package/esm2020/drawer/list.component.mjs +5 -5
- package/esm2020/drawer/template-directives/drawer-template.directive.mjs +3 -3
- package/esm2020/drawer/template-directives/footer-template.directive.mjs +3 -3
- package/esm2020/drawer/template-directives/header-template.directive.mjs +3 -3
- package/esm2020/drawer/template-directives/item-template.directive.mjs +3 -3
- package/esm2020/drawer.module.mjs +4 -4
- package/esm2020/expansionpanel/expansionpanel-title.directive.mjs +3 -3
- package/esm2020/expansionpanel/expansionpanel.component.mjs +6 -6
- package/esm2020/expansionpanel.module.mjs +4 -4
- package/esm2020/gridlayout.module.mjs +4 -4
- package/esm2020/index.mjs +7 -0
- package/esm2020/layout.module.mjs +11 -7
- package/esm2020/layouts/grid-layout.component.mjs +3 -3
- package/esm2020/layouts/gridlayout-item.component.mjs +3 -3
- package/esm2020/layouts/stack-layout.component.mjs +3 -3
- package/esm2020/package-metadata.mjs +2 -2
- package/esm2020/panelbar/panelbar-content.directive.mjs +3 -3
- package/esm2020/panelbar/panelbar-item-template.directive.mjs +3 -3
- package/esm2020/panelbar/panelbar-item-title.directive.mjs +3 -3
- package/esm2020/panelbar/panelbar-item.component.mjs +6 -6
- package/esm2020/panelbar/panelbar.component.mjs +6 -6
- package/esm2020/panelbar/panelbar.service.mjs +3 -3
- package/esm2020/panelbar.module.mjs +4 -4
- package/esm2020/splitter/splitter-bar.component.mjs +6 -6
- package/esm2020/splitter/splitter-pane.component.mjs +4 -4
- package/esm2020/splitter/splitter.component.mjs +7 -7
- package/esm2020/splitter/splitter.service.mjs +3 -3
- package/esm2020/splitter.module.mjs +6 -8
- package/esm2020/stacklayout.module.mjs +4 -4
- package/esm2020/stepper/list.component.mjs +5 -5
- package/esm2020/stepper/localization/custom-messages.component.mjs +3 -3
- package/esm2020/stepper/localization/localized-messages.directive.mjs +3 -3
- package/esm2020/stepper/localization/messages.mjs +3 -3
- package/esm2020/stepper/step.component.mjs +6 -6
- package/esm2020/stepper/stepper.component.mjs +7 -7
- package/esm2020/stepper/stepper.service.mjs +3 -3
- package/esm2020/stepper/template-directives/indicator-template.directive.mjs +3 -3
- package/esm2020/stepper/template-directives/label-template.directive.mjs +3 -3
- package/esm2020/stepper/template-directives/step-template.directive.mjs +3 -3
- package/esm2020/stepper.module.mjs +4 -4
- package/esm2020/tabstrip/directives/tab-content.directive.mjs +3 -3
- package/esm2020/tabstrip/directives/tab-title.directive.mjs +3 -3
- package/esm2020/tabstrip/directives/tab.directive.mjs +3 -3
- package/esm2020/tabstrip/localization/custom-messages.component.mjs +3 -3
- package/esm2020/tabstrip/localization/localized-messages.directive.mjs +3 -3
- package/esm2020/tabstrip/localization/messages.mjs +3 -3
- package/esm2020/tabstrip/models/tabstrip-tab.component.mjs +3 -3
- package/esm2020/tabstrip/rendering/tab.component.mjs +6 -6
- package/esm2020/tabstrip/scrollable-button.component.mjs +4 -4
- package/esm2020/tabstrip/tabstrip-scroll.service.mjs +3 -3
- package/esm2020/tabstrip/tabstrip.component.mjs +8 -8
- package/esm2020/tabstrip/tabstrip.service.mjs +3 -3
- package/esm2020/tabstrip.module.mjs +4 -4
- package/esm2020/tilelayout/dragging-service.mjs +3 -3
- package/esm2020/tilelayout/keyboard-navigation.service.mjs +3 -5
- package/esm2020/tilelayout/tilelayout-item-body.component.mjs +3 -3
- package/esm2020/tilelayout/tilelayout-item-header.component.mjs +3 -3
- package/esm2020/tilelayout/tilelayout-item.component.mjs +6 -6
- package/esm2020/tilelayout/tilelayout-resize-handle.directive.mjs +3 -3
- package/esm2020/tilelayout/tilelayout.component.mjs +6 -6
- package/esm2020/tilelayout.module.mjs +4 -4
- package/esm2020/timeline/events/navigation-direction.mjs +5 -0
- package/esm2020/timeline/localization/custom-messages.component.mjs +41 -0
- package/esm2020/timeline/localization/localized-messages.directive.mjs +37 -0
- package/esm2020/timeline/localization/messages.mjs +25 -0
- package/esm2020/timeline/models/anchor-target.mjs +5 -0
- package/esm2020/timeline/models/default-model-fields.mjs +16 -0
- package/esm2020/timeline/models/model-fields.mjs +5 -0
- package/esm2020/timeline/models/timeline-event.mjs +5 -0
- package/esm2020/timeline/templates/timeline-card-actions.directive.mjs +29 -0
- package/esm2020/timeline/templates/timeline-card-body.directive.mjs +29 -0
- package/esm2020/timeline/templates/timeline-card-header.directive.mjs +29 -0
- package/esm2020/timeline/timeline-card.component.mjs +402 -0
- package/esm2020/timeline/timeline-horizontal.component.mjs +722 -0
- package/esm2020/timeline/timeline-vertical.component.mjs +175 -0
- package/esm2020/timeline/timeline.component.mjs +418 -0
- package/esm2020/timeline/timeline.service.mjs +31 -0
- package/esm2020/timeline/util.mjs +26 -0
- package/esm2020/timeline.module.mjs +65 -0
- package/expansionpanel/expansionpanel-title.directive.d.ts +1 -1
- package/expansionpanel/expansionpanel.component.d.ts +1 -1
- package/fesm2015/progress-kendo-angular-layout.mjs +2513 -584
- package/fesm2020/progress-kendo-angular-layout.mjs +2249 -347
- package/index.d.ts +10 -0
- package/layout.module.d.ts +2 -1
- package/layouts/grid-layout.component.d.ts +1 -1
- package/layouts/gridlayout-item.component.d.ts +1 -1
- package/layouts/stack-layout.component.d.ts +1 -1
- package/package.json +13 -13
- package/panelbar/panelbar-content.directive.d.ts +1 -1
- package/panelbar/panelbar-item-template.directive.d.ts +1 -1
- package/panelbar/panelbar-item-title.directive.d.ts +1 -1
- package/panelbar/panelbar-item.component.d.ts +1 -1
- package/panelbar/panelbar.component.d.ts +1 -1
- package/splitter/splitter-bar.component.d.ts +1 -1
- package/splitter/splitter-pane.component.d.ts +1 -1
- package/splitter/splitter.component.d.ts +1 -1
- package/stepper/list.component.d.ts +1 -1
- package/stepper/localization/custom-messages.component.d.ts +1 -1
- package/stepper/localization/localized-messages.directive.d.ts +1 -1
- package/stepper/localization/messages.d.ts +1 -1
- package/stepper/step.component.d.ts +1 -1
- package/stepper/stepper.component.d.ts +1 -1
- package/stepper/template-directives/indicator-template.directive.d.ts +1 -1
- package/stepper/template-directives/label-template.directive.d.ts +1 -1
- package/stepper/template-directives/step-template.directive.d.ts +1 -1
- package/tabstrip/directives/tab-content.directive.d.ts +1 -1
- package/tabstrip/directives/tab-title.directive.d.ts +1 -1
- package/tabstrip/directives/tab.directive.d.ts +1 -1
- package/tabstrip/localization/custom-messages.component.d.ts +1 -1
- package/tabstrip/localization/localized-messages.directive.d.ts +1 -1
- package/tabstrip/localization/messages.d.ts +1 -1
- package/tabstrip/models/tabstrip-tab.component.d.ts +1 -1
- package/tabstrip/rendering/tab.component.d.ts +1 -1
- package/tabstrip/scrollable-button.component.d.ts +1 -1
- package/tabstrip/tabstrip.component.d.ts +1 -1
- package/tilelayout/tilelayout-item-body.component.d.ts +1 -1
- package/tilelayout/tilelayout-item-header.component.d.ts +1 -1
- package/tilelayout/tilelayout-item.component.d.ts +1 -1
- package/tilelayout/tilelayout-resize-handle.directive.d.ts +1 -1
- package/tilelayout/tilelayout.component.d.ts +1 -1
- package/timeline/events/navigation-direction.d.ts +5 -0
- package/timeline/localization/custom-messages.component.d.ts +17 -0
- package/timeline/localization/localized-messages.directive.d.ts +16 -0
- package/timeline/localization/messages.d.ts +21 -0
- package/timeline/models/anchor-target.d.ts +5 -0
- package/{progress-kendo-angular-layout.d.ts → timeline/models/default-model-fields.d.ts} +3 -3
- package/timeline/models/model-fields.d.ts +51 -0
- package/timeline/models/timeline-event.d.ts +49 -0
- package/timeline/templates/timeline-card-actions.directive.d.ts +20 -0
- package/timeline/templates/timeline-card-body.directive.d.ts +20 -0
- package/timeline/templates/timeline-card-header.directive.d.ts +20 -0
- package/timeline/timeline-card.component.d.ts +59 -0
- package/timeline/timeline-horizontal.component.d.ts +110 -0
- package/timeline/timeline-vertical.component.d.ts +41 -0
- package/timeline/timeline.component.d.ts +186 -0
- package/timeline/timeline.service.d.ts +17 -0
- package/timeline/util.d.ts +18 -0
- package/timeline.module.d.ts +31 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Directive, Optional, TemplateRef } from '@angular/core';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* Specifies the header of each timeline card. To define a header template, nest an `<ng-template>` tag
|
|
9
|
+
* with the `kendoTimelineCardHeaderTemplate` directive inside the `<kendo-timeline>` tag.
|
|
10
|
+
*
|
|
11
|
+
* The following values are available as context variables:
|
|
12
|
+
* - `let-event="event"` (`TimelineEvent`) - The current card's event. Also available as implicit context variable.
|
|
13
|
+
* - `let-index="index"` (`number`) - The current event index.
|
|
14
|
+
*/
|
|
15
|
+
export class TimelineCardHeaderTemplateDirective {
|
|
16
|
+
constructor(templateRef) {
|
|
17
|
+
this.templateRef = templateRef;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
TimelineCardHeaderTemplateDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: TimelineCardHeaderTemplateDirective, deps: [{ token: i0.TemplateRef, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
21
|
+
TimelineCardHeaderTemplateDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.4", type: TimelineCardHeaderTemplateDirective, selector: "[kendoTimelineCardHeaderTemplate]", ngImport: i0 });
|
|
22
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: TimelineCardHeaderTemplateDirective, decorators: [{
|
|
23
|
+
type: Directive,
|
|
24
|
+
args: [{
|
|
25
|
+
selector: '[kendoTimelineCardHeaderTemplate]'
|
|
26
|
+
}]
|
|
27
|
+
}], ctorParameters: function () { return [{ type: i0.TemplateRef, decorators: [{
|
|
28
|
+
type: Optional
|
|
29
|
+
}] }]; } });
|
|
@@ -0,0 +1,402 @@
|
|
|
1
|
+
/**-----------------------------------------------------------------------------------------
|
|
2
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
3
|
+
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
+
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
import { Component, ElementRef, HostBinding, HostListener, Input, Renderer2, ViewChild } from '@angular/core';
|
|
6
|
+
import { chevronRightIcon } from '@progress/kendo-svg-icons';
|
|
7
|
+
import { Keys, isChanged } from '@progress/kendo-angular-common';
|
|
8
|
+
import { animate, state, style, transition, trigger } from '@angular/animations';
|
|
9
|
+
import { TimelineService } from './timeline.service';
|
|
10
|
+
import { TimelineCardHeaderTemplateDirective } from './templates/timeline-card-header.directive';
|
|
11
|
+
import { TimelineCardBodyTemplateDirective } from './templates/timeline-card-body.directive';
|
|
12
|
+
import { TimelineCardActionsTemplateDirective } from './templates/timeline-card-actions.directive';
|
|
13
|
+
import * as i0 from "@angular/core";
|
|
14
|
+
import * as i1 from "./timeline.service";
|
|
15
|
+
import * as i2 from "@angular/common";
|
|
16
|
+
import * as i3 from "../card/card.component";
|
|
17
|
+
import * as i4 from "../card/card-header.component";
|
|
18
|
+
import * as i5 from "../card/card-body.component";
|
|
19
|
+
import * as i6 from "../card/card-actions.component";
|
|
20
|
+
import * as i7 from "../card/directives/card-title.directive";
|
|
21
|
+
import * as i8 from "../card/directives/card-subtitle.directive";
|
|
22
|
+
import * as i9 from "../card/directives/card-media.directive";
|
|
23
|
+
import * as i10 from "@progress/kendo-angular-buttons";
|
|
24
|
+
/**
|
|
25
|
+
* @hidden
|
|
26
|
+
*/
|
|
27
|
+
export class TimelineCardComponent {
|
|
28
|
+
constructor(element, timelineService, renderer) {
|
|
29
|
+
this.element = element;
|
|
30
|
+
this.timelineService = timelineService;
|
|
31
|
+
this.renderer = renderer;
|
|
32
|
+
this.expanded = false;
|
|
33
|
+
this.collapsible = true;
|
|
34
|
+
this.reversed = false;
|
|
35
|
+
this.hostClass = true;
|
|
36
|
+
this.calloutSvgIcon = chevronRightIcon;
|
|
37
|
+
this.calloutFontIcon = 'arrow-chevron-right';
|
|
38
|
+
this.animationState = this.expanded ? 'expanded' : 'collapsed';
|
|
39
|
+
this.animationInProgress = false;
|
|
40
|
+
}
|
|
41
|
+
set calloutStyle(value) {
|
|
42
|
+
// applies only to horizontal orientation where the callout points upwards
|
|
43
|
+
if (!this.calloutElementRef || !this.calloutElementRef.nativeElement.classList.contains('k-callout-n')) {
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
this.calloutElementRef.nativeElement.style.left = value?.left;
|
|
47
|
+
}
|
|
48
|
+
get collapsedClass() {
|
|
49
|
+
return !this.expanded && !this.animationInProgress && this.animationState === 'collapsed';
|
|
50
|
+
}
|
|
51
|
+
onComponentKeyDown(event) {
|
|
52
|
+
if (!this.navigable) {
|
|
53
|
+
return;
|
|
54
|
+
}
|
|
55
|
+
if (event.keyCode === Keys.Space || event.keyCode === Keys.Enter) {
|
|
56
|
+
event.preventDefault();
|
|
57
|
+
if (this.collapsible && this.orientation === 'vertical') {
|
|
58
|
+
this.expanded = !this.expanded;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
get role() {
|
|
63
|
+
return this.orientation === 'vertical' ? 'button' : 'tabpanel';
|
|
64
|
+
}
|
|
65
|
+
get ariaLive() {
|
|
66
|
+
return this.orientation === 'vertical' ? 'polite' : null;
|
|
67
|
+
}
|
|
68
|
+
get ariaExpanded() {
|
|
69
|
+
return this.orientation === 'vertical' ? this.expanded : null;
|
|
70
|
+
}
|
|
71
|
+
ngAfterViewInit() {
|
|
72
|
+
this.makeOverflowVisible();
|
|
73
|
+
}
|
|
74
|
+
ngOnChanges(changes) {
|
|
75
|
+
if (isChanged('collapsible', changes, false)) {
|
|
76
|
+
if (!this.collapsible) {
|
|
77
|
+
this.expanded = true;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
toggle() {
|
|
82
|
+
if (this.orientation === 'vertical') {
|
|
83
|
+
this.expanded = this.collapsible ? !this.expanded : true;
|
|
84
|
+
this.timelineService.onToggle(this.index);
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
expand() {
|
|
88
|
+
if (!this.expanded) {
|
|
89
|
+
this.expanded = true;
|
|
90
|
+
this.timelineService.onToggle(this.index);
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
collapse() {
|
|
94
|
+
if (!this.collapsible || !this.expanded) {
|
|
95
|
+
return;
|
|
96
|
+
}
|
|
97
|
+
this.expanded = false;
|
|
98
|
+
this.timelineService.onToggle(this.index);
|
|
99
|
+
}
|
|
100
|
+
onActionClick(event) {
|
|
101
|
+
event.stopPropagation();
|
|
102
|
+
this.timelineService.onActionClick(this.index);
|
|
103
|
+
}
|
|
104
|
+
animationStart() {
|
|
105
|
+
this.animationInProgress = true;
|
|
106
|
+
}
|
|
107
|
+
animationDone(event) {
|
|
108
|
+
this.animationInProgress = false;
|
|
109
|
+
if (event.toState === 'expanded' && event.fromState !== 'expanded') {
|
|
110
|
+
this.animationState = 'expanded';
|
|
111
|
+
this.makeOverflowVisible();
|
|
112
|
+
}
|
|
113
|
+
else if (event.toState === 'collapsed' && event.fromState !== 'collapsed') {
|
|
114
|
+
this.animationState = 'collapsed';
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
makeOverflowVisible() {
|
|
118
|
+
if (this.orientation === 'vertical') {
|
|
119
|
+
return;
|
|
120
|
+
}
|
|
121
|
+
const cardBody = this.element?.nativeElement.querySelector('.k-card-body');
|
|
122
|
+
if (cardBody) {
|
|
123
|
+
this.renderer.setStyle(cardBody, 'overflow', 'auto');
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
TimelineCardComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: TimelineCardComponent, deps: [{ token: i0.ElementRef }, { token: i1.TimelineService }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
|
|
128
|
+
TimelineCardComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.4", type: TimelineCardComponent, selector: "kendo-timeline-card", inputs: { event: "event", expanded: "expanded", collapsible: "collapsible", reversed: "reversed", orientation: "orientation", navigable: "navigable", tabIndex: "tabIndex", animationDuration: "animationDuration", index: "index", eventWidth: "eventWidth", eventHeight: "eventHeight", headerTemplate: "headerTemplate", bodyTemplate: "bodyTemplate", actionsTemplate: "actionsTemplate", calloutStyle: "calloutStyle" }, host: { listeners: { "keydown": "onComponentKeyDown($event)" }, properties: { "class.k-timeline-card": "this.hostClass", "class.k-collapsed": "this.collapsedClass" } }, providers: [], viewQueries: [{ propertyName: "calloutElementRef", first: true, predicate: ["callout"], descendants: true }], exportAs: ["kendoTimelineCard"], usesOnChanges: true, ngImport: i0, template: `
|
|
129
|
+
<kendo-card
|
|
130
|
+
[ngStyle]="{ 'height': orientation === 'horizontal' ? eventHeight + 'px' : null }"
|
|
131
|
+
[width]="orientation === 'horizontal' ? 'auto' : eventWidth + 'px'"
|
|
132
|
+
class="k-card-with-callout k-card-vertical"
|
|
133
|
+
(click)="toggle()"
|
|
134
|
+
[attr.role]="role"
|
|
135
|
+
[attr.aria-live]="ariaLive"
|
|
136
|
+
[attr.aria-expanded]="ariaExpanded"
|
|
137
|
+
[attr.tabindex]="tabIndex"
|
|
138
|
+
>
|
|
139
|
+
<span
|
|
140
|
+
#callout
|
|
141
|
+
*ngIf="event"
|
|
142
|
+
class="k-timeline-card-callout k-card-callout"
|
|
143
|
+
[ngClass]="{
|
|
144
|
+
'k-callout-n': orientation === 'horizontal',
|
|
145
|
+
'k-callout-w': orientation === 'vertical' && !this.reversed,
|
|
146
|
+
'k-callout-e': orientation === 'vertical' && this.reversed
|
|
147
|
+
}"
|
|
148
|
+
>
|
|
149
|
+
</span>
|
|
150
|
+
<div *ngIf="event" class="k-card-inner">
|
|
151
|
+
<kendo-card-header>
|
|
152
|
+
<ng-template
|
|
153
|
+
*ngIf="headerTemplate"
|
|
154
|
+
[ngTemplateOutlet]="headerTemplate?.templateRef"
|
|
155
|
+
[ngTemplateOutletContext]="{ $implicit: event, index: index}">
|
|
156
|
+
>
|
|
157
|
+
</ng-template>
|
|
158
|
+
|
|
159
|
+
<div kendoCardTitle *ngIf="!headerTemplate">
|
|
160
|
+
<span class="k-event-title">{{ event.title }}</span>
|
|
161
|
+
<button
|
|
162
|
+
kendoButton
|
|
163
|
+
*ngIf="collapsible && orientation === 'vertical'"
|
|
164
|
+
[icon]="calloutFontIcon"
|
|
165
|
+
[svgIcon]="calloutSvgIcon"
|
|
166
|
+
class="k-event-collapse"
|
|
167
|
+
fillMode="flat"
|
|
168
|
+
[attr.aria-hidden]="true"
|
|
169
|
+
tabindex="-1"
|
|
170
|
+
type="button"
|
|
171
|
+
></button>
|
|
172
|
+
</div>
|
|
173
|
+
<div kendoCardSubtitle *ngIf="!headerTemplate">{{ event.subtitle }}</div>
|
|
174
|
+
</kendo-card-header>
|
|
175
|
+
|
|
176
|
+
<kendo-card-body
|
|
177
|
+
*ngIf="event.description || event.images"
|
|
178
|
+
[@toggle]="{value: expanded ? 'expanded' : 'collapsed', params: {animationDuration: this.animationDuration || 0}}"
|
|
179
|
+
(@toggle.start)="animationStart()"
|
|
180
|
+
(@toggle.done)="animationDone($event)"
|
|
181
|
+
>
|
|
182
|
+
<ng-template
|
|
183
|
+
*ngIf="bodyTemplate"
|
|
184
|
+
[ngTemplateOutlet]="bodyTemplate?.templateRef"
|
|
185
|
+
[ngTemplateOutletContext]="{ $implicit: event, index: index}">
|
|
186
|
+
>
|
|
187
|
+
</ng-template>
|
|
188
|
+
|
|
189
|
+
<div *ngIf="!bodyTemplate" class="k-card-description">
|
|
190
|
+
<p *ngIf="event.description">{{ event.description }}</p>
|
|
191
|
+
<ng-container *ngFor="let image of event.images">
|
|
192
|
+
<img *ngIf="image.alt" kendoCardMedia [src]="image.src" [alt]="image.alt" />
|
|
193
|
+
<img *ngIf="!image.alt" kendoCardMedia [src]="image.src" />
|
|
194
|
+
</ng-container>
|
|
195
|
+
</div>
|
|
196
|
+
</kendo-card-body>
|
|
197
|
+
|
|
198
|
+
<kendo-card-actions
|
|
199
|
+
*ngIf="event.actions"
|
|
200
|
+
[@toggle]="{value: expanded ? 'expanded' : 'collapsed', params: {animationDuration: this.animationDuration || 0}}"
|
|
201
|
+
>
|
|
202
|
+
<ng-template
|
|
203
|
+
*ngIf="actionsTemplate"
|
|
204
|
+
[ngTemplateOutlet]="actionsTemplate?.templateRef"
|
|
205
|
+
[ngTemplateOutletContext]="{ $implicit: event, index: index}">
|
|
206
|
+
>
|
|
207
|
+
</ng-template>
|
|
208
|
+
|
|
209
|
+
<ng-container *ngIf="!actionsTemplate">
|
|
210
|
+
<a *ngFor="let action of event.actions"
|
|
211
|
+
[href]="action.url"
|
|
212
|
+
[target]="action.target === 'blank' ? '_blank' : '_self'"
|
|
213
|
+
(click)="onActionClick($event)"
|
|
214
|
+
class="k-button k-button-md k-rounded-md k-button-flat k-button-flat-primary"
|
|
215
|
+
role="button"
|
|
216
|
+
>
|
|
217
|
+
{{ action.text }}
|
|
218
|
+
</a>
|
|
219
|
+
</ng-container>
|
|
220
|
+
</kendo-card-actions>
|
|
221
|
+
</div>
|
|
222
|
+
</kendo-card>
|
|
223
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: i3.CardComponent, selector: "kendo-card", inputs: ["orientation", "width"] }, { kind: "component", type: i4.CardHeaderComponent, selector: "kendo-card-header" }, { kind: "component", type: i5.CardBodyComponent, selector: "kendo-card-body" }, { kind: "component", type: i6.CardActionsComponent, selector: "kendo-card-actions", inputs: ["orientation", "layout", "actions"], outputs: ["action"] }, { kind: "directive", type: i7.CardTitleDirective, selector: "[kendoCardTitle]" }, { kind: "directive", type: i8.CardSubtitleDirective, selector: "[kendoCardSubtitle]" }, { kind: "directive", type: i9.CardMediaDirective, selector: "[kendoCardMedia]" }, { kind: "component", type: i10.ButtonComponent, selector: "button[kendoButton], span[kendoButton], kendo-button", inputs: ["arrowIcon", "toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }], animations: [
|
|
224
|
+
trigger('toggle', [
|
|
225
|
+
state('collapsed', style({
|
|
226
|
+
height: '0',
|
|
227
|
+
'overflow-y': 'hidden',
|
|
228
|
+
display: 'none'
|
|
229
|
+
})),
|
|
230
|
+
state('expanded', style({
|
|
231
|
+
height: '*',
|
|
232
|
+
'overflow-y': 'hidden',
|
|
233
|
+
display: 'block'
|
|
234
|
+
})),
|
|
235
|
+
transition('collapsed <=> expanded', [
|
|
236
|
+
animate('{{animationDuration}}ms')
|
|
237
|
+
], { params: { animationDuration: '400' } }),
|
|
238
|
+
])
|
|
239
|
+
] });
|
|
240
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.4", ngImport: i0, type: TimelineCardComponent, decorators: [{
|
|
241
|
+
type: Component,
|
|
242
|
+
args: [{
|
|
243
|
+
animations: [
|
|
244
|
+
trigger('toggle', [
|
|
245
|
+
state('collapsed', style({
|
|
246
|
+
height: '0',
|
|
247
|
+
'overflow-y': 'hidden',
|
|
248
|
+
display: 'none'
|
|
249
|
+
})),
|
|
250
|
+
state('expanded', style({
|
|
251
|
+
height: '*',
|
|
252
|
+
'overflow-y': 'hidden',
|
|
253
|
+
display: 'block'
|
|
254
|
+
})),
|
|
255
|
+
transition('collapsed <=> expanded', [
|
|
256
|
+
animate('{{animationDuration}}ms')
|
|
257
|
+
], { params: { animationDuration: '400' } }),
|
|
258
|
+
])
|
|
259
|
+
],
|
|
260
|
+
providers: [],
|
|
261
|
+
exportAs: 'kendoTimelineCard',
|
|
262
|
+
selector: 'kendo-timeline-card',
|
|
263
|
+
template: `
|
|
264
|
+
<kendo-card
|
|
265
|
+
[ngStyle]="{ 'height': orientation === 'horizontal' ? eventHeight + 'px' : null }"
|
|
266
|
+
[width]="orientation === 'horizontal' ? 'auto' : eventWidth + 'px'"
|
|
267
|
+
class="k-card-with-callout k-card-vertical"
|
|
268
|
+
(click)="toggle()"
|
|
269
|
+
[attr.role]="role"
|
|
270
|
+
[attr.aria-live]="ariaLive"
|
|
271
|
+
[attr.aria-expanded]="ariaExpanded"
|
|
272
|
+
[attr.tabindex]="tabIndex"
|
|
273
|
+
>
|
|
274
|
+
<span
|
|
275
|
+
#callout
|
|
276
|
+
*ngIf="event"
|
|
277
|
+
class="k-timeline-card-callout k-card-callout"
|
|
278
|
+
[ngClass]="{
|
|
279
|
+
'k-callout-n': orientation === 'horizontal',
|
|
280
|
+
'k-callout-w': orientation === 'vertical' && !this.reversed,
|
|
281
|
+
'k-callout-e': orientation === 'vertical' && this.reversed
|
|
282
|
+
}"
|
|
283
|
+
>
|
|
284
|
+
</span>
|
|
285
|
+
<div *ngIf="event" class="k-card-inner">
|
|
286
|
+
<kendo-card-header>
|
|
287
|
+
<ng-template
|
|
288
|
+
*ngIf="headerTemplate"
|
|
289
|
+
[ngTemplateOutlet]="headerTemplate?.templateRef"
|
|
290
|
+
[ngTemplateOutletContext]="{ $implicit: event, index: index}">
|
|
291
|
+
>
|
|
292
|
+
</ng-template>
|
|
293
|
+
|
|
294
|
+
<div kendoCardTitle *ngIf="!headerTemplate">
|
|
295
|
+
<span class="k-event-title">{{ event.title }}</span>
|
|
296
|
+
<button
|
|
297
|
+
kendoButton
|
|
298
|
+
*ngIf="collapsible && orientation === 'vertical'"
|
|
299
|
+
[icon]="calloutFontIcon"
|
|
300
|
+
[svgIcon]="calloutSvgIcon"
|
|
301
|
+
class="k-event-collapse"
|
|
302
|
+
fillMode="flat"
|
|
303
|
+
[attr.aria-hidden]="true"
|
|
304
|
+
tabindex="-1"
|
|
305
|
+
type="button"
|
|
306
|
+
></button>
|
|
307
|
+
</div>
|
|
308
|
+
<div kendoCardSubtitle *ngIf="!headerTemplate">{{ event.subtitle }}</div>
|
|
309
|
+
</kendo-card-header>
|
|
310
|
+
|
|
311
|
+
<kendo-card-body
|
|
312
|
+
*ngIf="event.description || event.images"
|
|
313
|
+
[@toggle]="{value: expanded ? 'expanded' : 'collapsed', params: {animationDuration: this.animationDuration || 0}}"
|
|
314
|
+
(@toggle.start)="animationStart()"
|
|
315
|
+
(@toggle.done)="animationDone($event)"
|
|
316
|
+
>
|
|
317
|
+
<ng-template
|
|
318
|
+
*ngIf="bodyTemplate"
|
|
319
|
+
[ngTemplateOutlet]="bodyTemplate?.templateRef"
|
|
320
|
+
[ngTemplateOutletContext]="{ $implicit: event, index: index}">
|
|
321
|
+
>
|
|
322
|
+
</ng-template>
|
|
323
|
+
|
|
324
|
+
<div *ngIf="!bodyTemplate" class="k-card-description">
|
|
325
|
+
<p *ngIf="event.description">{{ event.description }}</p>
|
|
326
|
+
<ng-container *ngFor="let image of event.images">
|
|
327
|
+
<img *ngIf="image.alt" kendoCardMedia [src]="image.src" [alt]="image.alt" />
|
|
328
|
+
<img *ngIf="!image.alt" kendoCardMedia [src]="image.src" />
|
|
329
|
+
</ng-container>
|
|
330
|
+
</div>
|
|
331
|
+
</kendo-card-body>
|
|
332
|
+
|
|
333
|
+
<kendo-card-actions
|
|
334
|
+
*ngIf="event.actions"
|
|
335
|
+
[@toggle]="{value: expanded ? 'expanded' : 'collapsed', params: {animationDuration: this.animationDuration || 0}}"
|
|
336
|
+
>
|
|
337
|
+
<ng-template
|
|
338
|
+
*ngIf="actionsTemplate"
|
|
339
|
+
[ngTemplateOutlet]="actionsTemplate?.templateRef"
|
|
340
|
+
[ngTemplateOutletContext]="{ $implicit: event, index: index}">
|
|
341
|
+
>
|
|
342
|
+
</ng-template>
|
|
343
|
+
|
|
344
|
+
<ng-container *ngIf="!actionsTemplate">
|
|
345
|
+
<a *ngFor="let action of event.actions"
|
|
346
|
+
[href]="action.url"
|
|
347
|
+
[target]="action.target === 'blank' ? '_blank' : '_self'"
|
|
348
|
+
(click)="onActionClick($event)"
|
|
349
|
+
class="k-button k-button-md k-rounded-md k-button-flat k-button-flat-primary"
|
|
350
|
+
role="button"
|
|
351
|
+
>
|
|
352
|
+
{{ action.text }}
|
|
353
|
+
</a>
|
|
354
|
+
</ng-container>
|
|
355
|
+
</kendo-card-actions>
|
|
356
|
+
</div>
|
|
357
|
+
</kendo-card>
|
|
358
|
+
`,
|
|
359
|
+
}]
|
|
360
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1.TimelineService }, { type: i0.Renderer2 }]; }, propDecorators: { event: [{
|
|
361
|
+
type: Input
|
|
362
|
+
}], expanded: [{
|
|
363
|
+
type: Input
|
|
364
|
+
}], collapsible: [{
|
|
365
|
+
type: Input
|
|
366
|
+
}], reversed: [{
|
|
367
|
+
type: Input
|
|
368
|
+
}], orientation: [{
|
|
369
|
+
type: Input
|
|
370
|
+
}], navigable: [{
|
|
371
|
+
type: Input
|
|
372
|
+
}], tabIndex: [{
|
|
373
|
+
type: Input
|
|
374
|
+
}], animationDuration: [{
|
|
375
|
+
type: Input
|
|
376
|
+
}], index: [{
|
|
377
|
+
type: Input
|
|
378
|
+
}], eventWidth: [{
|
|
379
|
+
type: Input
|
|
380
|
+
}], eventHeight: [{
|
|
381
|
+
type: Input
|
|
382
|
+
}], headerTemplate: [{
|
|
383
|
+
type: Input
|
|
384
|
+
}], bodyTemplate: [{
|
|
385
|
+
type: Input
|
|
386
|
+
}], actionsTemplate: [{
|
|
387
|
+
type: Input
|
|
388
|
+
}], calloutStyle: [{
|
|
389
|
+
type: Input
|
|
390
|
+
}], calloutElementRef: [{
|
|
391
|
+
type: ViewChild,
|
|
392
|
+
args: ['callout']
|
|
393
|
+
}], hostClass: [{
|
|
394
|
+
type: HostBinding,
|
|
395
|
+
args: ['class.k-timeline-card']
|
|
396
|
+
}], collapsedClass: [{
|
|
397
|
+
type: HostBinding,
|
|
398
|
+
args: ['class.k-collapsed']
|
|
399
|
+
}], onComponentKeyDown: [{
|
|
400
|
+
type: HostListener,
|
|
401
|
+
args: ['keydown', ['$event']]
|
|
402
|
+
}] } });
|