We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4a79674 commit 0517990Copy full SHA for 0517990
src/BootstrapBlazor/Components/TreeView/TreeView.razor.js
@@ -30,9 +30,9 @@ export function init(id, options) {
30
31
export function scroll(id, options) {
32
const el = document.getElementById(id);
33
- const item = el.querySelector(".active .tree-node");
+ const item = el.querySelector(".tree-content.active");
34
if (item) {
35
- item.scrollIntoView(options ?? { behavior: 'smooth', block: 'start', inline: 'nearest' });
+ item.parentElement.scrollTo(0, item.offsetTop, options || { behavior: 'smooth' });
36
}
37
38
0 commit comments