* Return formatted cost and sales price for MarketingCampaigns.
* Display formatted cost and sales number in Campaigns card.
* Use price formatting.
* Format decimal places based on currency.
* Add changelog.
* Fix type issue is useCampaigns.test.ts.
* Use wp_strip_all_tags to respect currency symbol positioning settings.
Without wp_strip_all_tags, the result contains <bdi> element, and it causes browser to show the currency symbol in unexpected unwanted position.
* Fix PHP linting issue.
* Fix tests in useCampaigns.test.ts.
* Use html_entity_decode to remove dangerouslySetInnerHTML usage.
* Remove unneeded code formatting in Campaigns.tsx.
* Add explanation comment for `get_formatted_price`.
* Fix PHP lint error.
* Use map instead of filter to get price format.
* Add code comment.
* Get currency info based on user locale or default locale.
* Use locales in locale-info.php instead of currency-info.php.
Co-authored-by: Bartosz Budzanowski <bartosz.budzanowski@automattic.com>
* Code formatting and fix code comment.
* Fix lint errors.
---------
Co-authored-by: Bartosz Budzanowski <bartosz.budzanowski@automattic.com>
* CYS - Core: install font when user clicks opt-in
* remove debugger
* CYS - Core: fix wp-admin page visible when click on start designing
* Add changefile(s) from automation for the following project(s): woocommerce
* use sendEvent instead of redirect
* Add changefile(s) from automation for the following project(s): woocommerce
* not show wp-admin after the click on the dialog button
* use sendEventToIntroMachine
* fix font installation
* fix eslint error
* fix install font phase when the iframe is not loaded
* remove not necessary async
---------
Co-authored-by: github-actions <github-actions@github.com>
* Add basic wp dropdown component
* use getAdminLink
* Add styling based on state
* Add changefile(s) from automation for the following project(s): woocommerce
* update store page only text
* Add better 'for now' comment
* translate links
* remove private repo link from comment
* lint
---------
Co-authored-by: github-actions <github-actions@github.com>
* Use theme color to style the theme badge component
* Add changefile(s) from automation for the following project(s): woocommerce
* Fix linting errors
---------
Co-authored-by: github-actions <github-actions@github.com>
* Ensure field is on schema before sanitizing/validating against it
* Sanitize the key as a text field if we don't know what it is
* Add changelog
* Revert "Sanitize the key as a text field if we don't know what it is"
This reverts commit 9f5071051c.
* Revert "Ensure field is on schema before sanitizing/validating against it"
This reverts commit 109fbe766c.
* Omit unknown items in sanization
* add test doc block
---------
Co-authored-by: Nadir Seghir <nadir.seghir@gmail.com>
* Add dummy Force Page Reload control to Inspector Advanced Control
* Add enhancedPagination attribute that decides if client side navigation is enabled
* Consume the enhancedPagination attribute
* Force client side navigation when incompatible blocks detected
* Dummy util to detect incompatible blocks
* Detect incompatible blocks in the Editor
* Switch to WordPress Interactivity package in Product Collection
* Add initial implementation of the incompatible blocks detection in frontend
* Remove leftover
* Revert to using internal version of interactivity API
* There's no Interactivity store config available in the internal Interactivity implementation so remove it
* Disable client side navigation if the incompatible block is detected
* Add default attribute value
* Switch from enmhancedPagination attribute to forcePageReload
* Fixed some misclicked line order change
* Switch from enhancedPagination to forcePageReload in PHP code
* Apply the correct filter
* Fix the incorrect condition to detect incompatible block
* Initial implementation of orange dot to bring attention
* Cleanup
* Remove the orange dot indicator
* Refactor checking for unsupported blocks
* Add changelog
* Fix PHP lint errors
* Bring back empty line at the end of pnpm-lock
* Bring pnpm-lock.yaml file to original state
* Fix incorrect function call
* Add visibility description to function
* Switch private method to public
* More linted fixes
Fires an action after a customer has logged in, and their guest session id has been deleted with its data migrated to a customer id. This hook gives extensions the chance to connect the old session id to the customer id, if the key is being used externally.
Fixes#44852
Updates the markup used to generate the Refunds page so that it is valid, semantic HTML, which in turn fixes an alignment issue.
Fixes#45213
---------
Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
Adds a new filter to the legacy Active Product Filters widget that allows the attribute names to be modified.
---------
Co-authored-by: Corey McKrill <916023+coreymckrill@users.noreply.github.com>
* Disable block interactions within the editor
* Add changefile(s) from automation for the following project(s): woocommerce-blocks
---------
Co-authored-by: github-actions <github-actions@github.com>
* Pass isPreview prop to inner blocks of the Product Filter block
* Add logic to render preview block when in Preview mode
* Add changefile(s) from automation for the following project(s): woocommerce-blocks
---------
Co-authored-by: github-actions <github-actions@github.com>
* CYS - fix warning
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* add snapshot tracking
* add changelog
* address feedback
* Add changefile(s) from automation for the following project(s): woocommerce
* update changelog
* Add changefile(s) from automation for the following project(s): woocommerce
* remove the extra changelog
---------
Co-authored-by: github-actions <github-actions@github.com>
* Add get_action_url for Payments task
* Check if plugin active before redirecting to connect page
* Add changelog
* Fix linting issues
* Point payments task to welcome page when WCPay incentive active
* Point WooPayments installed task to Connect page
* Rename WooPayments to payments
* Add from query arg
* Adjust payments task URL logic to account for suggestions logic
* Fix for partially onboarded accounts
* Replace Get paid with WooPayments
* Add new test for unsupported countries
* Add missing api definition
* Add missing baseURL
* Maybe change order of tests to fix failing test
* Revert changes to package.json (error in push)
---------
Co-authored-by: Vlad Olaru <vlad@pixelgrade.com>
Co-authored-by: oaratovskyi <oleksandr.aratovskyi@automattic.com>
* Update the transitional page.
* Update icons
* Remove unnecessary div class
* Update the styles for the transitional page.
* remove the editor param
* conditionally display the survey button
* Additional layout changes
* Streamline the classes for the icons
* Import brush and tag from wordpress/icons
* delete the custom icons from Woo as they already exist on wordpress/icons and can be imported from there.
* Update styles for adding support to mobile view.
* Update the lesson-plan icon.
* Add changefile(s) from automation for the following project(s): woocommerce
* Update e2e tests to account for the changes made to the transitional page.
---------
Co-authored-by: github-actions <github-actions@github.com>
* Install and activate the TT4 before any other step on the loader
* Show the loader while activating the theme
* Try running steps together in parallel
* Try to run install and global styles in the same function
* Handle when the active theme returns null
* Add changefile(s) from automation for the following project(s): woocommerce
* Add retries and types to fix lint errors
* Fix lint errors
* Fix more lint errors
---------
Co-authored-by: github-actions <github-actions@github.com>
* CYS - Core: fix wp-admin page visible when click on start designing
* Add changefile(s) from automation for the following project(s): woocommerce
* not show wp-admin after the click on the dialog button
---------
Co-authored-by: github-actions <github-actions@github.com>
* Update code freeze GH Actions workflow to upload the woocommerce packages to the R2 bucket on code freeze.
* Make the job that uploads WooCommerce release packages to the R2 bucket independent from the Slack integration in release-code-freeze.yml workflow.
* support running A/B tests in frontend
* add optional chaining
* Add changefile(s) from automation for the following project(s): @woocommerce/explat
* switch to shared variable
* fix tests
---------
Co-authored-by: github-actions <github-actions@github.com>
Since the product collection block uses the interactivity router,
it reloads the page in the background and replaces sections
with a `data-wc-navigation-id` set. This adds the attribute
to the count block so that it can also live reload regardless
of where it is in the tree.
* Disable checkout menu when checkout block is default
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Match template based on different attributes besides product types
* Do not hard-code postType
* Refactor code
* Handle isResolving from useEntityRecord
* Refactor useProductTemplate
* Handle null value in `useProductTemplate`
* Add additional-checkout-fields-test-helper wp-env plugin
* Ensure Checkout page waits for email to be visible before filling
* Handle additional fields in checkout page utils
* Add test for filling additional checkout fields
* Add additional check for gov-id validation
* Close context used for plugin-checking
* Update types for additional fields to be key/value objects
* Check billing gov-id is different to shipping one
* Move additional fields plugin to inline with checkout tests
* Use additional fields plugin from local dir
* Await email input to check Checkout block is loaded
* Add test to verify error message shows when leaving a field blank
* Update comment
* Add test for checking/unchecking checkboxes
* Update check in additional field test plugin
* Change fields multiple times in one test
* Add server-side validation tests
* Get exact matches for checkout form fields
* Remove unnecessarily translated strings
* update hook in test plugin to compare to confirmation gov id
* Fill in gov ID confirmation field
* Register a field of each type in each location
* Don't validate field unless both are filled
* Fill additional fields and check their values
* Fill additional fields
* Check select values in order confirmation
* Change the values of all field types multiple times
* Make checkout wait until not calculating before submitting
* Update tests to use all additional field types
* Blur after editing select box
* Add customer area checks
* Check shipping isn't calculating before submitting
* Add merchant-side tests for additional checkout fields
* Ensure customer data is done updating before submitting
* use waitForFunction to check for updating shipping
* Add changelog
* Ensure fields are blurred before pressing button
* Update validation error check
* Add test for logged out shopper
* make specific function to wait for checkout to be finished updating
* Add test to ensure fields are saved across orders
* Add sanitize and validate callbacks to gov id fields
* Make purchase type select field required
* Add sanitization test
* Use experimental function in test plugin
* Add standalone sanitization filter test
* Update testing plugin to use new and renamed filters
* Fix typo
* Move empty value test to logged out shopper block and check empty val
* Update tests to include tests for new validation/sanitization filters
* Add verifyAdditionalFieldsDetails function to checkout page
* Use new verifyAdditionalFieldsDetails function to improve readability
* Update second test to use new function to improve readability
* Update third test to improve readability
* Update fourth function to improve readability
* Update fourth test to improve readability
* Update guest shopper test to be more readable
* Update helper function to only return value not assert
* Remove check causing test to fail in CI
* Make check for guest shopper same as logged in
* Move guest shopper tests to their own file
* Ensure unchecking checkbox works OK
* Adding accessible markup to sale price. See #31099
This PR adds accessible markup to the sale price.
A user who only uses screen reader software can now hear and understand the original price as well as the current price.
This is important for accessibility.
Full issue: https://github.com/woocommerce/woocommerce/issues/31099
* Improving sale price string formatting & localization #31099
This PR merges in feedback from the WooCommerce team.
* Improving string translation & output. Giving RTL languages more customization with the price in the translatable string.
* Formatting regular price & sale price at the top and then inserting into the HTML below. This prevents some sloppy logic where you might print out a blank del or ins tag.
* Swapping esc_html & sprintf #31099
Reversed the esc_html() and sprintf(). This is intentional because if translations accidentally include some HTML, that could break things.
Also, stripping HTML tags in $formatted_regular_price so that the end result in the screen-reader-text span is just plain text.
* Adjusting white space #31099
Mostly removing white space for the lint checker
* Adding translator comments #31099
Adding translator comments for lint
* Add changelog
* Fix some PHPCS violations
* Fix unit tests
* Adjust E2E test
---------
Co-authored-by: Jorge Torres <jorge.torres@automattic.com>
* `wc hpos diff` command enhancements
* Add support for partial backfills to LegacyDataHandler
* Add unit tests
* Add support for partial backfills to `wp wc hpos backfill` CLI tool
* Add changelog
* Augment update_order_from_object() with args parameter
* Implement update_order_from_object() for HPOS
* Simplify partial backfill logic in LegacyDataHandler
* Move prop name validation to legacy data handler
* Apply changes to order before passing to backfill functions
* Simplify update_order_from_object() in HPOS datastore
* Simplify order update from object across datastores
* Undo change
* Minor fix for CPT version (which only takes order differences into account)
* Improve readability around ‘woocommerce_orders_table_datastore_should_save_after_meta_change’ filter
* Commit docblock suggestion
* PHPCS fixes
* Enhance unit test
* Add remove custom field for the new product editor
* Add changelog file
* Show add button when the custom fields are empty
* Ensures to always convert the metas into a string array since it can be anything
* Add changelog file
* Switch from "invoice" to "order details" in our emails.
* Revise default order details email subject text.
* Revise default order details header text.
* Bring E2E check up-to-date with latest text revision.
* Update API tests to match order detail email changes.
* Fix typo
---------
Co-authored-by: Jorge Torres <jorge.torres@automattic.com>
* Bump woocommerce-sniffs to 1.0.0 for WPCS 3.0 support
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Add json config files to ci changes config
* Add admin config to Woo plugin ci config
* Add changefile(s) from automation for the following project(s): woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>