2021-05-20 14:20:04 +02:00
|
|
|
this.wp=this.wp||{},this.wp.nux=function(e){var n={};function t(r){if(n[r])return n[r].exports;var s=n[r]={i:r,l:!1,exports:{}};return e[r].call(s.exports,s,s.exports,t),s.l=!0,s.exports}return t.m=e,t.c=n,t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{enumerable:!0,get:r})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,n){if(1&n&&(e=t(e)),8&n)return e;if(4&n&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(t.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&n&&"string"!=typeof e)for(var s in e)t.d(r,s,function(n){return e[n]}.bind(null,s));return r},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},t.p="",t(t.s="./node_modules/@wordpress/nux/build-module/index.js")}({"./node_modules/@wordpress/icons/build-module/library/close.js":function(e,n,t){"use strict";var r=t("@wordpress/element"),s=t("@wordpress/primitives");const i=Object(r.createElement)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(s.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"}));n.a=i},"./node_modules/@wordpress/nux/build-module/index.js":function(e,n,t){"use strict";t.r(n),t.d(n,"store",(function(){return j})),t.d(n,"DotTip",(function(){return I}));var r={};t.r(r),t.d(r,"triggerGuide",(function(){return p})),t.d(r,"dismissTip",(function(){return a})),t.d(r,"disableTips",(function(){return l})),t.d(r,"enableTips",(function(){return f}));var s={};t.r(s),t.d(s,"getAssociatedGuide",(function(){return m})),t.d(s,"isTipVisible",(function(){return h})),t.d(s,"areTipsEnabled",(function(){return x}));var i=t("@wordpress/deprecated"),o=t.n(i),u=t("@wordpress/data");const c=Object(u.combineReducers)({areTipsEnabled:function(e=!0,n){switch(n.type){case"DISABLE_TIPS":return!1;case"ENABLE_TIPS":return!0}return e},dismissedTips:function(e={},n){switch(n.type){case"DISMISS_TIP":return{...e,[n.id]:!0};case"ENABLE_TIPS":return{}}return e}});var d=Object(u.combineReducers)({guides:function(e=[],n){switch(n.type){case"TRIGGER_GUIDE":return[...e,n.tipIds]}return e},preferences:c});function p(e){return{type:"TRIGGER_GUIDE",tipIds:e}}function a(e){return{type:"DISMISS_TIP",id:e}}function l(){return{type:"DISABLE_TIPS"}}function f(){return{type:"ENABLE_TIPS"}}var b=t("./node_modules/rememo/es/rememo.js"),w=t("lodash");const m=Object(b.a)((e,n)=>{for(const t of e.guides)if(Object(w.includes)(t,n)){const n=Object(w.difference)(t,Object(w.keys)(e.preferences.dismissedTips)),[r=null,s=null]=n;return{tipIds:t,currentTipId:r,nextTipId:s}}return null},e=>[e.guides,e.preferences.dismissedTips]);function h(e,n){if(!e.preferences.areTipsEnabled)return!1;if(Object(w.has)(e.preferences.dismissedTips,[n]))return!1;const t=m(e,n);return!t||t.currentTipId===n}function x(e){return e.preferences.areTipsEnabled}const j=Object(u.createReduxStore)("core/nux",{reducer:d,actions:r,selectors:s,persist:["preferences"]});Object(u.registerStore)("core/nux",{reducer:d,actions:r,selectors:s,persist:["preferences"]});var v=t("@wordpress/element"),O=t("@wordpress/compose"),T=t("@wordpress/components"),g=t("@wordpress/i18n"),_=t("./node_modules/@wordpress/icons/build-module/library/close.js");function y(e){e.stopPropagation()}var I=Object(O.compose)(Object(u.withSelect)((e,{tipId:n})=>{const{isTipVisible:t,getAssociatedGuide:r}=e("core/nux"),s=r(n);return{isVisible:t(n),hasNextTip:!(!s||!s.nextTipId)}}),Object(u.withDispatch)((e,{tipId:n})=>{const{dismissTip:t,disableTips:r}=e("core/nux");return{onDismiss(){t(n)},onDisable(){r()}}}))((function({position:e="middle right",children:n,isVisible:t,hasNextTip:r,onDismiss:s,onDisable:i}){const o=Object(v.useRef)(null),u=Object(v.useCallback)(e=>{o.current&&(o.current.contains(e.relatedTarget)||i())},[i,o]);return t?Object(v.createElement)(T.Popover,{className:"
|