芝麻web文件管理V1.00
编辑当前文件:/home/r5772835/public_html/dina.ycreate.jp/wp-content/plugins/layout-grid/index.js
!function(){var e={184:function(e,t){var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e=[],t=0;t
1?R(e)/2:R(e):e===B?R(e):R(e)/t}function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function N(t){for(var n=1;n
4&&void 0!==arguments[4])||arguments[4];return{name:e,column:t,value:n,device:r,enabled:o}}function Z(e,t,n){for(var r=[],o=R(e),i=function(e,t,n){for(var r=[],o=0,i=0;i
0)),r.push(W("row",a,s+1,e))}return r}function $(e,t){var n={};return e.filter((function(e){return e.enabled&&t[e.name]})).map((function(e){return n[t[e.name](e.column,e.value,e.device)]=!0})),n}function J(e){return e?e.replace(/column\d-\w*-grid__\w*-\d*/g,"").replace(/column\d-grid__\w*-\d*/g,"").replace(/\s{2,}/,"").replace(/wp-block-jetpack-layout-gutter__\w*/,"").replace(/is-vertically-aligned-\w*/,"").replace(/is-style-[A-Za-z-_]*/,"").replace(/are-vertically-aligned-\w*/):e}function Q(e){var t=e.gutterSize;return{"wp-block-jetpack-layout-gutter__nowrap":!e.addGutterEnds,"wp-block-jetpack-layout-gutter__none":"none"===t,"wp-block-jetpack-layout-gutter__small":"small"===t,"wp-block-jetpack-layout-gutter__medium":"medium"===t,"wp-block-jetpack-layout-gutter__huge":"huge"===t}}var Y=["columns"],ee=function(e){return(0,g.createElement)(b.SVG,o({xmlns:"http://www.w3.org/2000/svg",width:"48",height:"48",viewBox:"0 0 48 48"},e),(0,g.createElement)(b.Path,{d:"M7 12v24h34V12H7zm32 22H9V14h30v20z"}))},te=function(e){return(0,g.createElement)(b.SVG,o({xmlns:"http://www.w3.org/2000/svg",width:"48",height:"48",viewBox:"0 0 48 48"},e),(0,g.createElement)(b.Path,{d:"M7,12v24h34V12H7z M23,34H9V14h14V34z M39,34H25V14h14V34z"}))},ne=function(e){return(0,g.createElement)(b.SVG,o({xmlns:"http://www.w3.org/2000/svg",width:"48",height:"48",viewBox:"0 0 48 48"},e),(0,g.createElement)(b.Path,{d:"M7 12v24h34V12H7zm23 2h9v20h-9V14zm-2 20h-8V14h8v20zM9 14h9v20H9V14z"}))},re=function(e){return(0,g.createElement)(b.SVG,o({xmlns:"http://www.w3.org/2000/svg",width:"48",height:"48",viewBox:"0 0 48 48"},e),(0,g.createElement)(b.Path,{d:"M7 12v24h34V12H7zm8 22H9V14h6v20zm8 0h-6V14h6v20zm8 0h-6V14h6v20zm8 0h-6V14h6v20z"}))},oe=function(e){var t=e.columns,n=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r
=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r
=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,Y);return 4===t?(0,g.createElement)(re,n):3===t?(0,g.createElement)(ne,n):2===t?(0,g.createElement)(te,n):(0,g.createElement)(ee,n)},ie=function(e){var t=e.direction,n=e.height,r=e.xPos,o=e.top,i=e.isSelected,a=h()("wpcom-overlay-resize__handle","components-resizable-box__container",{"is-selected":i}),c={height:n+"px",width:r+"px",top:o+"px"},l={left:r+"px"},u=h()("components-resizable-box__handle","components-resizable-box__side-handle",{"components-resizable-box__handle-left":"left"===t,"components-resizable-box__handle-right":"right"===t});return(0,g.createElement)("div",{className:a,style:c},(0,g.createElement)("span",null,(0,g.createElement)("div",{className:u,style:l})))};var ae=function(t){s(a,t);var n,r,o=(n=a,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=f(n);if(r){var o=f(this).constructor;e=Reflect.construct(t,arguments,o)}else e=t.apply(this,arguments);return p(this,e)});function a(t){var n;return i(this,a),e(l(n=o.call(this,t)),"onMouseDown",(function(e){var t=e.target;if((0===e.button||e.touches)&&(t.dataset.resizeRight||t.dataset.resizeLeft)){n.block=t.closest(".wp-block");var r=n.block.getBoundingClientRect(),o=r.height,i=r.right,a=r.left,c=r.top,l=t.getBoundingClientRect().width,u=n.getChildPosition(n.block),s=t.dataset.resizeLeft;n.setState({resizingColumn:u,xPos:n.getAdjustedOffset(n.getMouseX(e),l),height:o,width:l,top:n.getAdjustedTop(c),direction:s?"left":"right",max:s?n.getAdjustedOffset(i,l):n.getAdjustedOffset(a,l)}),0===e.button?(document.addEventListener("mousemove",n.onMouseMove),document.addEventListener("mouseup",n.onMouseUp),e.preventDefault()):(document.addEventListener("touchmove",n.onMouseMove),document.addEventListener("touchend",n.onMouseUp)),e.stopPropagation()}})),e(l(n),"onMouseMove",(function(e){e.stopPropagation(),void 0===e.touches&&e.preventDefault();var t=n.block.getBoundingClientRect().height;n.setState({xPos:n.getRestrictedOffset(n.getAdjustedOffset(n.getMouseX(e))),height:t});var r=n.getNearestColumn(n.state.direction,e);r&&n.props.onResize(n.state.resizingColumn,r)})),e(l(n),"onMouseUp",(function(e){n.setState({resizingColumn:-1}),document.removeEventListener("mousemove",n.onMouseMove),document.removeEventListener("mouseup",n.onMouseUp),document.removeEventListener("touchmove",n.onMouseMove),document.removeEventListener("touchend",n.onMouseUp)})),n.containerRef=(0,g.createRef)(),n.state={resizingColumn:-1,xPos:0,height:0},n}return c(a,[{key:"getNearestColumn",value:function(e,t){var n=this.props,r=n.totalColumns,o=n.layoutGrid,i=o.getStart(this.state.resizingColumn),a=o.getSpan(this.state.resizingColumn),c=Math.min(r,Math.max(0,function(e,t,n,r){var o=e.getBoundingClientRect(),i=o.width/r,a=t-o.x,c=Math.floor(a/i),l=a%i;return"left"===n?l<=i/2?c:c+1:l
i?a-l:a+l,direction:e};return u.start>=i+a?null:(u.span=Math.max(1,u.span),u)}return{span:Math.max(1,c-i),direction:e}}},{key:"getMouseX",value:function(e){var t=e.clientX,n=e.targetTouches;return t||n&&n[0].clientX}},{key:"getAdjustedOffset",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.state.width,r=t>0?t:n;return e-this.containerRef.current.getBoundingClientRect().left-r/2}},{key:"getAdjustedTop",value:function(e){return e-this.containerRef.current.getBoundingClientRect().top}},{key:"getRestrictedOffset",value:function(e){var t=this.state,n=t.direction,r=t.max,o=t.width;return"left"===n?Math.min(r-o,e):Math.max(r+o,e)}},{key:"getChildPosition",value:function(e){for(var t=0;null!==e.previousSibling;)e=e.previousSibling,t++;return t}},{key:"render",value:function(){var e=this.props,t=e.className,n=e.children,r=e.isSelected,o=this.state,i=o.resizingColumn,a=o.xPos,c=o.height,l=h()(t,-1!==i?"wp-block-jetpack-layout-grid__resizing":null);return(0,g.createElement)("div",{className:l,onMouseDown:this.onMouseDown,onTouchStart:this.onMouseDown,ref:this.containerRef},-1!==i&&(0,g.createElement)(ie,{direction:this.state.direction,height:c,xPos:a,top:this.state.top,isSelected:r}),n)}}]),a}(g.Component),ce=ae;function le(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function ue(t){for(var n=1;n
=n?n:t;return{adjustment:this.getAdjustOffset(e,n-r),offsetUsed:r}}},{key:"hasOverlaps",value:function(e){for(var t=0;t
o.start&&n.start
o.start&&n.end
=o&&(a-=o),(a+=l)>o)return!1;r.push({start:i+u,end:i+u+l}),i+=l+u}return!(i>(t=this.device,n=this.columnCount,t===A&&n>2?2*R(t):t===B?R(t)*n:R(t))||this.hasOverlaps(r))}},{key:"getEndAdjustments",value:function(e,t){var n=[];if(t<0)return[this.getAdjustOffset(e,this.getOffset(e)+Math.abs(t))];if(t>0)for(var r=e;r
0;r++){var o=this.getShrinkOffset(r,Math.abs(t));n.push(o.adjustment),t-=o.offsetUsed}return n}},{key:"getStartMovedLeft",value:function(e,t){for(var n=[],r=e;r>=0&&t>0;r--){var o=this.getShrinkOffset(r,t);n.push(o.adjustment),t-=o.offsetUsed}return n}},{key:"getStartAdjustments",value:function(e,t){var n=this.getOffset(e),r=this.getOffsetFromStart(e,t),o=r-n;return o<0?this.getStartMovedLeft(e,Math.abs(o)):[this.getAdjustOffset(e,r)]}},{key:"getSpan",value:function(e){return this.attributes[M(e,this.device)]}},{key:"getOffset",value:function(e){return this.attributes[D(e,this.device)]}},{key:"getStart",value:function(e){for(var t=0,n=0;n
0&&this.validateGrid(c)?c:null}}]),t}();function de(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n
50}},{key:"updateInspectorDevice",value:function(e){this.setState({inspectorDeviceType:e}),"Mobile"!==this.state.viewPort&&this.props.setPreviewDeviceType(e)}},{key:"getPreviewMode",value:function(){return this.props.isBlockOrPatternPreview?"Desktop":"Desktop"===this.state.viewPort||"Mobile"===this.props.previewDeviceType?this.props.previewDeviceType:this.state.viewPort}},{key:"getInspectorMode",value:function(){return"Desktop"===this.state.viewPort?this.props.previewDeviceType:this.state.inspectorDeviceType}},{key:"render",value:function(){var t=this,n=this.props,o=n.className,i=n.attributes,a=void 0===i?{}:i,c=n.isSelected,l=n.columns,u=n.setAttributes,s=n.updateAlignment,d=n.columnAttributes,p=this.state.viewPort,f=this.getPreviewMode(),m=this.getInspectorMode(),k=function(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],o=Z(e,t,n),i={span:G,offset:I,row:L},a={},c=0;c
n)return[].concat(ve(e),ve(Array.from({length:r-n},(function(){return(0,t.createBlock)("jetpack/layout-grid-column")}))));var o=ve(e),i=0;return o.reverse(),(o=o.filter((function(e){return!(i
0}})),(0,fe.withDispatch)((function(e,t,n){return{updateAlignment:function(r){var o=t.clientId,i=t.setAttributes,a=e("core/block-editor").updateBlockAttributes,c=n.select("core/block-editor").getBlockRootClientId;i({verticalAlignment:r}),a(c(o),{verticalAlignment:null})}}})))(je),Se=[{attributes:{backgroundColor:{type:"string"},customBackgroundColor:{type:"string"},padding:{type:"string",default:"none"},verticalAlignment:{type:"string"}},save:function(t){var n,r=t.attributes,o=void 0===r?{}:r,i=o.className,a=o.backgroundColor,c=o.customBackgroundColor,l=o.padding,u=o.verticalAlignment,s=(0,y.getColorClassName)("background-color",a),d=h()(i,(e(n={},"wp-block-jetpack-layout-grid__padding-"+l,!0),e(n,"has-background",a),e(n,s,s),e(n,"is-vertically-aligned-".concat(u),u),n)),p={backgroundColor:s?void 0:c};return(0,g.createElement)("div",{className:d,style:p},(0,g.createElement)(y.InnerBlocks.Content,null))}}];function Pe(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}(0,t.registerBlockType)("jetpack/layout-grid",{title:(0,r.__)("Layout Grid","layout-grid"),description:(0,r.__)("Align blocks to a global grid, with support for responsive breakpoints.","layout-grid"),icon:function(e){return e.size&&(e.width=e.size,e.height=e.size),(0,g.createElement)(b.SVG,o({xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},e),(0,g.createElement)(b.Path,{d:"M19 6H6c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-7.5 11.5H6c-.3 0-.5-.2-.5-.5V8c0-.3.2-.5.5-.5h5.5v10zm4 0H13v-10h2.5v10zm4-.5c0 .3-.2.5-.5.5h-2v-10h2c.3 0 .5.2.5.5v9z"}))},category:"design",supports:{align:["full"],html:!1},example:{attributes:{columns:2},innerBlocks:[{name:"jetpack/layout-grid-column",innerBlocks:[{name:"core/paragraph",attributes:{customFontSize:32,content:(0,r.__)("
Snow Patrol
","layout-grid"),align:"center"}}]},{name:"jetpack/layout-grid-column",innerBlocks:[{name:"core/image",attributes:{url:"https://s.w.org/images/core/5.3/Windbuchencom.jpg"}}]}]},attributes:function(t){for(var n=1;n
1&&void 0!==arguments[1]?arguments[1]:{},n={},r={span:U,offset:X,row:F},o=0;o