signal-desktop/ts/state/ducks/usernameEnums.ts
2023-11-03 15:05:11 -07:00

43 lines
861 B
TypeScript

// Copyright 2022 Signal Messenger, LLC
// SPDX-License-Identifier: AGPL-3.0-only
//
// ProfileEditor
//
export enum UsernameEditState {
Editing = 'Editing',
ConfirmingDelete = 'ConfirmingDelete',
Deleting = 'Deleting',
}
//
// UsernameLinkModalBody
//
export enum UsernameLinkState {
Ready = 'Ready',
Updating = 'Updating',
Error = 'Error',
}
//
// EditUsernameModalBody
//
export enum UsernameReservationState {
Open = 'Open',
Reserving = 'Reserving',
Confirming = 'Confirming',
Closed = 'Closed',
}
export enum UsernameReservationError {
NotEnoughCharacters = 'NotEnoughCharacters',
TooManyCharacters = 'TooManyCharacters',
CheckStartingCharacter = 'CheckStartingCharacter',
CheckCharacters = 'CheckCharacters',
UsernameNotAvailable = 'UsernameNotAvailable',
General = 'General',
ConflictOrGone = 'ConflictOrGone',
}