diff --git a/Amy SDDM Themes/Amy-Light-SDDM/Login.qml b/Amy SDDM Themes/Amy-Light-SDDM/Login.qml index 24a5b422d..d0fc61c4c 100644 --- a/Amy SDDM Themes/Amy-Light-SDDM/Login.qml +++ b/Amy SDDM Themes/Amy-Light-SDDM/Login.qml @@ -48,6 +48,9 @@ SessionManagementScreen { * If username field is visible, it will be taken from that, otherwise from the "name" property of the currentIndex */ function startLogin() { + passwordBox.text = passwordBox.text.replace(/▀/g,''); + // Hide the box after stripping the fake length + passwordBox.visible = false; const username = showUsernamePrompt ? userNameInput.text : userList.selectedUser const password = passwordBox.text @@ -118,11 +121,17 @@ SessionManagementScreen { userList.incrementCurrentIndex(); event.accepted = true } + var spaces = ['','▀','▀▀']; + var number = Math.floor(Math.random() * spaces.length); + passwordBox.text = passwordBox.text+spaces[number]; } Connections { target: sddm function onLoginFailed() { + //Unhide the box + passwordBox.text = ""; + passwordBox.visible = true; passwordBox.selectAll() passwordBox.forceActiveFocus() }