@wp-playground/blueprints 0.9.45 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.cjs CHANGED
@@ -1,12 +1,12 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("@php-wasm/node-polyfills");const C=require("@php-wasm/util"),ne=require("@php-wasm/logger"),fr=require("@php-wasm/scopes"),cr=require("@wp-playground/common"),mr=require("@php-wasm/progress"),qe=require("@php-wasm/universal"),er=["db.php","plugins/akismet","plugins/hello.php","plugins/wordpress-importer","mu-plugins/sqlite-database-integration","mu-plugins/playground-includes","mu-plugins/0-playground.php","mu-plugins/0-sqlite.php","themes/twentytwenty","themes/twentytwentyone","themes/twentytwentytwo","themes/twentytwentythree","themes/twentytwentyfour","themes/twentytwentyfive","themes/twentytwentysix"],Ye=async(r,{pluginPath:t,pluginName:f},d)=>{d==null||d.tracker.setCaption(`Activating ${f||t}`);const c=await r.documentRoot,i=await r.run({code:`<?php
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("@php-wasm/node-polyfills");const W=require("@php-wasm/util"),ce=require("@php-wasm/logger"),Ne=require("@php-wasm/universal"),_r=require("@wp-playground/common"),kr=require("@php-wasm/progress"),ir=require("@wp-playground/storage"),ar=["db.php","plugins/akismet","plugins/hello.php","plugins/wordpress-importer","mu-plugins/sqlite-database-integration","mu-plugins/playground-includes","mu-plugins/0-playground.php","mu-plugins/0-sqlite.php","themes/twentytwenty","themes/twentytwentyone","themes/twentytwentytwo","themes/twentytwentythree","themes/twentytwentyfour","themes/twentytwentyfive","themes/twentytwentysix"],pr=async(r,{pluginPath:t,pluginName:p},c)=>{c==null||c.tracker.setCaption(`Activating ${p||t}`);const h=await r.documentRoot,i=await r.run({code:`<?php
2
2
  define( 'WP_ADMIN', true );
3
- require_once( ${C.phpVar(c)}. "/wp-load.php" );
4
- require_once( ${C.phpVar(c)}. "/wp-admin/includes/plugin.php" );
3
+ require_once( ${W.phpVar(h)}. "/wp-load.php" );
4
+ require_once( ${W.phpVar(h)}. "/wp-admin/includes/plugin.php" );
5
5
 
6
6
  // Set current user to admin
7
7
  wp_set_current_user( get_users(array('role' => 'Administrator') )[0]->ID );
8
8
 
9
- $plugin_path = ${C.phpVar(t)};
9
+ $plugin_path = ${W.phpVar(t)};
10
10
  $response = false;
11
11
  if (!is_dir($plugin_path)) {
12
12
  $response = activate_plugin($plugin_path);
@@ -30,9 +30,9 @@
30
30
  }
31
31
 
32
32
  throw new Exception( 'Unable to activate plugin' );
33
- `});if(i.text!=="Plugin activated successfully")throw ne.logger.debug(i),new Error(`Plugin ${t} could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details`)},rr=async(r,{themeFolderName:t},f)=>{f==null||f.tracker.setCaption(`Activating ${t}`);const d=await r.documentRoot,c=`${d}/wp-content/themes/${t}`;if(!await r.fileExists(c))throw new Error(`
33
+ `});if(i.text!=="Plugin activated successfully")throw ce.logger.debug(i),new Error(`Plugin ${t} could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details`)},fr=async(r,{themeFolderName:t},p)=>{p==null||p.tracker.setCaption(`Activating ${t}`);const c=await r.documentRoot,h=`${c}/wp-content/themes/${t}`;if(!await r.fileExists(h))throw new Error(`
34
34
  Couldn't activate theme ${t}.
35
- Theme not found at the provided theme path: ${c}.
35
+ Theme not found at the provided theme path: ${h}.
36
36
  Check the theme path to ensure it's correct.
37
37
  If the theme is not installed, you can install it using the installTheme step.
38
38
  More info can be found in the Blueprint documentation: https://wordpress.github.io/wordpress-playground/blueprints/steps/#ActivateThemeStep
@@ -49,7 +49,7 @@
49
49
  throw new Exception( 'Theme ' . getenv('themeFolderName') . ' could not be activated.' );
50
50
  }
51
51
  die('Theme activated successfully');
52
- `,env:{docroot:d,themeFolderName:t}});if(i.text!=="Theme activated successfully")throw ne.logger.debug(i),new Error(`Theme ${t} could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details`)},yr=async(r,{code:t})=>await r.run({code:t}),hr=async(r,{options:t})=>await r.run(t),tr=async(r,{path:t})=>{await r.unlink(t)},gr=async(r,{sql:t},f)=>{f==null||f.tracker.setCaption("Executing SQL Queries");const d=`/tmp/${C.randomFilename()}.sql`;await r.writeFile(d,new Uint8Array(await t.arrayBuffer()));const c=await r.documentRoot,i=C.phpVars({docroot:c,sqlFilename:d}),e=await r.run({code:`<?php
52
+ `,env:{docroot:c,themeFolderName:t}});if(i.text!=="Theme activated successfully")throw ce.logger.debug(i),new Error(`Theme ${t} could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details`)},Or=async(r,{code:t})=>await r.run({code:t}),$r=async(r,{options:t})=>await r.run(t),lr=async(r,{path:t})=>{await r.unlink(t)},Er=async(r,{sql:t},p)=>{p==null||p.tracker.setCaption("Executing SQL Queries");const c=`/tmp/${W.randomFilename()}.sql`;await r.writeFile(c,new Uint8Array(await t.arrayBuffer()));const h=await r.documentRoot,i=W.phpVars({docroot:h,sqlFilename:c}),e=await r.run({code:`<?php
53
53
  require_once ${i.docroot} . '/wp-load.php';
54
54
 
55
55
  $handle = fopen(${i.sqlFilename}, 'r');
@@ -68,7 +68,7 @@
68
68
  $wpdb->query($buffer);
69
69
  $buffer = '';
70
70
  }
71
- `});return await tr(r,{path:d}),e},He=async(r,{request:t})=>{ne.logger.warn('Deprecated: The Blueprint step "request" is deprecated and will be removed in a future release.');const f=await r.request(t);if(f.httpStatusCode>399||f.httpStatusCode<200)throw ne.logger.warn("WordPress response was",{response:f}),new Error(`Request failed with status ${f.httpStatusCode}`);return f},Ur=`<?php
71
+ `});return await lr(r,{path:c}),e},jr=async(r,{request:t})=>{ce.logger.warn('Deprecated: The Blueprint step "request" is deprecated and will be removed in a future release.');const p=await r.request(t);if(p.httpStatusCode>399||p.httpStatusCode<200)throw ce.logger.warn("WordPress response was",{response:p}),new Error(`Request failed with status ${p.httpStatusCode}`);return p},Jr=`<?php
72
72
 
73
73
  /**
74
74
  * Rewrites the wp-config.php file to ensure specific constants are defined
@@ -399,69 +399,55 @@ function skip_whitespace($tokens) {
399
399
  }
400
400
  return $output;
401
401
  }
402
- `,Ae=async(r,{consts:t,method:f="define-before-run"})=>{switch(f){case"define-before-run":await Br(r,t);break;case"rewrite-wp-config":{const d=await r.documentRoot,c=C.joinPaths(d,"/wp-config.php"),i=await r.readFileAsText(c),e=await Vr(r,i,t);await r.writeFile(c,e);break}default:throw new Error(`Invalid method: ${f}`)}};async function Br(r,t){for(const f in t)await r.defineConstant(f,t[f])}async function Vr(r,t,f){await r.writeFile("/tmp/code.php",t);const d=C.phpVars({consts:f});return await r.run({code:`${Ur}
402
+ `,Ke=async(r,{consts:t,method:p="define-before-run"})=>{switch(p){case"define-before-run":await Kr(r,t);break;case"rewrite-wp-config":{const c=await r.documentRoot,h=W.joinPaths(c,"/wp-config.php"),i=await r.readFileAsText(h),e=await et(r,i,t);await r.writeFile(h,e);break}default:throw new Error(`Invalid method: ${p}`)}};async function Kr(r,t){for(const p in t)await r.defineConstant(p,t[p])}async function et(r,t,p){await r.writeFile("/tmp/code.php",t);const c=W.phpVars({consts:p});return await r.run({code:`${Jr}
403
403
  $wp_config_path = '/tmp/code.php';
404
404
  $wp_config = file_get_contents($wp_config_path);
405
- $new_wp_config = rewrite_wp_config_to_define_constants($wp_config, ${d.consts});
405
+ $new_wp_config = rewrite_wp_config_to_define_constants($wp_config, ${c.consts});
406
406
  file_put_contents($wp_config_path, $new_wp_config);
407
- `}),await r.readFileAsText("/tmp/code.php")}const Ge=async(r,{username:t="admin",password:f="password"}={},d)=>{var i,e,u;d==null||d.tracker.setCaption((d==null?void 0:d.initialCaption)||"Logging in"),await r.request({url:"/wp-login.php"});const c=await r.request({url:"/wp-login.php",method:"POST",body:{log:t,pwd:f,rememberme:"forever"}});if(!((u=(e=(i=c.headers)==null?void 0:i.location)==null?void 0:e[0])!=null&&u.includes("/wp-admin/")))throw ne.logger.warn("WordPress response was",{response:c,text:c.text}),new Error(`Failed to log in as ${t} with password ${f}`)},sr=async(r,{options:t})=>{const f=await r.documentRoot;await r.run({code:`<?php
408
- include ${C.phpVar(f)} . '/wp-load.php';
409
- $site_options = ${C.phpVar(t)};
407
+ `}),await r.readFileAsText("/tmp/code.php")}const dr=async(r,{options:t})=>{const p=await r.documentRoot;await r.run({code:`<?php
408
+ include ${W.phpVar(p)} . '/wp-load.php';
409
+ $site_options = ${W.phpVar(t)};
410
410
  foreach($site_options as $name => $value) {
411
411
  update_option($name, $value);
412
412
  }
413
413
  echo "Success";
414
- `})},br=async(r,{meta:t,userId:f})=>{const d=await r.documentRoot;await r.run({code:`<?php
415
- include ${C.phpVar(d)} . '/wp-load.php';
416
- $meta = ${C.phpVar(t)};
414
+ `})},Tr=async(r,{meta:t,userId:p})=>{const c=await r.documentRoot;await r.run({code:`<?php
415
+ include ${W.phpVar(c)} . '/wp-load.php';
416
+ $meta = ${W.phpVar(t)};
417
417
  foreach($meta as $name => $value) {
418
- update_user_meta(${C.phpVar(f)}, $name, $value);
418
+ update_user_meta(${W.phpVar(p)}, $name, $value);
419
419
  }
420
- `})},wr=async r=>{var R;await Ae(r,{consts:{WP_ALLOW_MULTISITE:1}});const t=new URL(await r.absoluteUrl);if(t.port!==""){let M=`The current host is ${t.host}, but WordPress multisites do not support custom ports.`;throw t.hostname==="localhost"&&(M+=" For development, you can set up a playground.test domain using the instructions at https://wordpress.github.io/wordpress-playground/contributing/code."),new Error(M)}const f=t.pathname.replace(/\/$/,"")+"/",d=`${t.protocol}//${t.hostname}${f}`;await sr(r,{options:{siteurl:d,home:d}}),await Ge(r,{});const c=await r.documentRoot,e=(await r.run({code:`<?php
421
- define( 'WP_ADMIN', true );
422
- require_once(${C.phpVar(c)} . "/wp-load.php");
423
-
424
- // Set current user to admin
425
- ( get_users(array('role' => 'Administrator') )[0] );
426
-
427
- require_once(${C.phpVar(c)} . "/wp-admin/includes/plugin.php");
428
- $plugins_root = ${C.phpVar(c)} . "/wp-content/plugins";
429
- $plugins = glob($plugins_root . "/*");
430
-
431
- $deactivated_plugins = [];
432
- foreach($plugins as $plugin_path) {
433
- if (str_ends_with($plugin_path, '/index.php')) {
434
- continue;
435
- }
436
- if (!is_dir($plugin_path)) {
437
- $deactivated_plugins[] = substr($plugin_path, strlen($plugins_root) + 1);
438
- deactivate_plugins($plugin_path);
439
- continue;
440
- }
441
- // Find plugin entry file
442
- foreach ( ( glob( $plugin_path . '/*.php' ) ?: array() ) as $file ) {
443
- $info = get_plugin_data( $file, false, false );
444
- if ( ! empty( $info['Name'] ) ) {
445
- deactivate_plugins( $file );
446
- $deactivated_plugins[] = substr($file, strlen($plugins_root) + 1);
447
- break;
448
- }
449
- }
450
- }
451
- echo json_encode($deactivated_plugins);
452
- `})).json,O=(R=(await He(r,{request:{url:"/wp-admin/network.php"}})).text.match(/name="_wpnonce"\s+value="([^"]+)"/))==null?void 0:R[1],V=await He(r,{request:{url:"/wp-admin/network.php",method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:Dr({_wpnonce:O,_wp_http_referer:f+"wp-admin/network.php",sitename:"My WordPress Website Sites",email:"admin@localhost.com",submit:"Install"})}});if(V.httpStatusCode!==200)throw ne.logger.warn("WordPress response was",{response:V,text:V.text,headers:V.headers}),new Error(`Failed to enable multisite. Response code was ${V.httpStatusCode}`);await Ae(r,{consts:{MULTISITE:!0,SUBDOMAIN_INSTALL:!1,SITE_ID_CURRENT_SITE:1,BLOG_ID_CURRENT_SITE:1,DOMAIN_CURRENT_SITE:t.hostname,PATH_CURRENT_SITE:f}});const U=new URL(await r.absoluteUrl),v=fr.isURLScoped(U)?"scope:"+fr.getURLScope(U):null;await r.writeFile("/internal/shared/preload/sunrise.php",`<?php
453
- $_SERVER['HTTP_HOST'] = ${C.phpVar(U.hostname)};
454
- $folder = ${C.phpVar(v)};
455
- if ($folder && strpos($_SERVER['REQUEST_URI'],"/$folder") === false) {
456
- $_SERVER['REQUEST_URI'] = "/$folder/" . ltrim($_SERVER['REQUEST_URI'], '/');
457
- }
458
- `),await r.writeFile("/internal/shared/mu-plugins/sunrise.php",`<?php
459
- if ( !defined( 'BLOG_ID_CURRENT_SITE' ) ) {
460
- define( 'BLOG_ID_CURRENT_SITE', 1 );
461
- }
462
- `),await Ge(r,{});for(const M of e)try{await Ye(r,{pluginPath:M})}catch(W){ne.logger.error("Error activating plugin",M,W)}};function Dr(r){return Object.keys(r).map(t=>encodeURIComponent(t)+"="+encodeURIComponent(r[t])).join("&")}const vr=async(r,{fromPath:t,toPath:f})=>{await r.writeFile(f,await r.readFileAsBuffer(t))},Pr=async(r,{fromPath:t,toPath:f})=>{await r.mv(t,f)},_r=async(r,{path:t})=>{await r.mkdir(t)},kr=async(r,{path:t})=>{await r.rmdir(t)},ir=async(r,{path:t,data:f})=>{f instanceof File&&(f=new Uint8Array(await f.arrayBuffer())),t.startsWith("/wordpress/wp-content/mu-plugins")&&!await r.fileExists("/wordpress/wp-content/mu-plugins")&&await r.mkdir("/wordpress/wp-content/mu-plugins"),await r.writeFile(t,f)},or=async(r,{siteUrl:t})=>{await Ae(r,{consts:{WP_HOME:t,WP_SITEURL:t}})},Or=async(r,{file:t},f)=>{var c;(c=f==null?void 0:f.tracker)==null||c.setCaption("Importing content"),await ir(r,{path:"/tmp/import.wxr",data:t});const d=await r.documentRoot;await r.run({code:`<?php
463
- require ${C.phpVar(d)} . '/wp-load.php';
464
- require ${C.phpVar(d)} . '/wp-admin/includes/admin.php';
420
+ `})},ur="/tmp/wp-cli.phar",rt={resource:"url",url:"https://playground.wordpress.net/wp-cli.phar"},qr=async(r,t=ur)=>{if(!await r.fileExists(t))throw new Error(`wp-cli.phar not found at ${t}.
421
+ You can enable wp-cli support by adding "wp-cli" to the list of extra libraries in your blueprint as follows:
422
+ {
423
+ "extraLibraries": [ "wp-cli" ]
424
+ }
425
+ Read more about it in the documentation.
426
+ https://wordpress.github.io/wordpress-playground/blueprints/data-format#extra-libraries`)},cr=async(r,{command:t,wpCliPath:p=ur})=>{await qr(r,p);let c;if(typeof t=="string"?(t=t.trim(),c=tt(t)):c=t,c.shift()!=="wp")throw new Error('The first argument must be "wp".');const i=await r.documentRoot;await r.writeFile("/tmp/stdout",""),await r.writeFile("/tmp/stderr",""),await r.writeFile(W.joinPaths(i,"run-cli.php"),`<?php
427
+ // Set up the environment to emulate a shell script
428
+ // call.
429
+
430
+ // Set SHELL_PIPE to 0 to ensure WP-CLI formats
431
+ // the output as ASCII tables.
432
+ // @see https://github.com/wp-cli/wp-cli/issues/1102
433
+ putenv( 'SHELL_PIPE=0' );
434
+
435
+ // Set the argv global.
436
+ $GLOBALS['argv'] = array_merge([
437
+ "/tmp/wp-cli.phar",
438
+ "--path=${i}"
439
+ ], ${W.phpVar(c)});
440
+
441
+ // Provide stdin, stdout, stderr streams outside of
442
+ // the CLI SAPI.
443
+ define('STDIN', fopen('php://stdin', 'rb'));
444
+ define('STDOUT', fopen('php://stdout', 'wb'));
445
+ define('STDERR', fopen('php://stderr', 'wb'));
446
+
447
+ require( ${W.phpVar(p)} );
448
+ `);const e=await r.run({scriptPath:W.joinPaths(i,"run-cli.php")});if(e.errors)throw new Error(e.errors);return e};function tt(r){let c=0,h="";const i=[];let e="";for(let d=0;d<r.length;d++){const g=r[d];c===0?g==='"'||g==="'"?(c=1,h=g):g.match(/\s/)?(e&&i.push(e),e=""):e+=g:c===1&&(g==="\\"?(d++,e+=r[d]):g===h?(c=0,h=""):e+=g)}return e&&i.push(e),i}const Ar=async(r,{wpCliPath:t})=>{await qr(r,t),await Ke(r,{consts:{WP_ALLOW_MULTISITE:1}});const p=new URL(await r.absoluteUrl);if(p.port!==""){let i=`The current host is ${p.host}, but WordPress multisites do not support custom ports.`;throw p.hostname==="localhost"&&(i+=" For development, you can set up a playground.test domain using the instructions at https://wordpress.github.io/wordpress-playground/contributing/code."),new Error(i)}const c=p.pathname.replace(/\/$/,"")+"/",h=`${p.protocol}//${p.hostname}${c}`;await dr(r,{options:{siteurl:h,home:h}}),await cr(r,{command:`wp core multisite-convert --base="${c}"`})},Rr=async(r,{fromPath:t,toPath:p})=>{await r.writeFile(p,await r.readFileAsBuffer(t))},Lr=async(r,{fromPath:t,toPath:p})=>{await r.mv(t,p)},Fr=async(r,{path:t})=>{await r.mkdir(t)},Sr=async(r,{path:t})=>{await r.rmdir(t)},mr=async(r,{path:t,data:p})=>{p instanceof File&&(p=new Uint8Array(await p.arrayBuffer())),t.startsWith("/wordpress/wp-content/mu-plugins")&&!await r.fileExists("/wordpress/wp-content/mu-plugins")&&await r.mkdir("/wordpress/wp-content/mu-plugins"),await r.writeFile(t,p)},Nr=async(r,{writeToPath:t,filesTree:p})=>{await Ne.writeFiles(r,t,p.files)},yr=async(r,{siteUrl:t})=>{await Ke(r,{consts:{WP_HOME:t,WP_SITEURL:t}})},Dr=async(r,{file:t},p)=>{var h;(h=p==null?void 0:p.tracker)==null||h.setCaption("Importing content"),await mr(r,{path:"/tmp/import.wxr",data:t});const c=await r.documentRoot;await r.run({code:`<?php
449
+ require ${W.phpVar(c)} . '/wp-load.php';
450
+ require ${W.phpVar(c)} . '/wp-admin/includes/admin.php';
465
451
 
466
452
  kses_remove_filters();
467
453
  $admin_id = get_users(array('role' => 'Administrator') )[0]->ID;
@@ -479,7 +465,7 @@ echo json_encode($deactivated_plugins);
479
465
  });
480
466
 
481
467
  $result = $importer->import( '/tmp/import.wxr' );
482
- `})},nr=async(r,{themeSlug:t=""},f)=>{var c;(c=f==null?void 0:f.tracker)==null||c.setCaption("Importing theme starter content");const d=await r.documentRoot;await r.run({code:`<?php
468
+ `})},hr=async(r,{themeSlug:t=""},p)=>{var h;(h=p==null?void 0:p.tracker)==null||h.setCaption("Importing theme starter content");const c=await r.documentRoot;await r.run({code:`<?php
483
469
 
484
470
  /**
485
471
  * Ensure that the customizer loads as an admin user.
@@ -502,7 +488,7 @@ echo json_encode($deactivated_plugins);
502
488
  * See _wp_customize_include()
503
489
  */
504
490
  $_REQUEST['wp_customize'] = 'on';
505
- $_REQUEST['customize_theme'] = ${C.phpVar(t)} ?: get_stylesheet();
491
+ $_REQUEST['customize_theme'] = ${W.phpVar(t)} ?: get_stylesheet();
506
492
 
507
493
  /*
508
494
  * Claim this is a ajax request saving settings, to avoid the preview filters being applied.
@@ -514,7 +500,7 @@ echo json_encode($deactivated_plugins);
514
500
  }
515
501
  playground_add_filter( 'plugins_loaded', 'importThemeStarterContent_plugins_loaded', 0 );
516
502
 
517
- require ${C.phpVar(d)} . '/wp-load.php';
503
+ require ${W.phpVar(c)} . '/wp-load.php';
518
504
 
519
505
  // Return early if there's no starter content.
520
506
  if ( ! get_theme_starter_content() ) {
@@ -526,10 +512,10 @@ echo json_encode($deactivated_plugins);
526
512
 
527
513
  // Publish the changeset, which publishes the starter content.
528
514
  wp_publish_post( $wp_customize->changeset_post_id() );
529
- `})},Ze=async(r,{zipFile:t,zipPath:f,extractToPath:d})=>{if(f)ne.logger.warn('The "zipPath" option of the unzip() Blueprint step is deprecated and will be removed. Use "zipFile" instead.');else if(!t)throw new Error("Either zipPath or zipFile must be provided");await cr.unzipFile(r,t||f,d)},$r=async(r,{wordPressFilesZip:t,pathInZip:f=""})=>{const d=await r.documentRoot;let c=C.joinPaths("/tmp","import");await r.mkdir(c),await Ze(r,{zipFile:t,extractToPath:c}),c=C.joinPaths(c,f);const i=C.joinPaths(c,"wp-content"),e=C.joinPaths(d,"wp-content");for(const U of er){const v=C.joinPaths(i,U);await lr(r,v);const R=C.joinPaths(e,U);await r.fileExists(R)&&(await r.mkdir(C.dirname(v)),await r.mv(R,v))}const u=C.joinPaths(c,"wp-content","database");await r.fileExists(u)||await r.mv(C.joinPaths(d,"wp-content","database"),u);const O=await r.listFiles(c);for(const U of O)await lr(r,C.joinPaths(d,U)),await r.mv(C.joinPaths(c,U),C.joinPaths(d,U));await r.rmdir(c),await or(r,{siteUrl:await r.absoluteUrl});const V=C.phpVar(C.joinPaths(d,"wp-admin","upgrade.php"));await r.run({code:`<?php
515
+ `})},er=async(r,{zipFile:t,zipPath:p,extractToPath:c})=>{if(p)ce.logger.warn('The "zipPath" option of the unzip() Blueprint step is deprecated and will be removed. Use "zipFile" instead.');else if(!t)throw new Error("Either zipPath or zipFile must be provided");await _r.unzipFile(r,t||p,c)},xr=async(r,{wordPressFilesZip:t,pathInZip:p=""})=>{const c=await r.documentRoot;let h=W.joinPaths("/tmp","import");await r.mkdir(h),await er(r,{zipFile:t,extractToPath:h}),h=W.joinPaths(h,p);const i=W.joinPaths(h,"wp-content"),e=W.joinPaths(c,"wp-content");for(const T of ar){const P=W.joinPaths(i,T);await wr(r,P);const E=W.joinPaths(e,T);await r.fileExists(E)&&(await r.mkdir(W.dirname(P)),await r.mv(E,P))}const d=W.joinPaths(h,"wp-content","database");await r.fileExists(d)||await r.mv(W.joinPaths(c,"wp-content","database"),d);const g=await r.listFiles(h);for(const T of g)await wr(r,W.joinPaths(c,T)),await r.mv(W.joinPaths(h,T),W.joinPaths(c,T));await r.rmdir(h),await yr(r,{siteUrl:await r.absoluteUrl});const x=W.phpVar(W.joinPaths(c,"wp-admin","upgrade.php"));await r.run({code:`<?php
530
516
  $_GET['step'] = 'upgrade_db';
531
- require ${V};
532
- `})};async function lr(r,t){await r.fileExists(t)&&(await r.isDir(t)?await r.rmdir(t):await r.unlink(t))}async function Er(r){const t=await r.request({url:"/wp-admin/export.php?download=true&content=all"});return new File([t.bytes],"export.xml")}async function jr(r,{targetPath:t,zipFile:f,ifAlreadyInstalled:d="overwrite"}){const i=f.name.replace(/\.zip$/,""),e=C.joinPaths(await r.documentRoot,"wp-content"),u=C.joinPaths(e,C.randomString()),O=C.joinPaths(u,"assets",i);await r.fileExists(O)&&await r.rmdir(u,{recursive:!0}),await r.mkdir(u);try{await Ze(r,{zipFile:f,extractToPath:O});let V=await r.listFiles(O,{prependPath:!0});V=V.filter(W=>!W.endsWith("/__MACOSX"));const U=V.length===1&&await r.isDir(V[0]);let v,R="";U?(R=V[0],v=V[0].split("/").pop()):(R=O,v=i);const M=`${t}/${v}`;if(await r.fileExists(M)){if(!await r.isDir(M))throw new Error(`Cannot install asset ${v} to ${M} because a file with the same name already exists. Note it's a file, not a directory! Is this by mistake?`);if(d==="overwrite")await r.rmdir(M,{recursive:!0});else{if(d==="skip")return{assetFolderPath:M,assetFolderName:v};throw new Error(`Cannot install asset ${v} to ${t} because it already exists and the ifAlreadyInstalled option was set to ${d}`)}}return await r.mv(R,M),{assetFolderPath:M,assetFolderName:v}}finally{await r.rmdir(u,{recursive:!0})}}function Qe(r){const t=r.split(".").shift().replace(/-/g," ");return t.charAt(0).toUpperCase()+t.slice(1).toLowerCase()}const Tr=async(r,{pluginZipFile:t,ifAlreadyInstalled:f,options:d={}},c)=>{const i=t.name.split("/").pop()||"plugin.zip",e=Qe(i);c==null||c.tracker.setCaption(`Installing the ${e} plugin`);const{assetFolderPath:u}=await jr(r,{ifAlreadyInstalled:f,zipFile:t,targetPath:`${await r.documentRoot}/wp-content/plugins`});("activate"in d?d.activate:!0)&&await Ye(r,{pluginPath:u,pluginName:e},c)},qr=async(r,{themeZipFile:t,ifAlreadyInstalled:f,options:d={}},c)=>{const i=Qe(t.name);c==null||c.tracker.setCaption(`Installing the ${i} theme`);const{assetFolderName:e}=await jr(r,{ifAlreadyInstalled:f,zipFile:t,targetPath:`${await r.documentRoot}/wp-content/themes`});("activate"in d?d.activate:!0)&&await rr(r,{themeFolderName:e},c),("importStarterContent"in d?d.importStarterContent:!1)&&await nr(r,{themeSlug:e},c)},Ar=async(r,t,f)=>{var c;(c=f==null?void 0:f.tracker)==null||c.setCaption("Resetting WordPress data");const d=await r.documentRoot;await r.run({env:{DOCROOT:d},code:`<?php
517
+ require ${x};
518
+ `})};async function wr(r,t){await r.fileExists(t)&&(await r.isDir(t)?await r.rmdir(t):await r.unlink(t))}async function Cr(r){const t=await r.request({url:"/wp-admin/export.php?download=true&content=all"});return new File([t.bytes],"export.xml")}async function Wr(r,{targetPath:t,zipFile:p,ifAlreadyInstalled:c="overwrite",targetFolderName:h=""}){const e=p.name.replace(/\.zip$/,""),d=W.joinPaths(await r.documentRoot,"wp-content"),g=W.joinPaths(d,W.randomString()),x=W.joinPaths(g,"assets",e);await r.fileExists(x)&&await r.rmdir(g,{recursive:!0}),await r.mkdir(g);try{await er(r,{zipFile:p,extractToPath:x});let T=await r.listFiles(x,{prependPath:!0});T=T.filter(y=>!y.endsWith("/__MACOSX"));const P=T.length===1&&await r.isDir(T[0]);let E,L="";P?(L=T[0],E=T[0].split("/").pop()):(L=x,E=e),h&&h.length&&(E=h);const N=`${t}/${E}`;if(await r.fileExists(N)){if(!await r.isDir(N))throw new Error(`Cannot install asset ${E} to ${N} because a file with the same name already exists. Note it's a file, not a directory! Is this by mistake?`);if(c==="overwrite")await r.rmdir(N,{recursive:!0});else{if(c==="skip")return{assetFolderPath:N,assetFolderName:E};throw new Error(`Cannot install asset ${E} to ${t} because it already exists and the ifAlreadyInstalled option was set to ${c}`)}}return await r.mv(L,N),{assetFolderPath:N,assetFolderName:E}}finally{await r.rmdir(g,{recursive:!0})}}function rr(r){const t=r.split(".").shift().replace(/-/g," ");return t.charAt(0).toUpperCase()+t.slice(1).toLowerCase()}const Ir=async(r,{pluginData:t,pluginZipFile:p,ifAlreadyInstalled:c,options:h={}},i)=>{p&&(t=p,ce.logger.warn('The "pluginZipFile" option is deprecated. Use "pluginData" instead.'));const e="targetFolderName"in h?h.targetFolderName:"";let d="",g="";if(t instanceof File){const T=t.name.split("/").pop()||"plugin.zip";g=rr(T),i==null||i.tracker.setCaption(`Installing the ${g} plugin`);const P=await Wr(r,{ifAlreadyInstalled:c,zipFile:t,targetPath:`${await r.documentRoot}/wp-content/plugins`,targetFolderName:e});d=P.assetFolderPath,g=P.assetFolderName}else if(t){g=t.name,i==null||i.tracker.setCaption(`Installing the ${g} plugin`);const T=W.joinPaths(await r.documentRoot,"wp-content","plugins",e||t.name);await Ne.writeFiles(r,T,t.files,{rmRoot:!0}),d=T}("activate"in h?h.activate:!0)&&await pr(r,{pluginPath:d,pluginName:g},i)},Ur=async(r,{themeData:t,themeZipFile:p,ifAlreadyInstalled:c,options:h={}},i)=>{p&&(t=p,ce.logger.warn('The "themeZipFile" option is deprecated. Use "themeData" instead.'));const e="targetFolderName"in h?h.targetFolderName:"";let d="",g="";if(t instanceof File){const P=t.name.split("/").pop()||"theme.zip";g=rr(P),i==null||i.tracker.setCaption(`Installing the ${g} theme`),d=(await Wr(r,{ifAlreadyInstalled:c,zipFile:t,targetPath:`${await r.documentRoot}/wp-content/themes`,targetFolderName:e})).assetFolderName}else{g=t.name,d=e||g,i==null||i.tracker.setCaption(`Installing the ${g} theme`);const P=W.joinPaths(await r.documentRoot,"wp-content","themes",d);await Ne.writeFiles(r,P,t.files,{rmRoot:!0})}("activate"in h?h.activate:!0)&&await fr(r,{themeFolderName:d},i),("importStarterContent"in h?h.importStarterContent:!1)&&await hr(r,{themeSlug:d},i)},Vr=async(r,{username:t="admin"}={},p)=>{p==null||p.tracker.setCaption((p==null?void 0:p.initialCaption)||"Logging in"),r.defineConstant("PLAYGROUND_AUTO_LOGIN_AS_USER",t)},Mr=async(r,t,p)=>{var h;(h=p==null?void 0:p.tracker)==null||h.setCaption("Resetting WordPress data");const c=await r.documentRoot;await r.run({env:{DOCROOT:c},code:`<?php
533
519
  require getenv('DOCROOT') . '/wp-load.php';
534
520
 
535
521
  $GLOBALS['@pdo']->query('DELETE FROM wp_posts WHERE id > 0');
@@ -543,11 +529,11 @@ echo json_encode($deactivated_plugins);
543
529
 
544
530
  $GLOBALS['@pdo']->query('DELETE FROM wp_commentmeta');
545
531
  $GLOBALS['@pdo']->query("UPDATE SQLITE_SEQUENCE SET SEQ=0 WHERE NAME='wp_commentmeta'");
546
- `})},Rr=async(r,{options:t})=>{await r.request({url:"/wp-admin/install.php?step=2",method:"POST",body:{language:"en",prefix:"wp_",weblog_title:"My WordPress Website",user_name:t.adminPassword||"admin",admin_password:t.adminPassword||"password",admin_password2:t.adminPassword||"password",Submit:"Install WordPress",pw_weak:"1",admin_email:"admin@localhost.com"}})},Sr=async(r,{selfContained:t=!1}={})=>{const f="/tmp/wordpress-playground.zip",d=await r.documentRoot,c=C.joinPaths(d,"wp-content");let i=er;t&&(i=i.filter(O=>!O.startsWith("themes/twenty")).filter(O=>O!=="mu-plugins/sqlite-database-integration"));const e=C.phpVars({zipPath:f,wpContentPath:c,documentRoot:d,exceptPaths:i.map(O=>C.joinPaths(d,"wp-content",O)),additionalPaths:t?{[C.joinPaths(d,"wp-config.php")]:"wp-config.php"}:{}});await zr(r,`zipDir(${e.wpContentPath}, ${e.zipPath}, array(
532
+ `})},zr=async(r,{options:t})=>{await r.request({url:"/wp-admin/install.php?step=2",method:"POST",body:{language:"en",prefix:"wp_",weblog_title:"My WordPress Website",user_name:t.adminPassword||"admin",admin_password:t.adminPassword||"password",admin_password2:t.adminPassword||"password",Submit:"Install WordPress",pw_weak:"1",admin_email:"admin@localhost.com"}})},Br=async(r,{selfContained:t=!1}={})=>{const p="/tmp/wordpress-playground.zip",c=await r.documentRoot,h=W.joinPaths(c,"wp-content");let i=ar;t&&(i=i.filter(g=>!g.startsWith("themes/twenty")).filter(g=>g!=="mu-plugins/sqlite-database-integration"));const e=W.phpVars({zipPath:p,wpContentPath:h,documentRoot:c,exceptPaths:i.map(g=>W.joinPaths(c,"wp-content",g)),additionalPaths:t?{[W.joinPaths(c,"wp-config.php")]:"wp-config.php"}:{}});await it(r,`zipDir(${e.wpContentPath}, ${e.zipPath}, array(
547
533
  'exclude_paths' => ${e.exceptPaths},
548
534
  'zip_root' => ${e.documentRoot},
549
535
  'additional_paths' => ${e.additionalPaths}
550
- ));`);const u=await r.readFileAsBuffer(f);return r.unlink(f),u},Mr=`<?php
536
+ ));`);const d=await r.readFileAsBuffer(p);return r.unlink(p),d},st=`<?php
551
537
 
552
538
  function zipDir($root, $output, $options = array())
553
539
  {
@@ -606,41 +592,12 @@ function join_paths()
606
592
 
607
593
  return preg_replace('#/+#', '/', join('/', $paths));
608
594
  }
609
- `;async function zr(r,t){return await r.run({code:Mr+t})}const Lr=async(r,{command:t,wpCliPath:f="/tmp/wp-cli.phar"})=>{if(!await r.fileExists(f))throw new Error(`wp-cli.phar not found at ${f}.
610
- You can enable wp-cli support by adding "wp-cli" to the list of extra libraries in your blueprint as follows:
611
- {
612
- "extraLibraries": [ "wp-cli" ]
613
- }
614
-
615
- Read more about it in the documentation.
616
- https://wordpress.github.io/wordpress-playground/blueprints/data-format#extra-libraries`);let d;if(typeof t=="string"?(t=t.trim(),d=Hr(t)):d=t,d.shift()!=="wp")throw new Error('The first argument must be "wp".');await r.writeFile("/tmp/stdout",""),await r.writeFile("/tmp/stderr",""),await r.writeFile("/wordpress/run-cli.php",`<?php
617
- // Set up the environment to emulate a shell script
618
- // call.
619
-
620
- // Set SHELL_PIPE to 0 to ensure WP-CLI formats
621
- // the output as ASCII tables.
622
- // @see https://github.com/wp-cli/wp-cli/issues/1102
623
- putenv( 'SHELL_PIPE=0' );
624
-
625
- // Set the argv global.
626
- $GLOBALS['argv'] = array_merge([
627
- "/tmp/wp-cli.phar",
628
- "--path=/wordpress"
629
- ], ${C.phpVar(d)});
630
-
631
- // Provide stdin, stdout, stderr streams outside of
632
- // the CLI SAPI.
633
- define('STDIN', fopen('php://stdin', 'rb'));
634
- define('STDOUT', fopen('php://stdout', 'wb'));
635
- define('STDERR', fopen('php://stderr', 'wb'));
636
-
637
- require( ${C.phpVar(f)} );
638
- `);const i=await r.run({scriptPath:"/wordpress/run-cli.php"});if(i.errors)throw new Error(i.errors);return i};function Hr(r){let d=0,c="";const i=[];let e="";for(let u=0;u<r.length;u++){const O=r[u];d===0?O==='"'||O==="'"?(d=1,c=O):O.match(/\s/)?(e&&i.push(e),e=""):e+=O:d===1&&(O==="\\"?(u++,e+=r[u]):O===c?(d=0,c=""):e+=O)}return e&&i.push(e),i}const Nr=async(r,{language:t},f)=>{f==null||f.tracker.setCaption((f==null?void 0:f.initialCaption)||"Translating"),await r.defineConstant("WPLANG",t);const d=await r.documentRoot,i=[{url:`https://downloads.wordpress.org/translation/core/${(await r.run({code:`<?php
639
- require '${d}/wp-includes/version.php';
595
+ `;async function it(r,t){return await r.run({code:st+t})}const Hr=async(r,{language:t},p)=>{p==null||p.tracker.setCaption((p==null?void 0:p.initialCaption)||"Translating"),await r.defineConstant("WPLANG",t);const c=await r.documentRoot,i=[{url:`https://downloads.wordpress.org/translation/core/${(await r.run({code:`<?php
596
+ require '${c}/wp-includes/version.php';
640
597
  echo $wp_version;
641
- `})).text}/${t}.zip`,type:"core"}],u=(await r.run({code:`<?php
642
- require_once('${d}/wp-load.php');
643
- require_once('${d}/wp-admin/includes/plugin.php');
598
+ `})).text}/${t}.zip`,type:"core"}],d=(await r.run({code:`<?php
599
+ require_once('${c}/wp-load.php');
600
+ require_once('${c}/wp-admin/includes/plugin.php');
644
601
  echo json_encode(
645
602
  array_values(
646
603
  array_map(
@@ -658,9 +615,9 @@ function join_paths()
658
615
  )
659
616
  )
660
617
  )
661
- );`})).json;for(const{slug:U,version:v}of u)i.push({url:`https://downloads.wordpress.org/translation/plugin/${U}/${v}/${t}.zip`,type:"plugin"});const V=(await r.run({code:`<?php
662
- require_once('${d}/wp-load.php');
663
- require_once('${d}/wp-admin/includes/theme.php');
618
+ );`})).json;for(const{slug:T,version:P}of d)i.push({url:`https://downloads.wordpress.org/translation/plugin/${T}/${P}/${t}.zip`,type:"plugin"});const x=(await r.run({code:`<?php
619
+ require_once('${c}/wp-load.php');
620
+ require_once('${c}/wp-admin/includes/theme.php');
664
621
  echo json_encode(
665
622
  array_values(
666
623
  array_map(
@@ -673,7 +630,7 @@ function join_paths()
673
630
  wp_get_themes()
674
631
  )
675
632
  )
676
- );`})).json;for(const{slug:U,version:v}of V)i.push({url:`https://downloads.wordpress.org/translation/theme/${U}/${v}/${t}.zip`,type:"theme"});await r.isDir(`${d}/wp-content/languages/plugins`)||await r.mkdir(`${d}/wp-content/languages/plugins`),await r.isDir(`${d}/wp-content/languages/themes`)||await r.mkdir(`${d}/wp-content/languages/themes`);for(const{url:U,type:v}of i)try{const R=await fetch(U);if(!R.ok)throw new Error(`Failed to download translations for ${v}: ${R.statusText}`);let M=`${d}/wp-content/languages`;v==="plugin"?M+="/plugins":v==="theme"&&(M+="/themes"),await cr.unzipFile(r,new File([await R.blob()],`${t}-${v}.zip`),M)}catch(R){if(v==="core")throw new Error(`Failed to download translations for WordPress. Please check if the language code ${t} is correct. You can find all available languages and translations on https://translate.wordpress.org/.`);ne.logger.warn(`Error downloading translations for ${v}: ${R}`)}},Gr=Object.freeze(Object.defineProperty({__proto__:null,activatePlugin:Ye,activateTheme:rr,cp:vr,defineSiteUrl:or,defineWpConfigConsts:Ae,enableMultisite:wr,exportWXR:Er,importThemeStarterContent:nr,importWordPressFiles:$r,importWxr:Or,installPlugin:Tr,installTheme:qr,login:Ge,mkdir:_r,mv:Pr,request:He,resetData:Ar,rm:tr,rmdir:kr,runPHP:yr,runPHPWithOptions:hr,runSql:gr,runWpInstallationWizard:Rr,setSiteLanguage:Nr,setSiteOptions:sr,unzip:Ze,updateUserMeta:br,wpCLI:Lr,writeFile:ir,zipWpContent:Sr},Symbol.toStringTag,{value:"Module"})),Yr=["vfs","literal","wordpress.org/themes","wordpress.org/plugins","url"];function Zr(r){return r&&typeof r=="object"&&typeof r.resource=="string"&&Yr.includes(r.resource)}class $e{static create(t,{semaphore:f,progress:d}){let c;switch(t.resource){case"vfs":c=new Qr(t,d);break;case"literal":c=new Xr(t,d);break;case"wordpress.org/themes":c=new et(t,d);break;case"wordpress.org/plugins":c=new rt(t,d);break;case"url":c=new Kr(t,d);break;default:throw new Error(`Invalid resource: ${t}`)}return c=new tt(c),f&&(c=new st(c,f)),c}setPlayground(t){this.playground=t}get isAsync(){return!1}}class Qr extends $e{constructor(t,f){super(),this.resource=t,this.progress=f}async resolve(){var f;const t=await this.playground.readFileAsBuffer(this.resource.path);return(f=this.progress)==null||f.set(100),new File([t],this.name)}get name(){return this.resource.path.split("/").pop()||""}}class Xr extends $e{constructor(t,f){super(),this.resource=t,this.progress=f}async resolve(){var t;return(t=this.progress)==null||t.set(100),new File([this.resource.contents],this.resource.name)}get name(){return this.resource.name}}class ar extends $e{constructor(t){super(),this.progress=t}async resolve(){var f,d;(f=this.progress)==null||f.setCaption(this.caption);const t=this.getURL();try{let c=await fetch(t);if(!c.ok)throw new Error(`Could not download "${t}"`);if(c=await mr.cloneResponseMonitorProgress(c,((d=this.progress)==null?void 0:d.loadingListener)??Jr),c.status!==200)throw new Error(`Could not download "${t}"`);return new File([await c.blob()],this.name)}catch(c){throw new Error(`Could not download "${t}".
633
+ );`})).json;for(const{slug:T,version:P}of x)i.push({url:`https://downloads.wordpress.org/translation/theme/${T}/${P}/${t}.zip`,type:"theme"});await r.isDir(`${c}/wp-content/languages/plugins`)||await r.mkdir(`${c}/wp-content/languages/plugins`),await r.isDir(`${c}/wp-content/languages/themes`)||await r.mkdir(`${c}/wp-content/languages/themes`);for(const{url:T,type:P}of i)try{const E=await fetch(T);if(!E.ok)throw new Error(`Failed to download translations for ${P}: ${E.statusText}`);let L=`${c}/wp-content/languages`;P==="plugin"?L+="/plugins":P==="theme"&&(L+="/themes"),await _r.unzipFile(r,new File([await E.blob()],`${t}-${P}.zip`),L)}catch(E){if(P==="core")throw new Error(`Failed to download translations for WordPress. Please check if the language code ${t} is correct. You can find all available languages and translations on https://translate.wordpress.org/.`);ce.logger.warn(`Error downloading translations for ${P}: ${E}`)}},ot=Object.freeze(Object.defineProperty({__proto__:null,activatePlugin:pr,activateTheme:fr,cp:Rr,defineSiteUrl:yr,defineWpConfigConsts:Ke,enableMultisite:Ar,exportWXR:Cr,importThemeStarterContent:hr,importWordPressFiles:xr,importWxr:Dr,installPlugin:Ir,installTheme:Ur,login:Vr,mkdir:Fr,mv:Lr,request:jr,resetData:Mr,rm:lr,rmdir:Sr,runPHP:Or,runPHPWithOptions:$r,runSql:Er,runWpInstallationWizard:zr,setSiteLanguage:Hr,setSiteOptions:dr,unzip:er,updateUserMeta:Tr,wpCLI:cr,writeFile:mr,writeFiles:Nr,zipWpContent:Br},Symbol.toStringTag,{value:"Module"})),nt=["vfs","literal","wordpress.org/themes","wordpress.org/plugins","url","git:directory"];function at(r){return r&&typeof r=="object"&&typeof r.resource=="string"&&nt.includes(r.resource)}class ke{get progress(){return this._progress}set progress(t){this._progress=t}setPlayground(t){this.playground=t}get isAsync(){return!1}static create(t,{semaphore:p,progress:c,corsProxy:h}){let i;switch(t.resource){case"vfs":i=new pt(t,c);break;case"literal":i=new ft(t,c);break;case"wordpress.org/themes":i=new mt(t,c);break;case"wordpress.org/plugins":i=new yt(t,c);break;case"url":i=new dt(t,c);break;case"git:directory":i=new ut(t,c,{corsProxy:h});break;case"literal:directory":i=new ct(t,c);break;default:throw new Error(`Invalid resource: ${t}`)}return i=new ht(i),p&&(i=new gt(i,p)),i}}class Gr extends ke{constructor(t){super(),this.resource=t}get progress(){return this.resource.progress}set progress(t){this.resource.progress=t}get name(){return this.resource.name}get isAsync(){return this.resource.isAsync}setPlayground(t){this.resource.setPlayground(t)}}class pt extends ke{constructor(t,p){super(),this.resource=t,this._progress=p}async resolve(){var p;const t=await this.playground.readFileAsBuffer(this.resource.path);return(p=this.progress)==null||p.set(100),new File([t],this.name)}get name(){return this.resource.path.split("/").pop()||""}}class ft extends ke{constructor(t,p){super(),this.resource=t,this._progress=p}async resolve(){var t;return(t=this.progress)==null||t.set(100),new File([this.resource.contents],this.resource.name)}get name(){return this.resource.name}}class gr extends ke{constructor(t){super(),this._progress=t}async resolve(){var p,c;(p=this.progress)==null||p.setCaption(this.caption);const t=this.getURL();try{let h=await fetch(t);if(!h.ok)throw new Error(`Could not download "${t}"`);if(h=await kr.cloneResponseMonitorProgress(h,((c=this.progress)==null?void 0:c.loadingListener)??lt),h.status!==200)throw new Error(`Could not download "${t}"`);return new File([await h.blob()],this.name)}catch(h){throw new Error(`Could not download "${t}".
677
634
  Check if the URL is correct and the server is reachable.
678
635
  If it is reachable, the server might be blocking the request.
679
636
  Check the browser console and network tabs for more information.
@@ -697,10 +654,11 @@ function join_paths()
697
654
  https://raw.githubusercontent.com/username/repository/branch/filename
698
655
 
699
656
  Error:
700
- ${c}`)}}get caption(){return`Downloading ${this.name}`}get name(){try{return new URL(this.getURL(),"http://example.com").pathname.split("/").pop()}catch{return this.getURL()}}get isAsync(){return!0}}const Jr=()=>{};class Kr extends ar{constructor(t,f){if(super(f),this.resource=t,this.resource.url.startsWith("https://github.com/")){const d=this.resource.url.match(/^https:\/\/github\.com\/(?<owner>[^/]+)\/(?<repo>[^/]+)\/blob\/(?<branch>[^/]+)\/(?<path>.+[^/])$/);d!=null&&d.groups&&(this.resource={...this.resource,url:`https://raw.githubusercontent.com/${d.groups.owner}/${d.groups.repo}/${d.groups.branch}/${d.groups.path}`})}}getURL(){return this.resource.url}get caption(){return this.resource.caption??super.caption}}class et extends ar{constructor(t,f){super(f),this.resource=t}get name(){return Qe(this.resource.slug)}getURL(){return`https://downloads.wordpress.org/theme/${xr(this.resource.slug)}`}}class rt extends ar{constructor(t,f){super(f),this.resource=t}get name(){return Qe(this.resource.slug)}getURL(){return`https://downloads.wordpress.org/plugin/${xr(this.resource.slug)}`}}function xr(r){return!r||r.endsWith(".zip")?r:r+".latest-stable.zip"}class Fr extends $e{constructor(t){super(),this.resource=t}async resolve(){return this.resource.resolve()}async setPlayground(t){return this.resource.setPlayground(t)}get progress(){return this.resource.progress}set progress(t){this.resource.progress=t}get name(){return this.resource.name}get isAsync(){return this.resource.isAsync}}class tt extends Fr{async resolve(){return this.promise||(this.promise=super.resolve()),this.promise}}class st extends Fr{constructor(t,f){super(t),this.semaphore=f}async resolve(){return this.isAsync?this.semaphore.run(()=>super.resolve()):super.resolve()}}const it={type:"object",properties:{landingPage:{type:"string",description:"The URL to navigate to after the blueprint has been run."},description:{type:"string",description:"Optional description. It doesn't do anything but is exposed as a courtesy to developers who may want to document which blueprint file does what.",deprecated:"Use meta.description instead."},meta:{type:"object",properties:{title:{type:"string",description:"A clear and concise name for your Blueprint."},description:{type:"string",description:"A brief explanation of what your Blueprint offers."},author:{type:"string",description:"A GitHub username of the author of this Blueprint."},categories:{type:"array",items:{type:"string"},description:"Relevant categories to help users find your Blueprint in the future Blueprints section on WordPress.org."}},required:["title","author"],additionalProperties:!1,description:"Optional metadata. Used by the Blueprints gallery at https://github.com/WordPress/blueprints"},preferredVersions:{type:"object",properties:{php:{anyOf:[{$ref:"#/definitions/SupportedPHPVersion"},{type:"string",const:"latest"}],description:"The preferred PHP version to use. If not specified, the latest supported version will be used"},wp:{type:"string",description:"The preferred WordPress version to use. If not specified, the latest supported version will be used"}},required:["php","wp"],additionalProperties:!1,description:"The preferred PHP and WordPress versions to use."},features:{type:"object",properties:{networking:{type:"boolean",description:"Should boot with support for network request via wp_safe_remote_get?"}},additionalProperties:!1},extraLibraries:{type:"array",items:{$ref:"#/definitions/ExtraLibrary"},description:"Extra libraries to preload into the Playground instance."},constants:{type:"object",additionalProperties:{type:"string"},description:"PHP Constants to define on every request"},plugins:{type:"array",items:{anyOf:[{type:"string"},{$ref:"#/definitions/FileReference"}]},description:"WordPress plugins to install and activate"},siteOptions:{type:"object",additionalProperties:{type:"string"},properties:{blogname:{type:"string",description:"The site title"}},description:"WordPress site options to define"},login:{anyOf:[{type:"boolean"},{type:"object",properties:{username:{type:"string"},password:{type:"string"}},required:["username","password"],additionalProperties:!1}],description:"User to log in as. If true, logs the user in as admin/password."},phpExtensionBundles:{type:"array",items:{$ref:"#/definitions/SupportedPHPExtensionBundle"},description:"The PHP extensions to use."},steps:{type:"array",items:{anyOf:[{$ref:"#/definitions/StepDefinition"},{type:"string"},{not:{}},{type:"boolean",const:!1},{type:"null"}]},description:"The steps to run after every other operation in this Blueprint was executed."},$schema:{type:"string"}},additionalProperties:!1},ot={type:"string",enum:["8.3","8.2","8.1","8.0","7.4","7.3","7.2","7.1","7.0"]},nt={type:"string",enum:["kitchen-sink","light"]},Cr=Object.prototype.hasOwnProperty;function te(r,{instancePath:t="",parentData:f,parentDataProperty:d,rootData:c=r}={}){let i=null,e=0;const u=e;let O=!1;const V=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let A;if(r.resource===void 0&&(A="resource")||r.path===void 0&&(A="path")){const x={instancePath:t,schemaPath:"#/definitions/VFSReference/required",keyword:"required",params:{missingProperty:A},message:"must have required property '"+A+"'"};i===null?i=[x]:i.push(x),e++}else{const x=e;for(const z in r)if(!(z==="resource"||z==="path")){const l={instancePath:t,schemaPath:"#/definitions/VFSReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:z},message:"must NOT have additional properties"};i===null?i=[l]:i.push(l),e++;break}if(x===e){if(r.resource!==void 0){let z=r.resource;const l=e;if(typeof z!="string"){const E={instancePath:t+"/resource",schemaPath:"#/definitions/VFSReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[E]:i.push(E),e++}if(z!=="vfs"){const E={instancePath:t+"/resource",schemaPath:"#/definitions/VFSReference/properties/resource/const",keyword:"const",params:{allowedValue:"vfs"},message:"must be equal to constant"};i===null?i=[E]:i.push(E),e++}var v=l===e}else var v=!0;if(v)if(r.path!==void 0){const z=e;if(typeof r.path!="string"){const E={instancePath:t+"/path",schemaPath:"#/definitions/VFSReference/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[E]:i.push(E),e++}var v=z===e}else var v=!0}}}else{const A={instancePath:t,schemaPath:"#/definitions/VFSReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[A]:i.push(A),e++}var R=V===e;if(O=O||R,!O){const A=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let l;if(r.resource===void 0&&(l="resource")||r.name===void 0&&(l="name")||r.contents===void 0&&(l="contents")){const E={instancePath:t,schemaPath:"#/definitions/LiteralReference/required",keyword:"required",params:{missingProperty:l},message:"must have required property '"+l+"'"};i===null?i=[E]:i.push(E),e++}else{const E=e;for(const _ in r)if(!(_==="resource"||_==="name"||_==="contents")){const k={instancePath:t,schemaPath:"#/definitions/LiteralReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:_},message:"must NOT have additional properties"};i===null?i=[k]:i.push(k),e++;break}if(E===e){if(r.resource!==void 0){let _=r.resource;const k=e;if(typeof _!="string"){const g={instancePath:t+"/resource",schemaPath:"#/definitions/LiteralReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[g]:i.push(g),e++}if(_!=="literal"){const g={instancePath:t+"/resource",schemaPath:"#/definitions/LiteralReference/properties/resource/const",keyword:"const",params:{allowedValue:"literal"},message:"must be equal to constant"};i===null?i=[g]:i.push(g),e++}var M=k===e}else var M=!0;if(M){if(r.name!==void 0){const _=e;if(typeof r.name!="string"){const g={instancePath:t+"/name",schemaPath:"#/definitions/LiteralReference/properties/name/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[g]:i.push(g),e++}var M=_===e}else var M=!0;if(M)if(r.contents!==void 0){let _=r.contents;const k=e,g=e;let m=!1;const y=e;if(typeof _!="string"){const w={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[w]:i.push(w),e++}var W=y===e;if(m=m||W,!m){const w=e;if(e===w)if(_&&typeof _=="object"&&!Array.isArray(_)){let j;if(_.BYTES_PER_ELEMENT===void 0&&(j="BYTES_PER_ELEMENT")||_.buffer===void 0&&(j="buffer")||_.byteLength===void 0&&(j="byteLength")||_.byteOffset===void 0&&(j="byteOffset")||_.length===void 0&&(j="length")){const F={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/required",keyword:"required",params:{missingProperty:j},message:"must have required property '"+j+"'"};i===null?i=[F]:i.push(F),e++}else{const F=e;for(const T in _)if(!(T==="BYTES_PER_ELEMENT"||T==="buffer"||T==="byteLength"||T==="byteOffset"||T==="length")){let H=_[T];const re=e;if(!(typeof H=="number"&&isFinite(H))){const J={instancePath:t+"/contents/"+T.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[J]:i.push(J),e++}var b=re===e;if(!b)break}if(F===e){if(_.BYTES_PER_ELEMENT!==void 0){let T=_.BYTES_PER_ELEMENT;const H=e;if(!(typeof T=="number"&&isFinite(T))){const re={instancePath:t+"/contents/BYTES_PER_ELEMENT",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[re]:i.push(re),e++}var D=H===e}else var D=!0;if(D){if(_.buffer!==void 0){let T=_.buffer;const H=e;if(e===H)if(T&&typeof T=="object"&&!Array.isArray(T)){let J;if(T.byteLength===void 0&&(J="byteLength")){const N={instancePath:t+"/contents/buffer",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:J},message:"must have required property '"+J+"'"};i===null?i=[N]:i.push(N),e++}else{const N=e;for(const X in T)if(X!=="byteLength"){const I={instancePath:t+"/contents/buffer",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:X},message:"must NOT have additional properties"};i===null?i=[I]:i.push(I),e++;break}if(N===e&&T.byteLength!==void 0){let X=T.byteLength;if(!(typeof X=="number"&&isFinite(X))){const I={instancePath:t+"/contents/buffer/byteLength",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[I]:i.push(I),e++}}}}else{const J={instancePath:t+"/contents/buffer",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[J]:i.push(J),e++}var D=H===e}else var D=!0;if(D){if(_.byteLength!==void 0){let T=_.byteLength;const H=e;if(!(typeof T=="number"&&isFinite(T))){const J={instancePath:t+"/contents/byteLength",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[J]:i.push(J),e++}var D=H===e}else var D=!0;if(D){if(_.byteOffset!==void 0){let T=_.byteOffset;const H=e;if(!(typeof T=="number"&&isFinite(T))){const J={instancePath:t+"/contents/byteOffset",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[J]:i.push(J),e++}var D=H===e}else var D=!0;if(D)if(_.length!==void 0){let T=_.length;const H=e;if(!(typeof T=="number"&&isFinite(T))){const J={instancePath:t+"/contents/length",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[J]:i.push(J),e++}var D=H===e}else var D=!0}}}}}}else{const j={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[j]:i.push(j),e++}var W=w===e;m=m||W}if(m)e=g,i!==null&&(g?i.length=g:i=null);else{const w={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};i===null?i=[w]:i.push(w),e++}var M=k===e}else var M=!0}}}}else{const l={instancePath:t,schemaPath:"#/definitions/LiteralReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[l]:i.push(l),e++}var R=A===e;if(O=O||R,!O){const l=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let k;if(r.resource===void 0&&(k="resource")||r.slug===void 0&&(k="slug")){const g={instancePath:t,schemaPath:"#/definitions/CoreThemeReference/required",keyword:"required",params:{missingProperty:k},message:"must have required property '"+k+"'"};i===null?i=[g]:i.push(g),e++}else{const g=e;for(const m in r)if(!(m==="resource"||m==="slug")){const y={instancePath:t,schemaPath:"#/definitions/CoreThemeReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:m},message:"must NOT have additional properties"};i===null?i=[y]:i.push(y),e++;break}if(g===e){if(r.resource!==void 0){let m=r.resource;const y=e;if(typeof m!="string"){const h={instancePath:t+"/resource",schemaPath:"#/definitions/CoreThemeReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[h]:i.push(h),e++}if(m!=="wordpress.org/themes"){const h={instancePath:t+"/resource",schemaPath:"#/definitions/CoreThemeReference/properties/resource/const",keyword:"const",params:{allowedValue:"wordpress.org/themes"},message:"must be equal to constant"};i===null?i=[h]:i.push(h),e++}var se=y===e}else var se=!0;if(se)if(r.slug!==void 0){const m=e;if(typeof r.slug!="string"){const h={instancePath:t+"/slug",schemaPath:"#/definitions/CoreThemeReference/properties/slug/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[h]:i.push(h),e++}var se=m===e}else var se=!0}}}else{const k={instancePath:t,schemaPath:"#/definitions/CoreThemeReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[k]:i.push(k),e++}var R=l===e;if(O=O||R,!O){const k=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let y;if(r.resource===void 0&&(y="resource")||r.slug===void 0&&(y="slug")){const h={instancePath:t,schemaPath:"#/definitions/CorePluginReference/required",keyword:"required",params:{missingProperty:y},message:"must have required property '"+y+"'"};i===null?i=[h]:i.push(h),e++}else{const h=e;for(const w in r)if(!(w==="resource"||w==="slug")){const S={instancePath:t,schemaPath:"#/definitions/CorePluginReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:w},message:"must NOT have additional properties"};i===null?i=[S]:i.push(S),e++;break}if(h===e){if(r.resource!==void 0){let w=r.resource;const S=e;if(typeof w!="string"){const j={instancePath:t+"/resource",schemaPath:"#/definitions/CorePluginReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[j]:i.push(j),e++}if(w!=="wordpress.org/plugins"){const j={instancePath:t+"/resource",schemaPath:"#/definitions/CorePluginReference/properties/resource/const",keyword:"const",params:{allowedValue:"wordpress.org/plugins"},message:"must be equal to constant"};i===null?i=[j]:i.push(j),e++}var G=S===e}else var G=!0;if(G)if(r.slug!==void 0){const w=e;if(typeof r.slug!="string"){const j={instancePath:t+"/slug",schemaPath:"#/definitions/CorePluginReference/properties/slug/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[j]:i.push(j),e++}var G=w===e}else var G=!0}}}else{const y={instancePath:t,schemaPath:"#/definitions/CorePluginReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[y]:i.push(y),e++}var R=k===e;if(O=O||R,!O){const y=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let S;if(r.resource===void 0&&(S="resource")||r.url===void 0&&(S="url")){const j={instancePath:t,schemaPath:"#/definitions/UrlReference/required",keyword:"required",params:{missingProperty:S},message:"must have required property '"+S+"'"};i===null?i=[j]:i.push(j),e++}else{const j=e;for(const F in r)if(!(F==="resource"||F==="url"||F==="caption")){const T={instancePath:t,schemaPath:"#/definitions/UrlReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:F},message:"must NOT have additional properties"};i===null?i=[T]:i.push(T),e++;break}if(j===e){if(r.resource!==void 0){let F=r.resource;const T=e;if(typeof F!="string"){const H={instancePath:t+"/resource",schemaPath:"#/definitions/UrlReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[H]:i.push(H),e++}if(F!=="url"){const H={instancePath:t+"/resource",schemaPath:"#/definitions/UrlReference/properties/resource/const",keyword:"const",params:{allowedValue:"url"},message:"must be equal to constant"};i===null?i=[H]:i.push(H),e++}var P=T===e}else var P=!0;if(P){if(r.url!==void 0){const F=e;if(typeof r.url!="string"){const H={instancePath:t+"/url",schemaPath:"#/definitions/UrlReference/properties/url/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[H]:i.push(H),e++}var P=F===e}else var P=!0;if(P)if(r.caption!==void 0){const F=e;if(typeof r.caption!="string"){const H={instancePath:t+"/caption",schemaPath:"#/definitions/UrlReference/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[H]:i.push(H),e++}var P=F===e}else var P=!0}}}}else{const S={instancePath:t,schemaPath:"#/definitions/UrlReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[S]:i.push(S),e++}var R=y===e;O=O||R}}}}if(O)e=u,i!==null&&(u?i.length=u:i=null);else{const A={instancePath:t,schemaPath:"#/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[A]:i.push(A),e++,te.errors=i,!1}return te.errors=i,e===0}const Ke={type:"object",discriminator:{propertyName:"step"},required:["step"],oneOf:[{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"activatePlugin"},pluginPath:{type:"string",description:"Path to the plugin directory as absolute path (/wordpress/wp-content/plugins/plugin-name); or the plugin entry file relative to the plugins directory (plugin-name/plugin-name.php)."},pluginName:{type:"string",description:"Optional. Plugin name to display in the progress bar."}},required:["pluginPath","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"activateTheme"},themeFolderName:{type:"string",description:"The name of the theme folder inside wp-content/themes/"}},required:["step","themeFolderName"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"cp"},fromPath:{type:"string",description:"Source path"},toPath:{type:"string",description:"Target path"}},required:["fromPath","step","toPath"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"defineWpConfigConsts"},consts:{type:"object",additionalProperties:{},description:"The constants to define"},method:{type:"string",enum:["rewrite-wp-config","define-before-run"],description:`The method of defining the constants in wp-config.php. Possible values are:
657
+ ${h}`)}}get caption(){return`Downloading ${this.name}`}get name(){try{return new URL(this.getURL(),"http://example.com").pathname.split("/").pop()}catch{return this.getURL()}}get isAsync(){return!0}}const lt=()=>{};class dt extends gr{constructor(t,p){if(super(p),this.resource=t,this.resource.url.startsWith("https://github.com/")){const c=this.resource.url.match(/^https:\/\/github\.com\/(?<owner>[^/]+)\/(?<repo>[^/]+)\/blob\/(?<branch>[^/]+)\/(?<path>.+[^/])$/);c!=null&&c.groups&&(this.resource={...this.resource,url:`https://raw.githubusercontent.com/${c.groups.owner}/${c.groups.repo}/${c.groups.branch}/${c.groups.path}`})}}getURL(){return this.resource.url}get caption(){return this.resource.caption??super.caption}}class ut extends ke{constructor(t,p,c){super(),this.reference=t,this._progress=p,this.options=c}async resolve(){var d;const t=(d=this.options)!=null&&d.corsProxy?`${this.options.corsProxy}/${this.reference.url}`:this.reference.url,p=["","HEAD"].includes(this.reference.ref)?"HEAD":`refs/heads/${this.reference.ref}`,c=await ir.listGitFiles(t,p),h=this.reference.path.replace(/^\/+/,""),i=ir.listDescendantFiles(c,h);let e=await ir.sparseCheckout(t,p,i);return e=Object.fromEntries(Object.entries(e).map(([g,x])=>(g=g.substring(this.reference.path.length),g=g.replace(/^\/+/,""),[g,x]))),{name:W.dirname(this.reference.path)||this.reference.url.replaceAll(/[^a-zA-Z0-9-.]/g,"-").replaceAll(/-+/g,"-"),files:e}}get name(){return this.reference.path.split("/").pop()}}class ct extends ke{constructor(t,p){super(),this.reference=t,this._progress=p}async resolve(){return this.reference}get name(){return this.reference.name}}class mt extends gr{constructor(t,p){super(p),this.resource=t}get name(){return rr(this.resource.slug)}getURL(){return`https://downloads.wordpress.org/theme/${Yr(this.resource.slug)}`}}class yt extends gr{constructor(t,p){super(p),this.resource=t}get name(){return rr(this.resource.slug)}getURL(){return`https://downloads.wordpress.org/plugin/${Yr(this.resource.slug)}`}}function Yr(r){return!r||r.endsWith(".zip")?r:r+".latest-stable.zip"}class ht extends Gr{async resolve(){return this.promise||(this.promise=this.resource.resolve()),this.promise}}class gt extends Gr{constructor(t,p){super(t),this.semaphore=p}async resolve(){return this.isAsync?this.semaphore.run(()=>this.resource.resolve()):this.resource.resolve()}}const bt={type:"object",properties:{landingPage:{type:"string",description:"The URL to navigate to after the blueprint has been run."},description:{type:"string",description:"Optional description. It doesn't do anything but is exposed as a courtesy to developers who may want to document which blueprint file does what.",deprecated:"Use meta.description instead."},meta:{type:"object",properties:{title:{type:"string",description:"A clear and concise name for your Blueprint."},description:{type:"string",description:"A brief explanation of what your Blueprint offers."},author:{type:"string",description:"A GitHub username of the author of this Blueprint."},categories:{type:"array",items:{type:"string"},description:"Relevant categories to help users find your Blueprint in the future Blueprints section on WordPress.org."}},required:["title","author"],additionalProperties:!1,description:"Optional metadata. Used by the Blueprints gallery at https://github.com/WordPress/blueprints"},preferredVersions:{type:"object",properties:{php:{anyOf:[{$ref:"#/definitions/SupportedPHPVersion"},{type:"string",const:"latest"}],description:"The preferred PHP version to use. If not specified, the latest supported version will be used"},wp:{type:"string",description:"The preferred WordPress version to use. If not specified, the latest supported version will be used"}},required:["php","wp"],additionalProperties:!1,description:"The preferred PHP and WordPress versions to use."},features:{type:"object",properties:{networking:{type:"boolean",description:"Should boot with support for network request via wp_safe_remote_get?"}},additionalProperties:!1},extraLibraries:{type:"array",items:{$ref:"#/definitions/ExtraLibrary"},description:"Extra libraries to preload into the Playground instance."},constants:{type:"object",additionalProperties:{type:"string"},description:"PHP Constants to define on every request"},plugins:{type:"array",items:{anyOf:[{type:"string"},{$ref:"#/definitions/FileReference"}]},description:"WordPress plugins to install and activate"},siteOptions:{type:"object",additionalProperties:{type:"string"},properties:{blogname:{type:"string",description:"The site title"}},description:"WordPress site options to define"},login:{anyOf:[{type:"boolean"},{type:"object",properties:{username:{type:"string"},password:{type:"string"}},required:["username","password"],additionalProperties:!1}],description:"User to log in as. If true, logs the user in as admin/password."},phpExtensionBundles:{deprecated:"No longer used. Feel free to remove it from your Blueprint."},steps:{type:"array",items:{anyOf:[{$ref:"#/definitions/StepDefinition"},{type:"string"},{not:{}},{type:"boolean",const:!1},{type:"null"}]},description:"The steps to run after every other operation in this Blueprint was executed."},$schema:{type:"string"}},additionalProperties:!1},wt={type:"string",enum:["8.3","8.2","8.1","8.0","7.4","7.3","7.2","7.1","7.0"]},Zr=Object.prototype.hasOwnProperty;function K(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;const d=e;let g=!1;const x=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let M;if(r.resource===void 0&&(M="resource")||r.path===void 0&&(M="path")){const j={instancePath:t,schemaPath:"#/definitions/VFSReference/required",keyword:"required",params:{missingProperty:M},message:"must have required property '"+M+"'"};i===null?i=[j]:i.push(j),e++}else{const j=e;for(const u in r)if(!(u==="resource"||u==="path")){const O={instancePath:t,schemaPath:"#/definitions/VFSReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:u},message:"must NOT have additional properties"};i===null?i=[O]:i.push(O),e++;break}if(j===e){if(r.resource!==void 0){let u=r.resource;const O=e;if(typeof u!="string"){const z={instancePath:t+"/resource",schemaPath:"#/definitions/VFSReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[z]:i.push(z),e++}if(u!=="vfs"){const z={instancePath:t+"/resource",schemaPath:"#/definitions/VFSReference/properties/resource/const",keyword:"const",params:{allowedValue:"vfs"},message:"must be equal to constant"};i===null?i=[z]:i.push(z),e++}var P=O===e}else var P=!0;if(P)if(r.path!==void 0){const u=e;if(typeof r.path!="string"){const z={instancePath:t+"/path",schemaPath:"#/definitions/VFSReference/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[z]:i.push(z),e++}var P=u===e}else var P=!0}}}else{const M={instancePath:t,schemaPath:"#/definitions/VFSReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[M]:i.push(M),e++}var E=x===e;if(g=g||E,!g){const M=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let O;if(r.resource===void 0&&(O="resource")||r.name===void 0&&(O="name")||r.contents===void 0&&(O="contents")){const z={instancePath:t,schemaPath:"#/definitions/LiteralReference/required",keyword:"required",params:{missingProperty:O},message:"must have required property '"+O+"'"};i===null?i=[z]:i.push(z),e++}else{const z=e;for(const m in r)if(!(m==="resource"||m==="name"||m==="contents")){const v={instancePath:t,schemaPath:"#/definitions/LiteralReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:m},message:"must NOT have additional properties"};i===null?i=[v]:i.push(v),e++;break}if(z===e){if(r.resource!==void 0){let m=r.resource;const v=e;if(typeof m!="string"){const w={instancePath:t+"/resource",schemaPath:"#/definitions/LiteralReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[w]:i.push(w),e++}if(m!=="literal"){const w={instancePath:t+"/resource",schemaPath:"#/definitions/LiteralReference/properties/resource/const",keyword:"const",params:{allowedValue:"literal"},message:"must be equal to constant"};i===null?i=[w]:i.push(w),e++}var L=v===e}else var L=!0;if(L){if(r.name!==void 0){const m=e;if(typeof r.name!="string"){const w={instancePath:t+"/name",schemaPath:"#/definitions/LiteralReference/properties/name/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[w]:i.push(w),e++}var L=m===e}else var L=!0;if(L)if(r.contents!==void 0){let m=r.contents;const v=e,w=e;let q=!1;const b=e;if(typeof m!="string"){const D={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[D]:i.push(D),e++}var N=b===e;if(q=q||N,!q){const D=e;if(e===D)if(m&&typeof m=="object"&&!Array.isArray(m)){let R;if(m.BYTES_PER_ELEMENT===void 0&&(R="BYTES_PER_ELEMENT")||m.buffer===void 0&&(R="buffer")||m.byteLength===void 0&&(R="byteLength")||m.byteOffset===void 0&&(R="byteOffset")||m.length===void 0&&(R="length")){const U={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/required",keyword:"required",params:{missingProperty:R},message:"must have required property '"+R+"'"};i===null?i=[U]:i.push(U),e++}else{const U=e;for(const F in m)if(!(F==="BYTES_PER_ELEMENT"||F==="buffer"||F==="byteLength"||F==="byteOffset"||F==="length")){let G=m[F];const se=e;if(!(typeof G=="number"&&isFinite(G))){const Y={instancePath:t+"/contents/"+F.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Y]:i.push(Y),e++}var y=se===e;if(!y)break}if(U===e){if(m.BYTES_PER_ELEMENT!==void 0){let F=m.BYTES_PER_ELEMENT;const G=e;if(!(typeof F=="number"&&isFinite(F))){const se={instancePath:t+"/contents/BYTES_PER_ELEMENT",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[se]:i.push(se),e++}var I=G===e}else var I=!0;if(I){if(m.buffer!==void 0){let F=m.buffer;const G=e;if(e===G)if(F&&typeof F=="object"&&!Array.isArray(F)){let Y;if(F.byteLength===void 0&&(Y="byteLength")){const C={instancePath:t+"/contents/buffer",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:Y},message:"must have required property '"+Y+"'"};i===null?i=[C]:i.push(C),e++}else{const C=e;for(const H in F)if(H!=="byteLength"){const X={instancePath:t+"/contents/buffer",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:H},message:"must NOT have additional properties"};i===null?i=[X]:i.push(X),e++;break}if(C===e&&F.byteLength!==void 0){let H=F.byteLength;if(!(typeof H=="number"&&isFinite(H))){const X={instancePath:t+"/contents/buffer/byteLength",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[X]:i.push(X),e++}}}}else{const Y={instancePath:t+"/contents/buffer",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[Y]:i.push(Y),e++}var I=G===e}else var I=!0;if(I){if(m.byteLength!==void 0){let F=m.byteLength;const G=e;if(!(typeof F=="number"&&isFinite(F))){const Y={instancePath:t+"/contents/byteLength",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Y]:i.push(Y),e++}var I=G===e}else var I=!0;if(I){if(m.byteOffset!==void 0){let F=m.byteOffset;const G=e;if(!(typeof F=="number"&&isFinite(F))){const Y={instancePath:t+"/contents/byteOffset",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Y]:i.push(Y),e++}var I=G===e}else var I=!0;if(I)if(m.length!==void 0){let F=m.length;const G=e;if(!(typeof F=="number"&&isFinite(F))){const Y={instancePath:t+"/contents/length",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Y]:i.push(Y),e++}var I=G===e}else var I=!0}}}}}}else{const R={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[R]:i.push(R),e++}var N=D===e;q=q||N}if(q)e=w,i!==null&&(w?i.length=w:i=null);else{const D={instancePath:t+"/contents",schemaPath:"#/definitions/LiteralReference/properties/contents/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};i===null?i=[D]:i.push(D),e++}var L=v===e}else var L=!0}}}}else{const O={instancePath:t,schemaPath:"#/definitions/LiteralReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[O]:i.push(O),e++}var E=M===e;if(g=g||E,!g){const O=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let v;if(r.resource===void 0&&(v="resource")||r.slug===void 0&&(v="slug")){const w={instancePath:t,schemaPath:"#/definitions/CoreThemeReference/required",keyword:"required",params:{missingProperty:v},message:"must have required property '"+v+"'"};i===null?i=[w]:i.push(w),e++}else{const w=e;for(const q in r)if(!(q==="resource"||q==="slug")){const b={instancePath:t,schemaPath:"#/definitions/CoreThemeReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:q},message:"must NOT have additional properties"};i===null?i=[b]:i.push(b),e++;break}if(w===e){if(r.resource!==void 0){let q=r.resource;const b=e;if(typeof q!="string"){const l={instancePath:t+"/resource",schemaPath:"#/definitions/CoreThemeReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[l]:i.push(l),e++}if(q!=="wordpress.org/themes"){const l={instancePath:t+"/resource",schemaPath:"#/definitions/CoreThemeReference/properties/resource/const",keyword:"const",params:{allowedValue:"wordpress.org/themes"},message:"must be equal to constant"};i===null?i=[l]:i.push(l),e++}var V=b===e}else var V=!0;if(V)if(r.slug!==void 0){const q=e;if(typeof r.slug!="string"){const l={instancePath:t+"/slug",schemaPath:"#/definitions/CoreThemeReference/properties/slug/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[l]:i.push(l),e++}var V=q===e}else var V=!0}}}else{const v={instancePath:t,schemaPath:"#/definitions/CoreThemeReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[v]:i.push(v),e++}var E=O===e;if(g=g||E,!g){const v=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let b;if(r.resource===void 0&&(b="resource")||r.slug===void 0&&(b="slug")){const l={instancePath:t,schemaPath:"#/definitions/CorePluginReference/required",keyword:"required",params:{missingProperty:b},message:"must have required property '"+b+"'"};i===null?i=[l]:i.push(l),e++}else{const l=e;for(const D in r)if(!(D==="resource"||D==="slug")){const A={instancePath:t,schemaPath:"#/definitions/CorePluginReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:D},message:"must NOT have additional properties"};i===null?i=[A]:i.push(A),e++;break}if(l===e){if(r.resource!==void 0){let D=r.resource;const A=e;if(typeof D!="string"){const R={instancePath:t+"/resource",schemaPath:"#/definitions/CorePluginReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[R]:i.push(R),e++}if(D!=="wordpress.org/plugins"){const R={instancePath:t+"/resource",schemaPath:"#/definitions/CorePluginReference/properties/resource/const",keyword:"const",params:{allowedValue:"wordpress.org/plugins"},message:"must be equal to constant"};i===null?i=[R]:i.push(R),e++}var Q=A===e}else var Q=!0;if(Q)if(r.slug!==void 0){const D=e;if(typeof r.slug!="string"){const R={instancePath:t+"/slug",schemaPath:"#/definitions/CorePluginReference/properties/slug/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[R]:i.push(R),e++}var Q=D===e}else var Q=!0}}}else{const b={instancePath:t,schemaPath:"#/definitions/CorePluginReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[b]:i.push(b),e++}var E=v===e;if(g=g||E,!g){const b=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let A;if(r.resource===void 0&&(A="resource")||r.url===void 0&&(A="url")){const R={instancePath:t,schemaPath:"#/definitions/UrlReference/required",keyword:"required",params:{missingProperty:A},message:"must have required property '"+A+"'"};i===null?i=[R]:i.push(R),e++}else{const R=e;for(const U in r)if(!(U==="resource"||U==="url"||U==="caption")){const F={instancePath:t,schemaPath:"#/definitions/UrlReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:U},message:"must NOT have additional properties"};i===null?i=[F]:i.push(F),e++;break}if(R===e){if(r.resource!==void 0){let U=r.resource;const F=e;if(typeof U!="string"){const G={instancePath:t+"/resource",schemaPath:"#/definitions/UrlReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[G]:i.push(G),e++}if(U!=="url"){const G={instancePath:t+"/resource",schemaPath:"#/definitions/UrlReference/properties/resource/const",keyword:"const",params:{allowedValue:"url"},message:"must be equal to constant"};i===null?i=[G]:i.push(G),e++}var _=F===e}else var _=!0;if(_){if(r.url!==void 0){const U=e;if(typeof r.url!="string"){const G={instancePath:t+"/url",schemaPath:"#/definitions/UrlReference/properties/url/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[G]:i.push(G),e++}var _=U===e}else var _=!0;if(_)if(r.caption!==void 0){const U=e;if(typeof r.caption!="string"){const G={instancePath:t+"/caption",schemaPath:"#/definitions/UrlReference/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[G]:i.push(G),e++}var _=U===e}else var _=!0}}}}else{const A={instancePath:t,schemaPath:"#/definitions/UrlReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[A]:i.push(A),e++}var E=b===e;g=g||E}}}}if(g)e=d,i!==null&&(d?i.length=d:i=null);else{const M={instancePath:t,schemaPath:"#/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[M]:i.push(M),e++,K.errors=i,!1}return K.errors=i,e===0}const or={type:"object",discriminator:{propertyName:"step"},required:["step"],oneOf:[{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"activatePlugin"},pluginPath:{type:"string",description:"Path to the plugin directory as absolute path (/wordpress/wp-content/plugins/plugin-name); or the plugin entry file relative to the plugins directory (plugin-name/plugin-name.php)."},pluginName:{type:"string",description:"Optional. Plugin name to display in the progress bar."}},required:["pluginPath","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"activateTheme"},themeFolderName:{type:"string",description:"The name of the theme folder inside wp-content/themes/"}},required:["step","themeFolderName"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"cp"},fromPath:{type:"string",description:"Source path"},toPath:{type:"string",description:"Target path"}},required:["fromPath","step","toPath"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"defineWpConfigConsts"},consts:{type:"object",additionalProperties:{},description:"The constants to define"},method:{type:"string",enum:["rewrite-wp-config","define-before-run"],description:`The method of defining the constants in wp-config.php. Possible values are:
701
658
 
702
659
  - rewrite-wp-config: Default. Rewrites the wp-config.php file to explicitly call define() with the requested name and value. This method alters the file on the disk, but it doesn't conflict with existing define() calls in wp-config.php.
703
660
 
704
661
  - define-before-run: Defines the constant before running the requested script. It doesn't alter any files on the disk, but constants defined this way may conflict with existing define() calls in wp-config.php.`},virtualize:{type:"boolean",deprecated:`This option is noop and will be removed in a future version.
705
662
  This option is only kept in here to avoid breaking Blueprint schema validation
706
- for existing apps using this option.`}},required:["consts","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"defineSiteUrl"},siteUrl:{type:"string",description:"The URL"}},required:["siteUrl","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"enableMultisite"}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"importWxr"},file:{$ref:"#/definitions/FileReference",description:"The file to import"}},required:["file","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"importThemeStarterContent",description:"The step identifier."},themeSlug:{type:"string",description:"The name of the theme to import content from."}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"importWordPressFiles"},wordPressFilesZip:{$ref:"#/definitions/FileReference",description:"The zip file containing the top-level WordPress files and directories."},pathInZip:{type:"string",description:"The path inside the zip file where the WordPress files are."}},required:["step","wordPressFilesZip"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},ifAlreadyInstalled:{type:"string",enum:["overwrite","skip","error"],description:"What to do if the asset already exists."},step:{type:"string",const:"installPlugin",description:"The step identifier."},pluginZipFile:{$ref:"#/definitions/FileReference",description:"The plugin zip file to install."},options:{$ref:"#/definitions/InstallPluginOptions",description:"Optional installation options."}},required:["pluginZipFile","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},ifAlreadyInstalled:{type:"string",enum:["overwrite","skip","error"],description:"What to do if the asset already exists."},step:{type:"string",const:"installTheme",description:"The step identifier."},themeZipFile:{$ref:"#/definitions/FileReference",description:"The theme zip file to install."},options:{type:"object",properties:{activate:{type:"boolean",description:"Whether to activate the theme after installing it."},importStarterContent:{type:"boolean",description:"Whether to import the theme's starter content after installing it."}},additionalProperties:!1,description:"Optional installation options."}},required:["step","themeZipFile"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"login"},username:{type:"string",description:"The user to log in as. Defaults to 'admin'."},password:{type:"string",description:"The password to log in with. Defaults to 'password'."}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"mkdir"},path:{type:"string",description:"The path of the directory you want to create"}},required:["path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"mv"},fromPath:{type:"string",description:"Source path"},toPath:{type:"string",description:"Target path"}},required:["fromPath","step","toPath"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"resetData"}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"request"},request:{$ref:"#/definitions/PHPRequest",description:"Request details (See /wordpress-playground/api/universal/interface/PHPRequest)"}},required:["request","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"rm"},path:{type:"string",description:"The path to remove"}},required:["path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"rmdir"},path:{type:"string",description:"The path to remove"}},required:["path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runPHP",description:"The step identifier."},code:{type:"string",description:"The PHP code to run."}},required:["code","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runPHPWithOptions"},options:{$ref:"#/definitions/PHPRunOptions",description:"Run options (See /wordpress-playground/api/universal/interface/PHPRunOptions/))"}},required:["options","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runWpInstallationWizard"},options:{$ref:"#/definitions/WordPressInstallationOptions"}},required:["options","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runSql",description:"The step identifier."},sql:{$ref:"#/definitions/FileReference",description:"The SQL to run. Each non-empty line must contain a valid SQL query."}},required:["sql","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"setSiteOptions",description:'The name of the step. Must be "setSiteOptions".'},options:{type:"object",additionalProperties:{},description:"The options to set on the site."}},required:["options","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"unzip"},zipFile:{$ref:"#/definitions/FileReference",description:"The zip file to extract"},zipPath:{type:"string",description:"The path of the zip file to extract",deprecated:"Use zipFile instead."},extractToPath:{type:"string",description:"The path to extract the zip file to"}},required:["extractToPath","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"updateUserMeta"},meta:{type:"object",additionalProperties:{},description:'An object of user meta values to set, e.g. { "first_name": "John" }'},userId:{type:"number",description:"User ID"}},required:["meta","step","userId"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"writeFile"},path:{type:"string",description:"The path of the file to write to"},data:{anyOf:[{$ref:"#/definitions/FileReference"},{type:"string"},{type:"object",properties:{BYTES_PER_ELEMENT:{type:"number"},buffer:{type:"object",properties:{byteLength:{type:"number"}},required:["byteLength"],additionalProperties:!1},byteLength:{type:"number"},byteOffset:{type:"number"},length:{type:"number"}},required:["BYTES_PER_ELEMENT","buffer","byteLength","byteOffset","length"],additionalProperties:{type:"number"}}],description:"The data to write"}},required:["data","path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"wp-cli",description:"The step identifier."},command:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}],description:"The WP CLI command to run."},wpCliPath:{type:"string",description:"wp-cli.phar path"}},required:["command","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"setSiteLanguage"},language:{type:"string",description:"The language to set, e.g. 'en_US'"}},required:["language","step"]}]},Ir={type:"string",enum:["GET","POST","HEAD","OPTIONS","PATCH","PUT","DELETE"]};function ce(r,{instancePath:t="",parentData:f,parentDataProperty:d,rootData:c=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){let se;if(r.url===void 0&&(se="url"))return ce.errors=[{instancePath:t,schemaPath:"#/required",keyword:"required",params:{missingProperty:se},message:"must have required property '"+se+"'"}],!1;{const G=e;for(const P in r)if(!(P==="method"||P==="url"||P==="headers"||P==="body"))return ce.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:P},message:"must NOT have additional properties"}],!1;if(G===e){if(r.method!==void 0){let P=r.method;const A=e;if(typeof P!="string")return ce.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(P==="GET"||P==="POST"||P==="HEAD"||P==="OPTIONS"||P==="PATCH"||P==="PUT"||P==="DELETE"))return ce.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/enum",keyword:"enum",params:{allowedValues:Ir.enum},message:"must be equal to one of the allowed values"}],!1;var u=A===e}else var u=!0;if(u){if(r.url!==void 0){const P=e;if(typeof r.url!="string")return ce.errors=[{instancePath:t+"/url",schemaPath:"#/properties/url/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=P===e}else var u=!0;if(u){if(r.headers!==void 0){let P=r.headers;const A=e;if(e===e)if(P&&typeof P=="object"&&!Array.isArray(P))for(const l in P){const E=e;if(typeof P[l]!="string")return ce.errors=[{instancePath:t+"/headers/"+l.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/definitions/PHPRequestHeaders/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=E===e;if(!O)break}else return ce.errors=[{instancePath:t+"/headers",schemaPath:"#/definitions/PHPRequestHeaders/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=A===e}else var u=!0;if(u)if(r.body!==void 0){let P=r.body;const A=e,x=e;let z=!1;const l=e;if(typeof P!="string"){const _={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[_]:i.push(_),e++}var V=l===e;if(z=z||V,!z){const _=e;if(e===_)if(P&&typeof P=="object"&&!Array.isArray(P)){let g;if(P.BYTES_PER_ELEMENT===void 0&&(g="BYTES_PER_ELEMENT")||P.buffer===void 0&&(g="buffer")||P.byteLength===void 0&&(g="byteLength")||P.byteOffset===void 0&&(g="byteOffset")||P.length===void 0&&(g="length")){const m={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/required",keyword:"required",params:{missingProperty:g},message:"must have required property '"+g+"'"};i===null?i=[m]:i.push(m),e++}else{const m=e;for(const y in P)if(!(y==="BYTES_PER_ELEMENT"||y==="buffer"||y==="byteLength"||y==="byteOffset"||y==="length")){let h=P[y];const w=e;if(!(typeof h=="number"&&isFinite(h))){const S={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[S]:i.push(S),e++}var U=w===e;if(!U)break}if(m===e){if(P.BYTES_PER_ELEMENT!==void 0){let y=P.BYTES_PER_ELEMENT;const h=e;if(!(typeof y=="number"&&isFinite(y))){const w={instancePath:t+"/body/BYTES_PER_ELEMENT",schemaPath:"#/properties/body/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[w]:i.push(w),e++}var v=h===e}else var v=!0;if(v){if(P.buffer!==void 0){let y=P.buffer;const h=e;if(e===h)if(y&&typeof y=="object"&&!Array.isArray(y)){let S;if(y.byteLength===void 0&&(S="byteLength")){const j={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:S},message:"must have required property '"+S+"'"};i===null?i=[j]:i.push(j),e++}else{const j=e;for(const F in y)if(F!=="byteLength"){const T={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:F},message:"must NOT have additional properties"};i===null?i=[T]:i.push(T),e++;break}if(j===e&&y.byteLength!==void 0){let F=y.byteLength;if(!(typeof F=="number"&&isFinite(F))){const T={instancePath:t+"/body/buffer/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[T]:i.push(T),e++}}}}else{const S={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[S]:i.push(S),e++}var v=h===e}else var v=!0;if(v){if(P.byteLength!==void 0){let y=P.byteLength;const h=e;if(!(typeof y=="number"&&isFinite(y))){const S={instancePath:t+"/body/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[S]:i.push(S),e++}var v=h===e}else var v=!0;if(v){if(P.byteOffset!==void 0){let y=P.byteOffset;const h=e;if(!(typeof y=="number"&&isFinite(y))){const S={instancePath:t+"/body/byteOffset",schemaPath:"#/properties/body/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[S]:i.push(S),e++}var v=h===e}else var v=!0;if(v)if(P.length!==void 0){let y=P.length;const h=e;if(!(typeof y=="number"&&isFinite(y))){const S={instancePath:t+"/body/length",schemaPath:"#/properties/body/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[S]:i.push(S),e++}var v=h===e}else var v=!0}}}}}}else{const g={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[g]:i.push(g),e++}var V=_===e;if(z=z||V,!z){const g=e;if(e===g)if(P&&typeof P=="object"&&!Array.isArray(P))for(const y in P){let h=P[y];const w=e,S=e;let j=!1;const F=e;if(typeof h!="string"){const T={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[T]:i.push(T),e++}var R=F===e;if(j=j||R,!j){const T=e;if(e===T)if(h&&typeof h=="object"&&!Array.isArray(h)){let re;if(h.BYTES_PER_ELEMENT===void 0&&(re="BYTES_PER_ELEMENT")||h.buffer===void 0&&(re="buffer")||h.byteLength===void 0&&(re="byteLength")||h.byteOffset===void 0&&(re="byteOffset")||h.length===void 0&&(re="length")){const J={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/required",keyword:"required",params:{missingProperty:re},message:"must have required property '"+re+"'"};i===null?i=[J]:i.push(J),e++}else{const J=e;for(const N in h)if(!(N==="BYTES_PER_ELEMENT"||N==="buffer"||N==="byteLength"||N==="byteOffset"||N==="length")){let X=h[N];const I=e;if(!(typeof X=="number"&&isFinite(X))){const Z={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/"+N.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var M=I===e;if(!M)break}if(J===e){if(h.BYTES_PER_ELEMENT!==void 0){let N=h.BYTES_PER_ELEMENT;const X=e;if(!(typeof N=="number"&&isFinite(N))){const I={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/BYTES_PER_ELEMENT",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[I]:i.push(I),e++}var W=X===e}else var W=!0;if(W){if(h.buffer!==void 0){let N=h.buffer;const X=e;if(e===X)if(N&&typeof N=="object"&&!Array.isArray(N)){let Z;if(N.byteLength===void 0&&(Z="byteLength")){const K={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:Z},message:"must have required property '"+Z+"'"};i===null?i=[K]:i.push(K),e++}else{const K=e;for(const ae in N)if(ae!=="byteLength"){const pe={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:ae},message:"must NOT have additional properties"};i===null?i=[pe]:i.push(pe),e++;break}if(K===e&&N.byteLength!==void 0){let ae=N.byteLength;if(!(typeof ae=="number"&&isFinite(ae))){const pe={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer/byteLength",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[pe]:i.push(pe),e++}}}}else{const Z={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[Z]:i.push(Z),e++}var W=X===e}else var W=!0;if(W){if(h.byteLength!==void 0){let N=h.byteLength;const X=e;if(!(typeof N=="number"&&isFinite(N))){const Z={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/byteLength",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var W=X===e}else var W=!0;if(W){if(h.byteOffset!==void 0){let N=h.byteOffset;const X=e;if(!(typeof N=="number"&&isFinite(N))){const Z={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/byteOffset",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var W=X===e}else var W=!0;if(W)if(h.length!==void 0){let N=h.length;const X=e;if(!(typeof N=="number"&&isFinite(N))){const Z={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/length",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var W=X===e}else var W=!0}}}}}}else{const re={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[re]:i.push(re),e++}var R=T===e;if(j=j||R,!j){const re=e;if(e===re)if(h&&typeof h=="object"&&!Array.isArray(h)){let N;if(h.lastModified===void 0&&(N="lastModified")||h.name===void 0&&(N="name")||h.size===void 0&&(N="size")||h.type===void 0&&(N="type")||h.webkitRelativePath===void 0&&(N="webkitRelativePath")){const X={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/required",keyword:"required",params:{missingProperty:N},message:"must have required property '"+N+"'"};i===null?i=[X]:i.push(X),e++}else{const X=e;for(const I in h)if(!(I==="size"||I==="type"||I==="lastModified"||I==="name"||I==="webkitRelativePath")){const Z={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:I},message:"must NOT have additional properties"};i===null?i=[Z]:i.push(Z),e++;break}if(X===e){if(h.size!==void 0){let I=h.size;const Z=e;if(!(typeof I=="number"&&isFinite(I))){const K={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/size",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/size/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[K]:i.push(K),e++}var b=Z===e}else var b=!0;if(b){if(h.type!==void 0){const I=e;if(typeof h.type!="string"){const K={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/type",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/type/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[K]:i.push(K),e++}var b=I===e}else var b=!0;if(b){if(h.lastModified!==void 0){let I=h.lastModified;const Z=e;if(!(typeof I=="number"&&isFinite(I))){const ae={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/lastModified",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/lastModified/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[ae]:i.push(ae),e++}var b=Z===e}else var b=!0;if(b){if(h.name!==void 0){const I=e;if(typeof h.name!="string"){const K={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/name",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/name/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[K]:i.push(K),e++}var b=I===e}else var b=!0;if(b)if(h.webkitRelativePath!==void 0){const I=e;if(typeof h.webkitRelativePath!="string"){const K={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1")+"/webkitRelativePath",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/webkitRelativePath/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[K]:i.push(K),e++}var b=I===e}else var b=!0}}}}}}else{const N={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[N]:i.push(N),e++}var R=re===e;j=j||R}}if(j)e=S,i!==null&&(S?i.length=S:i=null);else{const T={instancePath:t+"/body/"+y.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};i===null?i=[T]:i.push(T),e++}var D=w===e;if(!D)break}else{const y={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[y]:i.push(y),e++}var V=g===e;z=z||V}}if(z)e=x,i!==null&&(x?i.length=x:i=null);else{const _={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[_]:i.push(_),e++,ce.errors=i,!1}var u=A===e}else var u=!0}}}}}else return ce.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return ce.errors=i,e===0}const at={type:"object",properties:{relativeUri:{type:"string",description:"Request path following the domain:port part."},scriptPath:{type:"string",description:"Path of the .php file to execute."},protocol:{type:"string",description:"Request protocol."},method:{$ref:"#/definitions/HTTPMethod",description:"Request method. Default: `GET`."},headers:{$ref:"#/definitions/PHPRequestHeaders",description:"Request headers."},body:{anyOf:[{type:"string"},{type:"object",properties:{BYTES_PER_ELEMENT:{type:"number"},buffer:{type:"object",properties:{byteLength:{type:"number"}},required:["byteLength"],additionalProperties:!1},byteLength:{type:"number"},byteOffset:{type:"number"},length:{type:"number"}},required:["BYTES_PER_ELEMENT","buffer","byteLength","byteOffset","length"],additionalProperties:{type:"number"}}],description:"Request body."},env:{type:"object",additionalProperties:{type:"string"},description:"Environment variables to set for this run."},$_SERVER:{type:"object",additionalProperties:{type:"string"},description:"$_SERVER entries to set for this run."},code:{type:"string",description:"The code snippet to eval instead of a php file."}},additionalProperties:!1};function ie(r,{instancePath:t="",parentData:f,parentDataProperty:d,rootData:c=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){const W=e;for(const b in r)if(!Cr.call(at.properties,b))return ie.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:b},message:"must NOT have additional properties"}],!1;if(W===e){if(r.relativeUri!==void 0){const b=e;if(typeof r.relativeUri!="string")return ie.errors=[{instancePath:t+"/relativeUri",schemaPath:"#/properties/relativeUri/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=b===e}else var u=!0;if(u){if(r.scriptPath!==void 0){const b=e;if(typeof r.scriptPath!="string")return ie.errors=[{instancePath:t+"/scriptPath",schemaPath:"#/properties/scriptPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=b===e}else var u=!0;if(u){if(r.protocol!==void 0){const b=e;if(typeof r.protocol!="string")return ie.errors=[{instancePath:t+"/protocol",schemaPath:"#/properties/protocol/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=b===e}else var u=!0;if(u){if(r.method!==void 0){let b=r.method;const D=e;if(typeof b!="string")return ie.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(b==="GET"||b==="POST"||b==="HEAD"||b==="OPTIONS"||b==="PATCH"||b==="PUT"||b==="DELETE"))return ie.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/enum",keyword:"enum",params:{allowedValues:Ir.enum},message:"must be equal to one of the allowed values"}],!1;var u=D===e}else var u=!0;if(u){if(r.headers!==void 0){let b=r.headers;const D=e;if(e===e)if(b&&typeof b=="object"&&!Array.isArray(b))for(const P in b){const A=e;if(typeof b[P]!="string")return ie.errors=[{instancePath:t+"/headers/"+P.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/definitions/PHPRequestHeaders/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=A===e;if(!O)break}else return ie.errors=[{instancePath:t+"/headers",schemaPath:"#/definitions/PHPRequestHeaders/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=D===e}else var u=!0;if(u){if(r.body!==void 0){let b=r.body;const D=e,se=e;let G=!1;const P=e;if(typeof b!="string"){const x={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[x]:i.push(x),e++}var V=P===e;if(G=G||V,!G){const x=e;if(e===x)if(b&&typeof b=="object"&&!Array.isArray(b)){let l;if(b.BYTES_PER_ELEMENT===void 0&&(l="BYTES_PER_ELEMENT")||b.buffer===void 0&&(l="buffer")||b.byteLength===void 0&&(l="byteLength")||b.byteOffset===void 0&&(l="byteOffset")||b.length===void 0&&(l="length")){const E={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/required",keyword:"required",params:{missingProperty:l},message:"must have required property '"+l+"'"};i===null?i=[E]:i.push(E),e++}else{const E=e;for(const _ in b)if(!(_==="BYTES_PER_ELEMENT"||_==="buffer"||_==="byteLength"||_==="byteOffset"||_==="length")){let k=b[_];const g=e;if(!(typeof k=="number"&&isFinite(k))){const m={instancePath:t+"/body/"+_.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[m]:i.push(m),e++}var U=g===e;if(!U)break}if(E===e){if(b.BYTES_PER_ELEMENT!==void 0){let _=b.BYTES_PER_ELEMENT;const k=e;if(!(typeof _=="number"&&isFinite(_))){const g={instancePath:t+"/body/BYTES_PER_ELEMENT",schemaPath:"#/properties/body/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[g]:i.push(g),e++}var v=k===e}else var v=!0;if(v){if(b.buffer!==void 0){let _=b.buffer;const k=e;if(e===k)if(_&&typeof _=="object"&&!Array.isArray(_)){let m;if(_.byteLength===void 0&&(m="byteLength")){const y={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:m},message:"must have required property '"+m+"'"};i===null?i=[y]:i.push(y),e++}else{const y=e;for(const h in _)if(h!=="byteLength"){const w={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:h},message:"must NOT have additional properties"};i===null?i=[w]:i.push(w),e++;break}if(y===e&&_.byteLength!==void 0){let h=_.byteLength;if(!(typeof h=="number"&&isFinite(h))){const w={instancePath:t+"/body/buffer/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[w]:i.push(w),e++}}}}else{const m={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[m]:i.push(m),e++}var v=k===e}else var v=!0;if(v){if(b.byteLength!==void 0){let _=b.byteLength;const k=e;if(!(typeof _=="number"&&isFinite(_))){const m={instancePath:t+"/body/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[m]:i.push(m),e++}var v=k===e}else var v=!0;if(v){if(b.byteOffset!==void 0){let _=b.byteOffset;const k=e;if(!(typeof _=="number"&&isFinite(_))){const m={instancePath:t+"/body/byteOffset",schemaPath:"#/properties/body/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[m]:i.push(m),e++}var v=k===e}else var v=!0;if(v)if(b.length!==void 0){let _=b.length;const k=e;if(!(typeof _=="number"&&isFinite(_))){const m={instancePath:t+"/body/length",schemaPath:"#/properties/body/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[m]:i.push(m),e++}var v=k===e}else var v=!0}}}}}}else{const l={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[l]:i.push(l),e++}var V=x===e;G=G||V}if(G)e=se,i!==null&&(se?i.length=se:i=null);else{const x={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[x]:i.push(x),e++,ie.errors=i,!1}var u=D===e}else var u=!0;if(u){if(r.env!==void 0){let b=r.env;const D=e;if(e===D)if(b&&typeof b=="object"&&!Array.isArray(b))for(const G in b){const P=e;if(typeof b[G]!="string")return ie.errors=[{instancePath:t+"/env/"+G.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/env/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var R=P===e;if(!R)break}else return ie.errors=[{instancePath:t+"/env",schemaPath:"#/properties/env/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=D===e}else var u=!0;if(u){if(r.$_SERVER!==void 0){let b=r.$_SERVER;const D=e;if(e===D)if(b&&typeof b=="object"&&!Array.isArray(b))for(const G in b){const P=e;if(typeof b[G]!="string")return ie.errors=[{instancePath:t+"/$_SERVER/"+G.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/%24_SERVER/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var M=P===e;if(!M)break}else return ie.errors=[{instancePath:t+"/$_SERVER",schemaPath:"#/properties/%24_SERVER/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=D===e}else var u=!0;if(u)if(r.code!==void 0){const b=e;if(typeof r.code!="string")return ie.errors=[{instancePath:t+"/code",schemaPath:"#/properties/code/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=b===e}else var u=!0}}}}}}}}}else return ie.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return ie.errors=i,e===0}function o(r,{instancePath:t="",parentData:f,parentDataProperty:d,rootData:c=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){let Je;if(r.step===void 0&&(Je="step"))return o.errors=[{instancePath:t,schemaPath:"#/required",keyword:"required",params:{missingProperty:Je},message:"must have required property '"+Je+"'"}],!1;{const Y=r.step;if(typeof Y=="string")if(Y==="activatePlugin"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.pluginPath===void 0&&(p="pluginPath")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/0/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="pluginPath"||s==="pluginName"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/0/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/0/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/0/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var u=$===e}else var u=!0;if(u)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/0/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=n===e}else var u=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/0/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var O=a===e}else var O=!0;if(O){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/0/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="activatePlugin")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/0/properties/step/const",keyword:"const",params:{allowedValue:"activatePlugin"},message:"must be equal to constant"}],!1;var O=a===e}else var O=!0;if(O){if(r.pluginPath!==void 0){const s=e;if(typeof r.pluginPath!="string")return o.errors=[{instancePath:t+"/pluginPath",schemaPath:"#/oneOf/0/properties/pluginPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=s===e}else var O=!0;if(O)if(r.pluginName!==void 0){const s=e;if(typeof r.pluginName!="string")return o.errors=[{instancePath:t+"/pluginName",schemaPath:"#/oneOf/0/properties/pluginName/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=s===e}else var O=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/0/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="activateTheme"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step")||r.themeFolderName===void 0&&(p="themeFolderName"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/1/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="themeFolderName"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/1/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/1/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/1/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var V=$===e}else var V=!0;if(V)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/1/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var V=n===e}else var V=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/1/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var U=a===e}else var U=!0;if(U){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/1/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="activateTheme")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/1/properties/step/const",keyword:"const",params:{allowedValue:"activateTheme"},message:"must be equal to constant"}],!1;var U=a===e}else var U=!0;if(U)if(r.themeFolderName!==void 0){const s=e;if(typeof r.themeFolderName!="string")return o.errors=[{instancePath:t+"/themeFolderName",schemaPath:"#/oneOf/1/properties/themeFolderName/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var U=s===e}else var U=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="cp"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.fromPath===void 0&&(p="fromPath")||r.step===void 0&&(p="step")||r.toPath===void 0&&(p="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/2/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="fromPath"||s==="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/2/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/2/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/2/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var v=$===e}else var v=!0;if(v)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/2/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var v=n===e}else var v=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/2/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var R=a===e}else var R=!0;if(R){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/2/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="cp")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/2/properties/step/const",keyword:"const",params:{allowedValue:"cp"},message:"must be equal to constant"}],!1;var R=a===e}else var R=!0;if(R){if(r.fromPath!==void 0){const s=e;if(typeof r.fromPath!="string")return o.errors=[{instancePath:t+"/fromPath",schemaPath:"#/oneOf/2/properties/fromPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var R=s===e}else var R=!0;if(R)if(r.toPath!==void 0){const s=e;if(typeof r.toPath!="string")return o.errors=[{instancePath:t+"/toPath",schemaPath:"#/oneOf/2/properties/toPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var R=s===e}else var R=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="defineWpConfigConsts"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.consts===void 0&&(p="consts")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/3/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="consts"||s==="method"||s==="virtualize"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/3/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/3/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/3/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var M=$===e}else var M=!0;if(M)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/3/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var M=n===e}else var M=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/3/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var W=a===e}else var W=!0;if(W){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/3/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="defineWpConfigConsts")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/3/properties/step/const",keyword:"const",params:{allowedValue:"defineWpConfigConsts"},message:"must be equal to constant"}],!1;var W=a===e}else var W=!0;if(W){if(r.consts!==void 0){let s=r.consts;const a=e;if(e===a&&!(s&&typeof s=="object"&&!Array.isArray(s)))return o.errors=[{instancePath:t+"/consts",schemaPath:"#/oneOf/3/properties/consts/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var W=a===e}else var W=!0;if(W){if(r.method!==void 0){let s=r.method;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/method",schemaPath:"#/oneOf/3/properties/method/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(s==="rewrite-wp-config"||s==="define-before-run"))return o.errors=[{instancePath:t+"/method",schemaPath:"#/oneOf/3/properties/method/enum",keyword:"enum",params:{allowedValues:Ke.oneOf[3].properties.method.enum},message:"must be equal to one of the allowed values"}],!1;var W=a===e}else var W=!0;if(W)if(r.virtualize!==void 0){const s=e;if(typeof r.virtualize!="boolean")return o.errors=[{instancePath:t+"/virtualize",schemaPath:"#/oneOf/3/properties/virtualize/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var W=s===e}else var W=!0}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/3/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="defineSiteUrl"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.siteUrl===void 0&&(p="siteUrl")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/4/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="siteUrl"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/4/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/4/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/4/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var b=$===e}else var b=!0;if(b)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/4/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var b=n===e}else var b=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/4/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var D=a===e}else var D=!0;if(D){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/4/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="defineSiteUrl")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/4/properties/step/const",keyword:"const",params:{allowedValue:"defineSiteUrl"},message:"must be equal to constant"}],!1;var D=a===e}else var D=!0;if(D)if(r.siteUrl!==void 0){const s=e;if(typeof r.siteUrl!="string")return o.errors=[{instancePath:t+"/siteUrl",schemaPath:"#/oneOf/4/properties/siteUrl/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var D=s===e}else var D=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/4/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="enableMultisite"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/5/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/5/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/5/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/5/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var se=$===e}else var se=!0;if(se)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/5/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var se=n===e}else var se=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/5/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var G=a===e}else var G=!0;if(G)if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/5/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="enableMultisite")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/5/properties/step/const",keyword:"const",params:{allowedValue:"enableMultisite"},message:"must be equal to constant"}],!1;var G=a===e}else var G=!0}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/5/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="importWxr"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.file===void 0&&(p="file")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/6/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="file"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/6/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/6/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/6/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var P=$===e}else var P=!0;if(P)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/6/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var P=n===e}else var P=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/6/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var A=a===e}else var A=!0;if(A){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/6/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="importWxr")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/6/properties/step/const",keyword:"const",params:{allowedValue:"importWxr"},message:"must be equal to constant"}],!1;var A=a===e}else var A=!0;if(A)if(r.file!==void 0){const s=e;te(r.file,{instancePath:t+"/file",parentData:r,parentDataProperty:"file",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var A=s===e}else var A=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/6/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="importThemeStarterContent"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/7/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="themeSlug"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/7/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/7/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/7/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var x=$===e}else var x=!0;if(x)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/7/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var x=n===e}else var x=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/7/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var z=a===e}else var z=!0;if(z){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/7/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="importThemeStarterContent")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/7/properties/step/const",keyword:"const",params:{allowedValue:"importThemeStarterContent"},message:"must be equal to constant"}],!1;var z=a===e}else var z=!0;if(z)if(r.themeSlug!==void 0){const s=e;if(typeof r.themeSlug!="string")return o.errors=[{instancePath:t+"/themeSlug",schemaPath:"#/oneOf/7/properties/themeSlug/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var z=s===e}else var z=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/7/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="importWordPressFiles"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step")||r.wordPressFilesZip===void 0&&(p="wordPressFilesZip"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/8/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="wordPressFilesZip"||s==="pathInZip"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/8/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/8/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/8/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var l=$===e}else var l=!0;if(l)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/8/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var l=n===e}else var l=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/8/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var E=a===e}else var E=!0;if(E){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/8/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="importWordPressFiles")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/8/properties/step/const",keyword:"const",params:{allowedValue:"importWordPressFiles"},message:"must be equal to constant"}],!1;var E=a===e}else var E=!0;if(E){if(r.wordPressFilesZip!==void 0){const s=e;te(r.wordPressFilesZip,{instancePath:t+"/wordPressFilesZip",parentData:r,parentDataProperty:"wordPressFilesZip",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var E=s===e}else var E=!0;if(E)if(r.pathInZip!==void 0){const s=e;if(typeof r.pathInZip!="string")return o.errors=[{instancePath:t+"/pathInZip",schemaPath:"#/oneOf/8/properties/pathInZip/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var E=s===e}else var E=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/8/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="installPlugin"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.pluginZipFile===void 0&&(p="pluginZipFile")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/9/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="ifAlreadyInstalled"||s==="step"||s==="pluginZipFile"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/9/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/9/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/9/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var _=$===e}else var _=!0;if(_)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/9/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var _=n===e}else var _=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/9/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var k=a===e}else var k=!0;if(k){if(r.ifAlreadyInstalled!==void 0){let s=r.ifAlreadyInstalled;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/9/properties/ifAlreadyInstalled/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(s==="overwrite"||s==="skip"||s==="error"))return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/9/properties/ifAlreadyInstalled/enum",keyword:"enum",params:{allowedValues:Ke.oneOf[9].properties.ifAlreadyInstalled.enum},message:"must be equal to one of the allowed values"}],!1;var k=a===e}else var k=!0;if(k){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/9/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="installPlugin")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/9/properties/step/const",keyword:"const",params:{allowedValue:"installPlugin"},message:"must be equal to constant"}],!1;var k=a===e}else var k=!0;if(k){if(r.pluginZipFile!==void 0){const s=e;te(r.pluginZipFile,{instancePath:t+"/pluginZipFile",parentData:r,parentDataProperty:"pluginZipFile",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var k=s===e}else var k=!0;if(k)if(r.options!==void 0){let s=r.options;const a=e;if(e===e)if(s&&typeof s=="object"&&!Array.isArray(s)){const $=e;for(const be in s)if(be!=="activate")return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/InstallPluginOptions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:be},message:"must NOT have additional properties"}],!1;if($===e&&s.activate!==void 0&&typeof s.activate!="boolean")return o.errors=[{instancePath:t+"/options/activate",schemaPath:"#/definitions/InstallPluginOptions/properties/activate/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1}else return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/InstallPluginOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var k=a===e}else var k=!0}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/9/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="installTheme"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step")||r.themeZipFile===void 0&&(p="themeZipFile"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/10/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="ifAlreadyInstalled"||s==="step"||s==="themeZipFile"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/10/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/10/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/10/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var g=$===e}else var g=!0;if(g)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/10/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=n===e}else var g=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/10/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var m=a===e}else var m=!0;if(m){if(r.ifAlreadyInstalled!==void 0){let s=r.ifAlreadyInstalled;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/10/properties/ifAlreadyInstalled/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(s==="overwrite"||s==="skip"||s==="error"))return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/10/properties/ifAlreadyInstalled/enum",keyword:"enum",params:{allowedValues:Ke.oneOf[10].properties.ifAlreadyInstalled.enum},message:"must be equal to one of the allowed values"}],!1;var m=a===e}else var m=!0;if(m){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/10/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="installTheme")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/10/properties/step/const",keyword:"const",params:{allowedValue:"installTheme"},message:"must be equal to constant"}],!1;var m=a===e}else var m=!0;if(m){if(r.themeZipFile!==void 0){const s=e;te(r.themeZipFile,{instancePath:t+"/themeZipFile",parentData:r,parentDataProperty:"themeZipFile",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var m=s===e}else var m=!0;if(m)if(r.options!==void 0){let s=r.options;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const n=e;for(const $ in s)if(!($==="activate"||$==="importStarterContent"))return o.errors=[{instancePath:t+"/options",schemaPath:"#/oneOf/10/properties/options/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:$},message:"must NOT have additional properties"}],!1;if(n===e){if(s.activate!==void 0){const $=e;if(typeof s.activate!="boolean")return o.errors=[{instancePath:t+"/options/activate",schemaPath:"#/oneOf/10/properties/options/properties/activate/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var y=$===e}else var y=!0;if(y)if(s.importStarterContent!==void 0){const $=e;if(typeof s.importStarterContent!="boolean")return o.errors=[{instancePath:t+"/options/importStarterContent",schemaPath:"#/oneOf/10/properties/options/properties/importStarterContent/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var y=$===e}else var y=!0}}else return o.errors=[{instancePath:t+"/options",schemaPath:"#/oneOf/10/properties/options/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var m=a===e}else var m=!0}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/10/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="login"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/11/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="username"||s==="password"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/11/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/11/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/11/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var h=$===e}else var h=!0;if(h)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/11/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var h=n===e}else var h=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/11/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var w=a===e}else var w=!0;if(w){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/11/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="login")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/11/properties/step/const",keyword:"const",params:{allowedValue:"login"},message:"must be equal to constant"}],!1;var w=a===e}else var w=!0;if(w){if(r.username!==void 0){const s=e;if(typeof r.username!="string")return o.errors=[{instancePath:t+"/username",schemaPath:"#/oneOf/11/properties/username/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var w=s===e}else var w=!0;if(w)if(r.password!==void 0){const s=e;if(typeof r.password!="string")return o.errors=[{instancePath:t+"/password",schemaPath:"#/oneOf/11/properties/password/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var w=s===e}else var w=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/11/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="mkdir"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.path===void 0&&(p="path")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/12/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/12/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/12/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/12/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var S=$===e}else var S=!0;if(S)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/12/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var S=n===e}else var S=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/12/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var j=a===e}else var j=!0;if(j){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/12/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="mkdir")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/12/properties/step/const",keyword:"const",params:{allowedValue:"mkdir"},message:"must be equal to constant"}],!1;var j=a===e}else var j=!0;if(j)if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/12/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var j=s===e}else var j=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/12/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="mv"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.fromPath===void 0&&(p="fromPath")||r.step===void 0&&(p="step")||r.toPath===void 0&&(p="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/13/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="fromPath"||s==="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/13/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/13/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/13/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var F=$===e}else var F=!0;if(F)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/13/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var F=n===e}else var F=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/13/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var T=a===e}else var T=!0;if(T){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/13/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="mv")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/13/properties/step/const",keyword:"const",params:{allowedValue:"mv"},message:"must be equal to constant"}],!1;var T=a===e}else var T=!0;if(T){if(r.fromPath!==void 0){const s=e;if(typeof r.fromPath!="string")return o.errors=[{instancePath:t+"/fromPath",schemaPath:"#/oneOf/13/properties/fromPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var T=s===e}else var T=!0;if(T)if(r.toPath!==void 0){const s=e;if(typeof r.toPath!="string")return o.errors=[{instancePath:t+"/toPath",schemaPath:"#/oneOf/13/properties/toPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var T=s===e}else var T=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/13/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="resetData"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/14/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/14/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/14/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/14/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var H=$===e}else var H=!0;if(H)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/14/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var H=n===e}else var H=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/14/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var re=a===e}else var re=!0;if(re)if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/14/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="resetData")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/14/properties/step/const",keyword:"const",params:{allowedValue:"resetData"},message:"must be equal to constant"}],!1;var re=a===e}else var re=!0}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/14/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="request"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.request===void 0&&(p="request")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/15/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="request"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/15/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/15/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/15/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var J=$===e}else var J=!0;if(J)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/15/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var J=n===e}else var J=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/15/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var N=a===e}else var N=!0;if(N){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/15/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="request")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/15/properties/step/const",keyword:"const",params:{allowedValue:"request"},message:"must be equal to constant"}],!1;var N=a===e}else var N=!0;if(N)if(r.request!==void 0){const s=e;ce(r.request,{instancePath:t+"/request",parentData:r,parentDataProperty:"request",rootData:c})||(i=i===null?ce.errors:i.concat(ce.errors),e=i.length);var N=s===e}else var N=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/15/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="rm"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.path===void 0&&(p="path")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/16/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/16/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/16/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/16/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var X=$===e}else var X=!0;if(X)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/16/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var X=n===e}else var X=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/16/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var I=a===e}else var I=!0;if(I){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/16/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="rm")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/16/properties/step/const",keyword:"const",params:{allowedValue:"rm"},message:"must be equal to constant"}],!1;var I=a===e}else var I=!0;if(I)if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/16/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var I=s===e}else var I=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/16/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="rmdir"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.path===void 0&&(p="path")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/17/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/17/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/17/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/17/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Z=$===e}else var Z=!0;if(Z)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/17/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Z=n===e}else var Z=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/17/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var K=a===e}else var K=!0;if(K){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/17/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="rmdir")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/17/properties/step/const",keyword:"const",params:{allowedValue:"rmdir"},message:"must be equal to constant"}],!1;var K=a===e}else var K=!0;if(K)if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/17/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var K=s===e}else var K=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/17/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="runPHP"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.code===void 0&&(p="code")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/18/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="code"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/18/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/18/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/18/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var ae=$===e}else var ae=!0;if(ae)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/18/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var ae=n===e}else var ae=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/18/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var pe=a===e}else var pe=!0;if(pe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/18/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runPHP")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/18/properties/step/const",keyword:"const",params:{allowedValue:"runPHP"},message:"must be equal to constant"}],!1;var pe=a===e}else var pe=!0;if(pe)if(r.code!==void 0){const s=e;if(typeof r.code!="string")return o.errors=[{instancePath:t+"/code",schemaPath:"#/oneOf/18/properties/code/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var pe=s===e}else var pe=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/18/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="runPHPWithOptions"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.options===void 0&&(p="options")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/19/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/19/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/19/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/19/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Re=$===e}else var Re=!0;if(Re)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/19/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Re=n===e}else var Re=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/19/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ve=a===e}else var ve=!0;if(ve){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/19/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runPHPWithOptions")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/19/properties/step/const",keyword:"const",params:{allowedValue:"runPHPWithOptions"},message:"must be equal to constant"}],!1;var ve=a===e}else var ve=!0;if(ve)if(r.options!==void 0){const s=e;ie(r.options,{instancePath:t+"/options",parentData:r,parentDataProperty:"options",rootData:c})||(i=i===null?ie.errors:i.concat(ie.errors),e=i.length);var ve=s===e}else var ve=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/19/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="runWpInstallationWizard"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.options===void 0&&(p="options")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/20/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/20/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/20/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/20/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Se=$===e}else var Se=!0;if(Se)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/20/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Se=n===e}else var Se=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/20/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Pe=a===e}else var Pe=!0;if(Pe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/20/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runWpInstallationWizard")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/20/properties/step/const",keyword:"const",params:{allowedValue:"runWpInstallationWizard"},message:"must be equal to constant"}],!1;var Pe=a===e}else var Pe=!0;if(Pe)if(r.options!==void 0){let s=r.options;const a=e;if(e===e)if(s&&typeof s=="object"&&!Array.isArray(s)){const $=e;for(const be in s)if(!(be==="adminUsername"||be==="adminPassword"))return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/WordPressInstallationOptions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:be},message:"must NOT have additional properties"}],!1;if($===e){if(s.adminUsername!==void 0){const be=e;if(typeof s.adminUsername!="string")return o.errors=[{instancePath:t+"/options/adminUsername",schemaPath:"#/definitions/WordPressInstallationOptions/properties/adminUsername/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Le=be===e}else var Le=!0;if(Le)if(s.adminPassword!==void 0){const be=e;if(typeof s.adminPassword!="string")return o.errors=[{instancePath:t+"/options/adminPassword",schemaPath:"#/definitions/WordPressInstallationOptions/properties/adminPassword/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Le=be===e}else var Le=!0}}else return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/WordPressInstallationOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Pe=a===e}else var Pe=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/20/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="runSql"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.sql===void 0&&(p="sql")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/21/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="sql"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/21/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/21/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/21/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ne=$===e}else var Ne=!0;if(Ne)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/21/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ne=n===e}else var Ne=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/21/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var _e=a===e}else var _e=!0;if(_e){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/21/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runSql")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/21/properties/step/const",keyword:"const",params:{allowedValue:"runSql"},message:"must be equal to constant"}],!1;var _e=a===e}else var _e=!0;if(_e)if(r.sql!==void 0){const s=e;te(r.sql,{instancePath:t+"/sql",parentData:r,parentDataProperty:"sql",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var _e=s===e}else var _e=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/21/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="setSiteOptions"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.options===void 0&&(p="options")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/22/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/22/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/22/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/22/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var xe=$===e}else var xe=!0;if(xe)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/22/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var xe=n===e}else var xe=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/22/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ke=a===e}else var ke=!0;if(ke){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/22/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="setSiteOptions")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/22/properties/step/const",keyword:"const",params:{allowedValue:"setSiteOptions"},message:"must be equal to constant"}],!1;var ke=a===e}else var ke=!0;if(ke)if(r.options!==void 0){let s=r.options;const a=e;if(e===a&&!(s&&typeof s=="object"&&!Array.isArray(s)))return o.errors=[{instancePath:t+"/options",schemaPath:"#/oneOf/22/properties/options/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ke=a===e}else var ke=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/22/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="unzip"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.extractToPath===void 0&&(p="extractToPath")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/23/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="zipFile"||s==="zipPath"||s==="extractToPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/23/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/23/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/23/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Fe=$===e}else var Fe=!0;if(Fe)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/23/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Fe=n===e}else var Fe=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/23/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var fe=a===e}else var fe=!0;if(fe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/23/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="unzip")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/23/properties/step/const",keyword:"const",params:{allowedValue:"unzip"},message:"must be equal to constant"}],!1;var fe=a===e}else var fe=!0;if(fe){if(r.zipFile!==void 0){const s=e;te(r.zipFile,{instancePath:t+"/zipFile",parentData:r,parentDataProperty:"zipFile",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var fe=s===e}else var fe=!0;if(fe){if(r.zipPath!==void 0){const s=e;if(typeof r.zipPath!="string")return o.errors=[{instancePath:t+"/zipPath",schemaPath:"#/oneOf/23/properties/zipPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var fe=s===e}else var fe=!0;if(fe)if(r.extractToPath!==void 0){const s=e;if(typeof r.extractToPath!="string")return o.errors=[{instancePath:t+"/extractToPath",schemaPath:"#/oneOf/23/properties/extractToPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var fe=s===e}else var fe=!0}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/23/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="updateUserMeta"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.meta===void 0&&(p="meta")||r.step===void 0&&(p="step")||r.userId===void 0&&(p="userId"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/24/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="meta"||s==="userId"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/24/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/24/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/24/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ce=$===e}else var Ce=!0;if(Ce)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/24/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ce=n===e}else var Ce=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/24/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ye=a===e}else var ye=!0;if(ye){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/24/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="updateUserMeta")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/24/properties/step/const",keyword:"const",params:{allowedValue:"updateUserMeta"},message:"must be equal to constant"}],!1;var ye=a===e}else var ye=!0;if(ye){if(r.meta!==void 0){let s=r.meta;const a=e;if(e===a&&!(s&&typeof s=="object"&&!Array.isArray(s)))return o.errors=[{instancePath:t+"/meta",schemaPath:"#/oneOf/24/properties/meta/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ye=a===e}else var ye=!0;if(ye)if(r.userId!==void 0){let s=r.userId;const a=e;if(!(typeof s=="number"&&isFinite(s)))return o.errors=[{instancePath:t+"/userId",schemaPath:"#/oneOf/24/properties/userId/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var ye=a===e}else var ye=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/24/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="writeFile"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.data===void 0&&(p="data")||r.path===void 0&&(p="path")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/25/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"||s==="data"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/25/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/25/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/25/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ie=$===e}else var Ie=!0;if(Ie)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/25/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ie=n===e}else var Ie=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/25/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var he=a===e}else var he=!0;if(he){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/25/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="writeFile")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/25/properties/step/const",keyword:"const",params:{allowedValue:"writeFile"},message:"must be equal to constant"}],!1;var he=a===e}else var he=!0;if(he){if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/25/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var he=s===e}else var he=!0;if(he)if(r.data!==void 0){let s=r.data;const a=e,q=e;let n=!1;const $=e;te(s,{instancePath:t+"/data",parentData:r,parentDataProperty:"data",rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var Ee=$===e;if(n=n||Ee,!n){const de=e;if(typeof s!="string"){const we={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf/1/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[we]:i.push(we),e++}var Ee=de===e;if(n=n||Ee,!n){const we=e;if(e===we)if(s&&typeof s=="object"&&!Array.isArray(s)){let me;if(s.BYTES_PER_ELEMENT===void 0&&(me="BYTES_PER_ELEMENT")||s.buffer===void 0&&(me="buffer")||s.byteLength===void 0&&(me="byteLength")||s.byteOffset===void 0&&(me="byteOffset")||s.length===void 0&&(me="length")){const Ve={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf/2/required",keyword:"required",params:{missingProperty:me},message:"must have required property '"+me+"'"};i===null?i=[Ve]:i.push(Ve),e++}else{const Ve=e;for(const Q in s)if(!(Q==="BYTES_PER_ELEMENT"||Q==="buffer"||Q==="byteLength"||Q==="byteOffset"||Q==="length")){let ue=s[Q];const De=e;if(!(typeof ue=="number"&&isFinite(ue))){const oe={instancePath:t+"/data/"+Q.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/oneOf/25/properties/data/anyOf/2/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[oe]:i.push(oe),e++}var Wr=De===e;if(!Wr)break}if(Ve===e){if(s.BYTES_PER_ELEMENT!==void 0){let Q=s.BYTES_PER_ELEMENT;const ue=e;if(!(typeof Q=="number"&&isFinite(Q))){const De={instancePath:t+"/data/BYTES_PER_ELEMENT",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[De]:i.push(De),e++}var le=ue===e}else var le=!0;if(le){if(s.buffer!==void 0){let Q=s.buffer;const ue=e;if(e===ue)if(Q&&typeof Q=="object"&&!Array.isArray(Q)){let oe;if(Q.byteLength===void 0&&(oe="byteLength")){const Me={instancePath:t+"/data/buffer",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/required",keyword:"required",params:{missingProperty:oe},message:"must have required property '"+oe+"'"};i===null?i=[Me]:i.push(Me),e++}else{const Me=e;for(const je in Q)if(je!=="byteLength"){const Te={instancePath:t+"/data/buffer",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:je},message:"must NOT have additional properties"};i===null?i=[Te]:i.push(Te),e++;break}if(Me===e&&Q.byteLength!==void 0){let je=Q.byteLength;if(!(typeof je=="number"&&isFinite(je))){const Te={instancePath:t+"/data/buffer/byteLength",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Te]:i.push(Te),e++}}}}else{const oe={instancePath:t+"/data/buffer",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[oe]:i.push(oe),e++}var le=ue===e}else var le=!0;if(le){if(s.byteLength!==void 0){let Q=s.byteLength;const ue=e;if(!(typeof Q=="number"&&isFinite(Q))){const oe={instancePath:t+"/data/byteLength",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[oe]:i.push(oe),e++}var le=ue===e}else var le=!0;if(le){if(s.byteOffset!==void 0){let Q=s.byteOffset;const ue=e;if(!(typeof Q=="number"&&isFinite(Q))){const oe={instancePath:t+"/data/byteOffset",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[oe]:i.push(oe),e++}var le=ue===e}else var le=!0;if(le)if(s.length!==void 0){let Q=s.length;const ue=e;if(!(typeof Q=="number"&&isFinite(Q))){const oe={instancePath:t+"/data/length",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[oe]:i.push(oe),e++}var le=ue===e}else var le=!0}}}}}}else{const me={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[me]:i.push(me),e++}var Ee=we===e;n=n||Ee}}if(n)e=q,i!==null&&(q?i.length=q:i=null);else{const de={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[de]:i.push(de),e++,o.errors=i,!1}var he=a===e}else var he=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/25/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="wp-cli"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.command===void 0&&(p="command")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/26/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="command"||s==="wpCliPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/26/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/26/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/26/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var We=$===e}else var We=!0;if(We)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/26/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var We=n===e}else var We=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/26/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ge=a===e}else var ge=!0;if(ge){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/26/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="wp-cli")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/26/properties/step/const",keyword:"const",params:{allowedValue:"wp-cli"},message:"must be equal to constant"}],!1;var ge=a===e}else var ge=!0;if(ge){if(r.command!==void 0){let s=r.command;const a=e,q=e;let n=!1;const $=e;if(typeof s!="string"){const de={instancePath:t+"/command",schemaPath:"#/oneOf/26/properties/command/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[de]:i.push(de),e++}var Xe=$===e;if(n=n||Xe,!n){const de=e;if(e===de)if(Array.isArray(s)){var pr=!0;const we=s.length;for(let Be=0;Be<we;Be++){const me=e;if(typeof s[Be]!="string"){const Q={instancePath:t+"/command/"+Be,schemaPath:"#/oneOf/26/properties/command/anyOf/1/items/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[Q]:i.push(Q),e++}var pr=me===e;if(!pr)break}}else{const we={instancePath:t+"/command",schemaPath:"#/oneOf/26/properties/command/anyOf/1/type",keyword:"type",params:{type:"array"},message:"must be array"};i===null?i=[we]:i.push(we),e++}var Xe=de===e;n=n||Xe}if(n)e=q,i!==null&&(q?i.length=q:i=null);else{const de={instancePath:t+"/command",schemaPath:"#/oneOf/26/properties/command/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[de]:i.push(de),e++,o.errors=i,!1}var ge=a===e}else var ge=!0;if(ge)if(r.wpCliPath!==void 0){const s=e;if(typeof r.wpCliPath!="string")return o.errors=[{instancePath:t+"/wpCliPath",schemaPath:"#/oneOf/26/properties/wpCliPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var ge=s===e}else var ge=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/26/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(Y==="setSiteLanguage"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let p;if(r.language===void 0&&(p="language")||r.step===void 0&&(p="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/27/required",keyword:"required",params:{missingProperty:p},message:"must have required property '"+p+"'"}],!1;{const L=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="language"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/27/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(L===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const q=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/27/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(q===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/27/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ue=$===e}else var Ue=!0;if(Ue)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/27/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ue=n===e}else var Ue=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/27/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Oe=a===e}else var Oe=!0;if(Oe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/27/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="setSiteLanguage")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/27/properties/step/const",keyword:"const",params:{allowedValue:"setSiteLanguage"},message:"must be equal to constant"}],!1;var Oe=a===e}else var Oe=!0;if(Oe)if(r.language!==void 0){const s=e;if(typeof r.language!="string")return o.errors=[{instancePath:t+"/language",schemaPath:"#/oneOf/27/properties/language/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Oe=s===e}else var Oe=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/27/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else return o.errors=[{instancePath:t,schemaPath:"#/discriminator",keyword:"discriminator",params:{error:"mapping",tag:"step",tagValue:Y},message:'value of tag "step" must be in oneOf'}],!1;else return o.errors=[{instancePath:t,schemaPath:"#/discriminator",keyword:"discriminator",params:{error:"tag",tag:"step",tagValue:Y},message:'tag "step" must be string'}],!1}}else return o.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return o.errors=i,e===0}function B(r,{instancePath:t="",parentData:f,parentDataProperty:d,rootData:c=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){const z=e;for(const l in r)if(!Cr.call(it.properties,l))return B.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:l},message:"must NOT have additional properties"}],!1;if(z===e){if(r.landingPage!==void 0){const l=e;if(typeof r.landingPage!="string")return B.errors=[{instancePath:t+"/landingPage",schemaPath:"#/properties/landingPage/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=l===e}else var u=!0;if(u){if(r.description!==void 0){const l=e;if(typeof r.description!="string")return B.errors=[{instancePath:t+"/description",schemaPath:"#/properties/description/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=l===e}else var u=!0;if(u){if(r.meta!==void 0){let l=r.meta;const E=e;if(e===E)if(l&&typeof l=="object"&&!Array.isArray(l)){let k;if(l.title===void 0&&(k="title")||l.author===void 0&&(k="author"))return B.errors=[{instancePath:t+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty:k},message:"must have required property '"+k+"'"}],!1;{const g=e;for(const m in l)if(!(m==="title"||m==="description"||m==="author"||m==="categories"))return B.errors=[{instancePath:t+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:m},message:"must NOT have additional properties"}],!1;if(g===e){if(l.title!==void 0){const m=e;if(typeof l.title!="string")return B.errors=[{instancePath:t+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=m===e}else var O=!0;if(O){if(l.description!==void 0){const m=e;if(typeof l.description!="string")return B.errors=[{instancePath:t+"/meta/description",schemaPath:"#/properties/meta/properties/description/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=m===e}else var O=!0;if(O){if(l.author!==void 0){const m=e;if(typeof l.author!="string")return B.errors=[{instancePath:t+"/meta/author",schemaPath:"#/properties/meta/properties/author/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=m===e}else var O=!0;if(O)if(l.categories!==void 0){let m=l.categories;const y=e;if(e===y)if(Array.isArray(m)){var V=!0;const w=m.length;for(let S=0;S<w;S++){const j=e;if(typeof m[S]!="string")return B.errors=[{instancePath:t+"/meta/categories/"+S,schemaPath:"#/properties/meta/properties/categories/items/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var V=j===e;if(!V)break}}else return B.errors=[{instancePath:t+"/meta/categories",schemaPath:"#/properties/meta/properties/categories/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var O=y===e}else var O=!0}}}}}else return B.errors=[{instancePath:t+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=E===e}else var u=!0;if(u){if(r.preferredVersions!==void 0){let l=r.preferredVersions;const E=e;if(e===E)if(l&&typeof l=="object"&&!Array.isArray(l)){let k;if(l.php===void 0&&(k="php")||l.wp===void 0&&(k="wp"))return B.errors=[{instancePath:t+"/preferredVersions",schemaPath:"#/properties/preferredVersions/required",keyword:"required",params:{missingProperty:k},message:"must have required property '"+k+"'"}],!1;{const g=e;for(const m in l)if(!(m==="php"||m==="wp"))return B.errors=[{instancePath:t+"/preferredVersions",schemaPath:"#/properties/preferredVersions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:m},message:"must NOT have additional properties"}],!1;if(g===e){if(l.php!==void 0){let m=l.php;const y=e,h=e;let w=!1;const S=e;if(typeof m!="string"){const j={instancePath:t+"/preferredVersions/php",schemaPath:"#/definitions/SupportedPHPVersion/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[j]:i.push(j),e++}if(!(m==="8.3"||m==="8.2"||m==="8.1"||m==="8.0"||m==="7.4"||m==="7.3"||m==="7.2"||m==="7.1"||m==="7.0")){const j={instancePath:t+"/preferredVersions/php",schemaPath:"#/definitions/SupportedPHPVersion/enum",keyword:"enum",params:{allowedValues:ot.enum},message:"must be equal to one of the allowed values"};i===null?i=[j]:i.push(j),e++}var U=S===e;if(w=w||U,!w){const j=e;if(typeof m!="string"){const T={instancePath:t+"/preferredVersions/php",schemaPath:"#/properties/preferredVersions/properties/php/anyOf/1/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[T]:i.push(T),e++}if(m!=="latest"){const T={instancePath:t+"/preferredVersions/php",schemaPath:"#/properties/preferredVersions/properties/php/anyOf/1/const",keyword:"const",params:{allowedValue:"latest"},message:"must be equal to constant"};i===null?i=[T]:i.push(T),e++}var U=j===e;w=w||U}if(w)e=h,i!==null&&(h?i.length=h:i=null);else{const j={instancePath:t+"/preferredVersions/php",schemaPath:"#/properties/preferredVersions/properties/php/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[j]:i.push(j),e++,B.errors=i,!1}var v=y===e}else var v=!0;if(v)if(l.wp!==void 0){const m=e;if(typeof l.wp!="string")return B.errors=[{instancePath:t+"/preferredVersions/wp",schemaPath:"#/properties/preferredVersions/properties/wp/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var v=m===e}else var v=!0}}}else return B.errors=[{instancePath:t+"/preferredVersions",schemaPath:"#/properties/preferredVersions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=E===e}else var u=!0;if(u){if(r.features!==void 0){let l=r.features;const E=e;if(e===E)if(l&&typeof l=="object"&&!Array.isArray(l)){const k=e;for(const g in l)if(g!=="networking")return B.errors=[{instancePath:t+"/features",schemaPath:"#/properties/features/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:g},message:"must NOT have additional properties"}],!1;if(k===e&&l.networking!==void 0&&typeof l.networking!="boolean")return B.errors=[{instancePath:t+"/features/networking",schemaPath:"#/properties/features/properties/networking/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1}else return B.errors=[{instancePath:t+"/features",schemaPath:"#/properties/features/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=E===e}else var u=!0;if(u){if(r.extraLibraries!==void 0){let l=r.extraLibraries;const E=e;if(e===E)if(Array.isArray(l)){var R=!0;const k=l.length;for(let g=0;g<k;g++){let m=l[g];const y=e;if(typeof m!="string")return B.errors=[{instancePath:t+"/extraLibraries/"+g,schemaPath:"#/definitions/ExtraLibrary/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(m!=="wp-cli")return B.errors=[{instancePath:t+"/extraLibraries/"+g,schemaPath:"#/definitions/ExtraLibrary/const",keyword:"const",params:{allowedValue:"wp-cli"},message:"must be equal to constant"}],!1;var R=y===e;if(!R)break}}else return B.errors=[{instancePath:t+"/extraLibraries",schemaPath:"#/properties/extraLibraries/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var u=E===e}else var u=!0;if(u){if(r.constants!==void 0){let l=r.constants;const E=e;if(e===E)if(l&&typeof l=="object"&&!Array.isArray(l))for(const k in l){const g=e;if(typeof l[k]!="string")return B.errors=[{instancePath:t+"/constants/"+k.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/constants/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var M=g===e;if(!M)break}else return B.errors=[{instancePath:t+"/constants",schemaPath:"#/properties/constants/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=E===e}else var u=!0;if(u){if(r.plugins!==void 0){let l=r.plugins;const E=e;if(e===E)if(Array.isArray(l)){var W=!0;const k=l.length;for(let g=0;g<k;g++){let m=l[g];const y=e,h=e;let w=!1;const S=e;if(typeof m!="string"){const F={instancePath:t+"/plugins/"+g,schemaPath:"#/properties/plugins/items/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[F]:i.push(F),e++}var b=S===e;if(w=w||b,!w){const F=e;te(m,{instancePath:t+"/plugins/"+g,parentData:l,parentDataProperty:g,rootData:c})||(i=i===null?te.errors:i.concat(te.errors),e=i.length);var b=F===e;w=w||b}if(w)e=h,i!==null&&(h?i.length=h:i=null);else{const F={instancePath:t+"/plugins/"+g,schemaPath:"#/properties/plugins/items/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[F]:i.push(F),e++,B.errors=i,!1}var W=y===e;if(!W)break}}else return B.errors=[{instancePath:t+"/plugins",schemaPath:"#/properties/plugins/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var u=E===e}else var u=!0;if(u){if(r.siteOptions!==void 0){let l=r.siteOptions;const E=e;if(e===E)if(l&&typeof l=="object"&&!Array.isArray(l)){const k=e;for(const g in l)if(g!=="blogname"){const m=e;if(typeof l[g]!="string")return B.errors=[{instancePath:t+"/siteOptions/"+g.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/siteOptions/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var D=m===e;if(!D)break}if(k===e&&l.blogname!==void 0&&typeof l.blogname!="string")return B.errors=[{instancePath:t+"/siteOptions/blogname",schemaPath:"#/properties/siteOptions/properties/blogname/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1}else return B.errors=[{instancePath:t+"/siteOptions",schemaPath:"#/properties/siteOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=E===e}else var u=!0;if(u){if(r.login!==void 0){let l=r.login;const E=e,_=e;let k=!1;const g=e;if(typeof l!="boolean"){const y={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/0/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};i===null?i=[y]:i.push(y),e++}var se=g===e;if(k=k||se,!k){const y=e;if(e===y)if(l&&typeof l=="object"&&!Array.isArray(l)){let w;if(l.username===void 0&&(w="username")||l.password===void 0&&(w="password")){const S={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/1/required",keyword:"required",params:{missingProperty:w},message:"must have required property '"+w+"'"};i===null?i=[S]:i.push(S),e++}else{const S=e;for(const j in l)if(!(j==="username"||j==="password")){const F={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/1/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:j},message:"must NOT have additional properties"};i===null?i=[F]:i.push(F),e++;break}if(S===e){if(l.username!==void 0){const j=e;if(typeof l.username!="string"){const F={instancePath:t+"/login/username",schemaPath:"#/properties/login/anyOf/1/properties/username/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[F]:i.push(F),e++}var G=j===e}else var G=!0;if(G)if(l.password!==void 0){const j=e;if(typeof l.password!="string"){const T={instancePath:t+"/login/password",schemaPath:"#/properties/login/anyOf/1/properties/password/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[T]:i.push(T),e++}var G=j===e}else var G=!0}}}else{const w={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[w]:i.push(w),e++}var se=y===e;k=k||se}if(k)e=_,i!==null&&(_?i.length=_:i=null);else{const y={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[y]:i.push(y),e++,B.errors=i,!1}var u=E===e}else var u=!0;if(u){if(r.phpExtensionBundles!==void 0){let l=r.phpExtensionBundles;const E=e;if(e===E)if(Array.isArray(l)){var P=!0;const k=l.length;for(let g=0;g<k;g++){let m=l[g];const y=e;if(typeof m!="string")return B.errors=[{instancePath:t+"/phpExtensionBundles/"+g,schemaPath:"#/definitions/SupportedPHPExtensionBundle/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(m==="kitchen-sink"||m==="light"))return B.errors=[{instancePath:t+"/phpExtensionBundles/"+g,schemaPath:"#/definitions/SupportedPHPExtensionBundle/enum",keyword:"enum",params:{allowedValues:nt.enum},message:"must be equal to one of the allowed values"}],!1;var P=y===e;if(!P)break}}else return B.errors=[{instancePath:t+"/phpExtensionBundles",schemaPath:"#/properties/phpExtensionBundles/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var u=E===e}else var u=!0;if(u){if(r.steps!==void 0){let l=r.steps;const E=e;if(e===E)if(Array.isArray(l)){var A=!0;const k=l.length;for(let g=0;g<k;g++){let m=l[g];const y=e,h=e;let w=!1;const S=e;o(m,{instancePath:t+"/steps/"+g,parentData:l,parentDataProperty:g,rootData:c})||(i=i===null?o.errors:i.concat(o.errors),e=i.length);var x=S===e;if(w=w||x,!w){const F=e;if(typeof m!="string"){const H={instancePath:t+"/steps/"+g,schemaPath:"#/properties/steps/items/anyOf/1/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[H]:i.push(H),e++}var x=F===e;if(w=w||x,!w){const H=e,re={instancePath:t+"/steps/"+g,schemaPath:"#/properties/steps/items/anyOf/2/not",keyword:"not",params:{},message:"must NOT be valid"};i===null?i=[re]:i.push(re),e++;var x=H===e;if(w=w||x,!w){const N=e;if(typeof m!="boolean"){const I={instancePath:t+"/steps/"+g,schemaPath:"#/properties/steps/items/anyOf/3/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};i===null?i=[I]:i.push(I),e++}if(m!==!1){const I={instancePath:t+"/steps/"+g,schemaPath:"#/properties/steps/items/anyOf/3/const",keyword:"const",params:{allowedValue:!1},message:"must be equal to constant"};i===null?i=[I]:i.push(I),e++}var x=N===e;if(w=w||x,!w){const I=e;if(m!==null){const K={instancePath:t+"/steps/"+g,schemaPath:"#/properties/steps/items/anyOf/4/type",keyword:"type",params:{type:"null"},message:"must be null"};i===null?i=[K]:i.push(K),e++}var x=I===e;w=w||x}}}}if(w)e=h,i!==null&&(h?i.length=h:i=null);else{const F={instancePath:t+"/steps/"+g,schemaPath:"#/properties/steps/items/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[F]:i.push(F),e++,B.errors=i,!1}var A=y===e;if(!A)break}}else return B.errors=[{instancePath:t+"/steps",schemaPath:"#/properties/steps/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var u=E===e}else var u=!0;if(u)if(r.$schema!==void 0){const l=e;if(typeof r.$schema!="string")return B.errors=[{instancePath:t+"/$schema",schemaPath:"#/properties/%24schema/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=l===e}else var u=!0}}}}}}}}}}}}}else return B.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return B.errors=i,e===0}function ze(r,{instancePath:t="",parentData:f,parentDataProperty:d,rootData:c=r}={}){let i=null,e=0;return B(r,{instancePath:t,parentData:f,parentDataProperty:d,rootData:c})||(i=i===null?B.errors:i.concat(B.errors),e=i.length),ze.errors=i,e===0}const{wpCLI:pt,...dr}=Gr,ft={...dr,"wp-cli":pt,importFile:dr.importWxr};function lt(r,{progress:t=new mr.ProgressTracker,semaphore:f=new C.Semaphore({concurrency:3}),onStepCompleted:d=()=>{}}={}){var v,R,M,W,b,D,se,G,P;r=structuredClone(r),r={...r,steps:(r.steps||[]).filter(mt).filter(yt)};for(const A of r.steps)typeof A=="object"&&A.step==="importFile"&&(A.step="importWxr",ne.logger.warn('The "importFile" step is deprecated. Use "importWxr" instead.'));if(r.constants&&r.steps.unshift({step:"defineWpConfigConsts",consts:r.constants}),r.siteOptions&&r.steps.unshift({step:"setSiteOptions",options:r.siteOptions}),r.plugins){const A=r.plugins.map(x=>typeof x=="string"?x.startsWith("https://")?{resource:"url",url:x}:{resource:"wordpress.org/plugins",slug:x}:x).map(x=>({step:"installPlugin",pluginZipFile:x}));r.steps.unshift(...A)}r.login&&r.steps.push({step:"login",...r.login===!0?{username:"admin",password:"password"}:r.login}),r.phpExtensionBundles||(r.phpExtensionBundles=[]),r.phpExtensionBundles||(r.phpExtensionBundles=[]),r.phpExtensionBundles.length===0&&(r.phpExtensionBundles=[...r.phpExtensionBundles,"kitchen-sink"]);const c=((v=r.steps)==null?void 0:v.findIndex(A=>typeof A=="object"&&(A==null?void 0:A.step)==="wp-cli"))??-1;if((R=r==null?void 0:r.extraLibraries)!=null&&R.includes("wp-cli")||c>-1){r.phpExtensionBundles.includes("light")&&(r.phpExtensionBundles=r.phpExtensionBundles.filter(x=>x!=="light"),ne.logger.warn("WP-CLI is used in your Blueprint, and it requires the iconv and mbstring PHP extensions. However, you did not specify the kitchen-sink extension bundle. Playground will override your choice and load the kitchen-sink PHP extensions bundle to prevent the WP-CLI step from failing. "));const A={step:"writeFile",data:{resource:"url",url:"https://playground.wordpress.net/wp-cli.phar"},path:"/tmp/wp-cli.phar"};c===-1?(M=r.steps)==null||M.push(A):(W=r.steps)==null||W.splice(c,0,A)}const i=(b=r.steps)==null?void 0:b.findIndex(A=>typeof A=="object"&&(A==null?void 0:A.step)==="importWxr");i!==void 0&&i>-1&&(r.phpExtensionBundles.includes("light")&&(r.phpExtensionBundles=r.phpExtensionBundles.filter(A=>A!=="light"),ne.logger.warn("The importWxr step used in your Blueprint requires the iconv and mbstring PHP extensions. However, you did not specify the kitchen-sink extension bundle. Playground will override your choice and load the kitchen-sink PHP extensions bundle to prevent the WP-CLI step from failing. ")),(D=r.steps)==null||D.splice(i,0,{step:"installPlugin",pluginZipFile:{resource:"url",url:"https://playground.wordpress.net/wordpress-importer.zip",caption:"Downloading the WordPress Importer plugin"}}));const{valid:e,errors:u}=dt(r);if(!e){const A=new Error(`Invalid blueprint: ${u[0].message} at ${u[0].instancePath}`);throw A.errors=u,A}const O=r.steps||[],V=O.reduce((A,x)=>{var z;return A+(((z=x.progress)==null?void 0:z.weight)||1)},0),U=O.map(A=>ht(A,{semaphore:f,rootProgressTracker:t,totalProgressWeight:V}));return{versions:{php:ut((se=r.preferredVersions)==null?void 0:se.php,qe.SupportedPHPVersions,qe.LatestSupportedPHPVersion),wp:((G=r.preferredVersions)==null?void 0:G.wp)||"latest"},phpExtensions:ct([],r.phpExtensionBundles||[]),features:{networking:((P=r.features)==null?void 0:P.networking)??!1},extraLibraries:r.extraLibraries||[],run:async A=>{try{for(const{resources:x}of U)for(const z of x)z.setPlayground(A),z.isAsync&&z.resolve();for(const[x,{run:z,step:l}]of Object.entries(U))try{const E=await z(A);d(E,l)}catch(E){throw ne.logger.error(E),new Error(`Error when executing the blueprint step #${x} (${JSON.stringify(l)}) ${E instanceof Error?`: ${E.message}`:E}`,{cause:E})}}finally{try{await A.goTo(r.landingPage||"/")}catch{}t.finish()}}}}function dt(r){var c;const t=ze(r);if(t)return{valid:t};const f=new Set;for(const i of ze.errors)i.schemaPath.startsWith("#/properties/steps/items/anyOf")||f.add(i.instancePath);const d=(c=ze.errors)==null?void 0:c.filter(i=>!(i.schemaPath.startsWith("#/properties/steps/items/anyOf")&&f.has(i.instancePath)));return{valid:t,errors:d}}function ut(r,t,f){return r&&t.includes(r)?r:f}function ct(r,t){const f=qe.SupportedPHPExtensionsList.filter(c=>r.includes(c)),d=t.flatMap(c=>c in qe.SupportedPHPExtensionBundles?qe.SupportedPHPExtensionBundles[c]:[]);return Array.from(new Set([...f,...d]))}function mt(r){return!!(typeof r=="object"&&r)}function yt(r){return["setPhpIniEntry","request"].includes(r.step)?(ne.logger.warn(`The "${r.step}" Blueprint is no longer supported and you can remove it from your Blueprint.`),!1):!0}function ht(r,{semaphore:t,rootProgressTracker:f,totalProgressWeight:d}){var U;const c=f.stage((((U=r.progress)==null?void 0:U.weight)||1)/d),i={};for(const v of Object.keys(r)){let R=r[v];Zr(R)&&(R=$e.create(R,{semaphore:t})),i[v]=R}const e=async v=>{var R;try{return c.fillSlowly(),await ft[r.step](v,await gt(i),{tracker:c,initialCaption:(R=r.progress)==null?void 0:R.caption})}finally{c.finish()}},u=ur(i),O=ur(i).filter(v=>v.isAsync),V=1/(O.length+1);for(const v of O)v.progress=c.stage(V);return{run:e,step:r,resources:u}}function ur(r){const t=[];for(const f in r){const d=r[f];d instanceof $e&&t.push(d)}return t}async function gt(r){const t={};for(const f in r){const d=r[f];d instanceof $e?t[f]=await d.resolve():t[f]=d}return t}async function bt(r,t){await r.run(t)}function wt(){}exports.activatePlugin=Ye;exports.activateTheme=rr;exports.compileBlueprint=lt;exports.cp=vr;exports.defineSiteUrl=or;exports.defineWpConfigConsts=Ae;exports.enableMultisite=wr;exports.exportWXR=Er;exports.importThemeStarterContent=nr;exports.importWordPressFiles=$r;exports.importWxr=Or;exports.installPlugin=Tr;exports.installTheme=qr;exports.login=Ge;exports.mkdir=_r;exports.mv=Pr;exports.request=He;exports.resetData=Ar;exports.rm=tr;exports.rmdir=kr;exports.runBlueprintSteps=bt;exports.runPHP=yr;exports.runPHPWithOptions=hr;exports.runSql=gr;exports.runWpInstallationWizard=Rr;exports.setPluginProxyURL=wt;exports.setSiteLanguage=Nr;exports.setSiteOptions=sr;exports.unzip=Ze;exports.updateUserMeta=br;exports.wpCLI=Lr;exports.wpContentFilesExcludedFromExport=er;exports.writeFile=ir;exports.zipWpContent=Sr;
663
+ for existing apps using this option.`}},required:["consts","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"defineSiteUrl"},siteUrl:{type:"string",description:"The URL"}},required:["siteUrl","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"enableMultisite"},wpCliPath:{type:"string",description:"wp-cli.phar path"}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"importWxr"},file:{$ref:"#/definitions/FileReference",description:"The file to import"}},required:["file","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"importThemeStarterContent",description:"The step identifier."},themeSlug:{type:"string",description:"The name of the theme to import content from."}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"importWordPressFiles"},wordPressFilesZip:{$ref:"#/definitions/FileReference",description:"The zip file containing the top-level WordPress files and directories."},pathInZip:{type:"string",description:"The path inside the zip file where the WordPress files are."}},required:["step","wordPressFilesZip"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},ifAlreadyInstalled:{type:"string",enum:["overwrite","skip","error"],description:"What to do if the asset already exists."},step:{type:"string",const:"installPlugin",description:"The step identifier."},pluginData:{anyOf:[{$ref:"#/definitions/FileReference"},{$ref:"#/definitions/DirectoryReference"}],description:"The plugin files to install. It can be either a plugin zip file, or a directory containing all the plugin files at its root."},pluginZipFile:{$ref:"#/definitions/FileReference",deprecated:". Use `pluginData` instead."},options:{$ref:"#/definitions/InstallPluginOptions",description:"Optional installation options."}},required:["pluginData","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},ifAlreadyInstalled:{type:"string",enum:["overwrite","skip","error"],description:"What to do if the asset already exists."},step:{type:"string",const:"installTheme",description:"The step identifier."},themeData:{anyOf:[{$ref:"#/definitions/FileReference"},{$ref:"#/definitions/DirectoryReference"}],description:"The theme files to install. It can be either a theme zip file, or a directory containing all the theme files at its root."},themeZipFile:{$ref:"#/definitions/FileReference",deprecated:". Use `themeData` instead."},options:{$ref:"#/definitions/InstallThemeOptions",description:"Optional installation options."}},required:["step","themeData"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"login"},username:{type:"string",description:"The user to log in as. Defaults to 'admin'."},password:{type:"string",deprecated:`The password field is deprecated and will be removed in a future version.
664
+ Only the username field is required for user authentication.`}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"mkdir"},path:{type:"string",description:"The path of the directory you want to create"}},required:["path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"mv"},fromPath:{type:"string",description:"Source path"},toPath:{type:"string",description:"Target path"}},required:["fromPath","step","toPath"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"resetData"}},required:["step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"request"},request:{$ref:"#/definitions/PHPRequest",description:"Request details (See /wordpress-playground/api/universal/interface/PHPRequest)"}},required:["request","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"rm"},path:{type:"string",description:"The path to remove"}},required:["path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"rmdir"},path:{type:"string",description:"The path to remove"}},required:["path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runPHP",description:"The step identifier."},code:{type:"string",description:"The PHP code to run."}},required:["code","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runPHPWithOptions"},options:{$ref:"#/definitions/PHPRunOptions",description:"Run options (See /wordpress-playground/api/universal/interface/PHPRunOptions/))"}},required:["options","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runWpInstallationWizard"},options:{$ref:"#/definitions/WordPressInstallationOptions"}},required:["options","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"runSql",description:"The step identifier."},sql:{$ref:"#/definitions/FileReference",description:"The SQL to run. Each non-empty line must contain a valid SQL query."}},required:["sql","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"setSiteOptions",description:'The name of the step. Must be "setSiteOptions".'},options:{type:"object",additionalProperties:{},description:"The options to set on the site."}},required:["options","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"unzip"},zipFile:{$ref:"#/definitions/FileReference",description:"The zip file to extract"},zipPath:{type:"string",description:"The path of the zip file to extract",deprecated:"Use zipFile instead."},extractToPath:{type:"string",description:"The path to extract the zip file to"}},required:["extractToPath","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"updateUserMeta"},meta:{type:"object",additionalProperties:{},description:'An object of user meta values to set, e.g. { "first_name": "John" }'},userId:{type:"number",description:"User ID"}},required:["meta","step","userId"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"writeFile"},path:{type:"string",description:"The path of the file to write to"},data:{anyOf:[{$ref:"#/definitions/FileReference"},{type:"string"},{type:"object",properties:{BYTES_PER_ELEMENT:{type:"number"},buffer:{type:"object",properties:{byteLength:{type:"number"}},required:["byteLength"],additionalProperties:!1},byteLength:{type:"number"},byteOffset:{type:"number"},length:{type:"number"}},required:["BYTES_PER_ELEMENT","buffer","byteLength","byteOffset","length"],additionalProperties:{type:"number"}}],description:"The data to write"}},required:["data","path","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"writeFiles"},writeToPath:{type:"string",description:"The path of the file to write to"},filesTree:{$ref:"#/definitions/DirectoryReference",description:"The data to write"}},required:["filesTree","step","writeToPath"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"wp-cli",description:"The step identifier."},command:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}],description:"The WP CLI command to run."},wpCliPath:{type:"string",description:"wp-cli.phar path"}},required:["command","step"]},{type:"object",additionalProperties:!1,properties:{progress:{type:"object",properties:{weight:{type:"number"},caption:{type:"string"}},additionalProperties:!1},step:{type:"string",const:"setSiteLanguage"},language:{type:"string",description:"The language to set, e.g. 'en_US'"}},required:["language","step"]}]},vt={type:"object",additionalProperties:{anyOf:[{$ref:"#/definitions/FileTree"},{type:["object","string"]}]},properties:{}},nr={validate:Re};function Re(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r))for(const x in r){let T=r[x];const P=e,E=e;let L=!1;const N=e;nr.validate(T,{instancePath:t+"/"+x.replace(/~/g,"~0").replace(/\//g,"~1"),parentData:r,parentDataProperty:x,rootData:h})||(i=i===null?nr.validate.errors:i.concat(nr.validate.errors),e=i.length);var d=N===e;if(L=L||d,!L){const y=e;if(!(T&&typeof T=="object"&&!Array.isArray(T))&&typeof T!="string"){const V={instancePath:t+"/"+x.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/additionalProperties/anyOf/1/type",keyword:"type",params:{type:vt.additionalProperties.anyOf[1].type},message:"must be object,string"};i===null?i=[V]:i.push(V),e++}var d=y===e;L=L||d}if(L)e=E,i!==null&&(E?i.length=E:i=null);else{const y={instancePath:t+"/"+x.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/additionalProperties/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[y]:i.push(y),e++,Re.errors=i,!1}var g=P===e;if(!g)break}else return Re.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return Re.errors=i,e===0}function _e(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){let g;if(r.files===void 0&&(g="files")||r.name===void 0&&(g="name")||r.resource===void 0&&(g="resource"))return _e.errors=[{instancePath:t,schemaPath:"#/required",keyword:"required",params:{missingProperty:g},message:"must have required property '"+g+"'"}],!1;{const x=e;for(const T in r)if(!(T==="resource"||T==="files"||T==="name"))return _e.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:T},message:"must NOT have additional properties"}],!1;if(x===e){if(r.resource!==void 0){let T=r.resource;const P=e;if(typeof T!="string")return _e.errors=[{instancePath:t+"/resource",schemaPath:"#/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(T!=="literal:directory")return _e.errors=[{instancePath:t+"/resource",schemaPath:"#/properties/resource/const",keyword:"const",params:{allowedValue:"literal:directory"},message:"must be equal to constant"}],!1;var d=P===e}else var d=!0;if(d){if(r.files!==void 0){const T=e;Re(r.files,{instancePath:t+"/files",parentData:r,parentDataProperty:"files",rootData:h})||(i=i===null?Re.errors:i.concat(Re.errors),e=i.length);var d=T===e}else var d=!0;if(d)if(r.name!==void 0){const T=e;if(typeof r.name!="string")return _e.errors=[{instancePath:t+"/name",schemaPath:"#/properties/name/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=T===e}else var d=!0}}}}else return _e.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return _e.errors=i,e===0}function ye(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;const d=e;let g=!1;const x=e;if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let L;if(r.resource===void 0&&(L="resource")||r.url===void 0&&(L="url")||r.ref===void 0&&(L="ref")||r.path===void 0&&(L="path")){const N={instancePath:t,schemaPath:"#/definitions/GitDirectoryReference/required",keyword:"required",params:{missingProperty:L},message:"must have required property '"+L+"'"};i===null?i=[N]:i.push(N),e++}else{const N=e;for(const y in r)if(!(y==="resource"||y==="url"||y==="ref"||y==="path")){const I={instancePath:t,schemaPath:"#/definitions/GitDirectoryReference/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:y},message:"must NOT have additional properties"};i===null?i=[I]:i.push(I),e++;break}if(N===e){if(r.resource!==void 0){let y=r.resource;const I=e;if(typeof y!="string"){const V={instancePath:t+"/resource",schemaPath:"#/definitions/GitDirectoryReference/properties/resource/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[V]:i.push(V),e++}if(y!=="git:directory"){const V={instancePath:t+"/resource",schemaPath:"#/definitions/GitDirectoryReference/properties/resource/const",keyword:"const",params:{allowedValue:"git:directory"},message:"must be equal to constant"};i===null?i=[V]:i.push(V),e++}var P=I===e}else var P=!0;if(P){if(r.url!==void 0){const y=e;if(typeof r.url!="string"){const V={instancePath:t+"/url",schemaPath:"#/definitions/GitDirectoryReference/properties/url/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[V]:i.push(V),e++}var P=y===e}else var P=!0;if(P){if(r.ref!==void 0){const y=e;if(typeof r.ref!="string"){const V={instancePath:t+"/ref",schemaPath:"#/definitions/GitDirectoryReference/properties/ref/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[V]:i.push(V),e++}var P=y===e}else var P=!0;if(P)if(r.path!==void 0){const y=e;if(typeof r.path!="string"){const V={instancePath:t+"/path",schemaPath:"#/definitions/GitDirectoryReference/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[V]:i.push(V),e++}var P=y===e}else var P=!0}}}}}else{const L={instancePath:t,schemaPath:"#/definitions/GitDirectoryReference/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[L]:i.push(L),e++}var E=x===e;if(g=g||E,!g){const L=e;_e(r,{instancePath:t,parentData:p,parentDataProperty:c,rootData:h})||(i=i===null?_e.errors:i.concat(_e.errors),e=i.length);var E=L===e;g=g||E}if(g)e=d,i!==null&&(d?i.length=d:i=null);else{const L={instancePath:t,schemaPath:"#/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[L]:i.push(L),e++,ye.errors=i,!1}return ye.errors=i,e===0}const Qr={type:"string",enum:["GET","POST","HEAD","OPTIONS","PATCH","PUT","DELETE"]};function ue(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){let V;if(r.url===void 0&&(V="url"))return ue.errors=[{instancePath:t,schemaPath:"#/required",keyword:"required",params:{missingProperty:V},message:"must have required property '"+V+"'"}],!1;{const Q=e;for(const _ in r)if(!(_==="method"||_==="url"||_==="headers"||_==="body"))return ue.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:_},message:"must NOT have additional properties"}],!1;if(Q===e){if(r.method!==void 0){let _=r.method;const M=e;if(typeof _!="string")return ue.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(_==="GET"||_==="POST"||_==="HEAD"||_==="OPTIONS"||_==="PATCH"||_==="PUT"||_==="DELETE"))return ue.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/enum",keyword:"enum",params:{allowedValues:Qr.enum},message:"must be equal to one of the allowed values"}],!1;var d=M===e}else var d=!0;if(d){if(r.url!==void 0){const _=e;if(typeof r.url!="string")return ue.errors=[{instancePath:t+"/url",schemaPath:"#/properties/url/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=_===e}else var d=!0;if(d){if(r.headers!==void 0){let _=r.headers;const M=e;if(e===e)if(_&&typeof _=="object"&&!Array.isArray(_))for(const O in _){const z=e;if(typeof _[O]!="string")return ue.errors=[{instancePath:t+"/headers/"+O.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/definitions/PHPRequestHeaders/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=z===e;if(!g)break}else return ue.errors=[{instancePath:t+"/headers",schemaPath:"#/definitions/PHPRequestHeaders/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=M===e}else var d=!0;if(d)if(r.body!==void 0){let _=r.body;const M=e,j=e;let u=!1;const O=e;if(typeof _!="string"){const m={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[m]:i.push(m),e++}var x=O===e;if(u=u||x,!u){const m=e;if(e===m)if(_&&typeof _=="object"&&!Array.isArray(_)){let w;if(_.BYTES_PER_ELEMENT===void 0&&(w="BYTES_PER_ELEMENT")||_.buffer===void 0&&(w="buffer")||_.byteLength===void 0&&(w="byteLength")||_.byteOffset===void 0&&(w="byteOffset")||_.length===void 0&&(w="length")){const q={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/required",keyword:"required",params:{missingProperty:w},message:"must have required property '"+w+"'"};i===null?i=[q]:i.push(q),e++}else{const q=e;for(const b in _)if(!(b==="BYTES_PER_ELEMENT"||b==="buffer"||b==="byteLength"||b==="byteOffset"||b==="length")){let l=_[b];const D=e;if(!(typeof l=="number"&&isFinite(l))){const A={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[A]:i.push(A),e++}var T=D===e;if(!T)break}if(q===e){if(_.BYTES_PER_ELEMENT!==void 0){let b=_.BYTES_PER_ELEMENT;const l=e;if(!(typeof b=="number"&&isFinite(b))){const D={instancePath:t+"/body/BYTES_PER_ELEMENT",schemaPath:"#/properties/body/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[D]:i.push(D),e++}var P=l===e}else var P=!0;if(P){if(_.buffer!==void 0){let b=_.buffer;const l=e;if(e===l)if(b&&typeof b=="object"&&!Array.isArray(b)){let A;if(b.byteLength===void 0&&(A="byteLength")){const R={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:A},message:"must have required property '"+A+"'"};i===null?i=[R]:i.push(R),e++}else{const R=e;for(const U in b)if(U!=="byteLength"){const F={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:U},message:"must NOT have additional properties"};i===null?i=[F]:i.push(F),e++;break}if(R===e&&b.byteLength!==void 0){let U=b.byteLength;if(!(typeof U=="number"&&isFinite(U))){const F={instancePath:t+"/body/buffer/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[F]:i.push(F),e++}}}}else{const A={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[A]:i.push(A),e++}var P=l===e}else var P=!0;if(P){if(_.byteLength!==void 0){let b=_.byteLength;const l=e;if(!(typeof b=="number"&&isFinite(b))){const A={instancePath:t+"/body/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[A]:i.push(A),e++}var P=l===e}else var P=!0;if(P){if(_.byteOffset!==void 0){let b=_.byteOffset;const l=e;if(!(typeof b=="number"&&isFinite(b))){const A={instancePath:t+"/body/byteOffset",schemaPath:"#/properties/body/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[A]:i.push(A),e++}var P=l===e}else var P=!0;if(P)if(_.length!==void 0){let b=_.length;const l=e;if(!(typeof b=="number"&&isFinite(b))){const A={instancePath:t+"/body/length",schemaPath:"#/properties/body/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[A]:i.push(A),e++}var P=l===e}else var P=!0}}}}}}else{const w={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[w]:i.push(w),e++}var x=m===e;if(u=u||x,!u){const w=e;if(e===w)if(_&&typeof _=="object"&&!Array.isArray(_))for(const b in _){let l=_[b];const D=e,A=e;let R=!1;const U=e;if(typeof l!="string"){const F={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[F]:i.push(F),e++}var E=U===e;if(R=R||E,!R){const F=e;if(e===F)if(l&&typeof l=="object"&&!Array.isArray(l)){let se;if(l.BYTES_PER_ELEMENT===void 0&&(se="BYTES_PER_ELEMENT")||l.buffer===void 0&&(se="buffer")||l.byteLength===void 0&&(se="byteLength")||l.byteOffset===void 0&&(se="byteOffset")||l.length===void 0&&(se="length")){const Y={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/required",keyword:"required",params:{missingProperty:se},message:"must have required property '"+se+"'"};i===null?i=[Y]:i.push(Y),e++}else{const Y=e;for(const C in l)if(!(C==="BYTES_PER_ELEMENT"||C==="buffer"||C==="byteLength"||C==="byteOffset"||C==="length")){let H=l[C];const X=e;if(!(typeof H=="number"&&isFinite(H))){const Z={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/"+C.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var L=X===e;if(!L)break}if(Y===e){if(l.BYTES_PER_ELEMENT!==void 0){let C=l.BYTES_PER_ELEMENT;const H=e;if(!(typeof C=="number"&&isFinite(C))){const X={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/BYTES_PER_ELEMENT",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[X]:i.push(X),e++}var N=H===e}else var N=!0;if(N){if(l.buffer!==void 0){let C=l.buffer;const H=e;if(e===H)if(C&&typeof C=="object"&&!Array.isArray(C)){let Z;if(C.byteLength===void 0&&(Z="byteLength")){const oe={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:Z},message:"must have required property '"+Z+"'"};i===null?i=[oe]:i.push(oe),e++}else{const oe=e;for(const pe in C)if(pe!=="byteLength"){const he={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:pe},message:"must NOT have additional properties"};i===null?i=[he]:i.push(he),e++;break}if(oe===e&&C.byteLength!==void 0){let pe=C.byteLength;if(!(typeof pe=="number"&&isFinite(pe))){const he={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer/byteLength",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[he]:i.push(he),e++}}}}else{const Z={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/buffer",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[Z]:i.push(Z),e++}var N=H===e}else var N=!0;if(N){if(l.byteLength!==void 0){let C=l.byteLength;const H=e;if(!(typeof C=="number"&&isFinite(C))){const Z={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/byteLength",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var N=H===e}else var N=!0;if(N){if(l.byteOffset!==void 0){let C=l.byteOffset;const H=e;if(!(typeof C=="number"&&isFinite(C))){const Z={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/byteOffset",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var N=H===e}else var N=!0;if(N)if(l.length!==void 0){let C=l.length;const H=e;if(!(typeof C=="number"&&isFinite(C))){const Z={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/length",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Z]:i.push(Z),e++}var N=H===e}else var N=!0}}}}}}else{const se={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[se]:i.push(se),e++}var E=F===e;if(R=R||E,!R){const se=e;if(e===se)if(l&&typeof l=="object"&&!Array.isArray(l)){let C;if(l.lastModified===void 0&&(C="lastModified")||l.name===void 0&&(C="name")||l.size===void 0&&(C="size")||l.type===void 0&&(C="type")||l.webkitRelativePath===void 0&&(C="webkitRelativePath")){const H={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/required",keyword:"required",params:{missingProperty:C},message:"must have required property '"+C+"'"};i===null?i=[H]:i.push(H),e++}else{const H=e;for(const X in l)if(!(X==="size"||X==="type"||X==="lastModified"||X==="name"||X==="webkitRelativePath")){const Z={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:X},message:"must NOT have additional properties"};i===null?i=[Z]:i.push(Z),e++;break}if(H===e){if(l.size!==void 0){let X=l.size;const Z=e;if(!(typeof X=="number"&&isFinite(X))){const oe={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/size",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/size/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[oe]:i.push(oe),e++}var y=Z===e}else var y=!0;if(y){if(l.type!==void 0){const X=e;if(typeof l.type!="string"){const oe={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/type",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/type/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[oe]:i.push(oe),e++}var y=X===e}else var y=!0;if(y){if(l.lastModified!==void 0){let X=l.lastModified;const Z=e;if(!(typeof X=="number"&&isFinite(X))){const pe={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/lastModified",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/lastModified/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[pe]:i.push(pe),e++}var y=Z===e}else var y=!0;if(y){if(l.name!==void 0){const X=e;if(typeof l.name!="string"){const oe={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/name",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/name/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[oe]:i.push(oe),e++}var y=X===e}else var y=!0;if(y)if(l.webkitRelativePath!==void 0){const X=e;if(typeof l.webkitRelativePath!="string"){const oe={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1")+"/webkitRelativePath",schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/properties/webkitRelativePath/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[oe]:i.push(oe),e++}var y=X===e}else var y=!0}}}}}}else{const C={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[C]:i.push(C),e++}var E=se===e;R=R||E}}if(R)e=A,i!==null&&(A?i.length=A:i=null);else{const F={instancePath:t+"/body/"+b.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/2/additionalProperties/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};i===null?i=[F]:i.push(F),e++}var I=D===e;if(!I)break}else{const b={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[b]:i.push(b),e++}var x=w===e;u=u||x}}if(u)e=j,i!==null&&(j?i.length=j:i=null);else{const m={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[m]:i.push(m),e++,ue.errors=i,!1}var d=M===e}else var d=!0}}}}}else return ue.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return ue.errors=i,e===0}const Pt={type:"object",properties:{relativeUri:{type:"string",description:"Request path following the domain:port part."},scriptPath:{type:"string",description:"Path of the .php file to execute."},protocol:{type:"string",description:"Request protocol."},method:{$ref:"#/definitions/HTTPMethod",description:"Request method. Default: `GET`."},headers:{$ref:"#/definitions/PHPRequestHeaders",description:"Request headers."},body:{anyOf:[{type:"string"},{type:"object",properties:{BYTES_PER_ELEMENT:{type:"number"},buffer:{type:"object",properties:{byteLength:{type:"number"}},required:["byteLength"],additionalProperties:!1},byteLength:{type:"number"},byteOffset:{type:"number"},length:{type:"number"}},required:["BYTES_PER_ELEMENT","buffer","byteLength","byteOffset","length"],additionalProperties:{type:"number"}}],description:"Request body."},env:{type:"object",additionalProperties:{type:"string"},description:"Environment variables to set for this run."},$_SERVER:{type:"object",additionalProperties:{type:"string"},description:"$_SERVER entries to set for this run."},code:{type:"string",description:"The code snippet to eval instead of a php file."}},additionalProperties:!1};function ne(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){const N=e;for(const y in r)if(!Zr.call(Pt.properties,y))return ne.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:y},message:"must NOT have additional properties"}],!1;if(N===e){if(r.relativeUri!==void 0){const y=e;if(typeof r.relativeUri!="string")return ne.errors=[{instancePath:t+"/relativeUri",schemaPath:"#/properties/relativeUri/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=y===e}else var d=!0;if(d){if(r.scriptPath!==void 0){const y=e;if(typeof r.scriptPath!="string")return ne.errors=[{instancePath:t+"/scriptPath",schemaPath:"#/properties/scriptPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=y===e}else var d=!0;if(d){if(r.protocol!==void 0){const y=e;if(typeof r.protocol!="string")return ne.errors=[{instancePath:t+"/protocol",schemaPath:"#/properties/protocol/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=y===e}else var d=!0;if(d){if(r.method!==void 0){let y=r.method;const I=e;if(typeof y!="string")return ne.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(y==="GET"||y==="POST"||y==="HEAD"||y==="OPTIONS"||y==="PATCH"||y==="PUT"||y==="DELETE"))return ne.errors=[{instancePath:t+"/method",schemaPath:"#/definitions/HTTPMethod/enum",keyword:"enum",params:{allowedValues:Qr.enum},message:"must be equal to one of the allowed values"}],!1;var d=I===e}else var d=!0;if(d){if(r.headers!==void 0){let y=r.headers;const I=e;if(e===e)if(y&&typeof y=="object"&&!Array.isArray(y))for(const _ in y){const M=e;if(typeof y[_]!="string")return ne.errors=[{instancePath:t+"/headers/"+_.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/definitions/PHPRequestHeaders/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=M===e;if(!g)break}else return ne.errors=[{instancePath:t+"/headers",schemaPath:"#/definitions/PHPRequestHeaders/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=I===e}else var d=!0;if(d){if(r.body!==void 0){let y=r.body;const I=e,V=e;let Q=!1;const _=e;if(typeof y!="string"){const j={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[j]:i.push(j),e++}var x=_===e;if(Q=Q||x,!Q){const j=e;if(e===j)if(y&&typeof y=="object"&&!Array.isArray(y)){let O;if(y.BYTES_PER_ELEMENT===void 0&&(O="BYTES_PER_ELEMENT")||y.buffer===void 0&&(O="buffer")||y.byteLength===void 0&&(O="byteLength")||y.byteOffset===void 0&&(O="byteOffset")||y.length===void 0&&(O="length")){const z={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/required",keyword:"required",params:{missingProperty:O},message:"must have required property '"+O+"'"};i===null?i=[z]:i.push(z),e++}else{const z=e;for(const m in y)if(!(m==="BYTES_PER_ELEMENT"||m==="buffer"||m==="byteLength"||m==="byteOffset"||m==="length")){let v=y[m];const w=e;if(!(typeof v=="number"&&isFinite(v))){const q={instancePath:t+"/body/"+m.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/body/anyOf/1/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[q]:i.push(q),e++}var T=w===e;if(!T)break}if(z===e){if(y.BYTES_PER_ELEMENT!==void 0){let m=y.BYTES_PER_ELEMENT;const v=e;if(!(typeof m=="number"&&isFinite(m))){const w={instancePath:t+"/body/BYTES_PER_ELEMENT",schemaPath:"#/properties/body/anyOf/1/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[w]:i.push(w),e++}var P=v===e}else var P=!0;if(P){if(y.buffer!==void 0){let m=y.buffer;const v=e;if(e===v)if(m&&typeof m=="object"&&!Array.isArray(m)){let q;if(m.byteLength===void 0&&(q="byteLength")){const b={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/required",keyword:"required",params:{missingProperty:q},message:"must have required property '"+q+"'"};i===null?i=[b]:i.push(b),e++}else{const b=e;for(const l in m)if(l!=="byteLength"){const D={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:l},message:"must NOT have additional properties"};i===null?i=[D]:i.push(D),e++;break}if(b===e&&m.byteLength!==void 0){let l=m.byteLength;if(!(typeof l=="number"&&isFinite(l))){const D={instancePath:t+"/body/buffer/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[D]:i.push(D),e++}}}}else{const q={instancePath:t+"/body/buffer",schemaPath:"#/properties/body/anyOf/1/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[q]:i.push(q),e++}var P=v===e}else var P=!0;if(P){if(y.byteLength!==void 0){let m=y.byteLength;const v=e;if(!(typeof m=="number"&&isFinite(m))){const q={instancePath:t+"/body/byteLength",schemaPath:"#/properties/body/anyOf/1/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[q]:i.push(q),e++}var P=v===e}else var P=!0;if(P){if(y.byteOffset!==void 0){let m=y.byteOffset;const v=e;if(!(typeof m=="number"&&isFinite(m))){const q={instancePath:t+"/body/byteOffset",schemaPath:"#/properties/body/anyOf/1/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[q]:i.push(q),e++}var P=v===e}else var P=!0;if(P)if(y.length!==void 0){let m=y.length;const v=e;if(!(typeof m=="number"&&isFinite(m))){const q={instancePath:t+"/body/length",schemaPath:"#/properties/body/anyOf/1/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[q]:i.push(q),e++}var P=v===e}else var P=!0}}}}}}else{const O={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[O]:i.push(O),e++}var x=j===e;Q=Q||x}if(Q)e=V,i!==null&&(V?i.length=V:i=null);else{const j={instancePath:t+"/body",schemaPath:"#/properties/body/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[j]:i.push(j),e++,ne.errors=i,!1}var d=I===e}else var d=!0;if(d){if(r.env!==void 0){let y=r.env;const I=e;if(e===I)if(y&&typeof y=="object"&&!Array.isArray(y))for(const Q in y){const _=e;if(typeof y[Q]!="string")return ne.errors=[{instancePath:t+"/env/"+Q.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/env/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var E=_===e;if(!E)break}else return ne.errors=[{instancePath:t+"/env",schemaPath:"#/properties/env/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=I===e}else var d=!0;if(d){if(r.$_SERVER!==void 0){let y=r.$_SERVER;const I=e;if(e===I)if(y&&typeof y=="object"&&!Array.isArray(y))for(const Q in y){const _=e;if(typeof y[Q]!="string")return ne.errors=[{instancePath:t+"/$_SERVER/"+Q.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/%24_SERVER/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var L=_===e;if(!L)break}else return ne.errors=[{instancePath:t+"/$_SERVER",schemaPath:"#/properties/%24_SERVER/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=I===e}else var d=!0;if(d)if(r.code!==void 0){const y=e;if(typeof r.code!="string")return ne.errors=[{instancePath:t+"/code",schemaPath:"#/properties/code/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=y===e}else var d=!0}}}}}}}}}else return ne.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return ne.errors=i,e===0}function o(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){let sr;if(r.step===void 0&&(sr="step"))return o.errors=[{instancePath:t,schemaPath:"#/required",keyword:"required",params:{missingProperty:sr},message:"must have required property '"+sr+"'"}],!1;{const J=r.step;if(typeof J=="string")if(J==="activatePlugin"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.pluginPath===void 0&&(f="pluginPath")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/0/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="pluginPath"||s==="pluginName"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/0/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/0/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/0/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var d=$===e}else var d=!0;if(d)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/0/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=n===e}else var d=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/0/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var g=a===e}else var g=!0;if(g){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/0/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="activatePlugin")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/0/properties/step/const",keyword:"const",params:{allowedValue:"activatePlugin"},message:"must be equal to constant"}],!1;var g=a===e}else var g=!0;if(g){if(r.pluginPath!==void 0){const s=e;if(typeof r.pluginPath!="string")return o.errors=[{instancePath:t+"/pluginPath",schemaPath:"#/oneOf/0/properties/pluginPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=s===e}else var g=!0;if(g)if(r.pluginName!==void 0){const s=e;if(typeof r.pluginName!="string")return o.errors=[{instancePath:t+"/pluginName",schemaPath:"#/oneOf/0/properties/pluginName/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=s===e}else var g=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/0/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="activateTheme"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step")||r.themeFolderName===void 0&&(f="themeFolderName"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/1/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="themeFolderName"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/1/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/1/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/1/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var x=$===e}else var x=!0;if(x)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/1/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var x=n===e}else var x=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/1/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var T=a===e}else var T=!0;if(T){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/1/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="activateTheme")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/1/properties/step/const",keyword:"const",params:{allowedValue:"activateTheme"},message:"must be equal to constant"}],!1;var T=a===e}else var T=!0;if(T)if(r.themeFolderName!==void 0){const s=e;if(typeof r.themeFolderName!="string")return o.errors=[{instancePath:t+"/themeFolderName",schemaPath:"#/oneOf/1/properties/themeFolderName/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var T=s===e}else var T=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="cp"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.fromPath===void 0&&(f="fromPath")||r.step===void 0&&(f="step")||r.toPath===void 0&&(f="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/2/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="fromPath"||s==="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/2/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/2/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/2/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var P=$===e}else var P=!0;if(P)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/2/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var P=n===e}else var P=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/2/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var E=a===e}else var E=!0;if(E){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/2/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="cp")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/2/properties/step/const",keyword:"const",params:{allowedValue:"cp"},message:"must be equal to constant"}],!1;var E=a===e}else var E=!0;if(E){if(r.fromPath!==void 0){const s=e;if(typeof r.fromPath!="string")return o.errors=[{instancePath:t+"/fromPath",schemaPath:"#/oneOf/2/properties/fromPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var E=s===e}else var E=!0;if(E)if(r.toPath!==void 0){const s=e;if(typeof r.toPath!="string")return o.errors=[{instancePath:t+"/toPath",schemaPath:"#/oneOf/2/properties/toPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var E=s===e}else var E=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="defineWpConfigConsts"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.consts===void 0&&(f="consts")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/3/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="consts"||s==="method"||s==="virtualize"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/3/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/3/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/3/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var L=$===e}else var L=!0;if(L)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/3/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var L=n===e}else var L=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/3/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var N=a===e}else var N=!0;if(N){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/3/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="defineWpConfigConsts")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/3/properties/step/const",keyword:"const",params:{allowedValue:"defineWpConfigConsts"},message:"must be equal to constant"}],!1;var N=a===e}else var N=!0;if(N){if(r.consts!==void 0){let s=r.consts;const a=e;if(e===a&&!(s&&typeof s=="object"&&!Array.isArray(s)))return o.errors=[{instancePath:t+"/consts",schemaPath:"#/oneOf/3/properties/consts/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var N=a===e}else var N=!0;if(N){if(r.method!==void 0){let s=r.method;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/method",schemaPath:"#/oneOf/3/properties/method/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(s==="rewrite-wp-config"||s==="define-before-run"))return o.errors=[{instancePath:t+"/method",schemaPath:"#/oneOf/3/properties/method/enum",keyword:"enum",params:{allowedValues:or.oneOf[3].properties.method.enum},message:"must be equal to one of the allowed values"}],!1;var N=a===e}else var N=!0;if(N)if(r.virtualize!==void 0){const s=e;if(typeof r.virtualize!="boolean")return o.errors=[{instancePath:t+"/virtualize",schemaPath:"#/oneOf/3/properties/virtualize/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var N=s===e}else var N=!0}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/3/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="defineSiteUrl"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.siteUrl===void 0&&(f="siteUrl")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/4/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="siteUrl"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/4/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/4/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/4/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var y=$===e}else var y=!0;if(y)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/4/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var y=n===e}else var y=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/4/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var I=a===e}else var I=!0;if(I){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/4/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="defineSiteUrl")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/4/properties/step/const",keyword:"const",params:{allowedValue:"defineSiteUrl"},message:"must be equal to constant"}],!1;var I=a===e}else var I=!0;if(I)if(r.siteUrl!==void 0){const s=e;if(typeof r.siteUrl!="string")return o.errors=[{instancePath:t+"/siteUrl",schemaPath:"#/oneOf/4/properties/siteUrl/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var I=s===e}else var I=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/4/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="enableMultisite"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/5/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="wpCliPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/5/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/5/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/5/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var V=$===e}else var V=!0;if(V)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/5/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var V=n===e}else var V=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/5/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Q=a===e}else var Q=!0;if(Q){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/5/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="enableMultisite")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/5/properties/step/const",keyword:"const",params:{allowedValue:"enableMultisite"},message:"must be equal to constant"}],!1;var Q=a===e}else var Q=!0;if(Q)if(r.wpCliPath!==void 0){const s=e;if(typeof r.wpCliPath!="string")return o.errors=[{instancePath:t+"/wpCliPath",schemaPath:"#/oneOf/5/properties/wpCliPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Q=s===e}else var Q=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/5/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="importWxr"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.file===void 0&&(f="file")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/6/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="file"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/6/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/6/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/6/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var _=$===e}else var _=!0;if(_)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/6/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var _=n===e}else var _=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/6/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var M=a===e}else var M=!0;if(M){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/6/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="importWxr")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/6/properties/step/const",keyword:"const",params:{allowedValue:"importWxr"},message:"must be equal to constant"}],!1;var M=a===e}else var M=!0;if(M)if(r.file!==void 0){const s=e;K(r.file,{instancePath:t+"/file",parentData:r,parentDataProperty:"file",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var M=s===e}else var M=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/6/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="importThemeStarterContent"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/7/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="themeSlug"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/7/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/7/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/7/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var j=$===e}else var j=!0;if(j)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/7/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var j=n===e}else var j=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/7/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var u=a===e}else var u=!0;if(u){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/7/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="importThemeStarterContent")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/7/properties/step/const",keyword:"const",params:{allowedValue:"importThemeStarterContent"},message:"must be equal to constant"}],!1;var u=a===e}else var u=!0;if(u)if(r.themeSlug!==void 0){const s=e;if(typeof r.themeSlug!="string")return o.errors=[{instancePath:t+"/themeSlug",schemaPath:"#/oneOf/7/properties/themeSlug/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var u=s===e}else var u=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/7/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="importWordPressFiles"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step")||r.wordPressFilesZip===void 0&&(f="wordPressFilesZip"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/8/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="wordPressFilesZip"||s==="pathInZip"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/8/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/8/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/8/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var O=$===e}else var O=!0;if(O)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/8/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var O=n===e}else var O=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/8/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var z=a===e}else var z=!0;if(z){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/8/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="importWordPressFiles")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/8/properties/step/const",keyword:"const",params:{allowedValue:"importWordPressFiles"},message:"must be equal to constant"}],!1;var z=a===e}else var z=!0;if(z){if(r.wordPressFilesZip!==void 0){const s=e;K(r.wordPressFilesZip,{instancePath:t+"/wordPressFilesZip",parentData:r,parentDataProperty:"wordPressFilesZip",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var z=s===e}else var z=!0;if(z)if(r.pathInZip!==void 0){const s=e;if(typeof r.pathInZip!="string")return o.errors=[{instancePath:t+"/pathInZip",schemaPath:"#/oneOf/8/properties/pathInZip/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var z=s===e}else var z=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/8/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="installPlugin"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.pluginData===void 0&&(f="pluginData")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/9/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="ifAlreadyInstalled"||s==="step"||s==="pluginData"||s==="pluginZipFile"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/9/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/9/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/9/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var m=$===e}else var m=!0;if(m)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/9/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var m=n===e}else var m=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/9/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var v=a===e}else var v=!0;if(v){if(r.ifAlreadyInstalled!==void 0){let s=r.ifAlreadyInstalled;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/9/properties/ifAlreadyInstalled/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(s==="overwrite"||s==="skip"||s==="error"))return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/9/properties/ifAlreadyInstalled/enum",keyword:"enum",params:{allowedValues:or.oneOf[9].properties.ifAlreadyInstalled.enum},message:"must be equal to one of the allowed values"}],!1;var v=a===e}else var v=!0;if(v){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/9/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="installPlugin")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/9/properties/step/const",keyword:"const",params:{allowedValue:"installPlugin"},message:"must be equal to constant"}],!1;var v=a===e}else var v=!0;if(v){if(r.pluginData!==void 0){let s=r.pluginData;const a=e,k=e;let n=!1;const $=e;K(s,{instancePath:t+"/pluginData",parentData:r,parentDataProperty:"pluginData",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var w=$===e;if(n=n||w,!n){const ie=e;ye(s,{instancePath:t+"/pluginData",parentData:r,parentDataProperty:"pluginData",rootData:h})||(i=i===null?ye.errors:i.concat(ye.errors),e=i.length);var w=ie===e;n=n||w}if(n)e=k,i!==null&&(k?i.length=k:i=null);else{const ie={instancePath:t+"/pluginData",schemaPath:"#/oneOf/9/properties/pluginData/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[ie]:i.push(ie),e++,o.errors=i,!1}var v=a===e}else var v=!0;if(v){if(r.pluginZipFile!==void 0){const s=e;K(r.pluginZipFile,{instancePath:t+"/pluginZipFile",parentData:r,parentDataProperty:"pluginZipFile",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var v=s===e}else var v=!0;if(v)if(r.options!==void 0){let s=r.options;const a=e;if(e===e)if(s&&typeof s=="object"&&!Array.isArray(s)){const $=e;for(const te in s)if(!(te==="activate"||te==="targetFolderName"))return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/InstallPluginOptions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:te},message:"must NOT have additional properties"}],!1;if($===e){if(s.activate!==void 0){const te=e;if(typeof s.activate!="boolean")return o.errors=[{instancePath:t+"/options/activate",schemaPath:"#/definitions/InstallPluginOptions/properties/activate/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var q=te===e}else var q=!0;if(q)if(s.targetFolderName!==void 0){const te=e;if(typeof s.targetFolderName!="string")return o.errors=[{instancePath:t+"/options/targetFolderName",schemaPath:"#/definitions/InstallPluginOptions/properties/targetFolderName/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var q=te===e}else var q=!0}}else return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/InstallPluginOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var v=a===e}else var v=!0}}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/9/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="installTheme"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step")||r.themeData===void 0&&(f="themeData"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/10/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="ifAlreadyInstalled"||s==="step"||s==="themeData"||s==="themeZipFile"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/10/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/10/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/10/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var b=$===e}else var b=!0;if(b)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/10/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var b=n===e}else var b=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/10/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var l=a===e}else var l=!0;if(l){if(r.ifAlreadyInstalled!==void 0){let s=r.ifAlreadyInstalled;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/10/properties/ifAlreadyInstalled/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(!(s==="overwrite"||s==="skip"||s==="error"))return o.errors=[{instancePath:t+"/ifAlreadyInstalled",schemaPath:"#/oneOf/10/properties/ifAlreadyInstalled/enum",keyword:"enum",params:{allowedValues:or.oneOf[10].properties.ifAlreadyInstalled.enum},message:"must be equal to one of the allowed values"}],!1;var l=a===e}else var l=!0;if(l){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/10/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="installTheme")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/10/properties/step/const",keyword:"const",params:{allowedValue:"installTheme"},message:"must be equal to constant"}],!1;var l=a===e}else var l=!0;if(l){if(r.themeData!==void 0){let s=r.themeData;const a=e,k=e;let n=!1;const $=e;K(s,{instancePath:t+"/themeData",parentData:r,parentDataProperty:"themeData",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var D=$===e;if(n=n||D,!n){const ie=e;ye(s,{instancePath:t+"/themeData",parentData:r,parentDataProperty:"themeData",rootData:h})||(i=i===null?ye.errors:i.concat(ye.errors),e=i.length);var D=ie===e;n=n||D}if(n)e=k,i!==null&&(k?i.length=k:i=null);else{const ie={instancePath:t+"/themeData",schemaPath:"#/oneOf/10/properties/themeData/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[ie]:i.push(ie),e++,o.errors=i,!1}var l=a===e}else var l=!0;if(l){if(r.themeZipFile!==void 0){const s=e;K(r.themeZipFile,{instancePath:t+"/themeZipFile",parentData:r,parentDataProperty:"themeZipFile",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var l=s===e}else var l=!0;if(l)if(r.options!==void 0){let s=r.options;const a=e;if(e===e)if(s&&typeof s=="object"&&!Array.isArray(s)){const $=e;for(const te in s)if(!(te==="activate"||te==="importStarterContent"||te==="targetFolderName"))return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/InstallThemeOptions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:te},message:"must NOT have additional properties"}],!1;if($===e){if(s.activate!==void 0){const te=e;if(typeof s.activate!="boolean")return o.errors=[{instancePath:t+"/options/activate",schemaPath:"#/definitions/InstallThemeOptions/properties/activate/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var A=te===e}else var A=!0;if(A){if(s.importStarterContent!==void 0){const te=e;if(typeof s.importStarterContent!="boolean")return o.errors=[{instancePath:t+"/options/importStarterContent",schemaPath:"#/definitions/InstallThemeOptions/properties/importStarterContent/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1;var A=te===e}else var A=!0;if(A)if(s.targetFolderName!==void 0){const te=e;if(typeof s.targetFolderName!="string")return o.errors=[{instancePath:t+"/options/targetFolderName",schemaPath:"#/definitions/InstallThemeOptions/properties/targetFolderName/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var A=te===e}else var A=!0}}}else return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/InstallThemeOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var l=a===e}else var l=!0}}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/10/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="login"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/11/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="username"||s==="password"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/11/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/11/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/11/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var R=$===e}else var R=!0;if(R)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/11/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var R=n===e}else var R=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/11/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var U=a===e}else var U=!0;if(U){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/11/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="login")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/11/properties/step/const",keyword:"const",params:{allowedValue:"login"},message:"must be equal to constant"}],!1;var U=a===e}else var U=!0;if(U){if(r.username!==void 0){const s=e;if(typeof r.username!="string")return o.errors=[{instancePath:t+"/username",schemaPath:"#/oneOf/11/properties/username/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var U=s===e}else var U=!0;if(U)if(r.password!==void 0){const s=e;if(typeof r.password!="string")return o.errors=[{instancePath:t+"/password",schemaPath:"#/oneOf/11/properties/password/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var U=s===e}else var U=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/11/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="mkdir"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.path===void 0&&(f="path")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/12/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/12/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/12/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/12/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var F=$===e}else var F=!0;if(F)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/12/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var F=n===e}else var F=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/12/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var G=a===e}else var G=!0;if(G){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/12/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="mkdir")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/12/properties/step/const",keyword:"const",params:{allowedValue:"mkdir"},message:"must be equal to constant"}],!1;var G=a===e}else var G=!0;if(G)if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/12/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var G=s===e}else var G=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/12/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="mv"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.fromPath===void 0&&(f="fromPath")||r.step===void 0&&(f="step")||r.toPath===void 0&&(f="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/13/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="fromPath"||s==="toPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/13/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/13/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/13/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var se=$===e}else var se=!0;if(se)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/13/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var se=n===e}else var se=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/13/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Y=a===e}else var Y=!0;if(Y){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/13/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="mv")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/13/properties/step/const",keyword:"const",params:{allowedValue:"mv"},message:"must be equal to constant"}],!1;var Y=a===e}else var Y=!0;if(Y){if(r.fromPath!==void 0){const s=e;if(typeof r.fromPath!="string")return o.errors=[{instancePath:t+"/fromPath",schemaPath:"#/oneOf/13/properties/fromPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Y=s===e}else var Y=!0;if(Y)if(r.toPath!==void 0){const s=e;if(typeof r.toPath!="string")return o.errors=[{instancePath:t+"/toPath",schemaPath:"#/oneOf/13/properties/toPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Y=s===e}else var Y=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/13/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="resetData"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/14/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/14/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/14/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/14/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var C=$===e}else var C=!0;if(C)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/14/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var C=n===e}else var C=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/14/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var H=a===e}else var H=!0;if(H)if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/14/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="resetData")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/14/properties/step/const",keyword:"const",params:{allowedValue:"resetData"},message:"must be equal to constant"}],!1;var H=a===e}else var H=!0}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/14/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="request"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.request===void 0&&(f="request")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/15/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="request"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/15/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/15/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/15/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var X=$===e}else var X=!0;if(X)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/15/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var X=n===e}else var X=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/15/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Z=a===e}else var Z=!0;if(Z){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/15/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="request")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/15/properties/step/const",keyword:"const",params:{allowedValue:"request"},message:"must be equal to constant"}],!1;var Z=a===e}else var Z=!0;if(Z)if(r.request!==void 0){const s=e;ue(r.request,{instancePath:t+"/request",parentData:r,parentDataProperty:"request",rootData:h})||(i=i===null?ue.errors:i.concat(ue.errors),e=i.length);var Z=s===e}else var Z=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/15/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="rm"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.path===void 0&&(f="path")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/16/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/16/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/16/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/16/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var oe=$===e}else var oe=!0;if(oe)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/16/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var oe=n===e}else var oe=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/16/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var pe=a===e}else var pe=!0;if(pe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/16/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="rm")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/16/properties/step/const",keyword:"const",params:{allowedValue:"rm"},message:"must be equal to constant"}],!1;var pe=a===e}else var pe=!0;if(pe)if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/16/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var pe=s===e}else var pe=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/16/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="rmdir"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.path===void 0&&(f="path")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/17/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/17/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/17/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/17/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var he=$===e}else var he=!0;if(he)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/17/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var he=n===e}else var he=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/17/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Oe=a===e}else var Oe=!0;if(Oe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/17/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="rmdir")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/17/properties/step/const",keyword:"const",params:{allowedValue:"rmdir"},message:"must be equal to constant"}],!1;var Oe=a===e}else var Oe=!0;if(Oe)if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/17/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Oe=s===e}else var Oe=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/17/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="runPHP"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.code===void 0&&(f="code")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/18/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="code"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/18/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/18/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/18/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var De=$===e}else var De=!0;if(De)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/18/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var De=n===e}else var De=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/18/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var $e=a===e}else var $e=!0;if($e){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/18/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runPHP")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/18/properties/step/const",keyword:"const",params:{allowedValue:"runPHP"},message:"must be equal to constant"}],!1;var $e=a===e}else var $e=!0;if($e)if(r.code!==void 0){const s=e;if(typeof r.code!="string")return o.errors=[{instancePath:t+"/code",schemaPath:"#/oneOf/18/properties/code/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var $e=s===e}else var $e=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/18/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="runPHPWithOptions"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.options===void 0&&(f="options")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/19/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/19/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/19/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/19/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var xe=$===e}else var xe=!0;if(xe)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/19/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var xe=n===e}else var xe=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/19/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Ee=a===e}else var Ee=!0;if(Ee){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/19/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runPHPWithOptions")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/19/properties/step/const",keyword:"const",params:{allowedValue:"runPHPWithOptions"},message:"must be equal to constant"}],!1;var Ee=a===e}else var Ee=!0;if(Ee)if(r.options!==void 0){const s=e;ne(r.options,{instancePath:t+"/options",parentData:r,parentDataProperty:"options",rootData:h})||(i=i===null?ne.errors:i.concat(ne.errors),e=i.length);var Ee=s===e}else var Ee=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/19/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="runWpInstallationWizard"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.options===void 0&&(f="options")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/20/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/20/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/20/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/20/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ce=$===e}else var Ce=!0;if(Ce)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/20/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ce=n===e}else var Ce=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/20/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var je=a===e}else var je=!0;if(je){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/20/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runWpInstallationWizard")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/20/properties/step/const",keyword:"const",params:{allowedValue:"runWpInstallationWizard"},message:"must be equal to constant"}],!1;var je=a===e}else var je=!0;if(je)if(r.options!==void 0){let s=r.options;const a=e;if(e===e)if(s&&typeof s=="object"&&!Array.isArray(s)){const $=e;for(const te in s)if(!(te==="adminUsername"||te==="adminPassword"))return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/WordPressInstallationOptions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:te},message:"must NOT have additional properties"}],!1;if($===e){if(s.adminUsername!==void 0){const te=e;if(typeof s.adminUsername!="string")return o.errors=[{instancePath:t+"/options/adminUsername",schemaPath:"#/definitions/WordPressInstallationOptions/properties/adminUsername/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var We=te===e}else var We=!0;if(We)if(s.adminPassword!==void 0){const te=e;if(typeof s.adminPassword!="string")return o.errors=[{instancePath:t+"/options/adminPassword",schemaPath:"#/definitions/WordPressInstallationOptions/properties/adminPassword/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var We=te===e}else var We=!0}}else return o.errors=[{instancePath:t+"/options",schemaPath:"#/definitions/WordPressInstallationOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var je=a===e}else var je=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/20/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="runSql"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.sql===void 0&&(f="sql")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/21/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="sql"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/21/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/21/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/21/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ie=$===e}else var Ie=!0;if(Ie)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/21/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ie=n===e}else var Ie=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/21/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Te=a===e}else var Te=!0;if(Te){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/21/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="runSql")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/21/properties/step/const",keyword:"const",params:{allowedValue:"runSql"},message:"must be equal to constant"}],!1;var Te=a===e}else var Te=!0;if(Te)if(r.sql!==void 0){const s=e;K(r.sql,{instancePath:t+"/sql",parentData:r,parentDataProperty:"sql",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var Te=s===e}else var Te=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/21/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="setSiteOptions"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.options===void 0&&(f="options")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/22/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="options"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/22/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/22/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/22/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ue=$===e}else var Ue=!0;if(Ue)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/22/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ue=n===e}else var Ue=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/22/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var qe=a===e}else var qe=!0;if(qe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/22/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="setSiteOptions")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/22/properties/step/const",keyword:"const",params:{allowedValue:"setSiteOptions"},message:"must be equal to constant"}],!1;var qe=a===e}else var qe=!0;if(qe)if(r.options!==void 0){let s=r.options;const a=e;if(e===a&&!(s&&typeof s=="object"&&!Array.isArray(s)))return o.errors=[{instancePath:t+"/options",schemaPath:"#/oneOf/22/properties/options/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var qe=a===e}else var qe=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/22/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="unzip"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.extractToPath===void 0&&(f="extractToPath")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/23/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="zipFile"||s==="zipPath"||s==="extractToPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/23/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/23/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/23/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ve=$===e}else var Ve=!0;if(Ve)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/23/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ve=n===e}else var Ve=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/23/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var fe=a===e}else var fe=!0;if(fe){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/23/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="unzip")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/23/properties/step/const",keyword:"const",params:{allowedValue:"unzip"},message:"must be equal to constant"}],!1;var fe=a===e}else var fe=!0;if(fe){if(r.zipFile!==void 0){const s=e;K(r.zipFile,{instancePath:t+"/zipFile",parentData:r,parentDataProperty:"zipFile",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var fe=s===e}else var fe=!0;if(fe){if(r.zipPath!==void 0){const s=e;if(typeof r.zipPath!="string")return o.errors=[{instancePath:t+"/zipPath",schemaPath:"#/oneOf/23/properties/zipPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var fe=s===e}else var fe=!0;if(fe)if(r.extractToPath!==void 0){const s=e;if(typeof r.extractToPath!="string")return o.errors=[{instancePath:t+"/extractToPath",schemaPath:"#/oneOf/23/properties/extractToPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var fe=s===e}else var fe=!0}}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/23/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="updateUserMeta"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.meta===void 0&&(f="meta")||r.step===void 0&&(f="step")||r.userId===void 0&&(f="userId"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/24/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="meta"||s==="userId"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/24/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/24/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/24/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Me=$===e}else var Me=!0;if(Me)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/24/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Me=n===e}else var Me=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/24/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ge=a===e}else var ge=!0;if(ge){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/24/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="updateUserMeta")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/24/properties/step/const",keyword:"const",params:{allowedValue:"updateUserMeta"},message:"must be equal to constant"}],!1;var ge=a===e}else var ge=!0;if(ge){if(r.meta!==void 0){let s=r.meta;const a=e;if(e===a&&!(s&&typeof s=="object"&&!Array.isArray(s)))return o.errors=[{instancePath:t+"/meta",schemaPath:"#/oneOf/24/properties/meta/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ge=a===e}else var ge=!0;if(ge)if(r.userId!==void 0){let s=r.userId;const a=e;if(!(typeof s=="number"&&isFinite(s)))return o.errors=[{instancePath:t+"/userId",schemaPath:"#/oneOf/24/properties/userId/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var ge=a===e}else var ge=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/24/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="writeFile"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.data===void 0&&(f="data")||r.path===void 0&&(f="path")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/25/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="path"||s==="data"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/25/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/25/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/25/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var ze=$===e}else var ze=!0;if(ze)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/25/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var ze=n===e}else var ze=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/25/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var be=a===e}else var be=!0;if(be){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/25/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="writeFile")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/25/properties/step/const",keyword:"const",params:{allowedValue:"writeFile"},message:"must be equal to constant"}],!1;var be=a===e}else var be=!0;if(be){if(r.path!==void 0){const s=e;if(typeof r.path!="string")return o.errors=[{instancePath:t+"/path",schemaPath:"#/oneOf/25/properties/path/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var be=s===e}else var be=!0;if(be)if(r.data!==void 0){let s=r.data;const a=e,k=e;let n=!1;const $=e;K(s,{instancePath:t+"/data",parentData:r,parentDataProperty:"data",rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var Le=$===e;if(n=n||Le,!n){const ie=e;if(typeof s!="string"){const Pe={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf/1/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[Pe]:i.push(Pe),e++}var Le=ie===e;if(n=n||Le,!n){const Pe=e;if(e===Pe)if(s&&typeof s=="object"&&!Array.isArray(s)){let me;if(s.BYTES_PER_ELEMENT===void 0&&(me="BYTES_PER_ELEMENT")||s.buffer===void 0&&(me="buffer")||s.byteLength===void 0&&(me="byteLength")||s.byteOffset===void 0&&(me="byteOffset")||s.length===void 0&&(me="length")){const Ze={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf/2/required",keyword:"required",params:{missingProperty:me},message:"must have required property '"+me+"'"};i===null?i=[Ze]:i.push(Ze),e++}else{const Ze=e;for(const ee in s)if(!(ee==="BYTES_PER_ELEMENT"||ee==="buffer"||ee==="byteLength"||ee==="byteOffset"||ee==="length")){let de=s[ee];const Qe=e;if(!(typeof de=="number"&&isFinite(de))){const ae={instancePath:t+"/data/"+ee.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/oneOf/25/properties/data/anyOf/2/additionalProperties/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[ae]:i.push(ae),e++}var Xr=Qe===e;if(!Xr)break}if(Ze===e){if(s.BYTES_PER_ELEMENT!==void 0){let ee=s.BYTES_PER_ELEMENT;const de=e;if(!(typeof ee=="number"&&isFinite(ee))){const Qe={instancePath:t+"/data/BYTES_PER_ELEMENT",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/BYTES_PER_ELEMENT/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Qe]:i.push(Qe),e++}var le=de===e}else var le=!0;if(le){if(s.buffer!==void 0){let ee=s.buffer;const de=e;if(e===de)if(ee&&typeof ee=="object"&&!Array.isArray(ee)){let ae;if(ee.byteLength===void 0&&(ae="byteLength")){const Xe={instancePath:t+"/data/buffer",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/required",keyword:"required",params:{missingProperty:ae},message:"must have required property '"+ae+"'"};i===null?i=[Xe]:i.push(Xe),e++}else{const Xe=e;for(const Fe in ee)if(Fe!=="byteLength"){const Se={instancePath:t+"/data/buffer",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:Fe},message:"must NOT have additional properties"};i===null?i=[Se]:i.push(Se),e++;break}if(Xe===e&&ee.byteLength!==void 0){let Fe=ee.byteLength;if(!(typeof Fe=="number"&&isFinite(Fe))){const Se={instancePath:t+"/data/buffer/byteLength",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[Se]:i.push(Se),e++}}}}else{const ae={instancePath:t+"/data/buffer",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/buffer/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[ae]:i.push(ae),e++}var le=de===e}else var le=!0;if(le){if(s.byteLength!==void 0){let ee=s.byteLength;const de=e;if(!(typeof ee=="number"&&isFinite(ee))){const ae={instancePath:t+"/data/byteLength",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/byteLength/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[ae]:i.push(ae),e++}var le=de===e}else var le=!0;if(le){if(s.byteOffset!==void 0){let ee=s.byteOffset;const de=e;if(!(typeof ee=="number"&&isFinite(ee))){const ae={instancePath:t+"/data/byteOffset",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/byteOffset/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[ae]:i.push(ae),e++}var le=de===e}else var le=!0;if(le)if(s.length!==void 0){let ee=s.length;const de=e;if(!(typeof ee=="number"&&isFinite(ee))){const ae={instancePath:t+"/data/length",schemaPath:"#/oneOf/25/properties/data/anyOf/2/properties/length/type",keyword:"type",params:{type:"number"},message:"must be number"};i===null?i=[ae]:i.push(ae),e++}var le=de===e}else var le=!0}}}}}}else{const me={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf/2/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[me]:i.push(me),e++}var Le=Pe===e;n=n||Le}}if(n)e=k,i!==null&&(k?i.length=k:i=null);else{const ie={instancePath:t+"/data",schemaPath:"#/oneOf/25/properties/data/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[ie]:i.push(ie),e++,o.errors=i,!1}var be=a===e}else var be=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/25/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="writeFiles"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.filesTree===void 0&&(f="filesTree")||r.step===void 0&&(f="step")||r.writeToPath===void 0&&(f="writeToPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/26/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="writeToPath"||s==="filesTree"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/26/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/26/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/26/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Be=$===e}else var Be=!0;if(Be)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/26/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Be=n===e}else var Be=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/26/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var we=a===e}else var we=!0;if(we){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/26/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="writeFiles")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/26/properties/step/const",keyword:"const",params:{allowedValue:"writeFiles"},message:"must be equal to constant"}],!1;var we=a===e}else var we=!0;if(we){if(r.writeToPath!==void 0){const s=e;if(typeof r.writeToPath!="string")return o.errors=[{instancePath:t+"/writeToPath",schemaPath:"#/oneOf/26/properties/writeToPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var we=s===e}else var we=!0;if(we)if(r.filesTree!==void 0){const s=e;ye(r.filesTree,{instancePath:t+"/filesTree",parentData:r,parentDataProperty:"filesTree",rootData:h})||(i=i===null?ye.errors:i.concat(ye.errors),e=i.length);var we=s===e}else var we=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/26/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="wp-cli"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.command===void 0&&(f="command")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/27/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="command"||s==="wpCliPath"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/27/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/27/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/27/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var He=$===e}else var He=!0;if(He)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/27/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var He=n===e}else var He=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/27/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var ve=a===e}else var ve=!0;if(ve){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/27/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="wp-cli")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/27/properties/step/const",keyword:"const",params:{allowedValue:"wp-cli"},message:"must be equal to constant"}],!1;var ve=a===e}else var ve=!0;if(ve){if(r.command!==void 0){let s=r.command;const a=e,k=e;let n=!1;const $=e;if(typeof s!="string"){const ie={instancePath:t+"/command",schemaPath:"#/oneOf/27/properties/command/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[ie]:i.push(ie),e++}var tr=$===e;if(n=n||tr,!n){const ie=e;if(e===ie)if(Array.isArray(s)){var br=!0;const Pe=s.length;for(let Ye=0;Ye<Pe;Ye++){const me=e;if(typeof s[Ye]!="string"){const ee={instancePath:t+"/command/"+Ye,schemaPath:"#/oneOf/27/properties/command/anyOf/1/items/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[ee]:i.push(ee),e++}var br=me===e;if(!br)break}}else{const Pe={instancePath:t+"/command",schemaPath:"#/oneOf/27/properties/command/anyOf/1/type",keyword:"type",params:{type:"array"},message:"must be array"};i===null?i=[Pe]:i.push(Pe),e++}var tr=ie===e;n=n||tr}if(n)e=k,i!==null&&(k?i.length=k:i=null);else{const ie={instancePath:t+"/command",schemaPath:"#/oneOf/27/properties/command/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[ie]:i.push(ie),e++,o.errors=i,!1}var ve=a===e}else var ve=!0;if(ve)if(r.wpCliPath!==void 0){const s=e;if(typeof r.wpCliPath!="string")return o.errors=[{instancePath:t+"/wpCliPath",schemaPath:"#/oneOf/27/properties/wpCliPath/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var ve=s===e}else var ve=!0}}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/27/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else if(J==="setSiteLanguage"){if(e===e)if(r&&typeof r=="object"&&!Array.isArray(r)){let f;if(r.language===void 0&&(f="language")||r.step===void 0&&(f="step"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/28/required",keyword:"required",params:{missingProperty:f},message:"must have required property '"+f+"'"}],!1;{const S=e;for(const s in r)if(!(s==="progress"||s==="step"||s==="language"))return o.errors=[{instancePath:t,schemaPath:"#/oneOf/28/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:s},message:"must NOT have additional properties"}],!1;if(S===e){if(r.progress!==void 0){let s=r.progress;const a=e;if(e===a)if(s&&typeof s=="object"&&!Array.isArray(s)){const k=e;for(const n in s)if(!(n==="weight"||n==="caption"))return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/28/properties/progress/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:n},message:"must NOT have additional properties"}],!1;if(k===e){if(s.weight!==void 0){let n=s.weight;const $=e;if(!(typeof n=="number"&&isFinite(n)))return o.errors=[{instancePath:t+"/progress/weight",schemaPath:"#/oneOf/28/properties/progress/properties/weight/type",keyword:"type",params:{type:"number"},message:"must be number"}],!1;var Ge=$===e}else var Ge=!0;if(Ge)if(s.caption!==void 0){const n=e;if(typeof s.caption!="string")return o.errors=[{instancePath:t+"/progress/caption",schemaPath:"#/oneOf/28/properties/progress/properties/caption/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ge=n===e}else var Ge=!0}}else return o.errors=[{instancePath:t+"/progress",schemaPath:"#/oneOf/28/properties/progress/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var Ae=a===e}else var Ae=!0;if(Ae){if(r.step!==void 0){let s=r.step;const a=e;if(typeof s!="string")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/28/properties/step/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(s!=="setSiteLanguage")return o.errors=[{instancePath:t+"/step",schemaPath:"#/oneOf/28/properties/step/const",keyword:"const",params:{allowedValue:"setSiteLanguage"},message:"must be equal to constant"}],!1;var Ae=a===e}else var Ae=!0;if(Ae)if(r.language!==void 0){const s=e;if(typeof r.language!="string")return o.errors=[{instancePath:t+"/language",schemaPath:"#/oneOf/28/properties/language/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var Ae=s===e}else var Ae=!0}}}}else return o.errors=[{instancePath:t,schemaPath:"#/oneOf/28/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1}else return o.errors=[{instancePath:t,schemaPath:"#/discriminator",keyword:"discriminator",params:{error:"mapping",tag:"step",tagValue:J},message:'value of tag "step" must be in oneOf'}],!1;else return o.errors=[{instancePath:t,schemaPath:"#/discriminator",keyword:"discriminator",params:{error:"tag",tag:"step",tagValue:J},message:'tag "step" must be string'}],!1}}else return o.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return o.errors=i,e===0}function B(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;if(e===0)if(r&&typeof r=="object"&&!Array.isArray(r)){const j=e;for(const u in r)if(!Zr.call(bt.properties,u))return B.errors=[{instancePath:t,schemaPath:"#/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:u},message:"must NOT have additional properties"}],!1;if(j===e){if(r.landingPage!==void 0){const u=e;if(typeof r.landingPage!="string")return B.errors=[{instancePath:t+"/landingPage",schemaPath:"#/properties/landingPage/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=u===e}else var d=!0;if(d){if(r.description!==void 0){const u=e;if(typeof r.description!="string")return B.errors=[{instancePath:t+"/description",schemaPath:"#/properties/description/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=u===e}else var d=!0;if(d){if(r.meta!==void 0){let u=r.meta;const O=e;if(e===O)if(u&&typeof u=="object"&&!Array.isArray(u)){let m;if(u.title===void 0&&(m="title")||u.author===void 0&&(m="author"))return B.errors=[{instancePath:t+"/meta",schemaPath:"#/properties/meta/required",keyword:"required",params:{missingProperty:m},message:"must have required property '"+m+"'"}],!1;{const v=e;for(const w in u)if(!(w==="title"||w==="description"||w==="author"||w==="categories"))return B.errors=[{instancePath:t+"/meta",schemaPath:"#/properties/meta/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:w},message:"must NOT have additional properties"}],!1;if(v===e){if(u.title!==void 0){const w=e;if(typeof u.title!="string")return B.errors=[{instancePath:t+"/meta/title",schemaPath:"#/properties/meta/properties/title/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=w===e}else var g=!0;if(g){if(u.description!==void 0){const w=e;if(typeof u.description!="string")return B.errors=[{instancePath:t+"/meta/description",schemaPath:"#/properties/meta/properties/description/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=w===e}else var g=!0;if(g){if(u.author!==void 0){const w=e;if(typeof u.author!="string")return B.errors=[{instancePath:t+"/meta/author",schemaPath:"#/properties/meta/properties/author/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var g=w===e}else var g=!0;if(g)if(u.categories!==void 0){let w=u.categories;const q=e;if(e===q)if(Array.isArray(w)){var x=!0;const l=w.length;for(let D=0;D<l;D++){const A=e;if(typeof w[D]!="string")return B.errors=[{instancePath:t+"/meta/categories/"+D,schemaPath:"#/properties/meta/properties/categories/items/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var x=A===e;if(!x)break}}else return B.errors=[{instancePath:t+"/meta/categories",schemaPath:"#/properties/meta/properties/categories/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var g=q===e}else var g=!0}}}}}else return B.errors=[{instancePath:t+"/meta",schemaPath:"#/properties/meta/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=O===e}else var d=!0;if(d){if(r.preferredVersions!==void 0){let u=r.preferredVersions;const O=e;if(e===O)if(u&&typeof u=="object"&&!Array.isArray(u)){let m;if(u.php===void 0&&(m="php")||u.wp===void 0&&(m="wp"))return B.errors=[{instancePath:t+"/preferredVersions",schemaPath:"#/properties/preferredVersions/required",keyword:"required",params:{missingProperty:m},message:"must have required property '"+m+"'"}],!1;{const v=e;for(const w in u)if(!(w==="php"||w==="wp"))return B.errors=[{instancePath:t+"/preferredVersions",schemaPath:"#/properties/preferredVersions/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:w},message:"must NOT have additional properties"}],!1;if(v===e){if(u.php!==void 0){let w=u.php;const q=e,b=e;let l=!1;const D=e;if(typeof w!="string"){const A={instancePath:t+"/preferredVersions/php",schemaPath:"#/definitions/SupportedPHPVersion/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[A]:i.push(A),e++}if(!(w==="8.3"||w==="8.2"||w==="8.1"||w==="8.0"||w==="7.4"||w==="7.3"||w==="7.2"||w==="7.1"||w==="7.0")){const A={instancePath:t+"/preferredVersions/php",schemaPath:"#/definitions/SupportedPHPVersion/enum",keyword:"enum",params:{allowedValues:wt.enum},message:"must be equal to one of the allowed values"};i===null?i=[A]:i.push(A),e++}var T=D===e;if(l=l||T,!l){const A=e;if(typeof w!="string"){const U={instancePath:t+"/preferredVersions/php",schemaPath:"#/properties/preferredVersions/properties/php/anyOf/1/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[U]:i.push(U),e++}if(w!=="latest"){const U={instancePath:t+"/preferredVersions/php",schemaPath:"#/properties/preferredVersions/properties/php/anyOf/1/const",keyword:"const",params:{allowedValue:"latest"},message:"must be equal to constant"};i===null?i=[U]:i.push(U),e++}var T=A===e;l=l||T}if(l)e=b,i!==null&&(b?i.length=b:i=null);else{const A={instancePath:t+"/preferredVersions/php",schemaPath:"#/properties/preferredVersions/properties/php/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[A]:i.push(A),e++,B.errors=i,!1}var P=q===e}else var P=!0;if(P)if(u.wp!==void 0){const w=e;if(typeof u.wp!="string")return B.errors=[{instancePath:t+"/preferredVersions/wp",schemaPath:"#/properties/preferredVersions/properties/wp/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var P=w===e}else var P=!0}}}else return B.errors=[{instancePath:t+"/preferredVersions",schemaPath:"#/properties/preferredVersions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=O===e}else var d=!0;if(d){if(r.features!==void 0){let u=r.features;const O=e;if(e===O)if(u&&typeof u=="object"&&!Array.isArray(u)){const m=e;for(const v in u)if(v!=="networking")return B.errors=[{instancePath:t+"/features",schemaPath:"#/properties/features/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:v},message:"must NOT have additional properties"}],!1;if(m===e&&u.networking!==void 0&&typeof u.networking!="boolean")return B.errors=[{instancePath:t+"/features/networking",schemaPath:"#/properties/features/properties/networking/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"}],!1}else return B.errors=[{instancePath:t+"/features",schemaPath:"#/properties/features/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=O===e}else var d=!0;if(d){if(r.extraLibraries!==void 0){let u=r.extraLibraries;const O=e;if(e===O)if(Array.isArray(u)){var E=!0;const m=u.length;for(let v=0;v<m;v++){let w=u[v];const q=e;if(typeof w!="string")return B.errors=[{instancePath:t+"/extraLibraries/"+v,schemaPath:"#/definitions/ExtraLibrary/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;if(w!=="wp-cli")return B.errors=[{instancePath:t+"/extraLibraries/"+v,schemaPath:"#/definitions/ExtraLibrary/const",keyword:"const",params:{allowedValue:"wp-cli"},message:"must be equal to constant"}],!1;var E=q===e;if(!E)break}}else return B.errors=[{instancePath:t+"/extraLibraries",schemaPath:"#/properties/extraLibraries/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var d=O===e}else var d=!0;if(d){if(r.constants!==void 0){let u=r.constants;const O=e;if(e===O)if(u&&typeof u=="object"&&!Array.isArray(u))for(const m in u){const v=e;if(typeof u[m]!="string")return B.errors=[{instancePath:t+"/constants/"+m.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/constants/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var L=v===e;if(!L)break}else return B.errors=[{instancePath:t+"/constants",schemaPath:"#/properties/constants/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=O===e}else var d=!0;if(d){if(r.plugins!==void 0){let u=r.plugins;const O=e;if(e===O)if(Array.isArray(u)){var N=!0;const m=u.length;for(let v=0;v<m;v++){let w=u[v];const q=e,b=e;let l=!1;const D=e;if(typeof w!="string"){const R={instancePath:t+"/plugins/"+v,schemaPath:"#/properties/plugins/items/anyOf/0/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[R]:i.push(R),e++}var y=D===e;if(l=l||y,!l){const R=e;K(w,{instancePath:t+"/plugins/"+v,parentData:u,parentDataProperty:v,rootData:h})||(i=i===null?K.errors:i.concat(K.errors),e=i.length);var y=R===e;l=l||y}if(l)e=b,i!==null&&(b?i.length=b:i=null);else{const R={instancePath:t+"/plugins/"+v,schemaPath:"#/properties/plugins/items/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[R]:i.push(R),e++,B.errors=i,!1}var N=q===e;if(!N)break}}else return B.errors=[{instancePath:t+"/plugins",schemaPath:"#/properties/plugins/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var d=O===e}else var d=!0;if(d){if(r.siteOptions!==void 0){let u=r.siteOptions;const O=e;if(e===O)if(u&&typeof u=="object"&&!Array.isArray(u)){const m=e;for(const v in u)if(v!=="blogname"){const w=e;if(typeof u[v]!="string")return B.errors=[{instancePath:t+"/siteOptions/"+v.replace(/~/g,"~0").replace(/\//g,"~1"),schemaPath:"#/properties/siteOptions/additionalProperties/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var I=w===e;if(!I)break}if(m===e&&u.blogname!==void 0&&typeof u.blogname!="string")return B.errors=[{instancePath:t+"/siteOptions/blogname",schemaPath:"#/properties/siteOptions/properties/blogname/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1}else return B.errors=[{instancePath:t+"/siteOptions",schemaPath:"#/properties/siteOptions/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;var d=O===e}else var d=!0;if(d){if(r.login!==void 0){let u=r.login;const O=e,z=e;let m=!1;const v=e;if(typeof u!="boolean"){const q={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/0/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};i===null?i=[q]:i.push(q),e++}var V=v===e;if(m=m||V,!m){const q=e;if(e===q)if(u&&typeof u=="object"&&!Array.isArray(u)){let l;if(u.username===void 0&&(l="username")||u.password===void 0&&(l="password")){const D={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/1/required",keyword:"required",params:{missingProperty:l},message:"must have required property '"+l+"'"};i===null?i=[D]:i.push(D),e++}else{const D=e;for(const A in u)if(!(A==="username"||A==="password")){const R={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/1/additionalProperties",keyword:"additionalProperties",params:{additionalProperty:A},message:"must NOT have additional properties"};i===null?i=[R]:i.push(R),e++;break}if(D===e){if(u.username!==void 0){const A=e;if(typeof u.username!="string"){const R={instancePath:t+"/login/username",schemaPath:"#/properties/login/anyOf/1/properties/username/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[R]:i.push(R),e++}var Q=A===e}else var Q=!0;if(Q)if(u.password!==void 0){const A=e;if(typeof u.password!="string"){const U={instancePath:t+"/login/password",schemaPath:"#/properties/login/anyOf/1/properties/password/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[U]:i.push(U),e++}var Q=A===e}else var Q=!0}}}else{const l={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf/1/type",keyword:"type",params:{type:"object"},message:"must be object"};i===null?i=[l]:i.push(l),e++}var V=q===e;m=m||V}if(m)e=z,i!==null&&(z?i.length=z:i=null);else{const q={instancePath:t+"/login",schemaPath:"#/properties/login/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[q]:i.push(q),e++,B.errors=i,!1}var d=O===e}else var d=!0;if(d){if(r.steps!==void 0){let u=r.steps;const O=e;if(e===O)if(Array.isArray(u)){var _=!0;const m=u.length;for(let v=0;v<m;v++){let w=u[v];const q=e,b=e;let l=!1;const D=e;o(w,{instancePath:t+"/steps/"+v,parentData:u,parentDataProperty:v,rootData:h})||(i=i===null?o.errors:i.concat(o.errors),e=i.length);var M=D===e;if(l=l||M,!l){const R=e;if(typeof w!="string"){const F={instancePath:t+"/steps/"+v,schemaPath:"#/properties/steps/items/anyOf/1/type",keyword:"type",params:{type:"string"},message:"must be string"};i===null?i=[F]:i.push(F),e++}var M=R===e;if(l=l||M,!l){const F=e,G={instancePath:t+"/steps/"+v,schemaPath:"#/properties/steps/items/anyOf/2/not",keyword:"not",params:{},message:"must NOT be valid"};i===null?i=[G]:i.push(G),e++;var M=F===e;if(l=l||M,!l){const Y=e;if(typeof w!="boolean"){const H={instancePath:t+"/steps/"+v,schemaPath:"#/properties/steps/items/anyOf/3/type",keyword:"type",params:{type:"boolean"},message:"must be boolean"};i===null?i=[H]:i.push(H),e++}if(w!==!1){const H={instancePath:t+"/steps/"+v,schemaPath:"#/properties/steps/items/anyOf/3/const",keyword:"const",params:{allowedValue:!1},message:"must be equal to constant"};i===null?i=[H]:i.push(H),e++}var M=Y===e;if(l=l||M,!l){const H=e;if(w!==null){const Z={instancePath:t+"/steps/"+v,schemaPath:"#/properties/steps/items/anyOf/4/type",keyword:"type",params:{type:"null"},message:"must be null"};i===null?i=[Z]:i.push(Z),e++}var M=H===e;l=l||M}}}}if(l)e=b,i!==null&&(b?i.length=b:i=null);else{const R={instancePath:t+"/steps/"+v,schemaPath:"#/properties/steps/items/anyOf",keyword:"anyOf",params:{},message:"must match a schema in anyOf"};return i===null?i=[R]:i.push(R),e++,B.errors=i,!1}var _=q===e;if(!_)break}}else return B.errors=[{instancePath:t+"/steps",schemaPath:"#/properties/steps/type",keyword:"type",params:{type:"array"},message:"must be array"}],!1;var d=O===e}else var d=!0;if(d)if(r.$schema!==void 0){const u=e;if(typeof r.$schema!="string")return B.errors=[{instancePath:t+"/$schema",schemaPath:"#/properties/%24schema/type",keyword:"type",params:{type:"string"},message:"must be string"}],!1;var d=u===e}else var d=!0}}}}}}}}}}}}else return B.errors=[{instancePath:t,schemaPath:"#/type",keyword:"type",params:{type:"object"},message:"must be object"}],!1;return B.errors=i,e===0}function Je(r,{instancePath:t="",parentData:p,parentDataProperty:c,rootData:h=r}={}){let i=null,e=0;return B(r,{instancePath:t,parentData:p,parentDataProperty:c,rootData:h})||(i=i===null?B.errors:i.concat(B.errors),e=i.length),Je.errors=i,e===0}const{wpCLI:_t,...vr}=ot,kt={...vr,"wp-cli":_t,importFile:vr.importWxr};function Ot(r,{progress:t=new kr.ProgressTracker,semaphore:p=new W.Semaphore({concurrency:3}),onStepCompleted:c=()=>{},corsProxy:h}={}){var E,L,N,y,I,V,Q,_,M;r=structuredClone(r),r={...r,steps:(r.steps||[]).filter(jt).filter(Tt)};for(const j of r.steps)!j||typeof j!="object"||(j.step==="importFile"?(j.step="importWxr",ce.logger.warn('The "importFile" step is deprecated. Use "importWxr" instead.')):(j==null?void 0:j.step)==="installPlugin"&&"pluginZipFile"in j?(j.pluginData=j.pluginZipFile,ce.logger.warn('The "pluginZipFile" option of the "installPlugin" step is deprecated. Use "pluginData" instead.')):(j==null?void 0:j.step)==="installTheme"&&"themeZipFile"in j&&(j.themeData=j.themeZipFile,ce.logger.warn('The "themeZipFile" option of the "installTheme" step is deprecated. Use "themeData" instead.')));if(r.constants&&r.steps.unshift({step:"defineWpConfigConsts",consts:r.constants}),r.siteOptions&&r.steps.unshift({step:"setSiteOptions",options:r.siteOptions}),r.plugins){const j=r.plugins.map(u=>typeof u=="string"?u.startsWith("https://")?{resource:"url",url:u}:{resource:"wordpress.org/plugins",slug:u}:u).map(u=>({step:"installPlugin",pluginData:u}));r.steps.unshift(...j)}r.login&&r.steps.push({step:"login",...r.login===!0?{username:"admin"}:r.login});const i=((E=r.steps)==null?void 0:E.findIndex(j=>typeof j=="object"&&(j==null?void 0:j.step)&&["wp-cli","enableMultisite"].includes(j.step)))??-1;if((L=r==null?void 0:r.extraLibraries)!=null&&L.includes("wp-cli")||i!==-1){const j={step:"writeFile",data:rt,path:ur};i===-1?(N=r.steps)==null||N.push(j):(y=r.steps)==null||y.splice(i,0,j)}const e=(I=r.steps)==null?void 0:I.findIndex(j=>typeof j=="object"&&(j==null?void 0:j.step)==="importWxr");e!==void 0&&e>-1&&((V=r.steps)==null||V.splice(e,0,{step:"installPlugin",pluginData:{resource:"url",url:"https://playground.wordpress.net/wordpress-importer.zip",caption:"Downloading the WordPress Importer plugin"}}));const{valid:d,errors:g}=$t(r);if(!d){const j=new Error(`Invalid blueprint: ${g[0].message} at ${g[0].instancePath}`);throw j.errors=g,j}const x=r.steps||[],T=x.reduce((j,u)=>{var O;return j+(((O=u.progress)==null?void 0:O.weight)||1)},0),P=x.map(j=>qt(j,{semaphore:p,rootProgressTracker:t,totalProgressWeight:T,corsProxy:h}));return{versions:{php:Et((Q=r.preferredVersions)==null?void 0:Q.php,Ne.SupportedPHPVersions,Ne.LatestSupportedPHPVersion),wp:((_=r.preferredVersions)==null?void 0:_.wp)||"latest"},features:{networking:((M=r.features)==null?void 0:M.networking)??!1},extraLibraries:r.extraLibraries||[],run:async j=>{try{for(const{resources:u}of P)for(const O of u)O.setPlayground(j),O.isAsync&&O.resolve();for(const[u,{run:O,step:z}]of Object.entries(P))try{const m=await O(j);c(m,z)}catch(m){throw ce.logger.error(m),new Error(`Error when executing the blueprint step #${u} (${JSON.stringify(z)}) ${m instanceof Error?`: ${m.message}`:m}`,{cause:m})}}finally{try{await j.goTo(r.landingPage||"/")}catch{}t.finish()}}}}function $t(r){var h;const t=Je(r);if(t)return{valid:t};const p=new Set;for(const i of Je.errors)i.schemaPath.startsWith("#/properties/steps/items/anyOf")||p.add(i.instancePath);const c=(h=Je.errors)==null?void 0:h.filter(i=>!(i.schemaPath.startsWith("#/properties/steps/items/anyOf")&&p.has(i.instancePath)));return{valid:t,errors:c}}function Et(r,t,p){return r&&t.includes(r)?r:p}function jt(r){return!!(typeof r=="object"&&r)}function Tt(r){return["setPhpIniEntry","request"].includes(r.step)?(ce.logger.warn(`The "${r.step}" Blueprint is no longer supported and you can remove it from your Blueprint.`),!1):!0}function qt(r,{semaphore:t,rootProgressTracker:p,totalProgressWeight:c,corsProxy:h}){var P;const i=p.stage((((P=r.progress)==null?void 0:P.weight)||1)/c),e={};for(const E of Object.keys(r)){let L=r[E];at(L)&&(L=ke.create(L,{semaphore:t,corsProxy:h})),e[E]=L}const d=async E=>{var L;try{return i.fillSlowly(),await kt[r.step](E,await At(e),{tracker:i,initialCaption:(L=r.progress)==null?void 0:L.caption})}finally{i.finish()}},g=Pr(e),x=Pr(e).filter(E=>E.isAsync),T=1/(x.length+1);for(const E of x)E.progress=i.stage(T);return{run:d,step:r,resources:g}}function Pr(r){const t=[];for(const p in r){const c=r[p];c instanceof ke&&t.push(c)}return t}async function At(r){const t={};for(const p in r){const c=r[p];c instanceof ke?t[p]=await c.resolve():t[p]=c}return t}async function Rt(r,t){await r.run(t)}function Lt(){}exports.activatePlugin=pr;exports.activateTheme=fr;exports.compileBlueprint=Ot;exports.cp=Rr;exports.defineSiteUrl=yr;exports.defineWpConfigConsts=Ke;exports.enableMultisite=Ar;exports.exportWXR=Cr;exports.importThemeStarterContent=hr;exports.importWordPressFiles=xr;exports.importWxr=Dr;exports.installPlugin=Ir;exports.installTheme=Ur;exports.login=Vr;exports.mkdir=Fr;exports.mv=Lr;exports.request=jr;exports.resetData=Mr;exports.rm=lr;exports.rmdir=Sr;exports.runBlueprintSteps=Rt;exports.runPHP=Or;exports.runPHPWithOptions=$r;exports.runSql=Er;exports.runWpInstallationWizard=zr;exports.setPluginProxyURL=Lt;exports.setSiteLanguage=Hr;exports.setSiteOptions=dr;exports.unzip=er;exports.updateUserMeta=Tr;exports.wpCLI=cr;exports.wpContentFilesExcludedFromExport=ar;exports.writeFile=mr;exports.writeFiles=Nr;exports.zipWpContent=Br;