Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3,122 changes: 2,827 additions & 295 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions projects/packages/forms/.eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
build/
dist/
routes/
6 changes: 6 additions & 0 deletions projects/packages/forms/.npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Hoist @wordpress packages so @wordpress/build can find and bundle them
public-hoist-pattern[]=@wordpress/*

# Workaround: @wordpress/build@next declares peer deps for 1.x versions that don't exist yet
# Only 0.x pre-release versions are published to npm
strict-peer-dependencies=false
7 changes: 7 additions & 0 deletions projects/packages/forms/.npmrc.bak
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Hoist @wordpress packages so @wordpress/build can find and bundle them
# This is needed for the experimental pages feature
public-hoist-pattern[]=@wordpress/*

# Workaround: @wordpress/build declares peer deps for 1.x versions that don't exist yet
# Only 0.x pre-release versions are published to npm
strict-peer-dependencies=false
43 changes: 43 additions & 0 deletions projects/packages/forms/build/index.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<?php
/**
* Main entry point for auto-generated asset registration.
* Do not edit this file manually.
*
* @package gutenberg
*/

// Load version constant.
$version_file = __DIR__ . '/version.php';
if ( file_exists( $version_file ) ) {
require_once $version_file;
}

// Load script module registration.
$modules_file = __DIR__ . '/modules.php';
if ( file_exists( $modules_file ) ) {
require_once $modules_file;
}

// Load script registration.
$scripts_file = __DIR__ . '/scripts.php';
if ( file_exists( $scripts_file ) ) {
require_once $scripts_file;
}

// Load style registration.
$styles_file = __DIR__ . '/styles.php';
if ( file_exists( $styles_file ) ) {
require_once $styles_file;
}

// Load routes registration.
$routes_file = __DIR__ . '/routes.php';
if ( file_exists( $routes_file ) ) {
require_once $routes_file;
}

// Load pages registration.
$pages_file = __DIR__ . '/pages.php';
if ( file_exists( $pages_file ) ) {
require_once $pages_file;
}
44 changes: 44 additions & 0 deletions projects/packages/forms/build/modules.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
<?php
/**
* Script module registration - Auto-generated by build process.
* Do not edit this file manually.
*
* @package gutenberg
*/

if ( ! function_exists( 'gutenberg_register_script_modules' ) ) {
/**
* Register all script modules.
*/
function gutenberg_register_script_modules() {
$modules_dir = __DIR__ . '/modules';
$modules_file = $modules_dir . '/index.php';

if ( ! file_exists( $modules_file ) ) {
return;
}

$modules = require $modules_file;
$base_url = plugins_url( 'build/modules/', dirname( __FILE__ ) );
$extension = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '.js' : '.min.js';

foreach ( $modules as $module ) {
$asset_path = $modules_dir . '/' . $module['asset'];
$asset = file_exists( $asset_path ) ? require $asset_path : array();

wp_register_script_module(

Check failure on line 29 in projects/packages/forms/build/modules.php

View workflow job for this annotation

GitHub Actions / Static analysis

ParamError PhanParamTooMany Call with 5 arg(s) to \wp_register_script_module(string $id, string $src, array $deps = [], ?false|?string $version = \false) which only takes 4 arg(s) defined at /home/runner/work/jetpack/jetpack/vendor/php-stubs/wordpress-stubs/wordpress-stubs.php:137393 FAQ on Phan issues: pdWQjU-Jb-p2
$module['id'],
$base_url . $module['path'] . $extension,
$asset['module_dependencies'] ?? array(),
$asset['version'] ?? false,
array(
'fetchpriority' => 'low',
'in_footer' => true,
)
);
}
}

add_action( 'wp_default_scripts', 'gutenberg_register_script_modules' );
remove_action( 'wp_default_scripts', 'wp_default_script_modules' );
}
Loading
Loading