From cc4917012583757fa3cfffb53ae4bd45814017b7 Mon Sep 17 00:00:00 2001 From: mnajdova Date: Mon, 24 Jun 2024 11:34:55 +0200 Subject: [PATCH] update fixtures --- .../tests/Grid/fixtures/Grid.output.css | 10 ++++++- .../tests/Grid/fixtures/Grid.output.js | 29 +++++++++++++++++++ 2 files changed, 38 insertions(+), 1 deletion(-) diff --git a/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.css b/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.css index d5e06b3e..30c65637 100644 --- a/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.css +++ b/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.css @@ -356,7 +356,6 @@ } .g1i5ygey-1 { display: flex; - flex-wrap: wrap; gap: var(--Grid-self-row-spacing) var(--Grid-self-column-spacing); } .g1i5ygey-2 { @@ -367,3 +366,12 @@ .g1i5ygey-3 { margin-left: var(--Grid-self-margin-left); } +.g1i5ygey-4 { + flex-wrap: nowrap; +} +.g1i5ygey-5 { + flex-wrap: wrap-reverse; +} +.g1i5ygey-6 { + flex-wrap: wrap; +} diff --git a/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.js b/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.js index 559bf4f9..e9cd779a 100644 --- a/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.js +++ b/packages/pigment-css-react/tests/Grid/fixtures/Grid.output.js @@ -207,6 +207,27 @@ const GridComponent = /*#__PURE__*/ _styled('div')({ props: ({ offset }) => offset !== undefined, className: 'g1i5ygey-3', }, + { + props: { + wrap: 'nowrap', + container: true, + }, + className: 'g1i5ygey-4', + }, + { + props: { + wrap: 'wrap-reverse', + container: true, + }, + className: 'g1i5ygey-5', + }, + { + props: { + wrap: 'wrap', + container: true, + }, + className: 'g1i5ygey-6', + }, ], }); const Grid = React.forwardRef(function Grid( @@ -230,6 +251,7 @@ const Grid = React.forwardRef(function Grid( unstable_parent_column_spacing, // eslint-disable-next-line react/prop-types unstable_parent_row_spacing, + wrap = 'wrap', ...rest }, ref, @@ -267,6 +289,7 @@ const Grid = React.forwardRef(function Grid( container, size, offset, + wrap, }; const gridClasses = gridAtomics(gridAtomicsObj); return ( @@ -381,6 +404,12 @@ process.env.NODE_ENV !== 'production' && * @ignore */ style: PropTypes.object, + /** + * Defines the `flex-wrap` style property. + * It's applied for all screen sizes. + * @default 'wrap' + */ + wrap: PropTypes.oneOf(['nowrap', 'wrap-reverse', 'wrap']), }); Grid.displayName = 'Grid'; export default Grid;