From b9b336898854f7adb47cf0b4a2408a154d4c1856 Mon Sep 17 00:00:00 2001 From: Luis Deschamps Rudge Date: Tue, 12 Jun 2018 18:47:14 -0300 Subject: [PATCH 1/2] In SSO mode, hide the password input instead of removing it from the DOM --- css/index.styl | 3 +++ .../__snapshots__/login_pane.test.jsx.snap | 14 +++++++++++++ .../__snapshots__/password_pane.test.jsx.snap | 20 +++++++++++++++++++ src/__tests__/field/password_pane.test.jsx | 4 ++++ src/connection/database/login_pane.jsx | 11 +++++----- src/field/password/password_pane.jsx | 8 +++++--- 6 files changed, 52 insertions(+), 8 deletions(-) diff --git a/css/index.styl b/css/index.styl index ebff6b2dd..a1954501d 100644 --- a/css/index.styl +++ b/css/index.styl @@ -1361,3 +1361,6 @@ tabsHeight = 40px input[type="button"] cursor pointer + +.auth0-lock-hidden + display: none \ No newline at end of file diff --git a/src/__tests__/field/__snapshots__/login_pane.test.jsx.snap b/src/__tests__/field/__snapshots__/login_pane.test.jsx.snap index 286189c22..e0977b991 100644 --- a/src/__tests__/field/__snapshots__/login_pane.test.jsx.snap +++ b/src/__tests__/field/__snapshots__/login_pane.test.jsx.snap @@ -12,6 +12,7 @@ exports[`LoginPane hides password link when lock does not have the screen \`forg />
+

@@ -74,6 +83,7 @@ exports[`LoginPane renders correctly 1`] = ` />

`; +exports[`PasswordPane renders correct css className when \`hidden\` is true 1`] = ` +
+
+
+`; + exports[`PasswordPane renders correctly 1`] = `
{ const PasswordPane = getComponent(); expectComponent().toMatchSnapshot(); }); + it('renders correct css className when `hidden` is true', () => { + const PasswordPane = getComponent(); + expectComponent(