-
Notifications
You must be signed in to change notification settings - Fork 301
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
This reverts commit 4278849.
- Loading branch information
1 parent
e4a261a
commit 60f0c1c
Showing
6 changed files
with
577 additions
and
255 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
138 changes: 0 additions & 138 deletions
138
packages/ui/src/utils/setUserAgent/__tests__/setUserAgent.test.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,72 +1,24 @@ | ||
import { | ||
AuthUserAgentInput, | ||
GeoUserAgentInput, | ||
InAppMessagingUserAgentInput, | ||
StorageUserAgentInput, | ||
setCustomUserAgent, | ||
SetCustomUserAgentInput, | ||
AuthAction, | ||
GeoAction, | ||
InAppMessagingAction, | ||
StorageAction, | ||
Category, | ||
} from '@aws-amplify/core/internals/utils'; | ||
|
||
// replace type once Category input types are available | ||
export const ACCOUNT_SETTINGS_INPUT_BASE: Omit< | ||
AuthUserAgentInput, | ||
SetCustomUserAgentInput, | ||
'additionalDetails' | ||
> = { | ||
apis: [AuthAction.DeleteUser, AuthAction.UpdatePassword], | ||
category: Category.Auth, | ||
}; | ||
|
||
export const AUTHENTICATOR_INPUT_BASE: Omit< | ||
AuthUserAgentInput, | ||
'additionalDetails' | ||
> = { | ||
apis: [ | ||
AuthAction.SignUp, | ||
AuthAction.ConfirmSignUp, | ||
AuthAction.ResendSignUpCode, | ||
AuthAction.SignIn, | ||
AuthAction.ConfirmSignIn, | ||
AuthAction.FetchUserAttributes, | ||
AuthAction.SignOut, | ||
AuthAction.ResetPassword, | ||
AuthAction.ConfirmResetPassword, | ||
AuthAction.SignInWithRedirect, | ||
], | ||
category: Category.Auth, | ||
}; | ||
|
||
// replace type once Category input types are available | ||
export const IN_APP_MESSAGING_INPUT_BASE: Omit< | ||
InAppMessagingUserAgentInput, | ||
SetCustomUserAgentInput, | ||
'additionalDetails' | ||
> = { | ||
apis: [InAppMessagingAction.NotifyMessageInteraction], | ||
apis: undefined, // TODO | ||
category: Category.InAppMessaging, | ||
}; | ||
|
||
export const LOCATION_SEARCH_INPUT_BASE: Omit< | ||
GeoUserAgentInput, | ||
'additionalDetails' | ||
> = { | ||
category: Category.Geo, | ||
apis: [ | ||
GeoAction.SearchByText, | ||
GeoAction.SearchForSuggestions, | ||
GeoAction.SearchByPlaceId, | ||
], | ||
}; | ||
|
||
export const MAP_VIEW_INPUT_BASE: Omit<GeoUserAgentInput, 'additionalDetails'> = | ||
{ | ||
category: Category.Geo, | ||
apis: [], | ||
}; | ||
|
||
export const STORAGE_MANAGER_INPUT_BASE: Omit< | ||
StorageUserAgentInput, | ||
'additionalDetails' | ||
> = { | ||
apis: [StorageAction.UploadData], | ||
category: Category.Storage, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.