Loading texts in TOC - Scroll view port

Comments

1 comment

  • Avatar
    Steffen Burzlaff

    Hi Sukumar,

    thanks for reaching out to us!

    The TOC is displaying two times because in your page.vm you inserted the TOC script twice: Once as a minified version and as an unminified version.

    Please remove on of them and your TOC won't show up twice. ( I recommend to remove the unminified script <script src="${theme.baseUrl}/jquery.toc.js"></script> ).

     

    To fix the issue with the "loading" showing up, please do the following:

    in your page.vm, replace your current <ul data-toc></ul> with the following:

     

    <ul data-toc data-toc-headings="headings"></ul>

     

    In your scroll-help.js file at the bottom, you have a document.ready function. Here please add the following line:

    $(document).ready(function () {

        .

        .

        .       

        auiTabsSetup();

        $("[data-toc]").toc({content: "body", headings: ":not(.ui-loader) > h1,:not(.ui-loader) > h2,:not(.ui-loader) > h3"});

    });

    The script from your TOC plugin will now look for the data-toc-heading attribute and gets the parameter "headings". The parameter contains the settings we need to use, to hide the loading heading in your TOC.

    This is everything you have to do, let me know if you have any questions or if you ran into any problems.

    Thanks and have a nice day.

    Best,
    Steffen

Please sign in to leave a comment.

Powered by Zendesk