Skip to content

Commit

Permalink
feat: add email translations (#90)
Browse files Browse the repository at this point in the history
* feat: add translations for refactor

* build: upgrade dependencies
  • Loading branch information
pyphilia authored May 10, 2023
1 parent bd9aa35 commit 204d3ac
Show file tree
Hide file tree
Showing 15 changed files with 2,138 additions and 2,132 deletions.
34 changes: 17 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "@graasp/translations",
"version": "1.12.0",
"engines": {
"node": ">=14.0.0"
"node": ">=16.0.0"
},
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down Expand Up @@ -37,24 +37,24 @@
"build": "tsc"
},
"devDependencies": {
"@commitlint/cli": "16.2.1",
"@commitlint/config-conventional": "16.2.1",
"@types/jest": "27.4.1",
"@types/node": "17.0.20",
"@typescript-eslint/eslint-plugin": "5.12.1",
"@typescript-eslint/parser": "5.12.1",
"eslint": "8.9.0",
"eslint-config-prettier": "8.4.0",
"eslint-plugin-import": "2.25.4",
"husky": "7.0.4",
"jest": "27.5.1",
"prettier": "2.5.1",
"ts-jest": "27.1.3",
"ts-node": "10.5.0",
"typescript": "4.1.3"
"@commitlint/cli": "17.6.1",
"@commitlint/config-conventional": "17.6.1",
"@types/jest": "29.5.1",
"@types/node": "18.16.3",
"@typescript-eslint/eslint-plugin": "5.59.2",
"@typescript-eslint/parser": "5.59.2",
"eslint": "8.39.0",
"eslint-config-prettier": "8.8.0",
"eslint-plugin-import": "2.27.5",
"husky": "8.0.3",
"jest": "29.5.0",
"prettier": "2.8.8",
"ts-jest": "29.1.0",
"ts-node": "10.9.1",
"typescript": "5.0.4"
},
"packageManager": "[email protected]",
"dependencies": {
"i18next": "21.8.1"
"i18next": "22.4.15"
}
}
85 changes: 47 additions & 38 deletions src/constants/builder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,53 @@ export const BUILDER = {
IMPORT_ZIP_TITLE: 'IMPORT_ZIP_TITLE',
IMPORT_ZIP_WARNING: 'IMPORT_ZIP_WARNING',
INVITATIONS_TABLE_ACTIONS_HEADER: 'INVITATIONS_TABLE_ACTIONS_HEADER',

MOVE_BUTTON: 'MOVE_BUTTON',

PIN_ITEM_PIN_TEXT: 'PIN_ITEM_PIN_TEXT',
PIN_ITEM_UNPIN_TEXT: 'PIN_ITEM_UNPIN_TEXT',
PLAY_BUTTON_TOOLTIP: 'PLAY_BUTTON_TOOLTIP',

LIBRARY_SETTINGS_BUTTON_TITLE: 'LIBRARY_SETTINGS_BUTTON_TITLE',
RECYCLE_ITEM_BUTTON: 'RECYCLE_ITEM_BUTTON',
RESTORE_ITEM_BUTTON: 'RESTORE_ITEM_BUTTON',
SHARE_ITEM_BUTTON: 'SHARE_ITEM_BUTTON',
ITEM_METADATA_CREATOR_TITLE: 'ITEM_METADATA_CREATOR_TITLE',
ITEM_METADATA_TYPE_TITLE: 'ITEM_METADATA_TYPE_TITLE',
USER_SWITCH_PROFILE_BUTTON: 'USER_SWITCH_PROFILE_BUTTON',

RECYCLE_BIN_TITLE: 'RECYCLE_BIN_TITLE',

SETTINGS_COLLAPSE_LABEL: 'SETTINGS_COLLAPSE_LABEL',
SETTINGS_PIN_ITEM_LABEL: 'SETTINGS_PIN_ITEM_LABEL',
SETTINGS_SHOW_CHAT_LABEL: 'SETTINGS_SHOW_CHAT_LABEL',
SETTINGS_RESIZE_LABEL: 'SETTINGS_RESIZE_LABEL',
SETTINGS_TITLE: 'SETTINGS_TITLE',
SETTINGS_COLLAPSE_FOLDER_INFORMATION: 'SETTINGS_COLLAPSE_FOLDER_INFORMATION',

LIBRARY_SETTINGS_INFORMATION: 'LIBRARY_SETTINGS_INFORMATION',
LIBRARY_SETTINGS_TITLE: 'LIBRARY_SETTINGS_TITLE',
LIBRARY_SETTINGS_VALIDATION_TITLE: 'LIBRARY_SETTINGS_VALIDATION_TITLE',

LIBRARY_SETTINGS_VISIBILITY_INFORMATIONS:
'LIBRARY_SETTINGS_VISIBILITY_INFORMATIONS',

SHARE_ITEM_CSV_IMPORT_MODAL_TITLE: 'SHARE_ITEM_CSV_IMPORT_MODAL_TITLE',
SHARE_ITEM_CSV_IMPORT_SUCCESS_MESSAGE:
'SHARE_ITEM_CSV_IMPORT_SUCCESS_MESSAGE',
SHARE_ITEM_CSV_IMPORT_MODAL_CONTENT: 'SHARE_ITEM_CSV_IMPORT_MODAL_CONTENT',
SHARE_ITEM_CSV_IMPORT_INPUT_BUTTON: 'SHARE_ITEM_CSV_IMPORT_INPUT_BUTTON',
SHARE_ITEM_CSV_IMPORT_ERROR_MESSAGE: 'SHARE_ITEM_CSV_IMPORT_ERROR_MESSAGE',
SHARE_ITEM_FORM_EMAIL_LABEL: 'SHARE_ITEM_FORM_EMAIL_LABEL',
SHARE_ITEM_FORM_CONFIRM_BUTTON: 'SHARE_ITEM_FORM_CONFIRM_BUTTON',
SHARE_ITEM_FORM_INVITATION_TOOLTIP: 'SHARE_ITEM_FORM_INVITATION_TOOLTIP',

SHARE_ITEM_FORM_INVITATION_EMAIL_EXISTS_MESSAGE:
'SHARE_ITEM_FORM_INVITATION_EMAIL_EXISTS_MESSAGE',
SHARE_ITEM_FORM_INVITATION_INVALID_EMAIL_MESSAGE:
'SHARE_ITEM_FORM_INVITATION_INVALID_EMAIL_MESSAGE',
SHARE_ITEM_FORM_INVITATION_EMPTY_EMAIL_MESSAGE:
'SHARE_ITEM_FORM_INVITATION_EMPTY_EMAIL_MESSAGE',
INVITATIONS_TABLE_CANNOT_DELETE_PARENT_TOOLTIP:
'INVITATIONS_TABLE_CANNOT_DELETE_PARENT_TOOLTIP',
INVITATIONS_TABLE_EMAIL_HEADER: 'INVITATIONS_TABLE_EMAIL_HEADER',
Expand All @@ -87,11 +134,9 @@ export const BUILDER = {
ITEM_MENU_CREATE_SHORTCUT_MENU_ITEM: 'ITEM_MENU_CREATE_SHORTCUT_MENU_ITEM',
ITEM_MENU_FLAG_MENU_ITEM: 'ITEM_MENU_FLAG_MENU_ITEM',
ITEM_METADATA_CREATED_AT_TITLE: 'ITEM_METADATA_CREATED_AT_TITLE',
ITEM_METADATA_CREATOR_TITLE: 'ITEM_METADATA_CREATOR_TITLE',
ITEM_METADATA_LINK_TITLE: 'ITEM_METADATA_LINK_TITLE',
ITEM_METADATA_SIZE_TITLE: 'ITEM_METADATA_SIZE_TITLE',
ITEM_METADATA_TITLE: 'ITEM_METADATA_TITLE',
ITEM_METADATA_TYPE_TITLE: 'ITEM_METADATA_TYPE_TITLE',
ITEM_METADATA_UPDATED_AT_TITLE: 'ITEM_METADATA_UPDATED_AT_TITLE',
ITEM_SEARCH_NO_RESULTS_MESSAGE: 'ITEM_SEARCH_NO_RESULTS_MESSAGE',
ITEM_SEARCH_PLACEHOLDER: 'ITEM_SEARCH_PLACEHOLDER',
Expand Down Expand Up @@ -165,15 +210,12 @@ export const BUILDER = {
ITEMS_TREE_OWN_ITEMS_LABEL: 'ITEMS_TREE_OWN_ITEMS_LABEL',
LAYOUT_MODE_GRID_LABEL: 'LAYOUT_MODE_GRID_LABEL',
LAYOUT_MODE_LIST_LABEL: 'LAYOUT_MODE_LIST_LABEL',
LIBRARY_SETTINGS_BUTTON_TITLE: 'LIBRARY_SETTINGS_BUTTON_TITLE',
LIBRARY_SETTINGS_INFORMATION: 'LIBRARY_SETTINGS_INFORMATION',
LIBRARY_SETTINGS_NOT_PUBLISHED_ITEM_MESSAGE:
'LIBRARY_SETTINGS_NOT_PUBLISHED_ITEM_MESSAGE',
LIBRARY_SETTINGS_PUBLISH_BUTTON: 'LIBRARY_SETTINGS_PUBLISH_BUTTON',
LIBRARY_SETTINGS_PUBLISH_NOTIFICATIONS_LABEL:
'LIBRARY_SETTINGS_PUBLISH_NOTIFICATIONS_LABEL',
LIBRARY_SETTINGS_PUBLISHED_STATUS: 'LIBRARY_SETTINGS_PUBLISHED_STATUS',
LIBRARY_SETTINGS_TITLE: 'LIBRARY_SETTINGS_TITLE',
LIBRARY_SETTINGS_UNPUBLISH_BUTTON: 'LIBRARY_SETTINGS_UNPUBLISH_BUTTON',
LIBRARY_SETTINGS_VALIDATION_CONFIGURATION_INFORMATIONS:
'LIBRARY_SETTINGS_VALIDATION_CONFIGURATION_INFORMATIONS',
Expand All @@ -193,13 +235,9 @@ export const BUILDER = {
'LIBRARY_SETTINGS_VALIDATION_STATUS_PENDING_AUTOMATIC',
LIBRARY_SETTINGS_VALIDATION_STATUS_PENDING_MANUAL:
'LIBRARY_SETTINGS_VALIDATION_STATUS_PENDING_MANUAL',
LIBRARY_SETTINGS_VALIDATION_TITLE: 'LIBRARY_SETTINGS_VALIDATION_TITLE',
LIBRARY_SETTINGS_VALIDATION_VALIDATE_BUTTON:
'LIBRARY_SETTINGS_VALIDATION_VALIDATE_BUTTON',
LIBRARY_SETTINGS_VISIBILITY_INFORMATIONS:
'LIBRARY_SETTINGS_VISIBILITY_INFORMATIONS',
LINK_DEFAULT_NAME: 'LINK_DEFAULT_NAME',
MOVE_BUTTON: 'MOVE_BUTTON',
MOVE_ITEM_MODAL_TITLE: 'MOVE_ITEM_MODAL_TITLE',
MY_ITEMS_TITLE: 'MY_ITEMS_TITLE',
NAVIGATION_FAVORITE_ITEMS_TITLE: 'NAVIGATION_FAVORITE_ITEMS_TITLE',
Expand All @@ -215,44 +253,16 @@ export const BUILDER = {
NEW_ITEM_H5P_TAB_TEXT: 'NEW_ITEM_H5P_TAB_TEXT',
NEW_ITEM_LINK_TAB_TEXT: 'NEW_ITEM_LINK_TAB_TEXT',
NEW_ITEM_ZIP_TAB_TEXT: 'NEW_ITEM_ZIP_TAB_TEXT',
PIN_ITEM_PIN_TEXT: 'PIN_ITEM_PIN_TEXT',
PIN_ITEM_UNPIN_TEXT: 'PIN_ITEM_UNPIN_TEXT',
PLAY_BUTTON_TOOLTIP: 'PLAY_BUTTON_TOOLTIP',
RECYCLE_BIN_TITLE: 'RECYCLE_BIN_TITLE',
RECYCLE_ITEM_BUTTON: 'RECYCLE_ITEM_BUTTON',
RESTORE_ITEM_BUTTON: 'RESTORE_ITEM_BUTTON',
SAVE_ACTIONS_TOGGLE_TOOLTIP: 'SAVE_ACTIONS_TOGGLE_TOOLTIP',
SETTINGS_COLLAPSE_FOLDER_INFORMATION: 'SETTINGS_COLLAPSE_FOLDER_INFORMATION',
SETTINGS_COLLAPSE_LABEL: 'SETTINGS_COLLAPSE_LABEL',
SETTINGS_LINK_SETTINGS_INFORMATIONS: 'SETTINGS_LINK_SETTINGS_INFORMATIONS',
SETTINGS_LINK_SETTINGS_TITLE: 'SETTINGS_LINK_SETTINGS_TITLE',
SETTINGS_LINK_SHOW_BUTTON: 'SETTINGS_LINK_SHOW_BUTTON',
SETTINGS_LINK_SHOW_IFRAME: 'SETTINGS_LINK_SHOW_IFRAME',
SETTINGS_PIN_ITEM_LABEL: 'SETTINGS_PIN_ITEM_LABEL',
SETTINGS_RESIZE_LABEL: 'SETTINGS_RESIZE_LABEL',
SETTINGS_SAVE_ACTIONS: 'SETTINGS_SAVE_ACTIONS',
SETTINGS_SHOW_CHAT_LABEL: 'SETTINGS_SHOW_CHAT_LABEL',
SETTINGS_THUMBNAIL_SETTINGS_INFORMATIONS:
'SETTINGS_THUMBNAIL_SETTINGS_INFORMATIONS',
SETTINGS_THUMBNAIL_TITLE: 'SETTINGS_THUMBNAIL_TITLE',
SETTINGS_TITLE: 'SETTINGS_TITLE',
SHARE_ITEM_BUTTON: 'SHARE_ITEM_BUTTON',
SHARE_ITEM_CSV_IMPORT_BUTTON: 'SHARE_ITEM_CSV_IMPORT_BUTTON',
SHARE_ITEM_CSV_IMPORT_ERROR_MESSAGE: 'SHARE_ITEM_CSV_IMPORT_ERROR_MESSAGE',
SHARE_ITEM_CSV_IMPORT_INPUT_BUTTON: 'SHARE_ITEM_CSV_IMPORT_INPUT_BUTTON',
SHARE_ITEM_CSV_IMPORT_MODAL_CONTENT: 'SHARE_ITEM_CSV_IMPORT_MODAL_CONTENT',
SHARE_ITEM_CSV_IMPORT_MODAL_TITLE: 'SHARE_ITEM_CSV_IMPORT_MODAL_TITLE',
SHARE_ITEM_CSV_IMPORT_SUCCESS_MESSAGE:
'SHARE_ITEM_CSV_IMPORT_SUCCESS_MESSAGE',
SHARE_ITEM_FORM_CONFIRM_BUTTON: 'SHARE_ITEM_FORM_CONFIRM_BUTTON',
SHARE_ITEM_FORM_EMAIL_LABEL: 'SHARE_ITEM_FORM_EMAIL_LABEL',
SHARE_ITEM_FORM_INVITATION_EMAIL_EXISTS_MESSAGE:
'SHARE_ITEM_FORM_INVITATION_EMAIL_EXISTS_MESSAGE',
SHARE_ITEM_FORM_INVITATION_EMPTY_EMAIL_MESSAGE:
'SHARE_ITEM_FORM_INVITATION_EMPTY_EMAIL_MESSAGE',
SHARE_ITEM_FORM_INVITATION_INVALID_EMAIL_MESSAGE:
'SHARE_ITEM_FORM_INVITATION_INVALID_EMAIL_MESSAGE',
SHARE_ITEM_FORM_INVITATION_TOOLTIP: 'SHARE_ITEM_FORM_INVITATION_TOOLTIP',
SHARE_ITEM_LINK_COPY_TOOLTIP: 'SHARE_ITEM_LINK_COPY_TOOLTIP',
SHARED_ITEMS_TITLE: 'SHARED_ITEMS_TITLE',
SHARED_MEMBERS_LABEL: 'SHARED_MEMBERS_LABEL',
Expand Down Expand Up @@ -280,7 +290,6 @@ export const BUILDER = {
UPLOAD_FILE_INFORMATIONS: 'UPLOAD_FILE_INFORMATIONS',
UPLOAD_FILE_LIMITATIONS_TEXT: 'UPLOAD_FILE_LIMITATIONS_TEXT',
UPLOAD_FILE_TITLE: 'UPLOAD_FILE_TITLE',
USER_SWITCH_PROFILE_BUTTON: 'USER_SWITCH_PROFILE_BUTTON',
USER_SWITCH_SIGN_OUT_BUTTON: 'USER_SWITCH_SIGN_OUT_BUTTON',
USER_SWITCH_SIGNED_OUT_TOOLTIP: 'USER_SWITCH_SIGNED_OUT_TOOLTIP',
USER_SWITCH_SWITCH_USER_TEXT: 'USER_SWITCH_SWITCH_USER_TEXT',
Expand Down
1 change: 1 addition & 0 deletions src/constants/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,5 @@ export * from './categories';
export * from './common';
export * from './chatbox';
export * from './library';
export * from './mail';
export * from './messages';
3 changes: 2 additions & 1 deletion src/constants/library.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ export const LIBRARY = {
SHARE_FACEBOOK_MESSAGE: 'SHARE_FACEBOOK_MESSAGE',
AUTHORSHIP_AUTHOR_TITLE: 'AUTHORSHIP_AUTHOR_TITLE',
COLLECTION_ITEMS_EMPTY_MESSAGE: 'COLLECTION_ITEMS_EMPTY_MESSAGE',
COLLECTION_ITEMS_EMPTY_FOLDER_MESSAGE: 'COLLECTION_ITEMS_EMPTY_FOLDER_MESSAGE',
COLLECTION_ITEMS_EMPTY_FOLDER_MESSAGE:
'COLLECTION_ITEMS_EMPTY_FOLDER_MESSAGE',
COLLECTION_ITEMS_TITLE: 'COLLECTION_ITEMS_TITLE',
COLLECTION_ITEMS_TOOLTIP_MESSAGE: 'COLLECTION_ITEMS_TOOLTIP_MESSAGE',
SIGN_IN_MODAL_SIGN_IN_BUTTON: 'SIGN_IN_MODAL_SIGN_IN_BUTTON',
Expand Down
26 changes: 26 additions & 0 deletions src/constants/mail.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
export const MAIL = {
GREETINGS: 'GREETINGS',
SIGN_UP_VERIFY_EMAIL: 'SIGN_UP_VERIFY_EMAIL',
SIGN_UP_TEXT: 'SIGN_UP_TEXT',
SIGN_UP_BUTTON_TEXT: 'SIGN_UP_BUTTON_TEXT',
SIGN_UP_NOT_REQUESTED: 'SIGN_UP_NOT_REQUESTED',
SIGN_IN_NOT_REQUESTED: 'SIGN_IN_NOT_REQUESTED',
SIGN_IN_BUTTON_TEXT: 'SIGN_IN_BUTTON_TEXT',
SIGN_IN_TEXT: 'SIGN_IN_TEXT',
EXPORT_ACTIONS_TEXT: 'EXPORT_ACTIONS_TEXT',
EXPORT_ACTIONS_BUTTON_TEXT: 'EXPORT_ACTIONS_BUTTON_TEXT',
EXPORT_ACTIONS_TITLE: 'EXPORT_ACTIONS_TITLE',
SIGN_IN_TITLE: 'SIGN_IN_TITLE',
SIGN_UP_TITLE: 'SIGN_UP_TITLE',
INVITATION_TEXT: 'INVITATION_TEXT',
INVITATION_TITLE: 'INVITATION_TITLE',
PUBLISH_ITEM_TEXT: 'PUBLISH_ITEM_TEXT',
PUBLISH_ITEM_BUTTON_TEXT: 'PUBLISH_ITEM_BUTTON_TEXT',
PUBLISH_ITEM_TITLE: 'PUBLISH_ITEM_TITLE',
CHAT_MENTION_TEXT: 'CHAT_MENTION_TEXT',
CHAT_MENTION_TITLE: 'CHAT_MENTION_TITLE',
CHAT_MENTION_BUTTON_TEXT: 'CHAT_MENTION_BUTTON_TEXT',
SHARE_ITEM_TEXT: 'SHARE_ITEM_TEXT',
SHARE_ITEM_BUTTON: 'SHARE_ITEM_BUTTON',
SHARE_ITEM_TITLE: 'SHARE_ITEM_TITLE',
};
23 changes: 20 additions & 3 deletions src/constants/messages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ export const FAILURE_MESSAGES = {
S3_FILE_NOT_FOUND: 'S3_FILE_NOT_FOUND',
INVALID_PASSWORD: 'INVALID_PASSWORD',
EMPTY_CURRENT_PASSWORD: 'EMPTY_CURRENT_PASSWORD',
UPLOAD_FILE_UNEXPECTED_ERROR: 'UPLOAD_FILE_UNEXPECTED_ERROR',
DOWNLOAD_FILE_UNEXPECTED_ERROR: 'DOWNLOAD_FILE_UNEXPECTED_ERROR',

// zip
INVALID_ARCHIVE_FILE: 'INVALID_ARCHIVE_FILE',
Expand Down Expand Up @@ -73,6 +75,14 @@ export const FAILURE_MESSAGES = {

// sharing item
COPY_LINK_TO_CLIPBOARD_ERROR: 'COPY_LINK_TO_CLIPBOARD_ERROR',

// password
PASSWORD_EMPTY_ERROR: 'Please enter a valid password',
PASSWORD_WEAK_ERROR: '"New Password" not strong enough',
PASSWORD_EQUAL_ERROR:
'Please enter a new password different from your current one',
PASSWORD_CONFIRM_ERROR:
'Please make sure "New Password" matches "Confirm password"',
};

export const DEFAULT_FAILURE_MESSAGE = FAILURE_MESSAGES.UNEXPECTED_ERROR;
Expand Down Expand Up @@ -115,13 +125,20 @@ export const SUCCESS_MESSAGES = {
DELETE_ITEM_TAG: 'DELETE_ITEM_TAG',
DELETE_MEMBER: 'DELETE_MEMBER',
UPDATE_PASSWORD: 'UPDATE_PASSWORD',
DELETE_ITEM_LOGIN_SCHEMA: 'DELETE_ITEM_LOGIN_SCHEMA',
PUT_ITEM_LOGIN_SCHEMA: 'PUT_ITEM_LOGIN_SCHEMA',

// sharing item
COPY_LINK_TO_CLIPBOARD: 'COPY_LINK_TO_CLIPBOARD',
};

// todo: might not be used anymore if we add a progress bar
export const REQUEST_MESSAGES = {
IMPORT_ZIP: 'The ZIP file is being processed. Please wait a moment.',
IMPORT_H5P: 'The H5P file is being processed. Please wait a moment.',
IMPORT_H5P: 'REQUEST_MESSAGES_IMPORT_H5P',
IMPORT_ZIP: 'REQUEST_MESSAGES_IMPORT_ZIP',
UPLOAD_FILES: 'REQUEST_MESSAGES_UPLOAD_FILES',
RECYCLE_ITEMS: 'REQUEST_MESSAGES_RECYCLE_ITEMS',
MOVE_ITEMS: 'REQUEST_MESSAGES_MOVE_ITEMS',
RESTORE_ITEMS: 'REQUEST_MESSAGES_RESTORE_ITEMS',
COPY_ITEMS: 'REQUEST_MESSAGES_COPY_ITEMS',
DELETE_ITEMS: 'REQUEST_MESSAGES_DELETE_ITEMS',
};
4 changes: 2 additions & 2 deletions src/i18n.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { en, fr, de, it, ar, namespaces } from './langs';

export const DEFAULT_LANG = 'en';

const buildI18n = (defaultNamespace = namespaces.messages) => {
const buildI18n = (defaultNamespace = namespaces.messages, debug?: boolean) => {
i18n.init({
resources: {
en,
Expand All @@ -15,7 +15,7 @@ const buildI18n = (defaultNamespace = namespaces.messages) => {
lng: DEFAULT_LANG,
fallbackLng: DEFAULT_LANG,
// debug only when not in production
debug: process.env.NODE_ENV !== 'production',
debug: debug ?? process.env.NODE_ENV !== 'production',
// define accessible namespaces
ns: Object.values(namespaces),
// define default namespace
Expand Down
1 change: 1 addition & 0 deletions src/langs/ar/mail.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
1 change: 1 addition & 0 deletions src/langs/de/mail.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
26 changes: 26 additions & 0 deletions src/langs/en/mail.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"GREETINGS": "Thank you for signing up to our platform.",
"SIGN_UP_VERIFY_EMAIL": "Please verify your email by clicking on the following button.",
"SIGN_UP_TEXT": "Complete registration and sign in",
"SIGN_UP_NOT_REQUESTED": "If you don't remember signing up to Graasp, you can just ignore this email.",
"SIGN_IN_BUTTON_TEXT": "Sign In",
"SIGN_UP_BUTTON_TEXT": "Register",
"SIGN_IN_TEXT": "You asked us to send you a magic link for quickly signing in to your account. Here your go:",
"SIGN_IN_NOT_REQUESTED": "If you haven't requested the link, no further action is required. It will expire soon, don't worry your account and data are safe.",
"EXPORT_ACTIONS_TEXT": "You requested to download actions from item {{itemName}}, here is the link to download the files. It will be available for {{days}} days",
"EXPORT_ACTIONS_BUTTON_TEXT": "Download",
"SIGN_IN_TITLE": "Sign In Link",
"SIGN_UP_TITLE": "Register",
"EXPORT_ACTIONS_TITLE": "Analytic Traces Download Link for {{itemName}}",
"INVITATION_TEXT": "{{creatorName}} shared {{itemName}} with you on the Graasp platform. Click on the following button to complete your registration.",
"INVITATION_TITLE": "The item {{itemName}} was shared with you on Graasp",
"PUBLISH_ITEM_TEXT": "Your item {{itemName}} has been published to Graasp Library. Click on the following link to view it.",
"PUBLISH_ITEM_BUTTON_TEXT": "View Item",
"PUBLISH_ITEM_TITLE": "{{itemName}} has been published",
"CHAT_MENTION_TEXT": "You have been mentioned in a message by {{creatorName}} in {{itemName}}. Click on the following link to view the conversation.",
"CHAT_MENTION_TITLE": "{{creatorName}} mentioned you in {{itemName}}",
"CHAT_MENTION_BUTTON_TEXT": "View Conversation",
"SHARE_ITEM_TEXT": "The item {{itemName}} has been shared with you on Graasp. Click on the following link to view the item in Graasp Builder.",
"SHARE_ITEM_BUTTON": "View Item",
"SHARE_ITEM_TITLE": "{{creatorName}} has shared {{itemName}} with you on Graasp"
}
23 changes: 20 additions & 3 deletions src/langs/en/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
"INVALID_DOWNLOAD_PARAMETERS": "One or many download parameters are invalid",
"LOCAL_FILE_NOT_FOUND": "The local file is not found",
"S3_FILE_NOT_FOUND": "The S3 file is not found",
"INVALID_PASSWORD": "Current password is invalid. Please try again",
"EMPTY_CURRENT_PASSWORD": "You forgot to input your current password. Please try again",
"UPLOAD_FILE_UNEXPECTED_ERROR": "An unexpected error happened while uploading a file",
"DOWNLOAD_FILE_UNEXPECTED_ERROR": "An unexpected error happened while downloading a file",

"RESTORE_ITEMS": "You successfully restored the item(s)",
"CREATE_ITEM": "The item was successfully created",
Expand Down Expand Up @@ -72,6 +72,8 @@
"IMPORT_H5P": "The H5P package was successfully imported",
"DELETE_MEMBER": "The account was successfully deleted",
"UPDATE_PASSWORD": "The password was updated successfully",
"DELETE_ITEM_LOGIN_SCHEMA": "The item login schema was deleted successfully",
"PUT_ITEM_LOGIN_SCHEMA": "The item login schema was updated successfully",

"INVALID_ARCHIVE_FILE": "The submitted file is not a zip archive",
"INVALID_FILE_ITEM": "The file's properties are invalid",
Expand All @@ -95,5 +97,20 @@
"INVALID_ITEM_STATUS": "The item does not satisfy the requirements",

"COPY_LINK_TO_CLIPBOARD_ERROR": "Unable to copy the link to the clipboard",
"COPY_LINK_TO_CLIPBOARD": "Link copied to clipboard"
"COPY_LINK_TO_CLIPBOARD": "Link copied to clipboard",
"REQUEST_MESSAGES_RECYCLE_ITEMS": "The selected item(s) will be put in the trash. It can take several minutes to take effect.",
"REQUEST_MESSAGES_MOVE_ITEMS": "The selected item(s) will be moved. It can take several minutes to take effect.",
"REQUEST_MESSAGES_RESTORE_ITEMS": "The selected item(s) will be restored. It can take several minutes to take effect.",
"REQUEST_MESSAGES_DELETE_ITEMS": "The selected item(s) will be deleted. It can take several minutes to take effect.",

"PASSWORD_EMPTY_ERROR": "Please enter a valid password",
"PASSWORD_WEAK_ERROR": "The new password is not strong enough",
"PASSWORD_EQUAL_ERROR": "Please enter a new password different from your current one",
"PASSWORD_CONFIRM_ERROR": "Please make sure the new password matches the confirmation",
"INVALID_PASSWORD": "Current password is invalid. Please try again",
"EMPTY_CURRENT_PASSWORD": "You forgot to input your current password. Please try again",

"REQUEST_MESSAGES_IMPORT_ZIP": "The ZIP file is being processed. Please wait a moment.",
"REQUEST_MESSAGES_IMPORT_H5P": "The H5P file is being processed. Please wait a moment.",
"REQUEST_MESSAGES_UPLOAD_FILES": "The file(s) are in queue for uploading. Please wait a moment."
}
Loading

0 comments on commit 204d3ac

Please sign in to comment.