web/api: merge picker types
This commit is contained in:
parent
9ff27391d0
commit
4505d6cfe1
1 changed files with 7 additions and 16 deletions
|
@ -20,24 +20,15 @@ type CobaltPartialURLResponse = {
|
||||||
url: string,
|
url: string,
|
||||||
}
|
}
|
||||||
|
|
||||||
type CobaltPartialImagesPickerResponse = {
|
|
||||||
pickerType: 'images',
|
|
||||||
picker: CobaltPartialURLResponse[],
|
|
||||||
}
|
|
||||||
|
|
||||||
type CobaltPartialVariousPickerResponse = {
|
|
||||||
pickerType: 'various',
|
|
||||||
picker: {
|
|
||||||
type: 'photo' | 'video',
|
|
||||||
url: string,
|
|
||||||
thumb: string,
|
|
||||||
}[];
|
|
||||||
}
|
|
||||||
|
|
||||||
type CobaltPickerResponse = {
|
type CobaltPickerResponse = {
|
||||||
status: CobaltResponseType.Picker
|
status: CobaltResponseType.Picker
|
||||||
audio: string | false,
|
picker: {
|
||||||
} & (CobaltPartialImagesPickerResponse | CobaltPartialVariousPickerResponse);
|
type: 'photo' | 'video' | 'gif',
|
||||||
|
url: string,
|
||||||
|
thumb?: string,
|
||||||
|
}[];
|
||||||
|
audio?: string,
|
||||||
|
};
|
||||||
|
|
||||||
type CobaltRedirectResponse = {
|
type CobaltRedirectResponse = {
|
||||||
status: CobaltResponseType.Redirect,
|
status: CobaltResponseType.Redirect,
|
||||||
|
|
Loading…
Reference in a new issue