diff --git a/storage/lang/en_US.yml b/storage/lang/en_US.yml index 2fcbb03..cbdb9a3 100755 --- a/storage/lang/en_US.yml +++ b/storage/lang/en_US.yml @@ -12,6 +12,13 @@ # %seo_description% - The SEO description of the application # %seo_keywords% - The SEO keywords of the application +# If you were asking what raw input means here is a simple explanation: +# Raw input means that the input is not processed by the framework. This means that the input is not escaped or sanitized. +# This is useful for passwords or other sensitive data that should not be processed by the framework. + +# The language file is divided into sections. Each section has its own keys and values. +# You can use the keys in your views to display the values in the correct language. + Pages: Components: Sidebar: @@ -91,7 +98,122 @@ Pages: Title: "Invalid credentials" Description: "The credentials you provided are invalid." Button: "Go back home" + Account: + Components: + Navbar: + Settings: "Settings" + Security: "Security" + Mails: "Mails" + Activities: "Activities" + APIKeys: "API Keys" + Connections: "Connections" + Profile: + UUID: "UUID:" + Role: "Role:" + FirstIP: "First IP:" + Verified: "Verified:" + FirstSeen: "First seen:" + Security: + CurrentPassword: + Label: "Current password" + Placeholder: "············" # Raw input !! + NewPassword: + Label: "New password" + Placeholder: "············" # Raw input !! + ConfirmPassword: + Label: "Confirm password" + Placeholder: "············" # Raw input !! + PasswordRequirements: + Title: "Password requirements:" + Items: + Length: "At least 8 characters" + Uppercase: "At least one uppercase letter" + Lowercase: "At least one lowercase letter" + Number: "At least one number" + Special: "At least one special character" + SaveChanges: "Save changes" + Reset: "Reset" + TwoFactor: + Title: "Two Factor verification" + Enabled: + Title: "Two factor authentication is enabled." + Description: "Two-factor authentication adds an additional layer of security to your account by requiring more than just a password to log in." + LearnMore: "Learn more" + Button: "Enable two factor authentication" + Disabled: + Title: "Two factor authentication is not enabled yet." + Description: "Two-factor authentication adds an additional layer of security to your account by requiring more than just a password to log in." + LearnMore: "Learn more" + Button: "Disable two factor authentication" + Settings: + Form: + FirstName: + Label: "First name" + LastName: + Label: "Last name" + Email: + Label: "Email" + Avatar: + Label: "Avatar" + Background: + Label: "Background" + Submit: "Save changes" + Cancel: "Cancel" + DeactivateAccount: + Title: "Deactivate account" + Warning: + Title: "Are you sure you want to delete your account?" + Items: + First: "Once you delete your account, there is a 30 days window for you to contact support" + Secondary: "to recover your account. After 30 days, your account will be permanently disabled." + Third: "This means that you account will be marked as deleted BUT we reserve to keep all the data" + Fourth: "for legal reasons. You may open a ticket for your data to be anonymized due to GDPR!" + Confirm: "Yes, i want to delete my account and i agree with the terms of the account deletion policy." + Button: "Deactivate account" + Mails: + Table: + Head: + Columns: + ID: "ID" + Subject: "Subject" + From: "From" + Date: "Date" + Actions: "Actions" + Actions: + View: "View" + Delete: "Delete" + ApiKeys: + Create: + Title: "Create API Key" + Form: + Name: + Label: "Name the API key" + Placeholder: "Enter the name of the API key..." + Permissions: + Label: "Permissions" + Placeholder: "Select the permissions..." + Items: + ReadOnly: "Read Only" + ReadWrite: "Read & Write" + Unknown: "Unknown" + Submit: + Label: "Create new key" + List: + Title: "API Key List & Access" + Description: "An API key is a simple encrypted string that identifies an application without any principal. They are useful for accessing public data anonymously, and are used to associate API requests with your project for quota and billing." + Items: + Created: "Created on" + Deleted: "Delete" + Activities: + Table: + Head: + Columns: + ID: "ID" + Action: "Action" + Description: "Description" + IPAddress: "IP Address" + Date: "Date" Auth: Login: Title: "Welcome back 👋!" diff --git a/storage/themes/v2/account/activities.twig b/storage/themes/v2/account/activities.twig index f9770b8..9515466 100755 --- a/storage/themes/v2/account/activities.twig +++ b/storage/themes/v2/account/activities.twig @@ -19,11 +19,11 @@ - - - - - + + + + + diff --git a/storage/themes/v2/account/api.twig b/storage/themes/v2/account/api.twig index 6896f1f..b2a057d 100755 --- a/storage/themes/v2/account/api.twig +++ b/storage/themes/v2/account/api.twig @@ -14,61 +14,58 @@
- - - - -
-
Create an API key
-
-
-
-
-
-
- - -
-
- - -
- {{ csrf_input | raw }} - - {% if isTurnStileEnabled == true %} -
-
-
-
-
-
-
- {% else %} -
- {% endif %} -
- + +
+
   {{lang("Pages.Account.ApiKeys.Create.Title")}}
+
+
+ +
+
+ + +
+
+ + +
+ {{ csrf_input | raw }} + + {% if isTurnStileEnabled == true %} +
+
+
+
+
+
+
+ {% else %} +
+ {% endif %} +
+ +
-
- + +
-
-
-
- Api Key Image +
+
+ Api Key Image +
-
API Key List & Access
+
{{ lang('Pages.Account.ApiKeys.Create.List.Title') }}

- An API key is a simple encrypted string that identifies an application without any principal. They are useful for accessing public data anonymously, and are used to associate API requests with your project for quota and billing. + {{lang("Pages.Account.ApiKeys.Create.List.Description") }}

@@ -79,11 +76,11 @@ ({{api_key.id}}) {% if api_key.type == 'rw' %} - Read & Write + {{ lang('Pages.Account.ApiKeys.Create.Form.Permissions.Items.ReadWrite') }} {% elseif api_key.type == 'r' %} - Read + {{ lang('Pages.Account.ApiKeys.Create.Form.Permissions.Items.ReadOnly') }} {% else %} - Unknown + {{ lang('Pages.Account.ApiKeys.Create.Form.Permissions.Items.Unknown') }} {% endif %}
@@ -93,11 +90,11 @@
- Created on + {{ lang('Pages.Account.ApiKeys.Create.List.Items.Created') }} {{ api_key.date}}
@@ -114,18 +111,18 @@ {% endblock %} {% block footer %} - {% include 'requirements/datatables.twig' %} + {% include 'requirements/datatables.twig' %} + document.getElementById('formAccountSettingsApiKey').addEventListener('submit', function(event) { + const apiKey = document.getElementById('apiKey').value; + const apiAccess = document.getElementById('apiAccess').value; + + if (apiKey === '' || apiAccess === '') { + Swal.fire({icon: 'error',title: "{{ lang('Alerts.Error.PleaseFillAllFields.Title') }}",text: "{{ lang('Alerts.Error.PleaseFillAllFields.Message') }}"}); + event.preventDefault(); + return; + } + }); + {% endblock %} diff --git a/storage/themes/v2/account/components/navbar.twig b/storage/themes/v2/account/components/navbar.twig index 0c40e98..276951e 100755 --- a/storage/themes/v2/account/components/navbar.twig +++ b/storage/themes/v2/account/components/navbar.twig @@ -3,35 +3,35 @@ {% if settings('smtp','enabled') == "true" %} {% endif %}
diff --git a/storage/themes/v2/account/components/profile.twig b/storage/themes/v2/account/components/profile.twig index ab7c2ac..e785a4e 100755 --- a/storage/themes/v2/account/components/profile.twig +++ b/storage/themes/v2/account/components/profile.twig @@ -2,19 +2,19 @@
user-avatar
-
UUID: +
{{ lang('Pages.Account.Components.Profile.UUID') }} {{ user('uuid',false) }}
-
Role: +
{{ lang('Pages.Account.Components.Profile.Role') }} {{role_name}}
-
First IP: +
{{ lang('Pages.Account.Components.Profile.FirstIP') }} {{user('first_ip',true) }} / ({{user('last_ip',true) }})
-
Verified: +
{{ lang('Pages.Account.Components.Profile.Verified') }} {{user('verified',false) }}
-
First Seen: +
{{ lang('Pages.Account.Components.Profile.FirstSeen') }} {{user('first_seen',false) }} / ({{user('last_seen',false) }})
diff --git a/storage/themes/v2/account/mails.twig b/storage/themes/v2/account/mails.twig index c20cc9a..105ba90 100755 --- a/storage/themes/v2/account/mails.twig +++ b/storage/themes/v2/account/mails.twig @@ -19,11 +19,11 @@
IDActionDescriptionIp AddressDate{{lang("Pages.Account.Activities.Table.Head.Columns.ID")}}{{lang("Pages.Account.Activities.Table.Head.Columns.Action")}}{{lang("Pages.Account.Activities.Table.Head.Columns.Description")}}{{lang("Pages.Account.Activities.Table.Head.Columns.IPAddress")}}{{lang("Pages.Account.Activities.Table.Head.Columns.Date")}}
- - - - - + + + + + @@ -34,8 +34,8 @@ {% endfor %} diff --git a/storage/themes/v2/account/security.twig b/storage/themes/v2/account/security.twig index 78c6621..f7c2c41 100755 --- a/storage/themes/v2/account/security.twig +++ b/storage/themes/v2/account/security.twig @@ -19,9 +19,9 @@
- +
- + @@ -31,9 +31,9 @@
- +
- + @@ -42,9 +42,9 @@
- +
- + @@ -52,11 +52,14 @@
-
Password Requirements:
+
{{ lang('Pages.Account.Security.PasswordRequirements.Title') }}
    -
  • Minimum 8 characters long - the more, the better
  • -
  • At least one lowercase character
  • -
  • At least one number, symbol, or whitespace character
  • +
  • {{ lang('Pages.Account.Security.PasswordRequirements.Items.Length') }}
  • +
  • {{ lang('Pages.Account.Security.PasswordRequirements.Items.Uppercase') }}
  • +
  • {{ lang('Pages.Account.Security.PasswordRequirements.Items.Lowercase') }}
  • +
  • {{ lang('Pages.Account.Security.PasswordRequirements.Items.Number') }}
  • +
  • {{ lang('Pages.Account.Security.PasswordRequirements.Items.Special') }}
  • +
{{ csrf_input | raw }} @@ -67,8 +70,8 @@ {% else %} {% endif %}
- - + +
@@ -79,24 +82,24 @@
-
Two-steps verification
+
{{ lang('Pages.Account.Security.TwoFactor.Title') }}
{% if user('2fa_enabled',false) == "false" %} -
Two factor authentication is not enabled yet.
+
{{ lang('Pages.Account.Security.TwoFactor.Disabled.Title') }}

- Two-factor authentication adds an additional layer of security to your account by requiring more - than just a password to log in. - Learn more. + {{ lang('Pages.Account.Security.TwoFactor.Disabled.Description') }} + {{ lang('Pages.Account.Security.TwoFactor.Disabled.LearnMore') }}

- Enable Two-Factor Authentication + {{lang('Pages.Account.Security.TwoFactor.Enabled.Button') }} {% else %} -
Two factor authentication is enabled.
-

Two-factor authentication adds an additional layer of security to your account by requiring more than just a password to log in. - Learn more. +

{{ lang('Pages.Account.Security.TwoFactor.Enabled.Title') }}
+

+ {{ lang('Pages.Account.Security.TwoFactor.Enabled.Description') }} + {{ lang('Pages.Account.Security.TwoFactor.Enabled.LearnMore') }}

- Disable Two-Factor Authentication + {{ lang('Pages.Account.Security.TwoFactor.Disabled.Button') }} {% endif %} @@ -109,32 +112,32 @@ {% endblock %} {% block footer %} - + var firstPassword = document.getElementById('currentPassword').value; + var newPassword = document.getElementById('newPassword').value; + var confirmPassword = document.getElementById('confirmPassword').value; + + if ( firstPassword === '' || newPassword === '' || confirmPassword === '') { + Swal.fire({ + icon: 'error', + title: "{{ lang('Alerts.Error.PleaseFillAllFields.Title') }}", + text: "{{ lang('Alerts.Error.PleaseFillAllFields.Message') }}", + }); + return false; + } + + if (newPassword !== confirmPassword) { + Swal.fire({ + icon: 'error', + title: "{{ lang('Alerts.Error.PasswordsNotTheSame.Title') }}", + text: "{{ lang('Alerts.Error.PasswordsNotTheSame.Message') }}", + }); + return false; + } + event.target.submit(); + }); + {% endblock %} diff --git a/storage/themes/v2/account/settings.twig b/storage/themes/v2/account/settings.twig index 379c564..4f03ef3 100755 --- a/storage/themes/v2/account/settings.twig +++ b/storage/themes/v2/account/settings.twig @@ -18,25 +18,25 @@
- +
- +
- +
- +
- +
@@ -61,24 +61,35 @@
-
Delete Account
+
{{lang("Pages.Account.Settings.Form.DeactivateAccount.Title") }}
-
Are you sure you want to delete your account?
-

Once you delete your account, there is no going back. Please be certain.

+
{{ lang('Pages.Account.Settings.Form.DeactivateAccount.Warning.Title') }}
+

{{ lang('Pages.Account.Settings.Form.DeactivateAccount.Warning.Items.First') }}

+

{{ lang('Pages.Account.Settings.Form.DeactivateAccount.Warning.Items.Secondary') }}

+

{{ lang('Pages.Account.Settings.Form.DeactivateAccount.Warning.Items.Third') }}

+

{{ lang('Pages.Account.Settings.Form.DeactivateAccount.Warning.Items.Fourth') }}

+ +
- +
- + +
IDSubjectFromDateActions{{ lang('Pages.Account.Mails.Table.Head.Columns.ID') }}{{ lang('Pages.Account.Mails.Table.Head.Columns.Subject') }}{{ lang('Pages.Account.Mails.Table.Head.Columns.From') }}{{ lang('Pages.Account.Mails.Table.Head.Columns.Date') }}{{ lang('Pages.Account.Mails.Table.Head.Columns.Actions') }}
{{ email.from }} {{ email.date }} - View - + {{ lang('Pages.Account.Mails.Table.Head.Actions.View') }} +