Commit Graph

218 Commits

Author SHA1 Message Date
Chi-Hsuan Huang 3ead227cdc
Merge branch 'trunk' into update/admin-docs 2022-04-15 11:53:08 +08:00
Chi-Hsuan Huang b936e3243f Update feature-flags.md 2022-04-14 17:15:12 +08:00
Chi-Hsuan Huang c813c3bc5f Remove "plugin" environment from admin feature plugin 2022-04-14 16:40:35 +08:00
Chi-Hsuan Huang 20736a5280 Remove docsify-cli and releated files 2022-04-14 13:50:29 +08:00
Chi-Hsuan Huang dfa51ac747 Update docs 2022-04-14 13:50:27 +08:00
Chi-Hsuan Huang 96a5a7b75d Remove building ./docs storybook 2022-04-14 13:49:51 +08:00
Chi-Hsuan Huang ed8885f0b7 Fix admin extensions webpack config 2022-04-14 13:49:51 +08:00
Chi-Hsuan Huang 0ed8911875 Update admin docs README.md 2022-04-14 13:49:51 +08:00
Chi-Hsuan Huang 3fc88f0a71 Update links of woocommerce-admin to https://github.com/woocommerce/woocommerce 2022-04-07 17:02:43 +08:00
RJChow 26ec889111 Manually change i18n text domain from 'woocommerce-admin' to 'woocommerce' in WCA Client .md files 2022-04-01 11:41:32 +08:00
Joshua T Flowers 611903ef5d Separate onboarding concerns into separate classes (https://github.com/woocommerce/woocommerce-admin/pull/8280)
* Separate onboarding concerns into separate classes

* Fix up onboarding product types

* Fix up references to profile data option

* Fix up call to allowed themes

* Move onboarding features to internal namespace

* Remove old onboarding redirect

* Fix failing tests

* Add changelog entry

* Move inernal classes to the new src-internal folder

* Fix lint error

* Add deprecated class for Onboarding

* Add empty construct method

* Remove some of the unnecessary static functions and make sure OnboardingTasks still gets initialized

* Fix missed changes during rebase

* Fix tests

Co-authored-by: Lourens Schep <lourensschep@gmail.com>
2022-03-17 17:10:43 -03:00
louwie17 c65d43a35e Cleanup Loader.php and move it to Internal namespace (https://github.com/woocommerce/woocommerce-admin/pull/8416)
* Seperated Asset, page, and translation logic into seperate classes out of Loader.php

* Move user, and assets logic out of Loader.php

* Move Loader to Internal and move page helper functions to PageController

* Fix unit tests

* Add changelog
2022-03-09 10:04:34 -04:00
Chi-Hsuan Huang 86fc8b62e5 Switch to pnpm (https://github.com/woocommerce/woocommerce-admin/pull/8349)
* Add pnpm-workspace.yaml

* Add missing dependencies & replace file: with workspace:* in
package.json

* Replace "npm" with "pnpm"

* Replace "npx" with "pnpx"

* Remove package-lock.json

* Add pnpm setup action to github workflows

* Update webpack babel exclude path

* Upgrade woo e2e and fix e2e test command

Update e2e.yml

Use pnpm run e2e:docker-up in e2e.yml

* Remove unused docker-compose.yaml

* Replace lerna with pnpm commands

Update publish commands

* Exclude _locutus_shared_bc.js in babel.config.js

* Add .npmrc to set enable-pre-post-scripts=true by default

* Fix storybook babel config

Update babel.config.js

* Add changelog

* Update pnpm-lock.yaml

* Replace pnpx with pnpm exec

* Update pnpm-lock.yaml

* Remove js-tests/package-lock.json

* Fix @woocommerce/tracks -> workspace:*

* Update pnpm-lock.yaml

* Add @woocommerce/experimental to onboarding/package.json

* Add "@woocommerce/component" to onboarding/package.json

* Update pnpm-lock.yaml

* Use || instead of && for "test:watch"

Co-authored-by: RJ <27843274+rjchow@users.noreply.github.com>

* Fix packages/number "clean" command

* Add root: true to .eslintrc.js to enforce it to use the root config file

* Exclude packages/**/node_modules from babel transpiling

* Fix js-tests build config

Co-authored-by: RJ <27843274+rjchow@users.noreply.github.com>
2022-03-04 12:01:16 +08:00
Chi-Hsuan Huang bfa445f600 Add Spain to Square suggestion country list (https://github.com/woocommerce/woocommerce-admin/pull/8210)
* Add Spain to square_credit_card suggestion country list

* Fix payment-gateway-suggestions.md data source polling url

* Add changelog
2022-01-26 17:37:05 +08:00
louwie17 3998f88597 Remove unpublished wc-admin-settings package and update getSetting usage (https://github.com/woocommerce/woocommerce-admin/pull/8057)
* Remove use of wc-admin-settings from packages

* Move getSetting to getAdminSetting and remove wc-admin-settings package

* Add changelog

* Update package.json and remove last use of wc-admin-settings
2022-01-06 08:53:30 -04:00
Chi-Hsuan Huang f838727546 Replace all docs.woocommerce.com links with woocommerce.com's (https://github.com/woocommerce/woocommerce-admin/pull/8105)
* Replace all docs.woocommerce.com links with woocommerce.com/documentation
* Add changelogs

Update changelogs

* Update woocommerce-amazon-ebay-integration doc url
2022-01-04 17:03:58 +08:00
Ilyas Foo fd396d018d Add Inbox Note example code to docs (https://github.com/woocommerce/woocommerce-admin/pull/8019)
* Add Inbox Note example extension

* Typo

* Put into class

* Fix premature class import, moved note check logic to its own method
2021-12-10 12:52:03 +08:00
Joshua T Flowers 5f8db47c16 Add payment gateway suggestion docs and example extensions (https://github.com/woocommerce/woocommerce-admin/pull/7966)
* Remove dated doc references

* Clean up slotfill and install script docs

* Add filter to suggestion specs

* Register example gateways

* Mock gateway installation and activation

* Add simple gateway

* Update gateway IDs

* Add slot filled gateway

* Add slot fill for slot filled gateway

* Allow gateway to be enabled and marked as configured if already enabled

* Add changelog entry

* Add quick start blurb to markdown file

* Remove duplicate JS registration and add default export

* Add payment settings save hook
2021-12-03 15:13:05 -05:00
Joshua T Flowers 126707eeab Replace old task list option calls with data store selectors (https://github.com/woocommerce/woocommerce-admin/pull/7820)
* Add endpoint to unhide task list

* Rename show method to unhide

* Replace requests for hidden task list options

* Replace unhide task list requests

* Replace task list complete checks

* Replace dismiss option requests

* Remove complete task option check

* Fix up panel buttons

* Update finished setup to wait for task list resolution

* Create selector for getting a single task list

* Add selector for single task

* Fix task list panel visibility

* Add changelog entry

* Fix empty product types in profiler data

* Revert to checking for hidden task list
2021-11-15 15:57:13 -05:00
Joshua T Flowers 91473959c8 Update add task extension example (https://github.com/woocommerce/woocommerce-admin/pull/7809)
* Update task extension example

* Fix up namespaced classes

* Register task on init hook for REST usage
2021-10-27 15:03:27 -04:00
Joshua T Flowers 0e132febad Add onboarding task docs (https://github.com/woocommerce/woocommerce-admin/pull/7762)
* Add onboarding task docs

* Add data store actions and class arguments

* Add SlotFill examples

* Add missing spaces

* Add sort_by argument

* Add changelog entry
2021-10-13 15:17:57 -04:00
Joel Thiessen 3ee60dc833 Fixing an unwanted page refresh when using Woo Navigation (https://github.com/woocommerce/woocommerce-admin/pull/7615)
* Adding changelog

* Fixing page refresh on woo navigation

* Narrowing scope of navigation slot fills
2021-09-15 09:42:54 -07:00
Joshua T Flowers 8f836c292f Create task list APIs (https://github.com/woocommerce/woocommerce-admin/pull/7577)
* Add endpoint to hide task lists

* Migrate old setup task list hidden option

* Use option to store all hidden lists

* Add getter for deprecated options

* Migrate old task list options

* Move task lists into separate class

* Add TaskList class for individual task list control

* Update hidden checks to use TaskList api

* Update docs for hidden lists

* Update use of should_show_tasks to check for visible task lists

* Remove hide endpoint to reduce scope on PR

* Fix up failing tests

* Fix up rebase

* Add back in should_show_tasks with deprecation notice

* Add delay between payment tests
2021-09-02 17:40:02 -04:00
Jeff Stieler d3e940208e Refactor package style builds (https://github.com/woocommerce/woocommerce-admin/pull/7531)
* Build experimental package CSS with webpack.

* Move style-only webpack config to reusable private package.

* Update other packages to use webpack for style builds.

* Add tsbuildinfo to clean scripts.

* Fix main start script.

* Remove defunct package build scripts.

* Move client/ dependencies for style builds.

* DRY.

* Remove defunct IE stylesheet definitions.

* Add missing RTL setup for onboarding styles.

* No need to export a function.

* Add changelog.

* Fix README.

* Revert concurrently script path change.
2021-08-19 10:15:59 -04:00
David Levin c728cced1f Sentence case all the things analytics (https://github.com/woocommerce/woocommerce-admin/pull/6501)
* Sentence case all the things

* Update a few more things that were missed on the first round

* update documentation titles to use title case

* Add changelog

* Handle PR feedback

* Revert readme changelog changes

* Revert changes to ALT text in dev documentation

* Revert a change to ALT text in dev documentation

* Fix failing tests

Co-authored-by: David Levin <davidlevin@Davids-MacBook-Pro-2.local>
Co-authored-by: Joshua Flowers <joshuatf@gmail.com>
Co-authored-by: Adrian Duffell <9312929+adrianduffell@users.noreply.github.com>
2021-08-13 14:54:24 -04:00
Joshua T Flowers 0ab7c7a3ec Remove the preloaded onboarding options (https://github.com/woocommerce/woocommerce-admin/pull/7338)
* Remove unused options

* Remove preloade tracking option

* Remove preloaded wc_connect_options

* Remove preloaded modal options

* Refactor requesting options into task list component

* Remove preloaded dismissed and completed tasks

* Add changelog entry

* Wait for modal before attempting to dismiss

* Attempt to make closing welcome modal more robust

* Update the payment E2E tests to support new app flow

* Update isResolving selectors to hasFinishedResolution

Co-authored-by: Lourens Schep <lourensschep@gmail.com>
2021-08-10 14:58:01 -04:00
Allen Smith 52e69697f8 Fix Google Analytics tracking for static docs site. (https://github.com/woocommerce/woocommerce-admin/pull/7439) 2021-07-30 15:25:59 +12:00
Fernando 089c5b5905 Add a delete option to completed tasks (https://github.com/woocommerce/woocommerce-admin/pull/7300)
* Added onDelete prop to `task-item`.

* Added `onDelete` and `Remid me later` options to task example in docs.

* Added changelog

* Fixed lint error

* Fixed another lint error

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2021-07-06 15:35:40 -03:00
Joel Thiessen af97dd68b5 Fixing logic around recommended gateways in payment suggestions feature (https://github.com/woocommerce/woocommerce-admin/pull/7231) 2021-07-05 16:33:03 -07:00
Joshua T Flowers d8d14fb9ca Localize payment gateway suggestions on wccom (https://github.com/woocommerce/woocommerce-admin/pull/7217)
* Localize payment gateway suggestions on wccom

* Add user locale as param to source URL

* Fix mock http request params
2021-07-05 17:50:26 -04:00
Joshua T Flowers 7e20ebf866 Fix successful gateway configuration message (https://github.com/woocommerce/woocommerce-admin/pull/7251)
* Fix successful gateway configuration message

* Update language from connect to configure

* Fix connect component tests
2021-06-29 12:02:21 -04:00
Fernando 602056952f Add `slotFill` to Abbreviated Notification panel (https://github.com/woocommerce/woocommerce-admin/pull/7091)
* Add `slotfill` to Abbreviated Notification panel

This commit adds `slotfill` approach to Abbreviated Notification panel

# Conflicts:
#	client/header/activity-panel/index.js
#	client/header/activity-panel/panels/inbox/inbox-panel.js

* Renamed `AbbreviatedNotification` slot

# Conflicts:
#	client/header/activity-panel/panels/inbox/inbox-panel.js

* Renamed `hasExtraFills`

# Conflicts:
#	client/header/activity-panel/index.js
#	client/header/activity-panel/panels/inbox/inbox-panel.js

* Added changelog

* Fixed hasExtendedNotifications check

* Fixed changelog

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
2021-06-11 10:37:21 -03:00
Ilyas Foo bd51529aea Revert Card component removal (https://github.com/woocommerce/woocommerce-admin/pull/7167)
* Revert "Remove the deprecated Card component (https://github.com/woocommerce/woocommerce-admin/pull/7114)"

This reverts commit c07a5d77a6.

* Update changelog
2021-06-11 14:26:02 +08:00
Fernando 8ced81d369 Show task and activity notifications in the Inbox panel (https://github.com/woocommerce/woocommerce-admin/pull/7017)
* Added abbreviated panels

This commit adds abbreviated panels

* Added notifications getter

* Variables renamed

* Added unread-indicators refactor

* Open panel by default

* Refactor unread-indicators

* Renamed a few files and added event recording

* Modified "critical alert" presentation

* Removed useless control

* Renamed const

* Added control to InboxPanel component

* Multiple critical alerts handling

* Fixed styles

* Moved Inbox panel styles

# Conflicts:
#	packages/experimental/src/inbox-note/style.scss

* Added tests

* Inbox panel width reduced

* Small refactor for unread notifications

* Renamed abbreviated card component

* Added changelog

# Conflicts:
#	readme.txt

# Conflicts:
#	readme.txt

* Renamed inbox-panel and the cards config file

* Renamed unread notifications variable

* Fixed abbreviated card box-shadow

* Small refactor to unread-indicators file

* Refactored method getInitialState

* Added scroll to task list

# Conflicts:
#	client/task-list/task-list.js

* Small CSS changes to titles

* Fixed changelog

# Conflicts:
#	readme.txt

# Conflicts:
#	readme.txt

* Added param to filter `woocommerce_admin_onboarding_task_list`

* Removed extensibility from `getAbbreviatedNotifications`

* Fixed chunk name

* Removed `critical` prop from `AbbreviatedCard` comopnent

* Moved AbbreviatedCard component to `packages`

This commit moves the component `AbbreviatedCard` to `packages`

# Conflicts:
#	docs/components/_sidebar.md
#	packages/components/CHANGELOG.md
#	packages/components/src/index.js

# Conflicts:
#	packages/components/CHANGELOG.md

* Removed `critical alerts` tag from abbreviated card

This commit removes the tag `critical alerts` from the `Things to do next` abbreviated card

* Removed filter `woocommerce_admin_abbreviated_card_list`

* Fixed icon

* Added defaut value to `hasUnreadNotifications`

* Fix mapSelect error when the dismissed tasks option isn't populated.

* Added AbbreviatedNotificationsPanel

* Added tests

* Renamed `getUnreadNotes` to `isNotesPanelVisible`

* Removed abbreviated-card.js

* Added singular/plural copy handling

* Renamed method `getInitialState` to `getInitialOpenState`

* Fixed Link prop

* Revert "Fixed Link prop"

This reverts commit 74e6a7fae030766eb5d6be098caa15478f2cb2c6.

* Fixed Link prop

* Added task list visibility check

* Fixed scroll after redirect

# Conflicts:
#	client/task-list/index.js

* Added propType to `AbbreviatedCard`

* Fixed `Add-task doc example

* Removed default values from ActivityPanel

* Fixed multiple calls to a filter

Co-authored-by: Fernando Marichal <contacto@fernandomarichal.com>
Co-authored-by: Jeff Stieler <jeff.m.stieler@gmail.com>
2021-06-09 10:56:45 -03:00
Joshua T Flowers a2fa141bcb Update payment gateway suggestions semantics to be more consistent (https://github.com/woocommerce/woocommerce-admin/pull/7130)
* Rename and simplify frontend component names

* Rename feature flag and feature folder

* Rename transients and filters

* Rename SlotFills

* Fix feature name comment

* Update variable naming in payment suggestions

* Update WCPay Button component

* Rename suggestion key to id

* Rename recommended to recommendation

* Add changelog entry

* Update isConfigured to needsSetup

* Fix key id reference in WCPayMethodCard

* Update onboarding component filenames and exports

* Fix typo

* Add changelog entry

* Fix up remaining references to keys/ids
2021-06-08 13:40:57 -04:00
Sam Seay c07a5d77a6 Remove the deprecated Card component (https://github.com/woocommerce/woocommerce-admin/pull/7114) 2021-06-04 07:43:56 +12:00
Joshua T Flowers e86667de02 Add payment gateway return URL and action (https://github.com/woocommerce/woocommerce-admin/pull/7095)
* Add return URL argument to connection URL method

* Remove 'oauth' from connection URL method

* Add changelog entry
2021-06-03 10:15:41 -04:00
Sam Seay edc8a1bdc5 Publish storybook docs, remove react docgen based docs (https://github.com/woocommerce/woocommerce-admin/pull/7055) 2021-06-02 15:54:00 +12:00
Joshua T Flowers 8ab9af4b21 Update remote payment docs gateway methods (https://github.com/woocommerce/woocommerce-admin/pull/7079)
* Update remote payment docs gateway methods

* Add changelog entry

* Fix the description for the post install scripts
2021-06-01 14:07:04 -04:00
Tomek Wytrębowicz 9fbebae1a6 Reduce the specificity and complexity of the `ReportError` component (https://github.com/woocommerce/woocommerce-admin/pull/6846)
- Remove unused `isEmpty` prop from ReportError. 
- Remove `isError` prop from ReportError, as it is always set. Also, to reduce confusion that: Could "report error" be not an error?
- Remove default value of `className` prop from `ReportError`, it is unnecesary, as `EmptyContent` takes falsy values as well as `''`.
- Change `ReportError` to a function component.
2021-06-01 12:07:35 +02:00
Joel Thiessen bb7f1dc466 Refactoring WCPayCard into new onboarding package (https://github.com/woocommerce/woocommerce-admin/pull/7058) 2021-05-28 16:26:38 -07:00
louwie17 b642576e34 Remove the use of Dashicons and replace with `@wordpress/icons` or `gridicons` (https://github.com/woocommerce/woocommerce-admin/pull/7020)
* Updated mobile banner icon with cross-small gridicon

* Update analytics dashboard icons, removing use of dashicon

* Remove use of dash icon in tag component

* Remove dash icon from ellipsis menu

* Remove use of dashicon in calendar

* Update icon imports and remove use of Dashicon in collapsible list

* Remove Dashicon usage from store alerts as it is depreciated

* Remove dashicon usage in shipping label

* Fix up old css for icons

* Removed dashicon usage in favorite button

* Update the wordpress/icons package

* Add changelogs

* Fix broken test
2021-05-25 12:14:14 -03:00
Joshua T Flowers 685c012dfe Add transient notices feature (https://github.com/woocommerce/woocommerce-admin/pull/6809)
* Add PluginInstaller class

* Redirect to referring page if one exists

* Store message and show after redirect

* Add transient notices feature

* Fix default and empty state of notices

* Use TransientNotices to display plugin notices

* Add transient notices readme

* Add feature unit tests

* Update notice queue client-side

* Add filter to queued option prior to notice creation

* Use the core/notices2 data store

* Fix filtered queued notices

* Add methods to get individual notices and queue

* Allow user ID specific notices

* Remove errant script asset dependencies

* Add user ID property to docs

* Use preloaded option instead of window var

* Refactor transient notices to directly use option instead of state

* Show error message from WP_Error in plugin installer

* Add tests around notice queue in client

* Add changelog entry
2021-05-13 09:08:31 -04:00
Joshua T Flowers ca11fa7f9a Add remote payment gateway recommendations initial docs (https://github.com/woocommerce/woocommerce-admin/pull/6962) 2021-05-11 13:57:19 -04:00
Joshua T Flowers 8f018fc518 Add plugin installer to allow installation of plugins via URL (https://github.com/woocommerce/woocommerce-admin/pull/6805)
* Allow any plugin to be installed or activated

* Add PluginInstaller class

* Redirect to referring page if one exists

* Store message and show after redirect

* Add changelog and testing instructions
2021-04-16 15:45:43 -04:00
Joshua T Flowers 94a2ad98fd Fix use of feature checks and remove deprecated method calls (https://github.com/woocommerce/woocommerce-admin/pull/6687)
* Update all references to of Loader::is_feature_enabled to use Feature class

* Check if feature is enabled instead of existence in deprecated feature method

* Add changelog entry
2021-03-26 13:00:05 -04:00
Lee Willis d99fe58925 Remove hardcoded dependencies from examples. (https://github.com/woocommerce/woocommerce-admin/pull/6542)
Authored-by: Lee Willis <lee@ademti-software.co.uk>
2021-03-24 11:10:32 +13:00
Ilyas Foo 0be173f4fd Fix wrong filename for feature config (https://github.com/woocommerce/woocommerce-admin/pull/6557) 2021-03-11 08:40:26 +08:00
Lee Willis 7ffe4a0f85 Remove redundant code (https://github.com/woocommerce/woocommerce-admin/pull/6523)
Co-authored-by: Lee Willis <lee@ademti-software.co.uk>
2021-03-08 17:15:46 +13:00
Joshua T Flowers 851dac281c Add filter to allow the wp toolbar in navigation (https://github.com/woocommerce/woocommerce-admin/pull/6371)
* Add class to determine styling for disabled wp toolbar

* Use disabled toolbar class in onboarding setup wizard

* Add changelog and readme notes for filter
2021-02-19 08:20:32 -05:00