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

7 lines
61 KiB
JavaScript
Raw Normal View History

/*! This file is auto-generated */
this.wp=this.wp||{},this.wp.editWidgets=function(e){var t={};function r(n){if(t[n])return t[n].exports;var c=t[n]={i:n,l:!1,exports:{}};return e[n].call(c.exports,c,c.exports,r),c.l=!0,c.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var c in e)r.d(n,c,function(t){return e[t]}.bind(null,c));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s="F35A")}({"//Lo":function(e,t,r){"use strict";var n=r("GRId"),c=r("Tqx9");const i=Object(n.createElement)(c.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(n.createElement)(c.Path,{d:"M19 8h-1V6h-5v2h-2V6H6v2H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8c0-1.1-.9-2-2-2zm.5 10c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-8c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v8z"}));t.a=i},"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},Cg8A:function(e,t,r){"use strict";var n=r("GRId"),c=r("Tqx9");const i=Object(n.createElement)(c.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(n.createElement)(c.Path,{fillRule:"evenodd",d:"M10.289 4.836A1 1 0 0111.275 4h1.306a1 1 0 01.987.836l.244 1.466c.787.26 1.503.679 2.108 1.218l1.393-.522a1 1 0 011.216.437l.653 1.13a1 1 0 01-.23 1.273l-1.148.944a6.025 6.025 0 010 2.435l1.149.946a1 1 0 01.23 1.272l-.653 1.13a1 1 0 01-1.216.437l-1.394-.522c-.605.54-1.32.958-2.108 1.218l-.244 1.466a1 1 0 01-.987.836h-1.306a1 1 0 01-.986-.836l-.244-1.466a5.995 5.995 0 01-2.108-1.218l-1.394.522a1 1 0 01-1.217-.436l-.653-1.131a1 1 0 01.23-1.272l1.149-.946a6.026 6.026 0 010-2.435l-1.148-.944a1 1 0 01-.23-1.272l.653-1.131a1 1 0 011.217-.437l1.393.522a5.994 5.994 0 012.108-1.218l.244-1.466zM14.929 12a3 3 0 11-6 0 3 3 0 016 0z",clipRule:"evenodd"}));t.a=i},F35A:function(e,t,r){"use strict";r.r(t),r.d(t,"reinitializeEditor",(function(){return bt})),r.d(t,"initialize",(function(){return mt}));var n={};r.r(n),r.d(n,"persistStubPost",(function(){return k})),r.d(n,"saveEditedWidgetAreas",(function(){return S})),r.d(n,"saveWidgetAreas",(function(){return I})),r.d(n,"saveWidgetArea",(function(){return A})),r.d(n,"setWidgetIdForClientId",(function(){return T})),r.d(n,"setWidgetAreasOpenState",(function(){return B})),r.d(n,"setIsWidgetAreaOpen",(function(){return N})),r.d(n,"setIsInserterOpened",(function(){return C})),r.d(n,"setIsListViewOpened",(function(){return L})),r.d(n,"closeGeneralSidebar",(function(){return W})),r.d(n,"moveBlockToWidgetArea",(function(){return R}));var c={};r.r(c),r.d(c,"getWidgetAreas",(function(){return P})),r.d(c,"getWidgets",(function(){return F}));var i={};r.r(i),r.d(i,"getWidgets",(function(){return D})),r.d(i,"getWidget",(function(){return V})),r.d(i,"getWidgetAreas",(function(){return G})),r.d(i,"getWidgetAreaForWidgetId",(function(){return U})),r.d(i,"getParentWidgetAreaBlock",(function(){return z})),r.d(i,"getEditedWidgetAreas",(function(){return H})),r.d(i,"getReferenceWidgetBlocks",(function(){return q})),r.d(i,"isSavingWidgetAreas",(function(){return K})),r.d(i,"getIsWidgetAreaOpen",(function(){return Y})),r.d(i,"isInserterOpened",(function(){return Q})),r.d(i,"__experimentalGetInsertionPoint",(function(){return X})),r.d(i,"canInsertBlockInWidgetArea",(function(){return Z})),r.d(i,"isListViewOpened",(function(){return $}));var a={};r.r(a),r.d(a,"metadata",(function(){return ue})),r.d(a,"name",(function(){return be})),r.d(a,"settings",(function(){return me}));var o=r("GRId"),s=r("HSyU"),l=r("1ZqX"),d=r("QyPg"),u=r("jZUy"),b=r("GLVC
/*!
Copyright (c) 2018 Jed Watson.
Licensed under the MIT License (MIT), see
http://jedwatson.github.io/classnames
*/!function(){"use strict";var r={}.hasOwnProperty;function c(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var i=typeof n;if("string"===i||"number"===i)e.push(n);else if(Array.isArray(n)){if(n.length){var a=c.apply(null,n);a&&e.push(a)}}else if("object"===i)if(n.toString===Object.prototype.toString)for(var o in n)r.call(n,o)&&n[o]&&e.push(o);else e.push(n.toString())}}return e.join(" ")}e.exports?(c.default=c,e.exports=c):void 0===(n=function(){return c}.apply(t,[]))||(e.exports=n)}()},Tqx9:function(e,t){e.exports=window.wp.primitives},TvNi:function(e,t){e.exports=window.wp.plugins},U60i:function(e,t,r){"use strict";r.d(t,"b",(function(){return K})),r.d(t,"c",(function(){return G})),r.d(t,"d",(function(){return Y})),r.d(t,"e",(function(){return X})),r.d(t,"h",(function(){return z})),r.d(t,"f",(function(){return $})),r.d(t,"g",(function(){return ee})),r.d(t,"a",(function(){return D})),r.d(t,"i",(function(){return L}));var n={};r.r(n),r.d(n,"enableComplementaryArea",(function(){return v})),r.d(n,"disableComplementaryArea",(function(){return y})),r.d(n,"pinItem",(function(){return S})),r.d(n,"unpinItem",(function(){return I})),r.d(n,"toggleFeature",(function(){return A})),r.d(n,"setFeatureValue",(function(){return x})),r.d(n,"setFeatureDefaults",(function(){return T}));var c={};r.r(c),r.d(c,"getActiveComplementaryArea",(function(){return B})),r.d(c,"isItemPinned",(function(){return N})),r.d(c,"isFeatureActive",(function(){return C}));var i=r("wx14"),a=r("GRId"),o=r("TSYQ"),s=r.n(o),l=r("tI+e"),d=r("1ZqX"),u=r("l3Sj"),b=r("RMJe"),m=r("URob"),g=r("Xxwi"),p=r("KEfo"),O=r("bWcr"),j=r("YLtl");const f=Object(d.combineReducers)({features(e={},t){if("SET_FEATURE_DEFAULTS"===t.type){const{scope:r,defaults:n}=t;return{...e,[r]:{...e[r],...n}}}return e}}),_=Object(d.combineReducers)({features(e={},t){if("SET_FEATURE_VALUE"===t.type){const{scope:r,featureName:n,value:c}=t;return{...e,[r]:{...e[r],[n]:c}}}return e}}),w=Object(d.combineReducers)({singleEnableItems:function(e={},{type:t,itemType:r,scope:n,item:c}){return"SET_SINGLE_ENABLE_ITEM"===t&&r&&n?{...e,[r]:{...e[r],[n]:c||null}}:e},multipleEnableItems:function(e={},{type:t,itemType:r,scope:n,item:c,isEnable:i}){if("SET_MULTIPLE_ENABLE_ITEM"!==t||!r||!n||!c||Object(j.get)(e,[r,n,c])===i)return e;const a=e[r]||{},o=a[n]||{};return{...e,[r]:{...a,[n]:{...o,[c]:i||!1}}}}});var h=Object(d.combineReducers)({enableItems:w,preferenceDefaults:f,preferences:_});function E(e,t,r){return{type:"SET_SINGLE_ENABLE_ITEM",itemType:e,scope:t,item:r}}function v(e,t){return E("complementaryArea",e,t)}function y(e){return E("complementaryArea",e,void 0)}function k(e,t,r,n){return{type:"SET_MULTIPLE_ENABLE_ITEM",itemType:e,scope:t,item:r,isEnable:n}}function S(e,t){return k("pinnedItems",e,t,!0)}function I(e,t){return k("pinnedItems",e,t,!1)}function A(e,t){return function({select:r,dispatch:n}){const c=r.isFeatureActive(e,t);n.setFeatureValue(e,t,!c)}}function x(e,t,r){return{type:"SET_FEATURE_VALUE",scope:e,featureName:t,value:!!r}}function T(e,t){return{type:"SET_FEATURE_DEFAULTS",scope:e,defaults:t}}function B(e,t){return function(e,t,r){return Object(j.get)(e.enableItems.singleEnableItems,[t,r])}(e,"complementaryArea",t)}function N(e,t,r){return!1!==function(e,t,r,n){return Object(j.get)(e.enableItems.multipleEnableItems,[t,r,n])}(e,"pinnedItems",t,r)}function C(e,t,r){var n,c;const i=null===(n=e.preferences.features[t])||void 0===n?void 0:n[r];return!!(void 0!==i?i:null===(c=e.preferenceDefaults.features[t])||void 0===c?void 0:c[r])}const L=Object(d.createReduxStore)("core/interface",{reducer:h,actions:n,selectors:c,persist:["enableItems","preferences"],__experimentalUseThunks:!0});Object(d.registerStore)("core/interface",{reducer:h,actions:n,selectors:c,persist:["enableItems","preferences"],__experimentalUseThunks:!0});var W=r("TvNi"),R=Object(W.withPluginContext)((e,t)=>({icon:t.icon||e.icon,identifier:t.identifier||`${e.name}/${t.name}`}));var P=R((function({as:e=l.Button,scope:t,identifier:r,icon:n,selectedIcon:c,...o}){const s=e,u=Object(d.useSelect)(e=>e(L).getActive