Commit Graph

8581 Commits

Author SHA1 Message Date
Jorge A. Torres 44ce3bd0c3
Make sure the `woocommerce` page hook name remains untranslated (#35695)
* Make sure the WooCommerce page hook is untranslated

This works around a WP core bug, and addresses compatibility issues where WC core or 3rd party code expect the pagename or screen ID for one of our submenu pages to remain fixed despite translations.

* Add changelog

* Make PHPCS happy
2022-11-24 04:16:56 -08:00
Kevin Brent f7f3f01be0
Fix attribute taxonomy sort order meta key (#34645)
Fix attribute taxonomy sort order meta key for improved consistency.

* whoops - close array for order meta key update

* Changelog.

* Update phpcs annotation.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-11-23 12:50:25 -08:00
Marco Almeida 085149ad82
Add $formatted_destination as an argument to the woocommerce_cart_no_shipping_available_html filter (#30723)
Add $formatted_destination as an argument to the woocommerce_cart_no_shipping_available_html filter.

Developers should be able to access the $formatted_destination variable directly in order to return a new string to the filter including that address.

* Add docblock and changelog for woocommerce_cart_no_shipping_available_html tweak.

* Bump version tag for cart-shipping template.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-11-23 11:22:51 -08:00
Joshua T Flowers 527249f754
Fix unread notes count in inbox panel (#35396)
* Mark note as read when viewing

* Show unread note count

* Add ability to fetch read or unread notes

* Count unread notes on server side to avoid pagination limits

* Add changelog entry

* Add data changelog entry

* Add check for note actions before checking length

* Add changelog entry

* Mark note as read after 3s delay
2022-11-23 08:52:46 -08:00
nigeljamesstevenson c35d62461e
Update/a2p Consolidate country data in api-core-tests (#35557)
* Consolidate country data

* update test data

* remove upper case files

* remove upper case files

* remove upper case files

* update country data tests

* countries states updates for local

* revert settings-crud.test
2022-11-23 08:04:37 -07:00
Roy Ho fd7c728689
Revert "Add pre build script to delete assets" (#35693)
Revert "Add pre build script to delete assets (#35627)"

This reverts commit 4770123fa3.
2022-11-23 06:38:28 -08:00
Kaushik Somaiya 102fabbee0
Fix missing tooltip in admin orders table. Fixes #33228 (#35638)
Co-authored-by: Kaushik Somaiya <kaushiksomaiya@Kaushiks-MacBook-Pro.local>
Co-authored-by: Néstor Soriano <konamiman@konamiman.com>
2022-11-23 12:06:27 +01:00
Jonathan Lane fd7fc355fa
Fix/e2e environment test failures (#35679) 2022-11-22 16:16:42 -07:00
Maikel David Pérez Gómez 29b9c691cd
Fix/unsaved prompt (#35657)
* Set initial values prop from reset form function as optional

* Fix unsaved modal propmt to not be shown during form submission

* Reset form on save draft and before navigation starts

* Add comments ssuggestions
2022-11-22 11:56:27 -03:00
Fernando Marichal 6ac092e498
Add tracks events to a few sections (#35262)
* Add tracks events

* Add changelog

* Add more tracks events

# Conflicts:
#	plugins/woocommerce-admin/client/products/fields/attribute-field/add-attribute-modal.tsx
#	plugins/woocommerce-admin/client/products/sections/product-shipping-section.tsx

* Fix name

* Fix duplicated event

* Add select as cover event

* Add cancel shipping class creation

* Rename tracks events

# Conflicts:
#	plugins/woocommerce-admin/client/products/sections/product-shipping-section.tsx

* Add const for tracks event name

* Rename event

* Rename events

* Remove `product_modal_new_shipping_class_cancel_button` trancks event

* Rename `product_add_first_attribute_button_click` event

* Fix method

* Fix confirmation modal events

* Rename `product_add_attributes_modal_add_button_click` event

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-11-22 11:30:44 -03:00
Sam Seay 03dbab0edd
Fix some bugs in syncpack configuration (#35651)
* Fix syncpack config

* Loosen the matched version for typescript eslint

* Add changelog entries

* Update lockfile
2022-11-22 12:06:47 +13:00
Roy Ho 4770123fa3
Add pre build script to delete assets (#35627)
* Add pre build script to delete assets

* Chain the script instead

* Add the cleanup dependency to turbo config

* Add assets cleanup for build zip command
2022-11-21 12:05:26 -08:00
louwie17 7ec3210b8b
Create attribute within the new product MVP (#35100)
* Add initial add new option

* Hook in create attribute modal to add attribute field

* Add unit tests for the create attribute modal

* Add extra test to attribute input field

* Add changelog

* Add custom attribute term input field and support for custom attributes

* Fix tets

* Add track for custom attribute creation

* Fix changes after merge conflict

* Revert one change

* Fix lint error

* Seperate out some logic and make use of null as empty object versus id: undefined

* Add isNewAttributeListItem helper function

* Make use of helper function for create new markup
2022-11-21 10:56:46 -04:00
github-actions[bot] 9c83a07145
Prep trunk for 7.3 cycle (#35621)
Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-11-19 08:21:49 +13:00
github-actions[bot] fc187fbafe
Release: Remove 7.2 change files (#35632)
Delete changelog files from 7.2 release.

Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
2022-11-19 08:01:15 +13:00
Joshua T Flowers 6f7cc707c7
Remove welcome to woocommerce for store users note (#35342)
* Remove welcome to woocommerce store note

* Add changelog entry
2022-11-18 09:51:35 -08:00
Joshua T Flowers b2f66e3cf4
Add breadcrumbs to new product management experience (#35596)
* Add product breadcrumbs component

* Add breadcrumb styling

* Truncate breadcrumbs when more than 3

* Add tests around product breadcrumbs

* Add changelog entry

* Convert indentation to tabs

* Add key to mapped breadcrumb items
2022-11-18 09:51:01 -08:00
Nathan Silveira 6d4c1b3b8a
Adapt the width of the pricing fields (#35545)
* Add css class to change the input width based on the screen's width

* Changelog

* Move class from pricing-section.scss to product-page.scss and use breakpoint 960px mixin

* Move className from currencyInputProps to InputControl

* Improve changelog

* Move 'half-width-field' class to currencyInputProps instead of adding it manually for the two currency fields

* Add 'half-width-field' class to SKU and Shipping Class

Sent as a parameter to getInputProps and getSelectControlProps to avoid overwriting any additional className

* Update changelog
2022-11-18 13:03:10 -03:00
Maikel David Pérez Gómez dba6d337f7
Add a confirmation modal when the user tries to navigate away with unsaved changes (#35625)
* Add a confirmation modal when the user tries to navigate away with unsaved changes

* Add support for react router navigation

* Fix unit tests
2022-11-18 11:54:59 -03:00
Roy Ho 0f6942849f
Dev/add back asset sources (#35624)
* Copy scss files to build

* Add changelog
2022-11-18 06:14:25 -08:00
Joshua T Flowers ba91c94ca9
Check if blocks have been added to rich text editors before updating value (#35626)
* Check if blocks have been added to rich text editors before updating value

* Add changelog entry
2022-11-17 10:06:10 -08:00
Maikel David Pérez Gómez fc56dcf6e9
Add/35173 category field improvements (#35606)
* Add experimental open menu when user click the select control input element

* Open categories menu list when the user click the category field

* Fix linter error

* Move open menu from click to focus event

* Fix linter errors
2022-11-17 15:04:40 -03:00
Joshua T Flowers 233e23704f
Add product settings menu to new product management experience (#35592)
* Add icons

* Add classic editor url

* Remove welcome guide link and icon

* Add initial settings menu

* Fix up button styling

* Move product settings to its own folder

* Remove unnecessary registerPlugin call

* Use number type control for menu order field

* Add tests around product settings component

* Allow reviews by default on all new products

* Alphabetize product properties

* Add changelog entry

* Add data changelog entry

* Convert indentation to tabs

* Fix up scss linting errors

* Remove whitespace
2022-11-17 09:59:51 -08:00
Matt Sherman 19058ed17c
Fix the `wcadmin_product_update` Tracks event `menu_order` custom property value (#35605) 2022-11-17 10:32:27 -05:00
Adrian Duffell ba0994fda5
Deploy the stacked layout in the Products Task experiment (#35611)
* Deploy stacked layout in product task experiment

* Add changelog

* Remove unused import
2022-11-17 22:48:14 +08:00
Alex Pantechovskis baa1c120bc
Do not use $_POST directly in validate_checkout (#35329)
Avoid direct use of $_POST from within the validate_checkout() method.

* Changelog.

* Address some of the undocumented hook errors flagged by our linting check.

This does not address all of the undocumented hooks (there are many in this file), just the ones flagged by the GitHub Actions code sniff check. This is an effort to unblock the PR, which we otherwise cannot merge at present.

* Add missing `@since` tags (satisfy linter).

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-11-17 04:39:31 -08:00
Yehuda Hassine 9337b3b5a6
fix get customer tokens limit (#29850)
Make it easier to support many payment methods (within My Account > Payment Methods page).

* Update includes/class-wc-payment-tokens.php

Better backward-compatible by @jonathansadowski

Co-authored-by: jonathansadowski <jonathansadowski@users.noreply.github.com>

* Add docblock for new filter `woocommerce_get_customer_payment_tokens_limit`.

* Add changelog.

Co-authored-by: Yehuda Hassine <yehuda@myinbox.in>
Co-authored-by: jonathansadowski <jonathansadowski@users.noreply.github.com>
Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-11-17 03:55:12 -08:00
SamirMahmudzade abcd2a799a
Update the Azerbaijani manat symbol AZN (#30605)
Update the Azerbaijani manat symbol AZN

* Rebase, update currecy symbol (from mathematical pitchfork to manat).
* Add changelog.
* Use Azerbaijani manat symbol instead of similar mathematical character.
* Update data crud test for the AZN currency symbol.
* Update currency settings for API tests.

Co-authored-by: barryhughes <3594411+barryhughes@users.noreply.github.com>
2022-11-16 23:07:15 -08:00
louwie17 1550806efc
Add/34 create new category field modal (#35132)
* Add initial category field component with new typeahead

Move search logic to useCategorySearch hook

Add initial add new category logic

Add parent category field to add new category modal

Adding some debug changes

Update category control to make use of internal selectItem function of select control

Add changelogs

Update pagesize back to 100

Add placeholder

Empty placeholder

Fix input and icon sizes

Fix input underline

Add max height and scroll to category dropdown

Add sorting of category items

Auto open parents when traversing up the tree using arrow keys

Add several comments

Add some initial unit tests for the category field component

Add tests for useCategorySearch hook and fixed minor bug

Update styling and autoselect parent if child is selected

Fix styling issues for the select control dropdown inside a modal

Fix issue with creating new category with parent

Add function comment and fixed border styling

* Fix up some issues after the rebase

* Some small fixes for the Category creation

* Fix up some styling issues around the add-new-item

* Add changelogs

* Remove unneeded export of toggle button props

* Fix create category error and tests in attribute field

* Fix some minor bugs and styling changes that came up during PR feedback

* Fix tests

* Make use of $gap variable for css
2022-11-16 12:30:42 -04:00
Joshua T Flowers 7bff5cbb6b
Add product status badge to product form header (#35460)
* Add product status badge

* Update status method to return keys

* Add tests around product status

* Add styling to badge

* Add changelog entry

* Change product status keys to enum

* Add enum return type to product status function

* Fix up lint errors

* Convert indentation to tabs
2022-11-16 08:03:39 -08:00
Joshua T Flowers 2297787a4f
Add contextual product more menu (#35447)
* Add icons

* Add product more menu

* Add classic editor url

* Update header and more menu styles

* Update dropdown menu label

* Add changelog entry

* Remove welcome guide link and icon

* Remove errant import

* Remove unnecessary plugin registration
2022-11-16 07:02:45 -08:00
Maikel David Pérez Gómez 0482860c74
Fix bg color that was not covering the full page (#35476) 2022-11-16 10:39:56 -03:00
Daniel Mallory ad80ff7134
WCPay Experiment: Create an Inbox Note if user wants more info on WCPay (#35581) 2022-11-16 13:22:16 +00:00
Néstor Soriano 42d2260ca6
Fix custom_orders_table_usage_is_enabled returning true when HPOS feature is disabled (#35597)
* custom_orders_table_usage_is_enabled returns now false if feature is disabled

* Add changelog file
2022-11-16 01:03:45 -08:00
Joshua T Flowers 23ca8d6297
Add product title to header when available (#35431)
* Move shared product header components to separate file

* Fill header title with product name

* Create method to get product title

* Add tests around title

* Add changelog entry

* Remove unnecessary plugin registration
2022-11-15 11:19:58 -08:00
timur987 8dc954d54b
Feature: Add the In-App Marketplace Tour (#35278)
Co-authored-by: Michal Iwanow <4765119+mcliwanow@users.noreply.github.com>
2022-11-15 11:12:17 +01:00
Daniel Dudzic f9dacb78a6
FSE: Fix icon fonts not being loaded in the Site Editor (#35532)
* Site Editor: Fix WooCommerce icons in the Site Editor

* Site Editor: Fix WooCommerce icons not loading in the site editor.

* Add additional FSE theme check
2022-11-15 00:58:40 -08:00
Sam Seay 63242cfa62
Remove duplicated API code folder in woocommerce-beta-tester (#35549) 2022-11-15 13:58:45 +13:00
Matt Sherman 5b06618a6f
Add scheduled sale fields (#34538)
* Add scheduled sale fields to product form
* Close DateTimePickerControl's dropdown when blurring from input.
* Log when onChange is called for Controlled stories
* Handle when input changes occur but the end date is the same
* Fix DateTimePickerControl usage when uncontrolled
* Fix handling when blur happens before debounced onChange
2022-11-14 21:03:13 +00:00
Timstreep beb2871b8d
Update readme.txt (#35573)
Co-authored-by: Peter Fabian <peter.fabian.github@gmail.com>
2022-11-14 21:04:19 +01:00
Herman dda14302fa
Add/source param to get subscriptions call (#35051)
* Add source param for subscription endpoint calls

- Adds an optional $source argument to the WC_Helper_API::url() method
- Get URL of page making WC_Helper::get-subscripitonts() request and add a
  source arg to the WC_Helper_API::get() request made by that method
- Pass that source arg to the WC_Helper_API::url() methd from
  WC_Helper_API::get()

* Add changelog file

* Use sripos instead of preg_match in WC_Helper::get_subscriptions()

- Update "source" argument name across methods to "query_string" to be
  more generic
- Use separate variables to make it clear the URI of the requesting
  page, and the value passed as the source query string are different

* Add @param declaration to function comment

* Address PHPCS issues

Co-authored-by: Jorge A. Torres <jorge.torres@automattic.com>
2022-11-14 05:52:35 -08:00
Alba Rincón efcbe197ea
Update woocommerce-blocks to 8.9.1 (#35564) 2022-11-14 11:33:10 +01:00
Jorge A. Torres bddb65699b
[HPOS] Implement "Empty Trash" functionality in list table (#35489) 2022-11-14 09:34:59 +01:00
nigeljamesstevenson 736593ef15
update/a2p update `api-core-tests` to run against both CI test env and JN (#35522)
* updates to allow tests to run against both CI test env and JN

* update customer data file

* comment uddates

* baseURL update

* update settings data

* Update plugins/woocommerce/tests/api-core-tests/playwright.config.js

Co-authored-by: Greg <71906536+zhongruige@users.noreply.github.com>

* Update plugins/woocommerce/tests/api-core-tests/tests/customers/customers-crud.test.js

Co-authored-by: Greg <71906536+zhongruige@users.noreply.github.com>

* Update plugins/woocommerce/tests/api-core-tests/playwright.config.js

Co-authored-by: Greg <71906536+zhongruige@users.noreply.github.com>

* updates from code review

* remove erroneous space

* remove comments

* updates for Localhost, LocalWP and JN

Co-authored-by: Greg <71906536+zhongruige@users.noreply.github.com>
2022-11-10 16:23:28 -07:00
jonathansadowski 63f639b2b1
Post-7.1 / release prep for 7.2 (#35547)
* Update class-woocommerce.php for 7.2

* Update stable tag in readme.txt

* Update version in woocommerce.php

* Update version in composer.json

* Update version in package.json
2022-11-10 17:07:07 -06:00
jonathansadowski 57a5dd4b4e
Revert "Update php version to 7.4" (#35546)
Revert "Update php version to 7.4 (#35528)"

This reverts commit 0b52411ff7.
2022-11-10 16:47:19 -06:00
Panos (Panagiotis Synetos) 7cd1a03043
[HPOS] Move hook `woocommerce_before_delete_order` before `woocommerce_before_delete_order` (#35517)
🧑‍💻 Move hook woocommerce_before_delete_order before deleting order
2022-11-10 09:39:26 -08:00
jonathansadowski 0b52411ff7
Update php version to 7.4 (#35528)
* Update php version in woocommerce.php

* Update php version in readme.txt

* Create update-php-7.4
2022-11-09 10:53:08 -06:00
Alba Rincón 91da0a15df
Update WooCommerce blocks package to 8.9.0 (#35521) 2022-11-09 09:59:08 +01:00
Jorge A. Torres 082f318da4
[HPOS] Add order data store info to SSR (#35487)
Add info on order datastore (and sync) to SSR

* Add changelog

* Make PHPCS happy

* Update plugins/woocommerce/includes/admin/views/html-admin-page-status-report.php

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>

* Remove unnecessary import

Co-authored-by: Barry Hughes <3594411+barryhughes@users.noreply.github.com>
2022-11-04 11:35:19 -07:00