diff options
Diffstat (limited to 'src/constants')
| -rw-r--r-- | src/constants/api.ts | 1 | ||||
| -rw-r--r-- | src/constants/regex.ts | 2 | ||||
| -rw-r--r-- | src/constants/strings.ts | 47 |
3 files changed, 49 insertions, 1 deletions
diff --git a/src/constants/api.ts b/src/constants/api.ts index de43b94d..701070eb 100644 --- a/src/constants/api.ts +++ b/src/constants/api.ts @@ -18,6 +18,7 @@ export const GET_FB_POSTS_ENDPOINT: string = API_URL + 'posts-fb/'; export const GET_TWITTER_POSTS_ENDPOINT: string = API_URL + 'posts-twitter/'; export const SEARCH_ENDPOINT: string = API_URL + 'search/'; export const MOMENTS_ENDPOINT: string = API_URL + 'moments/'; +export const MOMENT_THUMBNAIL_ENDPOINT: string = API_URL + 'moment-thumbnail/'; export const VERIFY_INVITATION_CODE_ENDPOUNT: string = API_URL + 'verify-code/'; export const COMMENTS_ENDPOINT: string = API_URL + 'comments/'; export const FRIENDS_ENDPOINT: string = API_URL + 'friends/'; diff --git a/src/constants/regex.ts b/src/constants/regex.ts index 6ab045bd..fe5ce3ab 100644 --- a/src/constants/regex.ts +++ b/src/constants/regex.ts @@ -40,7 +40,7 @@ export const websiteRegex: RegExp = /^$|^(https?:\/\/)?(www\.)?[-a-zA-Z0-9@:%._+ * - max. 150 chars for bio * - match alphanumerics, and special characters used in URLs */ -export const bioRegex: RegExp = /^$|^[A-Za-z0-9'\-,.!@#$%^&*()_:?/ ]{1,150}$/; +export const bioRegex: RegExp = /^[\s\S]{1,150}$/; /** * The gender regex has the following constraints diff --git a/src/constants/strings.ts b/src/constants/strings.ts new file mode 100644 index 00000000..b5344afd --- /dev/null +++ b/src/constants/strings.ts @@ -0,0 +1,47 @@ +/* eslint-disable */ +// Below is the regex to convert this into a csv for the Google Sheet +// export const (.*) = .*?(['|"|`])(.*)\2; +// replace with: $1\t$3 +export const COMING_SOON_MSG = 'Creating more fun things for you, surprises coming soon π'; +export const ERROR_AUTHENTICATION = 'An error occurred during authentication. Please login again!'; +export const ERROR_CATEGORY_CREATION = 'There was a problem creating your categories. Please refresh and try again.'; +export const ERROR_CATEGORY_UPDATE = 'There was a problem updating your categories. Please refresh and try again'; +export const ERROR_DELETE_CATEGORY = 'There was a problem while deleting category. Please try again'; +export const ERROR_DELETE_MOMENT = 'Unable to delete moment, please try again later!'; +export const ERROR_DOUBLE_CHECK_CONNECTION = 'Please double-check your network connection and retry'; +export const ERROR_DUP_OLD_PWD = 'You may not use a previously used password'; +export const ERROR_EMAIL_IN_USE = 'Email already in use, please try another one'; +export const ERROR_FAILED_LOGIN_INFO = 'Login failed, please try re-entering your login information'; +export const ERROR_FAILED_TO_COMMENT = 'Unable to post comment, refresh and try again!'; +export const ERROR_INVALID_INVITATION_CODE = 'Invitation code invalid, try again or talk to the friend that sent it π¬'; +export const ERROR_INVALID_LOGIN = 'Invalid login, Please login again'; +export const ERROR_INVALID_PWD_CODE = 'Looks like you have entered the wrong code, please try again'; +export const ERROR_INVALID_VERIFICATION_CODE = 'Invalid verification code, try re-entering or tap the resend code button for a new code'; +export const ERROR_INVALID_VERIFICATION_CODE_FORMAT = 'Please enter the 6 digit code sent to your phone'; +export const ERROR_INVLAID_CODE = 'The code entered is not valid!'; +export const ERROR_LINK = (str: string) => `Unable to link with ${str}, Please check your login and try again`; +export const ERROR_LOGIN = 'There was a problem logging you in, please refresh and try again'; +export const ERROR_LOGIN_FAILED = 'Login failed. Check your username and passoword, and try again'; +export const ERROR_NEXT_PAGE = 'There was a problem while loading the next page π, try again in a couple minutes'; +export const ERROR_PROFILE_CREATION_SHORT = 'Profile creation failed π'; +export const ERROR_PWD_ACCOUNT = (str: string) => `Please make sure that the email / username entered is registered with us. You may contact our customer support at ${str}`; +export const ERROR_REGISTRATION = (str: string) => `Registration failed π, ${str}`; +export const ERROR_SELECT_CLASS_YEAR = 'Please select your Class Year'; +export const ERROR_SERVER_DOWN = 'mhm, looks like our servers are down, please refresh and try again in a few mins'; +export const ERROR_SOMETHING_WENT_WRONG = "Oh dear, donβt worry someone will be held responsible for this error, In the meantime refresh the app"; +export const ERROR_SOMETHING_WENT_WRONG_REFRESH = "Ha, looks like this one's on us, please refresh and try again"; +export const ERROR_SOMETHING_WENT_WRONG_RELOAD = "You broke it, Just kidding! we don't know what happened... Please reload the app and try again"; +export const ERROR_UNABLE_TO_FIND_PROFILE = 'We were unable to find this profile. Please check username and try again'; +export const ERROR_UNABLE_TO_VIEW_PROFILE = 'Unable to view this profile'; +export const ERROR_UPLOAD = 'An error occurred while uploading. Please try again!'; +export const ERROR_UPLOAD_LARGE_PROFILE_PIC = "Can't have the first image seen on the profile be blank, please upload a large picture"; +export const ERROR_UPLOAD_MOMENT = 'Unable to upload moment. Please retry'; +export const ERROR_UPLOAD_SMALL_PROFILE_PIC = "Can't have a profile without a pic to represent you, please upload a small profile picture"; +export const ERROR_VERIFICATION_FAILED_SHORT = 'Verification failed π'; +export const MARKED_AS_MSG = (str: string) => `Marked as ${str}`; +export const MOMENT_DELETED_MSG = 'Moment deleted....Some moments have to go, to create space for greater ones'; +export const SUCCESS_CATEGORY_DELETE = 'Category successfully deleted, but its memory will live on'; +export const SUCCESS_LINK = (str: string) => `Successfully linked ${str} π`; +export const SUCCESS_PIC_UPLOAD = 'Beautiful, the picture was uploaded successfully!'; +export const SUCCESS_PWD_RESET = 'Your password was reset successfully!'; +export const SUCCESS_VERIFICATION_CODE_SENT = 'New verification code sent! Check your phone messages for your code'; |
