-
Notifications
You must be signed in to change notification settings - Fork 2
f7_list_item
Terry Wilson edited this page Sep 17, 2014
·
1 revision
This renders a single list item, which can be made up of quite a few components.
f7_list_item title, options, &block
f7_list_item options, &block
As well as all the usual HTML options, you have these extra, helper specific options:
-
:title
- Optional, some text to be displayed before the block. -
:href
- Optional, where to go when item is clicked. -
:icon
- Optional, icon to display on the left of list item. -
:after
- Optional, allows you specify content for the right portion of the list item.
<%= f7_list_item 'Item Title' %>
<li>
<div class="item-content">
<div class="item-inner">
<div class="item-title">Item Title</div>
</div>
</div>
</li>
<%= f7_list_item 'Username', :href => '#', :after => 'jbloggs' %>
<li>
<a class="item-content item-link">
<div class="item-inner">
<div class="item-title">Username</div>
<div class="item-after">jbloggs</div>
</div>
</a>
</li>
<%= f7_list_item 'Item Title', :icon => :'icon-f7' %>
<li>
<div class="item-content">
<div class="item-media">
<i class="icon icon-f7">
</div>
<div class="item-inner">
<div class="item-title">Item Title</div>
</div>
</div>
</li>
<%= f7_list_item 'Item Title', :icon => :'my-icon', :after => 'Value' %>
<li>
<div class="item-content">
<div class="item-media">
<i class="icon my-icon">
</div>
<div class="item-inner">
<div class="item-title">Item Title</div>
<div class="item-after">Value</div>
</div>
</div>
</li>