Chore: Migrate REST API - getAvatarSuggestion to Typescript (#3869)
This commit is contained in:
parent
b27cdade36
commit
a8b5ee718f
|
@ -57,6 +57,14 @@ export interface IAvatar {
|
|||
service?: any;
|
||||
}
|
||||
|
||||
export interface IAvatarSuggestion {
|
||||
[service: string]: {
|
||||
url: string;
|
||||
blob: string;
|
||||
contentType: string;
|
||||
};
|
||||
}
|
||||
|
||||
export interface IProfileViewState {
|
||||
saving: boolean;
|
||||
name: string;
|
||||
|
@ -66,13 +74,7 @@ export interface IProfileViewState {
|
|||
currentPassword: string | null;
|
||||
avatarUrl: string | null;
|
||||
avatar: IAvatar;
|
||||
avatarSuggestions: {
|
||||
[service: string]: {
|
||||
url: string;
|
||||
blob: string;
|
||||
contentType: string;
|
||||
};
|
||||
};
|
||||
avatarSuggestions: IAvatarSuggestion;
|
||||
customFields: {
|
||||
[key: string | number]: string;
|
||||
};
|
||||
|
|
|
@ -3,7 +3,7 @@ import { TEAM_TYPE } from '../../../definitions/ITeam';
|
|||
import roomTypeToApiType, { RoomTypes } from '../methods/roomTypeToApiType';
|
||||
import { SubscriptionType, INotificationPreferences, IRoomNotifications } from '../../../definitions';
|
||||
import { ISpotlight } from '../../../definitions/ISpotlight';
|
||||
import { IParams } from '../../../definitions/IProfileViewInterfaces';
|
||||
import { IAvatarSuggestion, IParams } from '../../../definitions/IProfileViewInterfaces';
|
||||
|
||||
export const createChannel = ({
|
||||
name,
|
||||
|
@ -568,7 +568,7 @@ export const getRoomRoles = (roomId: string, type: SubscriptionType): any =>
|
|||
// @ts-ignore
|
||||
sdk.get(`${roomTypeToApiType(type)}.roles`, { roomId });
|
||||
|
||||
export const getAvatarSuggestion = () =>
|
||||
export const getAvatarSuggestion = (): Promise<IAvatarSuggestion> =>
|
||||
// RC 0.51.0
|
||||
sdk.methodCallWrapper('getAvatarSuggestion');
|
||||
|
||||
|
|
Loading…
Reference in New Issue