@progress/kendo-angular-layout 21.4.1 → 22.0.0-develop.1
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/l10n/messages.d.ts +1 -1
- package/fesm2022/progress-kendo-angular-layout.mjs +290 -290
- package/package.json +12 -20
- package/stepper/localization/messages.d.ts +1 -1
- package/tabstrip/localization/messages.d.ts +1 -1
- package/timeline/localization/messages.d.ts +1 -1
- package/esm2022/avatar/avatar.component.mjs +0 -406
- package/esm2022/avatar/l10n/custom-messages.component.mjs +0 -53
- package/esm2022/avatar/l10n/localized-messages.directive.mjs +0 -40
- package/esm2022/avatar/l10n/messages.mjs +0 -27
- package/esm2022/avatar/models/fill.mjs +0 -5
- package/esm2022/avatar/models/models.mjs +0 -9
- package/esm2022/avatar/models/rounded.mjs +0 -5
- package/esm2022/avatar/models/shape.mjs +0 -5
- package/esm2022/avatar/models/size.mjs +0 -5
- package/esm2022/avatar/models/theme-color.mjs +0 -5
- package/esm2022/avatar.module.mjs +0 -38
- package/esm2022/card/card-actions.component.mjs +0 -177
- package/esm2022/card/card-body.component.mjs +0 -37
- package/esm2022/card/card-footer.component.mjs +0 -37
- package/esm2022/card/card-header.component.mjs +0 -38
- package/esm2022/card/card.component.mjs +0 -118
- package/esm2022/card/directives/card-media.directive.mjs +0 -33
- package/esm2022/card/directives/card-separator.directive.mjs +0 -61
- package/esm2022/card/directives/card-subtitle.directive.mjs +0 -31
- package/esm2022/card/directives/card-title.directive.mjs +0 -31
- package/esm2022/card/models/actions-layout.mjs +0 -5
- package/esm2022/card/models/card-action.mjs +0 -21
- package/esm2022/card.module.mjs +0 -45
- package/esm2022/common/direction.mjs +0 -5
- package/esm2022/common/dom-queries.mjs +0 -47
- package/esm2022/common/orientation.mjs +0 -5
- package/esm2022/common/preventable-event.mjs +0 -31
- package/esm2022/common/styling-classes.mjs +0 -5
- package/esm2022/common/util.mjs +0 -85
- package/esm2022/directives.mjs +0 -174
- package/esm2022/drawer/animations.mjs +0 -146
- package/esm2022/drawer/drawer-container.component.mjs +0 -135
- package/esm2022/drawer/drawer-content.component.mjs +0 -39
- package/esm2022/drawer/drawer.component.mjs +0 -471
- package/esm2022/drawer/drawer.service.mjs +0 -105
- package/esm2022/drawer/events/drawer-list-select.event.mjs +0 -29
- package/esm2022/drawer/events/select-event.mjs +0 -33
- package/esm2022/drawer/item.component.mjs +0 -210
- package/esm2022/drawer/list.component.mjs +0 -165
- package/esm2022/drawer/models/constants.mjs +0 -8
- package/esm2022/drawer/models/drawer-animation.interface.mjs +0 -5
- package/esm2022/drawer/models/drawer-item-expand.interface.mjs +0 -5
- package/esm2022/drawer/models/drawer-item.interface.mjs +0 -5
- package/esm2022/drawer/models/drawer-view-item.interface.mjs +0 -5
- package/esm2022/drawer/models/mode.mjs +0 -5
- package/esm2022/drawer/models/position.mjs +0 -5
- package/esm2022/drawer/template-directives/drawer-template.directive.mjs +0 -43
- package/esm2022/drawer/template-directives/footer-template.directive.mjs +0 -36
- package/esm2022/drawer/template-directives/header-template.directive.mjs +0 -36
- package/esm2022/drawer/template-directives/item-template.directive.mjs +0 -44
- package/esm2022/drawer/template-directives.mjs +0 -8
- package/esm2022/drawer/types.mjs +0 -5
- package/esm2022/drawer/util.mjs +0 -16
- package/esm2022/drawer.module.mjs +0 -43
- package/esm2022/expansionpanel/animations.mjs +0 -23
- package/esm2022/expansionpanel/events/action-event.mjs +0 -21
- package/esm2022/expansionpanel/expansionpanel-title.directive.mjs +0 -38
- package/esm2022/expansionpanel/expansionpanel.component.mjs +0 -515
- package/esm2022/expansionpanel.module.mjs +0 -38
- package/esm2022/gridlayout.module.mjs +0 -38
- package/esm2022/index.mjs +0 -89
- package/esm2022/layout.module.mjs +0 -89
- package/esm2022/layouts/grid-layout.component.mjs +0 -179
- package/esm2022/layouts/gridlayout-item.component.mjs +0 -82
- package/esm2022/layouts/models/gridlayout-gap-settings.mjs +0 -5
- package/esm2022/layouts/models/gridlayout-row-col-size.mjs +0 -5
- package/esm2022/layouts/models/layout-align-settings.mjs +0 -5
- package/esm2022/layouts/models/layout-horizontal-align.mjs +0 -5
- package/esm2022/layouts/models/layout-vertical-align.mjs +0 -5
- package/esm2022/layouts/models.mjs +0 -10
- package/esm2022/layouts/stack-layout.component.mjs +0 -161
- package/esm2022/layouts/util.mjs +0 -101
- package/esm2022/package-metadata.mjs +0 -16
- package/esm2022/panelbar/events/collapse-event.mjs +0 -14
- package/esm2022/panelbar/events/expand-event.mjs +0 -14
- package/esm2022/panelbar/events/item-click-event.mjs +0 -17
- package/esm2022/panelbar/events/select-event.mjs +0 -14
- package/esm2022/panelbar/events/state-change-event.mjs +0 -13
- package/esm2022/panelbar/events.mjs +0 -9
- package/esm2022/panelbar/panelbar-content.directive.mjs +0 -36
- package/esm2022/panelbar/panelbar-expand-mode.mjs +0 -29
- package/esm2022/panelbar/panelbar-item-model.mjs +0 -5
- package/esm2022/panelbar/panelbar-item-template.directive.mjs +0 -37
- package/esm2022/panelbar/panelbar-item-title.directive.mjs +0 -42
- package/esm2022/panelbar/panelbar-item.component.mjs +0 -722
- package/esm2022/panelbar/panelbar.component.mjs +0 -705
- package/esm2022/panelbar/panelbar.service.mjs +0 -53
- package/esm2022/panelbar.module.mjs +0 -41
- package/esm2022/progress-kendo-angular-layout.mjs +0 -8
- package/esm2022/splitter/splitter-bar.component.mjs +0 -338
- package/esm2022/splitter/splitter-pane.component.mjs +0 -324
- package/esm2022/splitter/splitter.component.mjs +0 -301
- package/esm2022/splitter/splitter.service.mjs +0 -205
- package/esm2022/splitter/util.mjs +0 -34
- package/esm2022/splitter.module.mjs +0 -38
- package/esm2022/stacklayout.module.mjs +0 -37
- package/esm2022/stepper/events/activate-event.mjs +0 -33
- package/esm2022/stepper/list.component.mjs +0 -185
- package/esm2022/stepper/localization/custom-messages.component.mjs +0 -52
- package/esm2022/stepper/localization/localized-messages.directive.mjs +0 -41
- package/esm2022/stepper/localization/messages.mjs +0 -27
- package/esm2022/stepper/models/constants.mjs +0 -8
- package/esm2022/stepper/models/orientation.mjs +0 -5
- package/esm2022/stepper/models/step-predicate.mjs +0 -5
- package/esm2022/stepper/models/step-type.mjs +0 -5
- package/esm2022/stepper/models/stepper-step.interface.mjs +0 -5
- package/esm2022/stepper/step.component.mjs +0 -396
- package/esm2022/stepper/stepper.component.mjs +0 -423
- package/esm2022/stepper/stepper.service.mjs +0 -186
- package/esm2022/stepper/template-directives/indicator-template.directive.mjs +0 -37
- package/esm2022/stepper/template-directives/label-template.directive.mjs +0 -37
- package/esm2022/stepper/template-directives/step-template.directive.mjs +0 -39
- package/esm2022/stepper/template-directives.mjs +0 -7
- package/esm2022/stepper/types.mjs +0 -5
- package/esm2022/stepper.module.mjs +0 -41
- package/esm2022/tabstrip/constants.mjs +0 -29
- package/esm2022/tabstrip/directives/tab-content.directive.mjs +0 -39
- package/esm2022/tabstrip/directives/tab-title.directive.mjs +0 -37
- package/esm2022/tabstrip/directives/tab.directive.mjs +0 -24
- package/esm2022/tabstrip/events/select-event.mjs +0 -25
- package/esm2022/tabstrip/events/tabclose-event.mjs +0 -23
- package/esm2022/tabstrip/events/tabscroll-event.mjs +0 -23
- package/esm2022/tabstrip/events.mjs +0 -7
- package/esm2022/tabstrip/localization/custom-messages.component.mjs +0 -53
- package/esm2022/tabstrip/localization/localized-messages.directive.mjs +0 -39
- package/esm2022/tabstrip/localization/messages.mjs +0 -39
- package/esm2022/tabstrip/models/button-state-change.mjs +0 -5
- package/esm2022/tabstrip/models/scroll-button-type.mjs +0 -5
- package/esm2022/tabstrip/models/scroll-buttons-visibility.mjs +0 -5
- package/esm2022/tabstrip/models/scrollable-settings.mjs +0 -23
- package/esm2022/tabstrip/models/size.mjs +0 -5
- package/esm2022/tabstrip/models/tab-alignment.mjs +0 -5
- package/esm2022/tabstrip/models/tab-position.mjs +0 -5
- package/esm2022/tabstrip/models/tabstrip-tab.component.mjs +0 -130
- package/esm2022/tabstrip/rendering/tab.component.mjs +0 -182
- package/esm2022/tabstrip/scrollable-button.component.mjs +0 -182
- package/esm2022/tabstrip/tabstrip-scroll.service.mjs +0 -176
- package/esm2022/tabstrip/tabstrip.component.mjs +0 -954
- package/esm2022/tabstrip/tabstrip.service.mjs +0 -155
- package/esm2022/tabstrip/util.mjs +0 -120
- package/esm2022/tabstrip.module.mjs +0 -41
- package/esm2022/tilelayout/constants.mjs +0 -70
- package/esm2022/tilelayout/dragging-service.mjs +0 -421
- package/esm2022/tilelayout/keyboard-navigation.service.mjs +0 -189
- package/esm2022/tilelayout/models/dragging-config.interface.mjs +0 -5
- package/esm2022/tilelayout/models/flowmode.type.mjs +0 -5
- package/esm2022/tilelayout/models/gap.interface.mjs +0 -5
- package/esm2022/tilelayout/models/navigation.interface.mjs +0 -5
- package/esm2022/tilelayout/reorder-event.mjs +0 -43
- package/esm2022/tilelayout/resize-event.mjs +0 -37
- package/esm2022/tilelayout/tilelayout-item-body.component.mjs +0 -45
- package/esm2022/tilelayout/tilelayout-item-header.component.mjs +0 -43
- package/esm2022/tilelayout/tilelayout-item.component.mjs +0 -322
- package/esm2022/tilelayout/tilelayout-resize-handle.directive.mjs +0 -61
- package/esm2022/tilelayout/tilelayout.component.mjs +0 -388
- package/esm2022/tilelayout/util.mjs +0 -138
- package/esm2022/tilelayout.module.mjs +0 -40
- package/esm2022/timeline/events/navigation-direction.mjs +0 -5
- package/esm2022/timeline/localization/custom-messages.component.mjs +0 -43
- package/esm2022/timeline/localization/localized-messages.directive.mjs +0 -39
- package/esm2022/timeline/localization/messages.mjs +0 -33
- package/esm2022/timeline/models/anchor-target.mjs +0 -5
- package/esm2022/timeline/models/default-model-fields.mjs +0 -16
- package/esm2022/timeline/models/events-order.mjs +0 -5
- package/esm2022/timeline/models/model-fields.mjs +0 -5
- package/esm2022/timeline/models/timeline-event.mjs +0 -5
- package/esm2022/timeline/templates/timeline-card-actions.directive.mjs +0 -40
- package/esm2022/timeline/templates/timeline-card-body.directive.mjs +0 -40
- package/esm2022/timeline/templates/timeline-card-header.directive.mjs +0 -41
- package/esm2022/timeline/timeline-card.component.mjs +0 -451
- package/esm2022/timeline/timeline-horizontal.component.mjs +0 -781
- package/esm2022/timeline/timeline-vertical.component.mjs +0 -203
- package/esm2022/timeline/timeline.component.mjs +0 -491
- package/esm2022/timeline/timeline.service.mjs +0 -32
- package/esm2022/timeline/util.mjs +0 -26
- package/esm2022/timeline.module.mjs +0 -41
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { Injectable } from '@angular/core';
|
|
6
|
-
import { BehaviorSubject, Subject } from 'rxjs';
|
|
7
|
-
import * as i0 from "@angular/core";
|
|
8
|
-
/**
|
|
9
|
-
* @hidden
|
|
10
|
-
*/
|
|
11
|
-
let nextPanelbarId = 0;
|
|
12
|
-
/**
|
|
13
|
-
* @hidden
|
|
14
|
-
*/
|
|
15
|
-
export class PanelBarService {
|
|
16
|
-
children$;
|
|
17
|
-
keepContent$;
|
|
18
|
-
parent$;
|
|
19
|
-
pbId;
|
|
20
|
-
animate;
|
|
21
|
-
expandMode;
|
|
22
|
-
itemClick;
|
|
23
|
-
childSource;
|
|
24
|
-
keepContentSource;
|
|
25
|
-
parentSource;
|
|
26
|
-
onKeepContent(keepContent) {
|
|
27
|
-
this.keepContentSource.next(keepContent);
|
|
28
|
-
}
|
|
29
|
-
onSelect(event) {
|
|
30
|
-
this.childSource.next(event);
|
|
31
|
-
}
|
|
32
|
-
onFocus() {
|
|
33
|
-
this.parentSource.next(true);
|
|
34
|
-
}
|
|
35
|
-
onBlur() {
|
|
36
|
-
this.parentSource.next(false);
|
|
37
|
-
}
|
|
38
|
-
constructor() {
|
|
39
|
-
this.parentSource = new Subject();
|
|
40
|
-
this.keepContentSource = new BehaviorSubject(false);
|
|
41
|
-
this.childSource = new Subject();
|
|
42
|
-
this.itemClick = new Subject();
|
|
43
|
-
this.parent$ = this.parentSource.asObservable();
|
|
44
|
-
this.children$ = this.childSource.asObservable();
|
|
45
|
-
this.keepContent$ = this.keepContentSource.asObservable();
|
|
46
|
-
this.pbId = nextPanelbarId++;
|
|
47
|
-
}
|
|
48
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: PanelBarService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
49
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: PanelBarService });
|
|
50
|
-
}
|
|
51
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: PanelBarService, decorators: [{
|
|
52
|
-
type: Injectable
|
|
53
|
-
}], ctorParameters: () => [] });
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
import { NgModule } from '@angular/core';
|
|
6
|
-
import { KENDO_PANELBAR } from './directives';
|
|
7
|
-
import * as i0 from "@angular/core";
|
|
8
|
-
import * as i1 from "./panelbar/panelbar.component";
|
|
9
|
-
import * as i2 from "./panelbar/panelbar-item.component";
|
|
10
|
-
import * as i3 from "./panelbar/panelbar-content.directive";
|
|
11
|
-
import * as i4 from "./panelbar/panelbar-item-template.directive";
|
|
12
|
-
import * as i5 from "./panelbar/panelbar-item-title.directive";
|
|
13
|
-
// IMPORTANT: NgModule export kept for backwards compatibility
|
|
14
|
-
/**
|
|
15
|
-
* Defines the [`NgModule`](link:site.data.urls.angular['ngmoduleapi']) for the PanelBar component.
|
|
16
|
-
*
|
|
17
|
-
* Use this module to add the PanelBar component to your NgModule-based Angular application.
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* ```typescript
|
|
21
|
-
* import { PanelBarModule } from '@progress/kendo-angular-layout';
|
|
22
|
-
* import { NgModule } from '@angular/core';
|
|
23
|
-
*
|
|
24
|
-
* @NgModule({
|
|
25
|
-
* imports: [PanelBarModule]
|
|
26
|
-
* })
|
|
27
|
-
* export class AppModule { }
|
|
28
|
-
* ```
|
|
29
|
-
*/
|
|
30
|
-
export class PanelBarModule {
|
|
31
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: PanelBarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
32
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.14", ngImport: i0, type: PanelBarModule, imports: [i1.PanelBarComponent, i2.PanelBarItemComponent, i3.PanelBarContentDirective, i4.PanelBarItemTemplateDirective, i5.PanelBarItemTitleDirective], exports: [i1.PanelBarComponent, i2.PanelBarItemComponent, i3.PanelBarContentDirective, i4.PanelBarItemTemplateDirective, i5.PanelBarItemTitleDirective] });
|
|
33
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: PanelBarModule, imports: [i1.PanelBarComponent, i2.PanelBarItemComponent] });
|
|
34
|
-
}
|
|
35
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: PanelBarModule, decorators: [{
|
|
36
|
-
type: NgModule,
|
|
37
|
-
args: [{
|
|
38
|
-
exports: [...KENDO_PANELBAR],
|
|
39
|
-
imports: [...KENDO_PANELBAR]
|
|
40
|
-
}]
|
|
41
|
-
}] });
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
/**
|
|
6
|
-
* Generated bundle index. Do not edit.
|
|
7
|
-
*/
|
|
8
|
-
export * from './index';
|
|
@@ -1,338 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2026 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
6
|
-
import { ChangeDetectorRef, Component, ElementRef, Host, HostBinding, Input, Renderer2 } from '@angular/core';
|
|
7
|
-
import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
8
|
-
import { DraggableDirective, Keys, isObjectPresent, normalizeKeys, parseAttributes, removeHTMLAttributes, setHTMLAttributes } from '@progress/kendo-angular-common';
|
|
9
|
-
import { SplitterService } from './splitter.service';
|
|
10
|
-
import { Subscription, of } from 'rxjs';
|
|
11
|
-
import { delay, filter, map, switchMap, takeUntil, tap } from 'rxjs/operators';
|
|
12
|
-
import { shouldToggleOrResize } from './util';
|
|
13
|
-
import { caretAltDownIcon, caretAltLeftIcon, caretAltRightIcon, caretAltUpIcon } from '@progress/kendo-svg-icons';
|
|
14
|
-
import { IconWrapperComponent } from '@progress/kendo-angular-icons';
|
|
15
|
-
import * as i0 from "@angular/core";
|
|
16
|
-
import * as i1 from "@progress/kendo-angular-common";
|
|
17
|
-
import * as i2 from "@progress/kendo-angular-l10n";
|
|
18
|
-
import * as i3 from "./splitter.service";
|
|
19
|
-
const stopPropagation = ({ originalEvent: event }) => {
|
|
20
|
-
event.stopPropagation();
|
|
21
|
-
event.preventDefault();
|
|
22
|
-
};
|
|
23
|
-
const preventOnDblClick = release => mouseDown => of(mouseDown).pipe(delay(150), takeUntil(release));
|
|
24
|
-
const classFromObject = classes => Object.keys(classes).filter(c => classes[c]).join(' ');
|
|
25
|
-
const createMoveStream = (draggable) => mouseDown => draggable.kendoDrag
|
|
26
|
-
.pipe(takeUntil(draggable.kendoRelease), map(({ pageX, pageY }) => ({
|
|
27
|
-
originalX: mouseDown.pageX,
|
|
28
|
-
originalY: mouseDown.pageY,
|
|
29
|
-
pageX,
|
|
30
|
-
pageY
|
|
31
|
-
})));
|
|
32
|
-
/**
|
|
33
|
-
* @hidden
|
|
34
|
-
*/
|
|
35
|
-
export class SplitterBarComponent {
|
|
36
|
-
draggable;
|
|
37
|
-
localization;
|
|
38
|
-
splitterService;
|
|
39
|
-
element;
|
|
40
|
-
renderer;
|
|
41
|
-
cdr;
|
|
42
|
-
ariaRole = 'separator';
|
|
43
|
-
ariaLabel = 'Splitter pane';
|
|
44
|
-
focused = false;
|
|
45
|
-
get hostOrientation() {
|
|
46
|
-
return this.orientation === 'horizontal' ? 'vertical' : 'horizontal';
|
|
47
|
-
}
|
|
48
|
-
get tabIndex() {
|
|
49
|
-
return this.splitterService.isStatic(this.index) ? -1 : 0;
|
|
50
|
-
}
|
|
51
|
-
get hostClasses() {
|
|
52
|
-
const isHorizontal = this.orientation === 'horizontal';
|
|
53
|
-
const isDraggable = this.splitterService.isDraggable(this.index);
|
|
54
|
-
const isStatic = this.splitterService.isStatic(this.index);
|
|
55
|
-
return classFromObject({
|
|
56
|
-
'k-focus': this.focused,
|
|
57
|
-
'k-splitbar': true,
|
|
58
|
-
'k-splitbar-horizontal': isHorizontal,
|
|
59
|
-
'k-splitbar-vertical': !isHorizontal,
|
|
60
|
-
'k-splitbar-draggable-horizontal': isHorizontal && isDraggable,
|
|
61
|
-
'k-splitbar-draggable-vertical': !isHorizontal && isDraggable,
|
|
62
|
-
'k-splitbar-static-horizontal': isHorizontal && isStatic,
|
|
63
|
-
'k-splitbar-static-vertical': !isHorizontal && isStatic,
|
|
64
|
-
'k-touch-action-none': isDraggable
|
|
65
|
-
});
|
|
66
|
-
}
|
|
67
|
-
get order() {
|
|
68
|
-
return 2 * this.index + 1;
|
|
69
|
-
}
|
|
70
|
-
orientation = 'horizontal';
|
|
71
|
-
index = 0;
|
|
72
|
-
set htmlAttributes(attributes) {
|
|
73
|
-
if (isObjectPresent(this.parsedAttributes)) {
|
|
74
|
-
removeHTMLAttributes(this.parsedAttributes, this.renderer, this.element.nativeElement);
|
|
75
|
-
}
|
|
76
|
-
this._htmlAttributes = attributes;
|
|
77
|
-
this.parsedAttributes = this.htmlAttributes ?
|
|
78
|
-
parseAttributes(this.htmlAttributes, this.defaultAttributes) :
|
|
79
|
-
this.htmlAttributes;
|
|
80
|
-
this.setHtmlAttributes();
|
|
81
|
-
}
|
|
82
|
-
get htmlAttributes() {
|
|
83
|
-
return this._htmlAttributes;
|
|
84
|
-
}
|
|
85
|
-
subscriptions = new Subscription();
|
|
86
|
-
_htmlAttributes;
|
|
87
|
-
parsedAttributes = {};
|
|
88
|
-
get defaultAttributes() {
|
|
89
|
-
return {
|
|
90
|
-
'aria-orientation': this.hostOrientation,
|
|
91
|
-
role: this.ariaRole
|
|
92
|
-
};
|
|
93
|
-
}
|
|
94
|
-
get mutableAttributes() {
|
|
95
|
-
return { 'tabindex': this.tabIndex };
|
|
96
|
-
}
|
|
97
|
-
constructor(draggable, localization, splitterService, element, renderer, cdr) {
|
|
98
|
-
this.draggable = draggable;
|
|
99
|
-
this.localization = localization;
|
|
100
|
-
this.splitterService = splitterService;
|
|
101
|
-
this.element = element;
|
|
102
|
-
this.renderer = renderer;
|
|
103
|
-
this.cdr = cdr;
|
|
104
|
-
}
|
|
105
|
-
ngOnInit() {
|
|
106
|
-
let state;
|
|
107
|
-
const listener = this.draggable.kendoPress.pipe(tap(stopPropagation), filter(() => this.splitterService.isDraggable(this.index)), tap(() => state = this.splitterService.dragState(this.index)), tap(() => this.splitterService.toggleContentOverlay(this.index, true)), switchMap(preventOnDblClick(this.draggable.kendoRelease)), switchMap(createMoveStream(this.draggable))).subscribe(({ pageX, pageY, originalX, originalY }) => {
|
|
108
|
-
let delta;
|
|
109
|
-
if (this.orientation === 'vertical') {
|
|
110
|
-
delta = pageY - originalY;
|
|
111
|
-
}
|
|
112
|
-
else if (this.direction === 'rtl') {
|
|
113
|
-
delta = originalX - pageX;
|
|
114
|
-
}
|
|
115
|
-
else {
|
|
116
|
-
delta = pageX - originalX;
|
|
117
|
-
}
|
|
118
|
-
this.splitterService.setSize(state, delta);
|
|
119
|
-
});
|
|
120
|
-
this.subscriptions.add(listener);
|
|
121
|
-
this.subscriptions.add(this.draggable.kendoRelease.subscribe(() => this.splitterService.toggleContentOverlay(this.index, false)));
|
|
122
|
-
const element = this.element.nativeElement;
|
|
123
|
-
this.subscriptions.add(this.renderer.listen(element, 'keydown', event => this.onKeyDown(event)));
|
|
124
|
-
this.subscriptions.add(this.renderer.listen(element, 'focusin', () => this.focused = true));
|
|
125
|
-
this.subscriptions.add(this.renderer.listen(element, 'focusout', () => this.focused = false));
|
|
126
|
-
this.subscriptions.add(this.renderer.listen(element, 'dblclick', () => this.togglePane()));
|
|
127
|
-
}
|
|
128
|
-
ngOnDestroy() {
|
|
129
|
-
if (this.subscriptions) {
|
|
130
|
-
this.subscriptions.unsubscribe();
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
togglePrevious() {
|
|
134
|
-
this.splitterService.tryToggle(this.index);
|
|
135
|
-
}
|
|
136
|
-
toggleNext() {
|
|
137
|
-
this.splitterService.tryToggle(this.index + 1);
|
|
138
|
-
}
|
|
139
|
-
get direction() {
|
|
140
|
-
return this.localization.rtl ? 'rtl' : 'ltr';
|
|
141
|
-
}
|
|
142
|
-
shouldShowIcon(iconName) {
|
|
143
|
-
const paneIndex = iconName === 'prev' ? this.index : this.index + 1;
|
|
144
|
-
const relatedPaneIndex = iconName === 'prev' ? this.index + 1 : this.index;
|
|
145
|
-
const pane = this.splitterService.pane(paneIndex);
|
|
146
|
-
const relatedPane = this.splitterService.pane(relatedPaneIndex);
|
|
147
|
-
const isCollapsible = pane?.collapsible;
|
|
148
|
-
return isCollapsible && !relatedPane?.isHidden;
|
|
149
|
-
}
|
|
150
|
-
previousArrowClass() {
|
|
151
|
-
const pane = this.splitterService.pane(this.index);
|
|
152
|
-
const isCollapsible = pane?.collapsible;
|
|
153
|
-
const isCollapsed = pane?.collapsed;
|
|
154
|
-
const isHorizontal = this.orientation === 'horizontal';
|
|
155
|
-
const isRTL = this.direction === 'rtl';
|
|
156
|
-
return classFromObject({
|
|
157
|
-
'caret-alt-left': isCollapsible && isHorizontal && ((!isCollapsed && !isRTL) || (isCollapsed && isRTL)),
|
|
158
|
-
'caret-alt-right': isCollapsible && isHorizontal && ((isCollapsed && !isRTL) || (!isCollapsed && isRTL)),
|
|
159
|
-
'caret-alt-up': isCollapsible && !isHorizontal && !isCollapsed,
|
|
160
|
-
'caret-alt-down': isCollapsible && !isHorizontal && isCollapsed
|
|
161
|
-
});
|
|
162
|
-
}
|
|
163
|
-
previousSVGArrowClass() {
|
|
164
|
-
const pane = this.splitterService.pane(this.index);
|
|
165
|
-
const isCollapsible = pane?.collapsible;
|
|
166
|
-
const isCollapsed = pane?.collapsed;
|
|
167
|
-
const isHorizontal = this.orientation === 'horizontal';
|
|
168
|
-
const isRTL = this.direction === 'rtl';
|
|
169
|
-
if (isCollapsible && isHorizontal && ((!isCollapsed && !isRTL) || (isCollapsed && isRTL))) {
|
|
170
|
-
return caretAltLeftIcon;
|
|
171
|
-
}
|
|
172
|
-
if (isCollapsible && isHorizontal && ((isCollapsed && !isRTL) || (!isCollapsed && isRTL))) {
|
|
173
|
-
return caretAltRightIcon;
|
|
174
|
-
}
|
|
175
|
-
if (isCollapsible && !isHorizontal && !isCollapsed) {
|
|
176
|
-
return caretAltUpIcon;
|
|
177
|
-
}
|
|
178
|
-
if (isCollapsible && !isHorizontal && isCollapsed) {
|
|
179
|
-
return caretAltDownIcon;
|
|
180
|
-
}
|
|
181
|
-
}
|
|
182
|
-
nextArrowClass() {
|
|
183
|
-
const pane = this.splitterService.pane(this.index + 1);
|
|
184
|
-
const isCollapsible = pane?.collapsible;
|
|
185
|
-
const isCollapsed = pane?.collapsed;
|
|
186
|
-
const isHorizontal = this.orientation === 'horizontal';
|
|
187
|
-
const isRTL = this.direction === 'rtl';
|
|
188
|
-
return classFromObject({
|
|
189
|
-
'caret-alt-right': isCollapsible && isHorizontal && ((!isCollapsed && !isRTL) || (isCollapsed && isRTL)),
|
|
190
|
-
'caret-alt-left': isCollapsible && isHorizontal && ((isCollapsed && !isRTL) || (!isCollapsed && isRTL)),
|
|
191
|
-
'caret-alt-down': isCollapsible && !isHorizontal && !isCollapsed,
|
|
192
|
-
'caret-alt-up': isCollapsible && !isHorizontal && isCollapsed
|
|
193
|
-
});
|
|
194
|
-
}
|
|
195
|
-
nextSVGArrowClass() {
|
|
196
|
-
const pane = this.splitterService.pane(this.index + 1);
|
|
197
|
-
const isCollapsible = pane?.collapsible;
|
|
198
|
-
const isCollapsed = pane?.collapsed;
|
|
199
|
-
const isHorizontal = this.orientation === 'horizontal';
|
|
200
|
-
const isRTL = this.direction === 'rtl';
|
|
201
|
-
if (isCollapsible && isHorizontal && ((!isCollapsed && !isRTL) || (isCollapsed && isRTL))) {
|
|
202
|
-
return caretAltRightIcon;
|
|
203
|
-
}
|
|
204
|
-
if (isCollapsible && isHorizontal && ((isCollapsed && !isRTL) || (!isCollapsed && isRTL))) {
|
|
205
|
-
return caretAltLeftIcon;
|
|
206
|
-
}
|
|
207
|
-
if (isCollapsible && !isHorizontal && !isCollapsed) {
|
|
208
|
-
return caretAltDownIcon;
|
|
209
|
-
}
|
|
210
|
-
if (isCollapsible && !isHorizontal && isCollapsed) {
|
|
211
|
-
return caretAltUpIcon;
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
togglePane() {
|
|
215
|
-
if (this.expandLast) {
|
|
216
|
-
this.toggleNext();
|
|
217
|
-
}
|
|
218
|
-
else {
|
|
219
|
-
this.tryToggleNearest();
|
|
220
|
-
}
|
|
221
|
-
this.cdr.markForCheck();
|
|
222
|
-
}
|
|
223
|
-
get expandLast() {
|
|
224
|
-
const panes = this.splitterService.panes;
|
|
225
|
-
return panes.length === 2 && panes[1].collapsed;
|
|
226
|
-
}
|
|
227
|
-
onKeyDown(event) {
|
|
228
|
-
const keyCode = normalizeKeys(event);
|
|
229
|
-
const shouldToggle = event.ctrlKey || event.metaKey;
|
|
230
|
-
if (keyCode === Keys.Enter || keyCode === Keys.NumpadEnter) {
|
|
231
|
-
event.preventDefault();
|
|
232
|
-
this.togglePane();
|
|
233
|
-
}
|
|
234
|
-
else if (shouldToggleOrResize(keyCode, this.orientation)) {
|
|
235
|
-
event.preventDefault();
|
|
236
|
-
if (shouldToggle) {
|
|
237
|
-
this.splitterService.togglePane(keyCode, this.index);
|
|
238
|
-
}
|
|
239
|
-
else {
|
|
240
|
-
this.splitterService.resizePane(keyCode, this.index);
|
|
241
|
-
}
|
|
242
|
-
}
|
|
243
|
-
}
|
|
244
|
-
tryToggleNearest() {
|
|
245
|
-
const prev = this.index;
|
|
246
|
-
const next = this.index + 1;
|
|
247
|
-
if (!this.splitterService.tryToggle(prev)) {
|
|
248
|
-
this.splitterService.tryToggle(next);
|
|
249
|
-
}
|
|
250
|
-
}
|
|
251
|
-
setHtmlAttributes() {
|
|
252
|
-
const attributesToRender = { ...this.mutableAttributes, ...this.parsedAttributes };
|
|
253
|
-
setHTMLAttributes(attributesToRender, this.renderer, this.element.nativeElement);
|
|
254
|
-
}
|
|
255
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SplitterBarComponent, deps: [{ token: i1.DraggableDirective, host: true }, { token: i2.LocalizationService }, { token: i3.SplitterService }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
256
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: SplitterBarComponent, isStandalone: true, selector: "kendo-splitter-bar", inputs: { orientation: "orientation", index: "index", htmlAttributes: "htmlAttributes" }, host: { properties: { "attr.role": "this.ariaRole", "attr.aria-label": "this.ariaLabel", "class.k-focus": "this.focused", "attr.aria-orientation": "this.hostOrientation", "attr.tabindex": "this.tabIndex", "class": "this.hostClasses", "style.-ms-flex-order": "this.order", "style.order": "this.order" } }, ngImport: i0, template: `
|
|
257
|
-
@if (shouldShowIcon('prev')) {
|
|
258
|
-
<div class="k-collapse-prev" (click)="togglePrevious()">
|
|
259
|
-
<kendo-icon-wrapper
|
|
260
|
-
size="xsmall"
|
|
261
|
-
[name]="previousArrowClass()"
|
|
262
|
-
[svgIcon]="previousSVGArrowClass()"
|
|
263
|
-
></kendo-icon-wrapper>
|
|
264
|
-
</div>
|
|
265
|
-
}
|
|
266
|
-
<div class="k-resize-handle"></div>
|
|
267
|
-
@if (shouldShowIcon('next')) {
|
|
268
|
-
<div class="k-collapse-next" (click)="toggleNext()">
|
|
269
|
-
<kendo-icon-wrapper
|
|
270
|
-
size="xsmall"
|
|
271
|
-
[name]="nextArrowClass()"
|
|
272
|
-
[svgIcon]="nextSVGArrowClass()"
|
|
273
|
-
></kendo-icon-wrapper>
|
|
274
|
-
</div>
|
|
275
|
-
}
|
|
276
|
-
`, isInline: true, dependencies: [{ kind: "component", type: IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass", "size"], exportAs: ["kendoIconWrapper"] }] });
|
|
277
|
-
}
|
|
278
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: SplitterBarComponent, decorators: [{
|
|
279
|
-
type: Component,
|
|
280
|
-
args: [{
|
|
281
|
-
selector: 'kendo-splitter-bar',
|
|
282
|
-
template: `
|
|
283
|
-
@if (shouldShowIcon('prev')) {
|
|
284
|
-
<div class="k-collapse-prev" (click)="togglePrevious()">
|
|
285
|
-
<kendo-icon-wrapper
|
|
286
|
-
size="xsmall"
|
|
287
|
-
[name]="previousArrowClass()"
|
|
288
|
-
[svgIcon]="previousSVGArrowClass()"
|
|
289
|
-
></kendo-icon-wrapper>
|
|
290
|
-
</div>
|
|
291
|
-
}
|
|
292
|
-
<div class="k-resize-handle"></div>
|
|
293
|
-
@if (shouldShowIcon('next')) {
|
|
294
|
-
<div class="k-collapse-next" (click)="toggleNext()">
|
|
295
|
-
<kendo-icon-wrapper
|
|
296
|
-
size="xsmall"
|
|
297
|
-
[name]="nextArrowClass()"
|
|
298
|
-
[svgIcon]="nextSVGArrowClass()"
|
|
299
|
-
></kendo-icon-wrapper>
|
|
300
|
-
</div>
|
|
301
|
-
}
|
|
302
|
-
`,
|
|
303
|
-
standalone: true,
|
|
304
|
-
imports: [IconWrapperComponent]
|
|
305
|
-
}]
|
|
306
|
-
}], ctorParameters: () => [{ type: i1.DraggableDirective, decorators: [{
|
|
307
|
-
type: Host
|
|
308
|
-
}] }, { type: i2.LocalizationService }, { type: i3.SplitterService }, { type: i0.ElementRef }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }], propDecorators: { ariaRole: [{
|
|
309
|
-
type: HostBinding,
|
|
310
|
-
args: ['attr.role']
|
|
311
|
-
}], ariaLabel: [{
|
|
312
|
-
type: HostBinding,
|
|
313
|
-
args: ['attr.aria-label']
|
|
314
|
-
}], focused: [{
|
|
315
|
-
type: HostBinding,
|
|
316
|
-
args: ['class.k-focus']
|
|
317
|
-
}], hostOrientation: [{
|
|
318
|
-
type: HostBinding,
|
|
319
|
-
args: ['attr.aria-orientation']
|
|
320
|
-
}], tabIndex: [{
|
|
321
|
-
type: HostBinding,
|
|
322
|
-
args: ['attr.tabindex']
|
|
323
|
-
}], hostClasses: [{
|
|
324
|
-
type: HostBinding,
|
|
325
|
-
args: ['class']
|
|
326
|
-
}], order: [{
|
|
327
|
-
type: HostBinding,
|
|
328
|
-
args: ['style.-ms-flex-order']
|
|
329
|
-
}, {
|
|
330
|
-
type: HostBinding,
|
|
331
|
-
args: ['style.order']
|
|
332
|
-
}], orientation: [{
|
|
333
|
-
type: Input
|
|
334
|
-
}], index: [{
|
|
335
|
-
type: Input
|
|
336
|
-
}], htmlAttributes: [{
|
|
337
|
-
type: Input
|
|
338
|
-
}] } });
|