### Apache Airflow version

2.7.0

### What happened

Actual Behavior:
Upon entering a keyword in the search bar, no search results are shown, and the UI remains unchanged. The search function seems to be non-responsive.
You can see in the address bar, `undefined` appears instead of valid value.
<img width="1427" alt="step-1" src="https://github.com/apache/airflow/assets/17428690/10da4758-a614-48c8-a926-6bc69f8595f1">
<img width="1433" alt="step-2" src="https://github.com/apache/airflow/assets/17428690/be8912f2-e49e-40ca-86f7-1803b516482e">


### What you think should happen instead

Expected Behavior:
When I use the search function in the Airflow UI, I expect to see a list of results that match the entered keyword. This should help me quickly locate specific DAGs or tasks within the UI.

### How to reproduce

Steps to Reproduce:
1. Log in to the Airflow UI.
2. Navigate to the "Connections" list view by clicking on the "Connections" link in the navigation menu or by directly visiting the URL: <your_airflow_ui_url>/connection/list/.
3. Attempt to use the search function by entering a keyword.
4. Observe that no search results are displayed, and the search appears to do nothing.

### Operating System

MacOS

### Versions of Apache Airflow Providers

_No response_

### Deployment

Other

### Deployment details

Standalone Airflow via official Quickstart documentation

### Anything else

I encounter this issue since `Airflow 2.6.0`. It was fine on `Airflow 2.5.3`.

### Are you willing to submit PR?

- [ ] Yes I am willing to submit a PR!

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)

"presto",
    "trino",
    "vertica",
]
def get_all_db_dependencies() -> list[str]:
    _all_db_reqs: set[str] = set()
    for provider in ALL_DB_PROVIDERS:
        if provider not in PROVIDER_DEPENDENCIES:
            continue
        for req in PROVIDER_DEPENDENCIES[provider][DEPS]:
            _all_db_reqs.add(req)
    return list(_all_db_reqs)
all_dbs = get_all_db_dependencies()
EXTRAS_DEPENDENCIES["all_dbs"] = all_dbs
_all_dependencies = get_unique_dependency_list(EXTRAS_DEPENDENCIES.values())
_all_dependencies_without_airflow_providers = [k for k in _all_dependencies if "apache-airflow-" not in k]
EXTRAS_DEPENDENCIES["all"] = _all_dependencies_without_airflow_providers
devel_all = get_unique_dependency_list(
    [_all_dependencies_without_airflow_providers, doc, doc_gen, devel, devel_hadoop]
)
PACKAGES_EXCLUDED_FOR_ALL: list[str] = []
def is_package_excluded(package: str, exclusion_list: list[str]) -> bool:
    """
    Check if package should be excluded.
    :param package: package name (beginning of it)
    :param exclusion_list: list of excluded packages
    :return: true if package should be excluded
    """
    return package.startswith(tuple(exclusion_list))
def remove_provider_limits(package: str) -> str: