Browse Source

SONAR-16537 When switching tabs, scrolling the content back to the top

tags/9.6.0.59041
Revanshu Paliwal 1 year ago
parent
commit
51f2a5f82d
1 changed files with 3 additions and 0 deletions
  1. 3
    0
      server/sonar-web/src/main/js/components/rules/RuleDescription.tsx

+ 3
- 0
server/sonar-web/src/main/js/components/rules/RuleDescription.tsx View File

@@ -171,6 +171,9 @@ export default class RuleDescription extends React.PureComponent<Props, State> {
markdown: isDefault,
'rule-desc': !isDefault
})}
ref={node => {
node?.scrollIntoView();
}}
// eslint-disable-next-line react/no-danger
dangerouslySetInnerHTML={{
__html: sanitizeString(sections[0].content)

Loading…
Cancel
Save