added value prop to reflect changes to the q parameter in the url, used new FilterInput component in pageActions

This commit is contained in:
Florian Scholdei
2019-04-17 16:35:17 +02:00
parent b3de87a343
commit 6f975acd21
4 changed files with 108 additions and 55 deletions

View File

@@ -6,6 +6,7 @@ import { translate } from "react-i18next";
type Props = {
filter: string => void,
value?: string,
// context props
classes: Object,
@@ -30,7 +31,7 @@ const styles = {
class FilterInput extends React.Component<Props, State> {
constructor(props) {
super(props);
this.state = { value: "" };
this.state = { value: this.props.value ? this.props.value : "" };
}
handleChange = event => {