Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Fix storybook
dominik-zeglen5f64a472807a
diff --git a/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx b/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsxindex b4aae1a2b9..a0a3603317 100644--- a/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx+++ b/saleor/static/dashboard-next/collections/components/CollectionDetailsPage/CollectionDetailsPage.tsx@@ -169,6 +169,7 @@ const CollectionDetailsPage = decorate<CollectionDetailsPageProps>(</div></div><SaveButtonBar+ onCancel={onBack}onDelete={toggleRemoveDialog}onSave={submit}disabled={disabled || !onSubmit || !hasChanged}diff --git a/saleor/static/dashboard-next/productTypes/fixtures.ts b/saleor/static/dashboard-next/productTypes/fixtures.tsindex d1184667a6..71f2035513 100644--- a/saleor/static/dashboard-next/productTypes/fixtures.ts+++ b/saleor/static/dashboard-next/productTypes/fixtures.ts@@ -1,3 +1,5 @@+import { TaxRateType } from "../gql-types";+export const productTypes = [{hasVariants: true,@@ -995,7 +997,7 @@ export const productType = {],totalCount: 4},- taxRate: "standard",+ taxRate: TaxRateType.ACCOMODATION,variantAttributes: {edges: [{diff --git a/saleor/static/dashboard-next/storybook/__snapshots__/Stories.test.ts.snap b/saleor/static/dashboard-next/storybook/__snapshots__/Stories.test.ts.snapindex e59e772bad..e1233e2d3f 100644--- a/saleor/static/dashboard-next/storybook/__snapshots__/Stories.test.ts.snap+++ b/saleor/static/dashboard-next/storybook/__snapshots__/Stories.test.ts.snap@@ -16308,7 +16308,7 @@ exports[`Storyshots Views / Configuration default 1`] = `class="Component-root-id"><div- class="MuiPaper-root-id MuiPaper-elevation1-id MuiPaper-rounded-id MuiCard-root-id Component-cardDisabled-id"+ class="MuiPaper-root-id MuiPaper-elevation1-id MuiPaper-rounded-id MuiCard-root-id Component-card-id"><divclass="MuiCardContent-root-id Component-cardContent-id"@@ -25491,12 +25491,12 @@ exports[`Storyshots Views / Product types / Product type details default 1`] = `role="button"tabindex="0">- standard+ ACCOMODATION</div><inputname="taxRate"type="hidden"- value="standard"+ value="ACCOMODATION"/><svgaria-hidden="true"diff --git a/saleor/static/dashboard-next/storybook/stories/productTypes/ProductTypeDetailsPage.tsx b/saleor/static/dashboard-next/storybook/stories/productTypes/ProductTypeDetailsPage.tsxindex 5c0d410e65..8f88dfb017 100644--- a/saleor/static/dashboard-next/storybook/stories/productTypes/ProductTypeDetailsPage.tsx+++ b/saleor/static/dashboard-next/storybook/stories/productTypes/ProductTypeDetailsPage.tsx@@ -1,17 +1,19 @@import { storiesOf } from "@storybook/react";import * as React from "react";+import { TaxRateType } from "../../../gql-types";import ProductTypeDetailsPage from "../../../productTypes/components/ProductTypeDetailsPage";import { attributes, productType } from "../../../productTypes/fixtures";import Decorator from "../../Decorator";-const taxRates = ["standard", "electronics", "food", "apparel"];+const taxRates = Object.keys(TaxRateType).map(key => TaxRateType[key]);storiesOf("Views / Product types / Product type details", module).addDecorator(Decorator).add("default", () => (<ProductTypeDetailsPagedisabled={false}+ errors={[]}pageTitle={productType.name}productType={productType}productAttributes={productType.productAttributes.edges.map(@@ -33,6 +35,7 @@ storiesOf("Views / Product types / Product type details", module).add("loading", () => (<ProductTypeDetailsPagedisabled={true}+ errors={[]}pageTitle={undefined}saveButtonBarState="default"searchLoading={false}