mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-07-04 10:05:43 +03:00
Manage Pledge: Update email dialog to use JS submission (#104)
Use the proper dialog behavior for submitting an email to generate a manage link. Fixes #98.
This commit is contained in:
parent
a67ef04505
commit
a11e3c5fa5
14 changed files with 1202 additions and 134 deletions
|
@ -14,7 +14,6 @@ defined( 'WPINC' ) || die();
|
|||
// Todo make this into simple optionless blocks instead?
|
||||
add_shortcode( '5ftf_pledge_form_new', __NAMESPACE__ . '\render_form_new' );
|
||||
add_shortcode( '5ftf_pledge_form_manage', __NAMESPACE__ . '\render_form_manage' );
|
||||
add_shortcode( '5ftf_pledge_form_manage_link', __NAMESPACE__ . '\render_manage_link_request' );
|
||||
|
||||
/**
|
||||
* Render the form(s) for creating new pledges.
|
||||
|
@ -175,19 +174,6 @@ function render_form_manage() {
|
|||
return ob_get_clean();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Render the `render_manage_link_request` shortcode.
|
||||
*/
|
||||
function render_manage_link_request() {
|
||||
// @todo enable when https://github.com/WordPress/five-for-the-future/issues/6 is done
|
||||
if ( ! defined( 'WPORG_SANDBOXED' ) || ! WPORG_SANDBOXED ) {
|
||||
return;
|
||||
}
|
||||
|
||||
require_once FiveForTheFuture\get_views_path() . 'form-pledge-request-manage-link.php';
|
||||
}
|
||||
|
||||
/**
|
||||
* Process a submission from the Manage Existing Pledge form.
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue