mirror of
https://github.com/keeweb/keeweb.git
synced 2024-06-26 07:39:04 +02:00
Introduced a tooltip to make the secure field feature more understandable
Fixes #805
This commit is contained in:
parent
6a7bea7120
commit
77123756b6
|
@ -268,6 +268,8 @@
|
||||||
"detOtpQrErrorBody": "Sorry, we could not read the QR code, please try once again or contact the app authors with error details.",
|
"detOtpQrErrorBody": "Sorry, we could not read the QR code, please try once again or contact the app authors with error details.",
|
||||||
"detOtpQrWrong": "Wrong QR code",
|
"detOtpQrWrong": "Wrong QR code",
|
||||||
"detOtpQrWrongBody": "Your QR code was successfully scanned but it doesn't contain one-time password data.",
|
"detOtpQrWrongBody": "Your QR code was successfully scanned but it doesn't contain one-time password data.",
|
||||||
|
"detLockField": "Lock this field, so its content isn't searchable and visible. Displaying the content requires explicitly clicking it.",
|
||||||
|
"detUnlockField": "Unlock this field, making its content searchable and visible immediately",
|
||||||
|
|
||||||
"autoTypeEntryFields": "Entry fields",
|
"autoTypeEntryFields": "Entry fields",
|
||||||
"autoTypeModifiers": "Modifier keys",
|
"autoTypeModifiers": "Modifier keys",
|
||||||
|
|
|
@ -3,6 +3,8 @@ const FieldViewText = require('./field-view-text');
|
||||||
const FieldView = require('./field-view');
|
const FieldView = require('./field-view');
|
||||||
const Keys = require('../../const/keys');
|
const Keys = require('../../const/keys');
|
||||||
const kdbxweb = require('kdbxweb');
|
const kdbxweb = require('kdbxweb');
|
||||||
|
const Tip = require('../../util/tip');
|
||||||
|
const Locale = require('../../util/locale');
|
||||||
|
|
||||||
const FieldViewCustom = FieldViewText.extend({
|
const FieldViewCustom = FieldViewText.extend({
|
||||||
events: {
|
events: {
|
||||||
|
@ -23,6 +25,14 @@ const FieldViewCustom = FieldViewText.extend({
|
||||||
$('<div/>').addClass('details__field-value-btn details__field-value-btn-protect')
|
$('<div/>').addClass('details__field-value-btn details__field-value-btn-protect')
|
||||||
.appendTo(this.valueEl)
|
.appendTo(this.valueEl)
|
||||||
.mousedown(this.protectBtnClick.bind(this));
|
.mousedown(this.protectBtnClick.bind(this));
|
||||||
|
let securityTipTitle = Locale.detLockField;
|
||||||
|
if (this.isProtected) {
|
||||||
|
securityTipTitle = Locale.detUnlockField;
|
||||||
|
}
|
||||||
|
const securityTip = new Tip($(this.valueEl).find('.details__field-value-btn'), {
|
||||||
|
title: securityTipTitle
|
||||||
|
});
|
||||||
|
securityTip.init();
|
||||||
},
|
},
|
||||||
|
|
||||||
endEdit: function(newVal, extra) {
|
endEdit: function(newVal, extra) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user