feat(platform): add the notification inbox and deterministic match search
This commit is contained in:
1 parent
5edff21d2d
commit
0b11021b16
169 files changed
+17083
-443
No files matched your search
@@ -84,6 +84,8 @@ export type MatchCardModel = MatchConfirmedCardModel | MatchUnconfirmedCardModel
|
||||
export type MatchSearchModel = {
|
||||
readonly source: MatchSearchSourceModel;
|
||||
readonly cards: readonly MatchCardModel[];
|
||||
/** True when the output is not the whole ranked result; it carries no count. */
|
||||
readonly truncated: boolean;
|
||||
};
|
||||
|
||||
function isRecord(value: unknown): value is Record<string, unknown> {
|
||||
@@ -258,6 +260,7 @@ export function matchSearchFromTransport(value: unknown, status = 200): MatchSea
|
||||
...response.groups.near.map((candidate) => confirmedFromTransport("near", candidate)),
|
||||
...response.groups.unconfirmed.map(unconfirmedFromTransport),
|
||||
],
|
||||
truncated: response.truncated,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -316,5 +319,6 @@ export function matchSearchToTransport(model: MatchSearchModel): MatchSearchResp
|
||||
return matchSearchResponseSchema.parse({
|
||||
source: sourceToTransport(model.source),
|
||||
groups,
|
||||
truncated: model.truncated,
|
||||
});
|
||||
}
|
||||
Reference in new issue
Block a user