File tree Expand file tree Collapse file tree 2 files changed +31
-2
lines changed
special-pages/pages/new-tab/app Expand file tree Collapse file tree 2 files changed +31
-2
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ children:
66 - ./update-notification/update-notification.md
77 - ./privacy-stats/privacy-stats.md
88 - ./favorites/favorites.md
9+ - ./next-steps/next-steps.md
910---
1011
1112## Requests
Original file line number Diff line number Diff line change 22title : Next Steps Cards
33---
44
5+ ## Setup
6+
7+ - Widget ID: ` nextSteps `
8+ - Add it to the ` widgets ` field on [ initialSetup] ( ../new-tab.md )
9+ - Example:
10+
11+ ``` json
12+ {
13+ "..." : " ..." ,
14+ "widgets" : [
15+ {"id" : " nextSteps" },
16+ {"..." : " ..." }
17+ ]
18+ }
19+ ```
20+
521## Requests:
622- {@link "NewTab Messages".NextStepsGetDataRequest ` nextSteps_getData ` }
723 - Used to fetch the initial data (during the first render)
8- - returns {@link "NewTab Messages".NextStepsData}
24+ - returns {@link "NewTab Messages".NextStepsData} - either ` null ` or ` Array<{id: string}> `
25+ - Note: Please use ` null ` to represent when there's nothing to show (instead of an empty array.)
26+ - IDs: Please find the list of supported IDs here {@link "NewTab Messages".NextStepsCards}
27+ - Example:
28+
29+ ``` json
30+ [
31+ { "id" : " bringStuff" },
32+ { "id" : " defaultApp" }
33+ ]
34+ ```
35+
936- {@link "NewTab Messages".NextStepsGetConfigRequest ` nextSteps_getConfig ` }
1037 - Used to fetch the initial config (during the first render)
1138 - returns {@link "NewTab Messages".NextStepsConfig}
@@ -14,8 +41,9 @@ title: Next Steps Cards
1441- {@link "NewTab Messages".NextStepsOnDataUpdateSubscription ` nextSteps_onDataUpdate ` }.
1542 - The messages available for the platform
1643 - returns {@link "NewTab Messages".NextStepsData}
44+ - as mentioned in the request, please use ` null ` to represent when there's nothing to show (instead of an empty array.)
1745- {@link "NewTab Messages".NextStepsOnConfigUpdateSubscription ` nextSteps_onConfigUpdate ` }.
18- - The widget config
46+ - The widget-specific config, to toggle things like the expansion
1947 - returns {@link "NewTab Messages".NextStepsConfig}
2048
2149## Notifications:
You can’t perform that action at this time.
0 commit comments