Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Need investigation] Problem with searching numbers with decimals in Table #4008

Open
kikuomax opened this issue Feb 1, 2024 · 2 comments
Open

Comments

@kikuomax
Copy link
Collaborator

kikuomax commented Feb 1, 2024

This addition breaks the ability to search numbers with decimals. I fixed it for myself by adjusting the removeDiacriticsFromString() function to be:

export function removeDiacriticsFromString(value) {
if (!value) return value
if (typeof value === 'string' || value instanceof String) {
return value.normalize('NFD').replace(/[\u0300-\u036f]/g, '');
} else {
return value;
}
}

Screenshot buefy search decimal
Screenshot error buefy search decimal

Originally posted by @AN-WM in #3606 (comment)

@mcstover
Copy link

mcstover commented Feb 2, 2024

Just ran into this same issue, though in my case the value is an array. Pretty sure this line is calling removeDiacriticsFromString which uses normalize underneath. Numbers and arrays don't have the normalize method.

@kikuomax kikuomax added the bug label Feb 2, 2024
@mcstover
Copy link

mcstover commented Feb 2, 2024

Just following up to say I was able to work around the bug by using a customSearch function on that column.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants