This is a migrated thread and some comments may be shown as answers.

Can I setting images in listView zoom?

1 Answer 65 Views
ListView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Miklos
Top achievements
Rank 1
Miklos asked on 08 Sep 2017, 06:56 AM

Hi!

I use latest nativescript-angular, nativescript, telerik-ui.

I get imagesSrc from API and insert my RadListView.

Can I setting images zoom in listView?

Can I get item id on scrolling? I want to write to user which items see. 1/12 or 2/12 or 3/12

Thanx for your help.

 

 

1 Answer, 1 is accepted

Sort by
0
Nick Iliev
Telerik team
answered on 08 Sep 2017, 07:54 AM
Hi Miklos,

There is no out-of-the-box zoom functionality for loaded images but this can be achieved by implementing further customizations for your items. Examples of how to create item templates in RadListView can be found here and in this article section, you can see how to customize your items based on the item index.

Using both techniques you can load different templates and control the UI of your list view items including how the images are rendered,

Regarding the id on scrolling - you can achieve that by directly creating the source array with a unique id for each of your items (e.g. like done with these arrays). Now that the source array has your own unique IDs for each element, you can visualize them using the Angular binding.

Another approach for Angular based application is to use the provided index in a ng-template tag.
e.g.
<ng-template let-country="item" let-index="index" let-odd="odd" let-even="even">
     <StackLayout class="list-group-item">
           <Label [text]="index"></Label> <!-- item index -->>
           <Label [text]="country.name"></Label>
      </StackLayout >
</ng-template>


Regards,
Nikolay Iliev
Progress Telerik
Did you know that you can open private support tickets which are reviewed and answered within 24h by the same team who built the components? This is available in our UI for NativeScript Pro + Support offering.
Tags
ListView
Asked by
Miklos
Top achievements
Rank 1
Answers by
Nick Iliev
Telerik team
Share this question
or