Skip to content

Commit 1441c02

Browse files
author
Guillaume Chau
committed
feat(ui): fr locale + related fixes
1 parent 969e326 commit 1441c02

File tree

11 files changed

+288
-36
lines changed

11 files changed

+288
-36
lines changed

packages/@vue/cli-ui/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"prod-graphql-api": "cross-env NODE_ENV=production vue-cli-service run-graphql-api"
1111
},
1212
"dependencies": {
13-
"@vue/ui": "^0.2.0",
13+
"@vue/ui": "^0.2.1",
1414
"ansi_up": "^2.0.2",
1515
"apollo-cache-inmemory": "^1.1.10",
1616
"apollo-client": "^2.2.6",

packages/@vue/cli-ui/src/components/InstantSearchInput.vue

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
icon-left="search"
66
v-model="query"
77
class="big"
8-
:placeholder="$t('components.instant-search-input.placeholder')"
8+
:placeholder="placeholder"
99
>
1010
<template slot="right">
1111
<VueButton
@@ -26,6 +26,13 @@ export default {
2626
Component
2727
],
2828
29+
props: {
30+
placeholder: {
31+
type: String,
32+
default: null
33+
}
34+
},
35+
2936
computed: {
3037
query: {
3138
get() {

packages/@vue/cli-ui/src/components/PromptsList.vue

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@
99
:prompt="prompt"
1010
@answer="value => $emit('answer', { prompt, value })"
1111
/>
12+
13+
<div v-if="!prompts.length" class="vue-ui-empty">
14+
<VueIcon icon="check_circle" class="empty-icon"/>
15+
<span>{{ $t('components.prompts-list.empty') }}</span>
16+
</div>
1217
</div>
1318
</div>
1419
</template>

packages/@vue/cli-ui/src/graphql-api/connectors/plugins.js

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -218,11 +218,15 @@ function runInvoke (id, context) {
218218

219219
async function initPrompts (id, context) {
220220
prompts.reset()
221-
let data = require(path.join(getPath(id), 'prompts.js'))
222-
if (typeof data === 'function') {
223-
data = await data()
221+
try {
222+
let data = require(path.join(getPath(id), 'prompts.js'))
223+
if (typeof data === 'function') {
224+
data = await data()
225+
}
226+
data.forEach(prompts.add)
227+
} catch (e) {
228+
console.warn(`No prompts found for ${id}`)
224229
}
225-
data.forEach(prompts.add)
226230
prompts.start()
227231
}
228232

packages/@vue/cli-ui/src/locales/en.json

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@
1313
"empty": "No favorite folders yet."
1414
}
1515
},
16-
"instant-search-input": {
17-
"placeholder": "Search a plugin"
18-
},
1916
"list-item-info": {
2017
"more-info": "More Info"
2118
},
@@ -53,6 +50,9 @@
5350
"official": "Official",
5451
"installed": "Installed"
5552
},
53+
"prompts-list": {
54+
"empty": "No configuration"
55+
},
5656
"status-bar": {
5757
"project": {
5858
"tooltip": "Current project<br><i>Click to toggle Project Manager</i>",
@@ -77,9 +77,9 @@
7777
"completion-hooks": "Running completion hooks...",
7878
"fetch-remote-preset": "Fetching remote preset...",
7979
"done": "Successfully created project",
80-
"plugin-install": "Installing {arg0}",
81-
"plugin-uninstall": "Uninstalling {arg0}",
82-
"plugin-invoke": "Invoking {arg0}"
80+
"plugin-install": "Installing {arg0}...",
81+
"plugin-uninstall": "Uninstalling {arg0}...",
82+
"plugin-invoke": "Invoking {arg0}..."
8383
}
8484
},
8585
"views": {
@@ -108,7 +108,7 @@
108108
"action": "Select this folder"
109109
},
110110
"manager": {
111-
"label": "Project manager",
111+
"label": "Package manager",
112112
"default": "Default"
113113
},
114114
"options": {
@@ -145,7 +145,7 @@
145145
},
146146
"features": {
147147
"title": "Features",
148-
"description": "You will be able to add features after the project is created.",
148+
"description": "You will be able to add features after the project is created by installing plugins.",
149149
"enable": "Enable features",
150150
"buttons": {
151151
"previous": "Previous",
@@ -185,7 +185,8 @@
185185
"tabs": {
186186
"search": {
187187
"label": "Search",
188-
"not-found": "Not results found",
188+
"search-input": "Search a plugin",
189+
"not-found": "No results found",
189190
"buttons": {
190191
"cancel": "Cancel",
191192
"install": "Install {target}"
Lines changed: 221 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,221 @@
1+
{
2+
"components": {
3+
"folder-explorer": {
4+
"toolbar": {
5+
"tooltips": {
6+
"parent-folder": "Ouvrir le dossier parent",
7+
"edit-path": "Modifier le chemin",
8+
"favorite": "Ajouter/Retirer des favoris",
9+
"favorite-folders": "Dossiers favoris",
10+
"refresh": "Rafraichir"
11+
},
12+
"placeholder": "Entrer le chemin complet d'un dossier",
13+
"empty": "Aucun dossier favoris."
14+
}
15+
},
16+
"list-item-info": {
17+
"more-info": "Plus d'infos"
18+
},
19+
"logger-view": {
20+
"title": "Journal",
21+
"empty": "Aucune entrée du journal",
22+
"buttons": {
23+
"clear": "Nettoyer le journal",
24+
"scroll": "Défiler en bas",
25+
"close": "Fermer"
26+
}
27+
},
28+
"progress-screen": {
29+
"close": "Fermer"
30+
},
31+
"project-nav": {
32+
"tooltips": {
33+
"plugins": "Plugins",
34+
"configuration": "Configuration",
35+
"tasks": "Tâches"
36+
}
37+
},
38+
"project-select-list": {
39+
"empty": "Aucun projet"
40+
},
41+
"project-select-list-item": {
42+
"tooltips": {
43+
"favorite": "Ajouter/Retirer des favoris",
44+
"delete": "Supprimer"
45+
}
46+
},
47+
"project-plugin-item": {
48+
"version": "version",
49+
"latest": "dernière version",
50+
"official": "Officiel",
51+
"installed": "Installé"
52+
},
53+
"prompts-list": {
54+
"empty": "Pas de configuration"
55+
},
56+
"status-bar": {
57+
"project": {
58+
"tooltip": "Project actuel<br><i>Cliquer pour afficher le Gestionnaire de Projets</i>",
59+
"empty": "Aucun projet ouvert"
60+
},
61+
"path": {
62+
"tooltip": "Dossier de travail actuel"
63+
},
64+
"log": {
65+
"tooltip": "Journal<br><i>Cliquer pour Afficher/Masquer le Journal Vue CLI</i>",
66+
"empty": "Aucun entrée dans le journal"
67+
}
68+
}
69+
},
70+
"mixins": {
71+
"progress": {
72+
"creating": "Création du projet...",
73+
"git-init": "Initialisation du dépôt git...",
74+
"plugins-install": "Installation des plugins Vue CLI. Ceci peut prendre un certain temps...",
75+
"invoking-generators": "Invocation des générateurs...",
76+
"deps-install": "Installation des dépendances additionnelles...",
77+
"completion-hooks": "Lancement des hooks de fin...",
78+
"fetch-remote-preset": "Téléchargement du preset distant...",
79+
"done": "Projet créé avec succès",
80+
"plugin-install": "Installation de {arg0}...",
81+
"plugin-uninstall": "Désinstallation de {arg0}...",
82+
"plugin-invoke": "Invocation de {arg0}..."
83+
}
84+
},
85+
"views": {
86+
"project-select": {
87+
"title": "Gestion des Projets Vue",
88+
"tabs": {
89+
"projects": "Projets",
90+
"create": "Créer",
91+
"import": "Importer"
92+
},
93+
"buttons": {
94+
"create": "Créer un nouveau projet ici",
95+
"import": "Importer ce dossier"
96+
}
97+
},
98+
"project-create": {
99+
"title": "Créer un nouveau projet",
100+
"tabs": {
101+
"details": {
102+
"title": "Détails",
103+
"form": {
104+
"folder": {
105+
"label": "Dossier du projet",
106+
"placeholder": "mon-app",
107+
"tooltip": "Modifier le dossier cible",
108+
"action": "Sélectionner ce dossier"
109+
},
110+
"manager": {
111+
"label": "Gestionnaire de paquets",
112+
"default": "Par défaut"
113+
},
114+
"options": {
115+
"label": "Options additionnelles",
116+
"description": "Ecraser le dossier s'il existe"
117+
}
118+
},
119+
"buttons": {
120+
"cancel": "Annuler",
121+
"next": "Suivant"
122+
},
123+
"modal": {
124+
"title": "Annuler et réintialiser la création de projet",
125+
"body": "Êtes-vous sûr de vouloir réinitialiser la création de projet?",
126+
"buttons": {
127+
"back": "Revenir en arrière",
128+
"clear": "Supprimer le projet"
129+
}
130+
}
131+
},
132+
"presets": {
133+
"title": "Presets",
134+
"description": "Un preset est un ensemble de plugins et de configurations prédéfins. Après avoir sélectionné des fonctionnalités, vous pouves sauvegarder la sélection actuelle dans un nouveau preset que vous pourrez réutiliser pour de futurs projets, sans avoir à tout reconfigurer à nouveau.",
135+
"select": "Sélectionner un preset",
136+
"buttons": {
137+
"previous": "Précédent",
138+
"next": "Suivant",
139+
"create": "Créer le projet"
140+
},
141+
"modal": {
142+
"title": "Configurer le preset distant",
143+
"body": "Bientôt disponible..."
144+
}
145+
},
146+
"features": {
147+
"title": "Fonctionnalités",
148+
"description": "Vous pourrez ajouter des fonctionnalités après la création du projet en installant des plugins.",
149+
"enable": "Activer des fonctionnalités",
150+
"buttons": {
151+
"previous": "Précédent",
152+
"next": "Suivant",
153+
"create": "Créer le projet"
154+
}
155+
},
156+
"configuration": {
157+
"title": "Configuration",
158+
"buttons": {
159+
"previous": "Précédent",
160+
"create": "Créer le projet"
161+
},
162+
"modal": {
163+
"title": "Sauvegarder dans un nouveau preset",
164+
"body": {
165+
"title": "Nom du preset",
166+
"subtitle": "Sauvegarder les fonctionnalités et configurations dans un nouveau preset"
167+
},
168+
"buttons": {
169+
"cancel": "Annuler",
170+
"continue": "Continuer sans sauvegarder",
171+
"create": "Créer un nouveau preset"
172+
}
173+
}
174+
}
175+
}
176+
},
177+
"project-plugins": {
178+
"title": "Plugins du projet",
179+
"button": "Ajouter un plugin",
180+
"heading": "Plugins installés"
181+
},
182+
"project-plugins-add": {
183+
"title": "Ajouter un plugin",
184+
"plugin": "un plugin",
185+
"tabs": {
186+
"search": {
187+
"label": "Recherche",
188+
"search-input": "Rechercher un plugin",
189+
"not-found": "Aucun résultat trouvé",
190+
"buttons": {
191+
"cancel": "Annuler",
192+
"install": "Installer {target}"
193+
}
194+
},
195+
"configuration": {
196+
"label": "Configuration",
197+
"heading": "Installation de {target}",
198+
"buttons": {
199+
"cancel": "Annuler",
200+
"finish": "Terminer l'installation"
201+
}
202+
}
203+
},
204+
"modal": {
205+
"title": "Désinstaller {target}?",
206+
"body": "Voulez-vous désinstaller le plugin {target}?",
207+
"buttons": {
208+
"back": "Revenir en arrière",
209+
"cancel": "Annuler sans désinstaller",
210+
"uninstall": "Désinstaller"
211+
}
212+
}
213+
},
214+
"project-configuration": {
215+
"title": "Configuration du projet"
216+
},
217+
"project-tasks": {
218+
"title": "Tâches du projet"
219+
}
220+
}
221+
}

0 commit comments

Comments
 (0)