Skip to content

Commit

Permalink
Mark jetpack as complete if page is visited
Browse files Browse the repository at this point in the history
  • Loading branch information
aulisius committed May 31, 2023
1 parent 263d731 commit d8f8f8e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build/index.asset.php
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'wp-api-fetch', 'wp-date', 'wp-element', 'wp-i18n'), 'version' => 'bf10e9b3127b0ce981c2');
<?php return array('dependencies' => array('lodash', 'moment', 'react', 'wp-api-fetch', 'wp-date', 'wp-element', 'wp-i18n'), 'version' => 'ba62801a6a28d1530960');
12 changes: 11 additions & 1 deletion src/configs/OnboardingList.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,11 +141,21 @@ export function OnboardingListDefinition(props) {
"wp-module-ecommerce"
),
state: {
isCompleted: () =>
pandora.get("nfd_ecommerce_onboarding_checklist", {})
.connect_socials === "completed",
isActive: (queries) => queries?.plugins?.isJetpackActive,
url: () => RuntimeSdk.adminUrl("admin.php?page=jetpack#/sharing"),
},
shouldRender: (state) => state.isActive,
actions: {},
actions: {
manage: () => {
pandora.set("nfd_ecommerce_onboarding_checklist", {
...pandora.get("nfd_ecommerce_onboarding_checklist", {}),
connect_socials: "completed",
});
},
},
queries: [{ key: "plugins", selector: parsePluginStatus }],
},
{
Expand Down

0 comments on commit d8f8f8e

Please sign in to comment.