This repository is used for customer feedback regarding Telerik UI for NativeScript. The issues system here is used by customers who want to submit their feature requests or vote for existing ones.
Other
115
stars
21
forks
source link
RadListView 7.1.0 iOS item backgroundColor issue while deselecting #1403
We want to get an identical behavior on Android and iOS for selecting items within RadListView.
So instead those selection-circles on the left in iOS items, we also want just a special backgroundColor on iOS when items are selected, and the default backgroundColor if items are not selected.
What we do:
We switch the css class of the outer container within the listitem, if the data-item's isSelected property is set to true or false.
In addition to switching the background-color, we also give a white color to all Labels within th selected listitem, so the user can better read the text of selected items with a dark background-color.
While this works as expected on Android (left), we have some trouble on iOS (right):
Actually, we already found out what is causing this: it's the FormattedString within the listitem template:
More specifically, the problem is the textWrap="true". When removing that, everything works as expected! But doing that is not an option for us, since this String can get longer in our real app and it needs to be wrappable to 1-3 lines.
Another option is to remove this style:
.listitem-selected Label {
color: #ffffff;
}
But this is also no option for us...
Maybe it is more a bug in the FormattedString on iOS, but as it occured for us while using the RadListView, I decided to post this thread here.
Tell us about the problem
We want to get an identical behavior on Android and iOS for selecting items within RadListView. So instead those selection-circles on the left in iOS items, we also want just a special backgroundColor on iOS when items are selected, and the default backgroundColor if items are not selected.
What we do: We switch the css class of the outer container within the listitem, if the data-item's isSelected property is set to true or false.
In addition to switching the background-color, we also give a white color to all Labels within th selected listitem, so the user can better read the text of selected items with a dark background-color.
While this works as expected on Android (left), we have some trouble on iOS (right):
Actually, we already found out what is causing this: it's the FormattedString within the listitem template:
More specifically, the problem is the
textWrap="true"
. When removing that, everything works as expected! But doing that is not an option for us, since this String can get longer in our real app and it needs to be wrappable to 1-3 lines.Another option is to remove this style:
But this is also no option for us...
Maybe it is more a bug in the FormattedString on iOS, but as it occured for us while using the RadListView, I decided to post this thread here.
We know that there is already the 8.1.1 version of RadListView, but we cannot migrate due to the issues: https://github.com/NativeScript/nativescript-ui-feedback/issues/1373 , https://github.com/NativeScript/nativescript-ui-feedback/issues/1404
Which platform(s) does your issue occur on?
iOS (tested 12.4 and 13.4, simulator and device)
Please provide the following version numbers that your issue occurs with:
Please tell us how to recreate the issue in as much detail as possible.
Follow the steps of the GIF above
Is there code involved? If so, please share the minimal amount of code needed to recreate the problem.
RadListViewSelectionIssueIOS.zip