Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93

Warning: Undefined array key "page_file_edit_line" in /home/sportsfever/public_html/filemanger/edit_text_line.php on line 32
/home/sportsfe.../httpdocs/clone/wp-inclu.../js/dist
File: block-editor.js
return extraProps;
[25000] Fix | Delete
}
[25001] Fix | Delete
/* harmony default export */ const aria_label = ({
[25002] Fix | Delete
addSaveProps: aria_label_addSaveProps,
[25003] Fix | Delete
attributeKeys: ['ariaLabel'],
[25004] Fix | Delete
hasSupport(name) {
[25005] Fix | Delete
return (0,external_wp_blocks_namespaceObject.hasBlockSupport)(name, 'ariaLabel');
[25006] Fix | Delete
}
[25007] Fix | Delete
});
[25008] Fix | Delete
(0,external_wp_hooks_namespaceObject.addFilter)('blocks.registerBlockType', 'core/ariaLabel/attribute', aria_label_addAttribute);
[25009] Fix | Delete
[25010] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/hooks/custom-class-name.js
[25011] Fix | Delete
/**
[25012] Fix | Delete
* External dependencies
[25013] Fix | Delete
*/
[25014] Fix | Delete
[25015] Fix | Delete
[25016] Fix | Delete
/**
[25017] Fix | Delete
* WordPress dependencies
[25018] Fix | Delete
*/
[25019] Fix | Delete
[25020] Fix | Delete
[25021] Fix | Delete
[25022] Fix | Delete
[25023] Fix | Delete
[25024] Fix | Delete
/**
[25025] Fix | Delete
* Internal dependencies
[25026] Fix | Delete
*/
[25027] Fix | Delete
[25028] Fix | Delete
[25029] Fix | Delete
[25030] Fix | Delete
/**
[25031] Fix | Delete
* Filters registered block settings, extending attributes to include `className`.
[25032] Fix | Delete
*
[25033] Fix | Delete
* @param {Object} settings Original block settings.
[25034] Fix | Delete
*
[25035] Fix | Delete
* @return {Object} Filtered block settings.
[25036] Fix | Delete
*/
[25037] Fix | Delete
[25038] Fix | Delete
function custom_class_name_addAttribute(settings) {
[25039] Fix | Delete
if ((0,external_wp_blocks_namespaceObject.hasBlockSupport)(settings, 'customClassName', true)) {
[25040] Fix | Delete
// Gracefully handle if settings.attributes is undefined.
[25041] Fix | Delete
settings.attributes = {
[25042] Fix | Delete
...settings.attributes,
[25043] Fix | Delete
className: {
[25044] Fix | Delete
type: 'string'
[25045] Fix | Delete
}
[25046] Fix | Delete
};
[25047] Fix | Delete
}
[25048] Fix | Delete
return settings;
[25049] Fix | Delete
}
[25050] Fix | Delete
function CustomClassNameControlsPure({
[25051] Fix | Delete
className,
[25052] Fix | Delete
setAttributes
[25053] Fix | Delete
}) {
[25054] Fix | Delete
const blockEditingMode = useBlockEditingMode();
[25055] Fix | Delete
if (blockEditingMode !== 'default') {
[25056] Fix | Delete
return null;
[25057] Fix | Delete
}
[25058] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(inspector_controls, {
[25059] Fix | Delete
group: "advanced",
[25060] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.TextControl, {
[25061] Fix | Delete
__nextHasNoMarginBottom: true,
[25062] Fix | Delete
__next40pxDefaultSize: true,
[25063] Fix | Delete
autoComplete: "off",
[25064] Fix | Delete
label: (0,external_wp_i18n_namespaceObject.__)('Additional CSS class(es)'),
[25065] Fix | Delete
value: className || '',
[25066] Fix | Delete
onChange: nextValue => {
[25067] Fix | Delete
setAttributes({
[25068] Fix | Delete
className: nextValue !== '' ? nextValue : undefined
[25069] Fix | Delete
});
[25070] Fix | Delete
},
[25071] Fix | Delete
help: (0,external_wp_i18n_namespaceObject.__)('Separate multiple classes with spaces.')
[25072] Fix | Delete
})
[25073] Fix | Delete
});
[25074] Fix | Delete
}
[25075] Fix | Delete
/* harmony default export */ const custom_class_name = ({
[25076] Fix | Delete
edit: CustomClassNameControlsPure,
[25077] Fix | Delete
addSaveProps: custom_class_name_addSaveProps,
[25078] Fix | Delete
attributeKeys: ['className'],
[25079] Fix | Delete
hasSupport(name) {
[25080] Fix | Delete
return (0,external_wp_blocks_namespaceObject.hasBlockSupport)(name, 'customClassName', true);
[25081] Fix | Delete
}
[25082] Fix | Delete
});
[25083] Fix | Delete
[25084] Fix | Delete
/**
[25085] Fix | Delete
* Override props assigned to save component to inject the className, if block
[25086] Fix | Delete
* supports customClassName. This is only applied if the block's save result is an
[25087] Fix | Delete
* element and not a markup string.
[25088] Fix | Delete
*
[25089] Fix | Delete
* @param {Object} extraProps Additional props applied to save element.
[25090] Fix | Delete
* @param {Object} blockType Block type.
[25091] Fix | Delete
* @param {Object} attributes Current block attributes.
[25092] Fix | Delete
*
[25093] Fix | Delete
* @return {Object} Filtered props applied to save element.
[25094] Fix | Delete
*/
[25095] Fix | Delete
function custom_class_name_addSaveProps(extraProps, blockType, attributes) {
[25096] Fix | Delete
if ((0,external_wp_blocks_namespaceObject.hasBlockSupport)(blockType, 'customClassName', true) && attributes.className) {
[25097] Fix | Delete
extraProps.className = dist_clsx(extraProps.className, attributes.className);
[25098] Fix | Delete
}
[25099] Fix | Delete
return extraProps;
[25100] Fix | Delete
}
[25101] Fix | Delete
function addTransforms(result, source, index, results) {
[25102] Fix | Delete
if (!(0,external_wp_blocks_namespaceObject.hasBlockSupport)(result.name, 'customClassName', true)) {
[25103] Fix | Delete
return result;
[25104] Fix | Delete
}
[25105] Fix | Delete
[25106] Fix | Delete
// If the condition verifies we are probably in the presence of a wrapping transform
[25107] Fix | Delete
// e.g: nesting paragraphs in a group or columns and in that case the class should not be kept.
[25108] Fix | Delete
if (results.length === 1 && result.innerBlocks.length === source.length) {
[25109] Fix | Delete
return result;
[25110] Fix | Delete
}
[25111] Fix | Delete
[25112] Fix | Delete
// If we are transforming one block to multiple blocks or multiple blocks to one block,
[25113] Fix | Delete
// we ignore the class during the transform.
[25114] Fix | Delete
if (results.length === 1 && source.length > 1 || results.length > 1 && source.length === 1) {
[25115] Fix | Delete
return result;
[25116] Fix | Delete
}
[25117] Fix | Delete
[25118] Fix | Delete
// If we are in presence of transform between one or more block in the source
[25119] Fix | Delete
// that have one or more blocks in the result
[25120] Fix | Delete
// we apply the class on source N to the result N,
[25121] Fix | Delete
// if source N does not exists we do nothing.
[25122] Fix | Delete
if (source[index]) {
[25123] Fix | Delete
const originClassName = source[index]?.attributes.className;
[25124] Fix | Delete
if (originClassName) {
[25125] Fix | Delete
return {
[25126] Fix | Delete
...result,
[25127] Fix | Delete
attributes: {
[25128] Fix | Delete
...result.attributes,
[25129] Fix | Delete
className: originClassName
[25130] Fix | Delete
}
[25131] Fix | Delete
};
[25132] Fix | Delete
}
[25133] Fix | Delete
}
[25134] Fix | Delete
return result;
[25135] Fix | Delete
}
[25136] Fix | Delete
(0,external_wp_hooks_namespaceObject.addFilter)('blocks.registerBlockType', 'core/editor/custom-class-name/attribute', custom_class_name_addAttribute);
[25137] Fix | Delete
(0,external_wp_hooks_namespaceObject.addFilter)('blocks.switchToBlockType.transformedBlock', 'core/color/addTransforms', addTransforms);
[25138] Fix | Delete
[25139] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/hooks/generated-class-name.js
[25140] Fix | Delete
/**
[25141] Fix | Delete
* WordPress dependencies
[25142] Fix | Delete
*/
[25143] Fix | Delete
[25144] Fix | Delete
[25145] Fix | Delete
[25146] Fix | Delete
/**
[25147] Fix | Delete
* Override props assigned to save component to inject generated className if
[25148] Fix | Delete
* block supports it. This is only applied if the block's save result is an
[25149] Fix | Delete
* element and not a markup string.
[25150] Fix | Delete
*
[25151] Fix | Delete
* @param {Object} extraProps Additional props applied to save element.
[25152] Fix | Delete
* @param {Object} blockType Block type.
[25153] Fix | Delete
*
[25154] Fix | Delete
* @return {Object} Filtered props applied to save element.
[25155] Fix | Delete
*/
[25156] Fix | Delete
function addGeneratedClassName(extraProps, blockType) {
[25157] Fix | Delete
// Adding the generated className.
[25158] Fix | Delete
if ((0,external_wp_blocks_namespaceObject.hasBlockSupport)(blockType, 'className', true)) {
[25159] Fix | Delete
if (typeof extraProps.className === 'string') {
[25160] Fix | Delete
// We have some extra classes and want to add the default classname
[25161] Fix | Delete
// We use uniq to prevent duplicate classnames.
[25162] Fix | Delete
[25163] Fix | Delete
extraProps.className = [...new Set([(0,external_wp_blocks_namespaceObject.getBlockDefaultClassName)(blockType.name), ...extraProps.className.split(' ')])].join(' ').trim();
[25164] Fix | Delete
} else {
[25165] Fix | Delete
// There is no string in the className variable,
[25166] Fix | Delete
// so we just dump the default name in there.
[25167] Fix | Delete
extraProps.className = (0,external_wp_blocks_namespaceObject.getBlockDefaultClassName)(blockType.name);
[25168] Fix | Delete
}
[25169] Fix | Delete
}
[25170] Fix | Delete
return extraProps;
[25171] Fix | Delete
}
[25172] Fix | Delete
(0,external_wp_hooks_namespaceObject.addFilter)('blocks.getSaveContent.extraProps', 'core/generated-class-name/save-props', addGeneratedClassName);
[25173] Fix | Delete
[25174] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/colord/index.mjs
[25175] Fix | Delete
var colord_r={grad:.9,turn:360,rad:360/(2*Math.PI)},t=function(r){return"string"==typeof r?r.length>0:"number"==typeof r},n=function(r,t,n){return void 0===t&&(t=0),void 0===n&&(n=Math.pow(10,t)),Math.round(n*r)/n+0},e=function(r,t,n){return void 0===t&&(t=0),void 0===n&&(n=1),r>n?n:r>t?r:t},u=function(r){return(r=isFinite(r)?r%360:0)>0?r:r+360},a=function(r){return{r:e(r.r,0,255),g:e(r.g,0,255),b:e(r.b,0,255),a:e(r.a)}},o=function(r){return{r:n(r.r),g:n(r.g),b:n(r.b),a:n(r.a,3)}},i=/^#([0-9a-f]{3,8})$/i,s=function(r){var t=r.toString(16);return t.length<2?"0"+t:t},h=function(r){var t=r.r,n=r.g,e=r.b,u=r.a,a=Math.max(t,n,e),o=a-Math.min(t,n,e),i=o?a===t?(n-e)/o:a===n?2+(e-t)/o:4+(t-n)/o:0;return{h:60*(i<0?i+6:i),s:a?o/a*100:0,v:a/255*100,a:u}},b=function(r){var t=r.h,n=r.s,e=r.v,u=r.a;t=t/360*6,n/=100,e/=100;var a=Math.floor(t),o=e*(1-n),i=e*(1-(t-a)*n),s=e*(1-(1-t+a)*n),h=a%6;return{r:255*[e,i,o,o,s,e][h],g:255*[s,e,e,i,o,o][h],b:255*[o,o,s,e,e,i][h],a:u}},g=function(r){return{h:u(r.h),s:e(r.s,0,100),l:e(r.l,0,100),a:e(r.a)}},d=function(r){return{h:n(r.h),s:n(r.s),l:n(r.l),a:n(r.a,3)}},f=function(r){return b((n=(t=r).s,{h:t.h,s:(n*=((e=t.l)<50?e:100-e)/100)>0?2*n/(e+n)*100:0,v:e+n,a:t.a}));var t,n,e},c=function(r){return{h:(t=h(r)).h,s:(u=(200-(n=t.s))*(e=t.v)/100)>0&&u<200?n*e/100/(u<=100?u:200-u)*100:0,l:u/2,a:t.a};var t,n,e,u},l=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,p=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,v=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,m=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,y={string:[[function(r){var t=i.exec(r);return t?(r=t[1]).length<=4?{r:parseInt(r[0]+r[0],16),g:parseInt(r[1]+r[1],16),b:parseInt(r[2]+r[2],16),a:4===r.length?n(parseInt(r[3]+r[3],16)/255,2):1}:6===r.length||8===r.length?{r:parseInt(r.substr(0,2),16),g:parseInt(r.substr(2,2),16),b:parseInt(r.substr(4,2),16),a:8===r.length?n(parseInt(r.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(r){var t=v.exec(r)||m.exec(r);return t?t[2]!==t[4]||t[4]!==t[6]?null:a({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:void 0===t[7]?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(t){var n=l.exec(t)||p.exec(t);if(!n)return null;var e,u,a=g({h:(e=n[1],u=n[2],void 0===u&&(u="deg"),Number(e)*(colord_r[u]||1)),s:Number(n[3]),l:Number(n[4]),a:void 0===n[5]?1:Number(n[5])/(n[6]?100:1)});return f(a)},"hsl"]],object:[[function(r){var n=r.r,e=r.g,u=r.b,o=r.a,i=void 0===o?1:o;return t(n)&&t(e)&&t(u)?a({r:Number(n),g:Number(e),b:Number(u),a:Number(i)}):null},"rgb"],[function(r){var n=r.h,e=r.s,u=r.l,a=r.a,o=void 0===a?1:a;if(!t(n)||!t(e)||!t(u))return null;var i=g({h:Number(n),s:Number(e),l:Number(u),a:Number(o)});return f(i)},"hsl"],[function(r){var n=r.h,a=r.s,o=r.v,i=r.a,s=void 0===i?1:i;if(!t(n)||!t(a)||!t(o))return null;var h=function(r){return{h:u(r.h),s:e(r.s,0,100),v:e(r.v,0,100),a:e(r.a)}}({h:Number(n),s:Number(a),v:Number(o),a:Number(s)});return b(h)},"hsv"]]},N=function(r,t){for(var n=0;n<t.length;n++){var e=t[n][0](r);if(e)return[e,t[n][1]]}return[null,void 0]},x=function(r){return"string"==typeof r?N(r.trim(),y.string):"object"==typeof r&&null!==r?N(r,y.object):[null,void 0]},I=function(r){return x(r)[1]},M=function(r,t){var n=c(r);return{h:n.h,s:e(n.s+100*t,0,100),l:n.l,a:n.a}},H=function(r){return(299*r.r+587*r.g+114*r.b)/1e3/255},$=function(r,t){var n=c(r);return{h:n.h,s:n.s,l:e(n.l+100*t,0,100),a:n.a}},colord_j=function(){function r(r){this.parsed=x(r)[0],this.rgba=this.parsed||{r:0,g:0,b:0,a:1}}return r.prototype.isValid=function(){return null!==this.parsed},r.prototype.brightness=function(){return n(H(this.rgba),2)},r.prototype.isDark=function(){return H(this.rgba)<.5},r.prototype.isLight=function(){return H(this.rgba)>=.5},r.prototype.toHex=function(){return r=o(this.rgba),t=r.r,e=r.g,u=r.b,i=(a=r.a)<1?s(n(255*a)):"","#"+s(t)+s(e)+s(u)+i;var r,t,e,u,a,i},r.prototype.toRgb=function(){return o(this.rgba)},r.prototype.toRgbString=function(){return r=o(this.rgba),t=r.r,n=r.g,e=r.b,(u=r.a)<1?"rgba("+t+", "+n+", "+e+", "+u+")":"rgb("+t+", "+n+", "+e+")";var r,t,n,e,u},r.prototype.toHsl=function(){return d(c(this.rgba))},r.prototype.toHslString=function(){return r=d(c(this.rgba)),t=r.h,n=r.s,e=r.l,(u=r.a)<1?"hsla("+t+", "+n+"%, "+e+"%, "+u+")":"hsl("+t+", "+n+"%, "+e+"%)";var r,t,n,e,u},r.prototype.toHsv=function(){return r=h(this.rgba),{h:n(r.h),s:n(r.s),v:n(r.v),a:n(r.a,3)};var r},r.prototype.invert=function(){return w({r:255-(r=this.rgba).r,g:255-r.g,b:255-r.b,a:r.a});var r},r.prototype.saturate=function(r){return void 0===r&&(r=.1),w(M(this.rgba,r))},r.prototype.desaturate=function(r){return void 0===r&&(r=.1),w(M(this.rgba,-r))},r.prototype.grayscale=function(){return w(M(this.rgba,-1))},r.prototype.lighten=function(r){return void 0===r&&(r=.1),w($(this.rgba,r))},r.prototype.darken=function(r){return void 0===r&&(r=.1),w($(this.rgba,-r))},r.prototype.rotate=function(r){return void 0===r&&(r=15),this.hue(this.hue()+r)},r.prototype.alpha=function(r){return"number"==typeof r?w({r:(t=this.rgba).r,g:t.g,b:t.b,a:r}):n(this.rgba.a,3);var t},r.prototype.hue=function(r){var t=c(this.rgba);return"number"==typeof r?w({h:r,s:t.s,l:t.l,a:t.a}):n(t.h)},r.prototype.isEqual=function(r){return this.toHex()===w(r).toHex()},r}(),w=function(r){return r instanceof colord_j?r:new colord_j(r)},S=[],k=function(r){r.forEach(function(r){S.indexOf(r)<0&&(r(colord_j,y),S.push(r))})},E=function(){return new colord_j({r:255*Math.random(),g:255*Math.random(),b:255*Math.random()})};
[25176] Fix | Delete
[25177] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/colord/plugins/names.mjs
[25178] Fix | Delete
/* harmony default export */ function names(e,f){var a={white:"#ffffff",bisque:"#ffe4c4",blue:"#0000ff",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",antiquewhite:"#faebd7",aqua:"#00ffff",azure:"#f0ffff",whitesmoke:"#f5f5f5",papayawhip:"#ffefd5",plum:"#dda0dd",blanchedalmond:"#ffebcd",black:"#000000",gold:"#ffd700",goldenrod:"#daa520",gainsboro:"#dcdcdc",cornsilk:"#fff8dc",cornflowerblue:"#6495ed",burlywood:"#deb887",aquamarine:"#7fffd4",beige:"#f5f5dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkkhaki:"#bdb76b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",peachpuff:"#ffdab9",darkmagenta:"#8b008b",darkred:"#8b0000",darkorchid:"#9932cc",darkorange:"#ff8c00",darkslateblue:"#483d8b",gray:"#808080",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",deeppink:"#ff1493",deepskyblue:"#00bfff",wheat:"#f5deb3",firebrick:"#b22222",floralwhite:"#fffaf0",ghostwhite:"#f8f8ff",darkviolet:"#9400d3",magenta:"#ff00ff",green:"#008000",dodgerblue:"#1e90ff",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",blueviolet:"#8a2be2",forestgreen:"#228b22",lawngreen:"#7cfc00",indianred:"#cd5c5c",indigo:"#4b0082",fuchsia:"#ff00ff",brown:"#a52a2a",maroon:"#800000",mediumblue:"#0000cd",lightcoral:"#f08080",darkturquoise:"#00ced1",lightcyan:"#e0ffff",ivory:"#fffff0",lightyellow:"#ffffe0",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",linen:"#faf0e6",mediumaquamarine:"#66cdaa",lemonchiffon:"#fffacd",lime:"#00ff00",khaki:"#f0e68c",mediumseagreen:"#3cb371",limegreen:"#32cd32",mediumspringgreen:"#00fa9a",lightskyblue:"#87cefa",lightblue:"#add8e6",midnightblue:"#191970",lightpink:"#ffb6c1",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",mintcream:"#f5fffa",lightslategray:"#778899",lightslategrey:"#778899",navajowhite:"#ffdead",navy:"#000080",mediumvioletred:"#c71585",powderblue:"#b0e0e6",palegoldenrod:"#eee8aa",oldlace:"#fdf5e6",paleturquoise:"#afeeee",mediumturquoise:"#48d1cc",mediumorchid:"#ba55d3",rebeccapurple:"#663399",lightsteelblue:"#b0c4de",mediumslateblue:"#7b68ee",thistle:"#d8bfd8",tan:"#d2b48c",orchid:"#da70d6",mediumpurple:"#9370db",purple:"#800080",pink:"#ffc0cb",skyblue:"#87ceeb",springgreen:"#00ff7f",palegreen:"#98fb98",red:"#ff0000",yellow:"#ffff00",slateblue:"#6a5acd",lavenderblush:"#fff0f5",peru:"#cd853f",palevioletred:"#db7093",violet:"#ee82ee",teal:"#008080",slategray:"#708090",slategrey:"#708090",aliceblue:"#f0f8ff",darkseagreen:"#8fbc8f",darkolivegreen:"#556b2f",greenyellow:"#adff2f",seagreen:"#2e8b57",seashell:"#fff5ee",tomato:"#ff6347",silver:"#c0c0c0",sienna:"#a0522d",lavender:"#e6e6fa",lightgreen:"#90ee90",orange:"#ffa500",orangered:"#ff4500",steelblue:"#4682b4",royalblue:"#4169e1",turquoise:"#40e0d0",yellowgreen:"#9acd32",salmon:"#fa8072",saddlebrown:"#8b4513",sandybrown:"#f4a460",rosybrown:"#bc8f8f",darksalmon:"#e9967a",lightgoldenrodyellow:"#fafad2",snow:"#fffafa",lightgrey:"#d3d3d3",lightgray:"#d3d3d3",dimgray:"#696969",dimgrey:"#696969",olivedrab:"#6b8e23",olive:"#808000"},r={};for(var d in a)r[a[d]]=d;var l={};e.prototype.toName=function(f){if(!(this.rgba.a||this.rgba.r||this.rgba.g||this.rgba.b))return"transparent";var d,i,n=r[this.toHex()];if(n)return n;if(null==f?void 0:f.closest){var o=this.toRgb(),t=1/0,b="black";if(!l.length)for(var c in a)l[c]=new e(a[c]).toRgb();for(var g in a){var u=(d=o,i=l[g],Math.pow(d.r-i.r,2)+Math.pow(d.g-i.g,2)+Math.pow(d.b-i.b,2));u<t&&(t=u,b=g)}return b}};f.string.push([function(f){var r=f.toLowerCase(),d="transparent"===r?"#0000":a[r];return d?new e(d).toRgb():null},"name"])}
[25179] Fix | Delete
[25180] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/colord/plugins/a11y.mjs
[25181] Fix | Delete
var a11y_o=function(o){var t=o/255;return t<.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},a11y_t=function(t){return.2126*a11y_o(t.r)+.7152*a11y_o(t.g)+.0722*a11y_o(t.b)};/* harmony default export */ function a11y(o){o.prototype.luminance=function(){return o=a11y_t(this.rgba),void 0===(r=2)&&(r=0),void 0===n&&(n=Math.pow(10,r)),Math.round(n*o)/n+0;var o,r,n},o.prototype.contrast=function(r){void 0===r&&(r="#FFF");var n,a,i,e,v,u,d,c=r instanceof o?r:new o(r);return e=this.rgba,v=c.toRgb(),u=a11y_t(e),d=a11y_t(v),n=u>d?(u+.05)/(d+.05):(d+.05)/(u+.05),void 0===(a=2)&&(a=0),void 0===i&&(i=Math.pow(10,a)),Math.floor(i*n)/i+0},o.prototype.isReadable=function(o,t){return void 0===o&&(o="#FFF"),void 0===t&&(t={}),this.contrast(o)>=(e=void 0===(i=(r=t).size)?"normal":i,"AAA"===(a=void 0===(n=r.level)?"AA":n)&&"normal"===e?7:"AA"===a&&"large"===e?3:4.5);var r,n,a,i,e}}
[25182] Fix | Delete
[25183] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/colors/utils.js
[25184] Fix | Delete
/**
[25185] Fix | Delete
* External dependencies
[25186] Fix | Delete
*/
[25187] Fix | Delete
[25188] Fix | Delete
[25189] Fix | Delete
[25190] Fix | Delete
[25191] Fix | Delete
/**
[25192] Fix | Delete
* WordPress dependencies
[25193] Fix | Delete
*/
[25194] Fix | Delete
[25195] Fix | Delete
[25196] Fix | Delete
/**
[25197] Fix | Delete
* Internal dependencies
[25198] Fix | Delete
*/
[25199] Fix | Delete
[25200] Fix | Delete
k([names, a11y]);
[25201] Fix | Delete
const {
[25202] Fix | Delete
kebabCase
[25203] Fix | Delete
} = unlock(external_wp_components_namespaceObject.privateApis);
[25204] Fix | Delete
[25205] Fix | Delete
/**
[25206] Fix | Delete
* Provided an array of color objects as set by the theme or by the editor defaults,
[25207] Fix | Delete
* and the values of the defined color or custom color returns a color object describing the color.
[25208] Fix | Delete
*
[25209] Fix | Delete
* @param {Array} colors Array of color objects as set by the theme or by the editor defaults.
[25210] Fix | Delete
* @param {?string} definedColor A string containing the color slug.
[25211] Fix | Delete
* @param {?string} customColor A string containing the customColor value.
[25212] Fix | Delete
*
[25213] Fix | Delete
* @return {?Object} If definedColor is passed and the name is found in colors,
[25214] Fix | Delete
* the color object exactly as set by the theme or editor defaults is returned.
[25215] Fix | Delete
* Otherwise, an object that just sets the color is defined.
[25216] Fix | Delete
*/
[25217] Fix | Delete
const getColorObjectByAttributeValues = (colors, definedColor, customColor) => {
[25218] Fix | Delete
if (definedColor) {
[25219] Fix | Delete
const colorObj = colors?.find(color => color.slug === definedColor);
[25220] Fix | Delete
if (colorObj) {
[25221] Fix | Delete
return colorObj;
[25222] Fix | Delete
}
[25223] Fix | Delete
}
[25224] Fix | Delete
return {
[25225] Fix | Delete
color: customColor
[25226] Fix | Delete
};
[25227] Fix | Delete
};
[25228] Fix | Delete
[25229] Fix | Delete
/**
[25230] Fix | Delete
* Provided an array of color objects as set by the theme or by the editor defaults, and a color value returns the color object matching that value or undefined.
[25231] Fix | Delete
*
[25232] Fix | Delete
* @param {Array} colors Array of color objects as set by the theme or by the editor defaults.
[25233] Fix | Delete
* @param {?string} colorValue A string containing the color value.
[25234] Fix | Delete
*
[25235] Fix | Delete
* @return {?Object} Color object included in the colors array whose color property equals colorValue.
[25236] Fix | Delete
* Returns undefined if no color object matches this requirement.
[25237] Fix | Delete
*/
[25238] Fix | Delete
const getColorObjectByColorValue = (colors, colorValue) => {
[25239] Fix | Delete
return colors?.find(color => color.color === colorValue);
[25240] Fix | Delete
};
[25241] Fix | Delete
[25242] Fix | Delete
/**
[25243] Fix | Delete
* Returns a class based on the context a color is being used and its slug.
[25244] Fix | Delete
*
[25245] Fix | Delete
* @param {string} colorContextName Context/place where color is being used e.g: background, text etc...
[25246] Fix | Delete
* @param {string} colorSlug Slug of the color.
[25247] Fix | Delete
*
[25248] Fix | Delete
* @return {?string} String with the class corresponding to the color in the provided context.
[25249] Fix | Delete
* Returns undefined if either colorContextName or colorSlug are not provided.
[25250] Fix | Delete
*/
[25251] Fix | Delete
function getColorClassName(colorContextName, colorSlug) {
[25252] Fix | Delete
if (!colorContextName || !colorSlug) {
[25253] Fix | Delete
return undefined;
[25254] Fix | Delete
}
[25255] Fix | Delete
return `has-${kebabCase(colorSlug)}-${colorContextName}`;
[25256] Fix | Delete
}
[25257] Fix | Delete
[25258] Fix | Delete
/**
[25259] Fix | Delete
* Given an array of color objects and a color value returns the color value of the most readable color in the array.
[25260] Fix | Delete
*
[25261] Fix | Delete
* @param {Array} colors Array of color objects as set by the theme or by the editor defaults.
[25262] Fix | Delete
* @param {?string} colorValue A string containing the color value.
[25263] Fix | Delete
*
[25264] Fix | Delete
* @return {string} String with the color value of the most readable color.
[25265] Fix | Delete
*/
[25266] Fix | Delete
function getMostReadableColor(colors, colorValue) {
[25267] Fix | Delete
const colordColor = w(colorValue);
[25268] Fix | Delete
const getColorContrast = ({
[25269] Fix | Delete
color
[25270] Fix | Delete
}) => colordColor.contrast(color);
[25271] Fix | Delete
const maxContrast = Math.max(...colors.map(getColorContrast));
[25272] Fix | Delete
return colors.find(color => getColorContrast(color) === maxContrast).color;
[25273] Fix | Delete
}
[25274] Fix | Delete
[25275] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/colors-gradients/use-multiple-origin-colors-and-gradients.js
[25276] Fix | Delete
/**
[25277] Fix | Delete
* WordPress dependencies
[25278] Fix | Delete
*/
[25279] Fix | Delete
[25280] Fix | Delete
[25281] Fix | Delete
[25282] Fix | Delete
/**
[25283] Fix | Delete
* Internal dependencies
[25284] Fix | Delete
*/
[25285] Fix | Delete
[25286] Fix | Delete
[25287] Fix | Delete
/**
[25288] Fix | Delete
* Retrieves color and gradient related settings.
[25289] Fix | Delete
*
[25290] Fix | Delete
* The arrays for colors and gradients are made up of color palettes from each
[25291] Fix | Delete
* origin i.e. "Core", "Theme", and "User".
[25292] Fix | Delete
*
[25293] Fix | Delete
* @return {Object} Color and gradient related settings.
[25294] Fix | Delete
*/
[25295] Fix | Delete
function useMultipleOriginColorsAndGradients() {
[25296] Fix | Delete
const [enableCustomColors, customColors, themeColors, defaultColors, shouldDisplayDefaultColors, enableCustomGradients, customGradients, themeGradients, defaultGradients, shouldDisplayDefaultGradients] = use_settings_useSettings('color.custom', 'color.palette.custom', 'color.palette.theme', 'color.palette.default', 'color.defaultPalette', 'color.customGradient', 'color.gradients.custom', 'color.gradients.theme', 'color.gradients.default', 'color.defaultGradients');
[25297] Fix | Delete
const colorGradientSettings = {
[25298] Fix | Delete
disableCustomColors: !enableCustomColors,
[25299] Fix | Delete
disableCustomGradients: !enableCustomGradients
[25300] Fix | Delete
};
[25301] Fix | Delete
colorGradientSettings.colors = (0,external_wp_element_namespaceObject.useMemo)(() => {
[25302] Fix | Delete
const result = [];
[25303] Fix | Delete
if (themeColors && themeColors.length) {
[25304] Fix | Delete
result.push({
[25305] Fix | Delete
name: (0,external_wp_i18n_namespaceObject._x)('Theme', 'Indicates this palette comes from the theme.'),
[25306] Fix | Delete
colors: themeColors
[25307] Fix | Delete
});
[25308] Fix | Delete
}
[25309] Fix | Delete
if (shouldDisplayDefaultColors && defaultColors && defaultColors.length) {
[25310] Fix | Delete
result.push({
[25311] Fix | Delete
name: (0,external_wp_i18n_namespaceObject._x)('Default', 'Indicates this palette comes from WordPress.'),
[25312] Fix | Delete
colors: defaultColors
[25313] Fix | Delete
});
[25314] Fix | Delete
}
[25315] Fix | Delete
if (customColors && customColors.length) {
[25316] Fix | Delete
result.push({
[25317] Fix | Delete
name: (0,external_wp_i18n_namespaceObject._x)('Custom', 'Indicates this palette comes from the theme.'),
[25318] Fix | Delete
colors: customColors
[25319] Fix | Delete
});
[25320] Fix | Delete
}
[25321] Fix | Delete
return result;
[25322] Fix | Delete
}, [customColors, themeColors, defaultColors, shouldDisplayDefaultColors]);
[25323] Fix | Delete
colorGradientSettings.gradients = (0,external_wp_element_namespaceObject.useMemo)(() => {
[25324] Fix | Delete
const result = [];
[25325] Fix | Delete
if (themeGradients && themeGradients.length) {
[25326] Fix | Delete
result.push({
[25327] Fix | Delete
name: (0,external_wp_i18n_namespaceObject._x)('Theme', 'Indicates this palette comes from the theme.'),
[25328] Fix | Delete
gradients: themeGradients
[25329] Fix | Delete
});
[25330] Fix | Delete
}
[25331] Fix | Delete
if (shouldDisplayDefaultGradients && defaultGradients && defaultGradients.length) {
[25332] Fix | Delete
result.push({
[25333] Fix | Delete
name: (0,external_wp_i18n_namespaceObject._x)('Default', 'Indicates this palette comes from WordPress.'),
[25334] Fix | Delete
gradients: defaultGradients
[25335] Fix | Delete
});
[25336] Fix | Delete
}
[25337] Fix | Delete
if (customGradients && customGradients.length) {
[25338] Fix | Delete
result.push({
[25339] Fix | Delete
name: (0,external_wp_i18n_namespaceObject._x)('Custom', 'Indicates this palette is created by the user.'),
[25340] Fix | Delete
gradients: customGradients
[25341] Fix | Delete
});
[25342] Fix | Delete
}
[25343] Fix | Delete
return result;
[25344] Fix | Delete
}, [customGradients, themeGradients, defaultGradients, shouldDisplayDefaultGradients]);
[25345] Fix | Delete
colorGradientSettings.hasColorsOrGradients = !!colorGradientSettings.colors.length || !!colorGradientSettings.gradients.length;
[25346] Fix | Delete
return colorGradientSettings;
[25347] Fix | Delete
}
[25348] Fix | Delete
[25349] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/border-radius-control/utils.js
[25350] Fix | Delete
/**
[25351] Fix | Delete
* WordPress dependencies
[25352] Fix | Delete
*/
[25353] Fix | Delete
[25354] Fix | Delete
[25355] Fix | Delete
/**
[25356] Fix | Delete
* Gets the (non-undefined) item with the highest occurrence within an array
[25357] Fix | Delete
* Based in part on: https://stackoverflow.com/a/20762713
[25358] Fix | Delete
*
[25359] Fix | Delete
* Undefined values are always sorted to the end by `sort`, so this function
[25360] Fix | Delete
* returns the first element, to always prioritize real values over undefined
[25361] Fix | Delete
* values.
[25362] Fix | Delete
*
[25363] Fix | Delete
* See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#description
[25364] Fix | Delete
*
[25365] Fix | Delete
* @param {Array<any>} inputArray Array of items to check.
[25366] Fix | Delete
* @return {any} The item with the most occurrences.
[25367] Fix | Delete
*/
[25368] Fix | Delete
function utils_mode(inputArray) {
[25369] Fix | Delete
const arr = [...inputArray];
[25370] Fix | Delete
return arr.sort((a, b) => inputArray.filter(v => v === b).length - inputArray.filter(v => v === a).length).shift();
[25371] Fix | Delete
}
[25372] Fix | Delete
[25373] Fix | Delete
/**
[25374] Fix | Delete
* Returns the most common CSS unit from the current CSS unit selections.
[25375] Fix | Delete
*
[25376] Fix | Delete
* - If a single flat border radius is set, its unit will be used
[25377] Fix | Delete
* - If individual corner selections, the most common of those will be used
[25378] Fix | Delete
* - Failing any unit selections a default of 'px' is returned.
[25379] Fix | Delete
*
[25380] Fix | Delete
* @param {Object} selectedUnits Unit selections for flat radius & each corner.
[25381] Fix | Delete
* @return {string} Most common CSS unit from current selections. Default: `px`.
[25382] Fix | Delete
*/
[25383] Fix | Delete
function getAllUnit(selectedUnits = {}) {
[25384] Fix | Delete
const {
[25385] Fix | Delete
flat,
[25386] Fix | Delete
...cornerUnits
[25387] Fix | Delete
} = selectedUnits;
[25388] Fix | Delete
return flat || utils_mode(Object.values(cornerUnits).filter(Boolean)) || 'px';
[25389] Fix | Delete
}
[25390] Fix | Delete
[25391] Fix | Delete
/**
[25392] Fix | Delete
* Gets the 'all' input value and unit from values data.
[25393] Fix | Delete
*
[25394] Fix | Delete
* @param {Object|string} values Radius values.
[25395] Fix | Delete
* @return {string} A value + unit for the 'all' input.
[25396] Fix | Delete
*/
[25397] Fix | Delete
function getAllValue(values = {}) {
[25398] Fix | Delete
/**
[25399] Fix | Delete
* Border radius support was originally a single pixel value.
[25400] Fix | Delete
*
[25401] Fix | Delete
* To maintain backwards compatibility treat this case as the all value.
[25402] Fix | Delete
*/
[25403] Fix | Delete
if (typeof values === 'string') {
[25404] Fix | Delete
return values;
[25405] Fix | Delete
}
[25406] Fix | Delete
const parsedQuantitiesAndUnits = Object.values(values).map(value => (0,external_wp_components_namespaceObject.__experimentalParseQuantityAndUnitFromRawValue)(value));
[25407] Fix | Delete
const allValues = parsedQuantitiesAndUnits.map(value => {
[25408] Fix | Delete
var _value$;
[25409] Fix | Delete
return (_value$ = value[0]) !== null && _value$ !== void 0 ? _value$ : '';
[25410] Fix | Delete
});
[25411] Fix | Delete
const allUnits = parsedQuantitiesAndUnits.map(value => value[1]);
[25412] Fix | Delete
const value = allValues.every(v => v === allValues[0]) ? allValues[0] : '';
[25413] Fix | Delete
const unit = utils_mode(allUnits);
[25414] Fix | Delete
const allValue = value === 0 || value ? `${value}${unit}` : undefined;
[25415] Fix | Delete
return allValue;
[25416] Fix | Delete
}
[25417] Fix | Delete
[25418] Fix | Delete
/**
[25419] Fix | Delete
* Checks to determine if values are mixed.
[25420] Fix | Delete
*
[25421] Fix | Delete
* @param {Object} values Radius values.
[25422] Fix | Delete
* @return {boolean} Whether values are mixed.
[25423] Fix | Delete
*/
[25424] Fix | Delete
function hasMixedValues(values = {}) {
[25425] Fix | Delete
const allValue = getAllValue(values);
[25426] Fix | Delete
const isMixed = typeof values === 'string' ? false : isNaN(parseFloat(allValue));
[25427] Fix | Delete
return isMixed;
[25428] Fix | Delete
}
[25429] Fix | Delete
[25430] Fix | Delete
/**
[25431] Fix | Delete
* Checks to determine if values are defined.
[25432] Fix | Delete
*
[25433] Fix | Delete
* @param {Object} values Radius values.
[25434] Fix | Delete
* @return {boolean} Whether values are mixed.
[25435] Fix | Delete
*/
[25436] Fix | Delete
function hasDefinedValues(values) {
[25437] Fix | Delete
if (!values) {
[25438] Fix | Delete
return false;
[25439] Fix | Delete
}
[25440] Fix | Delete
[25441] Fix | Delete
// A string value represents a shorthand value.
[25442] Fix | Delete
if (typeof values === 'string') {
[25443] Fix | Delete
return true;
[25444] Fix | Delete
}
[25445] Fix | Delete
[25446] Fix | Delete
// An object represents longhand border radius values, if any are set
[25447] Fix | Delete
// flag values as being defined.
[25448] Fix | Delete
const filteredValues = Object.values(values).filter(value => {
[25449] Fix | Delete
return !!value || value === 0;
[25450] Fix | Delete
});
[25451] Fix | Delete
return !!filteredValues.length;
[25452] Fix | Delete
}
[25453] Fix | Delete
[25454] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/border-radius-control/all-input-control.js
[25455] Fix | Delete
/**
[25456] Fix | Delete
* WordPress dependencies
[25457] Fix | Delete
*/
[25458] Fix | Delete
[25459] Fix | Delete
[25460] Fix | Delete
[25461] Fix | Delete
/**
[25462] Fix | Delete
* Internal dependencies
[25463] Fix | Delete
*/
[25464] Fix | Delete
[25465] Fix | Delete
[25466] Fix | Delete
function AllInputControl({
[25467] Fix | Delete
onChange,
[25468] Fix | Delete
selectedUnits,
[25469] Fix | Delete
setSelectedUnits,
[25470] Fix | Delete
values,
[25471] Fix | Delete
...props
[25472] Fix | Delete
}) {
[25473] Fix | Delete
let allValue = getAllValue(values);
[25474] Fix | Delete
if (allValue === undefined) {
[25475] Fix | Delete
// If we don't have any value set the unit to any current selection
[25476] Fix | Delete
// or the most common unit from the individual radii values.
[25477] Fix | Delete
allValue = getAllUnit(selectedUnits);
[25478] Fix | Delete
}
[25479] Fix | Delete
const hasValues = hasDefinedValues(values);
[25480] Fix | Delete
const isMixed = hasValues && hasMixedValues(values);
[25481] Fix | Delete
const allPlaceholder = isMixed ? (0,external_wp_i18n_namespaceObject.__)('Mixed') : null;
[25482] Fix | Delete
[25483] Fix | Delete
// Filter out CSS-unit-only values to prevent invalid styles.
[25484] Fix | Delete
const handleOnChange = next => {
[25485] Fix | Delete
const isNumeric = !isNaN(parseFloat(next));
[25486] Fix | Delete
const nextValue = isNumeric ? next : undefined;
[25487] Fix | Delete
onChange(nextValue);
[25488] Fix | Delete
};
[25489] Fix | Delete
[25490] Fix | Delete
// Store current unit selection for use as fallback for individual
[25491] Fix | Delete
// radii controls.
[25492] Fix | Delete
const handleOnUnitChange = unit => {
[25493] Fix | Delete
setSelectedUnits({
[25494] Fix | Delete
topLeft: unit,
[25495] Fix | Delete
topRight: unit,
[25496] Fix | Delete
bottomLeft: unit,
[25497] Fix | Delete
bottomRight: unit
[25498] Fix | Delete
});
[25499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function