diff --git a/app/components/dashboard/dashboard.html b/app/components/dashboard/dashboard.html index 063ec3090..cf3b2a9cb 100644 --- a/app/components/dashboard/dashboard.html +++ b/app/components/dashboard/dashboard.html @@ -1,31 +1,33 @@ - + - Dashboard + + +
-
+
- + - + - + - + @@ -33,26 +35,26 @@ -
+
- +
DASHBOARD.WIDGET_NODE.NODE_NAME {{ infoData.Name }}
DASHBOARD.WIDGET_NODE.DOCKER_VERSION {{ infoData.ServerVersion }}
DASHBOARD.WIDGET_NODE.CPU {{ infoData.NCPU }}
DASHBOARD.WIDGET_NODE.MEMORY {{ infoData.MemTotal|humansize }}
- + - + - + - + @@ -60,21 +62,23 @@ -
+
- +
Nodes {{ infoData.SystemStatus[0][1] == 'primary' ? infoData.SystemStatus[3][1] : infoData.SystemStatus[4][1] }}
Swarm version {{ infoData.ServerVersion|swarmversion }}
Total CPU {{ infoData.NCPU }}
Total memory {{ infoData.MemTotal|humansize: 2 }}
- + - + - + @@ -93,11 +97,11 @@
-
{{ containerData.running }} running
-
{{ containerData.stopped }} stopped
+
{{ containerData.running }}
+
{{ containerData.stopped }}
{{ containerData.total }}
-
Containers
+
@@ -113,7 +117,7 @@
{{ imageData.size|humansize }}
{{ imageData.total }}
-
Images
+
@@ -126,10 +130,10 @@
-
{{ infoData.Driver }} driver
+
{{ infoData.Driver }}
{{ volumeData.total }}
-
Volumes
+
@@ -142,12 +146,9 @@
{{ networkData.total }}
-
Networks
+
- -
-
diff --git a/app/components/sidebar/sidebar.html b/app/components/sidebar/sidebar.html index 068dab150..c8ed2afea 100644 --- a/app/components/sidebar/sidebar.html +++ b/app/components/sidebar/sidebar.html @@ -9,68 +9,121 @@ - - + diff --git a/app/directives/header-content.js b/app/directives/header-content.js index ecb52136d..f4d217da7 100644 --- a/app/directives/header-content.js +++ b/app/directives/header-content.js @@ -7,7 +7,7 @@ angular link: function (scope, iElement, iAttrs) { scope.username = Authentication.getUserDetails().username; }, - template: '', + template: '', restrict: 'E' }; return directive; diff --git a/app/directives/header-title.js b/app/directives/header-title.js index 3001d4f34..231de7173 100644 --- a/app/directives/header-title.js +++ b/app/directives/header-title.js @@ -10,7 +10,7 @@ angular scope.username = Authentication.getUserDetails().username; }, transclude: true, - template: '
{{title}} {{username}}
', + template: '
{{username}}
', restrict: 'E' }; return directive; diff --git a/app/directives/translation/por-translation.js b/app/directives/translation/por-translation.js new file mode 100644 index 000000000..8df162747 --- /dev/null +++ b/app/directives/translation/por-translation.js @@ -0,0 +1,6 @@ +angular.module('portainer').component('porTranslation', { + bindings: { + 'key': '@' + }, + template: '{{ $ctrl.key }}' +}); diff --git a/assets/i18n/en.json b/assets/i18n/en.json index 13069e092..f49fde244 100644 --- a/assets/i18n/en.json +++ b/assets/i18n/en.json @@ -1,11 +1,81 @@ { + "WIDGETS": { + "HEADER_CONTENT": { + "USER_PREFERENCES": "my account", + "LOGOUT": "log out" + } + }, + "SIDEBAR": { + "ACTIVE_ENDPOINT": { + "TITLE": "Active endpoint" + }, + "ENDPOINT_ACTIONS": { + "TITLE": "Endpoint actions", + "DASHBOARD": "Dashboard", + "APP_TEMPLATES": "App Templates", + "SERVICES": "Services", + "CONTAINERS": "Containers", + "IMAGES": "Images", + "NETWORKS": "Networks", + "VOLUMES": "Volumes", + "SECRETS": "Secrets", + "EVENTS": "Events", + "SWARM": "Swarm", + "DOCKER": "Docker" + }, + "PORTAINER_SETTINGS": { + "TITLE": "Portainer settings", + "USER_MANAGEMENT": { + "TITLE": "User management", + "TEAMS": "Teams" + }, + "ENDPOINTS": "Endpoints", + "REGISTRIES": "Registries", + "SETTINGS": { + "TITLE": "Settings", + "AUTHENTICATION": "Authentication" + } + } + }, "DASHBOARD": { + "HEADER": { + "TITLE": "Home", + "CONTENT": "Dashboard" + }, + "WIDGET_CLUSTER": { + "TITLE": "Cluster info", + "NODES": "Nodes", + "SWARM_VERSION": "Swarm version", + "CPU": "Total CPU", + "MEMORY": "Total memory" + }, + "WIDGET_SWARM": { + "TITLE": "Swarm info", + "COMMENT": "This node is part of a Swarm cluster", + "NODE_ROLE": "Node role", + "NODES_IN_CLUSTER": "Nodes in the cluster" + }, "WIDGET_NODE": { "TITLE": "Node info", "NODE_NAME": "Name", "DOCKER_VERSION": "Docker version", "CPU": "CPU", "MEMORY": "Memory" + }, + "WIDGET_CONTAINERS": { + "COMMENT": "Containers", + "RUNNING_CONTAINERS": "running", + "STOPPED_CONTAINERS": "stopped" + }, + "WIDGET_IMAGES": { + "COMMENT": "Images" + }, + "WIDGET_VOLUMES": { + "COMMENT": "Volumes", + "DRIVER": "driver" + }, + "WIDGET_NETWORKS": { + "COMMENT": "Networks" } } } diff --git a/assets/i18n/fr.json b/assets/i18n/fr.json index 0e8edf45e..7546b5622 100644 --- a/assets/i18n/fr.json +++ b/assets/i18n/fr.json @@ -1,11 +1,81 @@ { + "WIDGETS": { + "HEADER_CONTENT": { + "USER_PREFERENCES": "mon compte", + "LOGOUT": "se déconnecter" + } + }, + "SIDEBAR": { + "ACTIVE_ENDPOINT": { + "TITLE": "Environnement actif" + }, + "ENDPOINT_ACTIONS": { + "TITLE": "Actions de l'environnement", + "DASHBOARD": "Tableau de bord", + "APP_TEMPLATES": "App Templates", + "SERVICES": "Services", + "CONTAINERS": "Conteneurs", + "IMAGES": "Images", + "NETWORKS": "Réseaux", + "VOLUMES": "Volumes", + "SECRETS": "Secrets", + "EVENTS": "Evénements", + "SWARM": "Swarm", + "DOCKER": "Docker" + }, + "PORTAINER_SETTINGS": { + "TITLE": "Paramètres de Portainer", + "USER_MANAGEMENT": { + "TITLE": "Gestion utilisateurs", + "TEAMS": "Equipes" + }, + "ENDPOINTS": "Environnements", + "REGISTRIES": "Registres", + "SETTINGS": { + "TITLE": "Paramètres", + "AUTHENTICATION": "Authentification" + } + } + }, "DASHBOARD": { + "HEADER": { + "TITLE": "Accueil", + "CONTENT": "Tableau de bord" + }, + "WIDGET_CLUSTER": { + "TITLE": "Informations à propos du cluster", + "NODES": "Nombre de noeuds", + "SWARM_VERSION": "Version de Swarm", + "CPU": "Total des processeurs", + "MEMORY": "Mémoire totale" + }, + "WIDGET_SWARM": { + "TITLE": "Informations à propos de Swarm", + "COMMENT": "Cet hôte fait partie d'un cluster Swarm", + "NODE_ROLE": "Rôle de l'hôte", + "NODES_IN_CLUSTER": "Nombre d'hôtes dans le cluster" + }, "WIDGET_NODE": { "TITLE": "Informations à propos de l'hôte", "NODE_NAME": "Nom", "DOCKER_VERSION": "Version de Docker", "CPU": "Processeurs", "MEMORY": "Mémoire" + }, + "WIDGET_CONTAINERS": { + "COMMENT": "Conteneurs", + "RUNNING_CONTAINERS": "en marche", + "STOPPED_CONTAINERS": "à l'arrêt" + }, + "WIDGET_IMAGES": { + "COMMENT": "Images" + }, + "WIDGET_VOLUMES": { + "COMMENT": "Volumes", + "DRIVER": "driver" + }, + "WIDGET_NETWORKS": { + "COMMENT": "Réseaux" } } }
This node is part of a Swarm cluster + +
Node role {{ infoData.Swarm.ControlAvailable ? 'Manager' : 'Worker' }}
Nodes in the cluster {{ infoData.Swarm.Nodes }}