Accordion List / insert a description in submenu


#1

How to insert a description in submenu?


#2

I think i found it.

You just have to insert toggle items with html and css, and then configure its respective controller.

Look at this

Codepen


Look the code you can use for your list:

<ion-list>
        <div ng-repeat="group in groups">
          <ion-item class="item-stable"
                    ng-click="toggleGroup(group)"
                    ng-class="{active: isGroupShown(group)}">
              <i class="icon" ng-class="isGroupShown(group) ? 'ion-minus' : 'ion-plus'"></i>
            &nbsp;
            Group {{group.name}}
          </ion-item>
          <ion-item class="item-accordion"
                    ng-repeat="item in group.items"
                    ng-show="isGroupShown(group)">
            {{item}}
          </ion-item>
        </div>
      </ion-list>

I hope this works for you.


#3

I do not understand(