@@ -33,6 +33,7 @@ public function __construct() {
33
33
\add_action ( 'admin_menu ' , array ( __CLASS__ , 'register_page ' ) );
34
34
\add_action ( 'load-dashboard_page_ ' . self ::$ slug , array ( __CLASS__ , 'page_title ' ), 9 , 1 );
35
35
\add_action ( 'load-dashboard_page_ ' . self ::$ slug , array ( __CLASS__ , 'initialize ' ) );
36
+ \add_action ( 'load-toplevel_page_bluehost ' , array ( __CLASS__ , 'hide_onboarding_restart_card ' ) );
36
37
\add_action ( 'load-themes.php ' , array ( __CLASS__ , 'can_restart_onboarding ' ) );
37
38
if ( 'sitegen ' === Data::current_flow () ) {
38
39
\add_action ( 'load-themes.php ' , array ( __CLASS__ , 'mark_sitegen_generated_themes ' ) );
@@ -317,7 +318,38 @@ public static function can_restart_onboarding(): void {
317
318
'all '
318
319
);
319
320
321
+ /**
322
+ * Temporary: hide the build with ai button
323
+ */
324
+ wp_add_inline_style (
325
+ 'onboarding-restart-button ' ,
326
+ '.themes .theme.build-with-ai {
327
+ display: none !important;
328
+ } '
329
+ );
330
+
320
331
\wp_enqueue_script ( 'onboarding-restart-button ' );
321
332
\wp_enqueue_style ( 'onboarding-restart-button ' );
322
333
}
334
+
335
+ /**
336
+ * Temporary: Enqueue scripts that hides the build with ai button
337
+ *
338
+ * @return void
339
+ */
340
+ public static function hide_onboarding_restart_card (): void {
341
+ \wp_register_style (
342
+ 'hide-onboarding-restart-card ' ,
343
+ false ,
344
+ );
345
+
346
+ \wp_add_inline_style (
347
+ 'hide-onboarding-restart-card ' ,
348
+ 'div[data-testid="restartOnboarding"] {
349
+ display: none !important;
350
+ } '
351
+ );
352
+
353
+ \wp_enqueue_style ( 'hide-onboarding-restart-card ' );
354
+ }
323
355
} // END /NewfoldLabs/WP/Module/Onboarding/Admin()
0 commit comments