Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Make container use constant width

dominik-zeglen020e2e7e4071
diff --git a/saleor/static/dashboard-next/auth/components/LoginPage/LoginPage.tsx b/saleor/static/dashboard-next/auth/components/LoginPage/LoginPage.tsx
index d83e4cad37..08ce5c88e1 100644
--- a/saleor/static/dashboard-next/auth/components/LoginPage/LoginPage.tsx
+++ b/saleor/static/dashboard-next/auth/components/LoginPage/LoginPage.tsx
@@ -68,7 +68,10 @@ const styles = (theme: Theme) =>
},
alignItems: "center",
display: "flex",
- height: "100vh"
+ height: "100vh",
+ marginLeft: "auto",
+ marginRight: "auto",
+ maxWidth: theme.breakpoints.width("sm")
}
});
@@ -87,7 +90,7 @@ const LoginCard = withStyles(styles, { name: "LoginCard" })(
onSubmit={onSubmit}
>
{({ change: handleChange, data, submit: handleSubmit }) => (
- <Container className={classes.root} width="sm">
+ <div className={classes.root}>
<Card className={classes.card}>
<SVG className={classes.logo} src={saleorLogo} />
{error && (
@@ -144,7 +147,7 @@ const LoginCard = withStyles(styles, { name: "LoginCard" })(
{i18n.t("Reset your password")}
</Typography> */}
</Card>
- </Container>
+ </div>
)}
</Form>
);
diff --git a/saleor/static/dashboard-next/categories/components/CategoryCreatePage/CategoryCreatePage.tsx b/saleor/static/dashboard-next/categories/components/CategoryCreatePage/CategoryCreatePage.tsx
index 630bd11086..57749dac7c 100644
--- a/saleor/static/dashboard-next/categories/components/CategoryCreatePage/CategoryCreatePage.tsx
+++ b/saleor/static/dashboard-next/categories/components/CategoryCreatePage/CategoryCreatePage.tsx
@@ -51,7 +51,7 @@ export const CategoryCreatePage: React.StatelessComponent<
confirmLeave
>
{({ data, change, errors, submit, hasChanged }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Categories")}</AppHeader>
<PageHeader title={i18n.t("Add Category")} />
<div>
diff --git a/saleor/static/dashboard-next/categories/components/CategoryListPage/CategoryListPage.tsx b/saleor/static/dashboard-next/categories/components/CategoryListPage/CategoryListPage.tsx
index 5e7f5cf341..660d596a2c 100644
--- a/saleor/static/dashboard-next/categories/components/CategoryListPage/CategoryListPage.tsx
+++ b/saleor/static/dashboard-next/categories/components/CategoryListPage/CategoryListPage.tsx
@@ -30,7 +30,7 @@ export const CategoryListPage: React.StatelessComponent<CategoryTableProps> = ({
onRowClick,
pageInfo
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Category")}>
<Button color="secondary" variant="contained" onClick={onAdd}>
{i18n.t("Add category")} <AddIcon />
diff --git a/saleor/static/dashboard-next/categories/components/CategoryUpdatePage/CategoryUpdatePage.tsx b/saleor/static/dashboard-next/categories/components/CategoryUpdatePage/CategoryUpdatePage.tsx
index aa09a49c7d..66da357c8d 100644
--- a/saleor/static/dashboard-next/categories/components/CategoryUpdatePage/CategoryUpdatePage.tsx
+++ b/saleor/static/dashboard-next/categories/components/CategoryUpdatePage/CategoryUpdatePage.tsx
@@ -113,7 +113,7 @@ export const CategoryUpdatePage: React.StatelessComponent<
confirmLeave
>
{({ data, change, errors, submit, hasChanged }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Categories")}</AppHeader>
<PageHeader title={category ? category.name : undefined} />
<CategoryDetailsForm
diff --git a/saleor/static/dashboard-next/collections/components/CollectionCreatePage/CollectionCreatePage.tsx b/saleor/static/dashboard-next/collections/components/CollectionCreatePage/CollectionCreatePage.tsx
index ffae64d022..8639c9bc2d 100644
--- a/saleor/static/dashboard-next/collections/components/CollectionCreatePage/CollectionCreatePage.tsx
+++ b/saleor/static/dashboard-next/collections/components/CollectionCreatePage/CollectionCreatePage.tsx
@@ -64,7 +64,7 @@ const CollectionCreatePage: React.StatelessComponent<
}: CollectionCreatePageProps) => (
<Form errors={errors} initial={initialForm} onSubmit={onSubmit}>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Collections")}</AppHeader>
<PageHeader
title={i18n.t("Add collection", {
diff --git a/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx b/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx
index 3cc74cd2c6..df834ba484 100644
--- a/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx
+++ b/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx
@@ -69,7 +69,7 @@ const CollectionDetailsPage: React.StatelessComponent<
confirmLeave
>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Collections")}</AppHeader>
<PageHeader title={maybe(() => collection.name)} />
<Grid>
diff --git a/saleor/static/dashboard-next/collections/components/CollectionListPage/CollectionListPage.tsx b/saleor/static/dashboard-next/collections/components/CollectionListPage/CollectionListPage.tsx
index 77c4bd47d2..a9221cd01c 100644
--- a/saleor/static/dashboard-next/collections/components/CollectionListPage/CollectionListPage.tsx
+++ b/saleor/static/dashboard-next/collections/components/CollectionListPage/CollectionListPage.tsx
@@ -18,7 +18,7 @@ const CollectionListPage: React.StatelessComponent<CollectionListPageProps> = ({
onAdd,
...listProps
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Collections", { context: "page title" })}>
<Button
color="secondary"
diff --git a/saleor/static/dashboard-next/components/AppLayout/AppLayout.tsx b/saleor/static/dashboard-next/components/AppLayout/AppLayout.tsx
index 390420dad6..788412034f 100644
--- a/saleor/static/dashboard-next/components/AppLayout/AppLayout.tsx
+++ b/saleor/static/dashboard-next/components/AppLayout/AppLayout.tsx
@@ -183,7 +183,7 @@ const AppLayout = withStyles(styles, {
</div>
<div className={classes.content}>
<div>
- <Container width="md">
+ <Container >
<div className={classes.header}>
<div ref={appHeaderAnchor} />
<div
diff --git a/saleor/static/dashboard-next/components/Container.tsx b/saleor/static/dashboard-next/components/Container.tsx
index bd2f913b99..2827db85bc 100644
--- a/saleor/static/dashboard-next/components/Container.tsx
+++ b/saleor/static/dashboard-next/components/Container.tsx
@@ -4,37 +4,28 @@ import {
withStyles,
WithStyles
} from "@material-ui/core/styles";
-import { CSSProperties } from "@material-ui/core/styles/withStyles";
import * as classNames from "classnames";
import * as React from "react";
const styles = (theme: Theme) =>
- createStyles(
- ["xs", "sm", "md", "lg", "xl"].reduce<Record<string, CSSProperties>>(
- (prev, current) => {
- prev[current] = {
- [theme.breakpoints.up(current as any)]: {
- marginLeft: "auto",
- marginRight: "auto",
- maxWidth: theme.breakpoints.width(current as any)
- }
- };
- return prev;
- },
- {}
- )
- );
+ createStyles({
+ root: {
+ [theme.breakpoints.up("lg")]: {
+ marginLeft: "auto",
+ marginRight: "auto",
+ maxWidth: theme.breakpoints.width("lg")
+ }
+ }
+ });
-interface ContainerProps extends WithStyles<typeof styles, true> {
+interface ContainerProps extends WithStyles<typeof styles> {
className?: string;
- width: "xs" | "sm" | "md" | "lg" | "xl";
}
export const Container = withStyles(styles, {
- name: "Container",
- withTheme: true
-})(({ classes, className, width, theme, ...props }: ContainerProps) => (
- <div className={classNames(classes[width], className)} {...props} />
+ name: "Container"
+})(({ classes, className, ...props }: ContainerProps) => (
+ <div className={classNames(classes.root, className)} {...props} />
));
Container.displayName = "Container";
export default Container;
diff --git a/saleor/static/dashboard-next/components/SaveButtonBar/SaveButtonBar.tsx b/saleor/static/dashboard-next/components/SaveButtonBar/SaveButtonBar.tsx
index 26d8ed24f2..953cf8f700 100644
--- a/saleor/static/dashboard-next/components/SaveButtonBar/SaveButtonBar.tsx
+++ b/saleor/static/dashboard-next/components/SaveButtonBar/SaveButtonBar.tsx
@@ -97,7 +97,7 @@ export const SaveButtonBar = withStyles(styles, { name: "SaveButtonBar" })(
})}
{...props}
>
- <Container width="md" className={classes.container}>
+ <Container className={classes.container}>
{!!onDelete && (
<Button
variant="contained"
diff --git a/saleor/static/dashboard-next/configuration/ConfigurationPage.tsx b/saleor/static/dashboard-next/configuration/ConfigurationPage.tsx
index 9ce95e99ca..730ef1440c 100644
--- a/saleor/static/dashboard-next/configuration/ConfigurationPage.tsx
+++ b/saleor/static/dashboard-next/configuration/ConfigurationPage.tsx
@@ -77,7 +77,7 @@ export interface ConfigurationPageProps extends WithStyles<typeof styles> {
export const ConfigurationPage = withStyles(styles, {
name: "ConfigurationPage"
})(({ classes, menu, user, onSectionClick }: ConfigurationPageProps) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Configure")} />
<div className={classes.root}>
{menu
diff --git a/saleor/static/dashboard-next/customers/components/CustomerCreatePage/CustomerCreatePage.tsx b/saleor/static/dashboard-next/customers/components/CustomerCreatePage/CustomerCreatePage.tsx
index 049f58a087..b2303d9e61 100644
--- a/saleor/static/dashboard-next/customers/components/CustomerCreatePage/CustomerCreatePage.tsx
+++ b/saleor/static/dashboard-next/customers/components/CustomerCreatePage/CustomerCreatePage.tsx
@@ -59,7 +59,7 @@ const CustomerCreatePage: React.StatelessComponent<CustomerCreatePageProps> = ({
}: CustomerCreatePageProps) => (
<Form initial={initialForm} onSubmit={onSubmit} errors={errors} confirmLeave>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Customers")}</AppHeader>
<PageHeader title={i18n.t("Add customer")} />
<Grid>
diff --git a/saleor/static/dashboard-next/customers/components/CustomerDetailsPage/CustomerDetailsPage.tsx b/saleor/static/dashboard-next/customers/components/CustomerDetailsPage/CustomerDetailsPage.tsx
index 530d7b980b..9868c11c83 100644
--- a/saleor/static/dashboard-next/customers/components/CustomerDetailsPage/CustomerDetailsPage.tsx
+++ b/saleor/static/dashboard-next/customers/components/CustomerDetailsPage/CustomerDetailsPage.tsx
@@ -65,7 +65,7 @@ const CustomerDetailsPage: React.StatelessComponent<
confirmLeave
>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Customers")}</AppHeader>
<PageHeader title={getUserName(customer, true)} />
<Grid>
diff --git a/saleor/static/dashboard-next/customers/components/CustomerListPage/CustomerListPage.tsx b/saleor/static/dashboard-next/customers/components/CustomerListPage/CustomerListPage.tsx
index 45b734499c..2ba1fa50f5 100644
--- a/saleor/static/dashboard-next/customers/components/CustomerListPage/CustomerListPage.tsx
+++ b/saleor/static/dashboard-next/customers/components/CustomerListPage/CustomerListPage.tsx
@@ -19,7 +19,7 @@ const CustomerListPage: React.StatelessComponent<CustomerListPageProps> = ({
onAdd,
...customerListProps
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Customers")}>
<Button
color="secondary"
diff --git a/saleor/static/dashboard-next/discounts/components/SaleCreatePage/SaleCreatePage.tsx b/saleor/static/dashboard-next/discounts/components/SaleCreatePage/SaleCreatePage.tsx
index 6dca2c3fcd..9d11e209e2 100644
--- a/saleor/static/dashboard-next/discounts/components/SaleCreatePage/SaleCreatePage.tsx
+++ b/saleor/static/dashboard-next/discounts/components/SaleCreatePage/SaleCreatePage.tsx
@@ -49,7 +49,7 @@ const SaleCreatePage: React.StatelessComponent<SaleCreatePageProps> = ({
return (
<Form errors={errors} initial={initialForm} onSubmit={onSubmit}>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Sales")}</AppHeader>
<PageHeader title={i18n.t("Create Sale")} />
<Grid>
diff --git a/saleor/static/dashboard-next/discounts/components/SaleDetailsPage/SaleDetailsPage.tsx b/saleor/static/dashboard-next/discounts/components/SaleDetailsPage/SaleDetailsPage.tsx
index 85898847e3..5fb1ffddd7 100644
--- a/saleor/static/dashboard-next/discounts/components/SaleDetailsPage/SaleDetailsPage.tsx
+++ b/saleor/static/dashboard-next/discounts/components/SaleDetailsPage/SaleDetailsPage.tsx
@@ -103,7 +103,7 @@ const SaleDetailsPage: React.StatelessComponent<SaleDetailsPageProps> = ({
return (
<Form errors={errors} initial={initialForm} onSubmit={onSubmit}>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Sales")}</AppHeader>
<PageHeader title={maybe(() => sale.name)} />
<Grid>
diff --git a/saleor/static/dashboard-next/discounts/components/SaleListPage/SaleListPage.tsx b/saleor/static/dashboard-next/discounts/components/SaleListPage/SaleListPage.tsx
index ce3ec5084f..4d756dd26c 100644
--- a/saleor/static/dashboard-next/discounts/components/SaleListPage/SaleListPage.tsx
+++ b/saleor/static/dashboard-next/discounts/components/SaleListPage/SaleListPage.tsx
@@ -24,7 +24,7 @@ const SaleListPage: React.StatelessComponent<SaleListPageProps> = ({
pageInfo,
sales
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Sales")}>
<Button onClick={onAdd} variant="contained" color="secondary">
{i18n.t("Add sale")}
diff --git a/saleor/static/dashboard-next/discounts/components/VoucherCreatePage/VoucherCreatePage.tsx b/saleor/static/dashboard-next/discounts/components/VoucherCreatePage/VoucherCreatePage.tsx
index 0136872b2d..86dd5641eb 100644
--- a/saleor/static/dashboard-next/discounts/components/VoucherCreatePage/VoucherCreatePage.tsx
+++ b/saleor/static/dashboard-next/discounts/components/VoucherCreatePage/VoucherCreatePage.tsx
@@ -63,7 +63,7 @@ const VoucherCreatePage: React.StatelessComponent<VoucherCreatePageProps> = ({
return (
<Form errors={errors} initial={initialForm} onSubmit={onSubmit}>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Vouchers")}</AppHeader>
<PageHeader title={i18n.t("Create Voucher")} />
<Grid>
diff --git a/saleor/static/dashboard-next/discounts/components/VoucherDetailsPage/VoucherDetailsPage.tsx b/saleor/static/dashboard-next/discounts/components/VoucherDetailsPage/VoucherDetailsPage.tsx
index 1c9cd86426..12205621b8 100644
--- a/saleor/static/dashboard-next/discounts/components/VoucherDetailsPage/VoucherDetailsPage.tsx
+++ b/saleor/static/dashboard-next/discounts/components/VoucherDetailsPage/VoucherDetailsPage.tsx
@@ -126,7 +126,7 @@ const VoucherDetailsPage: React.StatelessComponent<VoucherDetailsPageProps> = ({
return (
<Form errors={errors} initial={initialForm} onSubmit={onSubmit}>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Vouchers")}</AppHeader>
<PageHeader title={maybe(() => voucher.name)} />
<Grid>
diff --git a/saleor/static/dashboard-next/discounts/components/VoucherListPage/VoucherListPage.tsx b/saleor/static/dashboard-next/discounts/components/VoucherListPage/VoucherListPage.tsx
index 9d90b4a0f8..b1549ff4bf 100644
--- a/saleor/static/dashboard-next/discounts/components/VoucherListPage/VoucherListPage.tsx
+++ b/saleor/static/dashboard-next/discounts/components/VoucherListPage/VoucherListPage.tsx
@@ -24,7 +24,7 @@ const VoucherListPage: React.StatelessComponent<VoucherListPageProps> = ({
pageInfo,
vouchers
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Vouchers")}>
<Button onClick={onAdd} variant="contained" color="secondary">
{i18n.t("Add voucher")}
diff --git a/saleor/static/dashboard-next/home/components/HomePage/HomePage.tsx b/saleor/static/dashboard-next/home/components/HomePage/HomePage.tsx
index 5ed9b3810c..703a01ddf7 100644
--- a/saleor/static/dashboard-next/home/components/HomePage/HomePage.tsx
+++ b/saleor/static/dashboard-next/home/components/HomePage/HomePage.tsx
@@ -70,7 +70,7 @@ const HomePage = withStyles(styles, { name: "HomePage" })(
ordersToFulfill,
productsOutOfStock
}: HomePageProps) => (
- <Container width="md">
+ <Container >
<HomeHeader userName={userName} />
<CardSpacer />
<Grid>
diff --git a/saleor/static/dashboard-next/home/components/HomeScreen.tsx b/saleor/static/dashboard-next/home/components/HomeScreen.tsx
index 25dee21ca1..5d9e03c8a5 100644
--- a/saleor/static/dashboard-next/home/components/HomeScreen.tsx
+++ b/saleor/static/dashboard-next/home/components/HomeScreen.tsx
@@ -17,7 +17,7 @@ interface HomeScreenProps {
export const HomeScreen: React.StatelessComponent<HomeScreenProps> = ({
user
}) => (
- <Container width="md">
+ <Container >
<PageHeader
title={i18n.t("Hello there, {{userName}}", { userName: user.email })}
/>
diff --git a/saleor/static/dashboard-next/orders/components/OrderDetailsPage/OrderDetailsPage.tsx b/saleor/static/dashboard-next/orders/components/OrderDetailsPage/OrderDetailsPage.tsx
index 52b364d99d..f4171a1a56 100644
--- a/saleor/static/dashboard-next/orders/components/OrderDetailsPage/OrderDetailsPage.tsx
+++ b/saleor/static/dashboard-next/orders/components/OrderDetailsPage/OrderDetailsPage.tsx
@@ -90,7 +90,7 @@ const OrderDetailsPage = withStyles(styles, { name: "OrderDetailsPage" })(
);
return (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Orders")}</AppHeader>
<PageHeader
className={classes.header}
diff --git a/saleor/static/dashboard-next/orders/components/OrderDraftPage/OrderDraftPage.tsx b/saleor/static/dashboard-next/orders/components/OrderDraftPage/OrderDraftPage.tsx
index 7a1597f674..1b1c8c2452 100644
--- a/saleor/static/dashboard-next/orders/components/OrderDraftPage/OrderDraftPage.tsx
+++ b/saleor/static/dashboard-next/orders/components/OrderDraftPage/OrderDraftPage.tsx
@@ -89,7 +89,7 @@ const OrderDraftPage = withStyles(styles, { name: "OrderDraftPage" })(
users,
usersLoading
}: OrderDraftPageProps) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Orders")}</AppHeader>
<PageHeader
className={classes.header}
diff --git a/saleor/static/dashboard-next/orders/components/OrderListPage/OrderListPage.tsx b/saleor/static/dashboard-next/orders/components/OrderListPage/OrderListPage.tsx
index c6cf6cdd5b..20ed205481 100644
--- a/saleor/static/dashboard-next/orders/components/OrderListPage/OrderListPage.tsx
+++ b/saleor/static/dashboard-next/orders/components/OrderListPage/OrderListPage.tsx
@@ -37,7 +37,7 @@ const OrderListPage: React.StatelessComponent<OrderListPageProps> = ({
onToCapture,
onCustomFilter
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Orders")}>
<Button
color="secondary"
diff --git a/saleor/static/dashboard-next/pages/components/PageListPage/PageListPage.tsx b/saleor/static/dashboard-next/pages/components/PageListPage/PageListPage.tsx
index 89e8bdc449..a1998661ea 100644
--- a/saleor/static/dashboard-next/pages/components/PageListPage/PageListPage.tsx
+++ b/saleor/static/dashboard-next/pages/components/PageListPage/PageListPage.tsx
@@ -22,7 +22,7 @@ const PageListPage: React.StatelessComponent<PageListPageProps> = ({
pageInfo,
pages
}) => (
- <Container width="md">
+ <Container>
<PageHeader title={i18n.t("Pages")}>
<Button
disabled={disabled}
diff --git a/saleor/static/dashboard-next/productTypes/components/ProductTypeCreatePage/ProductTypeCreatePage.tsx b/saleor/static/dashboard-next/productTypes/components/ProductTypeCreatePage/ProductTypeCreatePage.tsx
index 455dd11f5f..a6b86a226d 100644
--- a/saleor/static/dashboard-next/productTypes/components/ProductTypeCreatePage/ProductTypeCreatePage.tsx
+++ b/saleor/static/dashboard-next/productTypes/components/ProductTypeCreatePage/ProductTypeCreatePage.tsx
@@ -61,7 +61,7 @@ const ProductTypeCreatePage: React.StatelessComponent<
confirmLeave
>
{({ change, data, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Product Types")}</AppHeader>
<PageHeader title={pageTitle} />
<Grid>
diff --git a/saleor/static/dashboard-next/productTypes/components/ProductTypeDetailsPage/ProductTypeDetailsPage.tsx b/saleor/static/dashboard-next/productTypes/components/ProductTypeDetailsPage/ProductTypeDetailsPage.tsx
index 9a906adc02..cd1782f067 100644
--- a/saleor/static/dashboard-next/productTypes/components/ProductTypeDetailsPage/ProductTypeDetailsPage.tsx
+++ b/saleor/static/dashboard-next/productTypes/components/ProductTypeDetailsPage/ProductTypeDetailsPage.tsx
@@ -109,7 +109,7 @@ const ProductTypeDetailsPage: React.StatelessComponent<
confirmLeave
>
{({ change, data, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Product Types")}</AppHeader>
<PageHeader title={pageTitle} />
<Grid>
diff --git a/saleor/static/dashboard-next/productTypes/components/ProductTypeListPage/ProductTypeListPage.tsx b/saleor/static/dashboard-next/productTypes/components/ProductTypeListPage/ProductTypeListPage.tsx
index ed7c32d1db..b76873128c 100644
--- a/saleor/static/dashboard-next/productTypes/components/ProductTypeListPage/ProductTypeListPage.tsx
+++ b/saleor/static/dashboard-next/productTypes/components/ProductTypeListPage/ProductTypeListPage.tsx
@@ -24,7 +24,7 @@ const ProductTypeListPage: React.StatelessComponent<
onPreviousPage,
onRowClick
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Product types")}>
<Button
color="secondary"
diff --git a/saleor/static/dashboard-next/products/components/ProductCreatePage/ProductCreatePage.tsx b/saleor/static/dashboard-next/products/components/ProductCreatePage/ProductCreatePage.tsx
index b15f6d0684..9b257c19c0 100644
--- a/saleor/static/dashboard-next/products/components/ProductCreatePage/ProductCreatePage.tsx
+++ b/saleor/static/dashboard-next/products/components/ProductCreatePage/ProductCreatePage.tsx
@@ -128,7 +128,7 @@ export const ProductCreatePage: React.StatelessComponent<
confirmLeave
>
{({ change, data, errors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Products")}</AppHeader>
<PageHeader title={header} />
<Grid>
diff --git a/saleor/static/dashboard-next/products/components/ProductImagePage/ProductImagePage.tsx b/saleor/static/dashboard-next/products/components/ProductImagePage/ProductImagePage.tsx
index aeedc47f6f..2cdead3bc4 100644
--- a/saleor/static/dashboard-next/products/components/ProductImagePage/ProductImagePage.tsx
+++ b/saleor/static/dashboard-next/products/components/ProductImagePage/ProductImagePage.tsx
@@ -77,7 +77,7 @@ const ProductImagePage = withStyles(styles, { name: "ProductImagePage" })(
>
{({ change, data, hasChanged, submit }) => {
return (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{product}</AppHeader>
<PageHeader title={i18n.t("Edit Photo")} />
<Grid variant="inverted">
diff --git a/saleor/static/dashboard-next/products/components/ProductListCard/ProductListCard.tsx b/saleor/static/dashboard-next/products/components/ProductListCard/ProductListCard.tsx
index 485b970902..ceb16ee3ab 100644
--- a/saleor/static/dashboard-next/products/components/ProductListCard/ProductListCard.tsx
+++ b/saleor/static/dashboard-next/products/components/ProductListCard/ProductListCard.tsx
@@ -39,7 +39,7 @@ export const ProductListCard: React.StatelessComponent<
onOfStock,
onCustomFilter
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Products")}>
<Button onClick={onAdd} color="secondary" variant="contained">
{i18n.t("Add product")} <AddIcon />
diff --git a/saleor/static/dashboard-next/products/components/ProductUpdatePage/ProductUpdatePage.tsx b/saleor/static/dashboard-next/products/components/ProductUpdatePage/ProductUpdatePage.tsx
index 85f95b6a01..9cff403ff1 100644
--- a/saleor/static/dashboard-next/products/components/ProductUpdatePage/ProductUpdatePage.tsx
+++ b/saleor/static/dashboard-next/products/components/ProductUpdatePage/ProductUpdatePage.tsx
@@ -202,7 +202,7 @@ export const ProductUpdate: React.StatelessComponent<ProductUpdateProps> = ({
>
{({ change, data, errors, hasChanged, submit }) => (
<>
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Products")}</AppHeader>
<PageHeader title={header} />
<Grid>
diff --git a/saleor/static/dashboard-next/products/components/ProductVariantCreatePage/ProductVariantCreatePage.tsx b/saleor/static/dashboard-next/products/components/ProductVariantCreatePage/ProductVariantCreatePage.tsx
index 9b923161a4..7b95dbfd7d 100644
--- a/saleor/static/dashboard-next/products/components/ProductVariantCreatePage/ProductVariantCreatePage.tsx
+++ b/saleor/static/dashboard-next/products/components/ProductVariantCreatePage/ProductVariantCreatePage.tsx
@@ -75,7 +75,7 @@ const ProductVariantCreatePage: React.StatelessComponent<
key={product ? JSON.stringify(product) : "noproduct"}
>
{({ change, data, errors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{maybe(() => product.name)}</AppHeader>
<PageHeader title={header} />
<Grid variant="inverted">
diff --git a/saleor/static/dashboard-next/products/components/ProductVariantPage/ProductVariantPage.tsx b/saleor/static/dashboard-next/products/components/ProductVariantPage/ProductVariantPage.tsx
index c747636492..65c8322f63 100644
--- a/saleor/static/dashboard-next/products/components/ProductVariantPage/ProductVariantPage.tsx
+++ b/saleor/static/dashboard-next/products/components/ProductVariantPage/ProductVariantPage.tsx
@@ -61,7 +61,7 @@ const ProductVariantPage: React.StatelessComponent<ProductVariantPageProps> = ({
<Toggle>
{(isImageSelectModalActive, { toggle: toggleImageSelectModal }) => (
<>
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>
{maybe(() => variant.product.name)}
</AppHeader>
diff --git a/saleor/static/dashboard-next/siteSettings/components/SiteSettingsPage/SiteSettingsPage.tsx b/saleor/static/dashboard-next/siteSettings/components/SiteSettingsPage/SiteSettingsPage.tsx
index 4af3b99b78..794fb09850 100644
--- a/saleor/static/dashboard-next/siteSettings/components/SiteSettingsPage/SiteSettingsPage.tsx
+++ b/saleor/static/dashboard-next/siteSettings/components/SiteSettingsPage/SiteSettingsPage.tsx
@@ -57,7 +57,7 @@ const SiteSettingsPage: React.StatelessComponent<SiteSettingsPageProps> = ({
confirmLeave
>
{({ change, data, errors: formErrors, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<PageHeader
title={i18n.t("General Information", {
context: "page header"
diff --git a/saleor/static/dashboard-next/staff/components/StaffDetailsPage/StaffDetailsPage.tsx b/saleor/static/dashboard-next/staff/components/StaffDetailsPage/StaffDetailsPage.tsx
index 077a0fbb70..1574b2ebb4 100644
--- a/saleor/static/dashboard-next/staff/components/StaffDetailsPage/StaffDetailsPage.tsx
+++ b/saleor/static/dashboard-next/staff/components/StaffDetailsPage/StaffDetailsPage.tsx
@@ -67,7 +67,7 @@ const StaffDetailsPage: React.StatelessComponent<StaffDetailsPageProps> = ({
return (
<Form initial={initialForm} onSubmit={onSubmit} confirmLeave>
{({ data, change, hasChanged, submit }) => (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Staff Members")}</AppHeader>
<PageHeader title={getUserName(staffMember)} />
<Grid>
diff --git a/saleor/static/dashboard-next/staff/components/StaffListPage/StaffListPage.tsx b/saleor/static/dashboard-next/staff/components/StaffListPage/StaffListPage.tsx
index 203b392e96..1c69a6ec78 100644
--- a/saleor/static/dashboard-next/staff/components/StaffListPage/StaffListPage.tsx
+++ b/saleor/static/dashboard-next/staff/components/StaffListPage/StaffListPage.tsx
@@ -23,7 +23,7 @@ const StaffListPage: React.StatelessComponent<StaffListPageProps> = ({
onPreviousPage,
onRowClick
}) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Staff members", { context: "page title" })}>
<Button
color="secondary"
diff --git a/saleor/static/dashboard-next/storybook/stories/components/AddressEdit.tsx b/saleor/static/dashboard-next/storybook/stories/components/AddressEdit.tsx
index 7b193a56b1..79f56a6bc6 100644
--- a/saleor/static/dashboard-next/storybook/stories/components/AddressEdit.tsx
+++ b/saleor/static/dashboard-next/storybook/stories/components/AddressEdit.tsx
@@ -2,7 +2,6 @@ import { storiesOf } from "@storybook/react";
import * as React from "react";
import AddressEdit from "../../../components/AddressEdit";
-import { Container } from "../../../components/Container";
import { customer } from "../../../customers/fixtures";
import { transformAddressToForm } from "../../../misc";
import { countries } from "../../../orders/fixtures";
@@ -11,12 +10,17 @@ import Decorator from "../../Decorator";
storiesOf("Generics / AddressEdit", module)
.addDecorator(Decorator)
.add("default", () => (
- <Container width="sm">
+ <div
+ style={{
+ margin: "auto",
+ width: 768
+ }}
+ >
<AddressEdit
errors={{}}
data={transformAddressToForm(customer.defaultBillingAddress)}
countries={countries}
onChange={undefined}
/>
- </Container>
+ </div>
));
diff --git a/saleor/static/dashboard-next/taxes/components/CountryListPage/CountryListPage.tsx b/saleor/static/dashboard-next/taxes/components/CountryListPage/CountryListPage.tsx
index a83e0e626a..e8c125be83 100644
--- a/saleor/static/dashboard-next/taxes/components/CountryListPage/CountryListPage.tsx
+++ b/saleor/static/dashboard-next/taxes/components/CountryListPage/CountryListPage.tsx
@@ -38,7 +38,7 @@ const CountryListPage: React.StatelessComponent<CountryListPageProps> = ({
return (
<Form initial={initialForm} onSubmit={onSubmit}>
{({ change, data, submit }) => (
- <Container width="md">
+ <Container >
<PageHeader title={i18n.t("Taxes", { context: "page title" })} />
<Grid>
<div>
diff --git a/saleor/static/dashboard-next/taxes/components/CountryTaxesPage/CountryTaxesPage.tsx b/saleor/static/dashboard-next/taxes/components/CountryTaxesPage/CountryTaxesPage.tsx
index d6f3ce4f2a..a6a3caedac 100644
--- a/saleor/static/dashboard-next/taxes/components/CountryTaxesPage/CountryTaxesPage.tsx
+++ b/saleor/static/dashboard-next/taxes/components/CountryTaxesPage/CountryTaxesPage.tsx
@@ -37,7 +37,7 @@ const CountryTaxesPage = withStyles(styles, { name: "CountryTaxesPage" })(
}: CountryTaxesPageProps & WithStyles<typeof styles>) => {
const taxRates = translatedTaxRates();
return (
- <Container width="md">
+ <Container >
<AppHeader onBack={onBack}>{i18n.t("Taxes")}</AppHeader>
<PageHeader
title={