mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-10 06:16:32 +00:00
8f996992b2
Use new `PrivacyStore` method getPasswordStrengthScore and link it to the new password strength bar value. Used backend/general to call to `status-go` method and services/general to define the common `GetPasswordStrengthScore` service. Added onboarding chain to get password strength score information from `OnboardingStore` to `status-go` call. Closes #5096
35 lines
1.5 KiB
QML
35 lines
1.5 KiB
QML
pragma Singleton
|
|
|
|
import QtQuick 2.13
|
|
|
|
QtObject {
|
|
property var onBoardingModul: onboardingModule
|
|
|
|
function importMnemonic(mnemonic) {
|
|
onBoardingModul.importMnemonic(mnemonic)
|
|
}
|
|
|
|
function setCurrentAccountAndDisplayName(selectedAccountIdx, displayName) {
|
|
onBoardingModul.setDisplayName(displayName)
|
|
onBoardingModul.setSelectedAccountByIndex(selectedAccountIdx)
|
|
}
|
|
|
|
function getPasswordStrengthScore(password) {
|
|
let userName = onBoardingModul.importedAccountAlias
|
|
return onBoardingModul.getPasswordStrengthScore(password, userName)
|
|
}
|
|
|
|
property ListModel accountsSampleData: ListModel {
|
|
ListElement {
|
|
username: "Ferocious Herringbone Sinewave2"
|
|
identicon: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAAg0lEQVR4nOzXwQmAMBAFURV7sQybsgybsgyr0QYUlE1g+Mw7ioQMe9lMQwhDaAyhMYTGEJqYkPnrj/t5XE/ft2UdW1yken7MRAyhMYTGEBpDaAyhKe9JbzvSX9WdLWYihtAYQuMLkcYQGkPUScxEDKExhMYQGkNoDKExhMYQmjsAAP//ZfIUZgXTZXQAAAAASUVORK5CYII="
|
|
address: "0x123456789009876543211234567890"
|
|
}
|
|
ListElement {
|
|
username: "Another Account"
|
|
identicon: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAAg0lEQVR4nOzXwQmAMBAFURV7sQybsgybsgyr0QYUlE1g+Mw7ioQMe9lMQwhDaAyhMYTGEJqYkPnrj/t5XE/ft2UdW1yken7MRAyhMYTGEBpDaAyhKe9JbzvSX9WdLWYihtAYQuMLkcYQGkPUScxEDKExhMYQGkNoDKExhMYQmjsAAP//ZfIUZgXTZXQAAAAASUVORK5CYII="
|
|
address: "0x123456789009876543211234567890"
|
|
}
|
|
}
|
|
}
|