| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958 |
- "use strict";
- var __extends = (this && this.__extends) || (function () {
- var extendStatics = Object.setPrototypeOf ||
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
- function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
- return function (d, b) {
- extendStatics(d, b);
- function __() { this.constructor = d; }
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
- };
- })();
- /*!
- * devextreme-angular
- * Version: 19.1.16
- * Build date: Tue Oct 18 2022
- *
- * Copyright (c) 2012 - 2022 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-angular
- */
- Object.defineProperty(exports, "__esModule", { value: true });
- var platform_browser_1 = require("@angular/platform-browser");
- var platform_browser_2 = require("@angular/platform-browser");
- var core_1 = require("@angular/core");
- var autocomplete_1 = require("devextreme/ui/autocomplete");
- var forms_1 = require("@angular/forms");
- var component_1 = require("../core/component");
- var template_host_1 = require("../core/template-host");
- var integration_1 = require("../core/integration");
- var template_1 = require("../core/template");
- var nested_option_1 = require("../core/nested-option");
- var watcher_helper_1 = require("../core/watcher-helper");
- var iterable_differ_helper_1 = require("../core/iterable-differ-helper");
- var button_dxi_1 = require("./nested/button-dxi");
- var options_1 = require("./nested/options");
- var item_dxi_1 = require("./nested/item-dxi");
- var button_dxi_2 = require("./nested/button-dxi");
- var item_dxi_2 = require("./nested/item-dxi");
- var CUSTOM_VALUE_ACCESSOR_PROVIDER = {
- provide: forms_1.NG_VALUE_ACCESSOR,
- useExisting: core_1.forwardRef(function () { return DxAutocompleteComponent; }),
- multi: true
- };
- /**
- * The Autocomplete widget is a textbox that provides suggestions while a user types into it.
- */
- var DxAutocompleteComponent = (function (_super) {
- __extends(DxAutocompleteComponent, _super);
- function DxAutocompleteComponent(elementRef, ngZone, templateHost, _watcherHelper, _idh, optionHost, transferState, platformId) {
- var _this = _super.call(this, elementRef, ngZone, templateHost, _watcherHelper, transferState, platformId) || this;
- _this._watcherHelper = _watcherHelper;
- _this._idh = _idh;
- _this.touched = function (_) { };
- _this._createEventEmitters([
- { subscribe: 'change', emit: 'onChange' },
- { subscribe: 'closed', emit: 'onClosed' },
- { subscribe: 'contentReady', emit: 'onContentReady' },
- { subscribe: 'copy', emit: 'onCopy' },
- { subscribe: 'cut', emit: 'onCut' },
- { subscribe: 'disposing', emit: 'onDisposing' },
- { subscribe: 'enterKey', emit: 'onEnterKey' },
- { subscribe: 'focusIn', emit: 'onFocusIn' },
- { subscribe: 'focusOut', emit: 'onFocusOut' },
- { subscribe: 'initialized', emit: 'onInitialized' },
- { subscribe: 'input', emit: 'onInput' },
- { subscribe: 'itemClick', emit: 'onItemClick' },
- { subscribe: 'keyDown', emit: 'onKeyDown' },
- { subscribe: 'keyPress', emit: 'onKeyPress' },
- { subscribe: 'keyUp', emit: 'onKeyUp' },
- { subscribe: 'opened', emit: 'onOpened' },
- { subscribe: 'optionChanged', emit: 'onOptionChanged' },
- { subscribe: 'paste', emit: 'onPaste' },
- { subscribe: 'selectionChanged', emit: 'onSelectionChanged' },
- { subscribe: 'valueChanged', emit: 'onValueChanged' },
- { emit: 'accessKeyChange' },
- { emit: 'activeStateEnabledChange' },
- { emit: 'buttonsChange' },
- { emit: 'dataSourceChange' },
- { emit: 'deferRenderingChange' },
- { emit: 'disabledChange' },
- { emit: 'displayValueChange' },
- { emit: 'dropDownButtonTemplateChange' },
- { emit: 'elementAttrChange' },
- { emit: 'focusStateEnabledChange' },
- { emit: 'groupedChange' },
- { emit: 'groupTemplateChange' },
- { emit: 'heightChange' },
- { emit: 'hintChange' },
- { emit: 'hoverStateEnabledChange' },
- { emit: 'inputAttrChange' },
- { emit: 'isValidChange' },
- { emit: 'itemsChange' },
- { emit: 'itemTemplateChange' },
- { emit: 'maxItemCountChange' },
- { emit: 'maxLengthChange' },
- { emit: 'minSearchLengthChange' },
- { emit: 'nameChange' },
- { emit: 'openedChange' },
- { emit: 'openOnFieldClickChange' },
- { emit: 'placeholderChange' },
- { emit: 'readOnlyChange' },
- { emit: 'rtlEnabledChange' },
- { emit: 'searchExprChange' },
- { emit: 'searchModeChange' },
- { emit: 'searchTimeoutChange' },
- { emit: 'selectedItemChange' },
- { emit: 'showClearButtonChange' },
- { emit: 'showDropDownButtonChange' },
- { emit: 'spellcheckChange' },
- { emit: 'stylingModeChange' },
- { emit: 'tabIndexChange' },
- { emit: 'textChange' },
- { emit: 'validationErrorChange' },
- { emit: 'validationMessageModeChange' },
- { emit: 'valueChange' },
- { emit: 'valueChangeEventChange' },
- { emit: 'valueExprChange' },
- { emit: 'visibleChange' },
- { emit: 'widthChange' },
- { emit: 'onBlur' }
- ]);
- _this._idh.setHost(_this);
- optionHost.setHost(_this);
- return _this;
- }
- Object.defineProperty(DxAutocompleteComponent.prototype, "accessKey", {
- get: /**
- * Specifies the shortcut key that sets focus on the widget.
- */
- function () {
- return this._getOption('accessKey');
- },
- set: function (value) {
- this._setOption('accessKey', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "activeStateEnabled", {
- get: /**
- * Specifies whether or not the widget changes its state when interacting with a user.
- */
- function () {
- return this._getOption('activeStateEnabled');
- },
- set: function (value) {
- this._setOption('activeStateEnabled', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "buttons", {
- get: /**
- * Allows you to add custom buttons to the input text field.
- */
- function () {
- return this._getOption('buttons');
- },
- set: function (value) {
- this._setOption('buttons', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "dataSource", {
- get: /**
- * Binds the widget to data.
- */
- function () {
- return this._getOption('dataSource');
- },
- set: function (value) {
- this._setOption('dataSource', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "deferRendering", {
- get: /**
- * Specifies whether to render the drop-down field's content when it is displayed. If false, the content is rendered immediately.
- */
- function () {
- return this._getOption('deferRendering');
- },
- set: function (value) {
- this._setOption('deferRendering', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "disabled", {
- get: /**
- * Specifies whether the widget responds to user interaction.
- */
- function () {
- return this._getOption('disabled');
- },
- set: function (value) {
- this._setOption('disabled', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "displayValue", {
- get: /**
- * Returns the value currently displayed by the widget.
- */
- function () {
- return this._getOption('displayValue');
- },
- set: function (value) {
- this._setOption('displayValue', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "dropDownButtonTemplate", {
- get: /**
- * Specifies a custom template for the drop-down button.
- */
- function () {
- return this._getOption('dropDownButtonTemplate');
- },
- set: function (value) {
- this._setOption('dropDownButtonTemplate', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "elementAttr", {
- get: /**
- * Specifies the attributes to be attached to the widget's root element.
- */
- function () {
- return this._getOption('elementAttr');
- },
- set: function (value) {
- this._setOption('elementAttr', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "focusStateEnabled", {
- get: /**
- * Specifies whether the widget can be focused using keyboard navigation.
- */
- function () {
- return this._getOption('focusStateEnabled');
- },
- set: function (value) {
- this._setOption('focusStateEnabled', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "grouped", {
- get: /**
- * Specifies whether data items should be grouped.
- */
- function () {
- return this._getOption('grouped');
- },
- set: function (value) {
- this._setOption('grouped', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "groupTemplate", {
- get: /**
- * Specifies a custom template for group captions.
- */
- function () {
- return this._getOption('groupTemplate');
- },
- set: function (value) {
- this._setOption('groupTemplate', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "height", {
- get: /**
- * Specifies the widget's height.
- */
- function () {
- return this._getOption('height');
- },
- set: function (value) {
- this._setOption('height', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "hint", {
- get: /**
- * Specifies text for a hint that appears when a user pauses on the widget.
- */
- function () {
- return this._getOption('hint');
- },
- set: function (value) {
- this._setOption('hint', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "hoverStateEnabled", {
- get: /**
- * Specifies whether the widget changes its state when a user pauses on it.
- */
- function () {
- return this._getOption('hoverStateEnabled');
- },
- set: function (value) {
- this._setOption('hoverStateEnabled', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "inputAttr", {
- get: /**
- * Specifies the attributes to be passed on to the underlying HTML element.
- */
- function () {
- return this._getOption('inputAttr');
- },
- set: function (value) {
- this._setOption('inputAttr', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "isValid", {
- get: /**
- * Specifies whether the editor's value is valid.
- */
- function () {
- return this._getOption('isValid');
- },
- set: function (value) {
- this._setOption('isValid', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "items", {
- get: /**
- * An array of items displayed by the widget.
- */
- function () {
- return this._getOption('items');
- },
- set: function (value) {
- this._setOption('items', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "itemTemplate", {
- get: /**
- * Specifies a custom template for items.
- */
- function () {
- return this._getOption('itemTemplate');
- },
- set: function (value) {
- this._setOption('itemTemplate', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "maxItemCount", {
- get: /**
- * Specifies the maximum count of items displayed by the widget.
- */
- function () {
- return this._getOption('maxItemCount');
- },
- set: function (value) {
- this._setOption('maxItemCount', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "maxLength", {
- get: /**
- * Specifies the maximum number of characters you can enter into the textbox.
- */
- function () {
- return this._getOption('maxLength');
- },
- set: function (value) {
- this._setOption('maxLength', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "minSearchLength", {
- get: /**
- * The minimum number of characters that must be entered into the text box to begin a search.
- */
- function () {
- return this._getOption('minSearchLength');
- },
- set: function (value) {
- this._setOption('minSearchLength', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "name", {
- get: /**
- * The value to be assigned to the `name` attribute of the underlying HTML element.
- */
- function () {
- return this._getOption('name');
- },
- set: function (value) {
- this._setOption('name', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "opened", {
- get: /**
- * Specifies whether or not the drop-down editor is displayed.
- */
- function () {
- return this._getOption('opened');
- },
- set: function (value) {
- this._setOption('opened', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "openOnFieldClick", {
- get: /**
- * Specifies whether a user can open the drop-down list by clicking a text field.
- */
- function () {
- return this._getOption('openOnFieldClick');
- },
- set: function (value) {
- this._setOption('openOnFieldClick', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "placeholder", {
- get: /**
- * The text displayed by the widget when the widget value is empty.
- */
- function () {
- return this._getOption('placeholder');
- },
- set: function (value) {
- this._setOption('placeholder', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "readOnly", {
- get: /**
- * Specifies whether the editor is read-only.
- */
- function () {
- return this._getOption('readOnly');
- },
- set: function (value) {
- this._setOption('readOnly', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "rtlEnabled", {
- get: /**
- * Switches the widget to a right-to-left representation.
- */
- function () {
- return this._getOption('rtlEnabled');
- },
- set: function (value) {
- this._setOption('rtlEnabled', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "searchExpr", {
- get: /**
- * Specifies the name of a data source item field or an expression whose value is compared to the search criterion.
- */
- function () {
- return this._getOption('searchExpr');
- },
- set: function (value) {
- this._setOption('searchExpr', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "searchMode", {
- get: /**
- * Specifies a comparison operation used to search widget items.
- */
- function () {
- return this._getOption('searchMode');
- },
- set: function (value) {
- this._setOption('searchMode', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "searchTimeout", {
- get: /**
- * Specifies the time delay, in milliseconds, after the last character has been typed in, before a search is executed.
- */
- function () {
- return this._getOption('searchTimeout');
- },
- set: function (value) {
- this._setOption('searchTimeout', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "selectedItem", {
- get: /**
- * Gets the currently selected item.
- */
- function () {
- return this._getOption('selectedItem');
- },
- set: function (value) {
- this._setOption('selectedItem', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "showClearButton", {
- get: /**
- * Specifies whether to display the Clear button in the widget.
- */
- function () {
- return this._getOption('showClearButton');
- },
- set: function (value) {
- this._setOption('showClearButton', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "showDropDownButton", {
- get: /**
- * Specifies whether the drop-down button is visible.
- */
- function () {
- return this._getOption('showDropDownButton');
- },
- set: function (value) {
- this._setOption('showDropDownButton', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "spellcheck", {
- get: /**
- * Specifies whether or not the widget checks the inner text for spelling mistakes.
- */
- function () {
- return this._getOption('spellcheck');
- },
- set: function (value) {
- this._setOption('spellcheck', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "stylingMode", {
- get: /**
- * Specifies how the widget's text field is styled.
- */
- function () {
- return this._getOption('stylingMode');
- },
- set: function (value) {
- this._setOption('stylingMode', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "tabIndex", {
- get: /**
- * Specifies the number of the element when the Tab key is used for navigating.
- */
- function () {
- return this._getOption('tabIndex');
- },
- set: function (value) {
- this._setOption('tabIndex', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "text", {
- get: /**
- * The read-only option that holds the text displayed by the widget input element.
- */
- function () {
- return this._getOption('text');
- },
- set: function (value) {
- this._setOption('text', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "validationError", {
- get: /**
- * Specifies information on the validation error when using a custom validation engine. Should be changed at runtime along with the isValid option.
- */
- function () {
- return this._getOption('validationError');
- },
- set: function (value) {
- this._setOption('validationError', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "validationMessageMode", {
- get: /**
- * Specifies how the message about the validation rules that are not satisfied by this editor's value is displayed.
- */
- function () {
- return this._getOption('validationMessageMode');
- },
- set: function (value) {
- this._setOption('validationMessageMode', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "value", {
- get: /**
- * Specifies the current value displayed by the widget.
- */
- function () {
- return this._getOption('value');
- },
- set: function (value) {
- this._setOption('value', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "valueChangeEvent", {
- get: /**
- * Specifies the DOM events after which the widget's value should be updated.
- */
- function () {
- return this._getOption('valueChangeEvent');
- },
- set: function (value) {
- this._setOption('valueChangeEvent', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "valueExpr", {
- get: /**
- * Specifies which data field provides unique values to the widget's value.
- */
- function () {
- return this._getOption('valueExpr');
- },
- set: function (value) {
- this._setOption('valueExpr', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "visible", {
- get: /**
- * Specifies whether the widget is visible.
- */
- function () {
- return this._getOption('visible');
- },
- set: function (value) {
- this._setOption('visible', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "width", {
- get: /**
- * Specifies the widget's width.
- */
- function () {
- return this._getOption('width');
- },
- set: function (value) {
- this._setOption('width', value);
- },
- enumerable: true,
- configurable: true
- });
- DxAutocompleteComponent.prototype.change = function (_) { };
- Object.defineProperty(DxAutocompleteComponent.prototype, "buttonsChildren", {
- get: function () {
- return this._getOption('buttons');
- },
- set: function (value) {
- this.setChildren('buttons', value);
- },
- enumerable: true,
- configurable: true
- });
- Object.defineProperty(DxAutocompleteComponent.prototype, "itemsChildren", {
- get: function () {
- return this._getOption('items');
- },
- set: function (value) {
- this.setChildren('items', value);
- },
- enumerable: true,
- configurable: true
- });
- DxAutocompleteComponent.prototype._createInstance = function (element, options) {
- return new autocomplete_1.default(element, options);
- };
- DxAutocompleteComponent.prototype.writeValue = function (value) {
- this.eventHelper.lockedValueChangeEvent = true;
- this.value = value;
- this.eventHelper.lockedValueChangeEvent = false;
- };
- DxAutocompleteComponent.prototype.setDisabledState = function (isDisabled) {
- this.disabled = isDisabled;
- };
- DxAutocompleteComponent.prototype.registerOnChange = function (fn) { this.change = fn; };
- DxAutocompleteComponent.prototype.registerOnTouched = function (fn) { this.touched = fn; };
- DxAutocompleteComponent.prototype._createWidget = function (element) {
- var _this = this;
- _super.prototype._createWidget.call(this, element);
- this.instance.on('focusOut', function (e) {
- _this.eventHelper.fireNgEvent('onBlur', [e]);
- });
- };
- DxAutocompleteComponent.prototype.ngOnDestroy = function () {
- this._destroyWidget();
- };
- DxAutocompleteComponent.prototype.ngOnChanges = function (changes) {
- _super.prototype.ngOnChanges.call(this, changes);
- this.setupChanges('buttons', changes);
- this.setupChanges('dataSource', changes);
- this.setupChanges('items', changes);
- this.setupChanges('searchExpr', changes);
- };
- DxAutocompleteComponent.prototype.setupChanges = function (prop, changes) {
- if (!(prop in this._optionsToUpdate)) {
- this._idh.setup(prop, changes);
- }
- };
- DxAutocompleteComponent.prototype.ngDoCheck = function () {
- this._idh.doCheck('buttons');
- this._idh.doCheck('dataSource');
- this._idh.doCheck('items');
- this._idh.doCheck('searchExpr');
- this._watcherHelper.checkWatchers();
- _super.prototype.ngDoCheck.call(this);
- _super.prototype.clearChangedOptions.call(this);
- };
- DxAutocompleteComponent.prototype._setOption = function (name, value) {
- var isSetup = this._idh.setupSingle(name, value);
- var isChanged = this._idh.getChanges(name, value) !== null;
- if (isSetup || isChanged) {
- _super.prototype._setOption.call(this, name, value);
- }
- };
- DxAutocompleteComponent.decorators = [
- { type: core_1.Component, args: [{
- selector: 'dx-autocomplete',
- template: '',
- providers: [
- template_host_1.DxTemplateHost,
- watcher_helper_1.WatcherHelper,
- CUSTOM_VALUE_ACCESSOR_PROVIDER,
- nested_option_1.NestedOptionHost,
- iterable_differ_helper_1.IterableDifferHelper
- ]
- },] },
- ];
- /** @nocollapse */
- DxAutocompleteComponent.ctorParameters = function () { return [
- { type: core_1.ElementRef, },
- { type: core_1.NgZone, },
- { type: template_host_1.DxTemplateHost, },
- { type: watcher_helper_1.WatcherHelper, },
- { type: iterable_differ_helper_1.IterableDifferHelper, },
- { type: nested_option_1.NestedOptionHost, },
- { type: platform_browser_2.TransferState, },
- { type: undefined, decorators: [{ type: core_1.Inject, args: [core_1.PLATFORM_ID,] },] },
- ]; };
- DxAutocompleteComponent.propDecorators = {
- "accessKey": [{ type: core_1.Input },],
- "activeStateEnabled": [{ type: core_1.Input },],
- "buttons": [{ type: core_1.Input },],
- "dataSource": [{ type: core_1.Input },],
- "deferRendering": [{ type: core_1.Input },],
- "disabled": [{ type: core_1.Input },],
- "displayValue": [{ type: core_1.Input },],
- "dropDownButtonTemplate": [{ type: core_1.Input },],
- "elementAttr": [{ type: core_1.Input },],
- "focusStateEnabled": [{ type: core_1.Input },],
- "grouped": [{ type: core_1.Input },],
- "groupTemplate": [{ type: core_1.Input },],
- "height": [{ type: core_1.Input },],
- "hint": [{ type: core_1.Input },],
- "hoverStateEnabled": [{ type: core_1.Input },],
- "inputAttr": [{ type: core_1.Input },],
- "isValid": [{ type: core_1.Input },],
- "items": [{ type: core_1.Input },],
- "itemTemplate": [{ type: core_1.Input },],
- "maxItemCount": [{ type: core_1.Input },],
- "maxLength": [{ type: core_1.Input },],
- "minSearchLength": [{ type: core_1.Input },],
- "name": [{ type: core_1.Input },],
- "opened": [{ type: core_1.Input },],
- "openOnFieldClick": [{ type: core_1.Input },],
- "placeholder": [{ type: core_1.Input },],
- "readOnly": [{ type: core_1.Input },],
- "rtlEnabled": [{ type: core_1.Input },],
- "searchExpr": [{ type: core_1.Input },],
- "searchMode": [{ type: core_1.Input },],
- "searchTimeout": [{ type: core_1.Input },],
- "selectedItem": [{ type: core_1.Input },],
- "showClearButton": [{ type: core_1.Input },],
- "showDropDownButton": [{ type: core_1.Input },],
- "spellcheck": [{ type: core_1.Input },],
- "stylingMode": [{ type: core_1.Input },],
- "tabIndex": [{ type: core_1.Input },],
- "text": [{ type: core_1.Input },],
- "validationError": [{ type: core_1.Input },],
- "validationMessageMode": [{ type: core_1.Input },],
- "value": [{ type: core_1.Input },],
- "valueChangeEvent": [{ type: core_1.Input },],
- "valueExpr": [{ type: core_1.Input },],
- "visible": [{ type: core_1.Input },],
- "width": [{ type: core_1.Input },],
- "onChange": [{ type: core_1.Output },],
- "onClosed": [{ type: core_1.Output },],
- "onContentReady": [{ type: core_1.Output },],
- "onCopy": [{ type: core_1.Output },],
- "onCut": [{ type: core_1.Output },],
- "onDisposing": [{ type: core_1.Output },],
- "onEnterKey": [{ type: core_1.Output },],
- "onFocusIn": [{ type: core_1.Output },],
- "onFocusOut": [{ type: core_1.Output },],
- "onInitialized": [{ type: core_1.Output },],
- "onInput": [{ type: core_1.Output },],
- "onItemClick": [{ type: core_1.Output },],
- "onKeyDown": [{ type: core_1.Output },],
- "onKeyPress": [{ type: core_1.Output },],
- "onKeyUp": [{ type: core_1.Output },],
- "onOpened": [{ type: core_1.Output },],
- "onOptionChanged": [{ type: core_1.Output },],
- "onPaste": [{ type: core_1.Output },],
- "onSelectionChanged": [{ type: core_1.Output },],
- "onValueChanged": [{ type: core_1.Output },],
- "accessKeyChange": [{ type: core_1.Output },],
- "activeStateEnabledChange": [{ type: core_1.Output },],
- "buttonsChange": [{ type: core_1.Output },],
- "dataSourceChange": [{ type: core_1.Output },],
- "deferRenderingChange": [{ type: core_1.Output },],
- "disabledChange": [{ type: core_1.Output },],
- "displayValueChange": [{ type: core_1.Output },],
- "dropDownButtonTemplateChange": [{ type: core_1.Output },],
- "elementAttrChange": [{ type: core_1.Output },],
- "focusStateEnabledChange": [{ type: core_1.Output },],
- "groupedChange": [{ type: core_1.Output },],
- "groupTemplateChange": [{ type: core_1.Output },],
- "heightChange": [{ type: core_1.Output },],
- "hintChange": [{ type: core_1.Output },],
- "hoverStateEnabledChange": [{ type: core_1.Output },],
- "inputAttrChange": [{ type: core_1.Output },],
- "isValidChange": [{ type: core_1.Output },],
- "itemsChange": [{ type: core_1.Output },],
- "itemTemplateChange": [{ type: core_1.Output },],
- "maxItemCountChange": [{ type: core_1.Output },],
- "maxLengthChange": [{ type: core_1.Output },],
- "minSearchLengthChange": [{ type: core_1.Output },],
- "nameChange": [{ type: core_1.Output },],
- "openedChange": [{ type: core_1.Output },],
- "openOnFieldClickChange": [{ type: core_1.Output },],
- "placeholderChange": [{ type: core_1.Output },],
- "readOnlyChange": [{ type: core_1.Output },],
- "rtlEnabledChange": [{ type: core_1.Output },],
- "searchExprChange": [{ type: core_1.Output },],
- "searchModeChange": [{ type: core_1.Output },],
- "searchTimeoutChange": [{ type: core_1.Output },],
- "selectedItemChange": [{ type: core_1.Output },],
- "showClearButtonChange": [{ type: core_1.Output },],
- "showDropDownButtonChange": [{ type: core_1.Output },],
- "spellcheckChange": [{ type: core_1.Output },],
- "stylingModeChange": [{ type: core_1.Output },],
- "tabIndexChange": [{ type: core_1.Output },],
- "textChange": [{ type: core_1.Output },],
- "validationErrorChange": [{ type: core_1.Output },],
- "validationMessageModeChange": [{ type: core_1.Output },],
- "valueChange": [{ type: core_1.Output },],
- "valueChangeEventChange": [{ type: core_1.Output },],
- "valueExprChange": [{ type: core_1.Output },],
- "visibleChange": [{ type: core_1.Output },],
- "widthChange": [{ type: core_1.Output },],
- "onBlur": [{ type: core_1.Output },],
- "change": [{ type: core_1.HostListener, args: ['valueChange', ['$event'],] },],
- "touched": [{ type: core_1.HostListener, args: ['onBlur', ['$event'],] },],
- "buttonsChildren": [{ type: core_1.ContentChildren, args: [button_dxi_2.DxiButtonComponent,] },],
- "itemsChildren": [{ type: core_1.ContentChildren, args: [item_dxi_2.DxiItemComponent,] },],
- };
- return DxAutocompleteComponent;
- }(component_1.DxComponent));
- exports.DxAutocompleteComponent = DxAutocompleteComponent;
- var DxAutocompleteModule = (function () {
- function DxAutocompleteModule() {
- }
- DxAutocompleteModule.decorators = [
- { type: core_1.NgModule, args: [{
- imports: [
- button_dxi_1.DxiButtonModule,
- options_1.DxoOptionsModule,
- item_dxi_1.DxiItemModule,
- integration_1.DxIntegrationModule,
- template_1.DxTemplateModule,
- platform_browser_1.BrowserTransferStateModule
- ],
- declarations: [
- DxAutocompleteComponent
- ],
- exports: [
- DxAutocompleteComponent,
- button_dxi_1.DxiButtonModule,
- options_1.DxoOptionsModule,
- item_dxi_1.DxiItemModule,
- template_1.DxTemplateModule
- ]
- },] },
- ];
- return DxAutocompleteModule;
- }());
- exports.DxAutocompleteModule = DxAutocompleteModule;
- //# sourceMappingURL=autocomplete.js.map
|