osuite 2.9.8 → 2.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +69 -37
- package/cli.js +405 -41
- package/osuite.js +9 -2
- package/package.json +2 -1
- package/projectHooks.js +741 -0
- package/reviewSurface.js +10 -2
package/reviewSurface.js
CHANGED
|
@@ -133,8 +133,16 @@ export function buildReviewSurface(action = {}, options = {}) {
|
|
|
133
133
|
]
|
|
134
134
|
: [];
|
|
135
135
|
|
|
136
|
-
const
|
|
137
|
-
const
|
|
136
|
+
const baseUrl = options.baseUrl ? String(options.baseUrl).replace(/\/$/, '') : null;
|
|
137
|
+
const replayUrl = baseUrl ? `${baseUrl}/replay/${actionId}` : null;
|
|
138
|
+
// A request still waiting is decided by a person in Studio, so point there.
|
|
139
|
+
const reviewUrl = baseUrl && action.status === 'pending_approval'
|
|
140
|
+
? `${baseUrl}/approvals?action=${encodeURIComponent(actionId)}`
|
|
141
|
+
: null;
|
|
142
|
+
const footer = [
|
|
143
|
+
...(reviewUrl ? ['', `${colorize('Review', BOLD, color)} ${reviewUrl}`] : []),
|
|
144
|
+
...(replayUrl ? [reviewUrl ? null : '', `${colorize('Replay', BOLD, color)} ${replayUrl}`].filter((line) => line !== null) : []),
|
|
145
|
+
];
|
|
138
146
|
|
|
139
147
|
return [
|
|
140
148
|
colorize(title, `${BOLD}${CYAN}`, color),
|