diff --git a/mu-plugins/blocks/horizontal-slider/postcss/style.pcss b/mu-plugins/blocks/horizontal-slider/postcss/style.pcss
index b6fb85eff..d6bbdd580 100644
--- a/mu-plugins/blocks/horizontal-slider/postcss/style.pcss
+++ b/mu-plugins/blocks/horizontal-slider/postcss/style.pcss
@@ -78,6 +78,7 @@ button[disabled]::after {
gap: 12px;
padding-bottom: 24px;
padding-top: 6px;
+ list-style: none;
/* So item focus states are not clipped */
margin-left: -4px;
diff --git a/mu-plugins/blocks/horizontal-slider/src/block.js b/mu-plugins/blocks/horizontal-slider/src/block.js
index 8e0f35072..63dea7306 100644
--- a/mu-plugins/blocks/horizontal-slider/src/block.js
+++ b/mu-plugins/blocks/horizontal-slider/src/block.js
@@ -97,9 +97,7 @@ function Block( { items, title } ) {
return (
-
- { title }
-
+
{ title }
{ ( canNext || canPrevious ) && (
) }
-
+
{ items.map( ( item ) => (
-
+ -
+
+
) ) }
-
+
);
}
diff --git a/mu-plugins/blocks/screenshot-preview/src/block.js b/mu-plugins/blocks/screenshot-preview/src/block.js
index e31bcafa2..593e36c7f 100644
--- a/mu-plugins/blocks/screenshot-preview/src/block.js
+++ b/mu-plugins/blocks/screenshot-preview/src/block.js
@@ -13,13 +13,14 @@ import ScreenShot from './screenshot';
/**
*
* @param {Object} props
- * @param {string} props.link Url for anchor tag.
- * @param {string} props.previewLink Url used for the screenshot preview.
- * @param {string} props.caption Text for screen readers.
- * @param {string} props.height Initial height for the preview, include unit.
- * @param {string} props.width Desired with of the preview element, include unit.
- * @param {number} props.aspectRatio Aspect ratio for the preview element.
- * @param {string} props.queryString Arguments passed to screenshot service.
+ * @param {string} props.link Url for anchor tag.
+ * @param {string} props.previewLink Url used for the screenshot preview.
+ * @param {string} props.caption Text for screen readers.
+ * @param {string} props.height Initial height for the preview, include unit.
+ * @param {string} props.width Desired with of the preview element, include unit.
+ * @param {number} props.aspectRatio Aspect ratio for the preview element.
+ * @param {string} props.queryString Arguments passed to screenshot service.
+ * @param {Object} props.anchorTagProps HTMLAnchorElement attributes to be added to the block anchor tag.
*
* @return {Object} React element
*/
@@ -31,6 +32,7 @@ function Block( {
width = '100%',
aspectRatio = 2 / 3,
queryString = '?vpw=1200&vph=800',
+ anchorTagProps = {},
} ) {
const wrapperRef = useRef();
const [ frameHeight, setFrameHeight ] = useState( height );
@@ -68,9 +70,9 @@ function Block( {
width: width,
} }
href={ link }
+ { ...anchorTagProps }
>
- { caption && { caption } }
-
+
);
}
diff --git a/mu-plugins/blocks/screenshot-preview/src/screenshot.js b/mu-plugins/blocks/screenshot-preview/src/screenshot.js
index c4f78b8c1..80cfbff4f 100644
--- a/mu-plugins/blocks/screenshot-preview/src/screenshot.js
+++ b/mu-plugins/blocks/screenshot-preview/src/screenshot.js
@@ -42,13 +42,14 @@ function useInterval( callback, delay ) {
* we need to do some custom handling.
*
* @param {Object} props
+ * @param {string} props.alt Alternate text for image.
* @param {string} props.queryString Arguments that are passed to mShots.
* @param {string} props.src The url of the screenshot.
* @param {boolean} props.isReady Whether we should start try to show the image.
*
* @return {Object} React component
*/
-function ScreenShotImg( { queryString, src, isReady = false } ) {
+function ScreenShotImg( { alt = '', queryString, src, isReady = false } ) {
const fullUrl = `https://s0.wp.com/mshots/v1/${ encodeURIComponent( src ) }${ queryString }`;
const [ attempts, setAttempts ] = useState( 0 );
@@ -112,7 +113,7 @@ function ScreenShotImg( { queryString, src, isReady = false } ) {
return { __( 'error', 'wporg' ) }
;
}
- return ;
+ return ;
}
export default ScreenShotImg;