django-jazzmin
django-jazzmin copied to clipboard
[Bug report/Question] Unicode tab-names links don't work
Hi!
Problem:
If your tab name has any Unicode chars, it works as expected till you want to use the generated URL to access that tab directly.
E.g.: The tab "Oprávnění" generates this: #oprávnění-tab
- If I try to go to this URL directly I end up on the first tab ("Obecné" in this case). If there is a tab only with ASCII, it works great.
Question:
Why there is the allow Unicode option ON on slugify? Apart its name unicode_slugify
:)
https://github.com/farridav/django-jazzmin/blob/a69840caa7639daee8400710a877038efa1a7cc1/jazzmin/templatetags/jazzmin.py#L538
Using only ASCII chars in href seems to solve this. https://github.com/farridav/django-jazzmin/blob/6c6f88c8cacacf3f6dfae7aacee17e644eb4c39f/jazzmin/templates/jazzmin/includes/horizontal_tabs.html#L8
Is there some real usage, that needs to be Unicode? If yes, can there be another slugifier for generating tabs ids/href that will return only ASCII?