Skip to content

Commit

Permalink
Merge pull request #16 from newfold-labs/update/check-features-for-ar…
Browse files Browse the repository at this point in the history
…e-you-sure-card-conditions

require the newfold-features script and only display enabled features
  • Loading branch information
circlecube authored Jun 5, 2024
2 parents c99f4bf + 68d3421 commit a01eb3f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions includes/DeactivationSurvey.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,15 @@ public function __construct() {
ucwords( container()->plugin()->id )
),
'desc' => __( 'Automatically clears the server page cache when your site updates', 'wp-module-deactivation' ),
'condition' => true,
'condition' => 'window.NewfoldFeatures.features.performance',
),
array(
'title' => sprintf(
__( '%s Staging', 'wp-module-deactivation' ),
ucwords( container()->plugin()->id )
),
'desc' => __( 'Create a staging copy of your site to safely test changes', 'wp-module-deactivation' ),
'condition' => true,
'condition' => 'window.NewfoldFeatures.features.staging',
),
array(
'title' => __( 'WooCommerce Tools', 'wp-module-deactivation' ),
Expand All @@ -72,7 +72,7 @@ public function __construct() {
array(
'title' => __( 'Wonder Blocks & Patterns Library', 'wp-module-deactivation' ),
'desc' => __( 'Dozens of beautiful block templates and patterns', 'wp-module-deactivation' ),
'condition' => true,
'condition' => 'window.NewfoldFeatures.features.patterns',
),
),
'sureHelp' => sprintf(
Expand Down Expand Up @@ -118,7 +118,7 @@ public function deactivation_survey_assets() {
wp_enqueue_script(
'nfd-deactivation-survey',
$assets_dir . 'js/deactivation-survey.js',
array( 'nfd-deactivation-a11y-dialog' ),
array( 'newfold-features', 'nfd-deactivation-a11y-dialog' ),
container()->plugin()->version,
true
);
Expand Down

0 comments on commit a01eb3f

Please sign in to comment.