mirror of
https://github.com/smartxworks/sunmao-ui.git
synced 2025-04-12 21:50:23 +08:00
fix: don't scroll the tree item to top when clicking it
This commit is contained in:
parent
67fb8a0065
commit
c6c5fae8b2
@ -52,8 +52,8 @@ export const StructureTree: React.FC<Props> = props => {
|
||||
wrapperRef.current
|
||||
?.querySelector(`#tree-item-${selectedComponentId}`)
|
||||
?.scrollIntoView({
|
||||
behavior:'smooth',
|
||||
block:'center'
|
||||
block: 'nearest',
|
||||
inline: 'nearest'
|
||||
});
|
||||
}, [selectedComponentId]);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user