@automattic/newspack-blocks 4.3.2 → 4.3.3
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/CHANGELOG.md +7 -0
- package/dist/editor.asset.php +1 -1
- package/dist/editor.js +1 -1
- package/includes/class-newspack-blocks.php +0 -25
- package/newspack-blocks.php +2 -2
- package/package.json +1 -1
- package/src/blocks/video-playlist/editor.js +1 -3
- package/src/blocks/video-playlist/view.php +0 -4
- 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/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,10 @@
|
|
|
1
|
+
## [4.3.3](https://github.com/Automattic/newspack-blocks/compare/v4.3.2...v4.3.3) (2024-10-29)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* remove expensive query before registering video playlist block ([#1930](https://github.com/Automattic/newspack-blocks/issues/1930)) ([9d967e0](https://github.com/Automattic/newspack-blocks/commit/9d967e0e415ca78018540c2c033c06fd2fe64fab))
|
|
7
|
+
|
|
1
8
|
## [4.3.2](https://github.com/Automattic/newspack-blocks/compare/v4.3.1...v4.3.2) (2024-10-29)
|
|
2
9
|
|
|
3
10
|
|
package/dist/editor.asset.php
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'react-jsx-runtime', 'wp-a11y', 'wp-api-fetch', 'wp-autop', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-data', 'wp-date', 'wp-dom-ready', 'wp-element', 'wp-escape-html', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-url'), 'version' => '
|
|
1
|
+
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'react-jsx-runtime', 'wp-a11y', 'wp-api-fetch', 'wp-autop', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-data', 'wp-date', 'wp-dom-ready', 'wp-element', 'wp-escape-html', 'wp-hooks', 'wp-html-entities', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-url'), 'version' => '08a415b79429ba3f35e9');
|
package/dist/editor.js
CHANGED
|
@@ -41,4 +41,4 @@
|
|
|
41
41
|
(0,r.__)("Upload a document file (PDF, Word, Excel sheet, or a PPT), choose one from the media library, %s.","newspack-blocks"),newspack_blocks_data?.iframe_can_upload_archives?(0,r.__)("embed from a URL, or upload a .zip archive containing HTML assets","newspack-blocks"):(0,r.__)("or embed from a URL","newspack-blocks")),children:[g&&(0,u.jsx)(t.Notice,{status:"error",className:"wp-block-newspack-blocks-iframe-notice",isDismissible:!1,children:g}),(0,u.jsx)("div",{children:c?(0,u.jsx)(t.Spinner,{}):(0,u.jsx)(t.FormFileUpload,{accept:Object.keys(f).map((e=>"."+f[e])).join(","),onChange:e=>{const t=e.target.files;0<t.length&&p(t.item(0))},multiple:!1,render:({openFileDialog:e})=>{return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(t.Button,{isPrimary:!0,className:h()("wp-block-newspack-blocks-iframe__button","wp-block-newspack-blocks-iframe__upload-button"),onClick:e,children:d?(0,r.__)("Update","newspack-blocks"):(0,r.__)("Upload","newspack-blocks")}),(s=E,(0,u.jsx)(a.MediaUploadCheck,{children:(0,u.jsx)(a.MediaUpload,{onSelect:s,allowedTypes:Object.keys(f),render:({open:e})=>(0,u.jsx)(t.Button,{variant:"tertiary",onClick:e,children:(0,r.__)("Media Library","newspack-blocks")})})})),(n=""!==d,o&&(0,u.jsxs)("div",{className:"wp-block-newspack-blocks-iframe__url-input-container",children:[(0,u.jsx)(t.Button,{isTertiary:!0,onClick:x,isPressed:v,variant:"tertiary",children:n?(0,r.__)("Update from URL","newspack-blocks"):(0,r.__)("Embed from URL","newspack-blocks")}),v&&(0,u.jsx)(m,{src:w,onChange:_,onSubmit:S,onClose:k})]}))]});var n,s}})})]})},v=(0,u.jsx)(t.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,u.jsx)(t.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V9.8l4.7-5.3H19c.3 0 .5.2.5.5v14zm-6-9.5L16 12l-2.5 2.8 1.1 1L18 12l-3.5-3.5-1 1zm-3 0l-1-1L6 12l3.5 3.8 1.1-1L8 12l2.5-2.5z"})}),b=(0,u.jsxs)(t.SVG,{xmlns:"http://www.w3.org/2000/svg",height:"24",viewBox:"0 0 24 24",width:"24",children:[(0,u.jsx)(t.Path,{d:"M12 18.8c-4.8 0-8.5-6.1-8.6-6.4l-.3-.4.2-.4c.2-.3 3.9-6.4 8.6-6.4 4.7 0 8.5 6.1 8.6 6.4l.2.4-.2.4c0 .2-3.7 6.4-8.5 6.4zM4.9 12c.9 1.3 3.8 5.2 7.1 5.2s6.3-4 7.1-5.2c-.9-1.3-3.8-5.3-7.1-5.3-3.3.1-6.3 4-7.1 5.3z"}),(0,u.jsx)(t.Path,{d:"M15 11.2c-.3.5-.8.8-1.4.8-.9 0-1.6-.7-1.6-1.6 0-.5.3-1 .7-1.3-.2 0-.5-.1-.7-.1-1.7 0-3.2 1.4-3.2 3.2s1.4 3.2 3.2 3.2c1.7 0 3.2-1.4 3.2-3.2 0-.3-.1-.7-.2-1z"})]}),w=JSON.parse('{"UU":"iframe","L1":"newspack","uK":{"className":{"type":"string","default":""},"src":{"type":"string","default":""},"archiveFolder":{"type":"string","default":""},"height":{"type":"string","default":"600px"},"width":{"type":"string","default":"100%"},"isFullScreen":{"type":"boolean","default":false},"mode":{"type":"string","default":"iframe"}}}'),{UU:y,uK:_,L1:x}=w,k={title:(0,r.__)("Iframe","newspack-blocks"),icon:{src:v,foreground:"#36f"},category:x,keywords:[(0,r.__)("iframe","newspack-blocks"),(0,r.__)("project iframe","newspack-blocks")],description:(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)("p",{children:(0,r.__)("Embed an iframe.","newspack-blocks")}),(0,u.jsx)(t.ExternalLink,{href:"https://help.newspack.com/publishing-and-appearance/blocks/iframe-block/",children:(0,r.__)("Support reference","newspack-blocks")})]}),attributes:_,supports:{html:!1,align:["wide","full"]},edit:({attributes:e,setAttributes:n})=>{const o=(0,r.__)("Iframe","block title"),{mode:c,src:d,archiveFolder:p,isFullScreen:h,height:f,width:m}=e,[w,y]=(0,s.useState)(!0),[_,x]=(0,s.useState)(),[k,S]=(0,s.useState)(),E=[{value:"px",label:"px"},{value:"%",label:"%"},{value:"em",label:"em"}],j=[{icon:(0,u.jsx)(i.A,{icon:b}),title:w?(0,r.__)("Hide iframe preview","newspack-blocks"):(0,r.__)("Show iframe preview","newspack-blocks"),onClick:()=>y(!w),isActive:w}];return(0,u.jsxs)(s.Fragment,{children:[h&&(0,u.jsx)(t.Notice,{status:"warning",className:"wp-block-newspack-blocks-iframe-notice",isDismissible:!1,children:(0,r.__)("This block will take over the page content.","newspack-blocks")}),d&&w?(0,u.jsx)("div",{className:"iframe-container",children:(0,u.jsx)(t.FocusableIframe,{title:(0,r.__)("Newspack embedded iframe","newspack-blocks"),src:"document"===c?`https://docs.google.com/gview?embedded=true&url=${encodeURIComponent(d)}`:d,style:{width:h?"100vw":m,height:h?"100vh":f,maxWidth:"100%",maxHeight:"100%",pointerEvents:"none"}})}):(0,u.jsx)(g,{icon:v,label:o,src:d,onSelectURL:async e=>{S(null),x(!0);try{const t=new FormData;t.append("iframe_url",e);const{mode:r}=await l()({path:"/newspack-blocks/v1/newspack-blocks-iframe-mode-from-url",method:"POST",body:t});n({mode:r,src:e}),y(!0),p&&d&&p&&!d.includes(p)&&l()({path:"/newspack-blocks/v1/newspack-blocks-remove-iframe-archive",method:"DELETE",body:JSON.stringify({archive_folder:p})})}catch(e){S(e.message||(0,r.__)("An error occured when uploading the iframe archive.","newspack-blocks"))}x(!1)},onSelectMedia:async e=>{S(null),x(!0);try{const t=new FormData;t.append("media_id",e);const{src:r,dir:s,mode:a}=await l()({path:"/newspack-blocks/v1/newspack-blocks-iframe-archive-from-media",method:"POST",body:t});n({mode:a,src:r,archiveFolder:s}),y(!0)}catch(e){S(e.message||(0,r.__)("An error occured when setting the iframe from the archive media.","newspack-blocks"))}x(!1)},isUploadingArchive:_,archiveFolder:p,uploadIframeArchive:async e=>{S(null),x(!0);try{const t=new FormData;t.append("archive_folder",p),t.append("iframe_file",e);const{src:r,dir:s,mode:a}=await l()({path:"/newspack-blocks/v1/newspack-blocks-iframe-archive",method:"POST",body:t});n({mode:a,src:r,archiveFolder:s}),y(!0)}catch(e){S(e.message||(0,r.__)("An error occured when uploading the iframe archive.","newspack-blocks"))}x(!1)},error:k}),(0,u.jsx)(a.BlockControls,{children:(0,u.jsx)(t.Toolbar,{controls:d&&j})}),(0,u.jsx)(a.InspectorControls,{children:(0,u.jsx)(t.PanelBody,{title:(0,r.__)("Iframe Settings","newspack-blocks"),initialOpen:!0,children:(0,u.jsxs)(s.Fragment,{children:[(0,u.jsx)(t.ToggleControl,{label:(0,r.__)("Fullscreen","newspack-blocks"),help:(0,r.__)("If enabled, the iframe will be full screen and hide all the post content.","newspack-blocks"),checked:h,onChange:e=>n({isFullScreen:e}),required:!0}),!h&&(0,u.jsxs)("div",{className:"wp-block-newspack-blocks-iframe__unit-control",children:[(0,u.jsx)(t.__experimentalUnitControl,{label:(0,r.__)("Width","newspack-blocks"),onChange:e=>n({width:e}),value:m,units:E}),(0,u.jsx)(t.__experimentalUnitControl,{label:(0,r.__)("Height","newspack-blocks"),onChange:e=>n({height:e}),value:f,units:E})]})]})})})]})},save:()=>null};(0,e.registerBlockType)(`newspack-blocks/${y}`,k)})(),(()=>{"use strict";var e=n(4997),t=n(6427),r=n(7723),s=n(1455),a=n.n(s),i=n(6087),o=n(4715),l=n(3832),c=n(8537),u=n(790);class d extends i.Component{constructor(e){super(e),this.state={isLoading:!1,error:"",embed:"",interactive:!1}}componentDidMount(){this.refreshPreview()}componentDidUpdate(e){const{attributes:t}=this.props,{categories:n,videosToShow:r}=t,{attributes:s}=e,{categories:a,videosToShow:i}=s;n===a&&r===i||this.refreshPreview()}static getDerivedStateFromProps(e,t){return!e.isSelected&&t.interactive?{interactive:!1}:null}refreshPreview(){const{attributes:e}=this.props,{categories:t,videosToShow:n}=e,r=(0,l.addQueryArgs)("/newspack-blocks/v1/video-playlist",{categories:t,videosToShow:n});this.setState({isLoading:!0},(()=>{a()({path:r}).then((e=>{const{html:t}=e;this.setState({embed:t,isLoading:!1})})).catch((e=>{this.setState({isLoading:!1,error:e.message})}))}))}renderPlaceholder(){const{isLoading:e,error:n,embed:s}=this.state;return e?(0,u.jsx)(t.Placeholder,{icon:(0,u.jsx)(t.Spinner,{}),className:"component-placeholder__align-center"}):n.length?(0,u.jsx)(t.Placeholder,{icon:"warning",label:(0,r.__)("Error","newspack-blocks"),instructions:n}):s.length?null:(0,u.jsx)(t.Placeholder,{icon:"warning",label:(0,r.__)("Error","newspack-blocks"),instructions:(0,r.__)("No videos found","newspack-blocks")})}fetchCategorySuggestions=e=>a()({path:(0,l.addQueryArgs)("/wp/v2/categories",{search:e,per_page:20,_fields:"id,name",orderby:"count",order:"desc"})}).then((function(e){return e.map((e=>({value:e.id,label:(0,c.decodeEntities)(e.name)||(0,r.__)("(no title)","newspack-blocks")})))}));fetchSavedCategories=e=>a()({path:(0,l.addQueryArgs)("/wp/v2/categories",{per_page:100,_fields:"id,name",include:e.join(",")})}).then((function(e){return e.map((e=>({value:e.id,label:(0,c.decodeEntities)(e.name)||(0,r.__)("(no title)","newspack-blocks")})))}));render(){const{embed:e,isLoading:n}=this.state,s=()=>(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)("h2",{children:(0,r.__)("The YouTube Video Playlist block is deprecated","newspack-plugin")}),(0,u.jsx)("p",{dangerouslySetInnerHTML:{__html:(0,r.sprintf)(
|
|
42
42
|
// translators: %1$s is the link to Google's help doc on creating YouTube playlists. %2$s is the link to the help doc on embedding playlists.
|
|
43
43
|
// translators: %1$s is the link to Google's help doc on creating YouTube playlists. %2$s is the link to the help doc on embedding playlists.
|
|
44
|
-
(0,r.__)('Consider using <a href="%1$s">YouTube Playlists</a> instead, which can be <a href="%2$s">embedded</a> into post or page content.',"newspack-blocks"),"https://support.google.com/youtube/answer/57792","https://support.google.com/youtube/answer/171780")}})]});return(0,u.jsxs)(i.Fragment,{children:[(0,u.jsxs)("div",{children:[(n||""===e)&&this.renderPlaceholder(),!(n||""===e)&&(0,u.jsx)("div",{className:"wpbnbvp-preview",children:(0,u.jsx)("div",{dangerouslySetInnerHTML:{__html:e}})}),!n&&(0,u.jsx)("div",{className:"wpbnbvp__overlay",children:(0,u.jsx)(s,{})})]}),(0,u.jsx)(o.InspectorControls,{children:(0,u.jsx)(t.PanelBody,{title:(0,r.__)("Settings","newspack-blocks"),initialOpen:!0,children:(0,u.jsx)(t.Notice,{status:"warning",isDismissible:!1,children:(0,u.jsx)(s,{})})})})]})}}const p=d,h={title:(0,r.__)("YouTube Video Playlist (DEPRECATED)","newspack-blocks"),icon:{src:(0,u.jsxs)(t.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[(0,u.jsx)(t.Path,{d:"M13 10.5L8.833 8v5z"}),(0,u.jsx)(t.Path,{clipRule:"evenodd",d:"M4.625 3C3.728 3 3 3.728 3 4.625v11.75C3 17.272 3.728 18 4.625 18h11.75c.897 0 1.625-.728 1.625-1.625V4.625C18 3.728 17.272 3 16.375 3zm11.75 1.5H4.625a.125.125 0 00-.125.125v11.75c0 .069.056.125.125.125h11.75a.125.125 0 00.125-.125V4.625a.125.125 0 00-.125-.125z",fillRule:"evenodd"}),(0,u.jsx)(t.Path,{d:"M20.25 8v11c0 .69-.56 1.25-1.249 1.25H6v1.5h13.001A2.749 2.749 0 0021.75 19V8z"})]}),foreground:"#36f"},category:"newspack",keywords:[(0,r.__)("video","newspack-blocks"),(0,r.__)("playlist","newspack-blocks"),(0,r.__)("youtube","newspack-blocks")],description:(0,r.__)("Embed a playlist of latest YouTube videos.","newspack-blocks"),attributes:{className:{type:"string"},categories:{type:"array",default:[]},videosToShow:{type:"integer",default:5}},supports:{html:!1,align:!0},edit:p,save:()=>null};
|
|
44
|
+
(0,r.__)('Consider using <a href="%1$s">YouTube Playlists</a> instead, which can be <a href="%2$s">embedded</a> into post or page content.',"newspack-blocks"),"https://support.google.com/youtube/answer/57792","https://support.google.com/youtube/answer/171780")}})]});return(0,u.jsxs)(i.Fragment,{children:[(0,u.jsxs)("div",{children:[(n||""===e)&&this.renderPlaceholder(),!(n||""===e)&&(0,u.jsx)("div",{className:"wpbnbvp-preview",children:(0,u.jsx)("div",{dangerouslySetInnerHTML:{__html:e}})}),!n&&(0,u.jsx)("div",{className:"wpbnbvp__overlay",children:(0,u.jsx)(s,{})})]}),(0,u.jsx)(o.InspectorControls,{children:(0,u.jsx)(t.PanelBody,{title:(0,r.__)("Settings","newspack-blocks"),initialOpen:!0,children:(0,u.jsx)(t.Notice,{status:"warning",isDismissible:!1,children:(0,u.jsx)(s,{})})})})]})}}const p=d,h={title:(0,r.__)("YouTube Video Playlist (DEPRECATED)","newspack-blocks"),icon:{src:(0,u.jsxs)(t.SVG,{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[(0,u.jsx)(t.Path,{d:"M13 10.5L8.833 8v5z"}),(0,u.jsx)(t.Path,{clipRule:"evenodd",d:"M4.625 3C3.728 3 3 3.728 3 4.625v11.75C3 17.272 3.728 18 4.625 18h11.75c.897 0 1.625-.728 1.625-1.625V4.625C18 3.728 17.272 3 16.375 3zm11.75 1.5H4.625a.125.125 0 00-.125.125v11.75c0 .069.056.125.125.125h11.75a.125.125 0 00.125-.125V4.625a.125.125 0 00-.125-.125z",fillRule:"evenodd"}),(0,u.jsx)(t.Path,{d:"M20.25 8v11c0 .69-.56 1.25-1.249 1.25H6v1.5h13.001A2.749 2.749 0 0021.75 19V8z"})]}),foreground:"#36f"},category:"newspack",keywords:[(0,r.__)("video","newspack-blocks"),(0,r.__)("playlist","newspack-blocks"),(0,r.__)("youtube","newspack-blocks")],description:(0,r.__)("Embed a playlist of latest YouTube videos.","newspack-blocks"),attributes:{className:{type:"string"},categories:{type:"array",default:[]},videosToShow:{type:"integer",default:5}},supports:{html:!1,align:!0},edit:p,save:()=>null};(0,e.registerBlockType)("newspack-blocks/youtube-video-playlist",h)})()})();
|
|
@@ -241,7 +241,6 @@ class Newspack_Blocks {
|
|
|
241
241
|
'custom_taxonomies' => self::get_custom_taxonomies(),
|
|
242
242
|
'can_use_name_your_price' => self::can_use_name_your_price(),
|
|
243
243
|
'tier_amounts_template' => self::get_formatted_amount(),
|
|
244
|
-
'can_use_video_playlist' => self::can_use_video_playlist_block(),
|
|
245
244
|
];
|
|
246
245
|
|
|
247
246
|
if ( class_exists( 'WP_REST_Newspack_Author_List_Controller' ) ) {
|
|
@@ -1644,29 +1643,5 @@ class Newspack_Blocks {
|
|
|
1644
1643
|
|
|
1645
1644
|
return $combined_caption;
|
|
1646
1645
|
}
|
|
1647
|
-
|
|
1648
|
-
/**
|
|
1649
|
-
* Check if the current site can use the Video Playlist block.
|
|
1650
|
-
* If the block doesn't already exist in site content, it won't be registered.
|
|
1651
|
-
*/
|
|
1652
|
-
public static function can_use_video_playlist_block() {
|
|
1653
|
-
// Check if the block exists in any content on the site.
|
|
1654
|
-
$existing_blocks = new WP_Query(
|
|
1655
|
-
[
|
|
1656
|
-
'fields' => 'ids',
|
|
1657
|
-
'post_type' => 'any',
|
|
1658
|
-
'post_status' => 'publish',
|
|
1659
|
-
's' => 'newspack-blocks/youtube-video-playlist',
|
|
1660
|
-
'posts_per_page' => 1,
|
|
1661
|
-
]
|
|
1662
|
-
);
|
|
1663
|
-
|
|
1664
|
-
// Don't register the block if it's not already on the site.
|
|
1665
|
-
if ( 0 < $existing_blocks->found_posts ) {
|
|
1666
|
-
return true;
|
|
1667
|
-
}
|
|
1668
|
-
|
|
1669
|
-
return false;
|
|
1670
|
-
}
|
|
1671
1646
|
}
|
|
1672
1647
|
Newspack_Blocks::init();
|
package/newspack-blocks.php
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* Author URI: https://newspack.com/
|
|
8
8
|
* Text Domain: newspack-blocks
|
|
9
9
|
* Domain Path: /languages
|
|
10
|
-
* Version: 4.3.
|
|
10
|
+
* Version: 4.3.3
|
|
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', '4.3.
|
|
18
|
+
define( 'NEWSPACK_BLOCKS__VERSION', '4.3.3' );
|
|
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
|
@@ -4,6 +4,4 @@
|
|
|
4
4
|
import { registerBlockType } from '@wordpress/blocks';
|
|
5
5
|
import { name, settings } from '.';
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
registerBlockType( `newspack-blocks/${ name }`, settings );
|
|
9
|
-
}
|
|
7
|
+
registerBlockType( `newspack-blocks/${ name }`, settings );
|
|
@@ -23,10 +23,6 @@ function newspack_blocks_render_block_video_playlist( $attributes ) {
|
|
|
23
23
|
* Registers the `newspack-blocks/donate` block on server.
|
|
24
24
|
*/
|
|
25
25
|
function newspack_blocks_register_video_playlist() {
|
|
26
|
-
if ( ! Newspack_Blocks::can_use_video_playlist_block() ) {
|
|
27
|
-
return;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
26
|
register_block_type(
|
|
31
27
|
'newspack-blocks/youtube-video-playlist',
|
|
32
28
|
array(
|
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 ComposerAutoloaderInit10b95eb0a8e5aea462548a9f531a3d39
|
|
6
6
|
{
|
|
7
7
|
private static $loader;
|
|
8
8
|
|
|
@@ -22,12 +22,12 @@ class ComposerAutoloaderInit35c3a51d6927e3d9cc4006b63ff43f08
|
|
|
22
22
|
return self::$loader;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
spl_autoload_register(array('
|
|
25
|
+
spl_autoload_register(array('ComposerAutoloaderInit10b95eb0a8e5aea462548a9f531a3d39', 'loadClassLoader'), true, true);
|
|
26
26
|
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
|
27
|
-
spl_autoload_unregister(array('
|
|
27
|
+
spl_autoload_unregister(array('ComposerAutoloaderInit10b95eb0a8e5aea462548a9f531a3d39', 'loadClassLoader'));
|
|
28
28
|
|
|
29
29
|
require __DIR__ . '/autoload_static.php';
|
|
30
|
-
call_user_func(\Composer\Autoload\
|
|
30
|
+
call_user_func(\Composer\Autoload\ComposerStaticInit10b95eb0a8e5aea462548a9f531a3d39::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 ComposerStaticInit10b95eb0a8e5aea462548a9f531a3d39
|
|
8
8
|
{
|
|
9
9
|
public static $classMap = array (
|
|
10
10
|
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
|
|
@@ -13,7 +13,7 @@ class ComposerStaticInit35c3a51d6927e3d9cc4006b63ff43f08
|
|
|
13
13
|
public static function getInitializer(ClassLoader $loader)
|
|
14
14
|
{
|
|
15
15
|
return \Closure::bind(function () use ($loader) {
|
|
16
|
-
$loader->classMap =
|
|
16
|
+
$loader->classMap = ComposerStaticInit10b95eb0a8e5aea462548a9f531a3d39::$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-trunk',
|
|
5
5
|
'version' => 'dev-trunk',
|
|
6
|
-
'reference' => '
|
|
6
|
+
'reference' => '9d967e0e415ca78018540c2c033c06fd2fe64fab',
|
|
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-trunk',
|
|
15
15
|
'version' => 'dev-trunk',
|
|
16
|
-
'reference' => '
|
|
16
|
+
'reference' => '9d967e0e415ca78018540c2c033c06fd2fe64fab',
|
|
17
17
|
'type' => 'wordpress-plugin',
|
|
18
18
|
'install_path' => __DIR__ . '/../../',
|
|
19
19
|
'aliases' => array(),
|