* Fix WCPay task Settings link
Fixeswoocommerce/woocommerce-admin#4293 by setting link type for new pageload.
* Check for success query param to show notice
* Shrink WCPay task footnote so it fits in one line
* Remove unnecessary Fragment wrapper
* Omit option update from client side
The payment method is already enabled when the connection is finalized on redirect.
* Add getInAppPurchaseUrl lib function
* Implement getInAppPurchaseUrl for marketing tab
* Include the directory with the wccom-site param
* use getInAppPurchaseUrl helper function in onboarding CartModal component
* Fix 'addQueryArgs' is defined but never used
* Fix Missing JSDoc @return description
* Make connectNonce setting a global setting rather than a marketing once
Co-authored-by: Jason Conroy <jason@findingsimple.com>
* Allow updateActivePlugins to add new plugins instead of replace
* Add autoConnect prop to Jetpack Connect component
* Add connect component to plugin benefits screen
* Add onError and missing prop types for Connect
* Update redirect URL after Jetpack connection
* Add tests for added active plugins
* Skip install if plugin error exists
* Update active and installed plugins to use replace flag
* Update tests to handle replace flag
* Refactor plugin install flow pending state
* Release: 1.2.0
* Updates per feedback.
* Get installed plugins from new plugin settings object. (https://github.com/woocommerce/woocommerce-admin/pull/4357)
* Bumping version numbers
* synch package-lock.json with master
Co-authored-by: Jeff Stieler <jeff.m.stieler@gmail.com>
* Move allowed report analytics data to separate function
* Add function to retrieve allowed Jetpack module endpoints
* Fix API urls
* Add number format as default for jetpack modules
* Add module permissions and format to array
* Add filter for returned data from performance indicators API
* Filter jetpack stats by queried dates
* Fix empty date query filtering
* Mock the Jetpack API response
* Add tests for Jetpack stats in allowed endpoints
* Add tests for filtering Jetpack stats based on time
* Add tests for default args
* Fixwoocommerce/woocommerce-admin#4086 misaligned 'required' text on selects
* rework this so that the issue is fixed in the select control itself
Co-authored-by: Rebecca Scott <me@becdetat.com>
* New notification: How to draw attention to your online store
# Conflicts:
# src/FeaturePlugin.php
* Get the option from the arguments
Co-authored-by: Rebecca Scott <me@becdetat.com>
* Add Storybook console addon.
* Add Link stories for all link types.
* Add unit tests for Link component.
* Add unit tests for List component.
* Add support for List item `listItemTag`.
* Document the `woocommerce_admin_is_loading` filter.
* Prevent dashboard from being visible during ProfileWizard chunk load.
* Delay removing loading class rather than adding full screen class prematurely.
* Remove welcome note
* Remove store notice setting note
* Remove review your experience note
* Add tests for delete_notes_with_name
* Add filter support so that other code can add notes to be deleted on upgrade.
* Homwpage: add stats overview stat toggle
* toggle stats
* fix
* tests
* better hook name
* clean up
* add back in Fragment
* remove extra prop
* better test name
* Save payment skipped and event timestamp to options
* Add payments note
* Convert payments task timestamp to seconds
* Skip payments note if skip timestamp is not set
* Use lazy loading to split up the size of the js downloaded
* Use lazy loading to split up the size of the js downloaded
* Add Moment Timezone plugin to reduce size of data file.
* Lazy load header panels and use Dashicons for faster loading
* Load assets from the correct publicPath
* Load assets from the correct publicPath
* PHP cs fixes
* Fix missing quotes on string literal.
* Fix PropType warning for lazy loaded component.
* Separate the task list and dashboard chunks.
* Lazy load dashboard sections.
* Restore original icons and reduce size by importing only the icons needed
* Lazy load alerts to save more Kb on initial load
* Minify built JS in production mode.
* Add preload tags for WC Admin assets. (https://github.com/woocommerce/woocommerce-admin/pull/4162)
* Fix linting errors.
* Add modified UnminifiedWebpackPlugin.
* Produce minified and unminified bundles for all builds.
* Remove unused variable from webpack config.
* Run unminify after sourcemap generation.
* Only hook after optimization if we're using a devtool.
* Add minification suffix in Loader::get_url().
* Lazy load OBW on new home screen.
* Move OBW style up a level to layout.
* Hydrate ProfileWizard independently of withSelect and withDispatch
* Fix order of composition and fallback function when using hydration.
Co-authored-by: Jeff Stieler <jeff.m.stieler@gmail.com>
Co-authored-by: Paul Sealock <psealock@gmail.com>
* Fix sorting to push Storefront to the top of the theme list
* Add test to ensure Storefront is sorted in get_themes()
* copy paste cleanup
* Refactor sorting logic.
* Fix linting errors
* Updates per feedback.
* Add check for products property
* Fix for 5.6 CI.
* Oh hey another CI fix
Co-authored-by: Timmy Crawford <timmydcrawford@gmail.com>
* Move ProfileWizard component out of Dashboard.
* Don't trigger the OBW from the Analytics Dashboard (with new home screen).
* Trigger OBW from the new home screen.
* Fix duplicate import.
* Specify home screen in tracks event when enabled.
* Add Jetpack info to home page Tracks event.
* Use @wordpress/data's withSelect - no need for wc-api.
* Add plugins hydration to existing compose() call.
* Safer access of wcSettings object in plugins hydration.
* Remove redundant plugins hydration from TaskList and ProfileWizard.
* Add base nav component
* Check if current screen is WC registered page
* Add core menu items
* Add param for menu items to migrate and hide old menu items
* Add body classes for wc navigation
* Check capability before adding menu items
* Add submenu items to frontend component
* Hide wc nav behind option
Co-authored-by: Joshua Flowers <joshuatf@gmail.com>
* Add allowMarketplaceSuggestions to woocommerce_shared_settings
* Convert to functional component
* Hide ReccomendedExtensions card if opted out from marketing suggestions
* Change "Demo" to "Sample" products
A few years ago we had a discussion on the name of the files for test products and we choose "sample" data over "dummy" data. I think we should likely stick to that naming (which is also the name of the folder and the files in WC core: https://github.com/woocommerce/woocommerce/tree/master/sample-data)
This commit changes that wording
* Small update in caps of "Build a better WooCommerce"
All titles and questions in the new onboarding wizards only capitalise names and the first letter of the sentence. This seemed a tiny bit off.
* Remove auto connect steps from Stripe payment task
As of May 31 the API for stripe account auto creation will no longer be
supported. As a result, the Stripe payment on-boarding step will no
longer be able to auto create accounts for users.
This removes all auto connect functionality from this step, and instead
falls back to the oAuth setup flow.
See:
https://wcpay.wordpress.com/2020/02/06/stripe-ending-support-for-the-deferred-account-activation-api-on-may-31/#comment-2080
* Fix logic to decide which connect method to render
When the Stripe component renders for the first time, it
always returns the manual connect method. This is because there is
an additional call to requiresManualConfig() in getConnectStep which
looks for values in activePlugins that won't be present on the initial
component render.
This removes this check and instead relies on the isPending state to
help decide to render a connect method or wait for oAuth connectURL
to finish fetching.
* Remove redundant error modal render method
This removes the error modal render method as it is also no longer
needed with the removal of auto account creation.
This also removes errorMessage and errorTitle state along with any
references to these values.
* Changed email marketing note and the old filter was removed
The email marketing note was modified. Also, the old filter was removed.
* This note is not using NoteTraits anymore.
The NoteTraits reference was removed because the note is not using it anymore.
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
* Changed element that is compared after choosing a theme
Onboarding - There was a problem in the theme verification where at the end of the profiler it always went into the installation flow. This problem was solved in this commit.
* Added check to choose the right flow (install or activate plugin)
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
* Plugins DataStore: decouple from onboarding (https://github.com/woocommerce/woocommerce-admin/pull/4048)
* Plugins DataStore: Add client side store
* change active_plugins to public static function
* don't change shape of allowed plugins
* Set a max word length for the installed extension descriptions
* Improve InstalledExtensions layout for tablet and mobile
Mobile still needs work…
* Align product icon to top
* Tweak WelcomeCard mobile appearance
* Fix alignment
* Use EmptyContent component when there are no knowledge base posts
* Reduce transient timeout to 15 mins when remote get fails
* Satisfy phpcs
* Satisfy jslint
* woocommerce/woocommerce-admin#3793 create admin note if Jetpack plugin doesn't work during OBW
* Move slug logic into the note creator class
* Also allow WooCommerce Services plugin when creating note
* rename possibly_add
* Rename note service class for jetpack/woocommerce services
* Remove (by actioning) notes when the Jetpack or WooCommerce Services plugins are activated
* Add todo around using a filter to make onboarding plugin API more generic
* Create admin note if activation fails
* Fix callback, don't know how that got through...
* Install from the note using a callback fn rather than redirecting back to the OBW
* Remove .orig file
* Move WC_Admin_Notes_Filters action hooks into WC_Admin_Notes_Install_Jetpack_And_WooCommerce_Services_Plugin
* Remove return values from plugin install function
* Simplify how plugin installation triggers actioning the note
* Use better icon in Jetpack/WooCommerce Services note
* Add space to note copy
* Shorten some names
* Only action the note if both plugins are activated
Co-authored-by: Rebecca Scott <me@becdetat.com>
* Enlarged competitors' Listbox in the Onboarding
Onboarding - Added a new class to enlarge the competitors' Listbox in the Business details step.
* Replaced fixed height with unset
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
* Add method to retrieve all synced order statuses.
* Determine what unregistered order statuses we have and add to client-side settings object.
* Stop filtering out unregistered statuses from analytics settings.
* Add unregistered statuses to analytics settings fields.
* Added check to show WC Pay option only when Jetpack is connected
A verification was added to the Setup Checklist payment step, to show WC Pay option only when Jetpack is connected
* Changed the solution approach
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
* Bugfix on payments step in CBD flow
The `array_search` method was changed to `in_array`
* After pressing Connect a new tab opens with the Square webpage
* Updated behavior for non CBD Square payment connection
* Square option's name updated
* Replaced <p> tag with a <div> tag
Since there was a `validateDOMNesting` warning because we weren't adding only text inside a <p> tag, the `p` tag was changed to a `div`.
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
* Add support for additional partner extensions to installed extensions
* Use correct variable name
* Add codisto support url
* Fix hubspot svg
- Fixes orange color as per brand guide
- Reduces file size from 120kb to 1kb
* Replace Google logo with vector SVG
* Fix AutomateWoo icon
* Fix Amazon Ebay svg icon
Co-authored-by: Daniel Bitzer <danielbitzer@gmail.com>
This commit adds the "woocommerce_admin_onboarding_homepage_template" filter, enabling themes/plugins to filter the default homepage template created by the WooCommerce onboarding process.
* Use plugin component with autoinstall in benefits step
* Cache plugins to install to prevent render changes on install
* Add busy state to button when installing
* Prevent multiple requests being fired when awaiting next step
* Disable buttons when actioned
* Hide some more performance indicators by default.
Don't show: AOV, Returns, Gross Sales.
* Fix default hidden dashboard chart identifiers.
They were missing the expected endpoint prefix.
* Pass specified totals/intervals fields parameter to the Order Stats Query.
* Only request stats used in render for report summaries and charts.
Implement Orders as an example.
* Specify stats fields for all report requests.
* Add 'fields' parameter handling to all stats endpoint controllers.
* Reduce stats fields requested by dashboard charts.
* Added hook to delete woocommerce_onboarding_homepage_post_id
Added hook to delete woocommerce_onboarding_homepage_post_id when the homepage is deleted.
* Moved post type check further up in the method
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
* Add WC Pay to allowed plugins
* Add WC Pay Note to Inbox
* Don't update WC Pay note content
Actioned notes are hidden from the Inbox it turns out, so there's
no need to update the content to reflect that the WC Pay plugin
has been installed.
* Add WC pay note only after April 14
Instead of only adding the Install Now button in April. Only
add the note so that the Install now button is always available
and generally, the note is more useful and actionable because
the plugin is actually available.
* Fix WC Pay note install action
* Check if WC Pay is active or installed
Not just if the plugin files are available. This addresses both the
case where the plugin may be active an in a different folder name,
and where the plugin may have been installed but is not active,
likely because it's been deactivated.
* Add Marketing feature flag
* Add marketing page and menu item
* Register marketing page with layout controller
* Add initial marketing cards
* Add max-width to marketing overview page
* Add initial marketing WelcomeCard component
* Make marketing welcome card permanently dismiss
* Add a readme for the marketing page components
* Record tracks event when marketing welcome dismissed
* Match design width
* Add welcome image and initial styles
* Use gridicon for close button
* Fix whitespace
* Add PluginsHelper::get_plugin_data()
* Add initial Marketing\InstalledExtensions class
* Preload installed marketing extensions data
* Tweak extension statuses
* Add InstalledExtensionRow component
* Add initial extension data to InstalledExtensions card
* Refactor PluginsHelper::get_plugin_data method
Using the new get_plugin_path_from_slug method
* Ensure get_plugins() function is available for PluginsHelper
* Simplify using PluginsHelper method
* Add MailChimp configured status logic
* Add links to InstalledExtensionRow component
* Add key prop to extensions list
* Setup styles for InstalledExtensions card
* Display nothing if no installed extensions
* Add InstalledExtensions::get_allowed_plugins()
* Setup Marketing Overview API controller
* Add /activate-plugin marketing endpoint
* Add more extensions URL props
* Add Facebook extension configured status logic
* Update Facebook extension URL props
* Fix extenion data logic
* Move component into it’s own directory
* Setup /marketing/overview/recommended endpoint
* Initial marketing page card header styles
* Add basic extension data to RecommendedExtensions
* Use color as variable
* Tweak card header padding for design
* Add basic styling to RecommendedExtensions card
* settingsUrl is not available if the plugin is not active
* Add /marketing/overview/installed-plugins REST endpoint
* Add basic activation functionality to InstalledExtensions component
* Don’t throw error on success
* Add MVP data store for installed extensions card
* Add core dark blue color variable
* Add styles for installed extensions card
* Move knowledge-base component to its own directory
* Pull recommended marketing plugins from remote test site
* Hide description when configured
As per design
* Tweak colors based on design
* Finish off styling for RecommendedExtensions
* Limit recommended extensions to 6 items
* Add error handling to RecommendedExtensions card
* Rename ‘copy’ extension prop
* Add marketing button component to match design
* Create ProductIcon component for marketing
* Add InstalledExtension icons
* Fix icon image paths
* Add ProductIcon to InstallExtensionRow
* Final styling to installed extensions card row
* Knowledge base card placeholders
* Fix missing icons when plugin not activated
* Remove logging
* Tweak array structure to ensure we have an array in JS
and not an object
* Refactor KnowledgeBase marketing component
- We don’t need loop through every post when rendering, just pick the posts we need
- Remove unused classes
* Move padding from each slide to the container
* Improve slider animations by absolute positioning the slides
* Reduce the slider animation timeout and add a note
* Add in-app purchase flow url params for recommended extensions
* Fix slider animation
* Reset slider height on window resize
* Short slider animation, fix double margin on smaller screens
* Add initial marketing/knowledge-base endpoint
* Pull knowledge base posts from API
* Rename welcome card dismiss tracks event
* Record event on recommended product click
* Recond onclick events for installed extensions card
* Record event when carousel navigation clicked
* img elements must have an alt prop
* Remove import that is never used
* use camelCase
* Decode HTML entities from API call
* Remove unused container div
* Add card loading state
* Add images to knowledge base card
* Link knowledge base posts
* Use the Pagination component rather than duplicate it’s functionality
* Clean up and rename knowledge base slider
* Clean knowledge base CSS and update responsive styles for single post slide
* Add a README for button component
* Add README for product icon component
* Add initial readme for Slider component
* Add correct image sizes to knowledge base slider, finalize styles
* Fix extension link urls
* Resolve some code formatting issue
* Bind class click methods to this
* Wrap nodes in Fragment
* Fix wccom-back path
* Add placeholder author and gravatar
Default avatar url size returned from the API is currently set to 96 so I’ve done a simple replace with 16
* Fix style-lint expected new line
* Add docblock for get_knowledge_base_posts()
* Setup data store for marketing to handle installedExtensions card
* Fix function names
“Activating” not “installing”
* Move welcome card component to its own dir
* IconButton component is going to be deprecated
ref: https://github.com/WordPress/gutenberg/pull/19299
* Support multiple activating plugins in the data store
* Rename extension to plugin for consistency
* Add propTypes to component
* Rename data-store/ to data/
* Fix import paths
* Extract isActivatingPlugin logic into datastore
* Move data store selectors into own file
* POST requests are not cached
* Export apiFetch action
* Don’t wrap API response in object
* Implement data store for recommended extensions
* Implement data store for marketing knowledge base
* Tidy getRecommendedPlugins resolver
* Try a cross browser cover/crop image effect to fit proposed design
And help fit longer titles in
* Add caught errors to handler
* Adjust positioning so watermater is displayed
* InstalledExtensions phpcs fixes
* Marketing phpcs fixes
* Alignment fix
* MarketingOverview phpcs fixes
* Missing full stop
* Update breadcrumbs to use new approach
* Fix style lint issues
* Record `marketing_knowledge_article` track event on knowledge base post click
* Import apiFetch and controls from @wordpress/data-controls
* Hex color to lowercase
* Remove duplicate method after rebase
* Use new showPageArrowsLabel rather than hide with CSS
* Fix blurry avatars on hidpi displays
* Hide avatar if URL is falsy
* Replace test author data with live data
* Combine conditionals into ternary
* Combine conditionals into ternary
* Simplify class column logic
* Only preload option and component settings in the admin
* Fix isActivatingPlugin not updating
Component was not re-rendeding.
* Use querySelector over getElementsByClassName
* Hide Marketing Welcome Card immediately on click
* Use create-a-ticket url for supportUrl and make that the default
* Add getInstalledPlugins resolver with preloaded data
* Revert "Add getInstalledPlugins resolver with preloaded data"
This reverts commit b8b127ec6411bef15616576b3bb189dc31777c13.
* Load plugin data in a separate request after activation
* Update welcome image
* Don’t return plugin data in the activation request.
* A space is required before closing bracket
* Update Jest config to gracefully handle static assets
Ref: https://jestjs.io/docs/en/webpack#handling-static-assets
* Remove unused onExit property
* Remove placeholder README
* Use prop directly
* yield createNotice
* Add note to indicate which Category
* Increase transient time to 3 days
* Use $gap-small
* Add proptype
* Add debounce to slider height resize listener
* Clean up isLoading logic
* Dont show image elements if image data is empty
* Open knowledge base posts in a new window
* Add “noreferrer”
* Turn the tab on in all env
Co-authored-by: Daniel Bitzer <danielbitzer@gmail.com>
* Add feature flag for wcpay (https://github.com/woocommerce/woocommerce-admin/pull/3958)
* Add card to payments task for WooCommerce Payments (https://github.com/woocommerce/woocommerce-admin/pull/3978)
* Add card to payments task for WooCommerce Payments
* Add missing plugin and settings PHP constants for woocommerce payments
* Add endpoint to return url to kick off wcpay
* Fix incorrect option name
* I can haz purple with white text, plz
* Linkify TOS, settings
* Recommend wcpay when visible; move wcpay to list top
* Test for wcpay feature flag
* Improved handling of feature flag
* If the user is an agency, include wcpay docs link on card
* Reverse agency logic, LOL
* Camel case fillRule etc
* Turn off wcpay for core and plugin for now
Co-authored-by: David Stone <david@nnucomputerwhiz.com>
Co-authored-by: Chris Shultz <chris.shultz@automattic.com>
Co-authored-by: Harris Wong <harris.wong@a8c.com>
Omit validation error (and resulting disabled "Continue" button) on the other platform name text field, in an edge case where the field is first required but value is missing, and then no longer required.
* Abstract WP plugin code into a PluginsHelper class
We plan to use these methods in the Marketing tab.
* Add PluginsHelper::is_plugin_active()
* Add PluginsHelper::is_plugin_installed()
* Add PluginsHelper::get_plugin_data()
* Add PluginsHelper::get_plugin_path_from_slug()
* Refactor PluginsHelper::get_plugin_data method
Using the new get_plugin_path_from_slug method
* Refactor is_plugin_installed and is_plugin_active
Also adds support for plugin slugs or paths as parameters.
* Ensure get_plugins() function is available for PluginsHelper
* Ensure plugin path is a string before checking if installed/active
* PHPCS fixes
* Add initial unit tests for PluginsHelper
* Check plugin data array keys rather than all values
Will make it less fragile when Woo plugin data changes
* Fix typos
Co-authored-by: Daniel Bitzer <danielbitzer@gmail.com>
* Added note to Personalize Store
Added note to Personalize Store, 5 days after registration or when the user completes the task list.
* Lint repeared
Lint error repeared.
* Moved homepage_id < 0 check to OnboardingTasks.php
Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>