cancel
Showing results for 
Search instead for 
Did you mean: 

HWC listview refreshing height issue

Former Member
0 Kudos

HI,

we're developing a HWC with custom listview by coding in custom.js.

We discover that if we add another item to the listview, we're unable to scroll to very bottom of the listview and this only happen to iOS devices, we tested on android devices, the listview is working fine.

Any idea on this?

Thanks.

Warm Regards,

S.C.Wong

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Able to correct this bug by delete and append related DIV

Following are sample code:-


        document.getElementById("batch_item_content_list").innerHTML = html;

       

        // Remove the div first

        var parent = document.getElementById('batch_item_html').parentNode;

        var content = document.getElementById('batch_item_html').innerHTML;

        parent.removeChild(document.getElementById('batch_item_html'));


        // Recreate the div

        var div = document.createElement('div');

        div.setAttribute('id', 'batch_item_html');

        div.setAttribute('sup_html_type', 'batch_item_html');

       

        // Append the div to the parent

        parent.appendChild(div);


        document.getElementById('batch_item_html').innerHTML = content;