Unplanned
Last Updated: 05 Jul 2023 08:54 by ADMIN
Manuel
Created on: 03 May 2023 10:32
Category: Grid
Type: Bug Report
5
Filter Menu in Column Menu - filter value is reset upon calling Rebind

When using the Filter Menu inside the Column Menu filter value is reset if Rebind is called. For reference, if using FIlter Row or a standalone Filter Menu value is not reset upon invoking Rebind.

Reproduction: https://blazorrepl.telerik.com/mdOJYHas48vPCPUv47.

2 comments
ADMIN
Yanislav
Posted on: 05 Jul 2023 08:54

Hello Steve,

In general, if any viable workarounds emerge, we will share them as comments here in the public discussions. Currently, we are not aware of any viable workarounds for this specific bug. Regarding your question on how to track when the filter menu is open, you can hook into the click event of the body and track which element the user clicks on. If the element happens to be a column menu option and the text of the element is "Filter," then it indicates that the clicked element is the one responsible for opening the filter menu.

<script suppress-error="BL9992">
    const body = document.getElementsByTagName("body")[0]

    body.addEventListener("click", (event) => {
        if(event.target.textContent.includes("Filter") && event.target.classList.contains('k-columnmenu-item')) {
            console.log("filter is opened")
        }
    })
</script>

Here is a REPL example that demonstrates this approach: https://blazorrepl.telerik.com/cnkLaTYs38kErCBT10

I hope this helps.

Regards,
Yanislav
Progress Telerik

As of R2 2023, the default icon type will be SVG instead of Font. See this blogpost for more information.
Steve
Posted on: 28 Jun 2023 17:11
I'm having this exact problem, are there any work arounds for this , like a way to detect the filter menu is open ?