Fix types
This commit is contained in:
parent
2e488f9436
commit
78132229af
7 changed files with 3 additions and 18 deletions
|
@ -150,7 +150,6 @@ const CollectionCreatePage: React.StatelessComponent<
|
||||||
errors={formErrors}
|
errors={formErrors}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
onChange={change}
|
onChange={change}
|
||||||
translate="collection"
|
|
||||||
/>
|
/>
|
||||||
</CardContent>
|
</CardContent>
|
||||||
</Card>
|
</Card>
|
||||||
|
|
|
@ -125,7 +125,6 @@ const CollectionDetailsPage: React.StatelessComponent<
|
||||||
errors={formErrors}
|
errors={formErrors}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
onChange={change}
|
onChange={change}
|
||||||
translate="collection"
|
|
||||||
>
|
>
|
||||||
<ControlledCheckbox
|
<ControlledCheckbox
|
||||||
name={"isFeatured" as keyof CollectionDetailsPageFormData}
|
name={"isFeatured" as keyof CollectionDetailsPageFormData}
|
||||||
|
|
|
@ -43,7 +43,6 @@ interface VisibilityCardProps extends WithStyles<typeof styles> {
|
||||||
errors: { [key: string]: string };
|
errors: { [key: string]: string };
|
||||||
disabled?: boolean;
|
disabled?: boolean;
|
||||||
onChange(event: any);
|
onChange(event: any);
|
||||||
translate: string;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export const VisibilityCard = withStyles(styles, {
|
export const VisibilityCard = withStyles(styles, {
|
||||||
|
@ -55,8 +54,7 @@ export const VisibilityCard = withStyles(styles, {
|
||||||
data: { isPublished, publicationDate },
|
data: { isPublished, publicationDate },
|
||||||
errors,
|
errors,
|
||||||
disabled,
|
disabled,
|
||||||
onChange,
|
onChange
|
||||||
translate
|
|
||||||
}: VisibilityCardProps) => {
|
}: VisibilityCardProps) => {
|
||||||
const intl = useIntl();
|
const intl = useIntl();
|
||||||
const [isPublicationDate, setPublicationDate] = React.useState(
|
const [isPublicationDate, setPublicationDate] = React.useState(
|
||||||
|
@ -77,8 +75,7 @@ export const VisibilityCard = withStyles(styles, {
|
||||||
defaultMessage: "since {date}"
|
defaultMessage: "since {date}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
date: localizeDate(publicationDate),
|
date: localizeDate(publicationDate)
|
||||||
description: translate
|
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
: null
|
: null
|
||||||
|
@ -92,8 +89,7 @@ export const VisibilityCard = withStyles(styles, {
|
||||||
defaultMessage: "will be visible from {date}"
|
defaultMessage: "will be visible from {date}"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
date: localizeDate(publicationDate),
|
date: localizeDate(publicationDate)
|
||||||
description: translate
|
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
: null
|
: null
|
||||||
|
|
|
@ -1,11 +1,5 @@
|
||||||
import Card from "@material-ui/core/Card";
|
import Card from "@material-ui/core/Card";
|
||||||
import CardContent from "@material-ui/core/CardContent";
|
import CardContent from "@material-ui/core/CardContent";
|
||||||
import {
|
|
||||||
createStyles,
|
|
||||||
Theme,
|
|
||||||
WithStyles,
|
|
||||||
withStyles
|
|
||||||
} from "@material-ui/core/styles";
|
|
||||||
import TextField from "@material-ui/core/TextField";
|
import TextField from "@material-ui/core/TextField";
|
||||||
import React from "react";
|
import React from "react";
|
||||||
import { useIntl } from "react-intl";
|
import { useIntl } from "react-intl";
|
||||||
|
|
|
@ -124,7 +124,6 @@ const PageDetailsPage: React.StatelessComponent<PageDetailsPageProps> = ({
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
errors={formErrors}
|
errors={formErrors}
|
||||||
onChange={change}
|
onChange={change}
|
||||||
translate="product"
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
|
@ -281,7 +281,6 @@ export const ProductCreatePage: React.StatelessComponent<
|
||||||
errors={errors}
|
errors={errors}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
onChange={change}
|
onChange={change}
|
||||||
translate="page"
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
|
@ -291,7 +291,6 @@ export const ProductUpdatePage: React.FC<ProductUpdatePageProps> = ({
|
||||||
errors={errors}
|
errors={errors}
|
||||||
disabled={disabled}
|
disabled={disabled}
|
||||||
onChange={change}
|
onChange={change}
|
||||||
translate="product"
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
Loading…
Reference in a new issue