Fix: Empty Mini Cart contents overflow issue (https://github.com/woocommerce/woocommerce-blocks/pull/5635)
* fix: add wrapper for empty mini cart contents inner blocks. Allow inner content to be scrollable * fix overflow issue for the editor * add padding for the empty cart view
This commit is contained in:
parent
9d1464baf3
commit
995d41e2a9
|
@ -41,4 +41,16 @@
|
|||
box-shadow: inset 0 0 0 1px;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.wp-block-woocommerce-empty-mini-cart-contents-block {
|
||||
overflow-y: unset;
|
||||
padding: 0;
|
||||
|
||||
> .block-editor-inner-blocks {
|
||||
max-height: 100vh;
|
||||
overflow-y: auto;
|
||||
box-sizing: border-box;
|
||||
padding: $gap-largest $gap $gap;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
const Block = ( { children }: { children: JSX.Element } ): JSX.Element => {
|
||||
return <>{ children }</>;
|
||||
};
|
||||
|
||||
export default Block;
|
|
@ -20,7 +20,11 @@ const EmptyMiniCartContentsBlock = ( {
|
|||
return null;
|
||||
}
|
||||
|
||||
return <>{ children }</>;
|
||||
return (
|
||||
<div className="wp-block-woocommerce-empty-mini-cart-contents-block">
|
||||
{ children }
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default EmptyMiniCartContentsBlock;
|
||||
|
|
|
@ -65,6 +65,7 @@
|
|||
|
||||
button {
|
||||
color: inherit;
|
||||
z-index: 9999;
|
||||
}
|
||||
|
||||
svg {
|
||||
|
@ -84,6 +85,11 @@
|
|||
justify-content: center;
|
||||
}
|
||||
|
||||
.wp-block-woocommerce-empty-mini-cart-contents-block {
|
||||
overflow-y: auto;
|
||||
padding: $gap-largest $gap $gap;
|
||||
}
|
||||
|
||||
h2.wc-block-mini-cart__title {
|
||||
@include font-size(larger);
|
||||
margin: $gap-largest $gap 0;
|
||||
|
|
Loading…
Reference in New Issue