Fix search dropdown

Created on 6 May 2025, 10 days ago

Problem/Motivation

After upgrading to D11, the eStore stopped working because of the new jQuery version (4), the search dropdown menu is not working anymore

Steps to reproduce

Install the eStore theme in a D11 instance, click in the search icon, the dropdown wont show up

Proposed resolution

Modify the HTML structure of the search dropdown to fix it after the new modified BS3 is installed

Remaining tasks

N/A

User interface changes

N/A

API changes

N/A

Data model changes

N/A

🐛 Bug report
Status

Active

Version

2.2

Component

Code

Created by

🇨🇦Canada danrod Ottawa

Live updates comments and jobs are added and updated live.
  • Novice

    It would make a good project for someone who is new to the Drupal contribution process. It's preferred over Newbie.

Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @danrod
  • 🇨🇦Canada danrod Ottawa

    Looking at the JS Console, I see this issue:

    Uncaught TypeError: $.camelCase is not a function
        at Collapse.show (bootstrap.js?svv6vg:710:24)
        at Collapse.toggle (bootstrap.js?svv6vg:756:57)
        at new Collapse (bootstrap.js?svv6vg:650:35)
        at HTMLDivElement.<anonymous> (bootstrap.js?svv6vg:797:52)
        at T.each (jquery.min.js?v=4.0.0-beta.2:2:2876)
        at T.fn.init.each (jquery.min.js?v=4.0.0-beta.2:2:1386)
        at T.fn.init.Plugin [as collapse] (bootstrap.js?svv6vg:791:17)
        at HTMLButtonElement.<anonymous> (bootstrap.js?svv6vg:829:12)
        at HTMLDocument.dispatch (jquery.min.js?v=4.0.0-beta.2:2:38062)
        at v.handle (jquery.min.js?v=4.0.0-beta.2:2:36042)
    

    It seems likebootstrap.js is using a function that is deprecated in jQuery around 2016: https://github.com/jquery/jquery/issues/3384

  • 🇨🇦Canada danrod Ottawa

    I was able to make the collapse functionality to work by forking the project and adding the missing functions, screenshot:

    There's some styling to do and I need to update the README.md file but at least it is working for now.

  • Merge request !25Issue # 3522990: Fix the dropdown search button → (Merged) created by danrod
  • 🇨🇦Canada danrod Ottawa

    I applied some changes and It looks much better than It was before, even on mobile:

    I'll move it to "Needs Review" but I think this can be moved to "Fixed" soon in order to merge it to the 2.2.x branch and fix some issues related with the search bar.

  • 🇨🇦Canada danrod Ottawa
  • 🇨🇦Canada danrod Ottawa
  • 🇨🇦Canada danrod Ottawa

    I just merged it to the 2.2.x branch because I really need the changes for fixing the issue # 3328586

Production build 0.71.5 2024