@automattic/newspack-blocks 2.1.0 → 2.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/.cache/babel/6aca28a6c4a1d89dde32fdeb4bda53d5.json.gz +0 -0
  2. package/.cache/babel/b69c05682a3bd6b8f597906127dab44e.json.gz +0 -0
  3. package/.cache/babel/c163868a7a55ba37b772721cb99ffc73.json.gz +0 -0
  4. package/.cache/babel/c7cfb8590e887722a3e715c72ee99bac.json.gz +0 -0
  5. package/CHANGELOG.md +34 -0
  6. package/composer.json +2 -2
  7. package/composer.lock +171 -19
  8. package/dist/checkout-button/view.asset.php +1 -1
  9. package/dist/checkout-button/view.css +1 -1
  10. package/dist/checkout-button/view.rtl.css +1 -1
  11. package/dist/donateStreamlined.asset.php +1 -1
  12. package/dist/donateStreamlined.js +1 -1
  13. package/dist/editor.asset.php +1 -1
  14. package/dist/editor.css +1 -1
  15. package/dist/editor.js +1 -1
  16. package/dist/editor.rtl.css +1 -1
  17. package/dist/homepage-articles/view.asset.php +1 -1
  18. package/dist/homepage-articles/view.css +1 -1
  19. package/dist/homepage-articles/view.rtl.css +1 -1
  20. package/includes/class-newspack-blocks-api.php +44 -30
  21. package/includes/class-newspack-blocks.php +2 -2
  22. package/newspack-blocks.php +2 -2
  23. package/package.json +5 -5
  24. package/src/block-patterns/subscribe-1.php +1 -1
  25. package/src/block-patterns/subscribe-10.php +1 -1
  26. package/src/block-patterns/subscribe-2.php +1 -1
  27. package/src/block-patterns/subscribe-3.php +1 -1
  28. package/src/block-patterns/subscribe-4.php +1 -1
  29. package/src/block-patterns/subscribe-5.php +1 -1
  30. package/src/block-patterns/subscribe-6.php +1 -1
  31. package/src/block-patterns/subscribe-7.php +1 -1
  32. package/src/block-patterns/subscribe-8.php +1 -1
  33. package/src/block-patterns/subscribe-9.php +1 -1
  34. package/src/blocks/author-list/class-wp-rest-newspack-author-list-controller.php +9 -11
  35. package/src/blocks/checkout-button/block.json +3 -0
  36. package/src/blocks/checkout-button/edit.js +35 -1
  37. package/src/blocks/checkout-button/save.js +3 -1
  38. package/src/blocks/checkout-button/view.scss +19 -6
  39. package/src/blocks/homepage-articles/class-wp-rest-newspack-articles-controller.php +13 -0
  40. package/src/blocks/homepage-articles/edit.js +1 -4
  41. package/src/blocks/homepage-articles/editor.js +16 -2
  42. package/src/blocks/homepage-articles/templates/article.php +10 -12
  43. package/src/blocks/homepage-articles/templates/articles-list.php +2 -2
  44. package/src/blocks/homepage-articles/view.php +177 -11
  45. package/src/blocks/homepage-articles/view.scss +0 -102
  46. package/src/modal-checkout/templates/thankyou.php +7 -1
  47. package/src/templates/author-profile-card.php +22 -12
  48. package/vendor/autoload.php +1 -1
  49. package/vendor/composer/autoload_real.php +4 -4
  50. package/vendor/composer/autoload_static.php +2 -2
  51. package/vendor/composer/installed.php +2 -2
  52. package/.cache/babel/39bcc541624feefe54d1493493ae1ce8.json.gz +0 -0
  53. package/.cache/babel/4d8c26a76e77fa64d01f30a5f2d62f85.json.gz +0 -0
  54. package/.cache/babel/6715650e6d89955011841839faac29f2.json.gz +0 -0
  55. package/.cache/babel/6d457f8985600b07d97aebc4e1a21855.json.gz +0 -0
@@ -1 +1 @@
1
- <?php return array('dependencies' => array('wp-polyfill'), 'version' => '170fec77ebb39cb515b46ab8740c3760');
1
+ <?php return array('dependencies' => array('wp-polyfill'), 'version' => '98fe1ccb8e90ec2ca3b4644b173d66ad');
@@ -1 +1 @@
1
- .newspack-preview-label{position:absolute;top:5px;left:5px;z-index:1;font-family:sans-serif;font-size:10px;text-transform:uppercase;background:#ffc000;padding:0 4px;border-radius:2px}:root{--wpnbha-col-gap:1em}@media only screen and (min-width:600px){:root{--wpnbha-col-gap:16px}}@media only screen and (min-width:782px){:root{--wpnbha-col-gap:32px}}@media only screen and (min-width:600px){.colgap-2{--wpnbha-col-gap:16px}}@media only screen and (min-width:600px){.colgap-1{--wpnbha-col-gap:8px}}.wpnbha{margin-bottom:1em}.wpnbha article{min-width:0;margin-bottom:1.5em;word-break:break-word;overflow-wrap:break-word;position:relative}.wpnbha article:last-of-type{margin-bottom:0}.wpnbha .article-section-title{font-size:.8em;margin-bottom:.5em;width:100%}.wpnbha .article-section-title mark{background-color:transparent}.wpnbha.is-grid>div{display:flex;flex-flow:row wrap;justify-content:flex-start;gap:var(--wpnbha-col-gap);padding:0;list-style:none}.wpnbha.is-grid article{flex-basis:100%;margin-bottom:0}.wpnbha.is-grid .article-section-title{margin-bottom:calc(1em - var(--wpnbha-col-gap))}@media only screen and (min-width:600px){.wpnbha.columns-3 article,.wpnbha.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)/3*2)}.wpnbha.is-style-borders.columns-3 article,.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)*2/3*2 - 1px)}.wpnbha.columns-2 article,.wpnbha.columns-4 article,.wpnbha.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)/2)}.wpnbha.is-style-borders.columns-2 article,.wpnbha.is-style-borders.columns-4 article,.wpnbha.is-style-borders.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)*2/2 - 1px)}.wpnbha.columns-5 article:last-of-type,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:100%}}@media only screen and (min-width:782px){.wpnbha.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)/4*3)}.wpnbha.is-style-borders.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)*2/4*3 - 1px)}.wpnbha.columns-5 article,.wpnbha.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)/5*4)}.wpnbha.is-style-borders.columns-5 article,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)*2/5*4 - 1px)}.wpnbha.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)/6*5)}.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)*2/6*5 - 1px)}}.wpnbha .post-thumbnail{margin:0 0 .25em}.wpnbha .post-thumbnail img{height:auto;width:100%}.wpnbha .post-thumbnail figcaption{margin-bottom:.5em}.wpnbha figcaption{font-size:.6em}.wpnbha.image-alignleft .post-has-image,.wpnbha.image-alignright .post-has-image{display:flex}.wpnbha.image-alignleft .post-has-image .post-thumbnail,.wpnbha.image-alignright .post-has-image .post-thumbnail{flex-basis:33%}.wpnbha.image-alignleft .post-has-image .entry-wrapper,.wpnbha.image-alignright .post-has-image .entry-wrapper{flex-basis:67%}.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:block}@media only screen and (min-width:600px){.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:flex}}@media only screen and (min-width:600px){.wpnbha.image-alignleft.is-4 .post-thumbnail,.wpnbha.image-alignright.is-4 .post-thumbnail{flex-basis:75%}.wpnbha.image-alignleft.is-4 .entry-wrapper,.wpnbha.image-alignright.is-4 .entry-wrapper{flex-basis:25%}.wpnbha.image-alignleft.is-3 .entry-wrapper,.wpnbha.image-alignleft.is-3 .post-thumbnail,.wpnbha.image-alignright.is-3 .entry-wrapper,.wpnbha.image-alignright.is-3 .post-thumbnail{flex-basis:50%}}.wpnbha.image-alignleft.is-1 .post-thumbnail,.wpnbha.image-alignright.is-1 .post-thumbnail{flex-basis:25%}.wpnbha.image-alignleft.is-1 .entry-wrapper,.wpnbha.image-alignright.is-1 .entry-wrapper{flex-basis:75%}.wpnbha.image-alignleft .post-thumbnail{margin-right:1em}.wpnbha.image-alignright .post-thumbnail{margin-left:1em}.wpnbha.image-alignright .entry-wrapper{order:-1}.wpnbha.mobile-stack.image-alignleft .post-thumbnail,.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-left:0;margin-right:0}@media only screen and (min-width:600px){.wpnbha.mobile-stack.image-alignleft .post-thumbnail{margin-right:1em}.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-left:1em}}.wpnbha .entry-title{margin:0 0 .25em}.wpnbha .entry-title a{color:inherit;text-decoration:none}.wpnbha .entry-meta{display:flex;flex-wrap:wrap;align-items:center;margin-top:.5em}.wpnbha .entry-meta .byline:not(:last-child){margin-right:1.5em}.wpnbha .entry-meta .updated{display:none}.wpnbha .entry-meta .updated.published{display:block}.wpnbha .avatar{border-radius:100%;display:block;margin-right:.5em}.wpnbha p{margin:.5em 0}.wpnbha.has-text-color .article-section-title,.wpnbha.has-text-color .cat-links,.wpnbha.has-text-color .cat-links a,.wpnbha.has-text-color .cat-links a:visited,.wpnbha.has-text-color .entry-meta,.wpnbha.has-text-color .entry-meta .byline a,.wpnbha.has-text-color .entry-meta .byline a:visited,.wpnbha.has-text-color .entry-meta a,.wpnbha.has-text-color .entry-title,.wpnbha.has-text-color .entry-title a,.wpnbha.has-text-color .entry-title a:visited,.wpnbha.has-text-color figcaption{color:inherit}.wpnbha.has-text-color .entry-meta span:not(.avatar){opacity:.8}.wpnbha.image-alignbehind .post-has-image{display:flex;align-items:flex-end;position:relative}.wpnbha.image-alignbehind .post-has-image .post-thumbnail{inset:0;margin:0;overflow:hidden;position:absolute}.wpnbha.image-alignbehind .post-has-image .post-thumbnail img{height:100%!important;-o-object-fit:cover!important;object-fit:cover!important;margin:0!important;max-width:1000%!important;width:100%!important}.wpnbha.image-alignbehind .post-has-image .post-thumbnail:after{background:rgba(0,0,0,.5);content:"";inset:0;position:absolute;z-index:1}.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1rem;position:relative;width:100%;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1.5rem}}.wpnbha.image-alignbehind .post-has-image .cat-links a,.wpnbha.image-alignbehind .post-has-image .entry-meta,.wpnbha.image-alignbehind .post-has-image .entry-meta .byline a,.wpnbha.image-alignbehind .post-has-image .entry-title a,.wpnbha.image-alignbehind .post-has-image .entry-wrapper{color:#fff}.wpnbha.image-alignbehind figcaption{bottom:1em;-webkit-box-orient:vertical;color:hsla(0,0%,100%,.9);display:-webkit-box;font-style:italic;left:0;-webkit-line-clamp:1;margin:0;max-height:1.6em;overflow:hidden;padding:0 1rem;position:absolute;right:0;text-align:right;text-overflow:ellipsis;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind figcaption{padding:0 1.5rem}}.wpnbha .error,.wpnbha .loading,.wpnbha button{display:none}.wpnbha>button{margin-top:1em}.wpnbha.has-more-button button{display:block}.wpnbha.has-more-button.is-loading button{display:none}.wpnbha.has-more-button.is-error .error,.wpnbha.has-more-button.is-error button,.wpnbha.has-more-button.is-loading .loading{display:block}.wpnbha .author-avatar,.wpnbha .byline,.wpnbha .cat-links,.wpnbha .posted-on,.wpnbha .tags-links{clip:auto;height:auto;position:relative;width:auto}.wpnbha.has-text-align-center .cat-links,.wpnbha.has-text-align-center .entry-meta,.wpnbha.has-text-align-center .entry-sponsors{justify-content:center}.wpnbha.has-text-align-center.image-alignbehind figcaption,.wpnbha.has-text-align-center figcaption{text-align:inherit}.wpnbha.has-text-align-right .cat-links,.wpnbha.has-text-align-right .entry-meta,.wpnbha.has-text-align-right .entry-sponsors,.wpnbha.has-text-align-right .sponsor-logos{justify-content:flex-end;text-align:right}.wpnbha.has-text-align-right figcaption{text-align:inherit}.wpnbha.has-text-align-right .entry-date:not(:first-child){margin-left:1.5em}.wpnbha.has-text-align-right .entry-meta .byline:not(:last-child){margin:0}.wpnbha .cat-links{display:flex;flex-wrap:wrap;font-size:.6em;font-weight:700;margin:0 0 .5em}.wpnbha .cat-links.sponsor-label{align-items:center;display:flex;gap:.5em}.wpnbha .cat-links a{text-decoration:none}.wpnbha .cat-links a:hover{text-decoration:underline}.wpnbha .entry-sponsors{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.25em;width:100%}.wpnbha .entry-sponsors.plus-author{font-size:.9em}.wpnbha .entry-sponsors.plus-author:not(:last-child){margin-bottom:.5rem}.wpnbha .sponsor-logos{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.5em;line-height:1}.wpnbha article .entry-title{font-size:1.2em}.wpnbha article .entry-meta{font-size:.8em}.wpnbha article .avatar{height:25px;width:25px}@media only screen and (min-width:782px){.wpnbha article .entry-title{font-size:1.6em}.wpnbha article .avatar{height:40px;width:40px}}.wpnbha.ts-8 .entry-title,.wpnbha.ts-9 .entry-title,.wpnbha.ts-10 .entry-title{line-height:1.1}@media only screen and (min-width:782px){.wpnbha.ts-8 article .avatar,.wpnbha.ts-9 article .avatar,.wpnbha.ts-10 article .avatar{height:2.4em;width:2.4em}}.wpnbha.ts-7 .newspack-post-subtitle,.wpnbha.ts-8 .newspack-post-subtitle,.wpnbha.ts-9 .newspack-post-subtitle,.wpnbha.ts-10 .newspack-post-subtitle{font-size:1.4em}.wpnbha.ts-10 article .entry-title{font-size:2.6em}@media only screen and (min-width:782px){.wpnbha.ts-10 article .entry-title{font-size:3.6em}}@media only screen and (min-width:1168px){.wpnbha.ts-10 article .entry-title{font-size:4.8em}}.wpnbha.ts-9 article .entry-title{font-size:2.4em}@media only screen and (min-width:782px){.wpnbha.ts-9 article .entry-title{font-size:3.4em}}@media only screen and (min-width:1168px){.wpnbha.ts-9 article .entry-title{font-size:4.2em}}.wpnbha.ts-8 article .entry-title{font-size:2.2em}@media only screen and (min-width:782px){.wpnbha.ts-8 article .entry-title{font-size:3em}}@media only screen and (min-width:1168px){.wpnbha.ts-8 article .entry-title{font-size:3.6em}}.wpnbha.ts-7 article .entry-title{font-size:2em}@media only screen and (min-width:782px){.wpnbha.ts-7 article .entry-title{font-size:2.4em}.wpnbha.ts-7 article .avatar{height:48px;width:48px}}@media only screen and (min-width:1168px){.wpnbha.ts-7 article .entry-title{font-size:3em}}.wpnbha.ts-6 article .entry-title{font-size:1.7em}.wpnbha.ts-6 article .newspack-post-subtitle{font-size:1.4em}@media only screen and (min-width:782px){.wpnbha.ts-6 article .entry-title{font-size:2em}.wpnbha.ts-6 article .avatar{height:44px;width:44px}}@media only screen and (min-width:1168px){.wpnbha.ts-6 article .entry-title{font-size:2.4em}}.wpnbha.ts-5 article .entry-title{font-size:1.4em}.wpnbha.ts-5 article .newspack-post-subtitle{font-size:1.2em}@media only screen and (min-width:782px){.wpnbha.ts-5 article .entry-title{font-size:1.8em}.wpnbha.ts-5 article .avatar{height:40px;width:40px}}@media only screen and (min-width:1168px){.wpnbha.ts-5 article .entry-title{font-size:2em}}.wpnbha.ts-3 article .entry-title{font-size:1em}.wpnbha.ts-3 article .entry-meta,.wpnbha.ts-3 article .entry-wrapper .more-link,.wpnbha.ts-3 article .entry-wrapper p,.wpnbha.ts-3 article .newspack-post-subtitle{font-size:.8em}@media only screen and (min-width:782px){.wpnbha.ts-3 article .entry-title{font-size:1.2em}.wpnbha.ts-3 article .entry-meta{font-size:.7em}.wpnbha.ts-3 article .avatar{height:32px;width:32px}}.wpnbha.ts-1 article .entry-title,.wpnbha.ts-2 article .entry-title{font-size:.9em}.wpnbha.ts-1 article .entry-meta,.wpnbha.ts-1 article .entry-wrapper .more-link,.wpnbha.ts-1 article .entry-wrapper p,.wpnbha.ts-1 article .newspack-post-subtitle,.wpnbha.ts-2 article .entry-meta,.wpnbha.ts-2 article .entry-wrapper .more-link,.wpnbha.ts-2 article .entry-wrapper p,.wpnbha.ts-2 article .newspack-post-subtitle{font-size:.8em}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-meta,.wpnbha.ts-1 article .entry-wrapper .more-link,.wpnbha.ts-1 article .entry-wrapper p,.wpnbha.ts-1 article .newspack-post-subtitle,.wpnbha.ts-2 article .entry-meta,.wpnbha.ts-2 article .entry-wrapper .more-link,.wpnbha.ts-2 article .entry-wrapper p,.wpnbha.ts-2 article .newspack-post-subtitle{font-size:.7em}}@media only screen and (min-width:782px){.wpnbha.ts-2 article .entry-title{font-size:.9em}.wpnbha.ts-2 article .avatar{height:28px;width:28px}}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-title{font-size:.7em}.wpnbha.ts-1 article .avatar{height:24px;width:24px}}.wpnbha.is-style-borders article{border:solid rgba(0,0,0,.2);border-width:0 0 1px;box-sizing:content-box;padding-bottom:1em}.wpnbha.is-style-borders article:last-of-type:not(:first-of-type){border-bottom:0;padding-right:0}@media only screen and (min-width:600px){.wpnbha.is-style-borders.is-grid article{border-width:0;padding-right:0}.wpnbha.is-style-borders.columns-2 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+2):not(:last-of-type),.wpnbha.is-style-borders.columns-4 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-5 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+2):not(:last-of-type){border-width:0 1px 0 0;padding-right:var(--wpnbha-col-gap)}}@media only screen and (min-width:782px){.wpnbha.is-style-borders.is-grid article{border-width:0 1px 0 0;padding-right:var(--wpnbha-col-gap)}.wpnbha.is-style-borders.columns-1 article,.wpnbha.is-style-borders.columns-2 article:nth-of-type(2n),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n),.wpnbha.is-style-borders.columns-4 article:nth-of-type(4n),.wpnbha.is-style-borders.columns-5 article:nth-of-type(5n),.wpnbha.is-style-borders.columns-6 article:nth-of-type(6n),.wpnbha.is-style-borders.is-grid article:last-of-type{border:0;padding-right:0}}.newspack-post-subtitle--in-homepage-block{margin-top:.3em;margin-bottom:0;line-height:1.4;font-style:italic}
1
+ .newspack-preview-label{position:absolute;top:5px;left:5px;z-index:1;font-family:sans-serif;font-size:10px;text-transform:uppercase;background:#ffc000;padding:0 4px;border-radius:2px}:root{--wpnbha-col-gap:1em}@media only screen and (min-width:600px){:root{--wpnbha-col-gap:16px}}@media only screen and (min-width:782px){:root{--wpnbha-col-gap:32px}}@media only screen and (min-width:600px){.colgap-2{--wpnbha-col-gap:16px}}@media only screen and (min-width:600px){.colgap-1{--wpnbha-col-gap:8px}}.wpnbha{margin-bottom:1em}.wpnbha article{min-width:0;margin-bottom:1.5em;word-break:break-word;overflow-wrap:break-word;position:relative}.wpnbha article:last-of-type{margin-bottom:0}.wpnbha .article-section-title{font-size:.8em;margin-bottom:.5em;width:100%}.wpnbha .article-section-title mark{background-color:transparent}.wpnbha.is-grid>div{display:flex;flex-flow:row wrap;justify-content:flex-start;gap:var(--wpnbha-col-gap);padding:0;list-style:none}.wpnbha.is-grid article{flex-basis:100%;margin-bottom:0}.wpnbha.is-grid .article-section-title{margin-bottom:calc(1em - var(--wpnbha-col-gap))}@media only screen and (min-width:600px){.wpnbha.columns-3 article,.wpnbha.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)/3*2)}.wpnbha.is-style-borders.columns-3 article,.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)*2/3*2 - 1px)}.wpnbha.columns-2 article,.wpnbha.columns-4 article,.wpnbha.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)/2)}.wpnbha.is-style-borders.columns-2 article,.wpnbha.is-style-borders.columns-4 article,.wpnbha.is-style-borders.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)*2/2 - 1px)}.wpnbha.columns-5 article:last-of-type,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:100%}}@media only screen and (min-width:782px){.wpnbha.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)/4*3)}.wpnbha.is-style-borders.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)*2/4*3 - 1px)}.wpnbha.columns-5 article,.wpnbha.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)/5*4)}.wpnbha.is-style-borders.columns-5 article,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)*2/5*4 - 1px)}.wpnbha.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)/6*5)}.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)*2/6*5 - 1px)}}.wpnbha figcaption{font-size:.6em}.wpnbha.image-alignleft .post-has-image,.wpnbha.image-alignright .post-has-image{display:flex}.wpnbha.image-alignleft .post-has-image .post-thumbnail,.wpnbha.image-alignright .post-has-image .post-thumbnail{flex-basis:33%}.wpnbha.image-alignleft .post-has-image .entry-wrapper,.wpnbha.image-alignright .post-has-image .entry-wrapper{flex-basis:67%}.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:block}@media only screen and (min-width:600px){.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:flex}}@media only screen and (min-width:600px){.wpnbha.image-alignleft.is-4 .post-thumbnail,.wpnbha.image-alignright.is-4 .post-thumbnail{flex-basis:75%}.wpnbha.image-alignleft.is-4 .entry-wrapper,.wpnbha.image-alignright.is-4 .entry-wrapper{flex-basis:25%}.wpnbha.image-alignleft.is-3 .entry-wrapper,.wpnbha.image-alignleft.is-3 .post-thumbnail,.wpnbha.image-alignright.is-3 .entry-wrapper,.wpnbha.image-alignright.is-3 .post-thumbnail{flex-basis:50%}}.wpnbha.image-alignleft.is-1 .post-thumbnail,.wpnbha.image-alignright.is-1 .post-thumbnail{flex-basis:25%}.wpnbha.image-alignleft.is-1 .entry-wrapper,.wpnbha.image-alignright.is-1 .entry-wrapper{flex-basis:75%}.wpnbha.image-alignleft .post-thumbnail{margin-right:1em}.wpnbha.image-alignright .post-thumbnail{margin-left:1em}.wpnbha.image-alignright .entry-wrapper{order:-1}.wpnbha.mobile-stack.image-alignleft .post-thumbnail,.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-left:0;margin-right:0}@media only screen and (min-width:600px){.wpnbha.mobile-stack.image-alignleft .post-thumbnail{margin-right:1em}.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-left:1em}}.wpnbha .entry-title{margin:0 0 .25em}.wpnbha .entry-title a{color:inherit;text-decoration:none}.wpnbha .entry-meta .byline:not(:last-child){margin-right:1.5em}.wpnbha .entry-meta .updated{display:none}.wpnbha .entry-meta .updated.published{display:block}.wpnbha .avatar{border-radius:100%;display:block;margin-right:.5em}.wpnbha.has-text-color .article-section-title,.wpnbha.has-text-color .cat-links,.wpnbha.has-text-color .cat-links a,.wpnbha.has-text-color .cat-links a:visited,.wpnbha.has-text-color .entry-meta,.wpnbha.has-text-color .entry-meta .byline a,.wpnbha.has-text-color .entry-meta .byline a:visited,.wpnbha.has-text-color .entry-meta a,.wpnbha.has-text-color .entry-title,.wpnbha.has-text-color .entry-title a,.wpnbha.has-text-color .entry-title a:visited,.wpnbha.has-text-color figcaption{color:inherit}.wpnbha.has-text-color .entry-meta span:not(.avatar){opacity:.8}.wpnbha.image-alignbehind .post-has-image{display:flex;align-items:flex-end;position:relative}.wpnbha.image-alignbehind .post-has-image .post-thumbnail{inset:0;margin:0;overflow:hidden;position:absolute}.wpnbha.image-alignbehind .post-has-image .post-thumbnail img{height:100%!important;-o-object-fit:cover!important;object-fit:cover!important;margin:0!important;max-width:1000%!important;width:100%!important}.wpnbha.image-alignbehind .post-has-image .post-thumbnail:after{background:rgba(0,0,0,.5);content:"";inset:0;position:absolute;z-index:1}.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1rem;position:relative;width:100%;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1.5rem}}.wpnbha.image-alignbehind .post-has-image .cat-links a,.wpnbha.image-alignbehind .post-has-image .entry-meta,.wpnbha.image-alignbehind .post-has-image .entry-meta .byline a,.wpnbha.image-alignbehind .post-has-image .entry-title a,.wpnbha.image-alignbehind .post-has-image .entry-wrapper{color:#fff}.wpnbha.image-alignbehind figcaption{bottom:1em;-webkit-box-orient:vertical;color:hsla(0,0%,100%,.9);display:-webkit-box;font-style:italic;left:0;-webkit-line-clamp:1;margin:0;max-height:1.6em;overflow:hidden;padding:0 1rem;position:absolute;right:0;text-align:right;text-overflow:ellipsis;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind figcaption{padding:0 1.5rem}}.wpnbha .error,.wpnbha .loading,.wpnbha button{display:none}.wpnbha>button{margin-top:1em}.wpnbha.has-more-button button{display:block}.wpnbha.has-more-button.is-loading button{display:none}.wpnbha.has-more-button.is-error .error,.wpnbha.has-more-button.is-error button,.wpnbha.has-more-button.is-loading .loading{display:block}.wpnbha .author-avatar,.wpnbha .byline,.wpnbha .cat-links,.wpnbha .posted-on,.wpnbha .tags-links{clip:auto;height:auto;position:relative;width:auto}.wpnbha.has-text-align-center .cat-links,.wpnbha.has-text-align-center .entry-meta,.wpnbha.has-text-align-center .entry-sponsors{justify-content:center}.wpnbha.has-text-align-center.image-alignbehind figcaption,.wpnbha.has-text-align-center figcaption{text-align:inherit}.wpnbha.has-text-align-right .cat-links,.wpnbha.has-text-align-right .entry-meta,.wpnbha.has-text-align-right .entry-sponsors,.wpnbha.has-text-align-right .sponsor-logos{justify-content:flex-end;text-align:right}.wpnbha.has-text-align-right figcaption{text-align:inherit}.wpnbha.has-text-align-right .entry-date:not(:first-child){margin-left:1.5em}.wpnbha.has-text-align-right .entry-meta .byline:not(:last-child){margin:0}.wpnbha .cat-links{display:flex;flex-wrap:wrap;font-size:.6em;font-weight:700;margin:0 0 .5em}.wpnbha .cat-links.sponsor-label{align-items:center;display:flex;gap:.5em}.wpnbha .cat-links a{text-decoration:none}.wpnbha .cat-links a:hover{text-decoration:underline}.wpnbha .entry-sponsors{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.25em;width:100%}.wpnbha .entry-sponsors.plus-author{font-size:.9em}.wpnbha .entry-sponsors.plus-author:not(:last-child){margin-bottom:.5rem}.wpnbha .sponsor-logos{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.5em;line-height:1}@media only screen and (min-width:782px){.wpnbha article .entry-title{font-size:1.6em}.wpnbha article .avatar{height:40px;width:40px}}@media only screen and (min-width:782px){.wpnbha.ts-8 article .avatar,.wpnbha.ts-9 article .avatar,.wpnbha.ts-10 article .avatar{height:2.4em;width:2.4em}}@media only screen and (min-width:782px){.wpnbha.ts-10 article .entry-title{font-size:3.6em}}@media only screen and (min-width:1168px){.wpnbha.ts-10 article .entry-title{font-size:4.8em}}@media only screen and (min-width:782px){.wpnbha.ts-9 article .entry-title{font-size:3.4em}}@media only screen and (min-width:1168px){.wpnbha.ts-9 article .entry-title{font-size:4.2em}}@media only screen and (min-width:782px){.wpnbha.ts-8 article .entry-title{font-size:3em}}@media only screen and (min-width:1168px){.wpnbha.ts-8 article .entry-title{font-size:3.6em}}@media only screen and (min-width:782px){.wpnbha.ts-7 article .entry-title{font-size:2.4em}.wpnbha.ts-7 article .avatar{height:48px;width:48px}}@media only screen and (min-width:1168px){.wpnbha.ts-7 article .entry-title{font-size:3em}}@media only screen and (min-width:782px){.wpnbha.ts-6 article .entry-title{font-size:2em}.wpnbha.ts-6 article .avatar{height:44px;width:44px}}@media only screen and (min-width:1168px){.wpnbha.ts-6 article .entry-title{font-size:2.4em}}@media only screen and (min-width:782px){.wpnbha.ts-5 article .entry-title{font-size:1.8em}.wpnbha.ts-5 article .avatar{height:40px;width:40px}}@media only screen and (min-width:1168px){.wpnbha.ts-5 article .entry-title{font-size:2em}}@media only screen and (min-width:782px){.wpnbha.ts-3 article .entry-title{font-size:1.2em}.wpnbha.ts-3 article .entry-meta{font-size:.7em}.wpnbha.ts-3 article .avatar{height:32px;width:32px}}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-meta,.wpnbha.ts-1 article .entry-wrapper .more-link,.wpnbha.ts-1 article .entry-wrapper p,.wpnbha.ts-1 article .newspack-post-subtitle,.wpnbha.ts-2 article .entry-meta,.wpnbha.ts-2 article .entry-wrapper .more-link,.wpnbha.ts-2 article .entry-wrapper p,.wpnbha.ts-2 article .newspack-post-subtitle{font-size:.7em}}@media only screen and (min-width:782px){.wpnbha.ts-2 article .entry-title{font-size:.9em}.wpnbha.ts-2 article .avatar{height:28px;width:28px}}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-title{font-size:.7em}.wpnbha.ts-1 article .avatar{height:24px;width:24px}}.wpnbha.is-style-borders article{border:solid rgba(0,0,0,.2);border-width:0 0 1px;box-sizing:content-box;padding-bottom:1em}.wpnbha.is-style-borders article:last-of-type:not(:first-of-type){border-bottom:0;padding-right:0}@media only screen and (min-width:600px){.wpnbha.is-style-borders.is-grid article{border-width:0;padding-right:0}.wpnbha.is-style-borders.columns-2 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+2):not(:last-of-type),.wpnbha.is-style-borders.columns-4 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-5 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+2):not(:last-of-type){border-width:0 1px 0 0;padding-right:var(--wpnbha-col-gap)}}@media only screen and (min-width:782px){.wpnbha.is-style-borders.is-grid article{border-width:0 1px 0 0;padding-right:var(--wpnbha-col-gap)}.wpnbha.is-style-borders.columns-1 article,.wpnbha.is-style-borders.columns-2 article:nth-of-type(2n),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n),.wpnbha.is-style-borders.columns-4 article:nth-of-type(4n),.wpnbha.is-style-borders.columns-5 article:nth-of-type(5n),.wpnbha.is-style-borders.columns-6 article:nth-of-type(6n),.wpnbha.is-style-borders.is-grid article:last-of-type{border:0;padding-right:0}}
@@ -1 +1 @@
1
- .newspack-preview-label{position:absolute;top:5px;right:5px;z-index:1;font-family:sans-serif;font-size:10px;text-transform:uppercase;background:#ffc000;padding:0 4px;border-radius:2px}:root{--wpnbha-col-gap:1em}@media only screen and (min-width:600px){:root{--wpnbha-col-gap:16px}}@media only screen and (min-width:782px){:root{--wpnbha-col-gap:32px}}@media only screen and (min-width:600px){.colgap-2{--wpnbha-col-gap:16px}}@media only screen and (min-width:600px){.colgap-1{--wpnbha-col-gap:8px}}.wpnbha{margin-bottom:1em}.wpnbha article{min-width:0;margin-bottom:1.5em;word-break:break-word;overflow-wrap:break-word;position:relative}.wpnbha article:last-of-type{margin-bottom:0}.wpnbha .article-section-title{font-size:.8em;margin-bottom:.5em;width:100%}.wpnbha .article-section-title mark{background-color:transparent}.wpnbha.is-grid>div{display:flex;flex-flow:row wrap;justify-content:flex-start;gap:var(--wpnbha-col-gap);padding:0;list-style:none}.wpnbha.is-grid article{flex-basis:100%;margin-bottom:0}.wpnbha.is-grid .article-section-title{margin-bottom:calc(1em - var(--wpnbha-col-gap))}@media only screen and (min-width:600px){.wpnbha.columns-3 article,.wpnbha.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)/3*2)}.wpnbha.is-style-borders.columns-3 article,.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)*2/3*2 - 1px)}.wpnbha.columns-2 article,.wpnbha.columns-4 article,.wpnbha.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)/2)}.wpnbha.is-style-borders.columns-2 article,.wpnbha.is-style-borders.columns-4 article,.wpnbha.is-style-borders.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)*2/2 - 1px)}.wpnbha.columns-5 article:last-of-type,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:100%}}@media only screen and (min-width:782px){.wpnbha.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)/4*3)}.wpnbha.is-style-borders.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)*2/4*3 - 1px)}.wpnbha.columns-5 article,.wpnbha.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)/5*4)}.wpnbha.is-style-borders.columns-5 article,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)*2/5*4 - 1px)}.wpnbha.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)/6*5)}.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)*2/6*5 - 1px)}}.wpnbha .post-thumbnail{margin:0 0 .25em}.wpnbha .post-thumbnail img{height:auto;width:100%}.wpnbha .post-thumbnail figcaption{margin-bottom:.5em}.wpnbha figcaption{font-size:.6em}.wpnbha.image-alignleft .post-has-image,.wpnbha.image-alignright .post-has-image{display:flex}.wpnbha.image-alignleft .post-has-image .post-thumbnail,.wpnbha.image-alignright .post-has-image .post-thumbnail{flex-basis:33%}.wpnbha.image-alignleft .post-has-image .entry-wrapper,.wpnbha.image-alignright .post-has-image .entry-wrapper{flex-basis:67%}.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:block}@media only screen and (min-width:600px){.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:flex}}@media only screen and (min-width:600px){.wpnbha.image-alignleft.is-4 .post-thumbnail,.wpnbha.image-alignright.is-4 .post-thumbnail{flex-basis:75%}.wpnbha.image-alignleft.is-4 .entry-wrapper,.wpnbha.image-alignright.is-4 .entry-wrapper{flex-basis:25%}.wpnbha.image-alignleft.is-3 .entry-wrapper,.wpnbha.image-alignleft.is-3 .post-thumbnail,.wpnbha.image-alignright.is-3 .entry-wrapper,.wpnbha.image-alignright.is-3 .post-thumbnail{flex-basis:50%}}.wpnbha.image-alignleft.is-1 .post-thumbnail,.wpnbha.image-alignright.is-1 .post-thumbnail{flex-basis:25%}.wpnbha.image-alignleft.is-1 .entry-wrapper,.wpnbha.image-alignright.is-1 .entry-wrapper{flex-basis:75%}.wpnbha.image-alignleft .post-thumbnail{margin-left:1em}.wpnbha.image-alignright .post-thumbnail{margin-right:1em}.wpnbha.image-alignright .entry-wrapper{order:-1}.wpnbha.mobile-stack.image-alignleft .post-thumbnail,.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-right:0;margin-left:0}@media only screen and (min-width:600px){.wpnbha.mobile-stack.image-alignleft .post-thumbnail{margin-left:1em}.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-right:1em}}.wpnbha .entry-title{margin:0 0 .25em}.wpnbha .entry-title a{color:inherit;text-decoration:none}.wpnbha .entry-meta{display:flex;flex-wrap:wrap;align-items:center;margin-top:.5em}.wpnbha .entry-meta .byline:not(:last-child){margin-left:1.5em}.wpnbha .entry-meta .updated{display:none}.wpnbha .entry-meta .updated.published{display:block}.wpnbha .avatar{border-radius:100%;display:block;margin-left:.5em}.wpnbha p{margin:.5em 0}.wpnbha.has-text-color .article-section-title,.wpnbha.has-text-color .cat-links,.wpnbha.has-text-color .cat-links a,.wpnbha.has-text-color .cat-links a:visited,.wpnbha.has-text-color .entry-meta,.wpnbha.has-text-color .entry-meta .byline a,.wpnbha.has-text-color .entry-meta .byline a:visited,.wpnbha.has-text-color .entry-meta a,.wpnbha.has-text-color .entry-title,.wpnbha.has-text-color .entry-title a,.wpnbha.has-text-color .entry-title a:visited,.wpnbha.has-text-color figcaption{color:inherit}.wpnbha.has-text-color .entry-meta span:not(.avatar){opacity:.8}.wpnbha.image-alignbehind .post-has-image{display:flex;align-items:flex-end;position:relative}.wpnbha.image-alignbehind .post-has-image .post-thumbnail{inset:0;margin:0;overflow:hidden;position:absolute}.wpnbha.image-alignbehind .post-has-image .post-thumbnail img{height:100%!important;-o-object-fit:cover!important;object-fit:cover!important;margin:0!important;max-width:1000%!important;width:100%!important}.wpnbha.image-alignbehind .post-has-image .post-thumbnail:after{background:rgba(0,0,0,.5);content:"";inset:0;position:absolute;z-index:1}.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1rem;position:relative;width:100%;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1.5rem}}.wpnbha.image-alignbehind .post-has-image .cat-links a,.wpnbha.image-alignbehind .post-has-image .entry-meta,.wpnbha.image-alignbehind .post-has-image .entry-meta .byline a,.wpnbha.image-alignbehind .post-has-image .entry-title a,.wpnbha.image-alignbehind .post-has-image .entry-wrapper{color:#fff}.wpnbha.image-alignbehind figcaption{bottom:1em;-webkit-box-orient:vertical;color:hsla(0,0%,100%,.9);display:-webkit-box;font-style:italic;right:0;-webkit-line-clamp:1;margin:0;max-height:1.6em;overflow:hidden;padding:0 1rem;position:absolute;left:0;text-align:left;text-overflow:ellipsis;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind figcaption{padding:0 1.5rem}}.wpnbha .error,.wpnbha .loading,.wpnbha button{display:none}.wpnbha>button{margin-top:1em}.wpnbha.has-more-button button{display:block}.wpnbha.has-more-button.is-loading button{display:none}.wpnbha.has-more-button.is-error .error,.wpnbha.has-more-button.is-error button,.wpnbha.has-more-button.is-loading .loading{display:block}.wpnbha .author-avatar,.wpnbha .byline,.wpnbha .cat-links,.wpnbha .posted-on,.wpnbha .tags-links{clip:auto;height:auto;position:relative;width:auto}.wpnbha.has-text-align-center .cat-links,.wpnbha.has-text-align-center .entry-meta,.wpnbha.has-text-align-center .entry-sponsors{justify-content:center}.wpnbha.has-text-align-center.image-alignbehind figcaption,.wpnbha.has-text-align-center figcaption{text-align:inherit}.wpnbha.has-text-align-right .cat-links,.wpnbha.has-text-align-right .entry-meta,.wpnbha.has-text-align-right .entry-sponsors,.wpnbha.has-text-align-right .sponsor-logos{justify-content:flex-end;text-align:left}.wpnbha.has-text-align-right figcaption{text-align:inherit}.wpnbha.has-text-align-right .entry-date:not(:first-child){margin-right:1.5em}.wpnbha.has-text-align-right .entry-meta .byline:not(:last-child){margin:0}.wpnbha .cat-links{display:flex;flex-wrap:wrap;font-size:.6em;font-weight:700;margin:0 0 .5em}.wpnbha .cat-links.sponsor-label{align-items:center;display:flex;gap:.5em}.wpnbha .cat-links a{text-decoration:none}.wpnbha .cat-links a:hover{text-decoration:underline}.wpnbha .entry-sponsors{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.25em;width:100%}.wpnbha .entry-sponsors.plus-author{font-size:.9em}.wpnbha .entry-sponsors.plus-author:not(:last-child){margin-bottom:.5rem}.wpnbha .sponsor-logos{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.5em;line-height:1}.wpnbha article .entry-title{font-size:1.2em}.wpnbha article .entry-meta{font-size:.8em}.wpnbha article .avatar{height:25px;width:25px}@media only screen and (min-width:782px){.wpnbha article .entry-title{font-size:1.6em}.wpnbha article .avatar{height:40px;width:40px}}.wpnbha.ts-8 .entry-title,.wpnbha.ts-9 .entry-title,.wpnbha.ts-10 .entry-title{line-height:1.1}@media only screen and (min-width:782px){.wpnbha.ts-8 article .avatar,.wpnbha.ts-9 article .avatar,.wpnbha.ts-10 article .avatar{height:2.4em;width:2.4em}}.wpnbha.ts-7 .newspack-post-subtitle,.wpnbha.ts-8 .newspack-post-subtitle,.wpnbha.ts-9 .newspack-post-subtitle,.wpnbha.ts-10 .newspack-post-subtitle{font-size:1.4em}.wpnbha.ts-10 article .entry-title{font-size:2.6em}@media only screen and (min-width:782px){.wpnbha.ts-10 article .entry-title{font-size:3.6em}}@media only screen and (min-width:1168px){.wpnbha.ts-10 article .entry-title{font-size:4.8em}}.wpnbha.ts-9 article .entry-title{font-size:2.4em}@media only screen and (min-width:782px){.wpnbha.ts-9 article .entry-title{font-size:3.4em}}@media only screen and (min-width:1168px){.wpnbha.ts-9 article .entry-title{font-size:4.2em}}.wpnbha.ts-8 article .entry-title{font-size:2.2em}@media only screen and (min-width:782px){.wpnbha.ts-8 article .entry-title{font-size:3em}}@media only screen and (min-width:1168px){.wpnbha.ts-8 article .entry-title{font-size:3.6em}}.wpnbha.ts-7 article .entry-title{font-size:2em}@media only screen and (min-width:782px){.wpnbha.ts-7 article .entry-title{font-size:2.4em}.wpnbha.ts-7 article .avatar{height:48px;width:48px}}@media only screen and (min-width:1168px){.wpnbha.ts-7 article .entry-title{font-size:3em}}.wpnbha.ts-6 article .entry-title{font-size:1.7em}.wpnbha.ts-6 article .newspack-post-subtitle{font-size:1.4em}@media only screen and (min-width:782px){.wpnbha.ts-6 article .entry-title{font-size:2em}.wpnbha.ts-6 article .avatar{height:44px;width:44px}}@media only screen and (min-width:1168px){.wpnbha.ts-6 article .entry-title{font-size:2.4em}}.wpnbha.ts-5 article .entry-title{font-size:1.4em}.wpnbha.ts-5 article .newspack-post-subtitle{font-size:1.2em}@media only screen and (min-width:782px){.wpnbha.ts-5 article .entry-title{font-size:1.8em}.wpnbha.ts-5 article .avatar{height:40px;width:40px}}@media only screen and (min-width:1168px){.wpnbha.ts-5 article .entry-title{font-size:2em}}.wpnbha.ts-3 article .entry-title{font-size:1em}.wpnbha.ts-3 article .entry-meta,.wpnbha.ts-3 article .entry-wrapper .more-link,.wpnbha.ts-3 article .entry-wrapper p,.wpnbha.ts-3 article .newspack-post-subtitle{font-size:.8em}@media only screen and (min-width:782px){.wpnbha.ts-3 article .entry-title{font-size:1.2em}.wpnbha.ts-3 article .entry-meta{font-size:.7em}.wpnbha.ts-3 article .avatar{height:32px;width:32px}}.wpnbha.ts-1 article .entry-title,.wpnbha.ts-2 article .entry-title{font-size:.9em}.wpnbha.ts-1 article .entry-meta,.wpnbha.ts-1 article .entry-wrapper .more-link,.wpnbha.ts-1 article .entry-wrapper p,.wpnbha.ts-1 article .newspack-post-subtitle,.wpnbha.ts-2 article .entry-meta,.wpnbha.ts-2 article .entry-wrapper .more-link,.wpnbha.ts-2 article .entry-wrapper p,.wpnbha.ts-2 article .newspack-post-subtitle{font-size:.8em}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-meta,.wpnbha.ts-1 article .entry-wrapper .more-link,.wpnbha.ts-1 article .entry-wrapper p,.wpnbha.ts-1 article .newspack-post-subtitle,.wpnbha.ts-2 article .entry-meta,.wpnbha.ts-2 article .entry-wrapper .more-link,.wpnbha.ts-2 article .entry-wrapper p,.wpnbha.ts-2 article .newspack-post-subtitle{font-size:.7em}}@media only screen and (min-width:782px){.wpnbha.ts-2 article .entry-title{font-size:.9em}.wpnbha.ts-2 article .avatar{height:28px;width:28px}}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-title{font-size:.7em}.wpnbha.ts-1 article .avatar{height:24px;width:24px}}.wpnbha.is-style-borders article{border:solid rgba(0,0,0,.2);border-width:0 0 1px;box-sizing:content-box;padding-bottom:1em}.wpnbha.is-style-borders article:last-of-type:not(:first-of-type){border-bottom:0;padding-left:0}@media only screen and (min-width:600px){.wpnbha.is-style-borders.is-grid article{border-width:0;padding-left:0}.wpnbha.is-style-borders.columns-2 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+2):not(:last-of-type),.wpnbha.is-style-borders.columns-4 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-5 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+2):not(:last-of-type){border-width:0 0 0 1px;padding-left:var(--wpnbha-col-gap)}}@media only screen and (min-width:782px){.wpnbha.is-style-borders.is-grid article{border-width:0 0 0 1px;padding-left:var(--wpnbha-col-gap)}.wpnbha.is-style-borders.columns-1 article,.wpnbha.is-style-borders.columns-2 article:nth-of-type(2n),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n),.wpnbha.is-style-borders.columns-4 article:nth-of-type(4n),.wpnbha.is-style-borders.columns-5 article:nth-of-type(5n),.wpnbha.is-style-borders.columns-6 article:nth-of-type(6n),.wpnbha.is-style-borders.is-grid article:last-of-type{border:0;padding-left:0}}.newspack-post-subtitle--in-homepage-block{margin-top:.3em;margin-bottom:0;line-height:1.4;font-style:italic}
1
+ .newspack-preview-label{position:absolute;top:5px;right:5px;z-index:1;font-family:sans-serif;font-size:10px;text-transform:uppercase;background:#ffc000;padding:0 4px;border-radius:2px}:root{--wpnbha-col-gap:1em}@media only screen and (min-width:600px){:root{--wpnbha-col-gap:16px}}@media only screen and (min-width:782px){:root{--wpnbha-col-gap:32px}}@media only screen and (min-width:600px){.colgap-2{--wpnbha-col-gap:16px}}@media only screen and (min-width:600px){.colgap-1{--wpnbha-col-gap:8px}}.wpnbha{margin-bottom:1em}.wpnbha article{min-width:0;margin-bottom:1.5em;word-break:break-word;overflow-wrap:break-word;position:relative}.wpnbha article:last-of-type{margin-bottom:0}.wpnbha .article-section-title{font-size:.8em;margin-bottom:.5em;width:100%}.wpnbha .article-section-title mark{background-color:transparent}.wpnbha.is-grid>div{display:flex;flex-flow:row wrap;justify-content:flex-start;gap:var(--wpnbha-col-gap);padding:0;list-style:none}.wpnbha.is-grid article{flex-basis:100%;margin-bottom:0}.wpnbha.is-grid .article-section-title{margin-bottom:calc(1em - var(--wpnbha-col-gap))}@media only screen and (min-width:600px){.wpnbha.columns-3 article,.wpnbha.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)/3*2)}.wpnbha.is-style-borders.columns-3 article,.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(33.33% - var(--wpnbha-col-gap)*2/3*2 - 1px)}.wpnbha.columns-2 article,.wpnbha.columns-4 article,.wpnbha.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)/2)}.wpnbha.is-style-borders.columns-2 article,.wpnbha.is-style-borders.columns-4 article,.wpnbha.is-style-borders.columns-5 article{flex-basis:calc(50% - var(--wpnbha-col-gap)*2/2 - 1px)}.wpnbha.columns-5 article:last-of-type,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:100%}}@media only screen and (min-width:782px){.wpnbha.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)/4*3)}.wpnbha.is-style-borders.columns-4 article{flex-basis:calc(25% - var(--wpnbha-col-gap)*2/4*3 - 1px)}.wpnbha.columns-5 article,.wpnbha.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)/5*4)}.wpnbha.is-style-borders.columns-5 article,.wpnbha.is-style-borders.columns-5 article:last-of-type{flex-basis:calc(20% - var(--wpnbha-col-gap)*2/5*4 - 1px)}.wpnbha.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)/6*5)}.wpnbha.is-style-borders.columns-6 article{flex-basis:calc(16.6666% - var(--wpnbha-col-gap)*2/6*5 - 1px)}}.wpnbha figcaption{font-size:.6em}.wpnbha.image-alignleft .post-has-image,.wpnbha.image-alignright .post-has-image{display:flex}.wpnbha.image-alignleft .post-has-image .post-thumbnail,.wpnbha.image-alignright .post-has-image .post-thumbnail{flex-basis:33%}.wpnbha.image-alignleft .post-has-image .entry-wrapper,.wpnbha.image-alignright .post-has-image .entry-wrapper{flex-basis:67%}.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:block}@media only screen and (min-width:600px){.wpnbha.image-alignleft.mobile-stack .post-has-image,.wpnbha.image-alignright.mobile-stack .post-has-image{display:flex}}@media only screen and (min-width:600px){.wpnbha.image-alignleft.is-4 .post-thumbnail,.wpnbha.image-alignright.is-4 .post-thumbnail{flex-basis:75%}.wpnbha.image-alignleft.is-4 .entry-wrapper,.wpnbha.image-alignright.is-4 .entry-wrapper{flex-basis:25%}.wpnbha.image-alignleft.is-3 .entry-wrapper,.wpnbha.image-alignleft.is-3 .post-thumbnail,.wpnbha.image-alignright.is-3 .entry-wrapper,.wpnbha.image-alignright.is-3 .post-thumbnail{flex-basis:50%}}.wpnbha.image-alignleft.is-1 .post-thumbnail,.wpnbha.image-alignright.is-1 .post-thumbnail{flex-basis:25%}.wpnbha.image-alignleft.is-1 .entry-wrapper,.wpnbha.image-alignright.is-1 .entry-wrapper{flex-basis:75%}.wpnbha.image-alignleft .post-thumbnail{margin-left:1em}.wpnbha.image-alignright .post-thumbnail{margin-right:1em}.wpnbha.image-alignright .entry-wrapper{order:-1}.wpnbha.mobile-stack.image-alignleft .post-thumbnail,.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-right:0;margin-left:0}@media only screen and (min-width:600px){.wpnbha.mobile-stack.image-alignleft .post-thumbnail{margin-left:1em}.wpnbha.mobile-stack.image-alignright .post-thumbnail{margin-right:1em}}.wpnbha .entry-title{margin:0 0 .25em}.wpnbha .entry-title a{color:inherit;text-decoration:none}.wpnbha .entry-meta .byline:not(:last-child){margin-left:1.5em}.wpnbha .entry-meta .updated{display:none}.wpnbha .entry-meta .updated.published{display:block}.wpnbha .avatar{border-radius:100%;display:block;margin-left:.5em}.wpnbha.has-text-color .article-section-title,.wpnbha.has-text-color .cat-links,.wpnbha.has-text-color .cat-links a,.wpnbha.has-text-color .cat-links a:visited,.wpnbha.has-text-color .entry-meta,.wpnbha.has-text-color .entry-meta .byline a,.wpnbha.has-text-color .entry-meta .byline a:visited,.wpnbha.has-text-color .entry-meta a,.wpnbha.has-text-color .entry-title,.wpnbha.has-text-color .entry-title a,.wpnbha.has-text-color .entry-title a:visited,.wpnbha.has-text-color figcaption{color:inherit}.wpnbha.has-text-color .entry-meta span:not(.avatar){opacity:.8}.wpnbha.image-alignbehind .post-has-image{display:flex;align-items:flex-end;position:relative}.wpnbha.image-alignbehind .post-has-image .post-thumbnail{inset:0;margin:0;overflow:hidden;position:absolute}.wpnbha.image-alignbehind .post-has-image .post-thumbnail img{height:100%!important;-o-object-fit:cover!important;object-fit:cover!important;margin:0!important;max-width:1000%!important;width:100%!important}.wpnbha.image-alignbehind .post-has-image .post-thumbnail:after{background:rgba(0,0,0,.5);content:"";inset:0;position:absolute;z-index:1}.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1rem;position:relative;width:100%;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind .post-has-image .entry-wrapper{padding:2rem 1.5rem}}.wpnbha.image-alignbehind .post-has-image .cat-links a,.wpnbha.image-alignbehind .post-has-image .entry-meta,.wpnbha.image-alignbehind .post-has-image .entry-meta .byline a,.wpnbha.image-alignbehind .post-has-image .entry-title a,.wpnbha.image-alignbehind .post-has-image .entry-wrapper{color:#fff}.wpnbha.image-alignbehind figcaption{bottom:1em;-webkit-box-orient:vertical;color:hsla(0,0%,100%,.9);display:-webkit-box;font-style:italic;right:0;-webkit-line-clamp:1;margin:0;max-height:1.6em;overflow:hidden;padding:0 1rem;position:absolute;left:0;text-align:left;text-overflow:ellipsis;z-index:2}@media only screen and (min-width:1168px){.wpnbha.image-alignbehind figcaption{padding:0 1.5rem}}.wpnbha .error,.wpnbha .loading,.wpnbha button{display:none}.wpnbha>button{margin-top:1em}.wpnbha.has-more-button button{display:block}.wpnbha.has-more-button.is-loading button{display:none}.wpnbha.has-more-button.is-error .error,.wpnbha.has-more-button.is-error button,.wpnbha.has-more-button.is-loading .loading{display:block}.wpnbha .author-avatar,.wpnbha .byline,.wpnbha .cat-links,.wpnbha .posted-on,.wpnbha .tags-links{clip:auto;height:auto;position:relative;width:auto}.wpnbha.has-text-align-center .cat-links,.wpnbha.has-text-align-center .entry-meta,.wpnbha.has-text-align-center .entry-sponsors{justify-content:center}.wpnbha.has-text-align-center.image-alignbehind figcaption,.wpnbha.has-text-align-center figcaption{text-align:inherit}.wpnbha.has-text-align-right .cat-links,.wpnbha.has-text-align-right .entry-meta,.wpnbha.has-text-align-right .entry-sponsors,.wpnbha.has-text-align-right .sponsor-logos{justify-content:flex-end;text-align:left}.wpnbha.has-text-align-right figcaption{text-align:inherit}.wpnbha.has-text-align-right .entry-date:not(:first-child){margin-right:1.5em}.wpnbha.has-text-align-right .entry-meta .byline:not(:last-child){margin:0}.wpnbha .cat-links{display:flex;flex-wrap:wrap;font-size:.6em;font-weight:700;margin:0 0 .5em}.wpnbha .cat-links.sponsor-label{align-items:center;display:flex;gap:.5em}.wpnbha .cat-links a{text-decoration:none}.wpnbha .cat-links a:hover{text-decoration:underline}.wpnbha .entry-sponsors{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.25em;width:100%}.wpnbha .entry-sponsors.plus-author{font-size:.9em}.wpnbha .entry-sponsors.plus-author:not(:last-child){margin-bottom:.5rem}.wpnbha .sponsor-logos{align-items:center;display:inline-flex;flex-wrap:wrap;gap:.5em;line-height:1}@media only screen and (min-width:782px){.wpnbha article .entry-title{font-size:1.6em}.wpnbha article .avatar{height:40px;width:40px}}@media only screen and (min-width:782px){.wpnbha.ts-8 article .avatar,.wpnbha.ts-9 article .avatar,.wpnbha.ts-10 article .avatar{height:2.4em;width:2.4em}}@media only screen and (min-width:782px){.wpnbha.ts-10 article .entry-title{font-size:3.6em}}@media only screen and (min-width:1168px){.wpnbha.ts-10 article .entry-title{font-size:4.8em}}@media only screen and (min-width:782px){.wpnbha.ts-9 article .entry-title{font-size:3.4em}}@media only screen and (min-width:1168px){.wpnbha.ts-9 article .entry-title{font-size:4.2em}}@media only screen and (min-width:782px){.wpnbha.ts-8 article .entry-title{font-size:3em}}@media only screen and (min-width:1168px){.wpnbha.ts-8 article .entry-title{font-size:3.6em}}@media only screen and (min-width:782px){.wpnbha.ts-7 article .entry-title{font-size:2.4em}.wpnbha.ts-7 article .avatar{height:48px;width:48px}}@media only screen and (min-width:1168px){.wpnbha.ts-7 article .entry-title{font-size:3em}}@media only screen and (min-width:782px){.wpnbha.ts-6 article .entry-title{font-size:2em}.wpnbha.ts-6 article .avatar{height:44px;width:44px}}@media only screen and (min-width:1168px){.wpnbha.ts-6 article .entry-title{font-size:2.4em}}@media only screen and (min-width:782px){.wpnbha.ts-5 article .entry-title{font-size:1.8em}.wpnbha.ts-5 article .avatar{height:40px;width:40px}}@media only screen and (min-width:1168px){.wpnbha.ts-5 article .entry-title{font-size:2em}}@media only screen and (min-width:782px){.wpnbha.ts-3 article .entry-title{font-size:1.2em}.wpnbha.ts-3 article .entry-meta{font-size:.7em}.wpnbha.ts-3 article .avatar{height:32px;width:32px}}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-meta,.wpnbha.ts-1 article .entry-wrapper .more-link,.wpnbha.ts-1 article .entry-wrapper p,.wpnbha.ts-1 article .newspack-post-subtitle,.wpnbha.ts-2 article .entry-meta,.wpnbha.ts-2 article .entry-wrapper .more-link,.wpnbha.ts-2 article .entry-wrapper p,.wpnbha.ts-2 article .newspack-post-subtitle{font-size:.7em}}@media only screen and (min-width:782px){.wpnbha.ts-2 article .entry-title{font-size:.9em}.wpnbha.ts-2 article .avatar{height:28px;width:28px}}@media only screen and (min-width:782px){.wpnbha.ts-1 article .entry-title{font-size:.7em}.wpnbha.ts-1 article .avatar{height:24px;width:24px}}.wpnbha.is-style-borders article{border:solid rgba(0,0,0,.2);border-width:0 0 1px;box-sizing:content-box;padding-bottom:1em}.wpnbha.is-style-borders article:last-of-type:not(:first-of-type){border-bottom:0;padding-left:0}@media only screen and (min-width:600px){.wpnbha.is-style-borders.is-grid article{border-width:0;padding-left:0}.wpnbha.is-style-borders.columns-2 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n+2):not(:last-of-type),.wpnbha.is-style-borders.columns-4 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-5 article:nth-of-type(odd):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+1):not(:last-of-type),.wpnbha.is-style-borders.columns-6 article:nth-of-type(3n+2):not(:last-of-type){border-width:0 0 0 1px;padding-left:var(--wpnbha-col-gap)}}@media only screen and (min-width:782px){.wpnbha.is-style-borders.is-grid article{border-width:0 0 0 1px;padding-left:var(--wpnbha-col-gap)}.wpnbha.is-style-borders.columns-1 article,.wpnbha.is-style-borders.columns-2 article:nth-of-type(2n),.wpnbha.is-style-borders.columns-3 article:nth-of-type(3n),.wpnbha.is-style-borders.columns-4 article:nth-of-type(4n),.wpnbha.is-style-borders.columns-5 article:nth-of-type(5n),.wpnbha.is-style-borders.columns-6 article:nth-of-type(6n),.wpnbha.is-style-borders.is-grid article:last-of-type{border:0;padding-left:0}}
@@ -12,19 +12,19 @@ class Newspack_Blocks_API {
12
12
  /**
13
13
  * Get thumbnail featured image source for the rest field.
14
14
  *
15
- * @param array $object The object info.
15
+ * @param array $object_info The object info.
16
16
  * @return array | bool Featured image if available, false if not.
17
17
  */
18
- public static function newspack_blocks_get_image_src( $object ) {
18
+ public static function newspack_blocks_get_image_src( $object_info ) {
19
19
  $featured_image_set = [];
20
20
 
21
- if ( 0 === $object['featured_media'] ) {
21
+ if ( 0 === $object_info['featured_media'] ) {
22
22
  return false;
23
23
  }
24
24
 
25
25
  // Large image.
26
26
  $feat_img_array_large = wp_get_attachment_image_src(
27
- $object['featured_media'],
27
+ $object_info['featured_media'],
28
28
  'large',
29
29
  false
30
30
  );
@@ -34,7 +34,7 @@ class Newspack_Blocks_API {
34
34
  $landscape_size = Newspack_Blocks::image_size_for_orientation( 'landscape' );
35
35
 
36
36
  $feat_img_array_landscape = wp_get_attachment_image_src(
37
- $object['featured_media'],
37
+ $object_info['featured_media'],
38
38
  $landscape_size,
39
39
  false
40
40
  );
@@ -44,7 +44,7 @@ class Newspack_Blocks_API {
44
44
  $portrait_size = Newspack_Blocks::image_size_for_orientation( 'portrait' );
45
45
 
46
46
  $feat_img_array_portrait = wp_get_attachment_image_src(
47
- $object['featured_media'],
47
+ $object_info['featured_media'],
48
48
  $portrait_size,
49
49
  false
50
50
  );
@@ -54,7 +54,7 @@ class Newspack_Blocks_API {
54
54
  $square_size = Newspack_Blocks::image_size_for_orientation( 'square' );
55
55
 
56
56
  $feat_img_array_square = wp_get_attachment_image_src(
57
- $object['featured_media'],
57
+ $object_info['featured_media'],
58
58
  $square_size,
59
59
  false
60
60
  );
@@ -64,7 +64,7 @@ class Newspack_Blocks_API {
64
64
  $uncropped_size = 'newspack-article-block-uncropped';
65
65
 
66
66
  $feat_img_array_uncropped = wp_get_attachment_image_src(
67
- $object['featured_media'],
67
+ $object_info['featured_media'],
68
68
  $uncropped_size,
69
69
  false
70
70
  );
@@ -76,20 +76,20 @@ class Newspack_Blocks_API {
76
76
  /**
77
77
  * Get thumbnail featured image captions for the rest field.
78
78
  *
79
- * @param array $object The object info.
79
+ * @param array $object_info The object info.
80
80
  * @return string|null Image caption on success, null on failure.
81
81
  */
82
- public static function newspack_blocks_get_image_caption( $object ) {
83
- return (int) $object['featured_media'] > 0 ? trim( wp_get_attachment_caption( $object['featured_media'] ) ) : null;
82
+ public static function newspack_blocks_get_image_caption( $object_info ) {
83
+ return (int) $object_info['featured_media'] > 0 ? trim( wp_get_attachment_caption( $object_info['featured_media'] ) ) : null;
84
84
  }
85
85
 
86
86
  /**
87
87
  * Get author info for the rest field.
88
88
  *
89
- * @param array $object The object info.
89
+ * @param array $object_info The object info.
90
90
  * @return array Author data.
91
91
  */
92
- public static function newspack_blocks_get_author_info( $object ) {
92
+ public static function newspack_blocks_get_author_info( $object_info ) {
93
93
  $author_data = [];
94
94
 
95
95
  if ( function_exists( 'coauthors_posts_links' ) && ! empty( get_coauthors() ) ) :
@@ -116,13 +116,13 @@ class Newspack_Blocks_API {
116
116
  else :
117
117
  $author_data[] = array(
118
118
  /* Get the author name */
119
- 'display_name' => get_the_author_meta( 'display_name', $object['author'] ),
119
+ 'display_name' => get_the_author_meta( 'display_name', $object_info['author'] ),
120
120
  /* Get the author avatar */
121
- 'avatar' => get_avatar( $object['author'], 48 ),
121
+ 'avatar' => get_avatar( $object_info['author'], 48 ),
122
122
  /* Get the author ID */
123
- 'id' => $object['author'],
123
+ 'id' => $object_info['author'],
124
124
  /* Get the author Link */
125
- 'author_link' => get_author_posts_url( $object['author'] ),
125
+ 'author_link' => get_author_posts_url( $object_info['author'] ),
126
126
  );
127
127
  endif;
128
128
 
@@ -133,15 +133,15 @@ class Newspack_Blocks_API {
133
133
  /**
134
134
  * Get primary category for the rest field.
135
135
  *
136
- * @param array $object The object info.
136
+ * @param array $object_info The object info.
137
137
  * @return string Category name.
138
138
  */
139
- public static function newspack_blocks_get_primary_category( $object ) {
139
+ public static function newspack_blocks_get_primary_category( $object_info ) {
140
140
  $category = false;
141
141
 
142
142
  // Use Yoast primary category if set.
143
143
  if ( class_exists( 'WPSEO_Primary_Term' ) ) {
144
- $primary_term = new WPSEO_Primary_Term( 'category', $object['id'] );
144
+ $primary_term = new WPSEO_Primary_Term( 'category', $object_info['id'] );
145
145
  $category_id = $primary_term->get_primary_term();
146
146
  if ( $category_id ) {
147
147
  $category = get_term( $category_id );
@@ -149,7 +149,7 @@ class Newspack_Blocks_API {
149
149
  }
150
150
 
151
151
  if ( ! $category ) {
152
- $categories_list = get_the_category( $object['id'] );
152
+ $categories_list = get_the_category( $object_info['id'] );
153
153
  if ( ! empty( $categories_list ) ) {
154
154
  $category = $categories_list[0];
155
155
  }
@@ -167,22 +167,22 @@ class Newspack_Blocks_API {
167
167
  /**
168
168
  * Get a list of category, tag classes for the rest field.
169
169
  *
170
- * @param array $object The object info.
170
+ * @param array $object_info The object info.
171
171
  * @return string classes from assigned categories and tags.
172
172
  */
173
- public static function newspack_blocks_get_cat_tag_classes( $object ) {
174
- return Newspack_Blocks::get_term_classes( $object['id'] );
173
+ public static function newspack_blocks_get_cat_tag_classes( $object_info ) {
174
+ return Newspack_Blocks::get_term_classes( $object_info['id'] );
175
175
  }
176
176
 
177
177
  /**
178
178
  * Get all sponsor information for the rest field.
179
179
  *
180
- * @param array $object The object info.
180
+ * @param array $object_info The object info.
181
181
  * @return array sponsor information.
182
182
  */
183
- public static function newspack_blocks_sponsor_info( $object ) {
183
+ public static function newspack_blocks_sponsor_info( $object_info ) {
184
184
  $sponsors = Newspack_Blocks::get_all_sponsors(
185
- $object['id'],
185
+ $object_info['id'],
186
186
  'native',
187
187
  'post',
188
188
  array(
@@ -217,11 +217,11 @@ class Newspack_Blocks_API {
217
217
  /**
218
218
  * Pass whether there is a custom excerpt to the editor.
219
219
  *
220
- * @param array $object The object info.
220
+ * @param array $object_info The object info.
221
221
  * @return boolean custom excerpt status.
222
222
  */
223
- public static function newspack_blocks_has_custom_excerpt( $object ) {
224
- $post_has_custom_excerpt = has_excerpt( $object['id'] );
223
+ public static function newspack_blocks_has_custom_excerpt( $object_info ) {
224
+ $post_has_custom_excerpt = has_excerpt( $object_info['id'] );
225
225
  return $post_has_custom_excerpt;
226
226
  }
227
227
 
@@ -397,6 +397,20 @@ class Newspack_Blocks_API {
397
397
  $where .= ' AND post_title LIKE "%' . $search . '%" ';
398
398
  return $where;
399
399
  }
400
+
401
+ /**
402
+ * Return CSS for the Homepage Articles block, when rendered in the editor.
403
+ *
404
+ * @return WP_REST_Response.
405
+ */
406
+ public static function css_endpoint() {
407
+ return newspack_blocks_get_homepage_articles_css_string(
408
+ [
409
+ 'typeScale' => range( 1, 10 ),
410
+ 'showSubtitle' => [ 1 ],
411
+ ]
412
+ );
413
+ }
400
414
  }
401
415
 
402
416
  add_action( 'rest_api_init', array( 'Newspack_Blocks_API', 'register_video_playlist_endpoint' ) );
@@ -201,7 +201,7 @@ class Newspack_Blocks {
201
201
  'slug' => $tax->name,
202
202
  'label' => $tax->label,
203
203
  ];
204
- };
204
+ }
205
205
  },
206
206
  get_taxonomies(
207
207
  [
@@ -794,7 +794,7 @@ class Newspack_Blocks {
794
794
  * @param array $data Data to be passed into the template to be included.
795
795
  * @return string
796
796
  */
797
- public static function template_inc( $template, $data = array() ) { //phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable
797
+ public static function template_inc( $template, $data = array() ) { //phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable, Generic.CodeAnalysis.UnusedFunctionParameter.FoundAfterLastUsed
798
798
  if ( ! strpos( $template, '.php' ) ) {
799
799
  $template = $template . '.php';
800
800
  }
@@ -7,7 +7,7 @@
7
7
  * Author URI: https://newspack.com/
8
8
  * Text Domain: newspack-blocks
9
9
  * Domain Path: /languages
10
- * Version: 2.1.0
10
+ * Version: 2.2.0
11
11
  *
12
12
  * @package Newspack_Blocks
13
13
  */
@@ -15,7 +15,7 @@
15
15
  define( 'NEWSPACK_BLOCKS__PLUGIN_FILE', __FILE__ );
16
16
  define( 'NEWSPACK_BLOCKS__BLOCKS_DIRECTORY', 'dist/' );
17
17
  define( 'NEWSPACK_BLOCKS__PLUGIN_DIR', plugin_dir_path( NEWSPACK_BLOCKS__PLUGIN_FILE ) );
18
- define( 'NEWSPACK_BLOCKS__VERSION', '2.1.0' );
18
+ define( 'NEWSPACK_BLOCKS__VERSION', '2.2.0' );
19
19
 
20
20
  require_once NEWSPACK_BLOCKS__PLUGIN_DIR . 'includes/class-newspack-blocks.php';
21
21
  require_once NEWSPACK_BLOCKS__PLUGIN_DIR . 'includes/class-newspack-blocks-api.php';
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@automattic/newspack-blocks",
3
- "version": "2.1.0",
3
+ "version": "2.2.0",
4
4
  "author": "Automattic",
5
5
  "devDependencies": {
6
6
  "@rushstack/eslint-patch": "^1.5.1",
7
7
  "@testing-library/dom": "^9.3.3",
8
- "@testing-library/user-event": "^14.4.3",
8
+ "@testing-library/user-event": "^14.5.1",
9
9
  "@types/lodash": "^4.14.200",
10
- "@types/lodash.debounce": "^4.0.7",
10
+ "@types/lodash.debounce": "^4.0.8",
11
11
  "eslint": "^7.32.0",
12
12
  "fetch-mock-jest": "^1.5.1",
13
13
  "html-entities": "^2.4.0",
@@ -16,11 +16,11 @@
16
16
  "newspack-scripts": "^5.1.0",
17
17
  "postcss-scss": "^4.0.9",
18
18
  "prettier": "npm:wp-prettier@^2.6.2-beta-1",
19
- "stylelint": "^15.10.3"
19
+ "stylelint": "^15.11.0"
20
20
  },
21
21
  "description": "=== Newspack Blocks === Contributors: (this should be a list of wordpress.org userid's) Donate link: https://example.com/ Tags: comments, spam Requires at least: 4.5 Tested up to: 5.1.1 Stable tag: 0.1.0 License: GPLv2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html",
22
22
  "dependencies": {
23
- "@stripe/stripe-js": "^2.1.7",
23
+ "@stripe/stripe-js": "^2.1.11",
24
24
  "classnames": "^2.3.2",
25
25
  "lodash": "^4.17.21",
26
26
  "newspack-components": "^2.1.0",
@@ -7,7 +7,7 @@
7
7
 
8
8
  return array(
9
9
  'title' => __( 'Subscribe Pattern 1', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-1\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-1\"><div class=\"wp-block-group__inner-container\"><!-- wp:media-text {\"align\":\"\",\"mediaPosition\":\"right\",\"mediaId\":131,\"mediaType\":\"image\",\"verticalAlignment\":\"center\",\"imageFill\":true,\"backgroundColor\":\"light-gray\",\"className\":\"has-background\"} -->\n<div class=\"wp-block-media-text has-media-on-the-right is-stacked-on-mobile is-vertically-aligned-center is-image-fill has-background has-light-gray-background-color has-background\"><figure class=\"wp-block-media-text__media\" style=\"background-image:url(https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg);background-position:50% 50%\"><img src=\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\" alt=\"\" class=\"wp-image-131 size-full\"/></figure><div class=\"wp-block-media-text__content\"><!-- wp:spacer {\"height\":32} -->\n<div style=\"height:32px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer -->\n\n<!-- wp:heading -->\n<h2>" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading -->\n\n<!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us and Mailchimp to receive marketing, updates, and other emails from us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\",\"interests\":[]} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp -->\n\n<!-- wp:spacer {\"height\":32} -->\n<div style=\"height:32px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer --></div></div>\n<!-- /wp:media-text --></div></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-1\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-1\"><div class=\"wp-block-group__inner-container\"><!-- wp:media-text {\"align\":\"\",\"mediaPosition\":\"right\",\"mediaId\":131,\"mediaType\":\"image\",\"verticalAlignment\":\"center\",\"imageFill\":true,\"backgroundColor\":\"light-gray\",\"className\":\"has-background\"} -->\n<div class=\"wp-block-media-text has-media-on-the-right is-stacked-on-mobile is-vertically-aligned-center is-image-fill has-background has-light-gray-background-color has-background\"><figure class=\"wp-block-media-text__media\" style=\"background-image:url(https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg);background-position:50% 50%\"><img src=\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\" alt=\"\" class=\"wp-image-131 size-full\"/></figure><div class=\"wp-block-media-text__content\"><!-- wp:spacer {\"height\":32} -->\n<div style=\"height:32px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer -->\n\n<!-- wp:heading -->\n<h2>" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading -->\n\n<!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /-->\n\n<!-- wp:spacer {\"height\":32} -->\n<div style=\"height:32px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer --></div></div>\n<!-- /wp:media-text --></div></div>\n<!-- /wp:group -->",
11
11
  'viewportWidth' => 1000,
12
12
  'categories' => array( 'newspack-subscribe' ),
13
13
  );
@@ -7,6 +7,6 @@
7
7
 
8
8
  return array(
9
9
  'title' => esc_html__( 'Subscribe Pattern 10', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-10\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-10\"><!-- wp:columns -->\n<div class=\"wp-block-columns\"><!-- wp:column {\"width\":\"66.66%\"} -->\n<div class=\"wp-block-column\" style=\"flex-basis:66.66%\"><!-- wp:paragraph {\"lock\":{\"remove\":true}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"width\":\"33.33%\"} -->\n<div class=\"wp-block-column\" style=\"flex-basis:33.33%\"><!-- wp:jetpack/mailchimp {\"lock\":{\"remove\":true},\"consentText\":\"\"} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"borderRadius\":0,\"text\":\"→\"} /-->\n<!-- /wp:jetpack/mailchimp --></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-10\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-10\"><!-- wp:columns -->\n<div class=\"wp-block-columns\"><!-- wp:column {\"width\":\"60%\"} -->\n<div class=\"wp-block-column\" style=\"flex-basis:60%\"><!-- wp:paragraph {\"lock\":{\"remove\":true}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"width\":\"40%\"} -->\n<div class=\"wp-block-column\" style=\"flex-basis:40%\"><!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div>\n<!-- /wp:group -->",
11
11
  'categories' => array( 'newspack-subscribe' ),
12
12
  );
@@ -7,7 +7,7 @@
7
7
 
8
8
  return array(
9
9
  'title' => __( 'Subscribe Pattern 2', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-2\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-2\"><div class=\"wp-block-group__inner-container\"><!-- wp:cover {\"url\":\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\",\"id\":131} -->\n<div class=\"wp-block-cover has-background-dim\"><img class=\"wp-block-cover__image-background wp-image-131\" alt=\"\" src=\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\" data-object-fit=\"cover\"/><div class=\"wp-block-cover__inner-container\"><!-- wp:heading {\"textAlign\":\"center\",\"textColor\":\"white\"} -->\n<h2 class=\"has-text-align-center has-white-color has-text-color\">" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div></div>\n<!-- /wp:cover -->\n\n<!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us and Mailchimp to receive marketing, updates, and other emails from us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\",\"interests\":[]} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp --></div></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-2\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-2\"><div class=\"wp-block-group__inner-container\"><!-- wp:cover {\"url\":\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\",\"id\":131} -->\n<div class=\"wp-block-cover has-background-dim\"><img class=\"wp-block-cover__image-background wp-image-131\" alt=\"\" src=\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\" data-object-fit=\"cover\"/><div class=\"wp-block-cover__inner-container\"><!-- wp:heading {\"textAlign\":\"center\",\"textColor\":\"white\"} -->\n<h2 class=\"has-text-align-center has-white-color has-text-color\">" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div></div>\n<!-- /wp:cover -->\n\n<!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div></div>\n<!-- /wp:group -->",
11
11
  'viewportWidth' => 1000,
12
12
  'categories' => array( 'newspack-subscribe' ),
13
13
  );
@@ -7,7 +7,7 @@
7
7
 
8
8
  return array(
9
9
  'title' => __( 'Subscribe Pattern 3', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-3\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-3\"><!-- wp:columns {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-columns are-vertically-aligned-center\"><!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:cover {\"url\":\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\",\"id\":131,\"contentPosition\":\"center center\"} -->\n<div class=\"wp-block-cover has-background-dim\"><img class=\"wp-block-cover__image-background wp-image-131\" alt=\"\" src=\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\" data-object-fit=\"cover\"/><div class=\"wp-block-cover__inner-container\"><!-- wp:heading {\"textColor\":\"white\"} -->\n<h2 class=\"has-white-color has-text-color\">" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div></div>\n<!-- /wp:cover --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us and Mailchimp to receive marketing, updates, and other emails from us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\",\"interests\":[]} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp --></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-3\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-3\"><!-- wp:columns {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-columns are-vertically-aligned-center\"><!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:cover {\"url\":\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\",\"id\":131,\"contentPosition\":\"center center\"} -->\n<div class=\"wp-block-cover has-background-dim\"><img class=\"wp-block-cover__image-background wp-image-131\" alt=\"\" src=\"https://newspack.newspackstaging.com/wp-content/uploads/2020/03/automated_upload-62.jpg\" data-object-fit=\"cover\"/><div class=\"wp-block-cover__inner-container\"><!-- wp:heading {\"textColor\":\"white\"} -->\n<h2 class=\"has-white-color has-text-color\">" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div></div>\n<!-- /wp:cover --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div>\n<!-- /wp:group -->",
11
11
  'viewportWidth' => 1000,
12
12
  'categories' => array( 'newspack-subscribe' ),
13
13
  );
@@ -7,7 +7,7 @@
7
7
 
8
8
  return array(
9
9
  'title' => __( 'Subscribe Pattern 4', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-4\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-4\"><div class=\"wp-block-group__inner-container\"><!-- wp:columns {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-columns are-vertically-aligned-center\"><!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:heading -->\n<h2>" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us and Mailchimp to receive marketing, updates, and other emails from us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\",\"interests\":[]} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp --></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"className\":\"newspack-pattern subscribe__style-4\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-4\"><div class=\"wp-block-group__inner-container\"><!-- wp:columns {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-columns are-vertically-aligned-center\"><!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:heading -->\n<h2>" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\"><!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div></div>\n<!-- /wp:group -->",
11
11
  'viewportWidth' => 1000,
12
12
  'categories' => array( 'newspack-subscribe' ),
13
13
  );
@@ -7,7 +7,7 @@
7
7
 
8
8
  return array(
9
9
  'title' => __( 'Subscribe Pattern 5', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"align\":\"full\",\"backgroundColor\":\"primary\",\"textColor\":\"white\",\"className\":\"newspack-pattern subscribe__style-5\"} -->\n<div class=\"wp-block-group alignfull newspack-pattern subscribe__style-5 has-white-color has-primary-background-color has-text-color has-background\"><!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer -->\n\n<!-- wp:heading {\"textAlign\":\"center\",\"level\":4} -->\n<h4 class=\"has-text-align-center\">" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us and Mailchimp to receive marketing, updates, and other emails from us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\",\"interests\":[]} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\",\"textColor\":\"dark-gray\",\"backgroundColor\":\"white\",\"className\":\"is-style-fill\"} /-->\n<!-- /wp:jetpack/mailchimp -->\n\n<!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"align\":\"full\",\"backgroundColor\":\"primary\",\"textColor\":\"white\",\"className\":\"newspack-pattern subscribe__style-5\"} -->\n<div class=\"wp-block-group alignfull newspack-pattern subscribe__style-5 has-white-color has-primary-background-color has-text-color has-background\"><!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer -->\n\n<!-- wp:heading {\"textAlign\":\"center\",\"level\":4} -->\n<h4 class=\"has-text-align-center\">" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /-->\n\n<!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer --></div>\n<!-- /wp:group -->",
11
11
  'viewportWidth' => 1000,
12
12
  'categories' => array( 'newspack-subscribe' ),
13
13
  );
@@ -7,7 +7,7 @@
7
7
 
8
8
  return array(
9
9
  'title' => __( 'Subscribe Pattern 6', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"align\":\"full\",\"backgroundColor\":\"light-gray\",\"className\":\"newspack-pattern subscribe__style-6\"} -->\n<div class=\"wp-block-group alignfull newspack-pattern subscribe__style-6 has-light-gray-background-color has-background\"><!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer -->\n\n<!-- wp:columns {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-columns are-vertically-aligned-center\"><!-- wp:column {\"verticalAlignment\":\"center\",\"width\":\"33.33%\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\" style=\"flex-basis:33.33%\"><!-- wp:heading -->\n<h2>" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"verticalAlignment\":\"center\",\"width\":\"66.66%\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\" style=\"flex-basis:66.66%\"><!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us and Mailchimp to receive marketing, updates, and other emails from us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\",\"interests\":[]} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp --></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns -->\n\n<!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"align\":\"full\",\"backgroundColor\":\"light-gray\",\"className\":\"newspack-pattern subscribe__style-6\"} -->\n<div class=\"wp-block-group alignfull newspack-pattern subscribe__style-6 has-light-gray-background-color has-background\"><!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer -->\n\n<!-- wp:columns {\"verticalAlignment\":\"center\"} -->\n<div class=\"wp-block-columns are-vertically-aligned-center\"><!-- wp:column {\"verticalAlignment\":\"center\",\"width\":\"33.33%\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\" style=\"flex-basis:33.33%\"><!-- wp:heading -->\n<h2>" . esc_html__( 'Subscribe to our newsletter', 'newspack-blocks' ) . "</h2>\n<!-- /wp:heading --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"verticalAlignment\":\"center\",\"width\":\"66.66%\"} -->\n<div class=\"wp-block-column is-vertically-aligned-center\" style=\"flex-basis:66.66%\"><!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns -->\n\n<!-- wp:spacer {\"height\":7} -->\n<div style=\"height:7px\" aria-hidden=\"true\" class=\"wp-block-spacer\"></div>\n<!-- /wp:spacer --></div>\n<!-- /wp:group -->",
11
11
  'viewportWidth' => 1000,
12
12
  'categories' => array( 'newspack-subscribe' ),
13
13
  );
@@ -7,6 +7,6 @@
7
7
 
8
8
  return array(
9
9
  'title' => esc_html__( 'Subscribe Pattern 7', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-7\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-7\"><!-- wp:media-text {\"mediaId\":999,\"mediaLink\":\"https://newspackdev.mystagingwebsite.com/prompts-patterns/pexels-brotin-biswas-518543/\",\"mediaType\":\"image\",\"imageFill\":true} -->\n<div class=\"wp-block-media-text alignwide is-stacked-on-mobile is-image-fill\"><figure class=\"wp-block-media-text__media\" style=\"background-image:url(https://newspackdev.mystagingwebsite.com/wp-content/uploads/2022/03/pexels-brotin-biswas-518543-1024x683.jpeg);background-position:50% 50%\"><img src=\"https://newspackdev.mystagingwebsite.com/wp-content/uploads/2022/03/pexels-brotin-biswas-518543-1024x683.jpeg\" alt=\"\" class=\"wp-image-999 size-full\"/></figure><div class=\"wp-block-media-text__content\"><!-- wp:heading {\"lock\":{\"remove\":false},\"level\":4,\"className\":\"newspack-pattern__heading\"} -->\n<h4 class=\"newspack-pattern__heading\">" . esc_html__( 'Subscribe to our Newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:paragraph {\"lock\":{\"remove\":false}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph -->\n\n<!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\"} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\",\"width\":\"100%\"} /-->\n<!-- /wp:jetpack/mailchimp --></div></div>\n<!-- /wp:media-text --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-7\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-7\"><!-- wp:media-text {\"mediaId\":999,\"mediaLink\":\"https://newspackdev.mystagingwebsite.com/prompts-patterns/pexels-brotin-biswas-518543/\",\"mediaType\":\"image\",\"imageFill\":true} -->\n<div class=\"wp-block-media-text alignwide is-stacked-on-mobile is-image-fill\"><figure class=\"wp-block-media-text__media\" style=\"background-image:url(https://newspackdev.mystagingwebsite.com/wp-content/uploads/2022/03/pexels-brotin-biswas-518543-1024x683.jpeg);background-position:50% 50%\"><img src=\"https://newspackdev.mystagingwebsite.com/wp-content/uploads/2022/03/pexels-brotin-biswas-518543-1024x683.jpeg\" alt=\"\" class=\"wp-image-999 size-full\"/></figure><div class=\"wp-block-media-text__content\"><!-- wp:heading {\"lock\":{\"remove\":false},\"level\":4,\"className\":\"newspack-pattern__heading\"} -->\n<h4 class=\"newspack-pattern__heading\">" . esc_html__( 'Subscribe to our Newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:paragraph {\"lock\":{\"remove\":false}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph -->\n\n<!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div></div>\n<!-- /wp:media-text --></div>\n<!-- /wp:group -->",
11
11
  'categories' => array( 'newspack-subscribe' ),
12
12
  );
@@ -7,6 +7,6 @@
7
7
 
8
8
  return array(
9
9
  'title' => esc_html__( 'Subscribe Pattern 8', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-8\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-8\"><!-- wp:image {\"lock\":{\"remove\":false},\"id\":999} -->\n<figure class=\"wp-block-image\"><img src=\"https://newspack.newspackstaging.com/wp-content/uploads/2022/03/pexels-brotin-biswas-518543-crop-scaled.jpg\" alt=\"\" class=\"wp-image-999\"/></figure>\n<!-- /wp:image -->\n\n<!-- wp:group {\"className\":\"newspack-pattern__inner\"} -->\n<div class=\"wp-block-group newspack-pattern__inner\"><!-- wp:heading {\"lock\":{\"remove\":false},\"level\":4,\"className\":\"newspack-pattern__heading\"} -->\n<h4 class=\"newspack-pattern__heading\">" . esc_html__( 'Subscribe to our Newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:paragraph {\"lock\":{\"remove\":false}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph -->\n\n<!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\"} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp --></div>\n<!-- /wp:group --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-8\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-8\"><!-- wp:image {\"lock\":{\"remove\":false},\"id\":999} -->\n<figure class=\"wp-block-image\"><img src=\"https://newspack.newspackstaging.com/wp-content/uploads/2022/03/pexels-brotin-biswas-518543-crop-scaled.jpg\" alt=\"\" class=\"wp-image-999\"/></figure>\n<!-- /wp:image -->\n\n<!-- wp:group {\"className\":\"newspack-pattern__inner\"} -->\n<div class=\"wp-block-group newspack-pattern__inner\"><!-- wp:heading {\"lock\":{\"remove\":false},\"level\":4,\"className\":\"newspack-pattern__heading\"} -->\n<h4 class=\"newspack-pattern__heading\">" . esc_html__( 'Subscribe to our Newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:paragraph {\"lock\":{\"remove\":false}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph -->\n\n<!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div>\n<!-- /wp:group --></div>\n<!-- /wp:group -->",
11
11
  'categories' => array( 'newspack-subscribe' ),
12
12
  );
@@ -7,6 +7,6 @@
7
7
 
8
8
  return array(
9
9
  'title' => esc_html__( 'Subscribe Pattern 9', 'newspack-blocks' ),
10
- 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-9\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-9\"><!-- wp:columns -->\n<div class=\"wp-block-columns\"><!-- wp:column {\"templateLock\":\"all\"} -->\n<div class=\"wp-block-column\"><!-- wp:heading {\"lock\":{\"remove\":false},\"level\":4,\"className\":\"newspack-pattern__heading\"} -->\n<h4 class=\"newspack-pattern__heading\">" . esc_html__( 'Subscribe to our Newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:paragraph {\"lock\":{\"remove\":false}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"templateLock\":\"all\"} -->\n<div class=\"wp-block-column\"><!-- wp:jetpack/mailchimp {\"consentText\":\"" . esc_html__( 'By subscribing, you agree to share your email address with us. Use the unsubscribe link in those emails to opt out at any time.', 'newspack-blocks' ) . "\"} -->\n<!-- wp:jetpack/button {\"element\":\"button\",\"uniqueId\":\"mailchimp-widget-id\",\"text\":\"" . esc_html__( 'Subscribe', 'newspack-blocks' ) . "\"} /-->\n<!-- /wp:jetpack/mailchimp --></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div>\n<!-- /wp:group -->",
10
+ 'content' => "<!-- wp:group {\"templateLock\":\"all\",\"className\":\"newspack-pattern subscribe__style-9\"} -->\n<div class=\"wp-block-group newspack-pattern subscribe__style-9\"><!-- wp:columns -->\n<div class=\"wp-block-columns\"><!-- wp:column {\"templateLock\":\"all\"} -->\n<div class=\"wp-block-column\"><!-- wp:heading {\"lock\":{\"remove\":false},\"level\":4,\"className\":\"newspack-pattern__heading\"} -->\n<h4 class=\"newspack-pattern__heading\">" . esc_html__( 'Subscribe to our Newsletter', 'newspack-blocks' ) . "</h4>\n<!-- /wp:heading -->\n\n<!-- wp:paragraph {\"lock\":{\"remove\":false}} -->\n<p>" . esc_html__( 'Be the first to know about breaking news, articles, and updates.', 'newspack-blocks' ) . "</p>\n<!-- /wp:paragraph --></div>\n<!-- /wp:column -->\n\n<!-- wp:column {\"templateLock\":\"all\"} -->\n<div class=\"wp-block-column\"><!-- wp:newspack-newsletters/subscribe {\"lists\":[]} /--></div>\n<!-- /wp:column --></div>\n<!-- /wp:columns --></div>\n<!-- /wp:group -->",
11
11
  'categories' => array( 'newspack-subscribe' ),
12
12
  );
@@ -74,23 +74,21 @@ class WP_REST_Newspack_Author_List_Controller extends WP_REST_Newspack_Authors_C
74
74
  /**
75
75
  * Sanitize an array of text or number values.
76
76
  *
77
- * @param array $array Array of text or float values to be sanitized.
77
+ * @param array $array_to_sanitize Array of text or float values to be sanitized.
78
78
  * @return array Sanitized array.
79
79
  */
80
- public static function sanitize_array( $array ) {
81
- foreach ( $array as $value ) {
80
+ public static function sanitize_array( $array_to_sanitize ) {
81
+ foreach ( $array_to_sanitize as $value ) {
82
82
  if ( is_array( $value ) ) {
83
83
  $value = self::sanitize_array( $value );
84
- } else {
85
- if ( is_string( $value ) ) {
84
+ } elseif ( is_string( $value ) ) {
86
85
  $value = sanitize_text_field( $value );
87
- } else {
88
- $value = floatval( $value );
89
- }
86
+ } else {
87
+ $value = floatval( $value );
90
88
  }
91
89
  }
92
90
 
93
- return $array;
91
+ return $array_to_sanitize;
94
92
  }
95
93
 
96
94
  /**
@@ -221,7 +219,7 @@ class WP_REST_Newspack_Author_List_Controller extends WP_REST_Newspack_Authors_C
221
219
  // Keep querying until we have all guest authors.
222
220
  if ( $current_page < $number_of_pages ) {
223
221
  while ( $current_page < $number_of_pages ) {
224
- $current_page ++;
222
+ $current_page++;
225
223
  $guest_author_args['paged'] = $current_page;
226
224
  $results = new \WP_Query( $guest_author_args );
227
225
  $all_guest_authors = array_merge( $all_guest_authors, $results->posts );
@@ -278,7 +276,7 @@ class WP_REST_Newspack_Author_List_Controller extends WP_REST_Newspack_Authors_C
278
276
  // Keep querying until we have all users.
279
277
  if ( $current_page < $number_of_pages ) {
280
278
  while ( $current_page < $number_of_pages ) {
281
- $current_page ++;
279
+ $current_page++;
282
280
  $user_args['paged'] = $current_page;
283
281
  $results = new \WP_User_Query( $user_args );
284
282
  $all_users = array_merge( $all_users, $results->get_results() );