5623 add an inviteteam onboarding step (#5769)

## Changes
- add a new invite Team onboarding step
- update currentUser.state to currentUser.onboardingStep

## Edge cases
We will never display invite team onboarding step 
- if number of workspaceMember > 1
- if a workspaceMember as been deleted

## Important changes
Update typeorm package version to 0.3.20 because we needed a fix on
`indexPredicates` pushed in 0.3.20 version
(https://github.com/typeorm/typeorm/issues/10191)

## Result
<img width="844" alt="image"
src="https://github.com/twentyhq/twenty/assets/29927851/0dab54cf-7c66-4c64-b0c9-b0973889a148">



https://github.com/twentyhq/twenty/assets/29927851/13268d0a-cfa7-42a4-84c6-9e1fbbe48912
This commit is contained in:
martmull
2024-06-12 21:13:18 +02:00
committed by GitHub
parent 2fdd2f4949
commit 3986824017
60 changed files with 1009 additions and 372 deletions

View File

@ -407,7 +407,7 @@ export type Mutation = {
renewToken: AuthTokens;
sendInviteLink: SendInviteLink;
signUp: LoginToken;
skipSyncEmailOnboardingStep: SkipSyncEmailOnboardingStep;
skipSyncEmailOnboardingStep: OnboardingStepSuccess;
syncRemoteTable: RemoteTable;
syncRemoteTableSchemaChanges: RemoteTable;
track: Analytics;
@ -636,6 +636,18 @@ export type ObjectFieldsConnection = {
pageInfo: PageInfo;
};
/** Onboarding step */
export enum OnboardingStep {
InviteTeam = 'INVITE_TEAM',
SyncEmail = 'SYNC_EMAIL'
}
export type OnboardingStepSuccess = {
__typename?: 'OnboardingStepSuccess';
/** Boolean that confirms query was dispatched */
success: Scalars['Boolean']['output'];
};
export type PageInfo = {
__typename?: 'PageInfo';
/** The cursor of the last returned record. */
@ -888,12 +900,6 @@ export type SessionEntity = {
url?: Maybe<Scalars['String']['output']>;
};
export type SkipSyncEmailOnboardingStep = {
__typename?: 'SkipSyncEmailOnboardingStep';
/** Boolean that confirms query was dispatched */
success: Scalars['Boolean']['output'];
};
/** Sort Directions */
export enum SortDirection {
Asc = 'ASC',
@ -1078,12 +1084,12 @@ export type User = {
firstName: Scalars['String']['output'];
id: Scalars['UUID']['output'];
lastName: Scalars['String']['output'];
onboardingStep?: Maybe<OnboardingStep>;
passwordHash?: Maybe<Scalars['String']['output']>;
/** @deprecated field migrated into the AppTokens Table ref: https://github.com/twentyhq/twenty/issues/5021 */
passwordResetToken?: Maybe<Scalars['String']['output']>;
/** @deprecated field migrated into the AppTokens Table ref: https://github.com/twentyhq/twenty/issues/5021 */
passwordResetTokenExpiresAt?: Maybe<Scalars['DateTime']['output']>;
state: UserState;
supportUserHash?: Maybe<Scalars['String']['output']>;
updatedAt: Scalars['DateTime']['output'];
workspaceMember?: Maybe<WorkspaceMember>;
@ -1118,11 +1124,6 @@ export type UserMappingOptionsUser = {
user?: Maybe<Scalars['String']['output']>;
};
export type UserState = {
__typename?: 'UserState';
skipSyncEmailOnboardingStep?: Maybe<Scalars['Boolean']['output']>;
};
export type UserWorkspace = {
__typename?: 'UserWorkspace';
createdAt: Scalars['DateTime']['output'];