mirror of
https://github.com/mattermost/focalboard.git
synced 2024-11-27 08:31:20 +02:00
Fix: ViewTitle update on board change
This commit is contained in:
parent
48719f16ce
commit
3ff889ebab
@ -29,6 +29,16 @@ class ViewTitle extends React.Component<Props, State> {
|
||||
return true
|
||||
}
|
||||
|
||||
static getDerivedStateFromProps(nextProps: Props, prevState: State) {
|
||||
if (prevState.title !== nextProps.board.title) {
|
||||
return {
|
||||
title: nextProps.board.title,
|
||||
}
|
||||
}
|
||||
|
||||
return null
|
||||
}
|
||||
|
||||
constructor(props: Props) {
|
||||
super(props)
|
||||
this.state = {title: props.board.title}
|
||||
|
Loading…
Reference in New Issue
Block a user