#10328 Fix security font and values

This commit is contained in:
miguel angel rasteu 2023-05-16 17:03:10 +02:00
parent 1d885f5e42
commit 52886b96b3
3 changed files with 14 additions and 9 deletions

View File

@ -413,7 +413,7 @@ $(document).ready (function () {
$(".hide_inputs").each(function(index) { $(".hide_inputs").each(function(index) {
var $input_in_row = $(this).closest('tr').find('.field_value'); var $input_in_row = $(this).closest('tr').find('.field_value');
if($(this).is(':checked')) { if($(this).is(':checked')) {
$input_in_row.prop('style', '-webkit-text-security: disc;'); $input_in_row.prop('style', '-webkit-text-security: disc; font-family: text-security-disc;');
} else { } else {
$input_in_row.prop('style', ''); $input_in_row.prop('style', '');
} }
@ -422,9 +422,9 @@ $(document).ready (function () {
$(".hide_inputs").click(function() { $(".hide_inputs").click(function() {
var $input_in_row = $(this).closest('tr').find('.field_value'); var $input_in_row = $(this).closest('tr').find('.field_value');
if($(this).is(':checked')) { if($(this).is(':checked')) {
$input_in_row.prop('type', 'password'); $input_in_row.prop('style', '-webkit-text-security: disc; font-family: text-security-disc;');
} else { } else {
$input_in_row.prop('type', 'text') $input_in_row.prop('style', '');
} }
}); });
}); });

View File

@ -4273,22 +4273,22 @@ function html_print_checkbox_extended(
if (is_array($attributes) === true) { if (is_array($attributes) === true) {
$tmpAttributes = []; $tmpAttributes = [];
foreach ($attributes as $key => $val) { foreach ($attributes as $key => $value) {
switch ($key) { switch ($key) {
case 'input_class': case 'input_class':
$inputClass .= ' '.$val; $inputClass .= ' '.$value;
break; break;
case 'label_class': case 'label_class':
$labelClass .= ' '.$val; $labelClass .= ' '.$value;
break; break;
case 'label_style': case 'label_style':
$labelStyle .= 'style="'.$val.'"'; $labelStyle .= 'style="'.$value.'"';
break; break;
default: default:
$tmpAttributes[] = $key.'="'.$val.'"'; $tmpAttributes[] = $key.'="'.$value.'"';
break; break;
} }
} }

View File

@ -87,6 +87,11 @@
font-weight: 900; font-weight: 900;
} }
@font-face {
font-family: "text-security-disc";
src: url("https://raw.githubusercontent.com/noppa/text-security/master/dist/text-security-disc.woff");
}
/* /*
@font-face { @font-face {
font-family: "lato-italic"; font-family: "lato-italic";