UNPKG

devextreme-angular

Version:

DevExtreme UI and Visualization Components for Angular

379 lines (361 loc) 15.1 kB
import * as i0 from '@angular/core'; import { PLATFORM_ID, Output, Input, ContentChildren, Inject, Component, NgModule } from '@angular/core'; import DxSplitter from 'devextreme/ui/splitter'; import * as i1 from 'devextreme-angular/core'; import { DxComponent, DxIntegrationModule, DxTemplateHost, WatcherHelper, NestedOptionHost, IterableDifferHelper, DxTemplateModule } from 'devextreme-angular/core'; import { DxiItemModule, DxoSplitterModule } from 'devextreme-angular/ui/nested'; import { DxiSplitterItemModule } from 'devextreme-angular/ui/splitter/nested'; export * from 'devextreme-angular/ui/splitter/nested'; import { PROPERTY_TOKEN_items } from 'devextreme-angular/core/tokens'; /*! * devextreme-angular * Version: 26.1.3 * Build date: Wed Jun 10 2026 * * Copyright (c) 2012 - 2026 Developer Express Inc. ALL RIGHTS RESERVED * * This software may be modified and distributed under the terms * of the MIT license. See the LICENSE file in the root of the project for details. * * https://github.com/DevExpress/DevExtreme */ /* tslint:disable:max-line-length */ /** * Splitter is a UI component that allows you to divide a page or section into multiple adjustable panes. */ class DxSplitterComponent extends DxComponent { set _itemsContentChildren(value) { this.setChildren('items', value); } /** * Specifies whether to allow the Splitter to take focus and allow keyboard navigation. */ get allowKeyboardNavigation() { return this._getOption('allowKeyboardNavigation'); } set allowKeyboardNavigation(value) { this._setOption('allowKeyboardNavigation', value); } /** * Binds the UI component to data. */ get dataSource() { return this._getOption('dataSource'); } set dataSource(value) { this._setOption('dataSource', value); } /** * Specifies whether the UI component responds to user interaction. */ get disabled() { return this._getOption('disabled'); } set disabled(value) { this._setOption('disabled', value); } /** * Specifies the global attributes to be attached to the UI component's container element. */ get elementAttr() { return this._getOption('elementAttr'); } set elementAttr(value) { this._setOption('elementAttr', value); } /** * Specifies the UI component's height. */ get height() { return this._getOption('height'); } set height(value) { this._setOption('height', value); } /** * Specifies whether the UI component changes its state when a user pauses on it. */ get hoverStateEnabled() { return this._getOption('hoverStateEnabled'); } set hoverStateEnabled(value) { this._setOption('hoverStateEnabled', value); } /** * An array of items (panes) displayed by the UI component. */ get items() { return this._getOption('items'); } set items(value) { this._setOption('items', value); } /** * Specifies a custom template for items. */ get itemTemplate() { return this._getOption('itemTemplate'); } set itemTemplate(value) { this._setOption('itemTemplate', value); } /** * Specifies item orientation (layout). */ get orientation() { return this._getOption('orientation'); } set orientation(value) { this._setOption('orientation', value); } /** * Switches the UI component to a right-to-left representation. */ get rtlEnabled() { return this._getOption('rtlEnabled'); } set rtlEnabled(value) { this._setOption('rtlEnabled', value); } /** * Specifies the size of a separator bar in pixels. */ get separatorSize() { return this._getOption('separatorSize'); } set separatorSize(value) { this._setOption('separatorSize', value); } /** * Specifies whether the UI component is visible. */ get visible() { return this._getOption('visible'); } set visible(value) { this._setOption('visible', value); } /** * Specifies the UI component's width. */ get width() { return this._getOption('width'); } set width(value) { this._setOption('width', value); } constructor(elementRef, ngZone, templateHost, _watcherHelper, _idh, optionHost, transferState, platformId) { super(elementRef, ngZone, templateHost, _watcherHelper, transferState, platformId); this._watcherHelper = _watcherHelper; this._idh = _idh; this.instance = null; this._createEventEmitters([ { subscribe: 'contentReady', emit: 'onContentReady' }, { subscribe: 'disposing', emit: 'onDisposing' }, { subscribe: 'initialized', emit: 'onInitialized' }, { subscribe: 'itemClick', emit: 'onItemClick' }, { subscribe: 'itemCollapsed', emit: 'onItemCollapsed' }, { subscribe: 'itemContextMenu', emit: 'onItemContextMenu' }, { subscribe: 'itemExpanded', emit: 'onItemExpanded' }, { subscribe: 'itemRendered', emit: 'onItemRendered' }, { subscribe: 'optionChanged', emit: 'onOptionChanged' }, { subscribe: 'resize', emit: 'onResize' }, { subscribe: 'resizeEnd', emit: 'onResizeEnd' }, { subscribe: 'resizeStart', emit: 'onResizeStart' }, { emit: 'allowKeyboardNavigationChange' }, { emit: 'dataSourceChange' }, { emit: 'disabledChange' }, { emit: 'elementAttrChange' }, { emit: 'heightChange' }, { emit: 'hoverStateEnabledChange' }, { emit: 'itemsChange' }, { emit: 'itemTemplateChange' }, { emit: 'orientationChange' }, { emit: 'rtlEnabledChange' }, { emit: 'separatorSizeChange' }, { emit: 'visibleChange' }, { emit: 'widthChange' } ]); this._idh.setHost(this); optionHost.setHost(this); } _createInstance(element, options) { return new DxSplitter(element, options); } ngOnDestroy() { this._destroyWidget(); } ngOnChanges(changes) { super.ngOnChanges(changes); this.setupChanges('dataSource', changes); this.setupChanges('items', changes); } setupChanges(prop, changes) { if (!(prop in this._optionsToUpdate)) { this._idh.setup(prop, changes); } } ngDoCheck() { this._idh.doCheck('dataSource'); this._idh.doCheck('items'); this._watcherHelper.checkWatchers(); super.ngDoCheck(); super.clearChangedOptions(); } _setOption(name, value) { let isSetup = this._idh.setupSingle(name, value); let isChanged = this._idh.getChanges(name, value) !== null; if (isSetup || isChanged) { super._setOption(name, value); } } /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.21", ngImport: i0, type: DxSplitterComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i1.DxTemplateHost }, { token: i1.WatcherHelper }, { token: i1.IterableDifferHelper }, { token: i1.NestedOptionHost }, { token: i0.TransferState }, { token: PLATFORM_ID }], target: i0.ɵɵFactoryTarget.Component }); } /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.21", type: DxSplitterComponent, isStandalone: true, selector: "dx-splitter", inputs: { allowKeyboardNavigation: "allowKeyboardNavigation", dataSource: "dataSource", disabled: "disabled", elementAttr: "elementAttr", height: "height", hoverStateEnabled: "hoverStateEnabled", items: "items", itemTemplate: "itemTemplate", orientation: "orientation", rtlEnabled: "rtlEnabled", separatorSize: "separatorSize", visible: "visible", width: "width" }, outputs: { onContentReady: "onContentReady", onDisposing: "onDisposing", onInitialized: "onInitialized", onItemClick: "onItemClick", onItemCollapsed: "onItemCollapsed", onItemContextMenu: "onItemContextMenu", onItemExpanded: "onItemExpanded", onItemRendered: "onItemRendered", onOptionChanged: "onOptionChanged", onResize: "onResize", onResizeEnd: "onResizeEnd", onResizeStart: "onResizeStart", allowKeyboardNavigationChange: "allowKeyboardNavigationChange", dataSourceChange: "dataSourceChange", disabledChange: "disabledChange", elementAttrChange: "elementAttrChange", heightChange: "heightChange", hoverStateEnabledChange: "hoverStateEnabledChange", itemsChange: "itemsChange", itemTemplateChange: "itemTemplateChange", orientationChange: "orientationChange", rtlEnabledChange: "rtlEnabledChange", separatorSizeChange: "separatorSizeChange", visibleChange: "visibleChange", widthChange: "widthChange" }, host: { attributes: { "ngSkipHydration": "true" } }, providers: [ DxTemplateHost, WatcherHelper, NestedOptionHost, IterableDifferHelper ], queries: [{ propertyName: "_itemsContentChildren", predicate: PROPERTY_TOKEN_items }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: '', isInline: true, dependencies: [{ kind: "ngmodule", type: DxIntegrationModule }] }); } } i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.21", ngImport: i0, type: DxSplitterComponent, decorators: [{ type: Component, args: [{ selector: 'dx-splitter', template: '', host: { ngSkipHydration: 'true' }, imports: [DxIntegrationModule], providers: [ DxTemplateHost, WatcherHelper, NestedOptionHost, IterableDifferHelper ] }] }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: i1.DxTemplateHost }, { type: i1.WatcherHelper }, { type: i1.IterableDifferHelper }, { type: i1.NestedOptionHost }, { type: i0.TransferState }, { type: undefined, decorators: [{ type: Inject, args: [PLATFORM_ID] }] }], propDecorators: { _itemsContentChildren: [{ type: ContentChildren, args: [PROPERTY_TOKEN_items] }], allowKeyboardNavigation: [{ type: Input }], dataSource: [{ type: Input }], disabled: [{ type: Input }], elementAttr: [{ type: Input }], height: [{ type: Input }], hoverStateEnabled: [{ type: Input }], items: [{ type: Input }], itemTemplate: [{ type: Input }], orientation: [{ type: Input }], rtlEnabled: [{ type: Input }], separatorSize: [{ type: Input }], visible: [{ type: Input }], width: [{ type: Input }], onContentReady: [{ type: Output }], onDisposing: [{ type: Output }], onInitialized: [{ type: Output }], onItemClick: [{ type: Output }], onItemCollapsed: [{ type: Output }], onItemContextMenu: [{ type: Output }], onItemExpanded: [{ type: Output }], onItemRendered: [{ type: Output }], onOptionChanged: [{ type: Output }], onResize: [{ type: Output }], onResizeEnd: [{ type: Output }], onResizeStart: [{ type: Output }], allowKeyboardNavigationChange: [{ type: Output }], dataSourceChange: [{ type: Output }], disabledChange: [{ type: Output }], elementAttrChange: [{ type: Output }], heightChange: [{ type: Output }], hoverStateEnabledChange: [{ type: Output }], itemsChange: [{ type: Output }], itemTemplateChange: [{ type: Output }], orientationChange: [{ type: Output }], rtlEnabledChange: [{ type: Output }], separatorSizeChange: [{ type: Output }], visibleChange: [{ type: Output }], widthChange: [{ type: Output }] } }); class DxSplitterModule { /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.21", ngImport: i0, type: DxSplitterModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); } /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.21", ngImport: i0, type: DxSplitterModule, imports: [DxSplitterComponent, DxiItemModule, DxoSplitterModule, DxiSplitterItemModule, DxIntegrationModule, DxTemplateModule], exports: [DxSplitterComponent, DxiItemModule, DxoSplitterModule, DxiSplitterItemModule, DxTemplateModule] }); } /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.21", ngImport: i0, type: DxSplitterModule, imports: [DxSplitterComponent, DxiItemModule, DxoSplitterModule, DxiSplitterItemModule, DxIntegrationModule, DxTemplateModule, DxiItemModule, DxoSplitterModule, DxiSplitterItemModule, DxTemplateModule] }); } } i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.21", ngImport: i0, type: DxSplitterModule, decorators: [{ type: NgModule, args: [{ imports: [ DxSplitterComponent, DxiItemModule, DxoSplitterModule, DxiSplitterItemModule, DxIntegrationModule, DxTemplateModule ], exports: [ DxSplitterComponent, DxiItemModule, DxoSplitterModule, DxiSplitterItemModule, DxTemplateModule ] }] }] }); /** * Generated bundle index. Do not edit. */ export { DxSplitterComponent, DxSplitterModule }; //# sourceMappingURL=devextreme-angular-ui-splitter.mjs.map