@automattic/newspack-blocks 1.75.0 → 1.75.1

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.
@@ -1 +1 @@
1
- <?php return array('dependencies' => array('wp-polyfill'), 'version' => '88ce194c80c6db88ae2ec7ceefe2ce69');
1
+ <?php return array('dependencies' => array('wp-polyfill'), 'version' => 'e24cf595a0dd48984927d3a4906b564f');
package/dist/modal.css CHANGED
@@ -1 +1 @@
1
- @-webkit-keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(180deg)}to{transform:rotate(1turn)}}@keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(180deg)}to{transform:rotate(1turn)}}.newspack-blocks-checkout-modal,.newspack-blocks-variation-modal{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.75);z-index:99999}.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:calc(100vw - 32px);max-width:580px;min-height:200px;max-height:calc(100vh - 32px);background:#fff;border-radius:5px}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close){width:100%;height:100%;border:0;border-radius:5px}.newspack-blocks-checkout-modal__spinner,.newspack-blocks-variation-modal__spinner{align-items:center;background:#fff;border-radius:5px;display:flex;height:100%;justify-content:center;left:50%;opacity:.5;position:absolute;top:50%;transform:translate(-50%,-50%);width:100%}.newspack-blocks-checkout-modal__spinner>span,.newspack-blocks-variation-modal__spinner>span{-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:2px solid #fff;border-top-color:#767676;border-radius:50%;height:25px;width:25px}.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close{position:absolute;top:0;right:0;padding:8px;border:0;background:transparent;color:#111;cursor:pointer}.newspack-blocks-checkout-modal__close:focus,.newspack-blocks-checkout-modal__close:hover,.newspack-blocks-variation-modal__close:focus,.newspack-blocks-variation-modal__close:hover{color:#767676}.newspack-blocks-checkout-modal__close svg,.newspack-blocks-variation-modal__close svg{display:block}.newspack-blocks-variation-modal__content{padding:32px}.newspack-blocks-variation-modal__content h3{margin:0 0 1em}.newspack-blocks-variation-modal__content p{font-size:.8em}.newspack-blocks-variation-modal__content form{margin:0 0 .5em}.newspack-blocks-variation-modal__content form:last-child{margin:0}.newspack-blocks-variation-modal__content form button{display:block;width:100%;padding:16px;margin:0;border:1px solid #ccc;background:transparent;color:#111;text-align:inherit;font-weight:inherit}.newspack-blocks-variation-modal__content form button>span{display:block}.newspack-blocks-variation-modal__content form button .summary{width:100%;display:flex;justify-content:space-between;align-items:flex-end}.newspack-blocks-variation-modal__content form button .summary .subscription-details bdi{font-size:inherit}.newspack-blocks-variation-modal__content form button .price{max-width:65%}.newspack-blocks-variation-modal__content form button .variation_name{font-weight:600;font-size:.9em;margin-left:.5em}.newspack-blocks-variation-modal__content form button .description{padding-top:1em;margin-top:1em;font-size:.9em;border-top:1px solid #ccc}.newspack-blocks-variation-modal__content form button bdi{font-weight:600;font-size:1.8em}@media(max-width:600px){.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{max-width:100%;width:100%;border-radius:0;top:auto;bottom:0;left:0;transform:none}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close){border-radius:0}}
1
+ @-webkit-keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(180deg)}to{transform:rotate(1turn)}}@keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(180deg)}to{transform:rotate(1turn)}}.newspack-blocks-checkout-modal,.newspack-blocks-variation-modal{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.75);z-index:99999}.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:calc(100vw - 32px);max-width:580px;min-height:200px;max-height:calc(100vh - 32px);background:#fff;border-radius:5px}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close){width:100%;height:100%;border:0;border-radius:5px}.newspack-blocks-checkout-modal__spinner,.newspack-blocks-variation-modal__spinner{align-items:center;background:#fff;border-radius:5px;display:flex;height:100%;justify-content:center;left:50%;opacity:.5;position:absolute;top:50%;transform:translate(-50%,-50%);width:100%}.newspack-blocks-checkout-modal__spinner>span,.newspack-blocks-variation-modal__spinner>span{-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:2px solid #fff;border-top-color:#767676;border-radius:50%;height:25px;width:25px}.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close{position:absolute;top:0;right:0;padding:8px;border:0;background:transparent;color:#111;cursor:pointer}.newspack-blocks-checkout-modal__close:focus,.newspack-blocks-checkout-modal__close:hover,.newspack-blocks-variation-modal__close:focus,.newspack-blocks-variation-modal__close:hover{color:#767676}.newspack-blocks-checkout-modal__close svg,.newspack-blocks-variation-modal__close svg{display:block}.newspack-blocks-variation-modal__content{padding:32px;overflow:auto;border-radius:5px}.newspack-blocks-variation-modal__content h3{margin:0 0 1em}.newspack-blocks-variation-modal__content p{font-size:.8em}.newspack-blocks-variation-modal__content form{margin:0 0 .5em}.newspack-blocks-variation-modal__content form:last-child{margin:0}.newspack-blocks-variation-modal__content form button{display:block;width:100%;padding:16px;margin:0;border:1px solid #ccc;background:transparent;color:#111;text-align:inherit;font-weight:inherit}.newspack-blocks-variation-modal__content form button>span{display:block}.newspack-blocks-variation-modal__content form button .summary{width:100%;display:flex;justify-content:space-between;align-items:flex-end}.newspack-blocks-variation-modal__content form button .summary .subscription-details bdi{font-size:inherit}.newspack-blocks-variation-modal__content form button .price{max-width:65%}.newspack-blocks-variation-modal__content form button .variation_name{font-weight:600;font-size:.9em;margin-left:.5em}.newspack-blocks-variation-modal__content form button .description{padding-top:1em;margin-top:1em;font-size:.9em;border-top:1px solid #ccc}.newspack-blocks-variation-modal__content form button bdi{font-weight:600;font-size:1.8em}@media(max-width:600px){.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{max-width:100%;width:100%;border-radius:0;top:auto;bottom:0;left:0;transform:none}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close){border-radius:0}}
@@ -1 +1 @@
1
- @-webkit-keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(-180deg)}to{transform:rotate(-1turn)}}@keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(-180deg)}to{transform:rotate(-1turn)}}.newspack-blocks-checkout-modal,.newspack-blocks-variation-modal{position:fixed;top:0;right:0;width:100%;height:100%;background:rgba(0,0,0,.75);z-index:99999}.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{position:absolute;top:50%;right:50%;transform:translate(50%,-50%);width:calc(100vw - 32px);max-width:580px;min-height:200px;max-height:calc(100vh - 32px);background:#fff;border-radius:5px}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close){width:100%;height:100%;border:0;border-radius:5px}.newspack-blocks-checkout-modal__spinner,.newspack-blocks-variation-modal__spinner{align-items:center;background:#fff;border-radius:5px;display:flex;height:100%;justify-content:center;right:50%;opacity:.5;position:absolute;top:50%;transform:translate(50%,-50%);width:100%}.newspack-blocks-checkout-modal__spinner>span,.newspack-blocks-variation-modal__spinner>span{-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:2px solid #fff;border-top-color:#767676;border-radius:50%;height:25px;width:25px}.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close{position:absolute;top:0;left:0;padding:8px;border:0;background:transparent;color:#111;cursor:pointer}.newspack-blocks-checkout-modal__close:focus,.newspack-blocks-checkout-modal__close:hover,.newspack-blocks-variation-modal__close:focus,.newspack-blocks-variation-modal__close:hover{color:#767676}.newspack-blocks-checkout-modal__close svg,.newspack-blocks-variation-modal__close svg{display:block}.newspack-blocks-variation-modal__content{padding:32px}.newspack-blocks-variation-modal__content h3{margin:0 0 1em}.newspack-blocks-variation-modal__content p{font-size:.8em}.newspack-blocks-variation-modal__content form{margin:0 0 .5em}.newspack-blocks-variation-modal__content form:last-child{margin:0}.newspack-blocks-variation-modal__content form button{display:block;width:100%;padding:16px;margin:0;border:1px solid #ccc;background:transparent;color:#111;text-align:inherit;font-weight:inherit}.newspack-blocks-variation-modal__content form button>span{display:block}.newspack-blocks-variation-modal__content form button .summary{width:100%;display:flex;justify-content:space-between;align-items:flex-end}.newspack-blocks-variation-modal__content form button .summary .subscription-details bdi{font-size:inherit}.newspack-blocks-variation-modal__content form button .price{max-width:65%}.newspack-blocks-variation-modal__content form button .variation_name{font-weight:600;font-size:.9em;margin-right:.5em}.newspack-blocks-variation-modal__content form button .description{padding-top:1em;margin-top:1em;font-size:.9em;border-top:1px solid #ccc}.newspack-blocks-variation-modal__content form button bdi{font-weight:600;font-size:1.8em}@media(max-width:600px){.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{max-width:100%;width:100%;border-radius:0;top:auto;bottom:0;right:0;transform:none}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close){border-radius:0}}
1
+ @-webkit-keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(-180deg)}to{transform:rotate(-1turn)}}@keyframes spin{0%{transform:rotate(0deg)}50%{transform:rotate(-180deg)}to{transform:rotate(-1turn)}}.newspack-blocks-checkout-modal,.newspack-blocks-variation-modal{position:fixed;top:0;right:0;width:100%;height:100%;background:rgba(0,0,0,.75);z-index:99999}.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{position:absolute;top:50%;right:50%;transform:translate(50%,-50%);width:calc(100vw - 32px);max-width:580px;min-height:200px;max-height:calc(100vh - 32px);background:#fff;border-radius:5px}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close){width:100%;height:100%;border:0;border-radius:5px}.newspack-blocks-checkout-modal__spinner,.newspack-blocks-variation-modal__spinner{align-items:center;background:#fff;border-radius:5px;display:flex;height:100%;justify-content:center;right:50%;opacity:.5;position:absolute;top:50%;transform:translate(50%,-50%);width:100%}.newspack-blocks-checkout-modal__spinner>span,.newspack-blocks-variation-modal__spinner>span{-webkit-animation:spin 1s linear infinite;animation:spin 1s linear infinite;border:2px solid #fff;border-top-color:#767676;border-radius:50%;height:25px;width:25px}.newspack-blocks-checkout-modal__close,.newspack-blocks-variation-modal__close{position:absolute;top:0;left:0;padding:8px;border:0;background:transparent;color:#111;cursor:pointer}.newspack-blocks-checkout-modal__close:focus,.newspack-blocks-checkout-modal__close:hover,.newspack-blocks-variation-modal__close:focus,.newspack-blocks-variation-modal__close:hover{color:#767676}.newspack-blocks-checkout-modal__close svg,.newspack-blocks-variation-modal__close svg{display:block}.newspack-blocks-variation-modal__content{padding:32px;overflow:auto;border-radius:5px}.newspack-blocks-variation-modal__content h3{margin:0 0 1em}.newspack-blocks-variation-modal__content p{font-size:.8em}.newspack-blocks-variation-modal__content form{margin:0 0 .5em}.newspack-blocks-variation-modal__content form:last-child{margin:0}.newspack-blocks-variation-modal__content form button{display:block;width:100%;padding:16px;margin:0;border:1px solid #ccc;background:transparent;color:#111;text-align:inherit;font-weight:inherit}.newspack-blocks-variation-modal__content form button>span{display:block}.newspack-blocks-variation-modal__content form button .summary{width:100%;display:flex;justify-content:space-between;align-items:flex-end}.newspack-blocks-variation-modal__content form button .summary .subscription-details bdi{font-size:inherit}.newspack-blocks-variation-modal__content form button .price{max-width:65%}.newspack-blocks-variation-modal__content form button .variation_name{font-weight:600;font-size:.9em;margin-right:.5em}.newspack-blocks-variation-modal__content form button .description{padding-top:1em;margin-top:1em;font-size:.9em;border-top:1px solid #ccc}.newspack-blocks-variation-modal__content form button bdi{font-weight:600;font-size:1.8em}@media(max-width:600px){.newspack-blocks-checkout-modal__content,.newspack-blocks-variation-modal__content{max-width:100%;width:100%;border-radius:0;top:auto;bottom:0;right:0;transform:none}.newspack-blocks-checkout-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close),.newspack-blocks-variation-modal__content>:not(.newspack-blocks-variation-modal__close,.newspack-blocks-checkout-modal__close){border-radius:0}}
@@ -707,6 +707,7 @@ class Newspack_Blocks {
707
707
  if ( $authors && count( $authors ) ) {
708
708
  $co_authors_names = [];
709
709
  $author_names = [];
710
+ $author_emails = [];
710
711
 
711
712
  if ( $is_co_authors_plus_active ) {
712
713
  $co_authors_guest_authors = new CoAuthors_Guest_Authors();
@@ -736,7 +737,8 @@ class Newspack_Blocks {
736
737
  unset( $authors[ $index ] );
737
738
  }
738
739
  } else {
739
- $author_names[] = $author_data->user_login;
740
+ $author_names[] = $author_data->user_login;
741
+ $author_emails[] = $author_data->user_email;
740
742
  }
741
743
  }
742
744
  }
@@ -771,6 +773,11 @@ class Newspack_Blocks {
771
773
  'taxonomy' => 'author',
772
774
  'terms' => $author_names,
773
775
  ],
776
+ [
777
+ 'field' => 'name',
778
+ 'taxonomy' => 'author',
779
+ 'terms' => $author_emails,
780
+ ],
774
781
  ],
775
782
  ];
776
783
  }
@@ -7,7 +7,7 @@
7
7
  * Author URI: https://newspack.blog/
8
8
  * Text Domain: newspack-blocks
9
9
  * Domain Path: /languages
10
- * Version: 1.75.0
10
+ * Version: 1.75.1
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', '1.75.0' );
18
+ define( 'NEWSPACK_BLOCKS__VERSION', '1.75.1' );
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,6 +1,6 @@
1
1
  {
2
2
  "name": "@automattic/newspack-blocks",
3
- "version": "1.75.0",
3
+ "version": "1.75.1",
4
4
  "author": "Automattic",
5
5
  "devDependencies": {
6
6
  "@rushstack/eslint-patch": "^1.3.3",
@@ -167,7 +167,7 @@ function CheckoutButtonEdit( props ) {
167
167
  // Handle product variation data.
168
168
  if ( data?.variations?.length ) {
169
169
  setAttributes( { is_variable: true } );
170
- apiFetch( { path: `/wc/v2/products/${ data.id }/variations` } )
170
+ apiFetch( { path: `/wc/v2/products/${ data.id }/variations?per_page=100` } )
171
171
  .then( res => setVariations( res ) )
172
172
  .catch( () => setVariations( [] ) );
173
173
  } else {
@@ -51,7 +51,7 @@
51
51
  opacity: 0.5;
52
52
  position: absolute;
53
53
  top: 50%;
54
- transform: translate(-50%, -50%);
54
+ transform: translate( -50%, -50% );
55
55
  width: 100%;
56
56
  > span {
57
57
  animation: spin 1s infinite linear;
@@ -84,6 +84,8 @@
84
84
  .newspack-blocks-variation-modal {
85
85
  &__content {
86
86
  padding: 32px;
87
+ overflow: auto;
88
+ border-radius: 5px;
87
89
  h3 {
88
90
  margin: 0 0 1em;
89
91
  }
@@ -22,4 +22,4 @@ if (PHP_VERSION_ID < 50600) {
22
22
 
23
23
  require_once __DIR__ . '/composer/autoload_real.php';
24
24
 
25
- return ComposerAutoloaderInit3bb65053d47ca5edc96c5e708aaa5746::getLoader();
25
+ return ComposerAutoloaderInitb21f5e3c3fae90e3d1fa6a4b24a3b56c::getLoader();
@@ -2,7 +2,7 @@
2
2
 
3
3
  // autoload_real.php @generated by Composer
4
4
 
5
- class ComposerAutoloaderInit3bb65053d47ca5edc96c5e708aaa5746
5
+ class ComposerAutoloaderInitb21f5e3c3fae90e3d1fa6a4b24a3b56c
6
6
  {
7
7
  private static $loader;
8
8
 
@@ -22,12 +22,12 @@ class ComposerAutoloaderInit3bb65053d47ca5edc96c5e708aaa5746
22
22
  return self::$loader;
23
23
  }
24
24
 
25
- spl_autoload_register(array('ComposerAutoloaderInit3bb65053d47ca5edc96c5e708aaa5746', 'loadClassLoader'), true, true);
25
+ spl_autoload_register(array('ComposerAutoloaderInitb21f5e3c3fae90e3d1fa6a4b24a3b56c', 'loadClassLoader'), true, true);
26
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
27
- spl_autoload_unregister(array('ComposerAutoloaderInit3bb65053d47ca5edc96c5e708aaa5746', 'loadClassLoader'));
27
+ spl_autoload_unregister(array('ComposerAutoloaderInitb21f5e3c3fae90e3d1fa6a4b24a3b56c', 'loadClassLoader'));
28
28
 
29
29
  require __DIR__ . '/autoload_static.php';
30
- call_user_func(\Composer\Autoload\ComposerStaticInit3bb65053d47ca5edc96c5e708aaa5746::getInitializer($loader));
30
+ call_user_func(\Composer\Autoload\ComposerStaticInitb21f5e3c3fae90e3d1fa6a4b24a3b56c::getInitializer($loader));
31
31
 
32
32
  $loader->register(true);
33
33
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  namespace Composer\Autoload;
6
6
 
7
- class ComposerStaticInit3bb65053d47ca5edc96c5e708aaa5746
7
+ class ComposerStaticInitb21f5e3c3fae90e3d1fa6a4b24a3b56c
8
8
  {
9
9
  public static $classMap = array (
10
10
  'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
@@ -13,7 +13,7 @@ class ComposerStaticInit3bb65053d47ca5edc96c5e708aaa5746
13
13
  public static function getInitializer(ClassLoader $loader)
14
14
  {
15
15
  return \Closure::bind(function () use ($loader) {
16
- $loader->classMap = ComposerStaticInit3bb65053d47ca5edc96c5e708aaa5746::$classMap;
16
+ $loader->classMap = ComposerStaticInitb21f5e3c3fae90e3d1fa6a4b24a3b56c::$classMap;
17
17
 
18
18
  }, null, ClassLoader::class);
19
19
  }
@@ -3,7 +3,7 @@
3
3
  'name' => 'automattic/newspack-blocks',
4
4
  'pretty_version' => 'dev-master',
5
5
  'version' => 'dev-master',
6
- 'reference' => '2bf42ceb9fbeba7f9bb44300ef1c64e8458bd5cc',
6
+ 'reference' => '49406b9bf1075897939cad2e4c30f34efcf841da',
7
7
  'type' => 'wordpress-plugin',
8
8
  'install_path' => __DIR__ . '/../../',
9
9
  'aliases' => array(),
@@ -13,7 +13,7 @@
13
13
  'automattic/newspack-blocks' => array(
14
14
  'pretty_version' => 'dev-master',
15
15
  'version' => 'dev-master',
16
- 'reference' => '2bf42ceb9fbeba7f9bb44300ef1c64e8458bd5cc',
16
+ 'reference' => '49406b9bf1075897939cad2e4c30f34efcf841da',
17
17
  'type' => 'wordpress-plugin',
18
18
  'install_path' => __DIR__ . '/../../',
19
19
  'aliases' => array(),