summaryrefslogtreecommitdiff
path: root/pages/LoginPass.qml
blob: 9e5d2f4576666351baa4d18619b71bbd10faa463 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import QtQuick 2.12
import KelakonUser 0.1

PasswordForm {
	width: stackView.width
	height: stackView.height
	backButton.onClicked: stackView.pop()
	instructionLabel.text: qsTr("Enter password")
	emailAddressLabel.text: User.name

	passTextField.onTextChanged: {
		if (!passTextField.text || !createPassButton.enabled)
			createPassButton.enabled = !createPassButton.enabled
	}

	createPassButton.onClicked: {
		User.password = passTextField.text
		onClicked: login.logIn(User.name, User.password)
	}
}