Merge branch 'master' into fix-navigation
This commit is contained in:
commit
7c682ab685
91 changed files with 25882 additions and 14170 deletions
|
@ -25,3 +25,4 @@ All notable, unreleased changes to this project will be documented in this file.
|
||||||
- Add sorting to product list - #173 by @dominik-zeglen
|
- Add sorting to product list - #173 by @dominik-zeglen
|
||||||
- Add Heroku integration - #175 by @bogdal
|
- Add Heroku integration - #175 by @bogdal
|
||||||
- Fix navigation - #182 by @benekex2
|
- Fix navigation - #182 by @benekex2
|
||||||
|
- Add testcafe tags to attributes, categories, collections and product types - #178 by @dominik-zeglen
|
||||||
|
|
File diff suppressed because one or more lines are too long
958
locale/ar.po
958
locale/ar.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/az.po
958
locale/az.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/bg.po
958
locale/bg.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/bn.po
958
locale/bn.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/ca.po
958
locale/ca.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/cs.po
958
locale/cs.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/da.po
958
locale/da.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/de.po
958
locale/de.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/el.po
958
locale/el.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
966
locale/es.po
966
locale/es.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/es_CO.po
958
locale/es_CO.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
1207
locale/et.po
1207
locale/et.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/fa.po
958
locale/fa.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
1037
locale/fr.po
1037
locale/fr.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/hi.po
958
locale/hi.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/hu.po
958
locale/hu.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/hy.po
958
locale/hy.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/id.po
958
locale/id.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/is.po
958
locale/is.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/it.po
958
locale/it.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/ja.po
958
locale/ja.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/ko.po
958
locale/ko.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/mn.po
958
locale/mn.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/nb.po
958
locale/nb.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/nl.po
958
locale/nl.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/pl.po
958
locale/pl.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/pt.po
958
locale/pt.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/pt_BR.po
958
locale/pt_BR.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/ro.po
958
locale/ro.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/ru.po
958
locale/ru.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/sk.po
958
locale/sk.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/sl.po
958
locale/sl.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/sq.po
958
locale/sq.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/sr.po
958
locale/sr.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/sv.po
958
locale/sv.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/th.po
958
locale/th.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
967
locale/tr.po
967
locale/tr.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/uk.po
958
locale/uk.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
958
locale/vi.po
958
locale/vi.po
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load diff
|
@ -13,7 +13,7 @@ import Skeleton from "@saleor/components/Skeleton";
|
||||||
import TableHead from "@saleor/components/TableHead";
|
import TableHead from "@saleor/components/TableHead";
|
||||||
import TablePagination from "@saleor/components/TablePagination";
|
import TablePagination from "@saleor/components/TablePagination";
|
||||||
import { translateBoolean } from "@saleor/intl";
|
import { translateBoolean } from "@saleor/intl";
|
||||||
import { renderCollection } from "@saleor/misc";
|
import { maybe, renderCollection } from "@saleor/misc";
|
||||||
import { ListActions, ListProps } from "@saleor/types";
|
import { ListActions, ListProps } from "@saleor/types";
|
||||||
import { AttributeList_attributes_edges_node } from "../../types/AttributeList";
|
import { AttributeList_attributes_edges_node } from "../../types/AttributeList";
|
||||||
|
|
||||||
|
@ -139,6 +139,11 @@ const AttributeList: React.StatelessComponent<AttributeListProps> = ({
|
||||||
key={attribute ? attribute.id : "skeleton"}
|
key={attribute ? attribute.id : "skeleton"}
|
||||||
onClick={attribute && onRowClick(attribute.id)}
|
onClick={attribute && onRowClick(attribute.id)}
|
||||||
className={classes.link}
|
className={classes.link}
|
||||||
|
data-tc="id"
|
||||||
|
data-tc-id={maybe(() => attribute.id)}
|
||||||
|
data-tc-values={JSON.stringify(
|
||||||
|
maybe(() => attribute.values, [])
|
||||||
|
)}
|
||||||
>
|
>
|
||||||
<TableCell padding="checkbox">
|
<TableCell padding="checkbox">
|
||||||
<Checkbox
|
<Checkbox
|
||||||
|
@ -148,27 +153,43 @@ const AttributeList: React.StatelessComponent<AttributeListProps> = ({
|
||||||
onChange={() => toggle(attribute.id)}
|
onChange={() => toggle(attribute.id)}
|
||||||
/>
|
/>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colSlug}>
|
<TableCell className={classes.colSlug} data-tc="slug">
|
||||||
{attribute ? attribute.slug : <Skeleton />}
|
{attribute ? attribute.slug : <Skeleton />}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colName}>
|
<TableCell className={classes.colName} data-tc="name">
|
||||||
{attribute ? attribute.name : <Skeleton />}
|
{attribute ? attribute.name : <Skeleton />}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colVisible}>
|
<TableCell
|
||||||
|
className={classes.colVisible}
|
||||||
|
data-tc="visible"
|
||||||
|
data-tc-visible={maybe(() => attribute.visibleInStorefront)}
|
||||||
|
>
|
||||||
{attribute ? (
|
{attribute ? (
|
||||||
translateBoolean(attribute.visibleInStorefront, intl)
|
translateBoolean(attribute.visibleInStorefront, intl)
|
||||||
) : (
|
) : (
|
||||||
<Skeleton />
|
<Skeleton />
|
||||||
)}
|
)}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colSearchable}>
|
<TableCell
|
||||||
|
className={classes.colSearchable}
|
||||||
|
data-tc="searchable"
|
||||||
|
data-tc-searchable={maybe(
|
||||||
|
() => attribute.filterableInDashboard
|
||||||
|
)}
|
||||||
|
>
|
||||||
{attribute ? (
|
{attribute ? (
|
||||||
translateBoolean(attribute.filterableInDashboard, intl)
|
translateBoolean(attribute.filterableInDashboard, intl)
|
||||||
) : (
|
) : (
|
||||||
<Skeleton />
|
<Skeleton />
|
||||||
)}
|
)}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colFaceted}>
|
<TableCell
|
||||||
|
className={classes.colFaceted}
|
||||||
|
data-tc="use-in-faceted-search"
|
||||||
|
data-tc-use-in-faceted-search={maybe(
|
||||||
|
() => attribute.filterableInStorefront
|
||||||
|
)}
|
||||||
|
>
|
||||||
{attribute ? (
|
{attribute ? (
|
||||||
translateBoolean(attribute.filterableInStorefront, intl)
|
translateBoolean(attribute.filterableInStorefront, intl)
|
||||||
) : (
|
) : (
|
||||||
|
|
|
@ -72,6 +72,11 @@ const attributeList = gql`
|
||||||
edges {
|
edges {
|
||||||
node {
|
node {
|
||||||
...AttributeFragment
|
...AttributeFragment
|
||||||
|
values {
|
||||||
|
id
|
||||||
|
name
|
||||||
|
slug
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pageInfo {
|
pageInfo {
|
||||||
|
|
|
@ -8,6 +8,13 @@ import { AttributeFilterInput } from "./../../types/globalTypes";
|
||||||
// GraphQL query operation: AttributeList
|
// GraphQL query operation: AttributeList
|
||||||
// ====================================================
|
// ====================================================
|
||||||
|
|
||||||
|
export interface AttributeList_attributes_edges_node_values {
|
||||||
|
__typename: "AttributeValue";
|
||||||
|
id: string;
|
||||||
|
name: string | null;
|
||||||
|
slug: string | null;
|
||||||
|
}
|
||||||
|
|
||||||
export interface AttributeList_attributes_edges_node {
|
export interface AttributeList_attributes_edges_node {
|
||||||
__typename: "Attribute";
|
__typename: "Attribute";
|
||||||
id: string;
|
id: string;
|
||||||
|
@ -16,6 +23,7 @@ export interface AttributeList_attributes_edges_node {
|
||||||
visibleInStorefront: boolean;
|
visibleInStorefront: boolean;
|
||||||
filterableInDashboard: boolean;
|
filterableInDashboard: boolean;
|
||||||
filterableInStorefront: boolean;
|
filterableInStorefront: boolean;
|
||||||
|
values: (AttributeList_attributes_edges_node_values | null)[] | null;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface AttributeList_attributes_edges {
|
export interface AttributeList_attributes_edges {
|
||||||
|
|
|
@ -17,7 +17,7 @@ import Checkbox from "@saleor/components/Checkbox";
|
||||||
import Skeleton from "@saleor/components/Skeleton";
|
import Skeleton from "@saleor/components/Skeleton";
|
||||||
import TableHead from "@saleor/components/TableHead";
|
import TableHead from "@saleor/components/TableHead";
|
||||||
import TablePagination from "@saleor/components/TablePagination";
|
import TablePagination from "@saleor/components/TablePagination";
|
||||||
import { renderCollection } from "@saleor/misc";
|
import { maybe, renderCollection } from "@saleor/misc";
|
||||||
import { ListActions, ListProps } from "@saleor/types";
|
import { ListActions, ListProps } from "@saleor/types";
|
||||||
|
|
||||||
const styles = (theme: Theme) =>
|
const styles = (theme: Theme) =>
|
||||||
|
@ -126,6 +126,8 @@ const CategoryList = withStyles(styles, { name: "CategoryList" })(
|
||||||
onClick={category ? onRowClick(category.id) : undefined}
|
onClick={category ? onRowClick(category.id) : undefined}
|
||||||
key={category ? category.id : "skeleton"}
|
key={category ? category.id : "skeleton"}
|
||||||
selected={isSelected}
|
selected={isSelected}
|
||||||
|
data-tc="id"
|
||||||
|
data-tc-id={maybe(() => category.id)}
|
||||||
>
|
>
|
||||||
<TableCell padding="checkbox">
|
<TableCell padding="checkbox">
|
||||||
<Checkbox
|
<Checkbox
|
||||||
|
@ -135,7 +137,7 @@ const CategoryList = withStyles(styles, { name: "CategoryList" })(
|
||||||
onChange={() => toggle(category.id)}
|
onChange={() => toggle(category.id)}
|
||||||
/>
|
/>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colName}>
|
<TableCell className={classes.colName} data-tc="name">
|
||||||
{category && category.name ? category.name : <Skeleton />}
|
{category && category.name ? category.name : <Skeleton />}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colSubcategories}>
|
<TableCell className={classes.colSubcategories}>
|
||||||
|
|
|
@ -122,6 +122,8 @@ const CollectionList = withStyles(styles, { name: "CollectionList" })(
|
||||||
onClick={collection ? onRowClick(collection.id) : undefined}
|
onClick={collection ? onRowClick(collection.id) : undefined}
|
||||||
key={collection ? collection.id : "skeleton"}
|
key={collection ? collection.id : "skeleton"}
|
||||||
selected={isSelected}
|
selected={isSelected}
|
||||||
|
data-tc="id"
|
||||||
|
data-tc-id={maybe(() => collection.id)}
|
||||||
>
|
>
|
||||||
<TableCell padding="checkbox">
|
<TableCell padding="checkbox">
|
||||||
<Checkbox
|
<Checkbox
|
||||||
|
@ -131,7 +133,7 @@ const CollectionList = withStyles(styles, { name: "CollectionList" })(
|
||||||
onChange={() => toggle(collection.id)}
|
onChange={() => toggle(collection.id)}
|
||||||
/>
|
/>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colName}>
|
<TableCell className={classes.colName} data-tc="name">
|
||||||
{maybe<React.ReactNode>(
|
{maybe<React.ReactNode>(
|
||||||
() => collection.name,
|
() => collection.name,
|
||||||
<Skeleton />
|
<Skeleton />
|
||||||
|
@ -143,7 +145,11 @@ const CollectionList = withStyles(styles, { name: "CollectionList" })(
|
||||||
<Skeleton />
|
<Skeleton />
|
||||||
)}
|
)}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colAvailability}>
|
<TableCell
|
||||||
|
className={classes.colAvailability}
|
||||||
|
data-tc="published"
|
||||||
|
data-tc-published={maybe(() => collection.isPublished)}
|
||||||
|
>
|
||||||
{maybe(
|
{maybe(
|
||||||
() => (
|
() => (
|
||||||
<StatusLabel
|
<StatusLabel
|
||||||
|
|
|
@ -85,7 +85,13 @@ const ProductTypeAttributes = withStyles(styles, {
|
||||||
const intl = useIntl();
|
const intl = useIntl();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Card>
|
<Card
|
||||||
|
data-tc={
|
||||||
|
type === AttributeTypeEnum.PRODUCT
|
||||||
|
? "product-attributes"
|
||||||
|
: "variant-attributes"
|
||||||
|
}
|
||||||
|
>
|
||||||
<CardTitle
|
<CardTitle
|
||||||
title={
|
title={
|
||||||
type === AttributeTypeEnum.PRODUCT
|
type === AttributeTypeEnum.PRODUCT
|
||||||
|
@ -150,6 +156,8 @@ const ProductTypeAttributes = withStyles(styles, {
|
||||||
}
|
}
|
||||||
key={maybe(() => attribute.id)}
|
key={maybe(() => attribute.id)}
|
||||||
index={attributeIndex || 0}
|
index={attributeIndex || 0}
|
||||||
|
data-tc="id"
|
||||||
|
data-tc-id={maybe(() => attribute.id)}
|
||||||
>
|
>
|
||||||
<TableCell padding="checkbox">
|
<TableCell padding="checkbox">
|
||||||
<Checkbox
|
<Checkbox
|
||||||
|
@ -159,14 +167,14 @@ const ProductTypeAttributes = withStyles(styles, {
|
||||||
onChange={() => toggle(attribute.id)}
|
onChange={() => toggle(attribute.id)}
|
||||||
/>
|
/>
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colName}>
|
<TableCell className={classes.colName} data-tc="name">
|
||||||
{maybe(() => attribute.name) ? (
|
{maybe(() => attribute.name) ? (
|
||||||
attribute.name
|
attribute.name
|
||||||
) : (
|
) : (
|
||||||
<Skeleton />
|
<Skeleton />
|
||||||
)}
|
)}
|
||||||
</TableCell>
|
</TableCell>
|
||||||
<TableCell className={classes.colSlug}>
|
<TableCell className={classes.colSlug} data-tc="slug">
|
||||||
{maybe(() => attribute.slug) ? (
|
{maybe(() => attribute.slug) ? (
|
||||||
attribute.slug
|
attribute.slug
|
||||||
) : (
|
) : (
|
||||||
|
|
|
@ -124,6 +124,8 @@ const ProductTypeList = withStyles(styles, { name: "ProductTypeList" })(
|
||||||
key={productType ? productType.id : "skeleton"}
|
key={productType ? productType.id : "skeleton"}
|
||||||
onClick={productType ? onRowClick(productType.id) : undefined}
|
onClick={productType ? onRowClick(productType.id) : undefined}
|
||||||
selected={isSelected}
|
selected={isSelected}
|
||||||
|
data-tc="id"
|
||||||
|
data-tc-id={maybe(() => productType.id)}
|
||||||
>
|
>
|
||||||
<TableCell padding="checkbox">
|
<TableCell padding="checkbox">
|
||||||
<Checkbox
|
<Checkbox
|
||||||
|
@ -136,7 +138,7 @@ const ProductTypeList = withStyles(styles, { name: "ProductTypeList" })(
|
||||||
<TableCell className={classes.colName}>
|
<TableCell className={classes.colName}>
|
||||||
{productType ? (
|
{productType ? (
|
||||||
<>
|
<>
|
||||||
{productType.name}
|
<span data-tc="name">{productType.name}</span>
|
||||||
<Typography variant="caption">
|
<Typography variant="caption">
|
||||||
{maybe(() => productType.hasVariants)
|
{maybe(() => productType.hasVariants)
|
||||||
? intl.formatMessage({
|
? intl.formatMessage({
|
||||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue