Commit Graph

2795 Commits

Author SHA1 Message Date
Joel Thiessen 8405974674
Adding ces exit prompt when product importer abandoned (#35996) 2022-12-15 13:18:35 -08:00
louwie17 895cb1561c
Add/35126 ces exit prompt orders (#35762)
* Add exit tracking for orders

* Update exit page CES action

* Fix order hook name

* Add changelog

* Address PR feedback
2022-12-15 15:50:34 -04:00
Joshua T Flowers 266b61cd4c
Disable irrelevant product tabs when variations exist (#35939)
* Add disabled prop to product form tabs

* Add tooltips to disabled tabs

* Add styling for tooltips when disabled

* Add changelog entry

* Update disabled styles for experimental focus buttons
2022-12-15 11:20:10 -08:00
Fernando Marichal 44cf396be6
Product variation quantity status indicator (#35982)
* Add variation status indicator

* Add changelog

* Add tests

* Fix style

* Rename enum

* Fix lint

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-12-15 15:20:21 -03:00
Maikel David Pérez Gómez 393cc629d9
Add pagination to variations list (#35979)
* Add changelog

* Add pagination to variations list

* Apply styles for pagination paddings and to keep it at the bottom of the section card

* Returning back per page option from 2 to 25

* Fix pagination label text from uppercase to normal and font styles

* Update variation footer gap

Co-authored-by: Joshua T Flowers <joshuatf@gmail.com>
2022-12-15 10:13:29 -03:00
RJ cc9f4b65fc
Enhancement: Tax settings conflict warning (#36010)
* Add WIP error handling when conflicting settings chosen

* add: enhance tax settings conflict warning

* Fix WC_Settings_Tax_Test::test_get_settings_for_default_section

* Wrap texts in i18n method

* Add snackbar

Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com>
Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-12-15 21:04:28 +08:00
Adrian Duffell dbbe78c8ae
Add Codisto Extension to Onboarding (#36009)
* WIP

* Update codistoconnect

* Update selective-extensions-bundle for free trial badge

* Add codisto onboarding logo

* Add changelog

* Fix lint issues

* Fix lint issues with necassary spacing this time

* Add link to codisto product page

* Fix lint formatting

Co-authored-by: Chi-Hsuan Huang <chihsuan.tw@gmail.com>
2022-12-15 20:34:34 +08:00
Maikel David Pérez Gómez 31e6f90e74
Fix product tab to be shown on production build (#35976) 2022-12-14 18:07:55 -03:00
louwie17 c7132ec8f0
Add/35126 ces exit prompt settings (#35761)
* Add exit settings page tracker

* Add exception for when user hits the save button

* Update settings and add icon support

* Add changelog

* Add dismiss track for when user dismisses CES modal

* Add changelog

* Add tests for staticFormDataToObject function

* Fix imports of test file
2022-12-14 10:55:12 -04:00
timur987 4ac1d822ac
Update In-App Marketplace tour wording (#35929) 2022-12-14 10:59:42 +03:00
Chi-Hsuan Huang 679e875bd2
Fix ellipsis dropdown is hidden in task list (#35949)
* Fix the ellipsis dropdown menu is mostly hidden within the task list

* Add changelog
2022-12-14 13:53:52 +08:00
Joshua T Flowers e1aabf2d9d
Add product variations list to new product management experience (#35889)
* Add product variations section

* Add variations list

* Add util to get product stock status

* Add variation specific attribute type

* Add currency code to header column

* Fix up variations header width

* Add variations loading state

* Add changelog entries

* Convert spaces to tabs

* Fix status typo

* Fix up return type for stock status
2022-12-13 15:29:05 -08:00
Joshua T Flowers 4eacc67501
Add product tabs to product layout (#35862)
* Add product form tabs to layout

* Move product sections to respective tabs

* Add tab styling

* Add changelog entry

* Scroll to top on tab change

* Update font weight on active or inactive tabs

* Add blank EOL
2022-12-13 08:13:12 -08:00
Moon 131183597f
Fix RegExp used to filter the country list dropdown on the store details step (#35942)
* Add custom regexp for the country dropdown search

* Add changelog
2022-12-12 18:48:22 -08:00
louwie17 613e58c061
CES exit prompt for product editing screens (#35728)
* Add exit page tracker logic and implement it for product pages

* Add changelog

* Fix lint errors and add comments

* Add ces_location prop

* Add mock to fix broken test

* Add CES exit page survey tests

* Fix a bug with React pages redirects and update actions

* Fix test

* Fix lint

* Add default inside location prop

* Remove exit prefix within action

* Address PR feedback and make sure its not triggered on save

* Update copy of exit feedback notice

* Add changelog

* Update name of param

* Fix lint error

* Use hasFinishedResolution vs isResolved in customerEffortScoreTracks
2022-12-12 09:56:28 -04:00
louwie17 d406eeb299
Fix react chunk build warnings (#35930)
* Reorganize imports to fix build warnings and remove overlapping css import

* Add changelog

* Update changelog
2022-12-12 09:43:34 -04:00
Nathan Silveira 31773d4b06
Create ProductForm component to merge duplicated UI (#35783)
* Extract new component 'ProductForm', to reduce duplicated code between add-product-page and edit-product-page

* Add changelog

* Try to merge add-product-page and edit-product-page into a single product-page: running into some issues probably with the controller

* Revert "Try to merge add-product-page and edit-product-page into a single product-page: running into some issues probably with the controller"

This reverts commit bc30b67ef2.
2022-12-05 17:46:21 -03:00
louwie17 e7dd1a0be9
Add/35300 ces feedback product mvp (#35690)
* Add ability to show CES modal through share Feedback button

* Make use of showCesModal in footer

* Update CES action for share feedback

* Update changes to support second CES question

* Add changelog

* Address some PR feedback
2022-12-02 11:59:42 -04:00
louwie17 0e8fbe083d
Add/35129 product mvp ces (#35652)
* Add product mvp ces footer

* Add changelog

* Reset action option name after CES action

* Make sure we make use of cesAction

* Add close button

* Fix formatting

* Fix css styling issues

* Add icon to success notice

* Add product mvp CES hook and modify logic a little bit

* Update the CES product action name

* Address PR feedback and fix styling for smaller screens

* Add second question to CES product footer and update options

* Add changelog

* Fix lint error

* Fix tests
2022-12-02 05:35:47 -04:00
RJ 14ab611008
fix: woocommerce admin cart modal header clips header text (#35780)
fix: increased woocommerce cart modal margin
2022-12-01 08:03:58 +08:00
Maikel David Pérez Gómez 25a7c35cf4
Improve element stacking in modals on tablet and mobile (#35733)
* Add updated versions of sr-only and not-sr-only mixins

* Improve element stacking in modals on tablet and mobile

* Add comment suggestion

* Change sr-only for screen-reader-only which is more descriptive
2022-11-30 13:28:00 -03:00
Fernando Marichal 1e9fff35c0
Allow the user to select multiple images in the Media Library (#35722)
* Add multiple selection to MediaUploader

# Conflicts:
#	packages/js/components/src/media-uploader/media-uploader.tsx

* Fix README.md

* Add multiple select to image section

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

* Add changelogs

* Fix repeated images addition

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-11-30 10:40:41 -03:00
Fernando Marichal 716d5ab322
Move file picker by clicking card into the MediaUploader component (#35738)
* Fix `MediaUploader` component

* Fix storybook

* Fix image section

* Add changelogs

* Fix code comment

* Fix text

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-11-30 09:00:14 -03:00
louwie17 f16cfbc9d6
Add open on focus to attribute fields (#35758)
* Add experimental open menu on focus to attribute input fields

* Add changelog
2022-11-30 04:05:11 -04:00
Maikel David Pérez Gómez 79566d7e6b
Add a bottom padding to the whole form (#35721) 2022-11-29 15:11:57 -03:00
Joel Thiessen 4db5c0d8cd
Add additional question to CES modal (#35680) 2022-11-29 08:15:58 -08:00
Nathan Silveira 121bfe3a29
Add tracks event for "View product" and dismiss action after update (#35582)
* Record an event 'product_view_product_click' when the 'View Product' link is clicked after creating or updating a product

* Add product_view_product_dismiss tracks events (WIP, not currently working)

* Add changelog

* Fix whitespace in addEventListener and remove console.logs

* Change link tag id to be more specific and comply with CSS guidelines
Move HTML code out of translation function

* Run phpcs in class-wc-admin-post-types

* Add tinyMCE types to add global tinymce variable in typescript code

* Add additional data in getProductData

TODO: I'm not sure if it's possible, or if it makes sense, to include stock_quantity_update in the object

* Add code review suggestions, including:

* Create isElementVisible function to backfill jQuery implementation
* Fix wrong value for is_downloadable, is_virtual, manage_stock
* Fix wrong radix
* Update menu_order implementation
* Add missing ? to weight

* Add stock_quantity_update implementation which is not working as intended

Since the page reloads after product update, the initialStockValue is updated as well

* Remove stock_quantity_update property and adjust is_downloadable, is_virtual, and manage_stock for consistency
2022-11-28 22:01:10 -03:00
Maikel David Pérez Gómez 3857b51f30
Fix price field currency symbol position (#35718)
* Currency symbol is fixed on the left side of the price input field

* Currency symbol has a different color from the input field value (Gutenberg-700)

* Input value is aligned right

* On focus, we highlight the field's content so the user can quickly clear or overwrite the placeholder text

* On focus, the user can press the up and down arrow keys to increase or decrease the value by 1

* Add changelog

* Remove unnecesary stepUp function
2022-11-25 11:48:18 -03:00
Maikel David Pérez Gómez 410f06b8c8
Add a blank space between the emoji and the message within a notice popup (#35698)
* Add a blank space between the emoji and the message within a notice popup

* Apply comment suggestions

* Remove duplicated text in the snackbar message after publishing a product
2022-11-25 10:21:22 -03:00
Fernando Marichal 12121a40ee
Open file picker by clicking card (#35358)
* Add FormFileUpload component

* Add styles

* Add changelog

* Fix lint

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-11-25 09:07:54 -03:00
AnnaMag 49aa5e03fd
Update the summary placeholder text in the product management form. (#35717)
* Product management: change the product summary placeholder text.

* Add changelog

* Correct formatting
2022-11-24 17:11:04 -03:00
Fernando Marichal 28f5616973
Fix the gap in the featured product checkbox (#35710)
* Fix style

* Add changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2022-11-24 12:15:15 -03:00
Joshua T Flowers db737f2190
Add responsiveness to product form header (#35623)
* Update product title in smaller viewports

* Move secondary product actions to menu group on mobile

* Hide settings menu on smaller viewports

* Add changelog entry
2022-11-24 11:00:20 -03:00
Gan Eng Chin a811009a06
Add one-click installation for recommended extensions in multichannel Marketing page (#35542) 2022-11-24 21:46:08 +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
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
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
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
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
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
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
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
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
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
Joel Thiessen 5b1296fe45
Adding attribute edit modal for products MVP (#35269) 2022-11-03 08:20:29 -07:00
Chi-Hsuan Huang 76f99a482f
Cleanup and deprecate task properties and methods (#35450)
* Remove unused sectioned task code

* Remove section task type and update getVisibleTasks logic

* Clean up task list and deprecate methods/properties

* Add changelog

* Fix lint

* Remove snooze tests

* Remove snooze JS tests
2022-11-03 09:22:36 +08:00
Chi-Hsuan Huang 3fc0ee338e
Fix business details step fails to display when Gutenberg plugin is active (#35448)
* Fix business details tabs when Gutenberg is active

Fix business details tabs when Gutenberg is active

Fix business details tabs when Gutenberg is active

* Add changelog
2022-11-02 13:40:02 -05:00
louwie17 ff2b06c9af
Add create attribute term modal (#35131)
* Add create attribute term modal

* Add back filter missed during rebase

* Add changelog

* Fix lint error

* Address some feedback from PR review

* Prevent first modal from closing if closing the second modal when clicking outside
2022-11-01 09:05:46 -03:00
Joshua T Flowers e1ebabba29
Fix up rich text editor initial selection and add blocks (#35286)
* Fix double click toolbar behavior

* Fix initial block selection on editor load

* Add placeholder option to RichTextEditor

* Add image and video blocks

* Set toolbar height

* Allow inserter to be shown

* Allow media uploads in rich text editor

* Add changelog entries

* Fix media upload

* Check for existence of selected blocks before checking length

* Pass blocks to avoid race in detecting initially empty blocks
2022-10-31 14:36:54 -07:00
Joshua T Flowers 66370c823f
Add inventory advanced section (#35164)
* Add sold individually inventory option

* Add backorder purchase options

* Add margin around collapsible content areas

* Add changelog entry

* Add tests around inventory section

* Fix up checkbox props after rebase

* Check for disabled track quantity toggle

* Update manage stock test

* Fix nested radio control label margin
2022-10-31 14:36:33 -07:00
louwie17 04d6e8849c
Add name to select control popover slots (#35353)
* Add name to SelectControlMenuSlot

* Add changelogs

* Update changelog

* Fix typo in changelog
2022-10-27 12:52:29 -03:00
Joshua T Flowers 89961fe067
Add summary field to new product experience (#35201)
* Add summary to new product page experience

* Add changelog entry
2022-10-26 11:20:11 -07:00
Maikel David Pérez Gómez 47439ec241
Fix the display of letter descenders in the shipping class dropdown menu (#35258)
* Fix the display of letter descenders in the shipping class dropdown menu

* Add comment suggestions
2022-10-25 17:28:37 -03:00
Maikel David Pérez Gómez 78f659b702
Increase the spacing between the shipping box illustration and the dimensions fields (#35259) 2022-10-25 17:17:30 -03:00
Maikel David Pérez Gómez c1e5098ff2
Change the product info section title to Product Details (#35255)
* Change the product info section title to Product Details

* Add comment suggestions
2022-10-25 16:49:48 -03:00
Maikel David Pérez Gómez 1bca35c360
Improve the communication around required and optional (#35266)
* Improve the communication around required and optional

* Add comments suggestions
2022-10-25 16:49:02 -03:00
Maikel David Pérez Gómez 69e52c2fa0
Remove some placeholder values (#35267) 2022-10-25 10:17:43 -03:00
Joshua T Flowers 2aa4ce0d9f
Disable product inventory toggle when inventory management is disabled (#35059)
* Disable product inventory toggle when inventory management is disabled

* Export conditional wrapper as experimental component

* Conditionally show the tooltip

* Add comment explaining the tooltip overlay

* Add components changelog entry

* Display tooltip on hover any portion of toggle or label

* Add changelog entry

* Fix scss lint error

* Center tooltip over label and toggle

* Fix up input props after rebase

* Add wrapper around field to maintain block item formatting
2022-10-24 09:08:27 -07:00
Maikel David Pérez Gómez 64ee20ff0f
Show a dismissible snackbar if the server responds an error (#35160)
* Show a dismissible snackbar if the server responds an error

* Removed the default value New shipping class from the Name field and replaced it with a placeholder: e.g. Fragile products

* Only used the category's name when the user creates a new shipping class for the first time

* Fix linter errors

* Update grammar error

Co-authored-by: Joshua T Flowers <joshuatf@gmail.com>

* Add empty initial values to form field to prevent controlled/uncontrolled react error

* Tune error handling

Co-authored-by: Joshua T Flowers <joshuatf@gmail.com>
2022-10-22 10:47:17 -03:00
Joshua T Flowers 28f8e7f996
Enhance getInputProps to allow passing of non-overridden props (#35034)
* Allow additional props to be passed to the Form getInputProps method

* Remove getTextControlProps

* Pass additional shared props through getInputProps in shipping

* Simplify checkbox props

* Unwrap currency props

* Use onBlur event to sanitize prices

* Add changelog entry

* Add option to get checkbox props to form context helpers

* Update checkbox tracks handler naming and typing

* Fix up usage of getInputProps

* Add helper sanitize method

* Use sanitize helper method for product input fields

* Fix inventory input props after rebase

* Fix shipping typo

* Fix up form types after rebase

* Align all checkboxes on product page

* Rename new checkbox helper to getCheckboxControlProps

* Add helper method to get select control props

* Add data changelog entry

* Check for product name length on blur

* Add initial value for name to prevent uncontrolled value

* Add initial value for sku
2022-10-21 07:03:49 -07:00
Joshua T Flowers 3a2a22905b
Add manual stock management section to product management experience (#35047)
* Add manual stock management section to product management experience

* Add changelog entry

* Add default value for stock status

* Fix up lint issues

* Handle PR feedback
2022-10-20 14:14:54 -07:00
Maikel David Pérez Gómez 114be56f63
Move product action buttons to header menu (#35214)
* Move product action buttons to header menu

* Fix unit tests

* Add comment suggestions
2022-10-20 17:15:44 -03:00
louwie17 5f2c656e6b
Add/34331 add attributes modal (#34999)
* Add initial add attribute modal

* Add async select control component and add attribute terms

* Make use of AsyncSelectControl for attributes

* Rearranged the add attribute form to make removing easier

* Make sure add button is disabled if fields are empty

* Remove the use of AsyncSelectControl for now

* Add disabled option and fix merge conflict

* Add attribute modal tests

* Remove unused trigger drag

* Add popover slot

* Small update to select control and fix multi selection in term field

* Add tests for attribute and attribute term fields

* Add changelogs

* Small fix after merge conflict

* Fix some styling and issue with select control when clearing item

* Fix lint error

* Fix up some styling issues after rebase

* Fix formatting, some styling issues, and address some PR feedback

* And confirmation dialog for closing the modal.
2022-10-19 16:28:29 -03:00
Joshua T Flowers c72e00d85c
Add Tooltip component and remove EnrichedLabel (#35024)
* Add experimental tooltip component

* Add tooltip stories

* Update EnrichedLabel component

* Remove EnrichedLabel

* Add changelog entries

* Fix up linting issues

* Handle PR feedback
2022-10-18 16:08:49 -07:00
Maikel David Pérez Gómez c79af1acc5
Replace the trash can icon in the attribute list (#35133) 2022-10-18 16:05:01 -03:00
Maikel David Pérez Gómez a0b27a4966
Select the current new added shipping class (#35123)
* Select the current new added shipping class

* Extracting constants into the right file

* Add unit tests

* Use setValue instead onChange to select the shipping class of the product
2022-10-18 15:40:56 -03:00
Joshua T Flowers 3c6681054a
Add product management description (#34961)
* Add label prop to rich text editor

* Create feature class and enqueue styles

* Add description editor and parsing

* Fix up incorrect context for product data

* Add styling to rich text editors in product form

* Fix editor initialization on new product

* Add changelog entries

* Use trunk lock file

* Add component changelog entry

* Update lock file

* Register block store provider in tests

* Fix up phpcs errors in product feature file
2022-10-18 08:55:31 -07:00
Moon 0f58f2efbd
Fix JS errors when the OBW business step is accessed directly via URL (#35045)
* Set default value for product types

* Add changelog
2022-10-14 11:43:36 -07:00
louwie17 c55c91d7e0
Add category field dropdown field (#34400)
* 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

Prune out create new category logic

Fix minor css issue with border

Revert some of the select control changes and make use of the custom type

Fix up some styling changes

* Fix type conflict

* Revert change in state reducer

* Add cursor pointer

* Fix styling errors

* Fix broken category tests

* Fix merge conflict
2022-10-14 09:05:39 -03:00
Joel Thiessen 315e163b29
Only show five inbox messages and add "Show more" button (#35003)
* Basic paging functionality

* Adding changelog

* Inserting placeholder at end of list, working dismissal

* Fixing issues with dismissed notes not updating UI

* Fixing odd display when removing last note

* Renaming page variable

* Adding tracks event

* Addressing issues caused by .map within useSelect, and getting rid of hash

* Fixing nested ternary linting issue

* Removing console logs

* Updating test
2022-10-13 08:36:02 -03:00
RJ 1991347234
fix: handle error loading and error states for magic link button (#35068) 2022-10-13 16:12:40 +08:00
Ismael Martín Alabarce 3d1f8c36e0
Update WCPay promo requirements and ensure dismiss (#35030)
* Ensure Payments menu is dismissed after choosing no

Now it gets also dismissed on modal close

* Add a new requirement

Check if the store has another payment gateway installed to be eligible for the promotion.

* Add changelog entry

* Fix not using strict comparison for in_array

* Update is_another_payment_gateway_installed

To use a static list instead of PaymentGatewaySuggestions
2022-10-13 08:14:01 +02:00
Joshua T Flowers 8fbdbaf354
Add product page inventory quantity management (#34984)
* Add manage stock section to product inventory section

* Fix up h4 styles in form sections

* Check if stock management is enabled in store settings

* Fix up more styles in form

* Extract inventory validation and add new validation rules

* Add changelog entry

* Add changelog entry

* Remove sku related validation
2022-10-12 14:30:02 -07:00
Joshua T Flowers 0ca3f6d589
Add product management SKU (#34978)
* Add product inventory section and sku control

* Add validation and errors

* Add changelog entry

* Add dependencies comment block

* Call input props onBlur for product name field

* Remove slug validation

* Watch product name value change in inventory section

* Fix up usePrevious hook TS

* Revert watching changes by previous touched status
2022-10-12 13:11:05 -07:00
Fernando Marichal 98162b9d42
Images Product management MVP 1.0 (#34769)
* Add image section

# Conflicts:
#	plugins/woocommerce-admin/client/products/add-product-page.tsx

* Add `keepSpaceWhenDragging` to sortable

# Conflicts:
#	packages/js/components/src/sortable/sortable-item.tsx
#	packages/js/components/src/sortable/sortable.tsx

# Conflicts:
#	packages/js/components/src/sortable/sortable.tsx

* Export ImageGalleryItem

* Add props to `image-gallery`

# Conflicts:
#	packages/js/components/src/image-gallery/image-gallery-item.tsx
#	packages/js/components/src/image-gallery/image-gallery.tsx

* Changed `media-uploader` label

* Add changelogs

* Fix image-gallery and sortable components

# Conflicts:
#	packages/js/components/src/sortable/sortable-item.tsx
#	packages/js/components/src/sortable/sortable.tsx

# Conflicts:
#	packages/js/components/src/image-gallery/image-gallery.tsx
#	packages/js/components/src/sortable/sortable.tsx

* Set gallery min-height

* Add onOrderChange

* Show images section edit-product

# Conflicts:
#	plugins/woocommerce-admin/client/products/edit-product-page.tsx

# Conflicts:
#	plugins/woocommerce-admin/client/products/edit-product-page.tsx

# Conflicts:
#	plugins/woocommerce-admin/client/products/edit-product-page.tsx

* Fix styles

* Fix styles

* Fix image alt

* Fix TS any

* Add prop `onDragOver`

# Conflicts:
#	packages/js/components/src/image-gallery/image-gallery.tsx

* Fix styles

* Fix padding

* Fix image area min-height

* Fix subtitle copy

* Fix image margin

* Change `draggedImageId`

* Fix `setDraggedImageId` reset

* Rename `isRemoveZoneVisible`

* Add `CardBody` and remove redundant `setValue`

* Fix card styles

* Remove `getUniqueImages`

* Use url as a key when there is no image id

* Fix `orderedImages`

* Add hover to gallery images

* Fix gallery arrows and set cover problems

* Altering blur handler to prevent toolbar closure on media modal

* Fix toolbar drag and drop

* Add replace fn

* Restoring modal class for blur function

* Fix storybook

* Ensuring onBlur doesn't happen while dragging, resolving issue in Firefox

* Adding expected event object to drag callbacks

* Fix image size

* Fix lint

* Another fix lint

* Update plugins/woocommerce-admin/client/products/sections/images-section.tsx

Co-authored-by: Joshua T Flowers <joshuatf@gmail.com>

* Fix `draggedImageId` default value

* Fix toolbar icon style

* Rename consts

* Update pnpm-lock.yaml

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
Co-authored-by: Joel <dygerati@gmail.com>
Co-authored-by: Joshua T Flowers <joshuatf@gmail.com>
2022-10-12 15:16:22 -03:00
Oleksandr Aratovskyi a9dbb6d64e
Change copy of the payments welcome modal (#35031)
* Change copy in Payments Welcome modal

* Change copy in Payments Welcome modal
2022-10-12 16:18:13 +03:00
Maikel David Pérez Gómez e95bb3768e
Add new shipping class modal to a shipping class section in product page (#34937)
Add new shippping class modal to a shipping class section in product page
2022-10-11 12:00:35 -03:00
louwie17 6af1695f34
Add/34333 attribute list (#34841)
* Add initial attribute list with dragging and removing functionality

* Fix sortable styling and remove the default selected logic

* Fix css formatting

* Add changelogs

* Add missing question mark

* Add tests

* Some minor CSS updates and move some logic to a util function

* Fix lint issues and add extra test
2022-10-05 13:04:20 -03:00
Maikel David Pérez Gómez d3c19642b0
Add shipping dimensions image (#34857)
* Remove custom styles from FormSection component and use Card and CardBody instead

* Add dimension fields formating using the woo number global settings

* Load size units to show it as a suffix of shipping dimensions fields

* Fix card styles according the disign and pass props manually to BaseControl

* Add shipping dimensions image

* Apply comment suggestions
2022-10-03 15:06:17 -03:00
Adam Heckler 4b44189e1d
Change "WCPay" to "WooCommerce Payments" (#34666) 2022-10-03 15:42:04 +05:30
Chi-Hsuan Huang 5f2aa49579
Deploy spotlight product tour (#34859)
* Remove product tour experiment code

* Remove experimental-product-tour flags

* Replace old product tour

* Add changelog

* Remove spotlight query string
2022-10-03 16:34:49 +08:00
Chi-Hsuan Huang 08848d46ca
Fix onboarding wizard popover padding (#34896)
* Fix onboarding wizard popover padding for WP6.1

* Add changelog
2022-10-03 16:34:20 +08:00
Chi-Hsuan Huang 4a39091961
Add "aria-disabled" prop to truly disable OBW continue buttons (#34895)
* Add aria-disabled prop to truly disable OBW continue buttons

* Add changelog
2022-10-03 16:32:23 +08:00
Joshua T Flowers 3fd736c72f
Update plugins installer component to TS, Fix TS bugs and Syncpack TypeScript (#34787) 2022-09-30 10:59:07 +13:00
Maikel David Pérez Gómez 7fe05d65f3
Load size units to show them as a suffix of shipping dimensions fields (#34856)
* Add dimensions to shipping section
Change the FormComponent to support input name with dot notation like dimensions.width
Add the dimension controls to the product form

* Remove custom styles from FormSection component and use Card and CardBody instead

* Add dimension fields formating using the woo number global settings

* Add dimension fields validations

* Solve conflics from rebase

* Add changelogs

* Fix resetForm function to consider the passed params and the initialValues

* Load size units to show it as a suffix of shipping dimensions fields

* Fix card styles according the disign and pass props manually to BaseControl
2022-09-29 14:54:04 -03:00
Gan Eng Chin 9e697cdf0a
Add tests for UI Revamp on Marketing page (#34840) 2022-09-27 22:25:48 +08:00
Chi-Hsuan Huang c31f8b0aa5
Fix industry options not populate after reloading page (#34847)
* Add a spinner loader to ensure Industry loaded after data fetched

* Add changelog

Fix style
2022-09-27 16:26:22 +08:00
Chi-Hsuan Huang 84641b1c41
Fix enable guided mode button not trigger when its text is translated (#34843)
* Fix enable guided mode button not trigger when its text is translated

* Add changelog
2022-09-27 16:12:01 +08:00
louwie17 c01c48c8c3
Add initial attributes section for empty state (#34751)
* Add new attributes section and attributes field with just an empty state

* ADd changelogs

* Add check to not render the blank section when attributes exist

* Fix misspelling
2022-09-26 14:44:06 -03:00
Chris Lilitsas 63aa382ffb
Add a header for the "Add store details" task in woocommerce admin (#34712)
* Add store-details task header and ensure the aid is disabled when task is completed

* Add an illustration

* Update the texts

* Add changelog

* Revisit progress header styles

* Bring back ellipsis menu

* Align the ellipsis menu on the baseline

* Give some room to the badge in the sidebar

* Update progress bar color with variable
2022-09-26 15:19:47 +03:00
Chris Lilitsas 20b561f2f6
Enhance "Add store details" task onboarding experience (#34697)
* Change the visibility condition of the store details onboarding tour

* Add changelog

* Rename handler variable

* Modify aid description

* Cleanup
2022-09-26 14:52:23 +03:00
Maikel David Pérez Gómez 2eda531d46
Add shipping class section and dropdown (#34684)
* Add shipping class section and dropdown

* Add comment suggestions

* Add a Spinner during shipping classes resolution
2022-09-23 09:54:52 -03:00