As far as I understood the issue on your side is when you are setting backgroundColor="transparent"
for your RadListView along with the code for setting the item background color
it will loose the default styling for all selecting items. However, as I do not have the actual code that stands behind your implementation and with the way nativescript-platform-css is affecting your project I have created this test application
to recreate the code as much as possible but the end the result is that I am not able to reproduce the issue as the selected styles are preserved on my side.
Here are the steps I have taken:
In the test application, I am setting the backgroundColor to transparent
(for RadListView) while using Press
as selection behavior. Then in the component class in itemLoading
, I am changing the color of each item
The final result is that the RadListView is transparent with custom color applied for each item and at the same time the selection styling is preserved just as it is by design (the selected cells are getting darker).
My guess here is that you are loosing the default styles due to overwriting them with the CSS rules and more specifically the one that is setting class .riv-item.
I am only speculating here (as I do not have eyes on the actual source code) but if this class is used to overwrite the backgroundColor of your items it is expected that it will overwrite the selected styles as well. Simply removing this rule and applying the item color via itemLoading
should resolve your issue.
If you still have troubles overcoming this one please send us a GitHub link or archive containing sample project which best illustrates and reproduces the issue.