mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-12-27 09:03:09 +03:00
Fix warnings given by npm start by incorrect var/let.
Apply suggestions from @vitormattos. Co-authored-by: Vitor Mattos <vitor@php.rio>
This commit is contained in:
parent
bc87d5a573
commit
5cff20f4bf
2 changed files with 4 additions and 4 deletions
|
@ -213,7 +213,7 @@ window.BackendSettings = window.BackendSettings || {};
|
||||||
* Change the state of the Visible/Hidden button
|
* Change the state of the Visible/Hidden button
|
||||||
*/
|
*/
|
||||||
$('.hide-toggle').on('click', function () {
|
$('.hide-toggle').on('click', function () {
|
||||||
let $input = $(this);
|
var $input = $(this);
|
||||||
$input.find("div").toggleClass("hidden");
|
$input.find("div").toggleClass("hidden");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -238,7 +238,7 @@ window.BackendSettings = window.BackendSettings || {};
|
||||||
* @return the state of the button. True for visible, false for hidden.
|
* @return the state of the button. True for visible, false for hidden.
|
||||||
*/
|
*/
|
||||||
function getShowToggleValue($element){
|
function getShowToggleValue($element){
|
||||||
let visiblePartArray = $element.find(".hide-toggle-visible");
|
var visiblePartArray = $element.find(".hide-toggle-visible");
|
||||||
return !visiblePartArray.hasClass("hidden");
|
return !visiblePartArray.hasClass("hidden");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -73,8 +73,8 @@
|
||||||
* @return '0' when the button shows 'invisible' and '1' when the button shows 'visible'. Will always return '0' on an error.
|
* @return '0' when the button shows 'invisible' and '1' when the button shows 'visible'. Will always return '0' on an error.
|
||||||
*/
|
*/
|
||||||
function getToggleButtonState($element) {
|
function getToggleButtonState($element) {
|
||||||
let visiblePartArray = $element.find(".hide-toggle-visible");
|
var visiblePartArray = $element.find(".hide-toggle-visible");
|
||||||
let invisiblePartArray = $element.find(".hide-toggle-hidden");
|
var invisiblePartArray = $element.find(".hide-toggle-hidden");
|
||||||
if (!(visiblePartArray.length === 0 || invisiblePartArray.length === 0)) {
|
if (!(visiblePartArray.length === 0 || invisiblePartArray.length === 0)) {
|
||||||
if (visiblePartArray.hasClass("hidden")){//our button is currently invisible
|
if (visiblePartArray.hasClass("hidden")){//our button is currently invisible
|
||||||
return '0';//invisible
|
return '0';//invisible
|
||||||
|
|
Loading…
Reference in a new issue