From acb366767a28b45fcd1ecb95e4087e43c7d81b62 Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Mon, 10 Jul 2017 16:28:28 -0600 Subject: [PATCH 01/18] safelogin.org to daplie.me --- index.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/index.html b/index.html index 7fcc9f5..7fdefd7 100644 --- a/index.html +++ b/index.html @@ -23,8 +23,8 @@
-

Safelogin.org

-

Welcome to a new way to login. Safelogin.org helps you create an Internet ID that allows you to choose what info is shared about you when you login into a site or app online.

+

daplie.me

+

Welcome to a new way to login. daplie.me helps you create an Internet ID that allows you to choose what info is shared about you when you login into a site or app online.

@@ -45,7 +45,7 @@
-

Safelogin.org

+

daplie.me

- + diff --git a/js/script.js b/js/script.js index ae26237..1a5c63c 100644 --- a/js/script.js +++ b/js/script.js @@ -69,28 +69,32 @@ $('body').on('click', '.js-auth-li-enabled', function (ev) { } }); -// $('body').on('keyup keypress', '.js-authn-otp-code', function (e) { -// 'use strict'; -// var keyCode = e.keyCode || e.which; -// var regex = new RegExp('^[0-9 \-]+$'); -// var key = String.fromCharCode(!e.charCode ? e.which : e.charCode); -// var oauthCode = $(this).val().split('-').join('').replace(/\s/g, ''); -// -// if (!regex.test(key)) { -// event.preventDefault(); -// return false; -// } -// -// if (oauthCode.length > 0) { -// oauthCode = oauthCode.match(new RegExp('.{1,4}', 'g')).join("-"); -// } -// -// $(this).val(oauthCode); -// -// if($(this).val().length === $(this).attr("maxlength")){ -// $('.submit-btn').prop("disabled", false); -// } -// }); +$('body').on('keyup keypress', '.js-authn-otp-code', function (e) { + 'use strict'; + // var keyCode = e.keyCode || e.which; + // var regex = new RegExp('^[0-9 \-]+$'); + // var key = String.fromCharCode(!e.charCode ? e.which : e.charCode); + // var oauthCode = $(this).val().split('-').join('').replace(/\s/g, ''); + // + // if (!regex.test(key)) { + // event.preventDefault(); + // return false; + // } + // + // if (oauthCode.length > 0) { + // oauthCode = oauthCode.match(new RegExp('.{1,4}', 'g')).join("-"); + // } + // + // $(this).val(oauthCode); + // + // if($(this).val().length === $(this).attr("maxlength")){ + // $('.submit-btn').prop("disabled", false); + // } + if ($(this).val().length === 14) { + $('.submit-btn').prop('disabled', false); + } + +}); $('.js-authn-otp-code').mask('####-####-####'); From c588ea7d3d7a205070e803a9e50e7aa1cab99734 Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Tue, 11 Jul 2017 16:29:07 -0600 Subject: [PATCH 05/18] fixing disabled --- js/script.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/script.js b/js/script.js index 1a5c63c..ab84331 100644 --- a/js/script.js +++ b/js/script.js @@ -92,8 +92,9 @@ $('body').on('keyup keypress', '.js-authn-otp-code', function (e) { // } if ($(this).val().length === 14) { $('.submit-btn').prop('disabled', false); + } else { + $('.submit-btn').prop('disabled', true); } - }); $('.js-authn-otp-code').mask('####-####-####'); From 837bdd80c9c8b2b8b033fc0fa6b7950245f809f3 Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Tue, 11 Jul 2017 16:40:36 -0600 Subject: [PATCH 06/18] fixing js --- js/script.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/js/script.js b/js/script.js index ab84331..d609437 100644 --- a/js/script.js +++ b/js/script.js @@ -90,11 +90,7 @@ $('body').on('keyup keypress', '.js-authn-otp-code', function (e) { // if($(this).val().length === $(this).attr("maxlength")){ // $('.submit-btn').prop("disabled", false); // } - if ($(this).val().length === 14) { - $('.submit-btn').prop('disabled', false); - } else { - $('.submit-btn').prop('disabled', true); - } + $(this).val().length === 14 ? $('.submit-btn').prop('disabled', false) : $('.submit-btn').prop('disabled', true); }); $('.js-authn-otp-code').mask('####-####-####'); From 37bd95fd54dbe03288c13f46d78f771b5d4145eb Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Wed, 12 Jul 2017 09:56:17 -0600 Subject: [PATCH 07/18] testing --- js/issuer.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/issuer.js b/js/issuer.js index eff27af..a6c34f3 100644 --- a/js/issuer.js +++ b/js/issuer.js @@ -262,7 +262,7 @@ $(function () { // Reference Implementation util.submitLoginCode = function (opts) { - + console.log("clicked???") // TODO // perhaps we should check that the code is valid before continuing to login (so that we don't send the key) From 624ccf02a04cf1891b54c438730ab8773b25b88f Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Wed, 12 Jul 2017 09:59:07 -0600 Subject: [PATCH 08/18] i donno --- js/issuer.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/issuer.js b/js/issuer.js index a6c34f3..20e9825 100644 --- a/js/issuer.js +++ b/js/issuer.js @@ -262,7 +262,7 @@ $(function () { // Reference Implementation util.submitLoginCode = function (opts) { - console.log("clicked???") + // TODO // perhaps we should check that the code is valid before continuing to login (so that we don't send the key) @@ -311,6 +311,8 @@ $(function () { return getAccount(session).then(function () { return getGrants(session); }); + }, function (err) { + console.log(err); }); }; From d4460575244ad7f7c30147ce46d1abe3a4eb83db Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Wed, 12 Jul 2017 10:00:49 -0600 Subject: [PATCH 09/18] fixing typo --- js/issuer.js | 1 + 1 file changed, 1 insertion(+) diff --git a/js/issuer.js b/js/issuer.js index 20e9825..da417d8 100644 --- a/js/issuer.js +++ b/js/issuer.js @@ -312,6 +312,7 @@ $(function () { return getGrants(session); }); }, function (err) { + console.log("oooooooppppps"); console.log(err); }); From 1d02c1d42424675bf6b192d2bed14b1a732cbccd Mon Sep 17 00:00:00 2001 From: Jon Lambson Date: Wed, 12 Jul 2017 10:08:56 -0600 Subject: [PATCH 10/18] error msg --- css/daplie-installer-overrides.css | 3 +++ index.html | 1 + js/issuer.js | 5 ++--- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/css/daplie-installer-overrides.css b/css/daplie-installer-overrides.css index 2d8abfc..a00cb00 100644 --- a/css/daplie-installer-overrides.css +++ b/css/daplie-installer-overrides.css @@ -445,3 +445,6 @@ span.dap-small-text.js-scope-desc.noselect { color : #808080; color : rgb(128, 128, 128); } +.error-msg { + color: #FDA748; +} diff --git a/index.html b/index.html index e1ef2f2..51da29c 100644 --- a/index.html +++ b/index.html @@ -61,6 +61,7 @@

Code lasts for 15 minutes.

+