Skip to content

Commit

Permalink
Merge pull request #66 from intuitem/CA-155-French-translation
Browse files Browse the repository at this point in the history
Ca 155 french translation
  • Loading branch information
eric-intuitem authored Feb 24, 2024
2 parents ad6c317 + 2277d5e commit 53dd509
Show file tree
Hide file tree
Showing 39 changed files with 1,602 additions and 1,264 deletions.
70 changes: 63 additions & 7 deletions frontend/messages/en.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,31 @@
{
"$schema": "https://inlang.com/schema/inlang-message-format",
"addButton": "Add {model}",
"associatedObject": "Associated {model}",
"french": "French",
"english": "English",
"addThreat": "New threat",
"addSecurityFunction": "New security function",
"addSecurityMeasure": "New security measure",
"addAsset": "New asset",
"addRiskAssessment": "New risk assessment",
"addRiskScenario": "New risk scenario",
"addRiskAcceptance": "New risk acceptance",
"addComplianceAssessment": "New compliance assessment",
"addEvidence": "New evidence",
"addDomain": "New domain",
"addProject": "New project",
"addUser": "New user",
"associatedThreats": "Associated threats",
"associatedSecurityFunctions": "Associated security functions",
"associatedSecurityMeasures": "Associated security measures",
"associatedAssets": "Associated assets",
"associatedRiskAssessments": "Associated risk assessments",
"associatedRiskScenarios": "Associated risk scenarios",
"associatedRiskAcceptances": "Associated risk acceptances",
"associatedComplianceAssessments": "Associated compliance assessments",
"associatedEvidences": "Associated evidences",
"associatedDomains": "Associated domains",
"associatedProjects": "Associated projects",
"associatedUsers": "Associated users",
"home": "Home",
"edit": "Edit",
"overview": "Overview",
Expand Down Expand Up @@ -125,7 +147,7 @@
"statistics": "Statistics",
"myProjects": "My projects",
"scenarios": "Scenarios",
"assignedObjects": "Assigned to {number} {object}",
"assignedProjects": "Assigned to {number} project{s}",
"currentRiskLevelPerScenario": "Current risk level per risk scenario",
"residualRiskLevelPerScenario": "Residual risk level per risk scenario",
"securityMeasuresStatus": "Security measures status",
Expand All @@ -147,7 +169,8 @@
"upcoming": "Upcoming",
"today": "Today",
"actionRequested": "Action requested",
"noObjectYet": "No {object} yet",
"noRiskAcceptanceYet": "No risk acceptance yet",
"noSecurityMeasureYet": "No security measure yet",
"authors": "Authors",
"reviewers": "Reviewers",
"process": "Process",
Expand All @@ -161,7 +184,7 @@
"pendingMeasures": "Your pending measures",
"orderdByRankingScore": "Ordered by ranking score",
"rankingScore": "Ranking score",
"noPendingObject": "No pending {object}",
"noPendingSecurityMeasure": "No pending security measure",
"rankingScoreDefintion": "Ranking score is an adaptive metric that combines the information of effort and current risk level, and crosses it with the other data to assist you for the prioritization",
"actions": "Actions",
"projectsSummaryEmpty": "Projects summary is empty",
Expand All @@ -172,6 +195,39 @@
"measureOpen": "Measure: open",
"measureProgress": "Measure: in progress",
"measureHold": "Measure: on hold",
"measureDone": "Measure: done"

"measureDone": "Measure: done",
"monday": "Monday",
"tuesday": "Tuesday",
"wednesday": "Wednesday",
"thursday": "Thursday",
"friday": "Friday",
"saturday": "Saturday",
"sunday": "Sunday",
"january": "January",
"february": "February",
"march": "March",
"april": "April",
"may": "May",
"june": "June",
"july": "July",
"august": "August",
"september": "September",
"october": "October",
"november": "November",
"december": "December",
"errorsFound": "error{s} found",
"warningsFound": "warning{s} found",
"infosFound": "info{s} found",
"remediationPlan": "Remediation plan",
"treatmentPlan": "Treatment plan",
"asPDF": "as PDF",
"asCSV": "as CSV",
"draft": "Draft",
"riskMatrixView": "Risk matrix view",
"currentInMatrixView": "Current",
"residualInMatrixView": "Residual",
"probability": "Probability",
"riskLevels": "Risk levels",
"cancel": "Cancel",
"save": "Save"
}
72 changes: 64 additions & 8 deletions frontend/messages/fr.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,31 @@
{
"$schema": "https://inlang.com/schema/inlang-message-format",
"addButton": "Ajouter {determinant} {model}",
"associatedObject": "{model} associé{e}s",
"french": "Français",
"english": "Anglais",
"addThreat": "Ajouter une menace",
"addSecurityFunction": "Ajouter une fonction de sécurité",
"addSecurityMeasure": "Ajouter une mesure de sécurité",
"addAsset": "Ajouter un bien sensible",
"addRiskAssessment": "Ajouter une évaluation de risque",
"addRiskScenario": "Ajouter un scénario de risque",
"addRiskAcceptance": "Ajouter une acceptation de risque",
"addComplianceAssessment": "Ajouter une évaluation de conformité",
"addEvidence": "Ajouter une preuve",
"addDomain": "Ajouter un domaine",
"addProject": "Ajouter un projet",
"addUser": "Ajouter un utilisateur",
"associatedThreats": "Menaces associées",
"associatedSecurityFunctions": "Fonctions de sécurité associées",
"associatedSecurityMeasures": "Mesures de sécurité associées",
"associatedAssets": "Biens sensibles associés",
"associatedRiskAssessments": "Évaluations de risque associées",
"associatedRiskScenarios": "Scénarios de risque associés",
"associatedRiskAcceptances": "Acceptations de risque associées",
"associatedComplianceAssessments": "Évaluations de conformité associées",
"associatedEvidences": "Preuves associées",
"associatedDomains": "Domaines associés",
"associatedProjects": "Projets associés",
"associatedUsers": "Utilisateurs associés",
"home": "Accueil",
"edit": "Modifier",
"overview": "Vue d'ensemble",
Expand Down Expand Up @@ -39,7 +61,7 @@
"userGroups": "Groupes d'utilisateurs",
"roleAssignments": "Affectations de rôle",
"xRays": "X-rays",
"scoringAssistant": "Assistat d'évaluation",
"scoringAssistant": "Assistant d'évaluation",
"libraries": "Bibliothèques",
"backupRestore": "Sauvegarde et restauration",
"myProfile": "Mon profil",
Expand Down Expand Up @@ -125,7 +147,7 @@
"statistics": "Statistiques",
"myProjects": "Mes projets",
"scenarios": "Scénarios",
"assignedObjects": "Assigné à {number} {object}",
"assignedProjects": "Assigné à {number} project{s}",
"currentRiskLevelPerScenario": "Niveau de risque courant par scénario de risque",
"residualRiskLevelPerScenario": "Niveau de risque résiduel par scénario de risque",
"securityMeasuresStatus": "Statut des mesures de sécurité",
Expand All @@ -147,7 +169,8 @@
"upcoming": "À venir",
"today": "Aujourd'hui",
"actionRequested": "Action requise",
"noObjectYet": "Aucun{e} {object} pour le moment",
"noRiskAcceptanceYet": "Aucune acceptation de risque pour le moment",
"noSecurityMeasureYet": "Aucune mesure de sécurité pour le moment",
"authors": "Auteurs",
"reviewers": "Relecteurs",
"process": "Traiter",
Expand All @@ -161,7 +184,7 @@
"pendingMeasures": "Vos mesures en attente",
"orderdByRankingScore": "Classées par score",
"rankingScore": "Score de classement",
"noPendingObject": "Aucun{e} {objet} en attente",
"noPendingSecurityMeasure": "Aucune mesure de sécurité en attente",
"rankingScoreDefintion": "Le score de classement est une mesure adaptative qui combine les informations relatives à l'effort et au niveau de risque actuel, et les croise avec d'autres données pour vous aider à établir des priorités",
"actions": "Actions",
"projectsSummaryEmpty": "Le résumé des projets est vide",
Expand All @@ -172,6 +195,39 @@
"measureOpen": "Mesure: ouverte",
"measureProgress": "Mesure: en cours",
"measureHold": "Mesure: en attente",
"measureDone": "Mesure: terminée"
"measureDone": "Mesure: terminée",
"monday": "Lundi",
"tuesday": "Mardi",
"wednesday": "Mercredi",
"thursday": "Jeudi",
"friday": "Vendredi",
"saturday": "Samedi",
"sunday": "Dimanche",
"january": "Janvier",
"february": "Février",
"march": "Mars",
"april": "Avril",
"may": "Mai",
"june": "Juin",
"july": "Juillet",
"august": "Août",
"september": "Septembre",
"october": "Octobre",
"november": "Novembre",
"december": "Décembre",
"errorsFound": "erreur{s} trouvée{s}",
"warningsFound": "avertissement{s} trouvé{s}",
"infosFound": "info{s} trouvée{s}",
"remediationPlan": "Plan de remédiation",
"treatmentPlan": "Plan de traitement",
"asPDF": "en PDF",
"asCSV": "en CSV",
"draft": "Brouillon",
"riskMatrixView": "Vue de la matrice de risque",
"currentInMatrixView": "Courante",
"residualInMatrixView": "Residuelle",
"probability": "Probabilité",
"riskLevels": "Niveaux de risque",
"cancel": "Annuler",
"save": "Enregistrer"
}

29 changes: 17 additions & 12 deletions frontend/playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ import { devices } from '@playwright/test';

const config: PlaywrightTestConfig = {
webServer: {
command: process.env.COMPOSE_TEST ? 'echo "The docker compose frontend server didn\'t start correctly"' : 'npm run build && npm run preview',
command: process.env.COMPOSE_TEST
? 'echo "The docker compose frontend server didn\'t start correctly"'
: 'npm run build && npm run preview',
port: process.env.COMPOSE_TEST ? 3000 : 4173,
reuseExistingServer: process.env.COMPOSE_TEST
},
Expand All @@ -15,34 +17,37 @@ const config: PlaywrightTestConfig = {
workers: process.env.CI ? 1 : 1,
globalTimeout: 60 * 60 * 1000,
timeout: 50 * 1000,
expect : {
expect: {
timeout: 10 * 1000
},
reporter: [
[process.env.CI ? 'github' : 'list'],
['html', {
open: process.env.CI ? 'never' : process.env.DOCKER ? 'always' : 'on-failure',
outputFolder: 'tests/reports',
host: process.env.DOCKER ? '0.0.0.0' : 'localhost'
}]
[
'html',
{
open: process.env.CI ? 'never' : process.env.DOCKER ? 'always' : 'on-failure',
outputFolder: 'tests/reports',
host: process.env.DOCKER ? '0.0.0.0' : 'localhost'
}
]
],
use: {
screenshot: 'only-on-failure',
video: process.env.CI ? 'retain-on-failure' : 'on',
trace: process.env.CI ? 'retain-on-failure' : 'on',
contextOptions: {
recordVideo: { dir: "tests/results/videos"},
},
recordVideo: { dir: 'tests/results/videos' }
}
},
projects: [
{
name: 'chromium',
use: { ...devices['Desktop Chrome'] },
use: { ...devices['Desktop Chrome'] }
},
{
name: 'firefox',
use: { ...devices['Desktop Firefox'] },
},
use: { ...devices['Desktop Firefox'] }
}
// {
// name: 'webkit',
// use: { ...devices['Desktop Safari'] },
Expand Down
25 changes: 13 additions & 12 deletions frontend/src/lib/components/Breadcrumbs/Breadcrumbs.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,41 +9,42 @@
let crumbs: Array<{ label: string; href: string; icon?: string }> = [];
function capitalizeSecondWord(sentence: string) {
var words = sentence.split(' ');
var words = sentence.split(' ');
if (words.length >= 2) {
words[1] = words[1].charAt(0).toUpperCase() + words[1].substring(1);
return words.join('');
} else {
return sentence;
}
}
if (words.length >= 2) {
words[1] = words[1].charAt(0).toUpperCase() + words[1].substring(1);
return words.join('');
} else {
return sentence;
}
}
$: {
// Remove zero-length tokens.
const tokens = $page.url.pathname.split('/').filter((t) => t !== '');
let title = '';
// Create { label, href } pairs for each token.
let tokenPath = '';
crumbs = tokens.map((t) => {
tokenPath += '/' + t;
if (t === $breadcrumbObject.id) {
if ($breadcrumbObject.name) t = $breadcrumbObject.name;
else t = $breadcrumbObject.email;
if ($breadcrumbObject.name) title = $breadcrumbObject.name;
else title = $breadcrumbObject.email;
} else if (t === 'folders') {
t = 'domains';
}
t = t.replace(/-/g, ' ');
t = capitalizeSecondWord(t);
return {
label: $page.data.label || t,
label: $page.data.label || title || t,
href: Object.keys(listViewFields).includes(tokens[0]) ? tokenPath : null
};
});
crumbs.unshift({ label: m.home(), href: '/', icon: 'fa-regular fa-compass' });
if (crumbs[crumbs.length - 1].label != 'edit') pageTitle.set(crumbs[crumbs.length - 1].label);
else pageTitle.set(m.edit()+ ' ' + crumbs[crumbs.length - 2].label);
else pageTitle.set(m.edit() + ' ' + crumbs[crumbs.length - 2].label);
}
</script>

Expand Down
Loading

0 comments on commit 53dd509

Please sign in to comment.