Forum Stats

  • 3,733,845 Users
  • 2,246,829 Discussions
  • 7,856,892 Comments

Discussions

Offcanvas Demo not working as expected

Philip Sommer
Philip Sommer Member Posts: 77 Red Ribbon

Hi Ojet-Team,


The demo at https://www.oracle.com/webfolder/technetwork/jet/jetCookbook.html?component=offcanvas&demo=basic is not working as expected form me using FF 88.0.1 (64bit). Following issues:

  1. None of the offcanvas can be toggled/opened multiple times. Opening the drawer a second time (after closing ofc), I first need to open a different one.
  2. I suspect related/causing (1): The ojClose eventlistener does not trigger on close. To check, add a simple console.log to the event listener and toggle a drawer.

I have some console errors/warnings which I attached to this post below.


Kind Regards,

Philip

Comments

  • John 'JB' Brock-Oracle
    John 'JB' Brock-Oracle Posts: 2,546 Employee

    Thanks for the heads up Philip, I've got an engineer looking into it to see if it's a demo bug or something in the component. Will get a reply to you shortly.

    --jb

  • John 'JB' Brock-Oracle
    John 'JB' Brock-Oracle Posts: 2,546 Employee

    Hi Philip,

    I'm told this is a known issue in the demo. It will be fixed in the next release (v11). From the engineer:

    ************************************

    It is a known bug in the Off-Canvas demo. Already fixed in main:

    The problem is that OffCanvas fires the custom ‘ojclose’ event as a jQuery event which cannot be handled using a standard listener registered by elem.addEventListener().

    It either needs a jquery handler registered via $(elem).on('ojclose', …), or as the 'onojclose' method defined on the DOM element. The latter approach is used in the 11 version of the demo, because we no longer expose jquery in Cookbook demos directly.

    ************************************

    Hope this helps you if you are seeing this in your code as well.

  • Philip Sommer
    Philip Sommer Member Posts: 77 Red Ribbon

    Hi John,


    Thank you for explaining. The suggested solution works for me as well.


    Kind Regards,

    Philip

Sign In or Register to comment.