Telerik Forums
Kendo UI for Angular Forum
1 answer
17 views

Hello,

Currently I have a Kendo Filter in which I'm passing in a CompositeFilterDescriptor (dslFilter) as a value, as such:

<kendo-filter
      #filter
      [filters]="filters"
      [value]="dslFilter" // <=== THIS ONE
      (valueChange)="onFilterChange($event)"
    >
...

 

As I understand it, the filter will turn a CompositeFilterDescriptor into a bunch of generated input forms, such as this:

 

Problem is, I implemented Kendo Autocomplete in those fields (full HTML below), but the generated input forms aren't generated as Autocomplete input forms.  I only get Autocomplete forms if I (1) edit the field in one of the forms, or (2) I add a filter.  In both cases, the input form will have to deviate from the generated (from the CompositeFilterDescriptor) form in order to become Autocomplete.  Otherwise, it's just a textbox.

 

How do I get the generated input forms to be Autocomplete?  Edit:  A more general question, how can I modify the generated input forms?  Say if I want the generated textbox to be wider...

 

Full HTML is below:

  <div>
    <kendo-filter
      #filter
      [filters]="filters"
      [value]="dslFilter"
      (valueChange)="onFilterChange($event)"
    >
      <ng-container *ngFor="let fl of filters">
        <kendo-filter-field [field]="fl.field" [editor]="fl.editor">
          <ng-template kendoFilterValueEditorTemplate let-currentItem>
            <ng-container *ngFor="let field of autocompleteFields">
              <ng-container *ngIf="currentItem.field === field">
                <kendo-autocomplete
                  [data]="getUniqueValues(currentItem.field)"
                  [value]="currentItem.value"
                  [suggest]="true"
                  [virtual]="{itemHeight: 28}"
                  (valueChange)="editorValueChange($event, currentItem, filter.value)"
                >
                </kendo-autocomplete>
              </ng-container>
            </ng-container>

          </ng-template>
        </kendo-filter-field>
      </ng-container>
    </kendo-filter>
  </div>

 

Martin
Telerik team
 answered on 15 Apr 2024
1 answer
55 views
I have a Angular form which contains two autocomplete fields. Both share same reference and call same function. autocomplete.toggle(false) is working for first field but not for the second one.
Hetali
Telerik team
 answered on 08 Aug 2023
1 answer
79 views
Hello, 

I am trying to put a max length on the angular autocomplete component to only allow a certain amount of characters to be typed. So far I have had no luck trying to use autocomplete api documentation. 

Hopefully someone is able to help. Thank you in advance.
Veselin
Telerik team
 answered on 24 Feb 2023
1 answer
262 views

Hi, we are looking for the input, dropdowns which has this outline design in the material theme but we are not able to find it. 

 

It'd have been better if we have this.

 

something like this https://codepen.io/finnhvman/pen/xyOORQ

 

Thanks.

1 answer
1.6K+ views
I need to clear the kendo searchbox input field to null or blank through a function call in angular 9
Yanmario
Telerik team
 answered on 09 Mar 2022
0 answers
100 views

Hello Team,

I have a scenerio where i need to show the data in multiple lines within autocomplete field, I'm able to get multiple lines in item template but when selected it is displaying in single line, is there any way to show it in multiple lines?

TIA.

Srija .P

 

Srija
Top achievements
Rank 1
 asked on 06 Mar 2022
1 answer
365 views

Hello Team,

                    We want to display an icon in empty autocomplete field to let the users know that is data can be assigned to that field by clicking or typing on it, we know that we can achieve this by using a kendo dropdown, but we are using the autocomplete in various area's in our product, is there any way to show the icon by using CSS or in any other way, please let us know. 

 

Thanks.

Hari Padala

Yanmario
Telerik team
 answered on 21 Apr 2021
4 answers
561 views

Hello,

Automcomplete html 

<kendo-autocomplete [data]="listItems" [valueField]="'text'" [placeholder]="'e.g. Andorra'"<br>    (valueChange)="valueChange($event)"><br>    </kendo-autocomplete>

 data is binded from array of object

public listItems: Array<{ text: string, value: string }> = [<br>         { text: "Albania", value: "Alb" },<br>         { text: "Andorra", value: "And" },<br>         { text: "Armenia", value: "Arm" },<br>         { text: "Austria", value: "Aus" },<br>         { text: "Azerbaijan", value: "Aze" }<br>     ];

, when valueChange event is fired ,only receive valueField data in valueChange event. I need object of selected item in valueChange event.

please check out this stackbiz demo.

AutoComplete

Dimiter Topalov
Telerik team
 answered on 02 Nov 2020
5 answers
1.6K+ views

 

Hi,

We are using KendoUI AutoComplete for Angular6 like below.

<kendo-autocomplete #autocomplete style="width:100%" [(data)]="items" [valueField]="'DESCR_FULL'"
      [suggest]="true" placeholder="Digita almeno 3 caratteri..." [(ngModel)]="selectedsedetechnica"
      (valueChange)=SelectedAssetFromSTCombo($event) [filterable]="true" (filterChange)="handleFilter($event)">
</kendo-autocomplete>

valueChange event is fired even when the AutoComplete is tabbed out / blurred.

But we want to fire the "valueChange" event only when the user selects any one of the AutoComplete suggestions (by clicking on any one of the suggestions (or) by selecting any one one of the suggestions with keyboard ENTER key.). We don't want to fire this event when Aucomplete lost focus (blurred).

Because the autocomplete suggestions will vary based on the user. We don't want to process any data that is not coming from AutoComplete.

How to stop firing "valueChange" event when AutoComplete is tabbed out (or) lost focus

Thanks in advance,

Rajesh

Martin
Telerik team
 answered on 13 Oct 2020
1 answer
77 views

I want to add a search icon inside the autocomplete component.while the user is not typing anything in the box a search icon should appear.as the user starts typing search would be replaced with a default cross icon.again when the focus is out of the box the cross icon should be replaced by the search icon.how do I achieve with autocomplete component.

 

Dimiter Madjarov
Telerik team
 answered on 07 Sep 2020
Top users last month
Dominik
Top achievements
Rank 1
Giuliano
Top achievements
Rank 1
Dominic
Top achievements
Rank 1
Glendys
Top achievements
Rank 1
Iron
NoobMaster
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?