Skip to content

Instantly share code, notes, and snippets.

@psealock
Last active June 9, 2021 00:52
Show Gist options
  • Save psealock/62c65f9f7f367c9db47d08e35802b19b to your computer and use it in GitHub Desktop.
Save psealock/62c65f9f7f367c9db47d08e35802b19b to your computer and use it in GitHub Desktop.
[
{
"key": "basics",
"locales": [
{
"locale": "en_US",
"title": "Get the BBBBBBasics"
}
],
"plugins": [
{
"key": "woocommerce-payments",
"product": "woocommerce-payments",
"locales": [
{
"locale": "en_US",
"description": "Accept credit cards with {{link}}WooCommerce Payments{{/link}}"
}
],
"is_visible": [
{
"type": "or",
"operands": [
{
"type": "base_location_country",
"value": "US",
"operation": "="
},
{
"type": "base_location_country",
"value": "PR",
"operation": "="
},
{
"type": "base_location_country",
"value": "AU",
"operation": "="
},
{
"type": "base_location_country",
"value": "CA",
"operation": "="
},
{
"type": "base_location_country",
"value": "DE",
"operation": "="
},
{
"type": "base_location_country",
"value": "ES",
"operation": "="
},
{
"type": "base_location_country",
"value": "FR",
"operation": "="
},
{
"type": "base_location_country",
"value": "GB",
"operation": "="
},
{
"type": "base_location_country",
"value": "IE",
"operation": "="
},
{
"type": "base_location_country",
"value": "IT",
"operation": "="
},
{
"type": "base_location_country",
"value": "NZ",
"operation": "="
}
]
},
{
"type": "option",
"transformers": [
{
"use": "dot_notation",
"arguments": {
"path": "industry"
}
},
{
"use": "array_column",
"arguments": {
"key": "slug"
}
},
{
"use": "array_search",
"arguments": {
"value": "cbd-other-hemp-derived-products"
}
}
],
"option_name": "woocommerce_onboarding_profile",
"value": "cbd-other-hemp-derived-products",
"default": "",
"operation": "!="
}
]
},
{
"key": "woocommerce-services:shipping",
"product": "shipping",
"locales": [
{
"locale": "en_US",
"description": "Print shipping labels with {{link}}WooCommerce Shipping{{/link}}"
}
],
"is_visible": [
{
"type": "base_location_country",
"value": "US",
"operation": "="
},
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"woocommerce-services"
]
}
]
},
{
"type": "or",
"operands": [
[
{
"type": "option",
"transformers": [
{
"use": "dot_notation",
"arguments": {
"path": "product_types"
}
},
{
"use": "count"
}
],
"option_name": "woocommerce_onboarding_profile",
"value": 1,
"default": "",
"operation": "!="
}
],
[
{
"type": "option",
"transformers": [
{
"use": "dot_notation",
"arguments": {
"path": "product_types.0"
}
}
],
"option_name": "woocommerce_onboarding_profile",
"value": "downloads",
"default": "",
"operation": "!="
}
]
]
}
]
},
{
"key": "woocommerce-services:tax",
"product": "tax",
"locales": [
{
"locale": "en_US",
"description": "Get automated sales tax with {{link}}WooCommerce Tax{{/link}}"
}
],
"is_visible": [
{
"type": "or",
"operands": [
{
"type": "base_location_country",
"value": "US",
"operation": "="
},
{
"type": "base_location_country",
"value": "FR",
"operation": "="
},
{
"type": "base_location_country",
"value": "GB",
"operation": "="
},
{
"type": "base_location_country",
"value": "DE",
"operation": "="
},
{
"type": "base_location_country",
"value": "CA",
"operation": "="
},
{
"type": "base_location_country",
"value": "AU",
"operation": "="
},
{
"type": "base_location_country",
"value": "GR",
"operation": "="
},
{
"type": "base_location_country",
"value": "BE",
"operation": "="
},
{
"type": "base_location_country",
"value": "PT",
"operation": "="
},
{
"type": "base_location_country",
"value": "DK",
"operation": "="
},
{
"type": "base_location_country",
"value": "SE",
"operation": "="
}
]
},
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"woocommerce-services"
]
}
]
}
]
},
{
"key": "jetpack",
"product": "jetpack",
"locales": [
{
"locale": "en_US",
"description": "Enhance speed and security with {{link}}Jetpack{{/link}}"
}
],
"is_visible": [
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"jetpack"
]
}
]
}
]
}
]
},
{
"key": "grow",
"locales": [
{
"locale": "en_US",
"title": "Grow your store"
}
],
"plugins": [
{
"key": "mailpoet",
"product": "mailpoet",
"locales": [
{
"locale": "en_US",
"description": "Level up your email marketing with {{link}}MailPoet{{/link}}"
}
],
"is_visible": [
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"mailpoet"
]
}
]
}
]
},
{
"key": "facebook-for-woocommerce",
"product": "facebook",
"locales": [
{
"locale": "en_US",
"description": "Market with {{link}}Facebook{{/link}}"
}
],
"is_visible": [
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"facebook-for-woocommerce"
]
}
]
}
]
},
{
"key": "google-listings-and-ads",
"product": "google-listings-and-ads",
"locales": [
{
"locale": "en_US",
"description": "Drive sales with {{link}}Google Listings and Ads{{/link}}"
}
],
"is_visible": [
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"google-listings-and-ads"
]
}
]
}
]
},
{
"key": "mailchimp-for-woocommerce",
"product": "mailchimp-for-woocommerce",
"locales": [
{
"locale": "en_US",
"description": "Contact customers with {{link}}Mailchimp{{/link}}"
}
],
"is_visible": [
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"mailchimp-for-woocommerce"
]
}
]
}
]
},
{
"key": "creative-mail-by-constant-contact",
"product": "creative-mail-for-woocommerce",
"locales": [
{
"locale": "en_US",
"description": "Emails made easy with {{link}}Creative Mail{{/link}}"
}
],
"is_visible": [
{
"type": "not",
"operand": [
{
"type": "plugins_activated",
"plugins": [
"creative-mail-for-woocommerce"
]
}
]
}
]
}
]
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment