diff --git a/assets/docs/components/table.md b/assets/docs/components/table.md index be241025..727bc35c 100644 --- a/assets/docs/components/table.md +++ b/assets/docs/components/table.md @@ -265,7 +265,7 @@ if (typeof window !== "undefined") { var isActive = btn.getAttribute('data-dt-sort') === state.sortKey; var target = isActive ? state.sortDir : 'none'; btn.querySelectorAll('[data-dt-sort-icon]').forEach(function (icon) { - icon.style.display = icon.getAttribute('data-dt-sort-icon') === target ? '' : 'none'; + icon.style.display = icon.getAttribute('data-dt-sort-icon') === target ? 'inline' : 'none'; }); }); }; diff --git a/components/ui/table.py b/components/ui/table.py index f7c3d132..8c1af50d 100644 --- a/components/ui/table.py +++ b/components/ui/table.py @@ -154,7 +154,7 @@ def _sort_icons() -> list[Component]: var isActive = btn.getAttribute('data-dt-sort') === state.sortKey; var target = isActive ? state.sortDir : 'none'; btn.querySelectorAll('[data-dt-sort-icon]').forEach(function (icon) { - icon.style.display = icon.getAttribute('data-dt-sort-icon') === target ? '' : 'none'; + icon.style.display = icon.getAttribute('data-dt-sort-icon') === target ? 'inline' : 'none'; }); }); };