We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Content of ej-accordion control

Hi, I was trying to wrap up this control and I would like to know is it possible to wrap up the content (h3, div elements and so on) of the control in some template, or some other property maybe.

Thank you, Kristina

1 Reply

PO Prince Oliver Syncfusion Team October 5, 2017 12:31 PM UTC

Hi Kristina, 

Thank you for contacting Syncfusion forums. 

You can use ng template in accordion control to wrap its contents. Kindly refer to the below code. 

<ej-accordion id="accordion1" enableMultipleOpen="true" *ngFor="let orderOptions of lookupValues"> 
    <h3> <a rel='nofollow' href="#">{{orderOptions}}</a></h3> 
    <div> 
        <div> 
        <label>Date:</label> <span>exampleDate</span> 
        </div> 
        <div> 
        <label>Product:</label> <span>exampleProduct</span> 
        </div>                                         
    </div> 
</ej-accordion>  

You can use the default template support in accordion, refer to the following UG documentation link for information: https://help.syncfusion.com/angular/accordion/template-support 

We have prepared a sample for your reference, kindly refer to the following link for the sample: http://www.syncfusion.com/downloads/support/forum/133029/ze/Accordion-ngfor1297670581 

Regards, 
Prince 


Loader.
Up arrow icon