← All changes
|
assets/js/packages/editor-props/editor-props.min.js
+3
-1
4.2.0-dev2
→
trunk
View file →
| @@ -1 +1,3 @@ | ||
| 1 | -!function(){"use strict";var e={15304:function(e,r,t){var a=e.exports.Validator=t(96482);e.exports.ValidatorResult=t(46677).ValidatorResult,e.exports.ValidatorResultError=t(46677).ValidatorResultError,e.exports.ValidationError=t(46677).ValidationError,e.exports.SchemaError=t(46677).SchemaError,e.exports.SchemaScanResult=t(49911).SchemaScanResult,e.exports.scan=t(49911).scan,e.exports.validate=function(e,r,t){return(new a).validate(e,r,t)}},16164:function(e,r,t){var a,i=Object.defineProperty,n=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,s=Object.prototype.hasOwnProperty,c={};((e,r)=>{for(var t in r)i(e,t,{get:r[t],enumerable:!0})})(c,{CLASSES_PROP_KEY:()=>b,DateTimePropTypeUtil:()=>de,Schema:()=>nr,backdropFilterPropTypeUtil:()=>Le,backgroundColorOverlayPropTypeUtil:()=>te,backgroundGradientOverlayPropTypeUtil:()=>ae,backgroundImageOverlayPropTypeUtil:()=>ie,backgroundImagePositionOffsetPropTypeUtil:()=>se,backgroundImageSizeScalePropTypeUtil:()=>ce,backgroundOverlayItem:()=>ne,backgroundOverlayPropTypeUtil:()=>oe,backgroundPropTypeUtil:()=>ee,blurFilterPropTypeUtil:()=>Oe,booleanPropTypeUtil:()=>le,borderRadiusPropTypeUtil:()=>y,borderWidthPropTypeUtil:()=>v,boxShadowPropTypeUtil:()=>h,classesPropTypeUtil:()=>A,colorPropTypeUtil:()=>z,colorStopPropTypeUtil:()=>ue,colorToneFilterPropTypeUtil:()=>xe,createArrayPropUtils:()=>createArrayPropUtils,createPropUtils:()=>createPropUtils,cssFilterFunctionPropUtil:()=>Ue,dateRangePropTypeUtil:()=>Ke,dateStringPropTypeUtil:()=>We,dimensionsPropTypeUtil:()=>Z,dropShadowFilterPropTypeUtil:()=>Se,emailPropTypeUtil:()=>H,emailsPropTypeUtil:()=>G,evaluateTerm:()=>evaluateTerm,extractValue:()=>extractValue,filterEmptyValues:()=>filterEmptyValues,filterPropTypeUtil:()=>Ee,flexPropTypeUtil:()=>P,fontFamilyPropTypeUtil:()=>w,getPropSchemaFromCache:()=>getPropSchemaFromCache,gradientColorStopPropTypeUtil:()=>pe,gridTrackSizePropTypeUtil:()=>q,htmlPropTypeUtil:()=>ge,htmlV2PropTypeUtil:()=>ze,htmlV3PropTypeUtil:()=>Fe,hueRotateFilterPropTypeUtil:()=>$e,imageAttachmentIdPropType:()=>O,imagePropTypeUtil:()=>S,imageSrcPropTypeUtil:()=>$,intensityFilterPropTypeUtil:()=>je,isDependency:()=>isDependency,isDependencyMet:()=>isDependencyMet,isEmpty:()=>isEmpty,isOverridable:()=>isOverridable,isTransformable:()=>isTransformable,keyValuePropTypeUtil:()=>X,layoutDirectionPropTypeUtil:()=>W,linkPropTypeUtil:()=>B,mergeProps:()=>mergeProps,moveTransformPropTypeUtil:()=>Ve,numberPropTypeUtil:()=>_,numberRangePropTypeUtil:()=>me,parseHtmlChildren:()=>parseHtmlChildren,perspectiveOriginPropTypeUtil:()=>Je,positionPropTypeUtil:()=>fe,queryFilterArrayPropTypeUtil:()=>ve,queryFilterPropTypeUtil:()=>ye,queryPropTypeUtil:()=>he,rewrapOverridableValue:()=>rewrapOverridableValue,rotateTransformPropTypeUtil:()=>Re,scaleTransformPropTypeUtil:()=>Ce,selectionSizePropTypeUtil:()=>Q,shadowPropTypeUtil:()=>f,sizePropTypeUtil:()=>R,skewTransformPropTypeUtil:()=>qe,spanPropTypeUtil:()=>N,stringArrayPropTypeUtil:()=>I,stringPropTypeUtil:()=>D,strokePropTypeUtil:()=>J,svgSrcPropTypeUtil:()=>U,timeRangePropTypeUtil:()=>Be,timeStringPropTypeUtil:()=>He,transformFunctionsPropTypeUtil:()=>De,transformOriginPropTypeUtil:()=>Ie,transformPropTypeUtil:()=>Te,urlPropTypeUtil:()=>L,videoAttachmentIdPropType:()=>E,videoSrcPropTypeUtil:()=>k}),e.exports=(a=c,((e,r,t,a)=>{if(r&&"object"==typeof r||"function"==typeof r)for(let c of o(r))s.call(e,c)||c===t||i(e,c,{get:()=>r[c],enumerable:!(a=n(r,c))||a.enumerable});return e})(i({},"__esModule",{value:!0}),a));var l=t(59618),u=t(59618),p=new Map;function getPropSchemaFromCache(e){return p.get(e)}function createPropUtils(e,r){const t=u.z.strictObject({$$type:u.z.literal(e),value:r,disabled:u.z.boolean().optional()});function isValid(e){return t.safeParse(e).success}const a={extract:function extract(e){return isValid(e)?e.value:null},isValid:isValid,create:function create(r,t){const a="function"==typeof r?r:()=>r,{base:i,disabled:n}=t||{};if(!i)return{$$type:e,value:a(),...n&&{disabled:n}};if(!isValid(i))throw new Error(`Cannot create prop based on invalid value: ${JSON.stringify(i)}`);return{$$type:e,value:a(i.value),...n&&{disabled:n}}},schema:t,key:e};return p.set(e,a),a}function createArrayPropUtils(e,r,t){return createPropUtils(t||`${e}-array`,u.z.array(r))}var m=t(59618),d=t(59618).z.any().nullable(),f=createPropUtils("shadow",m.z.strictObject({position:d,hOffset:d,vOffset:d,blur:d,spread:d,color:d})),h=createPropUtils("box-shadow",l.z.array(f.schema)),y=createPropUtils("border-radius",t(59618).z.strictObject({"start-start":d,"start-end":d,"end-start":d,"end-end":d})),v=createPropUtils("border-width",t(59618).z.strictObject({"block-start":d,"block-end":d,"inline-start":d,"inline-end":d})),g=t(59618),b="classes",A=createPropUtils(b,g.z.array(g.z.string().regex(/^[a-z][a-z-_0-9]*$/i))),z=createPropUtils("color",t(59618).z.string()),P=createPropUtils("flex",t(59618).z.strictObject({flexGrow:d,flexShrink:d,flexBasis:d})),F=createPropUtils("font-family",t(59618).z.string().nullable()),w=Object.assign(F,{getEnqueueFontFamily:e=>{const r=e.trim();return r.startsWith('"')&&r.endsWith('"')||r.startsWith("'")&&r.endsWith("'")?r.slice(1,-1).trim():r}}),S=createPropUtils("image",t(59618).z.strictObject({src:d,size:d})),O=createPropUtils("image-attachment-id",t(59618).z.number()),x=t(59618),$=createPropUtils("image-src",x.z.strictObject({id:d,url:x.z.null(),alt:d.optional().default(null)}).or(x.z.strictObject({id:d.optional().default(null),url:d,alt:d.optional().default(null)}))),j=t(59618),U=createPropUtils("svg-src",j.z.strictObject({id:d,url:j.z.null()}).or(j.z.strictObject({id:j.z.null(),url:d})).or(j.z.strictObject({id:d,url:d}))),E=createPropUtils("video-attachment-id",t(59618).z.number()),T=t(59618),k=createPropUtils("video-src",T.z.strictObject({id:d,url:T.z.null()}).or(T.z.strictObject({id:T.z.null(),url:d}))),Z=createPropUtils("dimensions",t(59618).z.strictObject({"block-start":d,"block-end":d,"inline-start":d,"inline-end":d})),_=createPropUtils("number",t(59618).z.number().nullable()),M=t(59618),V=M.z.union([M.z.number(),M.z.literal("")]),R=createPropUtils("size",M.z.strictObject({unit:M.z.enum(["px","em","rem","%","vw","vh","ch","fr"]),size:V}).or(M.z.strictObject({unit:M.z.enum(["deg","rad","grad","turn"]),size:V})).or(M.z.strictObject({unit:M.z.enum(["s","ms"]),size:V})).or(M.z.strictObject({unit:M.z.literal("auto"),size:M.z.literal("")})).or(M.z.strictObject({unit:M.z.literal("custom"),size:M.z.string()}))),C=t(59618),q=createPropUtils("grid-track-size",C.z.strictObject({unit:C.z.literal("fr"),size:C.z.union([C.z.number(),C.z.literal("")])}).or(C.z.strictObject({unit:C.z.literal("custom"),size:C.z.string()}))),N=createPropUtils("span",t(59618).z.string().nullable()),D=createPropUtils("string",t(59618).z.string().nullable()),I=createArrayPropUtils(D.key,D.schema),J=createPropUtils("stroke",t(59618).z.strictObject({color:d,width:d})),L=createPropUtils("url",t(59618).z.string().nullable()),K=t(59618),W=createPropUtils("layout-direction",K.z.object({row:K.z.any(),column:K.z.any()})),B=createPropUtils("link",t(59618).z.strictObject({destination:d,isTargetBlank:d,tag:d})),H=createPropUtils("email",t(59618).z.strictObject({to:d,subject:d,message:d,from:d,"meta-data":d,"send-as":d,"from-name":d,"reply-to":d,cc:d,bcc:d})),G=createPropUtils("emails",t(59618).z.strictObject({to:d,subject:d,message:d,from:d,"meta-data":d,"send-as":d,"from-name":d,"reply-to":d,cc:d,bcc:d})),Y=t(59618),X=createPropUtils("key-value",t(59618).z.strictObject({key:d,value:d})),Q=createPropUtils("selection-size",Y.z.strictObject({selection:Y.z.union([X.schema,D.schema]),size:d})),ee=createPropUtils("background",t(59618).z.strictObject({color:d,clip:d,"background-overlay":d})),re=t(59618),te=createPropUtils("background-color-overlay",d),ae=createPropUtils("background-gradient-overlay",d),ie=createPropUtils("background-image-overlay",d),ne=te.schema.or(ae.schema).or(ie.schema),oe=createPropUtils("background-overlay",re.z.array(ne)),se=createPropUtils("background-image-position-offset",d),ce=createPropUtils("background-image-size-scale",d),le=createPropUtils("boolean",t(59618).z.boolean().nullable()),ue=createPropUtils("color-stop",t(59618).z.strictObject({color:d,offset:d})),pe=createPropUtils("gradient-color-stop",t(59618).z.array(ue.schema)),me=createPropUtils("number-range",t(59618).z.strictObject({min:d,max:d})),de=createPropUtils("date-time",t(59618).z.strictObject({date:d,time:d})),fe=createPropUtils("object-position",t(59618).z.strictObject({x:d,y:d})),he=createPropUtils("query",t(59618).z.strictObject({id:d,label:d})),ye=createPropUtils("query-filter",t(59618).z.strictObject({key:d,values:d,taxonomies:d})),ve=createArrayPropUtils(ye.key,ye.schema),ge=createPropUtils("html",t(59618).z.string().nullable()),be=t(59618),Ae=be.z.lazy(()=>be.z.object({id:be.z.string(),type:be.z.string(),content:be.z.string().optional(),children:be.z.array(Ae).optional()})),ze=createPropUtils("html-v2",be.z.object({content:be.z.string().nullable(),children:be.z.array(Ae)})),Pe=t(59618),Fe=createPropUtils("html-v3",Pe.z.object({content:D.schema.nullable(),children:Pe.z.array(Pe.z.unknown())})),we=t(59618),Se=createPropUtils("drop-shadow",t(59618).z.object({xAxis:d,yAxis:d,blur:d,color:d})),Oe=createPropUtils("blur",t(59618).z.strictObject({size:d})),xe=createPropUtils("color-tone",t(59618).z.strictObject({size:d})),$e=createPropUtils("hue-rotate",t(59618).z.strictObject({size:d})),je=createPropUtils("intensity",t(59618).z.strictObject({size:d})),Ue=createPropUtils("css-filter-func",we.z.object({func:D.schema,args:we.z.union([Oe.schema,je.schema,xe.schema,$e.schema,Se.schema])})),Ee=createPropUtils("filter",we.z.array(Ue.schema)),Te=createPropUtils("transform",t(59618).z.strictObject({"transform-functions":d,"transform-origin":d,perspective:d,"perspective-origin":d})),ke=t(59618),Ze="transform-scale",_e="transform-rotate",Me="transform-skew",Ve=createPropUtils("transform-move",t(59618).z.strictObject({x:d,y:d,z:d})),Re=createPropUtils(_e,t(59618).z.strictObject({x:d,y:d,z:d})),Ce=createPropUtils(Ze,t(59618).z.strictObject({x:_.schema.nullable(),y:_.schema.nullable(),z:_.schema.nullable()})),qe=createPropUtils(Me,t(59618).z.strictObject({x:d,y:d})),Ne=Ve.schema.or(Ce.schema).or(Re.schema).or(qe.schema),De=createPropUtils("transform-functions",ke.z.array(Ne)),Ie=createPropUtils("transform-origin",t(59618).z.strictObject({x:d,y:d,z:d})),Je=createPropUtils("perspective-origin",t(59618).z.strictObject({x:d,y:d})),Le=createPropUtils("backdrop-filter",t(59618).z.array(Ue.schema)),Ke=createPropUtils("date-range",t(59618).z.strictObject({min:d,max:d})),We=createPropUtils("date-string",t(59618).z.string()),Be=createPropUtils("time-range",t(59618).z.strictObject({min:d,max:d})),He=createPropUtils("time-string",t(59618).z.string()),ensureNotNull=(e,r)=>null===e?r:e,Ge={transformers:{}},adjustLlmPropValueSchema=(e,{transformers:r={},forceKey:t}=Ge)=>{const a=structuredClone(e);if("object"!=typeof a||null===a)return null;if(Array.isArray(a))return a.map(e=>adjustLlmPropValueSchema(e,{forceKey:t,transformers:r}));const i=a;switch("$intention"in i&&delete i.$intention,t&&(i.$$type=t),i.$$type){case"size":{const{value:e}=i;return{$$type:"size",value:{unit:"string"==typeof e.unit?e.unit:ensureNotNull(D.extract(e.unit),"px"),size:"string"==typeof e.size||"number"==typeof e.size?e.size:ensureNotNull(D.extract(e.size),_.extract(e.size))}}}case"html-v3":{const{value:e}=i;return{$$type:"html-v3",value:{...e,children:Array.isArray(e.children)?e.children:[]}}}default:const e=r?.[i.$$type];if(e)return e(i.value)}if("object"==typeof i.value)if(Array.isArray(i.value))i.value=adjustLlmPropValueSchema(i.value,{transformers:r});else{const{value:e}=i,t=a;t.value={},Object.entries(e).forEach(([e,a])=>{t.value[e]=adjustLlmPropValueSchema(a,{transformers:r})})}return a};function jsonSchemaToPropType(e,r=e.key){const t={};return e.description&&(t.description=e.description),e.anyOf&&Array.isArray(e.anyOf)?function convertJsonSchemaToUnionPropType(e,r){const t={};if(!e.anyOf||!Array.isArray(e.anyOf))throw new Error("Invalid anyOf schema");for(const r of e.anyOf)if("object"===r.type&&r.properties&&r.properties.$$type&&r.properties.value){const e=r.properties.$$type;let a;if(!(e.enum&&Array.isArray(e.enum)&&e.enum.length>0))continue;a=e.enum[0];const i=convertJsonSchemaToPropType(r.properties.value);t[a]=i}return{kind:"union",prop_types:t,settings:{},meta:r}}(e,t):"object"===e.type&&e.properties?function convertJsonSchemaToObjectPropType(e,r,t=e.key){const a={};if(!e.properties)return{kind:"object",key:t,shape:{},settings:{},meta:r};const i=Array.isArray(e.required)?e.required:[];for(const[r,n]of Object.entries(e.properties)){const e=convertJsonSchemaToPropType(n,t);i.includes(r)&&(e.settings={...e.settings,required:!0}),a[r]=e}return{kind:"object",key:t||"object",shape:a,settings:{},meta:r}}(e,t,r):"array"===e.type&&e.items?function convertJsonSchemaToArrayPropType(e,r,t=e.key){if(!e.items)throw new Error("Array schema must have items property");const a=convertJsonSchemaToPropType(e.items);return{kind:"array",key:t||"array",item_prop_type:a,settings:{},meta:r}}(e,t,r):function convertJsonSchemaToPlainPropType(e,r,t=e.key){const a={};let i=t||"string";"number"===e.type?i="number":"boolean"===e.type?i="boolean":"string"===e.type&&(i="string");Array.isArray(e.enum)&&(a.enum=e.enum);return{kind:"plain",key:i,settings:a,meta:r}}(e,t,r)}function convertJsonSchemaToPropType(e,r){return jsonSchemaToPropType(e,r)}var Ye="dynamic",Xe="overridable",Qe=null;function propTypeToJsonSchema(e,r=!1){const t=e.meta?.description,a={};switch(t&&(a.description=t),null!==e.initial_value&&void 0!==e.initial_value&&(a.examples=[e.initial_value]),e.kind){case"union":return function convertUnionPropType(e,r,t){const a=structuredClone(r),i=e.prop_types||{},n=!t&&Boolean(i[Ye]),o=t||n,s=[];for(const[e,r]of Object.entries(i))e!==Xe&&(e!==Ye?s.push(propTypeToJsonSchema(r,o)):n&&s.push(convertDynamicPropType(r)));s.length>0&&(a.anyOf=s);const c=e.meta?.description;c&&(a.description=c);return a}(e,a,r);case"object":return function convertObjectPropType(e,r,t){const a=structuredClone(r);a.type="object";const i={properties:{$$type:{type:"string",const:e.key},value:{type:"object",properties:{},additionalProperties:!1}}},n=["$$type","value"],o=[],s=e.shape||{};for(const[e,r]of Object.entries(s)){const a=propTypeToJsonSchema(r,t);!0===r.settings?.required&&o.push(e),i.properties.value.properties&&(i.properties.value.properties[e]=a)}a.required=n,o.length>0&&(i.properties.value.required=o);return{...a,...i}}(e,a,r);case"array":return function convertArrayPropType(e,r,t){const a=structuredClone(r);let i;a.type="object";const n=e.item_prop_type;n&&(i=propTypeToJsonSchema(n,t));return a.properties={$$type:{type:"string",const:e.key},value:{type:"array",...i?{items:i}:{}}},a}(e,a,r);default:return function convertPlainPropType(e,r){const t={...r};if(!Object.hasOwn(e,"kind"))throw new Error(`PropType kind is undefined for propType with key: ${e.key??"[unknown key]"}`);const a=e.settings?.enum||[];switch(e.kind){case"string":case"number":case"boolean":return{...t,type:"object",properties:{$$type:{type:"string",const:e.key??e.kind},value:{type:e.kind,...a.length>0?{enum:a}:{}}},required:["$$type","value"]};case"unknown":return{};default:return{...t,type:"object",$$type:e.kind,value:{type:e.kind}}}}(e,a)}}function convertDynamicPropType(e){const r=Array.isArray(e.settings?.categories)?e.settings.categories:[],t=Qe?.(r)??[];return{type:"object",description:'Bind THIS value to a dynamic tag instead of a static value (this may be a nested field, e.g. an image\'s "src"). Look up the chosen tag in the "elementor://dynamic-tags" resource and populate "settings" exactly as its schema requires.',properties:{$$type:{type:"string",const:Ye},value:{type:"object",properties:{name:{type:"string",description:'Dynamic tag name from "elementor://dynamic-tags".',...t.length?{enum:t}:{}},settings:{type:"object",description:"Tag settings matching the chosen tag's schema in the resource."}},required:["name"]}},required:["$$type","value"]}}var er=["_cssid","classes","attributes"];function isPropKeyConfigurable(e,r){return!er.includes(e)||!(Array.isArray(r?.meta)||!r?.meta?.llm_configurable)}var rr=t(15304);function processValidationError(e){const r={path:e.path,message:e.message,schema:e.schema,instance:e.instance,name:e.name};if("anyOf"===e.name&&e.schema&&"object"==typeof e.schema&&"anyOf"in e.schema){const t=(e.schema.anyOf||[]).map((r,t)=>{const a=(0,rr.validate)(e.instance,r);let i=`variant-${t}`;if(r&&"object"==typeof r&&"properties"in r&&r.properties&&"object"==typeof r.properties&&"$$type"in r.properties){const e=r.properties.$$type;e&&"object"==typeof e&&"const"in e&&"string"==typeof e.const&&(i=e.const)}return{discriminator:i,errors:a.errors.map(processValidationError)}});r.variants=t}return r}function formatDetailedErrors(e,r=""){const t=[];for(const a of e){const e=a.path.length>0?a.path.join("."):"root";if(t.push(`${r}Error at ${e}: ${a.message}`),a.variants&&a.variants.length>0){t.push(`${r} Tried ${a.variants.length} variant(s):`);for(const e of a.variants)if(t.push(`${r} - ${e.discriminator}:`),0===e.errors.length)t.push(`${r} (no errors - this variant matched!)`);else for(const a of e.errors){const e=a.path.length>0?a.path.join("."):"root";t.push(`${r} ${e}: ${a.message}`),a.variants&&a.variants.length>0&&t.push(formatDetailedErrors([a],`${r} `))}}}return t.join("\n")}var tr=t(59618),ar=tr.z.object({$$type:tr.z.string(),value:tr.z.any(),disabled:tr.z.boolean().optional()}),isTransformable=e=>ar.safeParse(e).success,filterEmptyValues=e=>isEmpty(e)?null:Array.isArray(e)?e.map(filterEmptyValues).filter(e=>!isEmpty(e)):"object"==typeof e?Object.fromEntries(Object.entries(e).map(([e,r])=>[e,filterEmptyValues(r)]).filter(([,e])=>!isEmpty(e))):e,isEmpty=e=>e&&isTransformable(e)?isEmpty(e.value):isNullish(e)||isNullishArray(e)||isNullishObject(e),isNullish=e=>null==e||""===e,isNullishArray=e=>Array.isArray(e)&&e.every(isEmpty),isNullishObject=e=>"object"==typeof e&&isNullishArray(Object.values(e));function isOverridable(e){return isTransformable(e)&&"overridable"===e.$$type}function rewrapOverridableValue(e,r){return{...e,value:{...e.value,origin_value:r}}}function mergeProps(e,r){let t={};return Array.isArray(e)||(t=structuredClone(e)),Object.entries(r).forEach(([e,r])=>{null==r?delete t[e]:t[e]=r}),t}function isDependencyMet(e,r){if(!e?.terms.length)return{isMet:!0};const{relation:t,terms:a}=e,i=function getRelationMethod(e){switch(e){case"or":return"some";case"and":return"every";default:throw new Error(`Relation not supported ${e}`)}}(t),n=[];return{isMet:a[i](e=>{const t=isDependency(e)?isDependencyMet(e,r).isMet:evaluateTerm(e,extractValue(e.path,r,e.nestedPath)?.value);return t||n.push(e),t}),failingDependencies:n}}function evaluateTerm(e,r){const{value:t,operator:a}=e;switch(a){case"eq":case"ne":return r===t==("eq"===a);case"gt":case"lte":return!(!isNumber(r)||!isNumber(t))&&Number(r)>Number(t)==("gt"===a);case"lt":case"gte":return!(!isNumber(r)||!isNumber(t))&&Number(r)<Number(t)==("lt"===a);case"in":case"nin":return!!Array.isArray(t)&&t.includes(r)===("in"===a);case"contains":case"ncontains":if(("string"!=typeof r||"string"!=typeof t)&&!Array.isArray(r))return!1;return"contains"===a===(Array.isArray(r)?r.map(e=>isTransformable(e)?e.value:e):r).includes(t);case"exists":case"not_exist":return"exists"===a===(!!r||0===r||!1===r);default:return!0}}function isNumber(e){return"number"==typeof e&&!isNaN(e)}function extractValue(e,r,t=[],a={}){const{unwrapOverridableLeaf:i=!0}=a;let n=e.reduce((r,t,a)=>{const i=r?.[t];if(a===e.length-1)return i;if(isOverridable(i)){const e=i.value.origin_value;return isTransformable(e)?e.value??null:e}return isTransformable(i)?i.value??null:i},r);if(i&&n&&isOverridable(n)&&(n=n.value.origin_value??null),!t?.length)return n;return{$$type:"unknown",value:t.reduce((e,r)=>e?.[r],n?.value)}}function isDependency(e){return"terms"in e}var ir=new Set(["span","b","strong","i","em","u","a","del","sup","sub","s"]);function generateElementId(){return`e-${Date.now().toString(36)}-${Math.random().toString(36).substring(2,9)}`}function traverseChildren(e){const r=[];for(const t of Array.from(e.children)){const e=t.tagName.toLowerCase();if(!ir.has(e)){r.push(...traverseChildren(t));continue}let a=t.getAttribute("id");a||(a=generateElementId(),t.setAttribute("id",a));const i={id:a,type:e},n=t.textContent?.trim();n&&(i.content=n);const o=traverseChildren(t);o.length>0&&(i.children=o),r.push(i)}return r}function parseHtmlChildren(e){if(!e)return{content:e,children:[]};const r=(new DOMParser).parseFromString(`<body>${e}</body>`,"text/html"),t=r.querySelector("parsererror");if(t)return console.warn("HTML parsing error, returning original content:",t.textContent),{content:e,children:[]};const a=r.body,i=traverseChildren(a);return{content:a.innerHTML,children:i}}var nr={jsonSchemaToPropType:jsonSchemaToPropType,propTypeToJsonSchema:propTypeToJsonSchema,adjustLlmPropValueSchema:adjustLlmPropValueSchema,isPropKeyConfigurable:isPropKeyConfigurable,nonConfigurablePropKeys:er,configurableKeys:function configurableKeys(e){return Object.keys(e).filter(r=>isPropKeyConfigurable(r,e[r]))},validatePropValue:(e,r)=>{const t=propTypeToJsonSchema(e);if(null===r)return{valid:!0,errors:[],errorMessages:[],jsonSchema:JSON.stringify(propTypeToJsonSchema(e))};const a=(0,rr.validate)(r,t),i=a.errors.map(processValidationError);return{valid:a.valid,errors:a.errors,errorMessages:formatDetailedErrors(i),jsonSchema:JSON.stringify(t)}},enrichWithIntention:function enrichWithIntention(e,r="Describe the desired outcome"){const t=structuredClone(e);return t.properties?(t.properties.$intention={type:"string",description:r},t.required=[...t.required||[],"$intention"],t):e},removeIntention:function removeIntention(e){const r=structuredClone(e);return r.properties?(delete r.properties.$intention,r.required&&(r.required=r.required.filter(e=>"$intention"!==e)),r):e},setDynamicTagNamesResolver:function setDynamicTagNamesResolver(e){Qe=e}}},46677:function(e,r){var t=r.ValidationError=function ValidationError(e,r,t,a,i,n){if(Array.isArray(a)?(this.path=a,this.property=a.reduce(function(e,r){return e+s(r)},"instance")):void 0!==a&&(this.property=a),e&&(this.message=e),t){var o=t.$id||t.id;this.schema=o||t}void 0!==r&&(this.instance=r),this.name=i,this.argument=n,this.stack=this.toString()};t.prototype.toString=function toString(){return this.property+" "+this.message};var a=r.ValidatorResult=function ValidatorResult(e,r,t,a){this.instance=e,this.schema=r,this.options=t,this.path=a.path,this.propertyPath=a.propertyPath,this.errors=[],this.throwError=t&&t.throwError,this.throwFirst=t&&t.throwFirst,this.throwAll=t&&t.throwAll,this.disableFormat=t&&!0===t.disableFormat};function stringizer(e,r){return r+": "+e.toString()+"\n"}function ValidatorResultError(e){"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(this,ValidatorResultError),this.instance=e.instance,this.schema=e.schema,this.options=e.options,this.errors=e.errors}a.prototype.addError=function addError(e){var r;if("string"==typeof e)r=new t(e,this.instance,this.schema,this.path);else{if(!e)throw new Error("Missing error detail");if(!e.message)throw new Error("Missing error message");if(!e.name)throw new Error("Missing validator type");r=new t(e.message,this.instance,this.schema,this.path,e.name,e.argument)}if(this.errors.push(r),this.throwFirst)throw new ValidatorResultError(this);if(this.throwError)throw r;return r},a.prototype.importErrors=function importErrors(e){"string"==typeof e||e&&e.validatorType?this.addError(e):e&&e.errors&&(this.errors=this.errors.concat(e.errors))},a.prototype.toString=function toString(e){return this.errors.map(stringizer).join("")},Object.defineProperty(a.prototype,"valid",{get:function(){return!this.errors.length}}),e.exports.ValidatorResultError=ValidatorResultError,ValidatorResultError.prototype=new Error,ValidatorResultError.prototype.constructor=ValidatorResultError,ValidatorResultError.prototype.name="Validation Error";var i=r.SchemaError=function SchemaError(e,r){this.message=e,this.schema=r,Error.call(this,e),"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(this,SchemaError)};i.prototype=Object.create(Error.prototype,{constructor:{value:i,enumerable:!1},name:{value:"SchemaError",enumerable:!1}});var n=r.SchemaContext=function SchemaContext(e,r,t,a,i){this.schema=e,this.options=r,Array.isArray(t)?(this.path=t,this.propertyPath=t.reduce(function(e,r){return e+s(r)},"instance")):this.propertyPath=t,this.base=a,this.schemas=i};n.prototype.resolve=function resolve(e){return(()=>c(this.base,e))()},n.prototype.makeChild=function makeChild(e,r){var t=void 0===r?this.path:this.path.concat([r]),a=e.$id||e.id;let i=(()=>c(this.base,a||""))();var o=new n(e,this.options,t,i,Object.create(this.schemas));return a&&!o.schemas[i]&&(o.schemas[i]=e),o};var o=r.FORMAT_REGEXPS={"date-time":/^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-(3[01]|0[1-9]|[12][0-9])[tT ](2[0-4]|[01][0-9]):([0-5][0-9]):(60|[0-5][0-9])(\.\d+)?([zZ]|[+-]([0-5][0-9]):(60|[0-5][0-9]))$/,date:/^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-(3[01]|0[1-9]|[12][0-9])$/,time:/^(2[0-4]|[01][0-9]):([0-5][0-9]):(60|[0-5][0-9])$/,duration:/P(T\d+(H(\d+M(\d+S)?)?|M(\d+S)?|S)|\d+(D|M(\d+D)?|Y(\d+M(\d+D)?)?)(T\d+(H(\d+M(\d+S)?)?|M(\d+S)?|S))?|\d+W)/i,email:/^(?:[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9](?:[a-zA-Z0-9\-](?!\.)){0,61}[a-zA-Z0-9]?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9\-](?!$)){0,61}[a-zA-Z0-9]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/,"idn-email":/^("(?:[!#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|[.0-:A-Fa-f]+)\])?:\d*|\[(([Vv][0-9A-Fa-f]+\.[!$&-.0-;=A-Z_a-z~-\u{10FFFF}]+)?|[.0-:A-Fa-f]+)\])?)?|[A-Za-z][+\-.0-9A-Za-z]*:?)?$/u,uuid:/^[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}$/i,"uri-template":/(%[0-9a-f]{2}|[!#$&(-;=?@\[\]_a-z~]|\{[!#&+,./;=?@|]?(%[0-9a-f]{2}|[0-9_a-z])(\.?(%[0-9a-f]{2}|[0-9_a-z]))*(:[1-9]\d{0,3}|\*)?(,(%[0-9a-f]{2}|[0-9_a-z])(\.?(%[0-9a-f]{2}|[0-9_a-z]))*(:[1-9]\d{0,3}|\*)?)*\})*/iu,"json-pointer":/^(\/([\x00-\x2e0-@\[-}\x7f]|~[01])*)*$/iu,"relative-json-pointer":/^\d+(#|(\/([\x00-\x2e0-@\[-}\x7f]|~[01])*)*)$/iu,hostname:/^(?=.{1,255}$)[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?(?:\.[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?)*\.?$/,"host-name":/^(?=.{1,255}$)[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?(?:\.[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?)*\.?$/,"utc-millisec":function(e){return"string"==typeof e&&parseFloat(e)===parseInt(e,10)&&!isNaN(e)},regex:function(e){var r=!0;try{new RegExp(e)}catch(e){r=!1}return r},style:/[\r\n\t ]*[^\r\n\t ][^:]*:[\r\n\t ]*[^\r\n\t ;]*[\r\n\t ]*;?/,color:/^(#?([0-9A-Fa-f]{3}){1,2}\b|aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow|(rgb\(\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*\))|(rgb\(\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*\)))$/,phone:/^\+(?:[0-9] ?){6,14}[0-9]$/,alpha:/^[a-zA-Z]+$/,alphanumeric:/^[a-zA-Z0-9]+$/};o.regexp=o.regex,o.pattern=o.regex,o.ipv4=o["ip-address"],r.isFormat=function isFormat(e,r,t){if("string"==typeof e&&void 0!==o[r]){if(o[r]instanceof RegExp)return o[r].test(e);if("function"==typeof o[r])return o[r](e)}else if(t&&t.customFormats&&"function"==typeof t.customFormats[r])return t.customFormats[r](e);return!0};var s=r.makeSuffix=function makeSuffix(e){return(e=e.toString()).match(/[.\s\[\]]/)||e.match(/^[\d]/)?e.match(/^\d+$/)?"["+e+"]":"["+JSON.stringify(e)+"]":"."+e};function deepMerger(e,r,t,a){"object"==typeof t?r[a]=deepMerge(e[a],t):-1===e.indexOf(t)&&r.push(t)}function copyist(e,r,t){r[t]=e[t]}function copyistWithDeepMerge(e,r,t,a){"object"==typeof r[a]&&r[a]&&e[a]?t[a]=deepMerge(e[a],r[a]):t[a]=r[a]}function deepMerge(e,r){var t=Array.isArray(r),a=t&&[]||{};return t?(e=e||[],a=a.concat(e),r.forEach(deepMerger.bind(null,e,a))):(e&&"object"==typeof e&&Object.keys(e).forEach(copyist.bind(null,e,a)),Object.keys(r).forEach(copyistWithDeepMerge.bind(null,e,r,a))),a}function pathEncoder(e){return"/"+encodeURIComponent(e).replace(/~/g,"%7E")}r.deepCompareStrict=function deepCompareStrict(e,r){if(typeof e!=typeof r)return!1;if(Array.isArray(e))return!!Array.isArray(r)&&(e.length===r.length&&e.every(function(t,a){return deepCompareStrict(e[a],r[a])}));if("object"==typeof e){if(!e||!r)return e===r;var t=Object.keys(e),a=Object.keys(r);return t.length===a.length&&t.every(function(t){return deepCompareStrict(e[t],r[t])})}return e===r},e.exports.deepMerge=deepMerge,r.objectGetPath=function objectGetPath(e,r){for(var t,a=r.split("/").slice(1);"string"==typeof(t=a.shift());){var i=decodeURIComponent(t.replace(/~0/,"~").replace(/~1/g,"/"));if(!(i in e))return;e=e[i]}return e},r.encodePath=function encodePointer(e){return e.map(pathEncoder).join("")},r.getDecimalPlaces=function getDecimalPlaces(e){var r=0;if(isNaN(e))return r;"number"!=typeof e&&(e=Number(e));var t=e.toString().split("e");if(2===t.length){if("-"!==t[1][0])return r;r=Number(t[1].slice(1))}var a=t[0].split(".");return 2===a.length&&(r+=a[1].length),r},r.isSchema=function isSchema(e){return"object"==typeof e&&e||"boolean"==typeof e};var c=r.resolveUrl=function resolveUrl(e,r){const t=new URL(r,new URL(e,"resolve://"));if("resolve:"===t.protocol){const{pathname:e,search:r,hash:a}=t;return e+r+a}return t.toString()}},49911:function(e,r,t){var a=t(46677);function SchemaScanResult(e,r){this.id=e,this.ref=r}e.exports.SchemaScanResult=SchemaScanResult,e.exports.scan=function scan(e,r){function scanSchema(e,r){if(!r||"object"!=typeof r)return;if(r.$ref){let t=a.resolveUrl(e,r.$ref);return void(i[t]=i[t]?i[t]+1:0)}var n=r.$id||r.id;let o=a.resolveUrl(e,n);var s=n?o:e;if(s){if(s.indexOf("#")<0&&(s+="#"),t[s]){if(!a.deepCompareStrict(t[s],r))throw new Error("Schema <"+s+"> already exists with different definition");return t[s]}t[s]=r,"#"==s[s.length-1]&&(t[s.substring(0,s.length-1)]=r)}scanArray(s+"/items",Array.isArray(r.items)?r.items:[r.items]),scanArray(s+"/extends",Array.isArray(r.extends)?r.extends:[r.extends]),scanSchema(s+"/additionalItems",r.additionalItems),scanObject(s+"/properties",r.properties),scanSchema(s+"/additionalProperties",r.additionalProperties),scanObject(s+"/definitions",r.definitions),scanObject(s+"/patternProperties",r.patternProperties),scanObject(s+"/dependencies",r.dependencies),scanArray(s+"/disallow",r.disallow),scanArray(s+"/allOf",r.allOf),scanArray(s+"/anyOf",r.anyOf),scanArray(s+"/oneOf",r.oneOf),scanSchema(s+"/not",r.not)}function scanArray(e,r){if(Array.isArray(r))for(var t=0;t<r.length;t++)scanSchema(e+"/"+t,r[t])}function scanObject(e,r){if(r&&"object"==typeof r)for(var t in r)scanSchema(e+"/"+t,r[t])}var t={},i={};return scanSchema(e,r),new SchemaScanResult(t,i)}},55140:function(e,r,t){var a=t(46677),i=a.ValidatorResult,n=a.SchemaError,o={ignoreProperties:{id:!0,default:!0,description:!0,title:!0,additionalItems:!0,then:!0,else:!0,$schema:!0,$ref:!0,extends:!0}},s=o.validators={};function testSchemaNoThrow(e,r,t,a,i){var n=r.throwError,o=r.throwAll;r.throwError=!1,r.throwAll=!1;var s=this.validateSchema(e,i,r,t);return r.throwError=n,r.throwAll=o,!s.valid&&a instanceof Function&&a(s),s.valid}function getEnumerableProperty(e,r){if(Object.hasOwnProperty.call(e,r))return e[r];if(r in e)for(;e=Object.getPrototypeOf(e);)if(Object.propertyIsEnumerable.call(e,r))return e[r]}function testAdditionalProperty(e,r,t,a,i,n){if(this.types.object(e)&&(!r.properties||void 0===r.properties[i]))if(!1===r.additionalProperties)n.addError({name:"additionalProperties",argument:i,message:"is not allowed to have the additional property "+JSON.stringify(i)});else{var o=r.additionalProperties||{};"function"==typeof t.preValidateProperty&&t.preValidateProperty(e,i,o,t,a);var s=this.validateSchema(e[i],o,t,a.makeChild(o,i));s.instance!==n.instance[i]&&(n.instance[i]=s.instance),n.importErrors(s)}}s.type=function validateType(e,r,t,a){if(void 0===e)return null;var n=new i(e,r,t,a),o=Array.isArray(r.type)?r.type:[r.type];if(!o.some(this.testType.bind(this,e,r,t,a))){var s=o.map(function(e){if(e){var r=e.$id||e.id;return r?"<"+r+">":e+""}});n.addError({name:"type",argument:s,message:"is not of a type(s) "+s})}return n},s.anyOf=function validateAnyOf(e,r,t,a){if(void 0===e)return null;var o=new i(e,r,t,a),s=new i(e,r,t,a);if(!Array.isArray(r.anyOf))throw new n("anyOf must be an array");if(!r.anyOf.some(testSchemaNoThrow.bind(this,e,t,a,function(e){s.importErrors(e)}))){var c=r.anyOf.map(function(e,r){var t=e.$id||e.id;return t?"<"+t+">":e.title&&JSON.stringify(e.title)||e.$ref&&"<"+e.$ref+">"||"[subschema "+r+"]"});t.nestedErrors&&o.importErrors(s),o.addError({name:"anyOf",argument:c,message:"is not any of "+c.join(",")})}return o},s.allOf=function validateAllOf(e,r,t,a){if(void 0===e)return null;if(!Array.isArray(r.allOf))throw new n("allOf must be an array");var o=new i(e,r,t,a),s=this;return r.allOf.forEach(function(r,i){var n=s.validateSchema(e,r,t,a);if(!n.valid){var c=r.$id||r.id||r.title&&JSON.stringify(r.title)||r.$ref&&"<"+r.$ref+">"||"[subschema "+i+"]";o.addError({name:"allOf",argument:{id:c,length:n.errors.length,valid:n},message:"does not match allOf schema "+c+" with "+n.errors.length+" error[s]:"}),o.importErrors(n)}}),o},s.oneOf=function validateOneOf(e,r,t,a){if(void 0===e)return null;if(!Array.isArray(r.oneOf))throw new n("oneOf must be an array");var o=new i(e,r,t,a),s=new i(e,r,t,a),c=r.oneOf.filter(testSchemaNoThrow.bind(this,e,t,a,function(e){s.importErrors(e)})).length,l=r.oneOf.map(function(e,r){return e.$id||e.id||e.title&&JSON.stringify(e.title)||e.$ref&&"<"+e.$ref+">"||"[subschema "+r+"]"});return 1!==c&&(t.nestedErrors&&o.importErrors(s),o.addError({name:"oneOf",argument:l,message:"is not exactly one from "+l.join(",")})),o},s.if=function validateIf(e,r,t,n){if(void 0===e)return null;if(!a.isSchema(r.if))throw new Error('Expected "if" keyword to be a schema');var o,s=testSchemaNoThrow.call(this,e,t,n,null,r.if),c=new i(e,r,t,n);if(s){if(void 0===r.then)return;if(!a.isSchema(r.then))throw new Error('Expected "then" keyword to be a schema');o=this.validateSchema(e,r.then,t,n.makeChild(r.then)),c.importErrors(o)}else{if(void 0===r.else)return;if(!a.isSchema(r.else))throw new Error('Expected "else" keyword to be a schema');o=this.validateSchema(e,r.else,t,n.makeChild(r.else)),c.importErrors(o)}return c},s.propertyNames=function validatePropertyNames(e,r,t,o){if(this.types.object(e)){var s=new i(e,r,t,o),c=void 0!==r.propertyNames?r.propertyNames:{};if(!a.isSchema(c))throw new n('Expected "propertyNames" to be a schema (object or boolean)');for(var l in e)if(void 0!==getEnumerableProperty(e,l)){var u=this.validateSchema(l,c,t,o.makeChild(c));s.importErrors(u)}return s}},s.properties=function validateProperties(e,r,t,a){if(this.types.object(e)){var o=new i(e,r,t,a),s=r.properties||{};for(var c in s){var l=s[c];if(void 0!==l){if(null===l)throw new n('Unexpected null, expected schema in "properties"');"function"==typeof t.preValidateProperty&&t.preValidateProperty(e,c,l,t,a);var u=getEnumerableProperty(e,c),p=this.validateSchema(u,l,t,a.makeChild(l,c));p.instance!==o.instance[c]&&(o.instance[c]=p.instance),o.importErrors(p)}}return o}},s.patternProperties=function validatePatternProperties(e,r,t,a){if(this.types.object(e)){var o=new i(e,r,t,a),s=r.patternProperties||{};for(var c in e){var l=!0;for(var u in s){var p=s[u];if(void 0!==p){if(null===p)throw new n('Unexpected null, expected schema in "patternProperties"');try{var m=new RegExp(u,"u")}catch(e){m=new RegExp(u)}if(m.test(c)){l=!1,"function"==typeof t.preValidateProperty&&t.preValidateProperty(e,c,p,t,a);var d=this.validateSchema(e[c],p,t,a.makeChild(p,c));d.instance!==o.instance[c]&&(o.instance[c]=d.instance),o.importErrors(d)}}}l&&testAdditionalProperty.call(this,e,r,t,a,c,o)}return o}},s.additionalProperties=function validateAdditionalProperties(e,r,t,a){if(this.types.object(e)){if(r.patternProperties)return null;var n=new i(e,r,t,a);for(var o in e)testAdditionalProperty.call(this,e,r,t,a,o,n);return n}},s.minProperties=function validateMinProperties(e,r,t,a){if(this.types.object(e)){var n=new i(e,r,t,a);return Object.keys(e).length>=r.minProperties||n.addError({name:"minProperties",argument:r.minProperties,message:"does not meet minimum property length of "+r.minProperties}),n}},s.maxProperties=function validateMaxProperties(e,r,t,a){if(this.types.object(e)){var n=new i(e,r,t,a);return Object.keys(e).length<=r.maxProperties||n.addError({name:"maxProperties",argument:r.maxProperties,message:"does not meet maximum property length of "+r.maxProperties}),n}},s.items=function validateItems(e,r,t,a){var n=this;if(this.types.array(e)&&void 0!==r.items){var o=new i(e,r,t,a);return e.every(function(e,i){if(Array.isArray(r.items))var s=void 0===r.items[i]?r.additionalItems:r.items[i];else s=r.items;if(void 0===s)return!0;if(!1===s)return o.addError({name:"items",message:"additionalItems not permitted"}),!1;var c=n.validateSchema(e,s,t,a.makeChild(s,i));return c.instance!==o.instance[i]&&(o.instance[i]=c.instance),o.importErrors(c),!0}),o}},s.contains=function validateContains(e,r,t,n){var o=this;if(this.types.array(e)&&void 0!==r.contains){if(!a.isSchema(r.contains))throw new Error('Expected "contains" keyword to be a schema');var s=new i(e,r,t,n);return!1===e.some(function(e,a){return 0===o.validateSchema(e,r.contains,t,n.makeChild(r.contains,a)).errors.length})&&s.addError({name:"contains",argument:r.contains,message:"must contain an item matching given schema"}),s}},s.minimum=function validateMinimum(e,r,t,a){if(this.types.number(e)){var n=new i(e,r,t,a);return r.exclusiveMinimum&&!0===r.exclusiveMinimum?e>r.minimum||n.addError({name:"minimum",argument:r.minimum,message:"must be greater than "+r.minimum}):e>=r.minimum||n.addError({name:"minimum",argument:r.minimum,message:"must be greater than or equal to "+r.minimum}),n}},s.maximum=function validateMaximum(e,r,t,a){if(this.types.number(e)){var n=new i(e,r,t,a);return r.exclusiveMaximum&&!0===r.exclusiveMaximum?e<r.maximum||n.addError({name:"maximum",argument:r.maximum,message:"must be less than "+r.maximum}):e<=r.maximum||n.addError({name:"maximum",argument:r.maximum,message:"must be less than or equal to "+r.maximum}),n}},s.exclusiveMinimum=function validateExclusiveMinimum(e,r,t,a){if("boolean"!=typeof r.exclusiveMinimum&&this.types.number(e)){var n=new i(e,r,t,a);return e>r.exclusiveMinimum||n.addError({name:"exclusiveMinimum",argument:r.exclusiveMinimum,message:"must be strictly greater than "+r.exclusiveMinimum}),n}},s.exclusiveMaximum=function validateExclusiveMaximum(e,r,t,a){if("boolean"!=typeof r.exclusiveMaximum&&this.types.number(e)){var n=new i(e,r,t,a);return e<r.exclusiveMaximum||n.addError({name:"exclusiveMaximum",argument:r.exclusiveMaximum,message:"must be strictly less than "+r.exclusiveMaximum}),n}};var c=function validateMultipleOfOrDivisbleBy(e,r,t,o,s,c){if(this.types.number(e)){var l=r[s];if(0==l)throw new n(s+" cannot be zero");var u=new i(e,r,t,o),p=a.getDecimalPlaces(e),m=a.getDecimalPlaces(l),d=Math.max(p,m),f=Math.pow(10,d);return Math.round(e*f)%Math.round(l*f)!==0&&u.addError({name:s,argument:l,message:c+JSON.stringify(l)}),u}};function testArrays(e,r,t){var i,n=t.length;for(i=r+1;i<n;i++)if(a.deepCompareStrict(e,t[i]))return!1;return!0}s.multipleOf=function validateMultipleOf(e,r,t,a){return c.call(this,e,r,t,a,"multipleOf","is not a multiple of (divisible by) ")},s.divisibleBy=function validateDivisibleBy(e,r,t,a){return c.call(this,e,r,t,a,"divisibleBy","is not divisible by (multiple of) ")},s.required=function validateRequired(e,r,t,a){var n=new i(e,r,t,a);return void 0===e&&!0===r.required?n.addError({name:"required",message:"is required"}):this.types.object(e)&&Array.isArray(r.required)&&r.required.forEach(function(r){void 0===getEnumerableProperty(e,r)&&n.addError({name:"required",argument:r,message:"requires property "+JSON.stringify(r)})}),n},s.pattern=function validatePattern(e,r,t,a){if(this.types.string(e)){var n=new i(e,r,t,a),o=r.pattern;try{var s=new RegExp(o,"u")}catch(e){s=new RegExp(o)}return e.match(s)||n.addError({name:"pattern",argument:r.pattern,message:"does not match pattern "+JSON.stringify(r.pattern.toString())}),n}},s.format=function validateFormat(e,r,t,n){if(void 0!==e){var o=new i(e,r,t,n);return o.disableFormat||a.isFormat(e,r.format,this)||o.addError({name:"format",argument:r.format,message:"does not conform to the "+JSON.stringify(r.format)+" format"}),o}},s.minLength=function validateMinLength(e,r,t,a){if(this.types.string(e)){var n=new i(e,r,t,a),o=e.match(/[\uDC00-\uDFFF]/g);return e.length-(o?o.length:0)>=r.minLength||n.addError({name:"minLength",argument:r.minLength,message:"does not meet minimum length of "+r.minLength}),n}},s.maxLength=function validateMaxLength(e,r,t,a){if(this.types.string(e)){var n=new i(e,r,t,a),o=e.match(/[\uDC00-\uDFFF]/g);return e.length-(o?o.length:0)<=r.maxLength||n.addError({name:"maxLength",argument:r.maxLength,message:"does not meet maximum length of "+r.maxLength}),n}},s.minItems=function validateMinItems(e,r,t,a){if(this.types.array(e)){var n=new i(e,r,t,a);return e.length>=r.minItems||n.addError({name:"minItems",argument:r.minItems,message:"does not meet minimum length of "+r.minItems}),n}},s.maxItems=function validateMaxItems(e,r,t,a){if(this.types.array(e)){var n=new i(e,r,t,a);return e.length<=r.maxItems||n.addError({name:"maxItems",argument:r.maxItems,message:"does not meet maximum length of "+r.maxItems}),n}},s.uniqueItems=function validateUniqueItems(e,r,t,a){if(!0===r.uniqueItems&&this.types.array(e)){var n=new i(e,r,t,a);return e.every(testArrays)||n.addError({name:"uniqueItems",message:"contains duplicate item"}),n}},s.dependencies=function validateDependencies(e,r,t,a){if(this.types.object(e)){var n=new i(e,r,t,a);for(var o in r.dependencies)if(void 0!==e[o]){var s=r.dependencies[o],c=a.makeChild(s,o);if("string"==typeof s&&(s=[s]),Array.isArray(s))s.forEach(function(r){void 0===e[r]&&n.addError({name:"dependencies",argument:c.propertyPath,message:"property "+r+" not found, required by "+c.propertyPath})});else{var l=this.validateSchema(e,s,t,c);n.instance!==l.instance&&(n.instance=l.instance),l&&l.errors.length&&(n.addError({name:"dependencies",argument:c.propertyPath,message:"does not meet dependency required by "+c.propertyPath}),n.importErrors(l))}}return n}},s.enum=function validateEnum(e,r,t,o){if(void 0===e)return null;if(!Array.isArray(r.enum))throw new n("enum expects an array",r);var s=new i(e,r,t,o);return r.enum.some(a.deepCompareStrict.bind(null,e))||s.addError({name:"enum",argument:r.enum,message:"is not one of enum values: "+r.enum.map(String).join(",")}),s},s.const=function validateEnum(e,r,t,n){if(void 0===e)return null;var o=new i(e,r,t,n);return a.deepCompareStrict(r.const,e)||o.addError({name:"const",argument:r.const,message:"does not exactly match expected constant: "+r.const}),o},s.not=s.disallow=function validateNot(e,r,t,a){var n=this;if(void 0===e)return null;var o=new i(e,r,t,a),s=r.not||r.disallow;return s?(Array.isArray(s)||(s=[s]),s.forEach(function(i){if(n.testType(e,r,t,a,i)){var s=i&&(i.$id||i.id)||i;o.addError({name:"not",argument:s,message:"is of prohibited type "+s})}}),o):null},e.exports=o},59618:function(e){e.exports=window.elementorV2.schema},96482:function(e,r,t){var a=t(55140),i=t(46677),n=t(49911).scan,o=i.ValidatorResult,s=i.ValidatorResultError,c=i.SchemaError,l=i.SchemaContext,u=function Validator(){this.customFormats=Object.create(Validator.prototype.customFormats),this.schemas={},this.unresolvedRefs=[],this.types=Object.create(p),this.attributes=Object.create(a.validators)};function shouldResolve(e){var r="string"==typeof e?e:e.$ref;return"string"==typeof r&&r}u.prototype.customFormats={},u.prototype.schemas=null,u.prototype.types=null,u.prototype.attributes=null,u.prototype.unresolvedRefs=null,u.prototype.addSchema=function addSchema(e,r){var t=this;if(!e)return null;var a=n(r||"/",e),i=r||e.$id||e.id;for(var o in a.id)this.schemas[o]=a.id[o];for(var o in a.ref)this.unresolvedRefs.push(o);return this.unresolvedRefs=this.unresolvedRefs.filter(function(e){return void 0===t.schemas[e]}),this.schemas[i]},u.prototype.addSubSchemaArray=function addSubSchemaArray(e,r){if(Array.isArray(r))for(var t=0;t<r.length;t++)this.addSubSchema(e,r[t])},u.prototype.addSubSchemaObject=function addSubSchemaArray(e,r){if(r&&"object"==typeof r)for(var t in r)this.addSubSchema(e,r[t])},u.prototype.setSchemas=function setSchemas(e){this.schemas=e},u.prototype.getSchema=function getSchema(e){return this.schemas[e]},u.prototype.validate=function validate(e,r,t,a){if("boolean"!=typeof r&&"object"!=typeof r||null===r)throw new c("Expected `schema` to be an object or boolean");t||(t={});var u=r.$id||r.id;let p=i.resolveUrl(t.base,u||"");if(!a){(a=new l(r,t,[],p,Object.create(this.schemas))).schemas[p]||(a.schemas[p]=r);var m=n(p,r);for(var d in m.id){var f=m.id[d];a.schemas[d]=f}}var h;if(t.required&&void 0===e)return(h=new o(e,r,t,a)).addError("is required, but is undefined"),h;if(!(h=this.validateSchema(e,r,t,a)))throw new Error("Result undefined");if(t.throwAll&&h.errors.length)throw new s(h);return h},u.prototype.validateSchema=function validateSchema(e,r,t,n){var s=new o(e,r,t,n);if("boolean"==typeof r)!0===r?r={}:!1===r&&(r={type:[]});else if(!r)throw new Error("schema is undefined");if(r.extends)if(Array.isArray(r.extends)){var u={schema:r,ctx:n};r.extends.forEach(this.schemaTraverser.bind(this,u)),r=u.schema,u.schema=null,u.ctx=null,u=null}else r=i.deepMerge(r,this.superResolve(r.extends,n));var p=shouldResolve(r);if(p){var m=this.resolve(r,p,n),d=new l(m.subschema,t,n.path,m.switchSchema,n.schemas);return this.validateSchema(e,m.subschema,t,d)}var f=t&&t.skipAttributes||[];for(var h in r)if(!a.ignoreProperties[h]&&f.indexOf(h)<0){var y=null,v=this.attributes[h];if(v)y=v.call(this,e,r,t,n);else if(!1===t.allowUnknownAttributes)throw new c("Unsupported attribute: "+h,r);y&&s.importErrors(y)}if("function"==typeof t.rewrite){var g=t.rewrite.call(this,e,r,t,n);s.instance=g}return s},u.prototype.schemaTraverser=function schemaTraverser(e,r){e.schema=i.deepMerge(e.schema,this.superResolve(r,e.ctx))},u.prototype.superResolve=function superResolve(e,r){var t=shouldResolve(e);return t?this.resolve(e,t,r).subschema:e},u.prototype.resolve=function resolve(e,r,t){if(r=t.resolve(r),t.schemas[r])return{subschema:t.schemas[r],switchSchema:r};let a=new URL(r,"thismessage::/").hash;var n=a&&a.length&&r.substr(0,r.length-a.length);if(!n||!t.schemas[n])throw new c("no such schema <"+r+">",e);var o=i.objectGetPath(t.schemas[n],a.substr(1));if(void 0===o)throw new c("no such schema "+a+" located in <"+n+">",e);return{subschema:o,switchSchema:r}},u.prototype.testType=function validateType(e,r,t,a,i){if(void 0!==i){if(null===i)throw new c('Unexpected null in "type" keyword');if("function"==typeof this.types[i])return this.types[i].call(this,e);if(i&&"object"==typeof i){var n=this.validateSchema(e,i,t,a);return void 0===n||!(n&&n.errors.length)}return!0}};var p=u.prototype.types={};p.string=function testString(e){return"string"==typeof e},p.number=function testNumber(e){return"number"==typeof e&&isFinite(e)},p.integer=function testInteger(e){return"number"==typeof e&&e%1==0},p.boolean=function testBoolean(e){return"boolean"==typeof e},p.array=function testArray(e){return Array.isArray(e)},p.null=function testNull(e){return null===e},p.date=function testDate(e){return e instanceof Date},p.any=function testAny(e){return!0},p.object=function testObject(e){return e&&"object"==typeof e&&!Array.isArray(e)&&!(e instanceof Date)},e.exports=u}},r={};var t=function __webpack_require__(t){var a=r[t];if(void 0!==a)return a.exports;var i=r[t]={exports:{}};return e[t](i,i.exports,__webpack_require__),i.exports}(16164);(window.elementorV2=window.elementorV2||{}).editorProps=t}(),window.elementorV2.editorProps?.init?.(); | |
| 1 | +(function(){var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,__commonJSMin=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),__copyProps=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},__toESM=(n,r,a)=>(a=n==null?{}:e(i(n)),__copyProps(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n)),o=__commonJSMin(((e,t)=>{var n=e.ValidationError=function ValidationError(e,t,n,r,i,a){if(Array.isArray(r)?(this.path=r,this.property=r.reduce(function(e,t){return e+s(t)},`instance`)):r!==void 0&&(this.property=r),e&&(this.message=e),n){var o=n.$id||n.id;this.schema=o||n}t!==void 0&&(this.instance=t),this.name=i,this.argument=a,this.stack=this.toString()};n.prototype.toString=function toString(){return this.property+` `+this.message};var r=e.ValidatorResult=function ValidatorResult(e,t,n,r){this.instance=e,this.schema=t,this.options=n,this.path=r.path,this.propertyPath=r.propertyPath,this.errors=[],this.throwError=n&&n.throwError,this.throwFirst=n&&n.throwFirst,this.throwAll=n&&n.throwAll,this.disableFormat=n&&n.disableFormat===!0};r.prototype.addError=function addError(e){var t;if(typeof e==`string`)t=new n(e,this.instance,this.schema,this.path);else{if(!e)throw Error(`Missing error detail`);if(!e.message)throw Error(`Missing error message`);if(!e.name)throw Error(`Missing validator type`);t=new n(e.message,this.instance,this.schema,this.path,e.name,e.argument)}if(this.errors.push(t),this.throwFirst)throw new ValidatorResultError(this);if(this.throwError)throw t;return t},r.prototype.importErrors=function importErrors(e){typeof e==`string`||e&&e.validatorType?this.addError(e):e&&e.errors&&(this.errors=this.errors.concat(e.errors))};function stringizer(e,t){return t+`: `+e.toString()+` | |
| 2 | +`}r.prototype.toString=function toString(e){return this.errors.map(stringizer).join(``)},Object.defineProperty(r.prototype,"valid",{get:function(){return!this.errors.length}}),t.exports.ValidatorResultError=ValidatorResultError;function ValidatorResultError(e){typeof Error.captureStackTrace==`function`&&Error.captureStackTrace(this,ValidatorResultError),this.instance=e.instance,this.schema=e.schema,this.options=e.options,this.errors=e.errors}ValidatorResultError.prototype=Error(),ValidatorResultError.prototype.constructor=ValidatorResultError,ValidatorResultError.prototype.name=`Validation Error`;var i=e.SchemaError=function SchemaError(e,t){this.message=e,this.schema=t,Error.call(this,e),typeof Error.captureStackTrace==`function`&&Error.captureStackTrace(this,SchemaError)};i.prototype=Object.create(Error.prototype,{constructor:{value:i,enumerable:!1},name:{value:`SchemaError`,enumerable:!1}});var a=e.SchemaContext=function SchemaContext(e,t,n,r,i){this.schema=e,this.options=t,Array.isArray(n)?(this.path=n,this.propertyPath=n.reduce(function(e,t){return e+s(t)},`instance`)):this.propertyPath=n,this.base=r,this.schemas=i};a.prototype.resolve=function resolve(e){return c(this.base,e)},a.prototype.makeChild=function makeChild(e,t){var n=t===void 0?this.path:this.path.concat([t]),r=e.$id||e.id;let i=c(this.base,r||``);var o=new a(e,this.options,n,i,Object.create(this.schemas));return r&&!o.schemas[i]&&(o.schemas[i]=e),o};var o=e.FORMAT_REGEXPS={"date-time":/^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-(3[01]|0[1-9]|[12][0-9])[tT ](2[0-4]|[01][0-9]):([0-5][0-9]):(60|[0-5][0-9])(\.\d+)?([zZ]|[+-]([0-5][0-9]):(60|[0-5][0-9]))$/,date:/^\d{4}-(?:0[0-9]{1}|1[0-2]{1})-(3[01]|0[1-9]|[12][0-9])$/,time:/^(2[0-4]|[01][0-9]):([0-5][0-9]):(60|[0-5][0-9])$/,duration:/P(T\d+(H(\d+M(\d+S)?)?|M(\d+S)?|S)|\d+(D|M(\d+D)?|Y(\d+M(\d+D)?)?)(T\d+(H(\d+M(\d+S)?)?|M(\d+S)?|S))?|\d+W)/i,email:/^(?:[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+\.)*[\w\!\#\$\%\&\'\*\+\-\/\=\?\^\`\{\|\}\~]+@(?:(?:(?:[a-zA-Z0-9](?:[a-zA-Z0-9\-](?!\.)){0,61}[a-zA-Z0-9]?\.)+[a-zA-Z0-9](?:[a-zA-Z0-9\-](?!$)){0,61}[a-zA-Z0-9]?)|(?:\[(?:(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d{1,2}|2[0-4]\d|25[0-5])\]))$/,"idn-email":/^("(?:[!#-\[\]-\u{10FFFF}]|\\[\t -\u{10FFFF}])*"|[!#-'*+\-/-9=?A-Z\^-\u{10FFFF}](?:\.?[!#-'*+\-/-9=?A-Z\^-\u{10FFFF}])*)@([!#-'*+\-/-9=?A-Z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:?)?$/u,uuid:/^[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}$/i,"uri-template":/(%[0-9a-f]{2}|[!#$&(-;=?@\[\]_a-z~]|\{[!#&+,./;=?@|]?(%[0-9a-f]{2}|[0-9_a-z])(\.?(%[0-9a-f]{2}|[0-9_a-z]))*(:[1-9]\d{0,3}|\*)?(,(%[0-9a-f]{2}|[0-9_a-z])(\.?(%[0-9a-f]{2}|[0-9_a-z]))*(:[1-9]\d{0,3}|\*)?)*\})*/iu,"json-pointer":/^(\/([\x00-\x2e0-@\[-}\x7f]|~[01])*)*$/iu,"relative-json-pointer":/^\d+(#|(\/([\x00-\x2e0-@\[-}\x7f]|~[01])*)*)$/iu,hostname:/^(?=.{1,255}$)[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?(?:\.[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?)*\.?$/,"host-name":/^(?=.{1,255}$)[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?(?:\.[0-9A-Za-z](?:(?:[0-9A-Za-z]|-){0,61}[0-9A-Za-z])?)*\.?$/,"utc-millisec":function(e){return typeof e==`string`&&parseFloat(e)===parseInt(e,10)&&!isNaN(e)},regex:function(e){var t=!0;try{new RegExp(e)}catch{t=!1}return t},style:/[\r\n\t ]*[^\r\n\t ][^:]*:[\r\n\t ]*[^\r\n\t ;]*[\r\n\t ]*;?/,color:/^(#?([0-9A-Fa-f]{3}){1,2}\b|aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow|(rgb\(\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*\))|(rgb\(\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*\)))$/,phone:/^\+(?:[0-9] ?){6,14}[0-9]$/,alpha:/^[a-zA-Z]+$/,alphanumeric:/^[a-zA-Z0-9]+$/};o.regexp=o.regex,o.pattern=o.regex,o.ipv4=o[`ip-address`],e.isFormat=function isFormat(e,t,n){if(typeof e==`string`&&o[t]!==void 0){if(o[t]instanceof RegExp)return o[t].test(e);if(typeof o[t]==`function`)return o[t](e)}else if(n&&n.customFormats&&typeof n.customFormats[t]==`function`)return n.customFormats[t](e);return!0};var s=e.makeSuffix=function makeSuffix(e){return e=e.toString(),!e.match(/[.\s\[\]]/)&&!e.match(/^[\d]/)?`.`+e:e.match(/^\d+$/)?`[`+e+`]`:`[`+JSON.stringify(e)+`]`};e.deepCompareStrict=function deepCompareStrict(e,t){if(typeof e!=typeof t)return!1;if(Array.isArray(e))return!Array.isArray(t)||e.length!==t.length?!1:e.every(function(n,r){return deepCompareStrict(e[r],t[r])});if(typeof e==`object`){if(!e||!t)return e===t;var n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every(function(n){return deepCompareStrict(e[n],t[n])})}return e===t};function deepMerger(e,t,n,r){typeof n==`object`?t[r]=deepMerge(e[r],n):e.indexOf(n)===-1&&t.push(n)}function copyist(e,t,n){t[n]=e[n]}function copyistWithDeepMerge(e,t,n,r){typeof t[r]!=`object`||!t[r]?n[r]=t[r]:e[r]?n[r]=deepMerge(e[r],t[r]):n[r]=t[r]}function deepMerge(e,t){var n=Array.isArray(t),r=n&&[]||{};return n?(e||=[],r=r.concat(e),t.forEach(deepMerger.bind(null,e,r))):(e&&typeof e==`object`&&Object.keys(e).forEach(copyist.bind(null,e,r)),Object.keys(t).forEach(copyistWithDeepMerge.bind(null,e,t,r))),r}t.exports.deepMerge=deepMerge,e.objectGetPath=function objectGetPath(e,t){for(var n=t.split(`/`).slice(1),r;typeof(r=n.shift())==`string`;){var i=decodeURIComponent(r.replace(/~0/,`~`).replace(/~1/g,`/`));if(!(i in e))return;e=e[i]}return e};function pathEncoder(e){return`/`+encodeURIComponent(e).replace(/~/g,`%7E`)}e.encodePath=function encodePointer(e){return e.map(pathEncoder).join(``)},e.getDecimalPlaces=function getDecimalPlaces(e){var t=0;if(isNaN(e))return t;typeof e!=`number`&&(e=Number(e));var n=e.toString().split(`e`);if(n.length===2){if(n[1][0]!==`-`)return t;t=Number(n[1].slice(1))}var r=n[0].split(`.`);return r.length===2&&(t+=r[1].length),t},e.isSchema=function isSchema(e){return typeof e==`object`&&e||typeof e==`boolean`};var c=e.resolveUrl=function resolveUrl(e,t){let n=new URL(t,new URL(e,`resolve://`));if(n.protocol===`resolve:`){let{pathname:e,search:t,hash:r}=n;return e+t+r}return n.toString()}})),s=__commonJSMin(((e,t)=>{var n=o(),r=n.ValidatorResult,i=n.SchemaError,a={};a.ignoreProperties={id:!0,default:!0,description:!0,title:!0,additionalItems:!0,then:!0,else:!0,$schema:!0,$ref:!0,extends:!0};var s=a.validators={};s.type=function validateType(e,t,n,i){if(e===void 0)return null;var a=new r(e,t,n,i),o=Array.isArray(t.type)?t.type:[t.type];if(!o.some(this.testType.bind(this,e,t,n,i))){var s=o.map(function(e){if(e){var t=e.$id||e.id;return t?`<`+t+`>`:e+``}});a.addError({name:`type`,argument:s,message:`is not of a type(s) `+s})}return a};function testSchemaNoThrow(e,t,n,r,i){var a=t.throwError,o=t.throwAll;t.throwError=!1,t.throwAll=!1;var s=this.validateSchema(e,i,t,n);return t.throwError=a,t.throwAll=o,!s.valid&&r instanceof Function&&r(s),s.valid}s.anyOf=function validateAnyOf(e,t,n,a){if(e===void 0)return null;var o=new r(e,t,n,a),s=new r(e,t,n,a);if(!Array.isArray(t.anyOf))throw new i(`anyOf must be an array`);if(!t.anyOf.some(testSchemaNoThrow.bind(this,e,n,a,function(e){s.importErrors(e)}))){var c=t.anyOf.map(function(e,t){var n=e.$id||e.id;return n?`<`+n+`>`:e.title&&JSON.stringify(e.title)||e.$ref&&`<`+e.$ref+`>`||`[subschema `+t+`]`});n.nestedErrors&&o.importErrors(s),o.addError({name:`anyOf`,argument:c,message:`is not any of `+c.join(`,`)})}return o},s.allOf=function validateAllOf(e,t,n,a){if(e===void 0)return null;if(!Array.isArray(t.allOf))throw new i(`allOf must be an array`);var o=new r(e,t,n,a),s=this;return t.allOf.forEach(function(t,r){var i=s.validateSchema(e,t,n,a);if(!i.valid){var c=t.$id||t.id||t.title&&JSON.stringify(t.title)||t.$ref&&`<`+t.$ref+`>`||`[subschema `+r+`]`;o.addError({name:`allOf`,argument:{id:c,length:i.errors.length,valid:i},message:`does not match allOf schema `+c+` with `+i.errors.length+` error[s]:`}),o.importErrors(i)}}),o},s.oneOf=function validateOneOf(e,t,n,a){if(e===void 0)return null;if(!Array.isArray(t.oneOf))throw new i(`oneOf must be an array`);var o=new r(e,t,n,a),s=new r(e,t,n,a),c=t.oneOf.filter(testSchemaNoThrow.bind(this,e,n,a,function(e){s.importErrors(e)})).length,l=t.oneOf.map(function(e,t){return e.$id||e.id||e.title&&JSON.stringify(e.title)||e.$ref&&`<`+e.$ref+`>`||`[subschema `+t+`]`});return c!==1&&(n.nestedErrors&&o.importErrors(s),o.addError({name:`oneOf`,argument:l,message:`is not exactly one from `+l.join(`,`)})),o},s.if=function validateIf(e,t,i,a){if(e===void 0)return null;if(!n.isSchema(t.if))throw Error(`Expected "if" keyword to be a schema`);var o=testSchemaNoThrow.call(this,e,i,a,null,t.if),s=new r(e,t,i,a),c;if(o){if(t.then===void 0)return;if(!n.isSchema(t.then))throw Error(`Expected "then" keyword to be a schema`);c=this.validateSchema(e,t.then,i,a.makeChild(t.then)),s.importErrors(c)}else{if(t.else===void 0)return;if(!n.isSchema(t.else))throw Error(`Expected "else" keyword to be a schema`);c=this.validateSchema(e,t.else,i,a.makeChild(t.else)),s.importErrors(c)}return s};function getEnumerableProperty(e,t){if(Object.hasOwnProperty.call(e,t))return e[t];if(t in e){for(;e=Object.getPrototypeOf(e);)if(Object.propertyIsEnumerable.call(e,t))return e[t]}}s.propertyNames=function validatePropertyNames(e,t,a,o){if(this.types.object(e)){var s=new r(e,t,a,o),c=t.propertyNames===void 0?{}:t.propertyNames;if(!n.isSchema(c))throw new i(`Expected "propertyNames" to be a schema (object or boolean)`);for(var l in e)if(getEnumerableProperty(e,l)!==void 0){var u=this.validateSchema(l,c,a,o.makeChild(c));s.importErrors(u)}return s}},s.properties=function validateProperties(e,t,n,a){if(this.types.object(e)){var o=new r(e,t,n,a),s=t.properties||{};for(var c in s){var l=s[c];if(l!==void 0){if(l===null)throw new i(`Unexpected null, expected schema in "properties"`);typeof n.preValidateProperty==`function`&&n.preValidateProperty(e,c,l,n,a);var u=getEnumerableProperty(e,c),d=this.validateSchema(u,l,n,a.makeChild(l,c));d.instance!==o.instance[c]&&(o.instance[c]=d.instance),o.importErrors(d)}}return o}};function testAdditionalProperty(e,t,n,r,i,a){if(this.types.object(e)&&!(t.properties&&t.properties[i]!==void 0))if(t.additionalProperties===!1)a.addError({name:`additionalProperties`,argument:i,message:`is not allowed to have the additional property `+JSON.stringify(i)});else{var o=t.additionalProperties||{};typeof n.preValidateProperty==`function`&&n.preValidateProperty(e,i,o,n,r);var s=this.validateSchema(e[i],o,n,r.makeChild(o,i));s.instance!==a.instance[i]&&(a.instance[i]=s.instance),a.importErrors(s)}}s.patternProperties=function validatePatternProperties(e,t,n,a){if(this.types.object(e)){var o=new r(e,t,n,a),s=t.patternProperties||{};for(var c in e){var l=!0;for(var u in s){var d=s[u];if(d!==void 0){if(d===null)throw new i(`Unexpected null, expected schema in "patternProperties"`);try{var f=new RegExp(u,`u`)}catch{f=new RegExp(u)}if(f.test(c)){l=!1,typeof n.preValidateProperty==`function`&&n.preValidateProperty(e,c,d,n,a);var p=this.validateSchema(e[c],d,n,a.makeChild(d,c));p.instance!==o.instance[c]&&(o.instance[c]=p.instance),o.importErrors(p)}}}l&&testAdditionalProperty.call(this,e,t,n,a,c,o)}return o}},s.additionalProperties=function validateAdditionalProperties(e,t,n,i){if(this.types.object(e)){if(t.patternProperties)return null;var a=new r(e,t,n,i);for(var o in e)testAdditionalProperty.call(this,e,t,n,i,o,a);return a}},s.minProperties=function validateMinProperties(e,t,n,i){if(this.types.object(e)){var a=new r(e,t,n,i);return Object.keys(e).length>=t.minProperties||a.addError({name:`minProperties`,argument:t.minProperties,message:`does not meet minimum property length of `+t.minProperties}),a}},s.maxProperties=function validateMaxProperties(e,t,n,i){if(this.types.object(e)){var a=new r(e,t,n,i);return Object.keys(e).length<=t.maxProperties||a.addError({name:`maxProperties`,argument:t.maxProperties,message:`does not meet maximum property length of `+t.maxProperties}),a}},s.items=function validateItems(e,t,n,i){var a=this;if(this.types.array(e)&&t.items!==void 0){var o=new r(e,t,n,i);return e.every(function(e,r){if(Array.isArray(t.items))var s=t.items[r]===void 0?t.additionalItems:t.items[r];else var s=t.items;if(s===void 0)return!0;if(s===!1)return o.addError({name:`items`,message:`additionalItems not permitted`}),!1;var c=a.validateSchema(e,s,n,i.makeChild(s,r));return c.instance!==o.instance[r]&&(o.instance[r]=c.instance),o.importErrors(c),!0}),o}},s.contains=function validateContains(e,t,i,a){var o=this;if(this.types.array(e)&&t.contains!==void 0){if(!n.isSchema(t.contains))throw Error(`Expected "contains" keyword to be a schema`);var s=new r(e,t,i,a);return e.some(function(e,n){return o.validateSchema(e,t.contains,i,a.makeChild(t.contains,n)).errors.length===0})===!1&&s.addError({name:`contains`,argument:t.contains,message:`must contain an item matching given schema`}),s}},s.minimum=function validateMinimum(e,t,n,i){if(this.types.number(e)){var a=new r(e,t,n,i);return t.exclusiveMinimum&&t.exclusiveMinimum===!0?e>t.minimum||a.addError({name:`minimum`,argument:t.minimum,message:`must be greater than `+t.minimum}):e>=t.minimum||a.addError({name:`minimum`,argument:t.minimum,message:`must be greater than or equal to `+t.minimum}),a}},s.maximum=function validateMaximum(e,t,n,i){if(this.types.number(e)){var a=new r(e,t,n,i);return t.exclusiveMaximum&&t.exclusiveMaximum===!0?e<t.maximum||a.addError({name:`maximum`,argument:t.maximum,message:`must be less than `+t.maximum}):e<=t.maximum||a.addError({name:`maximum`,argument:t.maximum,message:`must be less than or equal to `+t.maximum}),a}},s.exclusiveMinimum=function validateExclusiveMinimum(e,t,n,i){if(typeof t.exclusiveMinimum!=`boolean`&&this.types.number(e)){var a=new r(e,t,n,i);return e>t.exclusiveMinimum||a.addError({name:`exclusiveMinimum`,argument:t.exclusiveMinimum,message:`must be strictly greater than `+t.exclusiveMinimum}),a}},s.exclusiveMaximum=function validateExclusiveMaximum(e,t,n,i){if(typeof t.exclusiveMaximum!=`boolean`&&this.types.number(e)){var a=new r(e,t,n,i);return e<t.exclusiveMaximum||a.addError({name:`exclusiveMaximum`,argument:t.exclusiveMaximum,message:`must be strictly less than `+t.exclusiveMaximum}),a}};var c=function validateMultipleOfOrDivisbleBy(e,t,a,o,s,c){if(this.types.number(e)){var l=t[s];if(l==0)throw new i(s+` cannot be zero`);var u=new r(e,t,a,o),d=n.getDecimalPlaces(e),f=n.getDecimalPlaces(l),p=10**Math.max(d,f);return Math.round(e*p)%Math.round(l*p)!==0&&u.addError({name:s,argument:l,message:c+JSON.stringify(l)}),u}};s.multipleOf=function validateMultipleOf(e,t,n,r){return c.call(this,e,t,n,r,`multipleOf`,`is not a multiple of (divisible by) `)},s.divisibleBy=function validateDivisibleBy(e,t,n,r){return c.call(this,e,t,n,r,`divisibleBy`,`is not divisible by (multiple of) `)},s.required=function validateRequired(e,t,n,i){var a=new r(e,t,n,i);return e===void 0&&t.required===!0?a.addError({name:`required`,message:`is required`}):this.types.object(e)&&Array.isArray(t.required)&&t.required.forEach(function(t){getEnumerableProperty(e,t)===void 0&&a.addError({name:`required`,argument:t,message:`requires property `+JSON.stringify(t)})}),a},s.pattern=function validatePattern(e,t,n,i){if(this.types.string(e)){var a=new r(e,t,n,i),o=t.pattern;try{var s=new RegExp(o,`u`)}catch{s=new RegExp(o)}return e.match(s)||a.addError({name:`pattern`,argument:t.pattern,message:`does not match pattern `+JSON.stringify(t.pattern.toString())}),a}},s.format=function validateFormat(e,t,i,a){if(e!==void 0){var o=new r(e,t,i,a);return!o.disableFormat&&!n.isFormat(e,t.format,this)&&o.addError({name:`format`,argument:t.format,message:`does not conform to the `+JSON.stringify(t.format)+` format`}),o}},s.minLength=function validateMinLength(e,t,n,i){if(this.types.string(e)){var a=new r(e,t,n,i),o=e.match(/[\uDC00-\uDFFF]/g);return e.length-(o?o.length:0)>=t.minLength||a.addError({name:`minLength`,argument:t.minLength,message:`does not meet minimum length of `+t.minLength}),a}},s.maxLength=function validateMaxLength(e,t,n,i){if(this.types.string(e)){var a=new r(e,t,n,i),o=e.match(/[\uDC00-\uDFFF]/g);return e.length-(o?o.length:0)<=t.maxLength||a.addError({name:`maxLength`,argument:t.maxLength,message:`does not meet maximum length of `+t.maxLength}),a}},s.minItems=function validateMinItems(e,t,n,i){if(this.types.array(e)){var a=new r(e,t,n,i);return e.length>=t.minItems||a.addError({name:`minItems`,argument:t.minItems,message:`does not meet minimum length of `+t.minItems}),a}},s.maxItems=function validateMaxItems(e,t,n,i){if(this.types.array(e)){var a=new r(e,t,n,i);return e.length<=t.maxItems||a.addError({name:`maxItems`,argument:t.maxItems,message:`does not meet maximum length of `+t.maxItems}),a}};function testArrays(e,t,r){var i,a=r.length;for(i=t+1;i<a;i++)if(n.deepCompareStrict(e,r[i]))return!1;return!0}s.uniqueItems=function validateUniqueItems(e,t,n,i){if(t.uniqueItems===!0&&this.types.array(e)){var a=new r(e,t,n,i);return e.every(testArrays)||a.addError({name:`uniqueItems`,message:`contains duplicate item`}),a}},s.dependencies=function validateDependencies(e,t,n,i){if(this.types.object(e)){var a=new r(e,t,n,i);for(var o in t.dependencies)if(e[o]!==void 0){var s=t.dependencies[o],c=i.makeChild(s,o);if(typeof s==`string`&&(s=[s]),Array.isArray(s))s.forEach(function(t){e[t]===void 0&&a.addError({name:`dependencies`,argument:c.propertyPath,message:`property `+t+` not found, required by `+c.propertyPath})});else{var l=this.validateSchema(e,s,n,c);a.instance!==l.instance&&(a.instance=l.instance),l&&l.errors.length&&(a.addError({name:`dependencies`,argument:c.propertyPath,message:`does not meet dependency required by `+c.propertyPath}),a.importErrors(l))}}return a}},s.enum=function validateEnum(e,t,a,o){if(e===void 0)return null;if(!Array.isArray(t.enum))throw new i(`enum expects an array`,t);var s=new r(e,t,a,o);return t.enum.some(n.deepCompareStrict.bind(null,e))||s.addError({name:`enum`,argument:t.enum,message:`is not one of enum values: `+t.enum.map(String).join(`,`)}),s},s.const=function validateEnum(e,t,i,a){if(e===void 0)return null;var o=new r(e,t,i,a);return n.deepCompareStrict(t.const,e)||o.addError({name:`const`,argument:t.const,message:`does not exactly match expected constant: `+t.const}),o},s.not=s.disallow=function validateNot(e,t,n,i){var a=this;if(e===void 0)return null;var o=new r(e,t,n,i),s=t.not||t.disallow;return s?(Array.isArray(s)||(s=[s]),s.forEach(function(r){if(a.testType(e,t,n,i,r)){var s=r&&(r.$id||r.id)||r;o.addError({name:`not`,argument:s,message:`is of prohibited type `+s})}}),o):null},t.exports=a})),c=__commonJSMin(((e,t)=>{var n=o();t.exports.SchemaScanResult=SchemaScanResult;function SchemaScanResult(e,t){this.id=e,this.ref=t}t.exports.scan=function scan(e,t){function scanSchema(e,t){if(!t||typeof t!=`object`)return;if(t.$ref){let r=n.resolveUrl(e,t.$ref);i[r]=i[r]?i[r]+1:0;return}var a=t.$id||t.id;let o=n.resolveUrl(e,a);var s=a?o:e;if(s){if(s.indexOf(`#`)<0&&(s+=`#`),r[s]){if(!n.deepCompareStrict(r[s],t))throw Error(`Schema <`+s+`> already exists with different definition`);return r[s]}r[s]=t,s[s.length-1]==`#`&&(r[s.substring(0,s.length-1)]=t)}scanArray(s+`/items`,Array.isArray(t.items)?t.items:[t.items]),scanArray(s+`/extends`,Array.isArray(t.extends)?t.extends:[t.extends]),scanSchema(s+`/additionalItems`,t.additionalItems),scanObject(s+`/properties`,t.properties),scanSchema(s+`/additionalProperties`,t.additionalProperties),scanObject(s+`/definitions`,t.definitions),scanObject(s+`/patternProperties`,t.patternProperties),scanObject(s+`/dependencies`,t.dependencies),scanArray(s+`/disallow`,t.disallow),scanArray(s+`/allOf`,t.allOf),scanArray(s+`/anyOf`,t.anyOf),scanArray(s+`/oneOf`,t.oneOf),scanSchema(s+`/not`,t.not)}function scanArray(e,t){if(Array.isArray(t))for(var n=0;n<t.length;n++)scanSchema(e+`/`+n,t[n])}function scanObject(e,t){if(!(!t||typeof t!=`object`))for(var n in t)scanSchema(e+`/`+n,t[n])}var r={},i={};return scanSchema(e,t),new SchemaScanResult(r,i)}})),l=__commonJSMin(((e,t)=>{var n=s(),r=o(),i=c().scan,a=r.ValidatorResult,l=r.ValidatorResultError,u=r.SchemaError,d=r.SchemaContext,f=`/`,p=function Validator(){this.customFormats=Object.create(Validator.prototype.customFormats),this.schemas={},this.unresolvedRefs=[],this.types=Object.create(m),this.attributes=Object.create(n.validators)};p.prototype.customFormats={},p.prototype.schemas=null,p.prototype.types=null,p.prototype.attributes=null,p.prototype.unresolvedRefs=null,p.prototype.addSchema=function addSchema(e,t){var n=this;if(!e)return null;var r=i(t||f,e),a=t||e.$id||e.id;for(var o in r.id)this.schemas[o]=r.id[o];for(var o in r.ref)this.unresolvedRefs.push(o);return this.unresolvedRefs=this.unresolvedRefs.filter(function(e){return n.schemas[e]===void 0}),this.schemas[a]},p.prototype.addSubSchemaArray=function addSubSchemaArray(e,t){if(Array.isArray(t))for(var n=0;n<t.length;n++)this.addSubSchema(e,t[n])},p.prototype.addSubSchemaObject=function addSubSchemaArray(e,t){if(!(!t||typeof t!=`object`))for(var n in t)this.addSubSchema(e,t[n])},p.prototype.setSchemas=function setSchemas(e){this.schemas=e},p.prototype.getSchema=function getSchema(e){return this.schemas[e]},p.prototype.validate=function validate(e,t,n,o){if(typeof t!=`boolean`&&typeof t!=`object`||t===null)throw new u("Expected `schema` to be an object or boolean");n||={};var s=t.$id||t.id;let c=r.resolveUrl(n.base,s||``);if(!o){o=new d(t,n,[],c,Object.create(this.schemas)),o.schemas[c]||(o.schemas[c]=t);var f=i(c,t);for(var p in f.id){var m=f.id[p];o.schemas[p]=m}}if(n.required&&e===void 0){var h=new a(e,t,n,o);return h.addError(`is required, but is undefined`),h}var h=this.validateSchema(e,t,n,o);if(!h)throw Error(`Result undefined`);if(n.throwAll&&h.errors.length)throw new l(h);return h};function shouldResolve(e){var t=typeof e==`string`?e:e.$ref;return typeof t==`string`&&t}p.prototype.validateSchema=function validateSchema(e,t,i,o){var s=new a(e,t,i,o);if(typeof t==`boolean`)t===!0?t={}:t===!1&&(t={type:[]});else if(!t)throw Error(`schema is undefined`);if(t.extends)if(Array.isArray(t.extends)){var c={schema:t,ctx:o};t.extends.forEach(this.schemaTraverser.bind(this,c)),t=c.schema,c.schema=null,c.ctx=null,c=null}else t=r.deepMerge(t,this.superResolve(t.extends,o));var l=shouldResolve(t);if(l){var f=this.resolve(t,l,o),p=new d(f.subschema,i,o.path,f.switchSchema,o.schemas);return this.validateSchema(e,f.subschema,i,p)}var m=i&&i.skipAttributes||[];for(var h in t)if(!n.ignoreProperties[h]&&m.indexOf(h)<0){var g=null,_=this.attributes[h];if(_)g=_.call(this,e,t,i,o);else if(i.allowUnknownAttributes===!1)throw new u(`Unsupported attribute: `+h,t);g&&s.importErrors(g)}return typeof i.rewrite==`function`&&(s.instance=i.rewrite.call(this,e,t,i,o)),s},p.prototype.schemaTraverser=function schemaTraverser(e,t){e.schema=r.deepMerge(e.schema,this.superResolve(t,e.ctx))},p.prototype.superResolve=function superResolve(e,t){var n=shouldResolve(e);return n?this.resolve(e,n,t).subschema:e},p.prototype.resolve=function resolve(e,t,n){if(t=n.resolve(t),n.schemas[t])return{subschema:n.schemas[t],switchSchema:t};let i=new URL(t,`thismessage::/`).hash;var a=i&&i.length&&t.substr(0,t.length-i.length);if(!a||!n.schemas[a])throw new u(`no such schema <`+t+`>`,e);var o=r.objectGetPath(n.schemas[a],i.substr(1));if(o===void 0)throw new u(`no such schema `+i+` located in <`+a+`>`,e);return{subschema:o,switchSchema:t}},p.prototype.testType=function validateType(e,t,n,r,i){if(i!==void 0){if(i===null)throw new u(`Unexpected null in "type" keyword`);if(typeof this.types[i]==`function`)return this.types[i].call(this,e);if(i&&typeof i==`object`){var a=this.validateSchema(e,i,n,r);return a===void 0||!(a&&a.errors.length)}return!0}};var m=p.prototype.types={};m.string=function testString(e){return typeof e==`string`},m.number=function testNumber(e){return typeof e==`number`&&isFinite(e)},m.integer=function testInteger(e){return typeof e==`number`&&e%1==0},m.boolean=function testBoolean(e){return typeof e==`boolean`},m.array=function testArray(e){return Array.isArray(e)},m.null=function testNull(e){return e===null},m.date=function testDate(e){return e instanceof Date},m.any=function testAny(e){return!0},m.object=function testObject(e){return e&&typeof e==`object`&&!Array.isArray(e)&&!(e instanceof Date)},t.exports=p})),u=__commonJSMin(((e,t)=>{var n=t.exports.Validator=l();t.exports.ValidatorResult=o().ValidatorResult,t.exports.ValidatorResultError=o().ValidatorResultError,t.exports.ValidationError=o().ValidationError,t.exports.SchemaError=o().SchemaError,t.exports.SchemaScanResult=c().SchemaScanResult,t.exports.scan=c().scan,t.exports.validate=function(e,t,r){return new n().validate(e,t,r)}})),d=__toESM(__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{CLASSES_PROP_KEY:()=>v,DateTimePropTypeUtil:()=>je,Schema:()=>ct,backdropFilterPropTypeUtil:()=>Z,backgroundColorOverlayPropTypeUtil:()=>j,backgroundGradientOverlayPropTypeUtil:()=>M,backgroundImageOverlayPropTypeUtil:()=>N,backgroundImagePositionOffsetPropTypeUtil:()=>Ee,backgroundImageSizeScalePropTypeUtil:()=>De,backgroundOverlayItem:()=>P,backgroundOverlayPropTypeUtil:()=>Te,backgroundPropTypeUtil:()=>A,blurFilterPropTypeUtil:()=>V,booleanPropTypeUtil:()=>Oe,borderRadiusPropTypeUtil:()=>h,borderWidthPropTypeUtil:()=>g,boxShadowPropTypeUtil:()=>m,classesPropTypeUtil:()=>ee,colorPropTypeUtil:()=>te,colorStopPropTypeUtil:()=>F,colorToneFilterPropTypeUtil:()=>H,createArrayPropUtils:()=>createArrayPropUtils,createPropUtils:()=>createPropUtils,cssFilterFunctionPropUtil:()=>G,dateRangePropTypeUtil:()=>Ze,dateStringPropTypeUtil:()=>Qe,dimensionsPropTypeUtil:()=>fe,dropShadowFilterPropTypeUtil:()=>B,emailPropTypeUtil:()=>xe,emailsPropTypeUtil:()=>Se,escapedHtmlPropTypeUtil:()=>ze,evaluateTerm:()=>evaluateTerm,extractValue:()=>extractValue,filterEmptyValues:()=>filterEmptyValues,filterPropTypeUtil:()=>Be,flexPropTypeUtil:()=>ne,fontFamilyPropTypeUtil:()=>ie,getPropSchemaFromCache:()=>getPropSchemaFromCache,gradientColorStopPropTypeUtil:()=>ke,gridTrackSizePropTypeUtil:()=>me,htmlPropTypeUtil:()=>Fe,htmlV2PropTypeUtil:()=>Le,htmlV3PropTypeUtil:()=>Re,hueRotateFilterPropTypeUtil:()=>U,iconPropTypeUtil:()=>ce,imageAttachmentIdPropType:()=>oe,imagePropTypeUtil:()=>ae,imageSrcPropTypeUtil:()=>se,intensityFilterPropTypeUtil:()=>W,isDependency:()=>isDependency,isDependencyMet:()=>isDependencyMet,isEmpty:()=>isEmpty,isOverridable:()=>isOverridable,isTransformable:()=>isTransformable,keyValuePropTypeUtil:()=>O,layoutDirectionPropTypeUtil:()=>ye,linkPropTypeUtil:()=>be,mergeProps:()=>mergeProps,moveTransformPropTypeUtil:()=>q,numberPropTypeUtil:()=>S,numberRangePropTypeUtil:()=>Ae,parseHtmlChildren:()=>parseHtmlChildren,perspectiveOriginPropTypeUtil:()=>Xe,positionPropTypeUtil:()=>Me,queryFilterArrayPropTypeUtil:()=>Pe,queryFilterPropTypeUtil:()=>I,queryPropTypeUtil:()=>Ne,rewrapOverridableValue:()=>rewrapOverridableValue,rotateTransformPropTypeUtil:()=>J,scaleTransformPropTypeUtil:()=>Y,selectionSizePropTypeUtil:()=>k,shadowPropTypeUtil:()=>p,sizePropTypeUtil:()=>pe,skewTransformPropTypeUtil:()=>X,spanPropTypeUtil:()=>he,stringArrayPropTypeUtil:()=>ge,stringPropTypeUtil:()=>E,strokePropTypeUtil:()=>_e,svgSrcPropTypeUtil:()=>le,timeRangePropTypeUtil:()=>$e,timeStringPropTypeUtil:()=>et,transformFunctionsPropTypeUtil:()=>Je,transformOriginPropTypeUtil:()=>Ye,transformPropTypeUtil:()=>Ve,urlPropTypeUtil:()=>ve,videoAttachmentIdPropType:()=>ue,videoSrcPropTypeUtil:()=>de}),t.exports=__toCommonJS(o);var s=globalThis.elementorV2.schema,c=globalThis.elementorV2.schema,l=new Map;function getPropSchemaFromCache(e){return l.get(e)}function createPropUtils(e,t){let n=c.z.strictObject({$$type:c.z.literal(e),value:t,disabled:c.z.boolean().optional()});function isValid(e){return n.safeParse(e).success}function create(t,n){let r=typeof t==`function`?t:()=>t,{base:i,disabled:a}=n||{};if(!i)return{$$type:e,value:r(),...a&&{disabled:a}};if(!isValid(i))throw Error(`Cannot create prop based on invalid value: ${JSON.stringify(i)}`);return{$$type:e,value:r(i.value),...a&&{disabled:a}}}function extract(e){return isValid(e)?e.value:null}let r={extract,isValid,create,schema:n,key:e};return l.set(e,r),r}function createArrayPropUtils(e,t,n){return createPropUtils(n||`${e}-array`,c.z.array(t))}var d=globalThis.elementorV2.schema,f=globalThis.elementorV2.schema.z.any().nullable(),p=createPropUtils(`shadow`,d.z.strictObject({position:f,hOffset:f,vOffset:f,blur:f,spread:f,color:f})),m=createPropUtils(`box-shadow`,s.z.array(p.schema)),h=createPropUtils(`border-radius-v2`,globalThis.elementorV2.schema.z.strictObject({"start-start":f,"start-end":f,"end-start":f,"end-end":f})),g=createPropUtils(`border-width-v2`,globalThis.elementorV2.schema.z.strictObject({"block-start":f,"block-end":f,"inline-start":f,"inline-end":f})),_=globalThis.elementorV2.schema,v=`classes`,ee=createPropUtils(v,_.z.array(_.z.string().regex(/^[a-z][a-z-_0-9]*$/i))),te=createPropUtils(`color`,globalThis.elementorV2.schema.z.string()),ne=createPropUtils(`flex`,globalThis.elementorV2.schema.z.strictObject({flexGrow:f,flexShrink:f,flexBasis:f})),re=createPropUtils(`font-family`,globalThis.elementorV2.schema.z.string().nullable()),ie=Object.assign(re,{getEnqueueFontFamily:e=>{let t=e.trim();return t.startsWith(`"`)&&t.endsWith(`"`)||t.startsWith(`'`)&&t.endsWith(`'`)?t.slice(1,-1).trim():t}}),ae=createPropUtils(`image`,globalThis.elementorV2.schema.z.strictObject({src:f,size:f})),oe=createPropUtils(`image-attachment-id`,globalThis.elementorV2.schema.z.number()),y=globalThis.elementorV2.schema,se=createPropUtils(`image-src`,y.z.strictObject({id:f,url:y.z.null(),alt:f.optional().default(null)}).or(y.z.strictObject({id:f.optional().default(null),url:f,alt:f.optional().default(null)}))),ce=createPropUtils(`icon`,globalThis.elementorV2.schema.z.strictObject({value:f,library:f})),b=globalThis.elementorV2.schema,le=createPropUtils(`svg-src`,b.z.strictObject({id:f,url:b.z.null()}).or(b.z.strictObject({id:b.z.null(),url:f})).or(b.z.strictObject({id:f,url:f}))),ue=createPropUtils(`video-attachment-id`,globalThis.elementorV2.schema.z.number()),x=globalThis.elementorV2.schema,de=createPropUtils(`video-src`,x.z.strictObject({id:f,url:x.z.literal(null).optional()}).or(x.z.strictObject({id:x.z.literal(null).optional(),url:f}))),fe=createPropUtils(`dimensions`,globalThis.elementorV2.schema.z.strictObject({"block-start":f,"block-end":f,"inline-start":f,"inline-end":f})),S=createPropUtils(`number`,globalThis.elementorV2.schema.z.number().nullable()),C=globalThis.elementorV2.schema,w=C.z.union([C.z.number(),C.z.literal(``)]),pe=createPropUtils(`size`,C.z.strictObject({unit:C.z.enum([`px`,`em`,`rem`,`%`,`vw`,`vh`,`ch`,`fr`]),size:w}).or(C.z.strictObject({unit:C.z.enum([`deg`,`rad`,`grad`,`turn`]),size:w})).or(C.z.strictObject({unit:C.z.enum([`s`,`ms`]),size:w})).or(C.z.strictObject({unit:C.z.literal(`auto`),size:C.z.literal(``)})).or(C.z.strictObject({unit:C.z.literal(`custom`),size:C.z.string()}))),T=globalThis.elementorV2.schema,me=createPropUtils(`grid-track-size`,T.z.strictObject({unit:T.z.literal(`fr`),size:T.z.union([T.z.number(),T.z.literal(``)])}).or(T.z.strictObject({unit:T.z.literal(`custom`),size:T.z.string()}))),he=createPropUtils(`span`,globalThis.elementorV2.schema.z.string().nullable()),E=createPropUtils(`string`,globalThis.elementorV2.schema.z.string().nullable()),ge=createArrayPropUtils(E.key,E.schema),_e=createPropUtils(`stroke`,globalThis.elementorV2.schema.z.strictObject({color:f,width:f})),ve=createPropUtils(`url`,globalThis.elementorV2.schema.z.string().nullable()),D=globalThis.elementorV2.schema,ye=createPropUtils(`layout-direction`,D.z.object({row:D.z.any(),column:D.z.any()})),be=createPropUtils(`link`,globalThis.elementorV2.schema.z.strictObject({destination:f,isTargetBlank:f,tag:f})),xe=createPropUtils(`email`,globalThis.elementorV2.schema.z.strictObject({to:f,subject:f,message:f,from:f,"meta-data":f,"send-as":f,"from-name":f,"reply-to":f,cc:f,bcc:f})),Se=createPropUtils(`emails`,globalThis.elementorV2.schema.z.strictObject({to:f,subject:f,message:f,from:f,"meta-data":f,"send-as":f,"from-name":f,"reply-to":f,cc:f,bcc:f})),Ce=globalThis.elementorV2.schema,O=createPropUtils(`key-value`,globalThis.elementorV2.schema.z.strictObject({key:f,value:f})),k=createPropUtils(`selection-size`,Ce.z.strictObject({selection:Ce.z.union([O.schema,E.schema]),size:f})),A=createPropUtils(`background`,globalThis.elementorV2.schema.z.strictObject({color:f,clip:f,"background-overlay":f})),we=globalThis.elementorV2.schema,j=createPropUtils(`background-color-overlay`,f),M=createPropUtils(`background-gradient-overlay`,f),N=createPropUtils(`background-image-overlay`,f),P=j.schema.or(M.schema).or(N.schema),Te=createPropUtils(`background-overlay`,we.z.array(P)),Ee=createPropUtils(`background-image-position-offset`,f),De=createPropUtils(`background-image-size-scale`,f),Oe=createPropUtils(`boolean`,globalThis.elementorV2.schema.z.boolean().nullable()),F=createPropUtils(`color-stop`,globalThis.elementorV2.schema.z.strictObject({color:f,offset:f})),ke=createPropUtils(`gradient-color-stop`,globalThis.elementorV2.schema.z.array(F.schema)),Ae=createPropUtils(`number-range`,globalThis.elementorV2.schema.z.strictObject({min:f,max:f})),je=createPropUtils(`date-time`,globalThis.elementorV2.schema.z.strictObject({date:f,time:f})),Me=createPropUtils(`object-position`,globalThis.elementorV2.schema.z.strictObject({x:f,y:f})),Ne=createPropUtils(`query`,globalThis.elementorV2.schema.z.strictObject({id:f,label:f})),I=createPropUtils(`query-filter`,globalThis.elementorV2.schema.z.strictObject({key:f,values:f,taxonomies:f})),Pe=createArrayPropUtils(I.key,I.schema),Fe=createPropUtils(`html`,globalThis.elementorV2.schema.z.string().nullable()),L=globalThis.elementorV2.schema,Ie=L.z.lazy(()=>L.z.object({id:L.z.string(),type:L.z.string(),content:L.z.string().optional(),children:L.z.array(Ie).optional()})),Le=createPropUtils(`html-v2`,L.z.object({content:L.z.string().nullable(),children:L.z.array(Ie)})),R=globalThis.elementorV2.schema,Re=createPropUtils(`html-v3`,R.z.object({content:E.schema.nullable(),children:R.z.array(R.z.unknown())})),ze=createPropUtils(`escaped-html`,globalThis.elementorV2.schema.z.string().nullable()),z=globalThis.elementorV2.schema,B=createPropUtils(`drop-shadow`,globalThis.elementorV2.schema.z.object({xAxis:f,yAxis:f,blur:f,color:f})),V=createPropUtils(`blur`,globalThis.elementorV2.schema.z.strictObject({size:f})),H=createPropUtils(`color-tone`,globalThis.elementorV2.schema.z.strictObject({size:f})),U=createPropUtils(`hue-rotate`,globalThis.elementorV2.schema.z.strictObject({size:f})),W=createPropUtils(`intensity`,globalThis.elementorV2.schema.z.strictObject({size:f})),G=createPropUtils(`css-filter-func`,z.z.object({func:E.schema,args:z.z.union([V.schema,W.schema,H.schema,U.schema,B.schema])})),Be=createPropUtils(`filter`,z.z.array(G.schema)),Ve=createPropUtils(`transform`,globalThis.elementorV2.schema.z.strictObject({"transform-functions":f,"transform-origin":f,perspective:f,"perspective-origin":f})),He=globalThis.elementorV2.schema,Ue=globalThis.elementorV2.schema,K={move:`transform-move`,scale:`transform-scale`,rotate:`transform-rotate`,skew:`transform-skew`},q=createPropUtils(K.move,Ue.z.strictObject({x:f,y:f,z:f})),We=globalThis.elementorV2.schema,J=createPropUtils(K.rotate,We.z.strictObject({x:f,y:f,z:f})),Ge=globalThis.elementorV2.schema,Y=createPropUtils(K.scale,Ge.z.strictObject({x:S.schema.nullable(),y:S.schema.nullable(),z:S.schema.nullable()})),Ke=globalThis.elementorV2.schema,X=createPropUtils(K.skew,Ke.z.strictObject({x:f,y:f})),qe=q.schema.or(Y.schema).or(J.schema).or(X.schema),Je=createPropUtils(`transform-functions`,He.z.array(qe)),Ye=createPropUtils(`transform-origin`,globalThis.elementorV2.schema.z.strictObject({x:f,y:f,z:f})),Xe=createPropUtils(`perspective-origin`,globalThis.elementorV2.schema.z.strictObject({x:f,y:f})),Z=createPropUtils(`backdrop-filter`,globalThis.elementorV2.schema.z.array(G.schema)),Ze=createPropUtils(`date-range`,globalThis.elementorV2.schema.z.strictObject({min:f,max:f})),Qe=createPropUtils(`date-string`,globalThis.elementorV2.schema.z.string()),$e=createPropUtils(`time-range`,globalThis.elementorV2.schema.z.strictObject({min:f,max:f})),et=createPropUtils(`time-string`,globalThis.elementorV2.schema.z.string()),ensureNotNull=(e,t)=>e===null?t:e,tt={transformers:{}},adjustLlmPropValueSchema=(e,{transformers:t={},forceKey:n=void 0}=tt)=>{let r=structuredClone(e);if(typeof r!=`object`||!r)return null;if(Array.isArray(r))return r.map(e=>adjustLlmPropValueSchema(e,{forceKey:n,transformers:t}));let i=r;switch(`$intention`in i&&delete i.$intention,n&&(i.$$type=n),i.$$type){case`size`:{let{value:e}=i;return{$$type:`size`,value:{unit:typeof e.unit==`string`?e.unit:ensureNotNull(E.extract(e.unit),`px`),size:typeof e.size==`string`||typeof e.size==`number`?e.size:ensureNotNull(E.extract(e.size),S.extract(e.size))}}}case`html-v3`:{let{value:e}=i;return{$$type:`html-v3`,value:{...e,children:Array.isArray(e.children)?e.children:[]}}}default:let e=t?.[i.$$type];if(e)return e(i.value)}if(typeof i.value==`object`)if(Array.isArray(i.value))i.value=adjustLlmPropValueSchema(i.value,{transformers:t});else{let{value:e}=i,n=r;n.value={},Object.entries(e).forEach(([e,r])=>{n.value[e]=adjustLlmPropValueSchema(r,{transformers:t})})}return r};function jsonSchemaToPropType(e,t=e.key){let n={};return e.description&&(n.description=e.description),e.anyOf&&Array.isArray(e.anyOf)?convertJsonSchemaToUnionPropType(e,n):e.type===`object`&&e.properties?convertJsonSchemaToObjectPropType(e,n,t):e.type===`array`&&e.items?convertJsonSchemaToArrayPropType(e,n,t):convertJsonSchemaToPlainPropType(e,n,t)}function convertJsonSchemaToPlainPropType(e,t,n=e.key){let r={},i=n||`string`;return e.type===`number`?i=`number`:e.type===`boolean`?i=`boolean`:e.type===`string`&&(i=`string`),Array.isArray(e.enum)&&(r.enum=e.enum),{kind:`plain`,key:i,settings:r,meta:t}}function convertJsonSchemaToUnionPropType(e,t){let n={};if(!e.anyOf||!Array.isArray(e.anyOf))throw Error(`Invalid anyOf schema`);for(let t of e.anyOf)if(t.type===`object`&&t.properties&&t.properties.$$type&&t.properties.value){let e=t.properties.$$type,r;if(e.enum&&Array.isArray(e.enum)&&e.enum.length>0)r=e.enum[0];else continue;n[r]=convertJsonSchemaToPropType(t.properties.value)}return{kind:`union`,prop_types:n,settings:{},meta:t}}function convertJsonSchemaToObjectPropType(e,t,n=e.key){let r={};if(!e.properties)return{kind:`object`,key:n,shape:{},settings:{},meta:t};let i=Array.isArray(e.required)?e.required:[];for(let[t,a]of Object.entries(e.properties)){let e=convertJsonSchemaToPropType(a,n);i.includes(t)&&(e.settings={...e.settings,required:!0}),r[t]=e}return{kind:`object`,key:n||`object`,shape:r,settings:{},meta:t}}function convertJsonSchemaToArrayPropType(e,t,n=e.key){if(!e.items)throw Error(`Array schema must have items property`);let r=convertJsonSchemaToPropType(e.items);return{kind:`array`,key:n||`array`,item_prop_type:r,settings:{},meta:t}}function convertJsonSchemaToPropType(e,t){return jsonSchemaToPropType(e,t)}var Q=`dynamic`,nt=`overridable`,rt=null;function setDynamicTagNamesResolver(e){rt=e}function propTypeToJsonSchema(e,t=!1){let n=e.meta?.description,r={};switch(n&&(r.description=n),e.initial_value!==null&&e.initial_value!==void 0&&(r.examples=[e.initial_value]),e.kind){case`union`:return convertUnionPropType(e,r,t);case`object`:return convertObjectPropType(e,r,t);case`array`:return convertArrayPropType(e,r,t);default:return convertPlainPropType(e,r)}}function convertPlainPropType(e,t){let n={...t};if(!Object.hasOwn(e,`kind`))throw Error(`PropType kind is undefined for propType with key: ${e.key??`[unknown key]`}`);let r=e.settings?.enum||[];switch(e.kind){case`string`:case`number`:case`boolean`:return{...n,type:`object`,properties:{$$type:{type:`string`,const:e.key??e.kind},value:{type:e.kind,...r.length>0?{enum:r}:{}}},required:[`$$type`,`value`]};case`unknown`:return{};default:return{...n,type:`object`,$$type:e.kind,value:{type:e.kind}}}}function convertUnionPropType(e,t,n){let r=structuredClone(t),i=e.prop_types||{},a=!n&&!!i[Q],o=n||a,s=[];for(let[e,t]of Object.entries(i))if(e!==nt){if(e===Q){a&&s.push(convertDynamicPropType(t));continue}s.push(propTypeToJsonSchema(t,o))}s.length>0&&(r.anyOf=s);let c=e.meta?.description;return c&&(r.description=c),r}function convertDynamicPropType(e){let t=Array.isArray(e.settings?.categories)?e.settings.categories:[],n=rt?.(t)??[];return{type:`object`,description:`Bind THIS value to a dynamic tag instead of a static value (this may be a nested field, e.g. an image's "src"). Look up the chosen tag in the "elementor://dynamic-tags" resource and populate "settings" exactly as its schema requires.`,properties:{$$type:{type:`string`,const:Q},value:{type:`object`,properties:{name:{type:`string`,description:`Dynamic tag name from "elementor://dynamic-tags".`,...n.length?{enum:n}:{}},settings:{type:`object`,description:`Tag settings matching the chosen tag's schema in the resource.`}},required:[`name`]}},required:[`$$type`,`value`]}}function convertObjectPropType(e,t,n){let r=structuredClone(t);r.type=`object`;let i={properties:{$$type:{type:`string`,const:e.key},value:{type:`object`,properties:{},additionalProperties:!1}}},a=[`$$type`,`value`],o=[],s=e.shape||{};for(let[e,t]of Object.entries(s)){let r=propTypeToJsonSchema(t,n);t.settings?.required===!0&&o.push(e),i.properties.value.properties&&(i.properties.value.properties[e]=r)}return r.required=a,o.length>0&&(i.properties.value.required=o),{...r,...i}}function convertArrayPropType(e,t,n){let r=structuredClone(t);r.type=`object`;let i,a=e.item_prop_type;return a&&(i=propTypeToJsonSchema(a,n)),r.properties={$$type:{type:`string`,const:e.key},value:{type:`array`,...i?{items:i}:{}}},r}var it=[`_cssid`,`classes`,`attributes`];function isPropKeyConfigurable(e,t){return!it.includes(e)||!!(!Array.isArray(t?.meta)&&t?.meta?.llm_configurable)}function configurableKeys(e){return Object.keys(e).filter(t=>isPropKeyConfigurable(t,e[t]))}function enrichWithIntention(e,t=`Describe the desired outcome`){let n=structuredClone(e);return n.properties?(n.properties.$intention={type:`string`,description:t},n.required=[...n.required||[],`$intention`],n):e}function removeIntention(e){let t=structuredClone(e);return t.properties?(delete t.properties.$intention,t.required&&=t.required.filter(e=>e!==`$intention`),t):e}var at=u();function processValidationError(e){let t={path:e.path,message:e.message,schema:e.schema,instance:e.instance,name:e.name};return e.name===`anyOf`&&e.schema&&typeof e.schema==`object`&&`anyOf`in e.schema&&(t.variants=(e.schema.anyOf||[]).map((t,n)=>{let r=(0,at.validate)(e.instance,t),i=`variant-${n}`;if(t&&typeof t==`object`&&`properties`in t&&t.properties&&typeof t.properties==`object`&&`$$type`in t.properties){let e=t.properties.$$type;e&&typeof e==`object`&&`const`in e&&typeof e.const==`string`&&(i=e.const)}return{discriminator:i,errors:r.errors.map(processValidationError)}})),t}function formatDetailedErrors(e,t=``){let n=[];for(let r of e){let e=r.path.length>0?r.path.join(`.`):`root`;if(n.push(`${t}Error at ${e}: ${r.message}`),r.variants&&r.variants.length>0){n.push(`${t} Tried ${r.variants.length} variant(s):`);for(let e of r.variants)if(n.push(`${t} - ${e.discriminator}:`),e.errors.length===0)n.push(`${t} (no errors - this variant matched!)`);else for(let r of e.errors){let e=r.path.length>0?r.path.join(`.`):`root`;n.push(`${t} ${e}: ${r.message}`),r.variants&&r.variants.length>0&&n.push(formatDetailedErrors([r],`${t} `))}}}return n.join(` | |
| 3 | +`)}var validatePropValue=(e,t)=>{let n=propTypeToJsonSchema(e);if(t===null)return{valid:!0,errors:[],errorMessages:[],jsonSchema:JSON.stringify(propTypeToJsonSchema(e))};let r=(0,at.validate)(t,n),i=r.errors.map(processValidationError);return{valid:r.valid,errors:r.errors,errorMessages:formatDetailedErrors(i),jsonSchema:JSON.stringify(n)}},$=globalThis.elementorV2.schema,ot=$.z.object({$$type:$.z.string(),value:$.z.any(),disabled:$.z.boolean().optional()}),isTransformable=e=>ot.safeParse(e).success,filterEmptyValues=e=>isEmpty(e)?null:Array.isArray(e)?e.map(filterEmptyValues).filter(e=>!isEmpty(e)):typeof e==`object`?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,filterEmptyValues(t)]).filter(([,e])=>!isEmpty(e))):e,isEmpty=e=>e&&isTransformable(e)?isEmpty(e.value):isNullish(e)||isNullishArray(e)||isNullishObject(e),isNullish=e=>e==null||e===``,isNullishArray=e=>Array.isArray(e)&&e.every(isEmpty),isNullishObject=e=>typeof e==`object`&&isNullishArray(Object.values(e));function isOverridable(e){return isTransformable(e)&&e.$$type===`overridable`}function rewrapOverridableValue(e,t){return{...e,value:{...e.value,origin_value:t}}}function mergeProps(e,t){let n={};return Array.isArray(e)||(n=structuredClone(e)),Object.entries(t).forEach(([e,t])=>{t==null?delete n[e]:n[e]=t}),n}function isDependencyMet(e,t){if(!e?.terms.length)return{isMet:!0};let{relation:n,terms:r}=e,i=getRelationMethod(n),a=[];return{isMet:r[i](e=>{let n=isDependency(e)?isDependencyMet(e,t).isMet:evaluateTerm(e,extractValue(e.path,t,e.nestedPath)?.value);return n||a.push(e),n}),failingDependencies:a}}function evaluateTerm(e,t){let{value:n,operator:r}=e;switch(r){case`eq`:case`ne`:return t===n==(r===`eq`);case`gt`:case`lte`:return!isNumber(t)||!isNumber(n)?!1:Number(t)>Number(n)==(r===`gt`);case`lt`:case`gte`:return!isNumber(t)||!isNumber(n)?!1:Number(t)<Number(n)==(r===`lt`);case`in`:case`nin`:return Array.isArray(n)?n.includes(t)===(r===`in`):!1;case`contains`:case`ncontains`:if((typeof t!=`string`||typeof n!=`string`)&&!Array.isArray(t))return!1;let e=Array.isArray(t)?t.map(e=>isTransformable(e)?e.value:e):t;return r===`contains`===e.includes(n);case`exists`:case`not_exist`:return r===`exists`==(!!t||t===0||!1===t);default:return!0}}function isNumber(e){return typeof e==`number`&&!isNaN(e)}function getRelationMethod(e){switch(e){case`or`:return`some`;case`and`:return`every`;default:throw Error(`Relation not supported ${e}`)}}function extractValue(e,t,n=[],r={}){let{unwrapOverridableLeaf:i=!0}=r,a=e.reduce((t,n,r)=>{let i=t?.[n];if(r===e.length-1)return i;if(isOverridable(i)){let e=i.value.origin_value;return isTransformable(e)?e.value??null:e}return isTransformable(i)?i.value??null:i},t);return i&&a&&isOverridable(a)&&(a=a.value.origin_value??null),n?.length?{$$type:`unknown`,value:n.reduce((e,t)=>e?.[t],a?.value)}:a}function isDependency(e){return`terms`in e}var st=new Set([`span`,`b`,`strong`,`i`,`em`,`u`,`a`,`del`,`sup`,`sub`,`s`]);function generateElementId(){return`e-${Date.now().toString(36)}-${Math.random().toString(36).substring(2,9)}`}function traverseChildren(e){let t=[];for(let n of Array.from(e.children)){let e=n.tagName.toLowerCase();if(!st.has(e)){t.push(...traverseChildren(n));continue}let r=n.getAttribute(`id`);r||(r=generateElementId(),n.setAttribute(`id`,r));let i={id:r,type:e},a=n.textContent?.trim();a&&(i.content=a);let o=traverseChildren(n);o.length>0&&(i.children=o),t.push(i)}return t}function parseHtmlChildren(e){if(!e)return{content:e,children:[]};let t=new DOMParser().parseFromString(`<body>${e}</body>`,`text/html`),n=t.querySelector(`parsererror`);if(n)return console.warn(`HTML parsing error, returning original content:`,n.textContent),{content:e,children:[]};let r=t.body,i=traverseChildren(r);return{content:r.innerHTML,children:i}}var ct={jsonSchemaToPropType,propTypeToJsonSchema,adjustLlmPropValueSchema,isPropKeyConfigurable,nonConfigurablePropKeys:it,configurableKeys,validatePropValue,enrichWithIntention,removeIntention,setDynamicTagNamesResolver};0&&(t.exports={CLASSES_PROP_KEY:v,DateTimePropTypeUtil:je,Schema:ct,backdropFilterPropTypeUtil:Z,backgroundColorOverlayPropTypeUtil:j,backgroundGradientOverlayPropTypeUtil:M,backgroundImageOverlayPropTypeUtil:N,backgroundImagePositionOffsetPropTypeUtil:Ee,backgroundImageSizeScalePropTypeUtil:De,backgroundOverlayItem:P,backgroundOverlayPropTypeUtil:Te,backgroundPropTypeUtil:A,blurFilterPropTypeUtil:V,booleanPropTypeUtil:Oe,borderRadiusPropTypeUtil:h,borderWidthPropTypeUtil:g,boxShadowPropTypeUtil:m,classesPropTypeUtil:ee,colorPropTypeUtil:te,colorStopPropTypeUtil:F,colorToneFilterPropTypeUtil:H,createArrayPropUtils,createPropUtils,cssFilterFunctionPropUtil:G,dateRangePropTypeUtil:Ze,dateStringPropTypeUtil:Qe,dimensionsPropTypeUtil:fe,dropShadowFilterPropTypeUtil:B,emailPropTypeUtil:xe,emailsPropTypeUtil:Se,escapedHtmlPropTypeUtil:ze,evaluateTerm,extractValue,filterEmptyValues,filterPropTypeUtil:Be,flexPropTypeUtil:ne,fontFamilyPropTypeUtil:ie,getPropSchemaFromCache,gradientColorStopPropTypeUtil:ke,gridTrackSizePropTypeUtil:me,htmlPropTypeUtil:Fe,htmlV2PropTypeUtil:Le,htmlV3PropTypeUtil:Re,hueRotateFilterPropTypeUtil:U,iconPropTypeUtil:ce,imageAttachmentIdPropType:oe,imagePropTypeUtil:ae,imageSrcPropTypeUtil:se,intensityFilterPropTypeUtil:W,isDependency,isDependencyMet,isEmpty,isOverridable,isTransformable,keyValuePropTypeUtil:O,layoutDirectionPropTypeUtil:ye,linkPropTypeUtil:be,mergeProps,moveTransformPropTypeUtil:q,numberPropTypeUtil:S,numberRangePropTypeUtil:Ae,parseHtmlChildren,perspectiveOriginPropTypeUtil:Xe,positionPropTypeUtil:Me,queryFilterArrayPropTypeUtil:Pe,queryFilterPropTypeUtil:I,queryPropTypeUtil:Ne,rewrapOverridableValue,rotateTransformPropTypeUtil:J,scaleTransformPropTypeUtil:Y,selectionSizePropTypeUtil:k,shadowPropTypeUtil:p,sizePropTypeUtil:pe,skewTransformPropTypeUtil:X,spanPropTypeUtil:he,stringArrayPropTypeUtil:ge,stringPropTypeUtil:E,strokePropTypeUtil:_e,svgSrcPropTypeUtil:le,timeRangePropTypeUtil:$e,timeStringPropTypeUtil:et,transformFunctionsPropTypeUtil:Je,transformOriginPropTypeUtil:Ye,transformPropTypeUtil:Ve,urlPropTypeUtil:ve,videoAttachmentIdPropType:ue,videoSrcPropTypeUtil:de})}))());(window.elementorV2=window.elementorV2||{}).editorProps=d})(),window.elementorV2.editorProps?.init?.(); | |