Skip to content

Commit

Permalink
fix link and current step
Browse files Browse the repository at this point in the history
  • Loading branch information
vraja-pro committed Jan 20, 2025
1 parent 442008b commit e9150b2
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,20 @@ import classNames from "classnames";
* @returns {Object} The button and stepper props.
*/
const getButtonAndStepperProps = ( active, installed, setup, connected, installUrl, activateUrl, setupUrl ) => {
let buttonProps = {
children: __( "Install Site Kit by Google", "wordpress-seo" ),
as: "a",
href: installUrl,
};
let currentStep = 1;
let isComplete = false;
let buttonProps;
let currentStep;
let isComplete;

switch ( true ) {
case ( ! installed ):
currentStep = 1;
isComplete = false;
buttonProps = {
children: __( "Install Site Kit by Google", "wordpress-seo" ),
as: "a",
href: installUrl,
};
break;
case ( ! active && installed ):
currentStep = 2;
buttonProps = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -157,9 +157,9 @@ public function get_google_site_kit_configuration(): array {
'setup' => \get_option( 'googlesitekit_has_connected_admins', false ) === '1',
'connected' => $this->options_helper->get( 'google_site_kit_connected', false ),
'featureActive' => $this->google_site_kit_conditional->is_met(),
'installUrl' => $google_site_kit_install_url,
'activateUrl' => $google_site_kit_activate_url,
'setupUrl' => $google_site_kit_setup_url,
'installUrl' => \html_entity_decode( $google_site_kit_install_url ),
'activateUrl' => \html_entity_decode( $google_site_kit_activate_url ),
'setupUrl' => \html_entity_decode( $google_site_kit_setup_url ),
];
}
}

0 comments on commit e9150b2

Please sign in to comment.