@stapel/alerts-react 0.1.1
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/CHANGELOG.md +109 -0
- package/LICENSE +21 -0
- package/MODULE.md +140 -0
- package/README.md +147 -0
- package/dist/analytics/events.d.ts +29 -0
- package/dist/analytics/events.d.ts.map +1 -0
- package/dist/analytics/events.js +28 -0
- package/dist/analytics/events.js.map +1 -0
- package/dist/api/alertsApi.d.ts +84 -0
- package/dist/api/alertsApi.d.ts.map +1 -0
- package/dist/api/alertsApi.js +127 -0
- package/dist/api/alertsApi.js.map +1 -0
- package/dist/api/generated/schema.d.ts +453 -0
- package/dist/api/generated/schema.d.ts.map +1 -0
- package/dist/api/generated/schema.js +2 -0
- package/dist/api/generated/schema.js.map +1 -0
- package/dist/api/types.d.ts +78 -0
- package/dist/api/types.d.ts.map +1 -0
- package/dist/api/types.js +44 -0
- package/dist/api/types.js.map +1 -0
- package/dist/default/FixIssueDialog.d.ts +15 -0
- package/dist/default/FixIssueDialog.d.ts.map +1 -0
- package/dist/default/FixIssueDialog.js +67 -0
- package/dist/default/FixIssueDialog.js.map +1 -0
- package/dist/default/IssueDetail.d.ts +10 -0
- package/dist/default/IssueDetail.d.ts.map +1 -0
- package/dist/default/IssueDetail.js +83 -0
- package/dist/default/IssueDetail.js.map +1 -0
- package/dist/default/IssueFilterBar.d.ts +21 -0
- package/dist/default/IssueFilterBar.d.ts.map +1 -0
- package/dist/default/IssueFilterBar.js +86 -0
- package/dist/default/IssueFilterBar.js.map +1 -0
- package/dist/default/IssuesFeed.d.ts +10 -0
- package/dist/default/IssuesFeed.d.ts.map +1 -0
- package/dist/default/IssuesFeed.js +137 -0
- package/dist/default/IssuesFeed.js.map +1 -0
- package/dist/default/MuteIssueDialog.d.ts +19 -0
- package/dist/default/MuteIssueDialog.d.ts.map +1 -0
- package/dist/default/MuteIssueDialog.js +72 -0
- package/dist/default/MuteIssueDialog.js.map +1 -0
- package/dist/default/index.d.ts +32 -0
- package/dist/default/index.d.ts.map +1 -0
- package/dist/default/index.js +26 -0
- package/dist/default/index.js.map +1 -0
- package/dist/default/labels.d.ts +40 -0
- package/dist/default/labels.d.ts.map +1 -0
- package/dist/default/labels.js +94 -0
- package/dist/default/labels.js.map +1 -0
- package/dist/default/layout.d.ts +32 -0
- package/dist/default/layout.d.ts.map +1 -0
- package/dist/default/layout.js +44 -0
- package/dist/default/layout.js.map +1 -0
- package/dist/default/types.d.ts +27 -0
- package/dist/default/types.d.ts.map +1 -0
- package/dist/default/types.js +2 -0
- package/dist/default/types.js.map +1 -0
- package/dist/flows/errors.d.ts +12 -0
- package/dist/flows/errors.d.ts.map +1 -0
- package/dist/flows/errors.js +13 -0
- package/dist/flows/errors.js.map +1 -0
- package/dist/flows/registry.d.ts +22 -0
- package/dist/flows/registry.d.ts.map +1 -0
- package/dist/flows/registry.js +20 -0
- package/dist/flows/registry.js.map +1 -0
- package/dist/headless/AlertsProvider.d.ts +19 -0
- package/dist/headless/AlertsProvider.d.ts.map +1 -0
- package/dist/headless/AlertsProvider.js +15 -0
- package/dist/headless/AlertsProvider.js.map +1 -0
- package/dist/i18n/errorsMap.d.ts +10 -0
- package/dist/i18n/errorsMap.d.ts.map +1 -0
- package/dist/i18n/errorsMap.js +20 -0
- package/dist/i18n/errorsMap.js.map +1 -0
- package/dist/i18n/es.d.ts +20 -0
- package/dist/i18n/es.d.ts.map +1 -0
- package/dist/i18n/es.js +152 -0
- package/dist/i18n/es.js.map +1 -0
- package/dist/i18n/generated/errors.es.gen.d.ts +9 -0
- package/dist/i18n/generated/errors.es.gen.d.ts.map +1 -0
- package/dist/i18n/generated/errors.es.gen.js +57 -0
- package/dist/i18n/generated/errors.es.gen.js.map +1 -0
- package/dist/i18n/generated/errors.gen.d.ts +323 -0
- package/dist/i18n/generated/errors.gen.d.ts.map +1 -0
- package/dist/i18n/generated/errors.gen.js +165 -0
- package/dist/i18n/generated/errors.gen.js.map +1 -0
- package/dist/i18n/generated/errors.ru.gen.d.ts +9 -0
- package/dist/i18n/generated/errors.ru.gen.d.ts.map +1 -0
- package/dist/i18n/generated/errors.ru.gen.js +57 -0
- package/dist/i18n/generated/errors.ru.gen.js.map +1 -0
- package/dist/i18n/keys.d.ts +164 -0
- package/dist/i18n/keys.d.ts.map +1 -0
- package/dist/i18n/keys.js +300 -0
- package/dist/i18n/keys.js.map +1 -0
- package/dist/i18n/ru.d.ts +27 -0
- package/dist/i18n/ru.d.ts.map +1 -0
- package/dist/i18n/ru.js +159 -0
- package/dist/i18n/ru.js.map +1 -0
- package/dist/index.d.ts +42 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +45 -0
- package/dist/index.js.map +1 -0
- package/dist/model/context.d.ts +11 -0
- package/dist/model/context.d.ts.map +1 -0
- package/dist/model/context.js +16 -0
- package/dist/model/context.js.map +1 -0
- package/dist/model/issues.d.ts +103 -0
- package/dist/model/issues.d.ts.map +1 -0
- package/dist/model/issues.js +230 -0
- package/dist/model/issues.js.map +1 -0
- package/dist/model/queryKeys.d.ts +11 -0
- package/dist/model/queryKeys.d.ts.map +1 -0
- package/dist/model/queryKeys.js +32 -0
- package/dist/model/queryKeys.js.map +1 -0
- package/dist/model/refusals.d.ts +25 -0
- package/dist/model/refusals.d.ts.map +1 -0
- package/dist/model/refusals.js +73 -0
- package/dist/model/refusals.js.map +1 -0
- package/dist/model/runtime.d.ts +51 -0
- package/dist/model/runtime.d.ts.map +1 -0
- package/dist/model/runtime.js +29 -0
- package/dist/model/runtime.js.map +1 -0
- package/dist/model/status.d.ts +60 -0
- package/dist/model/status.d.ts.map +1 -0
- package/dist/model/status.js +116 -0
- package/dist/model/status.js.map +1 -0
- package/dist/nav/manifest.d.ts +43 -0
- package/dist/nav/manifest.d.ts.map +1 -0
- package/dist/nav/manifest.js +36 -0
- package/dist/nav/manifest.js.map +1 -0
- package/llms.txt +84 -0
- package/manifest.json +694 -0
- package/nav-manifest.json +46 -0
- package/package.json +119 -0
- package/src/analytics/events.ts +29 -0
- package/src/analytics/generated/events.json +7 -0
- package/src/api/alertsApi.ts +259 -0
- package/src/api/generated/schema.ts +455 -0
- package/src/api/types.ts +113 -0
- package/src/default/FixIssueDialog.tsx +158 -0
- package/src/default/IssueDetail.tsx +431 -0
- package/src/default/IssueFilterBar.tsx +197 -0
- package/src/default/IssuesFeed.tsx +343 -0
- package/src/default/MuteIssueDialog.tsx +186 -0
- package/src/default/index.ts +37 -0
- package/src/default/labels.ts +113 -0
- package/src/default/layout.ts +52 -0
- package/src/default/types.ts +27 -0
- package/src/flows/errors.ts +16 -0
- package/src/flows/registry.ts +32 -0
- package/src/headless/AlertsProvider.tsx +20 -0
- package/src/i18n/errorsMap.ts +31 -0
- package/src/i18n/es.ts +181 -0
- package/src/i18n/generated/errors.es.gen.ts +63 -0
- package/src/i18n/generated/errors.gen.ts +196 -0
- package/src/i18n/generated/errors.json +370 -0
- package/src/i18n/generated/errors.ru.gen.ts +63 -0
- package/src/i18n/keys.ts +341 -0
- package/src/i18n/ru.ts +188 -0
- package/src/index.ts +152 -0
- package/src/model/context.tsx +28 -0
- package/src/model/issues.ts +311 -0
- package/src/model/queryKeys.ts +41 -0
- package/src/model/refusals.ts +82 -0
- package/src/model/runtime.ts +80 -0
- package/src/model/status.ts +179 -0
- package/src/nav/manifest.ts +76 -0
- package/tsconfig.json +26 -0
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The two reads — the triage feed and one issue — and the ETag machinery that
|
|
3
|
+
* makes re-asking cheap.
|
|
4
|
+
*
|
|
5
|
+
* ── The validator lives in the CACHE ENTRY, not in a ref ──────────────────
|
|
6
|
+
*
|
|
7
|
+
* The obvious place to keep an `ETag` is a `useRef` beside the query. It is
|
|
8
|
+
* the wrong place: two panes mounted on the same filters are two refs over one
|
|
9
|
+
* cache entry, an unmount throws the validator away while the rows survive,
|
|
10
|
+
* and a re-mount then asks unconditionally for a page it already has.
|
|
11
|
+
*
|
|
12
|
+
* So the cached VALUE is `{etag, page}` — the rows and the validator the
|
|
13
|
+
* server issued for exactly those rows, stored together because that is what
|
|
14
|
+
* they are. `queryFn` reads the previous entry, offers its validator, and on a
|
|
15
|
+
* 304 returns **the previous object itself**. Same reference in, same
|
|
16
|
+
* reference out: TanStack compares by identity, sees nothing changed, and
|
|
17
|
+
* notifies nobody — so a feed polling every minute through a quiet night
|
|
18
|
+
* repaints exactly zero times.
|
|
19
|
+
*
|
|
20
|
+
* A validator is offered only when there ARE previous rows to keep. "I have a
|
|
21
|
+
* validator but no data" is a state this hook cannot reach, and the one arm
|
|
22
|
+
* that could produce it (a 304 with an empty cache) re-asks without the
|
|
23
|
+
* validator rather than inventing an empty page.
|
|
24
|
+
*/
|
|
25
|
+
import { useCallback, useState } from "react";
|
|
26
|
+
import { useQuery, useQueryClient } from "@tanstack/react-query";
|
|
27
|
+
import { loadStateFromQuery, mapLoad, useActiveSessionReady } from "@stapel/core";
|
|
28
|
+
import { useAlertsApi, useAlertsRuntime } from "./context.js";
|
|
29
|
+
import { alertsQueryKeys } from "./queryKeys.js";
|
|
30
|
+
/**
|
|
31
|
+
* A stable cache identity for a filter set. Sorted, so `{level, service}` and
|
|
32
|
+
* `{service, level}` are ONE cache entry rather than two copies of the same
|
|
33
|
+
* page that invalidate independently — and so the same two filters always
|
|
34
|
+
* offer the same validator.
|
|
35
|
+
*/
|
|
36
|
+
export function issueFiltersKey(filters) {
|
|
37
|
+
if (filters === undefined)
|
|
38
|
+
return "";
|
|
39
|
+
const parts = [];
|
|
40
|
+
if (filters.status !== undefined)
|
|
41
|
+
parts.push(`status=${filters.status}`);
|
|
42
|
+
if (filters.level !== undefined)
|
|
43
|
+
parts.push(`level=${filters.level}`);
|
|
44
|
+
if (filters.service !== undefined)
|
|
45
|
+
parts.push(`service=${filters.service}`);
|
|
46
|
+
if (filters.since !== undefined)
|
|
47
|
+
parts.push(`since=${filters.since}`);
|
|
48
|
+
if (filters.open !== undefined)
|
|
49
|
+
parts.push(`open=${String(filters.open)}`);
|
|
50
|
+
if (filters.offset !== undefined)
|
|
51
|
+
parts.push(`offset=${String(filters.offset)}`);
|
|
52
|
+
if (filters.limit !== undefined)
|
|
53
|
+
parts.push(`limit=${String(filters.limit)}`);
|
|
54
|
+
return parts.sort().join("&");
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* The filters with every FILTER removed and the page size kept: `limit` is a
|
|
58
|
+
* view setting, not a question about the rows, so "Clear" must not turn a
|
|
59
|
+
* host's hundred-row page back into fifty.
|
|
60
|
+
*/
|
|
61
|
+
export function clearedIssueFilters(filters) {
|
|
62
|
+
return filters.limit === undefined ? {} : { limit: filters.limit };
|
|
63
|
+
}
|
|
64
|
+
const LEVEL_RANK = {
|
|
65
|
+
debug: 0,
|
|
66
|
+
info: 1,
|
|
67
|
+
warning: 2,
|
|
68
|
+
error: 3,
|
|
69
|
+
fatal: 4,
|
|
70
|
+
};
|
|
71
|
+
/**
|
|
72
|
+
* Group a page's rows by reporting service, worst-first.
|
|
73
|
+
*
|
|
74
|
+
* Pure and exported: "which service is on fire" is the first question the feed
|
|
75
|
+
* answers, and it must be answerable in a test without a render. Services are
|
|
76
|
+
* ordered by their worst level and then by how loud they are, because a
|
|
77
|
+
* service with one fatal outranks a service with two hundred warnings — and
|
|
78
|
+
* alphabetical order would bury it under `auth`.
|
|
79
|
+
*/
|
|
80
|
+
export function groupIssuesByService(issues) {
|
|
81
|
+
const byService = new Map();
|
|
82
|
+
for (const issue of issues) {
|
|
83
|
+
const rows = byService.get(issue.service);
|
|
84
|
+
if (rows)
|
|
85
|
+
rows.push(issue);
|
|
86
|
+
else
|
|
87
|
+
byService.set(issue.service, [issue]);
|
|
88
|
+
}
|
|
89
|
+
const groups = [];
|
|
90
|
+
for (const [service, rows] of byService) {
|
|
91
|
+
let worst = "debug";
|
|
92
|
+
let count = 0;
|
|
93
|
+
for (const row of rows) {
|
|
94
|
+
count += row.count;
|
|
95
|
+
if ((LEVEL_RANK[row.level] ?? 0) > (LEVEL_RANK[worst] ?? 0)) {
|
|
96
|
+
worst = row.level;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
groups.push({ service, issues: rows, worstLevel: worst, count });
|
|
100
|
+
}
|
|
101
|
+
return groups.sort((a, b) => (LEVEL_RANK[b.worstLevel] ?? 0) - (LEVEL_RANK[a.worstLevel] ?? 0) ||
|
|
102
|
+
b.count - a.count ||
|
|
103
|
+
a.service.localeCompare(b.service));
|
|
104
|
+
}
|
|
105
|
+
/** The shape a 304 with nothing to keep degrades to — see the module header. */
|
|
106
|
+
const EMPTY_PAGE = { count: 0, offset: 0, limit: 0, results: [] };
|
|
107
|
+
/**
|
|
108
|
+
* The triage feed.
|
|
109
|
+
*
|
|
110
|
+
* The page cursor is INSIDE the hook and resets to zero whenever the filters
|
|
111
|
+
* change — the alternative (a caller-held offset) reliably leaves somebody on
|
|
112
|
+
* page 4 of a filter with one page, looking at an empty screen that is not
|
|
113
|
+
* empty.
|
|
114
|
+
*
|
|
115
|
+
* `filters.limit` is passed through as `?limit=`; the hook still pages by the
|
|
116
|
+
* size the envelope echoes, so a request the server clamped cannot skip rows.
|
|
117
|
+
*/
|
|
118
|
+
export function useIssues(filters = {}, options = {}) {
|
|
119
|
+
const api = useAlertsApi();
|
|
120
|
+
const runtime = useAlertsRuntime();
|
|
121
|
+
const queryClient = useQueryClient();
|
|
122
|
+
const sessionReady = useActiveSessionReady();
|
|
123
|
+
const enabled = sessionReady && (options.enabled ?? true);
|
|
124
|
+
const filtersKey = issueFiltersKey(filters);
|
|
125
|
+
// Derived-during-render reset: a filter change is a new question, and the
|
|
126
|
+
// answer to it starts at its first page. No effect, so there is no frame in
|
|
127
|
+
// which the old offset is applied to the new filters.
|
|
128
|
+
const [cursor, setCursor] = useState({
|
|
129
|
+
key: filtersKey,
|
|
130
|
+
offset: 0,
|
|
131
|
+
});
|
|
132
|
+
const offset = cursor.key === filtersKey ? cursor.offset : 0;
|
|
133
|
+
const queryKey = alertsQueryKeys.issueList(issueFiltersKey({ ...filters, offset }));
|
|
134
|
+
const query = useQuery({
|
|
135
|
+
queryKey,
|
|
136
|
+
queryFn: async ({ signal }) => {
|
|
137
|
+
const previous = queryClient.getQueryData(queryKey);
|
|
138
|
+
const request = { ...filters, offset };
|
|
139
|
+
const answer = await api.issues(request, {
|
|
140
|
+
// Offered only when there are rows the validator belongs to.
|
|
141
|
+
etag: previous ? previous.etag : null,
|
|
142
|
+
signal,
|
|
143
|
+
});
|
|
144
|
+
if (answer.outcome === "unchanged") {
|
|
145
|
+
// The identity IS the message: same object, so nothing re-renders.
|
|
146
|
+
if (previous)
|
|
147
|
+
return previous;
|
|
148
|
+
const fresh = await api.issues(request, { signal });
|
|
149
|
+
return fresh.outcome === "modified"
|
|
150
|
+
? { etag: fresh.etag, page: fresh.data }
|
|
151
|
+
: { etag: fresh.etag, page: EMPTY_PAGE };
|
|
152
|
+
}
|
|
153
|
+
return { etag: answer.etag, page: answer.data };
|
|
154
|
+
},
|
|
155
|
+
enabled,
|
|
156
|
+
// No stream in this module, so the feed asks. Conditionally, which is why
|
|
157
|
+
// the backend put an ETag on this route in the first place.
|
|
158
|
+
refetchInterval: runtime.pollIntervalMs > 0 ? runtime.pollIntervalMs : false,
|
|
159
|
+
});
|
|
160
|
+
const snapshot = loadStateFromQuery(query);
|
|
161
|
+
const page = query.data?.page;
|
|
162
|
+
const pageSize = page?.limit ?? 0;
|
|
163
|
+
const total = page?.count ?? 0;
|
|
164
|
+
const goto = useCallback((next) => setCursor({ key: filtersKey, offset: Math.max(0, next) }), [filtersKey]);
|
|
165
|
+
return {
|
|
166
|
+
rows: mapLoad(snapshot, (s) => s.page.results),
|
|
167
|
+
groups: mapLoad(snapshot, (s) => groupIssuesByService(s.page.results)),
|
|
168
|
+
total,
|
|
169
|
+
pageSize,
|
|
170
|
+
offset,
|
|
171
|
+
hasPrevious: offset > 0,
|
|
172
|
+
hasNext: pageSize > 0 && offset + pageSize < total,
|
|
173
|
+
previousPage: () => goto(offset - (pageSize || 0)),
|
|
174
|
+
nextPage: () => goto(offset + (pageSize || 0)),
|
|
175
|
+
etag: query.data?.etag ?? null,
|
|
176
|
+
refetch: () => {
|
|
177
|
+
void query.refetch();
|
|
178
|
+
},
|
|
179
|
+
isFetching: query.isFetching,
|
|
180
|
+
};
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* One issue, with its last events — the read the detail screen is built on.
|
|
184
|
+
*
|
|
185
|
+
* Conditional in the same way as the feed, and for a sharper reason: an issue
|
|
186
|
+
* detail carries up to twenty full tracebacks, which is the largest body this
|
|
187
|
+
* module serves and the one nobody wants re-sent every minute.
|
|
188
|
+
*/
|
|
189
|
+
export function useIssue(issueId, options = {}) {
|
|
190
|
+
const api = useAlertsApi();
|
|
191
|
+
const runtime = useAlertsRuntime();
|
|
192
|
+
const queryClient = useQueryClient();
|
|
193
|
+
const sessionReady = useActiveSessionReady();
|
|
194
|
+
const enabled = sessionReady && issueId !== undefined && (options.enabled ?? true);
|
|
195
|
+
const queryKey = alertsQueryKeys.issue(issueId ?? "");
|
|
196
|
+
const query = useQuery({
|
|
197
|
+
queryKey,
|
|
198
|
+
queryFn: async ({ signal }) => {
|
|
199
|
+
const previous = queryClient.getQueryData(queryKey);
|
|
200
|
+
const id = issueId ?? "";
|
|
201
|
+
const answer = await api.issue(id, {
|
|
202
|
+
etag: previous ? previous.etag : null,
|
|
203
|
+
signal,
|
|
204
|
+
});
|
|
205
|
+
if (answer.outcome === "unchanged") {
|
|
206
|
+
if (previous)
|
|
207
|
+
return previous;
|
|
208
|
+
const fresh = await api.issue(id, { signal });
|
|
209
|
+
if (fresh.outcome === "modified") {
|
|
210
|
+
return { etag: fresh.etag, detail: fresh.data };
|
|
211
|
+
}
|
|
212
|
+
throw new Error("alerts: a conditional read answered 304 with no cache");
|
|
213
|
+
}
|
|
214
|
+
return { etag: answer.etag, detail: answer.data };
|
|
215
|
+
},
|
|
216
|
+
enabled,
|
|
217
|
+
refetchInterval: runtime.pollIntervalMs > 0 ? runtime.pollIntervalMs : false,
|
|
218
|
+
});
|
|
219
|
+
const snapshot = loadStateFromQuery(query);
|
|
220
|
+
return {
|
|
221
|
+
state: mapLoad(snapshot, (s) => s.detail),
|
|
222
|
+
events: mapLoad(snapshot, (s) => s.detail.events),
|
|
223
|
+
etag: query.data?.etag ?? null,
|
|
224
|
+
refetch: () => {
|
|
225
|
+
void query.refetch();
|
|
226
|
+
},
|
|
227
|
+
isFetching: query.isFetching,
|
|
228
|
+
};
|
|
229
|
+
}
|
|
230
|
+
//# sourceMappingURL=issues.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"issues.js","sourceRoot":"","sources":["../../src/model/issues.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC9C,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,EAAE,kBAAkB,EAAE,OAAO,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAIlF,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAC9D,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAiBjD;;;;;GAKG;AACH,MAAM,UAAU,eAAe,CAAC,OAAsB;IACpD,IAAI,OAAO,KAAK,SAAS;QAAE,OAAO,EAAE,CAAC;IACrC,MAAM,KAAK,GAAa,EAAE,CAAC;IAC3B,IAAI,OAAO,CAAC,MAAM,KAAK,SAAS;QAAE,KAAK,CAAC,IAAI,CAAC,UAAU,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC;IACzE,IAAI,OAAO,CAAC,KAAK,KAAK,SAAS;QAAE,KAAK,CAAC,IAAI,CAAC,SAAS,OAAO,CAAC,KAAK,EAAE,CAAC,CAAC;IACtE,IAAI,OAAO,CAAC,OAAO,KAAK,SAAS;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O,CAAC,QAAQ,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC;QACzC,MAAM,EAAE,OAAO,CAAC,QAAQ,EAAE,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,MAAM,CAAC;QACjD,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,IAAI,IAAI,IAAI;QAC9B,OAAO,EAAE,GAAG,EAAE;YACZ,KAAK,KAAK,CAAC,OAAO,EAAE,CAAC;QACvB,CAAC;QACD,UAAU,EAAE,KAAK,CAAC,UAAU;KAC7B,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const alertsQueryKeys: {
|
|
2
|
+
/** Everything this module caches — the one invalidation a host needs. */
|
|
3
|
+
readonly all: readonly ["alerts"];
|
|
4
|
+
/** Every issue read (the invalidation a write targets). */
|
|
5
|
+
readonly issues: readonly ["alerts", "issues"];
|
|
6
|
+
/** One filtered page. `filtersKey` is a stable serialization of the query. */
|
|
7
|
+
issueList(filtersKey: string): readonly ["alerts", "issues", "list", string];
|
|
8
|
+
/** One issue by id, with its events. */
|
|
9
|
+
issue(issueId: string): readonly ["alerts", "issues", "one", string];
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=queryKeys.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryKeys.d.ts","sourceRoot":"","sources":["../../src/model/queryKeys.ts"],"names":[],"mappings":"AA0BA,eAAO,MAAM,eAAe,EAAE;IAC5B,yEAAyE;IACzE,QAAQ,CAAC,GAAG,EAAE,SAAS,CAAC,QAAQ,CAAC,CAAC;IAClC,2DAA2D;IAC3D,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC,QAAQ,EAAE,QAAQ,CAAC,CAAC;IAC/C,8EAA8E;IAC9E,SAAS,CAAC,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;IAC7E,wCAAwC;IACxC,KAAK,CAAC,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC,QAAQ,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,CAAC,CAAC;CAMtE,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Namespaced TanStack Query keys (frontend-standard §2 — "keys are
|
|
3
|
+
* namespaced"). Everything under the `"alerts"` root, so a host can invalidate
|
|
4
|
+
* the whole module, one resource, or one row. Explicit tuple return types
|
|
5
|
+
* satisfy `--isolatedDeclarations`.
|
|
6
|
+
*
|
|
7
|
+
* ── The list key carries the FILTERS **and** the offset ───────────────────
|
|
8
|
+
*
|
|
9
|
+
* Those are different server answers, so they are different cache entries. A
|
|
10
|
+
* key that ignored the filters would show the "fatal only" view the rows it
|
|
11
|
+
* had already fetched for "everything" — on the one screen whose job is
|
|
12
|
+
* deciding what is on fire.
|
|
13
|
+
*
|
|
14
|
+
* The offset is in the key for the same reason and one more: the ETag a page
|
|
15
|
+
* carries is the validator for THAT page. Sharing a cache entry across offsets
|
|
16
|
+
* would mean offering a validator for rows 0–49 on a request for rows 50–99,
|
|
17
|
+
* and a matching 304 would then keep the wrong page on screen.
|
|
18
|
+
*
|
|
19
|
+
* ── Nothing here is keyed by a user id ────────────────────────────────────
|
|
20
|
+
*
|
|
21
|
+
* Every read is the same tracker for every operator: the rows are a property
|
|
22
|
+
* of the fleet, not of the reader. Core's query runtime partitions the
|
|
23
|
+
* persisted cache per user, and sign-out clears it.
|
|
24
|
+
*/
|
|
25
|
+
const ROOT = "alerts";
|
|
26
|
+
export const alertsQueryKeys = {
|
|
27
|
+
all: [ROOT],
|
|
28
|
+
issues: [ROOT, "issues"],
|
|
29
|
+
issueList: (filtersKey) => [ROOT, "issues", "list", filtersKey],
|
|
30
|
+
issue: (issueId) => [ROOT, "issues", "one", issueId],
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=queryKeys.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryKeys.js","sourceRoot":"","sources":["../../src/model/queryKeys.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,IAAI,GAAG,QAAiB,CAAC;AAE/B,MAAM,CAAC,MAAM,eAAe,GASxB;IACF,GAAG,EAAE,CAAC,IAAI,CAAC;IACX,MAAM,EAAE,CAAC,IAAI,EAAE,QAAQ,CAAC;IACxB,SAAS,EAAE,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,UAAU,CAAC;IAC/D,KAAK,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,CAAC;CACrD,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { FlowError } from "@stapel/core";
|
|
2
|
+
/** A status the store sets from evidence. Carries `{status}`. A **400**. */
|
|
3
|
+
export declare const ALERTS_ERROR_STATUS_NOT_SETTABLE = "error.400.alerts_status_not_settable";
|
|
4
|
+
/** No session reached the tracker at all. A **401**. */
|
|
5
|
+
export declare const ALERTS_ERROR_UNAUTHORIZED = "error.401.unauthorized";
|
|
6
|
+
/** Signed in, and not staff. The tracker wall. A **403**. */
|
|
7
|
+
export declare const ALERTS_ERROR_FORBIDDEN = "error.403.forbidden";
|
|
8
|
+
/** No issue with that id — it may have been swept, or the link is old. **404**. */
|
|
9
|
+
export declare const ALERTS_ERROR_ISSUE_NOT_FOUND = "error.404.alerts_issue_not_found";
|
|
10
|
+
/** Fold any thrown value into this pair's error dialect. */
|
|
11
|
+
export declare function toAlertsError(error: unknown): FlowError;
|
|
12
|
+
/** Nobody is signed in (or the session expired between two reads). */
|
|
13
|
+
export declare function isAlertsUnauthorized(error: unknown): boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Signed in, but not staff — the tracker wall.
|
|
16
|
+
*
|
|
17
|
+
* The one refusal every screen in this pair must be able to draw, because it
|
|
18
|
+
* is the answer the whole surface gives to most of a host's accounts.
|
|
19
|
+
*/
|
|
20
|
+
export declare function isAlertsStaffOnly(error: unknown): boolean;
|
|
21
|
+
/** No issue with that id (swept, or a stale `alerts:<id>` in a commit). */
|
|
22
|
+
export declare function isIssueNotFound(error: unknown): boolean;
|
|
23
|
+
/** The store, declining to be told what it is supposed to have observed. */
|
|
24
|
+
export declare function isStatusNotSettable(error: unknown): boolean;
|
|
25
|
+
//# sourceMappingURL=refusals.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refusals.d.ts","sourceRoot":"","sources":["../../src/model/refusals.ts"],"names":[],"mappings":"AAsCA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAE9C,4EAA4E;AAC5E,eAAO,MAAM,gCAAgC,yCACL,CAAC;AACzC,wDAAwD;AACxD,eAAO,MAAM,yBAAyB,2BAA2B,CAAC;AAClE,6DAA6D;AAC7D,eAAO,MAAM,sBAAsB,wBAAwB,CAAC;AAC5D,mFAAmF;AACnF,eAAO,MAAM,4BAA4B,qCAAqC,CAAC;AAE/E,4DAA4D;AAC5D,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,SAAS,CAEvD;AAKD,sEAAsE;AACtE,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAE5D;AAED;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAEzD;AAED,2EAA2E;AAC3E,wBAAgB,eAAe,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAEvD;AAED,4EAA4E;AAC5E,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAE3D"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The refusals this pair has to tell apart, and the reason every one of them
|
|
3
|
+
* is read by CODE and never by status.
|
|
4
|
+
*
|
|
5
|
+
* | status | code | what it actually means |
|
|
6
|
+
* |--------|---------------------------------|------------------------------------|
|
|
7
|
+
* | 400 | `alerts_status_not_settable` | the store asserts that status, not you |
|
|
8
|
+
* | 401 | `unauthorized` | no session reached the tracker |
|
|
9
|
+
* | 403 | `forbidden` | signed in, but not staff |
|
|
10
|
+
* | 404 | `alerts_issue_not_found` | no issue with that id |
|
|
11
|
+
*
|
|
12
|
+
* ── The 403 is the whole authorization story, and it is not a fault ───────
|
|
13
|
+
*
|
|
14
|
+
* Every tracker route is `IsStaffUser`. The nav axis has two values
|
|
15
|
+
* (`public` | `member`) and cannot say "staff", so the SCREEN says it: the
|
|
16
|
+
* door stays visible and the pane names the refusal
|
|
17
|
+
* ({@link isAlertsStaffOnly}) rather than drawing an empty triage table at
|
|
18
|
+
* somebody signed in with the wrong account. A hidden door teaches nobody
|
|
19
|
+
* anything; an empty table teaches the wrong thing — "nothing is broken".
|
|
20
|
+
*
|
|
21
|
+
* ── The 401 and the 403 are different sentences ───────────────────────────
|
|
22
|
+
*
|
|
23
|
+
* A 401 is "sign in"; a 403 is "you are signed in as the wrong person". The
|
|
24
|
+
* raw conditional reads (`api/alertsApi.ts`) do not run core's bearer-refresh
|
|
25
|
+
* retry, so a 401 on a read is also the shape an expired token takes here —
|
|
26
|
+
* which is exactly the case where "sign in again" is the right copy and
|
|
27
|
+
* "you do not have permission" is a lie.
|
|
28
|
+
*
|
|
29
|
+
* ── The 400 is the store refusing to be told what it observed ─────────────
|
|
30
|
+
*
|
|
31
|
+
* `regressed` is not a settable status (`serializers.SETTABLE_STATUSES`).
|
|
32
|
+
* Nothing in this pair offers it — {@link SETTABLE_ISSUE_STATUSES} is the list
|
|
33
|
+
* every control is built from — so {@link isStatusNotSettable} exists for the
|
|
34
|
+
* host that wired its own control, and for the day the backend narrows the set
|
|
35
|
+
* further. A refusal nobody can provoke from our own UI is still a refusal the
|
|
36
|
+
* UI must be able to render.
|
|
37
|
+
*/
|
|
38
|
+
import { isErrorCode, toFlowError } from "@stapel/core";
|
|
39
|
+
/** A status the store sets from evidence. Carries `{status}`. A **400**. */
|
|
40
|
+
export const ALERTS_ERROR_STATUS_NOT_SETTABLE = "error.400.alerts_status_not_settable";
|
|
41
|
+
/** No session reached the tracker at all. A **401**. */
|
|
42
|
+
export const ALERTS_ERROR_UNAUTHORIZED = "error.401.unauthorized";
|
|
43
|
+
/** Signed in, and not staff. The tracker wall. A **403**. */
|
|
44
|
+
export const ALERTS_ERROR_FORBIDDEN = "error.403.forbidden";
|
|
45
|
+
/** No issue with that id — it may have been swept, or the link is old. **404**. */
|
|
46
|
+
export const ALERTS_ERROR_ISSUE_NOT_FOUND = "error.404.alerts_issue_not_found";
|
|
47
|
+
/** Fold any thrown value into this pair's error dialect. */
|
|
48
|
+
export function toAlertsError(error) {
|
|
49
|
+
return toFlowError(error, "alerts.error.unknown");
|
|
50
|
+
}
|
|
51
|
+
const is = (error, code) => isErrorCode(toAlertsError(error), code);
|
|
52
|
+
/** Nobody is signed in (or the session expired between two reads). */
|
|
53
|
+
export function isAlertsUnauthorized(error) {
|
|
54
|
+
return is(error, ALERTS_ERROR_UNAUTHORIZED);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Signed in, but not staff — the tracker wall.
|
|
58
|
+
*
|
|
59
|
+
* The one refusal every screen in this pair must be able to draw, because it
|
|
60
|
+
* is the answer the whole surface gives to most of a host's accounts.
|
|
61
|
+
*/
|
|
62
|
+
export function isAlertsStaffOnly(error) {
|
|
63
|
+
return is(error, ALERTS_ERROR_FORBIDDEN);
|
|
64
|
+
}
|
|
65
|
+
/** No issue with that id (swept, or a stale `alerts:<id>` in a commit). */
|
|
66
|
+
export function isIssueNotFound(error) {
|
|
67
|
+
return is(error, ALERTS_ERROR_ISSUE_NOT_FOUND);
|
|
68
|
+
}
|
|
69
|
+
/** The store, declining to be told what it is supposed to have observed. */
|
|
70
|
+
export function isStatusNotSettable(error) {
|
|
71
|
+
return is(error, ALERTS_ERROR_STATUS_NOT_SETTABLE);
|
|
72
|
+
}
|
|
73
|
+
//# sourceMappingURL=refusals.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refusals.js","sourceRoot":"","sources":["../../src/model/refusals.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGxD,4EAA4E;AAC5E,MAAM,CAAC,MAAM,gCAAgC,GAC3C,sCAAsC,CAAC;AACzC,wDAAwD;AACxD,MAAM,CAAC,MAAM,yBAAyB,GAAG,wBAAwB,CAAC;AAClE,6DAA6D;AAC7D,MAAM,CAAC,MAAM,sBAAsB,GAAG,qBAAqB,CAAC;AAC5D,mFAAmF;AACnF,MAAM,CAAC,MAAM,4BAA4B,GAAG,kCAAkC,CAAC;AAE/E,4DAA4D;AAC5D,MAAM,UAAU,aAAa,CAAC,KAAc;IAC1C,OAAO,WAAW,CAAC,KAAK,EAAE,sBAAsB,CAAC,CAAC;AACpD,CAAC;AAED,MAAM,EAAE,GAAG,CAAC,KAAc,EAAE,IAAY,EAAW,EAAE,CACnD,WAAW,CAAC,aAAa,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC,CAAC;AAE1C,sEAAsE;AACtE,MAAM,UAAU,oBAAoB,CAAC,KAAc;IACjD,OAAO,EAAE,CAAC,KAAK,EAAE,yBAAyB,CAAC,CAAC;AAC9C,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,iBAAiB,CAAC,KAAc;IAC9C,OAAO,EAAE,CAAC,KAAK,EAAE,sBAAsB,CAAC,CAAC;AAC3C,CAAC;AAED,2EAA2E;AAC3E,MAAM,UAAU,eAAe,CAAC,KAAc;IAC5C,OAAO,EAAE,CAAC,KAAK,EAAE,4BAA4B,CAAC,CAAC;AACjD,CAAC;AAED,4EAA4E;AAC5E,MAAM,UAAU,mBAAmB,CAAC,KAAc;IAChD,OAAO,EAAE,CAAC,KAAK,EAAE,gCAAgC,CAAC,CAAC;AACrD,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import type { CreateModuleRuntimeOptions, ModuleRuntime } from "@stapel/core";
|
|
2
|
+
import type { AlertsApi } from "../api/alertsApi.js";
|
|
3
|
+
/**
|
|
4
|
+
* The wired alerts runtime — core's `ModuleRuntime` bound to this pair's API
|
|
5
|
+
* (slim wave §21/S2) — plus the two facts about this deployment that the
|
|
6
|
+
* module genuinely knows and its HTTP surface genuinely does not serve.
|
|
7
|
+
*
|
|
8
|
+
* The runtime's `fetch`/`credentials`/`defaultHeaders` are forwarded to the
|
|
9
|
+
* pair's RAW read surface as well, because the conditional (`ETag`) reads
|
|
10
|
+
* cannot ride the JSON client — see `api/alertsApi.ts`.
|
|
11
|
+
*
|
|
12
|
+
* ── `pollIntervalMs`: there is no stream ──────────────────────────────────
|
|
13
|
+
*
|
|
14
|
+
* stapel-alerts pushes nothing. An issue opens when a process somewhere fails,
|
|
15
|
+
* which is precisely when nobody is looking at the tracker; a feed that never
|
|
16
|
+
* re-read would show a green screen through an outage. The re-read is
|
|
17
|
+
* conditional, so the cost of asking is a 304 and a header — which is the
|
|
18
|
+
* whole reason the backend put an `ETag` on these two routes.
|
|
19
|
+
*
|
|
20
|
+
* ── `commitRefUrl`: where a sha goes when you click it ────────────────────
|
|
21
|
+
*
|
|
22
|
+
* A fixed issue carries `fixed_in_sha`, and the only useful thing to do with a
|
|
23
|
+
* sha is open the commit. WHERE that is is the host's repository, which this
|
|
24
|
+
* package cannot know and will not guess: unset, the sha renders as text and
|
|
25
|
+
* not as a dead link.
|
|
26
|
+
*/
|
|
27
|
+
export type AlertsRuntime = ModuleRuntime<AlertsApi> & {
|
|
28
|
+
/** How often an open feed re-asks, conditionally. `0` disables the poll. */
|
|
29
|
+
readonly pollIntervalMs: number;
|
|
30
|
+
/** `(sha) => href` for the host's repository browser. Omit for plain text. */
|
|
31
|
+
readonly commitRefUrl: ((sha: string) => string) | undefined;
|
|
32
|
+
};
|
|
33
|
+
/** The module's canonical mount (`urls.py` + `urls_v1.py`). */
|
|
34
|
+
export declare const DEFAULT_ALERTS_BASE_URL = "/alerts/api/v1/";
|
|
35
|
+
/**
|
|
36
|
+
* 60 seconds — the interval the module's own API doc names ("a poller that
|
|
37
|
+
* asks every minute should get a 304, not a page of JSON it already has").
|
|
38
|
+
* Fast enough that an operator watching a deploy sees a regression while it is
|
|
39
|
+
* still their deploy; slow enough that the answer is almost always 304.
|
|
40
|
+
*/
|
|
41
|
+
export declare const DEFAULT_ALERTS_POLL_INTERVAL_MS = 60000;
|
|
42
|
+
export interface CreateAlertsRuntimeOptions extends Omit<CreateModuleRuntimeOptions, "baseUrl"> {
|
|
43
|
+
/** Default {@link DEFAULT_ALERTS_BASE_URL}. */
|
|
44
|
+
readonly baseUrl?: string;
|
|
45
|
+
/** Default {@link DEFAULT_ALERTS_POLL_INTERVAL_MS}; `0` disables the poll. */
|
|
46
|
+
readonly pollIntervalMs?: number;
|
|
47
|
+
/** Turn a `fixed_in_sha` into a link into the host's repository browser. */
|
|
48
|
+
readonly commitRefUrl?: (sha: string) => string;
|
|
49
|
+
}
|
|
50
|
+
export declare function createAlertsRuntime(options?: CreateAlertsRuntimeOptions): AlertsRuntime;
|
|
51
|
+
//# sourceMappingURL=runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../../src/model/runtime.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,0BAA0B,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAE9E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,MAAM,aAAa,GAAG,aAAa,CAAC,SAAS,CAAC,GAAG;IACrD,4EAA4E;IAC5E,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,8EAA8E;IAC9E,QAAQ,CAAC,YAAY,EAAE,CAAC,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC,GAAG,SAAS,CAAC;CAC9D,CAAC;AAEF,+DAA+D;AAC/D,eAAO,MAAM,uBAAuB,oBAAoB,CAAC;AAEzD;;;;;GAKG;AACH,eAAO,MAAM,+BAA+B,QAAS,CAAC;AAEtD,MAAM,WAAW,0BACf,SAAQ,IAAI,CAAC,0BAA0B,EAAE,SAAS,CAAC;IACnD,+CAA+C;IAC/C,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,8EAA8E;IAC9E,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;IACjC,4EAA4E;IAC5E,QAAQ,CAAC,YAAY,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CACjD;AAED,wBAAgB,mBAAmB,CACjC,OAAO,GAAE,0BAA+B,GACvC,aAAa,CAoBf"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { createModuleRuntime } from "@stapel/core";
|
|
2
|
+
import { createAlertsApi } from "../api/alertsApi.js";
|
|
3
|
+
/** The module's canonical mount (`urls.py` + `urls_v1.py`). */
|
|
4
|
+
export const DEFAULT_ALERTS_BASE_URL = "/alerts/api/v1/";
|
|
5
|
+
/**
|
|
6
|
+
* 60 seconds — the interval the module's own API doc names ("a poller that
|
|
7
|
+
* asks every minute should get a 304, not a page of JSON it already has").
|
|
8
|
+
* Fast enough that an operator watching a deploy sees a regression while it is
|
|
9
|
+
* still their deploy; slow enough that the answer is almost always 304.
|
|
10
|
+
*/
|
|
11
|
+
export const DEFAULT_ALERTS_POLL_INTERVAL_MS = 60_000;
|
|
12
|
+
export function createAlertsRuntime(options = {}) {
|
|
13
|
+
const { baseUrl, pollIntervalMs, commitRefUrl, ...moduleOptions } = options;
|
|
14
|
+
const base = createModuleRuntime((client) => createAlertsApi(client, {
|
|
15
|
+
...(options.fetch !== undefined ? { fetch: options.fetch } : {}),
|
|
16
|
+
...(options.credentials !== undefined
|
|
17
|
+
? { credentials: options.credentials }
|
|
18
|
+
: {}),
|
|
19
|
+
...(options.defaultHeaders !== undefined
|
|
20
|
+
? { defaultHeaders: options.defaultHeaders }
|
|
21
|
+
: {}),
|
|
22
|
+
}), { ...moduleOptions, baseUrl: baseUrl ?? DEFAULT_ALERTS_BASE_URL });
|
|
23
|
+
return {
|
|
24
|
+
...base,
|
|
25
|
+
pollIntervalMs: pollIntervalMs ?? DEFAULT_ALERTS_POLL_INTERVAL_MS,
|
|
26
|
+
commitRefUrl,
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
//# sourceMappingURL=runtime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.js","sourceRoot":"","sources":["../../src/model/runtime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEnD,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAkCtD,+DAA+D;AAC/D,MAAM,CAAC,MAAM,uBAAuB,GAAG,iBAAiB,CAAC;AAEzD;;;;;GAKG;AACH,MAAM,CAAC,MAAM,+BAA+B,GAAG,MAAM,CAAC;AAYtD,MAAM,UAAU,mBAAmB,CACjC,UAAsC,EAAE;IAExC,MAAM,EAAE,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,GAAG,aAAa,EAAE,GAAG,OAAO,CAAC;IAC5E,MAAM,IAAI,GAAG,mBAAmB,CAC9B,CAAC,MAAM,EAAE,EAAE,CACT,eAAe,CAAC,MAAM,EAAE;QACtB,GAAG,CAAC,OAAO,CAAC,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,OAAO,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;QAChE,GAAG,CAAC,OAAO,CAAC,WAAW,KAAK,SAAS;YACnC,CAAC,CAAC,EAAE,WAAW,EAAE,OAAO,CAAC,WAAW,EAAE;YACtC,CAAC,CAAC,EAAE,CAAC;QACP,GAAG,CAAC,OAAO,CAAC,cAAc,KAAK,SAAS;YACtC,CAAC,CAAC,EAAE,cAAc,EAAE,OAAO,CAAC,cAAc,EAAE;YAC5C,CAAC,CAAC,EAAE,CAAC;KACR,CAAC,EACJ,EAAE,GAAG,aAAa,EAAE,OAAO,EAAE,OAAO,IAAI,uBAAuB,EAAE,CAClE,CAAC;IACF,OAAO;QACL,GAAG,IAAI;QACP,cAAc,EAAE,cAAc,IAAI,+BAA+B;QACjE,YAAY;KACb,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import type { UseMutationResult } from "@tanstack/react-query";
|
|
2
|
+
import type { StapelApiError } from "@stapel/core";
|
|
3
|
+
import type { Issue, IssueLevel } from "../api/types.js";
|
|
4
|
+
/** What `fix` is called with. */
|
|
5
|
+
export interface FixIssueInput {
|
|
6
|
+
readonly issueId: string;
|
|
7
|
+
/** The release that claims the fix. Optional — a hotfix may have no tag. */
|
|
8
|
+
readonly version?: string;
|
|
9
|
+
/** The commit that claims it. Optional — a human closing by hand has none. */
|
|
10
|
+
readonly sha?: string;
|
|
11
|
+
/**
|
|
12
|
+
* The row's level, for the analytics prop ONLY. The store reads the level
|
|
13
|
+
* off the row it already has; this never reaches the wire.
|
|
14
|
+
*/
|
|
15
|
+
readonly level?: IssueLevel;
|
|
16
|
+
}
|
|
17
|
+
/** What `mute` is called with. */
|
|
18
|
+
export interface MuteIssueInput {
|
|
19
|
+
readonly issueId: string;
|
|
20
|
+
/**
|
|
21
|
+
* When the mute lapses, as an ISO-8601 instant. `null` mutes with no
|
|
22
|
+
* deadline — sent explicitly, because the key IS the mute (see the module
|
|
23
|
+
* header).
|
|
24
|
+
*/
|
|
25
|
+
readonly mutedUntil: string | null;
|
|
26
|
+
/** Why it is muted. Worth a sentence: a silent row with no reason is a trap. */
|
|
27
|
+
readonly note?: string;
|
|
28
|
+
readonly level?: IssueLevel;
|
|
29
|
+
}
|
|
30
|
+
/** What `reopen` is called with. */
|
|
31
|
+
export interface ReopenIssueInput {
|
|
32
|
+
readonly issueId: string;
|
|
33
|
+
readonly note?: string;
|
|
34
|
+
readonly level?: IssueLevel;
|
|
35
|
+
}
|
|
36
|
+
/** What `annotate` is called with — a note, with no change of status. */
|
|
37
|
+
export interface AnnotateIssueInput {
|
|
38
|
+
readonly issueId: string;
|
|
39
|
+
readonly note: string;
|
|
40
|
+
}
|
|
41
|
+
/** What {@link useIssueStatus} reports. */
|
|
42
|
+
export interface IssueStatusBag {
|
|
43
|
+
/** `POST /issues/{id}/fix` — close it with the release that claims it. */
|
|
44
|
+
readonly fix: UseMutationResult<Issue, StapelApiError, FixIssueInput>;
|
|
45
|
+
/** `PATCH {muted_until}` — known, accepted, quiet; the status is implied. */
|
|
46
|
+
readonly mute: UseMutationResult<Issue, StapelApiError, MuteIssueInput>;
|
|
47
|
+
/** `PATCH {status: "new"}` — back on the board, by a person's judgement. */
|
|
48
|
+
readonly reopen: UseMutationResult<Issue, StapelApiError, ReopenIssueInput>;
|
|
49
|
+
/** `PATCH {note}` — a sentence, with no claim about the status. */
|
|
50
|
+
readonly annotate: UseMutationResult<Issue, StapelApiError, AnnotateIssueInput>;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* The write half of the tracker.
|
|
54
|
+
*
|
|
55
|
+
* Every mutation resolves to the issue the server saved, so a caller can show
|
|
56
|
+
* the row it now is rather than the row it asked for — the two differ whenever
|
|
57
|
+
* something else moved the issue between the read and the click.
|
|
58
|
+
*/
|
|
59
|
+
export declare function useIssueStatus(): IssueStatusBag;
|
|
60
|
+
//# sourceMappingURL=status.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../../src/model/status.ts"],"names":[],"mappings":"AAmCA,OAAO,KAAK,E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