|
@@ -6,10 +6,12 @@ import { connect } from "react-redux";
|
|
import Settings from "./Settings";
|
|
import Settings from "./Settings";
|
|
import Playlists from "./Playlists";
|
|
import Playlists from "./Playlists";
|
|
import EditPlaylist from "./EditPlaylist";
|
|
import EditPlaylist from "./EditPlaylist";
|
|
|
|
+import SearchYouTube from "./SearchYouTube";
|
|
|
|
|
|
@connect(state => ({
|
|
@connect(state => ({
|
|
overlay1: state.stationOverlay.get("overlay1"),
|
|
overlay1: state.stationOverlay.get("overlay1"),
|
|
overlay2: state.stationOverlay.get("overlay2"),
|
|
overlay2: state.stationOverlay.get("overlay2"),
|
|
|
|
+ overlay3: state.stationOverlay.get("overlay3"),
|
|
extraProps2: state.stationOverlay.get("extraProps2"),
|
|
extraProps2: state.stationOverlay.get("extraProps2"),
|
|
}))
|
|
}))
|
|
export default class Overlays extends Component {
|
|
export default class Overlays extends Component {
|
|
@@ -19,6 +21,7 @@ export default class Overlays extends Component {
|
|
this.state = {
|
|
this.state = {
|
|
overlay1: null,
|
|
overlay1: null,
|
|
overlay2: null,
|
|
overlay2: null,
|
|
|
|
+ overlay3: null,
|
|
};
|
|
};
|
|
}
|
|
}
|
|
|
|
|
|
@@ -27,6 +30,7 @@ export default class Overlays extends Component {
|
|
if (type === "settings") input = <Settings t={ this.props.t } key={ key }/>;
|
|
if (type === "settings") input = <Settings t={ this.props.t } key={ key }/>;
|
|
else if (type === "playlists") input = <Playlists t={ this.props.t } key={ key }/>;
|
|
else if (type === "playlists") input = <Playlists t={ this.props.t } key={ key }/>;
|
|
else if (type === "editPlaylist") input = <EditPlaylist t={ this.props.t } key={ key } playlistId={ this.props.extraProps2.get("playlistId") }/>;
|
|
else if (type === "editPlaylist") input = <EditPlaylist t={ this.props.t } key={ key } playlistId={ this.props.extraProps2.get("playlistId") }/>;
|
|
|
|
+ else if (type === "searchYouTube") input = <SearchYouTube t={ this.props.t } key={ key }/>;
|
|
return input;
|
|
return input;
|
|
};
|
|
};
|
|
|
|
|
|
@@ -41,12 +45,18 @@ export default class Overlays extends Component {
|
|
overlay2: this.getComponent(this.props.overlay2),
|
|
overlay2: this.getComponent(this.props.overlay2),
|
|
});
|
|
});
|
|
}
|
|
}
|
|
|
|
+ if (this.props.overlay3 !== prevProps.overlay3) {
|
|
|
|
+ this.setState({
|
|
|
|
+ overlay3: this.getComponent(this.props.overlay3),
|
|
|
|
+ });
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
render() {
|
|
render() {
|
|
return <div>
|
|
return <div>
|
|
{ this.state.overlay1 }
|
|
{ this.state.overlay1 }
|
|
{ this.state.overlay2 }
|
|
{ this.state.overlay2 }
|
|
|
|
+ { this.state.overlay3 }
|
|
</div>;
|
|
</div>;
|
|
}
|
|
}
|
|
}
|
|
}
|