Skip to content

Commit

Permalink
Merge pull request #475 from woocommerce/tweak/externalize-jsdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
tomalec authored Jun 9, 2022
2 parents b64ac8d + a63ed58 commit 268c09a
Show file tree
Hide file tree
Showing 8 changed files with 184 additions and 252 deletions.
7 changes: 2 additions & 5 deletions .jsdocrc.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
{
"opts": {
"recurse": true
},
"plugins": [
"woo-tracking-jsdoc/tilde-alias.js",
"woo-tracking-jsdoc/fires-description.js",
"woocommerce-grow-jsdoc/tilde-alias",
"woocommerce-grow-tracking-jsdoc/fires-description",
"jsdoc-plugin-typescript"
],
"typescript": {
Expand Down
44 changes: 22 additions & 22 deletions TRACKING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ When a store opts in to WooCommerce usage tracking and uses _Pinterest for WooCo

As in WooCommerce core, only non-sensitive data about how a store is set up and managed is tracked. We **do not track or store personal data** from your clients.

<woo-tracking-jsdoc>
<woocommerce-grow-tracking-jsdoc>
<!---
Everything below will be automatically generated by `woo-tracking-jsdoc`.
Everything below will be automatically generated by `woocommerce-grow-tracking-jsdoc`.
Do not edit it manually!
-->

Expand All @@ -32,8 +32,8 @@ Clicking on "… create a new Pinterest account" button.
### [`wcadmin_pfw_account_disconnect_button_click`](assets/source/setup-guide/app/components/Account/Connection.js#L42)
Clicking on "Disconnect" Pinterest account button.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`context` | `string` | `'settings' \| 'wizard'` In which context it was used?
#### Emitters
- [`AccountConnection`](assets/source/setup-guide/app/components/Account/Connection.js#L82) with the given `{ context }`
Expand All @@ -56,8 +56,8 @@ Clicking on "Create business account" button.
### [`wcadmin_pfw_documentation_link_click`](assets/source/setup-guide/app/helpers/documentation-link-props.js#L6)
Clicking on an external documentation link.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`link_id` | `string` | Identifier of the link.
`context` | `string` | `'settings' \| 'welcome-section' \| 'wizard'` In which context the link was placed?
`href` | `string` | Href to which the user was navigated to.
Expand All @@ -77,8 +77,8 @@ Clicking on an external documentation link.
### [`wcadmin_pfw_domain_verify_failure`](assets/source/setup-guide/app/steps/ClaimWebsite.js#L69)
Triggered when domain verification fails.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`step` | `string` | Identifier of the step when verification failed.
#### Emitters
- [`ClaimWebsite`](assets/source/setup-guide/app/steps/ClaimWebsite.js#L99)
Expand All @@ -91,8 +91,8 @@ Triggered when a site is successfully verified.
### [`wcadmin_pfw_get_started_faq`](assets/source/setup-guide/app/views/LandingPageApp.js#L222)
Clicking on getting started page faq item to collapse or expand it.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`action` | `string` | `'expand' \| 'collapse'` What action was initiated.
`question_id` | `string` | Identifier of the clicked question.
#### Emitters
Expand All @@ -101,8 +101,8 @@ Clicking on getting started page faq item to collapse or expand it.
### [`wcadmin_pfw_get_started_notice_link_click`](assets/source/setup-guide/app/helpers/documentation-link-props.js#L16)
Clicking on the link inside the notice.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`link_id` | `string` | Identifier of the link.
`context` | `string` | What action was initiated.
`href` | `string` | Href to which the user was navigated to.
Expand All @@ -113,8 +113,8 @@ Clicking on the link inside the notice.
### [`wcadmin_pfw_modal_closed`](assets/source/setup-guide/app/components/Account/Connection.js#L55)
Closing a modal.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`name` | `string` | Which modal is it?
`context` | `string` | `'settings' \| 'wizard'` In which context it was used?
`action` | `string` | `confirm` - When the final "Yes, I'm sure" button is clicked. <br> `dismiss` - When the modal is dismissed by clicking on "x", "cancel", overlay, or by pressing a keystroke.
Expand All @@ -124,8 +124,8 @@ Closing a modal.
### [`wcadmin_pfw_modal_open`](assets/source/setup-guide/app/components/Account/Connection.js#L48)
Opening a modal.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`name` | `string` | Which modal is it?
`context` | `string` | `'settings' \| 'wizard'` In which context it was used?
#### Emitters
Expand All @@ -134,8 +134,8 @@ Opening a modal.
### [`wcadmin_pfw_save_changes_button_click`](assets/source/setup-guide/app/components/SaveSettingsButton.js#L19)
Clicking on "… Save changes" button.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`enable_debug_logging` | `boolean` | Indicates if Enable debug logging option is checked
`enhanced_match_support` | `boolean` | Indicates if Enhanced Match Support option is checked
`erase_plugin_data` | `boolean` | Indicates if Erase Plugin Data option is checked
Expand All @@ -152,8 +152,8 @@ Clicking on "… Save changes" button.
Triggered on events during setup,
like starting, ending, or navigating between steps.
#### Properties
| | | |
|---|---|---|
| name | type | description |
| ---- | ---- | ----------- |
`target` | `string` | Setup phase that the user navigates to.
`trigger` | `string` | UI element that triggered the action, e.g. `wizard-stepper` or `get-started` button.
#### Emitters
Expand All @@ -167,6 +167,6 @@ like starting, ending, or navigating between steps.
- with `{ target: 'setup-tracking', trigger: 'claim-website-continue' }` when continue button is clicked.

<!---
End of `woo-tracking-jsdoc`-generated content.
End of `woocommerce-grow-tracking-jsdoc`-generated content.
-->
</woo-tracking-jsdoc>
</woocommerce-grow-tracking-jsdoc>
157 changes: 157 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@
"prettier": "npm:wp-prettier@^2.2.1-beta-1",
"semver": "^6.0.0",
"stylelint": "^13.13.1",
"underscore": "^1.9.1"
"underscore": "^1.9.1",
"woocommerce-grow-jsdoc": "https://gitpkg.now.sh/woocommerce/grow/packages/js/jsdoc?9eb10353728dc915bf5f7bdd4b8e218c625355a9"
},
"eslintConfig": {
"extends": [
Expand Down Expand Up @@ -107,7 +108,7 @@
"postbuild": "composer install",
"build:zip": "npm run build",
"dev": "wp-scripts build && gulp build",
"doc:tracking": "jsdoc ./assets/source/ -c .jsdocrc.json -t ./woo-tracking-jsdoc",
"doc:tracking": "woocommerce-grow-jsdoc ./assets/source/",
"format:js": "wp-scripts format ./assets/source",
"lint:css": "wp-scripts lint-style ./assets/source",
"lint:css:fix": "wp-scripts lint-style ./assets/source --fix",
Expand Down
Loading

0 comments on commit 268c09a

Please sign in to comment.