Notice: The Monaca & Onsen UI Community Forum is shutting down.
For Onsen UI bug reports, feature requests and questions, please use the Onsen UI GitHub issues page. For help with Monaca, please contact Monaca Support Team.
Thank you to all our community for your contributions to the forum. We look forward to hearing from you in the new communication channels.
ListItem
-
Component that represents each item in the list. Must be put inside the
List
component. The list item is composed of three parts that are represented with theleft
,center
andright
classes. These classes can be used to ensure that the content of the list items is properly aligned.Click here to see the original article
-
Hello! There is a modifier for the active ListItem?
-
@boomfly What do you mean with the “active” listItem? If you want an effect when an item is clicked you can use
tappable
.
-
Can I use
onClick
attribute?I’ve used it in my project and it works. But it’s not mentions in the Props table above.
-
@samphan that’s because
onClick
is a regular attribute for DOM elements, not a specific prop forListItem
, naturally you can use it in the regular way :+1:
-
The value of className is ‘left’ ‘center’ and ‘right’ but the css version the value is ‘list-item__left’ ‘list-item__center’ ‘list-item__right’…can someone explain this ?
-
How do you use Preset Modifiers?
-
@dax: found asolution - using modifier=“chevron”? Is this the correct way?
-
@jay: I found using className=‘center’ adds ‘list-item__center list-item–chevron__center’ at runtime, but alternatively for className=‘title’ does not add ‘list-item__title list-item–material__title’ for sub element. Very confusing!