moodle-block_openai_chat icon indicating copy to clipboard operation
moodle-block_openai_chat copied to clipboard

CSS rule breaking behat test for Moodle 4.5.2

Open jgg9026 opened this issue 9 months ago • 0 comments
trafficstars

Hi,

The following CSS rule from the blocks/openai_chat/styles.css is breaking a behat test that changes the window to a mobile size.

.drawerheader { pointer-events: none; }

In my opinion this CSS styling is way to general. This rule is preventing the link of the drawer header to redirect to the main page.

This is the output:

001 Scenario: Users could use primary nav menu on mobile size screens # /var/www/html/theme/boost/tests/behat/primarynav.feature:50 And I click on "[data-region='site-home-link']" "css_element" # /var/www/html/theme/boost/tests/behat/primarynav.feature:57 element click intercepted: Element <a href="http://webserver/my/" title="Acceptance test site" data-region="site-home-link" class="aabtn text-reset d-flex align-items-center py-1 h-100 d-md-none">...</a> is not clickable at point (139, 30). Other element would receive the click: <div class="drawer drawer-left drawer-primary d-print-none show" data-region="fixed-drawer" id="theme_boost-drawers-primary" data-preference="" data-state="show-drawer-primary" data-forceopen="0" data-close-on-resize="1">...</div> (Session info: chrome=124.0.6367.78) (Facebook\WebDriver\Exception\ElementClickInterceptedException)

After a quick look I couldn't see the purpose is for that rule and of the next one which is:

.drawerheader button { pointer-events: all; }

is it code used for testing purposes? is it ok if I just remove at least the first rule?

Thanks

jgg9026 avatar Feb 13 '25 05:02 jgg9026