mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-09 15:05:44 +01:00
Fix broken markdown rendering
This commit is contained in:
@@ -6,6 +6,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
|
|
||||||
## Unreleased
|
## Unreleased
|
||||||
### Fixed
|
### Fixed
|
||||||
|
- Fix broken markdown rendering ([#1303](https://github.com/scm-manager/scm-manager/pull/1303))
|
||||||
- JWT token timeout is now handled properly ([#1297](https://github.com/scm-manager/scm-manager/pull/1297))
|
- JWT token timeout is now handled properly ([#1297](https://github.com/scm-manager/scm-manager/pull/1297))
|
||||||
- Fix text-overflow in danger zone ([#1298](https://github.com/scm-manager/scm-manager/pull/1298))
|
- Fix text-overflow in danger zone ([#1298](https://github.com/scm-manager/scm-manager/pull/1298))
|
||||||
- Fix plugin installation error if previously a plugin was installed with the same dependency which is still pending. ([#1300](https://github.com/scm-manager/scm-manager/pull/1300))
|
- Fix plugin installation error if previously a plugin was installed with the same dependency which is still pending. ([#1300](https://github.com/scm-manager/scm-manager/pull/1300))
|
||||||
|
|||||||
@@ -91,10 +91,11 @@ class MarkdownView extends React.Component<Props, State> {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
shouldComponentUpdate(nextProps: Readonly<Props>, nextState: Readonly<State>, nextContext: any): boolean {
|
shouldComponentUpdate(nextProps: Readonly<Props>, nextState: Readonly<State>): boolean {
|
||||||
// We have check if the contentRef changed and update afterwards so the page can scroll to the anchor links.
|
// We have check if the contentRef changed and update afterwards so the page can scroll to the anchor links.
|
||||||
// Otherwise it can happen that componentDidUpdate is never executed depending on how fast the markdown got rendered
|
// Otherwise it can happen that componentDidUpdate is never executed depending on how fast the markdown got rendered
|
||||||
return this.state.contentRef !== nextState.contentRef;
|
// We also have to check if props have changed, because we also want to rerender if one of our props has changed
|
||||||
|
return this.state.contentRef !== nextState.contentRef || this.props !== nextProps;
|
||||||
}
|
}
|
||||||
|
|
||||||
componentDidUpdate() {
|
componentDidUpdate() {
|
||||||
|
|||||||
Reference in New Issue
Block a user