WordPress/wp-includes/js/dist/customize-widgets.min.js

7 lines
36 KiB
JavaScript
Raw Normal View History

/*! This file is auto-generated */
Editor: Update block editor packages for WordPress 5.8.1. The following packages were updated: - @wordpress/a11y to `3.1.2` - @wordpress/annotations to `2.1.6` - @wordpress/api-fetch to `5.1.2` - @wordpress/autop to `3.1.2` - @wordpress/babel-preset-default to `6.2.1` - @wordpress/blob to `3.1.2` - @wordpress/block-directory to `2.1.21` - @wordpress/block-editor to `6.1.14` - @wordpress/block-library to `3.2.19` - @wordpress/block-serialization-default-parser to `4.1.2` - @wordpress/blocks to `9.1.8` - @wordpress/components to `14.1.11` - @wordpress/compose to `4.1.6` - @wordpress/core-data to `3.1.12` - @wordpress/customize-widgets to `1.0.20` - @wordpress/data-controls to `2.1.6` - @wordpress/data to `5.1.6` - @wordpress/date to `4.1.2` - @wordpress/deprecated to `3.1.2` - @wordpress/dom-ready to `3.1.2` - @wordpress/dom to `3.1.5` - @wordpress/e2e-test-utils to `5.3.1` - @wordpress/edit-post to `4.1.21` - @wordpress/edit-widgets to `2.1.21` - @wordpress/editor to `10.1.17` - @wordpress/element to `3.1.2` - @wordpress/escape-html to `2.1.2` - @wordpress/format-library to `2.1.14` - @wordpress/html-entities to `3.1.2` - @wordpress/i18n to `4.1.2` - @wordpress/icons to `4.0.3` - @wordpress/interface to `3.1.12` - @wordpress/keyboard-shortcuts to `2.1.7` - @wordpress/keycodes to `3.1.2` - @wordpress/list-reusable-blocks to `2.1.11` - @wordpress/media-utils to `2.1.2` - @wordpress/notices to `3.1.6` - @wordpress/nux to `4.1.11` - @wordpress/plugins to `3.1.6` - @wordpress/primitives to `2.1.2` - @wordpress/priority-queue to `2.1.2` - @wordpress/react-i18n to `2.1.2` - @wordpress/redux-routine to `4.1.2` - @wordpress/reusable-blocks to `2.1.17` - @wordpress/rich-text to `4.1.6` - @wordpress/scripts to `16.1.5` - @wordpress/server-side-render to `2.1.12` - @wordpress/shortcode to `3.1.2` - @wordpress/url to `3.1.2` - @wordpress/viewport to `3.1.6` - @wordpress/warning to `2.1.2` - @wordpress/widgets to `1.1.19` - @wordpress/wordcount to `3.1.2` Props oandregal, juanmaguitar, gziolo, jblz, talldanwp, ribaricplusplus, peterwisoncc, youknowriad, paaljoachim, kreppar, ellatrix, aristath, walbo, ajlende, kevin940726, mamaduka, ntsekouras, toro_unit, mkaz, joen, noisysocks, zieladam, andraganescu, antonvlasenko, terraling, dariak, vladytimy, circlecube, desrosj. Fixes #54052, #52818. Built from https://develop.svn.wordpress.org/trunk@51719 git-svn-id: http://core.svn.wordpress.org/trunk@51325 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-09-01 15:08:24 -04:00
this.wp=this.wp||{},this.wp.customizeWidgets=function(e){var t={};function n(s){if(t[s])return t[s].exports;var r=t[s]={i:s,l:!1,exports:{}};return e[s].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,s){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:s})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var s=Object.create(null);if(n.r(s),Object.defineProperty(s,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(s,r,function(t){return e[t]}.bind(null,r));return s},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="9pbN")}({"1CF3":function(e,t){e.exports=window.wp.dom},"1ZqX":function(e,t){e.exports=window.wp.data},"6aBm":function(e,t){e.exports=window.wp.mediaUtils},"9pbN":function(e,t,n){"use strict";n.r(t),n.d(t,"initialize",(function(){return Te}));var s={};n.r(s),n.d(s,"__unstableIsFeatureActive",(function(){return z})),n.d(s,"isInserterOpened",(function(){return W})),n.d(s,"__experimentalGetInsertionPoint",(function(){return B}));var r={};n.r(r),n.d(r,"__unstableToggleFeature",(function(){return T})),n.d(r,"setIsInserterOpened",(function(){return F}));var i=n("GRId"),c=n("QyPg"),o=n("GLVC"),a=n("HSyU"),l=n("tI+e"),d=n("l3Sj"),u=n("axFQ"),b=n("K9lf");function m({text:e,children:t}){const n=Object(b.useCopyToClipboard)(e);return Object(i.createElement)(l.Button,{variant:"secondary",ref:n},t)}class h extends i.Component{constructor(){super(...arguments),this.state={error:null}}componentDidCatch(e){this.setState({error:e})}render(){const{error:e}=this.state;return e?Object(i.createElement)(u.Warning,{className:"customize-widgets-error-boundary",actions:[Object(i.createElement)(m,{key:"copy-error",text:e.stack},Object(d.__)("Copy Error"))]},Object(d.__)("The editor has encountered an unexpected error.")):this.props.children}}var p=n("YLtl"),g=n("jZUy"),O=n("1ZqX"),j=n("6aBm"),f=n("wx14");var w=function({inspector:e,closeMenu:t,...n}){const s=Object(O.useSelect)(e=>e(u.store).getSelectedBlockClientId(),[]),r=Object(i.useMemo)(()=>document.getElementById("block-"+s),[s]);return Object(i.createElement)(l.MenuItem,Object(f.a)({onClick:()=>{e.open({returnFocusWhenClose:r}),t()}},n),Object(d.__)("Show more settings"))},_=n("TSYQ"),y=n.n(_),v=n("RxS6"),E=n("Ntru"),k=n("K2cm"),C=n("Q4Sy"),x=n("bWcr");const S=Object(p.flow)([O.combineReducers,(I={features:{fixedToolbar:!1,welcomeGuide:!0}},e=>(t=I,n)=>e(t,n))])({features:(e,t)=>"TOGGLE_FEATURE"===t.type?{...e,[t.feature]:!e[t.feature]}:e});var I;function z(e,t){return Object(p.get)(e.preferences.features,[t],!1)}function W(e){return!!e.blockInserterPanel}function B(e){const{rootClientId:t,insertionIndex:n}=e.blockInserterPanel;return{rootClientId:t,insertionIndex:n}}function T(e){return{type:"TOGGLE_FEATURE",feature:e}}function F(e){return{type:"SET_IS_INSERTER_OPENED",value:e}}const M={reducer:Object(O.combineReducers)({blockInserterPanel:function(e=!1,t){switch(t.type){case"SET_IS_INSERTER_OPENED":return t.value}return e},preferences:S}),selectors:s,actions:r,persist:["preferences"]},A=Object(O.createReduxStore)("core/customize-widgets",M);Object(O.registerStore)("core/customize-widgets",M);var N=function e({setIsOpened:t}){const n=Object(b.useInstanceId)(e,"customize-widget-layout__inserter-panel-title"),s=Object(O.useSelect)(e=>e(A).__experimentalGetInsertionPoint());return Object(i.createElement)("div",{className:"customize-widgets-layout__inserter-panel","aria-labelledby":n},Object(i.createElement)("div",{className:"customize-widgets-layout__inserter-panel-header"},Object(i.createElement)("h2",{id:n,className:"customize-widgets-layout__inserter-panel-header-title"},Object(d.__)("Add a block")),Object(i.createElement)(l.Button,{className:"cust
/*!
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
Editor: Update block editor packages for WordPress 5.8.1. The following packages were updated: - @wordpress/a11y to `3.1.2` - @wordpress/annotations to `2.1.6` - @wordpress/api-fetch to `5.1.2` - @wordpress/autop to `3.1.2` - @wordpress/babel-preset-default to `6.2.1` - @wordpress/blob to `3.1.2` - @wordpress/block-directory to `2.1.21` - @wordpress/block-editor to `6.1.14` - @wordpress/block-library to `3.2.19` - @wordpress/block-serialization-default-parser to `4.1.2` - @wordpress/blocks to `9.1.8` - @wordpress/components to `14.1.11` - @wordpress/compose to `4.1.6` - @wordpress/core-data to `3.1.12` - @wordpress/customize-widgets to `1.0.20` - @wordpress/data-controls to `2.1.6` - @wordpress/data to `5.1.6` - @wordpress/date to `4.1.2` - @wordpress/deprecated to `3.1.2` - @wordpress/dom-ready to `3.1.2` - @wordpress/dom to `3.1.5` - @wordpress/e2e-test-utils to `5.3.1` - @wordpress/edit-post to `4.1.21` - @wordpress/edit-widgets to `2.1.21` - @wordpress/editor to `10.1.17` - @wordpress/element to `3.1.2` - @wordpress/escape-html to `2.1.2` - @wordpress/format-library to `2.1.14` - @wordpress/html-entities to `3.1.2` - @wordpress/i18n to `4.1.2` - @wordpress/icons to `4.0.3` - @wordpress/interface to `3.1.12` - @wordpress/keyboard-shortcuts to `2.1.7` - @wordpress/keycodes to `3.1.2` - @wordpress/list-reusable-blocks to `2.1.11` - @wordpress/media-utils to `2.1.2` - @wordpress/notices to `3.1.6` - @wordpress/nux to `4.1.11` - @wordpress/plugins to `3.1.6` - @wordpress/primitives to `2.1.2` - @wordpress/priority-queue to `2.1.2` - @wordpress/react-i18n to `2.1.2` - @wordpress/redux-routine to `4.1.2` - @wordpress/reusable-blocks to `2.1.17` - @wordpress/rich-text to `4.1.6` - @wordpress/scripts to `16.1.5` - @wordpress/server-side-render to `2.1.12` - @wordpress/shortcode to `3.1.2` - @wordpress/url to `3.1.2` - @wordpress/viewport to `3.1.6` - @wordpress/warning to `2.1.2` - @wordpress/widgets to `1.1.19` - @wordpress/wordcount to `3.1.2` Props oandregal, juanmaguitar, gziolo, jblz, talldanwp, ribaricplusplus, peterwisoncc, youknowriad, paaljoachim, kreppar, ellatrix, aristath, walbo, ajlende, kevin940726, mamaduka, ntsekouras, toro_unit, mkaz, joen, noisysocks, zieladam, andraganescu, antonvlasenko, terraling, dariak, vladytimy, circlecube, desrosj. Fixes #54052, #52818. Built from https://develop.svn.wordpress.org/trunk@51719 git-svn-id: http://core.svn.wordpress.org/trunk@51325 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-09-01 15:08:24 -04:00
*/!function(){"use strict";var n={}.hasOwnProperty;function r(){for(var e=[],t=0;t<arguments.length;t++){var s=arguments[t];if(s){var i=typeof s;if("string"===i||"number"===i)e.push(s);else if(Array.isArray(s)){if(s.length){var c=r.apply(null,s);c&&e.push(c)}}else if("object"===i)if(s.toString===Object.prototype.toString)for(var o in s)n.call(s,o)&&s[o]&&e.push(o);else e.push(s.toString())}}return e.join(" ")}e.exports?(r.default=r,e.exports=r):void 0===(s=function(){return r}.apply(t,[]))||(e.exports=s)}()},Tqx9:function(e,t){e.exports=window.wp.primitives},VKE3:function(e,t,n){"use strict";var s=n("GRId"),r=n("Tqx9");const i=Object(s.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(s.createElement)(r.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));t.a=i},YLtl:function(e,t){e.exports=window.lodash},axFQ:function(e,t){e.exports=window.wp.blockEditor},bWcr:function(e,t,n){"use strict";var s=n("GRId"),r=n("Tqx9");const i=Object(s.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(s.createElement)(r.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"}));t.a=i},g56x:function(e,t){e.exports=window.wp.hooks},gdqT:function(e,t){e.exports=window.wp.a11y},hF7m:function(e,t){e.exports=window.wp.keyboardShortcuts},jZUy:function(e,t){e.exports=window.wp.coreData},l3Sj:function(e,t){e.exports=window.wp.i18n},rl8x:function(e,t){e.exports=window.wp.isShallowEqual},"tI+e":function(e,t){e.exports=window.wp.components},wx14:function(e,t,n){"use strict";function s(){return(s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(e[s]=n[s])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return s}))}});