diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/admin.js b/openid-connect-server-webapp/src/main/webapp/resources/js/admin.js index 509840676..ca1134331 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/admin.js +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/admin.js @@ -560,7 +560,7 @@ var AppRouter = Backbone.Router.extend({ $('#content').html(view.render().el); - setPageTitle("New Client"); + setPageTitle($.t('client.client-form.new')); }); }, @@ -611,7 +611,7 @@ var AppRouter = Backbone.Router.extend({ var view = new ClientFormView({model:client, systemScopeList: app.systemScopeList}); view.load(function() { $('#content').html(view.render().el); - setPageTitle("Edit Client"); + setPageTitle($.t('client.client-form.edit')); }); @@ -725,7 +725,7 @@ var AppRouter = Backbone.Router.extend({ if (client != null) { this.whiteListFormView = new WhiteListFormView({model: whiteList, client: client, systemScopeList: this.systemScopeList}); $('#content').html(this.whiteListFormView.render().el); - setPageTitle("Edit Whitelist"); + setPageTitle($.t('whitelist.edit')); } else { console.log('ERROR: no client found for ' + whiteList.get('clientId')); @@ -749,7 +749,7 @@ var AppRouter = Backbone.Router.extend({ view.load( function(collection, response, options) { $('#content').html(view.render().el); - setPageTitle("Manage Approved Sites"); + setPageTitle($.t('grant.manage-approved-sites')); } ); @@ -769,7 +769,7 @@ var AppRouter = Backbone.Router.extend({ view.load( function(collection, response, options) { $('#content').html(view.render().el); - setPageTitle("Manage Active Tokens"); + setPageTitle($.t('token.manage')); } ); @@ -806,7 +806,7 @@ var AppRouter = Backbone.Router.extend({ view.load( function(collection, response, options) { $('#content').html(view.render().el); - setPageTitle("Manage Blacklist"); + setPageTitle($.t('admin.manage-blacklist')); } ); }, @@ -937,7 +937,7 @@ var AppRouter = Backbone.Router.extend({ $('#content').html(view.render().el); view.delegateEvents(); - setPageTitle("Dynamically Register a New Client"); + setPageTitle($.t('dynreg.new-client')); }); @@ -953,7 +953,7 @@ var AppRouter = Backbone.Router.extend({ this.updateSidebar('dev/dynreg'); - setPageTitle("Edit a Dynamically Registered Client"); + setPageTitle($.t('dynreg.edit-existing')); // note that this doesn't actually load the client, that's supposed to happen elsewhere... }, @@ -1004,7 +1004,7 @@ var AppRouter = Backbone.Router.extend({ $('#content').html(view.render().el); view.delegateEvents(); - setPageTitle("Dynamically Register a New Protected Resource"); + setPageTitle($.t('rsreg.new-resource')); }); @@ -1020,7 +1020,7 @@ var AppRouter = Backbone.Router.extend({ this.updateSidebar('dev/resource'); - setPageTitle("Edit a Dynamically Registered Protected Resource"); + setPageTitle($.t('rsreg.edit-existing')); // note that this doesn't actually load the client, that's supposed to happen elsewhere... }, diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js b/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js index a972c871c..9702ef471 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js @@ -465,7 +465,7 @@ var DynRegEditView = Backbone.View.extend({ }); var scopeView = new ListWidgetView({ - placeholder: 'new scope', + placeholder: $.t('client.client-form.scope-placeholder'), autocomplete: _.uniq(_.flatten(this.options.systemScopeList.pluck("value"))), collection: this.scopeCollection}); $("#scope .controls",this.el).html(scopeView.render().el); @@ -500,7 +500,7 @@ var DynRegEditView = Backbone.View.extend({ }); var defaultAcrView = new ListWidgetView({ - placeholder: 'new ACR value', + placeholder: $.t('client.client-form.acr-values-placeholder'), // TODO: autocomplete from spec collection: this.defaultAcrValuesCollection}); $('#defaultAcrValues .controls', this.el).html(defaultAcrView.render().el); diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/locale/en/messages.json b/openid-connect-server-webapp/src/main/webapp/resources/js/locale/en/messages.json index bfb3b183e..d81be672d 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/locale/en/messages.json +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/locale/en/messages.json @@ -7,6 +7,7 @@ "list-widget": { "empty": "There are no items in this list." }, + "manage-blacklist": "Manage Blacklist", "user-profile": { "claim": "Claim name:", "text": "Your user profile has the following information:", @@ -118,6 +119,7 @@ "show-secret": "Show Secret", "unchanged": "unchanged" }, + "scope-placeholder": "nytt scope", "seconds": "seconds", "secret-asymmetric-jwt": "Asymmetrically-signed JWT assertion", "secret-http": "Client Secret over HTTP Basic", @@ -212,7 +214,7 @@ "will-be-generated": "Will be generated" }, "grant": { - "more-info": "more information", + "manage-approved-sites": "Manage Approved Sites", "refresh": "Refresh", "grant-table": { "active-tokens": "Number of currently active access tokens", @@ -275,6 +277,7 @@ } }, "token": { + "manage": "Administrera aktiva tokens", "token-table": { "access-tokens": "Access Tokens", "associated-id": "This access token was issued with an associated ID token.", @@ -294,6 +297,7 @@ }, "whitelist": { "confirm": "Are you sure you want to delete this whitelist entry?", + "edit": "Edit Whitelist", "whitelist": "Whitelist", "whitelist-form": { "allowed-scopes": "Allowed Scopes", diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/locale/sv/messages.json b/openid-connect-server-webapp/src/main/webapp/resources/js/locale/sv/messages.json index 7ccc0b6ed..5c3a8f2e2 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/locale/sv/messages.json +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/locale/sv/messages.json @@ -4,6 +4,7 @@ "blacklist-form": { "blacklisted-uris": "Svarlistade länkar" }, + "manage-blacklist": "Administrera svartlista", "list-widget": { "empty": "Det finns inget innehåll i denna lista." }, @@ -32,7 +33,7 @@ "client-id-help": "Unik identifierare. Om du lämnar detta fält tomt kommer ett nytt ID genereras automatiskt", "client-id-placeholder": "Skriv någonting", "client-name": "Klientnamn", - "client-name-help": "Läsbar och begripligt namn på klienten", + "client-name-help": "Läsbart och begripligt namn på klienten", "client-name-placeholder": "Skriv någonting", "client-password": "lösenord", "client-secret": "Klienthemlighet", @@ -65,7 +66,7 @@ "generate-on-save": "Genereras vid sparande", "grant-types": "Grant-typer", "home": "Hemsida", - "home-help": "Länk till tjänstens hemsida. Den kommer att visas på bekräftelsesidan.", + "home-help": "Länk till tjänstens hemsida. Den visas på bekräftelsesidan.", "hours": "timmar", "id": "ID:", "id-token-crypto-algorithm": "Krypteringsalgoritm för ID-token", @@ -79,7 +80,7 @@ "jwk-set": "JWK Set", "jwk-set-help": "Länk till klientens JSON Webb-nyckel-set", "logo": "Logotyp", - "logo-help": "Länk till en logotyp. Den kommer att visas på bekräftelsesidan.", + "logo-help": "Länk till en logotyp. Den visas på bekräftelsesidan.", "main": "Basinformation", "max-age": "Max sessions-längd", "max-age-help": "Default maximal sessions-längd innan användaren tillfrågas igen", @@ -118,6 +119,7 @@ "show-secret": "Visa hemlighet", "unchanged": "oförändrad" }, + "scope-placeholder": "new scope", "seconds": "sekunder", "secret-asymmetric-jwt": "Asymmetriskt signerad JWT assertion", "secret-http": "Klienthemlighet över HTTP Basic", @@ -215,6 +217,7 @@ "will-be-generated": "Kommer att genereras" }, "grant": { + "manage-approved-sites": "Manage Approved Sites", "refresh": "Uppdatera", "grant-table": { "active-tokens": "Antal nu aktiva åtkomst-tokens", @@ -234,14 +237,14 @@ }, "rsreg": { "resource-id-placeholder": "Mata in resurs-ID", - "configuration-url": "Konfigurationslänk för klienten", + "configuration-url": "Konfigurationslänk för resursen", "edit-existing": "Ändra en befintlig resurs", "edit-existing-help": "Klistra in ditt resurs-ID och registrerings-access-token för att komma åt resursens egenskaper.", - "invalid-access-token": "Ogiltig klient eller registration-access-token.", - "new-client": "Registrera en ny klient", - "or": " - ELLER - ", - "regtoken-placeholder": "Mata in registration-access-token", - "will-be-generated": "Kommer att genereras" + "invalid-access-token": "Ogiltig resurs eller registration-access-token.", + "new": "Registrera en ny resurs", + "edit": "Ändra en befintlig resurs", + "new-resource": "Registrera en ny resurs", + "regtoken-placeholder": "Mata in registration-access-token" }, "scope": { "scope-list": { @@ -273,6 +276,7 @@ } }, "token": { + "manage-tokens": "Manage Active Tokens", "token-table": { "access-tokens": "Access-token", "associated-id": "Denna access-token utfärdades med en tillhörande ID-token.", @@ -291,6 +295,7 @@ }, "whitelist": { "confirm": "Är du säker på att du vill ta bort den här klienten ifrån vitlistan?", + "edit": "Redigera vitlista", "whitelist": "Vitlista", "whitelist-form": { "allowed-scopes": "Tillåtna scope", diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js b/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js index 97112add6..8e275b772 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js @@ -70,7 +70,7 @@ var ResRegRootView = Backbone.View.extend({ } $('#loadingbox').sheet('show'); - $('#loading').html('Scopes '); + $('#loading').html('' + $.t('common.scopes') + ' '); $.when(this.options.systemScopeList.fetchIfNeeded({success:function(e) {$('#loading-scopes').addClass('label-success');}})) .done(function() { @@ -110,7 +110,7 @@ var ResRegRootView = Backbone.View.extend({ view.load(function() { $('#content').html(view.render().el); view.delegateEvents(); - setPageTitle("Dynamically Register a New Protected Resource"); + setPageTitle($.t('rsreg.new')); app.navigate('dev/resource/edit', {trigger: true}); self.remove(); }); @@ -154,7 +154,7 @@ var ResRegEditView = Backbone.View.extend({ } $('#loadingbox').sheet('show'); - $('#loading').html('Scopes '); + $('#loading').html('' + $.t('common.scopes') + ' '); $.when(this.options.systemScopeList.fetchIfNeeded({success:function(e) {$('#loading-scopes').addClass('label-success');}})) .done(function() { @@ -179,7 +179,7 @@ var ResRegEditView = Backbone.View.extend({ deleteClient:function (e) { e.preventDefault(); - if (confirm("Are you sure sure you would like to delete this client?")) { + if (confirm($.t('client.client-table.confirm'))) { var self = this; this.model.destroy({ @@ -366,7 +366,7 @@ var ResRegEditView = Backbone.View.extend({ }); var scopeView = new ListWidgetView({ - placeholder: 'new scope', + placeholder: $.t('client.client-form.scope-placeholder'), autocomplete: _.uniq(_.flatten(this.options.systemScopeList.pluck("value"))), collection: this.scopeCollection}); $("#scope .controls",this.el).html(scopeView.render().el); @@ -378,7 +378,7 @@ var ResRegEditView = Backbone.View.extend({ }); var contactView = new ListWidgetView({ - placeholder: 'new contact', + placeholder: $.t('client.client-form.contacts-placeholder'), collection: this.contactsCollection}); $("#contacts .controls div", this.el).html(contactView.render().el); this.listWidgetViews.push(contactView); @@ -402,7 +402,7 @@ var ResRegEditView = Backbone.View.extend({ }); var defaultAcrView = new ListWidgetView({ - placeholder: 'new ACR value', + placeholder: $.t('client.client-form.acr-values-placeholder'), // TODO: autocomplete from spec collection: this.defaultAcrValuesCollection}); $('#defaultAcrValues .controls', this.el).html(defaultAcrView.render().el); diff --git a/openid-connect-server-webapp/src/main/webapp/resources/template/rsreg.html b/openid-connect-server-webapp/src/main/webapp/resources/template/rsreg.html index 158aef91f..3b1c0714d 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/template/rsreg.html +++ b/openid-connect-server-webapp/src/main/webapp/resources/template/rsreg.html @@ -24,7 +24,7 @@
- - OR - + - OR -
@@ -78,9 +78,13 @@
- +
-
<%-client.client_id ? client.client_id : 'Will be generated'%>
+ <% if (client.client_id) { %> +
<%-client.client_id%>
+ <% } else { %> + Will be generated + <% } %>
@@ -102,7 +106,7 @@ <% } %> <% } %> <% } else { %> -
Will be generated
+ Will be generated <% } %> @@ -110,50 +114,24 @@
- +
-
<%-client.registration_client_uri ? client.registration_client_uri : 'Will be generated'%>
+ <% if (client.registration_client_uri) { %> +
<%-client.registration_client_uri%>
+ <% } else { %> + Will be generated + <% } %>
- +
-
<%-client.registration_access_token ? client.registration_access_token : 'Will be generated'%>
-
-
- - <% } else { %> - -
- -
- Will be generated -
-
- - -
- -
-
- Will be generated -
-
- -
- -
- -
- Will be generated -
-
- -
- -
- Will be generated + <% if (client.registration_access_token) { %> +
<%-client.registration_access_token%>
+ <% } else { %> + Will be generated + <% } %>
@@ -161,19 +139,19 @@
- +
-

Human-readable application name

+

Human-readable application name

- -
- -

URL that points to a logo image, will be displayed on approval page

-
+ +
+ +

URL that points to a logo image, will be displayed on approval page

+
@@ -183,46 +161,46 @@
- -
- -

URL for the Terms of Service of this client, will be displayed to the user

-
+ +
+ +

URL for the Terms of Service of this client, will be displayed to the user

+
- -
- -

URL for the Policy Statement of this client, will be displayed to the user

-
+ +
+ +

URL for the Policy Statement of this client, will be displayed to the user

+
- -
- -

URL for the client's home page, will be displayed to the user

-
+ +
+ +

URL for the client's home page, will be displayed to the user

+
- -
- - -
+ +
+ + +
- +
- List of contacts for adminstrators of this client. Your email address (<%- userInfo.email %>) will be automatically added to this list on save. -
+

List of contacts for adminstrators of this client.

+
@@ -231,7 +209,7 @@
- +
@@ -240,50 +218,55 @@
- -
- - - - - -
+ +
+
+ > + +
+
+ > + +
+
+ > + +
+
+ > + +
+
+ > + +
+
- +
- +
- -
- -

URL for the client's JSON Web Key set

-
+ +
+ +

URL for the client's JSON Web Key set

+