pÝ °´ Ó Àë¢Ã“ 0sÓ @sÓ PsÓ `sÓ €Ã“ €sÓ sÓ sÓ °sÓ ÀsÓ ÐsÓ àsÓ ðsÓ ‘sÓ ‘sÓ ‘sÓ 0‘sÓ @‘sÓ P‘sÓ `‘sÓ p‘sÓ €‘sÓ ‘sÓ ‘sÓ °‘sÓ À‘sÓ БsÓ à‘sÓ ð‘sÓ ’sÓ ’sÓ ’sÓ 0’sÓ @’sÓ P’sÓ `’sÓ p’sÓ €’sÓ ’sÓ ’sÓ °’sÓ À’sÓ Ð’sÓ à’sÓ ð’sÓ “sÓ “sÓ “sÓ 0“sÓ @“sÓ P“sÓ `“sÓ p“sÓ €“sÓ “sÓ “sÓ °“sÓ À“sÓ ГsÓ ЈÓ ð“sÓ ”sÓ ”sÓ ”sÓ 0”sÓ @”sÓ P”sÓ `”sÓ p”sÓ €”sÓ ”sÓ ”sÓ à£Ã“ À”sÓ ¦¢Ã“ à”sÓ ð”sÓ •sÓ •sÓ •sÓ 0•sÓ @•sÓ P•sÓ `•sÓ p•sÓ ÀuÓ ÐuÓ ÐuÓ àuÓ àuÓ ÿÿÿÿÿÿÿÿd on_notice_helper; /** * {@inheritDoc} */ public static function get_conditionals() { return [ Admin_Conditional::class ]; } /** * First_Time_Configuration_Notice_Integration constructor. * * @param Options_Helper $options_helper The options helper. * @param First_Time_Configuration_Notice_Helper $first_time_configuration_notice_helper The first time configuration notice helper. * @param WPSEO_Admin_Asset_Manager $admin_asset_manager The admin asset manager. */ public function __construct( Options_Helper $options_helper, First_Time_Configuration_Notice_Helper $first_time_configuration_notice_helper, WPSEO_Admin_Asset_Manager $admin_asset_manager ) { $this->options_helper = $options_helper; $this->admin_asset_manager = $admin_asset_manager; $this->first_time_configuration_notice_helper = $first_time_configuration_notice_helper; } /** * {@inheritDoc} */ public function register_hooks() { \add_action( 'wp_ajax_dismiss_first_time_configuration_notice', [ $this, 'dismiss_first_time_configuration_notice' ] ); \add_action( 'admin_notices', [ $this, 'first_time_configuration_notice' ] ); } /** * Dismisses the First-time configuration notice. * * @return bool */ public function dismiss_first_time_configuration_notice() { return $this->options_helper->set( 'dismiss_configuration_workout_notice', true ); } /** * Determines whether and where the "First-time SEO Configuration" admin notice should be displayed. * * @return bool Whether the "First-time SEO Configuration" admin notice should be displayed. */ public function should_display_first_time_configuration_notice() { return $this->first_time_configuration_notice_helper->should_display_first_time_configuration_notice(); } /** * Displays an admin notice when the first-time configuration has not been finished yet. * * @return void */ public function first_time_configuration_notice() { if ( ! $this->should_display_first_time_configuration_notice() ) { return; } $this->admin_asset_manager->enqueue_style( 'monorepo' ); $title = $this->first_time_configuration_notice_helper->get_first_time_configuration_title(); if ( ! $this->first_time_configuration_notice_helper->should_show_alternate_message() ) { $content = \sprintf( /* translators: 1: Link start tag to the first-time configuration, 2: Yoast SEO, 3: Link closing tag. */ \__( 'Get started quickly with the %1$s%2$s First-time configuration%3$s and configure Yoast SEO with the optimal SEO settings for your site!', 'wordpress-seo' ), '', 'Yoast SEO', '' ); } else { $content = \sprintf( /* translators: 1: Link start tag to the first-time configuration, 2: Link closing tag. */ \__( 'We noticed that you haven\'t fully configured Yoast SEO yet. Optimize your SEO settings even further by using our improved %1$s First-time configuration%2$s.', 'wordpress-seo' ), '', '' ); } $notice = new Notice_Presenter( $title, $content, 'mirrored_fit_bubble_woman_1_optim.svg', null, true, 'yoast-first-time-configuration-notice' ); //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Output from present() is considered safe. echo $notice->present(); // Enable permanently dismissing the notice. echo ""; } }