* Remove duplicate
* Add is-coming-soon-page endpoint
* Render invalid cache warning
* Use meta tag instead
* Add url for debug purpose
* Use a different copy for the congrats page when the cache is still shown
* Clean up unused codes
* Guard the api with permission
* Add changefile(s) from automation for the following project(s): woocommerce
* Reuse $is_fse_theme
* Lint fixes
* Update 48586-update-48516-detect-cache-when-launching-store
* Add changefile(s) from automation for the following project(s): woocommerce
* Add changefile(s) from automation for the following project(s): woocommerce
* Update plugins/woocommerce/changelog/48586-update-48516-detect-cache-when-launching-store
Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
* Add changefile(s) from automation for the following project(s): woocommerce
* changed to js method
* Add changefile(s) from automation for the following project(s): @woocommerce/data, woocommerce
* empty commit to trigger CI
* Add changefile(s) from automation for the following project(s): @woocommerce/data, woocommerce
* empty commit to trigger CI
---------
Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
Co-authored-by: rjchow <me@rjchow.com>
* show terms optimistically
* define values as TokenItem array
* introduce TokenItem type
* add token animation when adding
* terms could be undefined
* remove unused action
* changelog
* minor doc enhancements
* rename consts
* simplify items selector
* clean the temporary items, one by one
* do not pass selectedTerms when adding a new one
* pull and update form terms when creating new ones
* fix typo
* do not export TokenItem type
* rename and tweak jsdoc
* skip E2E test
* Automated change: Prep @woocommerce/extend-cart-checkout-block for release.
* Re-add removed items from changelog with updated prefixes
---------
Co-authored-by: opr <opr@users.noreply.github.com>
Co-authored-by: Thomas Roberts <thomas.roberts@automattic.com>
* Fix review error type
* Add changelog
* Rename global error-boundary class to avoid conflict
* Rename global error-boundary class to avoid conflict
* Wrap panels in error boundary
* Remove console
* Reformat
* Fix test
* Fix test
* Add changelog
* Move productBlockEditorSettings type to global.d.ts
* Set maxUploadFileSize to system settings
* Changelog
* Add maxUploadFileSize to test
* Set maxUploadFileSize for downloads
* Set maxUploadFileSize for variation image quick action
* Remove unused EditDownloadsModal props
* Fix typo in EditDownloadsModal prop
* Remove unused EditDownloadsModalProps prop
* Remove unused function
* Show specific error message when upload of download file fails
* Show error notice when upload fails for variation image quick action
* Set maxUploadFileSize for download files menu item
* Close downloads menu on error
* Fix up types to avoid duplicate definitions
* Show specific link error
* Create VariationStockStatusForm component
* Integrate VariationStockStatusForm within the VariationsTableRow component
* Add woocommerce_manage_stock option to the default_option_permissions list in the Options rest controller
* Enable track inventory when woocommerce_manage_stock is set to yes
* Add stock_status radio component to the VariationStockStatusForm component
* Fix VariationStockStatusForm padding
* Fix control spacing
* Add stock_quantity to the VariationStockStatusForm component
* Add changelog files
* Fix linter errors
* Fix invalid sortable state in the variations table
* switch setting templates order
* pull product_form from the entity store
* fix typo
* set post excerpt with template description
* update the description for the Simple template
* rename type for product form post
* introduce isProductFormTemplateEnabled() helper
* render the PFTs into the templates selector
* changelog
* tscripting
* remopve dropdown
* re-write changelog files
* change and rename isProductFormTemplateSystemEnabled
* remove unused component
* try change the template version name
* Add tests for ProductPage
* Add tests for ProductVariationPage
* Add test for product_tab_click event
* Add test for product_editor_feedback_bar_turnoff_editor_click event
* Add test for product_dropdown_option_click event
* Add test for product_add_view track
* Changelogs
* Changelog
* Lint
* Add product_edit_view test and falsey test
* Fix test name
* Only run layout effect after product is resolved
* Fix edit variable product test
* Add changelog
---------
Co-authored-by: Jon Lane <jon.lane@automattic.com>
* Remove template matching from front-end
* Create 'woocommerce_rest_get_product' filter to allow extensions to change the product when it's fetched through the REST API
* Stop defaulting to 'standard-product-template' product template and handle defaults only in getLayoutTemplateId function
* Use created hook to determine and persist the product template ID when it's not defined.
Also introduce 'match_fn' in ProductTemplate to allow extensions to provide robust ways of matching the template
* Add changelog
* Fix tests
* Remove outdated tests
* Fix issue in filter because $product can be false and move API change to v3
* Add comments to continue statements
* Small refactor
* Only send layout template id to useLayoutTemplate after product is loaded
* Revert front-end changes
* Remove match_fn and create filter to allow extensions to determine the product template id
* Avoid loading layout template before product is loaded
* Create woocommerce_product_editor_determine_product_template filter and use it
* Update changelogs and remove unused code
* Remove _product_template_id for products that were created with the new product editor.
* Use only id to find productTemplate
* Turn hook into experimental
* Remove deprecated tests
* Rename filter
* Add more typings to useEntityRecord
* Use hasResolved boolean to check whether product has been resolved
* Add changelog
* Add 'variation' to ProductType
* Don't default to the standard-product-template for variations
* Update changelog
* Accept null in getLayoutTemplateId
* Fix edit variable product test
* Rename hook
* Revert changed logic to avoid regressions
* Increment useProductTemplate logic
* Default to standard-product-template instead of undefined when no matches
* Re-import Features class
---------
Co-authored-by: Jon Lane <jon.lane@automattic.com>
* introduce ProductFormTemplateProps type
* pull and set the default product form template
* render the PFT when it exists
* render a temporeary form templates selector
* changelog
* rollback TS global changes
* fix typo
* focus description when generating slug
* focus the name once the modal renders
* changelog
* do not focus on description field
* isSecondary is depcreated. use "variant" prop
* move changelog file
* Temp commit
* Clean up unused codes and streamline logic
* More cleanups and add comment
* Better naming and fix logic
* Rename and comment
* Changelog
* Changelog
* Lint
* Moved leap year utils to date package, added tests
* Moved functions to utils, add tests
* Add more test
* Fix changelog
* Focus tab shows focus style
* Tabbing when inside the tabs takes you to the first focusable element inside the current tab's tab panel
* Users can press the left and right arrow keys to move between tabs
* When a tab is focused and the Home key is pressed the first tab in the list should be focused. When the End key is pressed the last tab should be focused
* Add changelog file
* Fix e2e tests
* Add changelog file
* Get last tab by index
* Fix linter errors
* minor change in reducer
* use organizeItemsById to compute new items
* add reducer test with pick optimisticUrlParameters
* rename constant name
* add optimisticUrlParameters to CRUD actions types
* use organizeItemsById to generate store IDs
* add more reducer tests
* compute nextItemsData based on ids
* tessstssssss
* add a order_by: name test
* fix sorting data when url parameters
* add tests
* introduce filterDataByKeys helper fn
* fix process to sort items optimistically
* rollback wrong change in actions
* changelog
* set action `options` as optional
* set default value for options
* Explicitly check whether the only block is a paragraph
* Update comment
* Move handling of empty block array into clearDescriptionIfEmpty
* Add areBlocksEmpty util function
* Check for empty block inside iframe editor
* Remove check for empty block from description block
* Add unit tests for areBlocksEmpty
* Changelog
* Update comment to clarify
* Lazy load the PluginArea and the ModalEditor
* Remove repeated product request when editing a specific product
* Fix linter errors
* Add changelog files
* Fix linter errors
* Refactor the block editor to remove some extra rerenders
* Defer the publish button processing
* Defer the tab content render 500ms to reduce the total blocking time
* Fix linter errors
* Fix unit test and tabs unexpected rerender
* Fix linter errors
* Reduce the defered time to 300ms
* Fix get product url when the product has been duplicated since the new copy does not have permalink
* Fix the invalid unregistration of wc-admin-more-menu in the product page
* Fix compilation errors
* Don't use NavigableToolbar for header
* Rename CSS styles for header
* Put document tools in NavigableToolbar
* Fix alignment of inserter button
* Switch non-toolbar items to regular buttons
* Remove unused const
* Use same CSS styling as core for document tools
* Clean up errant change while rebasing
* Changelog
* Add workflow_call event
* Add tests-daily-run.yml
* Remove workflow version
* Update input value
* Remove secrets from caller workflow
* Rename job
* Check context
* Check context
* Check workflow_call inputs
* Override github.event_name with inputs.trigger
* Fix input name
* Add config for daily e2e tests with Gutenberg
* Update env commands for Gutenberg run
* Add disableHpos env variable in ci-utils
* Revert the trigger to push
* Revert the env variable setting in ci-jobs
* Revert the env variable setting in ci-jobs
* Rebuild utils
* Update test env start command
* Define the Gutenberg Playwright project
* Use path relative to workspace root
* Update events for test projects
* Update events for test projects
* Add changelogs
* Remove the e2e tests with Gutenberg tests from daily runs
* Set the schedule and workflow_dispatch triggers
* Add --project default flag to only run the default tests in CI
* Renamed snapshots to match the new Playwright project name
* Rename appendEdit function to appendToEditorHistory
* Don't append to editor history onInput
* Changelog
* Move onChange and onInput handles to named functions
* Debounce appendEdit
* Change undo and redo to useCallback
* Update debounce time to feel closer to post editor
* Move debounce of appendEdit into useEditorHistory
* Make sure debounced appendEdit is flushed before undo/redo
* Remove console.log() statement
* introduce processItems() util function
* add processItems fn tests
* use processItems in the reducer process
* udpate GET_ITEMS reducer test
* minor CREATE_ITEM_SUCCESS test update
* changelog
* Add undo shortcut support
* Add redo shortcut support
* Add document overview shortcut support
* Move keyboard shortcuts to after interface store is registered in subregistry
* Move settings sidebar identifier to a constant
* Add settings sidebar shortcut support
* Changelog
* Update to pnpm 9.1 and fix a mini css bug
* Add changefile(s) from automation for the following project(s): @woocommerce/tracks, @woocommerce/product-editor, @woocommerce/onboarding, @woocommerce/number, @woocommerce/notices, @woocommerce/navigation, @woocommerce/internal-js-tests, @woocommerce/extend-cart-checkout-block, @woocommerce/expression-evaluation, @woocommerce/explat, @woocommerce/experimental, @woocommerce/eslint-plugin, @woocommerce/dependency-extraction-webpack-plugin, @woocommerce/date, @woocommerce/data, @woocommerce/customer-effort-score, @woocommerce/currency, @woocommerce/csv-export, @woocommerce/create-woo-extension, @woocommerce/create-product-editor-block, @woocommerce/components, @woocommerce/api, @woocommerce/ai, @woocommerce/admin-e2e-tests, woocommerce-blocks, woocommerce-beta-tester, woocommerce, woo-ai
* temporarily disable swallowing build output to diagnose issue with perf workflow
* Ignore some type issues that commonly resurface when deps slightly change
* Fix persistent type issues that have recurred many times
* Add more ignores
* Fix lint issue
* Revert change to swallow build error
* Improve access of the config that needs updated build dir.
---------
Co-authored-by: github-actions <github-actions@github.com>
* fisrt approach
* do not clear same selected term
* tweak token field component
* chage the attributes type
* filter attributes already taken
* set instanceNumber for each combobox instance
* implement remove attribute
* final first approach
* update onRemove type
* rename edit VariationItemsBlockEdit
* handle local attributes
* rollback unrelated issue
* changelog
* remove unused component
* remove test
* add border color when disabled
* Use min and max values if provided when sanitizing values
* Pass min and max attributes to NumberControl
* Use 'min' and 'max' values when incrementing through + and - buttons
* Add changelog
* Handle increment when pressing buttons
* Show + and - buttons disabled when max/min has been reached
* Prevent suffix from being selected
* iframe editor PluginSidebar
* iframe editor PluginArea and ComplementaryArea
* iframe editor PinnedItems
* Try ComplementaryArea slot
* Update scope name
* Only render ComplementaryArea.Slot when right sidebar is open
* Register interface store in sub registry
* Move block inspector to complementary area
* Remove hardcoded inspector toggle button from header
* Remove debug statement
* Remove unused isSidebarOpened context
* Set settings sidebar to be active by default
* Don't allow unpinning of settings sidebar
* Organize sidebar components under folder
* Add plugin more menu item
* Remove width for sidebar
* Update PluginArea scope name
* Pull out small viewport support for pinned items (incomplete)
* Move sidebar complementary area scope to a const
* Update sidebar complementary area scope name
* Update PluginSidebar export name
* Provide comments to clarify sidebar props settings
* Add comment about why this icon was copied
* Remove unnecessary wrapper div around complementary area
* Changelog
* add package
* remove log
* Add changefile(s) from automation for the following project(s): @woocommerce/dependency-extraction-webpack-plugin, woocommerce
* Add changefile(s) from automation for the following project(s): @woocommerce/dependency-extraction-webpack-plugin
---------
Co-authored-by: github-actions <github-actions@github.com>
* Set BlockEditorProvider's value to temporalBlocks
* Remove unnecessary code
* Set initial blocks in editor history, so that the first edit on an existing description can be undone
* Changelog
* Increment ProductVariationImage type
* Allow adding images to variations from the main product screen through a button
* Add changelog
* Add changelog
* Change showSuccess parameter to optional
* Add 'placeholder' attribute to taxonomy block and add 'placeholder' attribute to category field in Simple Product Template
* Only show placeholder when nothing is selected
* Remove suffix from function parameters
* Add changelog for component
* fix unit tests
* Avoid requesting product with id -1
* Add changelog
* Move changelog
* Add options to useEntityRecord type
* Fix editedRecord
* Add comment
* Undo early return
* Avoid making a request for product if it isn't already loaded
* Avoid making a request for product if it isn't already loaded
* Add typing for useEntityId
* Rework header to avoid requesting product unless we have a product ID
* Avoid requesting product when getting productTemplateId and blocks
* Remove unused import (fix lint error)
---------
Co-authored-by: Matt Sherman <matt@jam123.com>
* Rename filter options in Orders Analytics.
* Sort filter options in labels in Orders Analytics.
* Change filter labels to singular.
* Wider label column to accommodate label change.
* Rename filter options in Variations Analytics.
* Change filter options to Attribute, Category and Product in Variations Analytics.
* Revert "Change filter options to Attribute, Category and Product in Variations Analytics."
This reverts commit b3ca5d5807.
* Change "Add a Filter" to "Add a filter".
* Add changelog.
* Add changelog.
* Refactor getAvailableFilterKeys and getAvailableFilters into one function.
* Add code comment and remove unneeded code.
* Code refactor getAvailableFilters.
This is done by starting from allFilterKeys, and filtering with allowMultiple or not yet active.
With this, we don't need to have `inactiveFilterKeys` and "Ensure filters that allow multiples are always present."
* Fix tests and lint issues.
* Simplify code with Object.entries.
* rename type for item of attribuite input field
* options is not part of the input item
* update type of getProductAttributeObject
* update types
* changelog
* fix eslint issue
* fix test
* move the logic to pull attribute to modal cmp
* changelog
* remove options from item props
* rename TS prop name
* save unsaved change
* rename type for item of attribuite input field
* options is not part of the input item
* update type of getProductAttributeObject
* update types
* changelog
* fix eslint issue
* fix test
* tweak optimisticQueryUpdate type
* sort items optimistically
* update attributes list optimistically
* do not invalidate when creating a new attribute
* changelog
* changelog
* update tests
* update options param in test
* wait for the promise when creating new attribute
* fix the rest of tests
* Import colors.native scss variables
* Add changelog
* Refactor WCPay banner and cleanup
We introduce a new WCPayConnectCard onboarding component and
remove/cleanup all other WCPay surface components.
This component uses the new design, updated payment methods icons
and WCPay logo.
* Add changelog
* Upgrade the WCPay payments settings banner
* test: Fix WCPay payments settings banner tests
* Update the WCPay welcome page to use the WCPayConnectCard component
* Update the Payments task page to use the WCPayConnectCard component
* Fix copy for payments settings methods CTA buttons label
* Add changelog
* Further cleanup of no-longer-used WCPay surfaces
* Consolidate onboarding component icons for single sources
* Minor cleanup
* test: Fix WCPay payments settings banner test
* test: Fix payments tasks page tests
* Add apiFetch middleware to add X-Wc-Product-Editor header to all requests from product editor
* Use productEditorHeaderApiFetchMiddleware
* Update name of header
* Utility function to check header
* Changelog
* Changelog
* Fix UI for add filter popover in Analytics.
* Make character casing consistent for filters.
* Add changelog.
* Add changelog.
* Change filter label to sentence case.
* Show validation message in the field that lost the focus
* Add unique validation for custom field names and trim values
* Let edit custom fields when creating a new product
* Add changelog file
* Allow saving a product as a draft when hitting ctrl/cmd + S
* Increment logic to keep product published/scheduled after it is published when using shortcut
* add a CustomActionDispatchers for createProductAttribute action
* add optional options to createItem() fn
* update items object when optimisticQueryUpdate is defined
* reduce itemsCount when creating a new item
* polish TS types
* update reducer tests
* clean unused type
* clean dirty code
* add optimisticQueryUpdate test
* changelog
* minor improvement
* options could be undefined
* compute items and itemsCount based on data
* fix TS error
* changelog
* Use editedRecord instead of record
* Always use productTemplateId when available
* Change private methods to protected in ProductVariationTemplate
* Use editedRecord in hook useEntityRecord
* Update changelogs
* Restore attribute renamed by mistake
* Change useProductTemplate unit test
* Add selectable attribute in product template to allow creation of product templates that do not appear on the "Change product type" UI
* Always use productTemplateId when available, otherwise fallback to standard-product-template
* Rename attribute
* Use editedRecord in hook useEntityRecord
* Revert "Always use productTemplateId when available, otherwise fallback to standard-product-template"
This reverts commit 2960fcd520.
* Revert "Use editedRecord in hook useEntityRecord"
This reverts commit c28e005e7b.
* Add changelogs
* Fix unit tests
* Increment changelog
* Fix Launch Your Store task item should not be clickable once completed
* Add changefile(s) from automation for the following project(s): @woocommerce/experimental, woocommerce
---------
Co-authored-by: github-actions <github-actions@github.com>
* Add meta_data parameter in generateProductVariations
* Apply filter to get meta_data to generate variations
* Add meta_data parameter in generate variations endpoint
* Update name and add documentation
* Fix useEntityRecord in blockEditor
* Remove ToS acceptance in WCPay banner and promotions JSON
* Add changefile(s) from automation for the following project(s): @woocommerce/onboarding, packages/php/remote-specs-validation
* Add line break in banner to look nicer
* Center banner content
* Style banner for mobile version
* fix js test to use another block (previous one no longer exist)
* Add changefile(s) from automation for the following project(s): @woocommerce/onboarding, packages/php/remote-specs-validation, woocommerce
* Add comment to css
---------
Co-authored-by: oaratovskyi <oleksandr.aratovskyi@automattic.com>
Co-authored-by: github-actions <github-actions@github.com>
* Add aria-labelledby attribute to rich text component
* Handle label click to focus rich text
* Remove unneeded ts-ignore
* Pass in label ID explicitly instead of hardcoding knowledge of its naming pattern
* Changelog
* Add tooltip attribute to block.json
* Focus text area when clicking on label
* Remove Label id... not needed
* Set text area labelled by to label
* Add aria-required to rich text
* Hide required asterisks from aria
* Only send edited properties
* Changelog
* Rename const to match previous code
* Remove all the logic to look up the entity key... we know it is 'id' for products
* Fix homepage link in package.json
* Add changefile(s) from automation for the following project(s): @woocommerce/create-woo-extension
---------
Co-authored-by: github-actions <github-actions@github.com>
* Disable woocommerce/product-regular-price-field when product type is variable
* Disable woocommerce/product-sale-price-field when product type is variable
* Disable woocommerce/product-sku-field when product type is variable
* Disable Track stock quantity toggle when product type is variable
* Disable woocommerce/product-radio-field when product type is variable
* Disable woocommerce/product-shipping-class-field when product type is variable
* Disable woocommerce/product-shipping-dimensions-fields when product type is variable
* Add changelog files
* Fix php linter
* register the `metadata` attribute for all blocks
* bind value attribute with the nane product entity
* changelog
* add a ToDo note
* rename edit component fn to NameBlockEdit
* changelog
* restore @ts-export line
* fix eslint issue
* fix eslint issue
* Show Scheduled product header tag when the product is been scheduled
* Fix the pre publish modal header message when to say scheduled when the product has a date in the future
* Add changelog file
* Create and register the woocommerce/product-select-field block
* Replace the tax class radio group block by woocommerce/product-select-field block
* Hide tax fields when taxes are disabled
* Hide tax fields when taxes are disabled in product variations
* Add changelog files
* Fix linter errors
* 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>
* 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 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
* Create the Add new button
* Integrate the CreateModal with the CustomFields component to add fields
* Add validation utils
* Fix validation errors in the edit modal component
* Fix linter error
* Add changelog file
* Create edit modal
* Add update function to the useCustomFields hook
* Integrate the EditModal in the CustomFields component
* Add edition and validation logic to the custom field EditModal component
* Fix text control validation error styles
* Focus the name field when its invalid
* Fix linter error
* Fix edit modal min width and controls width
* Add changelog file
* Fix text overflow in custom fields table
* Remove non needed block style file
* Create woocommerce/product-custom-fields block
* Register woocommerce/product-custom-fields block
* Add product-custom-fields block to the simple product template
* Create useCustomFields hook
* Create empty state
* Create CustomFields component
* Add custom fields table
* Add custom field remove button
* Hide the custom fields table base on the toggle value
* Remove non list features
* Add changelog files
* Fix linter errors
* Fix empty state styles
* Fix php linter error
* Remove context from the woocommerce/product-custom-fields-toggle-field block definition since it is not used
* Change url for the Read more about custom fields
* Register metaboxhidden_product user meta as a user rest field
* Create useMetaboxHiddenProduct to manage the user metaboxhidden_product meta field
* Create woocommerce/product-custom-fields-toggle-field block
* Register woocommerce/product-custom-fields-toggle-field block
* Create product-custom-fields feature flag
* Hide custom fields behind the product-custom-fields feature flag
* Add changelog files
* Get default postcustom user meta value when the metaboxhidden_product does not exist yet in the user object
* Close prepublish panel before create new
* Add changelog
* Remove close fn from blockeditor
* Close panel after clicking outside
* Refactor useEffect
* Remove empty lines
* Replace mousedown with click event
* Replace click with mouseup
* Move products to trash
* Create useProductManager hook
* Use useProductManager hook in the publish button
* Create PublishButtonMenu
* Hide move to trash when the product is already in trash
* Fix linter error
* Add changelog file