You've already forked focalboard
mirror of
https://github.com/mattermost/focalboard.git
synced 2025-07-15 23:54:29 +02:00
Fix: ViewTitle update on board change
This commit is contained in:
@ -29,6 +29,16 @@ class ViewTitle extends React.Component<Props, State> {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static getDerivedStateFromProps(nextProps: Props, prevState: State) {
|
||||||
|
if (prevState.title !== nextProps.board.title) {
|
||||||
|
return {
|
||||||
|
title: nextProps.board.title,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return null
|
||||||
|
}
|
||||||
|
|
||||||
constructor(props: Props) {
|
constructor(props: Props) {
|
||||||
super(props)
|
super(props)
|
||||||
this.state = {title: props.board.title}
|
this.state = {title: props.board.title}
|
||||||
|
Reference in New Issue
Block a user