@automattic/newspack-blocks 1.75.6 → 2.0.0-alpha.2
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.
- package/.cache/babel/05ef61416b32f57c09787aa5b64d2174.json.gz +0 -0
- package/.cache/babel/161346fa97c507c17228f7da8926b1a2.json.gz +0 -0
- package/.cache/babel/1f43960564787ebde7c6d44957cddf0e.json.gz +0 -0
- package/.cache/babel/2f22325668b5763f8f2c9557833af36f.json.gz +0 -0
- package/.cache/babel/3e0ce774e995d778a0c3c43825791fdf.json.gz +0 -0
- package/.cache/babel/6d457f8985600b07d97aebc4e1a21855.json.gz +0 -0
- package/.cache/babel/98c36ce1c809c31c7b1a84794c9233d3.json.gz +0 -0
- package/.cache/babel/a2068f9bffb6026a246057f4a1058bd9.json.gz +0 -0
- package/.cache/babel/a3f4c297e3a52f8342c1ffea1b4b1c0c.json.gz +0 -0
- package/.cache/babel/e1d8932bb19afa36f476f107dbc6ca39.json.gz +0 -0
- package/CHANGELOG.md +8 -0
- package/composer.lock +13 -13
- package/dist/carousel/view.asset.php +1 -1
- package/dist/carousel/view.css +1 -1
- package/dist/carousel/view.js +1 -1
- package/dist/carousel/view.rtl.css +1 -1
- package/dist/donateStreamlined.asset.php +1 -1
- package/dist/donateStreamlined.js +1 -1
- package/dist/editor.asset.php +1 -1
- package/dist/editor.css +1 -1
- package/dist/editor.js +3 -3
- package/dist/editor.rtl.css +1 -1
- package/dist/homepage-articles/view.asset.php +1 -1
- package/dist/homepage-articles/view.css +1 -1
- package/dist/homepage-articles/view.rtl.css +1 -1
- package/dist/modal.asset.php +1 -1
- package/dist/modal.js +1 -1
- package/includes/class-modal-checkout.php +49 -7
- package/includes/class-newspack-blocks.php +52 -59
- package/languages/newspack-blocks-de_DE.po +1 -1
- package/languages/newspack-blocks-es_ES.po +1 -1
- package/languages/newspack-blocks-fr_BE.po +2 -2
- package/languages/newspack-blocks-pt_PT.po +1 -1
- package/languages/newspack-blocks.pot +1 -1
- package/newspack-blocks.php +4 -4
- package/package.json +3 -3
- package/src/blocks/carousel/edit.js +5 -17
- package/src/blocks/carousel/editor.scss +1 -17
- package/src/blocks/carousel/view.php +20 -79
- package/src/blocks/carousel/view.scss +3 -36
- package/src/blocks/checkout-button/block.json +9 -0
- package/src/blocks/checkout-button/edit.js +45 -0
- package/src/blocks/checkout-button/save.js +23 -0
- package/src/blocks/donate/edit/index.tsx +5 -12
- package/src/blocks/donate/frontend/class-newspack-blocks-donate-renderer-base.php +1 -7
- package/src/blocks/donate/frontend/class-newspack-blocks-donate-renderer-frequency-based.php +1 -1
- package/src/blocks/donate/frontend/class-newspack-blocks-donate-renderer.php +0 -1
- package/src/blocks/donate/streamlined/index.test.js +2 -3
- package/src/blocks/donate/streamlined/index.ts +0 -8
- package/src/blocks/donate/streamlined/utils.ts +0 -1
- package/src/blocks/homepage-articles/block.json +4 -0
- package/src/blocks/homepage-articles/class-wp-rest-newspack-articles-controller.php +0 -28
- package/src/blocks/homepage-articles/edit.js +10 -0
- package/src/blocks/homepage-articles/store.js +22 -4
- package/src/blocks/homepage-articles/templates/article.php +0 -4
- package/src/blocks/homepage-articles/templates/articles-loop.php +1 -2
- package/src/blocks/homepage-articles/utils.ts +1 -0
- package/src/blocks/homepage-articles/view.php +0 -34
- package/src/blocks/homepage-articles/view.scss +0 -23
- package/src/blocks/iframe/view.php +11 -13
- package/src/modal-checkout/modal.js +14 -0
- package/src/modal-checkout/templates/checkout-form.php +8 -0
- package/src/types/index.d.ts +1 -2
- package/vendor/autoload.php +1 -1
- package/vendor/composer/autoload_real.php +4 -4
- package/vendor/composer/autoload_static.php +2 -2
- package/vendor/composer/installed.php +2 -2
- package/.cache/babel/0156e1f0f743cd4a5a4de57f8ccfe0b8.json.gz +0 -0
- package/.cache/babel/02e816c46dd4e4d9a24c9a1b7a59540a.json.gz +0 -0
- package/.cache/babel/06ef11d145e318fb48d3a115527879ce.json.gz +0 -0
- package/.cache/babel/078314f1ffd302d32bbe1124c797c4a8.json.gz +0 -0
- package/.cache/babel/08bd669298cd26a7d3a62aadcf637516.json.gz +0 -0
- package/.cache/babel/0a3c5c9b515d55e6daf9bb1530a33935.json.gz +0 -0
- package/.cache/babel/0ec98f305300249477f0877dcfeab93f.json.gz +0 -0
- package/.cache/babel/0f96392a3b96da0b4dce7a77edef76ca.json.gz +0 -0
- package/.cache/babel/0fced15ed787cc4239bb53c1d12892e6.json.gz +0 -0
- package/.cache/babel/13e57088d8bf09905af8538fcde7339b.json.gz +0 -0
- package/.cache/babel/15387cb771ffa80b113069531d7dbf2a.json.gz +0 -0
- package/.cache/babel/168ca11449f840b88170d992e1c687f9.json.gz +0 -0
- package/.cache/babel/1745993d7e6ba90f0d42d2bd650945a5.json.gz +0 -0
- package/.cache/babel/1a54b89358e5145c6ef0ce9b6f297420.json.gz +0 -0
- package/.cache/babel/1ab4bf44aa14d2eb7e6911900a3b2c12.json.gz +0 -0
- package/.cache/babel/1bc1de530b8e11865e9129484335e271.json.gz +0 -0
- package/.cache/babel/1c9fb1cadc04d30853d52c2b78719398.json.gz +0 -0
- package/.cache/babel/1e3c4531cef0122939eabd5f484f82bd.json.gz +0 -0
- package/.cache/babel/240c25710f01a9ff51938c1864e05565.json.gz +0 -0
- package/.cache/babel/243de511af40dccb789c53e2dbbcf8e2.json.gz +0 -0
- package/.cache/babel/251320ac52752952f12b0509db4847e9.json.gz +0 -0
- package/.cache/babel/264935e7a1393600813a1526a4c51a99.json.gz +0 -0
- package/.cache/babel/26ba0bb46844575022e54a8819fbf405.json.gz +0 -0
- package/.cache/babel/284040ebee104b9acefa5396c3e0e813.json.gz +0 -0
- package/.cache/babel/2dc630cecd79488c7912540ac3a1ae93.json.gz +0 -0
- package/.cache/babel/30cc975abcfadd1df5b5ab14bfef277e.json.gz +0 -0
- package/.cache/babel/317592e8c6159e343d73886ae88e3549.json.gz +0 -0
- package/.cache/babel/31bb32d659e37be6cb488e5db5bdeccb.json.gz +0 -0
- package/.cache/babel/3521a72b024f8525cb016ecb583e9982.json.gz +0 -0
- package/.cache/babel/41a786b05c7e86aa4ee7b0aca2422737.json.gz +0 -0
- package/.cache/babel/43305bd73ad590a21ab00045894c1407.json.gz +0 -0
- package/.cache/babel/469f215eb2ddc25aa138667dd41fb568.json.gz +0 -0
- package/.cache/babel/480d26447b7ee019a37e4e18422403e9.json.gz +0 -0
- package/.cache/babel/48df6fe3b45d872e1ded6f33a70e3176.json.gz +0 -0
- package/.cache/babel/49194e4a0a36c7ed4c0bff0be7fb831c.json.gz +0 -0
- package/.cache/babel/4b3def64c2dc6c4f40e7d35e18d9cda5.json.gz +0 -0
- package/.cache/babel/4b84a19f72461be1f3f8a1363456cb30.json.gz +0 -0
- package/.cache/babel/506a7461434184f7d09f833f61d6bfcf.json.gz +0 -0
- package/.cache/babel/50aaf34aa54b2cd3058518e42850bb62.json.gz +0 -0
- package/.cache/babel/522cbf93af7ec749dde0e2a7dd860c9f.json.gz +0 -0
- package/.cache/babel/53d915d1e8c3e78d33ce618b7e71d9c5.json.gz +0 -0
- package/.cache/babel/56046f06a99a61b7847b604a58062e17.json.gz +0 -0
- package/.cache/babel/5aa5e8d1492938c62999de022c4b220e.json.gz +0 -0
- package/.cache/babel/5cdc287b0f89d83292cb39ed8a26e634.json.gz +0 -0
- package/.cache/babel/6366f9a19fda42ebc6432b2767e76d7b.json.gz +0 -0
- package/.cache/babel/6531721abbc0b3906b28b268ed7914af.json.gz +0 -0
- package/.cache/babel/695780d53e2d31de09fc42456ad05cff.json.gz +0 -0
- package/.cache/babel/6ad227d2c4160c54ee51fdae5d795d99.json.gz +0 -0
- package/.cache/babel/6b835eb676bf657d4405404c13ceec1b.json.gz +0 -0
- package/.cache/babel/6bc5913640b460de4b83482460b5a779.json.gz +0 -0
- package/.cache/babel/6bc92299b6332d48bcc944e155ce08cd.json.gz +0 -0
- package/.cache/babel/6d2559360f2fff9e75ddf057cfe0e2a8.json.gz +0 -0
- package/.cache/babel/6edf79f9da4b488bd4355052d2604c1b.json.gz +0 -0
- package/.cache/babel/6f2e7ac771a37e6fcde789a298b73e70.json.gz +0 -0
- package/.cache/babel/7030a1a5aa29c124ce7c35ac8767ad57.json.gz +0 -0
- package/.cache/babel/764469c94d0f935d0d48d3b8ca9964ff.json.gz +0 -0
- package/.cache/babel/7b683070fec6ffe276629b2e43f832ad.json.gz +0 -0
- package/.cache/babel/82dcac9a920b1401a6e4d9116620ad03.json.gz +0 -0
- package/.cache/babel/845433093cc647521f9ed7aada6399c5.json.gz +0 -0
- package/.cache/babel/867d3b995951f97af45663f52797290b.json.gz +0 -0
- package/.cache/babel/88ec99735ea4f314937736f04360ff8c.json.gz +0 -0
- package/.cache/babel/89043a36a31c7e92c973b2e0ae512e39.json.gz +0 -0
- package/.cache/babel/8959ab8fcfa783cb56e9418b99c0951c.json.gz +0 -0
- package/.cache/babel/8992b31884c946aa1b70f6db4434a9fc.json.gz +0 -0
- package/.cache/babel/8ac84b121ed7e10702015d07c86d96c8.json.gz +0 -0
- package/.cache/babel/8b9624d721f8706682e33fe1853c8287.json.gz +0 -0
- package/.cache/babel/8e6a90b4bc7afb2e6b93ea86efce5a92.json.gz +0 -0
- package/.cache/babel/91cad33175abac6d33f0c20421ec316f.json.gz +0 -0
- package/.cache/babel/9300ec843499931b4743b6f0862a12ad.json.gz +0 -0
- package/.cache/babel/9321b14d86eb18eeecee85b95d36800c.json.gz +0 -0
- package/.cache/babel/95452ca3f0fd5a140f6426306fdec2b4.json.gz +0 -0
- package/.cache/babel/9dd0c10541b1bd54bcc6f7510f7e1730.json.gz +0 -0
- package/.cache/babel/9fa3511f36f06d92dadc26f96928aabb.json.gz +0 -0
- package/.cache/babel/a12f0cc885278887a2b0bbb3871824d6.json.gz +0 -0
- package/.cache/babel/a398d30cfa757f570719e381323da904.json.gz +0 -0
- package/.cache/babel/a656f81700e8f1a93c995190f8138b3b.json.gz +0 -0
- package/.cache/babel/ab39cbb804689d063293f37fa4485487.json.gz +0 -0
- package/.cache/babel/acff6371a410845f5da464cb4e237aaf.json.gz +0 -0
- package/.cache/babel/ad43360146aec3cbcdc4c0df3791d848.json.gz +0 -0
- package/.cache/babel/b25fb66cc6e303883b249f044f991b93.json.gz +0 -0
- package/.cache/babel/b54e20f4b38273a1ede9af6bb4bf20ac.json.gz +0 -0
- package/.cache/babel/bd79e4e680122935b9d5ff39b4b0665b.json.gz +0 -0
- package/.cache/babel/c0d9222366e0ca5cb1687b96ba0ff169.json.gz +0 -0
- package/.cache/babel/c0e75e9017dcf69507da774f93b23422.json.gz +0 -0
- package/.cache/babel/c481eae84d69b65405a44af442dbfea7.json.gz +0 -0
- package/.cache/babel/c7b72847e8266932199eab550d74d4ec.json.gz +0 -0
- package/.cache/babel/cb562dfa06c52220cf31b2d2f3dfe5ed.json.gz +0 -0
- package/.cache/babel/cf4e47aa0d80b97616c031301bcf80dc.json.gz +0 -0
- package/.cache/babel/d1cc4e91603f5c597ff63d85bf7f2ff2.json.gz +0 -0
- package/.cache/babel/d542afdb91386a0759170a6313be13c8.json.gz +0 -0
- package/.cache/babel/d665b07906defb294138edfb6c04e0a1.json.gz +0 -0
- package/.cache/babel/db5215643b0737dc5245972a5c25f736.json.gz +0 -0
- package/.cache/babel/dc94026c61aa370892be7ffaa3c0bdbd.json.gz +0 -0
- package/.cache/babel/df56e5784cf3decfe6c7a459f29e9d5f.json.gz +0 -0
- package/.cache/babel/e064590b2370afea20d7e2fbb313b7c5.json.gz +0 -0
- package/.cache/babel/e0b5ce53743b7a92333dde848fd81f42.json.gz +0 -0
- package/.cache/babel/e1f3cdff6066c3110a7df739f642ddc8.json.gz +0 -0
- package/.cache/babel/e32fb0d04614c50ee701cf3af842887f.json.gz +0 -0
- package/.cache/babel/e499e66d1cc40fb9b6c4238bf3dd2e6a.json.gz +0 -0
- package/.cache/babel/ef23c92e697190265fa2e11c69779b88.json.gz +0 -0
- package/.cache/babel/efc47462720c1d97fe7176407b3c5bca.json.gz +0 -0
- package/.cache/babel/f13abc23689523a1b6b97b9bfdd1aac5.json.gz +0 -0
- package/.cache/babel/f5dc184121cc109a8bc4f20364bd68b5.json.gz +0 -0
- package/.cache/babel/f8e24ac6182e943c6a6cd14ed62ee1b4.json.gz +0 -0
- package/.cache/babel/fac753cac804bb674519703a43aec6aa.json.gz +0 -0
- package/.cache/babel/fe735cbd0f6e131e28d8b6eb1f39141b.json.gz +0 -0
- package/.cache/babel/ff0e41a8b69788632a0b147d4169dc94.json.gz +0 -0
- package/amp/homepage-articles/view.js +0 -87
|
@@ -163,7 +163,6 @@ function newspack_blocks_render_block_homepage_articles( $attributes ) {
|
|
|
163
163
|
),
|
|
164
164
|
[
|
|
165
165
|
'page' => 2,
|
|
166
|
-
'amp' => Newspack_Blocks::is_amp(),
|
|
167
166
|
]
|
|
168
167
|
),
|
|
169
168
|
rest_url( '/newspack-blocks/v1/articles' )
|
|
@@ -191,9 +190,6 @@ function newspack_blocks_render_block_homepage_articles( $attributes ) {
|
|
|
191
190
|
ob_start();
|
|
192
191
|
|
|
193
192
|
if ( $article_query->have_posts() ) : ?>
|
|
194
|
-
<?php if ( $has_more_button && Newspack_Blocks::is_amp() ) : ?>
|
|
195
|
-
<amp-script layout="container" src="<?php echo esc_url( plugins_url( '/newspack-blocks/amp/homepage-articles/view.js' ) ); ?>">
|
|
196
|
-
<?php endif; ?>
|
|
197
193
|
<div
|
|
198
194
|
class="<?php echo esc_attr( $classes ); ?>"
|
|
199
195
|
style="<?php echo esc_attr( $styles ); ?>"
|
|
@@ -238,9 +234,6 @@ function newspack_blocks_render_block_homepage_articles( $attributes ) {
|
|
|
238
234
|
<?php endif; ?>
|
|
239
235
|
|
|
240
236
|
</div>
|
|
241
|
-
<?php if ( $has_more_button && Newspack_Blocks::is_amp() ) : ?>
|
|
242
|
-
</amp-script>
|
|
243
|
-
<?php endif; ?>
|
|
244
237
|
<?php
|
|
245
238
|
endif;
|
|
246
239
|
|
|
@@ -377,30 +370,3 @@ function newspack_blocks_format_categories( $post_id ) {
|
|
|
377
370
|
return apply_filters( 'newspack_blocks_categories', $category_formatted );
|
|
378
371
|
}
|
|
379
372
|
}
|
|
380
|
-
|
|
381
|
-
/**
|
|
382
|
-
* Inject amp-state containing all post IDs visible on page load.
|
|
383
|
-
*/
|
|
384
|
-
function newspack_blocks_inject_amp_state() {
|
|
385
|
-
if ( ! Newspack_Blocks::is_amp() ) {
|
|
386
|
-
return;
|
|
387
|
-
}
|
|
388
|
-
global $newspack_blocks_post_id;
|
|
389
|
-
if ( ! $newspack_blocks_post_id || ! count( $newspack_blocks_post_id ) ) {
|
|
390
|
-
return;
|
|
391
|
-
}
|
|
392
|
-
$post_ids = implode( ', ', array_merge( array_keys( $newspack_blocks_post_id ), [ get_the_ID() ] ) );
|
|
393
|
-
ob_start();
|
|
394
|
-
?>
|
|
395
|
-
<amp-state id='newspackHomepagePosts'>
|
|
396
|
-
<script type="application/json">
|
|
397
|
-
{
|
|
398
|
-
"exclude_ids": [ <?php echo esc_attr( $post_ids ); ?> ]
|
|
399
|
-
}
|
|
400
|
-
</script>
|
|
401
|
-
</amp-state>
|
|
402
|
-
<?php
|
|
403
|
-
echo ob_get_clean(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
|
|
404
|
-
}
|
|
405
|
-
|
|
406
|
-
add_action( 'wp_footer', 'newspack_blocks_inject_amp_state' );
|
|
@@ -455,11 +455,7 @@
|
|
|
455
455
|
margin: 0;
|
|
456
456
|
}
|
|
457
457
|
}
|
|
458
|
-
}
|
|
459
458
|
|
|
460
|
-
/* stylelint-disable selector-type-no-unknown */
|
|
461
|
-
.wpnbha,
|
|
462
|
-
amp-script .wpnbha {
|
|
463
459
|
/* Article meta */
|
|
464
460
|
.cat-links {
|
|
465
461
|
display: flex;
|
|
@@ -507,7 +503,6 @@ amp-script .wpnbha {
|
|
|
507
503
|
line-height: 1;
|
|
508
504
|
}
|
|
509
505
|
}
|
|
510
|
-
/* stylelint-enable */
|
|
511
506
|
|
|
512
507
|
/*
|
|
513
508
|
Some really rough font sizing.
|
|
@@ -830,21 +825,3 @@ amp-script .wpnbha {
|
|
|
830
825
|
font-style: italic;
|
|
831
826
|
}
|
|
832
827
|
}
|
|
833
|
-
|
|
834
|
-
/* Prevent tree-shaking Loading and Error style rules */
|
|
835
|
-
/* stylelint-disable selector-type-no-unknown */
|
|
836
|
-
amp-script .wpnbha.has-more-button.is-loading {
|
|
837
|
-
button {
|
|
838
|
-
display: none;
|
|
839
|
-
}
|
|
840
|
-
.loading {
|
|
841
|
-
display: block;
|
|
842
|
-
}
|
|
843
|
-
}
|
|
844
|
-
amp-script .wpnbha.has-more-button.is-error {
|
|
845
|
-
button,
|
|
846
|
-
.error {
|
|
847
|
-
display: block;
|
|
848
|
-
}
|
|
849
|
-
}
|
|
850
|
-
/* stylelint-enable */
|
|
@@ -111,19 +111,17 @@ function newspack_blocks_get_iframe_html( $mode, $src, $height, $width, $is_full
|
|
|
111
111
|
</div>
|
|
112
112
|
</figure>
|
|
113
113
|
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
</script>
|
|
126
|
-
<?php endif; ?>
|
|
114
|
+
<script>
|
|
115
|
+
const iframe = document.getElementById("<?php echo esc_attr( $iframe_id ); ?>");
|
|
116
|
+
const timerId = setInterval( function() {
|
|
117
|
+
iframe.src = iframe.src;
|
|
118
|
+
}, 2000 );
|
|
119
|
+
|
|
120
|
+
iframe.onload = function() {
|
|
121
|
+
clearInterval(timerId);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
</script>
|
|
127
125
|
|
|
128
126
|
<?php
|
|
129
127
|
return ob_get_clean();
|
|
@@ -105,6 +105,20 @@ domReady( () => {
|
|
|
105
105
|
forms.forEach( form => {
|
|
106
106
|
form.appendChild( modalCheckoutInput.cloneNode() );
|
|
107
107
|
form.target = iframeName;
|
|
108
|
+
|
|
109
|
+
// Fill in the referrer field.
|
|
110
|
+
const afterSuccessUrlInput = form.querySelector( 'input[name="after_success_url"]' );
|
|
111
|
+
const afterSuccessBehaviorInput = form.querySelector(
|
|
112
|
+
'input[name="after_success_behavior"]'
|
|
113
|
+
);
|
|
114
|
+
if (
|
|
115
|
+
afterSuccessBehaviorInput &&
|
|
116
|
+
afterSuccessUrlInput &&
|
|
117
|
+
'referrer' === afterSuccessBehaviorInput.getAttribute( 'value' )
|
|
118
|
+
) {
|
|
119
|
+
afterSuccessUrlInput.setAttribute( 'value', document.referrer || window.location.href );
|
|
120
|
+
}
|
|
121
|
+
|
|
108
122
|
form.addEventListener( 'submit', ev => {
|
|
109
123
|
const formData = new FormData( form );
|
|
110
124
|
// Clear any open variation modal.
|
|
@@ -24,6 +24,10 @@ $form_class = 'checkout woocommerce-checkout';
|
|
|
24
24
|
$form_method = $edit_billing ? 'get' : 'post';
|
|
25
25
|
$form_billing_fields = \Newspack_Blocks\Modal_Checkout::get_prefilled_fields();
|
|
26
26
|
|
|
27
|
+
$after_success_behavior = filter_input( INPUT_GET, 'after_success_behavior', FILTER_SANITIZE_STRING );
|
|
28
|
+
$after_success_url = filter_input( INPUT_GET, 'after_success_url', FILTER_SANITIZE_STRING );
|
|
29
|
+
$after_success_button_label = filter_input( INPUT_GET, 'after_success_button_label', FILTER_SANITIZE_STRING );
|
|
30
|
+
|
|
27
31
|
if ( $edit_billing ) {
|
|
28
32
|
$form_class .= ' edit-billing';
|
|
29
33
|
}
|
|
@@ -70,6 +74,10 @@ if ( ! $checkout->is_registration_enabled() && $checkout->is_registration_requir
|
|
|
70
74
|
<form name="checkout" method="<?php echo esc_attr( $form_method ); ?>" class="<?php echo esc_attr( $form_class ); ?>" action="<?php echo esc_url( $form_action ); ?>" enctype="multipart/form-data">
|
|
71
75
|
|
|
72
76
|
<input type="hidden" name="modal_checkout" value="1" />
|
|
77
|
+
<input type="hidden" name="after_success_behavior" value="<?php echo esc_attr( $after_success_behavior ); ?>" />
|
|
78
|
+
<input type="hidden" name="after_success_url" value="<?php echo esc_attr( $after_success_url ); ?>" />
|
|
79
|
+
<input type="hidden" name="after_success_button_label" value="<?php echo esc_attr( $after_success_button_label ); ?>" />
|
|
80
|
+
|
|
73
81
|
<?php
|
|
74
82
|
if ( $edit_billing ) {
|
|
75
83
|
wp_nonce_field( 'newspack_blocks_edit_billing', 'newspack_blocks_edit_billing_nonce' );
|
package/src/types/index.d.ts
CHANGED
|
@@ -6,7 +6,6 @@ declare global {
|
|
|
6
6
|
newspack_blocks_data: {
|
|
7
7
|
assets_path: string;
|
|
8
8
|
is_rendering_stripe_payment_form?: boolean;
|
|
9
|
-
can_render_tiers_based_layout?: boolean;
|
|
10
9
|
supports_recaptcha: boolean;
|
|
11
10
|
has_recaptcha: boolean;
|
|
12
11
|
recaptcha_url: string;
|
|
@@ -28,7 +27,7 @@ declare global {
|
|
|
28
27
|
type PostId = number;
|
|
29
28
|
type CategoryId = number;
|
|
30
29
|
type TagId = number;
|
|
31
|
-
type Taxonomy = { slug: string
|
|
30
|
+
type Taxonomy = { slug: string; terms: number[] }[];
|
|
32
31
|
type AuthorId = number;
|
|
33
32
|
|
|
34
33
|
type PostType = { name: string; slug: string; supports: { newspack_blocks: boolean } };
|
package/vendor/autoload.php
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
// autoload_real.php @generated by Composer
|
|
4
4
|
|
|
5
|
-
class
|
|
5
|
+
class ComposerAutoloaderInitf52ddb06dc7136613134cfd4647ad1e6
|
|
6
6
|
{
|
|
7
7
|
private static $loader;
|
|
8
8
|
|
|
@@ -22,12 +22,12 @@ class ComposerAutoloaderInitffcc00ed7277b9ae75748a70e6ef8db0
|
|
|
22
22
|
return self::$loader;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
spl_autoload_register(array('
|
|
25
|
+
spl_autoload_register(array('ComposerAutoloaderInitf52ddb06dc7136613134cfd4647ad1e6', 'loadClassLoader'), true, true);
|
|
26
26
|
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
|
27
|
-
spl_autoload_unregister(array('
|
|
27
|
+
spl_autoload_unregister(array('ComposerAutoloaderInitf52ddb06dc7136613134cfd4647ad1e6', 'loadClassLoader'));
|
|
28
28
|
|
|
29
29
|
require __DIR__ . '/autoload_static.php';
|
|
30
|
-
call_user_func(\Composer\Autoload\
|
|
30
|
+
call_user_func(\Composer\Autoload\ComposerStaticInitf52ddb06dc7136613134cfd4647ad1e6::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
|
|
7
|
+
class ComposerStaticInitf52ddb06dc7136613134cfd4647ad1e6
|
|
8
8
|
{
|
|
9
9
|
public static $classMap = array (
|
|
10
10
|
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
|
|
@@ -13,7 +13,7 @@ class ComposerStaticInitffcc00ed7277b9ae75748a70e6ef8db0
|
|
|
13
13
|
public static function getInitializer(ClassLoader $loader)
|
|
14
14
|
{
|
|
15
15
|
return \Closure::bind(function () use ($loader) {
|
|
16
|
-
$loader->classMap =
|
|
16
|
+
$loader->classMap = ComposerStaticInitf52ddb06dc7136613134cfd4647ad1e6::$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' => '
|
|
6
|
+
'reference' => '82cfb05790f13ba1e4515c51ca109e3cf3bc3232',
|
|
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' => '
|
|
16
|
+
'reference' => '82cfb05790f13ba1e4515c51ca109e3cf3bc3232',
|
|
17
17
|
'type' => 'wordpress-plugin',
|
|
18
18
|
'install_path' => __DIR__ . '/../../',
|
|
19
19
|
'aliases' => array(),
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|