OBW: Disable (not hide) payment email input when opted-out
This commit is contained in:
parent
0566708744
commit
5eea29eb31
|
@ -1060,6 +1060,10 @@ h3.jetpack-reasons {
|
|||
color: #444;
|
||||
background-color: #fff;
|
||||
display: inline-block;
|
||||
|
||||
&[disabled] {
|
||||
color: #aaa;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -163,18 +163,14 @@ jQuery( function( $ ) {
|
|||
$( this ).closest( '.wc-wizard-service-settings' )
|
||||
.find( 'input.payment-email-input' )
|
||||
.attr( 'type', 'email' )
|
||||
.prop( 'disabled', false )
|
||||
.prop( 'required', true );
|
||||
$( this ).closest( '.wc-wizard-service-settings' )
|
||||
.find( '.wc-wizard-service-setting-stripe_email, .wc-wizard-service-setting-ppec_paypal_email' )
|
||||
.show();
|
||||
} else {
|
||||
$( this ).closest( '.wc-wizard-service-settings' )
|
||||
.find( 'input.payment-email-input' )
|
||||
.attr( 'type', null )
|
||||
.prop( 'disabled', true )
|
||||
.prop( 'required', false );
|
||||
$( this ).closest( '.wc-wizard-service-settings' )
|
||||
.find( '.wc-wizard-service-setting-stripe_email, .wc-wizard-service-setting-ppec_paypal_email' )
|
||||
.hide();
|
||||
}
|
||||
} ).find( 'input#stripe_create_account, input#ppec_paypal_reroute_requests' ).change();
|
||||
|
||||
|
|
Loading…
Reference in New Issue