Tankōbon / lib/metadata-lookup / LookupAction
Type Alias: LookupAction
LookupAction = {
id:number;type:"searchStarted"; } | {id:number;step:LookupStep;type:"searchDone"; } | {type:"reset"; } | {review:MetadataReview;type:"picked"; } | {review:MetadataReview;type:"reviewChanged"; } | {type:"backToResults"; }
Defined in: lib/metadata-lookup.ts:24
Everything that can happen in the dialog.
Union Members
Type Literal
{ id: number; type: "searchStarted"; }
A search was sent; id is unique to it.
Type Literal
{ id: number; step: LookupStep; type: "searchDone"; }
The answer of search id, as the step it leads to; ignored unless that search is the awaited one.
Type Literal
{ type: "reset"; }
The user stopped the search, or changed the way to look the book up: back to the options.
Type Literal
{ review: MetadataReview; type: "picked"; }
A result was picked: its review replaces the results.
Type Literal
{ review: MetadataReview; type: "reviewChanged"; }
The user edited the review.
Type Literal
{ type: "backToResults"; }
Back from the review to the results it came from.